Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 894373 Details for
Bug 1096488
ICE In lambda function
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
preprocessed source
lamb.txt (text/plain), 8.98 MB, created by
Sami Farin
on 2014-05-11 04:30:49 UTC
(
hide
)
Description:
preprocessed source
Filename:
MIME Type:
Creator:
Sami Farin
Created:
2014-05-11 04:30:49 UTC
Size:
8.98 MB
patch
obsolete
>// /usr/libexec/gcc/x86_64-redhat-linux/4.9.0/cc1plus -fpreprocessed /home/honey/.ccache/tmp/core_rpc_s.tmp.lamb.11607.ii -march=sandybridge -mmmx -mno-3dnow -msse -msse2 -msse3 -mssse3 -mno-sse4a -mcx16 -msahf -mno-movbe -maes -mno-sha -mpclmul -mpopcnt -mno-abm -mno-lwp -mno-fma -mno-fma4 -mno-xop -mno-bmi -mno-bmi2 -mno-tbm -mavx -mno-avx2 -msse4.2 -msse4.1 -mno-lzcnt -mno-rtm -mno-hle -mno-rdrnd -mno-f16c -mno-fsgsbase -mno-rdseed -mno-prfchw -mno-adx -mfxsr -mxsave -mxsaveopt -mno-avx512f -mno-avx512er -mno-avx512cd -mno-avx512pf -mno-prefetchwt1 --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=6144 -mtune=sandybridge -quiet -dumpbase core_rpc_s.tmp.lamb.11607.ii -auxbase-strip /home/honey/.ccache/f/4/f9f87cde6a2f697f7bf3127e92a217-9421174.o.tmp.lamb.11607 -g -O2 -O3 -Wundef -Wvla -Wwrite-strings -Wno-error=extra -Wno-error=deprecated-declarations -Wno-error=sign-compare -Wno-error=strict-aliasing -Wno-error=type-limits -Wno-unused-parameter -Wno-error=unused-variable -Wlogical-op -Wno-error=maybe-uninitialized -Wno-missing-field-initializers -Wall -Wextra -Wno-c++0x-compat -Wno-pointer-arith -Wno-unused -Wno-cast-qual -Wno-comment -Wno-multichar -Wno-sign-compare -Wno-reorder -Wno-error -Wdate-time -std=c++11 -std=gnu++11 -fdiagnostics-color=auto -o - -frandom-seed=0 ># 1 "/c/honeypenny/src/rpc/core_rpc_server.cpp" ># 1 "/c/honeypenny/build/src//" ># 1 "<built-in>" ># 1 "<command-line>" ># 1 "/usr/include/stdc-predef.h" 1 3 4 ># 1 "<command-line>" 2 ># 1 "/c/honeypenny/src/rpc/core_rpc_server.cpp" > > > > > ># 1 "/usr/include/boost/foreach.hpp" 1 3 4 ># 27 "/usr/include/boost/foreach.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstddef" 1 3 4 ># 42 "/usr/include/c++/4.9.0/cstddef" 3 4 ># 43 "/usr/include/c++/4.9.0/cstddef" 3 > ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++config.h" 1 3 > > ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 4 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++config.h" 2 3 ># 1865 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++config.h" 3 >namespace std >{ > typedef long unsigned int size_t; > typedef long int ptrdiff_t; > > > typedef decltype(nullptr) nullptr_t; > >} ># 2109 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++config.h" 3 ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/os_defines.h" 1 3 ># 39 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/os_defines.h" 3 ># 1 "/usr/include/features.h" 1 3 4 ># 364 "/usr/include/features.h" 3 4 ># 1 "/usr/include/sys/cdefs.h" 1 3 4 ># 385 "/usr/include/sys/cdefs.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 386 "/usr/include/sys/cdefs.h" 2 3 4 ># 365 "/usr/include/features.h" 2 3 4 ># 388 "/usr/include/features.h" 3 4 ># 1 "/usr/include/gnu/stubs.h" 1 3 4 ># 10 "/usr/include/gnu/stubs.h" 3 4 ># 1 "/usr/include/gnu/stubs-64.h" 1 3 4 ># 11 "/usr/include/gnu/stubs.h" 2 3 4 ># 389 "/usr/include/features.h" 2 3 4 ># 40 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/os_defines.h" 2 3 ># 2110 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++config.h" 2 3 > > ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/cpu_defines.h" 1 3 ># 2113 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++config.h" 2 3 ># 45 "/usr/include/c++/4.9.0/cstddef" 2 3 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 147 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 3 4 >typedef long int ptrdiff_t; ># 212 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 3 4 >typedef long unsigned int size_t; ># 422 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 3 4 >typedef struct { > long long __max_align_ll __attribute__((__aligned__(__alignof__(long long)))); > long double __max_align_ld __attribute__((__aligned__(__alignof__(long double)))); >} max_align_t; > > > > > > > typedef decltype(nullptr) nullptr_t; ># 46 "/usr/include/c++/4.9.0/cstddef" 2 3 > > >namespace std >{ > > using ::max_align_t; >} ># 28 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/utility" 1 3 4 ># 58 "/usr/include/c++/4.9.0/utility" 3 4 ># 59 "/usr/include/c++/4.9.0/utility" 3 ># 69 "/usr/include/c++/4.9.0/utility" 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_relops.h" 1 3 ># 67 "/usr/include/c++/4.9.0/bits/stl_relops.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > namespace rel_ops > { ># 85 "/usr/include/c++/4.9.0/bits/stl_relops.h" 3 > template <class _Tp> > inline bool > operator!=(const _Tp& __x, const _Tp& __y) > { return !(__x == __y); } ># 98 "/usr/include/c++/4.9.0/bits/stl_relops.h" 3 > template <class _Tp> > inline bool > operator>(const _Tp& __x, const _Tp& __y) > { return __y < __x; } ># 111 "/usr/include/c++/4.9.0/bits/stl_relops.h" 3 > template <class _Tp> > inline bool > operator<=(const _Tp& __x, const _Tp& __y) > { return !(__y < __x); } ># 124 "/usr/include/c++/4.9.0/bits/stl_relops.h" 3 > template <class _Tp> > inline bool > operator>=(const _Tp& __x, const _Tp& __y) > { return !(__x < __y); } > > > } > >} ># 70 "/usr/include/c++/4.9.0/utility" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_pair.h" 1 3 ># 59 "/usr/include/c++/4.9.0/bits/stl_pair.h" 3 ># 1 "/usr/include/c++/4.9.0/bits/move.h" 1 3 ># 34 "/usr/include/c++/4.9.0/bits/move.h" 3 ># 1 "/usr/include/c++/4.9.0/bits/concept_check.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/concept_check.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/concept_check.h" 3 ># 35 "/usr/include/c++/4.9.0/bits/move.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > > template<typename _Tp> > inline _Tp* > __addressof(_Tp& __r) noexcept > { > return reinterpret_cast<_Tp*> > (&const_cast<char&>(reinterpret_cast<const volatile char&>(__r))); > } > > >} > > ># 1 "/usr/include/c++/4.9.0/type_traits" 1 3 ># 32 "/usr/include/c++/4.9.0/type_traits" 3 ># 33 "/usr/include/c++/4.9.0/type_traits" 3 > > > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 56 "/usr/include/c++/4.9.0/type_traits" 3 > template<typename _Tp, _Tp __v> > struct integral_constant > { > static constexpr _Tp value = __v; > typedef _Tp value_type; > typedef integral_constant<_Tp, __v> type; > constexpr operator value_type() const { return value; } > > > > }; > > template<typename _Tp, _Tp __v> > constexpr _Tp integral_constant<_Tp, __v>::value; > > > typedef integral_constant<bool, true> true_type; > > > typedef integral_constant<bool, false> false_type; > > > > template<bool, typename, typename> > struct conditional; > > template<typename...> > struct __or_; > > template<> > struct __or_<> > : public false_type > { }; > > template<typename _B1> > struct __or_<_B1> > : public _B1 > { }; > > template<typename _B1, typename _B2> > struct __or_<_B1, _B2> > : public conditional<_B1::value, _B1, _B2>::type > { }; > > template<typename _B1, typename _B2, typename _B3, typename... _Bn> > struct __or_<_B1, _B2, _B3, _Bn...> > : public conditional<_B1::value, _B1, __or_<_B2, _B3, _Bn...>>::type > { }; > > template<typename...> > struct __and_; > > template<> > struct __and_<> > : public true_type > { }; > > template<typename _B1> > struct __and_<_B1> > : public _B1 > { }; > > template<typename _B1, typename _B2> > struct __and_<_B1, _B2> > : public conditional<_B1::value, _B2, _B1>::type > { }; > > template<typename _B1, typename _B2, typename _B3, typename... _Bn> > struct __and_<_B1, _B2, _B3, _Bn...> > : public conditional<_B1::value, __and_<_B2, _B3, _Bn...>, _B1>::type > { }; > > template<typename _Pp> > struct __not_ > : public integral_constant<bool, !_Pp::value> > { }; > > > > > > > template<typename _Tp> > struct __success_type > { typedef _Tp type; }; > > struct __failure_type > { }; > > > > template<typename> > struct remove_cv; > > template<typename> > struct __is_void_helper > : public false_type { }; > > template<> > struct __is_void_helper<void> > : public true_type { }; > > > template<typename _Tp> > struct is_void > : public __is_void_helper<typename remove_cv<_Tp>::type>::type > { }; > > template<typename> > struct __is_integral_helper > : public false_type { }; > > template<> > struct __is_integral_helper<bool> > : public true_type { }; > > template<> > struct __is_integral_helper<char> > : public true_type { }; > > template<> > struct __is_integral_helper<signed char> > : public true_type { }; > > template<> > struct __is_integral_helper<unsigned char> > : public true_type { }; > > > template<> > struct __is_integral_helper<wchar_t> > : public true_type { }; > > > template<> > struct __is_integral_helper<char16_t> > : public true_type { }; > > template<> > struct __is_integral_helper<char32_t> > : public true_type { }; > > template<> > struct __is_integral_helper<short> > : public true_type { }; > > template<> > struct __is_integral_helper<unsigned short> > : public true_type { }; > > template<> > struct __is_integral_helper<int> > : public true_type { }; > > template<> > struct __is_integral_helper<unsigned int> > : public true_type { }; > > template<> > struct __is_integral_helper<long> > : public true_type { }; > > template<> > struct __is_integral_helper<unsigned long> > : public true_type { }; > > template<> > struct __is_integral_helper<long long> > : public true_type { }; > > template<> > struct __is_integral_helper<unsigned long long> > : public true_type { }; > > > template<> > struct __is_integral_helper<__int128> > : public true_type { }; > > template<> > struct __is_integral_helper<unsigned __int128> > : public true_type { }; > > > > template<typename _Tp> > struct is_integral > : public __is_integral_helper<typename remove_cv<_Tp>::type>::type > { }; > > template<typename> > struct __is_floating_point_helper > : public false_type { }; > > template<> > struct __is_floating_point_helper<float> > : public true_type { }; > > template<> > struct __is_floating_point_helper<double> > : public true_type { }; > > template<> > struct __is_floating_point_helper<long double> > : public true_type { }; > > > template<> > struct __is_floating_point_helper<__float128> > : public true_type { }; > > > > template<typename _Tp> > struct is_floating_point > : public __is_floating_point_helper<typename remove_cv<_Tp>::type>::type > { }; > > > template<typename> > struct is_array > : public false_type { }; > > template<typename _Tp, std::size_t _Size> > struct is_array<_Tp[_Size]> > : public true_type { }; > > template<typename _Tp> > struct is_array<_Tp[]> > : public true_type { }; > > template<typename> > struct __is_pointer_helper > : public false_type { }; > > template<typename _Tp> > struct __is_pointer_helper<_Tp*> > : public true_type { }; > > > template<typename _Tp> > struct is_pointer > : public __is_pointer_helper<typename remove_cv<_Tp>::type>::type > { }; > > > template<typename> > struct is_lvalue_reference > : public false_type { }; > > template<typename _Tp> > struct is_lvalue_reference<_Tp&> > : public true_type { }; > > > template<typename> > struct is_rvalue_reference > : public false_type { }; > > template<typename _Tp> > struct is_rvalue_reference<_Tp&&> > : public true_type { }; > > template<typename> > struct is_function; > > template<typename> > struct __is_member_object_pointer_helper > : public false_type { }; > > template<typename _Tp, typename _Cp> > struct __is_member_object_pointer_helper<_Tp _Cp::*> > : public integral_constant<bool, !is_function<_Tp>::value> { }; > > > template<typename _Tp> > struct is_member_object_pointer > : public __is_member_object_pointer_helper< > typename remove_cv<_Tp>::type>::type > { }; > > template<typename> > struct __is_member_function_pointer_helper > : public false_type { }; > > template<typename _Tp, typename _Cp> > struct __is_member_function_pointer_helper<_Tp _Cp::*> > : public integral_constant<bool, is_function<_Tp>::value> { }; > > > template<typename _Tp> > struct is_member_function_pointer > : public __is_member_function_pointer_helper< > typename remove_cv<_Tp>::type>::type > { }; > > > template<typename _Tp> > struct is_enum > : public integral_constant<bool, __is_enum(_Tp)> > { }; > > > template<typename _Tp> > struct is_union > : public integral_constant<bool, __is_union(_Tp)> > { }; > > > template<typename _Tp> > struct is_class > : public integral_constant<bool, __is_class(_Tp)> > { }; > > > template<typename> > struct is_function > : public false_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...)> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) &> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) &&> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......)> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) &> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) &&> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) const> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) const &> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) const &&> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) const> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) const &> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) const &&> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) volatile> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) volatile &> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) volatile &&> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) volatile> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) volatile &> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) volatile &&> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) const volatile> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) const volatile &> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes...) const volatile &&> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) const volatile> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) const volatile &> > : public true_type { }; > > template<typename _Res, typename... _ArgTypes> > struct is_function<_Res(_ArgTypes......) const volatile &&> > : public true_type { }; > > template<typename> > struct __is_null_pointer_helper > : public false_type { }; > > template<> > struct __is_null_pointer_helper<std::nullptr_t> > : public true_type { }; > > > template<typename _Tp> > struct is_null_pointer > : public __is_null_pointer_helper<typename remove_cv<_Tp>::type>::type > { }; > > > template<typename _Tp> > struct __is_nullptr_t > : public is_null_pointer<_Tp> > { }; > > > > > template<typename _Tp> > struct is_reference > : public __or_<is_lvalue_reference<_Tp>, > is_rvalue_reference<_Tp>>::type > { }; > > > template<typename _Tp> > struct is_arithmetic > : public __or_<is_integral<_Tp>, is_floating_point<_Tp>>::type > { }; > > > template<typename _Tp> > struct is_fundamental > : public __or_<is_arithmetic<_Tp>, is_void<_Tp>, > is_null_pointer<_Tp>>::type > { }; > > > template<typename _Tp> > struct is_object > : public __not_<__or_<is_function<_Tp>, is_reference<_Tp>, > is_void<_Tp>>>::type > { }; > > template<typename> > struct is_member_pointer; > > > template<typename _Tp> > struct is_scalar > : public __or_<is_arithmetic<_Tp>, is_enum<_Tp>, is_pointer<_Tp>, > is_member_pointer<_Tp>, is_null_pointer<_Tp>>::type > { }; > > > template<typename _Tp> > struct is_compound > : public integral_constant<bool, !is_fundamental<_Tp>::value> { }; > > template<typename _Tp> > struct __is_member_pointer_helper > : public false_type { }; > > template<typename _Tp, typename _Cp> > struct __is_member_pointer_helper<_Tp _Cp::*> > : public true_type { }; > > > template<typename _Tp> > struct is_member_pointer > : public __is_member_pointer_helper<typename remove_cv<_Tp>::type>::type > { }; > > > > template<typename _Tp> > struct __is_referenceable > : public __or_<is_object<_Tp>, is_reference<_Tp>>::type > { }; > > template<typename _Res, typename... _Args> > struct __is_referenceable<_Res(_Args...)> > : public true_type > { }; > > template<typename _Res, typename... _Args> > struct __is_referenceable<_Res(_Args......)> > : public true_type > { }; > > > > > template<typename> > struct is_const > : public false_type { }; > > template<typename _Tp> > struct is_const<_Tp const> > : public true_type { }; > > > template<typename> > struct is_volatile > : public false_type { }; > > template<typename _Tp> > struct is_volatile<_Tp volatile> > : public true_type { }; > > > template<typename _Tp> > struct is_trivial > : public integral_constant<bool, __is_trivial(_Tp)> > { }; > > > > > template<typename _Tp> > struct is_standard_layout > : public integral_constant<bool, __is_standard_layout(_Tp)> > { }; > > > > template<typename _Tp> > struct is_pod > : public integral_constant<bool, __is_pod(_Tp)> > { }; > > > template<typename _Tp> > struct is_literal_type > : public integral_constant<bool, __is_literal_type(_Tp)> > { }; > > > template<typename _Tp> > struct is_empty > : public integral_constant<bool, __is_empty(_Tp)> > { }; > > > template<typename _Tp> > struct is_polymorphic > : public integral_constant<bool, __is_polymorphic(_Tp)> > { }; > > > template<typename _Tp> > struct is_abstract > : public integral_constant<bool, __is_abstract(_Tp)> > { }; > > template<typename _Tp, > bool = is_arithmetic<_Tp>::value> > struct __is_signed_helper > : public false_type { }; > > template<typename _Tp> > struct __is_signed_helper<_Tp, true> > : public integral_constant<bool, _Tp(-1) < _Tp(0)> > { }; > > > template<typename _Tp> > struct is_signed > : public __is_signed_helper<_Tp>::type > { }; > > > template<typename _Tp> > struct is_unsigned > : public __and_<is_arithmetic<_Tp>, __not_<is_signed<_Tp>>>::type > { }; > > > > > template<typename> > struct add_rvalue_reference; > > > > > > template<typename _Tp> > typename add_rvalue_reference<_Tp>::type declval() noexcept; > > template<typename, unsigned = 0> > struct extent; > > template<typename> > struct remove_all_extents; > > template<typename _Tp> > struct __is_array_known_bounds > : public integral_constant<bool, (extent<_Tp>::value > 0)> > { }; > > template<typename _Tp> > struct __is_array_unknown_bounds > : public __and_<is_array<_Tp>, __not_<extent<_Tp>>>::type > { }; > > > > > > > struct __do_is_destructible_impl > { > template<typename _Tp, typename = decltype(declval<_Tp&>().~_Tp())> > static true_type __test(int); > > template<typename> > static false_type __test(...); > }; > > template<typename _Tp> > struct __is_destructible_impl > : public __do_is_destructible_impl > { > typedef decltype(__test<_Tp>(0)) type; > }; > > template<typename _Tp, > bool = __or_<is_void<_Tp>, > __is_array_unknown_bounds<_Tp>, > is_function<_Tp>>::value, > bool = __or_<is_reference<_Tp>, is_scalar<_Tp>>::value> > struct __is_destructible_safe; > > template<typename _Tp> > struct __is_destructible_safe<_Tp, false, false> > : public __is_destructible_impl<typename > remove_all_extents<_Tp>::type>::type > { }; > > template<typename _Tp> > struct __is_destructible_safe<_Tp, true, false> > : public false_type { }; > > template<typename _Tp> > struct __is_destructible_safe<_Tp, false, true> > : public true_type { }; > > > template<typename _Tp> > struct is_destructible > : public __is_destructible_safe<_Tp>::type > { }; > > > > > > struct __do_is_nt_destructible_impl > { > template<typename _Tp> > static integral_constant<bool, noexcept(declval<_Tp&>().~_Tp())> > __test(int); > > template<typename> > static false_type __test(...); > }; > > template<typename _Tp> > struct __is_nt_destructible_impl > : public __do_is_nt_destructible_impl > { > typedef decltype(__test<_Tp>(0)) type; > }; > > template<typename _Tp, > bool = __or_<is_void<_Tp>, > __is_array_unknown_bounds<_Tp>, > is_function<_Tp>>::value, > bool = __or_<is_reference<_Tp>, is_scalar<_Tp>>::value> > struct __is_nt_destructible_safe; > > template<typename _Tp> > struct __is_nt_destructible_safe<_Tp, false, false> > : public __is_nt_destructible_impl<typename > remove_all_extents<_Tp>::type>::type > { }; > > template<typename _Tp> > struct __is_nt_destructible_safe<_Tp, true, false> > : public false_type { }; > > template<typename _Tp> > struct __is_nt_destructible_safe<_Tp, false, true> > : public true_type { }; > > > template<typename _Tp> > struct is_nothrow_destructible > : public __is_nt_destructible_safe<_Tp>::type > { }; > > struct __do_is_default_constructible_impl > { > template<typename _Tp, typename = decltype(_Tp())> > static true_type __test(int); > > template<typename> > static false_type __test(...); > }; > > template<typename _Tp> > struct __is_default_constructible_impl > : public __do_is_default_constructible_impl > { > typedef decltype(__test<_Tp>(0)) type; > }; > > template<typename _Tp> > struct __is_default_constructible_atom > : public __and_<__not_<is_void<_Tp>>, > __is_default_constructible_impl<_Tp>>::type > { }; > > template<typename _Tp, bool = is_array<_Tp>::value> > struct __is_default_constructible_safe; > > > > > > > template<typename _Tp> > struct __is_default_constructible_safe<_Tp, true> > : public __and_<__is_array_known_bounds<_Tp>, > __is_default_constructible_atom<typename > remove_all_extents<_Tp>::type>>::type > { }; > > template<typename _Tp> > struct __is_default_constructible_safe<_Tp, false> > : public __is_default_constructible_atom<_Tp>::type > { }; > > > template<typename _Tp> > struct is_default_constructible > : public __is_default_constructible_safe<_Tp>::type > { }; ># 838 "/usr/include/c++/4.9.0/type_traits" 3 > struct __do_is_static_castable_impl > { > template<typename _From, typename _To, typename > = decltype(static_cast<_To>(declval<_From>()))> > static true_type __test(int); > > template<typename, typename> > static false_type __test(...); > }; > > template<typename _From, typename _To> > struct __is_static_castable_impl > : public __do_is_static_castable_impl > { > typedef decltype(__test<_From, _To>(0)) type; > }; > > template<typename _From, typename _To> > struct __is_static_castable_safe > : public __is_static_castable_impl<_From, _To>::type > { }; > > > template<typename _From, typename _To> > struct __is_static_castable > : public integral_constant<bool, (__is_static_castable_safe< > _From, _To>::value)> > { }; > > > > > > > struct __do_is_direct_constructible_impl > { > template<typename _Tp, typename _Arg, typename > = decltype(::new _Tp(declval<_Arg>()))> > static true_type __test(int); > > template<typename, typename> > static false_type __test(...); > }; > > template<typename _Tp, typename _Arg> > struct __is_direct_constructible_impl > : public __do_is_direct_constructible_impl > { > typedef decltype(__test<_Tp, _Arg>(0)) type; > }; > > template<typename _Tp, typename _Arg> > struct __is_direct_constructible_new_safe > : public __and_<is_destructible<_Tp>, > __is_direct_constructible_impl<_Tp, _Arg>>::type > { }; > > template<typename, typename> > struct is_same; > > template<typename, typename> > struct is_base_of; > > template<typename> > struct remove_reference; > > template<typename _From, typename _To, bool > = __not_<__or_<is_void<_From>, > is_function<_From>>>::value> > struct __is_base_to_derived_ref; > > > > template<typename _From, typename _To> > struct __is_base_to_derived_ref<_From, _To, true> > { > typedef typename remove_cv<typename remove_reference<_From > >::type>::type __src_t; > typedef typename remove_cv<typename remove_reference<_To > >::type>::type __dst_t; > typedef __and_<__not_<is_same<__src_t, __dst_t>>, > is_base_of<__src_t, __dst_t>> type; > static constexpr bool value = type::value; > }; > > template<typename _From, typename _To> > struct __is_base_to_derived_ref<_From, _To, false> > : public false_type > { }; > > template<typename _From, typename _To, bool > = __and_<is_lvalue_reference<_From>, > is_rvalue_reference<_To>>::value> > struct __is_lvalue_to_rvalue_ref; > > > > template<typename _From, typename _To> > struct __is_lvalue_to_rvalue_ref<_From, _To, true> > { > typedef typename remove_cv<typename remove_reference< > _From>::type>::type __src_t; > typedef typename remove_cv<typename remove_reference< > _To>::type>::type __dst_t; > typedef __and_<__not_<is_function<__src_t>>, > __or_<is_same<__src_t, __dst_t>, > is_base_of<__dst_t, __src_t>>> type; > static constexpr bool value = type::value; > }; > > template<typename _From, typename _To> > struct __is_lvalue_to_rvalue_ref<_From, _To, false> > : public false_type > { }; > > > > > > > > template<typename _Tp, typename _Arg> > struct __is_direct_constructible_ref_cast > : public __and_<__is_static_castable<_Arg, _Tp>, > __not_<__or_<__is_base_to_derived_ref<_Arg, _Tp>, > __is_lvalue_to_rvalue_ref<_Arg, _Tp> > >>>::type > { }; > > template<typename _Tp, typename _Arg> > struct __is_direct_constructible_new > : public conditional<is_reference<_Tp>::value, > __is_direct_constructible_ref_cast<_Tp, _Arg>, > __is_direct_constructible_new_safe<_Tp, _Arg> > >::type > { }; > > template<typename _Tp, typename _Arg> > struct __is_direct_constructible > : public __is_direct_constructible_new<_Tp, _Arg>::type > { }; > > > > > > > struct __do_is_nary_constructible_impl > { > template<typename _Tp, typename... _Args, typename > = decltype(_Tp(declval<_Args>()...))> > static true_type __test(int); > > template<typename, typename...> > static false_type __test(...); > }; > > template<typename _Tp, typename... _Args> > struct __is_nary_constructible_impl > : public __do_is_nary_constructible_impl > { > typedef decltype(__test<_Tp, _Args...>(0)) type; > }; > > template<typename _Tp, typename... _Args> > struct __is_nary_constructible > : public __is_nary_constructible_impl<_Tp, _Args...>::type > { > static_assert(sizeof...(_Args) > 1, > "Only useful for > 1 arguments"); > }; > > template<typename _Tp, typename... _Args> > struct __is_constructible_impl > : public __is_nary_constructible<_Tp, _Args...> > { }; > > template<typename _Tp, typename _Arg> > struct __is_constructible_impl<_Tp, _Arg> > : public __is_direct_constructible<_Tp, _Arg> > { }; > > template<typename _Tp> > struct __is_constructible_impl<_Tp> > : public is_default_constructible<_Tp> > { }; > > > template<typename _Tp, typename... _Args> > struct is_constructible > : public __is_constructible_impl<_Tp, _Args...>::type > { }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __is_copy_constructible_impl; > > template<typename _Tp> > struct __is_copy_constructible_impl<_Tp, false> > : public false_type { }; > > template<typename _Tp> > struct __is_copy_constructible_impl<_Tp, true> > : public is_constructible<_Tp, const _Tp&> > { }; > > > template<typename _Tp> > struct is_copy_constructible > : public __is_copy_constructible_impl<_Tp> > { }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __is_move_constructible_impl; > > template<typename _Tp> > struct __is_move_constructible_impl<_Tp, false> > : public false_type { }; > > template<typename _Tp> > struct __is_move_constructible_impl<_Tp, true> > : public is_constructible<_Tp, _Tp&&> > { }; > > > template<typename _Tp> > struct is_move_constructible > : public __is_move_constructible_impl<_Tp> > { }; > > template<typename _Tp> > struct __is_nt_default_constructible_atom > : public integral_constant<bool, noexcept(_Tp())> > { }; > > template<typename _Tp, bool = is_array<_Tp>::value> > struct __is_nt_default_constructible_impl; > > template<typename _Tp> > struct __is_nt_default_constructible_impl<_Tp, true> > : public __and_<__is_array_known_bounds<_Tp>, > __is_nt_default_constructible_atom<typename > remove_all_extents<_Tp>::type>>::type > { }; > > template<typename _Tp> > struct __is_nt_default_constructible_impl<_Tp, false> > : public __is_nt_default_constructible_atom<_Tp> > { }; > > > template<typename _Tp> > struct is_nothrow_default_constructible > : public __and_<is_default_constructible<_Tp>, > __is_nt_default_constructible_impl<_Tp>>::type > { }; > > template<typename _Tp, typename... _Args> > struct __is_nt_constructible_impl > : public integral_constant<bool, noexcept(_Tp(declval<_Args>()...))> > { }; > > template<typename _Tp, typename _Arg> > struct __is_nt_constructible_impl<_Tp, _Arg> > : public integral_constant<bool, > noexcept(static_cast<_Tp>(declval<_Arg>()))> > { }; > > template<typename _Tp> > struct __is_nt_constructible_impl<_Tp> > : public is_nothrow_default_constructible<_Tp> > { }; > > > template<typename _Tp, typename... _Args> > struct is_nothrow_constructible > : public __and_<is_constructible<_Tp, _Args...>, > __is_nt_constructible_impl<_Tp, _Args...>>::type > { }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __is_nothrow_copy_constructible_impl; > > template<typename _Tp> > struct __is_nothrow_copy_constructible_impl<_Tp, false> > : public false_type { }; > > template<typename _Tp> > struct __is_nothrow_copy_constructible_impl<_Tp, true> > : public is_nothrow_constructible<_Tp, const _Tp&> > { }; > > > template<typename _Tp> > struct is_nothrow_copy_constructible > : public __is_nothrow_copy_constructible_impl<_Tp> > { }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __is_nothrow_move_constructible_impl; > > template<typename _Tp> > struct __is_nothrow_move_constructible_impl<_Tp, false> > : public false_type { }; > > template<typename _Tp> > struct __is_nothrow_move_constructible_impl<_Tp, true> > : public is_nothrow_constructible<_Tp, _Tp&&> > { }; > > > template<typename _Tp> > struct is_nothrow_move_constructible > : public __is_nothrow_move_constructible_impl<_Tp> > { }; > > template<typename _Tp, typename _Up> > class __is_assignable_helper > { > template<typename _Tp1, typename _Up1, > typename = decltype(declval<_Tp1>() = declval<_Up1>())> > static true_type > __test(int); > > template<typename, typename> > static false_type > __test(...); > > public: > typedef decltype(__test<_Tp, _Up>(0)) type; > }; > > > template<typename _Tp, typename _Up> > struct is_assignable > : public __is_assignable_helper<_Tp, _Up>::type > { }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __is_copy_assignable_impl; > > template<typename _Tp> > struct __is_copy_assignable_impl<_Tp, false> > : public false_type { }; > > template<typename _Tp> > struct __is_copy_assignable_impl<_Tp, true> > : public is_assignable<_Tp&, const _Tp&> > { }; > > > template<typename _Tp> > struct is_copy_assignable > : public __is_copy_assignable_impl<_Tp> > { }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __is_move_assignable_impl; > > template<typename _Tp> > struct __is_move_assignable_impl<_Tp, false> > : public false_type { }; > > template<typename _Tp> > struct __is_move_assignable_impl<_Tp, true> > : public is_assignable<_Tp&, _Tp&&> > { }; > > > template<typename _Tp> > struct is_move_assignable > : public __is_move_assignable_impl<_Tp> > { }; > > template<typename _Tp, typename _Up> > struct __is_nt_assignable_impl > : public integral_constant<bool, noexcept(declval<_Tp>() = declval<_Up>())> > { }; > > > template<typename _Tp, typename _Up> > struct is_nothrow_assignable > : public __and_<is_assignable<_Tp, _Up>, > __is_nt_assignable_impl<_Tp, _Up>>::type > { }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __is_nt_copy_assignable_impl; > > template<typename _Tp> > struct __is_nt_copy_assignable_impl<_Tp, false> > : public false_type { }; > > template<typename _Tp> > struct __is_nt_copy_assignable_impl<_Tp, true> > : public is_nothrow_assignable<_Tp&, const _Tp&> > { }; > > > template<typename _Tp> > struct is_nothrow_copy_assignable > : public __is_nt_copy_assignable_impl<_Tp> > { }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __is_nt_move_assignable_impl; > > template<typename _Tp> > struct __is_nt_move_assignable_impl<_Tp, false> > : public false_type { }; > > template<typename _Tp> > struct __is_nt_move_assignable_impl<_Tp, true> > : public is_nothrow_assignable<_Tp&, _Tp&&> > { }; > > > template<typename _Tp> > struct is_nothrow_move_assignable > : public __is_nt_move_assignable_impl<_Tp> > { }; ># 1274 "/usr/include/c++/4.9.0/type_traits" 3 > template<typename _Tp> > struct is_trivially_destructible > : public __and_<is_destructible<_Tp>, integral_constant<bool, > __has_trivial_destructor(_Tp)>>::type > { }; > > > template<typename _Tp> > struct has_trivial_default_constructor > : public integral_constant<bool, __has_trivial_constructor(_Tp)> > { }; > > > template<typename _Tp> > struct has_trivial_copy_constructor > : public integral_constant<bool, __has_trivial_copy(_Tp)> > { }; > > > template<typename _Tp> > struct has_trivial_copy_assign > : public integral_constant<bool, __has_trivial_assign(_Tp)> > { }; > > > template<typename _Tp> > struct has_virtual_destructor > : public integral_constant<bool, __has_virtual_destructor(_Tp)> > { }; > > > > > > template<typename _Tp> > struct alignment_of > : public integral_constant<std::size_t, __alignof__(_Tp)> { }; > > > template<typename> > struct rank > : public integral_constant<std::size_t, 0> { }; > > template<typename _Tp, std::size_t _Size> > struct rank<_Tp[_Size]> > : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { }; > > template<typename _Tp> > struct rank<_Tp[]> > : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { }; > > > template<typename, unsigned _Uint> > struct extent > : public integral_constant<std::size_t, 0> { }; > > template<typename _Tp, unsigned _Uint, std::size_t _Size> > struct extent<_Tp[_Size], _Uint> > : public integral_constant<std::size_t, > _Uint == 0 ? _Size : extent<_Tp, > _Uint - 1>::value> > { }; > > template<typename _Tp, unsigned _Uint> > struct extent<_Tp[], _Uint> > : public integral_constant<std::size_t, > _Uint == 0 ? 0 : extent<_Tp, > _Uint - 1>::value> > { }; > > > > > > template<typename, typename> > struct is_same > : public false_type { }; > > template<typename _Tp> > struct is_same<_Tp, _Tp> > : public true_type { }; > > > template<typename _Base, typename _Derived> > struct is_base_of > : public integral_constant<bool, __is_base_of(_Base, _Derived)> > { }; > > template<typename _From, typename _To, > bool = __or_<is_void<_From>, is_function<_To>, > is_array<_To>>::value> > struct __is_convertible_helper > { typedef typename is_void<_To>::type type; }; > > template<typename _From, typename _To> > class __is_convertible_helper<_From, _To, false> > { > template<typename _To1> > static void __test_aux(_To1); > > template<typename _From1, typename _To1, > typename = decltype(__test_aux<_To1>(std::declval<_From1>()))> > static true_type > __test(int); > > template<typename, typename> > static false_type > __test(...); > > public: > typedef decltype(__test<_From, _To>(0)) type; > }; > > > > template<typename _From, typename _To> > struct is_convertible > : public __is_convertible_helper<_From, _To>::type > { }; > > > > > > template<typename _Tp> > struct remove_const > { typedef _Tp type; }; > > template<typename _Tp> > struct remove_const<_Tp const> > { typedef _Tp type; }; > > > template<typename _Tp> > struct remove_volatile > { typedef _Tp type; }; > > template<typename _Tp> > struct remove_volatile<_Tp volatile> > { typedef _Tp type; }; > > > template<typename _Tp> > struct remove_cv > { > typedef typename > remove_const<typename remove_volatile<_Tp>::type>::type type; > }; > > > template<typename _Tp> > struct add_const > { typedef _Tp const type; }; > > > template<typename _Tp> > struct add_volatile > { typedef _Tp volatile type; }; > > > template<typename _Tp> > struct add_cv > { > typedef typename > add_const<typename add_volatile<_Tp>::type>::type type; > }; ># 1470 "/usr/include/c++/4.9.0/type_traits" 3 > template<typename _Tp> > struct remove_reference > { typedef _Tp type; }; > > template<typename _Tp> > struct remove_reference<_Tp&> > { typedef _Tp type; }; > > template<typename _Tp> > struct remove_reference<_Tp&&> > { typedef _Tp type; }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __add_lvalue_reference_helper > { typedef _Tp type; }; > > template<typename _Tp> > struct __add_lvalue_reference_helper<_Tp, true> > { typedef _Tp& type; }; > > > template<typename _Tp> > struct add_lvalue_reference > : public __add_lvalue_reference_helper<_Tp> > { }; > > template<typename _Tp, bool = __is_referenceable<_Tp>::value> > struct __add_rvalue_reference_helper > { typedef _Tp type; }; > > template<typename _Tp> > struct __add_rvalue_reference_helper<_Tp, true> > { typedef _Tp&& type; }; > > > template<typename _Tp> > struct add_rvalue_reference > : public __add_rvalue_reference_helper<_Tp> > { }; ># 1527 "/usr/include/c++/4.9.0/type_traits" 3 > template<typename _Unqualified, bool _IsConst, bool _IsVol> > struct __cv_selector; > > template<typename _Unqualified> > struct __cv_selector<_Unqualified, false, false> > { typedef _Unqualified __type; }; > > template<typename _Unqualified> > struct __cv_selector<_Unqualified, false, true> > { typedef volatile _Unqualified __type; }; > > template<typename _Unqualified> > struct __cv_selector<_Unqualified, true, false> > { typedef const _Unqualified __type; }; > > template<typename _Unqualified> > struct __cv_selector<_Unqualified, true, true> > { typedef const volatile _Unqualified __type; }; > > template<typename _Qualified, typename _Unqualified, > bool _IsConst = is_const<_Qualified>::value, > bool _IsVol = is_volatile<_Qualified>::value> > class __match_cv_qualifiers > { > typedef __cv_selector<_Unqualified, _IsConst, _IsVol> __match; > > public: > typedef typename __match::__type __type; > }; > > > template<typename _Tp> > struct __make_unsigned > { typedef _Tp __type; }; > > template<> > struct __make_unsigned<char> > { typedef unsigned char __type; }; > > template<> > struct __make_unsigned<signed char> > { typedef unsigned char __type; }; > > template<> > struct __make_unsigned<short> > { typedef unsigned short __type; }; > > template<> > struct __make_unsigned<int> > { typedef unsigned int __type; }; > > template<> > struct __make_unsigned<long> > { typedef unsigned long __type; }; > > template<> > struct __make_unsigned<long long> > { typedef unsigned long long __type; }; > > > template<> > struct __make_unsigned<__int128> > { typedef unsigned __int128 __type; }; > > > > template<typename _Tp, > bool _IsInt = is_integral<_Tp>::value, > bool _IsEnum = is_enum<_Tp>::value> > class __make_unsigned_selector; > > template<typename _Tp> > class __make_unsigned_selector<_Tp, true, false> > { > typedef __make_unsigned<typename remove_cv<_Tp>::type> __unsignedt; > typedef typename __unsignedt::__type __unsigned_type; > typedef __match_cv_qualifiers<_Tp, __unsigned_type> __cv_unsigned; > > public: > typedef typename __cv_unsigned::__type __type; > }; > > template<typename _Tp> > class __make_unsigned_selector<_Tp, false, true> > { > > typedef unsigned char __smallest; > static const bool __b0 = sizeof(_Tp) <= sizeof(__smallest); > static const bool __b1 = sizeof(_Tp) <= sizeof(unsigned short); > static const bool __b2 = sizeof(_Tp) <= sizeof(unsigned int); > typedef conditional<__b2, unsigned int, unsigned long> __cond2; > typedef typename __cond2::type __cond2_type; > typedef conditional<__b1, unsigned short, __cond2_type> __cond1; > typedef typename __cond1::type __cond1_type; > > public: > typedef typename conditional<__b0, __smallest, __cond1_type>::type __type; > }; > > > > > > template<typename _Tp> > struct make_unsigned > { typedef typename __make_unsigned_selector<_Tp>::__type type; }; > > > template<> > struct make_unsigned<bool>; > > > > template<typename _Tp> > struct __make_signed > { typedef _Tp __type; }; > > template<> > struct __make_signed<char> > { typedef signed char __type; }; > > template<> > struct __make_signed<unsigned char> > { typedef signed char __type; }; > > template<> > struct __make_signed<unsigned short> > { typedef signed short __type; }; > > template<> > struct __make_signed<unsigned int> > { typedef signed int __type; }; > > template<> > struct __make_signed<unsigned long> > { typedef signed long __type; }; > > template<> > struct __make_signed<unsigned long long> > { typedef signed long long __type; }; > > > template<> > struct __make_signed<unsigned __int128> > { typedef __int128 __type; }; > > > > template<typename _Tp, > bool _IsInt = is_integral<_Tp>::value, > bool _IsEnum = is_enum<_Tp>::value> > class __make_signed_selector; > > template<typename _Tp> > class __make_signed_selector<_Tp, true, false> > { > typedef __make_signed<typename remove_cv<_Tp>::type> __signedt; > typedef typename __signedt::__type __signed_type; > typedef __match_cv_qualifiers<_Tp, __signed_type> __cv_signed; > > public: > typedef typename __cv_signed::__type __type; > }; > > template<typename _Tp> > class __make_signed_selector<_Tp, false, true> > { > > typedef signed char __smallest; > static const bool __b0 = sizeof(_Tp) <= sizeof(__smallest); > static const bool __b1 = sizeof(_Tp) <= sizeof(signed short); > static const bool __b2 = sizeof(_Tp) <= sizeof(signed int); > typedef conditional<__b2, signed int, signed long> __cond2; > typedef typename __cond2::type __cond2_type; > typedef conditional<__b1, signed short, __cond2_type> __cond1; > typedef typename __cond1::type __cond1_type; > > public: > typedef typename conditional<__b0, __smallest, __cond1_type>::type __type; > }; > > > > > > template<typename _Tp> > struct make_signed > { typedef typename __make_signed_selector<_Tp>::__type type; }; > > > template<> > struct make_signed<bool>; ># 1733 "/usr/include/c++/4.9.0/type_traits" 3 > template<typename _Tp> > struct remove_extent > { typedef _Tp type; }; > > template<typename _Tp, std::size_t _Size> > struct remove_extent<_Tp[_Size]> > { typedef _Tp type; }; > > template<typename _Tp> > struct remove_extent<_Tp[]> > { typedef _Tp type; }; > > > template<typename _Tp> > struct remove_all_extents > { typedef _Tp type; }; > > template<typename _Tp, std::size_t _Size> > struct remove_all_extents<_Tp[_Size]> > { typedef typename remove_all_extents<_Tp>::type type; }; > > template<typename _Tp> > struct remove_all_extents<_Tp[]> > { typedef typename remove_all_extents<_Tp>::type type; }; ># 1770 "/usr/include/c++/4.9.0/type_traits" 3 > template<typename _Tp, typename> > struct __remove_pointer_helper > { typedef _Tp type; }; > > template<typename _Tp, typename _Up> > struct __remove_pointer_helper<_Tp, _Up*> > { typedef _Up type; }; > > > template<typename _Tp> > struct remove_pointer > : public __remove_pointer_helper<_Tp, typename remove_cv<_Tp>::type> > { }; > > > template<typename _Tp, bool = __or_<__is_referenceable<_Tp>, > is_void<_Tp>>::value> > struct __add_pointer_helper > { typedef _Tp type; }; > > template<typename _Tp> > struct __add_pointer_helper<_Tp, true> > { typedef typename remove_reference<_Tp>::type* type; }; > > template<typename _Tp> > struct add_pointer > : public __add_pointer_helper<_Tp> > { }; ># 1809 "/usr/include/c++/4.9.0/type_traits" 3 > template<std::size_t _Len> > struct __aligned_storage_msa > { > union __type > { > unsigned char __data[_Len]; > struct __attribute__((__aligned__)) { } __align; > }; > }; ># 1829 "/usr/include/c++/4.9.0/type_traits" 3 > template<std::size_t _Len, std::size_t _Align = > __alignof__(typename __aligned_storage_msa<_Len>::__type)> > struct aligned_storage > { > union type > { > unsigned char __data[_Len]; > struct __attribute__((__aligned__((_Align)))) { } __align; > }; > }; > > > > > template<typename _Up, > bool _IsArray = is_array<_Up>::value, > bool _IsFunction = is_function<_Up>::value> > struct __decay_selector; > > > template<typename _Up> > struct __decay_selector<_Up, false, false> > { typedef typename remove_cv<_Up>::type __type; }; > > template<typename _Up> > struct __decay_selector<_Up, true, false> > { typedef typename remove_extent<_Up>::type* __type; }; > > template<typename _Up> > struct __decay_selector<_Up, false, true> > { typedef typename add_pointer<_Up>::type __type; }; > > > template<typename _Tp> > class decay > { > typedef typename remove_reference<_Tp>::type __remove_type; > > public: > typedef typename __decay_selector<__remove_type>::__type type; > }; > > template<typename _Tp> > class reference_wrapper; > > > template<typename _Tp> > struct __strip_reference_wrapper > { > typedef _Tp __type; > }; > > template<typename _Tp> > struct __strip_reference_wrapper<reference_wrapper<_Tp> > > { > typedef _Tp& __type; > }; > > template<typename _Tp> > struct __decay_and_strip > { > typedef typename __strip_reference_wrapper< > typename decay<_Tp>::type>::__type __type; > }; > > > > > template<bool, typename _Tp = void> > struct enable_if > { }; > > > template<typename _Tp> > struct enable_if<true, _Tp> > { typedef _Tp type; }; > > template<typename... _Cond> > using _Require = typename enable_if<__and_<_Cond...>::value>::type; > > > > template<bool _Cond, typename _Iftrue, typename _Iffalse> > struct conditional > { typedef _Iftrue type; }; > > > template<typename _Iftrue, typename _Iffalse> > struct conditional<false, _Iftrue, _Iffalse> > { typedef _Iffalse type; }; > > > template<typename... _Tp> > struct common_type; > > > > struct __do_common_type_impl > { > template<typename _Tp, typename _Up> > static __success_type<typename decay<decltype > (true ? std::declval<_Tp>() > : std::declval<_Up>())>::type> _S_test(int); > > template<typename, typename> > static __failure_type _S_test(...); > }; > > template<typename _Tp, typename _Up> > struct __common_type_impl > : private __do_common_type_impl > { > typedef decltype(_S_test<_Tp, _Up>(0)) type; > }; > > struct __do_member_type_wrapper > { > template<typename _Tp> > static __success_type<typename _Tp::type> _S_test(int); > > template<typename> > static __failure_type _S_test(...); > }; > > template<typename _Tp> > struct __member_type_wrapper > : private __do_member_type_wrapper > { > typedef decltype(_S_test<_Tp>(0)) type; > }; > > template<typename _CTp, typename... _Args> > struct __expanded_common_type_wrapper > { > typedef common_type<typename _CTp::type, _Args...> type; > }; > > template<typename... _Args> > struct __expanded_common_type_wrapper<__failure_type, _Args...> > { typedef __failure_type type; }; > > template<typename _Tp> > struct common_type<_Tp> > { typedef typename decay<_Tp>::type type; }; > > template<typename _Tp, typename _Up> > struct common_type<_Tp, _Up> > : public __common_type_impl<_Tp, _Up>::type > { }; > > template<typename _Tp, typename _Up, typename... _Vp> > struct common_type<_Tp, _Up, _Vp...> > : public __expanded_common_type_wrapper<typename __member_type_wrapper< > common_type<_Tp, _Up>>::type, _Vp...>::type > { }; > > > template<typename _Tp> > struct underlying_type > { > typedef __underlying_type(_Tp) type; > }; > > template<typename _Tp> > struct __declval_protector > { > static const bool __stop = false; > static typename add_rvalue_reference<_Tp>::type __delegate(); > }; > > template<typename _Tp> > inline typename add_rvalue_reference<_Tp>::type > declval() noexcept > { > static_assert(__declval_protector<_Tp>::__stop, > "declval() must not be used!"); > return __declval_protector<_Tp>::__delegate(); > } > > > template<typename _Signature> > class result_of; > > > > > struct __result_of_memfun_ref_impl > { > template<typename _Fp, typename _Tp1, typename... _Args> > static __success_type<decltype( > (std::declval<_Tp1>().*std::declval<_Fp>())(std::declval<_Args>()...) > )> _S_test(int); > > template<typename...> > static __failure_type _S_test(...); > }; > > template<typename _MemPtr, typename _Arg, typename... _Args> > struct __result_of_memfun_ref > : private __result_of_memfun_ref_impl > { > typedef decltype(_S_test<_MemPtr, _Arg, _Args...>(0)) type; > }; > > > struct __result_of_memfun_deref_impl > { > template<typename _Fp, typename _Tp1, typename... _Args> > static __success_type<decltype( > ((*std::declval<_Tp1>()).*std::declval<_Fp>())(std::declval<_Args>()...) > )> _S_test(int); > > template<typename...> > static __failure_type _S_test(...); > }; > > template<typename _MemPtr, typename _Arg, typename... _Args> > struct __result_of_memfun_deref > : private __result_of_memfun_deref_impl > { > typedef decltype(_S_test<_MemPtr, _Arg, _Args...>(0)) type; > }; > > > struct __result_of_memobj_ref_impl > { > template<typename _Fp, typename _Tp1> > static __success_type<decltype( > std::declval<_Tp1>().*std::declval<_Fp>() > )> _S_test(int); > > template<typename, typename> > static __failure_type _S_test(...); > }; > > template<typename _MemPtr, typename _Arg> > struct __result_of_memobj_ref > : private __result_of_memobj_ref_impl > { > typedef decltype(_S_test<_MemPtr, _Arg>(0)) type; > }; > > > struct __result_of_memobj_deref_impl > { > template<typename _Fp, typename _Tp1> > static __success_type<decltype( > (*std::declval<_Tp1>()).*std::declval<_Fp>() > )> _S_test(int); > > template<typename, typename> > static __failure_type _S_test(...); > }; > > template<typename _MemPtr, typename _Arg> > struct __result_of_memobj_deref > : private __result_of_memobj_deref_impl > { > typedef decltype(_S_test<_MemPtr, _Arg>(0)) type; > }; > > template<typename _MemPtr, typename _Arg> > struct __result_of_memobj; > > template<typename _Res, typename _Class, typename _Arg> > struct __result_of_memobj<_Res _Class::*, _Arg> > { > typedef typename remove_cv<typename remove_reference< > _Arg>::type>::type _Argval; > typedef _Res _Class::* _MemPtr; > typedef typename conditional<__or_<is_same<_Argval, _Class>, > is_base_of<_Class, _Argval>>::value, > __result_of_memobj_ref<_MemPtr, _Arg>, > __result_of_memobj_deref<_MemPtr, _Arg> > >::type::type type; > }; > > template<typename _MemPtr, typename _Arg, typename... _Args> > struct __result_of_memfun; > > template<typename _Res, typename _Class, typename _Arg, typename... _Args> > struct __result_of_memfun<_Res _Class::*, _Arg, _Args...> > { > typedef typename remove_cv<typename remove_reference< > _Arg>::type>::type _Argval; > typedef _Res _Class::* _MemPtr; > typedef typename conditional<__or_<is_same<_Argval, _Class>, > is_base_of<_Class, _Argval>>::value, > __result_of_memfun_ref<_MemPtr, _Arg, _Args...>, > __result_of_memfun_deref<_MemPtr, _Arg, _Args...> > >::type::type type; > }; > > template<bool, bool, typename _Functor, typename... _ArgTypes> > struct __result_of_impl > { > typedef __failure_type type; > }; > > template<typename _MemPtr, typename _Arg> > struct __result_of_impl<true, false, _MemPtr, _Arg> > : public __result_of_memobj<typename decay<_MemPtr>::type, _Arg> > { }; > > template<typename _MemPtr, typename _Arg, typename... _Args> > struct __result_of_impl<false, true, _MemPtr, _Arg, _Args...> > : public __result_of_memfun<typename decay<_MemPtr>::type, _Arg, _Args...> > { }; > > > struct __result_of_other_impl > { > template<typename _Fn, typename... _Args> > static __success_type<decltype( > std::declval<_Fn>()(std::declval<_Args>()...) > )> _S_test(int); > > template<typename...> > static __failure_type _S_test(...); > }; > > template<typename _Functor, typename... _ArgTypes> > struct __result_of_impl<false, false, _Functor, _ArgTypes...> > : private __result_of_other_impl > { > typedef decltype(_S_test<_Functor, _ArgTypes...>(0)) type; > }; > > template<typename _Functor, typename... _ArgTypes> > struct result_of<_Functor(_ArgTypes...)> > : public __result_of_impl< > is_member_object_pointer< > typename remove_reference<_Functor>::type > >::value, > is_member_function_pointer< > typename remove_reference<_Functor>::type > >::value, > _Functor, _ArgTypes... > >::type > { }; ># 2231 "/usr/include/c++/4.9.0/type_traits" 3 > >} ># 58 "/usr/include/c++/4.9.0/bits/move.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 74 "/usr/include/c++/4.9.0/bits/move.h" 3 > template<typename _Tp> > constexpr _Tp&& > forward(typename std::remove_reference<_Tp>::type& __t) noexcept > { return static_cast<_Tp&&>(__t); } > > > > > > > > template<typename _Tp> > constexpr _Tp&& > forward(typename std::remove_reference<_Tp>::type&& __t) noexcept > { > static_assert(!std::is_lvalue_reference<_Tp>::value, "template argument" > " substituting _Tp is an lvalue reference type"); > return static_cast<_Tp&&>(__t); > } > > > > > > > template<typename _Tp> > constexpr typename std::remove_reference<_Tp>::type&& > move(_Tp&& __t) noexcept > { return static_cast<typename std::remove_reference<_Tp>::type&&>(__t); } > > > template<typename _Tp> > struct __move_if_noexcept_cond > : public __and_<__not_<is_nothrow_move_constructible<_Tp>>, > is_copy_constructible<_Tp>>::type { }; ># 118 "/usr/include/c++/4.9.0/bits/move.h" 3 > template<typename _Tp> > constexpr typename > conditional<__move_if_noexcept_cond<_Tp>::value, const _Tp&, _Tp&&>::type > move_if_noexcept(_Tp& __x) noexcept > { return std::move(__x); } ># 133 "/usr/include/c++/4.9.0/bits/move.h" 3 > template<typename _Tp> > inline _Tp* > addressof(_Tp& __r) noexcept > { return std::__addressof(__r); } > > > >} ># 149 "/usr/include/c++/4.9.0/bits/move.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 164 "/usr/include/c++/4.9.0/bits/move.h" 3 > template<typename _Tp> > inline void > swap(_Tp& __a, _Tp& __b) > > noexcept(__and_<is_nothrow_move_constructible<_Tp>, > is_nothrow_move_assignable<_Tp>>::value) > > { > > > > _Tp __tmp = std::move(__a); > __a = std::move(__b); > __b = std::move(__tmp); > } > > > > > template<typename _Tp, size_t _Nm> > inline void > swap(_Tp (&__a)[_Nm], _Tp (&__b)[_Nm]) > > noexcept(noexcept(swap(*__a, *__b))) > > { > for (size_t __n = 0; __n < _Nm; ++__n) > swap(__a[__n], __b[__n]); > } > > > >} ># 60 "/usr/include/c++/4.9.0/bits/stl_pair.h" 2 3 > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 76 "/usr/include/c++/4.9.0/bits/stl_pair.h" 3 > struct piecewise_construct_t { }; > > > constexpr piecewise_construct_t piecewise_construct = piecewise_construct_t(); > > > template<typename...> > class tuple; > > template<std::size_t...> > struct _Index_tuple; ># 95 "/usr/include/c++/4.9.0/bits/stl_pair.h" 3 > template<class _T1, class _T2> > struct pair > { > typedef _T1 first_type; > typedef _T2 second_type; > > _T1 first; > _T2 second; > > > > > > constexpr pair() > : first(), second() { } > > > constexpr pair(const _T1& __a, const _T2& __b) > : first(__a), second(__b) { } > > > > > > > > template<class _U1, class _U2, class = typename > enable_if<__and_<is_convertible<const _U1&, _T1>, > is_convertible<const _U2&, _T2>>::value>::type> > constexpr pair(const pair<_U1, _U2>& __p) > : first(__p.first), second(__p.second) { } > > constexpr pair(const pair&) = default; > constexpr pair(pair&&) = default; > > > template<class _U1, class = typename > enable_if<is_convertible<_U1, _T1>::value>::type> > constexpr pair(_U1&& __x, const _T2& __y) > : first(std::forward<_U1>(__x)), second(__y) { } > > template<class _U2, class = typename > enable_if<is_convertible<_U2, _T2>::value>::type> > constexpr pair(const _T1& __x, _U2&& __y) > : first(__x), second(std::forward<_U2>(__y)) { } > > template<class _U1, class _U2, class = typename > enable_if<__and_<is_convertible<_U1, _T1>, > is_convertible<_U2, _T2>>::value>::type> > constexpr pair(_U1&& __x, _U2&& __y) > : first(std::forward<_U1>(__x)), second(std::forward<_U2>(__y)) { } > > template<class _U1, class _U2, class = typename > enable_if<__and_<is_convertible<_U1, _T1>, > is_convertible<_U2, _T2>>::value>::type> > constexpr pair(pair<_U1, _U2>&& __p) > : first(std::forward<_U1>(__p.first)), > second(std::forward<_U2>(__p.second)) { } > > template<typename... _Args1, typename... _Args2> > pair(piecewise_construct_t, tuple<_Args1...>, tuple<_Args2...>); > > pair& > operator=(const pair& __p) > { > first = __p.first; > second = __p.second; > return *this; > } > > pair& > operator=(pair&& __p) > noexcept(__and_<is_nothrow_move_assignable<_T1>, > is_nothrow_move_assignable<_T2>>::value) > { > first = std::forward<first_type>(__p.first); > second = std::forward<second_type>(__p.second); > return *this; > } > > template<class _U1, class _U2> > pair& > operator=(const pair<_U1, _U2>& __p) > { > first = __p.first; > second = __p.second; > return *this; > } > > template<class _U1, class _U2> > pair& > operator=(pair<_U1, _U2>&& __p) > { > first = std::forward<_U1>(__p.first); > second = std::forward<_U2>(__p.second); > return *this; > } > > void > swap(pair& __p) > noexcept(noexcept(swap(first, __p.first)) > && noexcept(swap(second, __p.second))) > { > using std::swap; > swap(first, __p.first); > swap(second, __p.second); > } > > private: > template<typename... _Args1, std::size_t... _Indexes1, > typename... _Args2, std::size_t... _Indexes2> > pair(tuple<_Args1...>&, tuple<_Args2...>&, > _Index_tuple<_Indexes1...>, _Index_tuple<_Indexes2...>); > > }; > > > template<class _T1, class _T2> > inline constexpr bool > operator==(const pair<_T1, _T2>& __x, const pair<_T1, _T2>& __y) > { return __x.first == __y.first && __x.second == __y.second; } > > > template<class _T1, class _T2> > inline constexpr bool > operator<(const pair<_T1, _T2>& __x, const pair<_T1, _T2>& __y) > { return __x.first < __y.first > || (!(__y.first < __x.first) && __x.second < __y.second); } > > > template<class _T1, class _T2> > inline constexpr bool > operator!=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>& __y) > { return !(__x == __y); } > > > template<class _T1, class _T2> > inline constexpr bool > operator>(const pair<_T1, _T2>& __x, const pair<_T1, _T2>& __y) > { return __y < __x; } > > > template<class _T1, class _T2> > inline constexpr bool > operator<=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>& __y) > { return !(__y < __x); } > > > template<class _T1, class _T2> > inline constexpr bool > operator>=(const pair<_T1, _T2>& __x, const pair<_T1, _T2>& __y) > { return !(__x < __y); } > > > > > > template<class _T1, class _T2> > inline void > swap(pair<_T1, _T2>& __x, pair<_T1, _T2>& __y) > noexcept(noexcept(__x.swap(__y))) > { __x.swap(__y); } ># 273 "/usr/include/c++/4.9.0/bits/stl_pair.h" 3 > template<class _T1, class _T2> > constexpr pair<typename __decay_and_strip<_T1>::__type, > typename __decay_and_strip<_T2>::__type> > make_pair(_T1&& __x, _T2&& __y) > { > typedef typename __decay_and_strip<_T1>::__type __ds_type1; > typedef typename __decay_and_strip<_T2>::__type __ds_type2; > typedef pair<__ds_type1, __ds_type2> __pair_type; > return __pair_type(std::forward<_T1>(__x), std::forward<_T2>(__y)); > } ># 292 "/usr/include/c++/4.9.0/bits/stl_pair.h" 3 > >} ># 71 "/usr/include/c++/4.9.0/utility" 2 3 > > > ># 1 "/usr/include/c++/4.9.0/initializer_list" 1 3 ># 33 "/usr/include/c++/4.9.0/initializer_list" 3 ># 34 "/usr/include/c++/4.9.0/initializer_list" 3 > > > > > >#pragma GCC visibility push(default) > > > >namespace std >{ > > template<class _E> > class initializer_list > { > public: > typedef _E value_type; > typedef const _E& reference; > typedef const _E& const_reference; > typedef size_t size_type; > typedef const _E* iterator; > typedef const _E* const_iterator; > > private: > iterator _M_array; > size_type _M_len; > > > constexpr initializer_list(const_iterator __a, size_type __l) > : _M_array(__a), _M_len(__l) { } > > public: > constexpr initializer_list() noexcept > : _M_array(0), _M_len(0) { } > > > constexpr size_type > size() const noexcept { return _M_len; } > > > constexpr const_iterator > begin() const noexcept { return _M_array; } > > > constexpr const_iterator > end() const noexcept { return begin() + size(); } > }; > > > > > > > template<class _Tp> > constexpr const _Tp* > begin(initializer_list<_Tp> __ils) noexcept > { return __ils.begin(); } > > > > > > > template<class _Tp> > constexpr const _Tp* > end(initializer_list<_Tp> __ils) noexcept > { return __ils.end(); } >} > >#pragma GCC visibility pop ># 75 "/usr/include/c++/4.9.0/utility" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<class _Tp> > class tuple_size; > > template<std::size_t _Int, class _Tp> > class tuple_element; > > > template<class _Tp1, class _Tp2> > struct tuple_size<std::pair<_Tp1, _Tp2>> > : public integral_constant<std::size_t, 2> { }; > > template<class _Tp1, class _Tp2> > struct tuple_element<0, std::pair<_Tp1, _Tp2>> > { typedef _Tp1 type; }; > > template<class _Tp1, class _Tp2> > struct tuple_element<1, std::pair<_Tp1, _Tp2>> > { typedef _Tp2 type; }; > > template<std::size_t _Int> > struct __pair_get; > > template<> > struct __pair_get<0> > { > template<typename _Tp1, typename _Tp2> > static constexpr _Tp1& > __get(std::pair<_Tp1, _Tp2>& __pair) noexcept > { return __pair.first; } > > template<typename _Tp1, typename _Tp2> > static constexpr _Tp1&& > __move_get(std::pair<_Tp1, _Tp2>&& __pair) noexcept > { return std::forward<_Tp1>(__pair.first); } > > template<typename _Tp1, typename _Tp2> > static constexpr const _Tp1& > __const_get(const std::pair<_Tp1, _Tp2>& __pair) noexcept > { return __pair.first; } > }; > > template<> > struct __pair_get<1> > { > template<typename _Tp1, typename _Tp2> > static constexpr _Tp2& > __get(std::pair<_Tp1, _Tp2>& __pair) noexcept > { return __pair.second; } > > template<typename _Tp1, typename _Tp2> > static constexpr _Tp2&& > __move_get(std::pair<_Tp1, _Tp2>&& __pair) noexcept > { return std::forward<_Tp2>(__pair.second); } > > template<typename _Tp1, typename _Tp2> > static constexpr const _Tp2& > __const_get(const std::pair<_Tp1, _Tp2>& __pair) noexcept > { return __pair.second; } > }; > > template<std::size_t _Int, class _Tp1, class _Tp2> > constexpr typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type& > get(std::pair<_Tp1, _Tp2>& __in) noexcept > { return __pair_get<_Int>::__get(__in); } > > template<std::size_t _Int, class _Tp1, class _Tp2> > constexpr typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type&& > get(std::pair<_Tp1, _Tp2>&& __in) noexcept > { return __pair_get<_Int>::__move_get(std::move(__in)); } > > template<std::size_t _Int, class _Tp1, class _Tp2> > constexpr const typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type& > get(const std::pair<_Tp1, _Tp2>& __in) noexcept > { return __pair_get<_Int>::__const_get(__in); } ># 199 "/usr/include/c++/4.9.0/utility" 3 > template<size_t... _Indexes> > struct _Index_tuple > { > typedef _Index_tuple<_Indexes..., sizeof...(_Indexes)> __next; > }; > > > template<size_t _Num> > struct _Build_index_tuple > { > typedef typename _Build_index_tuple<_Num - 1>::__type::__next __type; > }; > > template<> > struct _Build_index_tuple<0> > { > typedef _Index_tuple<> __type; > }; ># 258 "/usr/include/c++/4.9.0/utility" 3 > >} ># 29 "/usr/include/boost/foreach.hpp" 2 3 4 > ># 1 "/usr/include/boost/config.hpp" 1 3 4 ># 26 "/usr/include/boost/config.hpp" 3 4 ># 1 "/usr/include/boost/config/user.hpp" 1 3 4 ># 27 "/usr/include/boost/config.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/config/select_compiler_config.hpp" 1 3 4 ># 32 "/usr/include/boost/config.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/config/compiler/gcc.hpp" 1 3 4 ># 36 "/usr/include/boost/config.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/config/select_stdlib_config.hpp" 1 3 4 ># 37 "/usr/include/boost/config/select_stdlib_config.hpp" 3 4 ># 1 "/usr/include/boost/config/no_tr1/utility.hpp" 1 3 4 ># 38 "/usr/include/boost/config/select_stdlib_config.hpp" 2 3 4 ># 41 "/usr/include/boost/config.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/config/stdlib/libstdcpp3.hpp" 1 3 4 ># 77 "/usr/include/boost/config/stdlib/libstdcpp3.hpp" 3 4 ># 1 "/usr/include/unistd.h" 1 3 4 ># 27 "/usr/include/unistd.h" 3 4 >extern "C" { ># 202 "/usr/include/unistd.h" 3 4 ># 1 "/usr/include/bits/posix_opt.h" 1 3 4 ># 203 "/usr/include/unistd.h" 2 3 4 > > > ># 1 "/usr/include/bits/environments.h" 1 3 4 ># 22 "/usr/include/bits/environments.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 23 "/usr/include/bits/environments.h" 2 3 4 ># 207 "/usr/include/unistd.h" 2 3 4 ># 217 "/usr/include/unistd.h" 3 4 ># 1 "/usr/include/bits/types.h" 1 3 4 ># 27 "/usr/include/bits/types.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 28 "/usr/include/bits/types.h" 2 3 4 > > >typedef unsigned char __u_char; >typedef unsigned short int __u_short; >typedef unsigned int __u_int; >typedef unsigned long int __u_long; > > >typedef signed char __int8_t; >typedef unsigned char __uint8_t; >typedef signed short int __int16_t; >typedef unsigned short int __uint16_t; >typedef signed int __int32_t; >typedef unsigned int __uint32_t; > >typedef signed long int __int64_t; >typedef unsigned long int __uint64_t; > > > > > > > >typedef long int __quad_t; >typedef unsigned long int __u_quad_t; ># 121 "/usr/include/bits/types.h" 3 4 ># 1 "/usr/include/bits/typesizes.h" 1 3 4 ># 122 "/usr/include/bits/types.h" 2 3 4 > > >typedef unsigned long int __dev_t; >typedef unsigned int __uid_t; >typedef unsigned int __gid_t; >typedef unsigned long int __ino_t; >typedef unsigned long int __ino64_t; >typedef unsigned int __mode_t; >typedef unsigned long int __nlink_t; >typedef long int __off_t; >typedef long int __off64_t; >typedef int __pid_t; >typedef struct { int __val[2]; } __fsid_t; >typedef long int __clock_t; >typedef unsigned long int __rlim_t; >typedef unsigned long int __rlim64_t; >typedef unsigned int __id_t; >typedef long int __time_t; >typedef unsigned int __useconds_t; >typedef long int __suseconds_t; > >typedef int __daddr_t; >typedef int __key_t; > > >typedef int __clockid_t; > > >typedef void * __timer_t; > > >typedef long int __blksize_t; > > > > >typedef long int __blkcnt_t; >typedef long int __blkcnt64_t; > > >typedef unsigned long int __fsblkcnt_t; >typedef unsigned long int __fsblkcnt64_t; > > >typedef unsigned long int __fsfilcnt_t; >typedef unsigned long int __fsfilcnt64_t; > > >typedef long int __fsword_t; > >typedef long int __ssize_t; > > >typedef long int __syscall_slong_t; > >typedef unsigned long int __syscall_ulong_t; > > > >typedef __off64_t __loff_t; >typedef __quad_t *__qaddr_t; >typedef char *__caddr_t; > > >typedef long int __intptr_t; > > >typedef unsigned int __socklen_t; ># 218 "/usr/include/unistd.h" 2 3 4 > > >typedef __ssize_t ssize_t; > > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 227 "/usr/include/unistd.h" 2 3 4 > > > > > >typedef __gid_t gid_t; > > > > >typedef __uid_t uid_t; > > > > > >typedef __off_t off_t; > > > > > > >typedef __off64_t off64_t; > > > > >typedef __useconds_t useconds_t; > > > > >typedef __pid_t pid_t; > > > > > > >typedef __intptr_t intptr_t; > > > > > > >typedef __socklen_t socklen_t; ># 287 "/usr/include/unistd.h" 3 4 >extern int access (const char *__name, int __type) throw () __attribute__ ((__nonnull__ (1))); > > > > >extern int euidaccess (const char *__name, int __type) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int eaccess (const char *__name, int __type) > throw () __attribute__ ((__nonnull__ (1))); > > > > > > >extern int faccessat (int __fd, const char *__file, int __type, int __flag) > throw () __attribute__ ((__nonnull__ (2))) ; ># 334 "/usr/include/unistd.h" 3 4 >extern __off_t lseek (int __fd, __off_t __offset, int __whence) throw (); ># 345 "/usr/include/unistd.h" 3 4 >extern __off64_t lseek64 (int __fd, __off64_t __offset, int __whence) > throw (); > > > > > > >extern int close (int __fd); > > > > > > >extern ssize_t read (int __fd, void *__buf, size_t __nbytes) ; > > > > > >extern ssize_t write (int __fd, const void *__buf, size_t __n) ; ># 376 "/usr/include/unistd.h" 3 4 >extern ssize_t pread (int __fd, void *__buf, size_t __nbytes, > __off_t __offset) ; > > > > > > >extern ssize_t pwrite (int __fd, const void *__buf, size_t __n, > __off_t __offset) ; ># 404 "/usr/include/unistd.h" 3 4 >extern ssize_t pread64 (int __fd, void *__buf, size_t __nbytes, > __off64_t __offset) ; > > >extern ssize_t pwrite64 (int __fd, const void *__buf, size_t __n, > __off64_t __offset) ; > > > > > > > >extern int pipe (int __pipedes[2]) throw () ; > > > > >extern int pipe2 (int __pipedes[2], int __flags) throw () ; ># 432 "/usr/include/unistd.h" 3 4 >extern unsigned int alarm (unsigned int __seconds) throw (); ># 444 "/usr/include/unistd.h" 3 4 >extern unsigned int sleep (unsigned int __seconds); > > > > > > > >extern __useconds_t ualarm (__useconds_t __value, __useconds_t __interval) > throw (); > > > > > > >extern int usleep (__useconds_t __useconds); ># 469 "/usr/include/unistd.h" 3 4 >extern int pause (void); > > > >extern int chown (const char *__file, __uid_t __owner, __gid_t __group) > throw () __attribute__ ((__nonnull__ (1))) ; > > > >extern int fchown (int __fd, __uid_t __owner, __gid_t __group) throw () ; > > > > >extern int lchown (const char *__file, __uid_t __owner, __gid_t __group) > throw () __attribute__ ((__nonnull__ (1))) ; > > > > > > >extern int fchownat (int __fd, const char *__file, __uid_t __owner, > __gid_t __group, int __flag) > throw () __attribute__ ((__nonnull__ (2))) ; > > > >extern int chdir (const char *__path) throw () __attribute__ ((__nonnull__ (1))) ; > > > >extern int fchdir (int __fd) throw () ; ># 511 "/usr/include/unistd.h" 3 4 >extern char *getcwd (char *__buf, size_t __size) throw () ; > > > > > >extern char *get_current_dir_name (void) throw (); > > > > > > > >extern char *getwd (char *__buf) > throw () __attribute__ ((__nonnull__ (1))) __attribute__ ((__deprecated__)) ; > > > > >extern int dup (int __fd) throw () ; > > >extern int dup2 (int __fd, int __fd2) throw (); > > > > >extern int dup3 (int __fd, int __fd2, int __flags) throw (); > > > >extern char **__environ; > >extern char **environ; > > > > > >extern int execve (const char *__path, char *const __argv[], > char *const __envp[]) throw () __attribute__ ((__nonnull__ (1, 2))); > > > > >extern int fexecve (int __fd, char *const __argv[], char *const __envp[]) > throw () __attribute__ ((__nonnull__ (2))); > > > > >extern int execv (const char *__path, char *const __argv[]) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int execle (const char *__path, const char *__arg, ...) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int execl (const char *__path, const char *__arg, ...) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int execvp (const char *__file, char *const __argv[]) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > >extern int execlp (const char *__file, const char *__arg, ...) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > >extern int execvpe (const char *__file, char *const __argv[], > char *const __envp[]) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > > >extern int nice (int __inc) throw () ; > > > > >extern void _exit (int __status) __attribute__ ((__noreturn__)); > > > > > ># 1 "/usr/include/bits/confname.h" 1 3 4 ># 24 "/usr/include/bits/confname.h" 3 4 >enum > { > _PC_LINK_MAX, > > _PC_MAX_CANON, > > _PC_MAX_INPUT, > > _PC_NAME_MAX, > > _PC_PATH_MAX, > > _PC_PIPE_BUF, > > _PC_CHOWN_RESTRICTED, > > _PC_NO_TRUNC, > > _PC_VDISABLE, > > _PC_SYNC_IO, > > _PC_ASYNC_IO, > > _PC_PRIO_IO, > > _PC_SOCK_MAXBUF, > > _PC_FILESIZEBITS, > > _PC_REC_INCR_XFER_SIZE, > > _PC_REC_MAX_XFER_SIZE, > > _PC_REC_MIN_XFER_SIZE, > > _PC_REC_XFER_ALIGN, > > _PC_ALLOC_SIZE_MIN, > > _PC_SYMLINK_MAX, > > _PC_2_SYMLINKS > > }; > > >enum > { > _SC_ARG_MAX, > > _SC_CHILD_MAX, > > _SC_CLK_TCK, > > _SC_NGROUPS_MAX, > > _SC_OPEN_MAX, > > _SC_STREAM_MAX, > > _SC_TZNAME_MAX, > > _SC_JOB_CONTROL, > > _SC_SAVED_IDS, > > _SC_REALTIME_SIGNALS, > > _SC_PRIORITY_SCHEDULING, > > _SC_TIMERS, > > _SC_ASYNCHRONOUS_IO, > > _SC_PRIORITIZED_IO, > > _SC_SYNCHRONIZED_IO, > > _SC_FSYNC, > > _SC_MAPPED_FILES, > > _SC_MEMLOCK, > > _SC_MEMLOCK_RANGE, > > _SC_MEMORY_PROTECTION, > > _SC_MESSAGE_PASSING, > > _SC_SEMAPHORES, > > _SC_SHARED_MEMORY_OBJECTS, > > _SC_AIO_LISTIO_MAX, > > _SC_AIO_MAX, > > _SC_AIO_PRIO_DELTA_MAX, > > _SC_DELAYTIMER_MAX, > > _SC_MQ_OPEN_MAX, > > _SC_MQ_PRIO_MAX, > > _SC_VERSION, > > _SC_PAGESIZE, > > > _SC_RTSIG_MAX, > > _SC_SEM_NSEMS_MAX, > > _SC_SEM_VALUE_MAX, > > _SC_SIGQUEUE_MAX, > > _SC_TIMER_MAX, > > > > > _SC_BC_BASE_MAX, > > _SC_BC_DIM_MAX, > > _SC_BC_SCALE_MAX, > > _SC_BC_STRING_MAX, > > _SC_COLL_WEIGHTS_MAX, > > _SC_EQUIV_CLASS_MAX, > > _SC_EXPR_NEST_MAX, > > _SC_LINE_MAX, > > _SC_RE_DUP_MAX, > > _SC_CHARCLASS_NAME_MAX, > > > _SC_2_VERSION, > > _SC_2_C_BIND, > > _SC_2_C_DEV, > > _SC_2_FORT_DEV, > > _SC_2_FORT_RUN, > > _SC_2_SW_DEV, > > _SC_2_LOCALEDEF, > > > _SC_PII, > > _SC_PII_XTI, > > _SC_PII_SOCKET, > > _SC_PII_INTERNET, > > _SC_PII_OSI, > > _SC_POLL, > > _SC_SELECT, > > _SC_UIO_MAXIOV, > > _SC_IOV_MAX = _SC_UIO_MAXIOV, > > _SC_PII_INTERNET_STREAM, > > _SC_PII_INTERNET_DGRAM, > > _SC_PII_OSI_COTS, > > _SC_PII_OSI_CLTS, > > _SC_PII_OSI_M, > > _SC_T_IOV_MAX, > > > > _SC_THREADS, > > _SC_THREAD_SAFE_FUNCTIONS, > > _SC_GETGR_R_SIZE_MAX, > > _SC_GETPW_R_SIZE_MAX, > > _SC_LOGIN_NAME_MAX, > > _SC_TTY_NAME_MAX, > > _SC_THREAD_DESTRUCTOR_ITERATIONS, > > _SC_THREAD_KEYS_MAX, > > _SC_THREAD_STACK_MIN, > > _SC_THREAD_THREADS_MAX, > > _SC_THREAD_ATTR_STACKADDR, > > _SC_THREAD_ATTR_STACKSIZE, > > _SC_THREAD_PRIORITY_SCHEDULING, > > _SC_THREAD_PRIO_INHERIT, > > _SC_THREAD_PRIO_PROTECT, > > _SC_THREAD_PROCESS_SHARED, > > > _SC_NPROCESSORS_CONF, > > _SC_NPROCESSORS_ONLN, > > _SC_PHYS_PAGES, > > _SC_AVPHYS_PAGES, > > _SC_ATEXIT_MAX, > > _SC_PASS_MAX, > > > _SC_XOPEN_VERSION, > > _SC_XOPEN_XCU_VERSION, > > _SC_XOPEN_UNIX, > > _SC_XOPEN_CRYPT, > > _SC_XOPEN_ENH_I18N, > > _SC_XOPEN_SHM, > > > _SC_2_CHAR_TERM, > > _SC_2_C_VERSION, > > _SC_2_UPE, > > > _SC_XOPEN_XPG2, > > _SC_XOPEN_XPG3, > > _SC_XOPEN_XPG4, > > > _SC_CHAR_BIT, > > _SC_CHAR_MAX, > > _SC_CHAR_MIN, > > _SC_INT_MAX, > > _SC_INT_MIN, > > _SC_LONG_BIT, > > _SC_WORD_BIT, > > _SC_MB_LEN_MAX, > > _SC_NZERO, > > _SC_SSIZE_MAX, > > _SC_SCHAR_MAX, > > _SC_SCHAR_MIN, > > _SC_SHRT_MAX, > > _SC_SHRT_MIN, > > _SC_UCHAR_MAX, > > _SC_UINT_MAX, > > _SC_ULONG_MAX, > > _SC_USHRT_MAX, > > > _SC_NL_ARGMAX, > > _SC_NL_LANGMAX, > > _SC_NL_MSGMAX, > > _SC_NL_NMAX, > > _SC_NL_SETMAX, > > _SC_NL_TEXTMAX, > > > _SC_XBS5_ILP32_OFF32, > > _SC_XBS5_ILP32_OFFBIG, > > _SC_XBS5_LP64_OFF64, > > _SC_XBS5_LPBIG_OFFBIG, > > > _SC_XOPEN_LEGACY, > > _SC_XOPEN_REALTIME, > > _SC_XOPEN_REALTIME_THREADS, > > > _SC_ADVISORY_INFO, > > _SC_BARRIERS, > > _SC_BASE, > > _SC_C_LANG_SUPPORT, > > _SC_C_LANG_SUPPORT_R, > > _SC_CLOCK_SELECTION, > > _SC_CPUTIME, > > _SC_THREAD_CPUTIME, > > _SC_DEVICE_IO, > > _SC_DEVICE_SPECIFIC, > > _SC_DEVICE_SPECIFIC_R, > > _SC_FD_MGMT, > > _SC_FIFO, > > _SC_PIPE, > > _SC_FILE_ATTRIBUTES, > > _SC_FILE_LOCKING, > > _SC_FILE_SYSTEM, > > _SC_MONOTONIC_CLOCK, > > _SC_MULTI_PROCESS, > > _SC_SINGLE_PROCESS, > > _SC_NETWORKING, > > _SC_READER_WRITER_LOCKS, > > _SC_SPIN_LOCKS, > > _SC_REGEXP, > > _SC_REGEX_VERSION, > > _SC_SHELL, > > _SC_SIGNALS, > > _SC_SPAWN, > > _SC_SPORADIC_SERVER, > > _SC_THREAD_SPORADIC_SERVER, > > _SC_SYSTEM_DATABASE, > > _SC_SYSTEM_DATABASE_R, > > _SC_TIMEOUTS, > > _SC_TYPED_MEMORY_OBJECTS, > > _SC_USER_GROUPS, > > _SC_USER_GROUPS_R, > > _SC_2_PBS, > > _SC_2_PBS_ACCOUNTING, > > _SC_2_PBS_LOCATE, > > _SC_2_PBS_MESSAGE, > > _SC_2_PBS_TRACK, > > _SC_SYMLOOP_MAX, > > _SC_STREAMS, > > _SC_2_PBS_CHECKPOINT, > > > _SC_V6_ILP32_OFF32, > > _SC_V6_ILP32_OFFBIG, > > _SC_V6_LP64_OFF64, > > _SC_V6_LPBIG_OFFBIG, > > > _SC_HOST_NAME_MAX, > > _SC_TRACE, > > _SC_TRACE_EVENT_FILTER, > > _SC_TRACE_INHERIT, > > _SC_TRACE_LOG, > > > _SC_LEVEL1_ICACHE_SIZE, > > _SC_LEVEL1_ICACHE_ASSOC, > > _SC_LEVEL1_ICACHE_LINESIZE, > > _SC_LEVEL1_DCACHE_SIZE, > > _SC_LEVEL1_DCACHE_ASSOC, > > _SC_LEVEL1_DCACHE_LINESIZE, > > _SC_LEVEL2_CACHE_SIZE, > > _SC_LEVEL2_CACHE_ASSOC, > > _SC_LEVEL2_CACHE_LINESIZE, > > _SC_LEVEL3_CACHE_SIZE, > > _SC_LEVEL3_CACHE_ASSOC, > > _SC_LEVEL3_CACHE_LINESIZE, > > _SC_LEVEL4_CACHE_SIZE, > > _SC_LEVEL4_CACHE_ASSOC, > > _SC_LEVEL4_CACHE_LINESIZE, > > > > _SC_IPV6 = _SC_LEVEL1_ICACHE_SIZE + 50, > > _SC_RAW_SOCKETS, > > > _SC_V7_ILP32_OFF32, > > _SC_V7_ILP32_OFFBIG, > > _SC_V7_LP64_OFF64, > > _SC_V7_LPBIG_OFFBIG, > > > _SC_SS_REPL_MAX, > > > _SC_TRACE_EVENT_NAME_MAX, > > _SC_TRACE_NAME_MAX, > > _SC_TRACE_SYS_MAX, > > _SC_TRACE_USER_EVENT_MAX, > > > _SC_XOPEN_STREAMS, > > > _SC_THREAD_ROBUST_PRIO_INHERIT, > > _SC_THREAD_ROBUST_PRIO_PROTECT > > }; > > >enum > { > _CS_PATH, > > > _CS_V6_WIDTH_RESTRICTED_ENVS, > > > > _CS_GNU_LIBC_VERSION, > > _CS_GNU_LIBPTHREAD_VERSION, > > > _CS_V5_WIDTH_RESTRICTED_ENVS, > > > > _CS_V7_WIDTH_RESTRICTED_ENVS, > > > > _CS_LFS_CFLAGS = 1000, > > _CS_LFS_LDFLAGS, > > _CS_LFS_LIBS, > > _CS_LFS_LINTFLAGS, > > _CS_LFS64_CFLAGS, > > _CS_LFS64_LDFLAGS, > > _CS_LFS64_LIBS, > > _CS_LFS64_LINTFLAGS, > > > _CS_XBS5_ILP32_OFF32_CFLAGS = 1100, > > _CS_XBS5_ILP32_OFF32_LDFLAGS, > > _CS_XBS5_ILP32_OFF32_LIBS, > > _CS_XBS5_ILP32_OFF32_LINTFLAGS, > > _CS_XBS5_ILP32_OFFBIG_CFLAGS, > > _CS_XBS5_ILP32_OFFBIG_LDFLAGS, > > _CS_XBS5_ILP32_OFFBIG_LIBS, > > _CS_XBS5_ILP32_OFFBIG_LINTFLAGS, > > _CS_XBS5_LP64_OFF64_CFLAGS, > > _CS_XBS5_LP64_OFF64_LDFLAGS, > > _CS_XBS5_LP64_OFF64_LIBS, > > _CS_XBS5_LP64_OFF64_LINTFLAGS, > > _CS_XBS5_LPBIG_OFFBIG_CFLAGS, > > _CS_XBS5_LPBIG_OFFBIG_LDFLAGS, > > _CS_XBS5_LPBIG_OFFBIG_LIBS, > > _CS_XBS5_LPBIG_OFFBIG_LINTFLAGS, > > > _CS_POSIX_V6_ILP32_OFF32_CFLAGS, > > _CS_POSIX_V6_ILP32_OFF32_LDFLAGS, > > _CS_POSIX_V6_ILP32_OFF32_LIBS, > > _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS, > > _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS, > > _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS, > > _CS_POSIX_V6_ILP32_OFFBIG_LIBS, > > _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS, > > _CS_POSIX_V6_LP64_OFF64_CFLAGS, > > _CS_POSIX_V6_LP64_OFF64_LDFLAGS, > > _CS_POSIX_V6_LP64_OFF64_LIBS, > > _CS_POSIX_V6_LP64_OFF64_LINTFLAGS, > > _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS, > > _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS, > > _CS_POSIX_V6_LPBIG_OFFBIG_LIBS, > > _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS, > > > _CS_POSIX_V7_ILP32_OFF32_CFLAGS, > > _CS_POSIX_V7_ILP32_OFF32_LDFLAGS, > > _CS_POSIX_V7_ILP32_OFF32_LIBS, > > _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS, > > _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS, > > _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS, > > _CS_POSIX_V7_ILP32_OFFBIG_LIBS, > > _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS, > > _CS_POSIX_V7_LP64_OFF64_CFLAGS, > > _CS_POSIX_V7_LP64_OFF64_LDFLAGS, > > _CS_POSIX_V7_LP64_OFF64_LIBS, > > _CS_POSIX_V7_LP64_OFF64_LINTFLAGS, > > _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS, > > _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS, > > _CS_POSIX_V7_LPBIG_OFFBIG_LIBS, > > _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS, > > > _CS_V6_ENV, > > _CS_V7_ENV > > }; ># 610 "/usr/include/unistd.h" 2 3 4 > > >extern long int pathconf (const char *__path, int __name) > throw () __attribute__ ((__nonnull__ (1))); > > >extern long int fpathconf (int __fd, int __name) throw (); > > >extern long int sysconf (int __name) throw (); > > > >extern size_t confstr (int __name, char *__buf, size_t __len) throw (); > > > > >extern __pid_t getpid (void) throw (); > > >extern __pid_t getppid (void) throw (); > > > > >extern __pid_t getpgrp (void) throw (); ># 646 "/usr/include/unistd.h" 3 4 >extern __pid_t __getpgid (__pid_t __pid) throw (); > >extern __pid_t getpgid (__pid_t __pid) throw (); > > > > > > >extern int setpgid (__pid_t __pid, __pid_t __pgid) throw (); ># 672 "/usr/include/unistd.h" 3 4 >extern int setpgrp (void) throw (); ># 689 "/usr/include/unistd.h" 3 4 >extern __pid_t setsid (void) throw (); > > > >extern __pid_t getsid (__pid_t __pid) throw (); > > > >extern __uid_t getuid (void) throw (); > > >extern __uid_t geteuid (void) throw (); > > >extern __gid_t getgid (void) throw (); > > >extern __gid_t getegid (void) throw (); > > > > >extern int getgroups (int __size, __gid_t __list[]) throw () ; > > > >extern int group_member (__gid_t __gid) throw (); > > > > > > >extern int setuid (__uid_t __uid) throw () ; > > > > >extern int setreuid (__uid_t __ruid, __uid_t __euid) throw () ; > > > > >extern int seteuid (__uid_t __uid) throw () ; > > > > > > >extern int setgid (__gid_t __gid) throw () ; > > > > >extern int setregid (__gid_t __rgid, __gid_t __egid) throw () ; > > > > >extern int setegid (__gid_t __gid) throw () ; > > > > > >extern int getresuid (__uid_t *__ruid, __uid_t *__euid, __uid_t *__suid) > throw (); > > > >extern int getresgid (__gid_t *__rgid, __gid_t *__egid, __gid_t *__sgid) > throw (); > > > >extern int setresuid (__uid_t __ruid, __uid_t __euid, __uid_t __suid) > throw () ; > > > >extern int setresgid (__gid_t __rgid, __gid_t __egid, __gid_t __sgid) > throw () ; > > > > > > >extern __pid_t fork (void) throw (); > > > > > > > >extern __pid_t vfork (void) throw (); > > > > > >extern char *ttyname (int __fd) throw (); > > > >extern int ttyname_r (int __fd, char *__buf, size_t __buflen) > throw () __attribute__ ((__nonnull__ (2))) ; > > > >extern int isatty (int __fd) throw (); > > > > > >extern int ttyslot (void) throw (); > > > > >extern int link (const char *__from, const char *__to) > throw () __attribute__ ((__nonnull__ (1, 2))) ; > > > > >extern int linkat (int __fromfd, const char *__from, int __tofd, > const char *__to, int __flags) > throw () __attribute__ ((__nonnull__ (2, 4))) ; > > > > >extern int symlink (const char *__from, const char *__to) > throw () __attribute__ ((__nonnull__ (1, 2))) ; > > > > >extern ssize_t readlink (const char *__restrict __path, > char *__restrict __buf, size_t __len) > throw () __attribute__ ((__nonnull__ (1, 2))) ; > > > > >extern int symlinkat (const char *__from, int __tofd, > const char *__to) throw () __attribute__ ((__nonnull__ (1, 3))) ; > > >extern ssize_t readlinkat (int __fd, const char *__restrict __path, > char *__restrict __buf, size_t __len) > throw () __attribute__ ((__nonnull__ (2, 3))) ; > > > >extern int unlink (const char *__name) throw () __attribute__ ((__nonnull__ (1))); > > > >extern int unlinkat (int __fd, const char *__name, int __flag) > throw () __attribute__ ((__nonnull__ (2))); > > > >extern int rmdir (const char *__path) throw () __attribute__ ((__nonnull__ (1))); > > > >extern __pid_t tcgetpgrp (int __fd) throw (); > > >extern int tcsetpgrp (int __fd, __pid_t __pgrp_id) throw (); > > > > > > >extern char *getlogin (void); > > > > > > > >extern int getlogin_r (char *__name, size_t __name_len) __attribute__ ((__nonnull__ (1))); > > > > >extern int setlogin (const char *__name) throw () __attribute__ ((__nonnull__ (1))); ># 893 "/usr/include/unistd.h" 3 4 ># 1 "/usr/include/getopt.h" 1 3 4 ># 48 "/usr/include/getopt.h" 3 4 >extern "C" { ># 57 "/usr/include/getopt.h" 3 4 >extern char *optarg; ># 71 "/usr/include/getopt.h" 3 4 >extern int optind; > > > > >extern int opterr; > > > >extern int optopt; ># 150 "/usr/include/getopt.h" 3 4 >extern int getopt (int ___argc, char *const *___argv, const char *__shortopts) > throw (); ># 185 "/usr/include/getopt.h" 3 4 >} ># 894 "/usr/include/unistd.h" 2 3 4 > > > > > > > >extern int gethostname (char *__name, size_t __len) throw () __attribute__ ((__nonnull__ (1))); > > > > > > >extern int sethostname (const char *__name, size_t __len) > throw () __attribute__ ((__nonnull__ (1))) ; > > > >extern int sethostid (long int __id) throw () ; > > > > > >extern int getdomainname (char *__name, size_t __len) > throw () __attribute__ ((__nonnull__ (1))) ; >extern int setdomainname (const char *__name, size_t __len) > throw () __attribute__ ((__nonnull__ (1))) ; > > > > > >extern int vhangup (void) throw (); > > >extern int revoke (const char *__file) throw () __attribute__ ((__nonnull__ (1))) ; > > > > > > > >extern int profil (unsigned short int *__sample_buffer, size_t __size, > size_t __offset, unsigned int __scale) > throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern int acct (const char *__name) throw (); > > > >extern char *getusershell (void) throw (); >extern void endusershell (void) throw (); >extern void setusershell (void) throw (); > > > > > >extern int daemon (int __nochdir, int __noclose) throw () ; > > > > > > >extern int chroot (const char *__path) throw () __attribute__ ((__nonnull__ (1))) ; > > > >extern char *getpass (const char *__prompt) __attribute__ ((__nonnull__ (1))); > > > > > > > >extern int fsync (int __fd); > > > > > >extern int syncfs (int __fd) throw (); > > > > > > >extern long int gethostid (void); > > >extern void sync (void) throw (); > > > > > >extern int getpagesize (void) throw () __attribute__ ((__const__)); > > > > >extern int getdtablesize (void) throw (); ># 1015 "/usr/include/unistd.h" 3 4 >extern int truncate (const char *__file, __off_t __length) > throw () __attribute__ ((__nonnull__ (1))) ; ># 1027 "/usr/include/unistd.h" 3 4 >extern int truncate64 (const char *__file, __off64_t __length) > throw () __attribute__ ((__nonnull__ (1))) ; ># 1038 "/usr/include/unistd.h" 3 4 >extern int ftruncate (int __fd, __off_t __length) throw () ; ># 1048 "/usr/include/unistd.h" 3 4 >extern int ftruncate64 (int __fd, __off64_t __length) throw () ; ># 1059 "/usr/include/unistd.h" 3 4 >extern int brk (void *__addr) throw () ; > > > > > >extern void *sbrk (intptr_t __delta) throw (); ># 1080 "/usr/include/unistd.h" 3 4 >extern long int syscall (long int __sysno, ...) throw (); ># 1103 "/usr/include/unistd.h" 3 4 >extern int lockf (int __fd, int __cmd, __off_t __len) ; ># 1113 "/usr/include/unistd.h" 3 4 >extern int lockf64 (int __fd, int __cmd, __off64_t __len) ; ># 1134 "/usr/include/unistd.h" 3 4 >extern int fdatasync (int __fildes); > > > > > > > >extern char *crypt (const char *__key, const char *__salt) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern void encrypt (char *__block, int __edflag) throw () __attribute__ ((__nonnull__ (1))); > > > > > > >extern void swab (const void *__restrict __from, void *__restrict __to, > ssize_t __n) throw () __attribute__ ((__nonnull__ (1, 2))); ># 1172 "/usr/include/unistd.h" 3 4 >} ># 78 "/usr/include/boost/config/stdlib/libstdcpp3.hpp" 2 3 4 ># 45 "/usr/include/boost/config.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/config/select_platform_config.hpp" 1 3 4 ># 50 "/usr/include/boost/config.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/config/platform/linux.hpp" 1 3 4 ># 15 "/usr/include/boost/config/platform/linux.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 72 "/usr/include/c++/4.9.0/cstdlib" 3 ># 1 "/usr/include/stdlib.h" 1 3 4 ># 32 "/usr/include/stdlib.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 33 "/usr/include/stdlib.h" 2 3 4 > >extern "C" { > > > > > > ># 1 "/usr/include/bits/waitflags.h" 1 3 4 ># 42 "/usr/include/stdlib.h" 2 3 4 ># 1 "/usr/include/bits/waitstatus.h" 1 3 4 ># 64 "/usr/include/bits/waitstatus.h" 3 4 ># 1 "/usr/include/endian.h" 1 3 4 ># 36 "/usr/include/endian.h" 3 4 ># 1 "/usr/include/bits/endian.h" 1 3 4 ># 37 "/usr/include/endian.h" 2 3 4 ># 60 "/usr/include/endian.h" 3 4 ># 1 "/usr/include/bits/byteswap.h" 1 3 4 ># 28 "/usr/include/bits/byteswap.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 29 "/usr/include/bits/byteswap.h" 2 3 4 > > > > > > ># 1 "/usr/include/bits/byteswap-16.h" 1 3 4 ># 36 "/usr/include/bits/byteswap.h" 2 3 4 ># 44 "/usr/include/bits/byteswap.h" 3 4 >static __inline unsigned int >__bswap_32 (unsigned int __bsx) >{ > return __builtin_bswap32 (__bsx); >} ># 108 "/usr/include/bits/byteswap.h" 3 4 >static __inline __uint64_t >__bswap_64 (__uint64_t __bsx) >{ > return __builtin_bswap64 (__bsx); >} ># 61 "/usr/include/endian.h" 2 3 4 ># 65 "/usr/include/bits/waitstatus.h" 2 3 4 > >union wait > { > int w_status; > struct > { > > unsigned int __w_termsig:7; > unsigned int __w_coredump:1; > unsigned int __w_retcode:8; > unsigned int:16; > > > > > > > > } __wait_terminated; > struct > { > > unsigned int __w_stopval:8; > unsigned int __w_stopsig:8; > unsigned int:16; > > > > > > > } __wait_stopped; > }; ># 43 "/usr/include/stdlib.h" 2 3 4 ># 95 "/usr/include/stdlib.h" 3 4 > > >typedef struct > { > int quot; > int rem; > } div_t; > > > >typedef struct > { > long int quot; > long int rem; > } ldiv_t; > > > > > > > >__extension__ typedef struct > { > long long int quot; > long long int rem; > } lldiv_t; ># 139 "/usr/include/stdlib.h" 3 4 >extern size_t __ctype_get_mb_cur_max (void) throw () ; > > > > >extern double atof (const char *__nptr) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; > >extern int atoi (const char *__nptr) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; > >extern long int atol (const char *__nptr) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; > > > > > >__extension__ extern long long int atoll (const char *__nptr) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; > > > > > >extern double strtod (const char *__restrict __nptr, > char **__restrict __endptr) > throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern float strtof (const char *__restrict __nptr, > char **__restrict __endptr) throw () __attribute__ ((__nonnull__ (1))); > >extern long double strtold (const char *__restrict __nptr, > char **__restrict __endptr) > throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern long int strtol (const char *__restrict __nptr, > char **__restrict __endptr, int __base) > throw () __attribute__ ((__nonnull__ (1))); > >extern unsigned long int strtoul (const char *__restrict __nptr, > char **__restrict __endptr, int __base) > throw () __attribute__ ((__nonnull__ (1))); > > > > >__extension__ >extern long long int strtoq (const char *__restrict __nptr, > char **__restrict __endptr, int __base) > throw () __attribute__ ((__nonnull__ (1))); > >__extension__ >extern unsigned long long int strtouq (const char *__restrict __nptr, > char **__restrict __endptr, int __base) > throw () __attribute__ ((__nonnull__ (1))); > > > > > >__extension__ >extern long long int strtoll (const char *__restrict __nptr, > char **__restrict __endptr, int __base) > throw () __attribute__ ((__nonnull__ (1))); > >__extension__ >extern unsigned long long int strtoull (const char *__restrict __nptr, > char **__restrict __endptr, int __base) > throw () __attribute__ ((__nonnull__ (1))); ># 235 "/usr/include/stdlib.h" 3 4 ># 1 "/usr/include/xlocale.h" 1 3 4 ># 27 "/usr/include/xlocale.h" 3 4 >typedef struct __locale_struct >{ > > struct __locale_data *__locales[13]; > > > const unsigned short int *__ctype_b; > const int *__ctype_tolower; > const int *__ctype_toupper; > > > const char *__names[13]; >} *__locale_t; > > >typedef __locale_t locale_t; ># 236 "/usr/include/stdlib.h" 2 3 4 > > > >extern long int strtol_l (const char *__restrict __nptr, > char **__restrict __endptr, int __base, > __locale_t __loc) throw () __attribute__ ((__nonnull__ (1, 4))); > >extern unsigned long int strtoul_l (const char *__restrict __nptr, > char **__restrict __endptr, > int __base, __locale_t __loc) > throw () __attribute__ ((__nonnull__ (1, 4))); > >__extension__ >extern long long int strtoll_l (const char *__restrict __nptr, > char **__restrict __endptr, int __base, > __locale_t __loc) > throw () __attribute__ ((__nonnull__ (1, 4))); > >__extension__ >extern unsigned long long int strtoull_l (const char *__restrict __nptr, > char **__restrict __endptr, > int __base, __locale_t __loc) > throw () __attribute__ ((__nonnull__ (1, 4))); > >extern double strtod_l (const char *__restrict __nptr, > char **__restrict __endptr, __locale_t __loc) > throw () __attribute__ ((__nonnull__ (1, 3))); > >extern float strtof_l (const char *__restrict __nptr, > char **__restrict __endptr, __locale_t __loc) > throw () __attribute__ ((__nonnull__ (1, 3))); > >extern long double strtold_l (const char *__restrict __nptr, > char **__restrict __endptr, > __locale_t __loc) > throw () __attribute__ ((__nonnull__ (1, 3))); > > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) atoi (const char *__nptr) throw () >{ > return (int) strtol (__nptr, (char **) __null, 10); >} >extern __inline __attribute__ ((__gnu_inline__)) long int >__attribute__ ((__leaf__)) atol (const char *__nptr) throw () >{ > return strtol (__nptr, (char **) __null, 10); >} > > > > >__extension__ extern __inline __attribute__ ((__gnu_inline__)) long long int >__attribute__ ((__leaf__)) atoll (const char *__nptr) throw () >{ > return strtoll (__nptr, (char **) __null, 10); >} ># 305 "/usr/include/stdlib.h" 3 4 >extern char *l64a (long int __n) throw () ; > > >extern long int a64l (const char *__s) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; > > > > ># 1 "/usr/include/sys/types.h" 1 3 4 ># 27 "/usr/include/sys/types.h" 3 4 >extern "C" { > > > > > >typedef __u_char u_char; >typedef __u_short u_short; >typedef __u_int u_int; >typedef __u_long u_long; >typedef __quad_t quad_t; >typedef __u_quad_t u_quad_t; >typedef __fsid_t fsid_t; > > > > >typedef __loff_t loff_t; > > > >typedef __ino_t ino_t; > > > > > > >typedef __ino64_t ino64_t; > > > > >typedef __dev_t dev_t; ># 70 "/usr/include/sys/types.h" 3 4 >typedef __mode_t mode_t; > > > > >typedef __nlink_t nlink_t; ># 104 "/usr/include/sys/types.h" 3 4 >typedef __id_t id_t; ># 115 "/usr/include/sys/types.h" 3 4 >typedef __daddr_t daddr_t; >typedef __caddr_t caddr_t; > > > > > >typedef __key_t key_t; ># 132 "/usr/include/sys/types.h" 3 4 ># 1 "/usr/include/time.h" 1 3 4 ># 57 "/usr/include/time.h" 3 4 > > >typedef __clock_t clock_t; ># 73 "/usr/include/time.h" 3 4 > > >typedef __time_t time_t; ># 91 "/usr/include/time.h" 3 4 >typedef __clockid_t clockid_t; ># 103 "/usr/include/time.h" 3 4 >typedef __timer_t timer_t; ># 133 "/usr/include/sys/types.h" 2 3 4 > > > > > > > >typedef __suseconds_t suseconds_t; > > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 147 "/usr/include/sys/types.h" 2 3 4 > > > >typedef unsigned long int ulong; >typedef unsigned short int ushort; >typedef unsigned int uint; ># 194 "/usr/include/sys/types.h" 3 4 >typedef int int8_t __attribute__ ((__mode__ (__QI__))); >typedef int int16_t __attribute__ ((__mode__ (__HI__))); >typedef int int32_t __attribute__ ((__mode__ (__SI__))); >typedef int int64_t __attribute__ ((__mode__ (__DI__))); > > >typedef unsigned int u_int8_t __attribute__ ((__mode__ (__QI__))); >typedef unsigned int u_int16_t __attribute__ ((__mode__ (__HI__))); >typedef unsigned int u_int32_t __attribute__ ((__mode__ (__SI__))); >typedef unsigned int u_int64_t __attribute__ ((__mode__ (__DI__))); > >typedef int register_t __attribute__ ((__mode__ (__word__))); ># 219 "/usr/include/sys/types.h" 3 4 ># 1 "/usr/include/sys/select.h" 1 3 4 ># 30 "/usr/include/sys/select.h" 3 4 ># 1 "/usr/include/bits/select.h" 1 3 4 ># 22 "/usr/include/bits/select.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 23 "/usr/include/bits/select.h" 2 3 4 ># 31 "/usr/include/sys/select.h" 2 3 4 > > ># 1 "/usr/include/bits/sigset.h" 1 3 4 ># 22 "/usr/include/bits/sigset.h" 3 4 >typedef int __sig_atomic_t; > > > > >typedef struct > { > unsigned long int __val[(1024 / (8 * sizeof (unsigned long int)))]; > } __sigset_t; ># 34 "/usr/include/sys/select.h" 2 3 4 > > > >typedef __sigset_t sigset_t; > > > > > ># 1 "/usr/include/time.h" 1 3 4 ># 120 "/usr/include/time.h" 3 4 >struct timespec > { > __time_t tv_sec; > __syscall_slong_t tv_nsec; > }; ># 44 "/usr/include/sys/select.h" 2 3 4 > ># 1 "/usr/include/bits/time.h" 1 3 4 ># 30 "/usr/include/bits/time.h" 3 4 >struct timeval > { > __time_t tv_sec; > __suseconds_t tv_usec; > }; ># 46 "/usr/include/sys/select.h" 2 3 4 ># 54 "/usr/include/sys/select.h" 3 4 >typedef long int __fd_mask; ># 64 "/usr/include/sys/select.h" 3 4 >typedef struct > { > > > > __fd_mask fds_bits[1024 / (8 * (int) sizeof (__fd_mask))]; > > > > > > } fd_set; > > > > > > >typedef __fd_mask fd_mask; ># 96 "/usr/include/sys/select.h" 3 4 >extern "C" { ># 106 "/usr/include/sys/select.h" 3 4 >extern int select (int __nfds, fd_set *__restrict __readfds, > fd_set *__restrict __writefds, > fd_set *__restrict __exceptfds, > struct timeval *__restrict __timeout); ># 118 "/usr/include/sys/select.h" 3 4 >extern int pselect (int __nfds, fd_set *__restrict __readfds, > fd_set *__restrict __writefds, > fd_set *__restrict __exceptfds, > const struct timespec *__restrict __timeout, > const __sigset_t *__restrict __sigmask); ># 131 "/usr/include/sys/select.h" 3 4 >} ># 220 "/usr/include/sys/types.h" 2 3 4 > > ># 1 "/usr/include/sys/sysmacros.h" 1 3 4 ># 24 "/usr/include/sys/sysmacros.h" 3 4 >extern "C" { > >__extension__ >extern unsigned int gnu_dev_major (unsigned long long int __dev) > throw () __attribute__ ((__const__)); >__extension__ >extern unsigned int gnu_dev_minor (unsigned long long int __dev) > throw () __attribute__ ((__const__)); >__extension__ >extern unsigned long long int gnu_dev_makedev (unsigned int __major, > unsigned int __minor) > throw () __attribute__ ((__const__)); > > >__extension__ extern __inline __attribute__ ((__gnu_inline__)) __attribute__ ((__const__)) unsigned int >__attribute__ ((__leaf__)) gnu_dev_major (unsigned long long int __dev) throw () >{ > return ((__dev >> 8) & 0xfff) | ((unsigned int) (__dev >> 32) & ~0xfff); >} > >__extension__ extern __inline __attribute__ ((__gnu_inline__)) __attribute__ ((__const__)) unsigned int >__attribute__ ((__leaf__)) gnu_dev_minor (unsigned long long int __dev) throw () >{ > return (__dev & 0xff) | ((unsigned int) (__dev >> 12) & ~0xff); >} > >__extension__ extern __inline __attribute__ ((__gnu_inline__)) __attribute__ ((__const__)) unsigned long long int >__attribute__ ((__leaf__)) gnu_dev_makedev (unsigned int __major, unsigned int __minor) throw () >{ > return ((__minor & 0xff) | ((__major & 0xfff) << 8) > | (((unsigned long long int) (__minor & ~0xff)) << 12) > | (((unsigned long long int) (__major & ~0xfff)) << 32)); >} > >} ># 223 "/usr/include/sys/types.h" 2 3 4 > > > > > >typedef __blksize_t blksize_t; > > > > > > >typedef __blkcnt_t blkcnt_t; > > > >typedef __fsblkcnt_t fsblkcnt_t; > > > >typedef __fsfilcnt_t fsfilcnt_t; ># 262 "/usr/include/sys/types.h" 3 4 >typedef __blkcnt64_t blkcnt64_t; >typedef __fsblkcnt64_t fsblkcnt64_t; >typedef __fsfilcnt64_t fsfilcnt64_t; > > > > > ># 1 "/usr/include/bits/pthreadtypes.h" 1 3 4 ># 21 "/usr/include/bits/pthreadtypes.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 22 "/usr/include/bits/pthreadtypes.h" 2 3 4 ># 60 "/usr/include/bits/pthreadtypes.h" 3 4 >typedef unsigned long int pthread_t; > > >union pthread_attr_t >{ > char __size[56]; > long int __align; >}; > >typedef union pthread_attr_t pthread_attr_t; > > > > > >typedef struct __pthread_internal_list >{ > struct __pthread_internal_list *__prev; > struct __pthread_internal_list *__next; >} __pthread_list_t; ># 90 "/usr/include/bits/pthreadtypes.h" 3 4 >typedef union >{ > struct __pthread_mutex_s > { > int __lock; > unsigned int __count; > int __owner; > > unsigned int __nusers; > > > > int __kind; > > short __spins; > short __elision; > __pthread_list_t __list; ># 124 "/usr/include/bits/pthreadtypes.h" 3 4 > } __data; > char __size[40]; > long int __align; >} pthread_mutex_t; > >typedef union >{ > char __size[4]; > int __align; >} pthread_mutexattr_t; > > > > >typedef union >{ > struct > { > int __lock; > unsigned int __futex; > __extension__ unsigned long long int __total_seq; > __extension__ unsigned long long int __wakeup_seq; > __extension__ unsigned long long int __woken_seq; > void *__mutex; > unsigned int __nwaiters; > unsigned int __broadcast_seq; > } __data; > char __size[48]; > __extension__ long long int __align; >} pthread_cond_t; > >typedef union >{ > char __size[4]; > int __align; >} pthread_condattr_t; > > > >typedef unsigned int pthread_key_t; > > > >typedef int pthread_once_t; > > > > > >typedef union >{ > > struct > { > int __lock; > unsigned int __nr_readers; > unsigned int __readers_wakeup; > unsigned int __writer_wakeup; > unsigned int __nr_readers_queued; > unsigned int __nr_writers_queued; > int __writer; > int __shared; > unsigned long int __pad1; > unsigned long int __pad2; > > > unsigned int __flags; > > } __data; ># 211 "/usr/include/bits/pthreadtypes.h" 3 4 > char __size[56]; > long int __align; >} pthread_rwlock_t; > >typedef union >{ > char __size[8]; > long int __align; >} pthread_rwlockattr_t; > > > > > >typedef volatile int pthread_spinlock_t; > > > > >typedef union >{ > char __size[32]; > long int __align; >} pthread_barrier_t; > >typedef union >{ > char __size[4]; > int __align; >} pthread_barrierattr_t; ># 271 "/usr/include/sys/types.h" 2 3 4 > > >} ># 315 "/usr/include/stdlib.h" 2 3 4 > > > > > > >extern long int random (void) throw (); > > >extern void srandom (unsigned int __seed) throw (); > > > > > >extern char *initstate (unsigned int __seed, char *__statebuf, > size_t __statelen) throw () __attribute__ ((__nonnull__ (2))); > > > >extern char *setstate (char *__statebuf) throw () __attribute__ ((__nonnull__ (1))); > > > > > > > >struct random_data > { > int32_t *fptr; > int32_t *rptr; > int32_t *state; > int rand_type; > int rand_deg; > int rand_sep; > int32_t *end_ptr; > }; > >extern int random_r (struct random_data *__restrict __buf, > int32_t *__restrict __result) throw () __attribute__ ((__nonnull__ (1, 2))); > >extern int srandom_r (unsigned int __seed, struct random_data *__buf) > throw () __attribute__ ((__nonnull__ (2))); > >extern int initstate_r (unsigned int __seed, char *__restrict __statebuf, > size_t __statelen, > struct random_data *__restrict __buf) > throw () __attribute__ ((__nonnull__ (2, 4))); > >extern int setstate_r (char *__restrict __statebuf, > struct random_data *__restrict __buf) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > > > >extern int rand (void) throw (); > >extern void srand (unsigned int __seed) throw (); > > > > >extern int rand_r (unsigned int *__seed) throw (); > > > > > > > >extern double drand48 (void) throw (); >extern double erand48 (unsigned short int __xsubi[3]) throw () __attribute__ ((__nonnull__ (1))); > > >extern long int lrand48 (void) throw (); >extern long int nrand48 (unsigned short int __xsubi[3]) > throw () __attribute__ ((__nonnull__ (1))); > > >extern long int mrand48 (void) throw (); >extern long int jrand48 (unsigned short int __xsubi[3]) > throw () __attribute__ ((__nonnull__ (1))); > > >extern void srand48 (long int __seedval) throw (); >extern unsigned short int *seed48 (unsigned short int __seed16v[3]) > throw () __attribute__ ((__nonnull__ (1))); >extern void lcong48 (unsigned short int __param[7]) throw () __attribute__ ((__nonnull__ (1))); > > > > > >struct drand48_data > { > unsigned short int __x[3]; > unsigned short int __old_x[3]; > unsigned short int __c; > unsigned short int __init; > __extension__ unsigned long long int __a; > > }; > > >extern int drand48_r (struct drand48_data *__restrict __buffer, > double *__restrict __result) throw () __attribute__ ((__nonnull__ (1, 2))); >extern int erand48_r (unsigned short int __xsubi[3], > struct drand48_data *__restrict __buffer, > double *__restrict __result) throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int lrand48_r (struct drand48_data *__restrict __buffer, > long int *__restrict __result) > throw () __attribute__ ((__nonnull__ (1, 2))); >extern int nrand48_r (unsigned short int __xsubi[3], > struct drand48_data *__restrict __buffer, > long int *__restrict __result) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int mrand48_r (struct drand48_data *__restrict __buffer, > long int *__restrict __result) > throw () __attribute__ ((__nonnull__ (1, 2))); >extern int jrand48_r (unsigned short int __xsubi[3], > struct drand48_data *__restrict __buffer, > long int *__restrict __result) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int srand48_r (long int __seedval, struct drand48_data *__buffer) > throw () __attribute__ ((__nonnull__ (2))); > >extern int seed48_r (unsigned short int __seed16v[3], > struct drand48_data *__buffer) throw () __attribute__ ((__nonnull__ (1, 2))); > >extern int lcong48_r (unsigned short int __param[7], > struct drand48_data *__buffer) > throw () __attribute__ ((__nonnull__ (1, 2))); ># 466 "/usr/include/stdlib.h" 3 4 >extern void *malloc (size_t __size) throw () __attribute__ ((__malloc__)) ; > >extern void *calloc (size_t __nmemb, size_t __size) > throw () __attribute__ ((__malloc__)) ; ># 480 "/usr/include/stdlib.h" 3 4 >extern void *realloc (void *__ptr, size_t __size) > throw () __attribute__ ((__warn_unused_result__)); > >extern void free (void *__ptr) throw (); > > > > >extern void cfree (void *__ptr) throw (); > > > ># 1 "/usr/include/alloca.h" 1 3 4 ># 24 "/usr/include/alloca.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 25 "/usr/include/alloca.h" 2 3 4 > >extern "C" { > > > > > >extern void *alloca (size_t __size) throw (); > > > > > >} ># 493 "/usr/include/stdlib.h" 2 3 4 > > > > > >extern void *valloc (size_t __size) throw () __attribute__ ((__malloc__)) ; > > > > >extern int posix_memalign (void **__memptr, size_t __alignment, size_t __size) > throw () __attribute__ ((__nonnull__ (1))) ; > > > > >extern void *aligned_alloc (size_t __alignment, size_t __size) > throw () __attribute__ ((__malloc__)) __attribute__ ((__alloc_size__ (2))) ; > > > > >extern void abort (void) throw () __attribute__ ((__noreturn__)); > > > >extern int atexit (void (*__func) (void)) throw () __attribute__ ((__nonnull__ (1))); > > > > >extern "C++" int at_quick_exit (void (*__func) (void)) > throw () __asm ("at_quick_exit") __attribute__ ((__nonnull__ (1))); ># 535 "/usr/include/stdlib.h" 3 4 >extern int on_exit (void (*__func) (int __status, void *__arg), void *__arg) > throw () __attribute__ ((__nonnull__ (1))); > > > > > > >extern void exit (int __status) throw () __attribute__ ((__noreturn__)); > > > > > >extern void quick_exit (int __status) throw () __attribute__ ((__noreturn__)); > > > > > > > >extern void _Exit (int __status) throw () __attribute__ ((__noreturn__)); > > > > > > >extern char *getenv (const char *__name) throw () __attribute__ ((__nonnull__ (1))) ; > > > > > >extern char *secure_getenv (const char *__name) > throw () __attribute__ ((__nonnull__ (1))) ; > > > > > > >extern int putenv (char *__string) throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern int setenv (const char *__name, const char *__value, int __replace) > throw () __attribute__ ((__nonnull__ (2))); > > >extern int unsetenv (const char *__name) throw () __attribute__ ((__nonnull__ (1))); > > > > > > >extern int clearenv (void) throw (); ># 606 "/usr/include/stdlib.h" 3 4 >extern char *mktemp (char *__template) throw () __attribute__ ((__nonnull__ (1))); ># 620 "/usr/include/stdlib.h" 3 4 >extern int mkstemp (char *__template) __attribute__ ((__nonnull__ (1))) ; ># 630 "/usr/include/stdlib.h" 3 4 >extern int mkstemp64 (char *__template) __attribute__ ((__nonnull__ (1))) ; ># 642 "/usr/include/stdlib.h" 3 4 >extern int mkstemps (char *__template, int __suffixlen) __attribute__ ((__nonnull__ (1))) ; ># 652 "/usr/include/stdlib.h" 3 4 >extern int mkstemps64 (char *__template, int __suffixlen) > __attribute__ ((__nonnull__ (1))) ; ># 663 "/usr/include/stdlib.h" 3 4 >extern char *mkdtemp (char *__template) throw () __attribute__ ((__nonnull__ (1))) ; ># 674 "/usr/include/stdlib.h" 3 4 >extern int mkostemp (char *__template, int __flags) __attribute__ ((__nonnull__ (1))) ; ># 684 "/usr/include/stdlib.h" 3 4 >extern int mkostemp64 (char *__template, int __flags) __attribute__ ((__nonnull__ (1))) ; ># 694 "/usr/include/stdlib.h" 3 4 >extern int mkostemps (char *__template, int __suffixlen, int __flags) > __attribute__ ((__nonnull__ (1))) ; ># 706 "/usr/include/stdlib.h" 3 4 >extern int mkostemps64 (char *__template, int __suffixlen, int __flags) > __attribute__ ((__nonnull__ (1))) ; ># 717 "/usr/include/stdlib.h" 3 4 >extern int system (const char *__command) ; > > > > > > >extern char *canonicalize_file_name (const char *__name) > throw () __attribute__ ((__nonnull__ (1))) ; ># 734 "/usr/include/stdlib.h" 3 4 >extern char *realpath (const char *__restrict __name, > char *__restrict __resolved) throw () ; > > > > > > >typedef int (*__compar_fn_t) (const void *, const void *); > > >typedef __compar_fn_t comparison_fn_t; > > > >typedef int (*__compar_d_fn_t) (const void *, const void *, void *); > > > > > >extern void *bsearch (const void *__key, const void *__base, > size_t __nmemb, size_t __size, __compar_fn_t __compar) > __attribute__ ((__nonnull__ (1, 2, 5))) ; > > ># 1 "/usr/include/bits/stdlib-bsearch.h" 1 3 4 ># 19 "/usr/include/bits/stdlib-bsearch.h" 3 4 >extern __inline __attribute__ ((__gnu_inline__)) void * >bsearch (const void *__key, const void *__base, size_t __nmemb, size_t __size, > __compar_fn_t __compar) >{ > size_t __l, __u, __idx; > const void *__p; > int __comparison; > > __l = 0; > __u = __nmemb; > while (__l < __u) > { > __idx = (__l + __u) / 2; > __p = (void *) (((const char *) __base) + (__idx * __size)); > __comparison = (*__compar) (__key, __p); > if (__comparison < 0) > __u = __idx; > else if (__comparison > 0) > __l = __idx + 1; > else > return (void *) __p; > } > > return __null; >} ># 761 "/usr/include/stdlib.h" 2 3 4 > > > > >extern void qsort (void *__base, size_t __nmemb, size_t __size, > __compar_fn_t __compar) __attribute__ ((__nonnull__ (1, 4))); > >extern void qsort_r (void *__base, size_t __nmemb, size_t __size, > __compar_d_fn_t __compar, void *__arg) > __attribute__ ((__nonnull__ (1, 4))); > > > > >extern int abs (int __x) throw () __attribute__ ((__const__)) ; >extern long int labs (long int __x) throw () __attribute__ ((__const__)) ; > > > >__extension__ extern long long int llabs (long long int __x) > throw () __attribute__ ((__const__)) ; > > > > > > > >extern div_t div (int __numer, int __denom) > throw () __attribute__ ((__const__)) ; >extern ldiv_t ldiv (long int __numer, long int __denom) > throw () __attribute__ ((__const__)) ; > > > > >__extension__ extern lldiv_t lldiv (long long int __numer, > long long int __denom) > throw () __attribute__ ((__const__)) ; ># 812 "/usr/include/stdlib.h" 3 4 >extern char *ecvt (double __value, int __ndigit, int *__restrict __decpt, > int *__restrict __sign) throw () __attribute__ ((__nonnull__ (3, 4))) ; > > > > >extern char *fcvt (double __value, int __ndigit, int *__restrict __decpt, > int *__restrict __sign) throw () __attribute__ ((__nonnull__ (3, 4))) ; > > > > >extern char *gcvt (double __value, int __ndigit, char *__buf) > throw () __attribute__ ((__nonnull__ (3))) ; > > > > >extern char *qecvt (long double __value, int __ndigit, > int *__restrict __decpt, int *__restrict __sign) > throw () __attribute__ ((__nonnull__ (3, 4))) ; >extern char *qfcvt (long double __value, int __ndigit, > int *__restrict __decpt, int *__restrict __sign) > throw () __attribute__ ((__nonnull__ (3, 4))) ; >extern char *qgcvt (long double __value, int __ndigit, char *__buf) > throw () __attribute__ ((__nonnull__ (3))) ; > > > > >extern int ecvt_r (double __value, int __ndigit, int *__restrict __decpt, > int *__restrict __sign, char *__restrict __buf, > size_t __len) throw () __attribute__ ((__nonnull__ (3, 4, 5))); >extern int fcvt_r (double __value, int __ndigit, int *__restrict __decpt, > int *__restrict __sign, char *__restrict __buf, > size_t __len) throw () __attribute__ ((__nonnull__ (3, 4, 5))); > >extern int qecvt_r (long double __value, int __ndigit, > int *__restrict __decpt, int *__restrict __sign, > char *__restrict __buf, size_t __len) > throw () __attribute__ ((__nonnull__ (3, 4, 5))); >extern int qfcvt_r (long double __value, int __ndigit, > int *__restrict __decpt, int *__restrict __sign, > char *__restrict __buf, size_t __len) > throw () __attribute__ ((__nonnull__ (3, 4, 5))); > > > > > > >extern int mblen (const char *__s, size_t __n) throw (); > > >extern int mbtowc (wchar_t *__restrict __pwc, > const char *__restrict __s, size_t __n) throw (); > > >extern int wctomb (char *__s, wchar_t __wchar) throw (); > > > >extern size_t mbstowcs (wchar_t *__restrict __pwcs, > const char *__restrict __s, size_t __n) throw (); > >extern size_t wcstombs (char *__restrict __s, > const wchar_t *__restrict __pwcs, size_t __n) > throw (); ># 888 "/usr/include/stdlib.h" 3 4 >extern int rpmatch (const char *__response) throw () __attribute__ ((__nonnull__ (1))) ; ># 899 "/usr/include/stdlib.h" 3 4 >extern int getsubopt (char **__restrict __optionp, > char *const *__restrict __tokens, > char **__restrict __valuep) > throw () __attribute__ ((__nonnull__ (1, 2, 3))) ; > > > > > >extern void setkey (const char *__key) throw () __attribute__ ((__nonnull__ (1))); > > > > > > > >extern int posix_openpt (int __oflag) ; > > > > > > > >extern int grantpt (int __fd) throw (); > > > >extern int unlockpt (int __fd) throw (); > > > > >extern char *ptsname (int __fd) throw () ; > > > > > > >extern int ptsname_r (int __fd, char *__buf, size_t __buflen) > throw () __attribute__ ((__nonnull__ (2))); > > >extern int getpt (void); > > > > > > >extern int getloadavg (double __loadavg[], int __nelem) > throw () __attribute__ ((__nonnull__ (1))); > > ># 1 "/usr/include/bits/stdlib-float.h" 1 3 4 ># 24 "/usr/include/bits/stdlib-float.h" 3 4 > >extern __inline __attribute__ ((__gnu_inline__)) double >__attribute__ ((__leaf__)) atof (const char *__nptr) throw () >{ > return strtod (__nptr, (char **) __null); >} ># 956 "/usr/include/stdlib.h" 2 3 4 ># 968 "/usr/include/stdlib.h" 3 4 >} ># 73 "/usr/include/c++/4.9.0/cstdlib" 2 3 ># 114 "/usr/include/c++/4.9.0/cstdlib" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > using ::div_t; > using ::ldiv_t; > > using ::abort; > using ::abs; > using ::atexit; > > > using ::at_quick_exit; > > > using ::atof; > using ::atoi; > using ::atol; > using ::bsearch; > using ::calloc; > using ::div; > using ::exit; > using ::free; > using ::getenv; > using ::labs; > using ::ldiv; > using ::malloc; > > using ::mblen; > using ::mbstowcs; > using ::mbtowc; > > using ::qsort; > > > using ::quick_exit; > > > using ::rand; > using ::realloc; > using ::srand; > using ::strtod; > using ::strtol; > using ::strtoul; > using ::system; > > using ::wcstombs; > using ::wctomb; > > > > inline long > abs(long __i) { return __builtin_labs(__i); } > > inline ldiv_t > div(long __i, long __j) { return ldiv(__i, __j); } > > > > inline long long > abs(long long __x) { return __builtin_llabs (__x); } > > > > inline __int128 > abs(__int128 __x) { return __x >= 0 ? __x : -__x; } > > > >} ># 196 "/usr/include/c++/4.9.0/cstdlib" 3 >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > > using ::lldiv_t; > > > > > > using ::_Exit; > > > > using ::llabs; > > inline lldiv_t > div(long long __n, long long __d) > { lldiv_t __q; __q.quot = __n / __d; __q.rem = __n % __d; return __q; } > > using ::lldiv; ># 228 "/usr/include/c++/4.9.0/cstdlib" 3 > using ::atoll; > using ::strtoll; > using ::strtoull; > > using ::strtof; > using ::strtold; > > >} > >namespace std >{ > > using ::__gnu_cxx::lldiv_t; > > using ::__gnu_cxx::_Exit; > > using ::__gnu_cxx::llabs; > using ::__gnu_cxx::div; > using ::__gnu_cxx::lldiv; > > using ::__gnu_cxx::atoll; > using ::__gnu_cxx::strtof; > using ::__gnu_cxx::strtoll; > using ::__gnu_cxx::strtoull; > using ::__gnu_cxx::strtold; >} ># 16 "/usr/include/boost/config/platform/linux.hpp" 2 3 4 ># 74 "/usr/include/boost/config/platform/linux.hpp" 3 4 ># 1 "/usr/include/boost/config/posix_features.hpp" 1 3 4 ># 75 "/usr/include/boost/config/platform/linux.hpp" 2 3 4 ># 54 "/usr/include/boost/config.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/config/suffix.hpp" 1 3 4 ># 34 "/usr/include/boost/config/suffix.hpp" 3 4 ># 35 "/usr/include/boost/config/suffix.hpp" 3 ># 482 "/usr/include/boost/config/suffix.hpp" 3 >namespace boost{ > > __extension__ typedef long long long_long_type; > __extension__ typedef unsigned long long ulong_long_type; > > > > >} > > > >namespace boost{ > > __extension__ typedef __int128 int128_type; > __extension__ typedef unsigned __int128 uint128_type; > > > > >} ># 58 "/usr/include/boost/config.hpp" 2 3 4 ># 31 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/boost/detail/workaround.hpp" 1 3 4 ># 32 "/usr/include/boost/foreach.hpp" 2 3 4 ># 71 "/usr/include/boost/foreach.hpp" 3 4 ># 1 "/usr/include/boost/mpl/if.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/if.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/value_wknd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/value_wknd.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/static_cast.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/static_cast.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/workaround.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/static_cast.hpp" 2 3 4 ># 18 "/usr/include/boost/mpl/aux_/value_wknd.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/integral.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/config/integral.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/msvc.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/config/integral.hpp" 2 3 4 ># 19 "/usr/include/boost/mpl/aux_/value_wknd.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/eti.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/value_wknd.hpp" 2 3 4 ># 73 "/usr/include/boost/mpl/aux_/value_wknd.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >template< typename T > struct value_type_wknd >{ > typedef typename T::value_type type; >}; ># 87 "/usr/include/boost/mpl/aux_/value_wknd.hpp" 3 4 >}}} ># 18 "/usr/include/boost/mpl/if.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/aux_/na_spec.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/na_spec.hpp" 3 4 ># 1 "/usr/include/boost/mpl/lambda_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/lambda_fwd.hpp" 3 4 ># 1 "/usr/include/boost/mpl/void_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/void_fwd.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/adl_barrier.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/adl_barrier.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/adl.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/config/adl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/intel.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/config/adl.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/gcc.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/config/adl.hpp" 2 3 4 ># 18 "/usr/include/boost/mpl/aux_/adl_barrier.hpp" 2 3 4 ># 33 "/usr/include/boost/mpl/aux_/adl_barrier.hpp" 3 4 >namespace mpl_ { namespace aux {} } >namespace boost { namespace mpl { using namespace mpl_; >namespace aux { using namespace mpl_::aux; } >}} ># 18 "/usr/include/boost/mpl/void_fwd.hpp" 2 3 4 > >namespace mpl_ { > >struct void_; > >} >namespace boost { namespace mpl { using ::mpl_::void_; } } ># 18 "/usr/include/boost/mpl/lambda_fwd.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/na.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/na.hpp" 3 4 ># 1 "/usr/include/boost/mpl/bool.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/bool.hpp" 3 4 ># 1 "/usr/include/boost/mpl/bool_fwd.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/bool_fwd.hpp" 3 4 >namespace mpl_ { > >template< bool C_ > struct bool_; > > >typedef bool_<true> true_; >typedef bool_<false> false_; > >} > >namespace boost { namespace mpl { using ::mpl_::bool_; } } >namespace boost { namespace mpl { using ::mpl_::true_; } } >namespace boost { namespace mpl { using ::mpl_::false_; } } ># 18 "/usr/include/boost/mpl/bool.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/integral_c_tag.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/integral_c_tag.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/static_constant.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/integral_c_tag.hpp" 2 3 4 > >namespace mpl_ { >struct integral_c_tag { static const int value = 0; }; >} >namespace boost { namespace mpl { using ::mpl_::integral_c_tag; } } ># 19 "/usr/include/boost/mpl/bool.hpp" 2 3 4 > > >namespace mpl_ { > >template< bool C_ > struct bool_ >{ > static const bool value = C_; > typedef integral_c_tag tag; > typedef bool_ type; > typedef bool value_type; > operator bool() const { return this->value; } >}; > > >template< bool C_ > >bool const bool_<C_>::value; > > >} ># 18 "/usr/include/boost/mpl/aux_/na.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/na_fwd.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/na_fwd.hpp" 3 4 >namespace mpl_ { > > >struct na >{ > typedef na type; > enum { value = 0 }; >}; > >} >namespace boost { namespace mpl { using ::mpl_::na; } } ># 19 "/usr/include/boost/mpl/aux_/na.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/aux_/config/ctps.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/aux_/na.hpp" 2 3 4 > >namespace boost { namespace mpl { > >template< typename T > >struct is_na > : false_ >{ > > > >}; > >template<> >struct is_na<na> > : true_ >{ > > > >}; > >template< typename T > >struct is_not_na > : true_ >{ > > > >}; > >template<> >struct is_not_na<na> > : false_ >{ > > > >}; > > >template< typename T, typename U > struct if_na >{ > typedef T type; >}; > >template< typename U > struct if_na<na,U> >{ > typedef U type; >}; ># 93 "/usr/include/boost/mpl/aux_/na.hpp" 3 4 >}} ># 19 "/usr/include/boost/mpl/lambda_fwd.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/lambda.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/config/lambda.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/ttp.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/config/lambda.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/lambda_fwd.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/int.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/int.hpp" 3 4 ># 1 "/usr/include/boost/mpl/int_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/int_fwd.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/nttp_decl.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/nttp_decl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/nttp.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/nttp_decl.hpp" 2 3 4 ># 19 "/usr/include/boost/mpl/int_fwd.hpp" 2 3 4 > >namespace mpl_ { > >template< int N > struct int_; > >} >namespace boost { namespace mpl { using ::mpl_::int_; } } ># 18 "/usr/include/boost/mpl/int.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/cat.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/cat.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/config/config.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/cat.hpp" 2 3 4 ># 23 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 2 3 4 ># 40 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 3 4 >namespace mpl_ { > >template< int N > >struct int_ >{ > static const int value = N; > > > > > > typedef int_ type; > > typedef int value_type; > typedef integral_c_tag tag; ># 72 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 3 4 > typedef mpl_::int_< static_cast<int>((value + 1)) > next; > typedef mpl_::int_< static_cast<int>((value - 1)) > prior; > > > > > > > operator int() const { return static_cast<int>(this->value); } >}; > > >template< int N > >int const mpl_::int_< N >::value; > > >} ># 21 "/usr/include/boost/mpl/int.hpp" 2 3 4 ># 24 "/usr/include/boost/mpl/lambda_fwd.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/lambda_arity_param.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/lambda_fwd.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/template_arity_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/template_arity_fwd.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >template< typename F > struct template_arity; > >}}} ># 26 "/usr/include/boost/mpl/lambda_fwd.hpp" 2 3 4 > >namespace boost { namespace mpl { > >template< > typename T = na > , typename Tag = void_ > , typename Arity = int_< aux::template_arity<T>::value > > > > > >struct lambda; > >}} ># 19 "/usr/include/boost/mpl/aux_/na_spec.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/aux_/arity.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/arity.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/dtp.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/arity.hpp" 2 3 4 ># 23 "/usr/include/boost/mpl/aux_/na_spec.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/aux_/preprocessor/params.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/preprocessor/params.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/preprocessor.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/preprocessor/params.hpp" 2 3 4 ># 45 "/usr/include/boost/mpl/aux_/preprocessor/params.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/comma_if.hpp" 1 3 4 ># 15 "/usr/include/boost/preprocessor/comma_if.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/punctuation/comma_if.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/punctuation/comma_if.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/control/if.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/control/if.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/control/iif.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/control/if.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/logical/bool.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/control/if.hpp" 2 3 4 ># 19 "/usr/include/boost/preprocessor/punctuation/comma_if.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/facilities/empty.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/punctuation/comma_if.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/punctuation/comma.hpp" 1 3 4 ># 21 "/usr/include/boost/preprocessor/punctuation/comma_if.hpp" 2 3 4 ># 16 "/usr/include/boost/preprocessor/comma_if.hpp" 2 3 4 ># 46 "/usr/include/boost/mpl/aux_/preprocessor/params.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/repeat.hpp" 1 3 4 ># 15 "/usr/include/boost/preprocessor/repeat.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/repetition/repeat.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/repetition/repeat.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/debug/error.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/repetition/repeat.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 21 "/usr/include/boost/preprocessor/repetition/repeat.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/tuple/eat.hpp" 1 3 4 ># 22 "/usr/include/boost/preprocessor/repetition/repeat.hpp" 2 3 4 ># 16 "/usr/include/boost/preprocessor/repeat.hpp" 2 3 4 ># 47 "/usr/include/boost/mpl/aux_/preprocessor/params.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/inc.hpp" 1 3 4 ># 15 "/usr/include/boost/preprocessor/inc.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/arithmetic/inc.hpp" 1 3 4 ># 16 "/usr/include/boost/preprocessor/inc.hpp" 2 3 4 ># 48 "/usr/include/boost/mpl/aux_/preprocessor/params.hpp" 2 3 4 ># 27 "/usr/include/boost/mpl/aux_/na_spec.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessor/enum.hpp" 1 3 4 ># 28 "/usr/include/boost/mpl/aux_/na_spec.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessor/def_params_tail.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/preprocessor/def_params_tail.hpp" 3 4 ># 1 "/usr/include/boost/mpl/limits/arity.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/preprocessor/def_params_tail.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/preprocessor/logical/and.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/logical/and.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/logical/bitand.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/logical/and.hpp" 2 3 4 ># 23 "/usr/include/boost/mpl/aux_/preprocessor/def_params_tail.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/identity.hpp" 1 3 4 ># 15 "/usr/include/boost/preprocessor/identity.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/facilities/identity.hpp" 1 3 4 ># 16 "/usr/include/boost/preprocessor/identity.hpp" 2 3 4 ># 24 "/usr/include/boost/mpl/aux_/preprocessor/def_params_tail.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/empty.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/aux_/preprocessor/def_params_tail.hpp" 2 3 4 ># 66 "/usr/include/boost/mpl/aux_/preprocessor/def_params_tail.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/arithmetic/add.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/arithmetic/add.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/arithmetic/dec.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/arithmetic/add.hpp" 2 3 4 > > ># 1 "/usr/include/boost/preprocessor/control/while.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/control/while.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 21 "/usr/include/boost/preprocessor/control/while.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/list/fold_left.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/list/fold_left.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/control/while.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/list/fold_left.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 21 "/usr/include/boost/preprocessor/list/fold_left.hpp" 2 3 4 ># 41 "/usr/include/boost/preprocessor/list/fold_left.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/list/detail/fold_left.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/list/detail/fold_left.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/control/expr_iif.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/list/detail/fold_left.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/list/adt.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/list/adt.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/is_binary.hpp" 1 3 4 ># 16 "/usr/include/boost/preprocessor/detail/is_binary.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/check.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/detail/is_binary.hpp" 2 3 4 ># 19 "/usr/include/boost/preprocessor/list/adt.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/logical/compl.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/list/adt.hpp" 2 3 4 ># 20 "/usr/include/boost/preprocessor/list/detail/fold_left.hpp" 2 3 4 ># 42 "/usr/include/boost/preprocessor/list/fold_left.hpp" 2 3 4 ># 22 "/usr/include/boost/preprocessor/control/while.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/list/fold_right.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/list/fold_right.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 21 "/usr/include/boost/preprocessor/list/fold_right.hpp" 2 3 4 ># 37 "/usr/include/boost/preprocessor/list/fold_right.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/list/detail/fold_right.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/list/detail/fold_right.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/list/reverse.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/list/detail/fold_right.hpp" 2 3 4 ># 38 "/usr/include/boost/preprocessor/list/fold_right.hpp" 2 3 4 ># 23 "/usr/include/boost/preprocessor/control/while.hpp" 2 3 4 ># 48 "/usr/include/boost/preprocessor/control/while.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/control/detail/while.hpp" 1 3 4 ># 49 "/usr/include/boost/preprocessor/control/while.hpp" 2 3 4 ># 21 "/usr/include/boost/preprocessor/arithmetic/add.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/tuple/elem.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/tuple/elem.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/facilities/overload.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/facilities/overload.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/variadic/size.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/facilities/overload.hpp" 2 3 4 ># 21 "/usr/include/boost/preprocessor/tuple/elem.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/tuple/rem.hpp" 1 3 4 ># 22 "/usr/include/boost/preprocessor/tuple/elem.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/variadic/elem.hpp" 1 3 4 ># 23 "/usr/include/boost/preprocessor/tuple/elem.hpp" 2 3 4 ># 22 "/usr/include/boost/preprocessor/arithmetic/add.hpp" 2 3 4 ># 67 "/usr/include/boost/mpl/aux_/preprocessor/def_params_tail.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/arithmetic/sub.hpp" 1 3 4 ># 68 "/usr/include/boost/mpl/aux_/preprocessor/def_params_tail.hpp" 2 3 4 ># 29 "/usr/include/boost/mpl/aux_/na_spec.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/mpl/aux_/config/overload_resolution.hpp" 1 3 4 ># 36 "/usr/include/boost/mpl/aux_/na_spec.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/if.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/lambda_support.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/if.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > > > >template< > bool C > , typename T1 > , typename T2 > > >struct if_c >{ > typedef T1 type; >}; > >template< > typename T1 > , typename T2 > > >struct if_c<false,T1,T2> >{ > typedef T2 type; >}; > > > >template< > typename T1 = na > , typename T2 = na > , typename T3 = na > > >struct if_ >{ > private: > > typedef if_c< > > > > static_cast<bool>(T1::value) > > , T2 > , T3 > > almost_type_; > > public: > typedef typename almost_type_::type type; > > >}; ># 131 "/usr/include/boost/mpl/if.hpp" 3 4 >template<> struct if_< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : if_< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< if_< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef if_< na , na , na > result_; typedef if_< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< if_< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< if_< na , na , na > > : int_<-1> { }; } > >}} ># 72 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/assert.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/assert.hpp" 3 4 ># 1 "/usr/include/boost/mpl/not.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/not.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/nested_type_wknd.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/aux_/nested_type_wknd.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { >template< typename T > struct nested_type_wknd > : T::type >{ >}; >}}} ># 20 "/usr/include/boost/mpl/not.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >namespace aux { > >template< long C_ > >struct not_impl > : bool_<!C_> >{ >}; > >} > > >template< > typename T = na > > >struct not_ > : aux::not_impl< > ::boost::mpl::aux::nested_type_wknd<T>::value > > >{ > >}; > >template<> struct not_< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : not_< T1 > { }; }; template< typename Tag > struct lambda< not_< na > , Tag , int_<-1> > { typedef false_ is_le; typedef not_< na > result_; typedef not_< na > type; }; namespace aux { template< typename T1 > struct template_arity< not_< T1 > > : int_<1> { }; template<> struct template_arity< not_< na > > : int_<-1> { }; } > >}} ># 18 "/usr/include/boost/mpl/assert.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/aux_/yes_no.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/yes_no.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/arrays.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/yes_no.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { namespace aux { > >typedef char (&no_tag)[1]; >typedef char (&yes_tag)[2]; > >template< bool C_ > struct yes_no_tag >{ > typedef no_tag type; >}; > >template<> struct yes_no_tag<true> >{ > typedef yes_tag type; >}; > > >template< long n > struct weighted_tag >{ > > typedef char (&type)[n]; > > > > >}; ># 56 "/usr/include/boost/mpl/aux_/yes_no.hpp" 3 4 >}}} ># 21 "/usr/include/boost/mpl/assert.hpp" 2 3 4 ># 29 "/usr/include/boost/mpl/assert.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/pp_counter.hpp" 1 3 4 ># 30 "/usr/include/boost/mpl/assert.hpp" 2 3 4 ># 65 "/usr/include/boost/mpl/assert.hpp" 3 4 >namespace mpl_ { > >struct failed {}; ># 78 "/usr/include/boost/mpl/assert.hpp" 3 4 >template< bool C > struct assert { typedef void* type; }; >template<> struct assert<false> { typedef assert type; }; > >template< bool C > >int assertion_failed( typename assert<C>::type ); > >template< bool C > >struct assertion >{ > static int failed( assert<false> ); >}; > >template<> >struct assertion<true> >{ > static int failed( void* ); >}; > >struct assert_ >{ > > template< typename T1, typename T2 = na, typename T3 = na, typename T4 = na > struct types {}; > > static assert_ const arg; > enum relations { equal = 1, not_equal, greater, greater_equal, less, less_equal }; >}; ># 126 "/usr/include/boost/mpl/assert.hpp" 3 4 >boost::mpl::aux::weighted_tag<1>::type operator==( assert_, assert_ ); >boost::mpl::aux::weighted_tag<2>::type operator!=( assert_, assert_ ); >boost::mpl::aux::weighted_tag<3>::type operator>( assert_, assert_ ); >boost::mpl::aux::weighted_tag<4>::type operator>=( assert_, assert_ ); >boost::mpl::aux::weighted_tag<5>::type operator<( assert_, assert_ ); >boost::mpl::aux::weighted_tag<6>::type operator<=( assert_, assert_ ); > >template< assert_::relations r, long x, long y > struct assert_relation {}; ># 170 "/usr/include/boost/mpl/assert.hpp" 3 4 >template< bool > struct assert_arg_pred_impl { typedef int type; }; >template<> struct assert_arg_pred_impl<true> { typedef void* type; }; > >template< typename P > struct assert_arg_pred >{ > typedef typename P::type p_type; > typedef typename assert_arg_pred_impl< p_type::value >::type type; >}; > >template< typename P > struct assert_arg_pred_not >{ > typedef typename P::type p_type; > enum { p = !p_type::value }; > typedef typename assert_arg_pred_impl<p>::type type; >}; > >template< typename Pred > >failed ************ (Pred::************ > assert_arg( void (*)(Pred), typename assert_arg_pred<Pred>::type ) > ); > >template< typename Pred > >failed ************ (boost::mpl::not_<Pred>::************ > assert_not_arg( void (*)(Pred), typename assert_arg_pred_not<Pred>::type ) > ); > >template< typename Pred > >assert<false> >assert_arg( void (*)(Pred), typename assert_arg_pred_not<Pred>::type ); > >template< typename Pred > >assert<false> >assert_not_arg( void (*)(Pred), typename assert_arg_pred<Pred>::type ); ># 245 "/usr/include/boost/mpl/assert.hpp" 3 4 >} ># 73 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/logical.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/logical.hpp" 3 4 ># 1 "/usr/include/boost/mpl/or.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/or.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/use_preprocessed.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/or.hpp" 2 3 4 ># 43 "/usr/include/boost/mpl/or.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 16 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/compiler.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/preprocessor/stringize.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/or.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/or.hpp" 3 4 >namespace boost { namespace mpl { > >namespace aux { > >template< bool C_, typename T1, typename T2, typename T3, typename T4 > >struct or_impl > : true_ >{ >}; > >template< typename T1, typename T2, typename T3, typename T4 > >struct or_impl< false,T1,T2,T3,T4 > > : or_impl< > ::boost::mpl::aux::nested_type_wknd<T1>::value > , T2, T3, T4 > , false_ > > >{ >}; > >template<> >struct or_impl< > false > , false_, false_, false_, false_ > > > : false_ >{ >}; > >} > >template< > typename T1 = na > , typename T2 = na > , typename T3 = false_, typename T4 = false_, typename T5 = false_ > > >struct or_ > > : aux::or_impl< > ::boost::mpl::aux::nested_type_wknd<T1>::value > , T2, T3, T4, T5 > > > >{ > > > > > >}; > >template<> struct or_< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : or_< T1 , T2 > { }; }; template< typename Tag > struct lambda< or_< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef or_< na , na > result_; typedef or_< na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct template_arity< or_< T1 , T2 , T3 , T4 , T5 > > : int_<5> { }; template<> struct template_arity< or_< na , na > > : int_<-1> { }; } > > > > > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 44 "/usr/include/boost/mpl/or.hpp" 2 3 4 ># 18 "/usr/include/boost/mpl/logical.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/and.hpp" 1 3 4 ># 42 "/usr/include/boost/mpl/and.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/and.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/and.hpp" 3 4 >namespace boost { namespace mpl { > >namespace aux { > >template< bool C_, typename T1, typename T2, typename T3, typename T4 > >struct and_impl > : false_ >{ >}; > >template< typename T1, typename T2, typename T3, typename T4 > >struct and_impl< true,T1,T2,T3,T4 > > : and_impl< > ::boost::mpl::aux::nested_type_wknd<T1>::value > , T2, T3, T4 > , true_ > > >{ >}; > >template<> >struct and_impl< > true > , true_, true_, true_, true_ > > > : true_ >{ >}; > >} > >template< > typename T1 = na > , typename T2 = na > , typename T3 = true_, typename T4 = true_, typename T5 = true_ > > >struct and_ > > : aux::and_impl< > ::boost::mpl::aux::nested_type_wknd<T1>::value > , T2, T3, T4, T5 > > > >{ > > > > > >}; > >template<> struct and_< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : and_< T1 , T2 > { }; }; template< typename Tag > struct lambda< and_< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef and_< na , na > result_; typedef and_< na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct template_arity< and_< T1 , T2 , T3 , T4 , T5 > > : int_<5> { }; template<> struct template_arity< and_< na , na > > : int_<-1> { }; } > > > > > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 43 "/usr/include/boost/mpl/and.hpp" 2 3 4 ># 19 "/usr/include/boost/mpl/logical.hpp" 2 3 4 ># 74 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/eval_if.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/eval_if.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename C = na > , typename F1 = na > , typename F2 = na > > >struct eval_if > > > > >{ > typedef typename if_<C,F1,F2>::type f_; > typedef typename f_::type type; > > > > > >}; > > > >template< > bool C > , typename F1 > , typename F2 > > >struct eval_if_c > > > > >{ > typedef typename if_c<C,F1,F2>::type f_; > typedef typename f_::type type; > > > > >}; > >template<> struct eval_if< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : eval_if< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< eval_if< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef eval_if< na , na , na > result_; typedef eval_if< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< eval_if< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< eval_if< na , na , na > > : int_<-1> { }; } > >}} ># 75 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/boost/noncopyable.hpp" 1 3 4 ># 14 "/usr/include/boost/noncopyable.hpp" 3 4 >namespace boost { > > > > > > >namespace noncopyable_ >{ > class noncopyable > { > protected: > > constexpr noncopyable() = default; > ~noncopyable() = default; > > > > > > noncopyable( const noncopyable& ) = delete; > noncopyable& operator=( const noncopyable& ) = delete; > > > > > > }; >} > >typedef noncopyable_::noncopyable noncopyable; > >} ># 76 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/boost/range/end.hpp" 1 3 4 ># 18 "/usr/include/boost/range/end.hpp" 3 4 ># 1 "/usr/include/boost/range/config.hpp" 1 3 4 ># 19 "/usr/include/boost/range/end.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/range/detail/implementation_help.hpp" 1 3 4 ># 15 "/usr/include/boost/range/detail/implementation_help.hpp" 3 4 ># 1 "/usr/include/boost/range/detail/common.hpp" 1 3 4 ># 19 "/usr/include/boost/range/detail/common.hpp" 3 4 ># 1 "/usr/include/boost/range/detail/sfinae.hpp" 1 3 4 ># 15 "/usr/include/boost/range/detail/sfinae.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_array.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/is_array.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/config.hpp" 1 3 4 ># 18 "/usr/include/boost/type_traits/is_array.hpp" 2 3 4 ># 27 "/usr/include/boost/type_traits/is_array.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/integral_constant.hpp" 1 3 4 ># 11 "/usr/include/boost/type_traits/integral_constant.hpp" 3 4 ># 1 "/usr/include/boost/mpl/integral_c.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/integral_c.hpp" 3 4 ># 1 "/usr/include/boost/mpl/integral_c_fwd.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/integral_c_fwd.hpp" 3 4 >namespace mpl_ { > > > > > >template< typename T, T N > struct integral_c; > > >} >namespace boost { namespace mpl { using ::mpl_::integral_c; } } ># 18 "/usr/include/boost/mpl/integral_c.hpp" 2 3 4 ># 32 "/usr/include/boost/mpl/integral_c.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 1 3 4 ># 40 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 3 4 >namespace mpl_ { > >template< typename T, T N > >struct integral_c >{ > static const T value = N; > > > > > > typedef integral_c type; > > typedef T value_type; > typedef integral_c_tag tag; ># 72 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 3 4 > typedef integral_c< T, static_cast<T>((value + 1)) > next; > typedef integral_c< T, static_cast<T>((value - 1)) > prior; > > > > > > > operator T() const { return static_cast<T>(this->value); } >}; > > >template< typename T, T N > >T const integral_c< T, N >::value; > > >} ># 33 "/usr/include/boost/mpl/integral_c.hpp" 2 3 4 > > > > >namespace mpl_ { > >template< bool C > >struct integral_c<bool, C> >{ > static const bool value = C; > typedef integral_c_tag tag; > typedef integral_c type; > typedef bool value_type; > operator bool() const { return this->value; } >}; >} ># 12 "/usr/include/boost/type_traits/integral_constant.hpp" 2 3 4 > >namespace boost{ > > > > >template <class T, T val> > >struct integral_constant : public mpl::integral_c<T, val> >{ > typedef integral_constant<T,val> type; >}; > >template<> struct integral_constant<bool,true> : public mpl::true_ >{ > > > > > > > > typedef integral_constant<bool,true> type; >}; >template<> struct integral_constant<bool,false> : public mpl::false_ >{ > > > > > > > > typedef integral_constant<bool,false> type; >}; > >typedef integral_constant<bool,true> true_type; >typedef integral_constant<bool,false> false_type; > >} ># 16 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 28 "/usr/include/boost/type_traits/is_array.hpp" 2 3 4 > >namespace boost { > > > > >template< typename T > struct is_array : public ::boost::integral_constant<bool,false> { public: }; > >template< typename T, std::size_t N > struct is_array< T[N] > : public ::boost::integral_constant<bool,true> { public: }; >template< typename T, std::size_t N > struct is_array< T const[N] > : public ::boost::integral_constant<bool,true> { public: }; >template< typename T, std::size_t N > struct is_array< T volatile[N] > : public ::boost::integral_constant<bool,true> { public: }; >template< typename T, std::size_t N > struct is_array< T const volatile[N] > : public ::boost::integral_constant<bool,true> { public: }; > >template< typename T > struct is_array< T[] > : public ::boost::integral_constant<bool,true> { public: }; >template< typename T > struct is_array< T const[] > : public ::boost::integral_constant<bool,true> { public: }; >template< typename T > struct is_array< T volatile[] > : public ::boost::integral_constant<bool,true> { public: }; >template< typename T > struct is_array< T const volatile[] > : public ::boost::integral_constant<bool,true> { public: }; ># 87 "/usr/include/boost/type_traits/is_array.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 90 "/usr/include/boost/type_traits/is_array.hpp" 2 3 4 ># 16 "/usr/include/boost/range/detail/sfinae.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/detail/yes_no_type.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/yes_no_type.hpp" 3 4 >namespace boost { >namespace type_traits { > >typedef char yes_type; >struct no_type >{ > char padding[8]; >}; > >} >} ># 17 "/usr/include/boost/range/detail/sfinae.hpp" 2 3 4 > > > >namespace boost >{ > namespace range_detail > { > using type_traits::yes_type; > using type_traits::no_type; > > > > > > yes_type is_string_impl( const char* const ); > yes_type is_string_impl( const wchar_t* const ); > no_type is_string_impl( ... ); > > template< std::size_t sz > > yes_type is_char_array_impl( char (&boost_range_array)[sz] ); > template< std::size_t sz > > yes_type is_char_array_impl( const char (&boost_range_array)[sz] ); > no_type is_char_array_impl( ... ); > > template< std::size_t sz > > yes_type is_wchar_t_array_impl( wchar_t (&boost_range_array)[sz] ); > template< std::size_t sz > > yes_type is_wchar_t_array_impl( const wchar_t (&boost_range_array)[sz] ); > no_type is_wchar_t_array_impl( ... ); > > yes_type is_char_ptr_impl( char* const ); > no_type is_char_ptr_impl( ... ); > > yes_type is_const_char_ptr_impl( const char* const ); > no_type is_const_char_ptr_impl( ... ); > > yes_type is_wchar_t_ptr_impl( wchar_t* const ); > no_type is_wchar_t_ptr_impl( ... ); > > yes_type is_const_wchar_t_ptr_impl( const wchar_t* const ); > no_type is_const_wchar_t_ptr_impl( ... ); > > > > > > template< typename Iterator > > yes_type is_pair_impl( const std::pair<Iterator,Iterator>* ); > no_type is_pair_impl( ... ); > > > > > > struct char_or_wchar_t_array_tag {}; > > } > >} ># 20 "/usr/include/boost/range/detail/common.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_void.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/is_void.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/is_void.hpp" 2 3 4 > >namespace boost { > > > > > >template< typename T > struct is_void : public ::boost::integral_constant<bool,false> { public: }; >template<> struct is_void< void > : public ::boost::integral_constant<bool,true> { public: }; > > >template<> struct is_void< void const > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_void< void volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_void< void const volatile > : public ::boost::integral_constant<bool,true> { public: }; > > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 37 "/usr/include/boost/type_traits/is_void.hpp" 2 3 4 ># 21 "/usr/include/boost/range/detail/common.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/detail/ice_or.hpp" 1 3 4 ># 13 "/usr/include/boost/type_traits/detail/ice_or.hpp" 3 4 >namespace boost { >namespace type_traits { > >template <bool b1, bool b2, bool b3 = false, bool b4 = false, bool b5 = false, bool b6 = false, bool b7 = false> >struct ice_or; > >template <bool b1, bool b2, bool b3, bool b4, bool b5, bool b6, bool b7> >struct ice_or >{ > static const bool value = true; >}; > >template <> >struct ice_or<false, false, false, false, false, false, false> >{ > static const bool value = false; >}; > >} >} ># 22 "/usr/include/boost/range/detail/common.hpp" 2 3 4 ># 30 "/usr/include/boost/range/detail/common.hpp" 3 4 >namespace boost >{ > namespace range_detail > { ># 47 "/usr/include/boost/range/detail/common.hpp" 3 4 > typedef mpl::int_<1>::type std_container_; > typedef mpl::int_<2>::type std_pair_; > typedef mpl::int_<3>::type const_std_pair_; > typedef mpl::int_<4>::type array_; > typedef mpl::int_<5>::type const_array_; > typedef mpl::int_<6>::type char_array_; > typedef mpl::int_<7>::type wchar_t_array_; > typedef mpl::int_<8>::type char_ptr_; > typedef mpl::int_<9>::type const_char_ptr_; > typedef mpl::int_<10>::type wchar_t_ptr_; > typedef mpl::int_<11>::type const_wchar_t_ptr_; > typedef mpl::int_<12>::type string_; > > template< typename C > > struct range_helper > { > static C* c; > static C ptr; > > static const bool is_pair_ = sizeof( boost::range_detail::is_pair_impl( c ) ) == sizeof( yes_type ); > static const bool is_char_ptr_ = sizeof( boost::range_detail::is_char_ptr_impl( ptr ) ) == sizeof( yes_type ); > static const bool is_const_char_ptr_ = sizeof( boost::range_detail::is_const_char_ptr_impl( ptr ) ) == sizeof( yes_type ); > static const bool is_wchar_t_ptr_ = sizeof( boost::range_detail::is_wchar_t_ptr_impl( ptr ) ) == sizeof( yes_type ); > static const bool is_const_wchar_t_ptr_ = sizeof( boost::range_detail::is_const_wchar_t_ptr_impl( ptr ) ) == sizeof( yes_type ); > static const bool is_char_array_ = sizeof( boost::range_detail::is_char_array_impl( ptr ) ) == sizeof( yes_type ); > static const bool is_wchar_t_array_ = sizeof( boost::range_detail::is_wchar_t_array_impl( ptr ) ) == sizeof( yes_type ); > static const bool is_string_ = (boost::type_traits::ice_or<is_const_char_ptr_, is_const_wchar_t_ptr_>::value ); > static const bool is_array_ = boost::is_array<C>::value; > > }; > > template< typename C > > class range > { > typedef typename boost::mpl::if_c< ::boost::range_detail::range_helper<C>::is_pair_, > boost::range_detail::std_pair_, > void >::type pair_t; > typedef typename boost::mpl::if_c< ::boost::range_detail::range_helper<C>::is_array_, > boost::range_detail::array_, > pair_t >::type array_t; > typedef typename boost::mpl::if_c< ::boost::range_detail::range_helper<C>::is_string_, > boost::range_detail::string_, > array_t >::type string_t; > typedef typename boost::mpl::if_c< ::boost::range_detail::range_helper<C>::is_const_char_ptr_, > boost::range_detail::const_char_ptr_, > string_t >::type const_char_ptr_t; > typedef typename boost::mpl::if_c< ::boost::range_detail::range_helper<C>::is_char_ptr_, > boost::range_detail::char_ptr_, > const_char_ptr_t >::type char_ptr_t; > typedef typename boost::mpl::if_c< ::boost::range_detail::range_helper<C>::is_const_wchar_t_ptr_, > boost::range_detail::const_wchar_t_ptr_, > char_ptr_t >::type const_wchar_ptr_t; > typedef typename boost::mpl::if_c< ::boost::range_detail::range_helper<C>::is_wchar_t_ptr_, > boost::range_detail::wchar_t_ptr_, > const_wchar_ptr_t >::type wchar_ptr_t; > typedef typename boost::mpl::if_c< ::boost::range_detail::range_helper<C>::is_wchar_t_array_, > boost::range_detail::wchar_t_array_, > wchar_ptr_t >::type wchar_array_t; > typedef typename boost::mpl::if_c< ::boost::range_detail::range_helper<C>::is_char_array_, > boost::range_detail::char_array_, > wchar_array_t >::type char_array_t; > public: > typedef typename boost::mpl::if_c< ::boost::is_void<char_array_t>::value, > boost::range_detail::std_container_, > char_array_t >::type type; > }; > } >} ># 16 "/usr/include/boost/range/detail/implementation_help.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_same.hpp" 1 3 4 ># 31 "/usr/include/boost/type_traits/is_same.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 32 "/usr/include/boost/type_traits/is_same.hpp" 2 3 4 > >namespace boost { > > > >template< typename T, typename U > struct is_same : public ::boost::integral_constant<bool,false> { public: }; >template< typename T > struct is_same< T,T > : public ::boost::integral_constant<bool,true> { public: }; ># 98 "/usr/include/boost/type_traits/is_same.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 101 "/usr/include/boost/type_traits/is_same.hpp" 2 3 4 ># 17 "/usr/include/boost/range/detail/implementation_help.hpp" 2 3 4 > ># 1 "/usr/include/string.h" 1 3 4 ># 27 "/usr/include/string.h" 3 4 >extern "C" { > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 33 "/usr/include/string.h" 2 3 4 ># 42 "/usr/include/string.h" 3 4 >extern void *memcpy (void *__restrict __dest, const void *__restrict __src, > size_t __n) throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern void *memmove (void *__dest, const void *__src, size_t __n) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > > > >extern void *memccpy (void *__restrict __dest, const void *__restrict __src, > int __c, size_t __n) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > > >extern void *memset (void *__s, int __c, size_t __n) throw () __attribute__ ((__nonnull__ (1))); > > >extern int memcmp (const void *__s1, const void *__s2, size_t __n) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > > >extern "C++" >{ >extern void *memchr (void *__s, int __c, size_t __n) > throw () __asm ("memchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); >extern const void *memchr (const void *__s, int __c, size_t __n) > throw () __asm ("memchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); > > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) void * >memchr (void *__s, int __c, size_t __n) throw () >{ > return __builtin_memchr (__s, __c, __n); >} > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) const void * >memchr (const void *__s, int __c, size_t __n) throw () >{ > return __builtin_memchr (__s, __c, __n); >} > >} ># 101 "/usr/include/string.h" 3 4 >extern "C++" void *rawmemchr (void *__s, int __c) > throw () __asm ("rawmemchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); >extern "C++" const void *rawmemchr (const void *__s, int __c) > throw () __asm ("rawmemchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); > > > > > > > >extern "C++" void *memrchr (void *__s, int __c, size_t __n) > throw () __asm ("memrchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); >extern "C++" const void *memrchr (const void *__s, int __c, size_t __n) > throw () __asm ("memrchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); ># 125 "/usr/include/string.h" 3 4 >extern char *strcpy (char *__restrict __dest, const char *__restrict __src) > throw () __attribute__ ((__nonnull__ (1, 2))); > >extern char *strncpy (char *__restrict __dest, > const char *__restrict __src, size_t __n) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern char *strcat (char *__restrict __dest, const char *__restrict __src) > throw () __attribute__ ((__nonnull__ (1, 2))); > >extern char *strncat (char *__restrict __dest, const char *__restrict __src, > size_t __n) throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int strcmp (const char *__s1, const char *__s2) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > >extern int strncmp (const char *__s1, const char *__s2, size_t __n) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > >extern int strcoll (const char *__s1, const char *__s2) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > >extern size_t strxfrm (char *__restrict __dest, > const char *__restrict __src, size_t __n) > throw () __attribute__ ((__nonnull__ (2))); ># 162 "/usr/include/string.h" 3 4 >extern int strcoll_l (const char *__s1, const char *__s2, __locale_t __l) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2, 3))); > >extern size_t strxfrm_l (char *__dest, const char *__src, size_t __n, > __locale_t __l) throw () __attribute__ ((__nonnull__ (2, 4))); > > > > > >extern char *strdup (const char *__s) > throw () __attribute__ ((__malloc__)) __attribute__ ((__nonnull__ (1))); > > > > > > >extern char *strndup (const char *__string, size_t __n) > throw () __attribute__ ((__malloc__)) __attribute__ ((__nonnull__ (1))); ># 207 "/usr/include/string.h" 3 4 > > > >extern "C++" >{ >extern char *strchr (char *__s, int __c) > throw () __asm ("strchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); >extern const char *strchr (const char *__s, int __c) > throw () __asm ("strchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); > > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) char * >strchr (char *__s, int __c) throw () >{ > return __builtin_strchr (__s, __c); >} > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) const char * >strchr (const char *__s, int __c) throw () >{ > return __builtin_strchr (__s, __c); >} > >} > > > > > > >extern "C++" >{ >extern char *strrchr (char *__s, int __c) > throw () __asm ("strrchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); >extern const char *strrchr (const char *__s, int __c) > throw () __asm ("strrchr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); > > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) char * >strrchr (char *__s, int __c) throw () >{ > return __builtin_strrchr (__s, __c); >} > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) const char * >strrchr (const char *__s, int __c) throw () >{ > return __builtin_strrchr (__s, __c); >} > >} ># 268 "/usr/include/string.h" 3 4 >extern "C++" char *strchrnul (char *__s, int __c) > throw () __asm ("strchrnul") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); >extern "C++" const char *strchrnul (const char *__s, int __c) > throw () __asm ("strchrnul") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); ># 281 "/usr/include/string.h" 3 4 >extern size_t strcspn (const char *__s, const char *__reject) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > >extern size_t strspn (const char *__s, const char *__accept) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > >extern "C++" >{ >extern char *strpbrk (char *__s, const char *__accept) > throw () __asm ("strpbrk") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); >extern const char *strpbrk (const char *__s, const char *__accept) > throw () __asm ("strpbrk") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) char * >strpbrk (char *__s, const char *__accept) throw () >{ > return __builtin_strpbrk (__s, __accept); >} > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) const char * >strpbrk (const char *__s, const char *__accept) throw () >{ > return __builtin_strpbrk (__s, __accept); >} > >} > > > > > > >extern "C++" >{ >extern char *strstr (char *__haystack, const char *__needle) > throw () __asm ("strstr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); >extern const char *strstr (const char *__haystack, const char *__needle) > throw () __asm ("strstr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) char * >strstr (char *__haystack, const char *__needle) throw () >{ > return __builtin_strstr (__haystack, __needle); >} > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) const char * >strstr (const char *__haystack, const char *__needle) throw () >{ > return __builtin_strstr (__haystack, __needle); >} > >} > > > > > > > >extern char *strtok (char *__restrict __s, const char *__restrict __delim) > throw () __attribute__ ((__nonnull__ (2))); > > > > >extern char *__strtok_r (char *__restrict __s, > const char *__restrict __delim, > char **__restrict __save_ptr) > throw () __attribute__ ((__nonnull__ (2, 3))); > >extern char *strtok_r (char *__restrict __s, const char *__restrict __delim, > char **__restrict __save_ptr) > throw () __attribute__ ((__nonnull__ (2, 3))); > > > > > >extern "C++" char *strcasestr (char *__haystack, const char *__needle) > throw () __asm ("strcasestr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); >extern "C++" const char *strcasestr (const char *__haystack, > const char *__needle) > throw () __asm ("strcasestr") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); ># 378 "/usr/include/string.h" 3 4 >extern void *memmem (const void *__haystack, size_t __haystacklen, > const void *__needle, size_t __needlelen) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 3))); > > > >extern void *__mempcpy (void *__restrict __dest, > const void *__restrict __src, size_t __n) > throw () __attribute__ ((__nonnull__ (1, 2))); >extern void *mempcpy (void *__restrict __dest, > const void *__restrict __src, size_t __n) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > > >extern size_t strlen (const char *__s) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); > > > > > >extern size_t strnlen (const char *__string, size_t __maxlen) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); > > > > > >extern char *strerror (int __errnum) throw (); ># 434 "/usr/include/string.h" 3 4 >extern char *strerror_r (int __errnum, char *__buf, size_t __buflen) > throw () __attribute__ ((__nonnull__ (2))) ; > > > > > >extern char *strerror_l (int __errnum, __locale_t __l) throw (); > > > > > >extern void __bzero (void *__s, size_t __n) throw () __attribute__ ((__nonnull__ (1))); > > > >extern void bcopy (const void *__src, void *__dest, size_t __n) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern void bzero (void *__s, size_t __n) throw () __attribute__ ((__nonnull__ (1))); > > >extern int bcmp (const void *__s1, const void *__s2, size_t __n) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > > >extern "C++" >{ >extern char *index (char *__s, int __c) > throw () __asm ("index") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); >extern const char *index (const char *__s, int __c) > throw () __asm ("index") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); > > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) char * >index (char *__s, int __c) throw () >{ > return __builtin_index (__s, __c); >} > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) const char * >index (const char *__s, int __c) throw () >{ > return __builtin_index (__s, __c); >} > >} > > > > > > > >extern "C++" >{ >extern char *rindex (char *__s, int __c) > throw () __asm ("rindex") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); >extern const char *rindex (const char *__s, int __c) > throw () __asm ("rindex") __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); > > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) char * >rindex (char *__s, int __c) throw () >{ > return __builtin_rindex (__s, __c); >} > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) const char * >rindex (const char *__s, int __c) throw () >{ > return __builtin_rindex (__s, __c); >} > >} > > > > > > > >extern int ffs (int __i) throw () __attribute__ ((__const__)); > > > > >extern int ffsl (long int __l) throw () __attribute__ ((__const__)); >__extension__ extern int ffsll (long long int __ll) > throw () __attribute__ ((__const__)); > > > >extern int strcasecmp (const char *__s1, const char *__s2) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > >extern int strncasecmp (const char *__s1, const char *__s2, size_t __n) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > > > > >extern int strcasecmp_l (const char *__s1, const char *__s2, > __locale_t __loc) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2, 3))); > >extern int strncasecmp_l (const char *__s1, const char *__s2, > size_t __n, __locale_t __loc) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2, 4))); > > > > > >extern char *strsep (char **__restrict __stringp, > const char *__restrict __delim) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > >extern char *strsignal (int __sig) throw (); > > >extern char *__stpcpy (char *__restrict __dest, const char *__restrict __src) > throw () __attribute__ ((__nonnull__ (1, 2))); >extern char *stpcpy (char *__restrict __dest, const char *__restrict __src) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern char *__stpncpy (char *__restrict __dest, > const char *__restrict __src, size_t __n) > throw () __attribute__ ((__nonnull__ (1, 2))); >extern char *stpncpy (char *__restrict __dest, > const char *__restrict __src, size_t __n) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > >extern int strverscmp (const char *__s1, const char *__s2) > throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); > > >extern char *strfry (char *__string) throw () __attribute__ ((__nonnull__ (1))); > > >extern void *memfrob (void *__s, size_t __n) throw () __attribute__ ((__nonnull__ (1))); > > > > > > > >extern "C++" char *basename (char *__filename) > throw () __asm ("basename") __attribute__ ((__nonnull__ (1))); >extern "C++" const char *basename (const char *__filename) > throw () __asm ("basename") __attribute__ ((__nonnull__ (1))); ># 640 "/usr/include/string.h" 3 4 >} ># 19 "/usr/include/boost/range/detail/implementation_help.hpp" 2 3 4 > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 36 "/usr/include/wchar.h" 3 4 ># 1 "/usr/include/stdio.h" 1 3 4 ># 44 "/usr/include/stdio.h" 3 4 >struct _IO_FILE; > > > >typedef struct _IO_FILE FILE; ># 64 "/usr/include/stdio.h" 3 4 >typedef struct _IO_FILE __FILE; ># 37 "/usr/include/wchar.h" 2 3 4 > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stdarg.h" 1 3 4 ># 40 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stdarg.h" 3 4 >typedef __builtin_va_list __gnuc_va_list; ># 40 "/usr/include/wchar.h" 2 3 4 > ># 1 "/usr/include/bits/wchar.h" 1 3 4 ># 42 "/usr/include/wchar.h" 2 3 4 ># 51 "/usr/include/wchar.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 353 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 3 4 >typedef unsigned int wint_t; ># 52 "/usr/include/wchar.h" 2 3 4 ># 82 "/usr/include/wchar.h" 3 4 >typedef struct >{ > int __count; > union > { > > unsigned int __wch; > > > > char __wchb[4]; > } __value; >} __mbstate_t; ># 104 "/usr/include/wchar.h" 3 4 > > >typedef __mbstate_t mbstate_t; ># 132 "/usr/include/wchar.h" 3 4 >extern "C" { > > > > >struct tm; ># 147 "/usr/include/wchar.h" 3 4 >extern wchar_t *wcscpy (wchar_t *__restrict __dest, > const wchar_t *__restrict __src) throw (); > >extern wchar_t *wcsncpy (wchar_t *__restrict __dest, > const wchar_t *__restrict __src, size_t __n) > throw (); > > >extern wchar_t *wcscat (wchar_t *__restrict __dest, > const wchar_t *__restrict __src) throw (); > >extern wchar_t *wcsncat (wchar_t *__restrict __dest, > const wchar_t *__restrict __src, size_t __n) > throw (); > > >extern int wcscmp (const wchar_t *__s1, const wchar_t *__s2) > throw () __attribute__ ((__pure__)); > >extern int wcsncmp (const wchar_t *__s1, const wchar_t *__s2, size_t __n) > throw () __attribute__ ((__pure__)); > > > > >extern int wcscasecmp (const wchar_t *__s1, const wchar_t *__s2) throw (); > > >extern int wcsncasecmp (const wchar_t *__s1, const wchar_t *__s2, > size_t __n) throw (); > > > > > >extern int wcscasecmp_l (const wchar_t *__s1, const wchar_t *__s2, > __locale_t __loc) throw (); > >extern int wcsncasecmp_l (const wchar_t *__s1, const wchar_t *__s2, > size_t __n, __locale_t __loc) throw (); > > > > > >extern int wcscoll (const wchar_t *__s1, const wchar_t *__s2) throw (); > > > >extern size_t wcsxfrm (wchar_t *__restrict __s1, > const wchar_t *__restrict __s2, size_t __n) throw (); ># 206 "/usr/include/wchar.h" 3 4 >extern int wcscoll_l (const wchar_t *__s1, const wchar_t *__s2, > __locale_t __loc) throw (); > > > > >extern size_t wcsxfrm_l (wchar_t *__s1, const wchar_t *__s2, > size_t __n, __locale_t __loc) throw (); > > >extern wchar_t *wcsdup (const wchar_t *__s) throw () __attribute__ ((__malloc__)); > > > > > >extern "C++" wchar_t *wcschr (wchar_t *__wcs, wchar_t __wc) > throw () __asm ("wcschr") __attribute__ ((__pure__)); >extern "C++" const wchar_t *wcschr (const wchar_t *__wcs, wchar_t __wc) > throw () __asm ("wcschr") __attribute__ ((__pure__)); > > > > > > >extern "C++" wchar_t *wcsrchr (wchar_t *__wcs, wchar_t __wc) > throw () __asm ("wcsrchr") __attribute__ ((__pure__)); >extern "C++" const wchar_t *wcsrchr (const wchar_t *__wcs, wchar_t __wc) > throw () __asm ("wcsrchr") __attribute__ ((__pure__)); ># 245 "/usr/include/wchar.h" 3 4 >extern wchar_t *wcschrnul (const wchar_t *__s, wchar_t __wc) > throw () __attribute__ ((__pure__)); > > > > > >extern size_t wcscspn (const wchar_t *__wcs, const wchar_t *__reject) > throw () __attribute__ ((__pure__)); > > >extern size_t wcsspn (const wchar_t *__wcs, const wchar_t *__accept) > throw () __attribute__ ((__pure__)); > > >extern "C++" wchar_t *wcspbrk (wchar_t *__wcs, const wchar_t *__accept) > throw () __asm ("wcspbrk") __attribute__ ((__pure__)); >extern "C++" const wchar_t *wcspbrk (const wchar_t *__wcs, > const wchar_t *__accept) > throw () __asm ("wcspbrk") __attribute__ ((__pure__)); > > > > > > >extern "C++" wchar_t *wcsstr (wchar_t *__haystack, const wchar_t *__needle) > throw () __asm ("wcsstr") __attribute__ ((__pure__)); >extern "C++" const wchar_t *wcsstr (const wchar_t *__haystack, > const wchar_t *__needle) > throw () __asm ("wcsstr") __attribute__ ((__pure__)); > > > > > > >extern wchar_t *wcstok (wchar_t *__restrict __s, > const wchar_t *__restrict __delim, > wchar_t **__restrict __ptr) throw (); > > >extern size_t wcslen (const wchar_t *__s) throw () __attribute__ ((__pure__)); > > > > > >extern "C++" wchar_t *wcswcs (wchar_t *__haystack, const wchar_t *__needle) > throw () __asm ("wcswcs") __attribute__ ((__pure__)); >extern "C++" const wchar_t *wcswcs (const wchar_t *__haystack, > const wchar_t *__needle) > throw () __asm ("wcswcs") __attribute__ ((__pure__)); ># 306 "/usr/include/wchar.h" 3 4 >extern size_t wcsnlen (const wchar_t *__s, size_t __maxlen) > throw () __attribute__ ((__pure__)); > > > > > > >extern "C++" wchar_t *wmemchr (wchar_t *__s, wchar_t __c, size_t __n) > throw () __asm ("wmemchr") __attribute__ ((__pure__)); >extern "C++" const wchar_t *wmemchr (const wchar_t *__s, wchar_t __c, > size_t __n) > throw () __asm ("wmemchr") __attribute__ ((__pure__)); > > > > > > >extern int wmemcmp (const wchar_t *__s1, const wchar_t *__s2, size_t __n) > throw () __attribute__ ((__pure__)); > > >extern wchar_t *wmemcpy (wchar_t *__restrict __s1, > const wchar_t *__restrict __s2, size_t __n) throw (); > > > >extern wchar_t *wmemmove (wchar_t *__s1, const wchar_t *__s2, size_t __n) > throw (); > > >extern wchar_t *wmemset (wchar_t *__s, wchar_t __c, size_t __n) throw (); > > > > > >extern wchar_t *wmempcpy (wchar_t *__restrict __s1, > const wchar_t *__restrict __s2, size_t __n) > throw (); > > > > > > >extern wint_t btowc (int __c) throw (); > > > >extern int wctob (wint_t __c) throw (); > > > >extern int mbsinit (const mbstate_t *__ps) throw () __attribute__ ((__pure__)); > > > >extern size_t mbrtowc (wchar_t *__restrict __pwc, > const char *__restrict __s, size_t __n, > mbstate_t *__restrict __p) throw (); > > >extern size_t wcrtomb (char *__restrict __s, wchar_t __wc, > mbstate_t *__restrict __ps) throw (); > > >extern size_t __mbrlen (const char *__restrict __s, size_t __n, > mbstate_t *__restrict __ps) throw (); >extern size_t mbrlen (const char *__restrict __s, size_t __n, > mbstate_t *__restrict __ps) throw (); ># 386 "/usr/include/wchar.h" 3 4 >extern wint_t __btowc_alias (int __c) __asm ("btowc"); >extern __inline __attribute__ ((__gnu_inline__)) wint_t >__attribute__ ((__leaf__)) btowc (int __c) throw () >{ return (__builtin_constant_p (__c) && __c >= '\0' && __c <= '\x7f' > ? (wint_t) __c : __btowc_alias (__c)); } > >extern int __wctob_alias (wint_t __c) __asm ("wctob"); >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) wctob (wint_t __wc) throw () >{ return (__builtin_constant_p (__wc) && __wc >= L'\0' && __wc <= L'\x7f' > ? (int) __wc : __wctob_alias (__wc)); } > >extern __inline __attribute__ ((__gnu_inline__)) size_t >__attribute__ ((__leaf__)) mbrlen (const char *__restrict __s, size_t __n, mbstate_t *__restrict __ps) throw () > >{ return (__ps != __null > ? mbrtowc (__null, __s, __n, __ps) : __mbrlen (__s, __n, __null)); } > > > > > >extern size_t mbsrtowcs (wchar_t *__restrict __dst, > const char **__restrict __src, size_t __len, > mbstate_t *__restrict __ps) throw (); > > > >extern size_t wcsrtombs (char *__restrict __dst, > const wchar_t **__restrict __src, size_t __len, > mbstate_t *__restrict __ps) throw (); > > > > > > >extern size_t mbsnrtowcs (wchar_t *__restrict __dst, > const char **__restrict __src, size_t __nmc, > size_t __len, mbstate_t *__restrict __ps) throw (); > > > >extern size_t wcsnrtombs (char *__restrict __dst, > const wchar_t **__restrict __src, > size_t __nwc, size_t __len, > mbstate_t *__restrict __ps) throw (); > > > > > > >extern int wcwidth (wchar_t __c) throw (); > > > >extern int wcswidth (const wchar_t *__s, size_t __n) throw (); > > > > > > >extern double wcstod (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr) throw (); > > > > > >extern float wcstof (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr) throw (); >extern long double wcstold (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr) throw (); > > > > > > > >extern long int wcstol (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, int __base) throw (); > > > >extern unsigned long int wcstoul (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, int __base) > throw (); > > > > > > >__extension__ >extern long long int wcstoll (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, int __base) > throw (); > > > >__extension__ >extern unsigned long long int wcstoull (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, > int __base) throw (); > > > > > > >__extension__ >extern long long int wcstoq (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, int __base) > throw (); > > > >__extension__ >extern unsigned long long int wcstouq (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, > int __base) throw (); ># 530 "/usr/include/wchar.h" 3 4 >extern long int wcstol_l (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, int __base, > __locale_t __loc) throw (); > >extern unsigned long int wcstoul_l (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, > int __base, __locale_t __loc) throw (); > >__extension__ >extern long long int wcstoll_l (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, > int __base, __locale_t __loc) throw (); > >__extension__ >extern unsigned long long int wcstoull_l (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, > int __base, __locale_t __loc) > throw (); > >extern double wcstod_l (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, __locale_t __loc) > throw (); > >extern float wcstof_l (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, __locale_t __loc) > throw (); > >extern long double wcstold_l (const wchar_t *__restrict __nptr, > wchar_t **__restrict __endptr, > __locale_t __loc) throw (); > > > > > > >extern wchar_t *wcpcpy (wchar_t *__restrict __dest, > const wchar_t *__restrict __src) throw (); > > > >extern wchar_t *wcpncpy (wchar_t *__restrict __dest, > const wchar_t *__restrict __src, size_t __n) > throw (); > > > > > > >extern __FILE *open_wmemstream (wchar_t **__bufloc, size_t *__sizeloc) throw (); > > > > > > >extern int fwide (__FILE *__fp, int __mode) throw (); > > > > > > >extern int fwprintf (__FILE *__restrict __stream, > const wchar_t *__restrict __format, ...) > ; > > > > >extern int wprintf (const wchar_t *__restrict __format, ...) > ; > >extern int swprintf (wchar_t *__restrict __s, size_t __n, > const wchar_t *__restrict __format, ...) > throw () ; > > > > > >extern int vfwprintf (__FILE *__restrict __s, > const wchar_t *__restrict __format, > __gnuc_va_list __arg) > ; > > > > >extern int vwprintf (const wchar_t *__restrict __format, > __gnuc_va_list __arg) > ; > > >extern int vswprintf (wchar_t *__restrict __s, size_t __n, > const wchar_t *__restrict __format, > __gnuc_va_list __arg) > throw () ; > > > > > > >extern int fwscanf (__FILE *__restrict __stream, > const wchar_t *__restrict __format, ...) > ; > > > > >extern int wscanf (const wchar_t *__restrict __format, ...) > ; > >extern int swscanf (const wchar_t *__restrict __s, > const wchar_t *__restrict __format, ...) > throw () ; ># 680 "/usr/include/wchar.h" 3 4 ># 689 "/usr/include/wchar.h" 3 4 >extern int vfwscanf (__FILE *__restrict __s, > const wchar_t *__restrict __format, > __gnuc_va_list __arg) > ; > > > > >extern int vwscanf (const wchar_t *__restrict __format, > __gnuc_va_list __arg) > ; > >extern int vswscanf (const wchar_t *__restrict __s, > const wchar_t *__restrict __format, > __gnuc_va_list __arg) > throw () ; ># 736 "/usr/include/wchar.h" 3 4 ># 745 "/usr/include/wchar.h" 3 4 >extern wint_t fgetwc (__FILE *__stream); >extern wint_t getwc (__FILE *__stream); > > > > > >extern wint_t getwchar (void); > > > > > > >extern wint_t fputwc (wchar_t __wc, __FILE *__stream); >extern wint_t putwc (wchar_t __wc, __FILE *__stream); > > > > > >extern wint_t putwchar (wchar_t __wc); > > > > > > > >extern wchar_t *fgetws (wchar_t *__restrict __ws, int __n, > __FILE *__restrict __stream); > > > > > >extern int fputws (const wchar_t *__restrict __ws, > __FILE *__restrict __stream); > > > > > > >extern wint_t ungetwc (wint_t __wc, __FILE *__stream); ># 801 "/usr/include/wchar.h" 3 4 >extern wint_t getwc_unlocked (__FILE *__stream); >extern wint_t getwchar_unlocked (void); > > > > > > > >extern wint_t fgetwc_unlocked (__FILE *__stream); > > > > > > > >extern wint_t fputwc_unlocked (wchar_t __wc, __FILE *__stream); ># 827 "/usr/include/wchar.h" 3 4 >extern wint_t putwc_unlocked (wchar_t __wc, __FILE *__stream); >extern wint_t putwchar_unlocked (wchar_t __wc); ># 837 "/usr/include/wchar.h" 3 4 >extern wchar_t *fgetws_unlocked (wchar_t *__restrict __ws, int __n, > __FILE *__restrict __stream); > > > > > > > >extern int fputws_unlocked (const wchar_t *__restrict __ws, > __FILE *__restrict __stream); > > > > > > > >extern size_t wcsftime (wchar_t *__restrict __s, size_t __maxsize, > const wchar_t *__restrict __format, > const struct tm *__restrict __tp) throw (); > > > > > > > >extern size_t wcsftime_l (wchar_t *__restrict __s, size_t __maxsize, > const wchar_t *__restrict __format, > const struct tm *__restrict __tp, > __locale_t __loc) throw (); ># 891 "/usr/include/wchar.h" 3 4 >} ># 22 "/usr/include/boost/range/detail/implementation_help.hpp" 2 3 4 > > >namespace boost >{ > namespace range_detail > { > template <typename T> > inline void boost_range_silence_warning( const T& ) { } > > > > > > inline const char* str_end( const char* s, const char* ) > { > return s + strlen( s ); > } > > > inline const wchar_t* str_end( const wchar_t* s, const wchar_t* ) > { > return s + wcslen( s ); > } ># 56 "/usr/include/boost/range/detail/implementation_help.hpp" 3 4 > template< class Char > > inline Char* str_end( Char* s ) > { > return const_cast<Char*>( str_end( s, s ) ); > } > > template< class T, std::size_t sz > > inline T* array_end( T (&boost_range_array)[sz] ) > { > return boost_range_array + sz; > } > > template< class T, std::size_t sz > > inline const T* array_end( const T (&boost_range_array)[sz] ) > { > return boost_range_array + sz; > } > > > > > > template< class Char > > inline std::size_t str_size( const Char* const& s ) > { > return str_end( s ) - s; > } > > template< class T, std::size_t sz > > inline std::size_t array_size( T (&boost_range_array)[sz] ) > { > boost_range_silence_warning( boost_range_array ); > return sz; > } > > template< class T, std::size_t sz > > inline std::size_t array_size( const T (&boost_range_array)[sz] ) > { > boost_range_silence_warning( boost_range_array ); > return sz; > } > > } > >} ># 25 "/usr/include/boost/range/end.hpp" 2 3 4 ># 1 "/usr/include/boost/range/iterator.hpp" 1 3 4 ># 19 "/usr/include/boost/range/iterator.hpp" 3 4 ># 1 "/usr/include/boost/range/mutable_iterator.hpp" 1 3 4 ># 24 "/usr/include/boost/range/mutable_iterator.hpp" 3 4 ># 1 "/usr/include/boost/range/detail/extract_optional_type.hpp" 1 3 4 ># 30 "/usr/include/boost/range/detail/extract_optional_type.hpp" 3 4 >namespace boost { > namespace range_detail { > template< typename T > struct exists { typedef void type; }; > } >} ># 25 "/usr/include/boost/range/mutable_iterator.hpp" 2 3 4 ># 1 "/usr/include/boost/iterator/iterator_traits.hpp" 1 3 4 > > > > > > > ># 1 "/usr/include/boost/detail/iterator.hpp" 1 3 4 ># 54 "/usr/include/boost/detail/iterator.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/iterator" 1 3 4 ># 58 "/usr/include/c++/4.9.0/iterator" 3 4 ># 59 "/usr/include/c++/4.9.0/iterator" 3 > > ># 1 "/usr/include/c++/4.9.0/bits/stl_iterator_base_types.h" 1 3 ># 62 "/usr/include/c++/4.9.0/bits/stl_iterator_base_types.h" 3 ># 63 "/usr/include/c++/4.9.0/bits/stl_iterator_base_types.h" 3 > > > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 89 "/usr/include/c++/4.9.0/bits/stl_iterator_base_types.h" 3 > struct input_iterator_tag { }; > > > struct output_iterator_tag { }; > > > struct forward_iterator_tag : public input_iterator_tag { }; > > > > struct bidirectional_iterator_tag : public forward_iterator_tag { }; > > > > struct random_access_iterator_tag : public bidirectional_iterator_tag { }; ># 116 "/usr/include/c++/4.9.0/bits/stl_iterator_base_types.h" 3 > template<typename _Category, typename _Tp, typename _Distance = ptrdiff_t, > typename _Pointer = _Tp*, typename _Reference = _Tp&> > struct iterator > { > > typedef _Category iterator_category; > > typedef _Tp value_type; > > typedef _Distance difference_type; > > typedef _Pointer pointer; > > typedef _Reference reference; > }; ># 142 "/usr/include/c++/4.9.0/bits/stl_iterator_base_types.h" 3 >template<typename _Tp> class __has_iterator_category_helper { template<typename _Up> struct _Wrap_type { }; template<typename _Up> static true_type __test(_Wrap_type<typename _Up::iterator_category>*); template<typename _Up> static false_type __test(...); public: typedef decltype(__test<_Tp>(0)) type; }; template<typename _Tp> struct __has_iterator_category : public __has_iterator_category_helper <typename remove_cv<_Tp>::type>::type { }; > > template<typename _Iterator, > bool = __has_iterator_category<_Iterator>::value> > struct __iterator_traits { }; > > template<typename _Iterator> > struct __iterator_traits<_Iterator, true> > { > typedef typename _Iterator::iterator_category iterator_category; > typedef typename _Iterator::value_type value_type; > typedef typename _Iterator::difference_type difference_type; > typedef typename _Iterator::pointer pointer; > typedef typename _Iterator::reference reference; > }; > > template<typename _Iterator> > struct iterator_traits > : public __iterator_traits<_Iterator> { }; ># 174 "/usr/include/c++/4.9.0/bits/stl_iterator_base_types.h" 3 > template<typename _Tp> > struct iterator_traits<_Tp*> > { > typedef random_access_iterator_tag iterator_category; > typedef _Tp value_type; > typedef ptrdiff_t difference_type; > typedef _Tp* pointer; > typedef _Tp& reference; > }; > > > template<typename _Tp> > struct iterator_traits<const _Tp*> > { > typedef random_access_iterator_tag iterator_category; > typedef _Tp value_type; > typedef ptrdiff_t difference_type; > typedef const _Tp* pointer; > typedef const _Tp& reference; > }; > > > > > > template<typename _Iter> > inline typename iterator_traits<_Iter>::iterator_category > __iterator_category(const _Iter&) > { return typename iterator_traits<_Iter>::iterator_category(); } > > > > > > template<typename _Iterator, bool _HasBase> > struct _Iter_base > { > typedef _Iterator iterator_type; > static iterator_type _S_base(_Iterator __it) > { return __it; } > }; > > template<typename _Iterator> > struct _Iter_base<_Iterator, true> > { > typedef typename _Iterator::iterator_type iterator_type; > static iterator_type _S_base(_Iterator __it) > { return __it.base(); } > }; > > > template<typename _InIter> > using _RequireInputIter = typename > enable_if<is_convertible<typename > iterator_traits<_InIter>::iterator_category, > input_iterator_tag>::value>::type; > > > >} ># 62 "/usr/include/c++/4.9.0/iterator" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_iterator_base_funcs.h" 1 3 ># 62 "/usr/include/c++/4.9.0/bits/stl_iterator_base_funcs.h" 3 ># 63 "/usr/include/c++/4.9.0/bits/stl_iterator_base_funcs.h" 3 > > ># 1 "/usr/include/c++/4.9.0/debug/debug.h" 1 3 ># 46 "/usr/include/c++/4.9.0/debug/debug.h" 3 >namespace std >{ > namespace __debug { } >} > > > > >namespace __gnu_debug >{ > using namespace std::__debug; >} ># 66 "/usr/include/c++/4.9.0/bits/stl_iterator_base_funcs.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _InputIterator> > inline typename iterator_traits<_InputIterator>::difference_type > __distance(_InputIterator __first, _InputIterator __last, > input_iterator_tag) > { > > > > typename iterator_traits<_InputIterator>::difference_type __n = 0; > while (__first != __last) > { > ++__first; > ++__n; > } > return __n; > } > > template<typename _RandomAccessIterator> > inline typename iterator_traits<_RandomAccessIterator>::difference_type > __distance(_RandomAccessIterator __first, _RandomAccessIterator __last, > random_access_iterator_tag) > { > > > > return __last - __first; > } ># 112 "/usr/include/c++/4.9.0/bits/stl_iterator_base_funcs.h" 3 > template<typename _InputIterator> > inline typename iterator_traits<_InputIterator>::difference_type > distance(_InputIterator __first, _InputIterator __last) > { > > return std::__distance(__first, __last, > std::__iterator_category(__first)); > } > > template<typename _InputIterator, typename _Distance> > inline void > __advance(_InputIterator& __i, _Distance __n, input_iterator_tag) > { > > > ; > while (__n--) > ++__i; > } > > template<typename _BidirectionalIterator, typename _Distance> > inline void > __advance(_BidirectionalIterator& __i, _Distance __n, > bidirectional_iterator_tag) > { > > > > if (__n > 0) > while (__n--) > ++__i; > else > while (__n++) > --__i; > } > > template<typename _RandomAccessIterator, typename _Distance> > inline void > __advance(_RandomAccessIterator& __i, _Distance __n, > random_access_iterator_tag) > { > > > > __i += __n; > } ># 171 "/usr/include/c++/4.9.0/bits/stl_iterator_base_funcs.h" 3 > template<typename _InputIterator, typename _Distance> > inline void > advance(_InputIterator& __i, _Distance __n) > { > > typename iterator_traits<_InputIterator>::difference_type __d = __n; > std::__advance(__i, __d, std::__iterator_category(__i)); > } > > > > template<typename _ForwardIterator> > inline _ForwardIterator > next(_ForwardIterator __x, typename > iterator_traits<_ForwardIterator>::difference_type __n = 1) > { > std::advance(__x, __n); > return __x; > } > > template<typename _BidirectionalIterator> > inline _BidirectionalIterator > prev(_BidirectionalIterator __x, typename > iterator_traits<_BidirectionalIterator>::difference_type __n = 1) > { > std::advance(__x, -__n); > return __x; > } > > > > >} ># 63 "/usr/include/c++/4.9.0/iterator" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 1 3 ># 63 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 ># 1 "/usr/include/c++/4.9.0/bits/cpp_type_traits.h" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/cpp_type_traits.h" 3 ># 36 "/usr/include/c++/4.9.0/bits/cpp_type_traits.h" 3 ># 68 "/usr/include/c++/4.9.0/bits/cpp_type_traits.h" 3 >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Iterator, typename _Container> > class __normal_iterator; > > >} > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > struct __true_type { }; > struct __false_type { }; > > template<bool> > struct __truth_type > { typedef __false_type __type; }; > > template<> > struct __truth_type<true> > { typedef __true_type __type; }; > > > > template<class _Sp, class _Tp> > struct __traitor > { > enum { __value = bool(_Sp::__value) || bool(_Tp::__value) }; > typedef typename __truth_type<__value>::__type __type; > }; > > > template<typename, typename> > struct __are_same > { > enum { __value = 0 }; > typedef __false_type __type; > }; > > template<typename _Tp> > struct __are_same<_Tp, _Tp> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > template<typename _Tp> > struct __is_void > { > enum { __value = 0 }; > typedef __false_type __type; > }; > > template<> > struct __is_void<void> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > > > template<typename _Tp> > struct __is_integer > { > enum { __value = 0 }; > typedef __false_type __type; > }; > > > > > template<> > struct __is_integer<bool> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<char> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<signed char> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<unsigned char> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > template<> > struct __is_integer<wchar_t> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > > template<> > struct __is_integer<char16_t> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<char32_t> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > template<> > struct __is_integer<short> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<unsigned short> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<int> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<unsigned int> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<long> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<unsigned long> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<long long> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_integer<unsigned long long> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > > > template<typename _Tp> > struct __is_floating > { > enum { __value = 0 }; > typedef __false_type __type; > }; > > > template<> > struct __is_floating<float> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_floating<double> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_floating<long double> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > > > template<typename _Tp> > struct __is_pointer > { > enum { __value = 0 }; > typedef __false_type __type; > }; > > template<typename _Tp> > struct __is_pointer<_Tp*> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > > > template<typename _Tp> > struct __is_normal_iterator > { > enum { __value = 0 }; > typedef __false_type __type; > }; > > template<typename _Iterator, typename _Container> > struct __is_normal_iterator< __gnu_cxx::__normal_iterator<_Iterator, > _Container> > > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > > > template<typename _Tp> > struct __is_arithmetic > : public __traitor<__is_integer<_Tp>, __is_floating<_Tp> > > { }; > > > > > template<typename _Tp> > struct __is_scalar > : public __traitor<__is_arithmetic<_Tp>, __is_pointer<_Tp> > > { }; > > > > > template<typename _Tp> > struct __is_char > { > enum { __value = 0 }; > typedef __false_type __type; > }; > > template<> > struct __is_char<char> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > template<> > struct __is_char<wchar_t> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > template<typename _Tp> > struct __is_byte > { > enum { __value = 0 }; > typedef __false_type __type; > }; > > template<> > struct __is_byte<char> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_byte<signed char> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > template<> > struct __is_byte<unsigned char> > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > > > template<typename _Tp> > struct __is_move_iterator > { > enum { __value = 0 }; > typedef __false_type __type; > }; > > > template<typename _Iterator> > class move_iterator; > > template<typename _Iterator> > struct __is_move_iterator< move_iterator<_Iterator> > > { > enum { __value = 1 }; > typedef __true_type __type; > }; > > > >} ># 64 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 2 3 ># 1 "/usr/include/c++/4.9.0/ext/type_traits.h" 1 3 ># 32 "/usr/include/c++/4.9.0/ext/type_traits.h" 3 ># 33 "/usr/include/c++/4.9.0/ext/type_traits.h" 3 > > > > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > > template<bool, typename> > struct __enable_if > { }; > > template<typename _Tp> > struct __enable_if<true, _Tp> > { typedef _Tp __type; }; > > > > template<bool _Cond, typename _Iftrue, typename _Iffalse> > struct __conditional_type > { typedef _Iftrue __type; }; > > template<typename _Iftrue, typename _Iffalse> > struct __conditional_type<false, _Iftrue, _Iffalse> > { typedef _Iffalse __type; }; > > > > template<typename _Tp> > struct __add_unsigned > { > private: > typedef __enable_if<std::__is_integer<_Tp>::__value, _Tp> __if_type; > > public: > typedef typename __if_type::__type __type; > }; > > template<> > struct __add_unsigned<char> > { typedef unsigned char __type; }; > > template<> > struct __add_unsigned<signed char> > { typedef unsigned char __type; }; > > template<> > struct __add_unsigned<short> > { typedef unsigned short __type; }; > > template<> > struct __add_unsigned<int> > { typedef unsigned int __type; }; > > template<> > struct __add_unsigned<long> > { typedef unsigned long __type; }; > > template<> > struct __add_unsigned<long long> > { typedef unsigned long long __type; }; > > > template<> > struct __add_unsigned<bool>; > > template<> > struct __add_unsigned<wchar_t>; > > > > template<typename _Tp> > struct __remove_unsigned > { > private: > typedef __enable_if<std::__is_integer<_Tp>::__value, _Tp> __if_type; > > public: > typedef typename __if_type::__type __type; > }; > > template<> > struct __remove_unsigned<char> > { typedef signed char __type; }; > > template<> > struct __remove_unsigned<unsigned char> > { typedef signed char __type; }; > > template<> > struct __remove_unsigned<unsigned short> > { typedef short __type; }; > > template<> > struct __remove_unsigned<unsigned int> > { typedef int __type; }; > > template<> > struct __remove_unsigned<unsigned long> > { typedef long __type; }; > > template<> > struct __remove_unsigned<unsigned long long> > { typedef long long __type; }; > > > template<> > struct __remove_unsigned<bool>; > > template<> > struct __remove_unsigned<wchar_t>; > > > > template<typename _Type> > inline bool > __is_null_pointer(_Type* __ptr) > { return __ptr == 0; } > > template<typename _Type> > inline bool > __is_null_pointer(_Type) > { return false; } > > > inline bool > __is_null_pointer(std::nullptr_t) > { return true; } > > > > template<typename _Tp, bool = std::__is_integer<_Tp>::__value> > struct __promote > { typedef double __type; }; > > > > > template<typename _Tp> > struct __promote<_Tp, false> > { }; > > template<> > struct __promote<long double> > { typedef long double __type; }; > > template<> > struct __promote<double> > { typedef double __type; }; > > template<> > struct __promote<float> > { typedef float __type; }; > > template<typename _Tp, typename _Up, > typename _Tp2 = typename __promote<_Tp>::__type, > typename _Up2 = typename __promote<_Up>::__type> > struct __promote_2 > { > typedef __typeof__(_Tp2() + _Up2()) __type; > }; > > template<typename _Tp, typename _Up, typename _Vp, > typename _Tp2 = typename __promote<_Tp>::__type, > typename _Up2 = typename __promote<_Up>::__type, > typename _Vp2 = typename __promote<_Vp>::__type> > struct __promote_3 > { > typedef __typeof__(_Tp2() + _Up2() + _Vp2()) __type; > }; > > template<typename _Tp, typename _Up, typename _Vp, typename _Wp, > typename _Tp2 = typename __promote<_Tp>::__type, > typename _Up2 = typename __promote<_Up>::__type, > typename _Vp2 = typename __promote<_Vp>::__type, > typename _Wp2 = typename __promote<_Wp>::__type> > struct __promote_4 > { > typedef __typeof__(_Tp2() + _Up2() + _Vp2() + _Wp2()) __type; > }; > > >} ># 65 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 2 3 > ># 1 "/usr/include/c++/4.9.0/bits/ptr_traits.h" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/ptr_traits.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > >template<typename _Tp> class __has_element_type_helper { template<typename _Up> struct _Wrap_type { }; template<typename _Up> static true_type __test(_Wrap_type<typename _Up::element_type>*); template<typename _Up> static false_type __test(...); public: typedef decltype(__test<_Tp>(0)) type; }; template<typename _Tp> struct __has_element_type : public __has_element_type_helper <typename remove_cv<_Tp>::type>::type { }; >template<typename _Tp> class __has_difference_type_helper { template<typename _Up> struct _Wrap_type { }; template<typename _Up> static true_type __test(_Wrap_type<typename _Up::difference_type>*); template<typename _Up> static false_type __test(...); public: typedef decltype(__test<_Tp>(0)) type; }; template<typename _Tp> struct __has_difference_type : public __has_difference_type_helper <typename remove_cv<_Tp>::type>::type { }; > > template<typename _Tp, bool = __has_element_type<_Tp>::value> > struct __ptrtr_elt_type; > > template<typename _Tp> > struct __ptrtr_elt_type<_Tp, true> > { > typedef typename _Tp::element_type __type; > }; > > template<template<typename, typename...> class _SomePtr, typename _Tp, > typename... _Args> > struct __ptrtr_elt_type<_SomePtr<_Tp, _Args...>, false> > { > typedef _Tp __type; > }; > > template<typename _Tp, bool = __has_difference_type<_Tp>::value> > struct __ptrtr_diff_type > { > typedef typename _Tp::difference_type __type; > }; > > template<typename _Tp> > struct __ptrtr_diff_type<_Tp, false> > { > typedef ptrdiff_t __type; > }; > > template<typename _Ptr, typename _Up> > class __ptrtr_rebind_helper > { > template<typename _Ptr2, typename _Up2> > static constexpr true_type > _S_chk(typename _Ptr2::template rebind<_Up2>*); > > template<typename, typename> > static constexpr false_type > _S_chk(...); > > public: > using __type = decltype(_S_chk<_Ptr, _Up>(nullptr)); > }; > > template<typename _Tp, typename _Up, > bool = __ptrtr_rebind_helper<_Tp, _Up>::__type::value> > struct __ptrtr_rebind; > > template<typename _Tp, typename _Up> > struct __ptrtr_rebind<_Tp, _Up, true> > { > typedef typename _Tp::template rebind<_Up> __type; > }; > > template<template<typename, typename...> class _SomePtr, typename _Up, > typename _Tp, typename... _Args> > struct __ptrtr_rebind<_SomePtr<_Tp, _Args...>, _Up, false> > { > typedef _SomePtr<_Up, _Args...> __type; > }; > > template<typename _Tp, typename = typename remove_cv<_Tp>::type> > struct __ptrtr_not_void > { > typedef _Tp __type; > }; > > template<typename _Tp> > struct __ptrtr_not_void<_Tp, void> > { > struct __type { }; > }; > > template<typename _Ptr> > class __ptrtr_pointer_to > { > typedef typename __ptrtr_elt_type<_Ptr>::__type __orig_type; > typedef typename __ptrtr_not_void<__orig_type>::__type __element_type; > > public: > static _Ptr pointer_to(__element_type& __e) > { return _Ptr::pointer_to(__e); } > }; > > > > > > template<typename _Ptr> > struct pointer_traits : __ptrtr_pointer_to<_Ptr> > { > > typedef _Ptr pointer; > > typedef typename __ptrtr_elt_type<_Ptr>::__type element_type; > > typedef typename __ptrtr_diff_type<_Ptr>::__type difference_type; > > template<typename _Up> > using rebind = typename __ptrtr_rebind<_Ptr, _Up>::__type; > }; > > > > > > template<typename _Tp> > struct pointer_traits<_Tp*> > { > > typedef _Tp* pointer; > > typedef _Tp element_type; > > typedef ptrdiff_t difference_type; > > template<typename _Up> > using rebind = _Up*; > > > > > > > static pointer > pointer_to(typename __ptrtr_not_void<element_type>::__type& __r) noexcept > { return std::addressof(__r); } > }; > > >} ># 67 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 96 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _Iterator> > class reverse_iterator > : public iterator<typename iterator_traits<_Iterator>::iterator_category, > typename iterator_traits<_Iterator>::value_type, > typename iterator_traits<_Iterator>::difference_type, > typename iterator_traits<_Iterator>::pointer, > typename iterator_traits<_Iterator>::reference> > { > protected: > _Iterator current; > > typedef iterator_traits<_Iterator> __traits_type; > > public: > typedef _Iterator iterator_type; > typedef typename __traits_type::difference_type difference_type; > typedef typename __traits_type::pointer pointer; > typedef typename __traits_type::reference reference; > > > > > > > > reverse_iterator() : current() { } > > > > > explicit > reverse_iterator(iterator_type __x) : current(__x) { } > > > > > reverse_iterator(const reverse_iterator& __x) > : current(__x.current) { } > > > > > > template<typename _Iter> > reverse_iterator(const reverse_iterator<_Iter>& __x) > : current(__x.base()) { } > > > > > iterator_type > base() const > { return current; } ># 160 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > reference > operator*() const > { > _Iterator __tmp = current; > return *--__tmp; > } > > > > > > > pointer > operator->() const > { return &(operator*()); } > > > > > > > reverse_iterator& > operator++() > { > --current; > return *this; > } > > > > > > > reverse_iterator > operator++(int) > { > reverse_iterator __tmp = *this; > --current; > return __tmp; > } > > > > > > > reverse_iterator& > operator--() > { > ++current; > return *this; > } > > > > > > > reverse_iterator > operator--(int) > { > reverse_iterator __tmp = *this; > ++current; > return __tmp; > } > > > > > > > reverse_iterator > operator+(difference_type __n) const > { return reverse_iterator(current - __n); } > > > > > > > > reverse_iterator& > operator+=(difference_type __n) > { > current -= __n; > return *this; > } > > > > > > > reverse_iterator > operator-(difference_type __n) const > { return reverse_iterator(current + __n); } > > > > > > > > reverse_iterator& > operator-=(difference_type __n) > { > current += __n; > return *this; > } > > > > > > > reference > operator[](difference_type __n) const > { return *(*this + __n); } > }; ># 290 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _Iterator> > inline bool > operator==(const reverse_iterator<_Iterator>& __x, > const reverse_iterator<_Iterator>& __y) > { return __x.base() == __y.base(); } > > template<typename _Iterator> > inline bool > operator<(const reverse_iterator<_Iterator>& __x, > const reverse_iterator<_Iterator>& __y) > { return __y.base() < __x.base(); } > > template<typename _Iterator> > inline bool > operator!=(const reverse_iterator<_Iterator>& __x, > const reverse_iterator<_Iterator>& __y) > { return !(__x == __y); } > > template<typename _Iterator> > inline bool > operator>(const reverse_iterator<_Iterator>& __x, > const reverse_iterator<_Iterator>& __y) > { return __y < __x; } > > template<typename _Iterator> > inline bool > operator<=(const reverse_iterator<_Iterator>& __x, > const reverse_iterator<_Iterator>& __y) > { return !(__y < __x); } > > template<typename _Iterator> > inline bool > operator>=(const reverse_iterator<_Iterator>& __x, > const reverse_iterator<_Iterator>& __y) > { return !(__x < __y); } > > template<typename _Iterator> > inline typename reverse_iterator<_Iterator>::difference_type > operator-(const reverse_iterator<_Iterator>& __x, > const reverse_iterator<_Iterator>& __y) > { return __y.base() - __x.base(); } > > template<typename _Iterator> > inline reverse_iterator<_Iterator> > operator+(typename reverse_iterator<_Iterator>::difference_type __n, > const reverse_iterator<_Iterator>& __x) > { return reverse_iterator<_Iterator>(__x.base() - __n); } > > > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator==(const reverse_iterator<_IteratorL>& __x, > const reverse_iterator<_IteratorR>& __y) > { return __x.base() == __y.base(); } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator<(const reverse_iterator<_IteratorL>& __x, > const reverse_iterator<_IteratorR>& __y) > { return __y.base() < __x.base(); } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator!=(const reverse_iterator<_IteratorL>& __x, > const reverse_iterator<_IteratorR>& __y) > { return !(__x == __y); } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator>(const reverse_iterator<_IteratorL>& __x, > const reverse_iterator<_IteratorR>& __y) > { return __y < __x; } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator<=(const reverse_iterator<_IteratorL>& __x, > const reverse_iterator<_IteratorR>& __y) > { return !(__y < __x); } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator>=(const reverse_iterator<_IteratorL>& __x, > const reverse_iterator<_IteratorR>& __y) > { return !(__x < __y); } > > template<typename _IteratorL, typename _IteratorR> > > > inline auto > operator-(const reverse_iterator<_IteratorL>& __x, > const reverse_iterator<_IteratorR>& __y) > -> decltype(__y.base() - __x.base()) > > > > > > { return __y.base() - __x.base(); } ># 402 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _Container> > class back_insert_iterator > : public iterator<output_iterator_tag, void, void, void, void> > { > protected: > _Container* container; > > public: > > typedef _Container container_type; > > > explicit > back_insert_iterator(_Container& __x) : container(&__x) { } ># 436 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > back_insert_iterator& > operator=(const typename _Container::value_type& __value) > { > container->push_back(__value); > return *this; > } > > back_insert_iterator& > operator=(typename _Container::value_type&& __value) > { > container->push_back(std::move(__value)); > return *this; > } > > > > back_insert_iterator& > operator*() > { return *this; } > > > back_insert_iterator& > operator++() > { return *this; } > > > back_insert_iterator > operator++(int) > { return *this; } > }; ># 478 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _Container> > inline back_insert_iterator<_Container> > back_inserter(_Container& __x) > { return back_insert_iterator<_Container>(__x); } ># 493 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _Container> > class front_insert_iterator > : public iterator<output_iterator_tag, void, void, void, void> > { > protected: > _Container* container; > > public: > > typedef _Container container_type; > > > explicit front_insert_iterator(_Container& __x) : container(&__x) { } ># 526 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > front_insert_iterator& > operator=(const typename _Container::value_type& __value) > { > container->push_front(__value); > return *this; > } > > front_insert_iterator& > operator=(typename _Container::value_type&& __value) > { > container->push_front(std::move(__value)); > return *this; > } > > > > front_insert_iterator& > operator*() > { return *this; } > > > front_insert_iterator& > operator++() > { return *this; } > > > front_insert_iterator > operator++(int) > { return *this; } > }; ># 568 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _Container> > inline front_insert_iterator<_Container> > front_inserter(_Container& __x) > { return front_insert_iterator<_Container>(__x); } ># 587 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _Container> > class insert_iterator > : public iterator<output_iterator_tag, void, void, void, void> > { > protected: > _Container* container; > typename _Container::iterator iter; > > public: > > typedef _Container container_type; > > > > > > insert_iterator(_Container& __x, typename _Container::iterator __i) > : container(&__x), iter(__i) {} ># 638 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > insert_iterator& > operator=(const typename _Container::value_type& __value) > { > iter = container->insert(iter, __value); > ++iter; > return *this; > } > > insert_iterator& > operator=(typename _Container::value_type&& __value) > { > iter = container->insert(iter, std::move(__value)); > ++iter; > return *this; > } > > > > insert_iterator& > operator*() > { return *this; } > > > insert_iterator& > operator++() > { return *this; } > > > insert_iterator& > operator++(int) > { return *this; } > }; ># 682 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _Container, typename _Iterator> > inline insert_iterator<_Container> > inserter(_Container& __x, _Iterator __i) > { > return insert_iterator<_Container>(__x, > typename _Container::iterator(__i)); > } > > > > >} > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ ># 706 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > using std::iterator_traits; > using std::iterator; > template<typename _Iterator, typename _Container> > class __normal_iterator > { > protected: > _Iterator _M_current; > > typedef iterator_traits<_Iterator> __traits_type; > > public: > typedef _Iterator iterator_type; > typedef typename __traits_type::iterator_category iterator_category; > typedef typename __traits_type::value_type value_type; > typedef typename __traits_type::difference_type difference_type; > typedef typename __traits_type::reference reference; > typedef typename __traits_type::pointer pointer; > > constexpr __normal_iterator() noexcept > : _M_current(_Iterator()) { } > > explicit > __normal_iterator(const _Iterator& __i) noexcept > : _M_current(__i) { } > > > template<typename _Iter> > __normal_iterator(const __normal_iterator<_Iter, > typename __enable_if< > (std::__are_same<_Iter, typename _Container::pointer>::__value), > _Container>::__type>& __i) noexcept > : _M_current(__i.base()) { } > > > __normal_iterator<typename _Container::pointer, _Container> > _M_const_cast() const noexcept > { > using _PTraits = std::pointer_traits<typename _Container::pointer>; > return __normal_iterator<typename _Container::pointer, _Container> > (_PTraits::pointer_to(const_cast<typename _PTraits::element_type&> > (*_M_current))); > } > > > > > > > > reference > operator*() const noexcept > { return *_M_current; } > > pointer > operator->() const noexcept > { return _M_current; } > > __normal_iterator& > operator++() noexcept > { > ++_M_current; > return *this; > } > > __normal_iterator > operator++(int) noexcept > { return __normal_iterator(_M_current++); } > > > __normal_iterator& > operator--() noexcept > { > --_M_current; > return *this; > } > > __normal_iterator > operator--(int) noexcept > { return __normal_iterator(_M_current--); } > > > reference > operator[](difference_type __n) const noexcept > { return _M_current[__n]; } > > __normal_iterator& > operator+=(difference_type __n) noexcept > { _M_current += __n; return *this; } > > __normal_iterator > operator+(difference_type __n) const noexcept > { return __normal_iterator(_M_current + __n); } > > __normal_iterator& > operator-=(difference_type __n) noexcept > { _M_current -= __n; return *this; } > > __normal_iterator > operator-(difference_type __n) const noexcept > { return __normal_iterator(_M_current - __n); } > > const _Iterator& > base() const noexcept > { return _M_current; } > }; ># 821 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _IteratorL, typename _IteratorR, typename _Container> > inline bool > operator==(const __normal_iterator<_IteratorL, _Container>& __lhs, > const __normal_iterator<_IteratorR, _Container>& __rhs) > noexcept > { return __lhs.base() == __rhs.base(); } > > template<typename _Iterator, typename _Container> > inline bool > operator==(const __normal_iterator<_Iterator, _Container>& __lhs, > const __normal_iterator<_Iterator, _Container>& __rhs) > noexcept > { return __lhs.base() == __rhs.base(); } > > template<typename _IteratorL, typename _IteratorR, typename _Container> > inline bool > operator!=(const __normal_iterator<_IteratorL, _Container>& __lhs, > const __normal_iterator<_IteratorR, _Container>& __rhs) > noexcept > { return __lhs.base() != __rhs.base(); } > > template<typename _Iterator, typename _Container> > inline bool > operator!=(const __normal_iterator<_Iterator, _Container>& __lhs, > const __normal_iterator<_Iterator, _Container>& __rhs) > noexcept > { return __lhs.base() != __rhs.base(); } > > > template<typename _IteratorL, typename _IteratorR, typename _Container> > inline bool > operator<(const __normal_iterator<_IteratorL, _Container>& __lhs, > const __normal_iterator<_IteratorR, _Container>& __rhs) > noexcept > { return __lhs.base() < __rhs.base(); } > > template<typename _Iterator, typename _Container> > inline bool > operator<(const __normal_iterator<_Iterator, _Container>& __lhs, > const __normal_iterator<_Iterator, _Container>& __rhs) > noexcept > { return __lhs.base() < __rhs.base(); } > > template<typename _IteratorL, typename _IteratorR, typename _Container> > inline bool > operator>(const __normal_iterator<_IteratorL, _Container>& __lhs, > const __normal_iterator<_IteratorR, _Container>& __rhs) > noexcept > { return __lhs.base() > __rhs.base(); } > > template<typename _Iterator, typename _Container> > inline bool > operator>(const __normal_iterator<_Iterator, _Container>& __lhs, > const __normal_iterator<_Iterator, _Container>& __rhs) > noexcept > { return __lhs.base() > __rhs.base(); } > > template<typename _IteratorL, typename _IteratorR, typename _Container> > inline bool > operator<=(const __normal_iterator<_IteratorL, _Container>& __lhs, > const __normal_iterator<_IteratorR, _Container>& __rhs) > noexcept > { return __lhs.base() <= __rhs.base(); } > > template<typename _Iterator, typename _Container> > inline bool > operator<=(const __normal_iterator<_Iterator, _Container>& __lhs, > const __normal_iterator<_Iterator, _Container>& __rhs) > noexcept > { return __lhs.base() <= __rhs.base(); } > > template<typename _IteratorL, typename _IteratorR, typename _Container> > inline bool > operator>=(const __normal_iterator<_IteratorL, _Container>& __lhs, > const __normal_iterator<_IteratorR, _Container>& __rhs) > noexcept > { return __lhs.base() >= __rhs.base(); } > > template<typename _Iterator, typename _Container> > inline bool > operator>=(const __normal_iterator<_Iterator, _Container>& __lhs, > const __normal_iterator<_Iterator, _Container>& __rhs) > noexcept > { return __lhs.base() >= __rhs.base(); } > > > > > > template<typename _IteratorL, typename _IteratorR, typename _Container> > > > inline auto > operator-(const __normal_iterator<_IteratorL, _Container>& __lhs, > const __normal_iterator<_IteratorR, _Container>& __rhs) noexcept > -> decltype(__lhs.base() - __rhs.base()) > > > > > > { return __lhs.base() - __rhs.base(); } > > template<typename _Iterator, typename _Container> > inline typename __normal_iterator<_Iterator, _Container>::difference_type > operator-(const __normal_iterator<_Iterator, _Container>& __lhs, > const __normal_iterator<_Iterator, _Container>& __rhs) > noexcept > { return __lhs.base() - __rhs.base(); } > > template<typename _Iterator, typename _Container> > inline __normal_iterator<_Iterator, _Container> > operator+(typename __normal_iterator<_Iterator, _Container>::difference_type > __n, const __normal_iterator<_Iterator, _Container>& __i) > noexcept > { return __normal_iterator<_Iterator, _Container>(__i.base() + __n); } > > >} > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 961 "/usr/include/c++/4.9.0/bits/stl_iterator.h" 3 > template<typename _Iterator> > class move_iterator > { > protected: > _Iterator _M_current; > > typedef iterator_traits<_Iterator> __traits_type; > > public: > typedef _Iterator iterator_type; > typedef typename __traits_type::iterator_category iterator_category; > typedef typename __traits_type::value_type value_type; > typedef typename __traits_type::difference_type difference_type; > > typedef _Iterator pointer; > typedef value_type&& reference; > > move_iterator() > : _M_current() { } > > explicit > move_iterator(iterator_type __i) > : _M_current(__i) { } > > template<typename _Iter> > move_iterator(const move_iterator<_Iter>& __i) > : _M_current(__i.base()) { } > > iterator_type > base() const > { return _M_current; } > > reference > operator*() const > { return std::move(*_M_current); } > > pointer > operator->() const > { return _M_current; } > > move_iterator& > operator++() > { > ++_M_current; > return *this; > } > > move_iterator > operator++(int) > { > move_iterator __tmp = *this; > ++_M_current; > return __tmp; > } > > move_iterator& > operator--() > { > --_M_current; > return *this; > } > > move_iterator > operator--(int) > { > move_iterator __tmp = *this; > --_M_current; > return __tmp; > } > > move_iterator > operator+(difference_type __n) const > { return move_iterator(_M_current + __n); } > > move_iterator& > operator+=(difference_type __n) > { > _M_current += __n; > return *this; > } > > move_iterator > operator-(difference_type __n) const > { return move_iterator(_M_current - __n); } > > move_iterator& > operator-=(difference_type __n) > { > _M_current -= __n; > return *this; > } > > reference > operator[](difference_type __n) const > { return std::move(_M_current[__n]); } > }; > > > > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator==(const move_iterator<_IteratorL>& __x, > const move_iterator<_IteratorR>& __y) > { return __x.base() == __y.base(); } > > template<typename _Iterator> > inline bool > operator==(const move_iterator<_Iterator>& __x, > const move_iterator<_Iterator>& __y) > { return __x.base() == __y.base(); } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator!=(const move_iterator<_IteratorL>& __x, > const move_iterator<_IteratorR>& __y) > { return !(__x == __y); } > > template<typename _Iterator> > inline bool > operator!=(const move_iterator<_Iterator>& __x, > const move_iterator<_Iterator>& __y) > { return !(__x == __y); } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator<(const move_iterator<_IteratorL>& __x, > const move_iterator<_IteratorR>& __y) > { return __x.base() < __y.base(); } > > template<typename _Iterator> > inline bool > operator<(const move_iterator<_Iterator>& __x, > const move_iterator<_Iterator>& __y) > { return __x.base() < __y.base(); } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator<=(const move_iterator<_IteratorL>& __x, > const move_iterator<_IteratorR>& __y) > { return !(__y < __x); } > > template<typename _Iterator> > inline bool > operator<=(const move_iterator<_Iterator>& __x, > const move_iterator<_Iterator>& __y) > { return !(__y < __x); } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator>(const move_iterator<_IteratorL>& __x, > const move_iterator<_IteratorR>& __y) > { return __y < __x; } > > template<typename _Iterator> > inline bool > operator>(const move_iterator<_Iterator>& __x, > const move_iterator<_Iterator>& __y) > { return __y < __x; } > > template<typename _IteratorL, typename _IteratorR> > inline bool > operator>=(const move_iterator<_IteratorL>& __x, > const move_iterator<_IteratorR>& __y) > { return !(__x < __y); } > > template<typename _Iterator> > inline bool > operator>=(const move_iterator<_Iterator>& __x, > const move_iterator<_Iterator>& __y) > { return !(__x < __y); } > > > template<typename _IteratorL, typename _IteratorR> > inline auto > operator-(const move_iterator<_IteratorL>& __x, > const move_iterator<_IteratorR>& __y) > -> decltype(__x.base() - __y.base()) > { return __x.base() - __y.base(); } > > template<typename _Iterator> > inline auto > operator-(const move_iterator<_Iterator>& __x, > const move_iterator<_Iterator>& __y) > -> decltype(__x.base() - __y.base()) > { return __x.base() - __y.base(); } > > template<typename _Iterator> > inline move_iterator<_Iterator> > operator+(typename move_iterator<_Iterator>::difference_type __n, > const move_iterator<_Iterator>& __x) > { return __x + __n; } > > template<typename _Iterator> > inline move_iterator<_Iterator> > make_move_iterator(_Iterator __i) > { return move_iterator<_Iterator>(__i); } > > template<typename _Iterator, typename _ReturnType > = typename conditional<__move_if_noexcept_cond > <typename iterator_traits<_Iterator>::value_type>::value, > _Iterator, move_iterator<_Iterator>>::type> > inline _ReturnType > __make_move_if_noexcept_iterator(_Iterator __i) > { return _ReturnType(__i); } > > > > >} ># 64 "/usr/include/c++/4.9.0/iterator" 2 3 ># 1 "/usr/include/c++/4.9.0/ostream" 1 3 ># 36 "/usr/include/c++/4.9.0/ostream" 3 ># 37 "/usr/include/c++/4.9.0/ostream" 3 > ># 1 "/usr/include/c++/4.9.0/ios" 1 3 ># 36 "/usr/include/c++/4.9.0/ios" 3 ># 37 "/usr/include/c++/4.9.0/ios" 3 > ># 1 "/usr/include/c++/4.9.0/iosfwd" 1 3 ># 36 "/usr/include/c++/4.9.0/iosfwd" 3 ># 37 "/usr/include/c++/4.9.0/iosfwd" 3 > > ># 1 "/usr/include/c++/4.9.0/bits/stringfwd.h" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/stringfwd.h" 3 ># 38 "/usr/include/c++/4.9.0/bits/stringfwd.h" 3 > > ># 1 "/usr/include/c++/4.9.0/bits/memoryfwd.h" 1 3 ># 46 "/usr/include/c++/4.9.0/bits/memoryfwd.h" 3 ># 47 "/usr/include/c++/4.9.0/bits/memoryfwd.h" 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 63 "/usr/include/c++/4.9.0/bits/memoryfwd.h" 3 > template<typename> > class allocator; > > template<> > class allocator<void>; > > > template<typename, typename> > struct uses_allocator; > > > > >} ># 41 "/usr/include/c++/4.9.0/bits/stringfwd.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 52 "/usr/include/c++/4.9.0/bits/stringfwd.h" 3 > template<class _CharT> > struct char_traits; > > template<typename _CharT, typename _Traits = char_traits<_CharT>, > typename _Alloc = allocator<_CharT> > > class basic_string; > > template<> struct char_traits<char>; > > > typedef basic_string<char> string; > > > template<> struct char_traits<wchar_t>; > > > typedef basic_string<wchar_t> wstring; > > > > > > template<> struct char_traits<char16_t>; > template<> struct char_traits<char32_t>; > > > typedef basic_string<char16_t> u16string; > > > typedef basic_string<char32_t> u32string; > > > > > >} ># 40 "/usr/include/c++/4.9.0/iosfwd" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/postypes.h" 1 3 ># 38 "/usr/include/c++/4.9.0/bits/postypes.h" 3 ># 39 "/usr/include/c++/4.9.0/bits/postypes.h" 3 > ># 1 "/usr/include/c++/4.9.0/cwchar" 1 3 ># 39 "/usr/include/c++/4.9.0/cwchar" 3 ># 40 "/usr/include/c++/4.9.0/cwchar" 3 > > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 45 "/usr/include/c++/4.9.0/cwchar" 2 3 ># 62 "/usr/include/c++/4.9.0/cwchar" 3 >namespace std >{ > using ::mbstate_t; >} ># 135 "/usr/include/c++/4.9.0/cwchar" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > using ::wint_t; > > using ::btowc; > using ::fgetwc; > using ::fgetws; > using ::fputwc; > using ::fputws; > using ::fwide; > using ::fwprintf; > using ::fwscanf; > using ::getwc; > using ::getwchar; > using ::mbrlen; > using ::mbrtowc; > using ::mbsinit; > using ::mbsrtowcs; > using ::putwc; > using ::putwchar; > > using ::swprintf; > > using ::swscanf; > using ::ungetwc; > using ::vfwprintf; > > using ::vfwscanf; > > > using ::vswprintf; > > > using ::vswscanf; > > using ::vwprintf; > > using ::vwscanf; > > using ::wcrtomb; > using ::wcscat; > using ::wcscmp; > using ::wcscoll; > using ::wcscpy; > using ::wcscspn; > using ::wcsftime; > using ::wcslen; > using ::wcsncat; > using ::wcsncmp; > using ::wcsncpy; > using ::wcsrtombs; > using ::wcsspn; > using ::wcstod; > > using ::wcstof; > > using ::wcstok; > using ::wcstol; > using ::wcstoul; > using ::wcsxfrm; > using ::wctob; > using ::wmemcmp; > using ::wmemcpy; > using ::wmemmove; > using ::wmemset; > using ::wprintf; > using ::wscanf; > using ::wcschr; > using ::wcspbrk; > using ::wcsrchr; > using ::wcsstr; > using ::wmemchr; ># 232 "/usr/include/c++/4.9.0/cwchar" 3 > >} > > > > > > > >namespace __gnu_cxx >{ > > > > > > using ::wcstold; ># 257 "/usr/include/c++/4.9.0/cwchar" 3 > using ::wcstoll; > using ::wcstoull; > >} > >namespace std >{ > using ::__gnu_cxx::wcstold; > using ::__gnu_cxx::wcstoll; > using ::__gnu_cxx::wcstoull; >} ># 277 "/usr/include/c++/4.9.0/cwchar" 3 >namespace std >{ > > using std::wcstof; > > > using std::vfwscanf; > > > using std::vswscanf; > > > using std::vwscanf; > > > > using std::wcstold; > using std::wcstoll; > using std::wcstoull; > >} ># 41 "/usr/include/c++/4.9.0/bits/postypes.h" 2 3 ># 68 "/usr/include/c++/4.9.0/bits/postypes.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 88 "/usr/include/c++/4.9.0/bits/postypes.h" 3 > typedef long streamoff; ># 98 "/usr/include/c++/4.9.0/bits/postypes.h" 3 > typedef ptrdiff_t streamsize; ># 111 "/usr/include/c++/4.9.0/bits/postypes.h" 3 > template<typename _StateT> > class fpos > { > private: > streamoff _M_off; > _StateT _M_state; > > public: > > > > > fpos() > : _M_off(0), _M_state() { } ># 133 "/usr/include/c++/4.9.0/bits/postypes.h" 3 > fpos(streamoff __off) > : _M_off(__off), _M_state() { } > > > operator streamoff() const { return _M_off; } > > > void > state(_StateT __st) > { _M_state = __st; } > > > _StateT > state() const > { return _M_state; } > > > > > > fpos& > operator+=(streamoff __off) > { > _M_off += __off; > return *this; > } > > > > > > fpos& > operator-=(streamoff __off) > { > _M_off -= __off; > return *this; > } > > > > > > > > fpos > operator+(streamoff __off) const > { > fpos __pos(*this); > __pos += __off; > return __pos; > } > > > > > > > > fpos > operator-(streamoff __off) const > { > fpos __pos(*this); > __pos -= __off; > return __pos; > } > > > > > > > streamoff > operator-(const fpos& __other) const > { return _M_off - __other._M_off; } > }; > > > > > > > template<typename _StateT> > inline bool > operator==(const fpos<_StateT>& __lhs, const fpos<_StateT>& __rhs) > { return streamoff(__lhs) == streamoff(__rhs); } > > template<typename _StateT> > inline bool > operator!=(const fpos<_StateT>& __lhs, const fpos<_StateT>& __rhs) > { return streamoff(__lhs) != streamoff(__rhs); } > > > > > > typedef fpos<mbstate_t> streampos; > > typedef fpos<mbstate_t> wstreampos; > > > > typedef fpos<mbstate_t> u16streampos; > > typedef fpos<mbstate_t> u32streampos; > > > >} ># 41 "/usr/include/c++/4.9.0/iosfwd" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 74 "/usr/include/c++/4.9.0/iosfwd" 3 > class ios_base; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class basic_ios; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class basic_streambuf; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class basic_istream; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class basic_ostream; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class basic_iostream; > > template<typename _CharT, typename _Traits = char_traits<_CharT>, > typename _Alloc = allocator<_CharT> > > class basic_stringbuf; > > template<typename _CharT, typename _Traits = char_traits<_CharT>, > typename _Alloc = allocator<_CharT> > > class basic_istringstream; > > template<typename _CharT, typename _Traits = char_traits<_CharT>, > typename _Alloc = allocator<_CharT> > > class basic_ostringstream; > > template<typename _CharT, typename _Traits = char_traits<_CharT>, > typename _Alloc = allocator<_CharT> > > class basic_stringstream; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class basic_filebuf; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class basic_ifstream; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class basic_ofstream; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class basic_fstream; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class istreambuf_iterator; > > template<typename _CharT, typename _Traits = char_traits<_CharT> > > class ostreambuf_iterator; > > > > typedef basic_ios<char> ios; > > > typedef basic_streambuf<char> streambuf; > > > typedef basic_istream<char> istream; > > > typedef basic_ostream<char> ostream; > > > typedef basic_iostream<char> iostream; > > > typedef basic_stringbuf<char> stringbuf; > > > typedef basic_istringstream<char> istringstream; > > > typedef basic_ostringstream<char> ostringstream; > > > typedef basic_stringstream<char> stringstream; > > > typedef basic_filebuf<char> filebuf; > > > typedef basic_ifstream<char> ifstream; > > > typedef basic_ofstream<char> ofstream; > > > typedef basic_fstream<char> fstream; > > > > typedef basic_ios<wchar_t> wios; > > > typedef basic_streambuf<wchar_t> wstreambuf; > > > typedef basic_istream<wchar_t> wistream; > > > typedef basic_ostream<wchar_t> wostream; > > > typedef basic_iostream<wchar_t> wiostream; > > > typedef basic_stringbuf<wchar_t> wstringbuf; > > > typedef basic_istringstream<wchar_t> wistringstream; > > > typedef basic_ostringstream<wchar_t> wostringstream; > > > typedef basic_stringstream<wchar_t> wstringstream; > > > typedef basic_filebuf<wchar_t> wfilebuf; > > > typedef basic_ifstream<wchar_t> wifstream; > > > typedef basic_ofstream<wchar_t> wofstream; > > > typedef basic_fstream<wchar_t> wfstream; > > > > >} ># 39 "/usr/include/c++/4.9.0/ios" 2 3 ># 1 "/usr/include/c++/4.9.0/exception" 1 3 ># 33 "/usr/include/c++/4.9.0/exception" 3 ># 34 "/usr/include/c++/4.9.0/exception" 3 > >#pragma GCC visibility push(default) > > ># 1 "/usr/include/c++/4.9.0/bits/atomic_lockfree_defines.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/atomic_lockfree_defines.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/atomic_lockfree_defines.h" 3 ># 39 "/usr/include/c++/4.9.0/exception" 2 3 > >extern "C++" { > >namespace std >{ ># 60 "/usr/include/c++/4.9.0/exception" 3 > class exception > { > public: > exception() noexcept { } > virtual ~exception() noexcept; > > > > virtual const char* what() const noexcept; > }; > > > > class bad_exception : public exception > { > public: > bad_exception() noexcept { } > > > > virtual ~bad_exception() noexcept; > > > virtual const char* what() const noexcept; > }; > > > typedef void (*terminate_handler) (); > > > typedef void (*unexpected_handler) (); > > > terminate_handler set_terminate(terminate_handler) noexcept; > > > > terminate_handler get_terminate() noexcept; > > > > > void terminate() noexcept __attribute__ ((__noreturn__)); > > > unexpected_handler set_unexpected(unexpected_handler) noexcept; > > > > unexpected_handler get_unexpected() noexcept; > > > > > void unexpected() __attribute__ ((__noreturn__)); ># 127 "/usr/include/c++/4.9.0/exception" 3 > bool uncaught_exception() noexcept __attribute__ ((__pure__)); > > >} > >namespace __gnu_cxx >{ ># 152 "/usr/include/c++/4.9.0/exception" 3 > void __verbose_terminate_handler(); > > >} > >} > >#pragma GCC visibility pop > > ># 1 "/usr/include/c++/4.9.0/bits/exception_ptr.h" 1 3 ># 34 "/usr/include/c++/4.9.0/bits/exception_ptr.h" 3 >#pragma GCC visibility push(default) > > ># 1 "/usr/include/c++/4.9.0/bits/exception_defines.h" 1 3 ># 38 "/usr/include/c++/4.9.0/bits/exception_ptr.h" 2 3 > > > > > >extern "C++" { > >namespace std >{ > class type_info; > > > > > > namespace __exception_ptr > { > class exception_ptr; > } > > using __exception_ptr::exception_ptr; > > > > > > exception_ptr current_exception() noexcept; > > > void rethrow_exception(exception_ptr) __attribute__ ((__noreturn__)); > > namespace __exception_ptr > { > > > > > class exception_ptr > { > void* _M_exception_object; > > explicit exception_ptr(void* __e) noexcept; > > void _M_addref() noexcept; > void _M_release() noexcept; > > void *_M_get() const noexcept __attribute__ ((__pure__)); > > friend exception_ptr std::current_exception() noexcept; > friend void std::rethrow_exception(exception_ptr); > > public: > exception_ptr() noexcept; > > exception_ptr(const exception_ptr&) noexcept; > > > exception_ptr(nullptr_t) noexcept > : _M_exception_object(0) > { } > > exception_ptr(exception_ptr&& __o) noexcept > : _M_exception_object(__o._M_exception_object) > { __o._M_exception_object = 0; } ># 111 "/usr/include/c++/4.9.0/bits/exception_ptr.h" 3 > exception_ptr& > operator=(const exception_ptr&) noexcept; > > > exception_ptr& > operator=(exception_ptr&& __o) noexcept > { > exception_ptr(static_cast<exception_ptr&&>(__o)).swap(*this); > return *this; > } > > > ~exception_ptr() noexcept; > > void > swap(exception_ptr&) noexcept; ># 138 "/usr/include/c++/4.9.0/bits/exception_ptr.h" 3 > explicit operator bool() const > { return _M_exception_object; } > > > friend bool > operator==(const exception_ptr&, const exception_ptr&) > noexcept __attribute__ ((__pure__)); > > const class std::type_info* > __cxa_exception_type() const noexcept > __attribute__ ((__pure__)); > }; > > bool > operator==(const exception_ptr&, const exception_ptr&) > noexcept __attribute__ ((__pure__)); > > bool > operator!=(const exception_ptr&, const exception_ptr&) > noexcept __attribute__ ((__pure__)); > > inline void > swap(exception_ptr& __lhs, exception_ptr& __rhs) > { __lhs.swap(__rhs); } > > } > > > > template<typename _Ex> > exception_ptr > make_exception_ptr(_Ex __ex) noexcept > { > try > { > > throw __ex; > > } > catch(...) > { > return current_exception(); > } > } > > > > > > template<typename _Ex> > exception_ptr > copy_exception(_Ex __ex) noexcept __attribute__ ((__deprecated__)); > > template<typename _Ex> > exception_ptr > copy_exception(_Ex __ex) noexcept > { return std::make_exception_ptr<_Ex>(__ex); } > > >} > >} > >#pragma GCC visibility pop ># 163 "/usr/include/c++/4.9.0/exception" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/nested_exception.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/nested_exception.h" 3 >#pragma GCC visibility push(default) ># 45 "/usr/include/c++/4.9.0/bits/nested_exception.h" 3 >extern "C++" { > >namespace std >{ > > > > > > > class nested_exception > { > exception_ptr _M_ptr; > > public: > nested_exception() noexcept : _M_ptr(current_exception()) { } > > nested_exception(const nested_exception&) = default; > > nested_exception& operator=(const nested_exception&) = default; > > virtual ~nested_exception() noexcept; > > void > rethrow_nested() const __attribute__ ((__noreturn__)) > { rethrow_exception(_M_ptr); } > > exception_ptr > nested_ptr() const > { return _M_ptr; } > }; > > template<typename _Except> > struct _Nested_exception : public _Except, public nested_exception > { > explicit _Nested_exception(_Except&& __ex) > : _Except(static_cast<_Except&&>(__ex)) > { } > }; > > template<typename _Ex> > struct __get_nested_helper > { > static const nested_exception* > _S_get(const _Ex& __ex) > { return dynamic_cast<const nested_exception*>(&__ex); } > }; > > template<typename _Ex> > struct __get_nested_helper<_Ex*> > { > static const nested_exception* > _S_get(const _Ex* __ex) > { return dynamic_cast<const nested_exception*>(__ex); } > }; > > template<typename _Ex> > inline const nested_exception* > __get_nested_exception(const _Ex& __ex) > { return __get_nested_helper<_Ex>::_S_get(__ex); } > > template<typename _Ex> > void > __throw_with_nested(_Ex&&, const nested_exception* = 0) > __attribute__ ((__noreturn__)); > > template<typename _Ex> > void > __throw_with_nested(_Ex&&, ...) __attribute__ ((__noreturn__)); > > > > > template<typename _Ex> > inline void > __throw_with_nested(_Ex&& __ex, const nested_exception*) > { throw __ex; } > > template<typename _Ex> > inline void > __throw_with_nested(_Ex&& __ex, ...) > { throw _Nested_exception<_Ex>(static_cast<_Ex&&>(__ex)); } > > template<typename _Ex> > void > throw_with_nested(_Ex __ex) __attribute__ ((__noreturn__)); > > > > template<typename _Ex> > inline void > throw_with_nested(_Ex __ex) > { > if (__get_nested_exception(__ex)) > throw __ex; > __throw_with_nested(static_cast<_Ex&&>(__ex), &__ex); > } > > > template<typename _Ex> > inline void > rethrow_if_nested(const _Ex& __ex) > { > if (const nested_exception* __nested = __get_nested_exception(__ex)) > __nested->rethrow_nested(); > } > > > inline void > rethrow_if_nested(const nested_exception& __ex) > { __ex.rethrow_nested(); } > > >} > >} > > > >#pragma GCC visibility pop ># 164 "/usr/include/c++/4.9.0/exception" 2 3 ># 40 "/usr/include/c++/4.9.0/ios" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/char_traits.h" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/char_traits.h" 3 ># 38 "/usr/include/c++/4.9.0/bits/char_traits.h" 3 > ># 1 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 1 3 ># 60 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 ># 1 "/usr/include/c++/4.9.0/bits/functexcept.h" 1 3 ># 42 "/usr/include/c++/4.9.0/bits/functexcept.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > void > __throw_bad_exception(void) __attribute__((__noreturn__)); > > > void > __throw_bad_alloc(void) __attribute__((__noreturn__)); > > > void > __throw_bad_cast(void) __attribute__((__noreturn__)); > > void > __throw_bad_typeid(void) __attribute__((__noreturn__)); > > > void > __throw_logic_error(const char*) __attribute__((__noreturn__)); > > void > __throw_domain_error(const char*) __attribute__((__noreturn__)); > > void > __throw_invalid_argument(const char*) __attribute__((__noreturn__)); > > void > __throw_length_error(const char*) __attribute__((__noreturn__)); > > void > __throw_out_of_range(const char*) __attribute__((__noreturn__)); > > void > __throw_out_of_range_fmt(const char*, ...) __attribute__((__noreturn__)) > __attribute__((__format__(__printf__, 1, 2))); > > void > __throw_runtime_error(const char*) __attribute__((__noreturn__)); > > void > __throw_range_error(const char*) __attribute__((__noreturn__)); > > void > __throw_overflow_error(const char*) __attribute__((__noreturn__)); > > void > __throw_underflow_error(const char*) __attribute__((__noreturn__)); > > > void > __throw_ios_failure(const char*) __attribute__((__noreturn__)); > > void > __throw_system_error(int) __attribute__((__noreturn__)); > > void > __throw_future_error(int) __attribute__((__noreturn__)); > > > void > __throw_bad_function_call() __attribute__((__noreturn__)); > > >} ># 61 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 2 3 > > ># 1 "/usr/include/c++/4.9.0/ext/numeric_traits.h" 1 3 ># 32 "/usr/include/c++/4.9.0/ext/numeric_traits.h" 3 ># 33 "/usr/include/c++/4.9.0/ext/numeric_traits.h" 3 > > > > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ ># 54 "/usr/include/c++/4.9.0/ext/numeric_traits.h" 3 > template<typename _Value> > struct __numeric_traits_integer > { > > static const _Value __min = (((_Value)(-1) < 0) ? (_Value)1 << (sizeof(_Value) * 8 - ((_Value)(-1) < 0)) : (_Value)0); > static const _Value __max = (((_Value)(-1) < 0) ? (((((_Value)1 << ((sizeof(_Value) * 8 - ((_Value)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(_Value)0); > > > > static const bool __is_signed = ((_Value)(-1) < 0); > static const int __digits = (sizeof(_Value) * 8 - ((_Value)(-1) < 0)); > }; > > template<typename _Value> > const _Value __numeric_traits_integer<_Value>::__min; > > template<typename _Value> > const _Value __numeric_traits_integer<_Value>::__max; > > template<typename _Value> > const bool __numeric_traits_integer<_Value>::__is_signed; > > template<typename _Value> > const int __numeric_traits_integer<_Value>::__digits; ># 99 "/usr/include/c++/4.9.0/ext/numeric_traits.h" 3 > template<typename _Value> > struct __numeric_traits_floating > { > > static const int __max_digits10 = (2 + (std::__are_same<_Value, float>::__value ? 24 : std::__are_same<_Value, double>::__value ? 53 : 64) * 643L / 2136); > > > static const bool __is_signed = true; > static const int __digits10 = (std::__are_same<_Value, float>::__value ? 6 : std::__are_same<_Value, double>::__value ? 15 : 18); > static const int __max_exponent10 = (std::__are_same<_Value, float>::__value ? 38 : std::__are_same<_Value, double>::__value ? 308 : 4932); > }; > > template<typename _Value> > const int __numeric_traits_floating<_Value>::__max_digits10; > > template<typename _Value> > const bool __numeric_traits_floating<_Value>::__is_signed; > > template<typename _Value> > const int __numeric_traits_floating<_Value>::__digits10; > > template<typename _Value> > const int __numeric_traits_floating<_Value>::__max_exponent10; > > template<typename _Value> > struct __numeric_traits > : public __conditional_type<std::__is_integer<_Value>::__value, > __numeric_traits_integer<_Value>, > __numeric_traits_floating<_Value> >::__type > { }; > > >} ># 64 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 2 3 > > > > > > > ># 1 "/usr/include/c++/4.9.0/bits/predefined_ops.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/predefined_ops.h" 3 >namespace __gnu_cxx >{ >namespace __ops >{ > struct _Iter_less_iter > { > template<typename _Iterator1, typename _Iterator2> > bool > operator()(_Iterator1 __it1, _Iterator2 __it2) const > { return *__it1 < *__it2; } > }; > > inline _Iter_less_iter > __iter_less_iter() > { return _Iter_less_iter(); } > > struct _Iter_less_val > { > template<typename _Iterator, typename _Value> > bool > operator()(_Iterator __it, _Value& __val) const > { return *__it < __val; } > }; > > inline _Iter_less_val > __iter_less_val() > { return _Iter_less_val(); } > > inline _Iter_less_val > __iter_comp_val(_Iter_less_iter) > { return _Iter_less_val(); } > > struct _Val_less_iter > { > template<typename _Value, typename _Iterator> > bool > operator()(_Value& __val, _Iterator __it) const > { return __val < *__it; } > }; > > inline _Val_less_iter > __val_less_iter() > { return _Val_less_iter(); } > > inline _Val_less_iter > __val_comp_iter(_Iter_less_iter) > { return _Val_less_iter(); } > > struct _Iter_equal_to_iter > { > template<typename _Iterator1, typename _Iterator2> > bool > operator()(_Iterator1 __it1, _Iterator2 __it2) const > { return *__it1 == *__it2; } > }; > > inline _Iter_equal_to_iter > __iter_equal_to_iter() > { return _Iter_equal_to_iter(); } > > struct _Iter_equal_to_val > { > template<typename _Iterator, typename _Value> > bool > operator()(_Iterator __it, _Value& __val) const > { return *__it == __val; } > }; > > inline _Iter_equal_to_val > __iter_equal_to_val() > { return _Iter_equal_to_val(); } > > inline _Iter_equal_to_val > __iter_comp_val(_Iter_equal_to_iter) > { return _Iter_equal_to_val(); } > > template<typename _Compare> > struct _Iter_comp_iter > { > _Compare _M_comp; > > _Iter_comp_iter(_Compare __comp) > : _M_comp(__comp) > { } > > template<typename _Iterator1, typename _Iterator2> > bool > operator()(_Iterator1 __it1, _Iterator2 __it2) > { return bool(_M_comp(*__it1, *__it2)); } > }; > > template<typename _Compare> > inline _Iter_comp_iter<_Compare> > __iter_comp_iter(_Compare __comp) > { return _Iter_comp_iter<_Compare>(__comp); } > > template<typename _Compare> > struct _Iter_comp_val > { > _Compare _M_comp; > > _Iter_comp_val(_Compare __comp) > : _M_comp(__comp) > { } > > template<typename _Iterator, typename _Value> > bool > operator()(_Iterator __it, _Value& __val) > { return bool(_M_comp(*__it, __val)); } > }; > > template<typename _Compare> > inline _Iter_comp_val<_Compare> > __iter_comp_val(_Compare __comp) > { return _Iter_comp_val<_Compare>(__comp); } > > template<typename _Compare> > inline _Iter_comp_val<_Compare> > __iter_comp_val(_Iter_comp_iter<_Compare> __comp) > { return _Iter_comp_val<_Compare>(__comp._M_comp); } > > template<typename _Compare> > struct _Val_comp_iter > { > _Compare _M_comp; > > _Val_comp_iter(_Compare __comp) > : _M_comp(__comp) > { } > > template<typename _Value, typename _Iterator> > bool > operator()(_Value& __val, _Iterator __it) > { return bool(_M_comp(__val, *__it)); } > }; > > template<typename _Compare> > inline _Val_comp_iter<_Compare> > __val_comp_iter(_Compare __comp) > { return _Val_comp_iter<_Compare>(__comp); } > > template<typename _Compare> > inline _Val_comp_iter<_Compare> > __val_comp_iter(_Iter_comp_iter<_Compare> __comp) > { return _Val_comp_iter<_Compare>(__comp._M_comp); } > > template<typename _Value> > struct _Iter_equals_val > { > _Value& _M_value; > > _Iter_equals_val(_Value& __value) > : _M_value(__value) > { } > > template<typename _Iterator> > bool > operator()(_Iterator __it) > { return *__it == _M_value; } > }; > > template<typename _Value> > inline _Iter_equals_val<_Value> > __iter_equals_val(_Value& __val) > { return _Iter_equals_val<_Value>(__val); } > > template<typename _Iterator1> > struct _Iter_equals_iter > { > typename std::iterator_traits<_Iterator1>::reference _M_ref; > > _Iter_equals_iter(_Iterator1 __it1) > : _M_ref(*__it1) > { } > > template<typename _Iterator2> > bool > operator()(_Iterator2 __it2) > { return *__it2 == _M_ref; } > }; > > template<typename _Iterator> > inline _Iter_equals_iter<_Iterator> > __iter_comp_iter(_Iter_equal_to_iter, _Iterator __it) > { return _Iter_equals_iter<_Iterator>(__it); } > > template<typename _Predicate> > struct _Iter_pred > { > _Predicate _M_pred; > > _Iter_pred(_Predicate __pred) > : _M_pred(__pred) > { } > > template<typename _Iterator> > bool > operator()(_Iterator __it) > { return bool(_M_pred(*__it)); } > }; > > template<typename _Predicate> > inline _Iter_pred<_Predicate> > __pred_iter(_Predicate __pred) > { return _Iter_pred<_Predicate>(__pred); } > > template<typename _Compare, typename _Value> > struct _Iter_comp_to_val > { > _Compare _M_comp; > _Value& _M_value; > > _Iter_comp_to_val(_Compare __comp, _Value& __value) > : _M_comp(__comp), _M_value(__value) > { } > > template<typename _Iterator> > bool > operator()(_Iterator __it) > { return bool(_M_comp(*__it, _M_value)); } > }; > > template<typename _Compare, typename _Value> > _Iter_comp_to_val<_Compare, _Value> > __iter_comp_val(_Compare __comp, _Value &__val) > { return _Iter_comp_to_val<_Compare, _Value>(__comp, __val); } > > template<typename _Compare, typename _Iterator1> > struct _Iter_comp_to_iter > { > _Compare _M_comp; > typename std::iterator_traits<_Iterator1>::reference _M_ref; > > _Iter_comp_to_iter(_Compare __comp, _Iterator1 __it1) > : _M_comp(__comp), _M_ref(*__it1) > { } > > template<typename _Iterator2> > bool > operator()(_Iterator2 __it2) > { return bool(_M_comp(*__it2, _M_ref)); } > }; > > template<typename _Compare, typename _Iterator> > inline _Iter_comp_to_iter<_Compare, _Iterator> > __iter_comp_iter(_Iter_comp_iter<_Compare> __comp, _Iterator __it) > { return _Iter_comp_to_iter<_Compare, _Iterator>(__comp._M_comp, __it); } > > template<typename _Predicate> > struct _Iter_negate > { > _Predicate _M_pred; > > _Iter_negate(_Predicate __pred) > : _M_pred(__pred) > { } > > template<typename _Iterator> > bool > operator()(_Iterator __it) > { return !bool(_M_pred(*__it)); } > }; > > template<typename _Predicate> > inline _Iter_negate<_Predicate> > __negate(_Iter_pred<_Predicate> __pred) > { return _Iter_negate<_Predicate>(__pred._M_pred); } > >} >} ># 72 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 118 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _ForwardIterator1, typename _ForwardIterator2> > inline void > iter_swap(_ForwardIterator1 __a, _ForwardIterator2 __b) > { ># 148 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > swap(*__a, *__b); > > } ># 164 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _ForwardIterator1, typename _ForwardIterator2> > _ForwardIterator2 > swap_ranges(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2) > { > > > > > > ; > > for (; __first1 != __last1; ++__first1, ++__first2) > std::iter_swap(__first1, __first2); > return __first2; > } ># 192 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _Tp> > inline const _Tp& > min(const _Tp& __a, const _Tp& __b) > { > > > > if (__b < __a) > return __b; > return __a; > } ># 215 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _Tp> > inline const _Tp& > max(const _Tp& __a, const _Tp& __b) > { > > > > if (__a < __b) > return __b; > return __a; > } ># 238 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _Tp, typename _Compare> > inline const _Tp& > min(const _Tp& __a, const _Tp& __b, _Compare __comp) > { > > if (__comp(__b, __a)) > return __b; > return __a; > } ># 259 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _Tp, typename _Compare> > inline const _Tp& > max(const _Tp& __a, const _Tp& __b, _Compare __comp) > { > > if (__comp(__a, __b)) > return __b; > return __a; > } > > > > template<typename _Iterator> > struct _Niter_base > : _Iter_base<_Iterator, __is_normal_iterator<_Iterator>::__value> > { }; > > template<typename _Iterator> > inline typename _Niter_base<_Iterator>::iterator_type > __niter_base(_Iterator __it) > { return std::_Niter_base<_Iterator>::_S_base(__it); } > > > template<typename _Iterator> > struct _Miter_base > : _Iter_base<_Iterator, __is_move_iterator<_Iterator>::__value> > { }; > > template<typename _Iterator> > inline typename _Miter_base<_Iterator>::iterator_type > __miter_base(_Iterator __it) > { return std::_Miter_base<_Iterator>::_S_base(__it); } > > > > > > > > template<bool, bool, typename> > struct __copy_move > { > template<typename _II, typename _OI> > static _OI > __copy_m(_II __first, _II __last, _OI __result) > { > for (; __first != __last; ++__result, ++__first) > *__result = *__first; > return __result; > } > }; > > > template<typename _Category> > struct __copy_move<true, false, _Category> > { > template<typename _II, typename _OI> > static _OI > __copy_m(_II __first, _II __last, _OI __result) > { > for (; __first != __last; ++__result, ++__first) > *__result = std::move(*__first); > return __result; > } > }; > > > template<> > struct __copy_move<false, false, random_access_iterator_tag> > { > template<typename _II, typename _OI> > static _OI > __copy_m(_II __first, _II __last, _OI __result) > { > typedef typename iterator_traits<_II>::difference_type _Distance; > for(_Distance __n = __last - __first; __n > 0; --__n) > { > *__result = *__first; > ++__first; > ++__result; > } > return __result; > } > }; > > > template<> > struct __copy_move<true, false, random_access_iterator_tag> > { > template<typename _II, typename _OI> > static _OI > __copy_m(_II __first, _II __last, _OI __result) > { > typedef typename iterator_traits<_II>::difference_type _Distance; > for(_Distance __n = __last - __first; __n > 0; --__n) > { > *__result = std::move(*__first); > ++__first; > ++__result; > } > return __result; > } > }; > > > template<bool _IsMove> > struct __copy_move<_IsMove, true, random_access_iterator_tag> > { > template<typename _Tp> > static _Tp* > __copy_m(const _Tp* __first, const _Tp* __last, _Tp* __result) > { > > > static_assert( is_copy_assignable<_Tp>::value, > "type is not assignable" ); > > const ptrdiff_t _Num = __last - __first; > if (_Num) > __builtin_memmove(__result, __first, sizeof(_Tp) * _Num); > return __result + _Num; > } > }; > > template<bool _IsMove, typename _II, typename _OI> > inline _OI > __copy_move_a(_II __first, _II __last, _OI __result) > { > typedef typename iterator_traits<_II>::value_type _ValueTypeI; > typedef typename iterator_traits<_OI>::value_type _ValueTypeO; > typedef typename iterator_traits<_II>::iterator_category _Category; > const bool __simple = (__is_trivial(_ValueTypeI) > && __is_pointer<_II>::__value > && __is_pointer<_OI>::__value > && __are_same<_ValueTypeI, _ValueTypeO>::__value); > > return std::__copy_move<_IsMove, __simple, > _Category>::__copy_m(__first, __last, __result); > } > > > > template<typename _CharT> > struct char_traits; > > template<typename _CharT, typename _Traits> > class istreambuf_iterator; > > template<typename _CharT, typename _Traits> > class ostreambuf_iterator; > > template<bool _IsMove, typename _CharT> > typename __gnu_cxx::__enable_if<__is_char<_CharT>::__value, > ostreambuf_iterator<_CharT, char_traits<_CharT> > >::__type > __copy_move_a2(_CharT*, _CharT*, > ostreambuf_iterator<_CharT, char_traits<_CharT> >); > > template<bool _IsMove, typename _CharT> > typename __gnu_cxx::__enable_if<__is_char<_CharT>::__value, > ostreambuf_iterator<_CharT, char_traits<_CharT> > >::__type > __copy_move_a2(const _CharT*, const _CharT*, > ostreambuf_iterator<_CharT, char_traits<_CharT> >); > > template<bool _IsMove, typename _CharT> > typename __gnu_cxx::__enable_if<__is_char<_CharT>::__value, > _CharT*>::__type > __copy_move_a2(istreambuf_iterator<_CharT, char_traits<_CharT> >, > istreambuf_iterator<_CharT, char_traits<_CharT> >, _CharT*); > > template<bool _IsMove, typename _II, typename _OI> > inline _OI > __copy_move_a2(_II __first, _II __last, _OI __result) > { > return _OI(std::__copy_move_a<_IsMove>(std::__niter_base(__first), > std::__niter_base(__last), > std::__niter_base(__result))); > } ># 454 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _II, typename _OI> > inline _OI > copy(_II __first, _II __last, _OI __result) > { > > > > > ; > > return (std::__copy_move_a2<__is_move_iterator<_II>::__value> > (std::__miter_base(__first), std::__miter_base(__last), > __result)); > } ># 487 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _II, typename _OI> > inline _OI > move(_II __first, _II __last, _OI __result) > { > > > > > ; > > return std::__copy_move_a2<true>(std::__miter_base(__first), > std::__miter_base(__last), __result); > } > > > > > > > template<bool, bool, typename> > struct __copy_move_backward > { > template<typename _BI1, typename _BI2> > static _BI2 > __copy_move_b(_BI1 __first, _BI1 __last, _BI2 __result) > { > while (__first != __last) > *--__result = *--__last; > return __result; > } > }; > > > template<typename _Category> > struct __copy_move_backward<true, false, _Category> > { > template<typename _BI1, typename _BI2> > static _BI2 > __copy_move_b(_BI1 __first, _BI1 __last, _BI2 __result) > { > while (__first != __last) > *--__result = std::move(*--__last); > return __result; > } > }; > > > template<> > struct __copy_move_backward<false, false, random_access_iterator_tag> > { > template<typename _BI1, typename _BI2> > static _BI2 > __copy_move_b(_BI1 __first, _BI1 __last, _BI2 __result) > { > typename iterator_traits<_BI1>::difference_type __n; > for (__n = __last - __first; __n > 0; --__n) > *--__result = *--__last; > return __result; > } > }; > > > template<> > struct __copy_move_backward<true, false, random_access_iterator_tag> > { > template<typename _BI1, typename _BI2> > static _BI2 > __copy_move_b(_BI1 __first, _BI1 __last, _BI2 __result) > { > typename iterator_traits<_BI1>::difference_type __n; > for (__n = __last - __first; __n > 0; --__n) > *--__result = std::move(*--__last); > return __result; > } > }; > > > template<bool _IsMove> > struct __copy_move_backward<_IsMove, true, random_access_iterator_tag> > { > template<typename _Tp> > static _Tp* > __copy_move_b(const _Tp* __first, const _Tp* __last, _Tp* __result) > { > > > static_assert( is_copy_assignable<_Tp>::value, > "type is not assignable" ); > > const ptrdiff_t _Num = __last - __first; > if (_Num) > __builtin_memmove(__result - _Num, __first, sizeof(_Tp) * _Num); > return __result - _Num; > } > }; > > template<bool _IsMove, typename _BI1, typename _BI2> > inline _BI2 > __copy_move_backward_a(_BI1 __first, _BI1 __last, _BI2 __result) > { > typedef typename iterator_traits<_BI1>::value_type _ValueType1; > typedef typename iterator_traits<_BI2>::value_type _ValueType2; > typedef typename iterator_traits<_BI1>::iterator_category _Category; > const bool __simple = (__is_trivial(_ValueType1) > && __is_pointer<_BI1>::__value > && __is_pointer<_BI2>::__value > && __are_same<_ValueType1, _ValueType2>::__value); > > return std::__copy_move_backward<_IsMove, __simple, > _Category>::__copy_move_b(__first, > __last, > __result); > } > > template<bool _IsMove, typename _BI1, typename _BI2> > inline _BI2 > __copy_move_backward_a2(_BI1 __first, _BI1 __last, _BI2 __result) > { > return _BI2(std::__copy_move_backward_a<_IsMove> > (std::__niter_base(__first), std::__niter_base(__last), > std::__niter_base(__result))); > } ># 628 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _BI1, typename _BI2> > inline _BI2 > copy_backward(_BI1 __first, _BI1 __last, _BI2 __result) > { > > > > > > > ; > > return (std::__copy_move_backward_a2<__is_move_iterator<_BI1>::__value> > (std::__miter_base(__first), std::__miter_base(__last), > __result)); > } ># 664 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _BI1, typename _BI2> > inline _BI2 > move_backward(_BI1 __first, _BI1 __last, _BI2 __result) > { > > > > > > > ; > > return std::__copy_move_backward_a2<true>(std::__miter_base(__first), > std::__miter_base(__last), > __result); > } > > > > > > > template<typename _ForwardIterator, typename _Tp> > inline typename > __gnu_cxx::__enable_if<!__is_scalar<_Tp>::__value, void>::__type > __fill_a(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __value) > { > for (; __first != __last; ++__first) > *__first = __value; > } > > template<typename _ForwardIterator, typename _Tp> > inline typename > __gnu_cxx::__enable_if<__is_scalar<_Tp>::__value, void>::__type > __fill_a(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __value) > { > const _Tp __tmp = __value; > for (; __first != __last; ++__first) > *__first = __tmp; > } > > > template<typename _Tp> > inline typename > __gnu_cxx::__enable_if<__is_byte<_Tp>::__value, void>::__type > __fill_a(_Tp* __first, _Tp* __last, const _Tp& __c) > { > const _Tp __tmp = __c; > __builtin_memset(__first, static_cast<unsigned char>(__tmp), > __last - __first); > } ># 730 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _ForwardIterator, typename _Tp> > inline void > fill(_ForwardIterator __first, _ForwardIterator __last, const _Tp& __value) > { > > > > ; > > std::__fill_a(std::__niter_base(__first), std::__niter_base(__last), > __value); > } > > template<typename _OutputIterator, typename _Size, typename _Tp> > inline typename > __gnu_cxx::__enable_if<!__is_scalar<_Tp>::__value, _OutputIterator>::__type > __fill_n_a(_OutputIterator __first, _Size __n, const _Tp& __value) > { > for (__decltype(__n + 0) __niter = __n; > __niter > 0; --__niter, ++__first) > *__first = __value; > return __first; > } > > template<typename _OutputIterator, typename _Size, typename _Tp> > inline typename > __gnu_cxx::__enable_if<__is_scalar<_Tp>::__value, _OutputIterator>::__type > __fill_n_a(_OutputIterator __first, _Size __n, const _Tp& __value) > { > const _Tp __tmp = __value; > for (__decltype(__n + 0) __niter = __n; > __niter > 0; --__niter, ++__first) > *__first = __tmp; > return __first; > } > > template<typename _Size, typename _Tp> > inline typename > __gnu_cxx::__enable_if<__is_byte<_Tp>::__value, _Tp*>::__type > __fill_n_a(_Tp* __first, _Size __n, const _Tp& __c) > { > std::__fill_a(__first, __first + __n, __c); > return __first + __n; > } ># 790 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _OI, typename _Size, typename _Tp> > inline _OI > fill_n(_OI __first, _Size __n, const _Tp& __value) > { > > > > return _OI(std::__fill_n_a(std::__niter_base(__first), __n, __value)); > } > > template<bool _BoolType> > struct __equal > { > template<typename _II1, typename _II2> > static bool > equal(_II1 __first1, _II1 __last1, _II2 __first2) > { > for (; __first1 != __last1; ++__first1, ++__first2) > if (!(*__first1 == *__first2)) > return false; > return true; > } > }; > > template<> > struct __equal<true> > { > template<typename _Tp> > static bool > equal(const _Tp* __first1, const _Tp* __last1, const _Tp* __first2) > { > return !__builtin_memcmp(__first1, __first2, sizeof(_Tp) > * (__last1 - __first1)); > } > }; > > template<typename _II1, typename _II2> > inline bool > __equal_aux(_II1 __first1, _II1 __last1, _II2 __first2) > { > typedef typename iterator_traits<_II1>::value_type _ValueType1; > typedef typename iterator_traits<_II2>::value_type _ValueType2; > const bool __simple = ((__is_integer<_ValueType1>::__value > || __is_pointer<_ValueType1>::__value) > && __is_pointer<_II1>::__value > && __is_pointer<_II2>::__value > && __are_same<_ValueType1, _ValueType2>::__value); > > return std::__equal<__simple>::equal(__first1, __last1, __first2); > } > > template<typename, typename> > struct __lc_rai > { > template<typename _II1, typename _II2> > static _II1 > __newlast1(_II1, _II1 __last1, _II2, _II2) > { return __last1; } > > template<typename _II> > static bool > __cnd2(_II __first, _II __last) > { return __first != __last; } > }; > > template<> > struct __lc_rai<random_access_iterator_tag, random_access_iterator_tag> > { > template<typename _RAI1, typename _RAI2> > static _RAI1 > __newlast1(_RAI1 __first1, _RAI1 __last1, > _RAI2 __first2, _RAI2 __last2) > { > const typename iterator_traits<_RAI1>::difference_type > __diff1 = __last1 - __first1; > const typename iterator_traits<_RAI2>::difference_type > __diff2 = __last2 - __first2; > return __diff2 < __diff1 ? __first1 + __diff2 : __last1; > } > > template<typename _RAI> > static bool > __cnd2(_RAI, _RAI) > { return true; } > }; > > template<typename _II1, typename _II2, typename _Compare> > bool > __lexicographical_compare_impl(_II1 __first1, _II1 __last1, > _II2 __first2, _II2 __last2, > _Compare __comp) > { > typedef typename iterator_traits<_II1>::iterator_category _Category1; > typedef typename iterator_traits<_II2>::iterator_category _Category2; > typedef std::__lc_rai<_Category1, _Category2> __rai_type; > > __last1 = __rai_type::__newlast1(__first1, __last1, __first2, __last2); > for (; __first1 != __last1 && __rai_type::__cnd2(__first2, __last2); > ++__first1, ++__first2) > { > if (__comp(__first1, __first2)) > return true; > if (__comp(__first2, __first1)) > return false; > } > return __first1 == __last1 && __first2 != __last2; > } > > template<bool _BoolType> > struct __lexicographical_compare > { > template<typename _II1, typename _II2> > static bool __lc(_II1, _II1, _II2, _II2); > }; > > template<bool _BoolType> > template<typename _II1, typename _II2> > bool > __lexicographical_compare<_BoolType>:: > __lc(_II1 __first1, _II1 __last1, _II2 __first2, _II2 __last2) > { > return std::__lexicographical_compare_impl(__first1, __last1, > __first2, __last2, > __gnu_cxx::__ops::__iter_less_iter()); > } > > template<> > struct __lexicographical_compare<true> > { > template<typename _Tp, typename _Up> > static bool > __lc(const _Tp* __first1, const _Tp* __last1, > const _Up* __first2, const _Up* __last2) > { > const size_t __len1 = __last1 - __first1; > const size_t __len2 = __last2 - __first2; > const int __result = __builtin_memcmp(__first1, __first2, > std::min(__len1, __len2)); > return __result != 0 ? __result < 0 : __len1 < __len2; > } > }; > > template<typename _II1, typename _II2> > inline bool > __lexicographical_compare_aux(_II1 __first1, _II1 __last1, > _II2 __first2, _II2 __last2) > { > typedef typename iterator_traits<_II1>::value_type _ValueType1; > typedef typename iterator_traits<_II2>::value_type _ValueType2; > const bool __simple = > (__is_byte<_ValueType1>::__value && __is_byte<_ValueType2>::__value > && !__gnu_cxx::__numeric_traits<_ValueType1>::__is_signed > && !__gnu_cxx::__numeric_traits<_ValueType2>::__is_signed > && __is_pointer<_II1>::__value > && __is_pointer<_II2>::__value); > > return std::__lexicographical_compare<__simple>::__lc(__first1, __last1, > __first2, __last2); > } > > template<typename _ForwardIterator, typename _Tp, typename _Compare> > _ForwardIterator > __lower_bound(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val, _Compare __comp) > { > typedef typename iterator_traits<_ForwardIterator>::difference_type > _DistanceType; > > _DistanceType __len = std::distance(__first, __last); > > while (__len > 0) > { > _DistanceType __half = __len >> 1; > _ForwardIterator __middle = __first; > std::advance(__middle, __half); > if (__comp(__middle, __val)) > { > __first = __middle; > ++__first; > __len = __len - __half - 1; > } > else > __len = __half; > } > return __first; > } ># 988 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _ForwardIterator, typename _Tp> > inline _ForwardIterator > lower_bound(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val) > { > > > > > ; > > return std::__lower_bound(__first, __last, __val, > __gnu_cxx::__ops::__iter_less_val()); > } > > > > inline constexpr int > __lg(int __n) > { return sizeof(int) * 8 - 1 - __builtin_clz(__n); } > > inline constexpr unsigned > __lg(unsigned __n) > { return sizeof(int) * 8 - 1 - __builtin_clz(__n); } > > inline constexpr long > __lg(long __n) > { return sizeof(long) * 8 - 1 - __builtin_clzl(__n); } > > inline constexpr unsigned long > __lg(unsigned long __n) > { return sizeof(long) * 8 - 1 - __builtin_clzl(__n); } > > inline constexpr long long > __lg(long long __n) > { return sizeof(long long) * 8 - 1 - __builtin_clzll(__n); } > > inline constexpr unsigned long long > __lg(unsigned long long __n) > { return sizeof(long long) * 8 - 1 - __builtin_clzll(__n); } ># 1045 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _II1, typename _II2> > inline bool > equal(_II1 __first1, _II1 __last1, _II2 __first2) > { > > > > > > > ; > > return std::__equal_aux(std::__niter_base(__first1), > std::__niter_base(__last1), > std::__niter_base(__first2)); > } ># 1077 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _IIter1, typename _IIter2, typename _BinaryPredicate> > inline bool > equal(_IIter1 __first1, _IIter1 __last1, > _IIter2 __first2, _BinaryPredicate __binary_pred) > { > > > > ; > > for (; __first1 != __last1; ++__first1, ++__first2) > if (!bool(__binary_pred(*__first1, *__first2))) > return false; > return true; > } ># 1202 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _II1, typename _II2> > inline bool > lexicographical_compare(_II1 __first1, _II1 __last1, > _II2 __first2, _II2 __last2) > { ># 1216 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > ; > ; > > return std::__lexicographical_compare_aux(std::__niter_base(__first1), > std::__niter_base(__last1), > std::__niter_base(__first2), > std::__niter_base(__last2)); > } ># 1238 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _II1, typename _II2, typename _Compare> > inline bool > lexicographical_compare(_II1 __first1, _II1 __last1, > _II2 __first2, _II2 __last2, _Compare __comp) > { > > > > ; > ; > > return std::__lexicographical_compare_impl > (__first1, __last1, __first2, __last2, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _InputIterator1, typename _InputIterator2, > typename _BinaryPredicate> > pair<_InputIterator1, _InputIterator2> > __mismatch(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _BinaryPredicate __binary_pred) > { > while (__first1 != __last1 && __binary_pred(__first1, __first2)) > { > ++__first1; > ++__first2; > } > return pair<_InputIterator1, _InputIterator2>(__first1, __first2); > } ># 1281 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _InputIterator1, typename _InputIterator2> > inline pair<_InputIterator1, _InputIterator2> > mismatch(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2) > { > > > > > > > ; > > return std::__mismatch(__first1, __last1, __first2, > __gnu_cxx::__ops::__iter_equal_to_iter()); > } ># 1314 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _BinaryPredicate> > inline pair<_InputIterator1, _InputIterator2> > mismatch(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _BinaryPredicate __binary_pred) > { > > > > ; > > return std::__mismatch(__first1, __last1, __first2, > __gnu_cxx::__ops::__iter_comp_iter(__binary_pred)); > } ># 1414 "/usr/include/c++/4.9.0/bits/stl_algobase.h" 3 > >} ># 40 "/usr/include/c++/4.9.0/bits/char_traits.h" 2 3 > ># 1 "/usr/include/c++/4.9.0/cwchar" 1 3 ># 39 "/usr/include/c++/4.9.0/cwchar" 3 ># 40 "/usr/include/c++/4.9.0/cwchar" 3 > > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 45 "/usr/include/c++/4.9.0/cwchar" 2 3 ># 42 "/usr/include/c++/4.9.0/bits/char_traits.h" 2 3 > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ ># 57 "/usr/include/c++/4.9.0/bits/char_traits.h" 3 > template<typename _CharT> > struct _Char_types > { > typedef unsigned long int_type; > typedef std::streampos pos_type; > typedef std::streamoff off_type; > typedef std::mbstate_t state_type; > }; ># 82 "/usr/include/c++/4.9.0/bits/char_traits.h" 3 > template<typename _CharT> > struct char_traits > { > typedef _CharT char_type; > typedef typename _Char_types<_CharT>::int_type int_type; > typedef typename _Char_types<_CharT>::pos_type pos_type; > typedef typename _Char_types<_CharT>::off_type off_type; > typedef typename _Char_types<_CharT>::state_type state_type; > > static void > assign(char_type& __c1, const char_type& __c2) > { __c1 = __c2; } > > static constexpr bool > eq(const char_type& __c1, const char_type& __c2) > { return __c1 == __c2; } > > static constexpr bool > lt(const char_type& __c1, const char_type& __c2) > { return __c1 < __c2; } > > static int > compare(const char_type* __s1, const char_type* __s2, std::size_t __n); > > static std::size_t > length(const char_type* __s); > > static const char_type* > find(const char_type* __s, std::size_t __n, const char_type& __a); > > static char_type* > move(char_type* __s1, const char_type* __s2, std::size_t __n); > > static char_type* > copy(char_type* __s1, const char_type* __s2, std::size_t __n); > > static char_type* > assign(char_type* __s, std::size_t __n, char_type __a); > > static constexpr char_type > to_char_type(const int_type& __c) > { return static_cast<char_type>(__c); } > > static constexpr int_type > to_int_type(const char_type& __c) > { return static_cast<int_type>(__c); } > > static constexpr bool > eq_int_type(const int_type& __c1, const int_type& __c2) > { return __c1 == __c2; } > > static constexpr int_type > eof() > { return static_cast<int_type>(-1); } > > static constexpr int_type > not_eof(const int_type& __c) > { return !eq_int_type(__c, eof()) ? __c : to_int_type(char_type()); } > }; > > template<typename _CharT> > int > char_traits<_CharT>:: > compare(const char_type* __s1, const char_type* __s2, std::size_t __n) > { > for (std::size_t __i = 0; __i < __n; ++__i) > if (lt(__s1[__i], __s2[__i])) > return -1; > else if (lt(__s2[__i], __s1[__i])) > return 1; > return 0; > } > > template<typename _CharT> > std::size_t > char_traits<_CharT>:: > length(const char_type* __p) > { > std::size_t __i = 0; > while (!eq(__p[__i], char_type())) > ++__i; > return __i; > } > > template<typename _CharT> > const typename char_traits<_CharT>::char_type* > char_traits<_CharT>:: > find(const char_type* __s, std::size_t __n, const char_type& __a) > { > for (std::size_t __i = 0; __i < __n; ++__i) > if (eq(__s[__i], __a)) > return __s + __i; > return 0; > } > > template<typename _CharT> > typename char_traits<_CharT>::char_type* > char_traits<_CharT>:: > move(char_type* __s1, const char_type* __s2, std::size_t __n) > { > return static_cast<_CharT*>(__builtin_memmove(__s1, __s2, > __n * sizeof(char_type))); > } > > template<typename _CharT> > typename char_traits<_CharT>::char_type* > char_traits<_CharT>:: > copy(char_type* __s1, const char_type* __s2, std::size_t __n) > { > > std::copy(__s2, __s2 + __n, __s1); > return __s1; > } > > template<typename _CharT> > typename char_traits<_CharT>::char_type* > char_traits<_CharT>:: > assign(char_type* __s, std::size_t __n, char_type __a) > { > > std::fill_n(__s, __n, __a); > return __s; > } > > >} > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 226 "/usr/include/c++/4.9.0/bits/char_traits.h" 3 > template<class _CharT> > struct char_traits : public __gnu_cxx::char_traits<_CharT> > { }; > > > > template<> > struct char_traits<char> > { > typedef char char_type; > typedef int int_type; > typedef streampos pos_type; > typedef streamoff off_type; > typedef mbstate_t state_type; > > static void > assign(char_type& __c1, const char_type& __c2) noexcept > { __c1 = __c2; } > > static constexpr bool > eq(const char_type& __c1, const char_type& __c2) noexcept > { return __c1 == __c2; } > > static constexpr bool > lt(const char_type& __c1, const char_type& __c2) noexcept > { > > return (static_cast<unsigned char>(__c1) > < static_cast<unsigned char>(__c2)); > } > > static int > compare(const char_type* __s1, const char_type* __s2, size_t __n) > { return __builtin_memcmp(__s1, __s2, __n); } > > static size_t > length(const char_type* __s) > { return __builtin_strlen(__s); } > > static const char_type* > find(const char_type* __s, size_t __n, const char_type& __a) > { return static_cast<const char_type*>(__builtin_memchr(__s, __a, __n)); } > > static char_type* > move(char_type* __s1, const char_type* __s2, size_t __n) > { return static_cast<char_type*>(__builtin_memmove(__s1, __s2, __n)); } > > static char_type* > copy(char_type* __s1, const char_type* __s2, size_t __n) > { return static_cast<char_type*>(__builtin_memcpy(__s1, __s2, __n)); } > > static char_type* > assign(char_type* __s, size_t __n, char_type __a) > { return static_cast<char_type*>(__builtin_memset(__s, __a, __n)); } > > static constexpr char_type > to_char_type(const int_type& __c) noexcept > { return static_cast<char_type>(__c); } > > > > static constexpr int_type > to_int_type(const char_type& __c) noexcept > { return static_cast<int_type>(static_cast<unsigned char>(__c)); } > > static constexpr bool > eq_int_type(const int_type& __c1, const int_type& __c2) noexcept > { return __c1 == __c2; } > > static constexpr int_type > eof() noexcept > { return static_cast<int_type>(-1); } > > static constexpr int_type > not_eof(const int_type& __c) noexcept > { return (__c == eof()) ? 0 : __c; } > }; > > > > > template<> > struct char_traits<wchar_t> > { > typedef wchar_t char_type; > typedef wint_t int_type; > typedef streamoff off_type; > typedef wstreampos pos_type; > typedef mbstate_t state_type; > > static void > assign(char_type& __c1, const char_type& __c2) noexcept > { __c1 = __c2; } > > static constexpr bool > eq(const char_type& __c1, const char_type& __c2) noexcept > { return __c1 == __c2; } > > static constexpr bool > lt(const char_type& __c1, const char_type& __c2) noexcept > { return __c1 < __c2; } > > static int > compare(const char_type* __s1, const char_type* __s2, size_t __n) > { return wmemcmp(__s1, __s2, __n); } > > static size_t > length(const char_type* __s) > { return wcslen(__s); } > > static const char_type* > find(const char_type* __s, size_t __n, const char_type& __a) > { return wmemchr(__s, __a, __n); } > > static char_type* > move(char_type* __s1, const char_type* __s2, size_t __n) > { return wmemmove(__s1, __s2, __n); } > > static char_type* > copy(char_type* __s1, const char_type* __s2, size_t __n) > { return wmemcpy(__s1, __s2, __n); } > > static char_type* > assign(char_type* __s, size_t __n, char_type __a) > { return wmemset(__s, __a, __n); } > > static constexpr char_type > to_char_type(const int_type& __c) noexcept > { return char_type(__c); } > > static constexpr int_type > to_int_type(const char_type& __c) noexcept > { return int_type(__c); } > > static constexpr bool > eq_int_type(const int_type& __c1, const int_type& __c2) noexcept > { return __c1 == __c2; } > > static constexpr int_type > eof() noexcept > { return static_cast<int_type>((0xffffffffu)); } > > static constexpr int_type > not_eof(const int_type& __c) noexcept > { return eq_int_type(__c, eof()) ? 0 : __c; } > }; > > > >} > > > > ># 1 "/usr/include/c++/4.9.0/cstdint" 1 3 ># 32 "/usr/include/c++/4.9.0/cstdint" 3 ># 33 "/usr/include/c++/4.9.0/cstdint" 3 ># 41 "/usr/include/c++/4.9.0/cstdint" 3 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stdint.h" 1 3 4 ># 9 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stdint.h" 3 4 ># 1 "/usr/include/stdint.h" 1 3 4 ># 27 "/usr/include/stdint.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 28 "/usr/include/stdint.h" 2 3 4 ># 48 "/usr/include/stdint.h" 3 4 >typedef unsigned char uint8_t; >typedef unsigned short int uint16_t; > >typedef unsigned int uint32_t; > > > >typedef unsigned long int uint64_t; ># 65 "/usr/include/stdint.h" 3 4 >typedef signed char int_least8_t; >typedef short int int_least16_t; >typedef int int_least32_t; > >typedef long int int_least64_t; > > > > > > >typedef unsigned char uint_least8_t; >typedef unsigned short int uint_least16_t; >typedef unsigned int uint_least32_t; > >typedef unsigned long int uint_least64_t; ># 90 "/usr/include/stdint.h" 3 4 >typedef signed char int_fast8_t; > >typedef long int int_fast16_t; >typedef long int int_fast32_t; >typedef long int int_fast64_t; ># 103 "/usr/include/stdint.h" 3 4 >typedef unsigned char uint_fast8_t; > >typedef unsigned long int uint_fast16_t; >typedef unsigned long int uint_fast32_t; >typedef unsigned long int uint_fast64_t; ># 122 "/usr/include/stdint.h" 3 4 >typedef unsigned long int uintptr_t; ># 134 "/usr/include/stdint.h" 3 4 >typedef long int intmax_t; >typedef unsigned long int uintmax_t; ># 10 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stdint.h" 2 3 4 ># 42 "/usr/include/c++/4.9.0/cstdint" 2 3 > > > > >namespace std >{ > using ::int8_t; > using ::int16_t; > using ::int32_t; > using ::int64_t; > > using ::int_fast8_t; > using ::int_fast16_t; > using ::int_fast32_t; > using ::int_fast64_t; > > using ::int_least8_t; > using ::int_least16_t; > using ::int_least32_t; > using ::int_least64_t; > > using ::intmax_t; > using ::intptr_t; > > using ::uint8_t; > using ::uint16_t; > using ::uint32_t; > using ::uint64_t; > > using ::uint_fast8_t; > using ::uint_fast16_t; > using ::uint_fast32_t; > using ::uint_fast64_t; > > using ::uint_least8_t; > using ::uint_least16_t; > using ::uint_least32_t; > using ::uint_least64_t; > > using ::uintmax_t; > using ::uintptr_t; >} ># 381 "/usr/include/c++/4.9.0/bits/char_traits.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<> > struct char_traits<char16_t> > { > typedef char16_t char_type; > typedef uint_least16_t int_type; > typedef streamoff off_type; > typedef u16streampos pos_type; > typedef mbstate_t state_type; > > static void > assign(char_type& __c1, const char_type& __c2) noexcept > { __c1 = __c2; } > > static constexpr bool > eq(const char_type& __c1, const char_type& __c2) noexcept > { return __c1 == __c2; } > > static constexpr bool > lt(const char_type& __c1, const char_type& __c2) noexcept > { return __c1 < __c2; } > > static int > compare(const char_type* __s1, const char_type* __s2, size_t __n) > { > for (size_t __i = 0; __i < __n; ++__i) > if (lt(__s1[__i], __s2[__i])) > return -1; > else if (lt(__s2[__i], __s1[__i])) > return 1; > return 0; > } > > static size_t > length(const char_type* __s) > { > size_t __i = 0; > while (!eq(__s[__i], char_type())) > ++__i; > return __i; > } > > static const char_type* > find(const char_type* __s, size_t __n, const char_type& __a) > { > for (size_t __i = 0; __i < __n; ++__i) > if (eq(__s[__i], __a)) > return __s + __i; > return 0; > } > > static char_type* > move(char_type* __s1, const char_type* __s2, size_t __n) > { > return (static_cast<char_type*> > (__builtin_memmove(__s1, __s2, __n * sizeof(char_type)))); > } > > static char_type* > copy(char_type* __s1, const char_type* __s2, size_t __n) > { > return (static_cast<char_type*> > (__builtin_memcpy(__s1, __s2, __n * sizeof(char_type)))); > } > > static char_type* > assign(char_type* __s, size_t __n, char_type __a) > { > for (size_t __i = 0; __i < __n; ++__i) > assign(__s[__i], __a); > return __s; > } > > static constexpr char_type > to_char_type(const int_type& __c) noexcept > { return char_type(__c); } > > static constexpr int_type > to_int_type(const char_type& __c) noexcept > { return int_type(__c); } > > static constexpr bool > eq_int_type(const int_type& __c1, const int_type& __c2) noexcept > { return __c1 == __c2; } > > static constexpr int_type > eof() noexcept > { return static_cast<int_type>(-1); } > > static constexpr int_type > not_eof(const int_type& __c) noexcept > { return eq_int_type(__c, eof()) ? 0 : __c; } > }; > > template<> > struct char_traits<char32_t> > { > typedef char32_t char_type; > typedef uint_least32_t int_type; > typedef streamoff off_type; > typedef u32streampos pos_type; > typedef mbstate_t state_type; > > static void > assign(char_type& __c1, const char_type& __c2) noexcept > { __c1 = __c2; } > > static constexpr bool > eq(const char_type& __c1, const char_type& __c2) noexcept > { return __c1 == __c2; } > > static constexpr bool > lt(const char_type& __c1, const char_type& __c2) noexcept > { return __c1 < __c2; } > > static int > compare(const char_type* __s1, const char_type* __s2, size_t __n) > { > for (size_t __i = 0; __i < __n; ++__i) > if (lt(__s1[__i], __s2[__i])) > return -1; > else if (lt(__s2[__i], __s1[__i])) > return 1; > return 0; > } > > static size_t > length(const char_type* __s) > { > size_t __i = 0; > while (!eq(__s[__i], char_type())) > ++__i; > return __i; > } > > static const char_type* > find(const char_type* __s, size_t __n, const char_type& __a) > { > for (size_t __i = 0; __i < __n; ++__i) > if (eq(__s[__i], __a)) > return __s + __i; > return 0; > } > > static char_type* > move(char_type* __s1, const char_type* __s2, size_t __n) > { > return (static_cast<char_type*> > (__builtin_memmove(__s1, __s2, __n * sizeof(char_type)))); > } > > static char_type* > copy(char_type* __s1, const char_type* __s2, size_t __n) > { > return (static_cast<char_type*> > (__builtin_memcpy(__s1, __s2, __n * sizeof(char_type)))); > } > > static char_type* > assign(char_type* __s, size_t __n, char_type __a) > { > for (size_t __i = 0; __i < __n; ++__i) > assign(__s[__i], __a); > return __s; > } > > static constexpr char_type > to_char_type(const int_type& __c) noexcept > { return char_type(__c); } > > static constexpr int_type > to_int_type(const char_type& __c) noexcept > { return int_type(__c); } > > static constexpr bool > eq_int_type(const int_type& __c1, const int_type& __c2) noexcept > { return __c1 == __c2; } > > static constexpr int_type > eof() noexcept > { return static_cast<int_type>(-1); } > > static constexpr int_type > not_eof(const int_type& __c) noexcept > { return eq_int_type(__c, eof()) ? 0 : __c; } > }; > > >} ># 41 "/usr/include/c++/4.9.0/ios" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/localefwd.h" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/localefwd.h" 3 ># 38 "/usr/include/c++/4.9.0/bits/localefwd.h" 3 > > ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++locale.h" 1 3 ># 39 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++locale.h" 3 ># 40 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++locale.h" 3 > ># 1 "/usr/include/c++/4.9.0/clocale" 1 3 ># 39 "/usr/include/c++/4.9.0/clocale" 3 ># 40 "/usr/include/c++/4.9.0/clocale" 3 > > ># 1 "/usr/include/locale.h" 1 3 4 ># 28 "/usr/include/locale.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 29 "/usr/include/locale.h" 2 3 4 ># 1 "/usr/include/bits/locale.h" 1 3 4 ># 30 "/usr/include/locale.h" 2 3 4 > >extern "C" { ># 50 "/usr/include/locale.h" 3 4 > > > >struct lconv >{ > > > char *decimal_point; > char *thousands_sep; > > > > > > char *grouping; > > > > > > char *int_curr_symbol; > char *currency_symbol; > char *mon_decimal_point; > char *mon_thousands_sep; > char *mon_grouping; > char *positive_sign; > char *negative_sign; > char int_frac_digits; > char frac_digits; > > char p_cs_precedes; > > char p_sep_by_space; > > char n_cs_precedes; > > char n_sep_by_space; > > > > > > > char p_sign_posn; > char n_sign_posn; > > > char int_p_cs_precedes; > > char int_p_sep_by_space; > > char int_n_cs_precedes; > > char int_n_sep_by_space; > > > > > > > char int_p_sign_posn; > char int_n_sign_posn; ># 120 "/usr/include/locale.h" 3 4 >}; > > > >extern char *setlocale (int __category, const char *__locale) throw (); > > >extern struct lconv *localeconv (void) throw (); ># 151 "/usr/include/locale.h" 3 4 >extern __locale_t newlocale (int __category_mask, const char *__locale, > __locale_t __base) throw (); ># 186 "/usr/include/locale.h" 3 4 >extern __locale_t duplocale (__locale_t __dataset) throw (); > > > >extern void freelocale (__locale_t __dataset) throw (); > > > > > > >extern __locale_t uselocale (__locale_t __dataset) throw (); > > > > > > > >} ># 43 "/usr/include/c++/4.9.0/clocale" 2 3 ># 51 "/usr/include/c++/4.9.0/clocale" 3 >namespace std >{ > using ::lconv; > using ::setlocale; > using ::localeconv; >} ># 42 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++locale.h" 2 3 > > > > > > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > extern "C" __typeof(uselocale) __uselocale; > > >} > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > typedef __locale_t __c_locale; > > > > > > inline int > __convert_from_v(const __c_locale& __cloc __attribute__ ((__unused__)), > char* __out, > const int __size __attribute__ ((__unused__)), > const char* __fmt, ...) > { > > __c_locale __old = __gnu_cxx::__uselocale(__cloc); ># 88 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++locale.h" 3 > __builtin_va_list __args; > __builtin_va_start(__args, __fmt); > > > const int __ret = __builtin_vsnprintf(__out, __size, __fmt, __args); > > > > > __builtin_va_end(__args); > > > __gnu_cxx::__uselocale(__old); > > > > > > > > return __ret; > } > > >} ># 41 "/usr/include/c++/4.9.0/bits/localefwd.h" 2 3 > ># 1 "/usr/include/c++/4.9.0/cctype" 1 3 ># 39 "/usr/include/c++/4.9.0/cctype" 3 ># 40 "/usr/include/c++/4.9.0/cctype" 3 > > ># 1 "/usr/include/ctype.h" 1 3 4 ># 28 "/usr/include/ctype.h" 3 4 >extern "C" { ># 46 "/usr/include/ctype.h" 3 4 >enum >{ > _ISupper = ((0) < 8 ? ((1 << (0)) << 8) : ((1 << (0)) >> 8)), > _ISlower = ((1) < 8 ? ((1 << (1)) << 8) : ((1 << (1)) >> 8)), > _ISalpha = ((2) < 8 ? ((1 << (2)) << 8) : ((1 << (2)) >> 8)), > _ISdigit = ((3) < 8 ? ((1 << (3)) << 8) : ((1 << (3)) >> 8)), > _ISxdigit = ((4) < 8 ? ((1 << (4)) << 8) : ((1 << (4)) >> 8)), > _ISspace = ((5) < 8 ? ((1 << (5)) << 8) : ((1 << (5)) >> 8)), > _ISprint = ((6) < 8 ? ((1 << (6)) << 8) : ((1 << (6)) >> 8)), > _ISgraph = ((7) < 8 ? ((1 << (7)) << 8) : ((1 << (7)) >> 8)), > _ISblank = ((8) < 8 ? ((1 << (8)) << 8) : ((1 << (8)) >> 8)), > _IScntrl = ((9) < 8 ? ((1 << (9)) << 8) : ((1 << (9)) >> 8)), > _ISpunct = ((10) < 8 ? ((1 << (10)) << 8) : ((1 << (10)) >> 8)), > _ISalnum = ((11) < 8 ? ((1 << (11)) << 8) : ((1 << (11)) >> 8)) >}; ># 79 "/usr/include/ctype.h" 3 4 >extern const unsigned short int **__ctype_b_loc (void) > throw () __attribute__ ((__const__)); >extern const __int32_t **__ctype_tolower_loc (void) > throw () __attribute__ ((__const__)); >extern const __int32_t **__ctype_toupper_loc (void) > throw () __attribute__ ((__const__)); ># 104 "/usr/include/ctype.h" 3 4 > > > > > > >extern int isalnum (int) throw (); >extern int isalpha (int) throw (); >extern int iscntrl (int) throw (); >extern int isdigit (int) throw (); >extern int islower (int) throw (); >extern int isgraph (int) throw (); >extern int isprint (int) throw (); >extern int ispunct (int) throw (); >extern int isspace (int) throw (); >extern int isupper (int) throw (); >extern int isxdigit (int) throw (); > > > >extern int tolower (int __c) throw (); > > >extern int toupper (int __c) throw (); ># 136 "/usr/include/ctype.h" 3 4 >extern int isblank (int) throw (); > > > > > > >extern int isctype (int __c, int __mask) throw (); > > > > > > >extern int isascii (int __c) throw (); > > > >extern int toascii (int __c) throw (); > > > >extern int _toupper (int) throw (); >extern int _tolower (int) throw (); ># 271 "/usr/include/ctype.h" 3 4 >extern int isalnum_l (int, __locale_t) throw (); >extern int isalpha_l (int, __locale_t) throw (); >extern int iscntrl_l (int, __locale_t) throw (); >extern int isdigit_l (int, __locale_t) throw (); >extern int islower_l (int, __locale_t) throw (); >extern int isgraph_l (int, __locale_t) throw (); >extern int isprint_l (int, __locale_t) throw (); >extern int ispunct_l (int, __locale_t) throw (); >extern int isspace_l (int, __locale_t) throw (); >extern int isupper_l (int, __locale_t) throw (); >extern int isxdigit_l (int, __locale_t) throw (); > >extern int isblank_l (int, __locale_t) throw (); > > > >extern int __tolower_l (int __c, __locale_t __l) throw (); >extern int tolower_l (int __c, __locale_t __l) throw (); > > >extern int __toupper_l (int __c, __locale_t __l) throw (); >extern int toupper_l (int __c, __locale_t __l) throw (); ># 347 "/usr/include/ctype.h" 3 4 >} ># 43 "/usr/include/c++/4.9.0/cctype" 2 3 ># 62 "/usr/include/c++/4.9.0/cctype" 3 >namespace std >{ > using ::isalnum; > using ::isalpha; > using ::iscntrl; > using ::isdigit; > using ::isgraph; > using ::islower; > using ::isprint; > using ::ispunct; > using ::isspace; > using ::isupper; > using ::isxdigit; > using ::tolower; > using ::toupper; >} > > > > > > > >namespace std >{ > using ::isblank; >} ># 43 "/usr/include/c++/4.9.0/bits/localefwd.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 55 "/usr/include/c++/4.9.0/bits/localefwd.h" 3 > class locale; > > template<typename _Facet> > bool > has_facet(const locale&) throw(); > > template<typename _Facet> > const _Facet& > use_facet(const locale&); > > > template<typename _CharT> > bool > isspace(_CharT, const locale&); > > template<typename _CharT> > bool > isprint(_CharT, const locale&); > > template<typename _CharT> > bool > iscntrl(_CharT, const locale&); > > template<typename _CharT> > bool > isupper(_CharT, const locale&); > > template<typename _CharT> > bool > islower(_CharT, const locale&); > > template<typename _CharT> > bool > isalpha(_CharT, const locale&); > > template<typename _CharT> > bool > isdigit(_CharT, const locale&); > > template<typename _CharT> > bool > ispunct(_CharT, const locale&); > > template<typename _CharT> > bool > isxdigit(_CharT, const locale&); > > template<typename _CharT> > bool > isalnum(_CharT, const locale&); > > template<typename _CharT> > bool > isgraph(_CharT, const locale&); > > template<typename _CharT> > _CharT > toupper(_CharT, const locale&); > > template<typename _CharT> > _CharT > tolower(_CharT, const locale&); > > > class ctype_base; > template<typename _CharT> > class ctype; > template<> class ctype<char>; > > template<> class ctype<wchar_t>; > > template<typename _CharT> > class ctype_byname; > > > class codecvt_base; > template<typename _InternT, typename _ExternT, typename _StateT> > class codecvt; > template<> class codecvt<char, char, mbstate_t>; > > template<> class codecvt<wchar_t, char, mbstate_t>; > > template<typename _InternT, typename _ExternT, typename _StateT> > class codecvt_byname; > > > > template<typename _CharT, typename _InIter = istreambuf_iterator<_CharT> > > class num_get; > template<typename _CharT, typename _OutIter = ostreambuf_iterator<_CharT> > > class num_put; > > template<typename _CharT> class numpunct; > template<typename _CharT> class numpunct_byname; > > > template<typename _CharT> > class collate; > template<typename _CharT> class > collate_byname; > > > class time_base; > template<typename _CharT, typename _InIter = istreambuf_iterator<_CharT> > > class time_get; > template<typename _CharT, typename _InIter = istreambuf_iterator<_CharT> > > class time_get_byname; > template<typename _CharT, typename _OutIter = ostreambuf_iterator<_CharT> > > class time_put; > template<typename _CharT, typename _OutIter = ostreambuf_iterator<_CharT> > > class time_put_byname; > > > class money_base; > > template<typename _CharT, typename _InIter = istreambuf_iterator<_CharT> > > class money_get; > template<typename _CharT, typename _OutIter = ostreambuf_iterator<_CharT> > > class money_put; > > template<typename _CharT, bool _Intl = false> > class moneypunct; > template<typename _CharT, bool _Intl = false> > class moneypunct_byname; > > > class messages_base; > template<typename _CharT> > class messages; > template<typename _CharT> > class messages_byname; > > >} ># 42 "/usr/include/c++/4.9.0/ios" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/ios_base.h" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 ># 38 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > ># 1 "/usr/include/c++/4.9.0/ext/atomicity.h" 1 3 ># 32 "/usr/include/c++/4.9.0/ext/atomicity.h" 3 ># 33 "/usr/include/c++/4.9.0/ext/atomicity.h" 3 > > ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr.h" 1 3 ># 30 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr.h" 3 >#pragma GCC visibility push(default) ># 148 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr.h" 3 ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 1 3 ># 35 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 3 ># 1 "/usr/include/pthread.h" 1 3 4 ># 23 "/usr/include/pthread.h" 3 4 ># 1 "/usr/include/sched.h" 1 3 4 ># 28 "/usr/include/sched.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 29 "/usr/include/sched.h" 2 3 4 > > > ># 1 "/usr/include/time.h" 1 3 4 ># 33 "/usr/include/sched.h" 2 3 4 ># 41 "/usr/include/sched.h" 3 4 ># 1 "/usr/include/bits/sched.h" 1 3 4 ># 72 "/usr/include/bits/sched.h" 3 4 >struct sched_param > { > int __sched_priority; > }; > >extern "C" { > > > >extern int clone (int (*__fn) (void *__arg), void *__child_stack, > int __flags, void *__arg, ...) throw (); > > >extern int unshare (int __flags) throw (); > > >extern int sched_getcpu (void) throw (); > > >extern int setns (int __fd, int __nstype) throw (); > > > >} > > > > > > > >struct __sched_param > { > int __sched_priority; > }; ># 118 "/usr/include/bits/sched.h" 3 4 >typedef unsigned long int __cpu_mask; > > > > > > >typedef struct >{ > __cpu_mask __bits[1024 / (8 * sizeof (__cpu_mask))]; >} cpu_set_t; ># 201 "/usr/include/bits/sched.h" 3 4 >extern "C" { > >extern int __sched_cpucount (size_t __setsize, const cpu_set_t *__setp) > throw (); >extern cpu_set_t *__sched_cpualloc (size_t __count) throw () ; >extern void __sched_cpufree (cpu_set_t *__set) throw (); > >} ># 42 "/usr/include/sched.h" 2 3 4 > > > > >extern "C" { > > >extern int sched_setparam (__pid_t __pid, const struct sched_param *__param) > throw (); > > >extern int sched_getparam (__pid_t __pid, struct sched_param *__param) throw (); > > >extern int sched_setscheduler (__pid_t __pid, int __policy, > const struct sched_param *__param) throw (); > > >extern int sched_getscheduler (__pid_t __pid) throw (); > > >extern int sched_yield (void) throw (); > > >extern int sched_get_priority_max (int __algorithm) throw (); > > >extern int sched_get_priority_min (int __algorithm) throw (); > > >extern int sched_rr_get_interval (__pid_t __pid, struct timespec *__t) throw (); ># 116 "/usr/include/sched.h" 3 4 >extern int sched_setaffinity (__pid_t __pid, size_t __cpusetsize, > const cpu_set_t *__cpuset) throw (); > > >extern int sched_getaffinity (__pid_t __pid, size_t __cpusetsize, > cpu_set_t *__cpuset) throw (); > > >} ># 24 "/usr/include/pthread.h" 2 3 4 ># 1 "/usr/include/time.h" 1 3 4 ># 29 "/usr/include/time.h" 3 4 >extern "C" { > > > > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 38 "/usr/include/time.h" 2 3 4 > > > ># 1 "/usr/include/bits/time.h" 1 3 4 ># 86 "/usr/include/bits/time.h" 3 4 ># 1 "/usr/include/bits/timex.h" 1 3 4 ># 25 "/usr/include/bits/timex.h" 3 4 >struct timex >{ > unsigned int modes; > __syscall_slong_t offset; > __syscall_slong_t freq; > __syscall_slong_t maxerror; > __syscall_slong_t esterror; > int status; > __syscall_slong_t constant; > __syscall_slong_t precision; > __syscall_slong_t tolerance; > struct timeval time; > __syscall_slong_t tick; > __syscall_slong_t ppsfreq; > __syscall_slong_t jitter; > int shift; > __syscall_slong_t stabil; > __syscall_slong_t jitcnt; > __syscall_slong_t calcnt; > __syscall_slong_t errcnt; > __syscall_slong_t stbcnt; > > int tai; > > > int :32; int :32; int :32; int :32; > int :32; int :32; int :32; int :32; > int :32; int :32; int :32; >}; ># 87 "/usr/include/bits/time.h" 2 3 4 > >extern "C" { > > >extern int clock_adjtime (__clockid_t __clock_id, struct timex *__utx) throw (); > >} ># 42 "/usr/include/time.h" 2 3 4 ># 131 "/usr/include/time.h" 3 4 > > >struct tm >{ > int tm_sec; > int tm_min; > int tm_hour; > int tm_mday; > int tm_mon; > int tm_year; > int tm_wday; > int tm_yday; > int tm_isdst; > > > long int tm_gmtoff; > const char *tm_zone; > > > > >}; ># 161 "/usr/include/time.h" 3 4 >struct itimerspec > { > struct timespec it_interval; > struct timespec it_value; > }; > > >struct sigevent; ># 186 "/usr/include/time.h" 3 4 > > > >extern clock_t clock (void) throw (); > > >extern time_t time (time_t *__timer) throw (); > > >extern double difftime (time_t __time1, time_t __time0) > throw () __attribute__ ((__const__)); > > >extern time_t mktime (struct tm *__tp) throw (); > > > > > >extern size_t strftime (char *__restrict __s, size_t __maxsize, > const char *__restrict __format, > const struct tm *__restrict __tp) throw (); > > > > > >extern char *strptime (const char *__restrict __s, > const char *__restrict __fmt, struct tm *__tp) > throw (); > > > > > > > >extern size_t strftime_l (char *__restrict __s, size_t __maxsize, > const char *__restrict __format, > const struct tm *__restrict __tp, > __locale_t __loc) throw (); > > > >extern char *strptime_l (const char *__restrict __s, > const char *__restrict __fmt, struct tm *__tp, > __locale_t __loc) throw (); > > > > > > >extern struct tm *gmtime (const time_t *__timer) throw (); > > > >extern struct tm *localtime (const time_t *__timer) throw (); > > > > > >extern struct tm *gmtime_r (const time_t *__restrict __timer, > struct tm *__restrict __tp) throw (); > > > >extern struct tm *localtime_r (const time_t *__restrict __timer, > struct tm *__restrict __tp) throw (); > > > > > >extern char *asctime (const struct tm *__tp) throw (); > > >extern char *ctime (const time_t *__timer) throw (); > > > > > > > >extern char *asctime_r (const struct tm *__restrict __tp, > char *__restrict __buf) throw (); > > >extern char *ctime_r (const time_t *__restrict __timer, > char *__restrict __buf) throw (); > > > > >extern char *__tzname[2]; >extern int __daylight; >extern long int __timezone; > > > > >extern char *tzname[2]; > > > >extern void tzset (void) throw (); > > > >extern int daylight; >extern long int timezone; > > > > > >extern int stime (const time_t *__when) throw (); ># 319 "/usr/include/time.h" 3 4 >extern time_t timegm (struct tm *__tp) throw (); > > >extern time_t timelocal (struct tm *__tp) throw (); > > >extern int dysize (int __year) throw () __attribute__ ((__const__)); ># 334 "/usr/include/time.h" 3 4 >extern int nanosleep (const struct timespec *__requested_time, > struct timespec *__remaining); > > > >extern int clock_getres (clockid_t __clock_id, struct timespec *__res) throw (); > > >extern int clock_gettime (clockid_t __clock_id, struct timespec *__tp) throw (); > > >extern int clock_settime (clockid_t __clock_id, const struct timespec *__tp) > throw (); > > > > > > >extern int clock_nanosleep (clockid_t __clock_id, int __flags, > const struct timespec *__req, > struct timespec *__rem); > > >extern int clock_getcpuclockid (pid_t __pid, clockid_t *__clock_id) throw (); > > > > >extern int timer_create (clockid_t __clock_id, > struct sigevent *__restrict __evp, > timer_t *__restrict __timerid) throw (); > > >extern int timer_delete (timer_t __timerid) throw (); > > >extern int timer_settime (timer_t __timerid, int __flags, > const struct itimerspec *__restrict __value, > struct itimerspec *__restrict __ovalue) throw (); > > >extern int timer_gettime (timer_t __timerid, struct itimerspec *__value) > throw (); > > >extern int timer_getoverrun (timer_t __timerid) throw (); > > > > > >extern int timespec_get (struct timespec *__ts, int __base) > throw () __attribute__ ((__nonnull__ (1))); ># 403 "/usr/include/time.h" 3 4 >extern int getdate_err; ># 412 "/usr/include/time.h" 3 4 >extern struct tm *getdate (const char *__string); ># 426 "/usr/include/time.h" 3 4 >extern int getdate_r (const char *__restrict __string, > struct tm *__restrict __resbufp); > > >} ># 25 "/usr/include/pthread.h" 2 3 4 > > ># 1 "/usr/include/bits/setjmp.h" 1 3 4 ># 26 "/usr/include/bits/setjmp.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 27 "/usr/include/bits/setjmp.h" 2 3 4 > > > > >typedef long int __jmp_buf[8]; ># 28 "/usr/include/pthread.h" 2 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 29 "/usr/include/pthread.h" 2 3 4 > > > >enum >{ > PTHREAD_CREATE_JOINABLE, > > PTHREAD_CREATE_DETACHED > >}; > > > >enum >{ > PTHREAD_MUTEX_TIMED_NP, > PTHREAD_MUTEX_RECURSIVE_NP, > PTHREAD_MUTEX_ERRORCHECK_NP, > PTHREAD_MUTEX_ADAPTIVE_NP > > , > PTHREAD_MUTEX_NORMAL = PTHREAD_MUTEX_TIMED_NP, > PTHREAD_MUTEX_RECURSIVE = PTHREAD_MUTEX_RECURSIVE_NP, > PTHREAD_MUTEX_ERRORCHECK = PTHREAD_MUTEX_ERRORCHECK_NP, > PTHREAD_MUTEX_DEFAULT = PTHREAD_MUTEX_NORMAL > > > > , PTHREAD_MUTEX_FAST_NP = PTHREAD_MUTEX_TIMED_NP > >}; > > > > >enum >{ > PTHREAD_MUTEX_STALLED, > PTHREAD_MUTEX_STALLED_NP = PTHREAD_MUTEX_STALLED, > PTHREAD_MUTEX_ROBUST, > PTHREAD_MUTEX_ROBUST_NP = PTHREAD_MUTEX_ROBUST >}; > > > > > >enum >{ > PTHREAD_PRIO_NONE, > PTHREAD_PRIO_INHERIT, > PTHREAD_PRIO_PROTECT >}; ># 125 "/usr/include/pthread.h" 3 4 >enum >{ > PTHREAD_RWLOCK_PREFER_READER_NP, > PTHREAD_RWLOCK_PREFER_WRITER_NP, > PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP, > PTHREAD_RWLOCK_DEFAULT_NP = PTHREAD_RWLOCK_PREFER_READER_NP >}; ># 166 "/usr/include/pthread.h" 3 4 >enum >{ > PTHREAD_INHERIT_SCHED, > > PTHREAD_EXPLICIT_SCHED > >}; > > > >enum >{ > PTHREAD_SCOPE_SYSTEM, > > PTHREAD_SCOPE_PROCESS > >}; > > > >enum >{ > PTHREAD_PROCESS_PRIVATE, > > PTHREAD_PROCESS_SHARED > >}; ># 201 "/usr/include/pthread.h" 3 4 >struct _pthread_cleanup_buffer >{ > void (*__routine) (void *); > void *__arg; > int __canceltype; > struct _pthread_cleanup_buffer *__prev; >}; > > >enum >{ > PTHREAD_CANCEL_ENABLE, > > PTHREAD_CANCEL_DISABLE > >}; >enum >{ > PTHREAD_CANCEL_DEFERRED, > > PTHREAD_CANCEL_ASYNCHRONOUS > >}; ># 239 "/usr/include/pthread.h" 3 4 >extern "C" { > > > > >extern int pthread_create (pthread_t *__restrict __newthread, > const pthread_attr_t *__restrict __attr, > void *(*__start_routine) (void *), > void *__restrict __arg) throw () __attribute__ ((__nonnull__ (1, 3))); > > > > > >extern void pthread_exit (void *__retval) __attribute__ ((__noreturn__)); > > > > > > > >extern int pthread_join (pthread_t __th, void **__thread_return); > > > > >extern int pthread_tryjoin_np (pthread_t __th, void **__thread_return) throw (); > > > > > > > >extern int pthread_timedjoin_np (pthread_t __th, void **__thread_return, > const struct timespec *__abstime); > > > > > > >extern int pthread_detach (pthread_t __th) throw (); > > > >extern pthread_t pthread_self (void) throw () __attribute__ ((__const__)); > > >extern int pthread_equal (pthread_t __thread1, pthread_t __thread2) > throw () __attribute__ ((__const__)); > > > > > > > >extern int pthread_attr_init (pthread_attr_t *__attr) throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_attr_destroy (pthread_attr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_attr_getdetachstate (const pthread_attr_t *__attr, > int *__detachstate) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_attr_setdetachstate (pthread_attr_t *__attr, > int __detachstate) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_attr_getguardsize (const pthread_attr_t *__attr, > size_t *__guardsize) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_attr_setguardsize (pthread_attr_t *__attr, > size_t __guardsize) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_attr_getschedparam (const pthread_attr_t *__restrict __attr, > struct sched_param *__restrict __param) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_attr_setschedparam (pthread_attr_t *__restrict __attr, > const struct sched_param *__restrict > __param) throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_attr_getschedpolicy (const pthread_attr_t *__restrict > __attr, int *__restrict __policy) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_attr_setschedpolicy (pthread_attr_t *__attr, int __policy) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_attr_getinheritsched (const pthread_attr_t *__restrict > __attr, int *__restrict __inherit) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_attr_setinheritsched (pthread_attr_t *__attr, > int __inherit) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_attr_getscope (const pthread_attr_t *__restrict __attr, > int *__restrict __scope) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_attr_setscope (pthread_attr_t *__attr, int __scope) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_attr_getstackaddr (const pthread_attr_t *__restrict > __attr, void **__restrict __stackaddr) > throw () __attribute__ ((__nonnull__ (1, 2))) __attribute__ ((__deprecated__)); > > > > > >extern int pthread_attr_setstackaddr (pthread_attr_t *__attr, > void *__stackaddr) > throw () __attribute__ ((__nonnull__ (1))) __attribute__ ((__deprecated__)); > > >extern int pthread_attr_getstacksize (const pthread_attr_t *__restrict > __attr, size_t *__restrict __stacksize) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > >extern int pthread_attr_setstacksize (pthread_attr_t *__attr, > size_t __stacksize) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_attr_getstack (const pthread_attr_t *__restrict __attr, > void **__restrict __stackaddr, > size_t *__restrict __stacksize) > throw () __attribute__ ((__nonnull__ (1, 2, 3))); > > > > >extern int pthread_attr_setstack (pthread_attr_t *__attr, void *__stackaddr, > size_t __stacksize) throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern int pthread_attr_setaffinity_np (pthread_attr_t *__attr, > size_t __cpusetsize, > const cpu_set_t *__cpuset) > throw () __attribute__ ((__nonnull__ (1, 3))); > > > >extern int pthread_attr_getaffinity_np (const pthread_attr_t *__attr, > size_t __cpusetsize, > cpu_set_t *__cpuset) > throw () __attribute__ ((__nonnull__ (1, 3))); > > >extern int pthread_getattr_default_np (pthread_attr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_setattr_default_np (const pthread_attr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > > > >extern int pthread_getattr_np (pthread_t __th, pthread_attr_t *__attr) > throw () __attribute__ ((__nonnull__ (2))); > > > > > > > >extern int pthread_setschedparam (pthread_t __target_thread, int __policy, > const struct sched_param *__param) > throw () __attribute__ ((__nonnull__ (3))); > > >extern int pthread_getschedparam (pthread_t __target_thread, > int *__restrict __policy, > struct sched_param *__restrict __param) > throw () __attribute__ ((__nonnull__ (2, 3))); > > >extern int pthread_setschedprio (pthread_t __target_thread, int __prio) > throw (); > > > > >extern int pthread_getname_np (pthread_t __target_thread, char *__buf, > size_t __buflen) > throw () __attribute__ ((__nonnull__ (2))); > > >extern int pthread_setname_np (pthread_t __target_thread, const char *__name) > throw () __attribute__ ((__nonnull__ (2))); > > > > > >extern int pthread_getconcurrency (void) throw (); > > >extern int pthread_setconcurrency (int __level) throw (); > > > > > > > >extern int pthread_yield (void) throw (); > > > > >extern int pthread_setaffinity_np (pthread_t __th, size_t __cpusetsize, > const cpu_set_t *__cpuset) > throw () __attribute__ ((__nonnull__ (3))); > > >extern int pthread_getaffinity_np (pthread_t __th, size_t __cpusetsize, > cpu_set_t *__cpuset) > throw () __attribute__ ((__nonnull__ (3))); ># 505 "/usr/include/pthread.h" 3 4 >extern int pthread_once (pthread_once_t *__once_control, > void (*__init_routine) (void)) __attribute__ ((__nonnull__ (1, 2))); ># 517 "/usr/include/pthread.h" 3 4 >extern int pthread_setcancelstate (int __state, int *__oldstate); > > > >extern int pthread_setcanceltype (int __type, int *__oldtype); > > >extern int pthread_cancel (pthread_t __th); > > > > >extern void pthread_testcancel (void); > > > > >typedef struct >{ > struct > { > __jmp_buf __cancel_jmp_buf; > int __mask_was_saved; > } __cancel_jmp_buf[1]; > void *__pad[4]; >} __pthread_unwind_buf_t __attribute__ ((__aligned__)); ># 551 "/usr/include/pthread.h" 3 4 >struct __pthread_cleanup_frame >{ > void (*__cancel_routine) (void *); > void *__cancel_arg; > int __do_it; > int __cancel_type; >}; > > > > >class __pthread_cleanup_class >{ > void (*__cancel_routine) (void *); > void *__cancel_arg; > int __do_it; > int __cancel_type; > > public: > __pthread_cleanup_class (void (*__fct) (void *), void *__arg) > : __cancel_routine (__fct), __cancel_arg (__arg), __do_it (1) { } > ~__pthread_cleanup_class () { if (__do_it) __cancel_routine (__cancel_arg); } > void __setdoit (int __newval) { __do_it = __newval; } > void __defer () { pthread_setcanceltype (PTHREAD_CANCEL_DEFERRED, > &__cancel_type); } > void __restore () const { pthread_setcanceltype (__cancel_type, 0); } >}; ># 753 "/usr/include/pthread.h" 3 4 >struct __jmp_buf_tag; >extern int __sigsetjmp (struct __jmp_buf_tag *__env, int __savemask) throw (); > > > > > >extern int pthread_mutex_init (pthread_mutex_t *__mutex, > const pthread_mutexattr_t *__mutexattr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_mutex_destroy (pthread_mutex_t *__mutex) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_mutex_trylock (pthread_mutex_t *__mutex) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_mutex_lock (pthread_mutex_t *__mutex) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_mutex_timedlock (pthread_mutex_t *__restrict __mutex, > const struct timespec *__restrict > __abstime) throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int pthread_mutex_unlock (pthread_mutex_t *__mutex) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_mutex_getprioceiling (const pthread_mutex_t * > __restrict __mutex, > int *__restrict __prioceiling) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int pthread_mutex_setprioceiling (pthread_mutex_t *__restrict __mutex, > int __prioceiling, > int *__restrict __old_ceiling) > throw () __attribute__ ((__nonnull__ (1, 3))); > > > > >extern int pthread_mutex_consistent (pthread_mutex_t *__mutex) > throw () __attribute__ ((__nonnull__ (1))); > >extern int pthread_mutex_consistent_np (pthread_mutex_t *__mutex) > throw () __attribute__ ((__nonnull__ (1))); ># 817 "/usr/include/pthread.h" 3 4 >extern int pthread_mutexattr_init (pthread_mutexattr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_mutexattr_destroy (pthread_mutexattr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_mutexattr_getpshared (const pthread_mutexattr_t * > __restrict __attr, > int *__restrict __pshared) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_mutexattr_setpshared (pthread_mutexattr_t *__attr, > int __pshared) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_mutexattr_gettype (const pthread_mutexattr_t *__restrict > __attr, int *__restrict __kind) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > >extern int pthread_mutexattr_settype (pthread_mutexattr_t *__attr, int __kind) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_mutexattr_getprotocol (const pthread_mutexattr_t * > __restrict __attr, > int *__restrict __protocol) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int pthread_mutexattr_setprotocol (pthread_mutexattr_t *__attr, > int __protocol) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_mutexattr_getprioceiling (const pthread_mutexattr_t * > __restrict __attr, > int *__restrict __prioceiling) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_mutexattr_setprioceiling (pthread_mutexattr_t *__attr, > int __prioceiling) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_mutexattr_getrobust (const pthread_mutexattr_t *__attr, > int *__robustness) > throw () __attribute__ ((__nonnull__ (1, 2))); > >extern int pthread_mutexattr_getrobust_np (const pthread_mutexattr_t *__attr, > int *__robustness) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int pthread_mutexattr_setrobust (pthread_mutexattr_t *__attr, > int __robustness) > throw () __attribute__ ((__nonnull__ (1))); > >extern int pthread_mutexattr_setrobust_np (pthread_mutexattr_t *__attr, > int __robustness) > throw () __attribute__ ((__nonnull__ (1))); ># 899 "/usr/include/pthread.h" 3 4 >extern int pthread_rwlock_init (pthread_rwlock_t *__restrict __rwlock, > const pthread_rwlockattr_t *__restrict > __attr) throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_rwlock_destroy (pthread_rwlock_t *__rwlock) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_rwlock_rdlock (pthread_rwlock_t *__rwlock) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_rwlock_tryrdlock (pthread_rwlock_t *__rwlock) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_rwlock_timedrdlock (pthread_rwlock_t *__restrict __rwlock, > const struct timespec *__restrict > __abstime) throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int pthread_rwlock_wrlock (pthread_rwlock_t *__rwlock) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_rwlock_trywrlock (pthread_rwlock_t *__rwlock) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_rwlock_timedwrlock (pthread_rwlock_t *__restrict __rwlock, > const struct timespec *__restrict > __abstime) throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int pthread_rwlock_unlock (pthread_rwlock_t *__rwlock) > throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern int pthread_rwlockattr_init (pthread_rwlockattr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_rwlockattr_destroy (pthread_rwlockattr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_rwlockattr_getpshared (const pthread_rwlockattr_t * > __restrict __attr, > int *__restrict __pshared) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_rwlockattr_setpshared (pthread_rwlockattr_t *__attr, > int __pshared) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_rwlockattr_getkind_np (const pthread_rwlockattr_t * > __restrict __attr, > int *__restrict __pref) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_rwlockattr_setkind_np (pthread_rwlockattr_t *__attr, > int __pref) throw () __attribute__ ((__nonnull__ (1))); > > > > > > > >extern int pthread_cond_init (pthread_cond_t *__restrict __cond, > const pthread_condattr_t *__restrict __cond_attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_cond_destroy (pthread_cond_t *__cond) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_cond_signal (pthread_cond_t *__cond) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_cond_broadcast (pthread_cond_t *__cond) > throw () __attribute__ ((__nonnull__ (1))); > > > > > > >extern int pthread_cond_wait (pthread_cond_t *__restrict __cond, > pthread_mutex_t *__restrict __mutex) > __attribute__ ((__nonnull__ (1, 2))); ># 1011 "/usr/include/pthread.h" 3 4 >extern int pthread_cond_timedwait (pthread_cond_t *__restrict __cond, > pthread_mutex_t *__restrict __mutex, > const struct timespec *__restrict __abstime) > __attribute__ ((__nonnull__ (1, 2, 3))); > > > > >extern int pthread_condattr_init (pthread_condattr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_condattr_destroy (pthread_condattr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_condattr_getpshared (const pthread_condattr_t * > __restrict __attr, > int *__restrict __pshared) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_condattr_setpshared (pthread_condattr_t *__attr, > int __pshared) throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_condattr_getclock (const pthread_condattr_t * > __restrict __attr, > __clockid_t *__restrict __clock_id) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_condattr_setclock (pthread_condattr_t *__attr, > __clockid_t __clock_id) > throw () __attribute__ ((__nonnull__ (1))); ># 1055 "/usr/include/pthread.h" 3 4 >extern int pthread_spin_init (pthread_spinlock_t *__lock, int __pshared) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_spin_destroy (pthread_spinlock_t *__lock) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_spin_lock (pthread_spinlock_t *__lock) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_spin_trylock (pthread_spinlock_t *__lock) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_spin_unlock (pthread_spinlock_t *__lock) > throw () __attribute__ ((__nonnull__ (1))); > > > > > > >extern int pthread_barrier_init (pthread_barrier_t *__restrict __barrier, > const pthread_barrierattr_t *__restrict > __attr, unsigned int __count) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_barrier_destroy (pthread_barrier_t *__barrier) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_barrier_wait (pthread_barrier_t *__barrier) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int pthread_barrierattr_init (pthread_barrierattr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_barrierattr_destroy (pthread_barrierattr_t *__attr) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_barrierattr_getpshared (const pthread_barrierattr_t * > __restrict __attr, > int *__restrict __pshared) > throw () __attribute__ ((__nonnull__ (1, 2))); > > >extern int pthread_barrierattr_setpshared (pthread_barrierattr_t *__attr, > int __pshared) > throw () __attribute__ ((__nonnull__ (1))); ># 1122 "/usr/include/pthread.h" 3 4 >extern int pthread_key_create (pthread_key_t *__key, > void (*__destr_function) (void *)) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int pthread_key_delete (pthread_key_t __key) throw (); > > >extern void *pthread_getspecific (pthread_key_t __key) throw (); > > >extern int pthread_setspecific (pthread_key_t __key, > const void *__pointer) throw () ; > > > > >extern int pthread_getcpuclockid (pthread_t __thread_id, > __clockid_t *__clock_id) > throw () __attribute__ ((__nonnull__ (2))); ># 1156 "/usr/include/pthread.h" 3 4 >extern int pthread_atfork (void (*__prepare) (void), > void (*__parent) (void), > void (*__child) (void)) throw (); > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) pthread_equal (pthread_t __thread1, pthread_t __thread2) throw () >{ > return __thread1 == __thread2; >} > > >} ># 36 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 2 3 ># 47 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 3 >typedef pthread_t __gthread_t; >typedef pthread_key_t __gthread_key_t; >typedef pthread_once_t __gthread_once_t; >typedef pthread_mutex_t __gthread_mutex_t; >typedef pthread_mutex_t __gthread_recursive_mutex_t; >typedef pthread_cond_t __gthread_cond_t; >typedef struct timespec __gthread_time_t; ># 101 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 3 >static __typeof(pthread_once) __gthrw_pthread_once __attribute__ ((__weakref__("pthread_once"))); >static __typeof(pthread_getspecific) __gthrw_pthread_getspecific __attribute__ ((__weakref__("pthread_getspecific"))); >static __typeof(pthread_setspecific) __gthrw_pthread_setspecific __attribute__ ((__weakref__("pthread_setspecific"))); > >static __typeof(pthread_create) __gthrw_pthread_create __attribute__ ((__weakref__("pthread_create"))); >static __typeof(pthread_join) __gthrw_pthread_join __attribute__ ((__weakref__("pthread_join"))); >static __typeof(pthread_equal) __gthrw_pthread_equal __attribute__ ((__weakref__("pthread_equal"))); >static __typeof(pthread_self) __gthrw_pthread_self __attribute__ ((__weakref__("pthread_self"))); >static __typeof(pthread_detach) __gthrw_pthread_detach __attribute__ ((__weakref__("pthread_detach"))); > >static __typeof(pthread_cancel) __gthrw_pthread_cancel __attribute__ ((__weakref__("pthread_cancel"))); > >static __typeof(sched_yield) __gthrw_sched_yield __attribute__ ((__weakref__("sched_yield"))); > >static __typeof(pthread_mutex_lock) __gthrw_pthread_mutex_lock __attribute__ ((__weakref__("pthread_mutex_lock"))); >static __typeof(pthread_mutex_trylock) __gthrw_pthread_mutex_trylock __attribute__ ((__weakref__("pthread_mutex_trylock"))); > >static __typeof(pthread_mutex_timedlock) __gthrw_pthread_mutex_timedlock __attribute__ ((__weakref__("pthread_mutex_timedlock"))); > >static __typeof(pthread_mutex_unlock) __gthrw_pthread_mutex_unlock __attribute__ ((__weakref__("pthread_mutex_unlock"))); >static __typeof(pthread_mutex_init) __gthrw_pthread_mutex_init __attribute__ ((__weakref__("pthread_mutex_init"))); >static __typeof(pthread_mutex_destroy) __gthrw_pthread_mutex_destroy __attribute__ ((__weakref__("pthread_mutex_destroy"))); > >static __typeof(pthread_cond_init) __gthrw_pthread_cond_init __attribute__ ((__weakref__("pthread_cond_init"))); >static __typeof(pthread_cond_broadcast) __gthrw_pthread_cond_broadcast __attribute__ ((__weakref__("pthread_cond_broadcast"))); >static __typeof(pthread_cond_signal) __gthrw_pthread_cond_signal __attribute__ ((__weakref__("pthread_cond_signal"))); >static __typeof(pthread_cond_wait) __gthrw_pthread_cond_wait __attribute__ ((__weakref__("pthread_cond_wait"))); >static __typeof(pthread_cond_timedwait) __gthrw_pthread_cond_timedwait __attribute__ ((__weakref__("pthread_cond_timedwait"))); >static __typeof(pthread_cond_destroy) __gthrw_pthread_cond_destroy __attribute__ ((__weakref__("pthread_cond_destroy"))); > >static __typeof(pthread_key_create) __gthrw_pthread_key_create __attribute__ ((__weakref__("pthread_key_create"))); >static __typeof(pthread_key_delete) __gthrw_pthread_key_delete __attribute__ ((__weakref__("pthread_key_delete"))); >static __typeof(pthread_mutexattr_init) __gthrw_pthread_mutexattr_init __attribute__ ((__weakref__("pthread_mutexattr_init"))); >static __typeof(pthread_mutexattr_settype) __gthrw_pthread_mutexattr_settype __attribute__ ((__weakref__("pthread_mutexattr_settype"))); >static __typeof(pthread_mutexattr_destroy) __gthrw_pthread_mutexattr_destroy __attribute__ ((__weakref__("pthread_mutexattr_destroy"))); ># 236 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 3 >static __typeof(pthread_key_create) __gthrw___pthread_key_create __attribute__ ((__weakref__("__pthread_key_create"))); ># 246 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 3 >static inline int >__gthread_active_p (void) >{ > static void *const __gthread_active_ptr > = __extension__ (void *) &__gthrw___pthread_key_create; > return __gthread_active_ptr != 0; >} ># 658 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 3 >static inline int >__gthread_create (__gthread_t *__threadid, void *(*__func) (void*), > void *__args) >{ > return __gthrw_pthread_create (__threadid, __null, __func, __args); >} > >static inline int >__gthread_join (__gthread_t __threadid, void **__value_ptr) >{ > return __gthrw_pthread_join (__threadid, __value_ptr); >} > >static inline int >__gthread_detach (__gthread_t __threadid) >{ > return __gthrw_pthread_detach (__threadid); >} > >static inline int >__gthread_equal (__gthread_t __t1, __gthread_t __t2) >{ > return __gthrw_pthread_equal (__t1, __t2); >} > >static inline __gthread_t >__gthread_self (void) >{ > return __gthrw_pthread_self (); >} > >static inline int >__gthread_yield (void) >{ > return __gthrw_sched_yield (); >} > >static inline int >__gthread_once (__gthread_once_t *__once, void (*__func) (void)) >{ > if (__gthread_active_p ()) > return __gthrw_pthread_once (__once, __func); > else > return -1; >} > >static inline int >__gthread_key_create (__gthread_key_t *__key, void (*__dtor) (void *)) >{ > return __gthrw_pthread_key_create (__key, __dtor); >} > >static inline int >__gthread_key_delete (__gthread_key_t __key) >{ > return __gthrw_pthread_key_delete (__key); >} > >static inline void * >__gthread_getspecific (__gthread_key_t __key) >{ > return __gthrw_pthread_getspecific (__key); >} > >static inline int >__gthread_setspecific (__gthread_key_t __key, const void *__ptr) >{ > return __gthrw_pthread_setspecific (__key, __ptr); >} > >static inline void >__gthread_mutex_init_function (__gthread_mutex_t *__mutex) >{ > if (__gthread_active_p ()) > __gthrw_pthread_mutex_init (__mutex, __null); >} > >static inline int >__gthread_mutex_destroy (__gthread_mutex_t *__mutex) >{ > if (__gthread_active_p ()) > return __gthrw_pthread_mutex_destroy (__mutex); > else > return 0; >} > >static inline int >__gthread_mutex_lock (__gthread_mutex_t *__mutex) >{ > if (__gthread_active_p ()) > return __gthrw_pthread_mutex_lock (__mutex); > else > return 0; >} > >static inline int >__gthread_mutex_trylock (__gthread_mutex_t *__mutex) >{ > if (__gthread_active_p ()) > return __gthrw_pthread_mutex_trylock (__mutex); > else > return 0; >} > > >static inline int >__gthread_mutex_timedlock (__gthread_mutex_t *__mutex, > const __gthread_time_t *__abs_timeout) >{ > if (__gthread_active_p ()) > return __gthrw_pthread_mutex_timedlock (__mutex, __abs_timeout); > else > return 0; >} > > >static inline int >__gthread_mutex_unlock (__gthread_mutex_t *__mutex) >{ > if (__gthread_active_p ()) > return __gthrw_pthread_mutex_unlock (__mutex); > else > return 0; >} ># 807 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 3 >static inline int >__gthread_recursive_mutex_lock (__gthread_recursive_mutex_t *__mutex) >{ > return __gthread_mutex_lock (__mutex); >} > >static inline int >__gthread_recursive_mutex_trylock (__gthread_recursive_mutex_t *__mutex) >{ > return __gthread_mutex_trylock (__mutex); >} > > >static inline int >__gthread_recursive_mutex_timedlock (__gthread_recursive_mutex_t *__mutex, > const __gthread_time_t *__abs_timeout) >{ > return __gthread_mutex_timedlock (__mutex, __abs_timeout); >} > > >static inline int >__gthread_recursive_mutex_unlock (__gthread_recursive_mutex_t *__mutex) >{ > return __gthread_mutex_unlock (__mutex); >} > >static inline int >__gthread_recursive_mutex_destroy (__gthread_recursive_mutex_t *__mutex) >{ > return __gthread_mutex_destroy (__mutex); >} ># 849 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr-default.h" 3 >static inline int >__gthread_cond_broadcast (__gthread_cond_t *__cond) >{ > return __gthrw_pthread_cond_broadcast (__cond); >} > >static inline int >__gthread_cond_signal (__gthread_cond_t *__cond) >{ > return __gthrw_pthread_cond_signal (__cond); >} > >static inline int >__gthread_cond_wait (__gthread_cond_t *__cond, __gthread_mutex_t *__mutex) >{ > return __gthrw_pthread_cond_wait (__cond, __mutex); >} > >static inline int >__gthread_cond_timedwait (__gthread_cond_t *__cond, __gthread_mutex_t *__mutex, > const __gthread_time_t *__abs_timeout) >{ > return __gthrw_pthread_cond_timedwait (__cond, __mutex, __abs_timeout); >} > >static inline int >__gthread_cond_wait_recursive (__gthread_cond_t *__cond, > __gthread_recursive_mutex_t *__mutex) >{ > return __gthread_cond_wait (__cond, __mutex); >} > >static inline int >__gthread_cond_destroy (__gthread_cond_t* __cond) >{ > return __gthrw_pthread_cond_destroy (__cond); >} ># 149 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/gthr.h" 2 3 > > >#pragma GCC visibility pop ># 36 "/usr/include/c++/4.9.0/ext/atomicity.h" 2 3 ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/atomic_word.h" 1 3 ># 32 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/atomic_word.h" 3 >typedef int _Atomic_word; ># 37 "/usr/include/c++/4.9.0/ext/atomicity.h" 2 3 > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > > static inline _Atomic_word > __exchange_and_add(volatile _Atomic_word* __mem, int __val) > { return __atomic_fetch_add(__mem, __val, 4); } > > static inline void > __atomic_add(volatile _Atomic_word* __mem, int __val) > { __atomic_fetch_add(__mem, __val, 4); } ># 64 "/usr/include/c++/4.9.0/ext/atomicity.h" 3 > static inline _Atomic_word > __exchange_and_add_single(_Atomic_word* __mem, int __val) > { > _Atomic_word __result = *__mem; > *__mem += __val; > return __result; > } > > static inline void > __atomic_add_single(_Atomic_word* __mem, int __val) > { *__mem += __val; } > > static inline _Atomic_word > __attribute__ ((__unused__)) > __exchange_and_add_dispatch(_Atomic_word* __mem, int __val) > { > > if (__gthread_active_p()) > return __exchange_and_add(__mem, __val); > else > return __exchange_and_add_single(__mem, __val); > > > > } > > static inline void > __attribute__ ((__unused__)) > __atomic_add_dispatch(_Atomic_word* __mem, int __val) > { > > if (__gthread_active_p()) > __atomic_add(__mem, __val); > else > __atomic_add_single(__mem, __val); > > > > } > > >} ># 40 "/usr/include/c++/4.9.0/bits/ios_base.h" 2 3 > ># 1 "/usr/include/c++/4.9.0/bits/locale_classes.h" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 ># 38 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > > ># 1 "/usr/include/c++/4.9.0/string" 1 3 ># 36 "/usr/include/c++/4.9.0/string" 3 ># 37 "/usr/include/c++/4.9.0/string" 3 > > > > ># 1 "/usr/include/c++/4.9.0/bits/allocator.h" 1 3 ># 46 "/usr/include/c++/4.9.0/bits/allocator.h" 3 ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++allocator.h" 1 3 ># 33 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++allocator.h" 3 ># 1 "/usr/include/c++/4.9.0/ext/new_allocator.h" 1 3 ># 33 "/usr/include/c++/4.9.0/ext/new_allocator.h" 3 ># 1 "/usr/include/c++/4.9.0/new" 1 3 ># 37 "/usr/include/c++/4.9.0/new" 3 ># 38 "/usr/include/c++/4.9.0/new" 3 > > > > >#pragma GCC visibility push(default) > >extern "C++" { > >namespace std >{ > > > > > > > class bad_alloc : public exception > { > public: > bad_alloc() throw() { } > > > > virtual ~bad_alloc() throw(); > > > virtual const char* what() const throw(); > }; > > > class bad_array_new_length : public bad_alloc > { > public: > bad_array_new_length() throw() { }; > > > > virtual ~bad_array_new_length() throw(); > > > virtual const char* what() const throw(); > }; > > > > > > class bad_array_length : public bad_alloc > { > public: > bad_array_length() throw() { }; > > > > virtual ~bad_array_length() throw(); > > > virtual const char* what() const throw(); > }; > > > struct nothrow_t { }; > > extern const nothrow_t nothrow; > > > > typedef void (*new_handler)(); > > > > new_handler set_new_handler(new_handler) throw(); > > > > new_handler get_new_handler() noexcept; > >} ># 128 "/usr/include/c++/4.9.0/new" 3 >void* operator new(std::size_t) > __attribute__((__externally_visible__)); >void* operator new[](std::size_t) > __attribute__((__externally_visible__)); >void operator delete(void*) noexcept > __attribute__((__externally_visible__)); >void operator delete[](void*) noexcept > __attribute__((__externally_visible__)); >void* operator new(std::size_t, const std::nothrow_t&) noexcept > __attribute__((__externally_visible__)); >void* operator new[](std::size_t, const std::nothrow_t&) noexcept > __attribute__((__externally_visible__)); >void operator delete(void*, const std::nothrow_t&) noexcept > __attribute__((__externally_visible__)); >void operator delete[](void*, const std::nothrow_t&) noexcept > __attribute__((__externally_visible__)); > > >inline void* operator new(std::size_t, void* __p) noexcept >{ return __p; } >inline void* operator new[](std::size_t, void* __p) noexcept >{ return __p; } > > >inline void operator delete (void*, void*) noexcept { } >inline void operator delete[](void*, void*) noexcept { } > >} > >#pragma GCC visibility pop ># 34 "/usr/include/c++/4.9.0/ext/new_allocator.h" 2 3 > > > > > > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > using std::size_t; > using std::ptrdiff_t; ># 57 "/usr/include/c++/4.9.0/ext/new_allocator.h" 3 > template<typename _Tp> > class new_allocator > { > public: > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef _Tp* pointer; > typedef const _Tp* const_pointer; > typedef _Tp& reference; > typedef const _Tp& const_reference; > typedef _Tp value_type; > > template<typename _Tp1> > struct rebind > { typedef new_allocator<_Tp1> other; }; > > > > > typedef std::true_type propagate_on_container_move_assignment; > > > new_allocator() noexcept { } > > new_allocator(const new_allocator&) noexcept { } > > template<typename _Tp1> > new_allocator(const new_allocator<_Tp1>&) noexcept { } > > ~new_allocator() noexcept { } > > pointer > address(reference __x) const noexcept > { return std::__addressof(__x); } > > const_pointer > address(const_reference __x) const noexcept > { return std::__addressof(__x); } > > > > pointer > allocate(size_type __n, const void* = 0) > { > if (__n > this->max_size()) > std::__throw_bad_alloc(); > > return static_cast<_Tp*>(::operator new(__n * sizeof(_Tp))); > } > > > void > deallocate(pointer __p, size_type) > { ::operator delete(__p); } > > size_type > max_size() const noexcept > { return size_t(-1) / sizeof(_Tp); } > > > template<typename _Up, typename... _Args> > void > construct(_Up* __p, _Args&&... __args) > { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); } > > template<typename _Up> > void > destroy(_Up* __p) { __p->~_Up(); } ># 135 "/usr/include/c++/4.9.0/ext/new_allocator.h" 3 > }; > > template<typename _Tp> > inline bool > operator==(const new_allocator<_Tp>&, const new_allocator<_Tp>&) > { return true; } > > template<typename _Tp> > inline bool > operator!=(const new_allocator<_Tp>&, const new_allocator<_Tp>&) > { return false; } > > >} ># 34 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++allocator.h" 2 3 > > >namespace std >{ ># 47 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++allocator.h" 3 > template<typename _Tp> > using __allocator_base = __gnu_cxx::new_allocator<_Tp>; >} ># 47 "/usr/include/c++/4.9.0/bits/allocator.h" 2 3 > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 62 "/usr/include/c++/4.9.0/bits/allocator.h" 3 > template<> > class allocator<void> > { > public: > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef void* pointer; > typedef const void* const_pointer; > typedef void value_type; > > template<typename _Tp1> > struct rebind > { typedef allocator<_Tp1> other; }; > > > > > typedef true_type propagate_on_container_move_assignment; > > }; ># 91 "/usr/include/c++/4.9.0/bits/allocator.h" 3 > template<typename _Tp> > class allocator: public __allocator_base<_Tp> > { > public: > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef _Tp* pointer; > typedef const _Tp* const_pointer; > typedef _Tp& reference; > typedef const _Tp& const_reference; > typedef _Tp value_type; > > template<typename _Tp1> > struct rebind > { typedef allocator<_Tp1> other; }; > > > > > typedef true_type propagate_on_container_move_assignment; > > > allocator() throw() { } > > allocator(const allocator& __a) throw() > : __allocator_base<_Tp>(__a) { } > > template<typename _Tp1> > allocator(const allocator<_Tp1>&) throw() { } > > ~allocator() throw() { } > > > }; > > template<typename _T1, typename _T2> > inline bool > operator==(const allocator<_T1>&, const allocator<_T2>&) > { return true; } > > template<typename _Tp> > inline bool > operator==(const allocator<_Tp>&, const allocator<_Tp>&) > { return true; } > > template<typename _T1, typename _T2> > inline bool > operator!=(const allocator<_T1>&, const allocator<_T2>&) > { return false; } > > template<typename _Tp> > inline bool > operator!=(const allocator<_Tp>&, const allocator<_Tp>&) > { return false; } > > > > > > > extern template class allocator<char>; > extern template class allocator<wchar_t>; > > > > > > > template<typename _Alloc, bool = __is_empty(_Alloc)> > struct __alloc_swap > { static void _S_do_it(_Alloc&, _Alloc&) noexcept { } }; > > template<typename _Alloc> > struct __alloc_swap<_Alloc, false> > { > static void > _S_do_it(_Alloc& __one, _Alloc& __two) noexcept > { > > if (__one != __two) > swap(__one, __two); > } > }; > > > template<typename _Alloc, bool = __is_empty(_Alloc)> > struct __alloc_neq > { > static bool > _S_do_it(const _Alloc&, const _Alloc&) > { return false; } > }; > > template<typename _Alloc> > struct __alloc_neq<_Alloc, false> > { > static bool > _S_do_it(const _Alloc& __one, const _Alloc& __two) > { return __one != __two; } > }; > > > template<typename _Tp, bool > = __or_<is_copy_constructible<typename _Tp::value_type>, > is_nothrow_move_constructible<typename _Tp::value_type>>::value> > struct __shrink_to_fit_aux > { static bool _S_do_it(_Tp&) noexcept { return false; } }; > > template<typename _Tp> > struct __shrink_to_fit_aux<_Tp, true> > { > static bool > _S_do_it(_Tp& __c) noexcept > { > try > { > _Tp(__make_move_if_noexcept_iterator(__c.begin()), > __make_move_if_noexcept_iterator(__c.end()), > __c.get_allocator()).swap(__c); > return true; > } > catch(...) > { return false; } > } > }; > > > >} ># 42 "/usr/include/c++/4.9.0/string" 2 3 > > ># 1 "/usr/include/c++/4.9.0/bits/ostream_insert.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/ostream_insert.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/ostream_insert.h" 3 > > ># 1 "/usr/include/c++/4.9.0/bits/cxxabi_forced.h" 1 3 ># 34 "/usr/include/c++/4.9.0/bits/cxxabi_forced.h" 3 ># 35 "/usr/include/c++/4.9.0/bits/cxxabi_forced.h" 3 > >#pragma GCC visibility push(default) > > >namespace __cxxabiv1 >{ > > > > > > > > class __forced_unwind > { > virtual ~__forced_unwind() throw(); > > > virtual void __pure_dummy() = 0; > }; >} > > >#pragma GCC visibility pop ># 37 "/usr/include/c++/4.9.0/bits/ostream_insert.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT, typename _Traits> > inline void > __ostream_write(basic_ostream<_CharT, _Traits>& __out, > const _CharT* __s, streamsize __n) > { > typedef basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const streamsize __put = __out.rdbuf()->sputn(__s, __n); > if (__put != __n) > __out.setstate(__ios_base::badbit); > } > > template<typename _CharT, typename _Traits> > inline void > __ostream_fill(basic_ostream<_CharT, _Traits>& __out, streamsize __n) > { > typedef basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const _CharT __c = __out.fill(); > for (; __n > 0; --__n) > { > const typename _Traits::int_type __put = __out.rdbuf()->sputc(__c); > if (_Traits::eq_int_type(__put, _Traits::eof())) > { > __out.setstate(__ios_base::badbit); > break; > } > } > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > __ostream_insert(basic_ostream<_CharT, _Traits>& __out, > const _CharT* __s, streamsize __n) > { > typedef basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > typename __ostream_type::sentry __cerb(__out); > if (__cerb) > { > try > { > const streamsize __w = __out.width(); > if (__w > __n) > { > const bool __left = ((__out.flags() > & __ios_base::adjustfield) > == __ios_base::left); > if (!__left) > __ostream_fill(__out, __w - __n); > if (__out.good()) > __ostream_write(__out, __s, __n); > if (__left && __out.good()) > __ostream_fill(__out, __w - __n); > } > else > __ostream_write(__out, __s, __n); > __out.width(0); > } > catch(__cxxabiv1::__forced_unwind&) > { > __out._M_setstate(__ios_base::badbit); > throw; > } > catch(...) > { __out._M_setstate(__ios_base::badbit); } > } > return __out; > } > > > > > extern template ostream& __ostream_insert(ostream&, const char*, streamsize); > > > extern template wostream& __ostream_insert(wostream&, const wchar_t*, > streamsize); > > > > >} ># 45 "/usr/include/c++/4.9.0/string" 2 3 > > > ># 1 "/usr/include/c++/4.9.0/bits/stl_function.h" 1 3 ># 63 "/usr/include/c++/4.9.0/bits/stl_function.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 104 "/usr/include/c++/4.9.0/bits/stl_function.h" 3 > template<typename _Arg, typename _Result> > struct unary_function > { > > typedef _Arg argument_type; > > > typedef _Result result_type; > }; > > > > > template<typename _Arg1, typename _Arg2, typename _Result> > struct binary_function > { > > typedef _Arg1 first_argument_type; > > > typedef _Arg2 second_argument_type; > > > typedef _Result result_type; > }; ># 166 "/usr/include/c++/4.9.0/bits/stl_function.h" 3 > template<typename _Tp> > struct plus : public binary_function<_Tp, _Tp, _Tp> > { > _Tp > operator()(const _Tp& __x, const _Tp& __y) const > { return __x + __y; } > }; > > > template<typename _Tp> > struct minus : public binary_function<_Tp, _Tp, _Tp> > { > _Tp > operator()(const _Tp& __x, const _Tp& __y) const > { return __x - __y; } > }; > > > template<typename _Tp> > struct multiplies : public binary_function<_Tp, _Tp, _Tp> > { > _Tp > operator()(const _Tp& __x, const _Tp& __y) const > { return __x * __y; } > }; > > > template<typename _Tp> > struct divides : public binary_function<_Tp, _Tp, _Tp> > { > _Tp > operator()(const _Tp& __x, const _Tp& __y) const > { return __x / __y; } > }; > > > template<typename _Tp> > struct modulus : public binary_function<_Tp, _Tp, _Tp> > { > _Tp > operator()(const _Tp& __x, const _Tp& __y) const > { return __x % __y; } > }; > > > template<typename _Tp> > struct negate : public unary_function<_Tp, _Tp> > { > _Tp > operator()(const _Tp& __x) const > { return -__x; } > }; ># 335 "/usr/include/c++/4.9.0/bits/stl_function.h" 3 > template<typename _Tp> > struct equal_to : public binary_function<_Tp, _Tp, bool> > { > bool > operator()(const _Tp& __x, const _Tp& __y) const > { return __x == __y; } > }; > > > template<typename _Tp> > struct not_equal_to : public binary_function<_Tp, _Tp, bool> > { > bool > operator()(const _Tp& __x, const _Tp& __y) const > { return __x != __y; } > }; > > > template<typename _Tp> > struct greater : public binary_function<_Tp, _Tp, bool> > { > bool > operator()(const _Tp& __x, const _Tp& __y) const > { return __x > __y; } > }; > > > template<typename _Tp> > struct less : public binary_function<_Tp, _Tp, bool> > { > bool > operator()(const _Tp& __x, const _Tp& __y) const > { return __x < __y; } > }; > > > template<typename _Tp> > struct greater_equal : public binary_function<_Tp, _Tp, bool> > { > bool > operator()(const _Tp& __x, const _Tp& __y) const > { return __x >= __y; } > }; > > > template<typename _Tp> > struct less_equal : public binary_function<_Tp, _Tp, bool> > { > bool > operator()(const _Tp& __x, const _Tp& __y) const > { return __x <= __y; } > }; ># 496 "/usr/include/c++/4.9.0/bits/stl_function.h" 3 > template<typename _Tp> > struct logical_and : public binary_function<_Tp, _Tp, bool> > { > bool > operator()(const _Tp& __x, const _Tp& __y) const > { return __x && __y; } > }; > > > template<typename _Tp> > struct logical_or : public binary_function<_Tp, _Tp, bool> > { > bool > operator()(const _Tp& __x, const _Tp& __y) const > { return __x || __y; } > }; > > > template<typename _Tp> > struct logical_not : public unary_function<_Tp, bool> > { > bool > operator()(const _Tp& __x) const > { return !__x; } > }; ># 583 "/usr/include/c++/4.9.0/bits/stl_function.h" 3 > template<typename _Tp> > struct bit_and : public binary_function<_Tp, _Tp, _Tp> > { > _Tp > operator()(const _Tp& __x, const _Tp& __y) const > { return __x & __y; } > }; > > template<typename _Tp> > struct bit_or : public binary_function<_Tp, _Tp, _Tp> > { > _Tp > operator()(const _Tp& __x, const _Tp& __y) const > { return __x | __y; } > }; > > template<typename _Tp> > struct bit_xor : public binary_function<_Tp, _Tp, _Tp> > { > _Tp > operator()(const _Tp& __x, const _Tp& __y) const > { return __x ^ __y; } > }; > > template<typename _Tp> > struct bit_not : public unary_function<_Tp, _Tp> > { > _Tp > operator()(const _Tp& __x) const > { return ~__x; } > }; ># 699 "/usr/include/c++/4.9.0/bits/stl_function.h" 3 > template<typename _Predicate> > class unary_negate > : public unary_function<typename _Predicate::argument_type, bool> > { > protected: > _Predicate _M_pred; > > public: > explicit > unary_negate(const _Predicate& __x) : _M_pred(__x) { } > > bool > operator()(const typename _Predicate::argument_type& __x) const > { return !_M_pred(__x); } > }; > > > template<typename _Predicate> > inline unary_negate<_Predicate> > not1(const _Predicate& __pred) > { return unary_negate<_Predicate>(__pred); } > > > template<typename _Predicate> > class binary_negate > : public binary_function<typename _Predicate::first_argument_type, > typename _Predicate::second_argument_type, bool> > { > protected: > _Predicate _M_pred; > > public: > explicit > binary_negate(const _Predicate& __x) : _M_pred(__x) { } > > bool > operator()(const typename _Predicate::first_argument_type& __x, > const typename _Predicate::second_argument_type& __y) const > { return !_M_pred(__x, __y); } > }; > > > template<typename _Predicate> > inline binary_negate<_Predicate> > not2(const _Predicate& __pred) > { return binary_negate<_Predicate>(__pred); } ># 770 "/usr/include/c++/4.9.0/bits/stl_function.h" 3 > template<typename _Arg, typename _Result> > class pointer_to_unary_function : public unary_function<_Arg, _Result> > { > protected: > _Result (*_M_ptr)(_Arg); > > public: > pointer_to_unary_function() { } > > explicit > pointer_to_unary_function(_Result (*__x)(_Arg)) > : _M_ptr(__x) { } > > _Result > operator()(_Arg __x) const > { return _M_ptr(__x); } > }; > > > template<typename _Arg, typename _Result> > inline pointer_to_unary_function<_Arg, _Result> > ptr_fun(_Result (*__x)(_Arg)) > { return pointer_to_unary_function<_Arg, _Result>(__x); } > > > template<typename _Arg1, typename _Arg2, typename _Result> > class pointer_to_binary_function > : public binary_function<_Arg1, _Arg2, _Result> > { > protected: > _Result (*_M_ptr)(_Arg1, _Arg2); > > public: > pointer_to_binary_function() { } > > explicit > pointer_to_binary_function(_Result (*__x)(_Arg1, _Arg2)) > : _M_ptr(__x) { } > > _Result > operator()(_Arg1 __x, _Arg2 __y) const > { return _M_ptr(__x, __y); } > }; > > > template<typename _Arg1, typename _Arg2, typename _Result> > inline pointer_to_binary_function<_Arg1, _Arg2, _Result> > ptr_fun(_Result (*__x)(_Arg1, _Arg2)) > { return pointer_to_binary_function<_Arg1, _Arg2, _Result>(__x); } > > > template<typename _Tp> > struct _Identity > : public unary_function<_Tp,_Tp> > { > _Tp& > operator()(_Tp& __x) const > { return __x; } > > const _Tp& > operator()(const _Tp& __x) const > { return __x; } > }; > > template<typename _Pair> > struct _Select1st > : public unary_function<_Pair, typename _Pair::first_type> > { > typename _Pair::first_type& > operator()(_Pair& __x) const > { return __x.first; } > > const typename _Pair::first_type& > operator()(const _Pair& __x) const > { return __x.first; } > > > template<typename _Pair2> > typename _Pair2::first_type& > operator()(_Pair2& __x) const > { return __x.first; } > > template<typename _Pair2> > const typename _Pair2::first_type& > operator()(const _Pair2& __x) const > { return __x.first; } > > }; > > template<typename _Pair> > struct _Select2nd > : public unary_function<_Pair, typename _Pair::second_type> > { > typename _Pair::second_type& > operator()(_Pair& __x) const > { return __x.second; } > > const typename _Pair::second_type& > operator()(const _Pair& __x) const > { return __x.second; } > }; ># 890 "/usr/include/c++/4.9.0/bits/stl_function.h" 3 > template<typename _Ret, typename _Tp> > class mem_fun_t : public unary_function<_Tp*, _Ret> > { > public: > explicit > mem_fun_t(_Ret (_Tp::*__pf)()) > : _M_f(__pf) { } > > _Ret > operator()(_Tp* __p) const > { return (__p->*_M_f)(); } > > private: > _Ret (_Tp::*_M_f)(); > }; > > > > template<typename _Ret, typename _Tp> > class const_mem_fun_t : public unary_function<const _Tp*, _Ret> > { > public: > explicit > const_mem_fun_t(_Ret (_Tp::*__pf)() const) > : _M_f(__pf) { } > > _Ret > operator()(const _Tp* __p) const > { return (__p->*_M_f)(); } > > private: > _Ret (_Tp::*_M_f)() const; > }; > > > > template<typename _Ret, typename _Tp> > class mem_fun_ref_t : public unary_function<_Tp, _Ret> > { > public: > explicit > mem_fun_ref_t(_Ret (_Tp::*__pf)()) > : _M_f(__pf) { } > > _Ret > operator()(_Tp& __r) const > { return (__r.*_M_f)(); } > > private: > _Ret (_Tp::*_M_f)(); > }; > > > > template<typename _Ret, typename _Tp> > class const_mem_fun_ref_t : public unary_function<_Tp, _Ret> > { > public: > explicit > const_mem_fun_ref_t(_Ret (_Tp::*__pf)() const) > : _M_f(__pf) { } > > _Ret > operator()(const _Tp& __r) const > { return (__r.*_M_f)(); } > > private: > _Ret (_Tp::*_M_f)() const; > }; > > > > template<typename _Ret, typename _Tp, typename _Arg> > class mem_fun1_t : public binary_function<_Tp*, _Arg, _Ret> > { > public: > explicit > mem_fun1_t(_Ret (_Tp::*__pf)(_Arg)) > : _M_f(__pf) { } > > _Ret > operator()(_Tp* __p, _Arg __x) const > { return (__p->*_M_f)(__x); } > > private: > _Ret (_Tp::*_M_f)(_Arg); > }; > > > > template<typename _Ret, typename _Tp, typename _Arg> > class const_mem_fun1_t : public binary_function<const _Tp*, _Arg, _Ret> > { > public: > explicit > const_mem_fun1_t(_Ret (_Tp::*__pf)(_Arg) const) > : _M_f(__pf) { } > > _Ret > operator()(const _Tp* __p, _Arg __x) const > { return (__p->*_M_f)(__x); } > > private: > _Ret (_Tp::*_M_f)(_Arg) const; > }; > > > > template<typename _Ret, typename _Tp, typename _Arg> > class mem_fun1_ref_t : public binary_function<_Tp, _Arg, _Ret> > { > public: > explicit > mem_fun1_ref_t(_Ret (_Tp::*__pf)(_Arg)) > : _M_f(__pf) { } > > _Ret > operator()(_Tp& __r, _Arg __x) const > { return (__r.*_M_f)(__x); } > > private: > _Ret (_Tp::*_M_f)(_Arg); > }; > > > > template<typename _Ret, typename _Tp, typename _Arg> > class const_mem_fun1_ref_t : public binary_function<_Tp, _Arg, _Ret> > { > public: > explicit > const_mem_fun1_ref_t(_Ret (_Tp::*__pf)(_Arg) const) > : _M_f(__pf) { } > > _Ret > operator()(const _Tp& __r, _Arg __x) const > { return (__r.*_M_f)(__x); } > > private: > _Ret (_Tp::*_M_f)(_Arg) const; > }; > > > > template<typename _Ret, typename _Tp> > inline mem_fun_t<_Ret, _Tp> > mem_fun(_Ret (_Tp::*__f)()) > { return mem_fun_t<_Ret, _Tp>(__f); } > > template<typename _Ret, typename _Tp> > inline const_mem_fun_t<_Ret, _Tp> > mem_fun(_Ret (_Tp::*__f)() const) > { return const_mem_fun_t<_Ret, _Tp>(__f); } > > template<typename _Ret, typename _Tp> > inline mem_fun_ref_t<_Ret, _Tp> > mem_fun_ref(_Ret (_Tp::*__f)()) > { return mem_fun_ref_t<_Ret, _Tp>(__f); } > > template<typename _Ret, typename _Tp> > inline const_mem_fun_ref_t<_Ret, _Tp> > mem_fun_ref(_Ret (_Tp::*__f)() const) > { return const_mem_fun_ref_t<_Ret, _Tp>(__f); } > > template<typename _Ret, typename _Tp, typename _Arg> > inline mem_fun1_t<_Ret, _Tp, _Arg> > mem_fun(_Ret (_Tp::*__f)(_Arg)) > { return mem_fun1_t<_Ret, _Tp, _Arg>(__f); } > > template<typename _Ret, typename _Tp, typename _Arg> > inline const_mem_fun1_t<_Ret, _Tp, _Arg> > mem_fun(_Ret (_Tp::*__f)(_Arg) const) > { return const_mem_fun1_t<_Ret, _Tp, _Arg>(__f); } > > template<typename _Ret, typename _Tp, typename _Arg> > inline mem_fun1_ref_t<_Ret, _Tp, _Arg> > mem_fun_ref(_Ret (_Tp::*__f)(_Arg)) > { return mem_fun1_ref_t<_Ret, _Tp, _Arg>(__f); } > > template<typename _Ret, typename _Tp, typename _Arg> > inline const_mem_fun1_ref_t<_Ret, _Tp, _Arg> > mem_fun_ref(_Ret (_Tp::*__f)(_Arg) const) > { return const_mem_fun1_ref_t<_Ret, _Tp, _Arg>(__f); } > > > > >} > > ># 1 "/usr/include/c++/4.9.0/backward/binders.h" 1 3 ># 59 "/usr/include/c++/4.9.0/backward/binders.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 103 "/usr/include/c++/4.9.0/backward/binders.h" 3 > template<typename _Operation> > class binder1st > : public unary_function<typename _Operation::second_argument_type, > typename _Operation::result_type> > { > protected: > _Operation op; > typename _Operation::first_argument_type value; > > public: > binder1st(const _Operation& __x, > const typename _Operation::first_argument_type& __y) > : op(__x), value(__y) { } > > typename _Operation::result_type > operator()(const typename _Operation::second_argument_type& __x) const > { return op(value, __x); } > > > > typename _Operation::result_type > operator()(typename _Operation::second_argument_type& __x) const > { return op(value, __x); } > } __attribute__ ((__deprecated__)); > > > template<typename _Operation, typename _Tp> > inline binder1st<_Operation> > bind1st(const _Operation& __fn, const _Tp& __x) > { > typedef typename _Operation::first_argument_type _Arg1_type; > return binder1st<_Operation>(__fn, _Arg1_type(__x)); > } > > > template<typename _Operation> > class binder2nd > : public unary_function<typename _Operation::first_argument_type, > typename _Operation::result_type> > { > protected: > _Operation op; > typename _Operation::second_argument_type value; > > public: > binder2nd(const _Operation& __x, > const typename _Operation::second_argument_type& __y) > : op(__x), value(__y) { } > > typename _Operation::result_type > operator()(const typename _Operation::first_argument_type& __x) const > { return op(__x, value); } > > > > typename _Operation::result_type > operator()(typename _Operation::first_argument_type& __x) const > { return op(__x, value); } > } __attribute__ ((__deprecated__)); > > > template<typename _Operation, typename _Tp> > inline binder2nd<_Operation> > bind2nd(const _Operation& __fn, const _Tp& __x) > { > typedef typename _Operation::second_argument_type _Arg2_type; > return binder2nd<_Operation>(__fn, _Arg2_type(__x)); > } > > > >} ># 1081 "/usr/include/c++/4.9.0/bits/stl_function.h" 2 3 ># 49 "/usr/include/c++/4.9.0/string" 2 3 > > ># 1 "/usr/include/c++/4.9.0/bits/range_access.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/range_access.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/range_access.h" 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > > template<class _Container> > inline auto > begin(_Container& __cont) -> decltype(__cont.begin()) > { return __cont.begin(); } > > > > > > > template<class _Container> > inline auto > begin(const _Container& __cont) -> decltype(__cont.begin()) > { return __cont.begin(); } > > > > > > > template<class _Container> > inline auto > end(_Container& __cont) -> decltype(__cont.end()) > { return __cont.end(); } > > > > > > > template<class _Container> > inline auto > end(const _Container& __cont) -> decltype(__cont.end()) > { return __cont.end(); } > > > > > > template<class _Tp, size_t _Nm> > inline _Tp* > begin(_Tp (&__arr)[_Nm]) > { return __arr; } > > > > > > > template<class _Tp, size_t _Nm> > inline _Tp* > end(_Tp (&__arr)[_Nm]) > { return __arr + _Nm; } > > >} ># 52 "/usr/include/c++/4.9.0/string" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/basic_string.h" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 ># 38 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > > > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 111 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > class basic_string > { > typedef typename _Alloc::template rebind<_CharT>::other _CharT_alloc_type; > > > public: > typedef _Traits traits_type; > typedef typename _Traits::char_type value_type; > typedef _Alloc allocator_type; > typedef typename _CharT_alloc_type::size_type size_type; > typedef typename _CharT_alloc_type::difference_type difference_type; > typedef typename _CharT_alloc_type::reference reference; > typedef typename _CharT_alloc_type::const_reference const_reference; > typedef typename _CharT_alloc_type::pointer pointer; > typedef typename _CharT_alloc_type::const_pointer const_pointer; > typedef __gnu_cxx::__normal_iterator<pointer, basic_string> iterator; > typedef __gnu_cxx::__normal_iterator<const_pointer, basic_string> > const_iterator; > typedef std::reverse_iterator<const_iterator> const_reverse_iterator; > typedef std::reverse_iterator<iterator> reverse_iterator; > > private: ># 148 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > struct _Rep_base > { > size_type _M_length; > size_type _M_capacity; > _Atomic_word _M_refcount; > }; > > struct _Rep : _Rep_base > { > > typedef typename _Alloc::template rebind<char>::other _Raw_bytes_alloc; ># 173 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > static const size_type _S_max_size; > static const _CharT _S_terminal; > > > > static size_type _S_empty_rep_storage[]; > > static _Rep& > _S_empty_rep() noexcept > { > > > > void* __p = reinterpret_cast<void*>(&_S_empty_rep_storage); > return *reinterpret_cast<_Rep*>(__p); > } > > bool > _M_is_leaked() const noexcept > { return this->_M_refcount < 0; } > > bool > _M_is_shared() const noexcept > { return this->_M_refcount > 0; } > > void > _M_set_leaked() noexcept > { this->_M_refcount = -1; } > > void > _M_set_sharable() noexcept > { this->_M_refcount = 0; } > > void > _M_set_length_and_sharable(size_type __n) noexcept > { > > if (__builtin_expect(this != &_S_empty_rep(), false)) > > { > this->_M_set_sharable(); > this->_M_length = __n; > traits_type::assign(this->_M_refdata()[__n], _S_terminal); > > > } > } > > _CharT* > _M_refdata() throw() > { return reinterpret_cast<_CharT*>(this + 1); } > > _CharT* > _M_grab(const _Alloc& __alloc1, const _Alloc& __alloc2) > { > return (!_M_is_leaked() && __alloc1 == __alloc2) > ? _M_refcopy() : _M_clone(__alloc1); > } > > > static _Rep* > _S_create(size_type, size_type, const _Alloc&); > > void > _M_dispose(const _Alloc& __a) noexcept > { > > if (__builtin_expect(this != &_S_empty_rep(), false)) > > { > > ; > if (__gnu_cxx::__exchange_and_add_dispatch(&this->_M_refcount, > -1) <= 0) > { > ; > _M_destroy(__a); > } > } > } > > void > _M_destroy(const _Alloc&) throw(); > > _CharT* > _M_refcopy() throw() > { > > if (__builtin_expect(this != &_S_empty_rep(), false)) > > __gnu_cxx::__atomic_add_dispatch(&this->_M_refcount, 1); > return _M_refdata(); > } > > _CharT* > _M_clone(const _Alloc&, size_type __res = 0); > }; > > > struct _Alloc_hider : _Alloc > { > _Alloc_hider(_CharT* __dat, const _Alloc& __a) noexcept > : _Alloc(__a), _M_p(__dat) { } > > _CharT* _M_p; > }; > > public: > > > > > static const size_type npos = static_cast<size_type>(-1); > > private: > > mutable _Alloc_hider _M_dataplus; > > _CharT* > _M_data() const noexcept > { return _M_dataplus._M_p; } > > _CharT* > _M_data(_CharT* __p) noexcept > { return (_M_dataplus._M_p = __p); } > > _Rep* > _M_rep() const noexcept > { return &((reinterpret_cast<_Rep*> (_M_data()))[-1]); } > > > > iterator > _M_ibegin() const noexcept > { return iterator(_M_data()); } > > iterator > _M_iend() const noexcept > { return iterator(_M_data() + this->size()); } > > void > _M_leak() > { > if (!_M_rep()->_M_is_leaked()) > _M_leak_hard(); > } > > size_type > _M_check(size_type __pos, const char* __s) const > { > if (__pos > this->size()) > __throw_out_of_range_fmt(("%s: __pos (which is %zu) > " "this->size() (which is %zu)") > , > __s, __pos, this->size()); > return __pos; > } > > void > _M_check_length(size_type __n1, size_type __n2, const char* __s) const > { > if (this->max_size() - (this->size() - __n1) < __n2) > __throw_length_error((__s)); > } > > > size_type > _M_limit(size_type __pos, size_type __off) const noexcept > { > const bool __testoff = __off < this->size() - __pos; > return __testoff ? __off : this->size() - __pos; > } > > > bool > _M_disjunct(const _CharT* __s) const noexcept > { > return (less<const _CharT*>()(__s, _M_data()) > || less<const _CharT*>()(_M_data() + this->size(), __s)); > } > > > > static void > _M_copy(_CharT* __d, const _CharT* __s, size_type __n) noexcept > { > if (__n == 1) > traits_type::assign(*__d, *__s); > else > traits_type::copy(__d, __s, __n); > } > > static void > _M_move(_CharT* __d, const _CharT* __s, size_type __n) noexcept > { > if (__n == 1) > traits_type::assign(*__d, *__s); > else > traits_type::move(__d, __s, __n); > } > > static void > _M_assign(_CharT* __d, size_type __n, _CharT __c) noexcept > { > if (__n == 1) > traits_type::assign(*__d, __c); > else > traits_type::assign(__d, __n, __c); > } > > > > template<class _Iterator> > static void > _S_copy_chars(_CharT* __p, _Iterator __k1, _Iterator __k2) > noexcept > { > for (; __k1 != __k2; ++__k1, ++__p) > traits_type::assign(*__p, *__k1); > } > > static void > _S_copy_chars(_CharT* __p, iterator __k1, iterator __k2) noexcept > { _S_copy_chars(__p, __k1.base(), __k2.base()); } > > static void > _S_copy_chars(_CharT* __p, const_iterator __k1, const_iterator __k2) > noexcept > { _S_copy_chars(__p, __k1.base(), __k2.base()); } > > static void > _S_copy_chars(_CharT* __p, _CharT* __k1, _CharT* __k2) noexcept > { _M_copy(__p, __k1, __k2 - __k1); } > > static void > _S_copy_chars(_CharT* __p, const _CharT* __k1, const _CharT* __k2) > noexcept > { _M_copy(__p, __k1, __k2 - __k1); } > > static int > _S_compare(size_type __n1, size_type __n2) noexcept > { > const difference_type __d = difference_type(__n1 - __n2); > > if (__d > __gnu_cxx::__numeric_traits<int>::__max) > return __gnu_cxx::__numeric_traits<int>::__max; > else if (__d < __gnu_cxx::__numeric_traits<int>::__min) > return __gnu_cxx::__numeric_traits<int>::__min; > else > return int(__d); > } > > void > _M_mutate(size_type __pos, size_type __len1, size_type __len2); > > void > _M_leak_hard(); > > static _Rep& > _S_empty_rep() noexcept > { return _Rep::_S_empty_rep(); } > > public: > > > > > > > > basic_string() > > : _M_dataplus(_S_empty_rep()._M_refdata(), _Alloc()) { } > > > > > > > > explicit > basic_string(const _Alloc& __a); > > > > > > > basic_string(const basic_string& __str); > > > > > > > basic_string(const basic_string& __str, size_type __pos, > size_type __n = npos); > > > > > > > > basic_string(const basic_string& __str, size_type __pos, > size_type __n, const _Alloc& __a); ># 488 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string(const _CharT* __s, size_type __n, > const _Alloc& __a = _Alloc()); > > > > > > basic_string(const _CharT* __s, const _Alloc& __a = _Alloc()); > > > > > > > basic_string(size_type __n, _CharT __c, const _Alloc& __a = _Alloc()); ># 512 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string(basic_string&& __str) > > noexcept > > : _M_dataplus(__str._M_dataplus) > { > > __str._M_data(_S_empty_rep()._M_refdata()); > > > > } > > > > > > > basic_string(initializer_list<_CharT> __l, const _Alloc& __a = _Alloc()); ># 539 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<class _InputIterator> > basic_string(_InputIterator __beg, _InputIterator __end, > const _Alloc& __a = _Alloc()); > > > > > ~basic_string() noexcept > { _M_rep()->_M_dispose(this->get_allocator()); } > > > > > > basic_string& > operator=(const basic_string& __str) > { return this->assign(__str); } > > > > > > basic_string& > operator=(const _CharT* __s) > { return this->assign(__s); } ># 572 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > operator=(_CharT __c) > { > this->assign(1, __c); > return *this; > } ># 588 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > operator=(basic_string&& __str) > { > > this->swap(__str); > return *this; > } > > > > > > basic_string& > operator=(initializer_list<_CharT> __l) > { > this->assign(__l.begin(), __l.size()); > return *this; > } > > > > > > > > iterator > begin() > { > _M_leak(); > return iterator(_M_data()); > } > > > > > > const_iterator > begin() const noexcept > { return const_iterator(_M_data()); } > > > > > > iterator > end() > { > _M_leak(); > return iterator(_M_data() + this->size()); > } > > > > > > const_iterator > end() const noexcept > { return const_iterator(_M_data() + this->size()); } > > > > > > > reverse_iterator > rbegin() > { return reverse_iterator(this->end()); } > > > > > > > const_reverse_iterator > rbegin() const noexcept > { return const_reverse_iterator(this->end()); } > > > > > > > reverse_iterator > rend() > { return reverse_iterator(this->begin()); } > > > > > > > const_reverse_iterator > rend() const noexcept > { return const_reverse_iterator(this->begin()); } > > > > > > > const_iterator > cbegin() const noexcept > { return const_iterator(this->_M_data()); } > > > > > > const_iterator > cend() const noexcept > { return const_iterator(this->_M_data() + this->size()); } > > > > > > > const_reverse_iterator > crbegin() const noexcept > { return const_reverse_iterator(this->end()); } > > > > > > > const_reverse_iterator > crend() const noexcept > { return const_reverse_iterator(this->begin()); } > > > public: > > > > size_type > size() const noexcept > { return _M_rep()->_M_length; } > > > > size_type > length() const noexcept > { return _M_rep()->_M_length; } > > > size_type > max_size() const noexcept > { return _Rep::_S_max_size; } ># 748 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > void > resize(size_type __n, _CharT __c); ># 761 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > void > resize(size_type __n) > { this->resize(__n, _CharT()); } > > > > void > shrink_to_fit() noexcept > { > if (capacity() > size()) > { > try > { reserve(0); } > catch(...) > { } > } > } > > > > > > > size_type > capacity() const noexcept > { return _M_rep()->_M_capacity; } ># 805 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > void > reserve(size_type __res_arg = 0); > > > > > > void > clear() > { _M_mutate(0, this->size(), 0); } > > > > > > bool > empty() const noexcept > { return this->size() == 0; } ># 835 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > const_reference > operator[] (size_type __pos) const noexcept > { > ; > return _M_data()[__pos]; > } ># 852 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > reference > operator[](size_type __pos) > { > > > ; > > ; > _M_leak(); > return _M_data()[__pos]; > } ># 874 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > const_reference > at(size_type __n) const > { > if (__n >= this->size()) > __throw_out_of_range_fmt(("basic_string::at: __n " "(which is %zu) >= this->size() " "(which is %zu)") > > , > __n, this->size()); > return _M_data()[__n]; > } ># 896 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > reference > at(size_type __n) > { > if (__n >= size()) > __throw_out_of_range_fmt(("basic_string::at: __n " "(which is %zu) >= this->size() " "(which is %zu)") > > , > __n, this->size()); > _M_leak(); > return _M_data()[__n]; > } > > > > > > > reference > front() > { return operator[](0); } > > > > > > const_reference > front() const noexcept > { return operator[](0); } > > > > > > reference > back() > { return operator[](this->size() - 1); } > > > > > > const_reference > back() const noexcept > { return operator[](this->size() - 1); } ># 948 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > operator+=(const basic_string& __str) > { return this->append(__str); } > > > > > > > basic_string& > operator+=(const _CharT* __s) > { return this->append(__s); } > > > > > > > basic_string& > operator+=(_CharT __c) > { > this->push_back(__c); > return *this; > } > > > > > > > > basic_string& > operator+=(initializer_list<_CharT> __l) > { return this->append(__l.begin(), __l.size()); } > > > > > > > > basic_string& > append(const basic_string& __str); ># 1005 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > append(const basic_string& __str, size_type __pos, size_type __n); > > > > > > > > basic_string& > append(const _CharT* __s, size_type __n); > > > > > > > basic_string& > append(const _CharT* __s) > { > ; > return this->append(__s, traits_type::length(__s)); > } ># 1037 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > append(size_type __n, _CharT __c); > > > > > > > > basic_string& > append(initializer_list<_CharT> __l) > { return this->append(__l.begin(), __l.size()); } ># 1059 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<class _InputIterator> > basic_string& > append(_InputIterator __first, _InputIterator __last) > { return this->replace(_M_iend(), _M_iend(), __first, __last); } > > > > > > void > push_back(_CharT __c) > { > const size_type __len = 1 + this->size(); > if (__len > this->capacity() || _M_rep()->_M_is_shared()) > this->reserve(__len); > traits_type::assign(_M_data()[this->size()], __c); > _M_rep()->_M_set_length_and_sharable(__len); > } > > > > > > > basic_string& > assign(const basic_string& __str); ># 1096 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > assign(basic_string&& __str) > { > this->swap(__str); > return *this; > } ># 1117 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > assign(const basic_string& __str, size_type __pos, size_type __n) > { return this->assign(__str._M_data() > + __str._M_check(__pos, "basic_string::assign"), > __str._M_limit(__pos, __n)); } ># 1133 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > assign(const _CharT* __s, size_type __n); ># 1145 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > assign(const _CharT* __s) > { > ; > return this->assign(__s, traits_type::length(__s)); > } ># 1161 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > assign(size_type __n, _CharT __c) > { return _M_replace_aux(size_type(0), this->size(), __n, __c); } ># 1173 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<class _InputIterator> > basic_string& > assign(_InputIterator __first, _InputIterator __last) > { return this->replace(_M_ibegin(), _M_iend(), __first, __last); } > > > > > > > > basic_string& > assign(initializer_list<_CharT> __l) > { return this->assign(__l.begin(), __l.size()); } ># 1202 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > void > insert(iterator __p, size_type __n, _CharT __c) > { this->replace(__p, __p, __n, __c); } ># 1218 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<class _InputIterator> > void > insert(iterator __p, _InputIterator __beg, _InputIterator __end) > { this->replace(__p, __p, __beg, __end); } ># 1230 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > void > insert(iterator __p, initializer_list<_CharT> __l) > { > ; > this->insert(__p - _M_ibegin(), __l.begin(), __l.size()); > } ># 1250 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > insert(size_type __pos1, const basic_string& __str) > { return this->insert(__pos1, __str, size_type(0), __str.size()); } ># 1272 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > insert(size_type __pos1, const basic_string& __str, > size_type __pos2, size_type __n) > { return this->insert(__pos1, __str._M_data() > + __str._M_check(__pos2, "basic_string::insert"), > __str._M_limit(__pos2, __n)); } ># 1295 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > insert(size_type __pos, const _CharT* __s, size_type __n); ># 1313 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > insert(size_type __pos, const _CharT* __s) > { > ; > return this->insert(__pos, __s, traits_type::length(__s)); > } ># 1336 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > insert(size_type __pos, size_type __n, _CharT __c) > { return _M_replace_aux(_M_check(__pos, "basic_string::insert"), > size_type(0), __n, __c); } ># 1354 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > iterator > insert(iterator __p, _CharT __c) > { > ; > const size_type __pos = __p - _M_ibegin(); > _M_replace_aux(__pos, size_type(0), size_type(1), __c); > _M_rep()->_M_set_leaked(); > return iterator(_M_data() + __pos); > } ># 1379 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > erase(size_type __pos = 0, size_type __n = npos) > { > _M_mutate(_M_check(__pos, "basic_string::erase"), > _M_limit(__pos, __n), size_type(0)); > return *this; > } ># 1395 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > iterator > erase(iterator __position) > { > > ; > const size_type __pos = __position - _M_ibegin(); > _M_mutate(__pos, size_type(1), size_type(0)); > _M_rep()->_M_set_leaked(); > return iterator(_M_data() + __pos); > } ># 1415 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > iterator > erase(iterator __first, iterator __last); > > > > > > > > void > pop_back() > { erase(size()-1, 1); } ># 1446 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > replace(size_type __pos, size_type __n, const basic_string& __str) > { return this->replace(__pos, __n, __str._M_data(), __str.size()); } ># 1468 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > replace(size_type __pos1, size_type __n1, const basic_string& __str, > size_type __pos2, size_type __n2) > { return this->replace(__pos1, __n1, __str._M_data() > + __str._M_check(__pos2, "basic_string::replace"), > __str._M_limit(__pos2, __n2)); } ># 1493 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > replace(size_type __pos, size_type __n1, const _CharT* __s, > size_type __n2); ># 1513 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > replace(size_type __pos, size_type __n1, const _CharT* __s) > { > ; > return this->replace(__pos, __n1, __s, traits_type::length(__s)); > } ># 1537 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > replace(size_type __pos, size_type __n1, size_type __n2, _CharT __c) > { return _M_replace_aux(_M_check(__pos, "basic_string::replace"), > _M_limit(__pos, __n1), __n2, __c); } ># 1555 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > replace(iterator __i1, iterator __i2, const basic_string& __str) > { return this->replace(__i1, __i2, __str._M_data(), __str.size()); } ># 1574 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > replace(iterator __i1, iterator __i2, const _CharT* __s, size_type __n) > { > > ; > return this->replace(__i1 - _M_ibegin(), __i2 - __i1, __s, __n); > } ># 1595 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > replace(iterator __i1, iterator __i2, const _CharT* __s) > { > ; > return this->replace(__i1, __i2, __s, traits_type::length(__s)); > } ># 1616 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& > replace(iterator __i1, iterator __i2, size_type __n, _CharT __c) > { > > ; > return _M_replace_aux(__i1 - _M_ibegin(), __i2 - __i1, __n, __c); > } ># 1639 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<class _InputIterator> > basic_string& > replace(iterator __i1, iterator __i2, > _InputIterator __k1, _InputIterator __k2) > { > > ; > ; > typedef typename std::__is_integer<_InputIterator>::__type _Integral; > return _M_replace_dispatch(__i1, __i2, __k1, __k2, _Integral()); > } > > > > basic_string& > replace(iterator __i1, iterator __i2, _CharT* __k1, _CharT* __k2) > { > > ; > ; > return this->replace(__i1 - _M_ibegin(), __i2 - __i1, > __k1, __k2 - __k1); > } > > basic_string& > replace(iterator __i1, iterator __i2, > const _CharT* __k1, const _CharT* __k2) > { > > ; > ; > return this->replace(__i1 - _M_ibegin(), __i2 - __i1, > __k1, __k2 - __k1); > } > > basic_string& > replace(iterator __i1, iterator __i2, iterator __k1, iterator __k2) > { > > ; > ; > return this->replace(__i1 - _M_ibegin(), __i2 - __i1, > __k1.base(), __k2 - __k1); > } > > basic_string& > replace(iterator __i1, iterator __i2, > const_iterator __k1, const_iterator __k2) > { > > ; > ; > return this->replace(__i1 - _M_ibegin(), __i2 - __i1, > __k1.base(), __k2 - __k1); > } ># 1710 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string& replace(iterator __i1, iterator __i2, > initializer_list<_CharT> __l) > { return this->replace(__i1, __i2, __l.begin(), __l.end()); } > > > private: > template<class _Integer> > basic_string& > _M_replace_dispatch(iterator __i1, iterator __i2, _Integer __n, > _Integer __val, __true_type) > { return _M_replace_aux(__i1 - _M_ibegin(), __i2 - __i1, __n, __val); } > > template<class _InputIterator> > basic_string& > _M_replace_dispatch(iterator __i1, iterator __i2, _InputIterator __k1, > _InputIterator __k2, __false_type); > > basic_string& > _M_replace_aux(size_type __pos1, size_type __n1, size_type __n2, > _CharT __c); > > basic_string& > _M_replace_safe(size_type __pos1, size_type __n1, const _CharT* __s, > size_type __n2); > > > > template<class _InIterator> > static _CharT* > _S_construct_aux(_InIterator __beg, _InIterator __end, > const _Alloc& __a, __false_type) > { > typedef typename iterator_traits<_InIterator>::iterator_category _Tag; > return _S_construct(__beg, __end, __a, _Tag()); > } > > > > template<class _Integer> > static _CharT* > _S_construct_aux(_Integer __beg, _Integer __end, > const _Alloc& __a, __true_type) > { return _S_construct_aux_2(static_cast<size_type>(__beg), > __end, __a); } > > static _CharT* > _S_construct_aux_2(size_type __req, _CharT __c, const _Alloc& __a) > { return _S_construct(__req, __c, __a); } > > template<class _InIterator> > static _CharT* > _S_construct(_InIterator __beg, _InIterator __end, const _Alloc& __a) > { > typedef typename std::__is_integer<_InIterator>::__type _Integral; > return _S_construct_aux(__beg, __end, __a, _Integral()); > } > > > template<class _InIterator> > static _CharT* > _S_construct(_InIterator __beg, _InIterator __end, const _Alloc& __a, > input_iterator_tag); > > > > template<class _FwdIterator> > static _CharT* > _S_construct(_FwdIterator __beg, _FwdIterator __end, const _Alloc& __a, > forward_iterator_tag); > > static _CharT* > _S_construct(size_type __req, _CharT __c, const _Alloc& __a); > > public: ># 1797 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > copy(_CharT* __s, size_type __n, size_type __pos = 0) const; ># 1808 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > void > swap(basic_string& __s); ># 1818 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > const _CharT* > c_str() const noexcept > { return _M_data(); } > > > > > > > > const _CharT* > data() const noexcept > { return _M_data(); } > > > > > allocator_type > get_allocator() const noexcept > { return _M_dataplus; } ># 1851 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find(const _CharT* __s, size_type __pos, size_type __n) const; ># 1864 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find(const basic_string& __str, size_type __pos = 0) const > noexcept > { return this->find(__str.data(), __pos, __str.size()); } ># 1879 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find(const _CharT* __s, size_type __pos = 0) const > { > ; > return this->find(__s, __pos, traits_type::length(__s)); > } ># 1896 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find(_CharT __c, size_type __pos = 0) const noexcept; ># 1909 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > rfind(const basic_string& __str, size_type __pos = npos) const > noexcept > { return this->rfind(__str.data(), __pos, __str.size()); } ># 1926 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > rfind(const _CharT* __s, size_type __pos, size_type __n) const; ># 1939 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > rfind(const _CharT* __s, size_type __pos = npos) const > { > ; > return this->rfind(__s, __pos, traits_type::length(__s)); > } ># 1956 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > rfind(_CharT __c, size_type __pos = npos) const noexcept; ># 1970 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_first_of(const basic_string& __str, size_type __pos = 0) const > noexcept > { return this->find_first_of(__str.data(), __pos, __str.size()); } ># 1987 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_first_of(const _CharT* __s, size_type __pos, size_type __n) const; ># 2000 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_first_of(const _CharT* __s, size_type __pos = 0) const > { > ; > return this->find_first_of(__s, __pos, traits_type::length(__s)); > } ># 2019 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_first_of(_CharT __c, size_type __pos = 0) const noexcept > { return this->find(__c, __pos); } ># 2034 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_last_of(const basic_string& __str, size_type __pos = npos) const > noexcept > { return this->find_last_of(__str.data(), __pos, __str.size()); } ># 2051 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_last_of(const _CharT* __s, size_type __pos, size_type __n) const; ># 2064 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_last_of(const _CharT* __s, size_type __pos = npos) const > { > ; > return this->find_last_of(__s, __pos, traits_type::length(__s)); > } ># 2083 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_last_of(_CharT __c, size_type __pos = npos) const noexcept > { return this->rfind(__c, __pos); } ># 2097 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_first_not_of(const basic_string& __str, size_type __pos = 0) const > noexcept > { return this->find_first_not_of(__str.data(), __pos, __str.size()); } ># 2114 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_first_not_of(const _CharT* __s, size_type __pos, > size_type __n) const; ># 2128 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_first_not_of(const _CharT* __s, size_type __pos = 0) const > { > ; > return this->find_first_not_of(__s, __pos, traits_type::length(__s)); > } ># 2145 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_first_not_of(_CharT __c, size_type __pos = 0) const > noexcept; ># 2160 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_last_not_of(const basic_string& __str, size_type __pos = npos) const > noexcept > { return this->find_last_not_of(__str.data(), __pos, __str.size()); } ># 2177 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_last_not_of(const _CharT* __s, size_type __pos, > size_type __n) const; ># 2191 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_last_not_of(const _CharT* __s, size_type __pos = npos) const > { > ; > return this->find_last_not_of(__s, __pos, traits_type::length(__s)); > } ># 2208 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > size_type > find_last_not_of(_CharT __c, size_type __pos = npos) const > noexcept; ># 2224 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > basic_string > substr(size_type __pos = 0, size_type __n = npos) const > { return basic_string(*this, > _M_check(__pos, "basic_string::substr"), __n); } ># 2243 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > int > compare(const basic_string& __str) const > { > const size_type __size = this->size(); > const size_type __osize = __str.size(); > const size_type __len = std::min(__size, __osize); > > int __r = traits_type::compare(_M_data(), __str.data(), __len); > if (!__r) > __r = _S_compare(__size, __osize); > return __r; > } ># 2275 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > int > compare(size_type __pos, size_type __n, const basic_string& __str) const; ># 2301 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > int > compare(size_type __pos1, size_type __n1, const basic_string& __str, > size_type __pos2, size_type __n2) const; ># 2319 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > int > compare(const _CharT* __s) const; ># 2343 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > int > compare(size_type __pos, size_type __n1, const _CharT* __s) const; ># 2370 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > int > compare(size_type __pos, size_type __n1, const _CharT* __s, > size_type __n2) const; > }; ># 2382 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc> > operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { > basic_string<_CharT, _Traits, _Alloc> __str(__lhs); > __str.append(__rhs); > return __str; > } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT,_Traits,_Alloc> > operator+(const _CharT* __lhs, > const basic_string<_CharT,_Traits,_Alloc>& __rhs); > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT,_Traits,_Alloc> > operator+(_CharT __lhs, const basic_string<_CharT,_Traits,_Alloc>& __rhs); > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_string<_CharT, _Traits, _Alloc> > operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const _CharT* __rhs) > { > basic_string<_CharT, _Traits, _Alloc> __str(__lhs); > __str.append(__rhs); > return __str; > } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_string<_CharT, _Traits, _Alloc> > operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs, _CharT __rhs) > { > typedef basic_string<_CharT, _Traits, _Alloc> __string_type; > typedef typename __string_type::size_type __size_type; > __string_type __str(__lhs); > __str.append(__size_type(1), __rhs); > return __str; > } > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_string<_CharT, _Traits, _Alloc> > operator+(basic_string<_CharT, _Traits, _Alloc>&& __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return std::move(__lhs.append(__rhs)); } > > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_string<_CharT, _Traits, _Alloc> > operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > basic_string<_CharT, _Traits, _Alloc>&& __rhs) > { return std::move(__rhs.insert(0, __lhs)); } > > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_string<_CharT, _Traits, _Alloc> > operator+(basic_string<_CharT, _Traits, _Alloc>&& __lhs, > basic_string<_CharT, _Traits, _Alloc>&& __rhs) > { > const auto __size = __lhs.size() + __rhs.size(); > const bool __cond = (__size > __lhs.capacity() > && __size <= __rhs.capacity()); > return __cond ? std::move(__rhs.insert(0, __lhs)) > : std::move(__lhs.append(__rhs)); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_string<_CharT, _Traits, _Alloc> > operator+(const _CharT* __lhs, > basic_string<_CharT, _Traits, _Alloc>&& __rhs) > { return std::move(__rhs.insert(0, __lhs)); } > > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_string<_CharT, _Traits, _Alloc> > operator+(_CharT __lhs, > basic_string<_CharT, _Traits, _Alloc>&& __rhs) > { return std::move(__rhs.insert(0, 1, __lhs)); } > > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_string<_CharT, _Traits, _Alloc> > operator+(basic_string<_CharT, _Traits, _Alloc>&& __lhs, > const _CharT* __rhs) > { return std::move(__lhs.append(__rhs)); } > > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_string<_CharT, _Traits, _Alloc> > operator+(basic_string<_CharT, _Traits, _Alloc>&& __lhs, > _CharT __rhs) > { return std::move(__lhs.append(1, __rhs)); } ># 2503 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator==(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __lhs.compare(__rhs) == 0; } > > template<typename _CharT> > inline > typename __gnu_cxx::__enable_if<__is_char<_CharT>::__value, bool>::__type > operator==(const basic_string<_CharT>& __lhs, > const basic_string<_CharT>& __rhs) > { return (__lhs.size() == __rhs.size() > && !std::char_traits<_CharT>::compare(__lhs.data(), __rhs.data(), > __lhs.size())); } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator==(const _CharT* __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __rhs.compare(__lhs) == 0; } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator==(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const _CharT* __rhs) > { return __lhs.compare(__rhs) == 0; } ># 2549 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator!=(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return !(__lhs == __rhs); } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator!=(const _CharT* __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return !(__lhs == __rhs); } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator!=(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const _CharT* __rhs) > { return !(__lhs == __rhs); } ># 2586 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator<(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __lhs.compare(__rhs) < 0; } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator<(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const _CharT* __rhs) > { return __lhs.compare(__rhs) < 0; } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator<(const _CharT* __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __rhs.compare(__lhs) > 0; } ># 2623 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator>(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __lhs.compare(__rhs) > 0; } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator>(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const _CharT* __rhs) > { return __lhs.compare(__rhs) > 0; } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator>(const _CharT* __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __rhs.compare(__lhs) < 0; } ># 2660 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator<=(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __lhs.compare(__rhs) <= 0; } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator<=(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const _CharT* __rhs) > { return __lhs.compare(__rhs) <= 0; } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator<=(const _CharT* __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __rhs.compare(__lhs) >= 0; } ># 2697 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator>=(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __lhs.compare(__rhs) >= 0; } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator>=(const basic_string<_CharT, _Traits, _Alloc>& __lhs, > const _CharT* __rhs) > { return __lhs.compare(__rhs) >= 0; } > > > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > inline bool > operator>=(const _CharT* __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { return __rhs.compare(__lhs) <= 0; } ># 2734 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > inline void > swap(basic_string<_CharT, _Traits, _Alloc>& __lhs, > basic_string<_CharT, _Traits, _Alloc>& __rhs) > { __lhs.swap(__rhs); } ># 2752 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __is, > basic_string<_CharT, _Traits, _Alloc>& __str); > > template<> > basic_istream<char>& > operator>>(basic_istream<char>& __is, basic_string<char>& __str); ># 2770 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, > const basic_string<_CharT, _Traits, _Alloc>& __str) > { > > > return __ostream_insert(__os, __str.data(), __str.size()); > } ># 2793 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > basic_istream<_CharT, _Traits>& > getline(basic_istream<_CharT, _Traits>& __is, > basic_string<_CharT, _Traits, _Alloc>& __str, _CharT __delim); ># 2810 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > inline basic_istream<_CharT, _Traits>& > getline(basic_istream<_CharT, _Traits>& __is, > basic_string<_CharT, _Traits, _Alloc>& __str) > { return getline(__is, __str, __is.widen('\n')); } > > template<> > basic_istream<char>& > getline(basic_istream<char>& __in, basic_string<char>& __str, > char __delim); > > > template<> > basic_istream<wchar_t>& > getline(basic_istream<wchar_t>& __in, basic_string<wchar_t>& __str, > wchar_t __delim); > > > >} > > > > ># 1 "/usr/include/c++/4.9.0/ext/string_conversions.h" 1 3 ># 32 "/usr/include/c++/4.9.0/ext/string_conversions.h" 3 ># 33 "/usr/include/c++/4.9.0/ext/string_conversions.h" 3 ># 41 "/usr/include/c++/4.9.0/ext/string_conversions.h" 3 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 42 "/usr/include/c++/4.9.0/ext/string_conversions.h" 2 3 ># 1 "/usr/include/c++/4.9.0/cwchar" 1 3 ># 39 "/usr/include/c++/4.9.0/cwchar" 3 ># 40 "/usr/include/c++/4.9.0/cwchar" 3 > > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 45 "/usr/include/c++/4.9.0/cwchar" 2 3 ># 43 "/usr/include/c++/4.9.0/ext/string_conversions.h" 2 3 ># 1 "/usr/include/c++/4.9.0/cstdio" 1 3 ># 39 "/usr/include/c++/4.9.0/cstdio" 3 ># 40 "/usr/include/c++/4.9.0/cstdio" 3 > > ># 1 "/usr/include/stdio.h" 1 3 4 ># 29 "/usr/include/stdio.h" 3 4 >extern "C" { > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 34 "/usr/include/stdio.h" 2 3 4 ># 74 "/usr/include/stdio.h" 3 4 ># 1 "/usr/include/libio.h" 1 3 4 ># 31 "/usr/include/libio.h" 3 4 ># 1 "/usr/include/_G_config.h" 1 3 4 ># 15 "/usr/include/_G_config.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 16 "/usr/include/_G_config.h" 2 3 4 > > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 21 "/usr/include/_G_config.h" 2 3 4 >typedef struct >{ > __off_t __pos; > __mbstate_t __state; >} _G_fpos_t; >typedef struct >{ > __off64_t __pos; > __mbstate_t __state; >} _G_fpos64_t; ># 32 "/usr/include/libio.h" 2 3 4 ># 49 "/usr/include/libio.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stdarg.h" 1 3 4 ># 50 "/usr/include/libio.h" 2 3 4 ># 144 "/usr/include/libio.h" 3 4 >struct _IO_jump_t; struct _IO_FILE; ># 154 "/usr/include/libio.h" 3 4 >typedef void _IO_lock_t; > > > > > >struct _IO_marker { > struct _IO_marker *_next; > struct _IO_FILE *_sbuf; > > > > int _pos; ># 177 "/usr/include/libio.h" 3 4 >}; > > >enum __codecvt_result >{ > __codecvt_ok, > __codecvt_partial, > __codecvt_error, > __codecvt_noconv >}; ># 245 "/usr/include/libio.h" 3 4 >struct _IO_FILE { > int _flags; > > > > > char* _IO_read_ptr; > char* _IO_read_end; > char* _IO_read_base; > char* _IO_write_base; > char* _IO_write_ptr; > char* _IO_write_end; > char* _IO_buf_base; > char* _IO_buf_end; > > char *_IO_save_base; > char *_IO_backup_base; > char *_IO_save_end; > > struct _IO_marker *_markers; > > struct _IO_FILE *_chain; > > int _fileno; > > > > int _flags2; > > __off_t _old_offset; > > > > unsigned short _cur_column; > signed char _vtable_offset; > char _shortbuf[1]; > > > > _IO_lock_t *_lock; ># 293 "/usr/include/libio.h" 3 4 > __off64_t _offset; ># 302 "/usr/include/libio.h" 3 4 > void *__pad1; > void *__pad2; > void *__pad3; > void *__pad4; > size_t __pad5; > > int _mode; > > char _unused2[15 * sizeof (int) - 4 * sizeof (void *) - sizeof (size_t)]; > >}; > > > > > >struct _IO_FILE_plus; > >extern struct _IO_FILE_plus _IO_2_1_stdin_; >extern struct _IO_FILE_plus _IO_2_1_stdout_; >extern struct _IO_FILE_plus _IO_2_1_stderr_; ># 338 "/usr/include/libio.h" 3 4 >typedef __ssize_t __io_read_fn (void *__cookie, char *__buf, size_t __nbytes); > > > > > > > >typedef __ssize_t __io_write_fn (void *__cookie, const char *__buf, > size_t __n); > > > > > > > >typedef int __io_seek_fn (void *__cookie, __off64_t *__pos, int __w); > > >typedef int __io_close_fn (void *__cookie); > > > > >typedef __io_read_fn cookie_read_function_t; >typedef __io_write_fn cookie_write_function_t; >typedef __io_seek_fn cookie_seek_function_t; >typedef __io_close_fn cookie_close_function_t; > > >typedef struct >{ > __io_read_fn *read; > __io_write_fn *write; > __io_seek_fn *seek; > __io_close_fn *close; >} _IO_cookie_io_functions_t; >typedef _IO_cookie_io_functions_t cookie_io_functions_t; > >struct _IO_cookie_file; > > >extern void _IO_cookie_init (struct _IO_cookie_file *__cfile, int __read_write, > void *__cookie, _IO_cookie_io_functions_t __fns); > > > > >extern "C" { > > >extern int __underflow (_IO_FILE *); >extern int __uflow (_IO_FILE *); >extern int __overflow (_IO_FILE *, int); ># 434 "/usr/include/libio.h" 3 4 >extern int _IO_getc (_IO_FILE *__fp); >extern int _IO_putc (int __c, _IO_FILE *__fp); >extern int _IO_feof (_IO_FILE *__fp) throw (); >extern int _IO_ferror (_IO_FILE *__fp) throw (); > >extern int _IO_peekc_locked (_IO_FILE *__fp); > > > > > >extern void _IO_flockfile (_IO_FILE *) throw (); >extern void _IO_funlockfile (_IO_FILE *) throw (); >extern int _IO_ftrylockfile (_IO_FILE *) throw (); ># 464 "/usr/include/libio.h" 3 4 >extern int _IO_vfscanf (_IO_FILE * __restrict, const char * __restrict, > __gnuc_va_list, int *__restrict); >extern int _IO_vfprintf (_IO_FILE *__restrict, const char *__restrict, > __gnuc_va_list); >extern __ssize_t _IO_padn (_IO_FILE *, int, __ssize_t); >extern size_t _IO_sgetn (_IO_FILE *, void *, size_t); > >extern __off64_t _IO_seekoff (_IO_FILE *, __off64_t, int, int); >extern __off64_t _IO_seekpos (_IO_FILE *, __off64_t, int); > >extern void _IO_free_backup_area (_IO_FILE *) throw (); ># 526 "/usr/include/libio.h" 3 4 >} ># 75 "/usr/include/stdio.h" 2 3 4 > > > > >typedef __gnuc_va_list va_list; ># 108 "/usr/include/stdio.h" 3 4 > > >typedef _G_fpos_t fpos_t; > > > > > >typedef _G_fpos64_t fpos64_t; ># 164 "/usr/include/stdio.h" 3 4 ># 1 "/usr/include/bits/stdio_lim.h" 1 3 4 ># 165 "/usr/include/stdio.h" 2 3 4 > > > >extern struct _IO_FILE *stdin; >extern struct _IO_FILE *stdout; >extern struct _IO_FILE *stderr; > > > > > > > >extern int remove (const char *__filename) throw (); > >extern int rename (const char *__old, const char *__new) throw (); > > > > >extern int renameat (int __oldfd, const char *__old, int __newfd, > const char *__new) throw (); ># 195 "/usr/include/stdio.h" 3 4 >extern FILE *tmpfile (void) ; ># 205 "/usr/include/stdio.h" 3 4 >extern FILE *tmpfile64 (void) ; > > > >extern char *tmpnam (char *__s) throw () ; > > > > > >extern char *tmpnam_r (char *__s) throw () ; ># 227 "/usr/include/stdio.h" 3 4 >extern char *tempnam (const char *__dir, const char *__pfx) > throw () __attribute__ ((__malloc__)) ; ># 237 "/usr/include/stdio.h" 3 4 >extern int fclose (FILE *__stream); > > > > >extern int fflush (FILE *__stream); ># 252 "/usr/include/stdio.h" 3 4 >extern int fflush_unlocked (FILE *__stream); ># 262 "/usr/include/stdio.h" 3 4 >extern int fcloseall (void); ># 272 "/usr/include/stdio.h" 3 4 >extern FILE *fopen (const char *__restrict __filename, > const char *__restrict __modes) ; > > > > >extern FILE *freopen (const char *__restrict __filename, > const char *__restrict __modes, > FILE *__restrict __stream) ; ># 295 "/usr/include/stdio.h" 3 4 > > >extern FILE *fopen64 (const char *__restrict __filename, > const char *__restrict __modes) ; >extern FILE *freopen64 (const char *__restrict __filename, > const char *__restrict __modes, > FILE *__restrict __stream) ; > > > > >extern FILE *fdopen (int __fd, const char *__modes) throw () ; > > > > > >extern FILE *fopencookie (void *__restrict __magic_cookie, > const char *__restrict __modes, > _IO_cookie_io_functions_t __io_funcs) throw () ; > > > > >extern FILE *fmemopen (void *__s, size_t __len, const char *__modes) > throw () ; > > > > >extern FILE *open_memstream (char **__bufloc, size_t *__sizeloc) throw () ; > > > > > > >extern void setbuf (FILE *__restrict __stream, char *__restrict __buf) throw (); > > > >extern int setvbuf (FILE *__restrict __stream, char *__restrict __buf, > int __modes, size_t __n) throw (); > > > > > >extern void setbuffer (FILE *__restrict __stream, char *__restrict __buf, > size_t __size) throw (); > > >extern void setlinebuf (FILE *__stream) throw (); ># 356 "/usr/include/stdio.h" 3 4 >extern int fprintf (FILE *__restrict __stream, > const char *__restrict __format, ...); > > > > >extern int printf (const char *__restrict __format, ...); > >extern int sprintf (char *__restrict __s, > const char *__restrict __format, ...) throw (); > > > > > >extern int vfprintf (FILE *__restrict __s, const char *__restrict __format, > __gnuc_va_list __arg); > > > > >extern int vprintf (const char *__restrict __format, __gnuc_va_list __arg); > >extern int vsprintf (char *__restrict __s, const char *__restrict __format, > __gnuc_va_list __arg) throw (); > > > > > >extern int snprintf (char *__restrict __s, size_t __maxlen, > const char *__restrict __format, ...) > throw () __attribute__ ((__format__ (__printf__, 3, 4))); > >extern int vsnprintf (char *__restrict __s, size_t __maxlen, > const char *__restrict __format, __gnuc_va_list __arg) > throw () __attribute__ ((__format__ (__printf__, 3, 0))); > > > > > > >extern int vasprintf (char **__restrict __ptr, const char *__restrict __f, > __gnuc_va_list __arg) > throw () __attribute__ ((__format__ (__printf__, 2, 0))) ; >extern int __asprintf (char **__restrict __ptr, > const char *__restrict __fmt, ...) > throw () __attribute__ ((__format__ (__printf__, 2, 3))) ; >extern int asprintf (char **__restrict __ptr, > const char *__restrict __fmt, ...) > throw () __attribute__ ((__format__ (__printf__, 2, 3))) ; > > > > >extern int vdprintf (int __fd, const char *__restrict __fmt, > __gnuc_va_list __arg) > __attribute__ ((__format__ (__printf__, 2, 0))); >extern int dprintf (int __fd, const char *__restrict __fmt, ...) > __attribute__ ((__format__ (__printf__, 2, 3))); ># 425 "/usr/include/stdio.h" 3 4 >extern int fscanf (FILE *__restrict __stream, > const char *__restrict __format, ...) ; > > > > >extern int scanf (const char *__restrict __format, ...) ; > >extern int sscanf (const char *__restrict __s, > const char *__restrict __format, ...) throw (); ># 463 "/usr/include/stdio.h" 3 4 ># 471 "/usr/include/stdio.h" 3 4 >extern int vfscanf (FILE *__restrict __s, const char *__restrict __format, > __gnuc_va_list __arg) > __attribute__ ((__format__ (__scanf__, 2, 0))) ; > > > > > >extern int vscanf (const char *__restrict __format, __gnuc_va_list __arg) > __attribute__ ((__format__ (__scanf__, 1, 0))) ; > > >extern int vsscanf (const char *__restrict __s, > const char *__restrict __format, __gnuc_va_list __arg) > throw () __attribute__ ((__format__ (__scanf__, 2, 0))); ># 522 "/usr/include/stdio.h" 3 4 ># 531 "/usr/include/stdio.h" 3 4 >extern int fgetc (FILE *__stream); >extern int getc (FILE *__stream); > > > > > >extern int getchar (void); ># 550 "/usr/include/stdio.h" 3 4 >extern int getc_unlocked (FILE *__stream); >extern int getchar_unlocked (void); ># 561 "/usr/include/stdio.h" 3 4 >extern int fgetc_unlocked (FILE *__stream); ># 573 "/usr/include/stdio.h" 3 4 >extern int fputc (int __c, FILE *__stream); >extern int putc (int __c, FILE *__stream); > > > > > >extern int putchar (int __c); ># 594 "/usr/include/stdio.h" 3 4 >extern int fputc_unlocked (int __c, FILE *__stream); > > > > > > > >extern int putc_unlocked (int __c, FILE *__stream); >extern int putchar_unlocked (int __c); > > > > > > >extern int getw (FILE *__stream); > > >extern int putw (int __w, FILE *__stream); ># 622 "/usr/include/stdio.h" 3 4 >extern char *fgets (char *__restrict __s, int __n, FILE *__restrict __stream) > ; ># 638 "/usr/include/stdio.h" 3 4 >extern char *gets (char *__s) __attribute__ ((__deprecated__)); ># 649 "/usr/include/stdio.h" 3 4 >extern char *fgets_unlocked (char *__restrict __s, int __n, > FILE *__restrict __stream) ; ># 665 "/usr/include/stdio.h" 3 4 >extern __ssize_t __getdelim (char **__restrict __lineptr, > size_t *__restrict __n, int __delimiter, > FILE *__restrict __stream) ; >extern __ssize_t getdelim (char **__restrict __lineptr, > size_t *__restrict __n, int __delimiter, > FILE *__restrict __stream) ; > > > > > > > >extern __ssize_t getline (char **__restrict __lineptr, > size_t *__restrict __n, > FILE *__restrict __stream) ; ># 689 "/usr/include/stdio.h" 3 4 >extern int fputs (const char *__restrict __s, FILE *__restrict __stream); > > > > > >extern int puts (const char *__s); > > > > > > >extern int ungetc (int __c, FILE *__stream); > > > > > > >extern size_t fread (void *__restrict __ptr, size_t __size, > size_t __n, FILE *__restrict __stream) ; > > > > >extern size_t fwrite (const void *__restrict __ptr, size_t __size, > size_t __n, FILE *__restrict __s); ># 726 "/usr/include/stdio.h" 3 4 >extern int fputs_unlocked (const char *__restrict __s, > FILE *__restrict __stream); ># 737 "/usr/include/stdio.h" 3 4 >extern size_t fread_unlocked (void *__restrict __ptr, size_t __size, > size_t __n, FILE *__restrict __stream) ; >extern size_t fwrite_unlocked (const void *__restrict __ptr, size_t __size, > size_t __n, FILE *__restrict __stream); ># 749 "/usr/include/stdio.h" 3 4 >extern int fseek (FILE *__stream, long int __off, int __whence); > > > > >extern long int ftell (FILE *__stream) ; > > > > >extern void rewind (FILE *__stream); ># 773 "/usr/include/stdio.h" 3 4 >extern int fseeko (FILE *__stream, __off_t __off, int __whence); > > > > >extern __off_t ftello (FILE *__stream) ; ># 792 "/usr/include/stdio.h" 3 4 > > > > > > >extern int fgetpos (FILE *__restrict __stream, fpos_t *__restrict __pos); > > > > >extern int fsetpos (FILE *__stream, const fpos_t *__pos); ># 815 "/usr/include/stdio.h" 3 4 > > > >extern int fseeko64 (FILE *__stream, __off64_t __off, int __whence); >extern __off64_t ftello64 (FILE *__stream) ; >extern int fgetpos64 (FILE *__restrict __stream, fpos64_t *__restrict __pos); >extern int fsetpos64 (FILE *__stream, const fpos64_t *__pos); > > > > >extern void clearerr (FILE *__stream) throw (); > >extern int feof (FILE *__stream) throw () ; > >extern int ferror (FILE *__stream) throw () ; > > > > >extern void clearerr_unlocked (FILE *__stream) throw (); >extern int feof_unlocked (FILE *__stream) throw () ; >extern int ferror_unlocked (FILE *__stream) throw () ; ># 846 "/usr/include/stdio.h" 3 4 >extern void perror (const char *__s); > > > > > > ># 1 "/usr/include/bits/sys_errlist.h" 1 3 4 ># 26 "/usr/include/bits/sys_errlist.h" 3 4 >extern int sys_nerr; >extern const char *const sys_errlist[]; > > >extern int _sys_nerr; >extern const char *const _sys_errlist[]; ># 854 "/usr/include/stdio.h" 2 3 4 > > > > >extern int fileno (FILE *__stream) throw () ; > > > > >extern int fileno_unlocked (FILE *__stream) throw () ; ># 873 "/usr/include/stdio.h" 3 4 >extern FILE *popen (const char *__command, const char *__modes) ; > > > > > >extern int pclose (FILE *__stream); > > > > > >extern char *ctermid (char *__s) throw (); > > > > > >extern char *cuserid (char *__s); > > > > >struct obstack; > > >extern int obstack_printf (struct obstack *__restrict __obstack, > const char *__restrict __format, ...) > throw () __attribute__ ((__format__ (__printf__, 2, 3))); >extern int obstack_vprintf (struct obstack *__restrict __obstack, > const char *__restrict __format, > __gnuc_va_list __args) > throw () __attribute__ ((__format__ (__printf__, 2, 0))); > > > > > > > >extern void flockfile (FILE *__stream) throw (); > > > >extern int ftrylockfile (FILE *__stream) throw () ; > > >extern void funlockfile (FILE *__stream) throw (); ># 934 "/usr/include/stdio.h" 3 4 ># 1 "/usr/include/bits/stdio.h" 1 3 4 ># 35 "/usr/include/bits/stdio.h" 3 4 >extern __inline __attribute__ ((__gnu_inline__)) int >vprintf (const char *__restrict __fmt, __gnuc_va_list __arg) >{ > return vfprintf (stdout, __fmt, __arg); >} > > > >extern __inline __attribute__ ((__gnu_inline__)) int >getchar (void) >{ > return _IO_getc (stdin); >} > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >fgetc_unlocked (FILE *__fp) >{ > return (__builtin_expect (((__fp)->_IO_read_ptr >= (__fp)->_IO_read_end), 0) ? __uflow (__fp) : *(unsigned char *) (__fp)->_IO_read_ptr++); >} > > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >getc_unlocked (FILE *__fp) >{ > return (__builtin_expect (((__fp)->_IO_read_ptr >= (__fp)->_IO_read_end), 0) ? __uflow (__fp) : *(unsigned char *) (__fp)->_IO_read_ptr++); >} > > >extern __inline __attribute__ ((__gnu_inline__)) int >getchar_unlocked (void) >{ > return (__builtin_expect (((stdin)->_IO_read_ptr >= (stdin)->_IO_read_end), 0) ? __uflow (stdin) : *(unsigned char *) (stdin)->_IO_read_ptr++); >} > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >putchar (int __c) >{ > return _IO_putc (__c, stdout); >} > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >fputc_unlocked (int __c, FILE *__stream) >{ > return (__builtin_expect (((__stream)->_IO_write_ptr >= (__stream)->_IO_write_end), 0) ? __overflow (__stream, (unsigned char) (__c)) : (unsigned char) (*(__stream)->_IO_write_ptr++ = (__c))); >} > > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >putc_unlocked (int __c, FILE *__stream) >{ > return (__builtin_expect (((__stream)->_IO_write_ptr >= (__stream)->_IO_write_end), 0) ? __overflow (__stream, (unsigned char) (__c)) : (unsigned char) (*(__stream)->_IO_write_ptr++ = (__c))); >} > > >extern __inline __attribute__ ((__gnu_inline__)) int >putchar_unlocked (int __c) >{ > return (__builtin_expect (((stdout)->_IO_write_ptr >= (stdout)->_IO_write_end), 0) ? __overflow (stdout, (unsigned char) (__c)) : (unsigned char) (*(stdout)->_IO_write_ptr++ = (__c))); >} > > > > > >extern __inline __attribute__ ((__gnu_inline__)) __ssize_t >getline (char **__lineptr, size_t *__n, FILE *__stream) >{ > return __getdelim (__lineptr, __n, '\n', __stream); >} > > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) feof_unlocked (FILE *__stream) throw () >{ > return (((__stream)->_flags & 0x10) != 0); >} > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) ferror_unlocked (FILE *__stream) throw () >{ > return (((__stream)->_flags & 0x20) != 0); >} ># 935 "/usr/include/stdio.h" 2 3 4 ># 943 "/usr/include/stdio.h" 3 4 >} ># 43 "/usr/include/c++/4.9.0/cstdio" 2 3 ># 96 "/usr/include/c++/4.9.0/cstdio" 3 >namespace std >{ > using ::FILE; > using ::fpos_t; > > using ::clearerr; > using ::fclose; > using ::feof; > using ::ferror; > using ::fflush; > using ::fgetc; > using ::fgetpos; > using ::fgets; > using ::fopen; > using ::fprintf; > using ::fputc; > using ::fputs; > using ::fread; > using ::freopen; > using ::fscanf; > using ::fseek; > using ::fsetpos; > using ::ftell; > using ::fwrite; > using ::getc; > using ::getchar; > > > using ::gets; > > using ::perror; > using ::printf; > using ::putc; > using ::putchar; > using ::puts; > using ::remove; > using ::rename; > using ::rewind; > using ::scanf; > using ::setbuf; > using ::setvbuf; > using ::sprintf; > using ::sscanf; > using ::tmpfile; > > using ::tmpnam; > > using ::ungetc; > using ::vfprintf; > using ::vprintf; > using ::vsprintf; >} ># 157 "/usr/include/c++/4.9.0/cstdio" 3 >namespace __gnu_cxx >{ ># 175 "/usr/include/c++/4.9.0/cstdio" 3 > using ::snprintf; > using ::vfscanf; > using ::vscanf; > using ::vsnprintf; > using ::vsscanf; > >} > >namespace std >{ > using ::__gnu_cxx::snprintf; > using ::__gnu_cxx::vfscanf; > using ::__gnu_cxx::vscanf; > using ::__gnu_cxx::vsnprintf; > using ::__gnu_cxx::vsscanf; >} ># 44 "/usr/include/c++/4.9.0/ext/string_conversions.h" 2 3 ># 1 "/usr/include/c++/4.9.0/cerrno" 1 3 ># 39 "/usr/include/c++/4.9.0/cerrno" 3 ># 40 "/usr/include/c++/4.9.0/cerrno" 3 > ># 1 "/usr/include/errno.h" 1 3 4 ># 31 "/usr/include/errno.h" 3 4 >extern "C" { > > > ># 1 "/usr/include/bits/errno.h" 1 3 4 ># 24 "/usr/include/bits/errno.h" 3 4 ># 1 "/usr/include/linux/errno.h" 1 3 4 ># 1 "/usr/include/asm/errno.h" 1 3 4 ># 1 "/usr/include/asm-generic/errno.h" 1 3 4 > > > ># 1 "/usr/include/asm-generic/errno-base.h" 1 3 4 ># 5 "/usr/include/asm-generic/errno.h" 2 3 4 ># 1 "/usr/include/asm/errno.h" 2 3 4 ># 1 "/usr/include/linux/errno.h" 2 3 4 ># 25 "/usr/include/bits/errno.h" 2 3 4 ># 50 "/usr/include/bits/errno.h" 3 4 >extern int *__errno_location (void) throw () __attribute__ ((__const__)); ># 36 "/usr/include/errno.h" 2 3 4 ># 54 "/usr/include/errno.h" 3 4 >extern char *program_invocation_name, *program_invocation_short_name; > > > >} ># 68 "/usr/include/errno.h" 3 4 >typedef int error_t; ># 42 "/usr/include/c++/4.9.0/cerrno" 2 3 ># 45 "/usr/include/c++/4.9.0/ext/string_conversions.h" 2 3 > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > > template<typename _TRet, typename _Ret = _TRet, typename _CharT, > typename... _Base> > _Ret > __stoa(_TRet (*__convf) (const _CharT*, _CharT**, _Base...), > const char* __name, const _CharT* __str, std::size_t* __idx, > _Base... __base) > { > _Ret __ret; > > _CharT* __endptr; > (*__errno_location ()) = 0; > const _TRet __tmp = __convf(__str, &__endptr, __base...); > > if (__endptr == __str) > std::__throw_invalid_argument(__name); > else if ((*__errno_location ()) == 34 > || (std::__are_same<_Ret, int>::__value > && (__tmp < __numeric_traits<int>::__min > || __tmp > __numeric_traits<int>::__max))) > std::__throw_out_of_range(__name); > else > __ret = __tmp; > > if (__idx) > *__idx = __endptr - __str; > > return __ret; > } > > > template<typename _String, typename _CharT = typename _String::value_type> > _String > __to_xstring(int (*__convf) (_CharT*, std::size_t, const _CharT*, > __builtin_va_list), std::size_t __n, > const _CharT* __fmt, ...) > { > > > _CharT* __s = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT) > * __n)); > > __builtin_va_list __args; > __builtin_va_start(__args, __fmt); > > const int __len = __convf(__s, __n, __fmt, __args); > > __builtin_va_end(__args); > > return _String(__s, __s + __len); > } > > >} ># 2835 "/usr/include/c++/4.9.0/bits/basic_string.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > inline int > stoi(const string& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa<long, int>(&std::strtol, "stoi", __str.c_str(), > __idx, __base); } > > inline long > stol(const string& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa(&std::strtol, "stol", __str.c_str(), > __idx, __base); } > > inline unsigned long > stoul(const string& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa(&std::strtoul, "stoul", __str.c_str(), > __idx, __base); } > > inline long long > stoll(const string& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa(&std::strtoll, "stoll", __str.c_str(), > __idx, __base); } > > inline unsigned long long > stoull(const string& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa(&std::strtoull, "stoull", __str.c_str(), > __idx, __base); } > > > inline float > stof(const string& __str, size_t* __idx = 0) > { return __gnu_cxx::__stoa(&std::strtof, "stof", __str.c_str(), __idx); } > > inline double > stod(const string& __str, size_t* __idx = 0) > { return __gnu_cxx::__stoa(&std::strtod, "stod", __str.c_str(), __idx); } > > inline long double > stold(const string& __str, size_t* __idx = 0) > { return __gnu_cxx::__stoa(&std::strtold, "stold", __str.c_str(), __idx); } > > > > > inline string > to_string(int __val) > { return __gnu_cxx::__to_xstring<string>(&std::vsnprintf, 4 * sizeof(int), > "%d", __val); } > > inline string > to_string(unsigned __val) > { return __gnu_cxx::__to_xstring<string>(&std::vsnprintf, > 4 * sizeof(unsigned), > "%u", __val); } > > inline string > to_string(long __val) > { return __gnu_cxx::__to_xstring<string>(&std::vsnprintf, 4 * sizeof(long), > "%ld", __val); } > > inline string > to_string(unsigned long __val) > { return __gnu_cxx::__to_xstring<string>(&std::vsnprintf, > 4 * sizeof(unsigned long), > "%lu", __val); } > > inline string > to_string(long long __val) > { return __gnu_cxx::__to_xstring<string>(&std::vsnprintf, > 4 * sizeof(long long), > "%lld", __val); } > > inline string > to_string(unsigned long long __val) > { return __gnu_cxx::__to_xstring<string>(&std::vsnprintf, > 4 * sizeof(unsigned long long), > "%llu", __val); } > > inline string > to_string(float __val) > { > const int __n = > __gnu_cxx::__numeric_traits<float>::__max_exponent10 + 20; > return __gnu_cxx::__to_xstring<string>(&std::vsnprintf, __n, > "%f", __val); > } > > inline string > to_string(double __val) > { > const int __n = > __gnu_cxx::__numeric_traits<double>::__max_exponent10 + 20; > return __gnu_cxx::__to_xstring<string>(&std::vsnprintf, __n, > "%f", __val); > } > > inline string > to_string(long double __val) > { > const int __n = > __gnu_cxx::__numeric_traits<long double>::__max_exponent10 + 20; > return __gnu_cxx::__to_xstring<string>(&std::vsnprintf, __n, > "%Lf", __val); > } > > > inline int > stoi(const wstring& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa<long, int>(&std::wcstol, "stoi", __str.c_str(), > __idx, __base); } > > inline long > stol(const wstring& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa(&std::wcstol, "stol", __str.c_str(), > __idx, __base); } > > inline unsigned long > stoul(const wstring& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa(&std::wcstoul, "stoul", __str.c_str(), > __idx, __base); } > > inline long long > stoll(const wstring& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa(&std::wcstoll, "stoll", __str.c_str(), > __idx, __base); } > > inline unsigned long long > stoull(const wstring& __str, size_t* __idx = 0, int __base = 10) > { return __gnu_cxx::__stoa(&std::wcstoull, "stoull", __str.c_str(), > __idx, __base); } > > > inline float > stof(const wstring& __str, size_t* __idx = 0) > { return __gnu_cxx::__stoa(&std::wcstof, "stof", __str.c_str(), __idx); } > > inline double > stod(const wstring& __str, size_t* __idx = 0) > { return __gnu_cxx::__stoa(&std::wcstod, "stod", __str.c_str(), __idx); } > > inline long double > stold(const wstring& __str, size_t* __idx = 0) > { return __gnu_cxx::__stoa(&std::wcstold, "stold", __str.c_str(), __idx); } > > > inline wstring > to_wstring(int __val) > { return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, 4 * sizeof(int), > L"%d", __val); } > > inline wstring > to_wstring(unsigned __val) > { return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, > 4 * sizeof(unsigned), > L"%u", __val); } > > inline wstring > to_wstring(long __val) > { return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, 4 * sizeof(long), > L"%ld", __val); } > > inline wstring > to_wstring(unsigned long __val) > { return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, > 4 * sizeof(unsigned long), > L"%lu", __val); } > > inline wstring > to_wstring(long long __val) > { return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, > 4 * sizeof(long long), > L"%lld", __val); } > > inline wstring > to_wstring(unsigned long long __val) > { return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, > 4 * sizeof(unsigned long long), > L"%llu", __val); } > > inline wstring > to_wstring(float __val) > { > const int __n = > __gnu_cxx::__numeric_traits<float>::__max_exponent10 + 20; > return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, __n, > L"%f", __val); > } > > inline wstring > to_wstring(double __val) > { > const int __n = > __gnu_cxx::__numeric_traits<double>::__max_exponent10 + 20; > return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, __n, > L"%f", __val); > } > > inline wstring > to_wstring(long double __val) > { > const int __n = > __gnu_cxx::__numeric_traits<long double>::__max_exponent10 + 20; > return __gnu_cxx::__to_xstring<wstring>(&std::vswprintf, __n, > L"%Lf", __val); > } > > > >} > > > > > ># 1 "/usr/include/c++/4.9.0/bits/functional_hash.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/functional_hash.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/functional_hash.h" 3 > ># 1 "/usr/include/c++/4.9.0/bits/hash_bytes.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/hash_bytes.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/hash_bytes.h" 3 > > > >namespace std >{ > > > > > > > > size_t > _Hash_bytes(const void* __ptr, size_t __len, size_t __seed); > > > > > > size_t > _Fnv_hash_bytes(const void* __ptr, size_t __len, size_t __seed); > > >} ># 36 "/usr/include/c++/4.9.0/bits/functional_hash.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 49 "/usr/include/c++/4.9.0/bits/functional_hash.h" 3 > template<typename _Result, typename _Arg> > struct __hash_base > { > typedef _Result result_type; > typedef _Arg argument_type; > }; > > > template<typename _Tp> > struct hash; > > > template<typename _Tp> > struct hash<_Tp*> : public __hash_base<size_t, _Tp*> > { > size_t > operator()(_Tp* __p) const noexcept > { return reinterpret_cast<size_t>(__p); } > }; ># 80 "/usr/include/c++/4.9.0/bits/functional_hash.h" 3 > template<> struct hash<bool> : public __hash_base<size_t, bool> { size_t operator()(bool __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<char> : public __hash_base<size_t, char> { size_t operator()(char __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<signed char> : public __hash_base<size_t, signed char> { size_t operator()(signed char __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<unsigned char> : public __hash_base<size_t, unsigned char> { size_t operator()(unsigned char __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<wchar_t> : public __hash_base<size_t, wchar_t> { size_t operator()(wchar_t __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<char16_t> : public __hash_base<size_t, char16_t> { size_t operator()(char16_t __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<char32_t> : public __hash_base<size_t, char32_t> { size_t operator()(char32_t __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<short> : public __hash_base<size_t, short> { size_t operator()(short __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<int> : public __hash_base<size_t, int> { size_t operator()(int __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<long> : public __hash_base<size_t, long> { size_t operator()(long __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<long long> : public __hash_base<size_t, long long> { size_t operator()(long long __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<unsigned short> : public __hash_base<size_t, unsigned short> { size_t operator()(unsigned short __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<unsigned int> : public __hash_base<size_t, unsigned int> { size_t operator()(unsigned int __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<unsigned long> : public __hash_base<size_t, unsigned long> { size_t operator()(unsigned long __val) const noexcept { return static_cast<size_t>(__val); } }; > > > template<> struct hash<unsigned long long> : public __hash_base<size_t, unsigned long long> { size_t operator()(unsigned long long __val) const noexcept { return static_cast<size_t>(__val); } }; > > > > struct _Hash_impl > { > static size_t > hash(const void* __ptr, size_t __clength, > size_t __seed = static_cast<size_t>(0xc70f6907UL)) > { return _Hash_bytes(__ptr, __clength, __seed); } > > template<typename _Tp> > static size_t > hash(const _Tp& __val) > { return hash(&__val, sizeof(__val)); } > > template<typename _Tp> > static size_t > __hash_combine(const _Tp& __val, size_t __hash) > { return hash(&__val, sizeof(__val), __hash); } > }; > > struct _Fnv_hash_impl > { > static size_t > hash(const void* __ptr, size_t __clength, > size_t __seed = static_cast<size_t>(2166136261UL)) > { return _Fnv_hash_bytes(__ptr, __clength, __seed); } > > template<typename _Tp> > static size_t > hash(const _Tp& __val) > { return hash(&__val, sizeof(__val)); } > > template<typename _Tp> > static size_t > __hash_combine(const _Tp& __val, size_t __hash) > { return hash(&__val, sizeof(__val), __hash); } > }; > > > template<> > struct hash<float> : public __hash_base<size_t, float> > { > size_t > operator()(float __val) const noexcept > { > > return __val != 0.0f ? std::_Hash_impl::hash(__val) : 0; > } > }; > > > template<> > struct hash<double> : public __hash_base<size_t, double> > { > size_t > operator()(double __val) const noexcept > { > > return __val != 0.0 ? std::_Hash_impl::hash(__val) : 0; > } > }; > > > template<> > struct hash<long double> > : public __hash_base<size_t, long double> > { > __attribute__ ((__pure__)) size_t > operator()(long double __val) const noexcept; > }; > > > > > > > > template<typename _Hash> > struct __is_fast_hash : public std::true_type > { }; > > template<> > struct __is_fast_hash<hash<long double>> : public std::false_type > { }; > > >} ># 3053 "/usr/include/c++/4.9.0/bits/basic_string.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > template<> > struct hash<string> > : public __hash_base<size_t, string> > { > size_t > operator()(const string& __s) const noexcept > { return std::_Hash_impl::hash(__s.data(), __s.length()); } > }; > > template<> > struct __is_fast_hash<hash<string>> : std::false_type > { }; > > > > template<> > struct hash<wstring> > : public __hash_base<size_t, wstring> > { > size_t > operator()(const wstring& __s) const noexcept > { return std::_Hash_impl::hash(__s.data(), > __s.length() * sizeof(wchar_t)); } > }; > > template<> > struct __is_fast_hash<hash<wstring>> : std::false_type > { }; > > > > > > template<> > struct hash<u16string> > : public __hash_base<size_t, u16string> > { > size_t > operator()(const u16string& __s) const noexcept > { return std::_Hash_impl::hash(__s.data(), > __s.length() * sizeof(char16_t)); } > }; > > template<> > struct __is_fast_hash<hash<u16string>> : std::false_type > { }; > > > template<> > struct hash<u32string> > : public __hash_base<size_t, u32string> > { > size_t > operator()(const u32string& __s) const noexcept > { return std::_Hash_impl::hash(__s.data(), > __s.length() * sizeof(char32_t)); } > }; > > template<> > struct __is_fast_hash<hash<u32string>> : std::false_type > { }; ># 3157 "/usr/include/c++/4.9.0/bits/basic_string.h" 3 > >} ># 53 "/usr/include/c++/4.9.0/string" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/basic_string.tcc" 1 3 ># 40 "/usr/include/c++/4.9.0/bits/basic_string.tcc" 3 ># 41 "/usr/include/c++/4.9.0/bits/basic_string.tcc" 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT, typename _Traits, typename _Alloc> > const typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > _Rep::_S_max_size = (((npos - sizeof(_Rep_base))/sizeof(_CharT)) - 1) / 4; > > template<typename _CharT, typename _Traits, typename _Alloc> > const _CharT > basic_string<_CharT, _Traits, _Alloc>:: > _Rep::_S_terminal = _CharT(); > > template<typename _CharT, typename _Traits, typename _Alloc> > const typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>::npos; > > > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>::_Rep::_S_empty_rep_storage[ > (sizeof(_Rep_base) + sizeof(_CharT) + sizeof(size_type) - 1) / > sizeof(size_type)]; > > > > > > template<typename _CharT, typename _Traits, typename _Alloc> > template<typename _InIterator> > _CharT* > basic_string<_CharT, _Traits, _Alloc>:: > _S_construct(_InIterator __beg, _InIterator __end, const _Alloc& __a, > input_iterator_tag) > { > > if (__beg == __end && __a == _Alloc()) > return _S_empty_rep()._M_refdata(); > > > _CharT __buf[128]; > size_type __len = 0; > while (__beg != __end && __len < sizeof(__buf) / sizeof(_CharT)) > { > __buf[__len++] = *__beg; > ++__beg; > } > _Rep* __r = _Rep::_S_create(__len, size_type(0), __a); > _M_copy(__r->_M_refdata(), __buf, __len); > try > { > while (__beg != __end) > { > if (__len == __r->_M_capacity) > { > > _Rep* __another = _Rep::_S_create(__len + 1, __len, __a); > _M_copy(__another->_M_refdata(), __r->_M_refdata(), __len); > __r->_M_destroy(__a); > __r = __another; > } > __r->_M_refdata()[__len++] = *__beg; > ++__beg; > } > } > catch(...) > { > __r->_M_destroy(__a); > throw; > } > __r->_M_set_length_and_sharable(__len); > return __r->_M_refdata(); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > template <typename _InIterator> > _CharT* > basic_string<_CharT, _Traits, _Alloc>:: > _S_construct(_InIterator __beg, _InIterator __end, const _Alloc& __a, > forward_iterator_tag) > { > > if (__beg == __end && __a == _Alloc()) > return _S_empty_rep()._M_refdata(); > > > if (__gnu_cxx::__is_null_pointer(__beg) && __beg != __end) > __throw_logic_error(("basic_string::_S_construct null not valid")); > > const size_type __dnew = static_cast<size_type>(std::distance(__beg, > __end)); > > _Rep* __r = _Rep::_S_create(__dnew, size_type(0), __a); > try > { _S_copy_chars(__r->_M_refdata(), __beg, __end); } > catch(...) > { > __r->_M_destroy(__a); > throw; > } > __r->_M_set_length_and_sharable(__dnew); > return __r->_M_refdata(); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > _CharT* > basic_string<_CharT, _Traits, _Alloc>:: > _S_construct(size_type __n, _CharT __c, const _Alloc& __a) > { > > if (__n == 0 && __a == _Alloc()) > return _S_empty_rep()._M_refdata(); > > > _Rep* __r = _Rep::_S_create(__n, size_type(0), __a); > if (__n) > _M_assign(__r->_M_refdata(), __n, __c); > > __r->_M_set_length_and_sharable(__n); > return __r->_M_refdata(); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>:: > basic_string(const basic_string& __str) > : _M_dataplus(__str._M_rep()->_M_grab(_Alloc(__str.get_allocator()), > __str.get_allocator()), > __str.get_allocator()) > { } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>:: > basic_string(const _Alloc& __a) > : _M_dataplus(_S_construct(size_type(), _CharT(), __a), __a) > { } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>:: > basic_string(const basic_string& __str, size_type __pos, size_type __n) > : _M_dataplus(_S_construct(__str._M_data() > + __str._M_check(__pos, > "basic_string::basic_string"), > __str._M_data() + __str._M_limit(__pos, __n) > + __pos, _Alloc()), _Alloc()) > { } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>:: > basic_string(const basic_string& __str, size_type __pos, > size_type __n, const _Alloc& __a) > : _M_dataplus(_S_construct(__str._M_data() > + __str._M_check(__pos, > "basic_string::basic_string"), > __str._M_data() + __str._M_limit(__pos, __n) > + __pos, __a), __a) > { } > > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>:: > basic_string(const _CharT* __s, size_type __n, const _Alloc& __a) > : _M_dataplus(_S_construct(__s, __s + __n, __a), __a) > { } > > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>:: > basic_string(const _CharT* __s, const _Alloc& __a) > : _M_dataplus(_S_construct(__s, __s ? __s + traits_type::length(__s) : > __s + npos, __a), __a) > { } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>:: > basic_string(size_type __n, _CharT __c, const _Alloc& __a) > : _M_dataplus(_S_construct(__n, __c, __a), __a) > { } > > > template<typename _CharT, typename _Traits, typename _Alloc> > template<typename _InputIterator> > basic_string<_CharT, _Traits, _Alloc>:: > basic_string(_InputIterator __beg, _InputIterator __end, const _Alloc& __a) > : _M_dataplus(_S_construct(__beg, __end, __a), __a) > { } > > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>:: > basic_string(initializer_list<_CharT> __l, const _Alloc& __a) > : _M_dataplus(_S_construct(__l.begin(), __l.end(), __a), __a) > { } > > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > assign(const basic_string& __str) > { > if (_M_rep() != __str._M_rep()) > { > > const allocator_type __a = this->get_allocator(); > _CharT* __tmp = __str._M_rep()->_M_grab(__a, __str.get_allocator()); > _M_rep()->_M_dispose(__a); > _M_data(__tmp); > } > return *this; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > assign(const _CharT* __s, size_type __n) > { > ; > _M_check_length(this->size(), __n, "basic_string::assign"); > if (_M_disjunct(__s) || _M_rep()->_M_is_shared()) > return _M_replace_safe(size_type(0), this->size(), __s, __n); > else > { > > const size_type __pos = __s - _M_data(); > if (__pos >= __n) > _M_copy(_M_data(), __s, __n); > else if (__pos) > _M_move(_M_data(), __s, __n); > _M_rep()->_M_set_length_and_sharable(__n); > return *this; > } > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > append(size_type __n, _CharT __c) > { > if (__n) > { > _M_check_length(size_type(0), __n, "basic_string::append"); > const size_type __len = __n + this->size(); > if (__len > this->capacity() || _M_rep()->_M_is_shared()) > this->reserve(__len); > _M_assign(_M_data() + this->size(), __n, __c); > _M_rep()->_M_set_length_and_sharable(__len); > } > return *this; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > append(const _CharT* __s, size_type __n) > { > ; > if (__n) > { > _M_check_length(size_type(0), __n, "basic_string::append"); > const size_type __len = __n + this->size(); > if (__len > this->capacity() || _M_rep()->_M_is_shared()) > { > if (_M_disjunct(__s)) > this->reserve(__len); > else > { > const size_type __off = __s - _M_data(); > this->reserve(__len); > __s = _M_data() + __off; > } > } > _M_copy(_M_data() + this->size(), __s, __n); > _M_rep()->_M_set_length_and_sharable(__len); > } > return *this; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > append(const basic_string& __str) > { > const size_type __size = __str.size(); > if (__size) > { > const size_type __len = __size + this->size(); > if (__len > this->capacity() || _M_rep()->_M_is_shared()) > this->reserve(__len); > _M_copy(_M_data() + this->size(), __str._M_data(), __size); > _M_rep()->_M_set_length_and_sharable(__len); > } > return *this; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > append(const basic_string& __str, size_type __pos, size_type __n) > { > __str._M_check(__pos, "basic_string::append"); > __n = __str._M_limit(__pos, __n); > if (__n) > { > const size_type __len = __n + this->size(); > if (__len > this->capacity() || _M_rep()->_M_is_shared()) > this->reserve(__len); > _M_copy(_M_data() + this->size(), __str._M_data() + __pos, __n); > _M_rep()->_M_set_length_and_sharable(__len); > } > return *this; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > insert(size_type __pos, const _CharT* __s, size_type __n) > { > ; > _M_check(__pos, "basic_string::insert"); > _M_check_length(size_type(0), __n, "basic_string::insert"); > if (_M_disjunct(__s) || _M_rep()->_M_is_shared()) > return _M_replace_safe(__pos, size_type(0), __s, __n); > else > { > > const size_type __off = __s - _M_data(); > _M_mutate(__pos, 0, __n); > __s = _M_data() + __off; > _CharT* __p = _M_data() + __pos; > if (__s + __n <= __p) > _M_copy(__p, __s, __n); > else if (__s >= __p) > _M_copy(__p, __s + __n, __n); > else > { > const size_type __nleft = __p - __s; > _M_copy(__p, __s, __nleft); > _M_copy(__p + __nleft, __p + __n, __n - __nleft); > } > return *this; > } > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::iterator > basic_string<_CharT, _Traits, _Alloc>:: > erase(iterator __first, iterator __last) > { > > ; > > > > > const size_type __size = __last - __first; > if (__size) > { > const size_type __pos = __first - _M_ibegin(); > _M_mutate(__pos, __size, size_type(0)); > _M_rep()->_M_set_leaked(); > return iterator(_M_data() + __pos); > } > else > return __first; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > replace(size_type __pos, size_type __n1, const _CharT* __s, > size_type __n2) > { > ; > _M_check(__pos, "basic_string::replace"); > __n1 = _M_limit(__pos, __n1); > _M_check_length(__n1, __n2, "basic_string::replace"); > bool __left; > if (_M_disjunct(__s) || _M_rep()->_M_is_shared()) > return _M_replace_safe(__pos, __n1, __s, __n2); > else if ((__left = __s + __n2 <= _M_data() + __pos) > || _M_data() + __pos + __n1 <= __s) > { > > size_type __off = __s - _M_data(); > __left ? __off : (__off += __n2 - __n1); > _M_mutate(__pos, __n1, __n2); > _M_copy(_M_data() + __pos, _M_data() + __off, __n2); > return *this; > } > else > { > > const basic_string __tmp(__s, __n2); > return _M_replace_safe(__pos, __n1, __tmp._M_data(), __n2); > } > } > > template<typename _CharT, typename _Traits, typename _Alloc> > void > basic_string<_CharT, _Traits, _Alloc>::_Rep:: > _M_destroy(const _Alloc& __a) throw () > { > const size_type __size = sizeof(_Rep_base) + > (this->_M_capacity + 1) * sizeof(_CharT); > _Raw_bytes_alloc(__a).deallocate(reinterpret_cast<char*>(this), __size); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > void > basic_string<_CharT, _Traits, _Alloc>:: > _M_leak_hard() > { > > if (_M_rep() == &_S_empty_rep()) > return; > > if (_M_rep()->_M_is_shared()) > _M_mutate(0, 0, 0); > _M_rep()->_M_set_leaked(); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > void > basic_string<_CharT, _Traits, _Alloc>:: > _M_mutate(size_type __pos, size_type __len1, size_type __len2) > { > const size_type __old_size = this->size(); > const size_type __new_size = __old_size + __len2 - __len1; > const size_type __how_much = __old_size - __pos - __len1; > > if (__new_size > this->capacity() || _M_rep()->_M_is_shared()) > { > > const allocator_type __a = get_allocator(); > _Rep* __r = _Rep::_S_create(__new_size, this->capacity(), __a); > > if (__pos) > _M_copy(__r->_M_refdata(), _M_data(), __pos); > if (__how_much) > _M_copy(__r->_M_refdata() + __pos + __len2, > _M_data() + __pos + __len1, __how_much); > > _M_rep()->_M_dispose(__a); > _M_data(__r->_M_refdata()); > } > else if (__how_much && __len1 != __len2) > { > > _M_move(_M_data() + __pos + __len2, > _M_data() + __pos + __len1, __how_much); > } > _M_rep()->_M_set_length_and_sharable(__new_size); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > void > basic_string<_CharT, _Traits, _Alloc>:: > reserve(size_type __res) > { > if (__res != this->capacity() || _M_rep()->_M_is_shared()) > { > > if (__res < this->size()) > __res = this->size(); > const allocator_type __a = get_allocator(); > _CharT* __tmp = _M_rep()->_M_clone(__a, __res - this->size()); > _M_rep()->_M_dispose(__a); > _M_data(__tmp); > } > } > > template<typename _CharT, typename _Traits, typename _Alloc> > void > basic_string<_CharT, _Traits, _Alloc>:: > swap(basic_string& __s) > { > if (_M_rep()->_M_is_leaked()) > _M_rep()->_M_set_sharable(); > if (__s._M_rep()->_M_is_leaked()) > __s._M_rep()->_M_set_sharable(); > if (this->get_allocator() == __s.get_allocator()) > { > _CharT* __tmp = _M_data(); > _M_data(__s._M_data()); > __s._M_data(__tmp); > } > > else > { > const basic_string __tmp1(_M_ibegin(), _M_iend(), > __s.get_allocator()); > const basic_string __tmp2(__s._M_ibegin(), __s._M_iend(), > this->get_allocator()); > *this = __tmp2; > __s = __tmp1; > } > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::_Rep* > basic_string<_CharT, _Traits, _Alloc>::_Rep:: > _S_create(size_type __capacity, size_type __old_capacity, > const _Alloc& __alloc) > { > > > if (__capacity > _S_max_size) > __throw_length_error(("basic_string::_S_create")); ># 577 "/usr/include/c++/4.9.0/bits/basic_string.tcc" 3 > const size_type __pagesize = 4096; > const size_type __malloc_header_size = 4 * sizeof(void*); > > > > > > > > if (__capacity > __old_capacity && __capacity < 2 * __old_capacity) > __capacity = 2 * __old_capacity; > > > > > size_type __size = (__capacity + 1) * sizeof(_CharT) + sizeof(_Rep); > > const size_type __adj_size = __size + __malloc_header_size; > if (__adj_size > __pagesize && __capacity > __old_capacity) > { > const size_type __extra = __pagesize - __adj_size % __pagesize; > __capacity += __extra / sizeof(_CharT); > > if (__capacity > _S_max_size) > __capacity = _S_max_size; > __size = (__capacity + 1) * sizeof(_CharT) + sizeof(_Rep); > } > > > > void* __place = _Raw_bytes_alloc(__alloc).allocate(__size); > _Rep *__p = new (__place) _Rep; > __p->_M_capacity = __capacity; > > > > > > > > __p->_M_set_sharable(); > return __p; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > _CharT* > basic_string<_CharT, _Traits, _Alloc>::_Rep:: > _M_clone(const _Alloc& __alloc, size_type __res) > { > > const size_type __requested_cap = this->_M_length + __res; > _Rep* __r = _Rep::_S_create(__requested_cap, this->_M_capacity, > __alloc); > if (this->_M_length) > _M_copy(__r->_M_refdata(), _M_refdata(), this->_M_length); > > __r->_M_set_length_and_sharable(this->_M_length); > return __r->_M_refdata(); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > void > basic_string<_CharT, _Traits, _Alloc>:: > resize(size_type __n, _CharT __c) > { > const size_type __size = this->size(); > _M_check_length(__size, __n, "basic_string::resize"); > if (__size < __n) > this->append(__n - __size, __c); > else if (__n < __size) > this->erase(__n); > > } > > template<typename _CharT, typename _Traits, typename _Alloc> > template<typename _InputIterator> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > _M_replace_dispatch(iterator __i1, iterator __i2, _InputIterator __k1, > _InputIterator __k2, __false_type) > { > const basic_string __s(__k1, __k2); > const size_type __n1 = __i2 - __i1; > _M_check_length(__n1, __s.size(), "basic_string::_M_replace_dispatch"); > return _M_replace_safe(__i1 - _M_ibegin(), __n1, __s._M_data(), > __s.size()); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > _M_replace_aux(size_type __pos1, size_type __n1, size_type __n2, > _CharT __c) > { > _M_check_length(__n1, __n2, "basic_string::_M_replace_aux"); > _M_mutate(__pos1, __n1, __n2); > if (__n2) > _M_assign(_M_data() + __pos1, __n2, __c); > return *this; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc>& > basic_string<_CharT, _Traits, _Alloc>:: > _M_replace_safe(size_type __pos1, size_type __n1, const _CharT* __s, > size_type __n2) > { > _M_mutate(__pos1, __n1, __n2); > if (__n2) > _M_copy(_M_data() + __pos1, __s, __n2); > return *this; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc> > operator+(const _CharT* __lhs, > const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { > ; > typedef basic_string<_CharT, _Traits, _Alloc> __string_type; > typedef typename __string_type::size_type __size_type; > const __size_type __len = _Traits::length(__lhs); > __string_type __str; > __str.reserve(__len + __rhs.size()); > __str.append(__lhs, __len); > __str.append(__rhs); > return __str; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_string<_CharT, _Traits, _Alloc> > operator+(_CharT __lhs, const basic_string<_CharT, _Traits, _Alloc>& __rhs) > { > typedef basic_string<_CharT, _Traits, _Alloc> __string_type; > typedef typename __string_type::size_type __size_type; > __string_type __str; > const __size_type __len = __rhs.size(); > __str.reserve(__len + 1); > __str.append(__size_type(1), __lhs); > __str.append(__rhs); > return __str; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > copy(_CharT* __s, size_type __n, size_type __pos) const > { > _M_check(__pos, "basic_string::copy"); > __n = _M_limit(__pos, __n); > ; > if (__n) > _M_copy(__s, _M_data() + __pos, __n); > > return __n; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > find(const _CharT* __s, size_type __pos, size_type __n) const > { > ; > const size_type __size = this->size(); > const _CharT* __data = _M_data(); > > if (__n == 0) > return __pos <= __size ? __pos : npos; > > if (__n <= __size) > { > for (; __pos <= __size - __n; ++__pos) > if (traits_type::eq(__data[__pos], __s[0]) > && traits_type::compare(__data + __pos + 1, > __s + 1, __n - 1) == 0) > return __pos; > } > return npos; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > find(_CharT __c, size_type __pos) const noexcept > { > size_type __ret = npos; > const size_type __size = this->size(); > if (__pos < __size) > { > const _CharT* __data = _M_data(); > const size_type __n = __size - __pos; > const _CharT* __p = traits_type::find(__data + __pos, __n, __c); > if (__p) > __ret = __p - __data; > } > return __ret; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > rfind(const _CharT* __s, size_type __pos, size_type __n) const > { > ; > const size_type __size = this->size(); > if (__n <= __size) > { > __pos = std::min(size_type(__size - __n), __pos); > const _CharT* __data = _M_data(); > do > { > if (traits_type::compare(__data + __pos, __s, __n) == 0) > return __pos; > } > while (__pos-- > 0); > } > return npos; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > rfind(_CharT __c, size_type __pos) const noexcept > { > size_type __size = this->size(); > if (__size) > { > if (--__size > __pos) > __size = __pos; > for (++__size; __size-- > 0; ) > if (traits_type::eq(_M_data()[__size], __c)) > return __size; > } > return npos; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > find_first_of(const _CharT* __s, size_type __pos, size_type __n) const > { > ; > for (; __n && __pos < this->size(); ++__pos) > { > const _CharT* __p = traits_type::find(__s, __n, _M_data()[__pos]); > if (__p) > return __pos; > } > return npos; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > find_last_of(const _CharT* __s, size_type __pos, size_type __n) const > { > ; > size_type __size = this->size(); > if (__size && __n) > { > if (--__size > __pos) > __size = __pos; > do > { > if (traits_type::find(__s, __n, _M_data()[__size])) > return __size; > } > while (__size-- != 0); > } > return npos; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > find_first_not_of(const _CharT* __s, size_type __pos, size_type __n) const > { > ; > for (; __pos < this->size(); ++__pos) > if (!traits_type::find(__s, __n, _M_data()[__pos])) > return __pos; > return npos; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > find_first_not_of(_CharT __c, size_type __pos) const noexcept > { > for (; __pos < this->size(); ++__pos) > if (!traits_type::eq(_M_data()[__pos], __c)) > return __pos; > return npos; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > find_last_not_of(const _CharT* __s, size_type __pos, size_type __n) const > { > ; > size_type __size = this->size(); > if (__size) > { > if (--__size > __pos) > __size = __pos; > do > { > if (!traits_type::find(__s, __n, _M_data()[__size])) > return __size; > } > while (__size--); > } > return npos; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > typename basic_string<_CharT, _Traits, _Alloc>::size_type > basic_string<_CharT, _Traits, _Alloc>:: > find_last_not_of(_CharT __c, size_type __pos) const noexcept > { > size_type __size = this->size(); > if (__size) > { > if (--__size > __pos) > __size = __pos; > do > { > if (!traits_type::eq(_M_data()[__size], __c)) > return __size; > } > while (__size--); > } > return npos; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > int > basic_string<_CharT, _Traits, _Alloc>:: > compare(size_type __pos, size_type __n, const basic_string& __str) const > { > _M_check(__pos, "basic_string::compare"); > __n = _M_limit(__pos, __n); > const size_type __osize = __str.size(); > const size_type __len = std::min(__n, __osize); > int __r = traits_type::compare(_M_data() + __pos, __str.data(), __len); > if (!__r) > __r = _S_compare(__n, __osize); > return __r; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > int > basic_string<_CharT, _Traits, _Alloc>:: > compare(size_type __pos1, size_type __n1, const basic_string& __str, > size_type __pos2, size_type __n2) const > { > _M_check(__pos1, "basic_string::compare"); > __str._M_check(__pos2, "basic_string::compare"); > __n1 = _M_limit(__pos1, __n1); > __n2 = __str._M_limit(__pos2, __n2); > const size_type __len = std::min(__n1, __n2); > int __r = traits_type::compare(_M_data() + __pos1, > __str.data() + __pos2, __len); > if (!__r) > __r = _S_compare(__n1, __n2); > return __r; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > int > basic_string<_CharT, _Traits, _Alloc>:: > compare(const _CharT* __s) const > { > ; > const size_type __size = this->size(); > const size_type __osize = traits_type::length(__s); > const size_type __len = std::min(__size, __osize); > int __r = traits_type::compare(_M_data(), __s, __len); > if (!__r) > __r = _S_compare(__size, __osize); > return __r; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > int > basic_string <_CharT, _Traits, _Alloc>:: > compare(size_type __pos, size_type __n1, const _CharT* __s) const > { > ; > _M_check(__pos, "basic_string::compare"); > __n1 = _M_limit(__pos, __n1); > const size_type __osize = traits_type::length(__s); > const size_type __len = std::min(__n1, __osize); > int __r = traits_type::compare(_M_data() + __pos, __s, __len); > if (!__r) > __r = _S_compare(__n1, __osize); > return __r; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > int > basic_string <_CharT, _Traits, _Alloc>:: > compare(size_type __pos, size_type __n1, const _CharT* __s, > size_type __n2) const > { > ; > _M_check(__pos, "basic_string::compare"); > __n1 = _M_limit(__pos, __n1); > const size_type __len = std::min(__n1, __n2); > int __r = traits_type::compare(_M_data() + __pos, __s, __len); > if (!__r) > __r = _S_compare(__n1, __n2); > return __r; > } > > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __in, > basic_string<_CharT, _Traits, _Alloc>& __str) > { > typedef basic_istream<_CharT, _Traits> __istream_type; > typedef basic_string<_CharT, _Traits, _Alloc> __string_type; > typedef typename __istream_type::ios_base __ios_base; > typedef typename __istream_type::int_type __int_type; > typedef typename __string_type::size_type __size_type; > typedef ctype<_CharT> __ctype_type; > typedef typename __ctype_type::ctype_base __ctype_base; > > __size_type __extracted = 0; > typename __ios_base::iostate __err = __ios_base::goodbit; > typename __istream_type::sentry __cerb(__in, false); > if (__cerb) > { > try > { > > __str.erase(); > _CharT __buf[128]; > __size_type __len = 0; > const streamsize __w = __in.width(); > const __size_type __n = __w > 0 ? static_cast<__size_type>(__w) > : __str.max_size(); > const __ctype_type& __ct = use_facet<__ctype_type>(__in.getloc()); > const __int_type __eof = _Traits::eof(); > __int_type __c = __in.rdbuf()->sgetc(); > > while (__extracted < __n > && !_Traits::eq_int_type(__c, __eof) > && !__ct.is(__ctype_base::space, > _Traits::to_char_type(__c))) > { > if (__len == sizeof(__buf) / sizeof(_CharT)) > { > __str.append(__buf, sizeof(__buf) / sizeof(_CharT)); > __len = 0; > } > __buf[__len++] = _Traits::to_char_type(__c); > ++__extracted; > __c = __in.rdbuf()->snextc(); > } > __str.append(__buf, __len); > > if (_Traits::eq_int_type(__c, __eof)) > __err |= __ios_base::eofbit; > __in.width(0); > } > catch(__cxxabiv1::__forced_unwind&) > { > __in._M_setstate(__ios_base::badbit); > throw; > } > catch(...) > { > > > > __in._M_setstate(__ios_base::badbit); > } > } > > if (!__extracted) > __err |= __ios_base::failbit; > if (__err) > __in.setstate(__err); > return __in; > } > > template<typename _CharT, typename _Traits, typename _Alloc> > basic_istream<_CharT, _Traits>& > getline(basic_istream<_CharT, _Traits>& __in, > basic_string<_CharT, _Traits, _Alloc>& __str, _CharT __delim) > { > typedef basic_istream<_CharT, _Traits> __istream_type; > typedef basic_string<_CharT, _Traits, _Alloc> __string_type; > typedef typename __istream_type::ios_base __ios_base; > typedef typename __istream_type::int_type __int_type; > typedef typename __string_type::size_type __size_type; > > __size_type __extracted = 0; > const __size_type __n = __str.max_size(); > typename __ios_base::iostate __err = __ios_base::goodbit; > typename __istream_type::sentry __cerb(__in, true); > if (__cerb) > { > try > { > __str.erase(); > const __int_type __idelim = _Traits::to_int_type(__delim); > const __int_type __eof = _Traits::eof(); > __int_type __c = __in.rdbuf()->sgetc(); > > while (__extracted < __n > && !_Traits::eq_int_type(__c, __eof) > && !_Traits::eq_int_type(__c, __idelim)) > { > __str += _Traits::to_char_type(__c); > ++__extracted; > __c = __in.rdbuf()->snextc(); > } > > if (_Traits::eq_int_type(__c, __eof)) > __err |= __ios_base::eofbit; > else if (_Traits::eq_int_type(__c, __idelim)) > { > ++__extracted; > __in.rdbuf()->sbumpc(); > } > else > __err |= __ios_base::failbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > __in._M_setstate(__ios_base::badbit); > throw; > } > catch(...) > { > > > > __in._M_setstate(__ios_base::badbit); > } > } > if (!__extracted) > __err |= __ios_base::failbit; > if (__err) > __in.setstate(__err); > return __in; > } > > > > > extern template class basic_string<char>; > extern template > basic_istream<char>& > operator>>(basic_istream<char>&, string&); > extern template > basic_ostream<char>& > operator<<(basic_ostream<char>&, const string&); > extern template > basic_istream<char>& > getline(basic_istream<char>&, string&, char); > extern template > basic_istream<char>& > getline(basic_istream<char>&, string&); > > > extern template class basic_string<wchar_t>; > extern template > basic_istream<wchar_t>& > operator>>(basic_istream<wchar_t>&, wstring&); > extern template > basic_ostream<wchar_t>& > operator<<(basic_ostream<wchar_t>&, const wstring&); > extern template > basic_istream<wchar_t>& > getline(basic_istream<wchar_t>&, wstring&, wchar_t); > extern template > basic_istream<wchar_t>& > getline(basic_istream<wchar_t>&, wstring&); > > > > >} ># 54 "/usr/include/c++/4.9.0/string" 2 3 ># 41 "/usr/include/c++/4.9.0/bits/locale_classes.h" 2 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 62 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > class locale > { > public: > > > typedef int category; > > > class facet; > class id; > class _Impl; > > friend class facet; > friend class _Impl; > > template<typename _Facet> > friend bool > has_facet(const locale&) throw(); > > template<typename _Facet> > friend const _Facet& > use_facet(const locale&); > > template<typename _Cache> > friend struct __use_cache; ># 98 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > static const category none = 0; > static const category ctype = 1L << 0; > static const category numeric = 1L << 1; > static const category collate = 1L << 2; > static const category time = 1L << 3; > static const category monetary = 1L << 4; > static const category messages = 1L << 5; > static const category all = (ctype | numeric | collate | > time | monetary | messages); ># 117 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > locale() throw(); ># 126 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > locale(const locale& __other) throw(); ># 136 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > explicit > locale(const char* __s); ># 151 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > locale(const locale& __base, const char* __s, category __cat); ># 164 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > locale(const locale& __base, const locale& __add, category __cat); ># 177 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > template<typename _Facet> > locale(const locale& __other, _Facet* __f); > > > ~locale() throw(); ># 191 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > const locale& > operator=(const locale& __other) throw(); ># 206 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > template<typename _Facet> > locale > combine(const locale& __other) const; > > > > > > > string > name() const; ># 225 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > bool > operator==(const locale& __other) const throw(); > > > > > > > > bool > operator!=(const locale& __other) const throw() > { return !(this->operator==(__other)); } ># 253 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > template<typename _Char, typename _Traits, typename _Alloc> > bool > operator()(const basic_string<_Char, _Traits, _Alloc>& __s1, > const basic_string<_Char, _Traits, _Alloc>& __s2) const; ># 269 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > static locale > global(const locale& __loc); > > > > > static const locale& > classic(); > > private: > > _Impl* _M_impl; > > > static _Impl* _S_classic; > > > static _Impl* _S_global; > > > > > > static const char* const* const _S_categories; ># 304 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > enum { _S_categories_size = 6 + 6 }; > > > static __gthread_once_t _S_once; > > > explicit > locale(_Impl*) throw(); > > static void > _S_initialize(); > > static void > _S_initialize_once() throw(); > > static category > _S_normalize_category(category); > > void > _M_coalesce(const locale& __base, const locale& __add, category __cat); > }; ># 338 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > class locale::facet > { > private: > friend class locale; > friend class locale::_Impl; > > mutable _Atomic_word _M_refcount; > > > static __c_locale _S_c_locale; > > > static const char _S_c_name[2]; > > > static __gthread_once_t _S_once; > > > static void > _S_initialize_once(); > > protected: ># 369 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > explicit > facet(size_t __refs = 0) throw() : _M_refcount(__refs ? 1 : 0) > { } > > > virtual > ~facet(); > > static void > _S_create_c_locale(__c_locale& __cloc, const char* __s, > __c_locale __old = 0); > > static __c_locale > _S_clone_c_locale(__c_locale& __cloc) throw(); > > static void > _S_destroy_c_locale(__c_locale& __cloc); > > static __c_locale > _S_lc_ctype_c_locale(__c_locale __cloc, const char* __s); > > > > static __c_locale > _S_get_c_locale(); > > __attribute__ ((__const__)) static const char* > _S_get_c_name() throw(); > > private: > void > _M_add_reference() const throw() > { __gnu_cxx::__atomic_add_dispatch(&_M_refcount, 1); } > > void > _M_remove_reference() const throw() > { > > ; > if (__gnu_cxx::__exchange_and_add_dispatch(&_M_refcount, -1) == 1) > { > ; > try > { delete this; } > catch(...) > { } > } > } > > facet(const facet&); > > facet& > operator=(const facet&); > }; ># 436 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > class locale::id > { > private: > friend class locale; > friend class locale::_Impl; > > template<typename _Facet> > friend const _Facet& > use_facet(const locale&); > > template<typename _Facet> > friend bool > has_facet(const locale&) throw(); > > > > > mutable size_t _M_index; > > > static _Atomic_word _S_refcount; > > void > operator=(const id&); > > id(const id&); > > public: > > > > id() { } > > size_t > _M_id() const throw(); > }; > > > > class locale::_Impl > { > public: > > friend class locale; > friend class locale::facet; > > template<typename _Facet> > friend bool > has_facet(const locale&) throw(); > > template<typename _Facet> > friend const _Facet& > use_facet(const locale&); > > template<typename _Cache> > friend struct __use_cache; > > private: > > _Atomic_word _M_refcount; > const facet** _M_facets; > size_t _M_facets_size; > const facet** _M_caches; > char** _M_names; > static const locale::id* const _S_id_ctype[]; > static const locale::id* const _S_id_numeric[]; > static const locale::id* const _S_id_collate[]; > static const locale::id* const _S_id_time[]; > static const locale::id* const _S_id_monetary[]; > static const locale::id* const _S_id_messages[]; > static const locale::id* const* const _S_facet_categories[]; > > void > _M_add_reference() throw() > { __gnu_cxx::__atomic_add_dispatch(&_M_refcount, 1); } > > void > _M_remove_reference() throw() > { > > ; > if (__gnu_cxx::__exchange_and_add_dispatch(&_M_refcount, -1) == 1) > { > ; > try > { delete this; } > catch(...) > { } > } > } > > _Impl(const _Impl&, size_t); > _Impl(const char*, size_t); > _Impl(size_t) throw(); > > ~_Impl() throw(); > > _Impl(const _Impl&); > > void > operator=(const _Impl&); > > bool > _M_check_same_name() > { > bool __ret = true; > if (_M_names[1]) > > for (size_t __i = 0; __ret && __i < _S_categories_size - 1; ++__i) > __ret = __builtin_strcmp(_M_names[__i], _M_names[__i + 1]) == 0; > return __ret; > } > > void > _M_replace_categories(const _Impl*, category); > > void > _M_replace_category(const _Impl*, const locale::id* const*); > > void > _M_replace_facet(const _Impl*, const locale::id*); > > void > _M_install_facet(const locale::id*, const facet*); > > template<typename _Facet> > void > _M_init_facet(_Facet* __facet) > { _M_install_facet(&_Facet::id, __facet); } > > void > _M_install_cache(const facet*, size_t); > }; ># 583 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > template<typename _CharT> > class collate : public locale::facet > { > public: > > > > typedef _CharT char_type; > typedef basic_string<_CharT> string_type; > > > protected: > > > __c_locale _M_c_locale_collate; > > public: > > static locale::id id; ># 610 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > explicit > collate(size_t __refs = 0) > : facet(__refs), _M_c_locale_collate(_S_get_c_locale()) > { } ># 624 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > explicit > collate(__c_locale __cloc, size_t __refs = 0) > : facet(__refs), _M_c_locale_collate(_S_clone_c_locale(__cloc)) > { } ># 641 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > int > compare(const _CharT* __lo1, const _CharT* __hi1, > const _CharT* __lo2, const _CharT* __hi2) const > { return this->do_compare(__lo1, __hi1, __lo2, __hi2); } ># 660 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > string_type > transform(const _CharT* __lo, const _CharT* __hi) const > { return this->do_transform(__lo, __hi); } ># 674 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > long > hash(const _CharT* __lo, const _CharT* __hi) const > { return this->do_hash(__lo, __hi); } > > > int > _M_compare(const _CharT*, const _CharT*) const throw(); > > size_t > _M_transform(_CharT*, const _CharT*, size_t) const throw(); > > protected: > > virtual > ~collate() > { _S_destroy_c_locale(_M_c_locale_collate); } ># 703 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > virtual int > do_compare(const _CharT* __lo1, const _CharT* __hi1, > const _CharT* __lo2, const _CharT* __hi2) const; ># 717 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > virtual string_type > do_transform(const _CharT* __lo, const _CharT* __hi) const; ># 730 "/usr/include/c++/4.9.0/bits/locale_classes.h" 3 > virtual long > do_hash(const _CharT* __lo, const _CharT* __hi) const; > }; > > template<typename _CharT> > locale::id collate<_CharT>::id; > > > template<> > int > collate<char>::_M_compare(const char*, const char*) const throw(); > > template<> > size_t > collate<char>::_M_transform(char*, const char*, size_t) const throw(); > > > template<> > int > collate<wchar_t>::_M_compare(const wchar_t*, const wchar_t*) const throw(); > > template<> > size_t > collate<wchar_t>::_M_transform(wchar_t*, const wchar_t*, size_t) const throw(); > > > > template<typename _CharT> > class collate_byname : public collate<_CharT> > { > public: > > > typedef _CharT char_type; > typedef basic_string<_CharT> string_type; > > > explicit > collate_byname(const char* __s, size_t __refs = 0) > : collate<_CharT>(__refs) > { > if (__builtin_strcmp(__s, "C") != 0 > && __builtin_strcmp(__s, "POSIX") != 0) > { > this->_S_destroy_c_locale(this->_M_c_locale_collate); > this->_S_create_c_locale(this->_M_c_locale_collate, __s); > } > } > > protected: > virtual > ~collate_byname() { } > }; > > >} > ># 1 "/usr/include/c++/4.9.0/bits/locale_classes.tcc" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/locale_classes.tcc" 3 ># 38 "/usr/include/c++/4.9.0/bits/locale_classes.tcc" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Facet> > locale:: > locale(const locale& __other, _Facet* __f) > { > _M_impl = new _Impl(*__other._M_impl, 1); > > try > { _M_impl->_M_install_facet(&_Facet::id, __f); } > catch(...) > { > _M_impl->_M_remove_reference(); > throw; > } > delete [] _M_impl->_M_names[0]; > _M_impl->_M_names[0] = 0; > } > > template<typename _Facet> > locale > locale:: > combine(const locale& __other) const > { > _Impl* __tmp = new _Impl(*_M_impl, 1); > try > { > __tmp->_M_replace_facet(__other._M_impl, &_Facet::id); > } > catch(...) > { > __tmp->_M_remove_reference(); > throw; > } > return locale(__tmp); > } > > template<typename _CharT, typename _Traits, typename _Alloc> > bool > locale:: > operator()(const basic_string<_CharT, _Traits, _Alloc>& __s1, > const basic_string<_CharT, _Traits, _Alloc>& __s2) const > { > typedef std::collate<_CharT> __collate_type; > const __collate_type& __collate = use_facet<__collate_type>(*this); > return (__collate.compare(__s1.data(), __s1.data() + __s1.length(), > __s2.data(), __s2.data() + __s2.length()) < 0); > } ># 102 "/usr/include/c++/4.9.0/bits/locale_classes.tcc" 3 > template<typename _Facet> > bool > has_facet(const locale& __loc) throw() > { > const size_t __i = _Facet::id._M_id(); > const locale::facet** __facets = __loc._M_impl->_M_facets; > return (__i < __loc._M_impl->_M_facets_size > > && dynamic_cast<const _Facet*>(__facets[__i])); > > > > } ># 130 "/usr/include/c++/4.9.0/bits/locale_classes.tcc" 3 > template<typename _Facet> > const _Facet& > use_facet(const locale& __loc) > { > const size_t __i = _Facet::id._M_id(); > const locale::facet** __facets = __loc._M_impl->_M_facets; > if (__i >= __loc._M_impl->_M_facets_size || !__facets[__i]) > __throw_bad_cast(); > > return dynamic_cast<const _Facet&>(*__facets[__i]); > > > > } > > > > template<typename _CharT> > int > collate<_CharT>::_M_compare(const _CharT*, const _CharT*) const throw () > { return 0; } > > > template<typename _CharT> > size_t > collate<_CharT>::_M_transform(_CharT*, const _CharT*, size_t) const throw () > { return 0; } > > template<typename _CharT> > int > collate<_CharT>:: > do_compare(const _CharT* __lo1, const _CharT* __hi1, > const _CharT* __lo2, const _CharT* __hi2) const > { > > > const string_type __one(__lo1, __hi1); > const string_type __two(__lo2, __hi2); > > const _CharT* __p = __one.c_str(); > const _CharT* __pend = __one.data() + __one.length(); > const _CharT* __q = __two.c_str(); > const _CharT* __qend = __two.data() + __two.length(); > > > > > for (;;) > { > const int __res = _M_compare(__p, __q); > if (__res) > return __res; > > __p += char_traits<_CharT>::length(__p); > __q += char_traits<_CharT>::length(__q); > if (__p == __pend && __q == __qend) > return 0; > else if (__p == __pend) > return -1; > else if (__q == __qend) > return 1; > > __p++; > __q++; > } > } > > template<typename _CharT> > typename collate<_CharT>::string_type > collate<_CharT>:: > do_transform(const _CharT* __lo, const _CharT* __hi) const > { > string_type __ret; > > > const string_type __str(__lo, __hi); > > const _CharT* __p = __str.c_str(); > const _CharT* __pend = __str.data() + __str.length(); > > size_t __len = (__hi - __lo) * 2; > > _CharT* __c = new _CharT[__len]; > > try > { > > > > for (;;) > { > > size_t __res = _M_transform(__c, __p, __len); > > > if (__res >= __len) > { > __len = __res + 1; > delete [] __c, __c = 0; > __c = new _CharT[__len]; > __res = _M_transform(__c, __p, __len); > } > > __ret.append(__c, __res); > __p += char_traits<_CharT>::length(__p); > if (__p == __pend) > break; > > __p++; > __ret.push_back(_CharT()); > } > } > catch(...) > { > delete [] __c; > throw; > } > > delete [] __c; > > return __ret; > } > > template<typename _CharT> > long > collate<_CharT>:: > do_hash(const _CharT* __lo, const _CharT* __hi) const > { > unsigned long __val = 0; > for (; __lo < __hi; ++__lo) > __val = > *__lo + ((__val << 7) > | (__val >> (__gnu_cxx::__numeric_traits<unsigned long>:: > __digits - 7))); > return static_cast<long>(__val); > } > > > > > extern template class collate<char>; > extern template class collate_byname<char>; > > extern template > const collate<char>& > use_facet<collate<char> >(const locale&); > > extern template > bool > has_facet<collate<char> >(const locale&); > > > extern template class collate<wchar_t>; > extern template class collate_byname<wchar_t>; > > extern template > const collate<wchar_t>& > use_facet<collate<wchar_t> >(const locale&); > > extern template > bool > has_facet<collate<wchar_t> >(const locale&); > > > > >} ># 788 "/usr/include/c++/4.9.0/bits/locale_classes.h" 2 3 ># 42 "/usr/include/c++/4.9.0/bits/ios_base.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > enum _Ios_Fmtflags > { > _S_boolalpha = 1L << 0, > _S_dec = 1L << 1, > _S_fixed = 1L << 2, > _S_hex = 1L << 3, > _S_internal = 1L << 4, > _S_left = 1L << 5, > _S_oct = 1L << 6, > _S_right = 1L << 7, > _S_scientific = 1L << 8, > _S_showbase = 1L << 9, > _S_showpoint = 1L << 10, > _S_showpos = 1L << 11, > _S_skipws = 1L << 12, > _S_unitbuf = 1L << 13, > _S_uppercase = 1L << 14, > _S_adjustfield = _S_left | _S_right | _S_internal, > _S_basefield = _S_dec | _S_oct | _S_hex, > _S_floatfield = _S_scientific | _S_fixed, > _S_ios_fmtflags_end = 1L << 16 > }; > > inline constexpr _Ios_Fmtflags > operator&(_Ios_Fmtflags __a, _Ios_Fmtflags __b) > { return _Ios_Fmtflags(static_cast<int>(__a) & static_cast<int>(__b)); } > > inline constexpr _Ios_Fmtflags > operator|(_Ios_Fmtflags __a, _Ios_Fmtflags __b) > { return _Ios_Fmtflags(static_cast<int>(__a) | static_cast<int>(__b)); } > > inline constexpr _Ios_Fmtflags > operator^(_Ios_Fmtflags __a, _Ios_Fmtflags __b) > { return _Ios_Fmtflags(static_cast<int>(__a) ^ static_cast<int>(__b)); } > > inline constexpr _Ios_Fmtflags > operator~(_Ios_Fmtflags __a) > { return _Ios_Fmtflags(~static_cast<int>(__a)); } > > inline const _Ios_Fmtflags& > operator|=(_Ios_Fmtflags& __a, _Ios_Fmtflags __b) > { return __a = __a | __b; } > > inline const _Ios_Fmtflags& > operator&=(_Ios_Fmtflags& __a, _Ios_Fmtflags __b) > { return __a = __a & __b; } > > inline const _Ios_Fmtflags& > operator^=(_Ios_Fmtflags& __a, _Ios_Fmtflags __b) > { return __a = __a ^ __b; } > > > enum _Ios_Openmode > { > _S_app = 1L << 0, > _S_ate = 1L << 1, > _S_bin = 1L << 2, > _S_in = 1L << 3, > _S_out = 1L << 4, > _S_trunc = 1L << 5, > _S_ios_openmode_end = 1L << 16 > }; > > inline constexpr _Ios_Openmode > operator&(_Ios_Openmode __a, _Ios_Openmode __b) > { return _Ios_Openmode(static_cast<int>(__a) & static_cast<int>(__b)); } > > inline constexpr _Ios_Openmode > operator|(_Ios_Openmode __a, _Ios_Openmode __b) > { return _Ios_Openmode(static_cast<int>(__a) | static_cast<int>(__b)); } > > inline constexpr _Ios_Openmode > operator^(_Ios_Openmode __a, _Ios_Openmode __b) > { return _Ios_Openmode(static_cast<int>(__a) ^ static_cast<int>(__b)); } > > inline constexpr _Ios_Openmode > operator~(_Ios_Openmode __a) > { return _Ios_Openmode(~static_cast<int>(__a)); } > > inline const _Ios_Openmode& > operator|=(_Ios_Openmode& __a, _Ios_Openmode __b) > { return __a = __a | __b; } > > inline const _Ios_Openmode& > operator&=(_Ios_Openmode& __a, _Ios_Openmode __b) > { return __a = __a & __b; } > > inline const _Ios_Openmode& > operator^=(_Ios_Openmode& __a, _Ios_Openmode __b) > { return __a = __a ^ __b; } > > > enum _Ios_Iostate > { > _S_goodbit = 0, > _S_badbit = 1L << 0, > _S_eofbit = 1L << 1, > _S_failbit = 1L << 2, > _S_ios_iostate_end = 1L << 16 > }; > > inline constexpr _Ios_Iostate > operator&(_Ios_Iostate __a, _Ios_Iostate __b) > { return _Ios_Iostate(static_cast<int>(__a) & static_cast<int>(__b)); } > > inline constexpr _Ios_Iostate > operator|(_Ios_Iostate __a, _Ios_Iostate __b) > { return _Ios_Iostate(static_cast<int>(__a) | static_cast<int>(__b)); } > > inline constexpr _Ios_Iostate > operator^(_Ios_Iostate __a, _Ios_Iostate __b) > { return _Ios_Iostate(static_cast<int>(__a) ^ static_cast<int>(__b)); } > > inline constexpr _Ios_Iostate > operator~(_Ios_Iostate __a) > { return _Ios_Iostate(~static_cast<int>(__a)); } > > inline const _Ios_Iostate& > operator|=(_Ios_Iostate& __a, _Ios_Iostate __b) > { return __a = __a | __b; } > > inline const _Ios_Iostate& > operator&=(_Ios_Iostate& __a, _Ios_Iostate __b) > { return __a = __a & __b; } > > inline const _Ios_Iostate& > operator^=(_Ios_Iostate& __a, _Ios_Iostate __b) > { return __a = __a ^ __b; } > > > enum _Ios_Seekdir > { > _S_beg = 0, > _S_cur = 1, > _S_end = 2, > _S_ios_seekdir_end = 1L << 16 > }; ># 199 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > class ios_base > { > public: > > > > > > > > class failure : public exception > { > public: > > > explicit > failure(const string& __str) throw(); > > > > virtual > ~failure() throw(); > > virtual const char* > what() const throw(); > > private: > string _M_msg; > }; ># 255 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > typedef _Ios_Fmtflags fmtflags; > > > static const fmtflags boolalpha = _S_boolalpha; > > > static const fmtflags dec = _S_dec; > > > static const fmtflags fixed = _S_fixed; > > > static const fmtflags hex = _S_hex; > > > > > static const fmtflags internal = _S_internal; > > > > static const fmtflags left = _S_left; > > > static const fmtflags oct = _S_oct; > > > > static const fmtflags right = _S_right; > > > static const fmtflags scientific = _S_scientific; > > > > static const fmtflags showbase = _S_showbase; > > > > static const fmtflags showpoint = _S_showpoint; > > > static const fmtflags showpos = _S_showpos; > > > static const fmtflags skipws = _S_skipws; > > > static const fmtflags unitbuf = _S_unitbuf; > > > > static const fmtflags uppercase = _S_uppercase; > > > static const fmtflags adjustfield = _S_adjustfield; > > > static const fmtflags basefield = _S_basefield; > > > static const fmtflags floatfield = _S_floatfield; ># 330 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > typedef _Ios_Iostate iostate; > > > > static const iostate badbit = _S_badbit; > > > static const iostate eofbit = _S_eofbit; > > > > > static const iostate failbit = _S_failbit; > > > static const iostate goodbit = _S_goodbit; ># 361 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > typedef _Ios_Openmode openmode; > > > static const openmode app = _S_app; > > > static const openmode ate = _S_ate; > > > > > static const openmode binary = _S_bin; > > > static const openmode in = _S_in; > > > static const openmode out = _S_out; > > > static const openmode trunc = _S_trunc; ># 393 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > typedef _Ios_Seekdir seekdir; > > > static const seekdir beg = _S_beg; > > > static const seekdir cur = _S_cur; > > > static const seekdir end = _S_end; > > > typedef int io_state; > typedef int open_mode; > typedef int seek_dir; > > typedef std::streampos streampos; > typedef std::streamoff streamoff; ># 419 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > enum event > { > erase_event, > imbue_event, > copyfmt_event > }; ># 436 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > typedef void (*event_callback) (event __e, ios_base& __b, int __i); ># 448 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > void > register_callback(event_callback __fn, int __index); > > protected: > streamsize _M_precision; > streamsize _M_width; > fmtflags _M_flags; > iostate _M_exception; > iostate _M_streambuf_state; > > > > struct _Callback_list > { > > _Callback_list* _M_next; > ios_base::event_callback _M_fn; > int _M_index; > _Atomic_word _M_refcount; > > _Callback_list(ios_base::event_callback __fn, int __index, > _Callback_list* __cb) > : _M_next(__cb), _M_fn(__fn), _M_index(__index), _M_refcount(0) { } > > void > _M_add_reference() { __gnu_cxx::__atomic_add_dispatch(&_M_refcount, 1); } > > > int > _M_remove_reference() > { > > ; > int __res = __gnu_cxx::__exchange_and_add_dispatch(&_M_refcount, -1); > if (__res == 0) > { > ; > } > return __res; > } > }; > > _Callback_list* _M_callbacks; > > void > _M_call_callbacks(event __ev) throw(); > > void > _M_dispose_callbacks(void) throw(); > > > struct _Words > { > void* _M_pword; > long _M_iword; > _Words() : _M_pword(0), _M_iword(0) { } > }; > > > _Words _M_word_zero; > > > > enum { _S_local_word_size = 8 }; > _Words _M_local_word[_S_local_word_size]; > > > int _M_word_size; > _Words* _M_word; > > _Words& > _M_grow_words(int __index, bool __iword); > > > locale _M_ios_locale; > > void > _M_init() throw(); > > public: > > > > > > class Init > { > friend class ios_base; > public: > Init(); > ~Init(); > > private: > static _Atomic_word _S_refcount; > static bool _S_synced_with_stdio; > }; > > > > > > > fmtflags > flags() const > { return _M_flags; } ># 561 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > fmtflags > flags(fmtflags __fmtfl) > { > fmtflags __old = _M_flags; > _M_flags = __fmtfl; > return __old; > } ># 577 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > fmtflags > setf(fmtflags __fmtfl) > { > fmtflags __old = _M_flags; > _M_flags |= __fmtfl; > return __old; > } ># 594 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > fmtflags > setf(fmtflags __fmtfl, fmtflags __mask) > { > fmtflags __old = _M_flags; > _M_flags &= ~__mask; > _M_flags |= (__fmtfl & __mask); > return __old; > } > > > > > > > > void > unsetf(fmtflags __mask) > { _M_flags &= ~__mask; } ># 620 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > streamsize > precision() const > { return _M_precision; } > > > > > > > streamsize > precision(streamsize __prec) > { > streamsize __old = _M_precision; > _M_precision = __prec; > return __old; > } > > > > > > > > streamsize > width() const > { return _M_width; } > > > > > > > streamsize > width(streamsize __wide) > { > streamsize __old = _M_width; > _M_width = __wide; > return __old; > } ># 671 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > static bool > sync_with_stdio(bool __sync = true); ># 683 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > locale > imbue(const locale& __loc) throw(); ># 694 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > locale > getloc() const > { return _M_ios_locale; } ># 705 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > const locale& > _M_getloc() const > { return _M_ios_locale; } ># 724 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > static int > xalloc() throw(); ># 740 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > long& > iword(int __ix) > { > _Words& __word = (__ix < _M_word_size) > ? _M_word[__ix] : _M_grow_words(__ix, true); > return __word._M_iword; > } ># 761 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > void*& > pword(int __ix) > { > _Words& __word = (__ix < _M_word_size) > ? _M_word[__ix] : _M_grow_words(__ix, false); > return __word._M_pword; > } ># 778 "/usr/include/c++/4.9.0/bits/ios_base.h" 3 > virtual ~ios_base(); > > protected: > ios_base() throw (); > > > > private: > ios_base(const ios_base&); > > ios_base& > operator=(const ios_base&); > }; > > > > inline ios_base& > boolalpha(ios_base& __base) > { > __base.setf(ios_base::boolalpha); > return __base; > } > > > inline ios_base& > noboolalpha(ios_base& __base) > { > __base.unsetf(ios_base::boolalpha); > return __base; > } > > > inline ios_base& > showbase(ios_base& __base) > { > __base.setf(ios_base::showbase); > return __base; > } > > > inline ios_base& > noshowbase(ios_base& __base) > { > __base.unsetf(ios_base::showbase); > return __base; > } > > > inline ios_base& > showpoint(ios_base& __base) > { > __base.setf(ios_base::showpoint); > return __base; > } > > > inline ios_base& > noshowpoint(ios_base& __base) > { > __base.unsetf(ios_base::showpoint); > return __base; > } > > > inline ios_base& > showpos(ios_base& __base) > { > __base.setf(ios_base::showpos); > return __base; > } > > > inline ios_base& > noshowpos(ios_base& __base) > { > __base.unsetf(ios_base::showpos); > return __base; > } > > > inline ios_base& > skipws(ios_base& __base) > { > __base.setf(ios_base::skipws); > return __base; > } > > > inline ios_base& > noskipws(ios_base& __base) > { > __base.unsetf(ios_base::skipws); > return __base; > } > > > inline ios_base& > uppercase(ios_base& __base) > { > __base.setf(ios_base::uppercase); > return __base; > } > > > inline ios_base& > nouppercase(ios_base& __base) > { > __base.unsetf(ios_base::uppercase); > return __base; > } > > > inline ios_base& > unitbuf(ios_base& __base) > { > __base.setf(ios_base::unitbuf); > return __base; > } > > > inline ios_base& > nounitbuf(ios_base& __base) > { > __base.unsetf(ios_base::unitbuf); > return __base; > } > > > > inline ios_base& > internal(ios_base& __base) > { > __base.setf(ios_base::internal, ios_base::adjustfield); > return __base; > } > > > inline ios_base& > left(ios_base& __base) > { > __base.setf(ios_base::left, ios_base::adjustfield); > return __base; > } > > > inline ios_base& > right(ios_base& __base) > { > __base.setf(ios_base::right, ios_base::adjustfield); > return __base; > } > > > > inline ios_base& > dec(ios_base& __base) > { > __base.setf(ios_base::dec, ios_base::basefield); > return __base; > } > > > inline ios_base& > hex(ios_base& __base) > { > __base.setf(ios_base::hex, ios_base::basefield); > return __base; > } > > > inline ios_base& > oct(ios_base& __base) > { > __base.setf(ios_base::oct, ios_base::basefield); > return __base; > } > > > > inline ios_base& > fixed(ios_base& __base) > { > __base.setf(ios_base::fixed, ios_base::floatfield); > return __base; > } > > > inline ios_base& > scientific(ios_base& __base) > { > __base.setf(ios_base::scientific, ios_base::floatfield); > return __base; > } > > >} ># 43 "/usr/include/c++/4.9.0/ios" 2 3 ># 1 "/usr/include/c++/4.9.0/streambuf" 1 3 ># 36 "/usr/include/c++/4.9.0/streambuf" 3 ># 37 "/usr/include/c++/4.9.0/streambuf" 3 ># 45 "/usr/include/c++/4.9.0/streambuf" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT, typename _Traits> > streamsize > __copy_streambufs_eof(basic_streambuf<_CharT, _Traits>*, > basic_streambuf<_CharT, _Traits>*, bool&); ># 119 "/usr/include/c++/4.9.0/streambuf" 3 > template<typename _CharT, typename _Traits> > class basic_streambuf > { > public: > > > > > > > typedef _CharT char_type; > typedef _Traits traits_type; > typedef typename traits_type::int_type int_type; > typedef typename traits_type::pos_type pos_type; > typedef typename traits_type::off_type off_type; > > > > > typedef basic_streambuf<char_type, traits_type> __streambuf_type; > > > friend class basic_ios<char_type, traits_type>; > friend class basic_istream<char_type, traits_type>; > friend class basic_ostream<char_type, traits_type>; > friend class istreambuf_iterator<char_type, traits_type>; > friend class ostreambuf_iterator<char_type, traits_type>; > > friend streamsize > __copy_streambufs_eof<>(basic_streambuf*, basic_streambuf*, bool&); > > template<bool _IsMove, typename _CharT2> > friend typename __gnu_cxx::__enable_if<__is_char<_CharT2>::__value, > _CharT2*>::__type > __copy_move_a2(istreambuf_iterator<_CharT2>, > istreambuf_iterator<_CharT2>, _CharT2*); > > template<typename _CharT2> > friend typename __gnu_cxx::__enable_if<__is_char<_CharT2>::__value, > istreambuf_iterator<_CharT2> >::__type > find(istreambuf_iterator<_CharT2>, istreambuf_iterator<_CharT2>, > const _CharT2&); > > template<typename _CharT2, typename _Traits2> > friend basic_istream<_CharT2, _Traits2>& > operator>>(basic_istream<_CharT2, _Traits2>&, _CharT2*); > > template<typename _CharT2, typename _Traits2, typename _Alloc> > friend basic_istream<_CharT2, _Traits2>& > operator>>(basic_istream<_CharT2, _Traits2>&, > basic_string<_CharT2, _Traits2, _Alloc>&); > > template<typename _CharT2, typename _Traits2, typename _Alloc> > friend basic_istream<_CharT2, _Traits2>& > getline(basic_istream<_CharT2, _Traits2>&, > basic_string<_CharT2, _Traits2, _Alloc>&, _CharT2); > > protected: > > > > > > > > char_type* _M_in_beg; > char_type* _M_in_cur; > char_type* _M_in_end; > char_type* _M_out_beg; > char_type* _M_out_cur; > char_type* _M_out_end; > > > locale _M_buf_locale; > > public: > > virtual > ~basic_streambuf() > { } ># 208 "/usr/include/c++/4.9.0/streambuf" 3 > locale > pubimbue(const locale& __loc) > { > locale __tmp(this->getloc()); > this->imbue(__loc); > _M_buf_locale = __loc; > return __tmp; > } ># 225 "/usr/include/c++/4.9.0/streambuf" 3 > locale > getloc() const > { return _M_buf_locale; } ># 238 "/usr/include/c++/4.9.0/streambuf" 3 > basic_streambuf* > pubsetbuf(char_type* __s, streamsize __n) > { return this->setbuf(__s, __n); } ># 250 "/usr/include/c++/4.9.0/streambuf" 3 > pos_type > pubseekoff(off_type __off, ios_base::seekdir __way, > ios_base::openmode __mode = ios_base::in | ios_base::out) > { return this->seekoff(__off, __way, __mode); } ># 262 "/usr/include/c++/4.9.0/streambuf" 3 > pos_type > pubseekpos(pos_type __sp, > ios_base::openmode __mode = ios_base::in | ios_base::out) > { return this->seekpos(__sp, __mode); } > > > > > int > pubsync() { return this->sync(); } ># 283 "/usr/include/c++/4.9.0/streambuf" 3 > streamsize > in_avail() > { > const streamsize __ret = this->egptr() - this->gptr(); > return __ret ? __ret : this->showmanyc(); > } ># 297 "/usr/include/c++/4.9.0/streambuf" 3 > int_type > snextc() > { > int_type __ret = traits_type::eof(); > if (__builtin_expect(!traits_type::eq_int_type(this->sbumpc(), > __ret), true)) > __ret = this->sgetc(); > return __ret; > } ># 315 "/usr/include/c++/4.9.0/streambuf" 3 > int_type > sbumpc() > { > int_type __ret; > if (__builtin_expect(this->gptr() < this->egptr(), true)) > { > __ret = traits_type::to_int_type(*this->gptr()); > this->gbump(1); > } > else > __ret = this->uflow(); > return __ret; > } ># 337 "/usr/include/c++/4.9.0/streambuf" 3 > int_type > sgetc() > { > int_type __ret; > if (__builtin_expect(this->gptr() < this->egptr(), true)) > __ret = traits_type::to_int_type(*this->gptr()); > else > __ret = this->underflow(); > return __ret; > } ># 356 "/usr/include/c++/4.9.0/streambuf" 3 > streamsize > sgetn(char_type* __s, streamsize __n) > { return this->xsgetn(__s, __n); } ># 371 "/usr/include/c++/4.9.0/streambuf" 3 > int_type > sputbackc(char_type __c) > { > int_type __ret; > const bool __testpos = this->eback() < this->gptr(); > if (__builtin_expect(!__testpos || > !traits_type::eq(__c, this->gptr()[-1]), false)) > __ret = this->pbackfail(traits_type::to_int_type(__c)); > else > { > this->gbump(-1); > __ret = traits_type::to_int_type(*this->gptr()); > } > return __ret; > } ># 396 "/usr/include/c++/4.9.0/streambuf" 3 > int_type > sungetc() > { > int_type __ret; > if (__builtin_expect(this->eback() < this->gptr(), true)) > { > this->gbump(-1); > __ret = traits_type::to_int_type(*this->gptr()); > } > else > __ret = this->pbackfail(); > return __ret; > } ># 423 "/usr/include/c++/4.9.0/streambuf" 3 > int_type > sputc(char_type __c) > { > int_type __ret; > if (__builtin_expect(this->pptr() < this->epptr(), true)) > { > *this->pptr() = __c; > this->pbump(1); > __ret = traits_type::to_int_type(__c); > } > else > __ret = this->overflow(traits_type::to_int_type(__c)); > return __ret; > } ># 449 "/usr/include/c++/4.9.0/streambuf" 3 > streamsize > sputn(const char_type* __s, streamsize __n) > { return this->xsputn(__s, __n); } > > protected: ># 463 "/usr/include/c++/4.9.0/streambuf" 3 > basic_streambuf() > : _M_in_beg(0), _M_in_cur(0), _M_in_end(0), > _M_out_beg(0), _M_out_cur(0), _M_out_end(0), > _M_buf_locale(locale()) > { } ># 481 "/usr/include/c++/4.9.0/streambuf" 3 > char_type* > eback() const { return _M_in_beg; } > > char_type* > gptr() const { return _M_in_cur; } > > char_type* > egptr() const { return _M_in_end; } ># 497 "/usr/include/c++/4.9.0/streambuf" 3 > void > gbump(int __n) { _M_in_cur += __n; } ># 508 "/usr/include/c++/4.9.0/streambuf" 3 > void > setg(char_type* __gbeg, char_type* __gnext, char_type* __gend) > { > _M_in_beg = __gbeg; > _M_in_cur = __gnext; > _M_in_end = __gend; > } ># 528 "/usr/include/c++/4.9.0/streambuf" 3 > char_type* > pbase() const { return _M_out_beg; } > > char_type* > pptr() const { return _M_out_cur; } > > char_type* > epptr() const { return _M_out_end; } ># 544 "/usr/include/c++/4.9.0/streambuf" 3 > void > pbump(int __n) { _M_out_cur += __n; } ># 554 "/usr/include/c++/4.9.0/streambuf" 3 > void > setp(char_type* __pbeg, char_type* __pend) > { > _M_out_beg = _M_out_cur = __pbeg; > _M_out_end = __pend; > } ># 575 "/usr/include/c++/4.9.0/streambuf" 3 > virtual void > imbue(const locale& __loc) > { } ># 590 "/usr/include/c++/4.9.0/streambuf" 3 > virtual basic_streambuf<char_type,_Traits>* > setbuf(char_type*, streamsize) > { return this; } ># 601 "/usr/include/c++/4.9.0/streambuf" 3 > virtual pos_type > seekoff(off_type, ios_base::seekdir, > ios_base::openmode = ios_base::in | ios_base::out) > { return pos_type(off_type(-1)); } ># 613 "/usr/include/c++/4.9.0/streambuf" 3 > virtual pos_type > seekpos(pos_type, > ios_base::openmode = ios_base::in | ios_base::out) > { return pos_type(off_type(-1)); } ># 626 "/usr/include/c++/4.9.0/streambuf" 3 > virtual int > sync() { return 0; } ># 648 "/usr/include/c++/4.9.0/streambuf" 3 > virtual streamsize > showmanyc() { return 0; } ># 664 "/usr/include/c++/4.9.0/streambuf" 3 > virtual streamsize > xsgetn(char_type* __s, streamsize __n); ># 686 "/usr/include/c++/4.9.0/streambuf" 3 > virtual int_type > underflow() > { return traits_type::eof(); } ># 699 "/usr/include/c++/4.9.0/streambuf" 3 > virtual int_type > uflow() > { > int_type __ret = traits_type::eof(); > const bool __testeof = traits_type::eq_int_type(this->underflow(), > __ret); > if (!__testeof) > { > __ret = traits_type::to_int_type(*this->gptr()); > this->gbump(1); > } > return __ret; > } ># 723 "/usr/include/c++/4.9.0/streambuf" 3 > virtual int_type > pbackfail(int_type __c = traits_type::eof()) > { return traits_type::eof(); } ># 741 "/usr/include/c++/4.9.0/streambuf" 3 > virtual streamsize > xsputn(const char_type* __s, streamsize __n); ># 767 "/usr/include/c++/4.9.0/streambuf" 3 > virtual int_type > overflow(int_type __c = traits_type::eof()) > { return traits_type::eof(); } > > > > public: ># 782 "/usr/include/c++/4.9.0/streambuf" 3 > void > stossc() > { > if (this->gptr() < this->egptr()) > this->gbump(1); > else > this->uflow(); > } > > > > void > __safe_gbump(streamsize __n) { _M_in_cur += __n; } > > void > __safe_pbump(streamsize __n) { _M_out_cur += __n; } > > private: > > > basic_streambuf(const basic_streambuf& __sb) > : _M_in_beg(__sb._M_in_beg), _M_in_cur(__sb._M_in_cur), > _M_in_end(__sb._M_in_end), _M_out_beg(__sb._M_out_beg), > _M_out_cur(__sb._M_out_cur), _M_out_end(__sb._M_out_cur), > _M_buf_locale(__sb._M_buf_locale) > { } > > basic_streambuf& > operator=(const basic_streambuf&) { return *this; }; > }; > > > template<> > streamsize > __copy_streambufs_eof(basic_streambuf<char>* __sbin, > basic_streambuf<char>* __sbout, bool& __ineof); > > template<> > streamsize > __copy_streambufs_eof(basic_streambuf<wchar_t>* __sbin, > basic_streambuf<wchar_t>* __sbout, bool& __ineof); > > > >} > ># 1 "/usr/include/c++/4.9.0/bits/streambuf.tcc" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/streambuf.tcc" 3 ># 38 "/usr/include/c++/4.9.0/bits/streambuf.tcc" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT, typename _Traits> > streamsize > basic_streambuf<_CharT, _Traits>:: > xsgetn(char_type* __s, streamsize __n) > { > streamsize __ret = 0; > while (__ret < __n) > { > const streamsize __buf_len = this->egptr() - this->gptr(); > if (__buf_len) > { > const streamsize __remaining = __n - __ret; > const streamsize __len = std::min(__buf_len, __remaining); > traits_type::copy(__s, this->gptr(), __len); > __ret += __len; > __s += __len; > this->__safe_gbump(__len); > } > > if (__ret < __n) > { > const int_type __c = this->uflow(); > if (!traits_type::eq_int_type(__c, traits_type::eof())) > { > traits_type::assign(*__s++, traits_type::to_char_type(__c)); > ++__ret; > } > else > break; > } > } > return __ret; > } > > template<typename _CharT, typename _Traits> > streamsize > basic_streambuf<_CharT, _Traits>:: > xsputn(const char_type* __s, streamsize __n) > { > streamsize __ret = 0; > while (__ret < __n) > { > const streamsize __buf_len = this->epptr() - this->pptr(); > if (__buf_len) > { > const streamsize __remaining = __n - __ret; > const streamsize __len = std::min(__buf_len, __remaining); > traits_type::copy(this->pptr(), __s, __len); > __ret += __len; > __s += __len; > this->__safe_pbump(__len); > } > > if (__ret < __n) > { > int_type __c = this->overflow(traits_type::to_int_type(*__s)); > if (!traits_type::eq_int_type(__c, traits_type::eof())) > { > ++__ret; > ++__s; > } > else > break; > } > } > return __ret; > } > > > > > template<typename _CharT, typename _Traits> > streamsize > __copy_streambufs_eof(basic_streambuf<_CharT, _Traits>* __sbin, > basic_streambuf<_CharT, _Traits>* __sbout, > bool& __ineof) > { > streamsize __ret = 0; > __ineof = true; > typename _Traits::int_type __c = __sbin->sgetc(); > while (!_Traits::eq_int_type(__c, _Traits::eof())) > { > __c = __sbout->sputc(_Traits::to_char_type(__c)); > if (_Traits::eq_int_type(__c, _Traits::eof())) > { > __ineof = false; > break; > } > ++__ret; > __c = __sbin->snextc(); > } > return __ret; > } > > template<typename _CharT, typename _Traits> > inline streamsize > __copy_streambufs(basic_streambuf<_CharT, _Traits>* __sbin, > basic_streambuf<_CharT, _Traits>* __sbout) > { > bool __ineof; > return __copy_streambufs_eof(__sbin, __sbout, __ineof); > } > > > > > extern template class basic_streambuf<char>; > extern template > streamsize > __copy_streambufs(basic_streambuf<char>*, > basic_streambuf<char>*); > extern template > streamsize > __copy_streambufs_eof(basic_streambuf<char>*, > basic_streambuf<char>*, bool&); > > > extern template class basic_streambuf<wchar_t>; > extern template > streamsize > __copy_streambufs(basic_streambuf<wchar_t>*, > basic_streambuf<wchar_t>*); > extern template > streamsize > __copy_streambufs_eof(basic_streambuf<wchar_t>*, > basic_streambuf<wchar_t>*, bool&); > > > > >} ># 829 "/usr/include/c++/4.9.0/streambuf" 2 3 ># 44 "/usr/include/c++/4.9.0/ios" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/basic_ios.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > > > ># 1 "/usr/include/c++/4.9.0/bits/locale_facets.h" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 ># 38 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > ># 1 "/usr/include/c++/4.9.0/cwctype" 1 3 ># 39 "/usr/include/c++/4.9.0/cwctype" 3 ># 40 "/usr/include/c++/4.9.0/cwctype" 3 ># 50 "/usr/include/c++/4.9.0/cwctype" 3 ># 1 "/usr/include/wctype.h" 1 3 4 ># 33 "/usr/include/wctype.h" 3 4 ># 1 "/usr/include/wchar.h" 1 3 4 ># 34 "/usr/include/wctype.h" 2 3 4 ># 49 "/usr/include/wctype.h" 3 4 > > > >typedef unsigned long int wctype_t; ># 71 "/usr/include/wctype.h" 3 4 >enum >{ > __ISwupper = 0, > __ISwlower = 1, > __ISwalpha = 2, > __ISwdigit = 3, > __ISwxdigit = 4, > __ISwspace = 5, > __ISwprint = 6, > __ISwgraph = 7, > __ISwblank = 8, > __ISwcntrl = 9, > __ISwpunct = 10, > __ISwalnum = 11, > > _ISwupper = ((__ISwupper) < 8 ? (int) ((1UL << (__ISwupper)) << 24) : ((__ISwupper) < 16 ? (int) ((1UL << (__ISwupper)) << 8) : ((__ISwupper) < 24 ? (int) ((1UL << (__ISwupper)) >> 8) : (int) ((1UL << (__ISwupper)) >> 24)))), > _ISwlower = ((__ISwlower) < 8 ? (int) ((1UL << (__ISwlower)) << 24) : ((__ISwlower) < 16 ? (int) ((1UL << (__ISwlower)) << 8) : ((__ISwlower) < 24 ? (int) ((1UL << (__ISwlower)) >> 8) : (int) ((1UL << (__ISwlower)) >> 24)))), > _ISwalpha = ((__ISwalpha) < 8 ? (int) ((1UL << (__ISwalpha)) << 24) : ((__ISwalpha) < 16 ? (int) ((1UL << (__ISwalpha)) << 8) : ((__ISwalpha) < 24 ? (int) ((1UL << (__ISwalpha)) >> 8) : (int) ((1UL << (__ISwalpha)) >> 24)))), > _ISwdigit = ((__ISwdigit) < 8 ? (int) ((1UL << (__ISwdigit)) << 24) : ((__ISwdigit) < 16 ? (int) ((1UL << (__ISwdigit)) << 8) : ((__ISwdigit) < 24 ? (int) ((1UL << (__ISwdigit)) >> 8) : (int) ((1UL << (__ISwdigit)) >> 24)))), > _ISwxdigit = ((__ISwxdigit) < 8 ? (int) ((1UL << (__ISwxdigit)) << 24) : ((__ISwxdigit) < 16 ? (int) ((1UL << (__ISwxdigit)) << 8) : ((__ISwxdigit) < 24 ? (int) ((1UL << (__ISwxdigit)) >> 8) : (int) ((1UL << (__ISwxdigit)) >> 24)))), > _ISwspace = ((__ISwspace) < 8 ? (int) ((1UL << (__ISwspace)) << 24) : ((__ISwspace) < 16 ? (int) ((1UL << (__ISwspace)) << 8) : ((__ISwspace) < 24 ? (int) ((1UL << (__ISwspace)) >> 8) : (int) ((1UL << (__ISwspace)) >> 24)))), > _ISwprint = ((__ISwprint) < 8 ? (int) ((1UL << (__ISwprint)) << 24) : ((__ISwprint) < 16 ? (int) ((1UL << (__ISwprint)) << 8) : ((__ISwprint) < 24 ? (int) ((1UL << (__ISwprint)) >> 8) : (int) ((1UL << (__ISwprint)) >> 24)))), > _ISwgraph = ((__ISwgraph) < 8 ? (int) ((1UL << (__ISwgraph)) << 24) : ((__ISwgraph) < 16 ? (int) ((1UL << (__ISwgraph)) << 8) : ((__ISwgraph) < 24 ? (int) ((1UL << (__ISwgraph)) >> 8) : (int) ((1UL << (__ISwgraph)) >> 24)))), > _ISwblank = ((__ISwblank) < 8 ? (int) ((1UL << (__ISwblank)) << 24) : ((__ISwblank) < 16 ? (int) ((1UL << (__ISwblank)) << 8) : ((__ISwblank) < 24 ? (int) ((1UL << (__ISwblank)) >> 8) : (int) ((1UL << (__ISwblank)) >> 24)))), > _ISwcntrl = ((__ISwcntrl) < 8 ? (int) ((1UL << (__ISwcntrl)) << 24) : ((__ISwcntrl) < 16 ? (int) ((1UL << (__ISwcntrl)) << 8) : ((__ISwcntrl) < 24 ? (int) ((1UL << (__ISwcntrl)) >> 8) : (int) ((1UL << (__ISwcntrl)) >> 24)))), > _ISwpunct = ((__ISwpunct) < 8 ? (int) ((1UL << (__ISwpunct)) << 24) : ((__ISwpunct) < 16 ? (int) ((1UL << (__ISwpunct)) << 8) : ((__ISwpunct) < 24 ? (int) ((1UL << (__ISwpunct)) >> 8) : (int) ((1UL << (__ISwpunct)) >> 24)))), > _ISwalnum = ((__ISwalnum) < 8 ? (int) ((1UL << (__ISwalnum)) << 24) : ((__ISwalnum) < 16 ? (int) ((1UL << (__ISwalnum)) << 8) : ((__ISwalnum) < 24 ? (int) ((1UL << (__ISwalnum)) >> 8) : (int) ((1UL << (__ISwalnum)) >> 24)))) >}; > > > >extern "C" { ># 111 "/usr/include/wctype.h" 3 4 >extern int iswalnum (wint_t __wc) throw (); > > > > > >extern int iswalpha (wint_t __wc) throw (); > > >extern int iswcntrl (wint_t __wc) throw (); > > > >extern int iswdigit (wint_t __wc) throw (); > > > >extern int iswgraph (wint_t __wc) throw (); > > > > >extern int iswlower (wint_t __wc) throw (); > > >extern int iswprint (wint_t __wc) throw (); > > > > >extern int iswpunct (wint_t __wc) throw (); > > > > >extern int iswspace (wint_t __wc) throw (); > > > > >extern int iswupper (wint_t __wc) throw (); > > > > >extern int iswxdigit (wint_t __wc) throw (); > > > > > >extern int iswblank (wint_t __wc) throw (); ># 171 "/usr/include/wctype.h" 3 4 >extern wctype_t wctype (const char *__property) throw (); > > > >extern int iswctype (wint_t __wc, wctype_t __desc) throw (); ># 186 "/usr/include/wctype.h" 3 4 >typedef const __int32_t *wctrans_t; > > > > > > > >extern wint_t towlower (wint_t __wc) throw (); > > >extern wint_t towupper (wint_t __wc) throw (); > > >} ># 213 "/usr/include/wctype.h" 3 4 >extern "C" { > > > > >extern wctrans_t wctrans (const char *__property) throw (); > > >extern wint_t towctrans (wint_t __wc, wctrans_t __desc) throw (); ># 230 "/usr/include/wctype.h" 3 4 >extern int iswalnum_l (wint_t __wc, __locale_t __locale) throw (); > > > > > >extern int iswalpha_l (wint_t __wc, __locale_t __locale) throw (); > > >extern int iswcntrl_l (wint_t __wc, __locale_t __locale) throw (); > > > >extern int iswdigit_l (wint_t __wc, __locale_t __locale) throw (); > > > >extern int iswgraph_l (wint_t __wc, __locale_t __locale) throw (); > > > > >extern int iswlower_l (wint_t __wc, __locale_t __locale) throw (); > > >extern int iswprint_l (wint_t __wc, __locale_t __locale) throw (); > > > > >extern int iswpunct_l (wint_t __wc, __locale_t __locale) throw (); > > > > >extern int iswspace_l (wint_t __wc, __locale_t __locale) throw (); > > > > >extern int iswupper_l (wint_t __wc, __locale_t __locale) throw (); > > > > >extern int iswxdigit_l (wint_t __wc, __locale_t __locale) throw (); > > > > >extern int iswblank_l (wint_t __wc, __locale_t __locale) throw (); > > > >extern wctype_t wctype_l (const char *__property, __locale_t __locale) > throw (); > > > >extern int iswctype_l (wint_t __wc, wctype_t __desc, __locale_t __locale) > throw (); > > > > > > > >extern wint_t towlower_l (wint_t __wc, __locale_t __locale) throw (); > > >extern wint_t towupper_l (wint_t __wc, __locale_t __locale) throw (); > > > >extern wctrans_t wctrans_l (const char *__property, __locale_t __locale) > throw (); > > >extern wint_t towctrans_l (wint_t __wc, wctrans_t __desc, > __locale_t __locale) throw (); > > > >} ># 51 "/usr/include/c++/4.9.0/cwctype" 2 3 ># 80 "/usr/include/c++/4.9.0/cwctype" 3 >namespace std >{ > using ::wctrans_t; > using ::wctype_t; > using ::wint_t; > > using ::iswalnum; > using ::iswalpha; > > using ::iswblank; > > using ::iswcntrl; > using ::iswctype; > using ::iswdigit; > using ::iswgraph; > using ::iswlower; > using ::iswprint; > using ::iswpunct; > using ::iswspace; > using ::iswupper; > using ::iswxdigit; > using ::towctrans; > using ::towlower; > using ::towupper; > using ::wctrans; > using ::wctype; >} ># 40 "/usr/include/c++/4.9.0/bits/locale_facets.h" 2 3 ># 1 "/usr/include/c++/4.9.0/cctype" 1 3 ># 39 "/usr/include/c++/4.9.0/cctype" 3 ># 40 "/usr/include/c++/4.9.0/cctype" 3 ># 41 "/usr/include/c++/4.9.0/bits/locale_facets.h" 2 3 ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/ctype_base.h" 1 3 ># 36 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/ctype_base.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > struct ctype_base > { > > typedef const int* __to_type; > > > > typedef unsigned short mask; > static const mask upper = _ISupper; > static const mask lower = _ISlower; > static const mask alpha = _ISalpha; > static const mask digit = _ISdigit; > static const mask xdigit = _ISxdigit; > static const mask space = _ISspace; > static const mask print = _ISprint; > static const mask graph = _ISalpha | _ISdigit | _ISpunct; > static const mask cntrl = _IScntrl; > static const mask punct = _ISpunct; > static const mask alnum = _ISalpha | _ISdigit; > }; > > >} ># 42 "/usr/include/c++/4.9.0/bits/locale_facets.h" 2 3 > > > > > > ># 1 "/usr/include/c++/4.9.0/bits/streambuf_iterator.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/streambuf_iterator.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/streambuf_iterator.h" 3 > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 49 "/usr/include/c++/4.9.0/bits/streambuf_iterator.h" 3 > template<typename _CharT, typename _Traits> > class istreambuf_iterator > : public iterator<input_iterator_tag, _CharT, typename _Traits::off_type, > _CharT*, > > > _CharT> > > > > { > public: > > > > typedef _CharT char_type; > typedef _Traits traits_type; > typedef typename _Traits::int_type int_type; > typedef basic_streambuf<_CharT, _Traits> streambuf_type; > typedef basic_istream<_CharT, _Traits> istream_type; > > > template<typename _CharT2> > friend typename __gnu_cxx::__enable_if<__is_char<_CharT2>::__value, > ostreambuf_iterator<_CharT2> >::__type > copy(istreambuf_iterator<_CharT2>, istreambuf_iterator<_CharT2>, > ostreambuf_iterator<_CharT2>); > > template<bool _IsMove, typename _CharT2> > friend typename __gnu_cxx::__enable_if<__is_char<_CharT2>::__value, > _CharT2*>::__type > __copy_move_a2(istreambuf_iterator<_CharT2>, > istreambuf_iterator<_CharT2>, _CharT2*); > > template<typename _CharT2> > friend typename __gnu_cxx::__enable_if<__is_char<_CharT2>::__value, > istreambuf_iterator<_CharT2> >::__type > find(istreambuf_iterator<_CharT2>, istreambuf_iterator<_CharT2>, > const _CharT2&); > > private: > > > > > > > > mutable streambuf_type* _M_sbuf; > mutable int_type _M_c; > > public: > > constexpr istreambuf_iterator() noexcept > : _M_sbuf(0), _M_c(traits_type::eof()) { } > > > istreambuf_iterator(const istreambuf_iterator&) noexcept = default; > > ~istreambuf_iterator() = default; > > > > istreambuf_iterator(istream_type& __s) noexcept > : _M_sbuf(__s.rdbuf()), _M_c(traits_type::eof()) { } > > > istreambuf_iterator(streambuf_type* __s) noexcept > : _M_sbuf(__s), _M_c(traits_type::eof()) { } > > > > > char_type > operator*() const > { > > > > > > > > return traits_type::to_char_type(_M_get()); > } > > > istreambuf_iterator& > operator++() > { > > > ; > if (_M_sbuf) > { > _M_sbuf->sbumpc(); > _M_c = traits_type::eof(); > } > return *this; > } > > > istreambuf_iterator > operator++(int) > { > > > ; > > istreambuf_iterator __old = *this; > if (_M_sbuf) > { > __old._M_c = _M_sbuf->sbumpc(); > _M_c = traits_type::eof(); > } > return __old; > } > > > > > > bool > equal(const istreambuf_iterator& __b) const > { return _M_at_eof() == __b._M_at_eof(); } > > private: > int_type > _M_get() const > { > const int_type __eof = traits_type::eof(); > int_type __ret = __eof; > if (_M_sbuf) > { > if (!traits_type::eq_int_type(_M_c, __eof)) > __ret = _M_c; > else if (!traits_type::eq_int_type((__ret = _M_sbuf->sgetc()), > __eof)) > _M_c = __ret; > else > _M_sbuf = 0; > } > return __ret; > } > > bool > _M_at_eof() const > { > const int_type __eof = traits_type::eof(); > return traits_type::eq_int_type(_M_get(), __eof); > } > }; > > template<typename _CharT, typename _Traits> > inline bool > operator==(const istreambuf_iterator<_CharT, _Traits>& __a, > const istreambuf_iterator<_CharT, _Traits>& __b) > { return __a.equal(__b); } > > template<typename _CharT, typename _Traits> > inline bool > operator!=(const istreambuf_iterator<_CharT, _Traits>& __a, > const istreambuf_iterator<_CharT, _Traits>& __b) > { return !__a.equal(__b); } > > > template<typename _CharT, typename _Traits> > class ostreambuf_iterator > : public iterator<output_iterator_tag, void, void, void, void> > { > public: > > > > typedef _CharT char_type; > typedef _Traits traits_type; > typedef basic_streambuf<_CharT, _Traits> streambuf_type; > typedef basic_ostream<_CharT, _Traits> ostream_type; > > > template<typename _CharT2> > friend typename __gnu_cxx::__enable_if<__is_char<_CharT2>::__value, > ostreambuf_iterator<_CharT2> >::__type > copy(istreambuf_iterator<_CharT2>, istreambuf_iterator<_CharT2>, > ostreambuf_iterator<_CharT2>); > > private: > streambuf_type* _M_sbuf; > bool _M_failed; > > public: > > ostreambuf_iterator(ostream_type& __s) noexcept > : _M_sbuf(__s.rdbuf()), _M_failed(!_M_sbuf) { } > > > ostreambuf_iterator(streambuf_type* __s) noexcept > : _M_sbuf(__s), _M_failed(!_M_sbuf) { } > > > ostreambuf_iterator& > operator=(_CharT __c) > { > if (!_M_failed && > _Traits::eq_int_type(_M_sbuf->sputc(__c), _Traits::eof())) > _M_failed = true; > return *this; > } > > > ostreambuf_iterator& > operator*() > { return *this; } > > > ostreambuf_iterator& > operator++(int) > { return *this; } > > > ostreambuf_iterator& > operator++() > { return *this; } > > > bool > failed() const noexcept > { return _M_failed; } > > ostreambuf_iterator& > _M_put(const _CharT* __ws, streamsize __len) > { > if (__builtin_expect(!_M_failed, true) > && __builtin_expect(this->_M_sbuf->sputn(__ws, __len) != __len, > false)) > _M_failed = true; > return *this; > } > }; > > > template<typename _CharT> > typename __gnu_cxx::__enable_if<__is_char<_CharT>::__value, > ostreambuf_iterator<_CharT> >::__type > copy(istreambuf_iterator<_CharT> __first, > istreambuf_iterator<_CharT> __last, > ostreambuf_iterator<_CharT> __result) > { > if (__first._M_sbuf && !__last._M_sbuf && !__result._M_failed) > { > bool __ineof; > __copy_streambufs_eof(__first._M_sbuf, __result._M_sbuf, __ineof); > if (!__ineof) > __result._M_failed = true; > } > return __result; > } > > template<bool _IsMove, typename _CharT> > typename __gnu_cxx::__enable_if<__is_char<_CharT>::__value, > ostreambuf_iterator<_CharT> >::__type > __copy_move_a2(_CharT* __first, _CharT* __last, > ostreambuf_iterator<_CharT> __result) > { > const streamsize __num = __last - __first; > if (__num > 0) > __result._M_put(__first, __num); > return __result; > } > > template<bool _IsMove, typename _CharT> > typename __gnu_cxx::__enable_if<__is_char<_CharT>::__value, > ostreambuf_iterator<_CharT> >::__type > __copy_move_a2(const _CharT* __first, const _CharT* __last, > ostreambuf_iterator<_CharT> __result) > { > const streamsize __num = __last - __first; > if (__num > 0) > __result._M_put(__first, __num); > return __result; > } > > template<bool _IsMove, typename _CharT> > typename __gnu_cxx::__enable_if<__is_char<_CharT>::__value, > _CharT*>::__type > __copy_move_a2(istreambuf_iterator<_CharT> __first, > istreambuf_iterator<_CharT> __last, _CharT* __result) > { > typedef istreambuf_iterator<_CharT> __is_iterator_type; > typedef typename __is_iterator_type::traits_type traits_type; > typedef typename __is_iterator_type::streambuf_type streambuf_type; > typedef typename traits_type::int_type int_type; > > if (__first._M_sbuf && !__last._M_sbuf) > { > streambuf_type* __sb = __first._M_sbuf; > int_type __c = __sb->sgetc(); > while (!traits_type::eq_int_type(__c, traits_type::eof())) > { > const streamsize __n = __sb->egptr() - __sb->gptr(); > if (__n > 1) > { > traits_type::copy(__result, __sb->gptr(), __n); > __sb->__safe_gbump(__n); > __result += __n; > __c = __sb->underflow(); > } > else > { > *__result++ = traits_type::to_char_type(__c); > __c = __sb->snextc(); > } > } > } > return __result; > } > > template<typename _CharT> > typename __gnu_cxx::__enable_if<__is_char<_CharT>::__value, > istreambuf_iterator<_CharT> >::__type > find(istreambuf_iterator<_CharT> __first, > istreambuf_iterator<_CharT> __last, const _CharT& __val) > { > typedef istreambuf_iterator<_CharT> __is_iterator_type; > typedef typename __is_iterator_type::traits_type traits_type; > typedef typename __is_iterator_type::streambuf_type streambuf_type; > typedef typename traits_type::int_type int_type; > > if (__first._M_sbuf && !__last._M_sbuf) > { > const int_type __ival = traits_type::to_int_type(__val); > streambuf_type* __sb = __first._M_sbuf; > int_type __c = __sb->sgetc(); > while (!traits_type::eq_int_type(__c, traits_type::eof()) > && !traits_type::eq_int_type(__c, __ival)) > { > streamsize __n = __sb->egptr() - __sb->gptr(); > if (__n > 1) > { > const _CharT* __p = traits_type::find(__sb->gptr(), > __n, __val); > if (__p) > __n = __p - __sb->gptr(); > __sb->__safe_gbump(__n); > __c = __sb->sgetc(); > } > else > __c = __sb->snextc(); > } > > if (!traits_type::eq_int_type(__c, traits_type::eof())) > __first._M_c = __c; > else > __first._M_sbuf = 0; > } > return __first; > } > > > > >} ># 49 "/usr/include/c++/4.9.0/bits/locale_facets.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 64 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > template<typename _Tp> > void > __convert_to_v(const char*, _Tp&, ios_base::iostate&, > const __c_locale&) throw(); > > > template<> > void > __convert_to_v(const char*, float&, ios_base::iostate&, > const __c_locale&) throw(); > > template<> > void > __convert_to_v(const char*, double&, ios_base::iostate&, > const __c_locale&) throw(); > > template<> > void > __convert_to_v(const char*, long double&, ios_base::iostate&, > const __c_locale&) throw(); > > > > template<typename _CharT, typename _Traits> > struct __pad > { > static void > _S_pad(ios_base& __io, _CharT __fill, _CharT* __news, > const _CharT* __olds, streamsize __newlen, streamsize __oldlen); > }; > > > > > > > template<typename _CharT> > _CharT* > __add_grouping(_CharT* __s, _CharT __sep, > const char* __gbeg, size_t __gsize, > const _CharT* __first, const _CharT* __last); > > > > > template<typename _CharT> > inline > ostreambuf_iterator<_CharT> > __write(ostreambuf_iterator<_CharT> __s, const _CharT* __ws, int __len) > { > __s._M_put(__ws, __len); > return __s; > } > > > template<typename _CharT, typename _OutIter> > inline > _OutIter > __write(_OutIter __s, const _CharT* __ws, int __len) > { > for (int __j = 0; __j < __len; __j++, ++__s) > *__s = __ws[__j]; > return __s; > } ># 142 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > template<typename _CharT> > class __ctype_abstract_base : public locale::facet, public ctype_base > { > public: > > > typedef _CharT char_type; ># 161 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > bool > is(mask __m, char_type __c) const > { return this->do_is(__m, __c); } ># 178 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char_type* > is(const char_type *__lo, const char_type *__hi, mask *__vec) const > { return this->do_is(__lo, __hi, __vec); } ># 194 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char_type* > scan_is(mask __m, const char_type* __lo, const char_type* __hi) const > { return this->do_scan_is(__m, __lo, __hi); } ># 210 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char_type* > scan_not(mask __m, const char_type* __lo, const char_type* __hi) const > { return this->do_scan_not(__m, __lo, __hi); } ># 224 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char_type > toupper(char_type __c) const > { return this->do_toupper(__c); } ># 239 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char_type* > toupper(char_type *__lo, const char_type* __hi) const > { return this->do_toupper(__lo, __hi); } ># 253 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char_type > tolower(char_type __c) const > { return this->do_tolower(__c); } ># 268 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char_type* > tolower(char_type* __lo, const char_type* __hi) const > { return this->do_tolower(__lo, __hi); } ># 285 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char_type > widen(char __c) const > { return this->do_widen(__c); } ># 304 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char* > widen(const char* __lo, const char* __hi, char_type* __to) const > { return this->do_widen(__lo, __hi, __to); } ># 323 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char > narrow(char_type __c, char __dfault) const > { return this->do_narrow(__c, __dfault); } ># 345 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char_type* > narrow(const char_type* __lo, const char_type* __hi, > char __dfault, char* __to) const > { return this->do_narrow(__lo, __hi, __dfault, __to); } > > protected: > explicit > __ctype_abstract_base(size_t __refs = 0): facet(__refs) { } > > virtual > ~__ctype_abstract_base() { } ># 370 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual bool > do_is(mask __m, char_type __c) const = 0; ># 389 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_is(const char_type* __lo, const char_type* __hi, > mask* __vec) const = 0; ># 408 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_scan_is(mask __m, const char_type* __lo, > const char_type* __hi) const = 0; ># 427 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_scan_not(mask __m, const char_type* __lo, > const char_type* __hi) const = 0; ># 445 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_toupper(char_type __c) const = 0; ># 462 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_toupper(char_type* __lo, const char_type* __hi) const = 0; ># 478 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_tolower(char_type __c) const = 0; ># 495 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_tolower(char_type* __lo, const char_type* __hi) const = 0; ># 514 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_widen(char __c) const = 0; ># 535 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char* > do_widen(const char* __lo, const char* __hi, char_type* __to) const = 0; ># 556 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char > do_narrow(char_type __c, char __dfault) const = 0; ># 581 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_narrow(const char_type* __lo, const char_type* __hi, > char __dfault, char* __to) const = 0; > }; ># 604 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > template<typename _CharT> > class ctype : public __ctype_abstract_base<_CharT> > { > public: > > typedef _CharT char_type; > typedef typename __ctype_abstract_base<_CharT>::mask mask; > > > static locale::id id; > > explicit > ctype(size_t __refs = 0) : __ctype_abstract_base<_CharT>(__refs) { } > > protected: > virtual > ~ctype(); > > virtual bool > do_is(mask __m, char_type __c) const; > > virtual const char_type* > do_is(const char_type* __lo, const char_type* __hi, mask* __vec) const; > > virtual const char_type* > do_scan_is(mask __m, const char_type* __lo, const char_type* __hi) const; > > virtual const char_type* > do_scan_not(mask __m, const char_type* __lo, > const char_type* __hi) const; > > virtual char_type > do_toupper(char_type __c) const; > > virtual const char_type* > do_toupper(char_type* __lo, const char_type* __hi) const; > > virtual char_type > do_tolower(char_type __c) const; > > virtual const char_type* > do_tolower(char_type* __lo, const char_type* __hi) const; > > virtual char_type > do_widen(char __c) const; > > virtual const char* > do_widen(const char* __lo, const char* __hi, char_type* __dest) const; > > virtual char > do_narrow(char_type, char __dfault) const; > > virtual const char_type* > do_narrow(const char_type* __lo, const char_type* __hi, > char __dfault, char* __to) const; > }; > > template<typename _CharT> > locale::id ctype<_CharT>::id; ># 673 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > template<> > class ctype<char> : public locale::facet, public ctype_base > { > public: > > > typedef char char_type; > > protected: > > __c_locale _M_c_locale_ctype; > bool _M_del; > __to_type _M_toupper; > __to_type _M_tolower; > const mask* _M_table; > mutable char _M_widen_ok; > mutable char _M_widen[1 + static_cast<unsigned char>(-1)]; > mutable char _M_narrow[1 + static_cast<unsigned char>(-1)]; > mutable char _M_narrow_ok; > > > public: > > static locale::id id; > > static const size_t table_size = 1 + static_cast<unsigned char>(-1); ># 710 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > explicit > ctype(const mask* __table = 0, bool __del = false, size_t __refs = 0); ># 723 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > explicit > ctype(__c_locale __cloc, const mask* __table = 0, bool __del = false, > size_t __refs = 0); ># 736 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > inline bool > is(mask __m, char __c) const; ># 751 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > inline const char* > is(const char* __lo, const char* __hi, mask* __vec) const; ># 765 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > inline const char* > scan_is(mask __m, const char* __lo, const char* __hi) const; ># 779 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > inline const char* > scan_not(mask __m, const char* __lo, const char* __hi) const; ># 794 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char_type > toupper(char_type __c) const > { return this->do_toupper(__c); } ># 811 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char_type* > toupper(char_type *__lo, const char_type* __hi) const > { return this->do_toupper(__lo, __hi); } ># 827 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char_type > tolower(char_type __c) const > { return this->do_tolower(__c); } ># 844 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char_type* > tolower(char_type* __lo, const char_type* __hi) const > { return this->do_tolower(__lo, __hi); } ># 864 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char_type > widen(char __c) const > { > if (_M_widen_ok) > return _M_widen[static_cast<unsigned char>(__c)]; > this->_M_widen_init(); > return this->do_widen(__c); > } ># 891 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char* > widen(const char* __lo, const char* __hi, char_type* __to) const > { > if (_M_widen_ok == 1) > { > __builtin_memcpy(__to, __lo, __hi - __lo); > return __hi; > } > if (!_M_widen_ok) > _M_widen_init(); > return this->do_widen(__lo, __hi, __to); > } ># 922 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char > narrow(char_type __c, char __dfault) const > { > if (_M_narrow[static_cast<unsigned char>(__c)]) > return _M_narrow[static_cast<unsigned char>(__c)]; > const char __t = do_narrow(__c, __dfault); > if (__t != __dfault) > _M_narrow[static_cast<unsigned char>(__c)] = __t; > return __t; > } ># 955 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > const char_type* > narrow(const char_type* __lo, const char_type* __hi, > char __dfault, char* __to) const > { > if (__builtin_expect(_M_narrow_ok == 1, true)) > { > __builtin_memcpy(__to, __lo, __hi - __lo); > return __hi; > } > if (!_M_narrow_ok) > _M_narrow_init(); > return this->do_narrow(__lo, __hi, __dfault, __to); > } > > > > > > const mask* > table() const throw() > { return _M_table; } > > > static const mask* > classic_table() throw(); > protected: > > > > > > > > virtual > ~ctype(); ># 1004 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_toupper(char_type __c) const; ># 1021 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_toupper(char_type* __lo, const char_type* __hi) const; ># 1037 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_tolower(char_type __c) const; ># 1054 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_tolower(char_type* __lo, const char_type* __hi) const; ># 1074 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_widen(char __c) const > { return __c; } ># 1097 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char* > do_widen(const char* __lo, const char* __hi, char_type* __to) const > { > __builtin_memcpy(__to, __lo, __hi - __lo); > return __hi; > } ># 1123 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char > do_narrow(char_type __c, char __dfault) const > { return __c; } ># 1149 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_narrow(const char_type* __lo, const char_type* __hi, > char __dfault, char* __to) const > { > __builtin_memcpy(__to, __lo, __hi - __lo); > return __hi; > } > > private: > void _M_narrow_init() const; > void _M_widen_init() const; > }; ># 1174 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > template<> > class ctype<wchar_t> : public __ctype_abstract_base<wchar_t> > { > public: > > > typedef wchar_t char_type; > typedef wctype_t __wmask_type; > > protected: > __c_locale _M_c_locale_ctype; > > > bool _M_narrow_ok; > char _M_narrow[128]; > wint_t _M_widen[1 + static_cast<unsigned char>(-1)]; > > > mask _M_bit[16]; > __wmask_type _M_wmask[16]; > > public: > > > static locale::id id; ># 1207 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > explicit > ctype(size_t __refs = 0); ># 1218 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > explicit > ctype(__c_locale __cloc, size_t __refs = 0); > > protected: > __wmask_type > _M_convert_to_wmask(const mask __m) const throw(); > > > virtual > ~ctype(); ># 1242 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual bool > do_is(mask __m, char_type __c) const; ># 1261 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_is(const char_type* __lo, const char_type* __hi, mask* __vec) const; ># 1279 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_scan_is(mask __m, const char_type* __lo, const char_type* __hi) const; ># 1297 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_scan_not(mask __m, const char_type* __lo, > const char_type* __hi) const; ># 1314 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_toupper(char_type __c) const; ># 1331 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_toupper(char_type* __lo, const char_type* __hi) const; ># 1347 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_tolower(char_type __c) const; ># 1364 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_tolower(char_type* __lo, const char_type* __hi) const; ># 1384 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_widen(char __c) const; ># 1406 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char* > do_widen(const char* __lo, const char* __hi, char_type* __to) const; ># 1429 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char > do_narrow(char_type __c, char __dfault) const; ># 1455 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual const char_type* > do_narrow(const char_type* __lo, const char_type* __hi, > char __dfault, char* __to) const; > > > void > _M_initialize_ctype() throw(); > }; > > > > template<typename _CharT> > class ctype_byname : public ctype<_CharT> > { > public: > typedef typename ctype<_CharT>::mask mask; > > explicit > ctype_byname(const char* __s, size_t __refs = 0); > > protected: > virtual > ~ctype_byname() { }; > }; > > > template<> > class ctype_byname<char> : public ctype<char> > { > public: > explicit > ctype_byname(const char* __s, size_t __refs = 0); > > protected: > virtual > ~ctype_byname(); > }; > > > template<> > class ctype_byname<wchar_t> : public ctype<wchar_t> > { > public: > explicit > ctype_byname(const char* __s, size_t __refs = 0); > > protected: > virtual > ~ctype_byname(); > }; > > > >} > > ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/ctype_inline.h" 1 3 ># 37 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/ctype_inline.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > bool > ctype<char>:: > is(mask __m, char __c) const > { return _M_table[static_cast<unsigned char>(__c)] & __m; } > > const char* > ctype<char>:: > is(const char* __low, const char* __high, mask* __vec) const > { > while (__low < __high) > *__vec++ = _M_table[static_cast<unsigned char>(*__low++)]; > return __high; > } > > const char* > ctype<char>:: > scan_is(mask __m, const char* __low, const char* __high) const > { > while (__low < __high > && !(_M_table[static_cast<unsigned char>(*__low)] & __m)) > ++__low; > return __low; > } > > const char* > ctype<char>:: > scan_not(mask __m, const char* __low, const char* __high) const > { > while (__low < __high > && (_M_table[static_cast<unsigned char>(*__low)] & __m) != 0) > ++__low; > return __low; > } > > >} ># 1512 "/usr/include/c++/4.9.0/bits/locale_facets.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > class __num_base > { > public: > > > enum > { > _S_ominus, > _S_oplus, > _S_ox, > _S_oX, > _S_odigits, > _S_odigits_end = _S_odigits + 16, > _S_oudigits = _S_odigits_end, > _S_oudigits_end = _S_oudigits + 16, > _S_oe = _S_odigits + 14, > _S_oE = _S_oudigits + 14, > _S_oend = _S_oudigits_end > }; > > > > > > > static const char* _S_atoms_out; > > > > static const char* _S_atoms_in; > > enum > { > _S_iminus, > _S_iplus, > _S_ix, > _S_iX, > _S_izero, > _S_ie = _S_izero + 14, > _S_iE = _S_izero + 20, > _S_iend = 26 > }; > > > > static void > _S_format_float(const ios_base& __io, char* __fptr, char __mod) throw(); > }; > > template<typename _CharT> > struct __numpunct_cache : public locale::facet > { > const char* _M_grouping; > size_t _M_grouping_size; > bool _M_use_grouping; > const _CharT* _M_truename; > size_t _M_truename_size; > const _CharT* _M_falsename; > size_t _M_falsename_size; > _CharT _M_decimal_point; > _CharT _M_thousands_sep; > > > > > > _CharT _M_atoms_out[__num_base::_S_oend]; > > > > > > _CharT _M_atoms_in[__num_base::_S_iend]; > > bool _M_allocated; > > __numpunct_cache(size_t __refs = 0) > : facet(__refs), _M_grouping(0), _M_grouping_size(0), > _M_use_grouping(false), > _M_truename(0), _M_truename_size(0), _M_falsename(0), > _M_falsename_size(0), _M_decimal_point(_CharT()), > _M_thousands_sep(_CharT()), _M_allocated(false) > { } > > ~__numpunct_cache(); > > void > _M_cache(const locale& __loc); > > private: > __numpunct_cache& > operator=(const __numpunct_cache&); > > explicit > __numpunct_cache(const __numpunct_cache&); > }; > > template<typename _CharT> > __numpunct_cache<_CharT>::~__numpunct_cache() > { > if (_M_allocated) > { > delete [] _M_grouping; > delete [] _M_truename; > delete [] _M_falsename; > } > } ># 1640 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > template<typename _CharT> > class numpunct : public locale::facet > { > public: > > > > typedef _CharT char_type; > typedef basic_string<_CharT> string_type; > > typedef __numpunct_cache<_CharT> __cache_type; > > protected: > __cache_type* _M_data; > > public: > > static locale::id id; > > > > > > > explicit > numpunct(size_t __refs = 0) > : facet(__refs), _M_data(0) > { _M_initialize_numpunct(); } ># 1678 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > explicit > numpunct(__cache_type* __cache, size_t __refs = 0) > : facet(__refs), _M_data(__cache) > { _M_initialize_numpunct(); } ># 1692 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > explicit > numpunct(__c_locale __cloc, size_t __refs = 0) > : facet(__refs), _M_data(0) > { _M_initialize_numpunct(__cloc); } ># 1706 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char_type > decimal_point() const > { return this->do_decimal_point(); } ># 1719 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > char_type > thousands_sep() const > { return this->do_thousands_sep(); } ># 1750 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > string > grouping() const > { return this->do_grouping(); } ># 1763 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > string_type > truename() const > { return this->do_truename(); } ># 1776 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > string_type > falsename() const > { return this->do_falsename(); } > > protected: > > virtual > ~numpunct(); ># 1793 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_decimal_point() const > { return _M_data->_M_decimal_point; } ># 1805 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual char_type > do_thousands_sep() const > { return _M_data->_M_thousands_sep; } ># 1818 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual string > do_grouping() const > { return _M_data->_M_grouping; } ># 1831 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual string_type > do_truename() const > { return _M_data->_M_truename; } ># 1844 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual string_type > do_falsename() const > { return _M_data->_M_falsename; } > > > void > _M_initialize_numpunct(__c_locale __cloc = 0); > }; > > template<typename _CharT> > locale::id numpunct<_CharT>::id; > > template<> > numpunct<char>::~numpunct(); > > template<> > void > numpunct<char>::_M_initialize_numpunct(__c_locale __cloc); > > > template<> > numpunct<wchar_t>::~numpunct(); > > template<> > void > numpunct<wchar_t>::_M_initialize_numpunct(__c_locale __cloc); > > > > template<typename _CharT> > class numpunct_byname : public numpunct<_CharT> > { > public: > typedef _CharT char_type; > typedef basic_string<_CharT> string_type; > > explicit > numpunct_byname(const char* __s, size_t __refs = 0) > : numpunct<_CharT>(__refs) > { > if (__builtin_strcmp(__s, "C") != 0 > && __builtin_strcmp(__s, "POSIX") != 0) > { > __c_locale __tmp; > this->_S_create_c_locale(__tmp, __s); > this->_M_initialize_numpunct(__tmp); > this->_S_destroy_c_locale(__tmp); > } > } > > protected: > virtual > ~numpunct_byname() { } > }; ># 1914 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > template<typename _CharT, typename _InIter> > class num_get : public locale::facet > { > public: > > > > typedef _CharT char_type; > typedef _InIter iter_type; > > > > static locale::id id; ># 1935 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > explicit > num_get(size_t __refs = 0) : facet(__refs) { } ># 1961 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, bool& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } ># 1998 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, long& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } > > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, unsigned short& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } > > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, unsigned int& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } > > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, unsigned long& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } > > > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, long long& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } > > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, unsigned long long& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } ># 2058 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, float& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } > > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, double& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } > > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, long double& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } ># 2101 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > iter_type > get(iter_type __in, iter_type __end, ios_base& __io, > ios_base::iostate& __err, void*& __v) const > { return this->do_get(__in, __end, __io, __err, __v); } > > protected: > > virtual ~num_get() { } > > iter_type > _M_extract_float(iter_type, iter_type, ios_base&, ios_base::iostate&, > string&) const; > > template<typename _ValueT> > iter_type > _M_extract_int(iter_type, iter_type, ios_base&, ios_base::iostate&, > _ValueT&) const; > > template<typename _CharT2> > typename __gnu_cxx::__enable_if<__is_char<_CharT2>::__value, int>::__type > _M_find(const _CharT2*, size_t __len, _CharT2 __c) const > { > int __ret = -1; > if (__len <= 10) > { > if (__c >= _CharT2('0') && __c < _CharT2(_CharT2('0') + __len)) > __ret = __c - _CharT2('0'); > } > else > { > if (__c >= _CharT2('0') && __c <= _CharT2('9')) > __ret = __c - _CharT2('0'); > else if (__c >= _CharT2('a') && __c <= _CharT2('f')) > __ret = 10 + (__c - _CharT2('a')); > else if (__c >= _CharT2('A') && __c <= _CharT2('F')) > __ret = 10 + (__c - _CharT2('A')); > } > return __ret; > } > > template<typename _CharT2> > typename __gnu_cxx::__enable_if<!__is_char<_CharT2>::__value, > int>::__type > _M_find(const _CharT2* __zero, size_t __len, _CharT2 __c) const > { > int __ret = -1; > const char_type* __q = char_traits<_CharT2>::find(__zero, __len, __c); > if (__q) > { > __ret = __q - __zero; > if (__ret > 15) > __ret -= 6; > } > return __ret; > } ># 2172 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual iter_type > do_get(iter_type, iter_type, ios_base&, ios_base::iostate&, bool&) const; > > virtual iter_type > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, long& __v) const > { return _M_extract_int(__beg, __end, __io, __err, __v); } > > virtual iter_type > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, unsigned short& __v) const > { return _M_extract_int(__beg, __end, __io, __err, __v); } > > virtual iter_type > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, unsigned int& __v) const > { return _M_extract_int(__beg, __end, __io, __err, __v); } > > virtual iter_type > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, unsigned long& __v) const > { return _M_extract_int(__beg, __end, __io, __err, __v); } > > > virtual iter_type > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, long long& __v) const > { return _M_extract_int(__beg, __end, __io, __err, __v); } > > virtual iter_type > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, unsigned long long& __v) const > { return _M_extract_int(__beg, __end, __io, __err, __v); } > > > virtual iter_type > do_get(iter_type, iter_type, ios_base&, ios_base::iostate&, float&) const; > > virtual iter_type > do_get(iter_type, iter_type, ios_base&, ios_base::iostate&, > double&) const; > > > > > > > > virtual iter_type > do_get(iter_type, iter_type, ios_base&, ios_base::iostate&, > long double&) const; > > > virtual iter_type > do_get(iter_type, iter_type, ios_base&, ios_base::iostate&, void*&) const; ># 2235 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > }; > > template<typename _CharT, typename _InIter> > locale::id num_get<_CharT, _InIter>::id; ># 2253 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > template<typename _CharT, typename _OutIter> > class num_put : public locale::facet > { > public: > > > > typedef _CharT char_type; > typedef _OutIter iter_type; > > > > static locale::id id; ># 2274 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > explicit > num_put(size_t __refs = 0) : facet(__refs) { } ># 2292 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, bool __v) const > { return this->do_put(__s, __io, __fill, __v); } ># 2334 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, long __v) const > { return this->do_put(__s, __io, __fill, __v); } > > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, > unsigned long __v) const > { return this->do_put(__s, __io, __fill, __v); } > > > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, long long __v) const > { return this->do_put(__s, __io, __fill, __v); } > > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, > unsigned long long __v) const > { return this->do_put(__s, __io, __fill, __v); } ># 2397 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, double __v) const > { return this->do_put(__s, __io, __fill, __v); } > > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, > long double __v) const > { return this->do_put(__s, __io, __fill, __v); } ># 2422 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, > const void* __v) const > { return this->do_put(__s, __io, __fill, __v); } > > protected: > template<typename _ValueT> > iter_type > _M_insert_float(iter_type, ios_base& __io, char_type __fill, > char __mod, _ValueT __v) const; > > void > _M_group_float(const char* __grouping, size_t __grouping_size, > char_type __sep, const char_type* __p, char_type* __new, > char_type* __cs, int& __len) const; > > template<typename _ValueT> > iter_type > _M_insert_int(iter_type, ios_base& __io, char_type __fill, > _ValueT __v) const; > > void > _M_group_int(const char* __grouping, size_t __grouping_size, > char_type __sep, ios_base& __io, char_type* __new, > char_type* __cs, int& __len) const; > > void > _M_pad(char_type __fill, streamsize __w, ios_base& __io, > char_type* __new, const char_type* __cs, int& __len) const; > > > virtual > ~num_put() { }; ># 2470 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > virtual iter_type > do_put(iter_type __s, ios_base& __io, char_type __fill, bool __v) const; > > virtual iter_type > do_put(iter_type __s, ios_base& __io, char_type __fill, long __v) const > { return _M_insert_int(__s, __io, __fill, __v); } > > virtual iter_type > do_put(iter_type __s, ios_base& __io, char_type __fill, > unsigned long __v) const > { return _M_insert_int(__s, __io, __fill, __v); } > > > virtual iter_type > do_put(iter_type __s, ios_base& __io, char_type __fill, > long long __v) const > { return _M_insert_int(__s, __io, __fill, __v); } > > virtual iter_type > do_put(iter_type __s, ios_base& __io, char_type __fill, > unsigned long long __v) const > { return _M_insert_int(__s, __io, __fill, __v); } > > > virtual iter_type > do_put(iter_type, ios_base&, char_type, double) const; > > > > > > > virtual iter_type > do_put(iter_type, ios_base&, char_type, long double) const; > > > virtual iter_type > do_put(iter_type, ios_base&, char_type, const void*) const; > > > > > > > > }; > > template <typename _CharT, typename _OutIter> > locale::id num_put<_CharT, _OutIter>::id; ># 2528 "/usr/include/c++/4.9.0/bits/locale_facets.h" 3 > template<typename _CharT> > inline bool > isspace(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::space, __c); } > > > template<typename _CharT> > inline bool > isprint(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::print, __c); } > > > template<typename _CharT> > inline bool > iscntrl(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::cntrl, __c); } > > > template<typename _CharT> > inline bool > isupper(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::upper, __c); } > > > template<typename _CharT> > inline bool > islower(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::lower, __c); } > > > template<typename _CharT> > inline bool > isalpha(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::alpha, __c); } > > > template<typename _CharT> > inline bool > isdigit(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::digit, __c); } > > > template<typename _CharT> > inline bool > ispunct(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::punct, __c); } > > > template<typename _CharT> > inline bool > isxdigit(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::xdigit, __c); } > > > template<typename _CharT> > inline bool > isalnum(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::alnum, __c); } > > > template<typename _CharT> > inline bool > isgraph(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).is(ctype_base::graph, __c); } > > > template<typename _CharT> > inline _CharT > toupper(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).toupper(__c); } > > > template<typename _CharT> > inline _CharT > tolower(_CharT __c, const locale& __loc) > { return use_facet<ctype<_CharT> >(__loc).tolower(__c); } > > >} > ># 1 "/usr/include/c++/4.9.0/bits/locale_facets.tcc" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/locale_facets.tcc" 3 ># 34 "/usr/include/c++/4.9.0/bits/locale_facets.tcc" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > template<typename _Facet> > struct __use_cache > { > const _Facet* > operator() (const locale& __loc) const; > }; > > > template<typename _CharT> > struct __use_cache<__numpunct_cache<_CharT> > > { > const __numpunct_cache<_CharT>* > operator() (const locale& __loc) const > { > const size_t __i = numpunct<_CharT>::id._M_id(); > const locale::facet** __caches = __loc._M_impl->_M_caches; > if (!__caches[__i]) > { > __numpunct_cache<_CharT>* __tmp = 0; > try > { > __tmp = new __numpunct_cache<_CharT>; > __tmp->_M_cache(__loc); > } > catch(...) > { > delete __tmp; > throw; > } > __loc._M_impl->_M_install_cache(__tmp, __i); > } > return static_cast<const __numpunct_cache<_CharT>*>(__caches[__i]); > } > }; > > template<typename _CharT> > void > __numpunct_cache<_CharT>::_M_cache(const locale& __loc) > { > _M_allocated = true; > > const numpunct<_CharT>& __np = use_facet<numpunct<_CharT> >(__loc); > > char* __grouping = 0; > _CharT* __truename = 0; > _CharT* __falsename = 0; > try > { > _M_grouping_size = __np.grouping().size(); > __grouping = new char[_M_grouping_size]; > __np.grouping().copy(__grouping, _M_grouping_size); > _M_grouping = __grouping; > _M_use_grouping = (_M_grouping_size > && static_cast<signed char>(_M_grouping[0]) > 0 > && (_M_grouping[0] > != __gnu_cxx::__numeric_traits<char>::__max)); > > _M_truename_size = __np.truename().size(); > __truename = new _CharT[_M_truename_size]; > __np.truename().copy(__truename, _M_truename_size); > _M_truename = __truename; > > _M_falsename_size = __np.falsename().size(); > __falsename = new _CharT[_M_falsename_size]; > __np.falsename().copy(__falsename, _M_falsename_size); > _M_falsename = __falsename; > > _M_decimal_point = __np.decimal_point(); > _M_thousands_sep = __np.thousands_sep(); > > const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__loc); > __ct.widen(__num_base::_S_atoms_out, > __num_base::_S_atoms_out > + __num_base::_S_oend, _M_atoms_out); > __ct.widen(__num_base::_S_atoms_in, > __num_base::_S_atoms_in > + __num_base::_S_iend, _M_atoms_in); > } > catch(...) > { > delete [] __grouping; > delete [] __truename; > delete [] __falsename; > throw; > } > } ># 136 "/usr/include/c++/4.9.0/bits/locale_facets.tcc" 3 > __attribute__ ((__pure__)) bool > __verify_grouping(const char* __grouping, size_t __grouping_size, > const string& __grouping_tmp) throw (); > > > > template<typename _CharT, typename _InIter> > _InIter > num_get<_CharT, _InIter>:: > _M_extract_float(_InIter __beg, _InIter __end, ios_base& __io, > ios_base::iostate& __err, string& __xtrc) const > { > typedef char_traits<_CharT> __traits_type; > typedef __numpunct_cache<_CharT> __cache_type; > __use_cache<__cache_type> __uc; > const locale& __loc = __io._M_getloc(); > const __cache_type* __lc = __uc(__loc); > const _CharT* __lit = __lc->_M_atoms_in; > char_type __c = char_type(); > > > bool __testeof = __beg == __end; > > > if (!__testeof) > { > __c = *__beg; > const bool __plus = __c == __lit[__num_base::_S_iplus]; > if ((__plus || __c == __lit[__num_base::_S_iminus]) > && !(__lc->_M_use_grouping && __c == __lc->_M_thousands_sep) > && !(__c == __lc->_M_decimal_point)) > { > __xtrc += __plus ? '+' : '-'; > if (++__beg != __end) > __c = *__beg; > else > __testeof = true; > } > } > > > bool __found_mantissa = false; > int __sep_pos = 0; > while (!__testeof) > { > if ((__lc->_M_use_grouping && __c == __lc->_M_thousands_sep) > || __c == __lc->_M_decimal_point) > break; > else if (__c == __lit[__num_base::_S_izero]) > { > if (!__found_mantissa) > { > __xtrc += '0'; > __found_mantissa = true; > } > ++__sep_pos; > > if (++__beg != __end) > __c = *__beg; > else > __testeof = true; > } > else > break; > } > > > bool __found_dec = false; > bool __found_sci = false; > string __found_grouping; > if (__lc->_M_use_grouping) > __found_grouping.reserve(32); > const char_type* __lit_zero = __lit + __num_base::_S_izero; > > if (!__lc->_M_allocated) > > while (!__testeof) > { > const int __digit = _M_find(__lit_zero, 10, __c); > if (__digit != -1) > { > __xtrc += '0' + __digit; > __found_mantissa = true; > } > else if (__c == __lc->_M_decimal_point > && !__found_dec && !__found_sci) > { > __xtrc += '.'; > __found_dec = true; > } > else if ((__c == __lit[__num_base::_S_ie] > || __c == __lit[__num_base::_S_iE]) > && !__found_sci && __found_mantissa) > { > > __xtrc += 'e'; > __found_sci = true; > > > if (++__beg != __end) > { > __c = *__beg; > const bool __plus = __c == __lit[__num_base::_S_iplus]; > if (__plus || __c == __lit[__num_base::_S_iminus]) > __xtrc += __plus ? '+' : '-'; > else > continue; > } > else > { > __testeof = true; > break; > } > } > else > break; > > if (++__beg != __end) > __c = *__beg; > else > __testeof = true; > } > else > while (!__testeof) > { > > > if (__lc->_M_use_grouping && __c == __lc->_M_thousands_sep) > { > if (!__found_dec && !__found_sci) > { > > > if (__sep_pos) > { > __found_grouping += static_cast<char>(__sep_pos); > __sep_pos = 0; > } > else > { > > > __xtrc.clear(); > break; > } > } > else > break; > } > else if (__c == __lc->_M_decimal_point) > { > if (!__found_dec && !__found_sci) > { > > > > if (__found_grouping.size()) > __found_grouping += static_cast<char>(__sep_pos); > __xtrc += '.'; > __found_dec = true; > } > else > break; > } > else > { > const char_type* __q = > __traits_type::find(__lit_zero, 10, __c); > if (__q) > { > __xtrc += '0' + (__q - __lit_zero); > __found_mantissa = true; > ++__sep_pos; > } > else if ((__c == __lit[__num_base::_S_ie] > || __c == __lit[__num_base::_S_iE]) > && !__found_sci && __found_mantissa) > { > > if (__found_grouping.size() && !__found_dec) > __found_grouping += static_cast<char>(__sep_pos); > __xtrc += 'e'; > __found_sci = true; > > > if (++__beg != __end) > { > __c = *__beg; > const bool __plus = __c == __lit[__num_base::_S_iplus]; > if ((__plus || __c == __lit[__num_base::_S_iminus]) > && !(__lc->_M_use_grouping > && __c == __lc->_M_thousands_sep) > && !(__c == __lc->_M_decimal_point)) > __xtrc += __plus ? '+' : '-'; > else > continue; > } > else > { > __testeof = true; > break; > } > } > else > break; > } > > if (++__beg != __end) > __c = *__beg; > else > __testeof = true; > } > > > > if (__found_grouping.size()) > { > > if (!__found_dec && !__found_sci) > __found_grouping += static_cast<char>(__sep_pos); > > if (!std::__verify_grouping(__lc->_M_grouping, > __lc->_M_grouping_size, > __found_grouping)) > __err = ios_base::failbit; > } > > return __beg; > } > > template<typename _CharT, typename _InIter> > template<typename _ValueT> > _InIter > num_get<_CharT, _InIter>:: > _M_extract_int(_InIter __beg, _InIter __end, ios_base& __io, > ios_base::iostate& __err, _ValueT& __v) const > { > typedef char_traits<_CharT> __traits_type; > using __gnu_cxx::__add_unsigned; > typedef typename __add_unsigned<_ValueT>::__type __unsigned_type; > typedef __numpunct_cache<_CharT> __cache_type; > __use_cache<__cache_type> __uc; > const locale& __loc = __io._M_getloc(); > const __cache_type* __lc = __uc(__loc); > const _CharT* __lit = __lc->_M_atoms_in; > char_type __c = char_type(); > > > const ios_base::fmtflags __basefield = __io.flags() > & ios_base::basefield; > const bool __oct = __basefield == ios_base::oct; > int __base = __oct ? 8 : (__basefield == ios_base::hex ? 16 : 10); > > > bool __testeof = __beg == __end; > > > bool __negative = false; > if (!__testeof) > { > __c = *__beg; > __negative = __c == __lit[__num_base::_S_iminus]; > if ((__negative || __c == __lit[__num_base::_S_iplus]) > && !(__lc->_M_use_grouping && __c == __lc->_M_thousands_sep) > && !(__c == __lc->_M_decimal_point)) > { > if (++__beg != __end) > __c = *__beg; > else > __testeof = true; > } > } > > > > bool __found_zero = false; > int __sep_pos = 0; > while (!__testeof) > { > if ((__lc->_M_use_grouping && __c == __lc->_M_thousands_sep) > || __c == __lc->_M_decimal_point) > break; > else if (__c == __lit[__num_base::_S_izero] > && (!__found_zero || __base == 10)) > { > __found_zero = true; > ++__sep_pos; > if (__basefield == 0) > __base = 8; > if (__base == 8) > __sep_pos = 0; > } > else if (__found_zero > && (__c == __lit[__num_base::_S_ix] > || __c == __lit[__num_base::_S_iX])) > { > if (__basefield == 0) > __base = 16; > if (__base == 16) > { > __found_zero = false; > __sep_pos = 0; > } > else > break; > } > else > break; > > if (++__beg != __end) > { > __c = *__beg; > if (!__found_zero) > break; > } > else > __testeof = true; > } > > > > const size_t __len = (__base == 16 ? __num_base::_S_iend > - __num_base::_S_izero : __base); > > > string __found_grouping; > if (__lc->_M_use_grouping) > __found_grouping.reserve(32); > bool __testfail = false; > bool __testoverflow = false; > const __unsigned_type __max = > (__negative && __gnu_cxx::__numeric_traits<_ValueT>::__is_signed) > ? -__gnu_cxx::__numeric_traits<_ValueT>::__min > : __gnu_cxx::__numeric_traits<_ValueT>::__max; > const __unsigned_type __smax = __max / __base; > __unsigned_type __result = 0; > int __digit = 0; > const char_type* __lit_zero = __lit + __num_base::_S_izero; > > if (!__lc->_M_allocated) > > while (!__testeof) > { > __digit = _M_find(__lit_zero, __len, __c); > if (__digit == -1) > break; > > if (__result > __smax) > __testoverflow = true; > else > { > __result *= __base; > __testoverflow |= __result > __max - __digit; > __result += __digit; > ++__sep_pos; > } > > if (++__beg != __end) > __c = *__beg; > else > __testeof = true; > } > else > while (!__testeof) > { > > > if (__lc->_M_use_grouping && __c == __lc->_M_thousands_sep) > { > > > if (__sep_pos) > { > __found_grouping += static_cast<char>(__sep_pos); > __sep_pos = 0; > } > else > { > __testfail = true; > break; > } > } > else if (__c == __lc->_M_decimal_point) > break; > else > { > const char_type* __q = > __traits_type::find(__lit_zero, __len, __c); > if (!__q) > break; > > __digit = __q - __lit_zero; > if (__digit > 15) > __digit -= 6; > if (__result > __smax) > __testoverflow = true; > else > { > __result *= __base; > __testoverflow |= __result > __max - __digit; > __result += __digit; > ++__sep_pos; > } > } > > if (++__beg != __end) > __c = *__beg; > else > __testeof = true; > } > > > > if (__found_grouping.size()) > { > > __found_grouping += static_cast<char>(__sep_pos); > > if (!std::__verify_grouping(__lc->_M_grouping, > __lc->_M_grouping_size, > __found_grouping)) > __err = ios_base::failbit; > } > > > > if ((!__sep_pos && !__found_zero && !__found_grouping.size()) > || __testfail) > { > __v = 0; > __err = ios_base::failbit; > } > else if (__testoverflow) > { > if (__negative > && __gnu_cxx::__numeric_traits<_ValueT>::__is_signed) > __v = __gnu_cxx::__numeric_traits<_ValueT>::__min; > else > __v = __gnu_cxx::__numeric_traits<_ValueT>::__max; > __err = ios_base::failbit; > } > else > __v = __negative ? -__result : __result; > > if (__testeof) > __err |= ios_base::eofbit; > return __beg; > } > > > > template<typename _CharT, typename _InIter> > _InIter > num_get<_CharT, _InIter>:: > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, bool& __v) const > { > if (!(__io.flags() & ios_base::boolalpha)) > { > > > > long __l = -1; > __beg = _M_extract_int(__beg, __end, __io, __err, __l); > if (__l == 0 || __l == 1) > __v = bool(__l); > else > { > > > __v = true; > __err = ios_base::failbit; > if (__beg == __end) > __err |= ios_base::eofbit; > } > } > else > { > > typedef __numpunct_cache<_CharT> __cache_type; > __use_cache<__cache_type> __uc; > const locale& __loc = __io._M_getloc(); > const __cache_type* __lc = __uc(__loc); > > bool __testf = true; > bool __testt = true; > bool __donef = __lc->_M_falsename_size == 0; > bool __donet = __lc->_M_truename_size == 0; > bool __testeof = false; > size_t __n = 0; > while (!__donef || !__donet) > { > if (__beg == __end) > { > __testeof = true; > break; > } > > const char_type __c = *__beg; > > if (!__donef) > __testf = __c == __lc->_M_falsename[__n]; > > if (!__testf && __donet) > break; > > if (!__donet) > __testt = __c == __lc->_M_truename[__n]; > > if (!__testt && __donef) > break; > > if (!__testt && !__testf) > break; > > ++__n; > ++__beg; > > __donef = !__testf || __n >= __lc->_M_falsename_size; > __donet = !__testt || __n >= __lc->_M_truename_size; > } > if (__testf && __n == __lc->_M_falsename_size && __n) > { > __v = false; > if (__testt && __n == __lc->_M_truename_size) > __err = ios_base::failbit; > else > __err = __testeof ? ios_base::eofbit : ios_base::goodbit; > } > else if (__testt && __n == __lc->_M_truename_size && __n) > { > __v = true; > __err = __testeof ? ios_base::eofbit : ios_base::goodbit; > } > else > { > > > __v = false; > __err = ios_base::failbit; > if (__testeof) > __err |= ios_base::eofbit; > } > } > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > num_get<_CharT, _InIter>:: > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, float& __v) const > { > string __xtrc; > __xtrc.reserve(32); > __beg = _M_extract_float(__beg, __end, __io, __err, __xtrc); > std::__convert_to_v(__xtrc.c_str(), __v, __err, _S_get_c_locale()); > if (__beg == __end) > __err |= ios_base::eofbit; > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > num_get<_CharT, _InIter>:: > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, double& __v) const > { > string __xtrc; > __xtrc.reserve(32); > __beg = _M_extract_float(__beg, __end, __io, __err, __xtrc); > std::__convert_to_v(__xtrc.c_str(), __v, __err, _S_get_c_locale()); > if (__beg == __end) > __err |= ios_base::eofbit; > return __beg; > } ># 730 "/usr/include/c++/4.9.0/bits/locale_facets.tcc" 3 > template<typename _CharT, typename _InIter> > _InIter > num_get<_CharT, _InIter>:: > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, long double& __v) const > { > string __xtrc; > __xtrc.reserve(32); > __beg = _M_extract_float(__beg, __end, __io, __err, __xtrc); > std::__convert_to_v(__xtrc.c_str(), __v, __err, _S_get_c_locale()); > if (__beg == __end) > __err |= ios_base::eofbit; > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > num_get<_CharT, _InIter>:: > do_get(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, void*& __v) const > { > > typedef ios_base::fmtflags fmtflags; > const fmtflags __fmt = __io.flags(); > __io.flags((__fmt & ~ios_base::basefield) | ios_base::hex); > > typedef __gnu_cxx::__conditional_type<(sizeof(void*) > <= sizeof(unsigned long)), > unsigned long, unsigned long long>::__type _UIntPtrType; > > _UIntPtrType __ul; > __beg = _M_extract_int(__beg, __end, __io, __err, __ul); > > > __io.flags(__fmt); > > __v = reinterpret_cast<void*>(__ul); > return __beg; > } > > > > template<typename _CharT, typename _OutIter> > void > num_put<_CharT, _OutIter>:: > _M_pad(_CharT __fill, streamsize __w, ios_base& __io, > _CharT* __new, const _CharT* __cs, int& __len) const > { > > > __pad<_CharT, char_traits<_CharT> >::_S_pad(__io, __fill, __new, > __cs, __w, __len); > __len = static_cast<int>(__w); > } > > > > template<typename _CharT, typename _ValueT> > int > __int_to_char(_CharT* __bufend, _ValueT __v, const _CharT* __lit, > ios_base::fmtflags __flags, bool __dec) > { > _CharT* __buf = __bufend; > if (__builtin_expect(__dec, true)) > { > > do > { > *--__buf = __lit[(__v % 10) + __num_base::_S_odigits]; > __v /= 10; > } > while (__v != 0); > } > else if ((__flags & ios_base::basefield) == ios_base::oct) > { > > do > { > *--__buf = __lit[(__v & 0x7) + __num_base::_S_odigits]; > __v >>= 3; > } > while (__v != 0); > } > else > { > > const bool __uppercase = __flags & ios_base::uppercase; > const int __case_offset = __uppercase ? __num_base::_S_oudigits > : __num_base::_S_odigits; > do > { > *--__buf = __lit[(__v & 0xf) + __case_offset]; > __v >>= 4; > } > while (__v != 0); > } > return __bufend - __buf; > } > > > > template<typename _CharT, typename _OutIter> > void > num_put<_CharT, _OutIter>:: > _M_group_int(const char* __grouping, size_t __grouping_size, _CharT __sep, > ios_base&, _CharT* __new, _CharT* __cs, int& __len) const > { > _CharT* __p = std::__add_grouping(__new, __sep, __grouping, > __grouping_size, __cs, __cs + __len); > __len = __p - __new; > } > > template<typename _CharT, typename _OutIter> > template<typename _ValueT> > _OutIter > num_put<_CharT, _OutIter>:: > _M_insert_int(_OutIter __s, ios_base& __io, _CharT __fill, > _ValueT __v) const > { > using __gnu_cxx::__add_unsigned; > typedef typename __add_unsigned<_ValueT>::__type __unsigned_type; > typedef __numpunct_cache<_CharT> __cache_type; > __use_cache<__cache_type> __uc; > const locale& __loc = __io._M_getloc(); > const __cache_type* __lc = __uc(__loc); > const _CharT* __lit = __lc->_M_atoms_out; > const ios_base::fmtflags __flags = __io.flags(); > > > const int __ilen = 5 * sizeof(_ValueT); > _CharT* __cs = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT) > * __ilen)); > > > > const ios_base::fmtflags __basefield = __flags & ios_base::basefield; > const bool __dec = (__basefield != ios_base::oct > && __basefield != ios_base::hex); > const __unsigned_type __u = ((__v > 0 || !__dec) > ? __unsigned_type(__v) > : -__unsigned_type(__v)); > int __len = __int_to_char(__cs + __ilen, __u, __lit, __flags, __dec); > __cs += __ilen - __len; > > > if (__lc->_M_use_grouping) > { > > > _CharT* __cs2 = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT) > * (__len + 1) > * 2)); > _M_group_int(__lc->_M_grouping, __lc->_M_grouping_size, > __lc->_M_thousands_sep, __io, __cs2 + 2, __cs, __len); > __cs = __cs2 + 2; > } > > > if (__builtin_expect(__dec, true)) > { > > if (__v >= 0) > { > if (bool(__flags & ios_base::showpos) > && __gnu_cxx::__numeric_traits<_ValueT>::__is_signed) > *--__cs = __lit[__num_base::_S_oplus], ++__len; > } > else > *--__cs = __lit[__num_base::_S_ominus], ++__len; > } > else if (bool(__flags & ios_base::showbase) && __v) > { > if (__basefield == ios_base::oct) > *--__cs = __lit[__num_base::_S_odigits], ++__len; > else > { > > const bool __uppercase = __flags & ios_base::uppercase; > *--__cs = __lit[__num_base::_S_ox + __uppercase]; > > *--__cs = __lit[__num_base::_S_odigits]; > __len += 2; > } > } > > > const streamsize __w = __io.width(); > if (__w > static_cast<streamsize>(__len)) > { > _CharT* __cs3 = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT) > * __w)); > _M_pad(__fill, __w, __io, __cs3, __cs, __len); > __cs = __cs3; > } > __io.width(0); > > > > return std::__write(__s, __cs, __len); > } > > template<typename _CharT, typename _OutIter> > void > num_put<_CharT, _OutIter>:: > _M_group_float(const char* __grouping, size_t __grouping_size, > _CharT __sep, const _CharT* __p, _CharT* __new, > _CharT* __cs, int& __len) const > { > > > > const int __declen = __p ? __p - __cs : __len; > _CharT* __p2 = std::__add_grouping(__new, __sep, __grouping, > __grouping_size, > __cs, __cs + __declen); > > > int __newlen = __p2 - __new; > if (__p) > { > char_traits<_CharT>::copy(__p2, __p, __len - __declen); > __newlen += __len - __declen; > } > __len = __newlen; > } ># 966 "/usr/include/c++/4.9.0/bits/locale_facets.tcc" 3 > template<typename _CharT, typename _OutIter> > template<typename _ValueT> > _OutIter > num_put<_CharT, _OutIter>:: > _M_insert_float(_OutIter __s, ios_base& __io, _CharT __fill, char __mod, > _ValueT __v) const > { > typedef __numpunct_cache<_CharT> __cache_type; > __use_cache<__cache_type> __uc; > const locale& __loc = __io._M_getloc(); > const __cache_type* __lc = __uc(__loc); > > > const streamsize __prec = __io.precision() < 0 ? 6 : __io.precision(); > > const int __max_digits = > __gnu_cxx::__numeric_traits<_ValueT>::__digits10; > > > int __len; > > char __fbuf[16]; > __num_base::_S_format_float(__io, __fbuf, __mod); > > > > > int __cs_size = __max_digits * 3; > char* __cs = static_cast<char*>(__builtin_alloca(__cs_size)); > __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size, > __fbuf, __prec, __v); > > > if (__len >= __cs_size) > { > __cs_size = __len + 1; > __cs = static_cast<char*>(__builtin_alloca(__cs_size)); > __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size, > __fbuf, __prec, __v); > } ># 1027 "/usr/include/c++/4.9.0/bits/locale_facets.tcc" 3 > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > > _CharT* __ws = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT) > * __len)); > __ctype.widen(__cs, __cs + __len, __ws); > > > _CharT* __wp = 0; > const char* __p = char_traits<char>::find(__cs, __len, '.'); > if (__p) > { > __wp = __ws + (__p - __cs); > *__wp = __lc->_M_decimal_point; > } > > > > > if (__lc->_M_use_grouping > && (__wp || __len < 3 || (__cs[1] <= '9' && __cs[2] <= '9' > && __cs[1] >= '0' && __cs[2] >= '0'))) > { > > > _CharT* __ws2 = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT) > * __len * 2)); > > streamsize __off = 0; > if (__cs[0] == '-' || __cs[0] == '+') > { > __off = 1; > __ws2[0] = __ws[0]; > __len -= 1; > } > > _M_group_float(__lc->_M_grouping, __lc->_M_grouping_size, > __lc->_M_thousands_sep, __wp, __ws2 + __off, > __ws + __off, __len); > __len += __off; > > __ws = __ws2; > } > > > const streamsize __w = __io.width(); > if (__w > static_cast<streamsize>(__len)) > { > _CharT* __ws3 = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT) > * __w)); > _M_pad(__fill, __w, __io, __ws3, __ws, __len); > __ws = __ws3; > } > __io.width(0); > > > > return std::__write(__s, __ws, __len); > } > > template<typename _CharT, typename _OutIter> > _OutIter > num_put<_CharT, _OutIter>:: > do_put(iter_type __s, ios_base& __io, char_type __fill, bool __v) const > { > const ios_base::fmtflags __flags = __io.flags(); > if ((__flags & ios_base::boolalpha) == 0) > { > const long __l = __v; > __s = _M_insert_int(__s, __io, __fill, __l); > } > else > { > typedef __numpunct_cache<_CharT> __cache_type; > __use_cache<__cache_type> __uc; > const locale& __loc = __io._M_getloc(); > const __cache_type* __lc = __uc(__loc); > > const _CharT* __name = __v ? __lc->_M_truename > : __lc->_M_falsename; > int __len = __v ? __lc->_M_truename_size > : __lc->_M_falsename_size; > > const streamsize __w = __io.width(); > if (__w > static_cast<streamsize>(__len)) > { > const streamsize __plen = __w - __len; > _CharT* __ps > = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT) > * __plen)); > > char_traits<_CharT>::assign(__ps, __plen, __fill); > __io.width(0); > > if ((__flags & ios_base::adjustfield) == ios_base::left) > { > __s = std::__write(__s, __name, __len); > __s = std::__write(__s, __ps, __plen); > } > else > { > __s = std::__write(__s, __ps, __plen); > __s = std::__write(__s, __name, __len); > } > return __s; > } > __io.width(0); > __s = std::__write(__s, __name, __len); > } > return __s; > } > > template<typename _CharT, typename _OutIter> > _OutIter > num_put<_CharT, _OutIter>:: > do_put(iter_type __s, ios_base& __io, char_type __fill, double __v) const > { return _M_insert_float(__s, __io, __fill, char(), __v); } ># 1152 "/usr/include/c++/4.9.0/bits/locale_facets.tcc" 3 > template<typename _CharT, typename _OutIter> > _OutIter > num_put<_CharT, _OutIter>:: > do_put(iter_type __s, ios_base& __io, char_type __fill, > long double __v) const > { return _M_insert_float(__s, __io, __fill, 'L', __v); } > > template<typename _CharT, typename _OutIter> > _OutIter > num_put<_CharT, _OutIter>:: > do_put(iter_type __s, ios_base& __io, char_type __fill, > const void* __v) const > { > const ios_base::fmtflags __flags = __io.flags(); > const ios_base::fmtflags __fmt = ~(ios_base::basefield > | ios_base::uppercase); > __io.flags((__flags & __fmt) | (ios_base::hex | ios_base::showbase)); > > typedef __gnu_cxx::__conditional_type<(sizeof(const void*) > <= sizeof(unsigned long)), > unsigned long, unsigned long long>::__type _UIntPtrType; > > __s = _M_insert_int(__s, __io, __fill, > reinterpret_cast<_UIntPtrType>(__v)); > __io.flags(__flags); > return __s; > } ># 1189 "/usr/include/c++/4.9.0/bits/locale_facets.tcc" 3 > template<typename _CharT, typename _Traits> > void > __pad<_CharT, _Traits>::_S_pad(ios_base& __io, _CharT __fill, > _CharT* __news, const _CharT* __olds, > streamsize __newlen, streamsize __oldlen) > { > const size_t __plen = static_cast<size_t>(__newlen - __oldlen); > const ios_base::fmtflags __adjust = __io.flags() & ios_base::adjustfield; > > > if (__adjust == ios_base::left) > { > _Traits::copy(__news, __olds, __oldlen); > _Traits::assign(__news + __oldlen, __plen, __fill); > return; > } > > size_t __mod = 0; > if (__adjust == ios_base::internal) > { > > > > const locale& __loc = __io._M_getloc(); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > > if (__ctype.widen('-') == __olds[0] > || __ctype.widen('+') == __olds[0]) > { > __news[0] = __olds[0]; > __mod = 1; > ++__news; > } > else if (__ctype.widen('0') == __olds[0] > && __oldlen > 1 > && (__ctype.widen('x') == __olds[1] > || __ctype.widen('X') == __olds[1])) > { > __news[0] = __olds[0]; > __news[1] = __olds[1]; > __mod = 2; > __news += 2; > } > > } > _Traits::assign(__news, __plen, __fill); > _Traits::copy(__news + __plen, __olds + __mod, __oldlen - __mod); > } > > template<typename _CharT> > _CharT* > __add_grouping(_CharT* __s, _CharT __sep, > const char* __gbeg, size_t __gsize, > const _CharT* __first, const _CharT* __last) > { > size_t __idx = 0; > size_t __ctr = 0; > > while (__last - __first > __gbeg[__idx] > && static_cast<signed char>(__gbeg[__idx]) > 0 > && __gbeg[__idx] != __gnu_cxx::__numeric_traits<char>::__max) > { > __last -= __gbeg[__idx]; > __idx < __gsize - 1 ? ++__idx : ++__ctr; > } > > while (__first != __last) > *__s++ = *__first++; > > while (__ctr--) > { > *__s++ = __sep; > for (char __i = __gbeg[__idx]; __i > 0; --__i) > *__s++ = *__first++; > } > > while (__idx--) > { > *__s++ = __sep; > for (char __i = __gbeg[__idx]; __i > 0; --__i) > *__s++ = *__first++; > } > > return __s; > } > > > > > extern template class numpunct<char>; > extern template class numpunct_byname<char>; > extern template class num_get<char>; > extern template class num_put<char>; > extern template class ctype_byname<char>; > > extern template > const ctype<char>& > use_facet<ctype<char> >(const locale&); > > extern template > const numpunct<char>& > use_facet<numpunct<char> >(const locale&); > > extern template > const num_put<char>& > use_facet<num_put<char> >(const locale&); > > extern template > const num_get<char>& > use_facet<num_get<char> >(const locale&); > > extern template > bool > has_facet<ctype<char> >(const locale&); > > extern template > bool > has_facet<numpunct<char> >(const locale&); > > extern template > bool > has_facet<num_put<char> >(const locale&); > > extern template > bool > has_facet<num_get<char> >(const locale&); > > > extern template class numpunct<wchar_t>; > extern template class numpunct_byname<wchar_t>; > extern template class num_get<wchar_t>; > extern template class num_put<wchar_t>; > extern template class ctype_byname<wchar_t>; > > extern template > const ctype<wchar_t>& > use_facet<ctype<wchar_t> >(const locale&); > > extern template > const numpunct<wchar_t>& > use_facet<numpunct<wchar_t> >(const locale&); > > extern template > const num_put<wchar_t>& > use_facet<num_put<wchar_t> >(const locale&); > > extern template > const num_get<wchar_t>& > use_facet<num_get<wchar_t> >(const locale&); > > extern template > bool > has_facet<ctype<wchar_t> >(const locale&); > > extern template > bool > has_facet<numpunct<wchar_t> >(const locale&); > > extern template > bool > has_facet<num_put<wchar_t> >(const locale&); > > extern template > bool > has_facet<num_get<wchar_t> >(const locale&); > > > > >} ># 2609 "/usr/include/c++/4.9.0/bits/locale_facets.h" 2 3 ># 38 "/usr/include/c++/4.9.0/bits/basic_ios.h" 2 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Facet> > inline const _Facet& > __check_facet(const _Facet* __f) > { > if (!__f) > __throw_bad_cast(); > return *__f; > } ># 65 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > template<typename _CharT, typename _Traits> > class basic_ios : public ios_base > { > public: > > > > > > > typedef _CharT char_type; > typedef typename _Traits::int_type int_type; > typedef typename _Traits::pos_type pos_type; > typedef typename _Traits::off_type off_type; > typedef _Traits traits_type; > > > > > > > typedef ctype<_CharT> __ctype_type; > typedef num_put<_CharT, ostreambuf_iterator<_CharT, _Traits> > > __num_put_type; > typedef num_get<_CharT, istreambuf_iterator<_CharT, _Traits> > > __num_get_type; > > > > protected: > basic_ostream<_CharT, _Traits>* _M_tie; > mutable char_type _M_fill; > mutable bool _M_fill_init; > basic_streambuf<_CharT, _Traits>* _M_streambuf; > > > const __ctype_type* _M_ctype; > > const __num_put_type* _M_num_put; > > const __num_get_type* _M_num_get; > > public: > > > > > > > > operator void*() const > { return this->fail() ? 0 : const_cast<basic_ios*>(this); } > > bool > operator!() const > { return this->fail(); } ># 130 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > iostate > rdstate() const > { return _M_streambuf_state; } ># 141 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > void > clear(iostate __state = goodbit); > > > > > > > > void > setstate(iostate __state) > { this->clear(this->rdstate() | __state); } > > > > > void > _M_setstate(iostate __state) > { > > > _M_streambuf_state |= __state; > if (this->exceptions() & __state) > throw; > } > > > > > > > > bool > good() const > { return this->rdstate() == 0; } > > > > > > > > bool > eof() const > { return (this->rdstate() & eofbit) != 0; } ># 194 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > bool > fail() const > { return (this->rdstate() & (badbit | failbit)) != 0; } > > > > > > > > bool > bad() const > { return (this->rdstate() & badbit) != 0; } ># 215 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > iostate > exceptions() const > { return _M_exception; } ># 250 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > void > exceptions(iostate __except) > { > _M_exception = __except; > this->clear(_M_streambuf_state); > } > > > > > > > > explicit > basic_ios(basic_streambuf<_CharT, _Traits>* __sb) > : ios_base(), _M_tie(0), _M_fill(), _M_fill_init(false), _M_streambuf(0), > _M_ctype(0), _M_num_put(0), _M_num_get(0) > { this->init(__sb); } > > > > > > > > virtual > ~basic_ios() { } ># 288 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > basic_ostream<_CharT, _Traits>* > tie() const > { return _M_tie; } ># 300 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > basic_ostream<_CharT, _Traits>* > tie(basic_ostream<_CharT, _Traits>* __tiestr) > { > basic_ostream<_CharT, _Traits>* __old = _M_tie; > _M_tie = __tiestr; > return __old; > } > > > > > > > > basic_streambuf<_CharT, _Traits>* > rdbuf() const > { return _M_streambuf; } ># 340 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > basic_streambuf<_CharT, _Traits>* > rdbuf(basic_streambuf<_CharT, _Traits>* __sb); ># 354 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > basic_ios& > copyfmt(const basic_ios& __rhs); > > > > > > > > char_type > fill() const > { > if (!_M_fill_init) > { > _M_fill = this->widen(' '); > _M_fill_init = true; > } > return _M_fill; > } ># 383 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > char_type > fill(char_type __ch) > { > char_type __old = this->fill(); > _M_fill = __ch; > return __old; > } ># 403 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > locale > imbue(const locale& __loc); ># 423 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > char > narrow(char_type __c, char __dfault) const > { return __check_facet(_M_ctype).narrow(__c, __dfault); } ># 442 "/usr/include/c++/4.9.0/bits/basic_ios.h" 3 > char_type > widen(char __c) const > { return __check_facet(_M_ctype).widen(__c); } > > protected: > > > > > > > > basic_ios() > : ios_base(), _M_tie(0), _M_fill(char_type()), _M_fill_init(false), > _M_streambuf(0), _M_ctype(0), _M_num_put(0), _M_num_get(0) > { } > > > > > > > > void > init(basic_streambuf<_CharT, _Traits>* __sb); > > void > _M_cache_locale(const locale& __loc); > }; > > >} > ># 1 "/usr/include/c++/4.9.0/bits/basic_ios.tcc" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/basic_ios.tcc" 3 ># 34 "/usr/include/c++/4.9.0/bits/basic_ios.tcc" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT, typename _Traits> > void > basic_ios<_CharT, _Traits>::clear(iostate __state) > { > if (this->rdbuf()) > _M_streambuf_state = __state; > else > _M_streambuf_state = __state | badbit; > if (this->exceptions() & this->rdstate()) > __throw_ios_failure(("basic_ios::clear")); > } > > template<typename _CharT, typename _Traits> > basic_streambuf<_CharT, _Traits>* > basic_ios<_CharT, _Traits>::rdbuf(basic_streambuf<_CharT, _Traits>* __sb) > { > basic_streambuf<_CharT, _Traits>* __old = _M_streambuf; > _M_streambuf = __sb; > this->clear(); > return __old; > } > > template<typename _CharT, typename _Traits> > basic_ios<_CharT, _Traits>& > basic_ios<_CharT, _Traits>::copyfmt(const basic_ios& __rhs) > { > > > if (this != &__rhs) > { > > > > > _Words* __words = (__rhs._M_word_size <= _S_local_word_size) ? > _M_local_word : new _Words[__rhs._M_word_size]; > > > _Callback_list* __cb = __rhs._M_callbacks; > if (__cb) > __cb->_M_add_reference(); > _M_call_callbacks(erase_event); > if (_M_word != _M_local_word) > { > delete [] _M_word; > _M_word = 0; > } > _M_dispose_callbacks(); > > > _M_callbacks = __cb; > for (int __i = 0; __i < __rhs._M_word_size; ++__i) > __words[__i] = __rhs._M_word[__i]; > _M_word = __words; > _M_word_size = __rhs._M_word_size; > > this->flags(__rhs.flags()); > this->width(__rhs.width()); > this->precision(__rhs.precision()); > this->tie(__rhs.tie()); > this->fill(__rhs.fill()); > _M_ios_locale = __rhs.getloc(); > _M_cache_locale(_M_ios_locale); > > _M_call_callbacks(copyfmt_event); > > > this->exceptions(__rhs.exceptions()); > } > return *this; > } > > > template<typename _CharT, typename _Traits> > locale > basic_ios<_CharT, _Traits>::imbue(const locale& __loc) > { > locale __old(this->getloc()); > ios_base::imbue(__loc); > _M_cache_locale(__loc); > if (this->rdbuf() != 0) > this->rdbuf()->pubimbue(__loc); > return __old; > } > > template<typename _CharT, typename _Traits> > void > basic_ios<_CharT, _Traits>::init(basic_streambuf<_CharT, _Traits>* __sb) > { > > ios_base::_M_init(); > > > _M_cache_locale(_M_ios_locale); ># 146 "/usr/include/c++/4.9.0/bits/basic_ios.tcc" 3 > _M_fill = _CharT(); > _M_fill_init = false; > > _M_tie = 0; > _M_exception = goodbit; > _M_streambuf = __sb; > _M_streambuf_state = __sb ? goodbit : badbit; > } > > template<typename _CharT, typename _Traits> > void > basic_ios<_CharT, _Traits>::_M_cache_locale(const locale& __loc) > { > if (__builtin_expect(has_facet<__ctype_type>(__loc), true)) > _M_ctype = &use_facet<__ctype_type>(__loc); > else > _M_ctype = 0; > > if (__builtin_expect(has_facet<__num_put_type>(__loc), true)) > _M_num_put = &use_facet<__num_put_type>(__loc); > else > _M_num_put = 0; > > if (__builtin_expect(has_facet<__num_get_type>(__loc), true)) > _M_num_get = &use_facet<__num_get_type>(__loc); > else > _M_num_get = 0; > } > > > > > extern template class basic_ios<char>; > > > extern template class basic_ios<wchar_t>; > > > > >} ># 476 "/usr/include/c++/4.9.0/bits/basic_ios.h" 2 3 ># 45 "/usr/include/c++/4.9.0/ios" 2 3 ># 39 "/usr/include/c++/4.9.0/ostream" 2 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 57 "/usr/include/c++/4.9.0/ostream" 3 > template<typename _CharT, typename _Traits> > class basic_ostream : virtual public basic_ios<_CharT, _Traits> > { > public: > > typedef _CharT char_type; > typedef typename _Traits::int_type int_type; > typedef typename _Traits::pos_type pos_type; > typedef typename _Traits::off_type off_type; > typedef _Traits traits_type; > > > typedef basic_streambuf<_CharT, _Traits> __streambuf_type; > typedef basic_ios<_CharT, _Traits> __ios_type; > typedef basic_ostream<_CharT, _Traits> __ostream_type; > typedef num_put<_CharT, ostreambuf_iterator<_CharT, _Traits> > > __num_put_type; > typedef ctype<_CharT> __ctype_type; ># 83 "/usr/include/c++/4.9.0/ostream" 3 > explicit > basic_ostream(__streambuf_type* __sb) > { this->init(__sb); } > > > > > > > virtual > ~basic_ostream() { } > > > class sentry; > friend class sentry; ># 107 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > operator<<(__ostream_type& (*__pf)(__ostream_type&)) > { > > > > return __pf(*this); > } > > __ostream_type& > operator<<(__ios_type& (*__pf)(__ios_type&)) > { > > > > __pf(*this); > return *this; > } > > __ostream_type& > operator<<(ios_base& (*__pf) (ios_base&)) > { > > > > __pf(*this); > return *this; > } ># 165 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > operator<<(long __n) > { return _M_insert(__n); } > > __ostream_type& > operator<<(unsigned long __n) > { return _M_insert(__n); } > > __ostream_type& > operator<<(bool __n) > { return _M_insert(__n); } > > __ostream_type& > operator<<(short __n); > > __ostream_type& > operator<<(unsigned short __n) > { > > > return _M_insert(static_cast<unsigned long>(__n)); > } > > __ostream_type& > operator<<(int __n); > > __ostream_type& > operator<<(unsigned int __n) > { > > > return _M_insert(static_cast<unsigned long>(__n)); > } > > > __ostream_type& > operator<<(long long __n) > { return _M_insert(__n); } > > __ostream_type& > operator<<(unsigned long long __n) > { return _M_insert(__n); } ># 219 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > operator<<(double __f) > { return _M_insert(__f); } > > __ostream_type& > operator<<(float __f) > { > > > return _M_insert(static_cast<double>(__f)); > } > > __ostream_type& > operator<<(long double __f) > { return _M_insert(__f); } ># 244 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > operator<<(const void* __p) > { return _M_insert(__p); } ># 269 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > operator<<(__streambuf_type* __sb); ># 302 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > put(char_type __c); > > > > > > > void > _M_write(const char_type* __s, streamsize __n) > { > const streamsize __put = this->rdbuf()->sputn(__s, __n); > if (__put != __n) > this->setstate(ios_base::badbit); > } ># 334 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > write(const char_type* __s, streamsize __n); ># 347 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > flush(); ># 357 "/usr/include/c++/4.9.0/ostream" 3 > pos_type > tellp(); ># 368 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > seekp(pos_type); ># 380 "/usr/include/c++/4.9.0/ostream" 3 > __ostream_type& > seekp(off_type, ios_base::seekdir); > > protected: > basic_ostream() > { this->init(0); } > > template<typename _ValueT> > __ostream_type& > _M_insert(_ValueT __v); > }; ># 399 "/usr/include/c++/4.9.0/ostream" 3 > template <typename _CharT, typename _Traits> > class basic_ostream<_CharT, _Traits>::sentry > { > > bool _M_ok; > basic_ostream<_CharT, _Traits>& _M_os; > > public: ># 418 "/usr/include/c++/4.9.0/ostream" 3 > explicit > sentry(basic_ostream<_CharT, _Traits>& __os); ># 428 "/usr/include/c++/4.9.0/ostream" 3 > ~sentry() > { > > if (bool(_M_os.flags() & ios_base::unitbuf) && !uncaught_exception()) > { > > if (_M_os.rdbuf() && _M_os.rdbuf()->pubsync() == -1) > _M_os.setstate(ios_base::badbit); > } > } ># 447 "/usr/include/c++/4.9.0/ostream" 3 > explicit > > operator bool() const > { return _M_ok; } > }; ># 469 "/usr/include/c++/4.9.0/ostream" 3 > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __out, _CharT __c) > { return __ostream_insert(__out, &__c, 1); } > > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __out, char __c) > { return (__out << __out.widen(__c)); } > > > template <class _Traits> > inline basic_ostream<char, _Traits>& > operator<<(basic_ostream<char, _Traits>& __out, char __c) > { return __ostream_insert(__out, &__c, 1); } > > > template<class _Traits> > inline basic_ostream<char, _Traits>& > operator<<(basic_ostream<char, _Traits>& __out, signed char __c) > { return (__out << static_cast<char>(__c)); } > > template<class _Traits> > inline basic_ostream<char, _Traits>& > operator<<(basic_ostream<char, _Traits>& __out, unsigned char __c) > { return (__out << static_cast<char>(__c)); } ># 511 "/usr/include/c++/4.9.0/ostream" 3 > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __out, const _CharT* __s) > { > if (!__s) > __out.setstate(ios_base::badbit); > else > __ostream_insert(__out, __s, > static_cast<streamsize>(_Traits::length(__s))); > return __out; > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits> & > operator<<(basic_ostream<_CharT, _Traits>& __out, const char* __s); > > > template<class _Traits> > inline basic_ostream<char, _Traits>& > operator<<(basic_ostream<char, _Traits>& __out, const char* __s) > { > if (!__s) > __out.setstate(ios_base::badbit); > else > __ostream_insert(__out, __s, > static_cast<streamsize>(_Traits::length(__s))); > return __out; > } > > > template<class _Traits> > inline basic_ostream<char, _Traits>& > operator<<(basic_ostream<char, _Traits>& __out, const signed char* __s) > { return (__out << reinterpret_cast<const char*>(__s)); } > > template<class _Traits> > inline basic_ostream<char, _Traits> & > operator<<(basic_ostream<char, _Traits>& __out, const unsigned char* __s) > { return (__out << reinterpret_cast<const char*>(__s)); } ># 562 "/usr/include/c++/4.9.0/ostream" 3 > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > endl(basic_ostream<_CharT, _Traits>& __os) > { return flush(__os.put(__os.widen('\n'))); } ># 574 "/usr/include/c++/4.9.0/ostream" 3 > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > ends(basic_ostream<_CharT, _Traits>& __os) > { return __os.put(_CharT()); } > > > > > > > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > flush(basic_ostream<_CharT, _Traits>& __os) > { return __os.flush(); } ># 600 "/usr/include/c++/4.9.0/ostream" 3 > template<typename _CharT, typename _Traits, typename _Tp> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>&& __os, const _Tp& __x) > { return (__os << __x); } > > > >} > ># 1 "/usr/include/c++/4.9.0/bits/ostream.tcc" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/ostream.tcc" 3 ># 38 "/usr/include/c++/4.9.0/bits/ostream.tcc" 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>::sentry:: > sentry(basic_ostream<_CharT, _Traits>& __os) > : _M_ok(false), _M_os(__os) > { > > if (__os.tie() && __os.good()) > __os.tie()->flush(); > > if (__os.good()) > _M_ok = true; > else > __os.setstate(ios_base::failbit); > } > > template<typename _CharT, typename _Traits> > template<typename _ValueT> > basic_ostream<_CharT, _Traits>& > basic_ostream<_CharT, _Traits>:: > _M_insert(_ValueT __v) > { > sentry __cerb(*this); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > const __num_put_type& __np = __check_facet(this->_M_num_put); > if (__np.put(*this, *this, this->fill(), __v).failed()) > __err |= ios_base::badbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > basic_ostream<_CharT, _Traits>:: > operator<<(short __n) > { > > > const ios_base::fmtflags __fmt = this->flags() & ios_base::basefield; > if (__fmt == ios_base::oct || __fmt == ios_base::hex) > return _M_insert(static_cast<long>(static_cast<unsigned short>(__n))); > else > return _M_insert(static_cast<long>(__n)); > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > basic_ostream<_CharT, _Traits>:: > operator<<(int __n) > { > > > const ios_base::fmtflags __fmt = this->flags() & ios_base::basefield; > if (__fmt == ios_base::oct || __fmt == ios_base::hex) > return _M_insert(static_cast<long>(static_cast<unsigned int>(__n))); > else > return _M_insert(static_cast<long>(__n)); > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > basic_ostream<_CharT, _Traits>:: > operator<<(__streambuf_type* __sbin) > { > ios_base::iostate __err = ios_base::goodbit; > sentry __cerb(*this); > if (__cerb && __sbin) > { > try > { > if (!__copy_streambufs(__sbin, this->rdbuf())) > __err |= ios_base::failbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::failbit); } > } > else if (!__sbin) > __err |= ios_base::badbit; > if (__err) > this->setstate(__err); > return *this; > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > basic_ostream<_CharT, _Traits>:: > put(char_type __c) > { > > > > > > > sentry __cerb(*this); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > const int_type __put = this->rdbuf()->sputc(__c); > if (traits_type::eq_int_type(__put, traits_type::eof())) > __err |= ios_base::badbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > basic_ostream<_CharT, _Traits>:: > write(const _CharT* __s, streamsize __n) > { > > > > > > > > sentry __cerb(*this); > if (__cerb) > { > try > { _M_write(__s, __n); } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > basic_ostream<_CharT, _Traits>:: > flush() > { > > > > ios_base::iostate __err = ios_base::goodbit; > try > { > if (this->rdbuf() && this->rdbuf()->pubsync() == -1) > __err |= ios_base::badbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > return *this; > } > > template<typename _CharT, typename _Traits> > typename basic_ostream<_CharT, _Traits>::pos_type > basic_ostream<_CharT, _Traits>:: > tellp() > { > pos_type __ret = pos_type(-1); > try > { > if (!this->fail()) > __ret = this->rdbuf()->pubseekoff(0, ios_base::cur, ios_base::out); > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > return __ret; > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > basic_ostream<_CharT, _Traits>:: > seekp(pos_type __pos) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > if (!this->fail()) > { > > > const pos_type __p = this->rdbuf()->pubseekpos(__pos, > ios_base::out); > > > if (__p == pos_type(off_type(-1))) > __err |= ios_base::failbit; > } > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > return *this; > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > basic_ostream<_CharT, _Traits>:: > seekp(off_type __off, ios_base::seekdir __dir) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > if (!this->fail()) > { > > > const pos_type __p = this->rdbuf()->pubseekoff(__off, __dir, > ios_base::out); > > > if (__p == pos_type(off_type(-1))) > __err |= ios_base::failbit; > } > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > return *this; > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __out, const char* __s) > { > if (!__s) > __out.setstate(ios_base::badbit); > else > { > > > const size_t __clen = char_traits<char>::length(__s); > try > { > struct __ptr_guard > { > _CharT *__p; > __ptr_guard (_CharT *__ip): __p(__ip) { } > ~__ptr_guard() { delete[] __p; } > _CharT* __get() { return __p; } > } __pg (new _CharT[__clen]); > > _CharT *__ws = __pg.__get(); > for (size_t __i = 0; __i < __clen; ++__i) > __ws[__i] = __out.widen(__s[__i]); > __ostream_insert(__out, __ws, __clen); > } > catch(__cxxabiv1::__forced_unwind&) > { > __out._M_setstate(ios_base::badbit); > throw; > } > catch(...) > { __out._M_setstate(ios_base::badbit); } > } > return __out; > } > > > > > extern template class basic_ostream<char>; > extern template ostream& endl(ostream&); > extern template ostream& ends(ostream&); > extern template ostream& flush(ostream&); > extern template ostream& operator<<(ostream&, char); > extern template ostream& operator<<(ostream&, unsigned char); > extern template ostream& operator<<(ostream&, signed char); > extern template ostream& operator<<(ostream&, const char*); > extern template ostream& operator<<(ostream&, const unsigned char*); > extern template ostream& operator<<(ostream&, const signed char*); > > extern template ostream& ostream::_M_insert(long); > extern template ostream& ostream::_M_insert(unsigned long); > extern template ostream& ostream::_M_insert(bool); > > extern template ostream& ostream::_M_insert(long long); > extern template ostream& ostream::_M_insert(unsigned long long); > > extern template ostream& ostream::_M_insert(double); > extern template ostream& ostream::_M_insert(long double); > extern template ostream& ostream::_M_insert(const void*); > > > extern template class basic_ostream<wchar_t>; > extern template wostream& endl(wostream&); > extern template wostream& ends(wostream&); > extern template wostream& flush(wostream&); > extern template wostream& operator<<(wostream&, wchar_t); > extern template wostream& operator<<(wostream&, char); > extern template wostream& operator<<(wostream&, const wchar_t*); > extern template wostream& operator<<(wostream&, const char*); > > extern template wostream& wostream::_M_insert(long); > extern template wostream& wostream::_M_insert(unsigned long); > extern template wostream& wostream::_M_insert(bool); > > extern template wostream& wostream::_M_insert(long long); > extern template wostream& wostream::_M_insert(unsigned long long); > > extern template wostream& wostream::_M_insert(double); > extern template wostream& wostream::_M_insert(long double); > extern template wostream& wostream::_M_insert(const void*); > > > > >} ># 610 "/usr/include/c++/4.9.0/ostream" 2 3 ># 65 "/usr/include/c++/4.9.0/iterator" 2 3 ># 1 "/usr/include/c++/4.9.0/istream" 1 3 ># 36 "/usr/include/c++/4.9.0/istream" 3 ># 37 "/usr/include/c++/4.9.0/istream" 3 > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 57 "/usr/include/c++/4.9.0/istream" 3 > template<typename _CharT, typename _Traits> > class basic_istream : virtual public basic_ios<_CharT, _Traits> > { > public: > > typedef _CharT char_type; > typedef typename _Traits::int_type int_type; > typedef typename _Traits::pos_type pos_type; > typedef typename _Traits::off_type off_type; > typedef _Traits traits_type; > > > typedef basic_streambuf<_CharT, _Traits> __streambuf_type; > typedef basic_ios<_CharT, _Traits> __ios_type; > typedef basic_istream<_CharT, _Traits> __istream_type; > typedef num_get<_CharT, istreambuf_iterator<_CharT, _Traits> > > __num_get_type; > typedef ctype<_CharT> __ctype_type; > > protected: > > > > > > streamsize _M_gcount; > > public: > > > > > > > > explicit > basic_istream(__streambuf_type* __sb) > : _M_gcount(streamsize(0)) > { this->init(__sb); } > > > > > > > virtual > ~basic_istream() > { _M_gcount = streamsize(0); } > > > class sentry; > friend class sentry; ># 119 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > operator>>(__istream_type& (*__pf)(__istream_type&)) > { return __pf(*this); } > > __istream_type& > operator>>(__ios_type& (*__pf)(__ios_type&)) > { > __pf(*this); > return *this; > } > > __istream_type& > operator>>(ios_base& (*__pf)(ios_base&)) > { > __pf(*this); > return *this; > } ># 167 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > operator>>(bool& __n) > { return _M_extract(__n); } > > __istream_type& > operator>>(short& __n); > > __istream_type& > operator>>(unsigned short& __n) > { return _M_extract(__n); } > > __istream_type& > operator>>(int& __n); > > __istream_type& > operator>>(unsigned int& __n) > { return _M_extract(__n); } > > __istream_type& > operator>>(long& __n) > { return _M_extract(__n); } > > __istream_type& > operator>>(unsigned long& __n) > { return _M_extract(__n); } > > > __istream_type& > operator>>(long long& __n) > { return _M_extract(__n); } > > __istream_type& > operator>>(unsigned long long& __n) > { return _M_extract(__n); } ># 213 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > operator>>(float& __f) > { return _M_extract(__f); } > > __istream_type& > operator>>(double& __f) > { return _M_extract(__f); } > > __istream_type& > operator>>(long double& __f) > { return _M_extract(__f); } ># 234 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > operator>>(void*& __p) > { return _M_extract(__p); } ># 258 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > operator>>(__streambuf_type* __sb); ># 268 "/usr/include/c++/4.9.0/istream" 3 > streamsize > gcount() const > { return _M_gcount; } ># 301 "/usr/include/c++/4.9.0/istream" 3 > int_type > get(); ># 315 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > get(char_type& __c); ># 342 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > get(char_type* __s, streamsize __n, char_type __delim); ># 353 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > get(char_type* __s, streamsize __n) > { return this->get(__s, __n, this->widen('\n')); } ># 376 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > get(__streambuf_type& __sb, char_type __delim); ># 386 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > get(__streambuf_type& __sb) > { return this->get(__sb, this->widen('\n')); } ># 415 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > getline(char_type* __s, streamsize __n, char_type __delim); ># 426 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > getline(char_type* __s, streamsize __n) > { return this->getline(__s, __n, this->widen('\n')); } ># 450 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > ignore(streamsize __n, int_type __delim); > > __istream_type& > ignore(streamsize __n); > > __istream_type& > ignore(); ># 467 "/usr/include/c++/4.9.0/istream" 3 > int_type > peek(); ># 485 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > read(char_type* __s, streamsize __n); ># 504 "/usr/include/c++/4.9.0/istream" 3 > streamsize > readsome(char_type* __s, streamsize __n); ># 521 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > putback(char_type __c); ># 537 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > unget(); ># 555 "/usr/include/c++/4.9.0/istream" 3 > int > sync(); ># 570 "/usr/include/c++/4.9.0/istream" 3 > pos_type > tellg(); ># 585 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > seekg(pos_type); ># 601 "/usr/include/c++/4.9.0/istream" 3 > __istream_type& > seekg(off_type, ios_base::seekdir); > > > protected: > basic_istream() > : _M_gcount(streamsize(0)) > { this->init(0); } > > template<typename _ValueT> > __istream_type& > _M_extract(_ValueT& __v); > }; > > > template<> > basic_istream<char>& > basic_istream<char>:: > getline(char_type* __s, streamsize __n, char_type __delim); > > template<> > basic_istream<char>& > basic_istream<char>:: > ignore(streamsize __n); > > template<> > basic_istream<char>& > basic_istream<char>:: > ignore(streamsize __n, int_type __delim); > > > template<> > basic_istream<wchar_t>& > basic_istream<wchar_t>:: > getline(char_type* __s, streamsize __n, char_type __delim); > > template<> > basic_istream<wchar_t>& > basic_istream<wchar_t>:: > ignore(streamsize __n); > > template<> > basic_istream<wchar_t>& > basic_istream<wchar_t>:: > ignore(streamsize __n, int_type __delim); ># 656 "/usr/include/c++/4.9.0/istream" 3 > template<typename _CharT, typename _Traits> > class basic_istream<_CharT, _Traits>::sentry > { > > bool _M_ok; > > public: > > typedef _Traits traits_type; > typedef basic_streambuf<_CharT, _Traits> __streambuf_type; > typedef basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::__ctype_type __ctype_type; > typedef typename _Traits::int_type __int_type; ># 692 "/usr/include/c++/4.9.0/istream" 3 > explicit > sentry(basic_istream<_CharT, _Traits>& __is, bool __noskipws = false); ># 703 "/usr/include/c++/4.9.0/istream" 3 > explicit > > operator bool() const > { return _M_ok; } > }; ># 721 "/usr/include/c++/4.9.0/istream" 3 > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __in, _CharT& __c); > > template<class _Traits> > inline basic_istream<char, _Traits>& > operator>>(basic_istream<char, _Traits>& __in, unsigned char& __c) > { return (__in >> reinterpret_cast<char&>(__c)); } > > template<class _Traits> > inline basic_istream<char, _Traits>& > operator>>(basic_istream<char, _Traits>& __in, signed char& __c) > { return (__in >> reinterpret_cast<char&>(__c)); } ># 763 "/usr/include/c++/4.9.0/istream" 3 > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __in, _CharT* __s); > > > template<> > basic_istream<char>& > operator>>(basic_istream<char>& __in, char* __s); > > template<class _Traits> > inline basic_istream<char, _Traits>& > operator>>(basic_istream<char, _Traits>& __in, unsigned char* __s) > { return (__in >> reinterpret_cast<char*>(__s)); } > > template<class _Traits> > inline basic_istream<char, _Traits>& > operator>>(basic_istream<char, _Traits>& __in, signed char* __s) > { return (__in >> reinterpret_cast<char*>(__s)); } ># 794 "/usr/include/c++/4.9.0/istream" 3 > template<typename _CharT, typename _Traits> > class basic_iostream > : public basic_istream<_CharT, _Traits>, > public basic_ostream<_CharT, _Traits> > { > public: > > > > typedef _CharT char_type; > typedef typename _Traits::int_type int_type; > typedef typename _Traits::pos_type pos_type; > typedef typename _Traits::off_type off_type; > typedef _Traits traits_type; > > > typedef basic_istream<_CharT, _Traits> __istream_type; > typedef basic_ostream<_CharT, _Traits> __ostream_type; > > > > > > > > explicit > basic_iostream(basic_streambuf<_CharT, _Traits>* __sb) > : __istream_type(__sb), __ostream_type(__sb) { } > > > > > virtual > ~basic_iostream() { } > > protected: > basic_iostream() > : __istream_type(), __ostream_type() { } > }; ># 854 "/usr/include/c++/4.9.0/istream" 3 > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > ws(basic_istream<_CharT, _Traits>& __is); ># 870 "/usr/include/c++/4.9.0/istream" 3 > template<typename _CharT, typename _Traits, typename _Tp> > inline basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>&& __is, _Tp& __x) > { return (__is >> __x); } > > > >} > ># 1 "/usr/include/c++/4.9.0/bits/istream.tcc" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/istream.tcc" 3 ># 38 "/usr/include/c++/4.9.0/bits/istream.tcc" 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>::sentry:: > sentry(basic_istream<_CharT, _Traits>& __in, bool __noskip) : _M_ok(false) > { > ios_base::iostate __err = ios_base::goodbit; > if (__in.good()) > { > if (__in.tie()) > __in.tie()->flush(); > if (!__noskip && bool(__in.flags() & ios_base::skipws)) > { > const __int_type __eof = traits_type::eof(); > __streambuf_type* __sb = __in.rdbuf(); > __int_type __c = __sb->sgetc(); > > const __ctype_type& __ct = __check_facet(__in._M_ctype); > while (!traits_type::eq_int_type(__c, __eof) > && __ct.is(ctype_base::space, > traits_type::to_char_type(__c))) > __c = __sb->snextc(); > > > > > if (traits_type::eq_int_type(__c, __eof)) > __err |= ios_base::eofbit; > } > } > > if (__in.good() && __err == ios_base::goodbit) > _M_ok = true; > else > { > __err |= ios_base::failbit; > __in.setstate(__err); > } > } > > template<typename _CharT, typename _Traits> > template<typename _ValueT> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > _M_extract(_ValueT& __v) > { > sentry __cerb(*this, false); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > const __num_get_type& __ng = __check_facet(this->_M_num_get); > __ng.get(*this, 0, *this, __err, __v); > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > operator>>(short& __n) > { > > > sentry __cerb(*this, false); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > long __l; > const __num_get_type& __ng = __check_facet(this->_M_num_get); > __ng.get(*this, 0, *this, __err, __l); > > > > if (__l < __gnu_cxx::__numeric_traits<short>::__min) > { > __err |= ios_base::failbit; > __n = __gnu_cxx::__numeric_traits<short>::__min; > } > else if (__l > __gnu_cxx::__numeric_traits<short>::__max) > { > __err |= ios_base::failbit; > __n = __gnu_cxx::__numeric_traits<short>::__max; > } > else > __n = short(__l); > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > operator>>(int& __n) > { > > > sentry __cerb(*this, false); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > long __l; > const __num_get_type& __ng = __check_facet(this->_M_num_get); > __ng.get(*this, 0, *this, __err, __l); > > > > if (__l < __gnu_cxx::__numeric_traits<int>::__min) > { > __err |= ios_base::failbit; > __n = __gnu_cxx::__numeric_traits<int>::__min; > } > else if (__l > __gnu_cxx::__numeric_traits<int>::__max) > { > __err |= ios_base::failbit; > __n = __gnu_cxx::__numeric_traits<int>::__max; > } > else > __n = int(__l); > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > operator>>(__streambuf_type* __sbout) > { > ios_base::iostate __err = ios_base::goodbit; > sentry __cerb(*this, false); > if (__cerb && __sbout) > { > try > { > bool __ineof; > if (!__copy_streambufs_eof(this->rdbuf(), __sbout, __ineof)) > __err |= ios_base::failbit; > if (__ineof) > __err |= ios_base::eofbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::failbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::failbit); } > } > else if (!__sbout) > __err |= ios_base::failbit; > if (__err) > this->setstate(__err); > return *this; > } > > template<typename _CharT, typename _Traits> > typename basic_istream<_CharT, _Traits>::int_type > basic_istream<_CharT, _Traits>:: > get(void) > { > const int_type __eof = traits_type::eof(); > int_type __c = __eof; > _M_gcount = 0; > ios_base::iostate __err = ios_base::goodbit; > sentry __cerb(*this, true); > if (__cerb) > { > try > { > __c = this->rdbuf()->sbumpc(); > > if (!traits_type::eq_int_type(__c, __eof)) > _M_gcount = 1; > else > __err |= ios_base::eofbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > } > if (!_M_gcount) > __err |= ios_base::failbit; > if (__err) > this->setstate(__err); > return __c; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > get(char_type& __c) > { > _M_gcount = 0; > ios_base::iostate __err = ios_base::goodbit; > sentry __cerb(*this, true); > if (__cerb) > { > try > { > const int_type __cb = this->rdbuf()->sbumpc(); > > if (!traits_type::eq_int_type(__cb, traits_type::eof())) > { > _M_gcount = 1; > __c = traits_type::to_char_type(__cb); > } > else > __err |= ios_base::eofbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > } > if (!_M_gcount) > __err |= ios_base::failbit; > if (__err) > this->setstate(__err); > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > get(char_type* __s, streamsize __n, char_type __delim) > { > _M_gcount = 0; > ios_base::iostate __err = ios_base::goodbit; > sentry __cerb(*this, true); > if (__cerb) > { > try > { > const int_type __idelim = traits_type::to_int_type(__delim); > const int_type __eof = traits_type::eof(); > __streambuf_type* __sb = this->rdbuf(); > int_type __c = __sb->sgetc(); > > while (_M_gcount + 1 < __n > && !traits_type::eq_int_type(__c, __eof) > && !traits_type::eq_int_type(__c, __idelim)) > { > *__s++ = traits_type::to_char_type(__c); > ++_M_gcount; > __c = __sb->snextc(); > } > if (traits_type::eq_int_type(__c, __eof)) > __err |= ios_base::eofbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > } > > > if (__n > 0) > *__s = char_type(); > if (!_M_gcount) > __err |= ios_base::failbit; > if (__err) > this->setstate(__err); > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > get(__streambuf_type& __sb, char_type __delim) > { > _M_gcount = 0; > ios_base::iostate __err = ios_base::goodbit; > sentry __cerb(*this, true); > if (__cerb) > { > try > { > const int_type __idelim = traits_type::to_int_type(__delim); > const int_type __eof = traits_type::eof(); > __streambuf_type* __this_sb = this->rdbuf(); > int_type __c = __this_sb->sgetc(); > char_type __c2 = traits_type::to_char_type(__c); > > while (!traits_type::eq_int_type(__c, __eof) > && !traits_type::eq_int_type(__c, __idelim) > && !traits_type::eq_int_type(__sb.sputc(__c2), __eof)) > { > ++_M_gcount; > __c = __this_sb->snextc(); > __c2 = traits_type::to_char_type(__c); > } > if (traits_type::eq_int_type(__c, __eof)) > __err |= ios_base::eofbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > } > if (!_M_gcount) > __err |= ios_base::failbit; > if (__err) > this->setstate(__err); > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > getline(char_type* __s, streamsize __n, char_type __delim) > { > _M_gcount = 0; > ios_base::iostate __err = ios_base::goodbit; > sentry __cerb(*this, true); > if (__cerb) > { > try > { > const int_type __idelim = traits_type::to_int_type(__delim); > const int_type __eof = traits_type::eof(); > __streambuf_type* __sb = this->rdbuf(); > int_type __c = __sb->sgetc(); > > while (_M_gcount + 1 < __n > && !traits_type::eq_int_type(__c, __eof) > && !traits_type::eq_int_type(__c, __idelim)) > { > *__s++ = traits_type::to_char_type(__c); > __c = __sb->snextc(); > ++_M_gcount; > } > if (traits_type::eq_int_type(__c, __eof)) > __err |= ios_base::eofbit; > else > { > if (traits_type::eq_int_type(__c, __idelim)) > { > __sb->sbumpc(); > ++_M_gcount; > } > else > __err |= ios_base::failbit; > } > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > } > > > if (__n > 0) > *__s = char_type(); > if (!_M_gcount) > __err |= ios_base::failbit; > if (__err) > this->setstate(__err); > return *this; > } > > > > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > ignore(void) > { > _M_gcount = 0; > sentry __cerb(*this, true); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > const int_type __eof = traits_type::eof(); > __streambuf_type* __sb = this->rdbuf(); > > if (traits_type::eq_int_type(__sb->sbumpc(), __eof)) > __err |= ios_base::eofbit; > else > _M_gcount = 1; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > ignore(streamsize __n) > { > _M_gcount = 0; > sentry __cerb(*this, true); > if (__cerb && __n > 0) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > const int_type __eof = traits_type::eof(); > __streambuf_type* __sb = this->rdbuf(); > int_type __c = __sb->sgetc(); ># 513 "/usr/include/c++/4.9.0/bits/istream.tcc" 3 > bool __large_ignore = false; > while (true) > { > while (_M_gcount < __n > && !traits_type::eq_int_type(__c, __eof)) > { > ++_M_gcount; > __c = __sb->snextc(); > } > if (__n == __gnu_cxx::__numeric_traits<streamsize>::__max > && !traits_type::eq_int_type(__c, __eof)) > { > _M_gcount = > __gnu_cxx::__numeric_traits<streamsize>::__min; > __large_ignore = true; > } > else > break; > } > > if (__large_ignore) > _M_gcount = __gnu_cxx::__numeric_traits<streamsize>::__max; > > if (traits_type::eq_int_type(__c, __eof)) > __err |= ios_base::eofbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > ignore(streamsize __n, int_type __delim) > { > _M_gcount = 0; > sentry __cerb(*this, true); > if (__cerb && __n > 0) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > const int_type __eof = traits_type::eof(); > __streambuf_type* __sb = this->rdbuf(); > int_type __c = __sb->sgetc(); > > > bool __large_ignore = false; > while (true) > { > while (_M_gcount < __n > && !traits_type::eq_int_type(__c, __eof) > && !traits_type::eq_int_type(__c, __delim)) > { > ++_M_gcount; > __c = __sb->snextc(); > } > if (__n == __gnu_cxx::__numeric_traits<streamsize>::__max > && !traits_type::eq_int_type(__c, __eof) > && !traits_type::eq_int_type(__c, __delim)) > { > _M_gcount = > __gnu_cxx::__numeric_traits<streamsize>::__min; > __large_ignore = true; > } > else > break; > } > > if (__large_ignore) > _M_gcount = __gnu_cxx::__numeric_traits<streamsize>::__max; > > if (traits_type::eq_int_type(__c, __eof)) > __err |= ios_base::eofbit; > else if (traits_type::eq_int_type(__c, __delim)) > { > if (_M_gcount > < __gnu_cxx::__numeric_traits<streamsize>::__max) > ++_M_gcount; > __sb->sbumpc(); > } > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > typename basic_istream<_CharT, _Traits>::int_type > basic_istream<_CharT, _Traits>:: > peek(void) > { > int_type __c = traits_type::eof(); > _M_gcount = 0; > sentry __cerb(*this, true); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > __c = this->rdbuf()->sgetc(); > if (traits_type::eq_int_type(__c, traits_type::eof())) > __err |= ios_base::eofbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return __c; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > read(char_type* __s, streamsize __n) > { > _M_gcount = 0; > sentry __cerb(*this, true); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > _M_gcount = this->rdbuf()->sgetn(__s, __n); > if (_M_gcount != __n) > __err |= (ios_base::eofbit | ios_base::failbit); > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > streamsize > basic_istream<_CharT, _Traits>:: > readsome(char_type* __s, streamsize __n) > { > _M_gcount = 0; > sentry __cerb(*this, true); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > > const streamsize __num = this->rdbuf()->in_avail(); > if (__num > 0) > _M_gcount = this->rdbuf()->sgetn(__s, std::min(__num, __n)); > else if (__num == -1) > __err |= ios_base::eofbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return _M_gcount; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > putback(char_type __c) > { > > > _M_gcount = 0; > > this->clear(this->rdstate() & ~ios_base::eofbit); > sentry __cerb(*this, true); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > const int_type __eof = traits_type::eof(); > __streambuf_type* __sb = this->rdbuf(); > if (!__sb > || traits_type::eq_int_type(__sb->sputbackc(__c), __eof)) > __err |= ios_base::badbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > unget(void) > { > > > _M_gcount = 0; > > this->clear(this->rdstate() & ~ios_base::eofbit); > sentry __cerb(*this, true); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > const int_type __eof = traits_type::eof(); > __streambuf_type* __sb = this->rdbuf(); > if (!__sb > || traits_type::eq_int_type(__sb->sungetc(), __eof)) > __err |= ios_base::badbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > int > basic_istream<_CharT, _Traits>:: > sync(void) > { > > > int __ret = -1; > sentry __cerb(*this, true); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > __streambuf_type* __sb = this->rdbuf(); > if (__sb) > { > if (__sb->pubsync() == -1) > __err |= ios_base::badbit; > else > __ret = 0; > } > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return __ret; > } > > template<typename _CharT, typename _Traits> > typename basic_istream<_CharT, _Traits>::pos_type > basic_istream<_CharT, _Traits>:: > tellg(void) > { > > > pos_type __ret = pos_type(-1); > sentry __cerb(*this, true); > if (__cerb) > { > try > { > if (!this->fail()) > __ret = this->rdbuf()->pubseekoff(0, ios_base::cur, > ios_base::in); > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > } > return __ret; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > seekg(pos_type __pos) > { > > > > this->clear(this->rdstate() & ~ios_base::eofbit); > sentry __cerb(*this, true); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > if (!this->fail()) > { > > const pos_type __p = this->rdbuf()->pubseekpos(__pos, > ios_base::in); > > > if (__p == pos_type(off_type(-1))) > __err |= ios_base::failbit; > } > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > basic_istream<_CharT, _Traits>:: > seekg(off_type __off, ios_base::seekdir __dir) > { > > > > this->clear(this->rdstate() & ~ios_base::eofbit); > sentry __cerb(*this, true); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > if (!this->fail()) > { > > const pos_type __p = this->rdbuf()->pubseekoff(__off, __dir, > ios_base::in); > > > if (__p == pos_type(off_type(-1))) > __err |= ios_base::failbit; > } > } > catch(__cxxabiv1::__forced_unwind&) > { > this->_M_setstate(ios_base::badbit); > throw; > } > catch(...) > { this->_M_setstate(ios_base::badbit); } > if (__err) > this->setstate(__err); > } > return *this; > } > > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __in, _CharT& __c) > { > typedef basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::int_type __int_type; > > typename __istream_type::sentry __cerb(__in, false); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > const __int_type __cb = __in.rdbuf()->sbumpc(); > if (!_Traits::eq_int_type(__cb, _Traits::eof())) > __c = _Traits::to_char_type(__cb); > else > __err |= (ios_base::eofbit | ios_base::failbit); > } > catch(__cxxabiv1::__forced_unwind&) > { > __in._M_setstate(ios_base::badbit); > throw; > } > catch(...) > { __in._M_setstate(ios_base::badbit); } > if (__err) > __in.setstate(__err); > } > return __in; > } > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __in, _CharT* __s) > { > typedef basic_istream<_CharT, _Traits> __istream_type; > typedef basic_streambuf<_CharT, _Traits> __streambuf_type; > typedef typename _Traits::int_type int_type; > typedef _CharT char_type; > typedef ctype<_CharT> __ctype_type; > > streamsize __extracted = 0; > ios_base::iostate __err = ios_base::goodbit; > typename __istream_type::sentry __cerb(__in, false); > if (__cerb) > { > try > { > > streamsize __num = __in.width(); > if (__num <= 0) > __num = __gnu_cxx::__numeric_traits<streamsize>::__max; > > const __ctype_type& __ct = use_facet<__ctype_type>(__in.getloc()); > > const int_type __eof = _Traits::eof(); > __streambuf_type* __sb = __in.rdbuf(); > int_type __c = __sb->sgetc(); > > while (__extracted < __num - 1 > && !_Traits::eq_int_type(__c, __eof) > && !__ct.is(ctype_base::space, > _Traits::to_char_type(__c))) > { > *__s++ = _Traits::to_char_type(__c); > ++__extracted; > __c = __sb->snextc(); > } > if (_Traits::eq_int_type(__c, __eof)) > __err |= ios_base::eofbit; > > > > *__s = char_type(); > __in.width(0); > } > catch(__cxxabiv1::__forced_unwind&) > { > __in._M_setstate(ios_base::badbit); > throw; > } > catch(...) > { __in._M_setstate(ios_base::badbit); } > } > if (!__extracted) > __err |= ios_base::failbit; > if (__err) > __in.setstate(__err); > return __in; > } > > > template<typename _CharT, typename _Traits> > basic_istream<_CharT, _Traits>& > ws(basic_istream<_CharT, _Traits>& __in) > { > typedef basic_istream<_CharT, _Traits> __istream_type; > typedef basic_streambuf<_CharT, _Traits> __streambuf_type; > typedef typename __istream_type::int_type __int_type; > typedef ctype<_CharT> __ctype_type; > > const __ctype_type& __ct = use_facet<__ctype_type>(__in.getloc()); > const __int_type __eof = _Traits::eof(); > __streambuf_type* __sb = __in.rdbuf(); > __int_type __c = __sb->sgetc(); > > while (!_Traits::eq_int_type(__c, __eof) > && __ct.is(ctype_base::space, _Traits::to_char_type(__c))) > __c = __sb->snextc(); > > if (_Traits::eq_int_type(__c, __eof)) > __in.setstate(ios_base::eofbit); > return __in; > } > > > > > extern template class basic_istream<char>; > extern template istream& ws(istream&); > extern template istream& operator>>(istream&, char&); > extern template istream& operator>>(istream&, char*); > extern template istream& operator>>(istream&, unsigned char&); > extern template istream& operator>>(istream&, signed char&); > extern template istream& operator>>(istream&, unsigned char*); > extern template istream& operator>>(istream&, signed char*); > > extern template istream& istream::_M_extract(unsigned short&); > extern template istream& istream::_M_extract(unsigned int&); > extern template istream& istream::_M_extract(long&); > extern template istream& istream::_M_extract(unsigned long&); > extern template istream& istream::_M_extract(bool&); > > extern template istream& istream::_M_extract(long long&); > extern template istream& istream::_M_extract(unsigned long long&); > > extern template istream& istream::_M_extract(float&); > extern template istream& istream::_M_extract(double&); > extern template istream& istream::_M_extract(long double&); > extern template istream& istream::_M_extract(void*&); > > extern template class basic_iostream<char>; > > > extern template class basic_istream<wchar_t>; > extern template wistream& ws(wistream&); > extern template wistream& operator>>(wistream&, wchar_t&); > extern template wistream& operator>>(wistream&, wchar_t*); > > extern template wistream& wistream::_M_extract(unsigned short&); > extern template wistream& wistream::_M_extract(unsigned int&); > extern template wistream& wistream::_M_extract(long&); > extern template wistream& wistream::_M_extract(unsigned long&); > extern template wistream& wistream::_M_extract(bool&); > > extern template wistream& wistream::_M_extract(long long&); > extern template wistream& wistream::_M_extract(unsigned long long&); > > extern template wistream& wistream::_M_extract(float&); > extern template wistream& wistream::_M_extract(double&); > extern template wistream& wistream::_M_extract(long double&); > extern template wistream& wistream::_M_extract(void*&); > > extern template class basic_iostream<wchar_t>; > > > > >} ># 880 "/usr/include/c++/4.9.0/istream" 2 3 ># 66 "/usr/include/c++/4.9.0/iterator" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stream_iterator.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/stream_iterator.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/stream_iterator.h" 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 47 "/usr/include/c++/4.9.0/bits/stream_iterator.h" 3 > template<typename _Tp, typename _CharT = char, > typename _Traits = char_traits<_CharT>, typename _Dist = ptrdiff_t> > class istream_iterator > : public iterator<input_iterator_tag, _Tp, _Dist, const _Tp*, const _Tp&> > { > public: > typedef _CharT char_type; > typedef _Traits traits_type; > typedef basic_istream<_CharT, _Traits> istream_type; > > private: > istream_type* _M_stream; > _Tp _M_value; > bool _M_ok; > > public: > > constexpr istream_iterator() > : _M_stream(0), _M_value(), _M_ok(false) {} > > > istream_iterator(istream_type& __s) > : _M_stream(&__s) > { _M_read(); } > > istream_iterator(const istream_iterator& __obj) > : _M_stream(__obj._M_stream), _M_value(__obj._M_value), > _M_ok(__obj._M_ok) > { } > > const _Tp& > operator*() const > { > > > ; > return _M_value; > } > > const _Tp* > operator->() const { return &(operator*()); } > > istream_iterator& > operator++() > { > > > ; > _M_read(); > return *this; > } > > istream_iterator > operator++(int) > { > > > ; > istream_iterator __tmp = *this; > _M_read(); > return __tmp; > } > > bool > _M_equal(const istream_iterator& __x) const > { return (_M_ok == __x._M_ok) && (!_M_ok || _M_stream == __x._M_stream); } > > private: > void > _M_read() > { > _M_ok = (_M_stream && *_M_stream) ? true : false; > if (_M_ok) > { > *_M_stream >> _M_value; > _M_ok = *_M_stream ? true : false; > } > } > }; > > > template<typename _Tp, typename _CharT, typename _Traits, typename _Dist> > inline bool > operator==(const istream_iterator<_Tp, _CharT, _Traits, _Dist>& __x, > const istream_iterator<_Tp, _CharT, _Traits, _Dist>& __y) > { return __x._M_equal(__y); } > > > template <class _Tp, class _CharT, class _Traits, class _Dist> > inline bool > operator!=(const istream_iterator<_Tp, _CharT, _Traits, _Dist>& __x, > const istream_iterator<_Tp, _CharT, _Traits, _Dist>& __y) > { return !__x._M_equal(__y); } ># 152 "/usr/include/c++/4.9.0/bits/stream_iterator.h" 3 > template<typename _Tp, typename _CharT = char, > typename _Traits = char_traits<_CharT> > > class ostream_iterator > : public iterator<output_iterator_tag, void, void, void, void> > { > public: > > > typedef _CharT char_type; > typedef _Traits traits_type; > typedef basic_ostream<_CharT, _Traits> ostream_type; > > > private: > ostream_type* _M_stream; > const _CharT* _M_string; > > public: > > ostream_iterator(ostream_type& __s) : _M_stream(&__s), _M_string(0) {} ># 183 "/usr/include/c++/4.9.0/bits/stream_iterator.h" 3 > ostream_iterator(ostream_type& __s, const _CharT* __c) > : _M_stream(&__s), _M_string(__c) { } > > > ostream_iterator(const ostream_iterator& __obj) > : _M_stream(__obj._M_stream), _M_string(__obj._M_string) { } > > > > ostream_iterator& > operator=(const _Tp& __value) > { > > > ; > *_M_stream << __value; > if (_M_string) *_M_stream << _M_string; > return *this; > } > > ostream_iterator& > operator*() > { return *this; } > > ostream_iterator& > operator++() > { return *this; } > > ostream_iterator& > operator++(int) > { return *this; } > }; > > > > >} ># 67 "/usr/include/c++/4.9.0/iterator" 2 3 ># 55 "/usr/include/boost/detail/iterator.hpp" 2 3 4 ># 77 "/usr/include/boost/detail/iterator.hpp" 3 4 >namespace boost { namespace detail { > > >template <class Iterator> >struct iterator_traits > : std::iterator_traits<Iterator> >{}; >using std::distance; > >}} ># 9 "/usr/include/boost/iterator/iterator_traits.hpp" 2 3 4 > > >namespace boost { ># 27 "/usr/include/boost/iterator/iterator_traits.hpp" 3 4 >template <class Iterator> >struct iterator_value >{ > typedef typename boost::detail::iterator_traits<Iterator>::value_type type; >}; > >template <class Iterator> >struct iterator_reference >{ > typedef typename boost::detail::iterator_traits<Iterator>::reference type; >}; > > >template <class Iterator> >struct iterator_pointer >{ > typedef typename boost::detail::iterator_traits<Iterator>::pointer type; >}; > >template <class Iterator> >struct iterator_difference >{ > typedef typename boost::detail::iterator_traits<Iterator>::difference_type type; >}; > >template <class Iterator> >struct iterator_category >{ > typedef typename boost::detail::iterator_traits<Iterator>::iterator_category type; >}; ># 90 "/usr/include/boost/iterator/iterator_traits.hpp" 3 4 >} ># 26 "/usr/include/boost/range/mutable_iterator.hpp" 2 3 4 > > > >namespace boost >{ > > > > > namespace range_detail { > template< typename C, typename Enable=void > struct extract_iterator {}; template< typename C > struct extract_iterator< C , typename boost::range_detail::exists< typename C::iterator >::type > { typedef typename C::iterator type; }; > } > > template< typename C > > struct range_mutable_iterator : range_detail::extract_iterator<C> > {}; > > > > > > template< typename Iterator > > struct range_mutable_iterator< std::pair<Iterator,Iterator> > > { > typedef Iterator type; > }; > > > > > > template< typename T, std::size_t sz > > struct range_mutable_iterator< T[sz] > > { > typedef T* type; > }; > >} ># 20 "/usr/include/boost/range/iterator.hpp" 2 3 4 ># 1 "/usr/include/boost/range/const_iterator.hpp" 1 3 4 ># 25 "/usr/include/boost/range/const_iterator.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/remove_const.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/remove_const.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_volatile.hpp" 1 3 4 ># 28 "/usr/include/boost/type_traits/is_volatile.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/cv_traits_impl.hpp" 1 3 4 ># 23 "/usr/include/boost/type_traits/detail/cv_traits_impl.hpp" 3 4 >namespace boost { >namespace detail { > > > > > > > >template <typename T> struct cv_traits_imp {}; > >template <typename T> >struct cv_traits_imp<T*> >{ > static const bool is_const = false; > static const bool is_volatile = false; > typedef T unqualified_type; >}; > >template <typename T> >struct cv_traits_imp<const T*> >{ > static const bool is_const = true; > static const bool is_volatile = false; > typedef T unqualified_type; >}; > >template <typename T> >struct cv_traits_imp<volatile T*> >{ > static const bool is_const = false; > static const bool is_volatile = true; > typedef T unqualified_type; >}; > >template <typename T> >struct cv_traits_imp<const volatile T*> >{ > static const bool is_const = true; > static const bool is_volatile = true; > typedef T unqualified_type; >}; ># 92 "/usr/include/boost/type_traits/detail/cv_traits_impl.hpp" 3 4 >} >} ># 29 "/usr/include/boost/type_traits/is_volatile.hpp" 2 3 4 ># 40 "/usr/include/boost/type_traits/is_volatile.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 41 "/usr/include/boost/type_traits/is_volatile.hpp" 2 3 4 > >namespace boost { > >namespace detail{ >template <class T> >struct is_volatile_rval_filter >{ > > > > static const bool value = ::boost::detail::cv_traits_imp<T*>::is_volatile; > >}; > > > > > >template <class T> >struct is_volatile_rval_filter<T&&> >{ > static const bool value = false; >}; > >} > > > > > > >template< typename T > struct is_volatile : public ::boost::integral_constant<bool,::boost::detail::is_volatile_rval_filter<T>::value> { public: }; >template< typename T > struct is_volatile< T& > : public ::boost::integral_constant<bool,false> { public: }; ># 148 "/usr/include/boost/type_traits/is_volatile.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 151 "/usr/include/boost/type_traits/is_volatile.hpp" 2 3 4 ># 15 "/usr/include/boost/type_traits/remove_const.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/broken_compiler_spec.hpp" 1 3 4 ># 95 "/usr/include/boost/type_traits/broken_compiler_spec.hpp" 3 4 ># 16 "/usr/include/boost/type_traits/remove_const.hpp" 2 3 4 ># 27 "/usr/include/boost/type_traits/remove_const.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 28 "/usr/include/boost/type_traits/remove_const.hpp" 2 3 4 > >namespace boost { > > > >namespace detail { > >template <typename T, bool is_vol> >struct remove_const_helper >{ > typedef T type; >}; > >template <typename T> >struct remove_const_helper<T, true> >{ > typedef T volatile type; >}; > > >template <typename T> >struct remove_const_impl >{ > typedef typename remove_const_helper< > typename cv_traits_imp<T*>::unqualified_type > , ::boost::is_volatile<T>::value > >::type type; >}; > > > > > > >template <typename T> >struct remove_const_impl<T&&> >{ > typedef T&& type; >}; > > >} > > > >template< typename T > struct remove_const { public: typedef typename boost::detail::remove_const_impl<T>::type type; }; >template< typename T > struct remove_const<T&> { public: typedef T& type; }; > >template< typename T, std::size_t N > struct remove_const<T const[N]> { public: typedef T type[N]; }; >template< typename T, std::size_t N > struct remove_const<T const volatile[N]> { public: typedef T volatile type[N]; }; ># 86 "/usr/include/boost/type_traits/remove_const.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 89 "/usr/include/boost/type_traits/remove_const.hpp" 2 3 4 ># 26 "/usr/include/boost/range/const_iterator.hpp" 2 3 4 > > > >namespace boost >{ > > > > > namespace range_detail { > template< typename C, typename Enable=void > struct extract_const_iterator {}; template< typename C > struct extract_const_iterator< C , typename boost::range_detail::exists< typename C::const_iterator >::type > { typedef typename C::const_iterator type; }; > } > > template< typename C > > struct range_const_iterator : range_detail::extract_const_iterator<C> > {}; > > > > > > template< typename Iterator > > struct range_const_iterator< std::pair<Iterator,Iterator> > > { > typedef Iterator type; > }; > > > > > > template< typename T, std::size_t sz > > struct range_const_iterator< T[sz] > > { > typedef const T* type; > }; > >} ># 21 "/usr/include/boost/range/iterator.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_const.hpp" 1 3 4 ># 30 "/usr/include/boost/type_traits/is_const.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_reference.hpp" 1 3 4 ># 16 "/usr/include/boost/type_traits/is_reference.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_lvalue_reference.hpp" 1 3 4 ># 32 "/usr/include/boost/type_traits/is_lvalue_reference.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 33 "/usr/include/boost/type_traits/is_lvalue_reference.hpp" 2 3 4 > >namespace boost { > > > > > >template< typename T > struct is_lvalue_reference : public ::boost::integral_constant<bool,false> { public: }; >template< typename T > struct is_lvalue_reference< T& > : public ::boost::integral_constant<bool,true> { public: }; ># 113 "/usr/include/boost/type_traits/is_lvalue_reference.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 116 "/usr/include/boost/type_traits/is_lvalue_reference.hpp" 2 3 4 ># 17 "/usr/include/boost/type_traits/is_reference.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_rvalue_reference.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/is_rvalue_reference.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/is_rvalue_reference.hpp" 2 3 4 > >namespace boost { > >template< typename T > struct is_rvalue_reference : public ::boost::integral_constant<bool,false> { public: }; > >template< typename T > struct is_rvalue_reference< T&& > : public ::boost::integral_constant<bool,true> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 27 "/usr/include/boost/type_traits/is_rvalue_reference.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/is_reference.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/ice.hpp" 1 3 4 ># 16 "/usr/include/boost/type_traits/ice.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/ice_and.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/ice_and.hpp" 3 4 >namespace boost { >namespace type_traits { > >template <bool b1, bool b2, bool b3 = true, bool b4 = true, bool b5 = true, bool b6 = true, bool b7 = true> >struct ice_and; > >template <bool b1, bool b2, bool b3, bool b4, bool b5, bool b6, bool b7> >struct ice_and >{ > static const bool value = false; >}; > >template <> >struct ice_and<true, true, true, true, true, true, true> >{ > static const bool value = true; >}; > >} >} ># 17 "/usr/include/boost/type_traits/ice.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/detail/ice_not.hpp" 1 3 4 ># 13 "/usr/include/boost/type_traits/detail/ice_not.hpp" 3 4 >namespace boost { >namespace type_traits { > >template <bool b> >struct ice_not >{ > static const bool value = true; >}; > >template <> >struct ice_not<true> >{ > static const bool value = false; >}; > >} >} ># 18 "/usr/include/boost/type_traits/ice.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/detail/ice_eq.hpp" 1 3 4 ># 13 "/usr/include/boost/type_traits/detail/ice_eq.hpp" 3 4 >namespace boost { >namespace type_traits { > >template <int b1, int b2> >struct ice_eq >{ > static const bool value = (b1 == b2); >}; > >template <int b1, int b2> >struct ice_ne >{ > static const bool value = (b1 != b2); >}; > > >template <int b1, int b2> bool const ice_eq<b1,b2>::value; >template <int b1, int b2> bool const ice_ne<b1,b2>::value; > > >} >} ># 19 "/usr/include/boost/type_traits/ice.hpp" 2 3 4 ># 19 "/usr/include/boost/type_traits/is_reference.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 22 "/usr/include/boost/type_traits/is_reference.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct is_reference_impl >{ > static const bool value = (::boost::type_traits::ice_or< ::boost::is_lvalue_reference<T>::value, ::boost::is_rvalue_reference<T>::value >::value) > > > ; >}; > >} > >template< typename T > struct is_reference : public ::boost::integral_constant<bool,::boost::detail::is_reference_impl<T>::value> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 43 "/usr/include/boost/type_traits/is_reference.hpp" 2 3 4 ># 31 "/usr/include/boost/type_traits/is_const.hpp" 2 3 4 ># 43 "/usr/include/boost/type_traits/is_const.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 44 "/usr/include/boost/type_traits/is_const.hpp" 2 3 4 > >namespace boost { > > > > > > > >namespace detail{ > > > > >template <class T> >struct is_const_rvalue_filter >{ > > > > static const bool value = ::boost::detail::cv_traits_imp<T*>::is_const; > >}; > >template <class T> >struct is_const_rvalue_filter<T&&> >{ > static const bool value = false; >}; > >} > > >template< typename T > struct is_const : public ::boost::integral_constant<bool,::boost::detail::is_const_rvalue_filter<T>::value> { public: }; >template< typename T > struct is_const< T& > : public ::boost::integral_constant<bool,false> { public: }; ># 160 "/usr/include/boost/type_traits/is_const.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 163 "/usr/include/boost/type_traits/is_const.hpp" 2 3 4 ># 22 "/usr/include/boost/range/iterator.hpp" 2 3 4 > > > >namespace boost >{ ># 50 "/usr/include/boost/range/iterator.hpp" 3 4 > template< typename C > > struct range_iterator > { > > > > > > > > typedef typename > mpl::eval_if_c< is_const<C>::value, > range_const_iterator< typename remove_const<C>::type >, > range_mutable_iterator<C> >::type type; > > > }; > >} ># 26 "/usr/include/boost/range/end.hpp" 2 3 4 > > >namespace boost >{ > > > > >namespace range_detail >{ > > > > > > template< typename C > > inline typename range_iterator<C>::type > range_end( C& c ) > { > > > > > > return c.end(); > } > > > > > > template< typename Iterator > > inline Iterator range_end( const std::pair<Iterator,Iterator>& p ) > { > return p.second; > } > > template< typename Iterator > > inline Iterator range_end( std::pair<Iterator,Iterator>& p ) > { > return p.second; > } > > > > > > template< typename T, std::size_t sz > > inline const T* range_end( const T (&a)[sz] ) > { > return range_detail::array_end<T,sz>( a ); > } > > template< typename T, std::size_t sz > > inline T* range_end( T (&a)[sz] ) > { > return range_detail::array_end<T,sz>( a ); > } > > > > >} > > >namespace range_adl_barrier >{ > >template< class T > >inline typename range_iterator<T>::type end( T& r ) >{ > > > > using namespace range_detail; > > return range_end( r ); >} > >template< class T > >inline typename range_iterator<const T>::type end( const T& r ) >{ > > > > using namespace range_detail; > > return range_end( r ); >} > > } >} > > > >namespace boost >{ > namespace range_adl_barrier > { > template< class T > > inline typename range_iterator<const T>::type > const_end( const T& r ) > { > return boost::range_adl_barrier::end( r ); > } > } > using namespace range_adl_barrier; >} ># 77 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/boost/range/begin.hpp" 1 3 4 ># 26 "/usr/include/boost/range/begin.hpp" 3 4 >namespace boost >{ > > > > >namespace range_detail >{ > > > > > > > template< typename C > > inline typename range_iterator<C>::type > range_begin( C& c ) > { > > > > > > return c.begin(); > } > > > > > > template< typename Iterator > > inline Iterator range_begin( const std::pair<Iterator,Iterator>& p ) > { > return p.first; > } > > template< typename Iterator > > inline Iterator range_begin( std::pair<Iterator,Iterator>& p ) > { > return p.first; > } ># 75 "/usr/include/boost/range/begin.hpp" 3 4 > template< typename T, std::size_t sz > > inline const T* range_begin( const T (&a)[sz] ) > { > return a; > } > > template< typename T, std::size_t sz > > inline T* range_begin( T (&a)[sz] ) > { > return a; > } > > > > > >} > > > > > >namespace range_adl_barrier >{ > >template< class T > >inline typename range_iterator<T>::type begin( T& r ) >{ > > > > using namespace range_detail; > > return range_begin( r ); >} > >template< class T > >inline typename range_iterator<const T>::type begin( const T& r ) >{ > > > > using namespace range_detail; > > return range_begin( r ); >} > > } >} > > > >namespace boost >{ > namespace range_adl_barrier > { > template< class T > > inline typename range_iterator<const T>::type > const_begin( const T& r ) > { > return boost::range_adl_barrier::begin( r ); > } > } > > using namespace range_adl_barrier; >} ># 78 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/boost/range/rend.hpp" 1 3 4 ># 19 "/usr/include/boost/range/rend.hpp" 3 4 ># 1 "/usr/include/boost/range/reverse_iterator.hpp" 1 3 4 ># 20 "/usr/include/boost/range/reverse_iterator.hpp" 3 4 ># 1 "/usr/include/boost/iterator/reverse_iterator.hpp" 1 3 4 ># 10 "/usr/include/boost/iterator/reverse_iterator.hpp" 3 4 ># 1 "/usr/include/boost/next_prior.hpp" 1 3 4 ># 17 "/usr/include/boost/next_prior.hpp" 3 4 >namespace boost { ># 29 "/usr/include/boost/next_prior.hpp" 3 4 >template <class T> >inline T next(T x) { return ++x; } > >template <class T, class Distance> >inline T next(T x, Distance n) >{ > std::advance(x, n); > return x; >} > >template <class T> >inline T prior(T x) { return --x; } > >template <class T, class Distance> >inline T prior(T x, Distance n) >{ > std::advance(x, -n); > return x; >} > >} ># 11 "/usr/include/boost/iterator/reverse_iterator.hpp" 2 3 4 ># 1 "/usr/include/boost/iterator.hpp" 1 3 4 ># 21 "/usr/include/boost/iterator.hpp" 3 4 >namespace boost >{ ># 39 "/usr/include/boost/iterator.hpp" 3 4 > namespace detail { > template <class Category, class T, class Distance, class Pointer, class Reference> > > struct iterator_base : std::iterator<Category, T, Distance, Pointer, Reference> {}; ># 51 "/usr/include/boost/iterator.hpp" 3 4 > } > > template <class Category, class T, class Distance = std::ptrdiff_t, > class Pointer = T*, class Reference = T&> > struct iterator : boost::detail::iterator_base<Category, T, Distance, Pointer, Reference> {}; > >} ># 12 "/usr/include/boost/iterator/reverse_iterator.hpp" 2 3 4 ># 1 "/usr/include/boost/iterator/iterator_adaptor.hpp" 1 3 4 ># 10 "/usr/include/boost/iterator/iterator_adaptor.hpp" 3 4 ># 1 "/usr/include/boost/static_assert.hpp" 1 3 4 ># 11 "/usr/include/boost/iterator/iterator_adaptor.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/iterator/iterator_categories.hpp" 1 3 4 ># 11 "/usr/include/boost/iterator/iterator_categories.hpp" 3 4 ># 1 "/usr/include/boost/iterator/detail/config_def.hpp" 1 3 4 ># 12 "/usr/include/boost/iterator/iterator_categories.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/mpl/identity.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/identity.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T = na > > >struct identity >{ > typedef T type; > >}; > >template< > typename T = na > > >struct make_identity >{ > typedef identity<T> type; > >}; > >template<> struct identity< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : identity< T1 > { }; }; template< typename Tag > struct lambda< identity< na > , Tag , int_<-1> > { typedef false_ is_le; typedef identity< na > result_; typedef identity< na > type; }; namespace aux { template< typename T1 > struct template_arity< identity< T1 > > : int_<1> { }; template<> struct template_arity< identity< na > > : int_<-1> { }; } >template<> struct make_identity< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : make_identity< T1 > { }; }; template< typename Tag > struct lambda< make_identity< na > , Tag , int_<-1> > { typedef false_ is_le; typedef make_identity< na > result_; typedef make_identity< na > type; }; namespace aux { template< typename T1 > struct template_arity< make_identity< T1 > > : int_<1> { }; template<> struct template_arity< make_identity< na > > : int_<-1> { }; } > >}} ># 17 "/usr/include/boost/iterator/iterator_categories.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/placeholders.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/placeholders.hpp" 3 4 ># 1 "/usr/include/boost/mpl/arg.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/arg.hpp" 3 4 ># 1 "/usr/include/boost/mpl/arg_fwd.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/arg_fwd.hpp" 3 4 >namespace mpl_ { > >template< int N > struct arg; > >} >namespace boost { namespace mpl { using ::mpl_::arg; } } ># 24 "/usr/include/boost/mpl/arg.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/aux_/na_assert.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/arg.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/arity_spec.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/arg.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/arg_typedef.hpp" 1 3 4 ># 28 "/usr/include/boost/mpl/arg.hpp" 2 3 4 ># 37 "/usr/include/boost/mpl/arg.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/arg.hpp" 1 3 4 ># 13 "/usr/include/boost/mpl/aux_/preprocessed/gcc/arg.hpp" 3 4 >namespace mpl_ { >template<> struct arg< -1 > >{ > static const int value = -1; > > > > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > typedef U1 type; > enum { mpl_assertion_in_line_27 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) (boost::mpl::is_na<type>))0, 1 ) ) ) }; > }; >}; > >template<> struct arg<1> >{ > static const int value = 1; > typedef arg<2> next; > > > > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > typedef U1 type; > enum { mpl_assertion_in_line_45 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) (boost::mpl::is_na<type>))0, 1 ) ) ) }; > }; >}; > >template<> struct arg<2> >{ > static const int value = 2; > typedef arg<3> next; > > > > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > typedef U2 type; > enum { mpl_assertion_in_line_63 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) (boost::mpl::is_na<type>))0, 1 ) ) ) }; > }; >}; > >template<> struct arg<3> >{ > static const int value = 3; > typedef arg<4> next; > > > > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > typedef U3 type; > enum { mpl_assertion_in_line_81 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) (boost::mpl::is_na<type>))0, 1 ) ) ) }; > }; >}; > >template<> struct arg<4> >{ > static const int value = 4; > typedef arg<5> next; > > > > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > typedef U4 type; > enum { mpl_assertion_in_line_99 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) (boost::mpl::is_na<type>))0, 1 ) ) ) }; > }; >}; > >template<> struct arg<5> >{ > static const int value = 5; > typedef arg<6> next; > > > > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > typedef U5 type; > enum { mpl_assertion_in_line_117 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) (boost::mpl::is_na<type>))0, 1 ) ) ) }; > }; >}; > > > >} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 38 "/usr/include/boost/mpl/arg.hpp" 2 3 4 ># 25 "/usr/include/boost/mpl/placeholders.hpp" 2 3 4 ># 43 "/usr/include/boost/mpl/placeholders.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp" 1 3 4 ># 13 "/usr/include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp" 3 4 >namespace mpl_ { >typedef arg< -1 > _; >} >namespace boost { namespace mpl { > >using ::mpl_::_; > >namespace placeholders { >using mpl_::_; >} > >}} > > > >namespace mpl_ { >typedef arg<1> _1; > >} >namespace boost { namespace mpl { > >using ::mpl_::_1; > >namespace placeholders { >using mpl_::_1; >} > >}} >namespace mpl_ { >typedef arg<2> _2; > >} >namespace boost { namespace mpl { > >using ::mpl_::_2; > >namespace placeholders { >using mpl_::_2; >} > >}} >namespace mpl_ { >typedef arg<3> _3; > >} >namespace boost { namespace mpl { > >using ::mpl_::_3; > >namespace placeholders { >using mpl_::_3; >} > >}} >namespace mpl_ { >typedef arg<4> _4; > >} >namespace boost { namespace mpl { > >using ::mpl_::_4; > >namespace placeholders { >using mpl_::_4; >} > >}} >namespace mpl_ { >typedef arg<5> _5; > >} >namespace boost { namespace mpl { > >using ::mpl_::_5; > >namespace placeholders { >using mpl_::_5; >} > >}} >namespace mpl_ { >typedef arg<6> _6; > >} >namespace boost { namespace mpl { > >using ::mpl_::_6; > >namespace placeholders { >using mpl_::_6; >} > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 44 "/usr/include/boost/mpl/placeholders.hpp" 2 3 4 ># 18 "/usr/include/boost/iterator/iterator_categories.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/is_convertible.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/is_convertible.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/intrinsics.hpp" 1 3 4 ># 16 "/usr/include/boost/type_traits/is_convertible.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/type_traits/is_arithmetic.hpp" 1 3 4 ># 13 "/usr/include/boost/type_traits/is_arithmetic.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_integral.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/is_integral.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/is_integral.hpp" 2 3 4 > >namespace boost { > > > > > > > >template< typename T > struct is_integral : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct is_integral< unsigned char > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned char const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned char volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned char const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_integral< unsigned short > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned short const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned short volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned short const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_integral< unsigned int > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned int const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned int volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned int const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_integral< unsigned long > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned long const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned long volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< unsigned long const volatile > : public ::boost::integral_constant<bool,true> { public: }; > >template<> struct is_integral< signed char > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed char const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed char volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed char const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_integral< signed short > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed short const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed short volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed short const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_integral< signed int > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed int const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed int volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed int const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_integral< signed long > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed long const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed long volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< signed long const volatile > : public ::boost::integral_constant<bool,true> { public: }; > >template<> struct is_integral< bool > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< bool const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< bool volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< bool const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_integral< char > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< char const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< char volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< char const volatile > : public ::boost::integral_constant<bool,true> { public: }; > > > > > >template<> struct is_integral< wchar_t > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< wchar_t const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< wchar_t volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< wchar_t const volatile > : public ::boost::integral_constant<bool,true> { public: }; ># 65 "/usr/include/boost/type_traits/is_integral.hpp" 3 4 >template<> struct is_integral< ::boost::ulong_long_type > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< ::boost::ulong_long_type const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< ::boost::ulong_long_type volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< ::boost::ulong_long_type const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_integral< ::boost::long_long_type > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< ::boost::long_long_type const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< ::boost::long_long_type volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< ::boost::long_long_type const volatile > : public ::boost::integral_constant<bool,true> { public: }; > > > > > > >template<> struct is_integral< boost::int128_type > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< boost::int128_type const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< boost::int128_type volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< boost::int128_type const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_integral< boost::uint128_type > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< boost::uint128_type const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< boost::uint128_type volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< boost::uint128_type const volatile > : public ::boost::integral_constant<bool,true> { public: }; > > >template<> struct is_integral< char16_t > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< char16_t const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< char16_t volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< char16_t const volatile > : public ::boost::integral_constant<bool,true> { public: }; > > >template<> struct is_integral< char32_t > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< char32_t const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< char32_t volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_integral< char32_t const volatile > : public ::boost::integral_constant<bool,true> { public: }; > > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 88 "/usr/include/boost/type_traits/is_integral.hpp" 2 3 4 ># 14 "/usr/include/boost/type_traits/is_arithmetic.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_float.hpp" 1 3 4 ># 13 "/usr/include/boost/type_traits/is_float.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 14 "/usr/include/boost/type_traits/is_float.hpp" 2 3 4 > >namespace boost { > > >template< typename T > struct is_float : public ::boost::integral_constant<bool,false> { public: }; >template<> struct is_float< float > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_float< float const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_float< float volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_float< float const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_float< double > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_float< double const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_float< double volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_float< double const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_float< long double > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_float< long double const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_float< long double volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_float< long double const volatile > : public ::boost::integral_constant<bool,true> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 26 "/usr/include/boost/type_traits/is_float.hpp" 2 3 4 ># 15 "/usr/include/boost/type_traits/is_arithmetic.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 21 "/usr/include/boost/type_traits/is_arithmetic.hpp" 2 3 4 > >namespace boost { > > >namespace detail { > >template< typename T > >struct is_arithmetic_impl >{ > static const bool value = (::boost::type_traits::ice_or< ::boost::is_integral<T>::value, ::boost::is_float<T>::value >::value) > > > > ; >}; > >} > > > > > > >template< typename T > struct is_arithmetic : public ::boost::integral_constant<bool,::boost::detail::is_arithmetic_impl<T>::value> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 50 "/usr/include/boost/type_traits/is_arithmetic.hpp" 2 3 4 ># 22 "/usr/include/boost/type_traits/is_convertible.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/is_abstract.hpp" 1 3 4 ># 62 "/usr/include/boost/type_traits/is_abstract.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 63 "/usr/include/boost/type_traits/is_abstract.hpp" 2 3 4 > > >namespace boost { >namespace detail{ > > >template <class T> >struct is_abstract_imp >{ > static const bool value = __is_abstract(T); >}; ># 141 "/usr/include/boost/type_traits/is_abstract.hpp" 3 4 >} > > >template< typename T > struct is_abstract : public ::boost::integral_constant<bool,::boost::detail::is_abstract_imp<T>::value> { public: }; > > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 152 "/usr/include/boost/type_traits/is_abstract.hpp" 2 3 4 ># 25 "/usr/include/boost/type_traits/is_convertible.hpp" 2 3 4 > ># 1 "/usr/include/boost/type_traits/add_lvalue_reference.hpp" 1 3 4 ># 9 "/usr/include/boost/type_traits/add_lvalue_reference.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/add_reference.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/add_reference.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/add_reference.hpp" 2 3 4 > >namespace boost { > >namespace detail { ># 59 "/usr/include/boost/type_traits/add_reference.hpp" 3 4 >template <typename T> >struct add_reference_rvalue_layer >{ > typedef T& type; >}; > > >template <typename T> >struct add_reference_rvalue_layer<T&&> >{ > typedef T&& type; >}; > > >template <typename T> >struct add_reference_impl >{ > typedef typename add_reference_rvalue_layer<T>::type type; >}; > > >template< typename T > struct add_reference_impl<T&> { public: typedef T& type; }; > > > > > >template<> struct add_reference_impl<void> { public: typedef void type; }; > >template<> struct add_reference_impl<void const> { public: typedef void const type; }; >template<> struct add_reference_impl<void volatile> { public: typedef void volatile type; }; >template<> struct add_reference_impl<void const volatile> { public: typedef void const volatile type; }; > > >} > >template< typename T > struct add_reference { public: typedef typename boost::detail::add_reference_impl<T>::type type; }; > > > > > > > >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 106 "/usr/include/boost/type_traits/add_reference.hpp" 2 3 4 ># 10 "/usr/include/boost/type_traits/add_lvalue_reference.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 13 "/usr/include/boost/type_traits/add_lvalue_reference.hpp" 2 3 4 > >namespace boost{ > >template< typename T > struct add_lvalue_reference { public: typedef typename boost::add_reference<T>::type type; }; > > >template< typename T > struct add_lvalue_reference<T&&> { public: typedef T& type; }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 25 "/usr/include/boost/type_traits/add_lvalue_reference.hpp" 2 3 4 ># 27 "/usr/include/boost/type_traits/is_convertible.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/add_rvalue_reference.hpp" 1 3 4 ># 19 "/usr/include/boost/type_traits/add_rvalue_reference.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 20 "/usr/include/boost/type_traits/add_rvalue_reference.hpp" 2 3 4 ># 34 "/usr/include/boost/type_traits/add_rvalue_reference.hpp" 3 4 >namespace boost { > >namespace type_traits_detail { > > template <typename T, bool b> > struct add_rvalue_reference_helper > { typedef T type; }; > > > template <typename T> > struct add_rvalue_reference_helper<T, true> > { > typedef T&& type; > }; > > > template <typename T> > struct add_rvalue_reference_imp > { > typedef typename boost::type_traits_detail::add_rvalue_reference_helper > <T, (is_void<T>::value == false && is_reference<T>::value == false) >::type type; > }; > >} > >template< typename T > struct add_rvalue_reference { public: typedef typename boost::type_traits_detail::add_rvalue_reference_imp<T>::type type; }; > >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 64 "/usr/include/boost/type_traits/add_rvalue_reference.hpp" 2 3 4 ># 28 "/usr/include/boost/type_traits/is_convertible.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_function.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/is_function.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/false_result.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/false_result.hpp" 3 4 >namespace boost { >namespace type_traits { > > >struct false_result >{ > template <typename T> struct result_ > { > static const bool value = false; > }; >}; > >}} ># 16 "/usr/include/boost/type_traits/is_function.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/type_traits/detail/is_function_ptr_helper.hpp" 1 3 4 ># 26 "/usr/include/boost/type_traits/detail/is_function_ptr_helper.hpp" 3 4 >namespace boost { >namespace type_traits { > >template <class R> >struct is_function_ptr_helper >{ > static const bool value = false; >}; > > > > >template <class R > >struct is_function_ptr_helper<R (*)()> { static const bool value = true; }; > >template <class R > >struct is_function_ptr_helper<R (*)( ...)> { static const bool value = true; }; > >template <class R , class T0> >struct is_function_ptr_helper<R (*)( T0)> { static const bool value = true; }; > >template <class R , class T0> >struct is_function_ptr_helper<R (*)( T0 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1> >struct is_function_ptr_helper<R (*)( T0 , T1)> { static const bool value = true; }; > >template <class R , class T0 , class T1> >struct is_function_ptr_helper<R (*)( T0 , T1 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_function_ptr_helper<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_function_ptr_helper<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)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_function_ptr_helper<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 ...)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_function_ptr_helper<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)> { static const bool value = true; }; > >template <class R , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_function_ptr_helper<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 ...)> { static const bool value = true; }; ># 203 "/usr/include/boost/type_traits/detail/is_function_ptr_helper.hpp" 3 4 >} >} ># 20 "/usr/include/boost/type_traits/is_function.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 27 "/usr/include/boost/type_traits/is_function.hpp" 2 3 4 > > > > > > > >namespace boost { > > > >namespace detail { > > >template<bool is_ref = true> >struct is_function_chooser > : public ::boost::type_traits::false_result >{ >}; > >template <> >struct is_function_chooser<false> >{ > template< typename T > struct result_ > : public ::boost::type_traits::is_function_ptr_helper<T*> > { > }; >}; > >template <typename T> >struct is_function_impl > : public is_function_chooser< ::boost::is_reference<T>::value > > ::template result_<T> >{ >}; ># 95 "/usr/include/boost/type_traits/is_function.hpp" 3 4 >} > > > > > > >template< typename T > struct is_function : public ::boost::integral_constant<bool,::boost::detail::is_function_impl<T>::value> { public: }; > >template< typename T > struct is_function< T&& > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 110 "/usr/include/boost/type_traits/is_function.hpp" 2 3 4 ># 29 "/usr/include/boost/type_traits/is_convertible.hpp" 2 3 4 ># 37 "/usr/include/boost/type_traits/is_convertible.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 38 "/usr/include/boost/type_traits/is_convertible.hpp" 2 3 4 > >namespace boost { ># 53 "/usr/include/boost/type_traits/is_convertible.hpp" 3 4 >namespace detail { ># 120 "/usr/include/boost/type_traits/is_convertible.hpp" 3 4 >struct any_conversion >{ > template <typename T> any_conversion(const volatile T&); > template <typename T> any_conversion(const T&); > template <typename T> any_conversion(volatile T&); > template <typename T> any_conversion(T&); >}; > >template <typename T> struct checker >{ > static boost::type_traits::no_type _m_check(any_conversion ...); > static boost::type_traits::yes_type _m_check(T, int); >}; > >template <typename From, typename To> >struct is_convertible_basic_impl >{ > typedef typename add_lvalue_reference<From>::type lvalue_type; > typedef typename add_rvalue_reference<From>::type rvalue_type; > static lvalue_type _m_from; > > static bool const value = > sizeof( boost::detail::checker<To>::_m_check(static_cast<rvalue_type>(_m_from), 0) ) > == sizeof(::boost::type_traits::yes_type); > > > > > >}; ># 351 "/usr/include/boost/type_traits/is_convertible.hpp" 3 4 >template <typename From, typename To> >struct is_convertible_impl >{ > static const bool value = (::boost::type_traits::ice_and< ::boost::type_traits::ice_or< ::boost::detail::is_convertible_basic_impl<From,To>::value, ::boost::is_void<To>::value >::value, ::boost::type_traits::ice_not< ::boost::is_array<To>::value >::value, ::boost::type_traits::ice_not< ::boost::is_function<To>::value >::value >::value) ># 367 "/usr/include/boost/type_traits/is_convertible.hpp" 3 4 > ; >}; > > >template <bool trivial1, bool trivial2, bool abstract_target> >struct is_convertible_impl_select >{ > template <class From, class To> > struct rebind > { > typedef is_convertible_impl<From, To> type; > }; >}; > >template <> >struct is_convertible_impl_select<true, true, false> >{ > template <class From, class To> > struct rebind > { > typedef true_type type; > }; >}; > >template <> >struct is_convertible_impl_select<false, false, true> >{ > template <class From, class To> > struct rebind > { > typedef false_type type; > }; >}; > >template <> >struct is_convertible_impl_select<true, false, true> >{ > template <class From, class To> > struct rebind > { > typedef false_type type; > }; >}; > >template <typename From, typename To> >struct is_convertible_impl_dispatch_base >{ > > typedef is_convertible_impl_select< > ::boost::is_arithmetic<From>::value, > ::boost::is_arithmetic<To>::value, > > ::boost::is_abstract<To>::value > > > > > selector; > > > > typedef typename selector::template rebind<From, To> isc_binder; > typedef typename isc_binder::type type; >}; > >template <typename From, typename To> >struct is_convertible_impl_dispatch > : public is_convertible_impl_dispatch_base<From, To>::type >{}; ># 456 "/usr/include/boost/type_traits/is_convertible.hpp" 3 4 > template<> struct is_convertible_impl< void,void > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void,void const > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void,void volatile > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void,void const volatile > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void const,void > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void const,void const > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void const,void volatile > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void const,void const volatile > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void volatile,void > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void volatile,void const > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void volatile,void volatile > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void volatile,void const volatile > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void const volatile,void > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void const volatile,void const > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void const volatile,void volatile > { public: static const bool value = (true); }; template<> struct is_convertible_impl< void const volatile,void const volatile > { public: static const bool value = (true); }; ># 466 "/usr/include/boost/type_traits/is_convertible.hpp" 3 4 >template< typename To > struct is_convertible_impl< void,To > { public: static const bool value = (false); }; >template< typename From > struct is_convertible_impl< From,void > { public: static const bool value = (false); }; > >template< typename To > struct is_convertible_impl< void const,To > { public: static const bool value = (false); }; >template< typename To > struct is_convertible_impl< void volatile,To > { public: static const bool value = (false); }; >template< typename To > struct is_convertible_impl< void const volatile,To > { public: static const bool value = (false); }; >template< typename From > struct is_convertible_impl< From,void const > { public: static const bool value = (false); }; >template< typename From > struct is_convertible_impl< From,void volatile > { public: static const bool value = (false); }; >template< typename From > struct is_convertible_impl< From,void const volatile > { public: static const bool value = (false); }; > > > >} > >template< typename From, typename To > struct is_convertible : public ::boost::integral_constant<bool,(::boost::detail::is_convertible_impl_dispatch<From,To>::value)> { public: }; > > > > > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 491 "/usr/include/boost/type_traits/is_convertible.hpp" 2 3 4 ># 21 "/usr/include/boost/iterator/iterator_categories.hpp" 2 3 4 > > > >namespace boost { > > > > > >struct no_traversal_tag {}; > >struct incrementable_traversal_tag > : no_traversal_tag >{ > > >}; > >struct single_pass_traversal_tag > : incrementable_traversal_tag >{ > > >}; > >struct forward_traversal_tag > : single_pass_traversal_tag >{ > > >}; > >struct bidirectional_traversal_tag > : forward_traversal_tag >{ > > >}; > >struct random_access_traversal_tag > : bidirectional_traversal_tag >{ > > >}; > >namespace detail >{ > > > > > > > template <class Cat> > struct old_category_to_traversal > : mpl::eval_if< > is_convertible<Cat,std::random_access_iterator_tag> > , mpl::identity<random_access_traversal_tag> > , mpl::eval_if< > is_convertible<Cat,std::bidirectional_iterator_tag> > , mpl::identity<bidirectional_traversal_tag> > , mpl::eval_if< > is_convertible<Cat,std::forward_iterator_tag> > , mpl::identity<forward_traversal_tag> > , mpl::eval_if< > is_convertible<Cat,std::input_iterator_tag> > , mpl::identity<single_pass_traversal_tag> > , mpl::eval_if< > is_convertible<Cat,std::output_iterator_tag> > , mpl::identity<incrementable_traversal_tag> > , void > > > > > > > > > > > {}; ># 108 "/usr/include/boost/iterator/iterator_categories.hpp" 3 4 > template <class Traversal> > struct pure_traversal_tag > : mpl::eval_if< > is_convertible<Traversal,random_access_traversal_tag> > , mpl::identity<random_access_traversal_tag> > , mpl::eval_if< > is_convertible<Traversal,bidirectional_traversal_tag> > , mpl::identity<bidirectional_traversal_tag> > , mpl::eval_if< > is_convertible<Traversal,forward_traversal_tag> > , mpl::identity<forward_traversal_tag> > , mpl::eval_if< > is_convertible<Traversal,single_pass_traversal_tag> > , mpl::identity<single_pass_traversal_tag> > , mpl::eval_if< > is_convertible<Traversal,incrementable_traversal_tag> > , mpl::identity<incrementable_traversal_tag> > , void > > > > > > > > > > > { > }; ># 142 "/usr/include/boost/iterator/iterator_categories.hpp" 3 4 >} > > > > > >template <class Cat> >struct iterator_category_to_traversal > : mpl::eval_if< > is_convertible<Cat,incrementable_traversal_tag> > , mpl::identity<Cat> > , boost::detail::old_category_to_traversal<Cat> > > >{}; > > >template <class Iterator = mpl::_1> >struct iterator_traversal > : iterator_category_to_traversal< > typename boost::detail::iterator_traits<Iterator>::iterator_category > > >{}; ># 184 "/usr/include/boost/iterator/iterator_categories.hpp" 3 4 >} > ># 1 "/usr/include/boost/iterator/detail/config_undef.hpp" 1 3 4 ># 187 "/usr/include/boost/iterator/iterator_categories.hpp" 2 3 4 ># 15 "/usr/include/boost/iterator/iterator_adaptor.hpp" 2 3 4 ># 1 "/usr/include/boost/iterator/iterator_facade.hpp" 1 3 4 ># 11 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 ># 1 "/usr/include/boost/iterator/interoperable.hpp" 1 3 4 ># 15 "/usr/include/boost/iterator/interoperable.hpp" 3 4 ># 1 "/usr/include/boost/iterator/detail/config_def.hpp" 1 3 4 ># 16 "/usr/include/boost/iterator/interoperable.hpp" 2 3 4 > >namespace boost >{ ># 34 "/usr/include/boost/iterator/interoperable.hpp" 3 4 > template <typename A, typename B> > struct is_interoperable > > > > : mpl::or_< > is_convertible< A, B > > , is_convertible< B, A > > > > { > }; > >} > ># 1 "/usr/include/boost/iterator/detail/config_undef.hpp" 1 3 4 ># 49 "/usr/include/boost/iterator/interoperable.hpp" 2 3 4 ># 12 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 > > ># 1 "/usr/include/boost/iterator/detail/facade_iterator_category.hpp" 1 3 4 ># 23 "/usr/include/boost/iterator/detail/facade_iterator_category.hpp" 3 4 ># 1 "/usr/include/boost/iterator/detail/config_def.hpp" 1 3 4 ># 24 "/usr/include/boost/iterator/detail/facade_iterator_category.hpp" 2 3 4 > > ># 1 "/usr/include/boost/detail/indirect_traits.hpp" 1 3 4 ># 9 "/usr/include/boost/detail/indirect_traits.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_pointer.hpp" 1 3 4 ># 24 "/usr/include/boost/type_traits/is_pointer.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_member_pointer.hpp" 1 3 4 ># 28 "/usr/include/boost/type_traits/is_member_pointer.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_member_function_pointer.hpp" 1 3 4 ># 24 "/usr/include/boost/type_traits/is_member_function_pointer.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp" 1 3 4 ># 25 "/usr/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp" 3 4 >namespace boost { >namespace type_traits { > >template <typename T> >struct is_mem_fun_pointer_impl >{ > static const bool value = false; >}; > > > > > >template <class R, class T > >struct is_mem_fun_pointer_impl<R (T::*)() > { static const bool value = true; }; > >template <class R, class T > >struct is_mem_fun_pointer_impl<R (T::*)( ...) > { static const bool value = true; }; > > > >template <class R, class T > >struct is_mem_fun_pointer_impl<R (T::*)() const > { static const bool value = true; }; > >template <class R, class T > >struct is_mem_fun_pointer_impl<R (T::*)() volatile > { static const bool value = true; }; > >template <class R, class T > >struct is_mem_fun_pointer_impl<R (T::*)() const volatile > { static const bool value = true; }; > > >template <class R, class T > >struct is_mem_fun_pointer_impl<R (T::*)( ...) const > { static const bool value = true; }; > >template <class R, class T > >struct is_mem_fun_pointer_impl<R (T::*)( ...) volatile > { static const bool value = true; }; > >template <class R, class T > >struct is_mem_fun_pointer_impl<R (T::*)( ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0> >struct is_mem_fun_pointer_impl<R (T::*)( T0) > { static const bool value = true; }; > >template <class R, class T , class T0> >struct is_mem_fun_pointer_impl<R (T::*)( T0 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0> >struct is_mem_fun_pointer_impl<R (T::*)( T0) const > { static const bool value = true; }; > >template <class R, class T , class T0> >struct is_mem_fun_pointer_impl<R (T::*)( T0) volatile > { static const bool value = true; }; > >template <class R, class T , class T0> >struct is_mem_fun_pointer_impl<R (T::*)( T0) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0> >struct is_mem_fun_pointer_impl<R (T::*)( T0 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0> >struct is_mem_fun_pointer_impl<R (T::*)( T0 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0> >struct is_mem_fun_pointer_impl<R (T::*)( T0 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 , T23) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 , T23 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 , T23) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 , T23) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 , T23) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 , T23 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 , T23 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23> >struct is_mem_fun_pointer_impl<R (T::*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 , T20 , T21 , T22 , T23 ...) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_mem_fun_pointer_impl<R (T::*)( 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) > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_mem_fun_pointer_impl<R (T::*)( 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 ...) > { static const bool value = true; }; > > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_mem_fun_pointer_impl<R (T::*)( 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) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_mem_fun_pointer_impl<R (T::*)( 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) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_mem_fun_pointer_impl<R (T::*)( 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) const volatile > { static const bool value = true; }; > > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_mem_fun_pointer_impl<R (T::*)( 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 ...) const > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_mem_fun_pointer_impl<R (T::*)( 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 ...) volatile > { static const bool value = true; }; > >template <class R, class T , class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19 , class T20 , class T21 , class T22 , class T23 , class T24> >struct is_mem_fun_pointer_impl<R (T::*)( 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 ...) const volatile > { static const bool value = true; }; ># 776 "/usr/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp" 3 4 >} >} ># 25 "/usr/include/boost/type_traits/is_member_function_pointer.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/remove_cv.hpp" 1 3 4 ># 26 "/usr/include/boost/type_traits/remove_cv.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 27 "/usr/include/boost/type_traits/remove_cv.hpp" 2 3 4 > >namespace boost { > > > >namespace detail{ > >template <class T> >struct rvalue_ref_filter_rem_cv >{ > typedef typename boost::detail::cv_traits_imp<T*>::unqualified_type type; >}; > > > > > > >template <class T> >struct rvalue_ref_filter_rem_cv<T&&> >{ > typedef T&& type; >}; > > >} > > > >template< typename T > struct remove_cv { public: typedef typename boost::detail::rvalue_ref_filter_rem_cv<T>::type type; }; >template< typename T > struct remove_cv<T&> { public: typedef T& type; }; > >template< typename T, std::size_t N > struct remove_cv<T const[N]> { public: typedef T type[N]; }; >template< typename T, std::size_t N > struct remove_cv<T volatile[N]> { public: typedef T type[N]; }; >template< typename T, std::size_t N > struct remove_cv<T const volatile[N]> { public: typedef T type[N]; }; ># 80 "/usr/include/boost/type_traits/remove_cv.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 83 "/usr/include/boost/type_traits/remove_cv.hpp" 2 3 4 ># 26 "/usr/include/boost/type_traits/is_member_function_pointer.hpp" 2 3 4 ># 36 "/usr/include/boost/type_traits/is_member_function_pointer.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 37 "/usr/include/boost/type_traits/is_member_function_pointer.hpp" 2 3 4 > >namespace boost { > > > > > >template< typename T > struct is_member_function_pointer : public ::boost::integral_constant<bool,::boost::type_traits::is_mem_fun_pointer_impl<typename remove_cv<T>::type>::value> { public: }; ># 132 "/usr/include/boost/type_traits/is_member_function_pointer.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 135 "/usr/include/boost/type_traits/is_member_function_pointer.hpp" 2 3 4 ># 29 "/usr/include/boost/type_traits/is_member_pointer.hpp" 2 3 4 ># 39 "/usr/include/boost/type_traits/is_member_pointer.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 40 "/usr/include/boost/type_traits/is_member_pointer.hpp" 2 3 4 > >namespace boost { ># 50 "/usr/include/boost/type_traits/is_member_pointer.hpp" 3 4 >template< typename T > struct is_member_pointer : public ::boost::integral_constant<bool,::boost::is_member_function_pointer<T>::value> { public: }; >template< typename T, typename U > struct is_member_pointer< U T::* > : public ::boost::integral_constant<bool,true> { public: }; > > >template< typename T, typename U > struct is_member_pointer< U T::*const > : public ::boost::integral_constant<bool,true> { public: }; >template< typename T, typename U > struct is_member_pointer< U T::*volatile > : public ::boost::integral_constant<bool,true> { public: }; >template< typename T, typename U > struct is_member_pointer< U T::*const volatile > : public ::boost::integral_constant<bool,true> { public: }; ># 112 "/usr/include/boost/type_traits/is_member_pointer.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 115 "/usr/include/boost/type_traits/is_member_pointer.hpp" 2 3 4 ># 25 "/usr/include/boost/type_traits/is_pointer.hpp" 2 3 4 ># 41 "/usr/include/boost/type_traits/is_pointer.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 42 "/usr/include/boost/type_traits/is_pointer.hpp" 2 3 4 > >namespace boost { > > > > > >namespace detail { > >template< typename T > struct is_pointer_helper >{ > static const bool value = false; >}; ># 63 "/usr/include/boost/type_traits/is_pointer.hpp" 3 4 >template< typename T > struct is_pointer_helper<T*> { static const bool value = true; }; > > > >template< typename T > >struct is_pointer_impl >{ ># 80 "/usr/include/boost/type_traits/is_pointer.hpp" 3 4 > static const bool value = (::boost::type_traits::ice_and< ::boost::detail::is_pointer_helper<typename remove_cv<T>::type>::value , ::boost::type_traits::ice_not< ::boost::is_member_pointer<T>::value >::value >::value) > > > > > > > ; > >}; > >} > >template< typename T > struct is_pointer : public ::boost::integral_constant<bool,::boost::detail::is_pointer_impl<T>::value> { public: }; ># 158 "/usr/include/boost/type_traits/is_pointer.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 161 "/usr/include/boost/type_traits/is_pointer.hpp" 2 3 4 ># 10 "/usr/include/boost/detail/indirect_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_class.hpp" 1 3 4 ># 37 "/usr/include/boost/type_traits/is_class.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 38 "/usr/include/boost/type_traits/is_class.hpp" 2 3 4 > >namespace boost { > >namespace detail { ># 120 "/usr/include/boost/type_traits/is_class.hpp" 3 4 >template <typename T> >struct is_class_impl >{ > static const bool value = __is_class(T); >}; > > >} > > > > > >template< typename T > struct is_class : public ::boost::integral_constant<bool,::boost::detail::is_class_impl<T>::value> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 139 "/usr/include/boost/type_traits/is_class.hpp" 2 3 4 ># 11 "/usr/include/boost/detail/indirect_traits.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/type_traits/remove_reference.hpp" 1 3 4 ># 21 "/usr/include/boost/type_traits/remove_reference.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 22 "/usr/include/boost/type_traits/remove_reference.hpp" 2 3 4 > >namespace boost { > > > >namespace detail{ > > > > >template <class T> >struct remove_rvalue_ref >{ > typedef T type; >}; > >template <class T> >struct remove_rvalue_ref<T&&> >{ > typedef T type; >}; > > >} > >template< typename T > struct remove_reference { public: typedef typename boost::detail::remove_rvalue_ref<T>::type type; }; >template< typename T > struct remove_reference<T&> { public: typedef T type; }; ># 66 "/usr/include/boost/type_traits/remove_reference.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 69 "/usr/include/boost/type_traits/remove_reference.hpp" 2 3 4 ># 17 "/usr/include/boost/detail/indirect_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/remove_pointer.hpp" 1 3 4 ># 26 "/usr/include/boost/type_traits/remove_pointer.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 27 "/usr/include/boost/type_traits/remove_pointer.hpp" 2 3 4 > >namespace boost { ># 76 "/usr/include/boost/type_traits/remove_pointer.hpp" 3 4 >template< typename T > struct remove_pointer { public: typedef T type; }; >template< typename T > struct remove_pointer<T*> { public: typedef T type; }; >template< typename T > struct remove_pointer<T* const> { public: typedef T type; }; >template< typename T > struct remove_pointer<T* volatile> { public: typedef T type; }; >template< typename T > struct remove_pointer<T* const volatile> { public: typedef T type; }; > > > > > > > >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 91 "/usr/include/boost/type_traits/remove_pointer.hpp" 2 3 4 ># 18 "/usr/include/boost/detail/indirect_traits.hpp" 2 3 4 ># 33 "/usr/include/boost/detail/indirect_traits.hpp" 3 4 >namespace boost { namespace detail { > >namespace indirect_traits { > > >template <class T> >struct is_reference_to_const : mpl::false_ >{ >}; > >template <class T> >struct is_reference_to_const<T const&> : mpl::true_ >{ >}; ># 55 "/usr/include/boost/detail/indirect_traits.hpp" 3 4 >template <class T> >struct is_reference_to_function : mpl::false_ >{ >}; > >template <class T> >struct is_reference_to_function<T&> : is_function<T> >{ >}; > >template <class T> >struct is_pointer_to_function : mpl::false_ >{ >}; > > > >template <class T> >struct is_pointer_to_function<T*> : is_function<T> >{ >}; > >template <class T> >struct is_reference_to_member_function_pointer_impl : mpl::false_ >{ >}; > >template <class T> >struct is_reference_to_member_function_pointer_impl<T&> > : is_member_function_pointer<typename remove_cv<T>::type> >{ >}; > > >template <class T> >struct is_reference_to_member_function_pointer > : is_reference_to_member_function_pointer_impl<T> >{ > >}; > >template <class T> >struct is_reference_to_function_pointer_aux > : mpl::and_< > is_reference<T> > , is_pointer_to_function< > typename remove_cv< > typename remove_reference<T>::type > >::type > > > > >{ > >}; > >template <class T> >struct is_reference_to_function_pointer > : mpl::if_< > is_reference_to_function<T> > , mpl::false_ > , is_reference_to_function_pointer_aux<T> > >::type >{ >}; > >template <class T> >struct is_reference_to_non_const > : mpl::and_< > is_reference<T> > , mpl::not_< > is_reference_to_const<T> > > > > >{ >}; > >template <class T> >struct is_reference_to_volatile : mpl::false_ >{ >}; > >template <class T> >struct is_reference_to_volatile<T volatile&> : mpl::true_ >{ >}; ># 149 "/usr/include/boost/detail/indirect_traits.hpp" 3 4 >template <class T> >struct is_reference_to_pointer : mpl::false_ >{ >}; > >template <class T> >struct is_reference_to_pointer<T*&> : mpl::true_ >{ >}; > >template <class T> >struct is_reference_to_pointer<T* const&> : mpl::true_ >{ >}; > >template <class T> >struct is_reference_to_pointer<T* volatile&> : mpl::true_ >{ >}; > >template <class T> >struct is_reference_to_pointer<T* const volatile&> : mpl::true_ >{ >}; > >template <class T> >struct is_reference_to_class > : mpl::and_< > is_reference<T> > , is_class< > typename remove_cv< > typename remove_reference<T>::type > >::type > > > > >{ > >}; > >template <class T> >struct is_pointer_to_class > : mpl::and_< > is_pointer<T> > , is_class< > typename remove_cv< > typename remove_pointer<T>::type > >::type > > > > >{ > >}; ># 481 "/usr/include/boost/detail/indirect_traits.hpp" 3 4 >} > >using namespace indirect_traits; > >}} ># 27 "/usr/include/boost/iterator/detail/facade_iterator_category.hpp" 2 3 4 > > > > > > > >namespace boost { struct use_default; } > >namespace boost { namespace detail { > >struct input_output_iterator_tag > : std::input_iterator_tag >{ > > > > > > > operator std::output_iterator_tag() const > { > return std::output_iterator_tag(); > } >}; > > > > > > >template <class ValueParam, class Reference> >struct iterator_writability_disabled > > : mpl::or_< > is_const<Reference> > , boost::detail::indirect_traits::is_reference_to_const<Reference> > , is_const<ValueParam> > > > > > >{}; ># 86 "/usr/include/boost/iterator/detail/facade_iterator_category.hpp" 3 4 >template <class Traversal, class ValueParam, class Reference> >struct iterator_facade_default_category > : mpl::eval_if< > mpl::and_< > is_reference<Reference> > , is_convertible<Traversal,forward_traversal_tag> > > > , mpl::eval_if< > is_convertible<Traversal,random_access_traversal_tag> > , mpl::identity<std::random_access_iterator_tag> > , mpl::if_< > is_convertible<Traversal,bidirectional_traversal_tag> > , std::bidirectional_iterator_tag > , std::forward_iterator_tag > > > > > , typename mpl::eval_if< > mpl::and_< > is_convertible<Traversal, single_pass_traversal_tag> > > > , is_convertible<Reference, ValueParam> > > > , mpl::identity<std::input_iterator_tag> > , mpl::identity<Traversal> > > > > >{ >}; > > >template <class T> >struct is_iterator_category > : mpl::or_< > is_convertible<T,std::input_iterator_tag> > , is_convertible<T,std::output_iterator_tag> > > >{ >}; > >template <class T> >struct is_iterator_traversal > : is_convertible<T,incrementable_traversal_tag> >{}; > > > > > > > >template <class Category, class Traversal> >struct iterator_category_with_traversal > : Category, Traversal >{ > > > > > enum { mpl_assertion_in_line_149 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) ( is_convertible< typename iterator_category_to_traversal<Category>::type , Traversal >))0, 1 ) ) ) } > > > > ; > > enum { mpl_assertion_in_line_151 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) (is_iterator_category<Category>))0, 1 ) ) ) }; > enum { mpl_assertion_in_line_152 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) (is_iterator_category<Traversal>))0, 1 ) ) ) }; > enum { mpl_assertion_in_line_153 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) (is_iterator_traversal<Category>))0, 1 ) ) ) }; > > enum { mpl_assertion_in_line_155 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) (is_iterator_traversal<Traversal>))0, 1 ) ) ) }; > > >}; > > > >template <class Traversal, class ValueParam, class Reference> >struct facade_iterator_category_impl >{ > > enum { mpl_assertion_in_line_166 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_not_arg( (void (*) (is_iterator_category<Traversal>))0, 1 ) ) ) }; > > > typedef typename iterator_facade_default_category< > Traversal,ValueParam,Reference > >::type category; > > typedef typename mpl::if_< > is_same< > Traversal > , typename iterator_category_to_traversal<category>::type > > > , category > , iterator_category_with_traversal<category,Traversal> > >::type type; >}; > > > > >template <class CategoryOrTraversal, class ValueParam, class Reference> >struct facade_iterator_category > : mpl::eval_if< > is_iterator_category<CategoryOrTraversal> > , mpl::identity<CategoryOrTraversal> > , facade_iterator_category_impl<CategoryOrTraversal,ValueParam,Reference> > > >{ >}; > >}} > ># 1 "/usr/include/boost/iterator/detail/config_undef.hpp" 1 3 4 ># 199 "/usr/include/boost/iterator/detail/facade_iterator_category.hpp" 2 3 4 ># 15 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 ># 1 "/usr/include/boost/iterator/detail/enable_if.hpp" 1 3 4 ># 13 "/usr/include/boost/iterator/detail/enable_if.hpp" 3 4 ># 1 "/usr/include/boost/iterator/detail/config_def.hpp" 1 3 4 ># 14 "/usr/include/boost/iterator/detail/enable_if.hpp" 2 3 4 > > > > > > > >namespace boost >{ > > namespace iterators > { > > > > template<bool> > struct enabled > { > template<typename T> > struct base > { > typedef T type; > }; > }; > > > > > > > template<> > struct enabled<false> > { > template<typename T> > struct base > { ># 62 "/usr/include/boost/iterator/detail/enable_if.hpp" 3 4 > }; > }; > > > template <class Cond, > class Return> > struct enable_if > > : enabled<(Cond::value)>::template base<Return> > > > > { > > > > }; > > } > >} > ># 1 "/usr/include/boost/iterator/detail/config_undef.hpp" 1 3 4 ># 85 "/usr/include/boost/iterator/detail/enable_if.hpp" 2 3 4 ># 16 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 > > ># 1 "/usr/include/boost/utility/addressof.hpp" 1 3 4 ># 18 "/usr/include/boost/utility/addressof.hpp" 3 4 >namespace boost >{ > >namespace detail >{ > >template<class T> struct addr_impl_ref >{ > T & v_; > > inline addr_impl_ref( T & v ): v_( v ) {} > inline operator T& () const { return v_; } > >private: > addr_impl_ref & operator=(const addr_impl_ref &); >}; > >template<class T> struct addressof_impl >{ > static inline T * f( T & v, long ) > { > return reinterpret_cast<T*>( > &const_cast<char&>(reinterpret_cast<const volatile char &>(v))); > } > > static inline T * f( T * v, int ) > { > return v; > } >}; > >} > >template<class T> T * addressof( T & v ) >{ > > > > > > > return boost::detail::addressof_impl<T>::f( boost::detail::addr_impl_ref<T>( v ), 0 ); > > >} ># 100 "/usr/include/boost/utility/addressof.hpp" 3 4 >} ># 19 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/add_const.hpp" 1 3 4 ># 16 "/usr/include/boost/type_traits/add_const.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 17 "/usr/include/boost/type_traits/add_const.hpp" 2 3 4 > >namespace boost { ># 33 "/usr/include/boost/type_traits/add_const.hpp" 3 4 >template< typename T > struct add_const { public: typedef T const type; }; > > > > > > >template< typename T > struct add_const<T&> { public: typedef T& type; }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 46 "/usr/include/boost/type_traits/add_const.hpp" 2 3 4 ># 22 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/add_pointer.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/add_pointer.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/add_pointer.hpp" 2 3 4 > >namespace boost { > >namespace detail { ># 55 "/usr/include/boost/type_traits/add_pointer.hpp" 3 4 >template <typename T> >struct add_pointer_impl >{ > typedef typename remove_reference<T>::type no_ref_type; > typedef no_ref_type* type; >}; > > > >} > >template< typename T > struct add_pointer { public: typedef typename boost::detail::add_pointer_impl<T>::type type; }; > >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 71 "/usr/include/boost/type_traits/add_pointer.hpp" 2 3 4 ># 23 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/type_traits/is_pod.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/is_pod.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_scalar.hpp" 1 3 4 ># 13 "/usr/include/boost/type_traits/is_scalar.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_enum.hpp" 1 3 4 ># 32 "/usr/include/boost/type_traits/is_enum.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 33 "/usr/include/boost/type_traits/is_enum.hpp" 2 3 4 > >namespace boost { ># 181 "/usr/include/boost/type_traits/is_enum.hpp" 3 4 >template< typename T > struct is_enum : public ::boost::integral_constant<bool,__is_enum(T)> { public: }; > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 188 "/usr/include/boost/type_traits/is_enum.hpp" 2 3 4 ># 14 "/usr/include/boost/type_traits/is_scalar.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 21 "/usr/include/boost/type_traits/is_scalar.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct is_scalar_impl >{ > static const bool value = (::boost::type_traits::ice_or< ::boost::is_arithmetic<T>::value, ::boost::is_enum<T>::value, ::boost::is_pointer<T>::value, ::boost::is_member_pointer<T>::value >::value) > > > > > > ; >}; > > > >template <> struct is_scalar_impl<void>{ static const bool value = false; }; > >template <> struct is_scalar_impl<void const>{ static const bool value = false; }; >template <> struct is_scalar_impl<void volatile>{ static const bool value = false; }; >template <> struct is_scalar_impl<void const volatile>{ static const bool value = false; }; > > >} > >template< typename T > struct is_scalar : public ::boost::integral_constant<bool,::boost::detail::is_scalar_impl<T>::value> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 54 "/usr/include/boost/type_traits/is_scalar.hpp" 2 3 4 ># 15 "/usr/include/boost/type_traits/is_pod.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 22 "/usr/include/boost/type_traits/is_pod.hpp" 2 3 4 > > > > > > > >namespace boost { > > >template< typename T > struct is_POD; > >namespace detail { > > > >template <typename T> struct is_pod_impl >{ > static const bool value = (::boost::type_traits::ice_or< ::boost::is_scalar<T>::value, ::boost::is_void<T>::value, __is_pod(T) >::value) > > > > > > ; >}; > > >template <typename T, std::size_t sz> >struct is_pod_impl<T[sz]> > : public is_pod_impl<T> >{ >}; ># 124 "/usr/include/boost/type_traits/is_pod.hpp" 3 4 >template<> struct is_pod_impl< void > { public: static const bool value = (true); }; > > >template<> struct is_pod_impl< void const > { public: static const bool value = (true); }; >template<> struct is_pod_impl< void volatile > { public: static const bool value = (true); }; >template<> struct is_pod_impl< void const volatile > { public: static const bool value = (true); }; > > >} > >template< typename T > struct is_pod : public ::boost::integral_constant<bool,::boost::detail::is_pod_impl<T>::value> { public: }; > > >template< typename T > struct is_POD : public ::boost::integral_constant<bool,::boost::is_pod<T>::value> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 142 "/usr/include/boost/type_traits/is_pod.hpp" 2 3 4 ># 27 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/mpl/always.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/always.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Value > struct always >{ > template< > typename T > , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > > > struct apply > { > typedef Value type; > }; >}; > > > >}} ># 34 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/apply.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_fwd.hpp" 1 3 4 ># 31 "/usr/include/boost/mpl/apply_fwd.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/apply_fwd.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/apply_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename F, typename T1 = na, typename T2 = na, typename T3 = na > , typename T4 = na, typename T5 = na > > >struct apply; > >template< > typename F > > >struct apply0; > >template< > typename F, typename T1 > > >struct apply1; > >template< > typename F, typename T1, typename T2 > > >struct apply2; > >template< > typename F, typename T1, typename T2, typename T3 > > >struct apply3; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > > >struct apply4; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct apply5; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 32 "/usr/include/boost/mpl/apply_fwd.hpp" 2 3 4 ># 23 "/usr/include/boost/mpl/apply.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/apply_wrap.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/has_apply.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/has_apply.hpp" 3 4 ># 1 "/usr/include/boost/mpl/has_xxx.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/has_xxx.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/type_wrapper.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/type_wrapper.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >template< typename T > struct type_wrapper >{ > typedef T type; >}; > > > > > > >template< typename T > struct wrapped_type; > >template< typename T > struct wrapped_type< type_wrapper<T> > >{ > typedef T type; >}; > > > > > > > >}}} ># 22 "/usr/include/boost/mpl/has_xxx.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/aux_/config/has_xxx.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/has_xxx.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/msvc_typename.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/has_xxx.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/preprocessor/array/elem.hpp" 1 3 4 ># 15 "/usr/include/boost/preprocessor/array/elem.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/array/data.hpp" 1 3 4 ># 16 "/usr/include/boost/preprocessor/array/elem.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/array/size.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/array/elem.hpp" 2 3 4 ># 31 "/usr/include/boost/mpl/has_xxx.hpp" 2 3 4 > > ># 1 "/usr/include/boost/preprocessor/repetition/enum_params.hpp" 1 3 4 ># 34 "/usr/include/boost/mpl/has_xxx.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/repetition/enum_trailing_params.hpp" 1 3 4 ># 35 "/usr/include/boost/mpl/has_xxx.hpp" 2 3 4 ># 18 "/usr/include/boost/mpl/aux_/has_apply.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/has_apply.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/has_apply.hpp" 2 3 4 > >namespace boost { namespace mpl { namespace aux { > >template< typename T, typename fallback_ = boost::mpl::bool_<false> > struct has_apply { struct gcc_3_2_wknd { template< typename U > static boost::mpl::aux::yes_tag test( boost::mpl::aux::type_wrapper<U> const volatile* , boost::mpl::aux::type_wrapper<typename U::apply>* = 0 ); static boost::mpl::aux::no_tag test(...); }; typedef boost::mpl::aux::type_wrapper<T> t_; static const bool value = sizeof(gcc_3_2_wknd::test(static_cast<t_*>(0))) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_<value> type; }; > > > > > > > >}}} ># 24 "/usr/include/boost/mpl/apply_wrap.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/aux_/msvc_never_true.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/apply_wrap.hpp" 2 3 4 ># 34 "/usr/include/boost/mpl/apply_wrap.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/apply_wrap.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/apply_wrap.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename F > > , typename has_apply_ = typename aux::has_apply<F>::type > > > >struct apply_wrap0 > > : F::template apply< > >{ >}; > >template< typename F > >struct apply_wrap0< F,true_ > > : F::apply >{ >}; > >template< > typename F, typename T1 > > > >struct apply_wrap1 > > : F::template apply<T1> >{ >}; > >template< > typename F, typename T1, typename T2 > > > >struct apply_wrap2 > > : F::template apply< T1,T2 > >{ >}; > >template< > typename F, typename T1, typename T2, typename T3 > > > >struct apply_wrap3 > > : F::template apply< T1,T2,T3 > >{ >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > > > >struct apply_wrap4 > > : F::template apply< T1,T2,T3,T4 > >{ >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > > >struct apply_wrap5 > > : F::template apply< T1,T2,T3,T4,T5 > >{ >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 35 "/usr/include/boost/mpl/apply_wrap.hpp" 2 3 4 ># 24 "/usr/include/boost/mpl/apply.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/placeholders.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/apply.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/lambda.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/lambda.hpp" 3 4 ># 1 "/usr/include/boost/mpl/bind.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/bind.hpp" 3 4 ># 1 "/usr/include/boost/mpl/bind_fwd.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/bind_fwd.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/bind.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/bind_fwd.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/bind_fwd.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/bind_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename F, typename T1 = na, typename T2 = na, typename T3 = na > , typename T4 = na, typename T5 = na > > >struct bind; > >template< > typename F > > >struct bind0; > >template< > typename F, typename T1 > > >struct bind1; > >template< > typename F, typename T1, typename T2 > > >struct bind2; > >template< > typename F, typename T1, typename T2, typename T3 > > >struct bind3; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > > >struct bind4; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct bind5; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 33 "/usr/include/boost/mpl/bind_fwd.hpp" 2 3 4 ># 24 "/usr/include/boost/mpl/bind.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/placeholders.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/bind.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/next.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/next.hpp" 3 4 ># 1 "/usr/include/boost/mpl/next_prior.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/next_prior.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/common_name_wknd.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/next_prior.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > > > > >template< > typename T = na > > >struct next >{ > typedef typename T::next type; > >}; > >template< > typename T = na > > >struct prior >{ > typedef typename T::prior type; > >}; > >template<> struct next< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : next< T1 > { }; }; template< typename Tag > struct lambda< next< na > , Tag , int_<-1> > { typedef false_ is_le; typedef next< na > result_; typedef next< na > type; }; namespace aux { template< typename T1 > struct template_arity< next< T1 > > : int_<1> { }; template<> struct template_arity< next< na > > : int_<-1> { }; } >template<> struct prior< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : prior< T1 > { }; }; template< typename Tag > struct lambda< prior< na > , Tag , int_<-1> > { typedef false_ is_le; typedef prior< na > result_; typedef prior< na > type; }; namespace aux { template< typename T1 > struct template_arity< prior< T1 > > : int_<1> { }; template<> struct template_arity< prior< na > > : int_<-1> { }; } > >}} ># 18 "/usr/include/boost/mpl/next.hpp" 2 3 4 ># 26 "/usr/include/boost/mpl/bind.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/protect.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/protect.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T = na > , int not_le_ = 0 > > >struct protect : T >{ > > > > typedef protect type; > >}; ># 48 "/usr/include/boost/mpl/protect.hpp" 3 4 >template<> struct protect< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : protect< T1 > { }; }; > >namespace aux { template< typename T1 > struct template_arity< protect< T1 > > : int_<1> { }; template<> struct template_arity< protect< na > > : int_<-1> { }; } > > >}} ># 27 "/usr/include/boost/mpl/bind.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 28 "/usr/include/boost/mpl/bind.hpp" 2 3 4 ># 50 "/usr/include/boost/mpl/bind.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/bind.hpp" 1 3 4 ># 13 "/usr/include/boost/mpl/aux_/preprocessed/gcc/bind.hpp" 3 4 >namespace boost { namespace mpl { > >namespace aux { > >template< > typename T, typename U1, typename U2, typename U3, typename U4 > , typename U5 > > >struct resolve_bind_arg >{ > typedef T type; >}; > >template< > typename T > , typename Arg > > >struct replace_unnamed_arg >{ > typedef Arg next; > typedef T type; >}; > >template< > typename Arg > > >struct replace_unnamed_arg< arg< -1 >, Arg > >{ > typedef typename Arg::next next; > typedef Arg type; >}; > >template< > int N, typename U1, typename U2, typename U3, typename U4, typename U5 > > >struct resolve_bind_arg< arg<N>, U1, U2, U3, U4, U5 > >{ > typedef typename apply_wrap5<mpl::arg<N>, U1, U2, U3, U4, U5>::type type; >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename U1, typename U2, typename U3, typename U4 > , typename U5 > > >struct resolve_bind_arg< bind< F,T1,T2,T3,T4,T5 >, U1, U2, U3, U4, U5 > >{ > typedef bind< F,T1,T2,T3,T4,T5 > f_; > typedef typename apply_wrap5< f_,U1,U2,U3,U4,U5 >::type type; >}; > >} > >template< > typename F > > >struct bind0 >{ > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > private: > typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0; > typedef typename r0::type a0; > typedef typename r0::next n1; > typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_; > > public: > typedef typename apply_wrap0< > f_ > >::type type; > > }; >}; > >namespace aux { > >template< > typename F, typename U1, typename U2, typename U3, typename U4 > , typename U5 > > >struct resolve_bind_arg< > bind0<F>, U1, U2, U3, U4, U5 > > >{ > typedef bind0<F> f_; > typedef typename apply_wrap5< f_,U1,U2,U3,U4,U5 >::type type; >}; > >} > > >namespace aux { template< typename T1 > struct template_arity< bind0< T1> > : int_<1> { }; } > >template< > typename F > > >struct bind< F,na,na,na,na,na > > : bind0<F> >{ >}; > >template< > typename F, typename T1 > > >struct bind1 >{ > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > private: > typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0; > typedef typename r0::type a0; > typedef typename r0::next n1; > typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_; > > typedef aux::replace_unnamed_arg< T1,n1 > r1; > typedef typename r1::type a1; > typedef typename r1::next n2; > typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1; > > public: > typedef typename apply_wrap1< > f_ > , typename t1::type > >::type type; > > }; >}; > >namespace aux { > >template< > typename F, typename T1, typename U1, typename U2, typename U3 > , typename U4, typename U5 > > >struct resolve_bind_arg< > bind1< F,T1 >, U1, U2, U3, U4, U5 > > >{ > typedef bind1< F,T1 > f_; > typedef typename apply_wrap5< f_,U1,U2,U3,U4,U5 >::type type; >}; > >} > > >namespace aux { template< typename T1 , typename T2 > struct template_arity< bind1< T1 , T2> > : int_<2> { }; } > >template< > typename F, typename T1 > > >struct bind< F,T1,na,na,na,na > > : bind1< F,T1 > >{ >}; > >template< > typename F, typename T1, typename T2 > > >struct bind2 >{ > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > private: > typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0; > typedef typename r0::type a0; > typedef typename r0::next n1; > typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_; > > typedef aux::replace_unnamed_arg< T1,n1 > r1; > typedef typename r1::type a1; > typedef typename r1::next n2; > typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1; > > typedef aux::replace_unnamed_arg< T2,n2 > r2; > typedef typename r2::type a2; > typedef typename r2::next n3; > typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2; > > public: > typedef typename apply_wrap2< > f_ > , typename t1::type, typename t2::type > >::type type; > > }; >}; > >namespace aux { > >template< > typename F, typename T1, typename T2, typename U1, typename U2 > , typename U3, typename U4, typename U5 > > >struct resolve_bind_arg< > bind2< F,T1,T2 >, U1, U2, U3, U4, U5 > > >{ > typedef bind2< F,T1,T2 > f_; > typedef typename apply_wrap5< f_,U1,U2,U3,U4,U5 >::type type; >}; > >} > > >namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< bind2< T1 , T2 , T3> > : int_<3> { }; } > >template< > typename F, typename T1, typename T2 > > >struct bind< F,T1,T2,na,na,na > > : bind2< F,T1,T2 > >{ >}; > >template< > typename F, typename T1, typename T2, typename T3 > > >struct bind3 >{ > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > private: > typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0; > typedef typename r0::type a0; > typedef typename r0::next n1; > typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_; > > typedef aux::replace_unnamed_arg< T1,n1 > r1; > typedef typename r1::type a1; > typedef typename r1::next n2; > typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1; > > typedef aux::replace_unnamed_arg< T2,n2 > r2; > typedef typename r2::type a2; > typedef typename r2::next n3; > typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2; > > typedef aux::replace_unnamed_arg< T3,n3 > r3; > typedef typename r3::type a3; > typedef typename r3::next n4; > typedef aux::resolve_bind_arg< a3,U1,U2,U3,U4,U5 > t3; > > public: > typedef typename apply_wrap3< > f_ > , typename t1::type, typename t2::type, typename t3::type > >::type type; > > }; >}; > >namespace aux { > >template< > typename F, typename T1, typename T2, typename T3, typename U1 > , typename U2, typename U3, typename U4, typename U5 > > >struct resolve_bind_arg< > bind3< F,T1,T2,T3 >, U1, U2, U3, U4, U5 > > >{ > typedef bind3< F,T1,T2,T3 > f_; > typedef typename apply_wrap5< f_,U1,U2,U3,U4,U5 >::type type; >}; > >} > > >namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 > struct template_arity< bind3< T1 , T2 , T3 , T4> > : int_<4> { }; } > >template< > typename F, typename T1, typename T2, typename T3 > > >struct bind< F,T1,T2,T3,na,na > > : bind3< F,T1,T2,T3 > >{ >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > > >struct bind4 >{ > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > private: > typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0; > typedef typename r0::type a0; > typedef typename r0::next n1; > typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_; > > typedef aux::replace_unnamed_arg< T1,n1 > r1; > typedef typename r1::type a1; > typedef typename r1::next n2; > typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1; > > typedef aux::replace_unnamed_arg< T2,n2 > r2; > typedef typename r2::type a2; > typedef typename r2::next n3; > typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2; > > typedef aux::replace_unnamed_arg< T3,n3 > r3; > typedef typename r3::type a3; > typedef typename r3::next n4; > typedef aux::resolve_bind_arg< a3,U1,U2,U3,U4,U5 > t3; > > typedef aux::replace_unnamed_arg< T4,n4 > r4; > typedef typename r4::type a4; > typedef typename r4::next n5; > typedef aux::resolve_bind_arg< a4,U1,U2,U3,U4,U5 > t4; > > public: > typedef typename apply_wrap4< > f_ > , typename t1::type, typename t2::type, typename t3::type > , typename t4::type > >::type type; > > }; >}; > >namespace aux { > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename U1, typename U2, typename U3, typename U4, typename U5 > > >struct resolve_bind_arg< > bind4< F,T1,T2,T3,T4 >, U1, U2, U3, U4, U5 > > >{ > typedef bind4< F,T1,T2,T3,T4 > f_; > typedef typename apply_wrap5< f_,U1,U2,U3,U4,U5 >::type type; >}; > >} > > >namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct template_arity< bind4< T1 , T2 , T3 , T4 , T5> > : int_<5> { }; } > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > > >struct bind< F,T1,T2,T3,T4,na > > : bind4< F,T1,T2,T3,T4 > >{ >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct bind5 >{ > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > private: > typedef aux::replace_unnamed_arg< F, mpl::arg<1> > r0; > typedef typename r0::type a0; > typedef typename r0::next n1; > typedef typename aux::resolve_bind_arg< a0,U1,U2,U3,U4,U5 >::type f_; > > typedef aux::replace_unnamed_arg< T1,n1 > r1; > typedef typename r1::type a1; > typedef typename r1::next n2; > typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1; > > typedef aux::replace_unnamed_arg< T2,n2 > r2; > typedef typename r2::type a2; > typedef typename r2::next n3; > typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2; > > typedef aux::replace_unnamed_arg< T3,n3 > r3; > typedef typename r3::type a3; > typedef typename r3::next n4; > typedef aux::resolve_bind_arg< a3,U1,U2,U3,U4,U5 > t3; > > typedef aux::replace_unnamed_arg< T4,n4 > r4; > typedef typename r4::type a4; > typedef typename r4::next n5; > typedef aux::resolve_bind_arg< a4,U1,U2,U3,U4,U5 > t4; > > typedef aux::replace_unnamed_arg< T5,n5 > r5; > typedef typename r5::type a5; > typedef typename r5::next n6; > typedef aux::resolve_bind_arg< a5,U1,U2,U3,U4,U5 > t5; > > public: > typedef typename apply_wrap5< > f_ > , typename t1::type, typename t2::type, typename t3::type > , typename t4::type, typename t5::type > >::type type; > > }; >}; > >namespace aux { > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename U1, typename U2, typename U3, typename U4 > , typename U5 > > >struct resolve_bind_arg< > bind5< F,T1,T2,T3,T4,T5 >, U1, U2, U3, U4, U5 > > >{ > typedef bind5< F,T1,T2,T3,T4,T5 > f_; > typedef typename apply_wrap5< f_,U1,U2,U3,U4,U5 >::type type; >}; > >} > > >namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > struct template_arity< bind5< T1 , T2 , T3 , T4 , T5 , T6> > : int_<6> { }; } > > > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct bind > : bind5< F,T1,T2,T3,T4,T5 > >{ >}; > > >template< template< typename T1, typename T2, typename T3 > class F, typename Tag > >struct quote3; > >template< typename T1, typename T2, typename T3 > struct if_; > >template< > typename Tag, typename T1, typename T2, typename T3 > > >struct bind3< > quote3< if_,Tag > > , T1, T2, T3 > > >{ > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > private: > typedef mpl::arg<1> n1; > typedef aux::replace_unnamed_arg< T1,n1 > r1; > typedef typename r1::type a1; > typedef typename r1::next n2; > typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1; > > typedef aux::replace_unnamed_arg< T2,n2 > r2; > typedef typename r2::type a2; > typedef typename r2::next n3; > typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2; > > typedef aux::replace_unnamed_arg< T3,n3 > r3; > typedef typename r3::type a3; > typedef typename r3::next n4; > typedef aux::resolve_bind_arg< a3,U1,U2,U3,U4,U5 > t3; > > typedef typename if_< > typename t1::type > , t2, t3 > >::type f_; > > public: > typedef typename f_::type type; > }; >}; > >template< > template< typename T1, typename T2, typename T3 > class F, typename Tag > > >struct quote3; > >template< typename T1, typename T2, typename T3 > struct eval_if; > >template< > typename Tag, typename T1, typename T2, typename T3 > > >struct bind3< > quote3< eval_if,Tag > > , T1, T2, T3 > > >{ > template< > typename U1 = na, typename U2 = na, typename U3 = na > , typename U4 = na, typename U5 = na > > > struct apply > { > private: > typedef mpl::arg<1> n1; > typedef aux::replace_unnamed_arg< T1,n1 > r1; > typedef typename r1::type a1; > typedef typename r1::next n2; > typedef aux::resolve_bind_arg< a1,U1,U2,U3,U4,U5 > t1; > > typedef aux::replace_unnamed_arg< T2,n2 > r2; > typedef typename r2::type a2; > typedef typename r2::next n3; > typedef aux::resolve_bind_arg< a2,U1,U2,U3,U4,U5 > t2; > > typedef aux::replace_unnamed_arg< T3,n3 > r3; > typedef typename r3::type a3; > typedef typename r3::next n4; > typedef aux::resolve_bind_arg< a3,U1,U2,U3,U4,U5 > t3; > > typedef typename eval_if< > typename t1::type > , t2, t3 > >::type f_; > > public: > typedef typename f_::type type; > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 51 "/usr/include/boost/mpl/bind.hpp" 2 3 4 ># 19 "/usr/include/boost/mpl/lambda.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/aux_/full_lambda.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/full_lambda.hpp" 3 4 ># 1 "/usr/include/boost/mpl/bind_fwd.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/aux_/full_lambda.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/quote.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/quote.hpp" 3 4 ># 1 "/usr/include/boost/mpl/void.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/void.hpp" 3 4 >namespace mpl_ { > > > > > >struct void_ { typedef void_ type; }; > >} > >namespace boost { namespace mpl { > >template< typename T > >struct is_void_ > : false_ >{ > > > >}; > >template<> >struct is_void_<void_> > : true_ >{ > > > >}; > >template< typename T > >struct is_not_void_ > : true_ >{ > > > >}; > >template<> >struct is_not_void_<void_> > : false_ >{ > > > >}; > >template<> struct is_void_< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : is_void_< T1 > { }; }; template< typename Tag > struct lambda< is_void_< na > , Tag , int_<-1> > { typedef false_ is_le; typedef is_void_< na > result_; typedef is_void_< na > type; }; namespace aux { template< typename T1 > struct template_arity< is_void_< T1 > > : int_<1> { }; template<> struct template_arity< is_void_< na > > : int_<-1> { }; } >template<> struct is_not_void_< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : is_not_void_< T1 > { }; }; template< typename Tag > struct lambda< is_not_void_< na > , Tag , int_<-1> > { typedef false_ is_le; typedef is_not_void_< na > result_; typedef is_not_void_< na > type; }; namespace aux { template< typename T1 > struct template_arity< is_not_void_< T1 > > : int_<1> { }; template<> struct template_arity< is_not_void_< na > > : int_<-1> { }; } > >}} ># 23 "/usr/include/boost/mpl/quote.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/has_type.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/has_type.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { >template< typename T, typename fallback_ = boost::mpl::bool_<true> > struct has_type { struct gcc_3_2_wknd { template< typename U > static boost::mpl::aux::yes_tag test( boost::mpl::aux::type_wrapper<U> const volatile* , boost::mpl::aux::type_wrapper<typename U::type>* = 0 ); static boost::mpl::aux::no_tag test(...); }; typedef boost::mpl::aux::type_wrapper<T> t_; static const bool value = sizeof(gcc_3_2_wknd::test(static_cast<t_*>(0))) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_<value> type; }; >}}} ># 24 "/usr/include/boost/mpl/quote.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/aux_/config/bcc.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/quote.hpp" 2 3 4 ># 45 "/usr/include/boost/mpl/quote.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/quote.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/quote.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename T, bool has_type_ > >struct quote_impl >{ > typedef typename T::type type; >}; > >template< typename T > >struct quote_impl< T,false > >{ > typedef T type; >}; > >template< > template< typename P1 > class F > , typename Tag = void_ > > >struct quote1 >{ > template< typename U1 > struct apply > > : quote_impl< > F<U1> > , aux::has_type< F<U1> >::value > > > > { > }; >}; > >template< > template< typename P1, typename P2 > class F > , typename Tag = void_ > > >struct quote2 >{ > template< typename U1, typename U2 > struct apply > > : quote_impl< > F< U1,U2 > > , aux::has_type< F< U1,U2 > >::value > > > > { > }; >}; > >template< > template< typename P1, typename P2, typename P3 > class F > , typename Tag = void_ > > >struct quote3 >{ > template< typename U1, typename U2, typename U3 > struct apply > > : quote_impl< > F< U1,U2,U3 > > , aux::has_type< F< U1,U2,U3 > >::value > > > > { > }; >}; > >template< > template< typename P1, typename P2, typename P3, typename P4 > class F > , typename Tag = void_ > > >struct quote4 >{ > template< > typename U1, typename U2, typename U3, typename U4 > > > struct apply > > : quote_impl< > F< U1,U2,U3,U4 > > , aux::has_type< F< U1,U2,U3,U4 > >::value > > > > { > }; >}; > >template< > template< > typename P1, typename P2, typename P3, typename P4 > , typename P5 > > > class F > , typename Tag = void_ > > >struct quote5 >{ > template< > typename U1, typename U2, typename U3, typename U4 > , typename U5 > > > struct apply > > : quote_impl< > F< U1,U2,U3,U4,U5 > > , aux::has_type< F< U1,U2,U3,U4,U5 > >::value > > > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 46 "/usr/include/boost/mpl/quote.hpp" 2 3 4 ># 26 "/usr/include/boost/mpl/aux_/full_lambda.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/arg.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/aux_/full_lambda.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/aux_/template_arity.hpp" 1 3 4 ># 43 "/usr/include/boost/mpl/aux_/template_arity.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/template_arity.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/template_arity.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { >template< int N > struct arity_tag >{ > typedef char (&type)[N + 1]; >}; > >template< > int C1, int C2, int C3, int C4, int C5, int C6 > > >struct max_arity >{ > static const int value = ( C6 > 0 ? C6 : ( C5 > 0 ? C5 : ( C4 > 0 ? C4 : ( C3 > 0 ? C3 : ( C2 > 0 ? C2 : ( C1 > 0 ? C1 : -1 ) ) ) ) ) ) > > ; >}; > >arity_tag<0>::type arity_helper(...); > >template< > template< typename P1 > class F > , typename T1 > > >typename arity_tag<1>::type >arity_helper(type_wrapper< F<T1> >, arity_tag<1>); > >template< > template< typename P1, typename P2 > class F > , typename T1, typename T2 > > >typename arity_tag<2>::type >arity_helper(type_wrapper< F< T1,T2 > >, arity_tag<2>); > >template< > template< typename P1, typename P2, typename P3 > class F > , typename T1, typename T2, typename T3 > > >typename arity_tag<3>::type >arity_helper(type_wrapper< F< T1,T2,T3 > >, arity_tag<3>); > >template< > template< typename P1, typename P2, typename P3, typename P4 > class F > , typename T1, typename T2, typename T3, typename T4 > > >typename arity_tag<4>::type >arity_helper(type_wrapper< F< T1,T2,T3,T4 > >, arity_tag<4>); > >template< > template< > typename P1, typename P2, typename P3, typename P4 > , typename P5 > > > class F > , typename T1, typename T2, typename T3, typename T4, typename T5 > > >typename arity_tag<5>::type >arity_helper(type_wrapper< F< T1,T2,T3,T4,T5 > >, arity_tag<5>); > >template< > template< > typename P1, typename P2, typename P3, typename P4 > , typename P5, typename P6 > > > class F > , typename T1, typename T2, typename T3, typename T4, typename T5 > , typename T6 > > >typename arity_tag<6>::type >arity_helper(type_wrapper< F< T1,T2,T3,T4,T5,T6 > >, arity_tag<6>); >template< typename F, int N > >struct template_arity_impl >{ > static const int value = sizeof(::boost::mpl::aux::arity_helper(type_wrapper<F>(), arity_tag<N>())) - 1 > > ; >}; > >template< typename F > >struct template_arity >{ > static const int value = ( max_arity< template_arity_impl< F,1 >::value, template_arity_impl< F,2 >::value, template_arity_impl< F,3 >::value, template_arity_impl< F,4 >::value, template_arity_impl< F,5 >::value, template_arity_impl< F,6 >::value >::value ) > > ; > typedef mpl::int_<value> type; >}; > >}}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 44 "/usr/include/boost/mpl/aux_/template_arity.hpp" 2 3 4 ># 30 "/usr/include/boost/mpl/aux_/full_lambda.hpp" 2 3 4 ># 44 "/usr/include/boost/mpl/aux_/full_lambda.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/full_lambda.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/full_lambda.hpp" 3 4 >namespace boost { namespace mpl { > >namespace aux { > >template< > bool C1 = false, bool C2 = false, bool C3 = false, bool C4 = false > , bool C5 = false > > >struct lambda_or > : true_ >{ >}; > >template<> >struct lambda_or< false,false,false,false,false > > : false_ >{ >}; > >} > >template< > typename T > , typename Tag > , typename Arity > > >struct lambda >{ > typedef false_ is_le; > typedef T result_; > typedef T type; >}; > >template< > typename T > > >struct is_lambda_expression > : lambda<T>::is_le >{ >}; > >template< int N, typename Tag > >struct lambda< arg<N>,Tag, int_< -1 > > >{ > typedef true_ is_le; > typedef mpl::arg<N> result_; > typedef mpl::protect<result_> type; >}; > >template< > typename F > , typename Tag > > >struct lambda< > bind0<F> > , Tag > , int_<1> > > >{ > typedef false_ is_le; > typedef bind0< > F > > result_; > > typedef result_ type; >}; > >namespace aux { > >template< > typename IsLE, typename Tag > , template< typename P1 > class F > , typename L1 > > >struct le_result1 >{ > typedef F< > typename L1::type > > result_; > > typedef result_ type; >}; > >template< > typename Tag > , template< typename P1 > class F > , typename L1 > > >struct le_result1< true_,Tag,F,L1 > >{ > typedef bind1< > quote1< F,Tag > > , typename L1::result_ > > result_; > > typedef mpl::protect<result_> type; >}; > >} > >template< > template< typename P1 > class F > , typename T1 > , typename Tag > > >struct lambda< > F<T1> > , Tag > , int_<1> > > >{ > typedef lambda< T1,Tag > l1; > typedef typename l1::is_le is_le1; > typedef typename aux::lambda_or< > is_le1::value > >::type is_le; > > typedef aux::le_result1< > is_le, Tag, F, l1 > > le_result_; > > typedef typename le_result_::result_ result_; > typedef typename le_result_::type type; >}; > >template< > typename F, typename T1 > , typename Tag > > >struct lambda< > bind1< F,T1 > > , Tag > , int_<2> > > >{ > typedef false_ is_le; > typedef bind1< > F > , T1 > > result_; > > typedef result_ type; >}; > >namespace aux { > >template< > typename IsLE, typename Tag > , template< typename P1, typename P2 > class F > , typename L1, typename L2 > > >struct le_result2 >{ > typedef F< > typename L1::type, typename L2::type > > result_; > > typedef result_ type; >}; > >template< > typename Tag > , template< typename P1, typename P2 > class F > , typename L1, typename L2 > > >struct le_result2< true_,Tag,F,L1,L2 > >{ > typedef bind2< > quote2< F,Tag > > , typename L1::result_, typename L2::result_ > > result_; > > typedef mpl::protect<result_> type; >}; > >} > >template< > template< typename P1, typename P2 > class F > , typename T1, typename T2 > , typename Tag > > >struct lambda< > F< T1,T2 > > , Tag > , int_<2> > > >{ > typedef lambda< T1,Tag > l1; > typedef lambda< T2,Tag > l2; > > typedef typename l1::is_le is_le1; > typedef typename l2::is_le is_le2; > > > typedef typename aux::lambda_or< > is_le1::value, is_le2::value > >::type is_le; > > typedef aux::le_result2< > is_le, Tag, F, l1, l2 > > le_result_; > > typedef typename le_result_::result_ result_; > typedef typename le_result_::type type; >}; > >template< > typename F, typename T1, typename T2 > , typename Tag > > >struct lambda< > bind2< F,T1,T2 > > , Tag > , int_<3> > > >{ > typedef false_ is_le; > typedef bind2< > F > , T1, T2 > > result_; > > typedef result_ type; >}; > >namespace aux { > >template< > typename IsLE, typename Tag > , template< typename P1, typename P2, typename P3 > class F > , typename L1, typename L2, typename L3 > > >struct le_result3 >{ > typedef F< > typename L1::type, typename L2::type, typename L3::type > > result_; > > typedef result_ type; >}; > >template< > typename Tag > , template< typename P1, typename P2, typename P3 > class F > , typename L1, typename L2, typename L3 > > >struct le_result3< true_,Tag,F,L1,L2,L3 > >{ > typedef bind3< > quote3< F,Tag > > , typename L1::result_, typename L2::result_, typename L3::result_ > > result_; > > typedef mpl::protect<result_> type; >}; > >} > >template< > template< typename P1, typename P2, typename P3 > class F > , typename T1, typename T2, typename T3 > , typename Tag > > >struct lambda< > F< T1,T2,T3 > > , Tag > , int_<3> > > >{ > typedef lambda< T1,Tag > l1; > typedef lambda< T2,Tag > l2; > typedef lambda< T3,Tag > l3; > > typedef typename l1::is_le is_le1; > typedef typename l2::is_le is_le2; > typedef typename l3::is_le is_le3; > > > typedef typename aux::lambda_or< > is_le1::value, is_le2::value, is_le3::value > >::type is_le; > > typedef aux::le_result3< > is_le, Tag, F, l1, l2, l3 > > le_result_; > > typedef typename le_result_::result_ result_; > typedef typename le_result_::type type; >}; > >template< > typename F, typename T1, typename T2, typename T3 > , typename Tag > > >struct lambda< > bind3< F,T1,T2,T3 > > , Tag > , int_<4> > > >{ > typedef false_ is_le; > typedef bind3< > F > , T1, T2, T3 > > result_; > > typedef result_ type; >}; > >namespace aux { > >template< > typename IsLE, typename Tag > , template< typename P1, typename P2, typename P3, typename P4 > class F > , typename L1, typename L2, typename L3, typename L4 > > >struct le_result4 >{ > typedef F< > typename L1::type, typename L2::type, typename L3::type > , typename L4::type > > result_; > > typedef result_ type; >}; > >template< > typename Tag > , template< typename P1, typename P2, typename P3, typename P4 > class F > , typename L1, typename L2, typename L3, typename L4 > > >struct le_result4< true_,Tag,F,L1,L2,L3,L4 > >{ > typedef bind4< > quote4< F,Tag > > , typename L1::result_, typename L2::result_, typename L3::result_ > , typename L4::result_ > > result_; > > typedef mpl::protect<result_> type; >}; > >} > >template< > template< typename P1, typename P2, typename P3, typename P4 > class F > , typename T1, typename T2, typename T3, typename T4 > , typename Tag > > >struct lambda< > F< T1,T2,T3,T4 > > , Tag > , int_<4> > > >{ > typedef lambda< T1,Tag > l1; > typedef lambda< T2,Tag > l2; > typedef lambda< T3,Tag > l3; > typedef lambda< T4,Tag > l4; > > typedef typename l1::is_le is_le1; > typedef typename l2::is_le is_le2; > typedef typename l3::is_le is_le3; > typedef typename l4::is_le is_le4; > > > typedef typename aux::lambda_or< > is_le1::value, is_le2::value, is_le3::value, is_le4::value > >::type is_le; > > typedef aux::le_result4< > is_le, Tag, F, l1, l2, l3, l4 > > le_result_; > > typedef typename le_result_::result_ result_; > typedef typename le_result_::type type; >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename Tag > > >struct lambda< > bind4< F,T1,T2,T3,T4 > > , Tag > , int_<5> > > >{ > typedef false_ is_le; > typedef bind4< > F > , T1, T2, T3, T4 > > result_; > > typedef result_ type; >}; > >namespace aux { > >template< > typename IsLE, typename Tag > , template< typename P1, typename P2, typename P3, typename P4, typename P5 > class F > , typename L1, typename L2, typename L3, typename L4, typename L5 > > >struct le_result5 >{ > typedef F< > typename L1::type, typename L2::type, typename L3::type > , typename L4::type, typename L5::type > > result_; > > typedef result_ type; >}; > >template< > typename Tag > , template< typename P1, typename P2, typename P3, typename P4, typename P5 > class F > , typename L1, typename L2, typename L3, typename L4, typename L5 > > >struct le_result5< true_,Tag,F,L1,L2,L3,L4,L5 > >{ > typedef bind5< > quote5< F,Tag > > , typename L1::result_, typename L2::result_, typename L3::result_ > , typename L4::result_, typename L5::result_ > > result_; > > typedef mpl::protect<result_> type; >}; > >} > >template< > template< > typename P1, typename P2, typename P3, typename P4 > , typename P5 > > > class F > , typename T1, typename T2, typename T3, typename T4, typename T5 > , typename Tag > > >struct lambda< > F< T1,T2,T3,T4,T5 > > , Tag > , int_<5> > > >{ > typedef lambda< T1,Tag > l1; > typedef lambda< T2,Tag > l2; > typedef lambda< T3,Tag > l3; > typedef lambda< T4,Tag > l4; > typedef lambda< T5,Tag > l5; > > typedef typename l1::is_le is_le1; > typedef typename l2::is_le is_le2; > typedef typename l3::is_le is_le3; > typedef typename l4::is_le is_le4; > typedef typename l5::is_le is_le5; > > > typedef typename aux::lambda_or< > is_le1::value, is_le2::value, is_le3::value, is_le4::value > , is_le5::value > >::type is_le; > > typedef aux::le_result5< > is_le, Tag, F, l1, l2, l3, l4, l5 > > le_result_; > > typedef typename le_result_::result_ result_; > typedef typename le_result_::type type; >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5 > , typename Tag > > >struct lambda< > bind5< F,T1,T2,T3,T4,T5 > > , Tag > , int_<6> > > >{ > typedef false_ is_le; > typedef bind5< > F > , T1, T2, T3, T4, T5 > > result_; > > typedef result_ type; >}; > > >template< typename T, typename Tag > >struct lambda< mpl::protect<T>,Tag, int_<1> > >{ > typedef false_ is_le; > typedef mpl::protect<T> result_; > typedef result_ type; >}; > > > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5 > , typename Tag > > >struct lambda< > bind< F,T1,T2,T3,T4,T5 > > , Tag > , int_<6> > > >{ > typedef false_ is_le; > typedef bind< F,T1,T2,T3,T4,T5 > result_; > typedef result_ type; >}; > >template< > typename F > , typename Tag1 > , typename Tag2 > , typename Arity > > >struct lambda< > lambda< F,Tag1,Arity > > , Tag2 > , int_<3> > > >{ > typedef lambda< F,Tag2 > l1; > typedef lambda< Tag1,Tag2 > l2; > typedef typename l1::is_le is_le; > typedef bind1< quote1<aux::template_arity>, typename l1::result_ > arity_; > typedef lambda< typename if_< is_le,arity_,Arity >::type, Tag2 > l3; > typedef aux::le_result3<is_le, Tag2, mpl::lambda, l1, l2, l3> le_result_; > typedef typename le_result_::result_ result_; > typedef typename le_result_::type type; >}; > >template<> struct lambda< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : lambda< T1 , T2 > { }; }; template< typename Tag > struct lambda< lambda< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef lambda< na , na > result_; typedef lambda< na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< lambda< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< lambda< na , na > > : int_<-1> { }; } > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 45 "/usr/include/boost/mpl/aux_/full_lambda.hpp" 2 3 4 ># 23 "/usr/include/boost/mpl/lambda.hpp" 2 3 4 ># 26 "/usr/include/boost/mpl/apply.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/apply.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/apply.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/apply.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename F > > >struct apply0 > > : apply_wrap0< > typename lambda<F>::type > > > >{ > > > > > >}; > >template< > typename F > > >struct apply< F,na,na,na,na,na > > : apply0<F> >{ >}; > >template< > typename F, typename T1 > > >struct apply1 > > : apply_wrap1< > typename lambda<F>::type > , T1 > > >{ > > > > > >}; > >template< > typename F, typename T1 > > >struct apply< F,T1,na,na,na,na > > : apply1< F,T1 > >{ >}; > >template< > typename F, typename T1, typename T2 > > >struct apply2 > > : apply_wrap2< > typename lambda<F>::type > , T1, T2 > > >{ > > > > > >}; > >template< > typename F, typename T1, typename T2 > > >struct apply< F,T1,T2,na,na,na > > : apply2< F,T1,T2 > >{ >}; > >template< > typename F, typename T1, typename T2, typename T3 > > >struct apply3 > > : apply_wrap3< > typename lambda<F>::type > , T1, T2, T3 > > >{ > > > > > >}; > >template< > typename F, typename T1, typename T2, typename T3 > > >struct apply< F,T1,T2,T3,na,na > > : apply3< F,T1,T2,T3 > >{ >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > > >struct apply4 > > : apply_wrap4< > typename lambda<F>::type > , T1, T2, T3, T4 > > >{ > > > > > >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > > >struct apply< F,T1,T2,T3,T4,na > > : apply4< F,T1,T2,T3,T4 > >{ >}; > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct apply5 > > : apply_wrap5< > typename lambda<F>::type > , T1, T2, T3, T4, T5 > > >{ > > > > > >}; > > > >template< > typename F, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct apply > : apply5< F,T1,T2,T3,T4,T5 > >{ >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 37 "/usr/include/boost/mpl/apply.hpp" 2 3 4 ># 35 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 > > ># 1 "/usr/include/boost/iterator/detail/config_def.hpp" 1 3 4 ># 38 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 > >namespace boost >{ > > > template <class I, class V, class TC, class R, class D> class iterator_facade; > > namespace detail > { > > > > struct always_bool2 > { > template <class T, class U> > struct apply > { > typedef bool type; > }; > }; > > > > > template < > class Facade1 > , class Facade2 > , class Return > > > struct enable_if_interoperable ># 80 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > : ::boost::iterators::enable_if< > mpl::or_< > is_convertible<Facade1, Facade2> > , is_convertible<Facade2, Facade1> > > > , Return > > > {}; > > > > > > > template < > class ValueParam > , class CategoryOrTraversal > , class Reference > , class Difference > > > struct iterator_facade_types > { > typedef typename facade_iterator_category< > CategoryOrTraversal, ValueParam, Reference > >::type iterator_category; > > typedef typename remove_const<ValueParam>::type value_type; > > > typedef typename mpl::eval_if< > boost::detail::iterator_writability_disabled<ValueParam,Reference> > , add_pointer<const value_type> > , add_pointer<value_type> > >::type pointer; ># 131 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > }; > > > > > > > > template <class Iterator> > class postfix_increment_proxy > { > typedef typename iterator_value<Iterator>::type value_type; > public: > explicit postfix_increment_proxy(Iterator const& x) > : stored_value(*x) > {} > > > > > > value_type& > operator*() const > { > return this->stored_value; > } > private: > mutable value_type stored_value; > }; > > > > > > template <class Iterator> > class writable_postfix_increment_proxy > { > typedef typename iterator_value<Iterator>::type value_type; > public: > explicit writable_postfix_increment_proxy(Iterator const& x) > : stored_value(*x) > , stored_iterator(x) > {} > > > > > > writable_postfix_increment_proxy const& > operator*() const > { > return *this; > } > > > operator value_type&() const > { > return stored_value; > } > > > template <class T> > T const& operator=(T const& x) const > { > *this->stored_iterator = x; > return x; > } > > > template <class T> > T& operator=(T& x) const > { > *this->stored_iterator = x; > return x; > } > > > operator Iterator const&() const > { > return stored_iterator; > } > > private: > mutable value_type stored_value; > Iterator stored_iterator; > }; ># 245 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > template <class Reference, class Value> > struct is_non_proxy_reference > : is_convertible< > typename remove_reference<Reference>::type > const volatile* > , Value const volatile* > > > {}; ># 270 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > template <class Iterator, class Value, class Reference, class CategoryOrTraversal> > struct postfix_increment_result > : mpl::eval_if< > mpl::and_< > > is_convertible<Reference,Value const&> > > > > , mpl::not_< > is_convertible< > typename iterator_category_to_traversal<CategoryOrTraversal>::type > , forward_traversal_tag > > > > > > > , mpl::if_< > is_non_proxy_reference<Reference,Value> > , postfix_increment_proxy<Iterator> > , writable_postfix_increment_proxy<Iterator> > > > , mpl::identity<Iterator> > > > {}; > > > > > > template <class Reference, class Pointer> > struct operator_arrow_dispatch > { > struct proxy > { > explicit proxy(Reference const & x) : m_ref(x) {} > Reference* operator->() { return boost::addressof(m_ref); } > > > operator Reference*() { return boost::addressof(m_ref); } > Reference m_ref; > }; > typedef proxy result_type; > static result_type apply(Reference const & x) > { > return result_type(x); > } > }; > > template <class T, class Pointer> > struct operator_arrow_dispatch<T&, Pointer> > { > typedef Pointer result_type; > static result_type apply(T& x) > { > return boost::addressof(x); > } > }; ># 340 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > template <class Iterator> > class operator_brackets_proxy > { > > > typedef typename Iterator::reference reference; > typedef typename Iterator::value_type value_type; > > public: > operator_brackets_proxy(Iterator const& iter) > : m_iter(iter) > {} > > operator reference() const > { > return *m_iter; > } > > operator_brackets_proxy& operator=(value_type const& val) > { > *m_iter = val; > return *this; > } > > private: > Iterator m_iter; > }; > > > > template <class ValueType, class Reference> > struct use_operator_brackets_proxy > : mpl::not_< > mpl::and_< > > > boost::is_POD<ValueType> > , iterator_writability_disabled<ValueType,Reference> > > > > > {}; > > template <class Iterator, class Value, class Reference> > struct operator_brackets_result > { > typedef typename mpl::if_< > use_operator_brackets_proxy<Value,Reference> > , operator_brackets_proxy<Iterator> > , Value > >::type type; > }; > > template <class Iterator> > operator_brackets_proxy<Iterator> make_operator_brackets_result(Iterator const& iter, mpl::true_) > { > return operator_brackets_proxy<Iterator>(iter); > } > > template <class Iterator> > typename Iterator::value_type make_operator_brackets_result(Iterator const& iter, mpl::false_) > { > return *iter; > } > > struct choose_difference_type > { > template <class I1, class I2> > struct apply > : ># 418 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > mpl::eval_if< > is_convertible<I2,I1> > , iterator_difference<I1> > , iterator_difference<I2> > > > > {}; > > }; > } ># 469 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > class iterator_core_access > { > > > > > > > template <class I, class V, class TC, class R, class D> friend class iterator_facade; > > > > > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > friend typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator ==( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs); > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > friend typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator !=( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs); > > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > friend typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator <( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs); > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > friend typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator >( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs); > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > friend typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator <=( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs); > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > friend typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator >=( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs); > > > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > friend typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::choose_difference_type,Derived1,Derived2>::type >::type operator -( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs) > > ; > > template <class Derived, class V, class TC, class R, class D> friend inline Derived operator+ (iterator_facade<Derived, V, TC, R, D> const& , typename Derived::difference_type) > > > > > ; > > template <class Derived, class V, class TC, class R, class D> friend inline Derived operator+ (typename Derived::difference_type , iterator_facade<Derived, V, TC, R, D> const&) > > > > > ; > > > > template <class Facade> > static typename Facade::reference dereference(Facade const& f) > { > return f.dereference(); > } > > template <class Facade> > static void increment(Facade& f) > { > f.increment(); > } > > template <class Facade> > static void decrement(Facade& f) > { > f.decrement(); > } > > template <class Facade1, class Facade2> > static bool equal(Facade1 const& f1, Facade2 const& f2, mpl::true_) > { > return f1.equal(f2); > } > > template <class Facade1, class Facade2> > static bool equal(Facade1 const& f1, Facade2 const& f2, mpl::false_) > { > return f2.equal(f1); > } > > template <class Facade> > static void advance(Facade& f, typename Facade::difference_type n) > { > f.advance(n); > } > > template <class Facade1, class Facade2> > static typename Facade1::difference_type distance_from( > Facade1 const& f1, Facade2 const& f2, mpl::true_) > { > return -f1.distance_to(f2); > } > > template <class Facade1, class Facade2> > static typename Facade2::difference_type distance_from( > Facade1 const& f1, Facade2 const& f2, mpl::false_) > { > return f2.distance_to(f1); > } > > > > > template <class I, class V, class TC, class R, class D> > static I& derived(iterator_facade<I,V,TC,R,D>& facade) > { > return *static_cast<I*>(&facade); > } > > template <class I, class V, class TC, class R, class D> > static I const& derived(iterator_facade<I,V,TC,R,D> const& facade) > { > return *static_cast<I const*>(&facade); > } > > private: > > iterator_core_access(); > }; > > > > > > template < > class Derived > , class Value > , class CategoryOrTraversal > , class Reference = Value& > , class Difference = std::ptrdiff_t > > > class iterator_facade > > > > > > > { > private: > > > > Derived& derived() > { > return *static_cast<Derived*>(this); > } > > Derived const& derived() const > { > return *static_cast<Derived const*>(this); > } > > typedef boost::detail::iterator_facade_types< > Value, CategoryOrTraversal, Reference, Difference > > associated_types; > > typedef boost::detail::operator_arrow_dispatch< > Reference > , typename associated_types::pointer > > operator_arrow_dispatch_; > > protected: > > typedef iterator_facade<Derived,Value,CategoryOrTraversal,Reference,Difference> iterator_facade_; > > public: > > typedef typename associated_types::value_type value_type; > typedef Reference reference; > typedef Difference difference_type; > > typedef typename operator_arrow_dispatch_::result_type pointer; > > typedef typename associated_types::iterator_category iterator_category; > > reference operator*() const > { > return iterator_core_access::dereference(this->derived()); > } > > pointer operator->() const > { > return operator_arrow_dispatch_::apply(*this->derived()); > } > > typename boost::detail::operator_brackets_result<Derived,Value,reference>::type > operator[](difference_type n) const > { > typedef boost::detail::use_operator_brackets_proxy<Value,Reference> use_proxy; > > return boost::detail::make_operator_brackets_result<Derived>( > this->derived() + n > , use_proxy() > ); > } > > Derived& operator++() > { > iterator_core_access::increment(this->derived()); > return this->derived(); > } ># 675 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > Derived& operator--() > { > iterator_core_access::decrement(this->derived()); > return this->derived(); > } > > Derived operator--(int) > { > Derived tmp(this->derived()); > --*this; > return tmp; > } > > Derived& operator+=(difference_type n) > { > iterator_core_access::advance(this->derived(), n); > return this->derived(); > } > > Derived& operator-=(difference_type n) > { > iterator_core_access::advance(this->derived(), -n); > return this->derived(); > } > > Derived operator-(difference_type x) const > { > Derived result(this->derived()); > return result -= x; > } ># 717 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > }; > > > template <class I, class V, class TC, class R, class D> > inline typename boost::detail::postfix_increment_result<I,V,R,TC>::type > operator++( > iterator_facade<I,V,TC,R,D>& i > , int > ) > { > typename boost::detail::postfix_increment_result<I,V,R,TC>::type > tmp(*static_cast<I*>(&i)); > > ++i; > > return tmp; > } ># 832 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > inline typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator ==( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs) { static_assert(( is_interoperable< Derived1, Derived2 >::value ), "( is_interoperable< Derived1, Derived2 >::value )"); return iterator_core_access::equal( *static_cast<Derived1 const*>(&lhs) , *static_cast<Derived2 const*>(&rhs) , is_convertible<Derived2,Derived1>() ); } > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > inline typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator !=( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs) { static_assert(( is_interoperable< Derived1, Derived2 >::value ), "( is_interoperable< Derived1, Derived2 >::value )"); return ! iterator_core_access::equal( *static_cast<Derived1 const*>(&lhs) , *static_cast<Derived2 const*>(&rhs) , is_convertible<Derived2,Derived1>() ); } > > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > inline typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator <( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs) { static_assert(( is_interoperable< Derived1, Derived2 >::value ), "( is_interoperable< Derived1, Derived2 >::value )"); return 0 > iterator_core_access::distance_from( *static_cast<Derived1 const*>(&lhs) , *static_cast<Derived2 const*>(&rhs) , is_convertible<Derived2,Derived1>() ); } > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > inline typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator >( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs) { static_assert(( is_interoperable< Derived1, Derived2 >::value ), "( is_interoperable< Derived1, Derived2 >::value )"); return 0 < iterator_core_access::distance_from( *static_cast<Derived1 const*>(&lhs) , *static_cast<Derived2 const*>(&rhs) , is_convertible<Derived2,Derived1>() ); } > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > inline typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator <=( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs) { static_assert(( is_interoperable< Derived1, Derived2 >::value ), "( is_interoperable< Derived1, Derived2 >::value )"); return 0 >= iterator_core_access::distance_from( *static_cast<Derived1 const*>(&lhs) , *static_cast<Derived2 const*>(&rhs) , is_convertible<Derived2,Derived1>() ); } > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > inline typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::always_bool2,Derived1,Derived2>::type >::type operator >=( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs) { static_assert(( is_interoperable< Derived1, Derived2 >::value ), "( is_interoperable< Derived1, Derived2 >::value )"); return 0 <= iterator_core_access::distance_from( *static_cast<Derived1 const*>(&lhs) , *static_cast<Derived2 const*>(&rhs) , is_convertible<Derived2,Derived1>() ); } > > > > template < class Derived1, class V1, class TC1, class Reference1, class Difference1 , class Derived2, class V2, class TC2, class Reference2, class Difference2 > inline typename boost::detail::enable_if_interoperable< Derived1, Derived2 , typename mpl::apply2<boost::detail::choose_difference_type,Derived1,Derived2>::type >::type operator -( iterator_facade<Derived1, V1, TC1, Reference1, Difference1> const& lhs , iterator_facade<Derived2, V2, TC2, Reference2, Difference2> const& rhs) { static_assert(( is_interoperable< Derived1, Derived2 >::value ), "( is_interoperable< Derived1, Derived2 >::value )"); return iterator_core_access::distance_from( *static_cast<Derived1 const*>(&lhs) , *static_cast<Derived2 const*>(&rhs) , is_convertible<Derived2,Derived1>() ); } ># 858 "/usr/include/boost/iterator/iterator_facade.hpp" 3 4 >template <class Derived, class V, class TC, class R, class D> inline Derived operator+ ( iterator_facade<Derived, V, TC, R, D> const& i , typename Derived::difference_type n ) { Derived tmp(static_cast<Derived const&>(i)); return tmp += n; } > > > > >template <class Derived, class V, class TC, class R, class D> inline Derived operator+ ( typename Derived::difference_type n , iterator_facade<Derived, V, TC, R, D> const& i ) { Derived tmp(static_cast<Derived const&>(i)); return tmp += n; } > > > > > > >} > ># 1 "/usr/include/boost/iterator/detail/config_undef.hpp" 1 3 4 ># 873 "/usr/include/boost/iterator/iterator_facade.hpp" 2 3 4 ># 16 "/usr/include/boost/iterator/iterator_adaptor.hpp" 2 3 4 ># 30 "/usr/include/boost/iterator/iterator_adaptor.hpp" 3 4 ># 1 "/usr/include/boost/iterator/detail/config_def.hpp" 1 3 4 ># 31 "/usr/include/boost/iterator/iterator_adaptor.hpp" 2 3 4 > > > >namespace boost >{ > > > > struct use_default; > > > > > > template<class To> > struct is_convertible<use_default,To> > : mpl::false_ {}; > > > namespace detail > { ># 60 "/usr/include/boost/iterator/iterator_adaptor.hpp" 3 4 > struct enable_type; > } ># 142 "/usr/include/boost/iterator/iterator_adaptor.hpp" 3 4 > template<typename From, typename To> > struct enable_if_convertible > : iterators::enable_if< > is_convertible<From, To> > , boost::detail::enable_type > > > {}; > > > > > > > namespace detail > { > > > template <class T, class DefaultNullaryFn> > struct ia_dflt_help > : mpl::eval_if< > is_same<T, use_default> > , DefaultNullaryFn > , mpl::identity<T> > > > { > }; > > > > template < > class Derived > , class Base > , class Value > , class Traversal > , class Reference > , class Difference > > > struct iterator_adaptor_base > { > typedef iterator_facade< > Derived > > > , typename boost::detail::ia_dflt_help< > Value > , mpl::eval_if< > is_same<Reference,use_default> > , iterator_value<Base> > , remove_reference<Reference> > > > >::type > > > > > > > , typename boost::detail::ia_dflt_help< > Traversal > , iterator_traversal<Base> > >::type > > , typename boost::detail::ia_dflt_help< > Reference > , mpl::eval_if< > is_same<Value,use_default> > , iterator_reference<Base> > , add_reference<Value> > > > >::type > > , typename boost::detail::ia_dflt_help< > Difference, iterator_difference<Base> > >::type > > > type; > }; > > > template <class Tr1, class Tr2> > inline void iterator_adaptor_assert_traversal () > { > static_assert((is_convertible<Tr1, Tr2>::value), "(is_convertible<Tr1, Tr2>::value)"); > } > } ># 253 "/usr/include/boost/iterator/iterator_adaptor.hpp" 3 4 > template < > class Derived > , class Base > , class Value = use_default > , class Traversal = use_default > , class Reference = use_default > , class Difference = use_default > > > class iterator_adaptor > : public boost::detail::iterator_adaptor_base< > Derived, Base, Value, Traversal, Reference, Difference > >::type > { > friend class iterator_core_access; > > protected: > typedef typename boost::detail::iterator_adaptor_base< > Derived, Base, Value, Traversal, Reference, Difference > >::type super_t; > public: > iterator_adaptor() {} > > explicit iterator_adaptor(Base const &iter) > : m_iterator(iter) > { > } > > typedef Base base_type; > > Base const& base() const > { return m_iterator; } > > protected: > > typedef iterator_adaptor<Derived,Base,Value,Traversal,Reference,Difference> iterator_adaptor_; > > > > > Base const& base_reference() const > { return m_iterator; } > > Base& base_reference() > { return m_iterator; } > > private: > > > > > > > typename super_t::reference dereference() const > { return *m_iterator; } > > template < > class OtherDerived, class OtherIterator, class V, class C, class R, class D > > > bool equal(iterator_adaptor<OtherDerived, OtherIterator, V, C, R, D> const& x) const > { > > > > > return m_iterator == x.base(); > } > > typedef typename iterator_category_to_traversal< > typename super_t::iterator_category > >::type my_traversal; > > > > > void advance(typename super_t::difference_type n) > { > boost::detail::iterator_adaptor_assert_traversal<my_traversal, random_access_traversal_tag>(); > m_iterator += n; > } > > void increment() { ++m_iterator; } > > void decrement() > { > boost::detail::iterator_adaptor_assert_traversal<my_traversal, bidirectional_traversal_tag>(); > --m_iterator; > } > > template < > class OtherDerived, class OtherIterator, class V, class C, class R, class D > > > typename super_t::difference_type distance_to( > iterator_adaptor<OtherDerived, OtherIterator, V, C, R, D> const& y) const > { > boost::detail::iterator_adaptor_assert_traversal<my_traversal, random_access_traversal_tag>(); > > > > > return y.base() - m_iterator; > } > > > > private: > Base m_iterator; > }; > >} > ># 1 "/usr/include/boost/iterator/detail/config_undef.hpp" 1 3 4 ># 364 "/usr/include/boost/iterator/iterator_adaptor.hpp" 2 3 4 ># 13 "/usr/include/boost/iterator/reverse_iterator.hpp" 2 3 4 > >namespace boost >{ > > > > > template <class Iterator> > class reverse_iterator > : public iterator_adaptor< reverse_iterator<Iterator>, Iterator > > { > typedef iterator_adaptor< reverse_iterator<Iterator>, Iterator > super_t; > > friend class iterator_core_access; > > public: > reverse_iterator() {} > > explicit reverse_iterator(Iterator x) > : super_t(x) {} > > template<class OtherIterator> > reverse_iterator( > reverse_iterator<OtherIterator> const& r > , typename enable_if_convertible<OtherIterator, Iterator>::type* = 0 > ) > : super_t(r.base()) > {} > > private: > typename super_t::reference dereference() const { return *boost::prior(this->base()); } > > void increment() { --this->base_reference(); } > void decrement() { ++this->base_reference(); } > > void advance(typename super_t::difference_type n) > { > this->base_reference() += -n; > } > > template <class OtherIterator> > typename super_t::difference_type > distance_to(reverse_iterator<OtherIterator> const& y) const > { > return this->base_reference() - y.base(); > } > }; > > template <class BidirectionalIterator> > reverse_iterator<BidirectionalIterator> make_reverse_iterator(BidirectionalIterator x) > { > return reverse_iterator<BidirectionalIterator>(x); > } > >} ># 21 "/usr/include/boost/range/reverse_iterator.hpp" 2 3 4 > > >namespace boost >{ > > > > > template< typename C > > struct range_reverse_iterator > { > typedef reverse_iterator< > typename range_iterator<C>::type > type; > }; > > >} ># 20 "/usr/include/boost/range/rend.hpp" 2 3 4 > >namespace boost >{ ># 35 "/usr/include/boost/range/rend.hpp" 3 4 >template< class C > >inline typename range_reverse_iterator<C>::type >rend( C& c ) >{ > typedef typename range_reverse_iterator<C>::type > iter_type; > return iter_type( boost::begin( c ) ); >} > >template< class C > >inline typename range_reverse_iterator<const C>::type >rend( const C& c ) >{ > typedef typename range_reverse_iterator<const C>::type > iter_type; > return iter_type( boost::begin( c ) ); >} > > > >template< class T > >inline typename range_reverse_iterator<const T>::type >const_rend( const T& r ) >{ > return boost::rend( r ); >} > >} ># 79 "/usr/include/boost/foreach.hpp" 2 3 4 ># 1 "/usr/include/boost/range/rbegin.hpp" 1 3 4 ># 21 "/usr/include/boost/range/rbegin.hpp" 3 4 >namespace boost >{ ># 35 "/usr/include/boost/range/rbegin.hpp" 3 4 >template< class C > >inline typename range_reverse_iterator<C>::type >rbegin( C& c ) >{ > typedef typename range_reverse_iterator<C>::type > iter_type; > return iter_type( boost::end( c ) ); >} > >template< class C > >inline typename range_reverse_iterator<const C>::type >rbegin( const C& c ) >{ > typedef typename range_reverse_iterator<const C>::type > iter_type; > return iter_type( boost::end( c ) ); >} > > > >template< class T > >inline typename range_reverse_iterator<const T>::type >const_rbegin( const T& r ) >{ > return boost::rbegin( r ); >} > >} ># 80 "/usr/include/boost/foreach.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/type_traits/is_base_and_derived.hpp" 1 3 4 ># 24 "/usr/include/boost/type_traits/is_base_and_derived.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 25 "/usr/include/boost/type_traits/is_base_and_derived.hpp" 2 3 4 > >namespace boost { > >namespace detail { ># 222 "/usr/include/boost/type_traits/is_base_and_derived.hpp" 3 4 >template <typename B, typename D> >struct is_base_and_derived_impl >{ > typedef typename remove_cv<B>::type ncvB; > typedef typename remove_cv<D>::type ncvD; > > static const bool value = ((__is_base_of(B,D) && !is_same<B,D>::value) && ! ::boost::is_same<ncvB,ncvD>::value); >}; > >} > >template< typename Base, typename Derived > struct is_base_and_derived : public ::boost::integral_constant<bool,(::boost::detail::is_base_and_derived_impl<Base,Derived>::value)> { public: }; > > > > > > > >template< typename Base, typename Derived > struct is_base_and_derived< Base&,Derived > : public ::boost::integral_constant<bool,false> { public: }; >template< typename Base, typename Derived > struct is_base_and_derived< Base,Derived& > : public ::boost::integral_constant<bool,false> { public: }; >template< typename Base, typename Derived > struct is_base_and_derived< Base&,Derived& > : public ::boost::integral_constant<bool,false> { public: }; > > > > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 253 "/usr/include/boost/type_traits/is_base_and_derived.hpp" 2 3 4 ># 86 "/usr/include/boost/foreach.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/foreach_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/foreach_fwd.hpp" 3 4 >enum boost_foreach_argument_dependent_lookup_hack >{ > boost_foreach_argument_dependent_lookup_hack_value >}; > >namespace boost >{ > >namespace foreach >{ > > > > typedef boost_foreach_argument_dependent_lookup_hack tag; > > > > > > template<typename T> > struct is_lightweight_proxy; > > > > > > template<typename T> > struct is_noncopyable; > >} > >} ># 90 "/usr/include/boost/foreach.hpp" 2 3 4 ># 98 "/usr/include/boost/foreach.hpp" 3 4 >namespace boost >{ > > >template<typename T> >class iterator_range; > > >template<typename T> >class sub_range; > >namespace foreach >{ > > > > template<typename T> > inline std::pair<T, T> in_range(T begin, T end) > { > return std::make_pair(begin, end); > } > > > > > > template<typename T> > struct is_lightweight_proxy > : boost::mpl::false_ > { > }; > > > > > > template<typename T> > struct is_noncopyable > > : boost::mpl::or_< > boost::is_abstract<T> > , boost::is_base_and_derived<boost::noncopyable, T> > > > > > > > > > > { > }; > >} > >} ># 167 "/usr/include/boost/foreach.hpp" 3 4 >template<typename T> >inline boost::foreach::is_lightweight_proxy<T> * >boost_foreach_is_lightweight_proxy(T *&, boost::foreach::tag) { return 0; } > >template<typename T> >inline boost::mpl::true_ * >boost_foreach_is_lightweight_proxy(std::pair<T, T> *&, boost::foreach::tag) { return 0; } > >template<typename T> >inline boost::mpl::true_ * >boost_foreach_is_lightweight_proxy(boost::iterator_range<T> *&, boost::foreach::tag) { return 0; } > >template<typename T> >inline boost::mpl::true_ * >boost_foreach_is_lightweight_proxy(boost::sub_range<T> *&, boost::foreach::tag) { return 0; } > >template<typename T> >inline boost::mpl::true_ * >boost_foreach_is_lightweight_proxy(T **&, boost::foreach::tag) { return 0; } > > > > > > >template<typename T> >inline boost::foreach::is_noncopyable<T> * >boost_foreach_is_noncopyable(T *&, boost::foreach::tag) { return 0; } > >namespace boost >{ > >namespace foreach_detail_ >{ > > > > >template<typename Bool1, typename Bool2> >inline boost::mpl::and_<Bool1, Bool2> *and_(Bool1 *, Bool2 *) { return 0; } > >template<typename Bool1, typename Bool2, typename Bool3> >inline boost::mpl::and_<Bool1, Bool2, Bool3> *and_(Bool1 *, Bool2 *, Bool3 *) { return 0; } > >template<typename Bool1, typename Bool2> >inline boost::mpl::or_<Bool1, Bool2> *or_(Bool1 *, Bool2 *) { return 0; } > >template<typename Bool1, typename Bool2, typename Bool3> >inline boost::mpl::or_<Bool1, Bool2, Bool3> *or_(Bool1 *, Bool2 *, Bool3 *) { return 0; } > >template<typename Bool1> >inline boost::mpl::not_<Bool1> *not_(Bool1 *) { return 0; } > >template<typename T> >inline boost::is_array<T> *is_array_(T const &) { return 0; } > >template<typename T> >inline boost::is_const<T> *is_const_(T &) { return 0; } > > >template<typename T> >inline boost::mpl::true_ *is_const_(T const &) { return 0; } ># 238 "/usr/include/boost/foreach.hpp" 3 4 >template<typename T> >inline boost::is_rvalue_reference<T &&> *is_rvalue_(T &&, int) { return 0; } > > > > > >struct auto_any_base >{ > > > operator bool() const > { > return false; > } >}; > >template<typename T> >struct auto_any : auto_any_base >{ > explicit auto_any(T const &t) > : item(t) > { > } > > > > > mutable T item; >}; > >typedef auto_any_base const &auto_any_t; > >template<typename T, typename C> >inline typename boost::mpl::if_<C, T const, T>::type &auto_any_cast(auto_any_t a) >{ > return static_cast<auto_any<T> const &>(a).item; >} > >typedef boost::mpl::true_ const_; > > > > >template<typename T, typename C = boost::mpl::false_> >struct type2type > : boost::mpl::if_<C, T const, T> >{ >}; > >template<typename T> >struct wrap_cstr >{ > typedef T type; >}; > >template<> >struct wrap_cstr<char *> >{ > typedef wrap_cstr<char *> type; > typedef char *iterator; > typedef char *const_iterator; >}; > >template<> >struct wrap_cstr<char const *> >{ > typedef wrap_cstr<char const *> type; > typedef char const *iterator; > typedef char const *const_iterator; >}; > >template<> >struct wrap_cstr<wchar_t *> >{ > typedef wrap_cstr<wchar_t *> type; > typedef wchar_t *iterator; > typedef wchar_t *const_iterator; >}; > >template<> >struct wrap_cstr<wchar_t const *> >{ > typedef wrap_cstr<wchar_t const *> type; > typedef wchar_t const *iterator; > typedef wchar_t const *const_iterator; >}; > >template<typename T> >struct is_char_array > : mpl::and_< > is_array<T> > , mpl::or_< > is_convertible<T, char const *> > , is_convertible<T, wchar_t const *> > > > > >{}; > >template<typename T, typename C = boost::mpl::false_> >struct foreach_iterator >{ ># 353 "/usr/include/boost/foreach.hpp" 3 4 > struct IS_THIS_AN_ARRAY_OR_A_NULL_TERMINATED_STRING; typedef struct IS_THIS_AN_ARRAY_OR_A_NULL_TERMINATED_STRING353 : boost::mpl::assert_ { static boost::mpl::failed ************ (IS_THIS_AN_ARRAY_OR_A_NULL_TERMINATED_STRING::************ assert_arg()) (T&) { return 0; } } mpl_assert_arg353; enum { mpl_assertion_in_line_353 = sizeof( boost::mpl::assertion_failed<((!is_char_array<T>::value))>( mpl_assert_arg353::assert_arg() ) ) }; > > > > > typedef typename wrap_cstr<T>::type container; > > typedef typename boost::mpl::eval_if< > C > , range_const_iterator<container> > , range_mutable_iterator<container> > >::type type; >}; > > >template<typename T, typename C = boost::mpl::false_> >struct foreach_reverse_iterator >{ ># 384 "/usr/include/boost/foreach.hpp" 3 4 > struct IS_THIS_AN_ARRAY_OR_A_NULL_TERMINATED_STRING; typedef struct IS_THIS_AN_ARRAY_OR_A_NULL_TERMINATED_STRING384 : boost::mpl::assert_ { static boost::mpl::failed ************ (IS_THIS_AN_ARRAY_OR_A_NULL_TERMINATED_STRING::************ assert_arg()) (T&) { return 0; } } mpl_assert_arg384; enum { mpl_assertion_in_line_384 = sizeof( boost::mpl::assertion_failed<((!is_char_array<T>::value))>( mpl_assert_arg384::assert_arg() ) ) }; > > > > > typedef typename wrap_cstr<T>::type container; > > typedef typename boost::mpl::eval_if< > C > , range_reverse_iterator<container const> > , range_reverse_iterator<container> > >::type type; >}; > >template<typename T, typename C = boost::mpl::false_> >struct foreach_reference > : iterator_reference<typename foreach_iterator<T, C>::type> >{ >}; > > > > >template<typename T> >inline type2type<T> *encode_type(T &, boost::mpl::false_ *) { return 0; } > >template<typename T> >inline type2type<T, const_> *encode_type(T const &, boost::mpl::true_ *) { return 0; } > > > > >inline bool set_false(bool &b) >{ > b = false; > return false; >} > > > > >template<typename T> >inline T *&to_ptr(T const &) >{ > static T *t = 0; > return t; >} ># 630 "/usr/include/boost/foreach.hpp" 3 4 >template<typename T> >inline auto_any<T> contain(T const &t, boost::mpl::true_ *) >{ > return auto_any<T>(t); >} > >template<typename T> >inline auto_any<T *> contain(T &t, boost::mpl::false_ *) >{ > > > > > return auto_any<T *>(boost::addressof(t)); > >} ># 659 "/usr/include/boost/foreach.hpp" 3 4 >template<typename T, typename C> >inline auto_any<typename foreach_iterator<T, C>::type> >begin(auto_any_t col, type2type<T, C> *, boost::mpl::true_ *) >{ > return auto_any<typename foreach_iterator<T, C>::type>( > boost::begin(auto_any_cast<T, C>(col))); >} > >template<typename T, typename C> >inline auto_any<typename foreach_iterator<T, C>::type> >begin(auto_any_t col, type2type<T, C> *, boost::mpl::false_ *) >{ > typedef typename type2type<T, C>::type type; > typedef typename foreach_iterator<T, C>::type iterator; > return auto_any<typename foreach_iterator<T, C>::type>( > iterator(boost::begin((*(auto_any_cast<type *, boost::mpl::false_>(col)))))); >} ># 688 "/usr/include/boost/foreach.hpp" 3 4 >template<typename T, typename C> >inline auto_any<T *> >begin(auto_any_t col, type2type<T *, C> *, boost::mpl::true_ *) >{ > return auto_any<T *>(auto_any_cast<T *, boost::mpl::false_>(col)); >} > > > > > >template<typename T, typename C> >inline auto_any<typename foreach_iterator<T, C>::type> >end(auto_any_t col, type2type<T, C> *, boost::mpl::true_ *) >{ > return auto_any<typename foreach_iterator<T, C>::type>( > boost::end(auto_any_cast<T, C>(col))); >} > >template<typename T, typename C> >inline auto_any<typename foreach_iterator<T, C>::type> >end(auto_any_t col, type2type<T, C> *, boost::mpl::false_ *) >{ > typedef typename type2type<T, C>::type type; > typedef typename foreach_iterator<T, C>::type iterator; > return auto_any<typename foreach_iterator<T, C>::type>( > iterator(boost::end((*(auto_any_cast<type *, boost::mpl::false_>(col)))))); >} ># 728 "/usr/include/boost/foreach.hpp" 3 4 >template<typename T, typename C> >inline auto_any<int> >end(auto_any_t, type2type<T *, C> *, boost::mpl::true_ *) >{ > return auto_any<int>(0); >} > > > > > >template<typename T, typename C> >inline bool done(auto_any_t cur, auto_any_t end, type2type<T, C> *) >{ > typedef typename foreach_iterator<T, C>::type iter_t; > return auto_any_cast<iter_t, boost::mpl::false_>(cur) == auto_any_cast<iter_t, boost::mpl::false_>(end); >} > > >template<typename T, typename C> >inline bool done(auto_any_t cur, auto_any_t, type2type<T *, C> *) >{ > return ! *auto_any_cast<T *, boost::mpl::false_>(cur); >} > > > > > >template<typename T, typename C> >inline void next(auto_any_t cur, type2type<T, C> *) >{ > typedef typename foreach_iterator<T, C>::type iter_t; > ++auto_any_cast<iter_t, boost::mpl::false_>(cur); >} > > > > >template<typename T, typename C> >inline typename foreach_reference<T, C>::type >deref(auto_any_t cur, type2type<T, C> *) >{ > typedef typename foreach_iterator<T, C>::type iter_t; > return *auto_any_cast<iter_t, boost::mpl::false_>(cur); >} > > > > >template<typename T, typename C> >inline auto_any<typename foreach_reverse_iterator<T, C>::type> >rbegin(auto_any_t col, type2type<T, C> *, boost::mpl::true_ *) >{ > return auto_any<typename foreach_reverse_iterator<T, C>::type>( > boost::rbegin(auto_any_cast<T, C>(col))); >} > >template<typename T, typename C> >inline auto_any<typename foreach_reverse_iterator<T, C>::type> >rbegin(auto_any_t col, type2type<T, C> *, boost::mpl::false_ *) >{ > typedef typename type2type<T, C>::type type; > typedef typename foreach_reverse_iterator<T, C>::type iterator; > return auto_any<typename foreach_reverse_iterator<T, C>::type>( > iterator(boost::rbegin((*(auto_any_cast<type *, boost::mpl::false_>(col)))))); >} ># 807 "/usr/include/boost/foreach.hpp" 3 4 >template<typename T, typename C> >inline auto_any<reverse_iterator<T *> > >rbegin(auto_any_t col, type2type<T *, C> *, boost::mpl::true_ *) >{ > T *p = auto_any_cast<T *, boost::mpl::false_>(col); > while(0 != *p) > ++p; > return auto_any<reverse_iterator<T *> >(reverse_iterator<T *>(p)); >} > > > > > >template<typename T, typename C> >inline auto_any<typename foreach_reverse_iterator<T, C>::type> >rend(auto_any_t col, type2type<T, C> *, boost::mpl::true_ *) >{ > return auto_any<typename foreach_reverse_iterator<T, C>::type>( > boost::rend(auto_any_cast<T, C>(col))); >} > >template<typename T, typename C> >inline auto_any<typename foreach_reverse_iterator<T, C>::type> >rend(auto_any_t col, type2type<T, C> *, boost::mpl::false_ *) >{ > typedef typename type2type<T, C>::type type; > typedef typename foreach_reverse_iterator<T, C>::type iterator; > return auto_any<typename foreach_reverse_iterator<T, C>::type>( > iterator(boost::rend((*(auto_any_cast<type *, boost::mpl::false_>(col)))))); >} ># 850 "/usr/include/boost/foreach.hpp" 3 4 >template<typename T, typename C> >inline auto_any<reverse_iterator<T *> > >rend(auto_any_t col, type2type<T *, C> *, boost::mpl::true_ *) >{ > return auto_any<reverse_iterator<T *> >( > reverse_iterator<T *>(auto_any_cast<T *, boost::mpl::false_>(col))); >} > > > > > >template<typename T, typename C> >inline bool rdone(auto_any_t cur, auto_any_t end, type2type<T, C> *) >{ > typedef typename foreach_reverse_iterator<T, C>::type iter_t; > return auto_any_cast<iter_t, boost::mpl::false_>(cur) == auto_any_cast<iter_t, boost::mpl::false_>(end); >} > > > > >template<typename T, typename C> >inline void rnext(auto_any_t cur, type2type<T, C> *) >{ > typedef typename foreach_reverse_iterator<T, C>::type iter_t; > ++auto_any_cast<iter_t, boost::mpl::false_>(cur); >} > > > > >template<typename T, typename C> >inline typename foreach_reference<T, C>::type >rderef(auto_any_t cur, type2type<T, C> *) >{ > typedef typename foreach_reverse_iterator<T, C>::type iter_t; > return *auto_any_cast<iter_t, boost::mpl::false_>(cur); >} > >} >} ># 7 "/c/honeypenny/src/rpc/core_rpc_server.cpp" 2 ># 1 "/c/honeypenny/contrib/epee/include/include_base_utils.h" 1 ># 27 "/c/honeypenny/contrib/epee/include/include_base_utils.h" > > > > > ># 1 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 1 ># 32 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" ># 1 "/usr/include/c++/4.9.0/atomic" 1 3 ># 35 "/usr/include/c++/4.9.0/atomic" 3 ># 36 "/usr/include/c++/4.9.0/atomic" 3 > > > > > ># 1 "/usr/include/c++/4.9.0/bits/atomic_base.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/atomic_base.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/atomic_base.h" 3 > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stdbool.h" 1 3 4 ># 37 "/usr/include/c++/4.9.0/bits/atomic_base.h" 2 3 > > > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 56 "/usr/include/c++/4.9.0/bits/atomic_base.h" 3 > typedef enum memory_order > { > memory_order_relaxed, > memory_order_consume, > memory_order_acquire, > memory_order_release, > memory_order_acq_rel, > memory_order_seq_cst > } memory_order; > > enum __memory_order_modifier > { > __memory_order_mask = 0x0ffff, > __memory_order_modifier_mask = 0xffff0000, > __memory_order_hle_acquire = 0x10000, > __memory_order_hle_release = 0x20000 > }; > > constexpr memory_order > operator|(memory_order __m, __memory_order_modifier __mod) > { > return memory_order(__m | int(__mod)); > } > > constexpr memory_order > operator&(memory_order __m, __memory_order_modifier __mod) > { > return memory_order(__m & int(__mod)); > } > > > constexpr memory_order > __cmpexch_failure_order2(memory_order __m) noexcept > { > return __m == memory_order_acq_rel ? memory_order_acquire > : __m == memory_order_release ? memory_order_relaxed : __m; > } > > constexpr memory_order > __cmpexch_failure_order(memory_order __m) noexcept > { > return memory_order(__cmpexch_failure_order2(__m & __memory_order_mask) > | (__m & __memory_order_modifier_mask)); > } > > inline __attribute__((always_inline)) void > atomic_thread_fence(memory_order __m) noexcept > { __atomic_thread_fence(__m); } > > inline __attribute__((always_inline)) void > atomic_signal_fence(memory_order __m) noexcept > { __atomic_signal_fence(__m); } > > > template<typename _Tp> > inline _Tp > kill_dependency(_Tp __y) noexcept > { > _Tp __ret(__y); > return __ret; > } > > > > template<typename _IntTp> > struct __atomic_base; > > > typedef __atomic_base<char> atomic_char; > > > typedef __atomic_base<signed char> atomic_schar; > > > typedef __atomic_base<unsigned char> atomic_uchar; > > > typedef __atomic_base<short> atomic_short; > > > typedef __atomic_base<unsigned short> atomic_ushort; > > > typedef __atomic_base<int> atomic_int; > > > typedef __atomic_base<unsigned int> atomic_uint; > > > typedef __atomic_base<long> atomic_long; > > > typedef __atomic_base<unsigned long> atomic_ulong; > > > typedef __atomic_base<long long> atomic_llong; > > > typedef __atomic_base<unsigned long long> atomic_ullong; > > > typedef __atomic_base<wchar_t> atomic_wchar_t; > > > typedef __atomic_base<char16_t> atomic_char16_t; > > > typedef __atomic_base<char32_t> atomic_char32_t; > > > typedef __atomic_base<char32_t> atomic_char32_t; > > > > typedef __atomic_base<int_least8_t> atomic_int_least8_t; > > > typedef __atomic_base<uint_least8_t> atomic_uint_least8_t; > > > typedef __atomic_base<int_least16_t> atomic_int_least16_t; > > > typedef __atomic_base<uint_least16_t> atomic_uint_least16_t; > > > typedef __atomic_base<int_least32_t> atomic_int_least32_t; > > > typedef __atomic_base<uint_least32_t> atomic_uint_least32_t; > > > typedef __atomic_base<int_least64_t> atomic_int_least64_t; > > > typedef __atomic_base<uint_least64_t> atomic_uint_least64_t; > > > > typedef __atomic_base<int_fast8_t> atomic_int_fast8_t; > > > typedef __atomic_base<uint_fast8_t> atomic_uint_fast8_t; > > > typedef __atomic_base<int_fast16_t> atomic_int_fast16_t; > > > typedef __atomic_base<uint_fast16_t> atomic_uint_fast16_t; > > > typedef __atomic_base<int_fast32_t> atomic_int_fast32_t; > > > typedef __atomic_base<uint_fast32_t> atomic_uint_fast32_t; > > > typedef __atomic_base<int_fast64_t> atomic_int_fast64_t; > > > typedef __atomic_base<uint_fast64_t> atomic_uint_fast64_t; > > > > typedef __atomic_base<intptr_t> atomic_intptr_t; > > > typedef __atomic_base<uintptr_t> atomic_uintptr_t; > > > typedef __atomic_base<size_t> atomic_size_t; > > > typedef __atomic_base<intmax_t> atomic_intmax_t; > > > typedef __atomic_base<uintmax_t> atomic_uintmax_t; > > > typedef __atomic_base<ptrdiff_t> atomic_ptrdiff_t; > > > > > template<typename _Tp> > struct atomic; > > template<typename _Tp> > struct atomic<_Tp*>; > > > > typedef bool __atomic_flag_data_type; ># 263 "/usr/include/c++/4.9.0/bits/atomic_base.h" 3 > extern "C" { > > struct __atomic_flag_base > { > __atomic_flag_data_type _M_i; > }; > > } > > > > > struct atomic_flag : public __atomic_flag_base > { > atomic_flag() noexcept = default; > ~atomic_flag() noexcept = default; > atomic_flag(const atomic_flag&) = delete; > atomic_flag& operator=(const atomic_flag&) = delete; > atomic_flag& operator=(const atomic_flag&) volatile = delete; > > > constexpr atomic_flag(bool __i) noexcept > : __atomic_flag_base{ _S_init(__i) } > { } > > inline __attribute__((always_inline)) bool > test_and_set(memory_order __m = memory_order_seq_cst) noexcept > { > return __atomic_test_and_set (&_M_i, __m); > } > > inline __attribute__((always_inline)) bool > test_and_set(memory_order __m = memory_order_seq_cst) volatile noexcept > { > return __atomic_test_and_set (&_M_i, __m); > } > > inline __attribute__((always_inline)) void > clear(memory_order __m = memory_order_seq_cst) noexcept > { > memory_order __b = __m & __memory_order_mask; > ; > ; > ; > > __atomic_clear (&_M_i, __m); > } > > inline __attribute__((always_inline)) void > clear(memory_order __m = memory_order_seq_cst) volatile noexcept > { > memory_order __b = __m & __memory_order_mask; > ; > ; > ; > > __atomic_clear (&_M_i, __m); > } > > private: > static constexpr __atomic_flag_data_type > _S_init(bool __i) > { return __i ? 1 : 0; } > }; ># 352 "/usr/include/c++/4.9.0/bits/atomic_base.h" 3 > template<typename _ITp> > struct __atomic_base > { > private: > typedef _ITp __int_type; > > __int_type _M_i; > > public: > __atomic_base() noexcept = default; > ~__atomic_base() noexcept = default; > __atomic_base(const __atomic_base&) = delete; > __atomic_base& operator=(const __atomic_base&) = delete; > __atomic_base& operator=(const __atomic_base&) volatile = delete; > > > constexpr __atomic_base(__int_type __i) noexcept : _M_i (__i) { } > > operator __int_type() const noexcept > { return load(); } > > operator __int_type() const volatile noexcept > { return load(); } > > __int_type > operator=(__int_type __i) noexcept > { > store(__i); > return __i; > } > > __int_type > operator=(__int_type __i) volatile noexcept > { > store(__i); > return __i; > } > > __int_type > operator++(int) noexcept > { return fetch_add(1); } > > __int_type > operator++(int) volatile noexcept > { return fetch_add(1); } > > __int_type > operator--(int) noexcept > { return fetch_sub(1); } > > __int_type > operator--(int) volatile noexcept > { return fetch_sub(1); } > > __int_type > operator++() noexcept > { return __atomic_add_fetch(&_M_i, 1, memory_order_seq_cst); } > > __int_type > operator++() volatile noexcept > { return __atomic_add_fetch(&_M_i, 1, memory_order_seq_cst); } > > __int_type > operator--() noexcept > { return __atomic_sub_fetch(&_M_i, 1, memory_order_seq_cst); } > > __int_type > operator--() volatile noexcept > { return __atomic_sub_fetch(&_M_i, 1, memory_order_seq_cst); } > > __int_type > operator+=(__int_type __i) noexcept > { return __atomic_add_fetch(&_M_i, __i, memory_order_seq_cst); } > > __int_type > operator+=(__int_type __i) volatile noexcept > { return __atomic_add_fetch(&_M_i, __i, memory_order_seq_cst); } > > __int_type > operator-=(__int_type __i) noexcept > { return __atomic_sub_fetch(&_M_i, __i, memory_order_seq_cst); } > > __int_type > operator-=(__int_type __i) volatile noexcept > { return __atomic_sub_fetch(&_M_i, __i, memory_order_seq_cst); } > > __int_type > operator&=(__int_type __i) noexcept > { return __atomic_and_fetch(&_M_i, __i, memory_order_seq_cst); } > > __int_type > operator&=(__int_type __i) volatile noexcept > { return __atomic_and_fetch(&_M_i, __i, memory_order_seq_cst); } > > __int_type > operator|=(__int_type __i) noexcept > { return __atomic_or_fetch(&_M_i, __i, memory_order_seq_cst); } > > __int_type > operator|=(__int_type __i) volatile noexcept > { return __atomic_or_fetch(&_M_i, __i, memory_order_seq_cst); } > > __int_type > operator^=(__int_type __i) noexcept > { return __atomic_xor_fetch(&_M_i, __i, memory_order_seq_cst); } > > __int_type > operator^=(__int_type __i) volatile noexcept > { return __atomic_xor_fetch(&_M_i, __i, memory_order_seq_cst); } > > bool > is_lock_free() const noexcept > { return __atomic_is_lock_free(sizeof(_M_i), nullptr); } > > bool > is_lock_free() const volatile noexcept > { return __atomic_is_lock_free(sizeof(_M_i), nullptr); } > > inline __attribute__((always_inline)) void > store(__int_type __i, memory_order __m = memory_order_seq_cst) noexcept > { > memory_order __b = __m & __memory_order_mask; > ; > ; > ; > > __atomic_store_n(&_M_i, __i, __m); > } > > inline __attribute__((always_inline)) void > store(__int_type __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { > memory_order __b = __m & __memory_order_mask; > ; > ; > ; > > __atomic_store_n(&_M_i, __i, __m); > } > > inline __attribute__((always_inline)) __int_type > load(memory_order __m = memory_order_seq_cst) const noexcept > { > memory_order __b = __m & __memory_order_mask; > ; > ; > > return __atomic_load_n(&_M_i, __m); > } > > inline __attribute__((always_inline)) __int_type > load(memory_order __m = memory_order_seq_cst) const volatile noexcept > { > memory_order __b = __m & __memory_order_mask; > ; > ; > > return __atomic_load_n(&_M_i, __m); > } > > inline __attribute__((always_inline)) __int_type > exchange(__int_type __i, > memory_order __m = memory_order_seq_cst) noexcept > { > return __atomic_exchange_n(&_M_i, __i, __m); > } > > > inline __attribute__((always_inline)) __int_type > exchange(__int_type __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { > return __atomic_exchange_n(&_M_i, __i, __m); > } > > inline __attribute__((always_inline)) bool > compare_exchange_weak(__int_type& __i1, __int_type __i2, > memory_order __m1, memory_order __m2) noexcept > { > memory_order __b2 = __m2 & __memory_order_mask; > memory_order __b1 = __m1 & __memory_order_mask; > ; > ; > ; > > return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 1, __m1, __m2); > } > > inline __attribute__((always_inline)) bool > compare_exchange_weak(__int_type& __i1, __int_type __i2, > memory_order __m1, > memory_order __m2) volatile noexcept > { > memory_order __b2 = __m2 & __memory_order_mask; > memory_order __b1 = __m1 & __memory_order_mask; > ; > ; > ; > > return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 1, __m1, __m2); > } > > inline __attribute__((always_inline)) bool > compare_exchange_weak(__int_type& __i1, __int_type __i2, > memory_order __m = memory_order_seq_cst) noexcept > { > return compare_exchange_weak(__i1, __i2, __m, > __cmpexch_failure_order(__m)); > } > > inline __attribute__((always_inline)) bool > compare_exchange_weak(__int_type& __i1, __int_type __i2, > memory_order __m = memory_order_seq_cst) volatile noexcept > { > return compare_exchange_weak(__i1, __i2, __m, > __cmpexch_failure_order(__m)); > } > > inline __attribute__((always_inline)) bool > compare_exchange_strong(__int_type& __i1, __int_type __i2, > memory_order __m1, memory_order __m2) noexcept > { > memory_order __b2 = __m2 & __memory_order_mask; > memory_order __b1 = __m1 & __memory_order_mask; > ; > ; > ; > > return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 0, __m1, __m2); > } > > inline __attribute__((always_inline)) bool > compare_exchange_strong(__int_type& __i1, __int_type __i2, > memory_order __m1, > memory_order __m2) volatile noexcept > { > memory_order __b2 = __m2 & __memory_order_mask; > memory_order __b1 = __m1 & __memory_order_mask; > > ; > ; > ; > > return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 0, __m1, __m2); > } > > inline __attribute__((always_inline)) bool > compare_exchange_strong(__int_type& __i1, __int_type __i2, > memory_order __m = memory_order_seq_cst) noexcept > { > return compare_exchange_strong(__i1, __i2, __m, > __cmpexch_failure_order(__m)); > } > > inline __attribute__((always_inline)) bool > compare_exchange_strong(__int_type& __i1, __int_type __i2, > memory_order __m = memory_order_seq_cst) volatile noexcept > { > return compare_exchange_strong(__i1, __i2, __m, > __cmpexch_failure_order(__m)); > } > > inline __attribute__((always_inline)) __int_type > fetch_add(__int_type __i, > memory_order __m = memory_order_seq_cst) noexcept > { return __atomic_fetch_add(&_M_i, __i, __m); } > > inline __attribute__((always_inline)) __int_type > fetch_add(__int_type __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return __atomic_fetch_add(&_M_i, __i, __m); } > > inline __attribute__((always_inline)) __int_type > fetch_sub(__int_type __i, > memory_order __m = memory_order_seq_cst) noexcept > { return __atomic_fetch_sub(&_M_i, __i, __m); } > > inline __attribute__((always_inline)) __int_type > fetch_sub(__int_type __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return __atomic_fetch_sub(&_M_i, __i, __m); } > > inline __attribute__((always_inline)) __int_type > fetch_and(__int_type __i, > memory_order __m = memory_order_seq_cst) noexcept > { return __atomic_fetch_and(&_M_i, __i, __m); } > > inline __attribute__((always_inline)) __int_type > fetch_and(__int_type __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return __atomic_fetch_and(&_M_i, __i, __m); } > > inline __attribute__((always_inline)) __int_type > fetch_or(__int_type __i, > memory_order __m = memory_order_seq_cst) noexcept > { return __atomic_fetch_or(&_M_i, __i, __m); } > > inline __attribute__((always_inline)) __int_type > fetch_or(__int_type __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return __atomic_fetch_or(&_M_i, __i, __m); } > > inline __attribute__((always_inline)) __int_type > fetch_xor(__int_type __i, > memory_order __m = memory_order_seq_cst) noexcept > { return __atomic_fetch_xor(&_M_i, __i, __m); } > > inline __attribute__((always_inline)) __int_type > fetch_xor(__int_type __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return __atomic_fetch_xor(&_M_i, __i, __m); } > }; > > > > template<typename _PTp> > struct __atomic_base<_PTp*> > { > private: > typedef _PTp* __pointer_type; > > __pointer_type _M_p; > > > constexpr ptrdiff_t > _M_type_size(ptrdiff_t __d) { return __d * sizeof(_PTp); } > > constexpr ptrdiff_t > _M_type_size(ptrdiff_t __d) volatile { return __d * sizeof(_PTp); } > > public: > __atomic_base() noexcept = default; > ~__atomic_base() noexcept = default; > __atomic_base(const __atomic_base&) = delete; > __atomic_base& operator=(const __atomic_base&) = delete; > __atomic_base& operator=(const __atomic_base&) volatile = delete; > > > constexpr __atomic_base(__pointer_type __p) noexcept : _M_p (__p) { } > > operator __pointer_type() const noexcept > { return load(); } > > operator __pointer_type() const volatile noexcept > { return load(); } > > __pointer_type > operator=(__pointer_type __p) noexcept > { > store(__p); > return __p; > } > > __pointer_type > operator=(__pointer_type __p) volatile noexcept > { > store(__p); > return __p; > } > > __pointer_type > operator++(int) noexcept > { return fetch_add(1); } > > __pointer_type > operator++(int) volatile noexcept > { return fetch_add(1); } > > __pointer_type > operator--(int) noexcept > { return fetch_sub(1); } > > __pointer_type > operator--(int) volatile noexcept > { return fetch_sub(1); } > > __pointer_type > operator++() noexcept > { return __atomic_add_fetch(&_M_p, _M_type_size(1), > memory_order_seq_cst); } > > __pointer_type > operator++() volatile noexcept > { return __atomic_add_fetch(&_M_p, _M_type_size(1), > memory_order_seq_cst); } > > __pointer_type > operator--() noexcept > { return __atomic_sub_fetch(&_M_p, _M_type_size(1), > memory_order_seq_cst); } > > __pointer_type > operator--() volatile noexcept > { return __atomic_sub_fetch(&_M_p, _M_type_size(1), > memory_order_seq_cst); } > > __pointer_type > operator+=(ptrdiff_t __d) noexcept > { return __atomic_add_fetch(&_M_p, _M_type_size(__d), > memory_order_seq_cst); } > > __pointer_type > operator+=(ptrdiff_t __d) volatile noexcept > { return __atomic_add_fetch(&_M_p, _M_type_size(__d), > memory_order_seq_cst); } > > __pointer_type > operator-=(ptrdiff_t __d) noexcept > { return __atomic_sub_fetch(&_M_p, _M_type_size(__d), > memory_order_seq_cst); } > > __pointer_type > operator-=(ptrdiff_t __d) volatile noexcept > { return __atomic_sub_fetch(&_M_p, _M_type_size(__d), > memory_order_seq_cst); } > > bool > is_lock_free() const noexcept > { return __atomic_is_lock_free(sizeof(__pointer_type), nullptr); } > > bool > is_lock_free() const volatile noexcept > { return __atomic_is_lock_free(sizeof(__pointer_type), nullptr); } > > inline __attribute__((always_inline)) void > store(__pointer_type __p, > memory_order __m = memory_order_seq_cst) noexcept > { > memory_order __b = __m & __memory_order_mask; > > ; > ; > ; > > __atomic_store_n(&_M_p, __p, __m); > } > > inline __attribute__((always_inline)) void > store(__pointer_type __p, > memory_order __m = memory_order_seq_cst) volatile noexcept > { > memory_order __b = __m & __memory_order_mask; > ; > ; > ; > > __atomic_store_n(&_M_p, __p, __m); > } > > inline __attribute__((always_inline)) __pointer_type > load(memory_order __m = memory_order_seq_cst) const noexcept > { > memory_order __b = __m & __memory_order_mask; > ; > ; > > return __atomic_load_n(&_M_p, __m); > } > > inline __attribute__((always_inline)) __pointer_type > load(memory_order __m = memory_order_seq_cst) const volatile noexcept > { > memory_order __b = __m & __memory_order_mask; > ; > ; > > return __atomic_load_n(&_M_p, __m); > } > > inline __attribute__((always_inline)) __pointer_type > exchange(__pointer_type __p, > memory_order __m = memory_order_seq_cst) noexcept > { > return __atomic_exchange_n(&_M_p, __p, __m); > } > > > inline __attribute__((always_inline)) __pointer_type > exchange(__pointer_type __p, > memory_order __m = memory_order_seq_cst) volatile noexcept > { > return __atomic_exchange_n(&_M_p, __p, __m); > } > > inline __attribute__((always_inline)) bool > compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2, > memory_order __m1, > memory_order __m2) noexcept > { > memory_order __b2 = __m2 & __memory_order_mask; > memory_order __b1 = __m1 & __memory_order_mask; > ; > ; > ; > > return __atomic_compare_exchange_n(&_M_p, &__p1, __p2, 0, __m1, __m2); > } > > inline __attribute__((always_inline)) bool > compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2, > memory_order __m1, > memory_order __m2) volatile noexcept > { > memory_order __b2 = __m2 & __memory_order_mask; > memory_order __b1 = __m1 & __memory_order_mask; > > ; > ; > ; > > return __atomic_compare_exchange_n(&_M_p, &__p1, __p2, 0, __m1, __m2); > } > > inline __attribute__((always_inline)) __pointer_type > fetch_add(ptrdiff_t __d, > memory_order __m = memory_order_seq_cst) noexcept > { return __atomic_fetch_add(&_M_p, _M_type_size(__d), __m); } > > inline __attribute__((always_inline)) __pointer_type > fetch_add(ptrdiff_t __d, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return __atomic_fetch_add(&_M_p, _M_type_size(__d), __m); } > > inline __attribute__((always_inline)) __pointer_type > fetch_sub(ptrdiff_t __d, > memory_order __m = memory_order_seq_cst) noexcept > { return __atomic_fetch_sub(&_M_p, _M_type_size(__d), __m); } > > inline __attribute__((always_inline)) __pointer_type > fetch_sub(ptrdiff_t __d, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return __atomic_fetch_sub(&_M_p, _M_type_size(__d), __m); } > }; > > > > >} ># 42 "/usr/include/c++/4.9.0/atomic" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 54 "/usr/include/c++/4.9.0/atomic" 3 > struct atomic_bool > { > private: > __atomic_base<bool> _M_base; > > public: > atomic_bool() noexcept = default; > ~atomic_bool() noexcept = default; > atomic_bool(const atomic_bool&) = delete; > atomic_bool& operator=(const atomic_bool&) = delete; > atomic_bool& operator=(const atomic_bool&) volatile = delete; > > constexpr atomic_bool(bool __i) noexcept : _M_base(__i) { } > > bool > operator=(bool __i) noexcept > { return _M_base.operator=(__i); } > > bool > operator=(bool __i) volatile noexcept > { return _M_base.operator=(__i); } > > operator bool() const noexcept > { return _M_base.load(); } > > operator bool() const volatile noexcept > { return _M_base.load(); } > > bool > is_lock_free() const noexcept { return _M_base.is_lock_free(); } > > bool > is_lock_free() const volatile noexcept { return _M_base.is_lock_free(); } > > void > store(bool __i, memory_order __m = memory_order_seq_cst) noexcept > { _M_base.store(__i, __m); } > > void > store(bool __i, memory_order __m = memory_order_seq_cst) volatile noexcept > { _M_base.store(__i, __m); } > > bool > load(memory_order __m = memory_order_seq_cst) const noexcept > { return _M_base.load(__m); } > > bool > load(memory_order __m = memory_order_seq_cst) const volatile noexcept > { return _M_base.load(__m); } > > bool > exchange(bool __i, memory_order __m = memory_order_seq_cst) noexcept > { return _M_base.exchange(__i, __m); } > > bool > exchange(bool __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return _M_base.exchange(__i, __m); } > > bool > compare_exchange_weak(bool& __i1, bool __i2, memory_order __m1, > memory_order __m2) noexcept > { return _M_base.compare_exchange_weak(__i1, __i2, __m1, __m2); } > > bool > compare_exchange_weak(bool& __i1, bool __i2, memory_order __m1, > memory_order __m2) volatile noexcept > { return _M_base.compare_exchange_weak(__i1, __i2, __m1, __m2); } > > bool > compare_exchange_weak(bool& __i1, bool __i2, > memory_order __m = memory_order_seq_cst) noexcept > { return _M_base.compare_exchange_weak(__i1, __i2, __m); } > > bool > compare_exchange_weak(bool& __i1, bool __i2, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return _M_base.compare_exchange_weak(__i1, __i2, __m); } > > bool > compare_exchange_strong(bool& __i1, bool __i2, memory_order __m1, > memory_order __m2) noexcept > { return _M_base.compare_exchange_strong(__i1, __i2, __m1, __m2); } > > bool > compare_exchange_strong(bool& __i1, bool __i2, memory_order __m1, > memory_order __m2) volatile noexcept > { return _M_base.compare_exchange_strong(__i1, __i2, __m1, __m2); } > > bool > compare_exchange_strong(bool& __i1, bool __i2, > memory_order __m = memory_order_seq_cst) noexcept > { return _M_base.compare_exchange_strong(__i1, __i2, __m); } > > bool > compare_exchange_strong(bool& __i1, bool __i2, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return _M_base.compare_exchange_strong(__i1, __i2, __m); } > }; > > > > > > > > template<typename _Tp> > struct atomic > { > private: > _Tp _M_i; > > public: > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(_Tp __i) noexcept : _M_i(__i) { } > > operator _Tp() const noexcept > { return load(); } > > operator _Tp() const volatile noexcept > { return load(); } > > _Tp > operator=(_Tp __i) noexcept > { store(__i); return __i; } > > _Tp > operator=(_Tp __i) volatile noexcept > { store(__i); return __i; } > > bool > is_lock_free() const noexcept > { return __atomic_is_lock_free(sizeof(_M_i), nullptr); } > > bool > is_lock_free() const volatile noexcept > { return __atomic_is_lock_free(sizeof(_M_i), nullptr); } > > void > store(_Tp __i, memory_order _m = memory_order_seq_cst) noexcept > { __atomic_store(&_M_i, &__i, _m); } > > void > store(_Tp __i, memory_order _m = memory_order_seq_cst) volatile noexcept > { __atomic_store(&_M_i, &__i, _m); } > > _Tp > load(memory_order _m = memory_order_seq_cst) const noexcept > { > _Tp tmp; > __atomic_load(&_M_i, &tmp, _m); > return tmp; > } > > _Tp > load(memory_order _m = memory_order_seq_cst) const volatile noexcept > { > _Tp tmp; > __atomic_load(&_M_i, &tmp, _m); > return tmp; > } > > _Tp > exchange(_Tp __i, memory_order _m = memory_order_seq_cst) noexcept > { > _Tp tmp; > __atomic_exchange(&_M_i, &__i, &tmp, _m); > return tmp; > } > > _Tp > exchange(_Tp __i, > memory_order _m = memory_order_seq_cst) volatile noexcept > { > _Tp tmp; > __atomic_exchange(&_M_i, &__i, &tmp, _m); > return tmp; > } > > bool > compare_exchange_weak(_Tp& __e, _Tp __i, memory_order __s, > memory_order __f) noexcept > { > return __atomic_compare_exchange(&_M_i, &__e, &__i, true, __s, __f); > } > > bool > compare_exchange_weak(_Tp& __e, _Tp __i, memory_order __s, > memory_order __f) volatile noexcept > { > return __atomic_compare_exchange(&_M_i, &__e, &__i, true, __s, __f); > } > > bool > compare_exchange_weak(_Tp& __e, _Tp __i, > memory_order __m = memory_order_seq_cst) noexcept > { return compare_exchange_weak(__e, __i, __m, > __cmpexch_failure_order(__m)); } > > bool > compare_exchange_weak(_Tp& __e, _Tp __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return compare_exchange_weak(__e, __i, __m, > __cmpexch_failure_order(__m)); } > > bool > compare_exchange_strong(_Tp& __e, _Tp __i, memory_order __s, > memory_order __f) noexcept > { > return __atomic_compare_exchange(&_M_i, &__e, &__i, false, __s, __f); > } > > bool > compare_exchange_strong(_Tp& __e, _Tp __i, memory_order __s, > memory_order __f) volatile noexcept > { > return __atomic_compare_exchange(&_M_i, &__e, &__i, false, __s, __f); > } > > bool > compare_exchange_strong(_Tp& __e, _Tp __i, > memory_order __m = memory_order_seq_cst) noexcept > { return compare_exchange_strong(__e, __i, __m, > __cmpexch_failure_order(__m)); } > > bool > compare_exchange_strong(_Tp& __e, _Tp __i, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return compare_exchange_strong(__e, __i, __m, > __cmpexch_failure_order(__m)); } > }; > > > > template<typename _Tp> > struct atomic<_Tp*> > { > typedef _Tp* __pointer_type; > typedef __atomic_base<_Tp*> __base_type; > __base_type _M_b; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__pointer_type __p) noexcept : _M_b(__p) { } > > operator __pointer_type() const noexcept > { return __pointer_type(_M_b); } > > operator __pointer_type() const volatile noexcept > { return __pointer_type(_M_b); } > > __pointer_type > operator=(__pointer_type __p) noexcept > { return _M_b.operator=(__p); } > > __pointer_type > operator=(__pointer_type __p) volatile noexcept > { return _M_b.operator=(__p); } > > __pointer_type > operator++(int) noexcept > { return _M_b++; } > > __pointer_type > operator++(int) volatile noexcept > { return _M_b++; } > > __pointer_type > operator--(int) noexcept > { return _M_b--; } > > __pointer_type > operator--(int) volatile noexcept > { return _M_b--; } > > __pointer_type > operator++() noexcept > { return ++_M_b; } > > __pointer_type > operator++() volatile noexcept > { return ++_M_b; } > > __pointer_type > operator--() noexcept > { return --_M_b; } > > __pointer_type > operator--() volatile noexcept > { return --_M_b; } > > __pointer_type > operator+=(ptrdiff_t __d) noexcept > { return _M_b.operator+=(__d); } > > __pointer_type > operator+=(ptrdiff_t __d) volatile noexcept > { return _M_b.operator+=(__d); } > > __pointer_type > operator-=(ptrdiff_t __d) noexcept > { return _M_b.operator-=(__d); } > > __pointer_type > operator-=(ptrdiff_t __d) volatile noexcept > { return _M_b.operator-=(__d); } > > bool > is_lock_free() const noexcept > { return _M_b.is_lock_free(); } > > bool > is_lock_free() const volatile noexcept > { return _M_b.is_lock_free(); } > > void > store(__pointer_type __p, > memory_order __m = memory_order_seq_cst) noexcept > { return _M_b.store(__p, __m); } > > void > store(__pointer_type __p, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return _M_b.store(__p, __m); } > > __pointer_type > load(memory_order __m = memory_order_seq_cst) const noexcept > { return _M_b.load(__m); } > > __pointer_type > load(memory_order __m = memory_order_seq_cst) const volatile noexcept > { return _M_b.load(__m); } > > __pointer_type > exchange(__pointer_type __p, > memory_order __m = memory_order_seq_cst) noexcept > { return _M_b.exchange(__p, __m); } > > __pointer_type > exchange(__pointer_type __p, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return _M_b.exchange(__p, __m); } > > bool > compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2, > memory_order __m1, memory_order __m2) noexcept > { return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); } > > bool > compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2, > memory_order __m1, > memory_order __m2) volatile noexcept > { return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); } > > bool > compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2, > memory_order __m = memory_order_seq_cst) noexcept > { > return compare_exchange_weak(__p1, __p2, __m, > __cmpexch_failure_order(__m)); > } > > bool > compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2, > memory_order __m = memory_order_seq_cst) volatile noexcept > { > return compare_exchange_weak(__p1, __p2, __m, > __cmpexch_failure_order(__m)); > } > > bool > compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2, > memory_order __m1, memory_order __m2) noexcept > { return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); } > > bool > compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2, > memory_order __m1, > memory_order __m2) volatile noexcept > { return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); } > > bool > compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2, > memory_order __m = memory_order_seq_cst) noexcept > { > return _M_b.compare_exchange_strong(__p1, __p2, __m, > __cmpexch_failure_order(__m)); > } > > bool > compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2, > memory_order __m = memory_order_seq_cst) volatile noexcept > { > return _M_b.compare_exchange_strong(__p1, __p2, __m, > __cmpexch_failure_order(__m)); > } > > __pointer_type > fetch_add(ptrdiff_t __d, > memory_order __m = memory_order_seq_cst) noexcept > { return _M_b.fetch_add(__d, __m); } > > __pointer_type > fetch_add(ptrdiff_t __d, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return _M_b.fetch_add(__d, __m); } > > __pointer_type > fetch_sub(ptrdiff_t __d, > memory_order __m = memory_order_seq_cst) noexcept > { return _M_b.fetch_sub(__d, __m); } > > __pointer_type > fetch_sub(ptrdiff_t __d, > memory_order __m = memory_order_seq_cst) volatile noexcept > { return _M_b.fetch_sub(__d, __m); } > }; > > > > template<> > struct atomic<bool> : public atomic_bool > { > typedef bool __integral_type; > typedef atomic_bool __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<char> : public atomic_char > { > typedef char __integral_type; > typedef atomic_char __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<signed char> : public atomic_schar > { > typedef signed char __integral_type; > typedef atomic_schar __base_type; > > atomic() noexcept= default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<unsigned char> : public atomic_uchar > { > typedef unsigned char __integral_type; > typedef atomic_uchar __base_type; > > atomic() noexcept= default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<short> : public atomic_short > { > typedef short __integral_type; > typedef atomic_short __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<unsigned short> : public atomic_ushort > { > typedef unsigned short __integral_type; > typedef atomic_ushort __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<int> : atomic_int > { > typedef int __integral_type; > typedef atomic_int __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<unsigned int> : public atomic_uint > { > typedef unsigned int __integral_type; > typedef atomic_uint __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<long> : public atomic_long > { > typedef long __integral_type; > typedef atomic_long __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<unsigned long> : public atomic_ulong > { > typedef unsigned long __integral_type; > typedef atomic_ulong __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<long long> : public atomic_llong > { > typedef long long __integral_type; > typedef atomic_llong __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<unsigned long long> : public atomic_ullong > { > typedef unsigned long long __integral_type; > typedef atomic_ullong __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<wchar_t> : public atomic_wchar_t > { > typedef wchar_t __integral_type; > typedef atomic_wchar_t __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<char16_t> : public atomic_char16_t > { > typedef char16_t __integral_type; > typedef atomic_char16_t __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > template<> > struct atomic<char32_t> : public atomic_char32_t > { > typedef char32_t __integral_type; > typedef atomic_char32_t __base_type; > > atomic() noexcept = default; > ~atomic() noexcept = default; > atomic(const atomic&) = delete; > atomic& operator=(const atomic&) = delete; > atomic& operator=(const atomic&) volatile = delete; > > constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { } > > using __base_type::operator __integral_type; > using __base_type::operator=; > }; > > > > inline bool > atomic_flag_test_and_set_explicit(atomic_flag* __a, > memory_order __m) noexcept > { return __a->test_and_set(__m); } > > inline bool > atomic_flag_test_and_set_explicit(volatile atomic_flag* __a, > memory_order __m) noexcept > { return __a->test_and_set(__m); } > > inline void > atomic_flag_clear_explicit(atomic_flag* __a, memory_order __m) noexcept > { __a->clear(__m); } > > inline void > atomic_flag_clear_explicit(volatile atomic_flag* __a, > memory_order __m) noexcept > { __a->clear(__m); } > > inline bool > atomic_flag_test_and_set(atomic_flag* __a) noexcept > { return atomic_flag_test_and_set_explicit(__a, memory_order_seq_cst); } > > inline bool > atomic_flag_test_and_set(volatile atomic_flag* __a) noexcept > { return atomic_flag_test_and_set_explicit(__a, memory_order_seq_cst); } > > inline void > atomic_flag_clear(atomic_flag* __a) noexcept > { atomic_flag_clear_explicit(__a, memory_order_seq_cst); } > > inline void > atomic_flag_clear(volatile atomic_flag* __a) noexcept > { atomic_flag_clear_explicit(__a, memory_order_seq_cst); } > > > > template<typename _ITp> > inline bool > atomic_is_lock_free(const atomic<_ITp>* __a) noexcept > { return __a->is_lock_free(); } > > template<typename _ITp> > inline bool > atomic_is_lock_free(const volatile atomic<_ITp>* __a) noexcept > { return __a->is_lock_free(); } > > template<typename _ITp> > inline void > atomic_init(atomic<_ITp>* __a, _ITp __i) noexcept; > > template<typename _ITp> > inline void > atomic_init(volatile atomic<_ITp>* __a, _ITp __i) noexcept; > > template<typename _ITp> > inline void > atomic_store_explicit(atomic<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { __a->store(__i, __m); } > > template<typename _ITp> > inline void > atomic_store_explicit(volatile atomic<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { __a->store(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_load_explicit(const atomic<_ITp>* __a, memory_order __m) noexcept > { return __a->load(__m); } > > template<typename _ITp> > inline _ITp > atomic_load_explicit(const volatile atomic<_ITp>* __a, > memory_order __m) noexcept > { return __a->load(__m); } > > template<typename _ITp> > inline _ITp > atomic_exchange_explicit(atomic<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->exchange(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_exchange_explicit(volatile atomic<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->exchange(__i, __m); } > > template<typename _ITp> > inline bool > atomic_compare_exchange_weak_explicit(atomic<_ITp>* __a, > _ITp* __i1, _ITp __i2, > memory_order __m1, > memory_order __m2) noexcept > { return __a->compare_exchange_weak(*__i1, __i2, __m1, __m2); } > > template<typename _ITp> > inline bool > atomic_compare_exchange_weak_explicit(volatile atomic<_ITp>* __a, > _ITp* __i1, _ITp __i2, > memory_order __m1, > memory_order __m2) noexcept > { return __a->compare_exchange_weak(*__i1, __i2, __m1, __m2); } > > template<typename _ITp> > inline bool > atomic_compare_exchange_strong_explicit(atomic<_ITp>* __a, > _ITp* __i1, _ITp __i2, > memory_order __m1, > memory_order __m2) noexcept > { return __a->compare_exchange_strong(*__i1, __i2, __m1, __m2); } > > template<typename _ITp> > inline bool > atomic_compare_exchange_strong_explicit(volatile atomic<_ITp>* __a, > _ITp* __i1, _ITp __i2, > memory_order __m1, > memory_order __m2) noexcept > { return __a->compare_exchange_strong(*__i1, __i2, __m1, __m2); } > > > template<typename _ITp> > inline void > atomic_store(atomic<_ITp>* __a, _ITp __i) noexcept > { atomic_store_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline void > atomic_store(volatile atomic<_ITp>* __a, _ITp __i) noexcept > { atomic_store_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_load(const atomic<_ITp>* __a) noexcept > { return atomic_load_explicit(__a, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_load(const volatile atomic<_ITp>* __a) noexcept > { return atomic_load_explicit(__a, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_exchange(atomic<_ITp>* __a, _ITp __i) noexcept > { return atomic_exchange_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_exchange(volatile atomic<_ITp>* __a, _ITp __i) noexcept > { return atomic_exchange_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline bool > atomic_compare_exchange_weak(atomic<_ITp>* __a, > _ITp* __i1, _ITp __i2) noexcept > { > return atomic_compare_exchange_weak_explicit(__a, __i1, __i2, > memory_order_seq_cst, > memory_order_seq_cst); > } > > template<typename _ITp> > inline bool > atomic_compare_exchange_weak(volatile atomic<_ITp>* __a, > _ITp* __i1, _ITp __i2) noexcept > { > return atomic_compare_exchange_weak_explicit(__a, __i1, __i2, > memory_order_seq_cst, > memory_order_seq_cst); > } > > template<typename _ITp> > inline bool > atomic_compare_exchange_strong(atomic<_ITp>* __a, > _ITp* __i1, _ITp __i2) noexcept > { > return atomic_compare_exchange_strong_explicit(__a, __i1, __i2, > memory_order_seq_cst, > memory_order_seq_cst); > } > > template<typename _ITp> > inline bool > atomic_compare_exchange_strong(volatile atomic<_ITp>* __a, > _ITp* __i1, _ITp __i2) noexcept > { > return atomic_compare_exchange_strong_explicit(__a, __i1, __i2, > memory_order_seq_cst, > memory_order_seq_cst); > } > > > > > > template<typename _ITp> > inline _ITp > atomic_fetch_add_explicit(__atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_add(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_add_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_add(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_sub_explicit(__atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_sub(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_sub_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_sub(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_and_explicit(__atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_and(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_and_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_and(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_or_explicit(__atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_or(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_or_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_or(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_xor_explicit(__atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_xor(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_xor_explicit(volatile __atomic_base<_ITp>* __a, _ITp __i, > memory_order __m) noexcept > { return __a->fetch_xor(__i, __m); } > > template<typename _ITp> > inline _ITp > atomic_fetch_add(__atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_add_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_fetch_add(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_add_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_fetch_sub(__atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_sub_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_fetch_sub(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_sub_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_fetch_and(__atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_and_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_fetch_and(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_and_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_fetch_or(__atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_or_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_fetch_or(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_or_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_fetch_xor(__atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_xor_explicit(__a, __i, memory_order_seq_cst); } > > template<typename _ITp> > inline _ITp > atomic_fetch_xor(volatile __atomic_base<_ITp>* __a, _ITp __i) noexcept > { return atomic_fetch_xor_explicit(__a, __i, memory_order_seq_cst); } > > > > template<typename _ITp> > inline _ITp* > atomic_fetch_add_explicit(atomic<_ITp*>* __a, ptrdiff_t __d, > memory_order __m) noexcept > { return __a->fetch_add(__d, __m); } > > template<typename _ITp> > inline _ITp* > atomic_fetch_add_explicit(volatile atomic<_ITp*>* __a, ptrdiff_t __d, > memory_order __m) noexcept > { return __a->fetch_add(__d, __m); } > > template<typename _ITp> > inline _ITp* > atomic_fetch_add(volatile atomic<_ITp*>* __a, ptrdiff_t __d) noexcept > { return __a->fetch_add(__d); } > > template<typename _ITp> > inline _ITp* > atomic_fetch_add(atomic<_ITp*>* __a, ptrdiff_t __d) noexcept > { return __a->fetch_add(__d); } > > template<typename _ITp> > inline _ITp* > atomic_fetch_sub_explicit(volatile atomic<_ITp*>* __a, > ptrdiff_t __d, memory_order __m) noexcept > { return __a->fetch_sub(__d, __m); } > > template<typename _ITp> > inline _ITp* > atomic_fetch_sub_explicit(atomic<_ITp*>* __a, ptrdiff_t __d, > memory_order __m) noexcept > { return __a->fetch_sub(__d, __m); } > > template<typename _ITp> > inline _ITp* > atomic_fetch_sub(volatile atomic<_ITp*>* __a, ptrdiff_t __d) noexcept > { return __a->fetch_sub(__d); } > > template<typename _ITp> > inline _ITp* > atomic_fetch_sub(atomic<_ITp*>* __a, ptrdiff_t __d) noexcept > { return __a->fetch_sub(__d); } > > > >} ># 33 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 > ># 1 "/usr/include/c++/4.9.0/iostream" 1 3 ># 36 "/usr/include/c++/4.9.0/iostream" 3 ># 37 "/usr/include/c++/4.9.0/iostream" 3 > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 60 "/usr/include/c++/4.9.0/iostream" 3 > extern istream cin; > extern ostream cout; > extern ostream cerr; > extern ostream clog; > > > extern wistream wcin; > extern wostream wcout; > extern wostream wcerr; > extern wostream wclog; > > > > > static ios_base::Init __ioinit; > > >} ># 35 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/usr/include/c++/4.9.0/sstream" 1 3 ># 36 "/usr/include/c++/4.9.0/sstream" 3 ># 37 "/usr/include/c++/4.9.0/sstream" 3 > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 63 "/usr/include/c++/4.9.0/sstream" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > class basic_stringbuf : public basic_streambuf<_CharT, _Traits> > { > public: > > typedef _CharT char_type; > typedef _Traits traits_type; > > > typedef _Alloc allocator_type; > typedef typename traits_type::int_type int_type; > typedef typename traits_type::pos_type pos_type; > typedef typename traits_type::off_type off_type; > > typedef basic_streambuf<char_type, traits_type> __streambuf_type; > typedef basic_string<char_type, _Traits, _Alloc> __string_type; > typedef typename __string_type::size_type __size_type; > > protected: > > ios_base::openmode _M_mode; > > > __string_type _M_string; > > public: ># 97 "/usr/include/c++/4.9.0/sstream" 3 > explicit > basic_stringbuf(ios_base::openmode __mode = ios_base::in | ios_base::out) > : __streambuf_type(), _M_mode(__mode), _M_string() > { } ># 110 "/usr/include/c++/4.9.0/sstream" 3 > explicit > basic_stringbuf(const __string_type& __str, > ios_base::openmode __mode = ios_base::in | ios_base::out) > : __streambuf_type(), _M_mode(), _M_string(__str.data(), __str.size()) > { _M_stringbuf_init(__mode); } ># 125 "/usr/include/c++/4.9.0/sstream" 3 > __string_type > str() const > { > __string_type __ret; > if (this->pptr()) > { > > if (this->pptr() > this->egptr()) > __ret = __string_type(this->pbase(), this->pptr()); > else > __ret = __string_type(this->pbase(), this->egptr()); > } > else > __ret = _M_string; > return __ret; > } ># 149 "/usr/include/c++/4.9.0/sstream" 3 > void > str(const __string_type& __s) > { > > _M_string.assign(__s.data(), __s.size()); > _M_stringbuf_init(_M_mode); > } > > protected: > > void > _M_stringbuf_init(ios_base::openmode __mode) > { > _M_mode = __mode; > __size_type __len = 0; > if (_M_mode & (ios_base::ate | ios_base::app)) > __len = _M_string.size(); > _M_sync(const_cast<char_type*>(_M_string.data()), 0, __len); > } > > virtual streamsize > showmanyc() > { > streamsize __ret = -1; > if (_M_mode & ios_base::in) > { > _M_update_egptr(); > __ret = this->egptr() - this->gptr(); > } > return __ret; > } > > virtual int_type > underflow(); > > virtual int_type > pbackfail(int_type __c = traits_type::eof()); > > virtual int_type > overflow(int_type __c = traits_type::eof()); ># 201 "/usr/include/c++/4.9.0/sstream" 3 > virtual __streambuf_type* > setbuf(char_type* __s, streamsize __n) > { > if (__s && __n >= 0) > { > > > > > > > _M_string.clear(); > > > _M_sync(__s, __n, 0); > } > return this; > } > > virtual pos_type > seekoff(off_type __off, ios_base::seekdir __way, > ios_base::openmode __mode = ios_base::in | ios_base::out); > > virtual pos_type > seekpos(pos_type __sp, > ios_base::openmode __mode = ios_base::in | ios_base::out); > > > > > void > _M_sync(char_type* __base, __size_type __i, __size_type __o); > > > > void > _M_update_egptr() > { > const bool __testin = _M_mode & ios_base::in; > if (this->pptr() && this->pptr() > this->egptr()) > { > if (__testin) > this->setg(this->eback(), this->gptr(), this->pptr()); > else > this->setg(this->pptr(), this->pptr(), this->pptr()); > } > } > > > > void > _M_pbump(char_type* __pbeg, char_type* __pend, off_type __off); > }; ># 271 "/usr/include/c++/4.9.0/sstream" 3 > template<typename _CharT, typename _Traits, typename _Alloc> > class basic_istringstream : public basic_istream<_CharT, _Traits> > { > public: > > typedef _CharT char_type; > typedef _Traits traits_type; > > > typedef _Alloc allocator_type; > typedef typename traits_type::int_type int_type; > typedef typename traits_type::pos_type pos_type; > typedef typename traits_type::off_type off_type; > > > typedef basic_string<_CharT, _Traits, _Alloc> __string_type; > typedef basic_stringbuf<_CharT, _Traits, _Alloc> __stringbuf_type; > typedef basic_istream<char_type, traits_type> __istream_type; > > private: > __stringbuf_type _M_stringbuf; > > public: ># 307 "/usr/include/c++/4.9.0/sstream" 3 > explicit > basic_istringstream(ios_base::openmode __mode = ios_base::in) > : __istream_type(), _M_stringbuf(__mode | ios_base::in) > { this->init(&_M_stringbuf); } ># 325 "/usr/include/c++/4.9.0/sstream" 3 > explicit > basic_istringstream(const __string_type& __str, > ios_base::openmode __mode = ios_base::in) > : __istream_type(), _M_stringbuf(__str, __mode | ios_base::in) > { this->init(&_M_stringbuf); } > > > > > > > > ~basic_istringstream() > { } ># 347 "/usr/include/c++/4.9.0/sstream" 3 > __stringbuf_type* > rdbuf() const > { return const_cast<__stringbuf_type*>(&_M_stringbuf); } > > > > > > __string_type > str() const > { return _M_stringbuf.str(); } > > > > > > > > void > str(const __string_type& __s) > { _M_stringbuf.str(__s); } > }; ># 386 "/usr/include/c++/4.9.0/sstream" 3 > template <typename _CharT, typename _Traits, typename _Alloc> > class basic_ostringstream : public basic_ostream<_CharT, _Traits> > { > public: > > typedef _CharT char_type; > typedef _Traits traits_type; > > > typedef _Alloc allocator_type; > typedef typename traits_type::int_type int_type; > typedef typename traits_type::pos_type pos_type; > typedef typename traits_type::off_type off_type; > > > typedef basic_string<_CharT, _Traits, _Alloc> __string_type; > typedef basic_stringbuf<_CharT, _Traits, _Alloc> __stringbuf_type; > typedef basic_ostream<char_type, traits_type> __ostream_type; > > private: > __stringbuf_type _M_stringbuf; > > public: ># 422 "/usr/include/c++/4.9.0/sstream" 3 > explicit > basic_ostringstream(ios_base::openmode __mode = ios_base::out) > : __ostream_type(), _M_stringbuf(__mode | ios_base::out) > { this->init(&_M_stringbuf); } ># 440 "/usr/include/c++/4.9.0/sstream" 3 > explicit > basic_ostringstream(const __string_type& __str, > ios_base::openmode __mode = ios_base::out) > : __ostream_type(), _M_stringbuf(__str, __mode | ios_base::out) > { this->init(&_M_stringbuf); } > > > > > > > > ~basic_ostringstream() > { } ># 462 "/usr/include/c++/4.9.0/sstream" 3 > __stringbuf_type* > rdbuf() const > { return const_cast<__stringbuf_type*>(&_M_stringbuf); } > > > > > > __string_type > str() const > { return _M_stringbuf.str(); } > > > > > > > > void > str(const __string_type& __s) > { _M_stringbuf.str(__s); } > }; ># 501 "/usr/include/c++/4.9.0/sstream" 3 > template <typename _CharT, typename _Traits, typename _Alloc> > class basic_stringstream : public basic_iostream<_CharT, _Traits> > { > public: > > typedef _CharT char_type; > typedef _Traits traits_type; > > > typedef _Alloc allocator_type; > typedef typename traits_type::int_type int_type; > typedef typename traits_type::pos_type pos_type; > typedef typename traits_type::off_type off_type; > > > typedef basic_string<_CharT, _Traits, _Alloc> __string_type; > typedef basic_stringbuf<_CharT, _Traits, _Alloc> __stringbuf_type; > typedef basic_iostream<char_type, traits_type> __iostream_type; > > private: > __stringbuf_type _M_stringbuf; > > public: ># 536 "/usr/include/c++/4.9.0/sstream" 3 > explicit > basic_stringstream(ios_base::openmode __m = ios_base::out | ios_base::in) > : __iostream_type(), _M_stringbuf(__m) > { this->init(&_M_stringbuf); } ># 552 "/usr/include/c++/4.9.0/sstream" 3 > explicit > basic_stringstream(const __string_type& __str, > ios_base::openmode __m = ios_base::out | ios_base::in) > : __iostream_type(), _M_stringbuf(__str, __m) > { this->init(&_M_stringbuf); } > > > > > > > > ~basic_stringstream() > { } ># 574 "/usr/include/c++/4.9.0/sstream" 3 > __stringbuf_type* > rdbuf() const > { return const_cast<__stringbuf_type*>(&_M_stringbuf); } > > > > > > __string_type > str() const > { return _M_stringbuf.str(); } > > > > > > > > void > str(const __string_type& __s) > { _M_stringbuf.str(__s); } > }; > > >} > ># 1 "/usr/include/c++/4.9.0/bits/sstream.tcc" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/sstream.tcc" 3 ># 38 "/usr/include/c++/4.9.0/bits/sstream.tcc" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template <class _CharT, class _Traits, class _Alloc> > typename basic_stringbuf<_CharT, _Traits, _Alloc>::int_type > basic_stringbuf<_CharT, _Traits, _Alloc>:: > pbackfail(int_type __c) > { > int_type __ret = traits_type::eof(); > if (this->eback() < this->gptr()) > { > > > const bool __testeof = traits_type::eq_int_type(__c, __ret); > if (!__testeof) > { > const bool __testeq = traits_type::eq(traits_type:: > to_char_type(__c), > this->gptr()[-1]); > const bool __testout = this->_M_mode & ios_base::out; > if (__testeq || __testout) > { > this->gbump(-1); > if (!__testeq) > *this->gptr() = traits_type::to_char_type(__c); > __ret = __c; > } > } > else > { > this->gbump(-1); > __ret = traits_type::not_eof(__c); > } > } > return __ret; > } > > template <class _CharT, class _Traits, class _Alloc> > typename basic_stringbuf<_CharT, _Traits, _Alloc>::int_type > basic_stringbuf<_CharT, _Traits, _Alloc>:: > overflow(int_type __c) > { > const bool __testout = this->_M_mode & ios_base::out; > if (__builtin_expect(!__testout, false)) > return traits_type::eof(); > > const bool __testeof = traits_type::eq_int_type(__c, traits_type::eof()); > if (__builtin_expect(__testeof, false)) > return traits_type::not_eof(__c); > > const __size_type __capacity = _M_string.capacity(); > const __size_type __max_size = _M_string.max_size(); > const bool __testput = this->pptr() < this->epptr(); > if (__builtin_expect(!__testput && __capacity == __max_size, false)) > return traits_type::eof(); > > > > const char_type __conv = traits_type::to_char_type(__c); > if (!__testput) > { ># 110 "/usr/include/c++/4.9.0/bits/sstream.tcc" 3 > const __size_type __opt_len = std::max(__size_type(2 * __capacity), > __size_type(512)); > const __size_type __len = std::min(__opt_len, __max_size); > __string_type __tmp; > __tmp.reserve(__len); > if (this->pbase()) > __tmp.assign(this->pbase(), this->epptr() - this->pbase()); > __tmp.push_back(__conv); > _M_string.swap(__tmp); > _M_sync(const_cast<char_type*>(_M_string.data()), > this->gptr() - this->eback(), this->pptr() - this->pbase()); > } > else > *this->pptr() = __conv; > this->pbump(1); > return __c; > } > > template <class _CharT, class _Traits, class _Alloc> > typename basic_stringbuf<_CharT, _Traits, _Alloc>::int_type > basic_stringbuf<_CharT, _Traits, _Alloc>:: > underflow() > { > int_type __ret = traits_type::eof(); > const bool __testin = this->_M_mode & ios_base::in; > if (__testin) > { > > _M_update_egptr(); > > if (this->gptr() < this->egptr()) > __ret = traits_type::to_int_type(*this->gptr()); > } > return __ret; > } > > template <class _CharT, class _Traits, class _Alloc> > typename basic_stringbuf<_CharT, _Traits, _Alloc>::pos_type > basic_stringbuf<_CharT, _Traits, _Alloc>:: > seekoff(off_type __off, ios_base::seekdir __way, ios_base::openmode __mode) > { > pos_type __ret = pos_type(off_type(-1)); > bool __testin = (ios_base::in & this->_M_mode & __mode) != 0; > bool __testout = (ios_base::out & this->_M_mode & __mode) != 0; > const bool __testboth = __testin && __testout && __way != ios_base::cur; > __testin &= !(__mode & ios_base::out); > __testout &= !(__mode & ios_base::in); > > > > const char_type* __beg = __testin ? this->eback() : this->pbase(); > if ((__beg || !__off) && (__testin || __testout || __testboth)) > { > _M_update_egptr(); > > off_type __newoffi = __off; > off_type __newoffo = __newoffi; > if (__way == ios_base::cur) > { > __newoffi += this->gptr() - __beg; > __newoffo += this->pptr() - __beg; > } > else if (__way == ios_base::end) > __newoffo = __newoffi += this->egptr() - __beg; > > if ((__testin || __testboth) > && __newoffi >= 0 > && this->egptr() - __beg >= __newoffi) > { > this->setg(this->eback(), this->eback() + __newoffi, > this->egptr()); > __ret = pos_type(__newoffi); > } > if ((__testout || __testboth) > && __newoffo >= 0 > && this->egptr() - __beg >= __newoffo) > { > _M_pbump(this->pbase(), this->epptr(), __newoffo); > __ret = pos_type(__newoffo); > } > } > return __ret; > } > > template <class _CharT, class _Traits, class _Alloc> > typename basic_stringbuf<_CharT, _Traits, _Alloc>::pos_type > basic_stringbuf<_CharT, _Traits, _Alloc>:: > seekpos(pos_type __sp, ios_base::openmode __mode) > { > pos_type __ret = pos_type(off_type(-1)); > const bool __testin = (ios_base::in & this->_M_mode & __mode) != 0; > const bool __testout = (ios_base::out & this->_M_mode & __mode) != 0; > > const char_type* __beg = __testin ? this->eback() : this->pbase(); > if ((__beg || !off_type(__sp)) && (__testin || __testout)) > { > _M_update_egptr(); > > const off_type __pos(__sp); > const bool __testpos = (0 <= __pos > && __pos <= this->egptr() - __beg); > if (__testpos) > { > if (__testin) > this->setg(this->eback(), this->eback() + __pos, > this->egptr()); > if (__testout) > _M_pbump(this->pbase(), this->epptr(), __pos); > __ret = __sp; > } > } > return __ret; > } > > template <class _CharT, class _Traits, class _Alloc> > void > basic_stringbuf<_CharT, _Traits, _Alloc>:: > _M_sync(char_type* __base, __size_type __i, __size_type __o) > { > const bool __testin = _M_mode & ios_base::in; > const bool __testout = _M_mode & ios_base::out; > char_type* __endg = __base + _M_string.size(); > char_type* __endp = __base + _M_string.capacity(); > > if (__base != _M_string.data()) > { > > __endg += __i; > __i = 0; > __endp = __endg; > } > > if (__testin) > this->setg(__base, __base + __i, __endg); > if (__testout) > { > _M_pbump(__base, __endp, __o); > > > > if (!__testin) > this->setg(__endg, __endg, __endg); > } > } > > template <class _CharT, class _Traits, class _Alloc> > void > basic_stringbuf<_CharT, _Traits, _Alloc>:: > _M_pbump(char_type* __pbeg, char_type* __pend, off_type __off) > { > this->setp(__pbeg, __pend); > while (__off > __gnu_cxx::__numeric_traits<int>::__max) > { > this->pbump(__gnu_cxx::__numeric_traits<int>::__max); > __off -= __gnu_cxx::__numeric_traits<int>::__max; > } > this->pbump(__off); > } > > > > > extern template class basic_stringbuf<char>; > extern template class basic_istringstream<char>; > extern template class basic_ostringstream<char>; > extern template class basic_stringstream<char>; > > > extern template class basic_stringbuf<wchar_t>; > extern template class basic_istringstream<wchar_t>; > extern template class basic_ostringstream<wchar_t>; > extern template class basic_stringstream<wchar_t>; > > > > >} ># 601 "/usr/include/c++/4.9.0/sstream" 2 3 ># 36 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/usr/include/c++/4.9.0/iomanip" 1 3 ># 36 "/usr/include/c++/4.9.0/iomanip" 3 ># 37 "/usr/include/c++/4.9.0/iomanip" 3 > > > > > > ># 1 "/usr/include/c++/4.9.0/locale" 1 3 ># 36 "/usr/include/c++/4.9.0/locale" 3 ># 37 "/usr/include/c++/4.9.0/locale" 3 > > > > ># 1 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 ># 38 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > ># 1 "/usr/include/c++/4.9.0/ctime" 1 3 ># 39 "/usr/include/c++/4.9.0/ctime" 3 ># 40 "/usr/include/c++/4.9.0/ctime" 3 ># 58 "/usr/include/c++/4.9.0/ctime" 3 >namespace std >{ > using ::clock_t; > using ::time_t; > using ::tm; > > using ::clock; > using ::difftime; > using ::mktime; > using ::time; > using ::asctime; > using ::ctime; > using ::gmtime; > using ::localtime; > using ::strftime; >} ># 40 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 52 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > class time_base > { > public: > enum dateorder { no_order, dmy, mdy, ymd, ydm }; > }; > > template<typename _CharT> > struct __timepunct_cache : public locale::facet > { > > static const _CharT* _S_timezones[14]; > > const _CharT* _M_date_format; > const _CharT* _M_date_era_format; > const _CharT* _M_time_format; > const _CharT* _M_time_era_format; > const _CharT* _M_date_time_format; > const _CharT* _M_date_time_era_format; > const _CharT* _M_am; > const _CharT* _M_pm; > const _CharT* _M_am_pm_format; > > > const _CharT* _M_day1; > const _CharT* _M_day2; > const _CharT* _M_day3; > const _CharT* _M_day4; > const _CharT* _M_day5; > const _CharT* _M_day6; > const _CharT* _M_day7; > > > const _CharT* _M_aday1; > const _CharT* _M_aday2; > const _CharT* _M_aday3; > const _CharT* _M_aday4; > const _CharT* _M_aday5; > const _CharT* _M_aday6; > const _CharT* _M_aday7; > > > const _CharT* _M_month01; > const _CharT* _M_month02; > const _CharT* _M_month03; > const _CharT* _M_month04; > const _CharT* _M_month05; > const _CharT* _M_month06; > const _CharT* _M_month07; > const _CharT* _M_month08; > const _CharT* _M_month09; > const _CharT* _M_month10; > const _CharT* _M_month11; > const _CharT* _M_month12; > > > const _CharT* _M_amonth01; > const _CharT* _M_amonth02; > const _CharT* _M_amonth03; > const _CharT* _M_amonth04; > const _CharT* _M_amonth05; > const _CharT* _M_amonth06; > const _CharT* _M_amonth07; > const _CharT* _M_amonth08; > const _CharT* _M_amonth09; > const _CharT* _M_amonth10; > const _CharT* _M_amonth11; > const _CharT* _M_amonth12; > > bool _M_allocated; > > __timepunct_cache(size_t __refs = 0) : facet(__refs), > _M_date_format(0), _M_date_era_format(0), _M_time_format(0), > _M_time_era_format(0), _M_date_time_format(0), > _M_date_time_era_format(0), _M_am(0), _M_pm(0), > _M_am_pm_format(0), _M_day1(0), _M_day2(0), _M_day3(0), > _M_day4(0), _M_day5(0), _M_day6(0), _M_day7(0), > _M_aday1(0), _M_aday2(0), _M_aday3(0), _M_aday4(0), > _M_aday5(0), _M_aday6(0), _M_aday7(0), _M_month01(0), > _M_month02(0), _M_month03(0), _M_month04(0), _M_month05(0), > _M_month06(0), _M_month07(0), _M_month08(0), _M_month09(0), > _M_month10(0), _M_month11(0), _M_month12(0), _M_amonth01(0), > _M_amonth02(0), _M_amonth03(0), _M_amonth04(0), > _M_amonth05(0), _M_amonth06(0), _M_amonth07(0), > _M_amonth08(0), _M_amonth09(0), _M_amonth10(0), > _M_amonth11(0), _M_amonth12(0), _M_allocated(false) > { } > > ~__timepunct_cache(); > > void > _M_cache(const locale& __loc); > > private: > __timepunct_cache& > operator=(const __timepunct_cache&); > > explicit > __timepunct_cache(const __timepunct_cache&); > }; > > template<typename _CharT> > __timepunct_cache<_CharT>::~__timepunct_cache() > { > if (_M_allocated) > { > > } > } > > > template<> > const char* > __timepunct_cache<char>::_S_timezones[14]; > > > template<> > const wchar_t* > __timepunct_cache<wchar_t>::_S_timezones[14]; > > > > template<typename _CharT> > const _CharT* __timepunct_cache<_CharT>::_S_timezones[14]; > > template<typename _CharT> > class __timepunct : public locale::facet > { > public: > > typedef _CharT __char_type; > typedef basic_string<_CharT> __string_type; > typedef __timepunct_cache<_CharT> __cache_type; > > protected: > __cache_type* _M_data; > __c_locale _M_c_locale_timepunct; > const char* _M_name_timepunct; > > public: > > static locale::id id; > > explicit > __timepunct(size_t __refs = 0); > > explicit > __timepunct(__cache_type* __cache, size_t __refs = 0); ># 210 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > __timepunct(__c_locale __cloc, const char* __s, size_t __refs = 0); > > > > void > _M_put(_CharT* __s, size_t __maxlen, const _CharT* __format, > const tm* __tm) const throw (); > > void > _M_date_formats(const _CharT** __date) const > { > > __date[0] = _M_data->_M_date_format; > __date[1] = _M_data->_M_date_era_format; > } > > void > _M_time_formats(const _CharT** __time) const > { > > __time[0] = _M_data->_M_time_format; > __time[1] = _M_data->_M_time_era_format; > } > > void > _M_date_time_formats(const _CharT** __dt) const > { > > __dt[0] = _M_data->_M_date_time_format; > __dt[1] = _M_data->_M_date_time_era_format; > } > > void > _M_am_pm_format(const _CharT* __ampm) const > { __ampm = _M_data->_M_am_pm_format; } > > void > _M_am_pm(const _CharT** __ampm) const > { > __ampm[0] = _M_data->_M_am; > __ampm[1] = _M_data->_M_pm; > } > > void > _M_days(const _CharT** __days) const > { > __days[0] = _M_data->_M_day1; > __days[1] = _M_data->_M_day2; > __days[2] = _M_data->_M_day3; > __days[3] = _M_data->_M_day4; > __days[4] = _M_data->_M_day5; > __days[5] = _M_data->_M_day6; > __days[6] = _M_data->_M_day7; > } > > void > _M_days_abbreviated(const _CharT** __days) const > { > __days[0] = _M_data->_M_aday1; > __days[1] = _M_data->_M_aday2; > __days[2] = _M_data->_M_aday3; > __days[3] = _M_data->_M_aday4; > __days[4] = _M_data->_M_aday5; > __days[5] = _M_data->_M_aday6; > __days[6] = _M_data->_M_aday7; > } > > void > _M_months(const _CharT** __months) const > { > __months[0] = _M_data->_M_month01; > __months[1] = _M_data->_M_month02; > __months[2] = _M_data->_M_month03; > __months[3] = _M_data->_M_month04; > __months[4] = _M_data->_M_month05; > __months[5] = _M_data->_M_month06; > __months[6] = _M_data->_M_month07; > __months[7] = _M_data->_M_month08; > __months[8] = _M_data->_M_month09; > __months[9] = _M_data->_M_month10; > __months[10] = _M_data->_M_month11; > __months[11] = _M_data->_M_month12; > } > > void > _M_months_abbreviated(const _CharT** __months) const > { > __months[0] = _M_data->_M_amonth01; > __months[1] = _M_data->_M_amonth02; > __months[2] = _M_data->_M_amonth03; > __months[3] = _M_data->_M_amonth04; > __months[4] = _M_data->_M_amonth05; > __months[5] = _M_data->_M_amonth06; > __months[6] = _M_data->_M_amonth07; > __months[7] = _M_data->_M_amonth08; > __months[8] = _M_data->_M_amonth09; > __months[9] = _M_data->_M_amonth10; > __months[10] = _M_data->_M_amonth11; > __months[11] = _M_data->_M_amonth12; > } > > protected: > virtual > ~__timepunct(); > > > void > _M_initialize_timepunct(__c_locale __cloc = 0); > }; > > template<typename _CharT> > locale::id __timepunct<_CharT>::id; > > > template<> > void > __timepunct<char>::_M_initialize_timepunct(__c_locale __cloc); > > template<> > void > __timepunct<char>::_M_put(char*, size_t, const char*, const tm*) const throw (); > > > template<> > void > __timepunct<wchar_t>::_M_initialize_timepunct(__c_locale __cloc); > > template<> > void > __timepunct<wchar_t>::_M_put(wchar_t*, size_t, const wchar_t*, > const tm*) const throw (); > > > >} > > ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/time_members.h" 1 3 ># 37 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/time_members.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT> > __timepunct<_CharT>::__timepunct(size_t __refs) > : facet(__refs), _M_data(0), _M_c_locale_timepunct(0), > _M_name_timepunct(_S_get_c_name()) > { _M_initialize_timepunct(); } > > template<typename _CharT> > __timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs) > : facet(__refs), _M_data(__cache), _M_c_locale_timepunct(0), > _M_name_timepunct(_S_get_c_name()) > { _M_initialize_timepunct(); } > > template<typename _CharT> > __timepunct<_CharT>::__timepunct(__c_locale __cloc, const char* __s, > size_t __refs) > : facet(__refs), _M_data(0), _M_c_locale_timepunct(0), > _M_name_timepunct(0) > { > if (__builtin_strcmp(__s, _S_get_c_name()) != 0) > { > const size_t __len = __builtin_strlen(__s) + 1; > char* __tmp = new char[__len]; > __builtin_memcpy(__tmp, __s, __len); > _M_name_timepunct = __tmp; > } > else > _M_name_timepunct = _S_get_c_name(); > > try > { _M_initialize_timepunct(__cloc); } > catch(...) > { > if (_M_name_timepunct != _S_get_c_name()) > delete [] _M_name_timepunct; > throw; > } > } > > template<typename _CharT> > __timepunct<_CharT>::~__timepunct() > { > if (_M_name_timepunct != _S_get_c_name()) > delete [] _M_name_timepunct; > delete _M_data; > _S_destroy_c_locale(_M_c_locale_timepunct); > } > > >} ># 349 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 367 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > template<typename _CharT, typename _InIter> > class time_get : public locale::facet, public time_base > { > public: > > > > typedef _CharT char_type; > typedef _InIter iter_type; > > typedef basic_string<_CharT> __string_type; > > > static locale::id id; ># 389 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > time_get(size_t __refs = 0) > : facet (__refs) { } ># 406 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > dateorder > date_order() const > { return this->do_date_order(); } ># 430 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > get_time(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const > { return this->do_get_time(__beg, __end, __io, __err, __tm); } ># 455 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > get_date(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const > { return this->do_get_date(__beg, __end, __io, __err, __tm); } ># 483 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > get_weekday(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const > { return this->do_get_weekday(__beg, __end, __io, __err, __tm); } ># 512 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > get_monthname(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const > { return this->do_get_monthname(__beg, __end, __io, __err, __tm); } ># 538 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > get_year(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const > { return this->do_get_year(__beg, __end, __io, __err, __tm); } > > protected: > > virtual > ~time_get() { } ># 558 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual dateorder > do_date_order() const; ># 576 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_get_time(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const; ># 595 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_get_date(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const; ># 614 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_get_weekday(iter_type __beg, iter_type __end, ios_base&, > ios_base::iostate& __err, tm* __tm) const; ># 633 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_get_monthname(iter_type __beg, iter_type __end, ios_base&, > ios_base::iostate& __err, tm* __tm) const; ># 652 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_get_year(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const; > > > iter_type > _M_extract_num(iter_type __beg, iter_type __end, int& __member, > int __min, int __max, size_t __len, > ios_base& __io, ios_base::iostate& __err) const; > > > iter_type > _M_extract_name(iter_type __beg, iter_type __end, int& __member, > const _CharT** __names, size_t __indexlen, > ios_base& __io, ios_base::iostate& __err) const; > > > iter_type > _M_extract_wday_or_month(iter_type __beg, iter_type __end, int& __member, > const _CharT** __names, size_t __indexlen, > ios_base& __io, ios_base::iostate& __err) const; > > > iter_type > _M_extract_via_format(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm, > const _CharT* __format) const; > }; > > template<typename _CharT, typename _InIter> > locale::id time_get<_CharT, _InIter>::id; > > > template<typename _CharT, typename _InIter> > class time_get_byname : public time_get<_CharT, _InIter> > { > public: > > typedef _CharT char_type; > typedef _InIter iter_type; > > explicit > time_get_byname(const char*, size_t __refs = 0) > : time_get<_CharT, _InIter>(__refs) { } > > protected: > virtual > ~time_get_byname() { } > }; ># 714 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > template<typename _CharT, typename _OutIter> > class time_put : public locale::facet > { > public: > > > > typedef _CharT char_type; > typedef _OutIter iter_type; > > > > static locale::id id; ># 735 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > time_put(size_t __refs = 0) > : facet(__refs) { } ># 754 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, const tm* __tm, > const _CharT* __beg, const _CharT* __end) const; ># 774 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > put(iter_type __s, ios_base& __io, char_type __fill, > const tm* __tm, char __format, char __mod = 0) const > { return this->do_put(__s, __io, __fill, __tm, __format, __mod); } > > protected: > > virtual > ~time_put() > { } ># 801 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_put(iter_type __s, ios_base& __io, char_type __fill, const tm* __tm, > char __format, char __mod) const; > }; > > template<typename _CharT, typename _OutIter> > locale::id time_put<_CharT, _OutIter>::id; > > > template<typename _CharT, typename _OutIter> > class time_put_byname : public time_put<_CharT, _OutIter> > { > public: > > typedef _CharT char_type; > typedef _OutIter iter_type; > > explicit > time_put_byname(const char*, size_t __refs = 0) > : time_put<_CharT, _OutIter>(__refs) > { }; > > protected: > virtual > ~time_put_byname() { } > }; ># 840 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > class money_base > { > public: > enum part { none, space, symbol, sign, value }; > struct pattern { char field[4]; }; > > static const pattern _S_default_pattern; > > enum > { > _S_minus, > _S_zero, > _S_end = 11 > }; > > > > static const char* _S_atoms; > > > > __attribute__ ((__const__)) static pattern > _S_construct_pattern(char __precedes, char __space, char __posn) throw (); > }; > > template<typename _CharT, bool _Intl> > struct __moneypunct_cache : public locale::facet > { > const char* _M_grouping; > size_t _M_grouping_size; > bool _M_use_grouping; > _CharT _M_decimal_point; > _CharT _M_thousands_sep; > const _CharT* _M_curr_symbol; > size_t _M_curr_symbol_size; > const _CharT* _M_positive_sign; > size_t _M_positive_sign_size; > const _CharT* _M_negative_sign; > size_t _M_negative_sign_size; > int _M_frac_digits; > money_base::pattern _M_pos_format; > money_base::pattern _M_neg_format; > > > > > _CharT _M_atoms[money_base::_S_end]; > > bool _M_allocated; > > __moneypunct_cache(size_t __refs = 0) : facet(__refs), > _M_grouping(0), _M_grouping_size(0), _M_use_grouping(false), > _M_decimal_point(_CharT()), _M_thousands_sep(_CharT()), > _M_curr_symbol(0), _M_curr_symbol_size(0), > _M_positive_sign(0), _M_positive_sign_size(0), > _M_negative_sign(0), _M_negative_sign_size(0), > _M_frac_digits(0), > _M_pos_format(money_base::pattern()), > _M_neg_format(money_base::pattern()), _M_allocated(false) > { } > > ~__moneypunct_cache(); > > void > _M_cache(const locale& __loc); > > private: > __moneypunct_cache& > operator=(const __moneypunct_cache&); > > explicit > __moneypunct_cache(const __moneypunct_cache&); > }; > > template<typename _CharT, bool _Intl> > __moneypunct_cache<_CharT, _Intl>::~__moneypunct_cache() > { > if (_M_allocated) > { > delete [] _M_grouping; > delete [] _M_curr_symbol; > delete [] _M_positive_sign; > delete [] _M_negative_sign; > } > } ># 933 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > template<typename _CharT, bool _Intl> > class moneypunct : public locale::facet, public money_base > { > public: > > > > typedef _CharT char_type; > typedef basic_string<_CharT> string_type; > > typedef __moneypunct_cache<_CharT, _Intl> __cache_type; > > private: > __cache_type* _M_data; > > public: > > > static const bool intl = _Intl; > > static locale::id id; ># 962 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > moneypunct(size_t __refs = 0) > : facet(__refs), _M_data(0) > { _M_initialize_moneypunct(); } ># 975 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > moneypunct(__cache_type* __cache, size_t __refs = 0) > : facet(__refs), _M_data(__cache) > { _M_initialize_moneypunct(); } ># 990 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > moneypunct(__c_locale __cloc, const char* __s, size_t __refs = 0) > : facet(__refs), _M_data(0) > { _M_initialize_moneypunct(__cloc, __s); } ># 1004 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > char_type > decimal_point() const > { return this->do_decimal_point(); } ># 1017 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > char_type > thousands_sep() const > { return this->do_thousands_sep(); } ># 1047 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > string > grouping() const > { return this->do_grouping(); } ># 1060 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > string_type > curr_symbol() const > { return this->do_curr_symbol(); } ># 1077 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > string_type > positive_sign() const > { return this->do_positive_sign(); } ># 1094 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > string_type > negative_sign() const > { return this->do_negative_sign(); } ># 1110 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > int > frac_digits() const > { return this->do_frac_digits(); } ># 1146 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > pattern > pos_format() const > { return this->do_pos_format(); } > > pattern > neg_format() const > { return this->do_neg_format(); } > > > protected: > > virtual > ~moneypunct(); ># 1168 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual char_type > do_decimal_point() const > { return _M_data->_M_decimal_point; } ># 1180 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual char_type > do_thousands_sep() const > { return _M_data->_M_thousands_sep; } ># 1193 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual string > do_grouping() const > { return _M_data->_M_grouping; } ># 1206 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual string_type > do_curr_symbol() const > { return _M_data->_M_curr_symbol; } ># 1219 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual string_type > do_positive_sign() const > { return _M_data->_M_positive_sign; } ># 1232 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual string_type > do_negative_sign() const > { return _M_data->_M_negative_sign; } ># 1246 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual int > do_frac_digits() const > { return _M_data->_M_frac_digits; } ># 1260 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual pattern > do_pos_format() const > { return _M_data->_M_pos_format; } ># 1274 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual pattern > do_neg_format() const > { return _M_data->_M_neg_format; } > > > void > _M_initialize_moneypunct(__c_locale __cloc = 0, > const char* __name = 0); > }; > > template<typename _CharT, bool _Intl> > locale::id moneypunct<_CharT, _Intl>::id; > > template<typename _CharT, bool _Intl> > const bool moneypunct<_CharT, _Intl>::intl; > > template<> > moneypunct<char, true>::~moneypunct(); > > template<> > moneypunct<char, false>::~moneypunct(); > > template<> > void > moneypunct<char, true>::_M_initialize_moneypunct(__c_locale, const char*); > > template<> > void > moneypunct<char, false>::_M_initialize_moneypunct(__c_locale, const char*); > > > template<> > moneypunct<wchar_t, true>::~moneypunct(); > > template<> > moneypunct<wchar_t, false>::~moneypunct(); > > template<> > void > moneypunct<wchar_t, true>::_M_initialize_moneypunct(__c_locale, > const char*); > > template<> > void > moneypunct<wchar_t, false>::_M_initialize_moneypunct(__c_locale, > const char*); > > > > template<typename _CharT, bool _Intl> > class moneypunct_byname : public moneypunct<_CharT, _Intl> > { > public: > typedef _CharT char_type; > typedef basic_string<_CharT> string_type; > > static const bool intl = _Intl; > > explicit > moneypunct_byname(const char* __s, size_t __refs = 0) > : moneypunct<_CharT, _Intl>(__refs) > { > if (__builtin_strcmp(__s, "C") != 0 > && __builtin_strcmp(__s, "POSIX") != 0) > { > __c_locale __tmp; > this->_S_create_c_locale(__tmp, __s); > this->_M_initialize_moneypunct(__tmp); > this->_S_destroy_c_locale(__tmp); > } > } > > protected: > virtual > ~moneypunct_byname() { } > }; > > template<typename _CharT, bool _Intl> > const bool moneypunct_byname<_CharT, _Intl>::intl; ># 1369 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > template<typename _CharT, typename _InIter> > class money_get : public locale::facet > { > public: > > > > typedef _CharT char_type; > typedef _InIter iter_type; > typedef basic_string<_CharT> string_type; > > > > static locale::id id; ># 1391 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > money_get(size_t __refs = 0) : facet(__refs) { } ># 1421 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > get(iter_type __s, iter_type __end, bool __intl, ios_base& __io, > ios_base::iostate& __err, long double& __units) const > { return this->do_get(__s, __end, __intl, __io, __err, __units); } ># 1452 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > get(iter_type __s, iter_type __end, bool __intl, ios_base& __io, > ios_base::iostate& __err, string_type& __digits) const > { return this->do_get(__s, __end, __intl, __io, __err, __digits); } > > protected: > > virtual > ~money_get() { } ># 1475 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_get(iter_type __s, iter_type __end, bool __intl, ios_base& __io, > ios_base::iostate& __err, long double& __units) const; ># 1487 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_get(iter_type __s, iter_type __end, bool __intl, ios_base& __io, > ios_base::iostate& __err, string_type& __digits) const; ># 1498 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > template<bool _Intl> > iter_type > _M_extract(iter_type __s, iter_type __end, ios_base& __io, > ios_base::iostate& __err, string& __digits) const; > }; > > template<typename _CharT, typename _InIter> > locale::id money_get<_CharT, _InIter>::id; ># 1520 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > template<typename _CharT, typename _OutIter> > class money_put : public locale::facet > { > public: > > > typedef _CharT char_type; > typedef _OutIter iter_type; > typedef basic_string<_CharT> string_type; > > > > static locale::id id; ># 1541 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > money_put(size_t __refs = 0) : facet(__refs) { } ># 1561 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > put(iter_type __s, bool __intl, ios_base& __io, > char_type __fill, long double __units) const > { return this->do_put(__s, __intl, __io, __fill, __units); } ># 1584 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > iter_type > put(iter_type __s, bool __intl, ios_base& __io, > char_type __fill, const string_type& __digits) const > { return this->do_put(__s, __intl, __io, __fill, __digits); } > > protected: > > virtual > ~money_put() { } ># 1618 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_put(iter_type __s, bool __intl, ios_base& __io, char_type __fill, > long double __units) const; ># 1642 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual iter_type > do_put(iter_type __s, bool __intl, ios_base& __io, char_type __fill, > const string_type& __digits) const; ># 1653 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > template<bool _Intl> > iter_type > _M_insert(iter_type __s, ios_base& __io, char_type __fill, > const string_type& __digits) const; > }; > > template<typename _CharT, typename _OutIter> > locale::id money_put<_CharT, _OutIter>::id; > > > > > > > > struct messages_base > { > typedef int catalog; > }; ># 1694 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > template<typename _CharT> > class messages : public locale::facet, public messages_base > { > public: > > > > typedef _CharT char_type; > typedef basic_string<_CharT> string_type; > > > protected: > > > __c_locale _M_c_locale_messages; > const char* _M_name_messages; > > public: > > static locale::id id; ># 1722 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > messages(size_t __refs = 0); ># 1736 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > explicit > messages(__c_locale __cloc, const char* __s, size_t __refs = 0); ># 1749 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > catalog > open(const basic_string<char>& __s, const locale& __loc) const > { return this->do_open(__s, __loc); } ># 1767 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > catalog > open(const basic_string<char>&, const locale&, const char*) const; ># 1785 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > string_type > get(catalog __c, int __set, int __msgid, const string_type& __s) const > { return this->do_get(__c, __set, __msgid, __s); } ># 1796 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > void > close(catalog __c) const > { return this->do_close(__c); } > > protected: > > virtual > ~messages(); ># 1816 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual catalog > do_open(const basic_string<char>&, const locale&) const; ># 1835 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 3 > virtual string_type > do_get(catalog, int, int, const string_type& __dfault) const; > > > > > > > virtual void > do_close(catalog) const; > > > char* > _M_convert_to_char(const string_type& __msg) const > { > > return reinterpret_cast<char*>(const_cast<_CharT*>(__msg.c_str())); > } > > > string_type > _M_convert_from_char(char*) const > { > > return string_type(); > } > }; > > template<typename _CharT> > locale::id messages<_CharT>::id; > > > template<> > string > messages<char>::do_get(catalog, int, int, const string&) const; > > > template<> > wstring > messages<wchar_t>::do_get(catalog, int, int, const wstring&) const; > > > > template<typename _CharT> > class messages_byname : public messages<_CharT> > { > public: > typedef _CharT char_type; > typedef basic_string<_CharT> string_type; > > explicit > messages_byname(const char* __s, size_t __refs = 0); > > protected: > virtual > ~messages_byname() > { } > }; > > >} > > ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/messages_members.h" 1 3 ># 36 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/messages_members.h" 3 ># 1 "/usr/include/libintl.h" 1 3 4 ># 34 "/usr/include/libintl.h" 3 4 >extern "C" { > > > > >extern char *gettext (const char *__msgid) > throw () __attribute__ ((__format_arg__ (1))); > > > >extern char *dgettext (const char *__domainname, const char *__msgid) > throw () __attribute__ ((__format_arg__ (2))); >extern char *__dgettext (const char *__domainname, const char *__msgid) > throw () __attribute__ ((__format_arg__ (2))); > > > >extern char *dcgettext (const char *__domainname, > const char *__msgid, int __category) > throw () __attribute__ ((__format_arg__ (2))); >extern char *__dcgettext (const char *__domainname, > const char *__msgid, int __category) > throw () __attribute__ ((__format_arg__ (2))); > > > > >extern char *ngettext (const char *__msgid1, const char *__msgid2, > unsigned long int __n) > throw () __attribute__ ((__format_arg__ (1))) __attribute__ ((__format_arg__ (2))); > > > >extern char *dngettext (const char *__domainname, const char *__msgid1, > const char *__msgid2, unsigned long int __n) > throw () __attribute__ ((__format_arg__ (2))) __attribute__ ((__format_arg__ (3))); > > > >extern char *dcngettext (const char *__domainname, const char *__msgid1, > const char *__msgid2, unsigned long int __n, > int __category) > throw () __attribute__ ((__format_arg__ (2))) __attribute__ ((__format_arg__ (3))); > > > > > >extern char *textdomain (const char *__domainname) throw (); > > > >extern char *bindtextdomain (const char *__domainname, > const char *__dirname) throw (); > > > >extern char *bind_textdomain_codeset (const char *__domainname, > const char *__codeset) throw (); ># 121 "/usr/include/libintl.h" 3 4 >} ># 37 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/messages_members.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template<typename _CharT> > messages<_CharT>::messages(size_t __refs) > : facet(__refs), _M_c_locale_messages(_S_get_c_locale()), > _M_name_messages(_S_get_c_name()) > { } > > template<typename _CharT> > messages<_CharT>::messages(__c_locale __cloc, const char* __s, > size_t __refs) > : facet(__refs), _M_c_locale_messages(0), _M_name_messages(0) > { > if (__builtin_strcmp(__s, _S_get_c_name()) != 0) > { > const size_t __len = __builtin_strlen(__s) + 1; > char* __tmp = new char[__len]; > __builtin_memcpy(__tmp, __s, __len); > _M_name_messages = __tmp; > } > else > _M_name_messages = _S_get_c_name(); > > > _M_c_locale_messages = _S_clone_c_locale(__cloc); > } > > template<typename _CharT> > typename messages<_CharT>::catalog > messages<_CharT>::open(const basic_string<char>& __s, const locale& __loc, > const char* __dir) const > { > bindtextdomain(__s.c_str(), __dir); > return this->do_open(__s, __loc); > } > > > template<typename _CharT> > messages<_CharT>::~messages() > { > if (_M_name_messages != _S_get_c_name()) > delete [] _M_name_messages; > _S_destroy_c_locale(_M_c_locale_messages); > } > > template<typename _CharT> > typename messages<_CharT>::catalog > messages<_CharT>::do_open(const basic_string<char>& __s, > const locale&) const > { > > > textdomain(__s.c_str()); > return 0; > } > > template<typename _CharT> > void > messages<_CharT>::do_close(catalog) const > { } > > > template<typename _CharT> > messages_byname<_CharT>::messages_byname(const char* __s, size_t __refs) > : messages<_CharT>(__refs) > { > if (this->_M_name_messages != locale::facet::_S_get_c_name()) > { > delete [] this->_M_name_messages; > if (__builtin_strcmp(__s, locale::facet::_S_get_c_name()) != 0) > { > const size_t __len = __builtin_strlen(__s) + 1; > char* __tmp = new char[__len]; > __builtin_memcpy(__tmp, __s, __len); > this->_M_name_messages = __tmp; > } > else > this->_M_name_messages = locale::facet::_S_get_c_name(); > } > > if (__builtin_strcmp(__s, "C") != 0 > && __builtin_strcmp(__s, "POSIX") != 0) > { > this->_S_destroy_c_locale(this->_M_c_locale_messages); > this->_S_create_c_locale(this->_M_c_locale_messages, __s); > } > } > > >} ># 1899 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 2 3 > > ># 1 "/usr/include/c++/4.9.0/bits/codecvt.h" 1 3 ># 39 "/usr/include/c++/4.9.0/bits/codecvt.h" 3 ># 40 "/usr/include/c++/4.9.0/bits/codecvt.h" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > class codecvt_base > { > public: > enum result > { > ok, > partial, > error, > noconv > }; > }; ># 67 "/usr/include/c++/4.9.0/bits/codecvt.h" 3 > template<typename _InternT, typename _ExternT, typename _StateT> > class __codecvt_abstract_base > : public locale::facet, public codecvt_base > { > public: > > typedef codecvt_base::result result; > typedef _InternT intern_type; > typedef _ExternT extern_type; > typedef _StateT state_type; ># 115 "/usr/include/c++/4.9.0/bits/codecvt.h" 3 > result > out(state_type& __state, const intern_type* __from, > const intern_type* __from_end, const intern_type*& __from_next, > extern_type* __to, extern_type* __to_end, > extern_type*& __to_next) const > { > return this->do_out(__state, __from, __from_end, __from_next, > __to, __to_end, __to_next); > } ># 154 "/usr/include/c++/4.9.0/bits/codecvt.h" 3 > result > unshift(state_type& __state, extern_type* __to, extern_type* __to_end, > extern_type*& __to_next) const > { return this->do_unshift(__state, __to,__to_end,__to_next); } ># 195 "/usr/include/c++/4.9.0/bits/codecvt.h" 3 > result > in(state_type& __state, const extern_type* __from, > const extern_type* __from_end, const extern_type*& __from_next, > intern_type* __to, intern_type* __to_end, > intern_type*& __to_next) const > { > return this->do_in(__state, __from, __from_end, __from_next, > __to, __to_end, __to_next); > } > > int > encoding() const throw() > { return this->do_encoding(); } > > bool > always_noconv() const throw() > { return this->do_always_noconv(); } > > int > length(state_type& __state, const extern_type* __from, > const extern_type* __end, size_t __max) const > { return this->do_length(__state, __from, __end, __max); } > > int > max_length() const throw() > { return this->do_max_length(); } > > protected: > explicit > __codecvt_abstract_base(size_t __refs = 0) : locale::facet(__refs) { } > > virtual > ~__codecvt_abstract_base() { } ># 236 "/usr/include/c++/4.9.0/bits/codecvt.h" 3 > virtual result > do_out(state_type& __state, const intern_type* __from, > const intern_type* __from_end, const intern_type*& __from_next, > extern_type* __to, extern_type* __to_end, > extern_type*& __to_next) const = 0; > > virtual result > do_unshift(state_type& __state, extern_type* __to, > extern_type* __to_end, extern_type*& __to_next) const = 0; > > virtual result > do_in(state_type& __state, const extern_type* __from, > const extern_type* __from_end, const extern_type*& __from_next, > intern_type* __to, intern_type* __to_end, > intern_type*& __to_next) const = 0; > > virtual int > do_encoding() const throw() = 0; > > virtual bool > do_always_noconv() const throw() = 0; > > virtual int > do_length(state_type&, const extern_type* __from, > const extern_type* __end, size_t __max) const = 0; > > virtual int > do_max_length() const throw() = 0; > }; ># 275 "/usr/include/c++/4.9.0/bits/codecvt.h" 3 > template<typename _InternT, typename _ExternT, typename _StateT> > class codecvt > : public __codecvt_abstract_base<_InternT, _ExternT, _StateT> > { > public: > > typedef codecvt_base::result result; > typedef _InternT intern_type; > typedef _ExternT extern_type; > typedef _StateT state_type; > > protected: > __c_locale _M_c_locale_codecvt; > > public: > static locale::id id; > > explicit > codecvt(size_t __refs = 0) > : __codecvt_abstract_base<_InternT, _ExternT, _StateT> (__refs), > _M_c_locale_codecvt(0) > { } > > explicit > codecvt(__c_locale __cloc, size_t __refs = 0); > > protected: > virtual > ~codecvt() { } > > virtual result > do_out(state_type& __state, const intern_type* __from, > const intern_type* __from_end, const intern_type*& __from_next, > extern_type* __to, extern_type* __to_end, > extern_type*& __to_next) const; > > virtual result > do_unshift(state_type& __state, extern_type* __to, > extern_type* __to_end, extern_type*& __to_next) const; > > virtual result > do_in(state_type& __state, const extern_type* __from, > const extern_type* __from_end, const extern_type*& __from_next, > intern_type* __to, intern_type* __to_end, > intern_type*& __to_next) const; > > virtual int > do_encoding() const throw(); > > virtual bool > do_always_noconv() const throw(); > > virtual int > do_length(state_type&, const extern_type* __from, > const extern_type* __end, size_t __max) const; > > virtual int > do_max_length() const throw(); > }; > > template<typename _InternT, typename _ExternT, typename _StateT> > locale::id codecvt<_InternT, _ExternT, _StateT>::id; > > > template<> > class codecvt<char, char, mbstate_t> > : public __codecvt_abstract_base<char, char, mbstate_t> > { > public: > > typedef char intern_type; > typedef char extern_type; > typedef mbstate_t state_type; > > protected: > __c_locale _M_c_locale_codecvt; > > public: > static locale::id id; > > explicit > codecvt(size_t __refs = 0); > > explicit > codecvt(__c_locale __cloc, size_t __refs = 0); > > protected: > virtual > ~codecvt(); > > virtual result > do_out(state_type& __state, const intern_type* __from, > const intern_type* __from_end, const intern_type*& __from_next, > extern_type* __to, extern_type* __to_end, > extern_type*& __to_next) const; > > virtual result > do_unshift(state_type& __state, extern_type* __to, > extern_type* __to_end, extern_type*& __to_next) const; > > virtual result > do_in(state_type& __state, const extern_type* __from, > const extern_type* __from_end, const extern_type*& __from_next, > intern_type* __to, intern_type* __to_end, > intern_type*& __to_next) const; > > virtual int > do_encoding() const throw(); > > virtual bool > do_always_noconv() const throw(); > > virtual int > do_length(state_type&, const extern_type* __from, > const extern_type* __end, size_t __max) const; > > virtual int > do_max_length() const throw(); > }; > > > > template<> > class codecvt<wchar_t, char, mbstate_t> > : public __codecvt_abstract_base<wchar_t, char, mbstate_t> > { > public: > > typedef wchar_t intern_type; > typedef char extern_type; > typedef mbstate_t state_type; > > protected: > __c_locale _M_c_locale_codecvt; > > public: > static locale::id id; > > explicit > codecvt(size_t __refs = 0); > > explicit > codecvt(__c_locale __cloc, size_t __refs = 0); > > protected: > virtual > ~codecvt(); > > virtual result > do_out(state_type& __state, const intern_type* __from, > const intern_type* __from_end, const intern_type*& __from_next, > extern_type* __to, extern_type* __to_end, > extern_type*& __to_next) const; > > virtual result > do_unshift(state_type& __state, > extern_type* __to, extern_type* __to_end, > extern_type*& __to_next) const; > > virtual result > do_in(state_type& __state, > const extern_type* __from, const extern_type* __from_end, > const extern_type*& __from_next, > intern_type* __to, intern_type* __to_end, > intern_type*& __to_next) const; > > virtual > int do_encoding() const throw(); > > virtual > bool do_always_noconv() const throw(); > > virtual > int do_length(state_type&, const extern_type* __from, > const extern_type* __end, size_t __max) const; > > virtual int > do_max_length() const throw(); > }; > > > > template<typename _InternT, typename _ExternT, typename _StateT> > class codecvt_byname : public codecvt<_InternT, _ExternT, _StateT> > { > public: > explicit > codecvt_byname(const char* __s, size_t __refs = 0) > : codecvt<_InternT, _ExternT, _StateT>(__refs) > { > if (__builtin_strcmp(__s, "C") != 0 > && __builtin_strcmp(__s, "POSIX") != 0) > { > this->_S_destroy_c_locale(this->_M_c_locale_codecvt); > this->_S_create_c_locale(this->_M_c_locale_codecvt, __s); > } > } > > protected: > virtual > ~codecvt_byname() { } > }; > > > > > extern template class codecvt_byname<char, char, mbstate_t>; > > extern template > const codecvt<char, char, mbstate_t>& > use_facet<codecvt<char, char, mbstate_t> >(const locale&); > > extern template > bool > has_facet<codecvt<char, char, mbstate_t> >(const locale&); > > > extern template class codecvt_byname<wchar_t, char, mbstate_t>; > > extern template > const codecvt<wchar_t, char, mbstate_t>& > use_facet<codecvt<wchar_t, char, mbstate_t> >(const locale&); > > extern template > bool > has_facet<codecvt<wchar_t, char, mbstate_t> >(const locale&); > > > > >} ># 1902 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 2 3 > ># 1 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.tcc" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.tcc" 3 ># 34 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.tcc" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT, bool _Intl> > struct __use_cache<__moneypunct_cache<_CharT, _Intl> > > { > const __moneypunct_cache<_CharT, _Intl>* > operator() (const locale& __loc) const > { > const size_t __i = moneypunct<_CharT, _Intl>::id._M_id(); > const locale::facet** __caches = __loc._M_impl->_M_caches; > if (!__caches[__i]) > { > __moneypunct_cache<_CharT, _Intl>* __tmp = 0; > try > { > __tmp = new __moneypunct_cache<_CharT, _Intl>; > __tmp->_M_cache(__loc); > } > catch(...) > { > delete __tmp; > throw; > } > __loc._M_impl->_M_install_cache(__tmp, __i); > } > return static_cast< > const __moneypunct_cache<_CharT, _Intl>*>(__caches[__i]); > } > }; > > template<typename _CharT, bool _Intl> > void > __moneypunct_cache<_CharT, _Intl>::_M_cache(const locale& __loc) > { > _M_allocated = true; > > const moneypunct<_CharT, _Intl>& __mp = > use_facet<moneypunct<_CharT, _Intl> >(__loc); > > _M_decimal_point = __mp.decimal_point(); > _M_thousands_sep = __mp.thousands_sep(); > _M_frac_digits = __mp.frac_digits(); > > char* __grouping = 0; > _CharT* __curr_symbol = 0; > _CharT* __positive_sign = 0; > _CharT* __negative_sign = 0; > try > { > _M_grouping_size = __mp.grouping().size(); > __grouping = new char[_M_grouping_size]; > __mp.grouping().copy(__grouping, _M_grouping_size); > _M_grouping = __grouping; > _M_use_grouping = (_M_grouping_size > && static_cast<signed char>(_M_grouping[0]) > 0 > && (_M_grouping[0] > != __gnu_cxx::__numeric_traits<char>::__max)); > > _M_curr_symbol_size = __mp.curr_symbol().size(); > __curr_symbol = new _CharT[_M_curr_symbol_size]; > __mp.curr_symbol().copy(__curr_symbol, _M_curr_symbol_size); > _M_curr_symbol = __curr_symbol; > > _M_positive_sign_size = __mp.positive_sign().size(); > __positive_sign = new _CharT[_M_positive_sign_size]; > __mp.positive_sign().copy(__positive_sign, _M_positive_sign_size); > _M_positive_sign = __positive_sign; > > _M_negative_sign_size = __mp.negative_sign().size(); > __negative_sign = new _CharT[_M_negative_sign_size]; > __mp.negative_sign().copy(__negative_sign, _M_negative_sign_size); > _M_negative_sign = __negative_sign; > > _M_pos_format = __mp.pos_format(); > _M_neg_format = __mp.neg_format(); > > const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__loc); > __ct.widen(money_base::_S_atoms, > money_base::_S_atoms + money_base::_S_end, _M_atoms); > } > catch(...) > { > delete [] __grouping; > delete [] __curr_symbol; > delete [] __positive_sign; > delete [] __negative_sign; > throw; > } > } > > > > template<typename _CharT, typename _InIter> > template<bool _Intl> > _InIter > money_get<_CharT, _InIter>:: > _M_extract(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, string& __units) const > { > typedef char_traits<_CharT> __traits_type; > typedef typename string_type::size_type size_type; > typedef money_base::part part; > typedef __moneypunct_cache<_CharT, _Intl> __cache_type; > > const locale& __loc = __io._M_getloc(); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > > __use_cache<__cache_type> __uc; > const __cache_type* __lc = __uc(__loc); > const char_type* __lit = __lc->_M_atoms; > > > bool __negative = false; > > size_type __sign_size = 0; > > const bool __mandatory_sign = (__lc->_M_positive_sign_size > && __lc->_M_negative_sign_size); > > string __grouping_tmp; > if (__lc->_M_use_grouping) > __grouping_tmp.reserve(32); > > int __last_pos = 0; > > int __n = 0; > > bool __testvalid = true; > > bool __testdecfound = false; > > > string __res; > __res.reserve(32); > > const char_type* __lit_zero = __lit + money_base::_S_zero; > const money_base::pattern __p = __lc->_M_neg_format; > for (int __i = 0; __i < 4 && __testvalid; ++__i) > { > const part __which = static_cast<part>(__p.field[__i]); > switch (__which) > { > case money_base::symbol: > > > > > if (__io.flags() & ios_base::showbase || __sign_size > 1 > || __i == 0 > || (__i == 1 && (__mandatory_sign > || (static_cast<part>(__p.field[0]) > == money_base::sign) > || (static_cast<part>(__p.field[2]) > == money_base::space))) > || (__i == 2 && ((static_cast<part>(__p.field[3]) > == money_base::value) > || (__mandatory_sign > && (static_cast<part>(__p.field[3]) > == money_base::sign))))) > { > const size_type __len = __lc->_M_curr_symbol_size; > size_type __j = 0; > for (; __beg != __end && __j < __len > && *__beg == __lc->_M_curr_symbol[__j]; > ++__beg, ++__j); > if (__j != __len > && (__j || __io.flags() & ios_base::showbase)) > __testvalid = false; > } > break; > case money_base::sign: > > if (__lc->_M_positive_sign_size && __beg != __end > && *__beg == __lc->_M_positive_sign[0]) > { > __sign_size = __lc->_M_positive_sign_size; > ++__beg; > } > else if (__lc->_M_negative_sign_size && __beg != __end > && *__beg == __lc->_M_negative_sign[0]) > { > __negative = true; > __sign_size = __lc->_M_negative_sign_size; > ++__beg; > } > else if (__lc->_M_positive_sign_size > && !__lc->_M_negative_sign_size) > > > __negative = true; > else if (__mandatory_sign) > __testvalid = false; > break; > case money_base::value: > > > for (; __beg != __end; ++__beg) > { > const char_type __c = *__beg; > const char_type* __q = __traits_type::find(__lit_zero, > 10, __c); > if (__q != 0) > { > __res += money_base::_S_atoms[__q - __lit]; > ++__n; > } > else if (__c == __lc->_M_decimal_point > && !__testdecfound) > { > if (__lc->_M_frac_digits <= 0) > break; > > __last_pos = __n; > __n = 0; > __testdecfound = true; > } > else if (__lc->_M_use_grouping > && __c == __lc->_M_thousands_sep > && !__testdecfound) > { > if (__n) > { > > __grouping_tmp += static_cast<char>(__n); > __n = 0; > } > else > { > __testvalid = false; > break; > } > } > else > break; > } > if (__res.empty()) > __testvalid = false; > break; > case money_base::space: > > if (__beg != __end && __ctype.is(ctype_base::space, *__beg)) > ++__beg; > else > __testvalid = false; > case money_base::none: > > if (__i != 3) > for (; __beg != __end > && __ctype.is(ctype_base::space, *__beg); ++__beg); > break; > } > } > > > if (__sign_size > 1 && __testvalid) > { > const char_type* __sign = __negative ? __lc->_M_negative_sign > : __lc->_M_positive_sign; > size_type __i = 1; > for (; __beg != __end && __i < __sign_size > && *__beg == __sign[__i]; ++__beg, ++__i); > > if (__i != __sign_size) > __testvalid = false; > } > > if (__testvalid) > { > > if (__res.size() > 1) > { > const size_type __first = __res.find_first_not_of('0'); > const bool __only_zeros = __first == string::npos; > if (__first) > __res.erase(0, __only_zeros ? __res.size() - 1 : __first); > } > > > if (__negative && __res[0] != '0') > __res.insert(__res.begin(), '-'); > > > if (__grouping_tmp.size()) > { > > __grouping_tmp += static_cast<char>(__testdecfound ? __last_pos > : __n); > if (!std::__verify_grouping(__lc->_M_grouping, > __lc->_M_grouping_size, > __grouping_tmp)) > __err |= ios_base::failbit; > } > > > if (__testdecfound && __n != __lc->_M_frac_digits) > __testvalid = false; > } > > > if (!__testvalid) > __err |= ios_base::failbit; > else > __units.swap(__res); > > > if (__beg == __end) > __err |= ios_base::eofbit; > return __beg; > } ># 362 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.tcc" 3 > template<typename _CharT, typename _InIter> > _InIter > money_get<_CharT, _InIter>:: > do_get(iter_type __beg, iter_type __end, bool __intl, ios_base& __io, > ios_base::iostate& __err, long double& __units) const > { > string __str; > __beg = __intl ? _M_extract<true>(__beg, __end, __io, __err, __str) > : _M_extract<false>(__beg, __end, __io, __err, __str); > std::__convert_to_v(__str.c_str(), __units, __err, _S_get_c_locale()); > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > money_get<_CharT, _InIter>:: > do_get(iter_type __beg, iter_type __end, bool __intl, ios_base& __io, > ios_base::iostate& __err, string_type& __digits) const > { > typedef typename string::size_type size_type; > > const locale& __loc = __io._M_getloc(); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > > string __str; > __beg = __intl ? _M_extract<true>(__beg, __end, __io, __err, __str) > : _M_extract<false>(__beg, __end, __io, __err, __str); > const size_type __len = __str.size(); > if (__len) > { > __digits.resize(__len); > __ctype.widen(__str.data(), __str.data() + __len, &__digits[0]); > } > return __beg; > } > > template<typename _CharT, typename _OutIter> > template<bool _Intl> > _OutIter > money_put<_CharT, _OutIter>:: > _M_insert(iter_type __s, ios_base& __io, char_type __fill, > const string_type& __digits) const > { > typedef typename string_type::size_type size_type; > typedef money_base::part part; > typedef __moneypunct_cache<_CharT, _Intl> __cache_type; > > const locale& __loc = __io._M_getloc(); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > > __use_cache<__cache_type> __uc; > const __cache_type* __lc = __uc(__loc); > const char_type* __lit = __lc->_M_atoms; > > > > const char_type* __beg = __digits.data(); > > money_base::pattern __p; > const char_type* __sign; > size_type __sign_size; > if (!(*__beg == __lit[money_base::_S_minus])) > { > __p = __lc->_M_pos_format; > __sign = __lc->_M_positive_sign; > __sign_size = __lc->_M_positive_sign_size; > } > else > { > __p = __lc->_M_neg_format; > __sign = __lc->_M_negative_sign; > __sign_size = __lc->_M_negative_sign_size; > if (__digits.size()) > ++__beg; > } > > > size_type __len = __ctype.scan_not(ctype_base::digit, __beg, > __beg + __digits.size()) - __beg; > if (__len) > { > > > > string_type __value; > __value.reserve(2 * __len); > > > > long __paddec = __len - __lc->_M_frac_digits; > if (__paddec > 0) > { > if (__lc->_M_frac_digits < 0) > __paddec = __len; > if (__lc->_M_grouping_size) > { > __value.assign(2 * __paddec, char_type()); > _CharT* __vend = > std::__add_grouping(&__value[0], __lc->_M_thousands_sep, > __lc->_M_grouping, > __lc->_M_grouping_size, > __beg, __beg + __paddec); > __value.erase(__vend - &__value[0]); > } > else > __value.assign(__beg, __paddec); > } > > > if (__lc->_M_frac_digits > 0) > { > __value += __lc->_M_decimal_point; > if (__paddec >= 0) > __value.append(__beg + __paddec, __lc->_M_frac_digits); > else > { > > __value.append(-__paddec, __lit[money_base::_S_zero]); > __value.append(__beg, __len); > } > } > > > const ios_base::fmtflags __f = __io.flags() > & ios_base::adjustfield; > __len = __value.size() + __sign_size; > __len += ((__io.flags() & ios_base::showbase) > ? __lc->_M_curr_symbol_size : 0); > > string_type __res; > __res.reserve(2 * __len); > > const size_type __width = static_cast<size_type>(__io.width()); > const bool __testipad = (__f == ios_base::internal > && __len < __width); > > for (int __i = 0; __i < 4; ++__i) > { > const part __which = static_cast<part>(__p.field[__i]); > switch (__which) > { > case money_base::symbol: > if (__io.flags() & ios_base::showbase) > __res.append(__lc->_M_curr_symbol, > __lc->_M_curr_symbol_size); > break; > case money_base::sign: > > > > if (__sign_size) > __res += __sign[0]; > break; > case money_base::value: > __res += __value; > break; > case money_base::space: > > > > if (__testipad) > __res.append(__width - __len, __fill); > else > __res += __fill; > break; > case money_base::none: > if (__testipad) > __res.append(__width - __len, __fill); > break; > } > } > > > if (__sign_size > 1) > __res.append(__sign + 1, __sign_size - 1); > > > __len = __res.size(); > if (__width > __len) > { > if (__f == ios_base::left) > > __res.append(__width - __len, __fill); > else > > __res.insert(0, __width - __len, __fill); > __len = __width; > } > > > __s = std::__write(__s, __res.data(), __len); > } > __io.width(0); > return __s; > } ># 567 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.tcc" 3 > template<typename _CharT, typename _OutIter> > _OutIter > money_put<_CharT, _OutIter>:: > do_put(iter_type __s, bool __intl, ios_base& __io, char_type __fill, > long double __units) const > { > const locale __loc = __io.getloc(); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > > > int __cs_size = 64; > char* __cs = static_cast<char*>(__builtin_alloca(__cs_size)); > > > int __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size, > "%.*Lf", 0, __units); > > if (__len >= __cs_size) > { > __cs_size = __len + 1; > __cs = static_cast<char*>(__builtin_alloca(__cs_size)); > __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size, > "%.*Lf", 0, __units); > } ># 599 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.tcc" 3 > string_type __digits(__len, char_type()); > __ctype.widen(__cs, __cs + __len, &__digits[0]); > return __intl ? _M_insert<true>(__s, __io, __fill, __digits) > : _M_insert<false>(__s, __io, __fill, __digits); > } > > template<typename _CharT, typename _OutIter> > _OutIter > money_put<_CharT, _OutIter>:: > do_put(iter_type __s, bool __intl, ios_base& __io, char_type __fill, > const string_type& __digits) const > { return __intl ? _M_insert<true>(__s, __io, __fill, __digits) > : _M_insert<false>(__s, __io, __fill, __digits); } > > > > > > > template<typename _CharT, typename _InIter> > time_base::dateorder > time_get<_CharT, _InIter>::do_date_order() const > { return time_base::no_order; } > > > > template<typename _CharT, typename _InIter> > _InIter > time_get<_CharT, _InIter>:: > _M_extract_via_format(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm, > const _CharT* __format) const > { > const locale& __loc = __io._M_getloc(); > const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > const size_t __len = char_traits<_CharT>::length(__format); > > ios_base::iostate __tmperr = ios_base::goodbit; > size_t __i = 0; > for (; __beg != __end && __i < __len && !__tmperr; ++__i) > { > if (__ctype.narrow(__format[__i], 0) == '%') > { > > char __c = __ctype.narrow(__format[++__i], 0); > int __mem = 0; > if (__c == 'E' || __c == 'O') > __c = __ctype.narrow(__format[++__i], 0); > switch (__c) > { > const char* __cs; > _CharT __wcs[10]; > case 'a': > > const char_type* __days1[7]; > __tp._M_days_abbreviated(__days1); > __beg = _M_extract_name(__beg, __end, __tm->tm_wday, __days1, > 7, __io, __tmperr); > break; > case 'A': > > const char_type* __days2[7]; > __tp._M_days(__days2); > __beg = _M_extract_name(__beg, __end, __tm->tm_wday, __days2, > 7, __io, __tmperr); > break; > case 'h': > case 'b': > > const char_type* __months1[12]; > __tp._M_months_abbreviated(__months1); > __beg = _M_extract_name(__beg, __end, __tm->tm_mon, > __months1, 12, __io, __tmperr); > break; > case 'B': > > const char_type* __months2[12]; > __tp._M_months(__months2); > __beg = _M_extract_name(__beg, __end, __tm->tm_mon, > __months2, 12, __io, __tmperr); > break; > case 'c': > > const char_type* __dt[2]; > __tp._M_date_time_formats(__dt); > __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, > __tm, __dt[0]); > break; > case 'd': > > __beg = _M_extract_num(__beg, __end, __tm->tm_mday, 1, 31, 2, > __io, __tmperr); > break; > case 'e': > > > if (__ctype.is(ctype_base::space, *__beg)) > __beg = _M_extract_num(++__beg, __end, __tm->tm_mday, 1, 9, > 1, __io, __tmperr); > else > __beg = _M_extract_num(__beg, __end, __tm->tm_mday, 10, 31, > 2, __io, __tmperr); > break; > case 'D': > > __cs = "%m/%d/%y"; > __ctype.widen(__cs, __cs + 9, __wcs); > __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, > __tm, __wcs); > break; > case 'H': > > __beg = _M_extract_num(__beg, __end, __tm->tm_hour, 0, 23, 2, > __io, __tmperr); > break; > case 'I': > > __beg = _M_extract_num(__beg, __end, __tm->tm_hour, 1, 12, 2, > __io, __tmperr); > break; > case 'm': > > __beg = _M_extract_num(__beg, __end, __mem, 1, 12, 2, > __io, __tmperr); > if (!__tmperr) > __tm->tm_mon = __mem - 1; > break; > case 'M': > > __beg = _M_extract_num(__beg, __end, __tm->tm_min, 0, 59, 2, > __io, __tmperr); > break; > case 'n': > if (__ctype.narrow(*__beg, 0) == '\n') > ++__beg; > else > __tmperr |= ios_base::failbit; > break; > case 'R': > > __cs = "%H:%M"; > __ctype.widen(__cs, __cs + 6, __wcs); > __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, > __tm, __wcs); > break; > case 'S': > > > > __beg = _M_extract_num(__beg, __end, __tm->tm_sec, 0, 60, 2, > > > > __io, __tmperr); > break; > case 't': > if (__ctype.narrow(*__beg, 0) == '\t') > ++__beg; > else > __tmperr |= ios_base::failbit; > break; > case 'T': > > __cs = "%H:%M:%S"; > __ctype.widen(__cs, __cs + 9, __wcs); > __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, > __tm, __wcs); > break; > case 'x': > > const char_type* __dates[2]; > __tp._M_date_formats(__dates); > __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, > __tm, __dates[0]); > break; > case 'X': > > const char_type* __times[2]; > __tp._M_time_formats(__times); > __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, > __tm, __times[0]); > break; > case 'y': > case 'C': > > case 'Y': > > > > > __beg = _M_extract_num(__beg, __end, __mem, 0, 9999, 4, > __io, __tmperr); > if (!__tmperr) > __tm->tm_year = __mem < 0 ? __mem + 100 : __mem - 1900; > break; > case 'Z': > > if (__ctype.is(ctype_base::upper, *__beg)) > { > int __tmp; > __beg = _M_extract_name(__beg, __end, __tmp, > __timepunct_cache<_CharT>::_S_timezones, > 14, __io, __tmperr); > > > if (__beg != __end && !__tmperr && __tmp == 0 > && (*__beg == __ctype.widen('-') > || *__beg == __ctype.widen('+'))) > { > __beg = _M_extract_num(__beg, __end, __tmp, 0, 23, 2, > __io, __tmperr); > __beg = _M_extract_num(__beg, __end, __tmp, 0, 59, 2, > __io, __tmperr); > } > } > else > __tmperr |= ios_base::failbit; > break; > default: > > __tmperr |= ios_base::failbit; > } > } > else > { > > if (__format[__i] == *__beg) > ++__beg; > else > __tmperr |= ios_base::failbit; > } > } > > if (__tmperr || __i != __len) > __err |= ios_base::failbit; > > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > time_get<_CharT, _InIter>:: > _M_extract_num(iter_type __beg, iter_type __end, int& __member, > int __min, int __max, size_t __len, > ios_base& __io, ios_base::iostate& __err) const > { > const locale& __loc = __io._M_getloc(); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > > > int __mult = __len == 2 ? 10 : (__len == 4 ? 1000 : 1); > > ++__min; > size_t __i = 0; > int __value = 0; > for (; __beg != __end && __i < __len; ++__beg, ++__i) > { > const char __c = __ctype.narrow(*__beg, '*'); > if (__c >= '0' && __c <= '9') > { > __value = __value * 10 + (__c - '0'); > const int __valuec = __value * __mult; > if (__valuec > __max || __valuec + __mult < __min) > break; > __mult /= 10; > } > else > break; > } > if (__i == __len) > __member = __value; > > else if (__len == 4 && __i == 2) > __member = __value - 100; > else > __err |= ios_base::failbit; > > return __beg; > } > > > > template<typename _CharT, typename _InIter> > _InIter > time_get<_CharT, _InIter>:: > _M_extract_name(iter_type __beg, iter_type __end, int& __member, > const _CharT** __names, size_t __indexlen, > ios_base& __io, ios_base::iostate& __err) const > { > typedef char_traits<_CharT> __traits_type; > const locale& __loc = __io._M_getloc(); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > > int* __matches = static_cast<int*>(__builtin_alloca(sizeof(int) > * __indexlen)); > size_t __nmatches = 0; > size_t __pos = 0; > bool __testvalid = true; > const char_type* __name; > > > > > > if (__beg != __end) > { > const char_type __c = *__beg; > for (size_t __i1 = 0; __i1 < __indexlen; ++__i1) > if (__c == __names[__i1][0] > || __c == __ctype.toupper(__names[__i1][0])) > __matches[__nmatches++] = __i1; > } > > while (__nmatches > 1) > { > > size_t __minlen = __traits_type::length(__names[__matches[0]]); > for (size_t __i2 = 1; __i2 < __nmatches; ++__i2) > __minlen = std::min(__minlen, > __traits_type::length(__names[__matches[__i2]])); > ++__beg, ++__pos; > if (__pos < __minlen && __beg != __end) > for (size_t __i3 = 0; __i3 < __nmatches;) > { > __name = __names[__matches[__i3]]; > if (!(__name[__pos] == *__beg)) > __matches[__i3] = __matches[--__nmatches]; > else > ++__i3; > } > else > break; > } > > if (__nmatches == 1) > { > > ++__beg, ++__pos; > __name = __names[__matches[0]]; > const size_t __len = __traits_type::length(__name); > while (__pos < __len && __beg != __end && __name[__pos] == *__beg) > ++__beg, ++__pos; > > if (__len == __pos) > __member = __matches[0]; > else > __testvalid = false; > } > else > __testvalid = false; > if (!__testvalid) > __err |= ios_base::failbit; > > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > time_get<_CharT, _InIter>:: > _M_extract_wday_or_month(iter_type __beg, iter_type __end, int& __member, > const _CharT** __names, size_t __indexlen, > ios_base& __io, ios_base::iostate& __err) const > { > typedef char_traits<_CharT> __traits_type; > const locale& __loc = __io._M_getloc(); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > > int* __matches = static_cast<int*>(__builtin_alloca(2 * sizeof(int) > * __indexlen)); > size_t __nmatches = 0; > size_t* __matches_lengths = 0; > size_t __pos = 0; > > if (__beg != __end) > { > const char_type __c = *__beg; > for (size_t __i = 0; __i < 2 * __indexlen; ++__i) > if (__c == __names[__i][0] > || __c == __ctype.toupper(__names[__i][0])) > __matches[__nmatches++] = __i; > } > > if (__nmatches) > { > ++__beg, ++__pos; > > __matches_lengths > = static_cast<size_t*>(__builtin_alloca(sizeof(size_t) > * __nmatches)); > for (size_t __i = 0; __i < __nmatches; ++__i) > __matches_lengths[__i] > = __traits_type::length(__names[__matches[__i]]); > } > > for (; __beg != __end; ++__beg, ++__pos) > { > size_t __nskipped = 0; > const char_type __c = *__beg; > for (size_t __i = 0; __i < __nmatches;) > { > const char_type* __name = __names[__matches[__i]]; > if (__pos >= __matches_lengths[__i]) > ++__nskipped, ++__i; > else if (!(__name[__pos] == __c)) > { > --__nmatches; > __matches[__i] = __matches[__nmatches]; > __matches_lengths[__i] = __matches_lengths[__nmatches]; > } > else > ++__i; > } > if (__nskipped == __nmatches) > break; > } > > if ((__nmatches == 1 && __matches_lengths[0] == __pos) > || (__nmatches == 2 && (__matches_lengths[0] == __pos > || __matches_lengths[1] == __pos))) > __member = (__matches[0] >= __indexlen > ? __matches[0] - __indexlen : __matches[0]); > else > __err |= ios_base::failbit; > > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > time_get<_CharT, _InIter>:: > do_get_time(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const > { > const locale& __loc = __io._M_getloc(); > const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); > const char_type* __times[2]; > __tp._M_time_formats(__times); > __beg = _M_extract_via_format(__beg, __end, __io, __err, > __tm, __times[0]); > if (__beg == __end) > __err |= ios_base::eofbit; > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > time_get<_CharT, _InIter>:: > do_get_date(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const > { > const locale& __loc = __io._M_getloc(); > const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); > const char_type* __dates[2]; > __tp._M_date_formats(__dates); > __beg = _M_extract_via_format(__beg, __end, __io, __err, > __tm, __dates[0]); > if (__beg == __end) > __err |= ios_base::eofbit; > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > time_get<_CharT, _InIter>:: > do_get_weekday(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const > { > typedef char_traits<_CharT> __traits_type; > const locale& __loc = __io._M_getloc(); > const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > const char_type* __days[14]; > __tp._M_days_abbreviated(__days); > __tp._M_days(__days + 7); > int __tmpwday; > ios_base::iostate __tmperr = ios_base::goodbit; > > __beg = _M_extract_wday_or_month(__beg, __end, __tmpwday, __days, 7, > __io, __tmperr); > if (!__tmperr) > __tm->tm_wday = __tmpwday; > else > __err |= ios_base::failbit; > > if (__beg == __end) > __err |= ios_base::eofbit; > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > time_get<_CharT, _InIter>:: > do_get_monthname(iter_type __beg, iter_type __end, > ios_base& __io, ios_base::iostate& __err, tm* __tm) const > { > typedef char_traits<_CharT> __traits_type; > const locale& __loc = __io._M_getloc(); > const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > const char_type* __months[24]; > __tp._M_months_abbreviated(__months); > __tp._M_months(__months + 12); > int __tmpmon; > ios_base::iostate __tmperr = ios_base::goodbit; > > __beg = _M_extract_wday_or_month(__beg, __end, __tmpmon, __months, 12, > __io, __tmperr); > if (!__tmperr) > __tm->tm_mon = __tmpmon; > else > __err |= ios_base::failbit; > > if (__beg == __end) > __err |= ios_base::eofbit; > return __beg; > } > > template<typename _CharT, typename _InIter> > _InIter > time_get<_CharT, _InIter>:: > do_get_year(iter_type __beg, iter_type __end, ios_base& __io, > ios_base::iostate& __err, tm* __tm) const > { > const locale& __loc = __io._M_getloc(); > const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); > int __tmpyear; > ios_base::iostate __tmperr = ios_base::goodbit; > > __beg = _M_extract_num(__beg, __end, __tmpyear, 0, 9999, 4, > __io, __tmperr); > if (!__tmperr) > __tm->tm_year = __tmpyear < 0 ? __tmpyear + 100 : __tmpyear - 1900; > else > __err |= ios_base::failbit; > > if (__beg == __end) > __err |= ios_base::eofbit; > return __beg; > } > > template<typename _CharT, typename _OutIter> > _OutIter > time_put<_CharT, _OutIter>:: > put(iter_type __s, ios_base& __io, char_type __fill, const tm* __tm, > const _CharT* __beg, const _CharT* __end) const > { > const locale& __loc = __io._M_getloc(); > ctype<_CharT> const& __ctype = use_facet<ctype<_CharT> >(__loc); > for (; __beg != __end; ++__beg) > if (__ctype.narrow(*__beg, 0) != '%') > { > *__s = *__beg; > ++__s; > } > else if (++__beg != __end) > { > char __format; > char __mod = 0; > const char __c = __ctype.narrow(*__beg, 0); > if (__c != 'E' && __c != 'O') > __format = __c; > else if (++__beg != __end) > { > __mod = __c; > __format = __ctype.narrow(*__beg, 0); > } > else > break; > __s = this->do_put(__s, __io, __fill, __tm, __format, __mod); > } > else > break; > return __s; > } > > template<typename _CharT, typename _OutIter> > _OutIter > time_put<_CharT, _OutIter>:: > do_put(iter_type __s, ios_base& __io, char_type, const tm* __tm, > char __format, char __mod) const > { > const locale& __loc = __io._M_getloc(); > ctype<_CharT> const& __ctype = use_facet<ctype<_CharT> >(__loc); > __timepunct<_CharT> const& __tp = use_facet<__timepunct<_CharT> >(__loc); > > > > const size_t __maxlen = 128; > char_type __res[__maxlen]; > > > > > > > char_type __fmt[4]; > __fmt[0] = __ctype.widen('%'); > if (!__mod) > { > __fmt[1] = __format; > __fmt[2] = char_type(); > } > else > { > __fmt[1] = __mod; > __fmt[2] = __format; > __fmt[3] = char_type(); > } > > __tp._M_put(__res, __maxlen, __fmt, __tm); > > > return std::__write(__s, __res, char_traits<char_type>::length(__res)); > } > > > > > > extern template class moneypunct<char, false>; > extern template class moneypunct<char, true>; > extern template class moneypunct_byname<char, false>; > extern template class moneypunct_byname<char, true>; > extern template class money_get<char>; > extern template class money_put<char>; > extern template class __timepunct<char>; > extern template class time_put<char>; > extern template class time_put_byname<char>; > extern template class time_get<char>; > extern template class time_get_byname<char>; > extern template class messages<char>; > extern template class messages_byname<char>; > > extern template > const moneypunct<char, true>& > use_facet<moneypunct<char, true> >(const locale&); > > extern template > const moneypunct<char, false>& > use_facet<moneypunct<char, false> >(const locale&); > > extern template > const money_put<char>& > use_facet<money_put<char> >(const locale&); > > extern template > const money_get<char>& > use_facet<money_get<char> >(const locale&); > > extern template > const __timepunct<char>& > use_facet<__timepunct<char> >(const locale&); > > extern template > const time_put<char>& > use_facet<time_put<char> >(const locale&); > > extern template > const time_get<char>& > use_facet<time_get<char> >(const locale&); > > extern template > const messages<char>& > use_facet<messages<char> >(const locale&); > > extern template > bool > has_facet<moneypunct<char> >(const locale&); > > extern template > bool > has_facet<money_put<char> >(const locale&); > > extern template > bool > has_facet<money_get<char> >(const locale&); > > extern template > bool > has_facet<__timepunct<char> >(const locale&); > > extern template > bool > has_facet<time_put<char> >(const locale&); > > extern template > bool > has_facet<time_get<char> >(const locale&); > > extern template > bool > has_facet<messages<char> >(const locale&); > > > extern template class moneypunct<wchar_t, false>; > extern template class moneypunct<wchar_t, true>; > extern template class moneypunct_byname<wchar_t, false>; > extern template class moneypunct_byname<wchar_t, true>; > extern template class money_get<wchar_t>; > extern template class money_put<wchar_t>; > extern template class __timepunct<wchar_t>; > extern template class time_put<wchar_t>; > extern template class time_put_byname<wchar_t>; > extern template class time_get<wchar_t>; > extern template class time_get_byname<wchar_t>; > extern template class messages<wchar_t>; > extern template class messages_byname<wchar_t>; > > extern template > const moneypunct<wchar_t, true>& > use_facet<moneypunct<wchar_t, true> >(const locale&); > > extern template > const moneypunct<wchar_t, false>& > use_facet<moneypunct<wchar_t, false> >(const locale&); > > extern template > const money_put<wchar_t>& > use_facet<money_put<wchar_t> >(const locale&); > > extern template > const money_get<wchar_t>& > use_facet<money_get<wchar_t> >(const locale&); > > extern template > const __timepunct<wchar_t>& > use_facet<__timepunct<wchar_t> >(const locale&); > > extern template > const time_put<wchar_t>& > use_facet<time_put<wchar_t> >(const locale&); > > extern template > const time_get<wchar_t>& > use_facet<time_get<wchar_t> >(const locale&); > > extern template > const messages<wchar_t>& > use_facet<messages<wchar_t> >(const locale&); > > extern template > bool > has_facet<moneypunct<wchar_t> >(const locale&); > > extern template > bool > has_facet<money_put<wchar_t> >(const locale&); > > extern template > bool > has_facet<money_get<wchar_t> >(const locale&); > > extern template > bool > has_facet<__timepunct<wchar_t> >(const locale&); > > extern template > bool > has_facet<time_put<wchar_t> >(const locale&); > > extern template > bool > has_facet<time_get<wchar_t> >(const locale&); > > extern template > bool > has_facet<messages<wchar_t> >(const locale&); > > > > >} ># 1904 "/usr/include/c++/4.9.0/bits/locale_facets_nonio.h" 2 3 ># 42 "/usr/include/c++/4.9.0/locale" 2 3 ># 44 "/usr/include/c++/4.9.0/iomanip" 2 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > struct _Resetiosflags { ios_base::fmtflags _M_mask; }; ># 62 "/usr/include/c++/4.9.0/iomanip" 3 > inline _Resetiosflags > resetiosflags(ios_base::fmtflags __mask) > { return { __mask }; } > > template<typename _CharT, typename _Traits> > inline basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __is, _Resetiosflags __f) > { > __is.setf(ios_base::fmtflags(0), __f._M_mask); > return __is; > } > > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, _Resetiosflags __f) > { > __os.setf(ios_base::fmtflags(0), __f._M_mask); > return __os; > } > > > struct _Setiosflags { ios_base::fmtflags _M_mask; }; ># 92 "/usr/include/c++/4.9.0/iomanip" 3 > inline _Setiosflags > setiosflags(ios_base::fmtflags __mask) > { return { __mask }; } > > template<typename _CharT, typename _Traits> > inline basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __is, _Setiosflags __f) > { > __is.setf(__f._M_mask); > return __is; > } > > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, _Setiosflags __f) > { > __os.setf(__f._M_mask); > return __os; > } > > > struct _Setbase { int _M_base; }; ># 123 "/usr/include/c++/4.9.0/iomanip" 3 > inline _Setbase > setbase(int __base) > { return { __base }; } > > template<typename _CharT, typename _Traits> > inline basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __is, _Setbase __f) > { > __is.setf(__f._M_base == 8 ? ios_base::oct : > __f._M_base == 10 ? ios_base::dec : > __f._M_base == 16 ? ios_base::hex : > ios_base::fmtflags(0), ios_base::basefield); > return __is; > } > > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, _Setbase __f) > { > __os.setf(__f._M_base == 8 ? ios_base::oct : > __f._M_base == 10 ? ios_base::dec : > __f._M_base == 16 ? ios_base::hex : > ios_base::fmtflags(0), ios_base::basefield); > return __os; > } > > > template<typename _CharT> > struct _Setfill { _CharT _M_c; }; ># 160 "/usr/include/c++/4.9.0/iomanip" 3 > template<typename _CharT> > inline _Setfill<_CharT> > setfill(_CharT __c) > { return { __c }; } > > template<typename _CharT, typename _Traits> > inline basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __is, _Setfill<_CharT> __f) > { > __is.fill(__f._M_c); > return __is; > } > > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, _Setfill<_CharT> __f) > { > __os.fill(__f._M_c); > return __os; > } > > > struct _Setprecision { int _M_n; }; ># 191 "/usr/include/c++/4.9.0/iomanip" 3 > inline _Setprecision > setprecision(int __n) > { return { __n }; } > > template<typename _CharT, typename _Traits> > inline basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __is, _Setprecision __f) > { > __is.precision(__f._M_n); > return __is; > } > > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, _Setprecision __f) > { > __os.precision(__f._M_n); > return __os; > } > > > struct _Setw { int _M_n; }; ># 221 "/usr/include/c++/4.9.0/iomanip" 3 > inline _Setw > setw(int __n) > { return { __n }; } > > template<typename _CharT, typename _Traits> > inline basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __is, _Setw __f) > { > __is.width(__f._M_n); > return __is; > } > > template<typename _CharT, typename _Traits> > inline basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, _Setw __f) > { > __os.width(__f._M_n); > return __os; > } > > > > template<typename _MoneyT> > struct _Get_money { _MoneyT& _M_mon; bool _M_intl; }; ># 254 "/usr/include/c++/4.9.0/iomanip" 3 > template<typename _MoneyT> > inline _Get_money<_MoneyT> > get_money(_MoneyT& __mon, bool __intl = false) > { return { __mon, __intl }; } > > template<typename _CharT, typename _Traits, typename _MoneyT> > basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __is, _Get_money<_MoneyT> __f) > { > typename basic_istream<_CharT, _Traits>::sentry __cerb(__is, false); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > typedef istreambuf_iterator<_CharT, _Traits> _Iter; > typedef money_get<_CharT, _Iter> _MoneyGet; > > const _MoneyGet& __mg = use_facet<_MoneyGet>(__is.getloc()); > __mg.get(_Iter(__is.rdbuf()), _Iter(), __f._M_intl, > __is, __err, __f._M_mon); > } > catch(__cxxabiv1::__forced_unwind&) > { > __is._M_setstate(ios_base::badbit); > throw; > } > catch(...) > { __is._M_setstate(ios_base::badbit); } > if (__err) > __is.setstate(__err); > } > return __is; > } > > > template<typename _MoneyT> > struct _Put_money { const _MoneyT& _M_mon; bool _M_intl; }; ># 301 "/usr/include/c++/4.9.0/iomanip" 3 > template<typename _MoneyT> > inline _Put_money<_MoneyT> > put_money(const _MoneyT& __mon, bool __intl = false) > { return { __mon, __intl }; } > > template<typename _CharT, typename _Traits, typename _MoneyT> > basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, _Put_money<_MoneyT> __f) > { > typename basic_ostream<_CharT, _Traits>::sentry __cerb(__os); > if (__cerb) > { > ios_base::iostate __err = ios_base::goodbit; > try > { > typedef ostreambuf_iterator<_CharT, _Traits> _Iter; > typedef money_put<_CharT, _Iter> _MoneyPut; > > const _MoneyPut& __mp = use_facet<_MoneyPut>(__os.getloc()); > if (__mp.put(_Iter(__os.rdbuf()), __f._M_intl, __os, > __os.fill(), __f._M_mon).failed()) > __err |= ios_base::badbit; > } > catch(__cxxabiv1::__forced_unwind&) > { > __os._M_setstate(ios_base::badbit); > throw; > } > catch(...) > { __os._M_setstate(ios_base::badbit); } > if (__err) > __os.setstate(__err); > } > return __os; > } ># 498 "/usr/include/c++/4.9.0/iomanip" 3 > extern template ostream& operator<<(ostream&, _Setfill<char>); > extern template ostream& operator<<(ostream&, _Setiosflags); > extern template ostream& operator<<(ostream&, _Resetiosflags); > extern template ostream& operator<<(ostream&, _Setbase); > extern template ostream& operator<<(ostream&, _Setprecision); > extern template ostream& operator<<(ostream&, _Setw); > extern template istream& operator>>(istream&, _Setfill<char>); > extern template istream& operator>>(istream&, _Setiosflags); > extern template istream& operator>>(istream&, _Resetiosflags); > extern template istream& operator>>(istream&, _Setbase); > extern template istream& operator>>(istream&, _Setprecision); > extern template istream& operator>>(istream&, _Setw); > > > extern template wostream& operator<<(wostream&, _Setfill<wchar_t>); > extern template wostream& operator<<(wostream&, _Setiosflags); > extern template wostream& operator<<(wostream&, _Resetiosflags); > extern template wostream& operator<<(wostream&, _Setbase); > extern template wostream& operator<<(wostream&, _Setprecision); > extern template wostream& operator<<(wostream&, _Setw); > extern template wistream& operator>>(wistream&, _Setfill<wchar_t>); > extern template wistream& operator>>(wistream&, _Setiosflags); > extern template wistream& operator>>(wistream&, _Resetiosflags); > extern template wistream& operator>>(wistream&, _Setbase); > extern template wistream& operator>>(wistream&, _Setprecision); > extern template wistream& operator>>(wistream&, _Setw); > > > > >} ># 37 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/usr/include/c++/4.9.0/fstream" 1 3 ># 36 "/usr/include/c++/4.9.0/fstream" 3 ># 37 "/usr/include/c++/4.9.0/fstream" 3 > > > > ># 1 "/usr/include/c++/4.9.0/cstdio" 1 3 ># 39 "/usr/include/c++/4.9.0/cstdio" 3 ># 40 "/usr/include/c++/4.9.0/cstdio" 3 ># 42 "/usr/include/c++/4.9.0/fstream" 2 3 ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/basic_file.h" 1 3 ># 37 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/basic_file.h" 3 ># 38 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/basic_file.h" 3 > > ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++io.h" 1 3 ># 35 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++io.h" 3 ># 1 "/usr/include/c++/4.9.0/cstdio" 1 3 ># 39 "/usr/include/c++/4.9.0/cstdio" 3 ># 40 "/usr/include/c++/4.9.0/cstdio" 3 ># 36 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/c++io.h" 2 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > typedef __gthread_mutex_t __c_lock; > > > typedef FILE __c_file; > > >} ># 41 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/basic_file.h" 2 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template<typename _CharT> > class __basic_file; > > > template<> > class __basic_file<char> > { > > __c_file* _M_cfile; > > > bool _M_cfile_created; > > public: > __basic_file(__c_lock* __lock = 0) throw (); > > __basic_file* > open(const char* __name, ios_base::openmode __mode, int __prot = 0664); > > __basic_file* > sys_open(__c_file* __file, ios_base::openmode); > > __basic_file* > sys_open(int __fd, ios_base::openmode __mode) throw (); > > __basic_file* > close(); > > __attribute__ ((__pure__)) bool > is_open() const throw (); > > __attribute__ ((__pure__)) int > fd() throw (); > > __attribute__ ((__pure__)) __c_file* > file() throw (); > > ~__basic_file(); > > streamsize > xsputn(const char* __s, streamsize __n); > > streamsize > xsputn_2(const char* __s1, streamsize __n1, > const char* __s2, streamsize __n2); > > streamsize > xsgetn(char* __s, streamsize __n); > > streamoff > seekoff(streamoff __off, ios_base::seekdir __way) throw (); > > int > sync(); > > streamsize > showmanyc(); > }; > > >} ># 43 "/usr/include/c++/4.9.0/fstream" 2 3 > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 71 "/usr/include/c++/4.9.0/fstream" 3 > template<typename _CharT, typename _Traits> > class basic_filebuf : public basic_streambuf<_CharT, _Traits> > { > public: > > typedef _CharT char_type; > typedef _Traits traits_type; > typedef typename traits_type::int_type int_type; > typedef typename traits_type::pos_type pos_type; > typedef typename traits_type::off_type off_type; > > typedef basic_streambuf<char_type, traits_type> __streambuf_type; > typedef basic_filebuf<char_type, traits_type> __filebuf_type; > typedef __basic_file<char> __file_type; > typedef typename traits_type::state_type __state_type; > typedef codecvt<char_type, char, __state_type> __codecvt_type; > > friend class ios_base; > > protected: > > > __c_lock _M_lock; > > > __file_type _M_file; > > > ios_base::openmode _M_mode; > > > __state_type _M_state_beg; > > > > > __state_type _M_state_cur; > > > > __state_type _M_state_last; > > > char_type* _M_buf; > > > > > > > size_t _M_buf_size; > > > bool _M_buf_allocated; ># 133 "/usr/include/c++/4.9.0/fstream" 3 > bool _M_reading; > bool _M_writing; > > > > > > > > char_type _M_pback; > char_type* _M_pback_cur_save; > char_type* _M_pback_end_save; > bool _M_pback_init; > > > > const __codecvt_type* _M_codecvt; > > > > > > > char* _M_ext_buf; > > > > > streamsize _M_ext_buf_size; > > > > > > > const char* _M_ext_next; > char* _M_ext_end; > > > > > > > void > _M_create_pback() > { > if (!_M_pback_init) > { > _M_pback_cur_save = this->gptr(); > _M_pback_end_save = this->egptr(); > this->setg(&_M_pback, &_M_pback, &_M_pback + 1); > _M_pback_init = true; > } > } > > > > > > > void > _M_destroy_pback() throw() > { > if (_M_pback_init) > { > > _M_pback_cur_save += this->gptr() != this->eback(); > this->setg(_M_buf, _M_pback_cur_save, _M_pback_end_save); > _M_pback_init = false; > } > } > > public: > > > > > > > > basic_filebuf(); > > > > > virtual > ~basic_filebuf() > { this->close(); } > > > > > > bool > is_open() const throw() > { return _M_file.is_open(); } ># 271 "/usr/include/c++/4.9.0/fstream" 3 > __filebuf_type* > open(const char* __s, ios_base::openmode __mode); ># 281 "/usr/include/c++/4.9.0/fstream" 3 > __filebuf_type* > open(const std::string& __s, ios_base::openmode __mode) > { return open(__s.c_str(), __mode); } ># 298 "/usr/include/c++/4.9.0/fstream" 3 > __filebuf_type* > close(); > > protected: > void > _M_allocate_internal_buffer(); > > void > _M_destroy_internal_buffer() throw(); > > > virtual streamsize > showmanyc(); > > > > > > > virtual int_type > underflow(); > > virtual int_type > pbackfail(int_type __c = _Traits::eof()); ># 330 "/usr/include/c++/4.9.0/fstream" 3 > virtual int_type > overflow(int_type __c = _Traits::eof()); > > > > bool > _M_convert_to_external(char_type*, streamsize); ># 350 "/usr/include/c++/4.9.0/fstream" 3 > virtual __streambuf_type* > setbuf(char_type* __s, streamsize __n); > > virtual pos_type > seekoff(off_type __off, ios_base::seekdir __way, > ios_base::openmode __mode = ios_base::in | ios_base::out); > > virtual pos_type > seekpos(pos_type __pos, > ios_base::openmode __mode = ios_base::in | ios_base::out); > > > pos_type > _M_seek(off_type __off, ios_base::seekdir __way, __state_type __state); > > int > _M_get_ext_pos(__state_type &__state); > > virtual int > sync(); > > virtual void > imbue(const locale& __loc); > > virtual streamsize > xsgetn(char_type* __s, streamsize __n); > > virtual streamsize > xsputn(const char_type* __s, streamsize __n); > > > bool > _M_terminate_output(); ># 396 "/usr/include/c++/4.9.0/fstream" 3 > void > _M_set_buffer(streamsize __off) > { > const bool __testin = _M_mode & ios_base::in; > const bool __testout = (_M_mode & ios_base::out > || _M_mode & ios_base::app); > > if (__testin && __off > 0) > this->setg(_M_buf, _M_buf, _M_buf + __off); > else > this->setg(_M_buf, _M_buf, _M_buf); > > if (__testout && __off == 0 && _M_buf_size > 1 ) > this->setp(_M_buf, _M_buf + _M_buf_size - 1); > else > this->setp(0, 0); > } > }; ># 429 "/usr/include/c++/4.9.0/fstream" 3 > template<typename _CharT, typename _Traits> > class basic_ifstream : public basic_istream<_CharT, _Traits> > { > public: > > typedef _CharT char_type; > typedef _Traits traits_type; > typedef typename traits_type::int_type int_type; > typedef typename traits_type::pos_type pos_type; > typedef typename traits_type::off_type off_type; > > > typedef basic_filebuf<char_type, traits_type> __filebuf_type; > typedef basic_istream<char_type, traits_type> __istream_type; > > private: > __filebuf_type _M_filebuf; > > public: ># 456 "/usr/include/c++/4.9.0/fstream" 3 > basic_ifstream() : __istream_type(), _M_filebuf() > { this->init(&_M_filebuf); } ># 469 "/usr/include/c++/4.9.0/fstream" 3 > explicit > basic_ifstream(const char* __s, ios_base::openmode __mode = ios_base::in) > : __istream_type(), _M_filebuf() > { > this->init(&_M_filebuf); > this->open(__s, __mode); > } ># 485 "/usr/include/c++/4.9.0/fstream" 3 > explicit > basic_ifstream(const std::string& __s, > ios_base::openmode __mode = ios_base::in) > : __istream_type(), _M_filebuf() > { > this->init(&_M_filebuf); > this->open(__s, __mode); > } ># 501 "/usr/include/c++/4.9.0/fstream" 3 > ~basic_ifstream() > { } ># 511 "/usr/include/c++/4.9.0/fstream" 3 > __filebuf_type* > rdbuf() const > { return const_cast<__filebuf_type*>(&_M_filebuf); } > > > > > > bool > is_open() > { return _M_filebuf.is_open(); } > > > > bool > is_open() const > { return _M_filebuf.is_open(); } ># 540 "/usr/include/c++/4.9.0/fstream" 3 > void > open(const char* __s, ios_base::openmode __mode = ios_base::in) > { > if (!_M_filebuf.open(__s, __mode | ios_base::in)) > this->setstate(ios_base::failbit); > else > > > this->clear(); > } ># 560 "/usr/include/c++/4.9.0/fstream" 3 > void > open(const std::string& __s, ios_base::openmode __mode = ios_base::in) > { > if (!_M_filebuf.open(__s, __mode | ios_base::in)) > this->setstate(ios_base::failbit); > else > > > this->clear(); > } ># 578 "/usr/include/c++/4.9.0/fstream" 3 > void > close() > { > if (!_M_filebuf.close()) > this->setstate(ios_base::failbit); > } > }; ># 601 "/usr/include/c++/4.9.0/fstream" 3 > template<typename _CharT, typename _Traits> > class basic_ofstream : public basic_ostream<_CharT,_Traits> > { > public: > > typedef _CharT char_type; > typedef _Traits traits_type; > typedef typename traits_type::int_type int_type; > typedef typename traits_type::pos_type pos_type; > typedef typename traits_type::off_type off_type; > > > typedef basic_filebuf<char_type, traits_type> __filebuf_type; > typedef basic_ostream<char_type, traits_type> __ostream_type; > > private: > __filebuf_type _M_filebuf; > > public: ># 628 "/usr/include/c++/4.9.0/fstream" 3 > basic_ofstream(): __ostream_type(), _M_filebuf() > { this->init(&_M_filebuf); } ># 642 "/usr/include/c++/4.9.0/fstream" 3 > explicit > basic_ofstream(const char* __s, > ios_base::openmode __mode = ios_base::out|ios_base::trunc) > : __ostream_type(), _M_filebuf() > { > this->init(&_M_filebuf); > this->open(__s, __mode); > } ># 660 "/usr/include/c++/4.9.0/fstream" 3 > explicit > basic_ofstream(const std::string& __s, > ios_base::openmode __mode = ios_base::out|ios_base::trunc) > : __ostream_type(), _M_filebuf() > { > this->init(&_M_filebuf); > this->open(__s, __mode); > } ># 676 "/usr/include/c++/4.9.0/fstream" 3 > ~basic_ofstream() > { } ># 686 "/usr/include/c++/4.9.0/fstream" 3 > __filebuf_type* > rdbuf() const > { return const_cast<__filebuf_type*>(&_M_filebuf); } > > > > > > bool > is_open() > { return _M_filebuf.is_open(); } > > > > bool > is_open() const > { return _M_filebuf.is_open(); } ># 715 "/usr/include/c++/4.9.0/fstream" 3 > void > open(const char* __s, > ios_base::openmode __mode = ios_base::out | ios_base::trunc) > { > if (!_M_filebuf.open(__s, __mode | ios_base::out)) > this->setstate(ios_base::failbit); > else > > > this->clear(); > } ># 736 "/usr/include/c++/4.9.0/fstream" 3 > void > open(const std::string& __s, > ios_base::openmode __mode = ios_base::out | ios_base::trunc) > { > if (!_M_filebuf.open(__s, __mode | ios_base::out)) > this->setstate(ios_base::failbit); > else > > > this->clear(); > } ># 755 "/usr/include/c++/4.9.0/fstream" 3 > void > close() > { > if (!_M_filebuf.close()) > this->setstate(ios_base::failbit); > } > }; ># 778 "/usr/include/c++/4.9.0/fstream" 3 > template<typename _CharT, typename _Traits> > class basic_fstream : public basic_iostream<_CharT, _Traits> > { > public: > > typedef _CharT char_type; > typedef _Traits traits_type; > typedef typename traits_type::int_type int_type; > typedef typename traits_type::pos_type pos_type; > typedef typename traits_type::off_type off_type; > > > typedef basic_filebuf<char_type, traits_type> __filebuf_type; > typedef basic_ios<char_type, traits_type> __ios_type; > typedef basic_iostream<char_type, traits_type> __iostream_type; > > private: > __filebuf_type _M_filebuf; > > public: ># 806 "/usr/include/c++/4.9.0/fstream" 3 > basic_fstream() > : __iostream_type(), _M_filebuf() > { this->init(&_M_filebuf); } ># 818 "/usr/include/c++/4.9.0/fstream" 3 > explicit > basic_fstream(const char* __s, > ios_base::openmode __mode = ios_base::in | ios_base::out) > : __iostream_type(0), _M_filebuf() > { > this->init(&_M_filebuf); > this->open(__s, __mode); > } > > > > > > > > explicit > basic_fstream(const std::string& __s, > ios_base::openmode __mode = ios_base::in | ios_base::out) > : __iostream_type(0), _M_filebuf() > { > this->init(&_M_filebuf); > this->open(__s, __mode); > } ># 849 "/usr/include/c++/4.9.0/fstream" 3 > ~basic_fstream() > { } ># 859 "/usr/include/c++/4.9.0/fstream" 3 > __filebuf_type* > rdbuf() const > { return const_cast<__filebuf_type*>(&_M_filebuf); } > > > > > > bool > is_open() > { return _M_filebuf.is_open(); } > > > > bool > is_open() const > { return _M_filebuf.is_open(); } ># 888 "/usr/include/c++/4.9.0/fstream" 3 > void > open(const char* __s, > ios_base::openmode __mode = ios_base::in | ios_base::out) > { > if (!_M_filebuf.open(__s, __mode)) > this->setstate(ios_base::failbit); > else > > > this->clear(); > } ># 909 "/usr/include/c++/4.9.0/fstream" 3 > void > open(const std::string& __s, > ios_base::openmode __mode = ios_base::in | ios_base::out) > { > if (!_M_filebuf.open(__s, __mode)) > this->setstate(ios_base::failbit); > else > > > this->clear(); > } ># 928 "/usr/include/c++/4.9.0/fstream" 3 > void > close() > { > if (!_M_filebuf.close()) > this->setstate(ios_base::failbit); > } > }; > > >} > ># 1 "/usr/include/c++/4.9.0/bits/fstream.tcc" 1 3 ># 37 "/usr/include/c++/4.9.0/bits/fstream.tcc" 3 ># 38 "/usr/include/c++/4.9.0/bits/fstream.tcc" 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _CharT, typename _Traits> > void > basic_filebuf<_CharT, _Traits>:: > _M_allocate_internal_buffer() > { > > > if (!_M_buf_allocated && !_M_buf) > { > _M_buf = new char_type[_M_buf_size]; > _M_buf_allocated = true; > } > } > > template<typename _CharT, typename _Traits> > void > basic_filebuf<_CharT, _Traits>:: > _M_destroy_internal_buffer() throw() > { > if (_M_buf_allocated) > { > delete [] _M_buf; > _M_buf = 0; > _M_buf_allocated = false; > } > delete [] _M_ext_buf; > _M_ext_buf = 0; > _M_ext_buf_size = 0; > _M_ext_next = 0; > _M_ext_end = 0; > } > > template<typename _CharT, typename _Traits> > basic_filebuf<_CharT, _Traits>:: > basic_filebuf() : __streambuf_type(), _M_lock(), _M_file(&_M_lock), > _M_mode(ios_base::openmode(0)), _M_state_beg(), _M_state_cur(), > _M_state_last(), _M_buf(0), _M_buf_size(8192), > _M_buf_allocated(false), _M_reading(false), _M_writing(false), _M_pback(), > _M_pback_cur_save(0), _M_pback_end_save(0), _M_pback_init(false), > _M_codecvt(0), _M_ext_buf(0), _M_ext_buf_size(0), _M_ext_next(0), > _M_ext_end(0) > { > if (has_facet<__codecvt_type>(this->_M_buf_locale)) > _M_codecvt = &use_facet<__codecvt_type>(this->_M_buf_locale); > } > > template<typename _CharT, typename _Traits> > typename basic_filebuf<_CharT, _Traits>::__filebuf_type* > basic_filebuf<_CharT, _Traits>:: > open(const char* __s, ios_base::openmode __mode) > { > __filebuf_type *__ret = 0; > if (!this->is_open()) > { > _M_file.open(__s, __mode); > if (this->is_open()) > { > _M_allocate_internal_buffer(); > _M_mode = __mode; > > > _M_reading = false; > _M_writing = false; > _M_set_buffer(-1); > > > _M_state_last = _M_state_cur = _M_state_beg; > > > if ((__mode & ios_base::ate) > && this->seekoff(0, ios_base::end, __mode) > == pos_type(off_type(-1))) > this->close(); > else > __ret = this; > } > } > return __ret; > } > > template<typename _CharT, typename _Traits> > typename basic_filebuf<_CharT, _Traits>::__filebuf_type* > basic_filebuf<_CharT, _Traits>:: > close() > { > if (!this->is_open()) > return 0; > > bool __testfail = false; > { > > struct __close_sentry > { > basic_filebuf *__fb; > __close_sentry (basic_filebuf *__fbi): __fb(__fbi) { } > ~__close_sentry () > { > __fb->_M_mode = ios_base::openmode(0); > __fb->_M_pback_init = false; > __fb->_M_destroy_internal_buffer(); > __fb->_M_reading = false; > __fb->_M_writing = false; > __fb->_M_set_buffer(-1); > __fb->_M_state_last = __fb->_M_state_cur = __fb->_M_state_beg; > } > } __cs (this); > > try > { > if (!_M_terminate_output()) > __testfail = true; > } > catch(__cxxabiv1::__forced_unwind&) > { > _M_file.close(); > throw; > } > catch(...) > { __testfail = true; } > } > > if (!_M_file.close()) > __testfail = true; > > if (__testfail) > return 0; > else > return this; > } > > template<typename _CharT, typename _Traits> > streamsize > basic_filebuf<_CharT, _Traits>:: > showmanyc() > { > streamsize __ret = -1; > const bool __testin = _M_mode & ios_base::in; > if (__testin && this->is_open()) > { > > > __ret = this->egptr() - this->gptr(); > > > > > > > > if (__check_facet(_M_codecvt).encoding() >= 0) > > __ret += _M_file.showmanyc() / _M_codecvt->max_length(); > } > return __ret; > } > > template<typename _CharT, typename _Traits> > typename basic_filebuf<_CharT, _Traits>::int_type > basic_filebuf<_CharT, _Traits>:: > underflow() > { > int_type __ret = traits_type::eof(); > const bool __testin = _M_mode & ios_base::in; > if (__testin) > { > if (_M_writing) > { > if (overflow() == traits_type::eof()) > return __ret; > _M_set_buffer(-1); > _M_writing = false; > } > > > > _M_destroy_pback(); > > if (this->gptr() < this->egptr()) > return traits_type::to_int_type(*this->gptr()); > > > const size_t __buflen = _M_buf_size > 1 ? _M_buf_size - 1 : 1; > > > bool __got_eof = false; > > streamsize __ilen = 0; > codecvt_base::result __r = codecvt_base::ok; > if (__check_facet(_M_codecvt).always_noconv()) > { > __ilen = _M_file.xsgetn(reinterpret_cast<char*>(this->eback()), > __buflen); > if (__ilen == 0) > __got_eof = true; > } > else > { > > > const int __enc = _M_codecvt->encoding(); > streamsize __blen; > streamsize __rlen; > if (__enc > 0) > __blen = __rlen = __buflen * __enc; > else > { > __blen = __buflen + _M_codecvt->max_length() - 1; > __rlen = __buflen; > } > const streamsize __remainder = _M_ext_end - _M_ext_next; > __rlen = __rlen > __remainder ? __rlen - __remainder : 0; > > > > if (_M_reading && this->egptr() == this->eback() && __remainder) > __rlen = 0; > > > > if (_M_ext_buf_size < __blen) > { > char* __buf = new char[__blen]; > if (__remainder) > __builtin_memcpy(__buf, _M_ext_next, __remainder); > > delete [] _M_ext_buf; > _M_ext_buf = __buf; > _M_ext_buf_size = __blen; > } > else if (__remainder) > __builtin_memmove(_M_ext_buf, _M_ext_next, __remainder); > > _M_ext_next = _M_ext_buf; > _M_ext_end = _M_ext_buf + __remainder; > _M_state_last = _M_state_cur; > > do > { > if (__rlen > 0) > { > > > > if (_M_ext_end - _M_ext_buf + __rlen > _M_ext_buf_size) > { > __throw_ios_failure(("basic_filebuf::underflow " "codecvt::max_length() " "is not valid") > > ); > } > streamsize __elen = _M_file.xsgetn(_M_ext_end, __rlen); > if (__elen == 0) > __got_eof = true; > else if (__elen == -1) > break; > _M_ext_end += __elen; > } > > char_type* __iend = this->eback(); > if (_M_ext_next < _M_ext_end) > __r = _M_codecvt->in(_M_state_cur, _M_ext_next, > _M_ext_end, _M_ext_next, > this->eback(), > this->eback() + __buflen, __iend); > if (__r == codecvt_base::noconv) > { > size_t __avail = _M_ext_end - _M_ext_buf; > __ilen = std::min(__avail, __buflen); > traits_type::copy(this->eback(), > reinterpret_cast<char_type*> > (_M_ext_buf), __ilen); > _M_ext_next = _M_ext_buf + __ilen; > } > else > __ilen = __iend - this->eback(); > > > > > if (__r == codecvt_base::error) > break; > > __rlen = 1; > } > while (__ilen == 0 && !__got_eof); > } > > if (__ilen > 0) > { > _M_set_buffer(__ilen); > _M_reading = true; > __ret = traits_type::to_int_type(*this->gptr()); > } > else if (__got_eof) > { > > > > _M_set_buffer(-1); > _M_reading = false; > > > if (__r == codecvt_base::partial) > __throw_ios_failure(("basic_filebuf::underflow " "incomplete character in file") > ); > } > else if (__r == codecvt_base::error) > __throw_ios_failure(("basic_filebuf::underflow " "invalid byte sequence in file") > ); > else > __throw_ios_failure(("basic_filebuf::underflow " "error reading the file") > ); > } > return __ret; > } > > template<typename _CharT, typename _Traits> > typename basic_filebuf<_CharT, _Traits>::int_type > basic_filebuf<_CharT, _Traits>:: > pbackfail(int_type __i) > { > int_type __ret = traits_type::eof(); > const bool __testin = _M_mode & ios_base::in; > if (__testin) > { > if (_M_writing) > { > if (overflow() == traits_type::eof()) > return __ret; > _M_set_buffer(-1); > _M_writing = false; > } > > > const bool __testpb = _M_pback_init; > const bool __testeof = traits_type::eq_int_type(__i, __ret); > int_type __tmp; > if (this->eback() < this->gptr()) > { > this->gbump(-1); > __tmp = traits_type::to_int_type(*this->gptr()); > } > else if (this->seekoff(-1, ios_base::cur) != pos_type(off_type(-1))) > { > __tmp = this->underflow(); > if (traits_type::eq_int_type(__tmp, __ret)) > return __ret; > } > else > { > > > > > > return __ret; > } > > > > if (!__testeof && traits_type::eq_int_type(__i, __tmp)) > __ret = __i; > else if (__testeof) > __ret = traits_type::not_eof(__i); > else if (!__testpb) > { > _M_create_pback(); > _M_reading = true; > *this->gptr() = traits_type::to_char_type(__i); > __ret = __i; > } > } > return __ret; > } > > template<typename _CharT, typename _Traits> > typename basic_filebuf<_CharT, _Traits>::int_type > basic_filebuf<_CharT, _Traits>:: > overflow(int_type __c) > { > int_type __ret = traits_type::eof(); > const bool __testeof = traits_type::eq_int_type(__c, __ret); > const bool __testout = (_M_mode & ios_base::out > || _M_mode & ios_base::app); > if (__testout) > { > if (_M_reading) > { > _M_destroy_pback(); > const int __gptr_off = _M_get_ext_pos(_M_state_last); > if (_M_seek(__gptr_off, ios_base::cur, _M_state_last) > == pos_type(off_type(-1))) > return __ret; > } > if (this->pbase() < this->pptr()) > { > > if (!__testeof) > { > *this->pptr() = traits_type::to_char_type(__c); > this->pbump(1); > } > > > > if (_M_convert_to_external(this->pbase(), > this->pptr() - this->pbase())) > { > _M_set_buffer(0); > __ret = traits_type::not_eof(__c); > } > } > else if (_M_buf_size > 1) > { > > > > _M_set_buffer(0); > _M_writing = true; > if (!__testeof) > { > *this->pptr() = traits_type::to_char_type(__c); > this->pbump(1); > } > __ret = traits_type::not_eof(__c); > } > else > { > > char_type __conv = traits_type::to_char_type(__c); > if (__testeof || _M_convert_to_external(&__conv, 1)) > { > _M_writing = true; > __ret = traits_type::not_eof(__c); > } > } > } > return __ret; > } > > template<typename _CharT, typename _Traits> > bool > basic_filebuf<_CharT, _Traits>:: > _M_convert_to_external(_CharT* __ibuf, streamsize __ilen) > { > > streamsize __elen; > streamsize __plen; > if (__check_facet(_M_codecvt).always_noconv()) > { > __elen = _M_file.xsputn(reinterpret_cast<char*>(__ibuf), __ilen); > __plen = __ilen; > } > else > { > > > streamsize __blen = __ilen * _M_codecvt->max_length(); > char* __buf = static_cast<char*>(__builtin_alloca(__blen)); > > char* __bend; > const char_type* __iend; > codecvt_base::result __r; > __r = _M_codecvt->out(_M_state_cur, __ibuf, __ibuf + __ilen, > __iend, __buf, __buf + __blen, __bend); > > if (__r == codecvt_base::ok || __r == codecvt_base::partial) > __blen = __bend - __buf; > else if (__r == codecvt_base::noconv) > { > > __buf = reinterpret_cast<char*>(__ibuf); > __blen = __ilen; > } > else > __throw_ios_failure(("basic_filebuf::_M_convert_to_external " "conversion error") > ); > > __elen = _M_file.xsputn(__buf, __blen); > __plen = __blen; > > > if (__r == codecvt_base::partial && __elen == __plen) > { > const char_type* __iresume = __iend; > streamsize __rlen = this->pptr() - __iend; > __r = _M_codecvt->out(_M_state_cur, __iresume, > __iresume + __rlen, __iend, __buf, > __buf + __blen, __bend); > if (__r != codecvt_base::error) > { > __rlen = __bend - __buf; > __elen = _M_file.xsputn(__buf, __rlen); > __plen = __rlen; > } > else > __throw_ios_failure(("basic_filebuf::_M_convert_to_external " "conversion error") > ); > } > } > return __elen == __plen; > } > > template<typename _CharT, typename _Traits> > streamsize > basic_filebuf<_CharT, _Traits>:: > xsgetn(_CharT* __s, streamsize __n) > { > > streamsize __ret = 0; > if (_M_pback_init) > { > if (__n > 0 && this->gptr() == this->eback()) > { > *__s++ = *this->gptr(); > this->gbump(1); > __ret = 1; > --__n; > } > _M_destroy_pback(); > } > else if (_M_writing) > { > if (overflow() == traits_type::eof()) > return __ret; > _M_set_buffer(-1); > _M_writing = false; > } > > > > > const bool __testin = _M_mode & ios_base::in; > const streamsize __buflen = _M_buf_size > 1 ? _M_buf_size - 1 : 1; > > if (__n > __buflen && __check_facet(_M_codecvt).always_noconv() > && __testin) > { > > const streamsize __avail = this->egptr() - this->gptr(); > if (__avail != 0) > { > traits_type::copy(__s, this->gptr(), __avail); > __s += __avail; > this->setg(this->eback(), this->gptr() + __avail, > this->egptr()); > __ret += __avail; > __n -= __avail; > } > > > > streamsize __len; > for (;;) > { > __len = _M_file.xsgetn(reinterpret_cast<char*>(__s), > __n); > if (__len == -1) > __throw_ios_failure(("basic_filebuf::xsgetn " "error reading the file") > ); > if (__len == 0) > break; > > __n -= __len; > __ret += __len; > if (__n == 0) > break; > > __s += __len; > } > > if (__n == 0) > { > _M_set_buffer(0); > _M_reading = true; > } > else if (__len == 0) > { > > > > _M_set_buffer(-1); > _M_reading = false; > } > } > else > __ret += __streambuf_type::xsgetn(__s, __n); > > return __ret; > } > > template<typename _CharT, typename _Traits> > streamsize > basic_filebuf<_CharT, _Traits>:: > xsputn(const _CharT* __s, streamsize __n) > { > streamsize __ret = 0; > > > > const bool __testout = (_M_mode & ios_base::out > || _M_mode & ios_base::app); > if (__check_facet(_M_codecvt).always_noconv() > && __testout && !_M_reading) > { > > const streamsize __chunk = 1ul << 10; > streamsize __bufavail = this->epptr() - this->pptr(); > > > if (!_M_writing && _M_buf_size > 1) > __bufavail = _M_buf_size - 1; > > const streamsize __limit = std::min(__chunk, __bufavail); > if (__n >= __limit) > { > const streamsize __buffill = this->pptr() - this->pbase(); > const char* __buf = reinterpret_cast<const char*>(this->pbase()); > __ret = _M_file.xsputn_2(__buf, __buffill, > reinterpret_cast<const char*>(__s), > __n); > if (__ret == __buffill + __n) > { > _M_set_buffer(0); > _M_writing = true; > } > if (__ret > __buffill) > __ret -= __buffill; > else > __ret = 0; > } > else > __ret = __streambuf_type::xsputn(__s, __n); > } > else > __ret = __streambuf_type::xsputn(__s, __n); > return __ret; > } > > template<typename _CharT, typename _Traits> > typename basic_filebuf<_CharT, _Traits>::__streambuf_type* > basic_filebuf<_CharT, _Traits>:: > setbuf(char_type* __s, streamsize __n) > { > if (!this->is_open()) > { > if (__s == 0 && __n == 0) > _M_buf_size = 1; > else if (__s && __n > 0) > { ># 702 "/usr/include/c++/4.9.0/bits/fstream.tcc" 3 > _M_buf = __s; > _M_buf_size = __n; > } > } > return this; > } > > > > > template<typename _CharT, typename _Traits> > typename basic_filebuf<_CharT, _Traits>::pos_type > basic_filebuf<_CharT, _Traits>:: > seekoff(off_type __off, ios_base::seekdir __way, ios_base::openmode) > { > int __width = 0; > if (_M_codecvt) > __width = _M_codecvt->encoding(); > if (__width < 0) > __width = 0; > > pos_type __ret = pos_type(off_type(-1)); > const bool __testfail = __off != 0 && __width <= 0; > if (this->is_open() && !__testfail) > { > > > > > bool __no_movement = __way == ios_base::cur && __off == 0 > && (!_M_writing || _M_codecvt->always_noconv()); > > > if (!__no_movement) > _M_destroy_pback(); > > > > > > > __state_type __state = _M_state_beg; > off_type __computed_off = __off * __width; > if (_M_reading && __way == ios_base::cur) > { > __state = _M_state_last; > __computed_off += _M_get_ext_pos(__state); > } > if (!__no_movement) > __ret = _M_seek(__computed_off, __way, __state); > else > { > if (_M_writing) > __computed_off = this->pptr() - this->pbase(); > > off_type __file_off = _M_file.seekoff(0, ios_base::cur); > if (__file_off != off_type(-1)) > { > __ret = __file_off + __computed_off; > __ret.state(__state); > } > } > } > return __ret; > } > > > > > > template<typename _CharT, typename _Traits> > typename basic_filebuf<_CharT, _Traits>::pos_type > basic_filebuf<_CharT, _Traits>:: > seekpos(pos_type __pos, ios_base::openmode) > { > pos_type __ret = pos_type(off_type(-1)); > if (this->is_open()) > { > > _M_destroy_pback(); > __ret = _M_seek(off_type(__pos), ios_base::beg, __pos.state()); > } > return __ret; > } > > template<typename _CharT, typename _Traits> > typename basic_filebuf<_CharT, _Traits>::pos_type > basic_filebuf<_CharT, _Traits>:: > _M_seek(off_type __off, ios_base::seekdir __way, __state_type __state) > { > pos_type __ret = pos_type(off_type(-1)); > if (_M_terminate_output()) > { > off_type __file_off = _M_file.seekoff(__off, __way); > if (__file_off != off_type(-1)) > { > _M_reading = false; > _M_writing = false; > _M_ext_next = _M_ext_end = _M_ext_buf; > _M_set_buffer(-1); > _M_state_cur = __state; > __ret = __file_off; > __ret.state(_M_state_cur); > } > } > return __ret; > } > > > > > template<typename _CharT, typename _Traits> > int basic_filebuf<_CharT, _Traits>:: > _M_get_ext_pos(__state_type& __state) > { > if (_M_codecvt->always_noconv()) > return this->gptr() - this->egptr(); > else > { > > > > const int __gptr_off = > _M_codecvt->length(__state, _M_ext_buf, _M_ext_next, > this->gptr() - this->eback()); > return _M_ext_buf + __gptr_off - _M_ext_end; > } > } > > template<typename _CharT, typename _Traits> > bool > basic_filebuf<_CharT, _Traits>:: > _M_terminate_output() > { > > bool __testvalid = true; > if (this->pbase() < this->pptr()) > { > const int_type __tmp = this->overflow(); > if (traits_type::eq_int_type(__tmp, traits_type::eof())) > __testvalid = false; > } > > > if (_M_writing && !__check_facet(_M_codecvt).always_noconv() > && __testvalid) > { > > > > const size_t __blen = 128; > char __buf[__blen]; > codecvt_base::result __r; > streamsize __ilen = 0; > > do > { > char* __next; > __r = _M_codecvt->unshift(_M_state_cur, __buf, > __buf + __blen, __next); > if (__r == codecvt_base::error) > __testvalid = false; > else if (__r == codecvt_base::ok || > __r == codecvt_base::partial) > { > __ilen = __next - __buf; > if (__ilen > 0) > { > const streamsize __elen = _M_file.xsputn(__buf, __ilen); > if (__elen != __ilen) > __testvalid = false; > } > } > } > while (__r == codecvt_base::partial && __ilen > 0 && __testvalid); > > if (__testvalid) > { > > > > > const int_type __tmp = this->overflow(); > if (traits_type::eq_int_type(__tmp, traits_type::eof())) > __testvalid = false; > } > } > return __testvalid; > } > > template<typename _CharT, typename _Traits> > int > basic_filebuf<_CharT, _Traits>:: > sync() > { > > > int __ret = 0; > if (this->pbase() < this->pptr()) > { > const int_type __tmp = this->overflow(); > if (traits_type::eq_int_type(__tmp, traits_type::eof())) > __ret = -1; > } > return __ret; > } > > template<typename _CharT, typename _Traits> > void > basic_filebuf<_CharT, _Traits>:: > imbue(const locale& __loc) > { > bool __testvalid = true; > > const __codecvt_type* _M_codecvt_tmp = 0; > if (__builtin_expect(has_facet<__codecvt_type>(__loc), true)) > _M_codecvt_tmp = &use_facet<__codecvt_type>(__loc); > > if (this->is_open()) > { > > if ((_M_reading || _M_writing) > && __check_facet(_M_codecvt).encoding() == -1) > __testvalid = false; > else > { > if (_M_reading) > { > if (__check_facet(_M_codecvt).always_noconv()) > { > if (_M_codecvt_tmp > && !__check_facet(_M_codecvt_tmp).always_noconv()) > __testvalid = this->seekoff(0, ios_base::cur, _M_mode) > != pos_type(off_type(-1)); > } > else > { > > _M_ext_next = _M_ext_buf > + _M_codecvt->length(_M_state_last, _M_ext_buf, > _M_ext_next, > this->gptr() - this->eback()); > const streamsize __remainder = _M_ext_end - _M_ext_next; > if (__remainder) > __builtin_memmove(_M_ext_buf, _M_ext_next, __remainder); > > _M_ext_next = _M_ext_buf; > _M_ext_end = _M_ext_buf + __remainder; > _M_set_buffer(-1); > _M_state_last = _M_state_cur = _M_state_beg; > } > } > else if (_M_writing && (__testvalid = _M_terminate_output())) > _M_set_buffer(-1); > } > } > > if (__testvalid) > _M_codecvt = _M_codecvt_tmp; > else > _M_codecvt = 0; > } > > > > > extern template class basic_filebuf<char>; > extern template class basic_ifstream<char>; > extern template class basic_ofstream<char>; > extern template class basic_fstream<char>; > > > extern template class basic_filebuf<wchar_t>; > extern template class basic_ifstream<wchar_t>; > extern template class basic_ofstream<wchar_t>; > extern template class basic_fstream<wchar_t>; > > > > >} ># 940 "/usr/include/c++/4.9.0/fstream" 2 3 ># 38 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/usr/include/c++/4.9.0/algorithm" 1 3 ># 58 "/usr/include/c++/4.9.0/algorithm" 3 ># 59 "/usr/include/c++/4.9.0/algorithm" 3 > > > ># 1 "/usr/include/c++/4.9.0/bits/stl_algo.h" 1 3 ># 59 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 60 "/usr/include/c++/4.9.0/bits/stl_algo.h" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/algorithmfwd.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/algorithmfwd.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/algorithmfwd.h" 3 ># 42 "/usr/include/c++/4.9.0/bits/algorithmfwd.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 194 "/usr/include/c++/4.9.0/bits/algorithmfwd.h" 3 > template<typename _IIter, typename _Predicate> > bool > all_of(_IIter, _IIter, _Predicate); > > template<typename _IIter, typename _Predicate> > bool > any_of(_IIter, _IIter, _Predicate); > > > template<typename _FIter, typename _Tp> > bool > binary_search(_FIter, _FIter, const _Tp&); > > template<typename _FIter, typename _Tp, typename _Compare> > bool > binary_search(_FIter, _FIter, const _Tp&, _Compare); > > template<typename _IIter, typename _OIter> > _OIter > copy(_IIter, _IIter, _OIter); > > template<typename _BIter1, typename _BIter2> > _BIter2 > copy_backward(_BIter1, _BIter1, _BIter2); > > > template<typename _IIter, typename _OIter, typename _Predicate> > _OIter > copy_if(_IIter, _IIter, _OIter, _Predicate); > > template<typename _IIter, typename _Size, typename _OIter> > _OIter > copy_n(_IIter, _Size, _OIter); > > > > > > template<typename _FIter, typename _Tp> > pair<_FIter, _FIter> > equal_range(_FIter, _FIter, const _Tp&); > > template<typename _FIter, typename _Tp, typename _Compare> > pair<_FIter, _FIter> > equal_range(_FIter, _FIter, const _Tp&, _Compare); > > template<typename _FIter, typename _Tp> > void > fill(_FIter, _FIter, const _Tp&); > > template<typename _OIter, typename _Size, typename _Tp> > _OIter > fill_n(_OIter, _Size, const _Tp&); > > > > template<typename _FIter1, typename _FIter2> > _FIter1 > find_end(_FIter1, _FIter1, _FIter2, _FIter2); > > template<typename _FIter1, typename _FIter2, typename _BinaryPredicate> > _FIter1 > find_end(_FIter1, _FIter1, _FIter2, _FIter2, _BinaryPredicate); > > > > > > template<typename _IIter, typename _Predicate> > _IIter > find_if_not(_IIter, _IIter, _Predicate); > > > > > > > template<typename _IIter1, typename _IIter2> > bool > includes(_IIter1, _IIter1, _IIter2, _IIter2); > > template<typename _IIter1, typename _IIter2, typename _Compare> > bool > includes(_IIter1, _IIter1, _IIter2, _IIter2, _Compare); > > template<typename _BIter> > void > inplace_merge(_BIter, _BIter, _BIter); > > template<typename _BIter, typename _Compare> > void > inplace_merge(_BIter, _BIter, _BIter, _Compare); > > > template<typename _RAIter> > bool > is_heap(_RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > bool > is_heap(_RAIter, _RAIter, _Compare); > > template<typename _RAIter> > _RAIter > is_heap_until(_RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > _RAIter > is_heap_until(_RAIter, _RAIter, _Compare); > > template<typename _IIter, typename _Predicate> > bool > is_partitioned(_IIter, _IIter, _Predicate); > > template<typename _FIter1, typename _FIter2> > bool > is_permutation(_FIter1, _FIter1, _FIter2); > > template<typename _FIter1, typename _FIter2, > typename _BinaryPredicate> > bool > is_permutation(_FIter1, _FIter1, _FIter2, _BinaryPredicate); > > template<typename _FIter> > bool > is_sorted(_FIter, _FIter); > > template<typename _FIter, typename _Compare> > bool > is_sorted(_FIter, _FIter, _Compare); > > template<typename _FIter> > _FIter > is_sorted_until(_FIter, _FIter); > > template<typename _FIter, typename _Compare> > _FIter > is_sorted_until(_FIter, _FIter, _Compare); > > > template<typename _FIter1, typename _FIter2> > void > iter_swap(_FIter1, _FIter2); > > template<typename _FIter, typename _Tp> > _FIter > lower_bound(_FIter, _FIter, const _Tp&); > > template<typename _FIter, typename _Tp, typename _Compare> > _FIter > lower_bound(_FIter, _FIter, const _Tp&, _Compare); > > template<typename _RAIter> > void > make_heap(_RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > void > make_heap(_RAIter, _RAIter, _Compare); > > template<typename _Tp> > const _Tp& > max(const _Tp&, const _Tp&); > > template<typename _Tp, typename _Compare> > const _Tp& > max(const _Tp&, const _Tp&, _Compare); > > > > > template<typename _Tp> > const _Tp& > min(const _Tp&, const _Tp&); > > template<typename _Tp, typename _Compare> > const _Tp& > min(const _Tp&, const _Tp&, _Compare); > > > > > template<typename _Tp> > pair<const _Tp&, const _Tp&> > minmax(const _Tp&, const _Tp&); > > template<typename _Tp, typename _Compare> > pair<const _Tp&, const _Tp&> > minmax(const _Tp&, const _Tp&, _Compare); > > template<typename _FIter> > pair<_FIter, _FIter> > minmax_element(_FIter, _FIter); > > template<typename _FIter, typename _Compare> > pair<_FIter, _FIter> > minmax_element(_FIter, _FIter, _Compare); > > template<typename _Tp> > _Tp > min(initializer_list<_Tp>); > > template<typename _Tp, typename _Compare> > _Tp > min(initializer_list<_Tp>, _Compare); > > template<typename _Tp> > _Tp > max(initializer_list<_Tp>); > > template<typename _Tp, typename _Compare> > _Tp > max(initializer_list<_Tp>, _Compare); > > template<typename _Tp> > pair<_Tp, _Tp> > minmax(initializer_list<_Tp>); > > template<typename _Tp, typename _Compare> > pair<_Tp, _Tp> > minmax(initializer_list<_Tp>, _Compare); > > > > > template<typename _BIter> > bool > next_permutation(_BIter, _BIter); > > template<typename _BIter, typename _Compare> > bool > next_permutation(_BIter, _BIter, _Compare); > > > template<typename _IIter, typename _Predicate> > bool > none_of(_IIter, _IIter, _Predicate); > > > > > > template<typename _IIter, typename _RAIter> > _RAIter > partial_sort_copy(_IIter, _IIter, _RAIter, _RAIter); > > template<typename _IIter, typename _RAIter, typename _Compare> > _RAIter > partial_sort_copy(_IIter, _IIter, _RAIter, _RAIter, _Compare); > > > > > template<typename _IIter, typename _OIter1, > typename _OIter2, typename _Predicate> > pair<_OIter1, _OIter2> > partition_copy(_IIter, _IIter, _OIter1, _OIter2, _Predicate); > > template<typename _FIter, typename _Predicate> > _FIter > partition_point(_FIter, _FIter, _Predicate); > > > template<typename _RAIter> > void > pop_heap(_RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > void > pop_heap(_RAIter, _RAIter, _Compare); > > template<typename _BIter> > bool > prev_permutation(_BIter, _BIter); > > template<typename _BIter, typename _Compare> > bool > prev_permutation(_BIter, _BIter, _Compare); > > template<typename _RAIter> > void > push_heap(_RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > void > push_heap(_RAIter, _RAIter, _Compare); > > > > template<typename _FIter, typename _Tp> > _FIter > remove(_FIter, _FIter, const _Tp&); > > template<typename _FIter, typename _Predicate> > _FIter > remove_if(_FIter, _FIter, _Predicate); > > template<typename _IIter, typename _OIter, typename _Tp> > _OIter > remove_copy(_IIter, _IIter, _OIter, const _Tp&); > > template<typename _IIter, typename _OIter, typename _Predicate> > _OIter > remove_copy_if(_IIter, _IIter, _OIter, _Predicate); > > > > template<typename _IIter, typename _OIter, typename _Tp> > _OIter > replace_copy(_IIter, _IIter, _OIter, const _Tp&, const _Tp&); > > template<typename _Iter, typename _OIter, typename _Predicate, typename _Tp> > _OIter > replace_copy_if(_Iter, _Iter, _OIter, _Predicate, const _Tp&); > > > > template<typename _BIter> > void > reverse(_BIter, _BIter); > > template<typename _BIter, typename _OIter> > _OIter > reverse_copy(_BIter, _BIter, _OIter); > > template<typename _FIter> > void > rotate(_FIter, _FIter, _FIter); > > template<typename _FIter, typename _OIter> > _OIter > rotate_copy(_FIter, _FIter, _FIter, _OIter); ># 535 "/usr/include/c++/4.9.0/bits/algorithmfwd.h" 3 > template<typename _RAIter, typename _UGenerator> > void > shuffle(_RAIter, _RAIter, _UGenerator&&); > > > template<typename _RAIter> > void > sort_heap(_RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > void > sort_heap(_RAIter, _RAIter, _Compare); > > template<typename _BIter, typename _Predicate> > _BIter > stable_partition(_BIter, _BIter, _Predicate); > > template<typename _Tp> > void > swap(_Tp&, _Tp&) > > noexcept(__and_<is_nothrow_move_constructible<_Tp>, > is_nothrow_move_assignable<_Tp>>::value) > > ; > > template<typename _Tp, size_t _Nm> > void > swap(_Tp (&__a)[_Nm], _Tp (&__b)[_Nm]) > > noexcept(noexcept(swap(*__a, *__b))) > > ; > > template<typename _FIter1, typename _FIter2> > _FIter2 > swap_ranges(_FIter1, _FIter1, _FIter2); > > > > template<typename _FIter> > _FIter > unique(_FIter, _FIter); > > template<typename _FIter, typename _BinaryPredicate> > _FIter > unique(_FIter, _FIter, _BinaryPredicate); > > > > template<typename _FIter, typename _Tp> > _FIter > upper_bound(_FIter, _FIter, const _Tp&); > > template<typename _FIter, typename _Tp, typename _Compare> > _FIter > upper_bound(_FIter, _FIter, const _Tp&, _Compare); > > > > > > template<typename _FIter> > _FIter > adjacent_find(_FIter, _FIter); > > template<typename _FIter, typename _BinaryPredicate> > _FIter > adjacent_find(_FIter, _FIter, _BinaryPredicate); > > template<typename _IIter, typename _Tp> > typename iterator_traits<_IIter>::difference_type > count(_IIter, _IIter, const _Tp&); > > template<typename _IIter, typename _Predicate> > typename iterator_traits<_IIter>::difference_type > count_if(_IIter, _IIter, _Predicate); > > template<typename _IIter1, typename _IIter2> > bool > equal(_IIter1, _IIter1, _IIter2); > > template<typename _IIter1, typename _IIter2, typename _BinaryPredicate> > bool > equal(_IIter1, _IIter1, _IIter2, _BinaryPredicate); > > template<typename _IIter, typename _Tp> > _IIter > find(_IIter, _IIter, const _Tp&); > > template<typename _FIter1, typename _FIter2> > _FIter1 > find_first_of(_FIter1, _FIter1, _FIter2, _FIter2); > > template<typename _FIter1, typename _FIter2, typename _BinaryPredicate> > _FIter1 > find_first_of(_FIter1, _FIter1, _FIter2, _FIter2, _BinaryPredicate); > > template<typename _IIter, typename _Predicate> > _IIter > find_if(_IIter, _IIter, _Predicate); > > template<typename _IIter, typename _Funct> > _Funct > for_each(_IIter, _IIter, _Funct); > > template<typename _FIter, typename _Generator> > void > generate(_FIter, _FIter, _Generator); > > template<typename _OIter, typename _Size, typename _Generator> > _OIter > generate_n(_OIter, _Size, _Generator); > > template<typename _IIter1, typename _IIter2> > bool > lexicographical_compare(_IIter1, _IIter1, _IIter2, _IIter2); > > template<typename _IIter1, typename _IIter2, typename _Compare> > bool > lexicographical_compare(_IIter1, _IIter1, _IIter2, _IIter2, _Compare); > > template<typename _FIter> > _FIter > max_element(_FIter, _FIter); > > template<typename _FIter, typename _Compare> > _FIter > max_element(_FIter, _FIter, _Compare); > > template<typename _IIter1, typename _IIter2, typename _OIter> > _OIter > merge(_IIter1, _IIter1, _IIter2, _IIter2, _OIter); > > template<typename _IIter1, typename _IIter2, typename _OIter, > typename _Compare> > _OIter > merge(_IIter1, _IIter1, _IIter2, _IIter2, _OIter, _Compare); > > template<typename _FIter> > _FIter > min_element(_FIter, _FIter); > > template<typename _FIter, typename _Compare> > _FIter > min_element(_FIter, _FIter, _Compare); > > template<typename _IIter1, typename _IIter2> > pair<_IIter1, _IIter2> > mismatch(_IIter1, _IIter1, _IIter2); > > template<typename _IIter1, typename _IIter2, typename _BinaryPredicate> > pair<_IIter1, _IIter2> > mismatch(_IIter1, _IIter1, _IIter2, _BinaryPredicate); > > template<typename _RAIter> > void > nth_element(_RAIter, _RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > void > nth_element(_RAIter, _RAIter, _RAIter, _Compare); > > template<typename _RAIter> > void > partial_sort(_RAIter, _RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > void > partial_sort(_RAIter, _RAIter, _RAIter, _Compare); > > template<typename _BIter, typename _Predicate> > _BIter > partition(_BIter, _BIter, _Predicate); > > template<typename _RAIter> > void > random_shuffle(_RAIter, _RAIter); > > template<typename _RAIter, typename _Generator> > void > random_shuffle(_RAIter, _RAIter, > > _Generator&&); > > > > > template<typename _FIter, typename _Tp> > void > replace(_FIter, _FIter, const _Tp&, const _Tp&); > > template<typename _FIter, typename _Predicate, typename _Tp> > void > replace_if(_FIter, _FIter, _Predicate, const _Tp&); > > template<typename _FIter1, typename _FIter2> > _FIter1 > search(_FIter1, _FIter1, _FIter2, _FIter2); > > template<typename _FIter1, typename _FIter2, typename _BinaryPredicate> > _FIter1 > search(_FIter1, _FIter1, _FIter2, _FIter2, _BinaryPredicate); > > template<typename _FIter, typename _Size, typename _Tp> > _FIter > search_n(_FIter, _FIter, _Size, const _Tp&); > > template<typename _FIter, typename _Size, typename _Tp, > typename _BinaryPredicate> > _FIter > search_n(_FIter, _FIter, _Size, const _Tp&, _BinaryPredicate); > > template<typename _IIter1, typename _IIter2, typename _OIter> > _OIter > set_difference(_IIter1, _IIter1, _IIter2, _IIter2, _OIter); > > template<typename _IIter1, typename _IIter2, typename _OIter, > typename _Compare> > _OIter > set_difference(_IIter1, _IIter1, _IIter2, _IIter2, _OIter, _Compare); > > template<typename _IIter1, typename _IIter2, typename _OIter> > _OIter > set_intersection(_IIter1, _IIter1, _IIter2, _IIter2, _OIter); > > template<typename _IIter1, typename _IIter2, typename _OIter, > typename _Compare> > _OIter > set_intersection(_IIter1, _IIter1, _IIter2, _IIter2, _OIter, _Compare); > > template<typename _IIter1, typename _IIter2, typename _OIter> > _OIter > set_symmetric_difference(_IIter1, _IIter1, _IIter2, _IIter2, _OIter); > > template<typename _IIter1, typename _IIter2, typename _OIter, > typename _Compare> > _OIter > set_symmetric_difference(_IIter1, _IIter1, _IIter2, _IIter2, > _OIter, _Compare); > > template<typename _IIter1, typename _IIter2, typename _OIter> > _OIter > set_union(_IIter1, _IIter1, _IIter2, _IIter2, _OIter); > > template<typename _IIter1, typename _IIter2, typename _OIter, > typename _Compare> > _OIter > set_union(_IIter1, _IIter1, _IIter2, _IIter2, _OIter, _Compare); > > template<typename _RAIter> > void > sort(_RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > void > sort(_RAIter, _RAIter, _Compare); > > template<typename _RAIter> > void > stable_sort(_RAIter, _RAIter); > > template<typename _RAIter, typename _Compare> > void > stable_sort(_RAIter, _RAIter, _Compare); > > template<typename _IIter, typename _OIter, typename _UnaryOperation> > _OIter > transform(_IIter, _IIter, _OIter, _UnaryOperation); > > template<typename _IIter1, typename _IIter2, typename _OIter, > typename _BinaryOperation> > _OIter > transform(_IIter1, _IIter1, _IIter2, _OIter, _BinaryOperation); > > template<typename _IIter, typename _OIter> > _OIter > unique_copy(_IIter, _IIter, _OIter); > > template<typename _IIter, typename _OIter, typename _BinaryPredicate> > _OIter > unique_copy(_IIter, _IIter, _OIter, _BinaryPredicate); > > >} ># 61 "/usr/include/c++/4.9.0/bits/stl_algo.h" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_heap.h" 1 3 ># 62 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > > template<typename _RandomAccessIterator, typename _Distance, > typename _Compare> > _Distance > __is_heap_until(_RandomAccessIterator __first, _Distance __n, > _Compare __comp) > { > _Distance __parent = 0; > for (_Distance __child = 1; __child < __n; ++__child) > { > if (__comp(__first + __parent, __first + __child)) > return __child; > if ((__child & 1) == 0) > ++__parent; > } > return __n; > } > > > > template<typename _RandomAccessIterator, typename _Distance> > inline bool > __is_heap(_RandomAccessIterator __first, _Distance __n) > { > return std::__is_heap_until(__first, __n, > __gnu_cxx::__ops::__iter_less_iter()) == __n; > } > > template<typename _RandomAccessIterator, typename _Compare, > typename _Distance> > inline bool > __is_heap(_RandomAccessIterator __first, _Compare __comp, _Distance __n) > { > return std::__is_heap_until(__first, __n, > __gnu_cxx::__ops::__iter_comp_iter(__comp)) == __n; > } > > template<typename _RandomAccessIterator> > inline bool > __is_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) > { return std::__is_heap(__first, std::distance(__first, __last)); } > > template<typename _RandomAccessIterator, typename _Compare> > inline bool > __is_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { return std::__is_heap(__first, __comp, std::distance(__first, __last)); } > > > > > template<typename _RandomAccessIterator, typename _Distance, typename _Tp, > typename _Compare> > void > __push_heap(_RandomAccessIterator __first, > _Distance __holeIndex, _Distance __topIndex, _Tp __value, > _Compare __comp) > { > _Distance __parent = (__holeIndex - 1) / 2; > while (__holeIndex > __topIndex && __comp(__first + __parent, __value)) > { > *(__first + __holeIndex) = std::move(*(__first + __parent)); > __holeIndex = __parent; > __parent = (__holeIndex - 1) / 2; > } > *(__first + __holeIndex) = std::move(__value); > } ># 148 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator> > inline void > push_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) > { > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _ValueType; > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _DistanceType; > > > > > > ; > ; > > _ValueType __value = std::move(*(__last - 1)); > std::__push_heap(__first, _DistanceType((__last - __first) - 1), > _DistanceType(0), std::move(__value), > __gnu_cxx::__ops::__iter_less_val()); > } ># 182 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline void > push_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _ValueType; > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _DistanceType; > > > > > ; > ; > > _ValueType __value = std::move(*(__last - 1)); > std::__push_heap(__first, _DistanceType((__last - __first) - 1), > _DistanceType(0), std::move(__value), > __gnu_cxx::__ops::__iter_comp_val(__comp)); > } > > template<typename _RandomAccessIterator, typename _Distance, > typename _Tp, typename _Compare> > void > __adjust_heap(_RandomAccessIterator __first, _Distance __holeIndex, > _Distance __len, _Tp __value, _Compare __comp) > { > const _Distance __topIndex = __holeIndex; > _Distance __secondChild = __holeIndex; > while (__secondChild < (__len - 1) / 2) > { > __secondChild = 2 * (__secondChild + 1); > if (__comp(__first + __secondChild, > __first + (__secondChild - 1))) > __secondChild--; > *(__first + __holeIndex) = std::move(*(__first + __secondChild)); > __holeIndex = __secondChild; > } > if ((__len & 1) == 0 && __secondChild == (__len - 2) / 2) > { > __secondChild = 2 * (__secondChild + 1); > *(__first + __holeIndex) = std::move(*(__first + (__secondChild - 1))) > ; > __holeIndex = __secondChild - 1; > } > std::__push_heap(__first, __holeIndex, __topIndex, > std::move(__value), > __gnu_cxx::__ops::__iter_comp_val(__comp)); > } > > template<typename _RandomAccessIterator, typename _Compare> > inline void > __pop_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, > _RandomAccessIterator __result, _Compare __comp) > { > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _ValueType; > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _DistanceType; > > _ValueType __value = std::move(*__result); > *__result = std::move(*__first); > std::__adjust_heap(__first, _DistanceType(0), > _DistanceType(__last - __first), > std::move(__value), __comp); > } ># 261 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator> > inline void > pop_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) > { > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _ValueType; > > > > > > ; > ; > ; > > if (__last - __first > 1) > { > --__last; > std::__pop_heap(__first, __last, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } > } ># 295 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline void > pop_heap(_RandomAccessIterator __first, > _RandomAccessIterator __last, _Compare __comp) > { > > > > ; > ; > ; > > if (__last - __first > 1) > { > --__last; > std::__pop_heap(__first, __last, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > } > > template<typename _RandomAccessIterator, typename _Compare> > void > __make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _ValueType; > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _DistanceType; > > if (__last - __first < 2) > return; > > const _DistanceType __len = __last - __first; > _DistanceType __parent = (__len - 2) / 2; > while (true) > { > _ValueType __value = std::move(*(__first + __parent)); > std::__adjust_heap(__first, __parent, __len, std::move(__value), > __comp); > if (__parent == 0) > return; > __parent--; > } > } ># 349 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator> > inline void > make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) > { > > > > > > ; > > std::__make_heap(__first, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 374 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline void > make_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > > > > ; > > std::__make_heap(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _RandomAccessIterator, typename _Compare> > void > __sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > while (__last - __first > 1) > { > --__last; > std::__pop_heap(__first, __last, __last, __comp); > } > } ># 408 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator> > inline void > sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) > { > > > > > > ; > ; > > std::__sort_heap(__first, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 434 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline void > sort_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > > > > ; > ; > > std::__sort_heap(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } ># 460 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator> > inline _RandomAccessIterator > is_heap_until(_RandomAccessIterator __first, _RandomAccessIterator __last) > { > > > > > > ; > > return __first + > std::__is_heap_until(__first, std::distance(__first, __last), > __gnu_cxx::__ops::__iter_less_iter()); > } ># 487 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline _RandomAccessIterator > is_heap_until(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > > > > ; > > return __first > + std::__is_heap_until(__first, std::distance(__first, __last), > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } ># 509 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator> > inline bool > is_heap(_RandomAccessIterator __first, _RandomAccessIterator __last) > { return std::is_heap_until(__first, __last) == __last; } ># 522 "/usr/include/c++/4.9.0/bits/stl_heap.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline bool > is_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { return std::is_heap_until(__first, __last, __comp) == __last; } > > > >} ># 62 "/usr/include/c++/4.9.0/bits/stl_algo.h" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_tempbuf.h" 1 3 ># 60 "/usr/include/c++/4.9.0/bits/stl_tempbuf.h" 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_construct.h" 1 3 ># 61 "/usr/include/c++/4.9.0/bits/stl_construct.h" 3 ># 1 "/usr/include/c++/4.9.0/ext/alloc_traits.h" 1 3 ># 32 "/usr/include/c++/4.9.0/ext/alloc_traits.h" 3 ># 33 "/usr/include/c++/4.9.0/ext/alloc_traits.h" 3 > > > ># 1 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 1 3 ># 39 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Alloc, typename _Tp> > class __alloctr_rebind_helper > { > template<typename _Alloc2, typename _Tp2> > static constexpr true_type > _S_chk(typename _Alloc2::template rebind<_Tp2>::other*); > > template<typename, typename> > static constexpr false_type > _S_chk(...); > > public: > using __type = decltype(_S_chk<_Alloc, _Tp>(nullptr)); > }; > > template<typename _Alloc, typename _Tp, > bool = __alloctr_rebind_helper<_Alloc, _Tp>::__type::value> > struct __alloctr_rebind; > > template<typename _Alloc, typename _Tp> > struct __alloctr_rebind<_Alloc, _Tp, true> > { > typedef typename _Alloc::template rebind<_Tp>::other __type; > }; > > template<template<typename, typename...> class _Alloc, typename _Tp, > typename _Up, typename... _Args> > struct __alloctr_rebind<_Alloc<_Up, _Args...>, _Tp, false> > { > typedef _Alloc<_Tp, _Args...> __type; > }; > > > > > > template<typename _Alloc> > struct allocator_traits > { > > typedef _Alloc allocator_type; > > typedef typename _Alloc::value_type value_type; ># 95 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 >private: template<typename _Tp> static typename _Tp::pointer _S_pointer_helper(_Tp*); static value_type* _S_pointer_helper(...); typedef decltype(_S_pointer_helper((_Alloc*)0)) __pointer; public: > > > > > > > typedef __pointer pointer; > >private: template<typename _Tp> static typename _Tp::const_pointer _S_const_pointer_helper(_Tp*); static typename pointer_traits<pointer>::template rebind<const value_type> _S_const_pointer_helper(...); typedef decltype(_S_const_pointer_helper((_Alloc*)0)) __const_pointer; public: ># 113 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > typedef __const_pointer const_pointer; > >private: template<typename _Tp> static typename _Tp::void_pointer _S_void_pointer_helper(_Tp*); static typename pointer_traits<pointer>::template rebind<void> _S_void_pointer_helper(...); typedef decltype(_S_void_pointer_helper((_Alloc*)0)) __void_pointer; public: ># 124 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > typedef __void_pointer void_pointer; > >private: template<typename _Tp> static typename _Tp::const_void_pointer _S_const_void_pointer_helper(_Tp*); static typename pointer_traits<pointer>::template rebind<const void> _S_const_void_pointer_helper(...); typedef decltype(_S_const_void_pointer_helper((_Alloc*)0)) __const_void_pointer; public: ># 135 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > typedef __const_void_pointer const_void_pointer; > >private: template<typename _Tp> static typename _Tp::difference_type _S_difference_type_helper(_Tp*); static typename pointer_traits<pointer>::difference_type _S_difference_type_helper(...); typedef decltype(_S_difference_type_helper((_Alloc*)0)) __difference_type; public: ># 146 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > typedef __difference_type difference_type; > >private: template<typename _Tp> static typename _Tp::size_type _S_size_type_helper(_Tp*); static typename make_unsigned<difference_type>::type _S_size_type_helper(...); typedef decltype(_S_size_type_helper((_Alloc*)0)) __size_type; public: ># 157 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > typedef __size_type size_type; > >private: template<typename _Tp> static typename _Tp::propagate_on_container_copy_assignment _S_propagate_on_container_copy_assignment_helper(_Tp*); static false_type _S_propagate_on_container_copy_assignment_helper(...); typedef decltype(_S_propagate_on_container_copy_assignment_helper((_Alloc*)0)) __propagate_on_container_copy_assignment; public: ># 168 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > typedef __propagate_on_container_copy_assignment > propagate_on_container_copy_assignment; > >private: template<typename _Tp> static typename _Tp::propagate_on_container_move_assignment _S_propagate_on_container_move_assignment_helper(_Tp*); static false_type _S_propagate_on_container_move_assignment_helper(...); typedef decltype(_S_propagate_on_container_move_assignment_helper((_Alloc*)0)) __propagate_on_container_move_assignment; public: ># 180 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > typedef __propagate_on_container_move_assignment > propagate_on_container_move_assignment; > >private: template<typename _Tp> static typename _Tp::propagate_on_container_swap _S_propagate_on_container_swap_helper(_Tp*); static false_type _S_propagate_on_container_swap_helper(...); typedef decltype(_S_propagate_on_container_swap_helper((_Alloc*)0)) __propagate_on_container_swap; public: ># 192 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > typedef __propagate_on_container_swap propagate_on_container_swap; > > > > template<typename _Tp> > using rebind_alloc = typename __alloctr_rebind<_Alloc, _Tp>::__type; > template<typename _Tp> > using rebind_traits = allocator_traits<rebind_alloc<_Tp>>; > > private: > template<typename _Alloc2> > struct __allocate_helper > { > template<typename _Alloc3, > typename = decltype(std::declval<_Alloc3*>()->allocate( > std::declval<size_type>(), > std::declval<const_void_pointer>()))> > static true_type __test(int); > > template<typename> > static false_type __test(...); > > using type = decltype(__test<_Alloc>(0)); > }; > > template<typename _Alloc2> > using __has_allocate = typename __allocate_helper<_Alloc2>::type; > > template<typename _Alloc2, > typename = _Require<__has_allocate<_Alloc2>>> > static pointer > _S_allocate(_Alloc2& __a, size_type __n, const_void_pointer __hint) > { return __a.allocate(__n, __hint); } > > template<typename _Alloc2, typename _UnusedHint, > typename = _Require<__not_<__has_allocate<_Alloc2>>>> > static pointer > _S_allocate(_Alloc2& __a, size_type __n, _UnusedHint) > { return __a.allocate(__n); } > > template<typename _Tp, typename... _Args> > struct __construct_helper > { > template<typename _Alloc2, > typename = decltype(std::declval<_Alloc2*>()->construct( > std::declval<_Tp*>(), std::declval<_Args>()...))> > static true_type __test(int); > > template<typename> > static false_type __test(...); > > using type = decltype(__test<_Alloc>(0)); > }; > > template<typename _Tp, typename... _Args> > using __has_construct > = typename __construct_helper<_Tp, _Args...>::type; > > template<typename _Tp, typename... _Args> > static _Require<__has_construct<_Tp, _Args...>> > _S_construct(_Alloc& __a, _Tp* __p, _Args&&... __args) > { __a.construct(__p, std::forward<_Args>(__args)...); } > > template<typename _Tp, typename... _Args> > static > _Require<__and_<__not_<__has_construct<_Tp, _Args...>>, > is_constructible<_Tp, _Args...>>> > _S_construct(_Alloc&, _Tp* __p, _Args&&... __args) > { ::new((void*)__p) _Tp(std::forward<_Args>(__args)...); } > > template<typename _Tp> > struct __destroy_helper > { > template<typename _Alloc2, > typename = decltype(std::declval<_Alloc2*>()->destroy( > std::declval<_Tp*>()))> > static true_type __test(int); > > template<typename> > static false_type __test(...); > > using type = decltype(__test<_Alloc>(0)); > }; > > template<typename _Tp> > using __has_destroy = typename __destroy_helper<_Tp>::type; > > template<typename _Tp> > static _Require<__has_destroy<_Tp>> > _S_destroy(_Alloc& __a, _Tp* __p) > { __a.destroy(__p); } > > template<typename _Tp> > static _Require<__not_<__has_destroy<_Tp>>> > _S_destroy(_Alloc&, _Tp* __p) > { __p->~_Tp(); } > > template<typename _Alloc2> > struct __maxsize_helper > { > template<typename _Alloc3, > typename = decltype(std::declval<_Alloc3*>()->max_size())> > static true_type __test(int); > > template<typename> > static false_type __test(...); > > using type = decltype(__test<_Alloc2>(0)); > }; > > template<typename _Alloc2> > using __has_max_size = typename __maxsize_helper<_Alloc2>::type; > > template<typename _Alloc2, > typename = _Require<__has_max_size<_Alloc2>>> > static size_type > _S_max_size(_Alloc2& __a, int) > { return __a.max_size(); } > > template<typename _Alloc2, > typename = _Require<__not_<__has_max_size<_Alloc2>>>> > static size_type > _S_max_size(_Alloc2&, ...) > { return __gnu_cxx::__numeric_traits<size_type>::__max; } > > template<typename _Alloc2> > struct __select_helper > { > template<typename _Alloc3, typename > = decltype(std::declval<_Alloc3*>() > ->select_on_container_copy_construction())> > static true_type __test(int); > > template<typename> > static false_type __test(...); > > using type = decltype(__test<_Alloc2>(0)); > }; > > template<typename _Alloc2> > using __has_soccc = typename __select_helper<_Alloc2>::type; > > template<typename _Alloc2, > typename = _Require<__has_soccc<_Alloc2>>> > static _Alloc2 > _S_select(_Alloc2& __a, int) > { return __a.select_on_container_copy_construction(); } > > template<typename _Alloc2, > typename = _Require<__not_<__has_soccc<_Alloc2>>>> > static _Alloc2 > _S_select(_Alloc2& __a, ...) > { return __a; } > > public: ># 355 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > static pointer > allocate(_Alloc& __a, size_type __n) > { return __a.allocate(__n); } ># 370 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > static pointer > allocate(_Alloc& __a, size_type __n, const_void_pointer __hint) > { return _S_allocate(__a, __n, __hint); } ># 382 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > static void deallocate(_Alloc& __a, pointer __p, size_type __n) > { __a.deallocate(__p, __n); } ># 396 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > template<typename _Tp, typename... _Args> > static auto construct(_Alloc& __a, _Tp* __p, _Args&&... __args) > -> decltype(_S_construct(__a, __p, std::forward<_Args>(__args)...)) > { _S_construct(__a, __p, std::forward<_Args>(__args)...); } ># 409 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > template <class _Tp> > static void destroy(_Alloc& __a, _Tp* __p) > { _S_destroy(__a, __p); } ># 421 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > static size_type max_size(const _Alloc& __a) noexcept > { return _S_max_size(__a, 0); } ># 432 "/usr/include/c++/4.9.0/bits/alloc_traits.h" 3 > static _Alloc > select_on_container_copy_construction(const _Alloc& __rhs) > { return _S_select(__rhs, 0); } > }; > > template<typename _Alloc> > inline void > __do_alloc_on_copy(_Alloc& __one, const _Alloc& __two, true_type) > { __one = __two; } > > template<typename _Alloc> > inline void > __do_alloc_on_copy(_Alloc&, const _Alloc&, false_type) > { } > > template<typename _Alloc> > inline void __alloc_on_copy(_Alloc& __one, const _Alloc& __two) > { > typedef allocator_traits<_Alloc> __traits; > typedef typename __traits::propagate_on_container_copy_assignment __pocca; > __do_alloc_on_copy(__one, __two, __pocca()); > } > > template<typename _Alloc> > inline _Alloc __alloc_on_copy(const _Alloc& __a) > { > typedef allocator_traits<_Alloc> __traits; > return __traits::select_on_container_copy_construction(__a); > } > > template<typename _Alloc> > inline void __do_alloc_on_move(_Alloc& __one, _Alloc& __two, true_type) > { __one = std::move(__two); } > > template<typename _Alloc> > inline void __do_alloc_on_move(_Alloc&, _Alloc&, false_type) > { } > > template<typename _Alloc> > inline void __alloc_on_move(_Alloc& __one, _Alloc& __two) > { > typedef allocator_traits<_Alloc> __traits; > typedef typename __traits::propagate_on_container_move_assignment __pocma; > __do_alloc_on_move(__one, __two, __pocma()); > } > > template<typename _Alloc> > inline void __do_alloc_on_swap(_Alloc& __one, _Alloc& __two, true_type) > { > using std::swap; > swap(__one, __two); > } > > template<typename _Alloc> > inline void __do_alloc_on_swap(_Alloc&, _Alloc&, false_type) > { } > > template<typename _Alloc> > inline void __alloc_on_swap(_Alloc& __one, _Alloc& __two) > { > typedef allocator_traits<_Alloc> __traits; > typedef typename __traits::propagate_on_container_swap __pocs; > __do_alloc_on_swap(__one, __two, __pocs()); > } > > template<typename _Alloc> > class __is_copy_insertable_impl > { > typedef allocator_traits<_Alloc> _Traits; > > template<typename _Up, typename > = decltype(_Traits::construct(std::declval<_Alloc&>(), > std::declval<_Up*>(), > std::declval<const _Up&>()))> > static true_type > _M_select(int); > > template<typename _Up> > static false_type > _M_select(...); > > public: > typedef decltype(_M_select<typename _Alloc::value_type>(0)) type; > }; > > > template<typename _Alloc> > struct __is_copy_insertable > : __is_copy_insertable_impl<_Alloc>::type > { }; > > > template<typename _Tp> > struct __is_copy_insertable<allocator<_Tp>> > : is_copy_constructible<_Tp> > { }; > > >} ># 37 "/usr/include/c++/4.9.0/ext/alloc_traits.h" 2 3 > > > > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > > template<typename _Alloc> > struct __allocator_always_compares_equal : std::false_type { }; > > template<typename _Tp> > struct __allocator_always_compares_equal<std::allocator<_Tp>> > : std::true_type { }; > > template<typename, typename> struct array_allocator; > > template<typename _Tp, typename _Array> > struct __allocator_always_compares_equal<array_allocator<_Tp, _Array>> > : std::true_type { }; > > template<typename> struct bitmap_allocator; > > template<typename _Tp> > struct __allocator_always_compares_equal<bitmap_allocator<_Tp>> > : std::true_type { }; > > template<typename> struct malloc_allocator; > > template<typename _Tp> > struct __allocator_always_compares_equal<malloc_allocator<_Tp>> > : std::true_type { }; > > template<typename> struct mt_allocator; > > template<typename _Tp> > struct __allocator_always_compares_equal<mt_allocator<_Tp>> > : std::true_type { }; > > template<typename> struct new_allocator; > > template<typename _Tp> > struct __allocator_always_compares_equal<new_allocator<_Tp>> > : std::true_type { }; > > template<typename> struct pool_allocator; > > template<typename _Tp> > struct __allocator_always_compares_equal<pool_allocator<_Tp>> > : std::true_type { }; > > > > > > >template<typename _Alloc> > struct __alloc_traits > > : std::allocator_traits<_Alloc> > > { > typedef _Alloc allocator_type; > > typedef std::allocator_traits<_Alloc> _Base_type; > typedef typename _Base_type::value_type value_type; > typedef typename _Base_type::pointer pointer; > typedef typename _Base_type::const_pointer const_pointer; > typedef typename _Base_type::size_type size_type; > typedef typename _Base_type::difference_type difference_type; > > typedef value_type& reference; > typedef const value_type& const_reference; > using _Base_type::allocate; > using _Base_type::deallocate; > using _Base_type::construct; > using _Base_type::destroy; > using _Base_type::max_size; > > private: > template<typename _Ptr> > using __is_custom_pointer > = std::__and_<std::is_same<pointer, _Ptr>, > std::__not_<std::is_pointer<_Ptr>>>; > > public: > > template<typename _Ptr, typename... _Args> > static typename std::enable_if<__is_custom_pointer<_Ptr>::value>::type > construct(_Alloc& __a, _Ptr __p, _Args&&... __args) > { > _Base_type::construct(__a, std::addressof(*__p), > std::forward<_Args>(__args)...); > } > > > template<typename _Ptr> > static typename std::enable_if<__is_custom_pointer<_Ptr>::value>::type > destroy(_Alloc& __a, _Ptr __p) > { _Base_type::destroy(__a, std::addressof(*__p)); } > > static _Alloc _S_select_on_copy(const _Alloc& __a) > { return _Base_type::select_on_container_copy_construction(__a); } > > static void _S_on_swap(_Alloc& __a, _Alloc& __b) > { std::__alloc_on_swap(__a, __b); } > > static constexpr bool _S_propagate_on_copy_assign() > { return _Base_type::propagate_on_container_copy_assignment::value; } > > static constexpr bool _S_propagate_on_move_assign() > { return _Base_type::propagate_on_container_move_assignment::value; } > > static constexpr bool _S_propagate_on_swap() > { return _Base_type::propagate_on_container_swap::value; } > > static constexpr bool _S_always_equal() > { return __allocator_always_compares_equal<_Alloc>::value; } > > static constexpr bool _S_nothrow_move() > { return _S_propagate_on_move_assign() || _S_always_equal(); } > > static constexpr bool _S_nothrow_swap() > { > using std::swap; > return !_S_propagate_on_swap() > || noexcept(swap(std::declval<_Alloc&>(), std::declval<_Alloc&>())); > } > > template<typename _Tp> > struct rebind > { typedef typename _Base_type::template rebind_alloc<_Tp> other; }; ># 210 "/usr/include/c++/4.9.0/ext/alloc_traits.h" 3 > }; > > >} ># 62 "/usr/include/c++/4.9.0/bits/stl_construct.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > > template<typename _T1, typename... _Args> > inline void > _Construct(_T1* __p, _Args&&... __args) > { ::new(static_cast<void*>(__p)) _T1(std::forward<_Args>(__args)...); } ># 90 "/usr/include/c++/4.9.0/bits/stl_construct.h" 3 > template<typename _Tp> > inline void > _Destroy(_Tp* __pointer) > { __pointer->~_Tp(); } > > template<bool> > struct _Destroy_aux > { > template<typename _ForwardIterator> > static void > __destroy(_ForwardIterator __first, _ForwardIterator __last) > { > for (; __first != __last; ++__first) > std::_Destroy(std::__addressof(*__first)); > } > }; > > template<> > struct _Destroy_aux<true> > { > template<typename _ForwardIterator> > static void > __destroy(_ForwardIterator, _ForwardIterator) { } > }; > > > > > > > template<typename _ForwardIterator> > inline void > _Destroy(_ForwardIterator __first, _ForwardIterator __last) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _Value_type; > std::_Destroy_aux<__has_trivial_destructor(_Value_type)>:: > __destroy(__first, __last); > } > > > > > > > > template<typename _ForwardIterator, typename _Allocator> > void > _Destroy(_ForwardIterator __first, _ForwardIterator __last, > _Allocator& __alloc) > { > typedef __gnu_cxx::__alloc_traits<_Allocator> __traits; > for (; __first != __last; ++__first) > __traits::destroy(__alloc, std::__addressof(*__first)); > } > > template<typename _ForwardIterator, typename _Tp> > inline void > _Destroy(_ForwardIterator __first, _ForwardIterator __last, > allocator<_Tp>&) > { > _Destroy(__first, __last); > } > > >} ># 61 "/usr/include/c++/4.9.0/bits/stl_tempbuf.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 83 "/usr/include/c++/4.9.0/bits/stl_tempbuf.h" 3 > template<typename _Tp> > pair<_Tp*, ptrdiff_t> > get_temporary_buffer(ptrdiff_t __len) noexcept > { > const ptrdiff_t __max = > __gnu_cxx::__numeric_traits<ptrdiff_t>::__max / sizeof(_Tp); > if (__len > __max) > __len = __max; > > while (__len > 0) > { > _Tp* __tmp = static_cast<_Tp*>(::operator new(__len * sizeof(_Tp), > std::nothrow)); > if (__tmp != 0) > return std::pair<_Tp*, ptrdiff_t>(__tmp, __len); > __len /= 2; > } > return std::pair<_Tp*, ptrdiff_t>(static_cast<_Tp*>(0), 0); > } ># 110 "/usr/include/c++/4.9.0/bits/stl_tempbuf.h" 3 > template<typename _Tp> > inline void > return_temporary_buffer(_Tp* __p) > { ::operator delete(__p, std::nothrow); } > > > > > > > > template<typename _ForwardIterator, typename _Tp> > class _Temporary_buffer > { > > > > public: > typedef _Tp value_type; > typedef value_type* pointer; > typedef pointer iterator; > typedef ptrdiff_t size_type; > > protected: > size_type _M_original_len; > size_type _M_len; > pointer _M_buffer; > > public: > > size_type > size() const > { return _M_len; } > > > size_type > requested_size() const > { return _M_original_len; } > > > iterator > begin() > { return _M_buffer; } > > > iterator > end() > { return _M_buffer + _M_len; } > > > > > > _Temporary_buffer(_ForwardIterator __first, _ForwardIterator __last); > > ~_Temporary_buffer() > { > std::_Destroy(_M_buffer, _M_buffer + _M_len); > std::return_temporary_buffer(_M_buffer); > } > > private: > > _Temporary_buffer(const _Temporary_buffer&); > > void > operator=(const _Temporary_buffer&); > }; > > > template<bool> > struct __uninitialized_construct_buf_dispatch > { > template<typename _Pointer, typename _ForwardIterator> > static void > __ucr(_Pointer __first, _Pointer __last, > _ForwardIterator __seed) > { > if(__first == __last) > return; > > _Pointer __cur = __first; > try > { > std::_Construct(std::__addressof(*__first), > std::move(*__seed)); > _Pointer __prev = __cur; > ++__cur; > for(; __cur != __last; ++__cur, ++__prev) > std::_Construct(std::__addressof(*__cur), > std::move(*__prev)); > *__seed = std::move(*__prev); > } > catch(...) > { > std::_Destroy(__first, __cur); > throw; > } > } > }; > > template<> > struct __uninitialized_construct_buf_dispatch<true> > { > template<typename _Pointer, typename _ForwardIterator> > static void > __ucr(_Pointer, _Pointer, _ForwardIterator) { } > }; ># 229 "/usr/include/c++/4.9.0/bits/stl_tempbuf.h" 3 > template<typename _Pointer, typename _ForwardIterator> > inline void > __uninitialized_construct_buf(_Pointer __first, _Pointer __last, > _ForwardIterator __seed) > { > typedef typename std::iterator_traits<_Pointer>::value_type > _ValueType; > > std::__uninitialized_construct_buf_dispatch< > __has_trivial_constructor(_ValueType)>:: > __ucr(__first, __last, __seed); > } > > template<typename _ForwardIterator, typename _Tp> > _Temporary_buffer<_ForwardIterator, _Tp>:: > _Temporary_buffer(_ForwardIterator __first, _ForwardIterator __last) > : _M_original_len(std::distance(__first, __last)), > _M_len(0), _M_buffer(0) > { > try > { > std::pair<pointer, size_type> __p(std::get_temporary_buffer< > value_type>(_M_original_len)); > _M_buffer = __p.first; > _M_len = __p.second; > if (_M_buffer) > std::__uninitialized_construct_buf(_M_buffer, _M_buffer + _M_len, > __first); > } > catch(...) > { > std::return_temporary_buffer(_M_buffer); > _M_buffer = 0; > _M_len = 0; > throw; > } > } > > >} ># 63 "/usr/include/c++/4.9.0/bits/stl_algo.h" 2 3 > > > ># 1 "/usr/include/c++/4.9.0/random" 1 3 ># 32 "/usr/include/c++/4.9.0/random" 3 ># 33 "/usr/include/c++/4.9.0/random" 3 > > > > > ># 1 "/usr/include/c++/4.9.0/cmath" 1 3 ># 39 "/usr/include/c++/4.9.0/cmath" 3 ># 40 "/usr/include/c++/4.9.0/cmath" 3 > > > > ># 1 "/usr/include/math.h" 1 3 4 ># 28 "/usr/include/math.h" 3 4 >extern "C" { > > > ># 1 "/usr/include/bits/huge_val.h" 1 3 4 ># 33 "/usr/include/math.h" 2 3 4 > ># 1 "/usr/include/bits/huge_valf.h" 1 3 4 ># 35 "/usr/include/math.h" 2 3 4 ># 1 "/usr/include/bits/huge_vall.h" 1 3 4 ># 36 "/usr/include/math.h" 2 3 4 > > ># 1 "/usr/include/bits/inf.h" 1 3 4 ># 39 "/usr/include/math.h" 2 3 4 > > ># 1 "/usr/include/bits/nan.h" 1 3 4 ># 42 "/usr/include/math.h" 2 3 4 > > > ># 1 "/usr/include/bits/mathdef.h" 1 3 4 ># 28 "/usr/include/bits/mathdef.h" 3 4 >typedef float float_t; >typedef double double_t; ># 46 "/usr/include/math.h" 2 3 4 ># 69 "/usr/include/math.h" 3 4 ># 1 "/usr/include/bits/mathcalls.h" 1 3 4 ># 52 "/usr/include/bits/mathcalls.h" 3 4 > > >extern double acos (double __x) throw (); extern double __acos (double __x) throw (); > >extern double asin (double __x) throw (); extern double __asin (double __x) throw (); > >extern double atan (double __x) throw (); extern double __atan (double __x) throw (); > >extern double atan2 (double __y, double __x) throw (); extern double __atan2 (double __y, double __x) throw (); > > >extern double cos (double __x) throw (); extern double __cos (double __x) throw (); > >extern double sin (double __x) throw (); extern double __sin (double __x) throw (); > >extern double tan (double __x) throw (); extern double __tan (double __x) throw (); > > > > >extern double cosh (double __x) throw (); extern double __cosh (double __x) throw (); > >extern double sinh (double __x) throw (); extern double __sinh (double __x) throw (); > >extern double tanh (double __x) throw (); extern double __tanh (double __x) throw (); > > > > >extern void sincos (double __x, double *__sinx, double *__cosx) throw (); extern void __sincos (double __x, double *__sinx, double *__cosx) throw () > ; > > > > > >extern double acosh (double __x) throw (); extern double __acosh (double __x) throw (); > >extern double asinh (double __x) throw (); extern double __asinh (double __x) throw (); > >extern double atanh (double __x) throw (); extern double __atanh (double __x) throw (); > > > > > > > >extern double exp (double __x) throw (); extern double __exp (double __x) throw (); > > >extern double frexp (double __x, int *__exponent) throw (); extern double __frexp (double __x, int *__exponent) throw (); > > >extern double ldexp (double __x, int __exponent) throw (); extern double __ldexp (double __x, int __exponent) throw (); > > >extern double log (double __x) throw (); extern double __log (double __x) throw (); > > >extern double log10 (double __x) throw (); extern double __log10 (double __x) throw (); > > >extern double modf (double __x, double *__iptr) throw (); extern double __modf (double __x, double *__iptr) throw () __attribute__ ((__nonnull__ (2))); > > > > >extern double exp10 (double __x) throw (); extern double __exp10 (double __x) throw (); > >extern double pow10 (double __x) throw (); extern double __pow10 (double __x) throw (); > > > > > >extern double expm1 (double __x) throw (); extern double __expm1 (double __x) throw (); > > >extern double log1p (double __x) throw (); extern double __log1p (double __x) throw (); > > >extern double logb (double __x) throw (); extern double __logb (double __x) throw (); > > > > > > >extern double exp2 (double __x) throw (); extern double __exp2 (double __x) throw (); > > >extern double log2 (double __x) throw (); extern double __log2 (double __x) throw (); ># 153 "/usr/include/bits/mathcalls.h" 3 4 >extern double pow (double __x, double __y) throw (); extern double __pow (double __x, double __y) throw (); > > >extern double sqrt (double __x) throw (); extern double __sqrt (double __x) throw (); > > > > > >extern double hypot (double __x, double __y) throw (); extern double __hypot (double __x, double __y) throw (); > > > > > > >extern double cbrt (double __x) throw (); extern double __cbrt (double __x) throw (); ># 178 "/usr/include/bits/mathcalls.h" 3 4 >extern double ceil (double __x) throw () __attribute__ ((__const__)); extern double __ceil (double __x) throw () __attribute__ ((__const__)); > > >extern double fabs (double __x) throw () __attribute__ ((__const__)); extern double __fabs (double __x) throw () __attribute__ ((__const__)); > > >extern double floor (double __x) throw () __attribute__ ((__const__)); extern double __floor (double __x) throw () __attribute__ ((__const__)); > > >extern double fmod (double __x, double __y) throw (); extern double __fmod (double __x, double __y) throw (); > > > > >extern int __isinf (double __value) throw () __attribute__ ((__const__)); > > >extern int __finite (double __value) throw () __attribute__ ((__const__)); > > > > > >extern int isinf (double __value) throw () __attribute__ ((__const__)); > > >extern int finite (double __value) throw () __attribute__ ((__const__)); > > >extern double drem (double __x, double __y) throw (); extern double __drem (double __x, double __y) throw (); > > > >extern double significand (double __x) throw (); extern double __significand (double __x) throw (); > > > > > >extern double copysign (double __x, double __y) throw () __attribute__ ((__const__)); extern double __copysign (double __x, double __y) throw () __attribute__ ((__const__)); > > > > > > >extern double nan (const char *__tagb) throw () __attribute__ ((__const__)); extern double __nan (const char *__tagb) throw () __attribute__ ((__const__)); > > > > > >extern int __isnan (double __value) throw () __attribute__ ((__const__)); > > > >extern int isnan (double __value) throw () __attribute__ ((__const__)); > > >extern double j0 (double) throw (); extern double __j0 (double) throw (); >extern double j1 (double) throw (); extern double __j1 (double) throw (); >extern double jn (int, double) throw (); extern double __jn (int, double) throw (); >extern double y0 (double) throw (); extern double __y0 (double) throw (); >extern double y1 (double) throw (); extern double __y1 (double) throw (); >extern double yn (int, double) throw (); extern double __yn (int, double) throw (); > > > > > > >extern double erf (double) throw (); extern double __erf (double) throw (); >extern double erfc (double) throw (); extern double __erfc (double) throw (); >extern double lgamma (double) throw (); extern double __lgamma (double) throw (); > > > > > > >extern double tgamma (double) throw (); extern double __tgamma (double) throw (); > > > > > >extern double gamma (double) throw (); extern double __gamma (double) throw (); > > > > > > >extern double lgamma_r (double, int *__signgamp) throw (); extern double __lgamma_r (double, int *__signgamp) throw (); > > > > > > > >extern double rint (double __x) throw (); extern double __rint (double __x) throw (); > > >extern double nextafter (double __x, double __y) throw () __attribute__ ((__const__)); extern double __nextafter (double __x, double __y) throw () __attribute__ ((__const__)); > >extern double nexttoward (double __x, long double __y) throw () __attribute__ ((__const__)); extern double __nexttoward (double __x, long double __y) throw () __attribute__ ((__const__)); > > > >extern double remainder (double __x, double __y) throw (); extern double __remainder (double __x, double __y) throw (); > > > >extern double scalbn (double __x, int __n) throw (); extern double __scalbn (double __x, int __n) throw (); > > > >extern int ilogb (double __x) throw (); extern int __ilogb (double __x) throw (); > > > > >extern double scalbln (double __x, long int __n) throw (); extern double __scalbln (double __x, long int __n) throw (); > > > >extern double nearbyint (double __x) throw (); extern double __nearbyint (double __x) throw (); > > > >extern double round (double __x) throw () __attribute__ ((__const__)); extern double __round (double __x) throw () __attribute__ ((__const__)); > > > >extern double trunc (double __x) throw () __attribute__ ((__const__)); extern double __trunc (double __x) throw () __attribute__ ((__const__)); > > > > >extern double remquo (double __x, double __y, int *__quo) throw (); extern double __remquo (double __x, double __y, int *__quo) throw (); > > > > > > >extern long int lrint (double __x) throw (); extern long int __lrint (double __x) throw (); >__extension__ >extern long long int llrint (double __x) throw (); extern long long int __llrint (double __x) throw (); > > > >extern long int lround (double __x) throw (); extern long int __lround (double __x) throw (); >__extension__ >extern long long int llround (double __x) throw (); extern long long int __llround (double __x) throw (); > > > >extern double fdim (double __x, double __y) throw (); extern double __fdim (double __x, double __y) throw (); > > >extern double fmax (double __x, double __y) throw () __attribute__ ((__const__)); extern double __fmax (double __x, double __y) throw () __attribute__ ((__const__)); > > >extern double fmin (double __x, double __y) throw () __attribute__ ((__const__)); extern double __fmin (double __x, double __y) throw () __attribute__ ((__const__)); > > > >extern int __fpclassify (double __value) throw () > __attribute__ ((__const__)); > > >extern int __signbit (double __value) throw () > __attribute__ ((__const__)); > > > >extern double fma (double __x, double __y, double __z) throw (); extern double __fma (double __x, double __y, double __z) throw (); ># 365 "/usr/include/bits/mathcalls.h" 3 4 >extern int __issignaling (double __value) throw () > __attribute__ ((__const__)); > > > > >extern double scalb (double __x, double __n) throw (); extern double __scalb (double __x, double __n) throw (); ># 70 "/usr/include/math.h" 2 3 4 ># 88 "/usr/include/math.h" 3 4 ># 1 "/usr/include/bits/mathcalls.h" 1 3 4 ># 52 "/usr/include/bits/mathcalls.h" 3 4 > > >extern float acosf (float __x) throw (); extern float __acosf (float __x) throw (); > >extern float asinf (float __x) throw (); extern float __asinf (float __x) throw (); > >extern float atanf (float __x) throw (); extern float __atanf (float __x) throw (); > >extern float atan2f (float __y, float __x) throw (); extern float __atan2f (float __y, float __x) throw (); > > >extern float cosf (float __x) throw (); extern float __cosf (float __x) throw (); > >extern float sinf (float __x) throw (); extern float __sinf (float __x) throw (); > >extern float tanf (float __x) throw (); extern float __tanf (float __x) throw (); > > > > >extern float coshf (float __x) throw (); extern float __coshf (float __x) throw (); > >extern float sinhf (float __x) throw (); extern float __sinhf (float __x) throw (); > >extern float tanhf (float __x) throw (); extern float __tanhf (float __x) throw (); > > > > >extern void sincosf (float __x, float *__sinx, float *__cosx) throw (); extern void __sincosf (float __x, float *__sinx, float *__cosx) throw () > ; > > > > > >extern float acoshf (float __x) throw (); extern float __acoshf (float __x) throw (); > >extern float asinhf (float __x) throw (); extern float __asinhf (float __x) throw (); > >extern float atanhf (float __x) throw (); extern float __atanhf (float __x) throw (); > > > > > > > >extern float expf (float __x) throw (); extern float __expf (float __x) throw (); > > >extern float frexpf (float __x, int *__exponent) throw (); extern float __frexpf (float __x, int *__exponent) throw (); > > >extern float ldexpf (float __x, int __exponent) throw (); extern float __ldexpf (float __x, int __exponent) throw (); > > >extern float logf (float __x) throw (); extern float __logf (float __x) throw (); > > >extern float log10f (float __x) throw (); extern float __log10f (float __x) throw (); > > >extern float modff (float __x, float *__iptr) throw (); extern float __modff (float __x, float *__iptr) throw () __attribute__ ((__nonnull__ (2))); > > > > >extern float exp10f (float __x) throw (); extern float __exp10f (float __x) throw (); > >extern float pow10f (float __x) throw (); extern float __pow10f (float __x) throw (); > > > > > >extern float expm1f (float __x) throw (); extern float __expm1f (float __x) throw (); > > >extern float log1pf (float __x) throw (); extern float __log1pf (float __x) throw (); > > >extern float logbf (float __x) throw (); extern float __logbf (float __x) throw (); > > > > > > >extern float exp2f (float __x) throw (); extern float __exp2f (float __x) throw (); > > >extern float log2f (float __x) throw (); extern float __log2f (float __x) throw (); ># 153 "/usr/include/bits/mathcalls.h" 3 4 >extern float powf (float __x, float __y) throw (); extern float __powf (float __x, float __y) throw (); > > >extern float sqrtf (float __x) throw (); extern float __sqrtf (float __x) throw (); > > > > > >extern float hypotf (float __x, float __y) throw (); extern float __hypotf (float __x, float __y) throw (); > > > > > > >extern float cbrtf (float __x) throw (); extern float __cbrtf (float __x) throw (); ># 178 "/usr/include/bits/mathcalls.h" 3 4 >extern float ceilf (float __x) throw () __attribute__ ((__const__)); extern float __ceilf (float __x) throw () __attribute__ ((__const__)); > > >extern float fabsf (float __x) throw () __attribute__ ((__const__)); extern float __fabsf (float __x) throw () __attribute__ ((__const__)); > > >extern float floorf (float __x) throw () __attribute__ ((__const__)); extern float __floorf (float __x) throw () __attribute__ ((__const__)); > > >extern float fmodf (float __x, float __y) throw (); extern float __fmodf (float __x, float __y) throw (); > > > > >extern int __isinff (float __value) throw () __attribute__ ((__const__)); > > >extern int __finitef (float __value) throw () __attribute__ ((__const__)); > > > > > >extern int isinff (float __value) throw () __attribute__ ((__const__)); > > >extern int finitef (float __value) throw () __attribute__ ((__const__)); > > >extern float dremf (float __x, float __y) throw (); extern float __dremf (float __x, float __y) throw (); > > > >extern float significandf (float __x) throw (); extern float __significandf (float __x) throw (); > > > > > >extern float copysignf (float __x, float __y) throw () __attribute__ ((__const__)); extern float __copysignf (float __x, float __y) throw () __attribute__ ((__const__)); > > > > > > >extern float nanf (const char *__tagb) throw () __attribute__ ((__const__)); extern float __nanf (const char *__tagb) throw () __attribute__ ((__const__)); > > > > > >extern int __isnanf (float __value) throw () __attribute__ ((__const__)); > > > >extern int isnanf (float __value) throw () __attribute__ ((__const__)); > > >extern float j0f (float) throw (); extern float __j0f (float) throw (); >extern float j1f (float) throw (); extern float __j1f (float) throw (); >extern float jnf (int, float) throw (); extern float __jnf (int, float) throw (); >extern float y0f (float) throw (); extern float __y0f (float) throw (); >extern float y1f (float) throw (); extern float __y1f (float) throw (); >extern float ynf (int, float) throw (); extern float __ynf (int, float) throw (); > > > > > > >extern float erff (float) throw (); extern float __erff (float) throw (); >extern float erfcf (float) throw (); extern float __erfcf (float) throw (); >extern float lgammaf (float) throw (); extern float __lgammaf (float) throw (); > > > > > > >extern float tgammaf (float) throw (); extern float __tgammaf (float) throw (); > > > > > >extern float gammaf (float) throw (); extern float __gammaf (float) throw (); > > > > > > >extern float lgammaf_r (float, int *__signgamp) throw (); extern float __lgammaf_r (float, int *__signgamp) throw (); > > > > > > > >extern float rintf (float __x) throw (); extern float __rintf (float __x) throw (); > > >extern float nextafterf (float __x, float __y) throw () __attribute__ ((__const__)); extern float __nextafterf (float __x, float __y) throw () __attribute__ ((__const__)); > >extern float nexttowardf (float __x, long double __y) throw () __attribute__ ((__const__)); extern float __nexttowardf (float __x, long double __y) throw () __attribute__ ((__const__)); > > > >extern float remainderf (float __x, float __y) throw (); extern float __remainderf (float __x, float __y) throw (); > > > >extern float scalbnf (float __x, int __n) throw (); extern float __scalbnf (float __x, int __n) throw (); > > > >extern int ilogbf (float __x) throw (); extern int __ilogbf (float __x) throw (); > > > > >extern float scalblnf (float __x, long int __n) throw (); extern float __scalblnf (float __x, long int __n) throw (); > > > >extern float nearbyintf (float __x) throw (); extern float __nearbyintf (float __x) throw (); > > > >extern float roundf (float __x) throw () __attribute__ ((__const__)); extern float __roundf (float __x) throw () __attribute__ ((__const__)); > > > >extern float truncf (float __x) throw () __attribute__ ((__const__)); extern float __truncf (float __x) throw () __attribute__ ((__const__)); > > > > >extern float remquof (float __x, float __y, int *__quo) throw (); extern float __remquof (float __x, float __y, int *__quo) throw (); > > > > > > >extern long int lrintf (float __x) throw (); extern long int __lrintf (float __x) throw (); >__extension__ >extern long long int llrintf (float __x) throw (); extern long long int __llrintf (float __x) throw (); > > > >extern long int lroundf (float __x) throw (); extern long int __lroundf (float __x) throw (); >__extension__ >extern long long int llroundf (float __x) throw (); extern long long int __llroundf (float __x) throw (); > > > >extern float fdimf (float __x, float __y) throw (); extern float __fdimf (float __x, float __y) throw (); > > >extern float fmaxf (float __x, float __y) throw () __attribute__ ((__const__)); extern float __fmaxf (float __x, float __y) throw () __attribute__ ((__const__)); > > >extern float fminf (float __x, float __y) throw () __attribute__ ((__const__)); extern float __fminf (float __x, float __y) throw () __attribute__ ((__const__)); > > > >extern int __fpclassifyf (float __value) throw () > __attribute__ ((__const__)); > > >extern int __signbitf (float __value) throw () > __attribute__ ((__const__)); > > > >extern float fmaf (float __x, float __y, float __z) throw (); extern float __fmaf (float __x, float __y, float __z) throw (); ># 365 "/usr/include/bits/mathcalls.h" 3 4 >extern int __issignalingf (float __value) throw () > __attribute__ ((__const__)); > > > > >extern float scalbf (float __x, float __n) throw (); extern float __scalbf (float __x, float __n) throw (); ># 89 "/usr/include/math.h" 2 3 4 ># 132 "/usr/include/math.h" 3 4 ># 1 "/usr/include/bits/mathcalls.h" 1 3 4 ># 52 "/usr/include/bits/mathcalls.h" 3 4 > > >extern long double acosl (long double __x) throw (); extern long double __acosl (long double __x) throw (); > >extern long double asinl (long double __x) throw (); extern long double __asinl (long double __x) throw (); > >extern long double atanl (long double __x) throw (); extern long double __atanl (long double __x) throw (); > >extern long double atan2l (long double __y, long double __x) throw (); extern long double __atan2l (long double __y, long double __x) throw (); > > >extern long double cosl (long double __x) throw (); extern long double __cosl (long double __x) throw (); > >extern long double sinl (long double __x) throw (); extern long double __sinl (long double __x) throw (); > >extern long double tanl (long double __x) throw (); extern long double __tanl (long double __x) throw (); > > > > >extern long double coshl (long double __x) throw (); extern long double __coshl (long double __x) throw (); > >extern long double sinhl (long double __x) throw (); extern long double __sinhl (long double __x) throw (); > >extern long double tanhl (long double __x) throw (); extern long double __tanhl (long double __x) throw (); > > > > >extern void sincosl (long double __x, long double *__sinx, long double *__cosx) throw (); extern void __sincosl (long double __x, long double *__sinx, long double *__cosx) throw () > ; > > > > > >extern long double acoshl (long double __x) throw (); extern long double __acoshl (long double __x) throw (); > >extern long double asinhl (long double __x) throw (); extern long double __asinhl (long double __x) throw (); > >extern long double atanhl (long double __x) throw (); extern long double __atanhl (long double __x) throw (); > > > > > > > >extern long double expl (long double __x) throw (); extern long double __expl (long double __x) throw (); > > >extern long double frexpl (long double __x, int *__exponent) throw (); extern long double __frexpl (long double __x, int *__exponent) throw (); > > >extern long double ldexpl (long double __x, int __exponent) throw (); extern long double __ldexpl (long double __x, int __exponent) throw (); > > >extern long double logl (long double __x) throw (); extern long double __logl (long double __x) throw (); > > >extern long double log10l (long double __x) throw (); extern long double __log10l (long double __x) throw (); > > >extern long double modfl (long double __x, long double *__iptr) throw (); extern long double __modfl (long double __x, long double *__iptr) throw () __attribute__ ((__nonnull__ (2))); > > > > >extern long double exp10l (long double __x) throw (); extern long double __exp10l (long double __x) throw (); > >extern long double pow10l (long double __x) throw (); extern long double __pow10l (long double __x) throw (); > > > > > >extern long double expm1l (long double __x) throw (); extern long double __expm1l (long double __x) throw (); > > >extern long double log1pl (long double __x) throw (); extern long double __log1pl (long double __x) throw (); > > >extern long double logbl (long double __x) throw (); extern long double __logbl (long double __x) throw (); > > > > > > >extern long double exp2l (long double __x) throw (); extern long double __exp2l (long double __x) throw (); > > >extern long double log2l (long double __x) throw (); extern long double __log2l (long double __x) throw (); ># 153 "/usr/include/bits/mathcalls.h" 3 4 >extern long double powl (long double __x, long double __y) throw (); extern long double __powl (long double __x, long double __y) throw (); > > >extern long double sqrtl (long double __x) throw (); extern long double __sqrtl (long double __x) throw (); > > > > > >extern long double hypotl (long double __x, long double __y) throw (); extern long double __hypotl (long double __x, long double __y) throw (); > > > > > > >extern long double cbrtl (long double __x) throw (); extern long double __cbrtl (long double __x) throw (); ># 178 "/usr/include/bits/mathcalls.h" 3 4 >extern long double ceill (long double __x) throw () __attribute__ ((__const__)); extern long double __ceill (long double __x) throw () __attribute__ ((__const__)); > > >extern long double fabsl (long double __x) throw () __attribute__ ((__const__)); extern long double __fabsl (long double __x) throw () __attribute__ ((__const__)); > > >extern long double floorl (long double __x) throw () __attribute__ ((__const__)); extern long double __floorl (long double __x) throw () __attribute__ ((__const__)); > > >extern long double fmodl (long double __x, long double __y) throw (); extern long double __fmodl (long double __x, long double __y) throw (); > > > > >extern int __isinfl (long double __value) throw () __attribute__ ((__const__)); > > >extern int __finitel (long double __value) throw () __attribute__ ((__const__)); > > > > > >extern int isinfl (long double __value) throw () __attribute__ ((__const__)); > > >extern int finitel (long double __value) throw () __attribute__ ((__const__)); > > >extern long double dreml (long double __x, long double __y) throw (); extern long double __dreml (long double __x, long double __y) throw (); > > > >extern long double significandl (long double __x) throw (); extern long double __significandl (long double __x) throw (); > > > > > >extern long double copysignl (long double __x, long double __y) throw () __attribute__ ((__const__)); extern long double __copysignl (long double __x, long double __y) throw () __attribute__ ((__const__)); > > > > > > >extern long double nanl (const char *__tagb) throw () __attribute__ ((__const__)); extern long double __nanl (const char *__tagb) throw () __attribute__ ((__const__)); > > > > > >extern int __isnanl (long double __value) throw () __attribute__ ((__const__)); > > > >extern int isnanl (long double __value) throw () __attribute__ ((__const__)); > > >extern long double j0l (long double) throw (); extern long double __j0l (long double) throw (); >extern long double j1l (long double) throw (); extern long double __j1l (long double) throw (); >extern long double jnl (int, long double) throw (); extern long double __jnl (int, long double) throw (); >extern long double y0l (long double) throw (); extern long double __y0l (long double) throw (); >extern long double y1l (long double) throw (); extern long double __y1l (long double) throw (); >extern long double ynl (int, long double) throw (); extern long double __ynl (int, long double) throw (); > > > > > > >extern long double erfl (long double) throw (); extern long double __erfl (long double) throw (); >extern long double erfcl (long double) throw (); extern long double __erfcl (long double) throw (); >extern long double lgammal (long double) throw (); extern long double __lgammal (long double) throw (); > > > > > > >extern long double tgammal (long double) throw (); extern long double __tgammal (long double) throw (); > > > > > >extern long double gammal (long double) throw (); extern long double __gammal (long double) throw (); > > > > > > >extern long double lgammal_r (long double, int *__signgamp) throw (); extern long double __lgammal_r (long double, int *__signgamp) throw (); > > > > > > > >extern long double rintl (long double __x) throw (); extern long double __rintl (long double __x) throw (); > > >extern long double nextafterl (long double __x, long double __y) throw () __attribute__ ((__const__)); extern long double __nextafterl (long double __x, long double __y) throw () __attribute__ ((__const__)); > >extern long double nexttowardl (long double __x, long double __y) throw () __attribute__ ((__const__)); extern long double __nexttowardl (long double __x, long double __y) throw () __attribute__ ((__const__)); > > > >extern long double remainderl (long double __x, long double __y) throw (); extern long double __remainderl (long double __x, long double __y) throw (); > > > >extern long double scalbnl (long double __x, int __n) throw (); extern long double __scalbnl (long double __x, int __n) throw (); > > > >extern int ilogbl (long double __x) throw (); extern int __ilogbl (long double __x) throw (); > > > > >extern long double scalblnl (long double __x, long int __n) throw (); extern long double __scalblnl (long double __x, long int __n) throw (); > > > >extern long double nearbyintl (long double __x) throw (); extern long double __nearbyintl (long double __x) throw (); > > > >extern long double roundl (long double __x) throw () __attribute__ ((__const__)); extern long double __roundl (long double __x) throw () __attribute__ ((__const__)); > > > >extern long double truncl (long double __x) throw () __attribute__ ((__const__)); extern long double __truncl (long double __x) throw () __attribute__ ((__const__)); > > > > >extern long double remquol (long double __x, long double __y, int *__quo) throw (); extern long double __remquol (long double __x, long double __y, int *__quo) throw (); > > > > > > >extern long int lrintl (long double __x) throw (); extern long int __lrintl (long double __x) throw (); >__extension__ >extern long long int llrintl (long double __x) throw (); extern long long int __llrintl (long double __x) throw (); > > > >extern long int lroundl (long double __x) throw (); extern long int __lroundl (long double __x) throw (); >__extension__ >extern long long int llroundl (long double __x) throw (); extern long long int __llroundl (long double __x) throw (); > > > >extern long double fdiml (long double __x, long double __y) throw (); extern long double __fdiml (long double __x, long double __y) throw (); > > >extern long double fmaxl (long double __x, long double __y) throw () __attribute__ ((__const__)); extern long double __fmaxl (long double __x, long double __y) throw () __attribute__ ((__const__)); > > >extern long double fminl (long double __x, long double __y) throw () __attribute__ ((__const__)); extern long double __fminl (long double __x, long double __y) throw () __attribute__ ((__const__)); > > > >extern int __fpclassifyl (long double __value) throw () > __attribute__ ((__const__)); > > >extern int __signbitl (long double __value) throw () > __attribute__ ((__const__)); > > > >extern long double fmal (long double __x, long double __y, long double __z) throw (); extern long double __fmal (long double __x, long double __y, long double __z) throw (); ># 365 "/usr/include/bits/mathcalls.h" 3 4 >extern int __issignalingl (long double __value) throw () > __attribute__ ((__const__)); > > > > >extern long double scalbl (long double __x, long double __n) throw (); extern long double __scalbl (long double __x, long double __n) throw (); ># 133 "/usr/include/math.h" 2 3 4 ># 148 "/usr/include/math.h" 3 4 >extern int signgam; ># 189 "/usr/include/math.h" 3 4 >enum > { > FP_NAN = > > 0, > FP_INFINITE = > > 1, > FP_ZERO = > > 2, > FP_SUBNORMAL = > > 3, > FP_NORMAL = > > 4 > }; ># 301 "/usr/include/math.h" 3 4 >typedef enum >{ > _IEEE_ = -1, > _SVID_, > _XOPEN_, > _POSIX_, > _ISOC_ >} _LIB_VERSION_TYPE; > > > > >extern _LIB_VERSION_TYPE _LIB_VERSION; ># 324 "/usr/include/math.h" 3 4 >struct __exception > > > > { > int type; > char *name; > double arg1; > double arg2; > double retval; > }; > > >extern int matherr (struct __exception *__exc) throw (); ># 426 "/usr/include/math.h" 3 4 ># 1 "/usr/include/bits/mathinline.h" 1 3 4 ># 123 "/usr/include/bits/mathinline.h" 3 4 > > > >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) __signbitf (float __x) throw () >{ > > int __m; > __asm ("pmovmskb %1, %0" : "=r" (__m) : "x" (__x)); > return (__m & 0x8) != 0; > > > > >} >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) __signbit (double __x) throw () >{ > > int __m; > __asm ("pmovmskb %1, %0" : "=r" (__m) : "x" (__x)); > return (__m & 0x80) != 0; > > > > >} >extern __inline __attribute__ ((__always_inline__)) __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) __signbitl (long double __x) throw () >{ > __extension__ union { long double __l; int __i[3]; } __u = { __l: __x }; > return (__u.__i[2] & 0x8000) != 0; >} ># 427 "/usr/include/math.h" 2 3 4 ># 488 "/usr/include/math.h" 3 4 >} ># 45 "/usr/include/c++/4.9.0/cmath" 2 3 ># 75 "/usr/include/c++/4.9.0/cmath" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > inline constexpr double > abs(double __x) > { return __builtin_fabs(__x); } > > > > inline constexpr float > abs(float __x) > { return __builtin_fabsf(__x); } > > inline constexpr long double > abs(long double __x) > { return __builtin_fabsl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > abs(_Tp __x) > { return __builtin_fabs(__x); } > > using ::acos; > > > inline constexpr float > acos(float __x) > { return __builtin_acosf(__x); } > > inline constexpr long double > acos(long double __x) > { return __builtin_acosl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > acos(_Tp __x) > { return __builtin_acos(__x); } > > using ::asin; > > > inline constexpr float > asin(float __x) > { return __builtin_asinf(__x); } > > inline constexpr long double > asin(long double __x) > { return __builtin_asinl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > asin(_Tp __x) > { return __builtin_asin(__x); } > > using ::atan; > > > inline constexpr float > atan(float __x) > { return __builtin_atanf(__x); } > > inline constexpr long double > atan(long double __x) > { return __builtin_atanl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > atan(_Tp __x) > { return __builtin_atan(__x); } > > using ::atan2; > > > inline constexpr float > atan2(float __y, float __x) > { return __builtin_atan2f(__y, __x); } > > inline constexpr long double > atan2(long double __y, long double __x) > { return __builtin_atan2l(__y, __x); } > > > template<typename _Tp, typename _Up> > inline constexpr > typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > atan2(_Tp __y, _Up __x) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return atan2(__type(__y), __type(__x)); > } > > using ::ceil; > > > inline constexpr float > ceil(float __x) > { return __builtin_ceilf(__x); } > > inline constexpr long double > ceil(long double __x) > { return __builtin_ceill(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > ceil(_Tp __x) > { return __builtin_ceil(__x); } > > using ::cos; > > > inline constexpr float > cos(float __x) > { return __builtin_cosf(__x); } > > inline constexpr long double > cos(long double __x) > { return __builtin_cosl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > cos(_Tp __x) > { return __builtin_cos(__x); } > > using ::cosh; > > > inline constexpr float > cosh(float __x) > { return __builtin_coshf(__x); } > > inline constexpr long double > cosh(long double __x) > { return __builtin_coshl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > cosh(_Tp __x) > { return __builtin_cosh(__x); } > > using ::exp; > > > inline constexpr float > exp(float __x) > { return __builtin_expf(__x); } > > inline constexpr long double > exp(long double __x) > { return __builtin_expl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > exp(_Tp __x) > { return __builtin_exp(__x); } > > using ::fabs; > > > inline constexpr float > fabs(float __x) > { return __builtin_fabsf(__x); } > > inline constexpr long double > fabs(long double __x) > { return __builtin_fabsl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > fabs(_Tp __x) > { return __builtin_fabs(__x); } > > using ::floor; > > > inline constexpr float > floor(float __x) > { return __builtin_floorf(__x); } > > inline constexpr long double > floor(long double __x) > { return __builtin_floorl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > floor(_Tp __x) > { return __builtin_floor(__x); } > > using ::fmod; > > > inline constexpr float > fmod(float __x, float __y) > { return __builtin_fmodf(__x, __y); } > > inline constexpr long double > fmod(long double __x, long double __y) > { return __builtin_fmodl(__x, __y); } > > > template<typename _Tp, typename _Up> > inline constexpr > typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > fmod(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return fmod(__type(__x), __type(__y)); > } > > using ::frexp; > > > inline float > frexp(float __x, int* __exp) > { return __builtin_frexpf(__x, __exp); } > > inline long double > frexp(long double __x, int* __exp) > { return __builtin_frexpl(__x, __exp); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > frexp(_Tp __x, int* __exp) > { return __builtin_frexp(__x, __exp); } > > using ::ldexp; > > > inline constexpr float > ldexp(float __x, int __exp) > { return __builtin_ldexpf(__x, __exp); } > > inline constexpr long double > ldexp(long double __x, int __exp) > { return __builtin_ldexpl(__x, __exp); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > ldexp(_Tp __x, int __exp) > { return __builtin_ldexp(__x, __exp); } > > using ::log; > > > inline constexpr float > log(float __x) > { return __builtin_logf(__x); } > > inline constexpr long double > log(long double __x) > { return __builtin_logl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > log(_Tp __x) > { return __builtin_log(__x); } > > using ::log10; > > > inline constexpr float > log10(float __x) > { return __builtin_log10f(__x); } > > inline constexpr long double > log10(long double __x) > { return __builtin_log10l(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > log10(_Tp __x) > { return __builtin_log10(__x); } > > using ::modf; > > > inline float > modf(float __x, float* __iptr) > { return __builtin_modff(__x, __iptr); } > > inline long double > modf(long double __x, long double* __iptr) > { return __builtin_modfl(__x, __iptr); } > > > using ::pow; > > > inline constexpr float > pow(float __x, float __y) > { return __builtin_powf(__x, __y); } > > inline constexpr long double > pow(long double __x, long double __y) > { return __builtin_powl(__x, __y); } ># 431 "/usr/include/c++/4.9.0/cmath" 3 > template<typename _Tp, typename _Up> > inline constexpr > typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > pow(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return pow(__type(__x), __type(__y)); > } > > using ::sin; > > > inline constexpr float > sin(float __x) > { return __builtin_sinf(__x); } > > inline constexpr long double > sin(long double __x) > { return __builtin_sinl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > sin(_Tp __x) > { return __builtin_sin(__x); } > > using ::sinh; > > > inline constexpr float > sinh(float __x) > { return __builtin_sinhf(__x); } > > inline constexpr long double > sinh(long double __x) > { return __builtin_sinhl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > sinh(_Tp __x) > { return __builtin_sinh(__x); } > > using ::sqrt; > > > inline constexpr float > sqrt(float __x) > { return __builtin_sqrtf(__x); } > > inline constexpr long double > sqrt(long double __x) > { return __builtin_sqrtl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > sqrt(_Tp __x) > { return __builtin_sqrt(__x); } > > using ::tan; > > > inline constexpr float > tan(float __x) > { return __builtin_tanf(__x); } > > inline constexpr long double > tan(long double __x) > { return __builtin_tanl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > tan(_Tp __x) > { return __builtin_tan(__x); } > > using ::tanh; > > > inline constexpr float > tanh(float __x) > { return __builtin_tanhf(__x); } > > inline constexpr long double > tanh(long double __x) > { return __builtin_tanhl(__x); } > > > template<typename _Tp> > inline constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > tanh(_Tp __x) > { return __builtin_tanh(__x); } > > >} ># 555 "/usr/include/c++/4.9.0/cmath" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > constexpr int > fpclassify(float __x) > { return __builtin_fpclassify(0, 1, 4, > 3, 2, __x); } > > constexpr int > fpclassify(double __x) > { return __builtin_fpclassify(0, 1, 4, > 3, 2, __x); } > > constexpr int > fpclassify(long double __x) > { return __builtin_fpclassify(0, 1, 4, > 3, 2, __x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > int>::__type > fpclassify(_Tp __x) > { return __x != 0 ? 4 : 2; } > > constexpr bool > isfinite(float __x) > { return __builtin_isfinite(__x); } > > constexpr bool > isfinite(double __x) > { return __builtin_isfinite(__x); } > > constexpr bool > isfinite(long double __x) > { return __builtin_isfinite(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > bool>::__type > isfinite(_Tp __x) > { return true; } > > constexpr bool > isinf(float __x) > { return __builtin_isinf(__x); } > > constexpr bool > isinf(double __x) > { return __builtin_isinf(__x); } > > constexpr bool > isinf(long double __x) > { return __builtin_isinf(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > bool>::__type > isinf(_Tp __x) > { return false; } > > constexpr bool > isnan(float __x) > { return __builtin_isnan(__x); } > > constexpr bool > isnan(double __x) > { return __builtin_isnan(__x); } > > constexpr bool > isnan(long double __x) > { return __builtin_isnan(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > bool>::__type > isnan(_Tp __x) > { return false; } > > constexpr bool > isnormal(float __x) > { return __builtin_isnormal(__x); } > > constexpr bool > isnormal(double __x) > { return __builtin_isnormal(__x); } > > constexpr bool > isnormal(long double __x) > { return __builtin_isnormal(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > bool>::__type > isnormal(_Tp __x) > { return __x != 0 ? true : false; } > > > constexpr bool > signbit(float __x) > { return __builtin_signbitf(__x); } > > constexpr bool > signbit(double __x) > { return __builtin_signbit(__x); } > > constexpr bool > signbit(long double __x) > { return __builtin_signbitl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > bool>::__type > signbit(_Tp __x) > { return __x < 0 ? true : false; } > > constexpr bool > isgreater(float __x, float __y) > { return __builtin_isgreater(__x, __y); } > > constexpr bool > isgreater(double __x, double __y) > { return __builtin_isgreater(__x, __y); } > > constexpr bool > isgreater(long double __x, long double __y) > { return __builtin_isgreater(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename > __gnu_cxx::__enable_if<(__is_arithmetic<_Tp>::__value > && __is_arithmetic<_Up>::__value), bool>::__type > isgreater(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return __builtin_isgreater(__type(__x), __type(__y)); > } > > constexpr bool > isgreaterequal(float __x, float __y) > { return __builtin_isgreaterequal(__x, __y); } > > constexpr bool > isgreaterequal(double __x, double __y) > { return __builtin_isgreaterequal(__x, __y); } > > constexpr bool > isgreaterequal(long double __x, long double __y) > { return __builtin_isgreaterequal(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename > __gnu_cxx::__enable_if<(__is_arithmetic<_Tp>::__value > && __is_arithmetic<_Up>::__value), bool>::__type > isgreaterequal(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return __builtin_isgreaterequal(__type(__x), __type(__y)); > } > > constexpr bool > isless(float __x, float __y) > { return __builtin_isless(__x, __y); } > > constexpr bool > isless(double __x, double __y) > { return __builtin_isless(__x, __y); } > > constexpr bool > isless(long double __x, long double __y) > { return __builtin_isless(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename > __gnu_cxx::__enable_if<(__is_arithmetic<_Tp>::__value > && __is_arithmetic<_Up>::__value), bool>::__type > isless(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return __builtin_isless(__type(__x), __type(__y)); > } > > constexpr bool > islessequal(float __x, float __y) > { return __builtin_islessequal(__x, __y); } > > constexpr bool > islessequal(double __x, double __y) > { return __builtin_islessequal(__x, __y); } > > constexpr bool > islessequal(long double __x, long double __y) > { return __builtin_islessequal(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename > __gnu_cxx::__enable_if<(__is_arithmetic<_Tp>::__value > && __is_arithmetic<_Up>::__value), bool>::__type > islessequal(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return __builtin_islessequal(__type(__x), __type(__y)); > } > > constexpr bool > islessgreater(float __x, float __y) > { return __builtin_islessgreater(__x, __y); } > > constexpr bool > islessgreater(double __x, double __y) > { return __builtin_islessgreater(__x, __y); } > > constexpr bool > islessgreater(long double __x, long double __y) > { return __builtin_islessgreater(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename > __gnu_cxx::__enable_if<(__is_arithmetic<_Tp>::__value > && __is_arithmetic<_Up>::__value), bool>::__type > islessgreater(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return __builtin_islessgreater(__type(__x), __type(__y)); > } > > constexpr bool > isunordered(float __x, float __y) > { return __builtin_isunordered(__x, __y); } > > constexpr bool > isunordered(double __x, double __y) > { return __builtin_isunordered(__x, __y); } > > constexpr bool > isunordered(long double __x, long double __y) > { return __builtin_isunordered(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename > __gnu_cxx::__enable_if<(__is_arithmetic<_Tp>::__value > && __is_arithmetic<_Up>::__value), bool>::__type > isunordered(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return __builtin_isunordered(__type(__x), __type(__y)); > } ># 917 "/usr/include/c++/4.9.0/cmath" 3 > >} ># 1033 "/usr/include/c++/4.9.0/cmath" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > using ::double_t; > using ::float_t; > > > using ::acosh; > using ::acoshf; > using ::acoshl; > > using ::asinh; > using ::asinhf; > using ::asinhl; > > using ::atanh; > using ::atanhf; > using ::atanhl; > > using ::cbrt; > using ::cbrtf; > using ::cbrtl; > > using ::copysign; > using ::copysignf; > using ::copysignl; > > using ::erf; > using ::erff; > using ::erfl; > > using ::erfc; > using ::erfcf; > using ::erfcl; > > using ::exp2; > using ::exp2f; > using ::exp2l; > > using ::expm1; > using ::expm1f; > using ::expm1l; > > using ::fdim; > using ::fdimf; > using ::fdiml; > > using ::fma; > using ::fmaf; > using ::fmal; > > using ::fmax; > using ::fmaxf; > using ::fmaxl; > > using ::fmin; > using ::fminf; > using ::fminl; > > using ::hypot; > using ::hypotf; > using ::hypotl; > > using ::ilogb; > using ::ilogbf; > using ::ilogbl; > > using ::lgamma; > using ::lgammaf; > using ::lgammal; > > using ::llrint; > using ::llrintf; > using ::llrintl; > > using ::llround; > using ::llroundf; > using ::llroundl; > > using ::log1p; > using ::log1pf; > using ::log1pl; > > using ::log2; > using ::log2f; > using ::log2l; > > using ::logb; > using ::logbf; > using ::logbl; > > using ::lrint; > using ::lrintf; > using ::lrintl; > > using ::lround; > using ::lroundf; > using ::lroundl; > > using ::nan; > using ::nanf; > using ::nanl; > > using ::nearbyint; > using ::nearbyintf; > using ::nearbyintl; > > using ::nextafter; > using ::nextafterf; > using ::nextafterl; > > using ::nexttoward; > using ::nexttowardf; > using ::nexttowardl; > > using ::remainder; > using ::remainderf; > using ::remainderl; > > using ::remquo; > using ::remquof; > using ::remquol; > > using ::rint; > using ::rintf; > using ::rintl; > > using ::round; > using ::roundf; > using ::roundl; > > using ::scalbln; > using ::scalblnf; > using ::scalblnl; > > using ::scalbn; > using ::scalbnf; > using ::scalbnl; > > using ::tgamma; > using ::tgammaf; > using ::tgammal; > > using ::trunc; > using ::truncf; > using ::truncl; > > > constexpr float > acosh(float __x) > { return __builtin_acoshf(__x); } > > constexpr long double > acosh(long double __x) > { return __builtin_acoshl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > acosh(_Tp __x) > { return __builtin_acosh(__x); } > > constexpr float > asinh(float __x) > { return __builtin_asinhf(__x); } > > constexpr long double > asinh(long double __x) > { return __builtin_asinhl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > asinh(_Tp __x) > { return __builtin_asinh(__x); } > > constexpr float > atanh(float __x) > { return __builtin_atanhf(__x); } > > constexpr long double > atanh(long double __x) > { return __builtin_atanhl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > atanh(_Tp __x) > { return __builtin_atanh(__x); } > > constexpr float > cbrt(float __x) > { return __builtin_cbrtf(__x); } > > constexpr long double > cbrt(long double __x) > { return __builtin_cbrtl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > cbrt(_Tp __x) > { return __builtin_cbrt(__x); } > > constexpr float > copysign(float __x, float __y) > { return __builtin_copysignf(__x, __y); } > > constexpr long double > copysign(long double __x, long double __y) > { return __builtin_copysignl(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > copysign(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return copysign(__type(__x), __type(__y)); > } > > constexpr float > erf(float __x) > { return __builtin_erff(__x); } > > constexpr long double > erf(long double __x) > { return __builtin_erfl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > erf(_Tp __x) > { return __builtin_erf(__x); } > > constexpr float > erfc(float __x) > { return __builtin_erfcf(__x); } > > constexpr long double > erfc(long double __x) > { return __builtin_erfcl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > erfc(_Tp __x) > { return __builtin_erfc(__x); } > > constexpr float > exp2(float __x) > { return __builtin_exp2f(__x); } > > constexpr long double > exp2(long double __x) > { return __builtin_exp2l(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > exp2(_Tp __x) > { return __builtin_exp2(__x); } > > constexpr float > expm1(float __x) > { return __builtin_expm1f(__x); } > > constexpr long double > expm1(long double __x) > { return __builtin_expm1l(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > expm1(_Tp __x) > { return __builtin_expm1(__x); } > > constexpr float > fdim(float __x, float __y) > { return __builtin_fdimf(__x, __y); } > > constexpr long double > fdim(long double __x, long double __y) > { return __builtin_fdiml(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > fdim(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return fdim(__type(__x), __type(__y)); > } > > constexpr float > fma(float __x, float __y, float __z) > { return __builtin_fmaf(__x, __y, __z); } > > constexpr long double > fma(long double __x, long double __y, long double __z) > { return __builtin_fmal(__x, __y, __z); } > > template<typename _Tp, typename _Up, typename _Vp> > constexpr typename __gnu_cxx::__promote_3<_Tp, _Up, _Vp>::__type > fma(_Tp __x, _Up __y, _Vp __z) > { > typedef typename __gnu_cxx::__promote_3<_Tp, _Up, _Vp>::__type __type; > return fma(__type(__x), __type(__y), __type(__z)); > } > > constexpr float > fmax(float __x, float __y) > { return __builtin_fmaxf(__x, __y); } > > constexpr long double > fmax(long double __x, long double __y) > { return __builtin_fmaxl(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > fmax(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return fmax(__type(__x), __type(__y)); > } > > constexpr float > fmin(float __x, float __y) > { return __builtin_fminf(__x, __y); } > > constexpr long double > fmin(long double __x, long double __y) > { return __builtin_fminl(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > fmin(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return fmin(__type(__x), __type(__y)); > } > > constexpr float > hypot(float __x, float __y) > { return __builtin_hypotf(__x, __y); } > > constexpr long double > hypot(long double __x, long double __y) > { return __builtin_hypotl(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > hypot(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return hypot(__type(__x), __type(__y)); > } > > constexpr int > ilogb(float __x) > { return __builtin_ilogbf(__x); } > > constexpr int > ilogb(long double __x) > { return __builtin_ilogbl(__x); } > > template<typename _Tp> > constexpr > typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > int>::__type > ilogb(_Tp __x) > { return __builtin_ilogb(__x); } > > constexpr float > lgamma(float __x) > { return __builtin_lgammaf(__x); } > > constexpr long double > lgamma(long double __x) > { return __builtin_lgammal(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > lgamma(_Tp __x) > { return __builtin_lgamma(__x); } > > constexpr long long > llrint(float __x) > { return __builtin_llrintf(__x); } > > constexpr long long > llrint(long double __x) > { return __builtin_llrintl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > long long>::__type > llrint(_Tp __x) > { return __builtin_llrint(__x); } > > constexpr long long > llround(float __x) > { return __builtin_llroundf(__x); } > > constexpr long long > llround(long double __x) > { return __builtin_llroundl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > long long>::__type > llround(_Tp __x) > { return __builtin_llround(__x); } > > constexpr float > log1p(float __x) > { return __builtin_log1pf(__x); } > > constexpr long double > log1p(long double __x) > { return __builtin_log1pl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > log1p(_Tp __x) > { return __builtin_log1p(__x); } > > > constexpr float > log2(float __x) > { return __builtin_log2f(__x); } > > constexpr long double > log2(long double __x) > { return __builtin_log2l(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > log2(_Tp __x) > { return __builtin_log2(__x); } > > constexpr float > logb(float __x) > { return __builtin_logbf(__x); } > > constexpr long double > logb(long double __x) > { return __builtin_logbl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > logb(_Tp __x) > { return __builtin_logb(__x); } > > constexpr long > lrint(float __x) > { return __builtin_lrintf(__x); } > > constexpr long > lrint(long double __x) > { return __builtin_lrintl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > long>::__type > lrint(_Tp __x) > { return __builtin_lrint(__x); } > > constexpr long > lround(float __x) > { return __builtin_lroundf(__x); } > > constexpr long > lround(long double __x) > { return __builtin_lroundl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > long>::__type > lround(_Tp __x) > { return __builtin_lround(__x); } > > constexpr float > nearbyint(float __x) > { return __builtin_nearbyintf(__x); } > > constexpr long double > nearbyint(long double __x) > { return __builtin_nearbyintl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > nearbyint(_Tp __x) > { return __builtin_nearbyint(__x); } > > constexpr float > nextafter(float __x, float __y) > { return __builtin_nextafterf(__x, __y); } > > constexpr long double > nextafter(long double __x, long double __y) > { return __builtin_nextafterl(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > nextafter(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return nextafter(__type(__x), __type(__y)); > } > > constexpr float > nexttoward(float __x, long double __y) > { return __builtin_nexttowardf(__x, __y); } > > constexpr long double > nexttoward(long double __x, long double __y) > { return __builtin_nexttowardl(__x, __y); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > nexttoward(_Tp __x, long double __y) > { return __builtin_nexttoward(__x, __y); } > > constexpr float > remainder(float __x, float __y) > { return __builtin_remainderf(__x, __y); } > > constexpr long double > remainder(long double __x, long double __y) > { return __builtin_remainderl(__x, __y); } > > template<typename _Tp, typename _Up> > constexpr typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > remainder(_Tp __x, _Up __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return remainder(__type(__x), __type(__y)); > } > > inline float > remquo(float __x, float __y, int* __pquo) > { return __builtin_remquof(__x, __y, __pquo); } > > inline long double > remquo(long double __x, long double __y, int* __pquo) > { return __builtin_remquol(__x, __y, __pquo); } > > template<typename _Tp, typename _Up> > inline typename __gnu_cxx::__promote_2<_Tp, _Up>::__type > remquo(_Tp __x, _Up __y, int* __pquo) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return remquo(__type(__x), __type(__y), __pquo); > } > > constexpr float > rint(float __x) > { return __builtin_rintf(__x); } > > constexpr long double > rint(long double __x) > { return __builtin_rintl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > rint(_Tp __x) > { return __builtin_rint(__x); } > > constexpr float > round(float __x) > { return __builtin_roundf(__x); } > > constexpr long double > round(long double __x) > { return __builtin_roundl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > round(_Tp __x) > { return __builtin_round(__x); } > > constexpr float > scalbln(float __x, long __ex) > { return __builtin_scalblnf(__x, __ex); } > > constexpr long double > scalbln(long double __x, long __ex) > { return __builtin_scalblnl(__x, __ex); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > scalbln(_Tp __x, long __ex) > { return __builtin_scalbln(__x, __ex); } > > constexpr float > scalbn(float __x, int __ex) > { return __builtin_scalbnf(__x, __ex); } > > constexpr long double > scalbn(long double __x, int __ex) > { return __builtin_scalbnl(__x, __ex); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > scalbn(_Tp __x, int __ex) > { return __builtin_scalbn(__x, __ex); } > > constexpr float > tgamma(float __x) > { return __builtin_tgammaf(__x); } > > constexpr long double > tgamma(long double __x) > { return __builtin_tgammal(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > tgamma(_Tp __x) > { return __builtin_tgamma(__x); } > > constexpr float > trunc(float __x) > { return __builtin_truncf(__x); } > > constexpr long double > trunc(long double __x) > { return __builtin_truncl(__x); } > > template<typename _Tp> > constexpr typename __gnu_cxx::__enable_if<__is_integer<_Tp>::__value, > double>::__type > trunc(_Tp __x) > { return __builtin_trunc(__x); } > > >} ># 39 "/usr/include/c++/4.9.0/random" 2 3 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 40 "/usr/include/c++/4.9.0/random" 2 3 > > ># 1 "/usr/include/c++/4.9.0/limits" 1 3 ># 40 "/usr/include/c++/4.9.0/limits" 3 ># 41 "/usr/include/c++/4.9.0/limits" 3 ># 147 "/usr/include/c++/4.9.0/limits" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > > enum float_round_style > { > round_indeterminate = -1, > round_toward_zero = 0, > round_to_nearest = 1, > round_toward_infinity = 2, > round_toward_neg_infinity = 3 > }; > > > > > > > > enum float_denorm_style > { > > denorm_indeterminate = -1, > > denorm_absent = 0, > > denorm_present = 1 > }; ># 191 "/usr/include/c++/4.9.0/limits" 3 > struct __numeric_limits_base > { > > > static constexpr bool is_specialized = false; > > > > > static constexpr int digits = 0; > > > static constexpr int digits10 = 0; > > > > > static constexpr int max_digits10 = 0; > > > > static constexpr bool is_signed = false; > > > static constexpr bool is_integer = false; > > > > > static constexpr bool is_exact = false; > > > > static constexpr int radix = 0; > > > > static constexpr int min_exponent = 0; > > > > static constexpr int min_exponent10 = 0; > > > > > static constexpr int max_exponent = 0; > > > > static constexpr int max_exponent10 = 0; > > > static constexpr bool has_infinity = false; > > > > static constexpr bool has_quiet_NaN = false; > > > > static constexpr bool has_signaling_NaN = false; > > > static constexpr float_denorm_style has_denorm = denorm_absent; > > > > static constexpr bool has_denorm_loss = false; > > > > static constexpr bool is_iec559 = false; > > > > > static constexpr bool is_bounded = false; ># 277 "/usr/include/c++/4.9.0/limits" 3 > static constexpr bool is_modulo = false; > > > static constexpr bool traps = false; > > > static constexpr bool tinyness_before = false; > > > > > static constexpr float_round_style round_style = > round_toward_zero; > }; ># 303 "/usr/include/c++/4.9.0/limits" 3 > template<typename _Tp> > struct numeric_limits : public __numeric_limits_base > { > > > static constexpr _Tp > min() noexcept { return _Tp(); } > > > static constexpr _Tp > max() noexcept { return _Tp(); } > > > > > static constexpr _Tp > lowest() noexcept { return _Tp(); } > > > > > static constexpr _Tp > epsilon() noexcept { return _Tp(); } > > > static constexpr _Tp > round_error() noexcept { return _Tp(); } > > > static constexpr _Tp > infinity() noexcept { return _Tp(); } > > > > static constexpr _Tp > quiet_NaN() noexcept { return _Tp(); } > > > > static constexpr _Tp > signaling_NaN() noexcept { return _Tp(); } > > > > > static constexpr _Tp > denorm_min() noexcept { return _Tp(); } > }; > > > template<typename _Tp> > struct numeric_limits<const _Tp> > : public numeric_limits<_Tp> { }; > > template<typename _Tp> > struct numeric_limits<volatile _Tp> > : public numeric_limits<_Tp> { }; > > template<typename _Tp> > struct numeric_limits<const volatile _Tp> > : public numeric_limits<_Tp> { }; > > > > > > > template<> > struct numeric_limits<bool> > { > static constexpr bool is_specialized = true; > > static constexpr bool > min() noexcept { return false; } > > static constexpr bool > max() noexcept { return true; } > > > static constexpr bool > lowest() noexcept { return min(); } > > static constexpr int digits = 1; > static constexpr int digits10 = 0; > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = false; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr bool > epsilon() noexcept { return false; } > > static constexpr bool > round_error() noexcept { return false; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr bool > infinity() noexcept { return false; } > > static constexpr bool > quiet_NaN() noexcept { return false; } > > static constexpr bool > signaling_NaN() noexcept { return false; } > > static constexpr bool > denorm_min() noexcept { return false; } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > > > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<char> > { > static constexpr bool is_specialized = true; > > static constexpr char > min() noexcept { return (((char)(-1) < 0) ? -(((char)(-1) < 0) ? (((((char)1 << ((sizeof(char) * 8 - ((char)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(char)0) - 1 : (char)0); } > > static constexpr char > max() noexcept { return (((char)(-1) < 0) ? (((((char)1 << ((sizeof(char) * 8 - ((char)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(char)0); } > > > static constexpr char > lowest() noexcept { return min(); } > > > static constexpr int digits = (sizeof(char) * 8 - ((char)(-1) < 0)); > static constexpr int digits10 = ((sizeof(char) * 8 - ((char)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = ((char)(-1) < 0); > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr char > epsilon() noexcept { return 0; } > > static constexpr char > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr > char infinity() noexcept { return char(); } > > static constexpr char > quiet_NaN() noexcept { return char(); } > > static constexpr char > signaling_NaN() noexcept { return char(); } > > static constexpr char > denorm_min() noexcept { return static_cast<char>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = !is_signed; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<signed char> > { > static constexpr bool is_specialized = true; > > static constexpr signed char > min() noexcept { return -127 - 1; } > > static constexpr signed char > max() noexcept { return 127; } > > > static constexpr signed char > lowest() noexcept { return min(); } > > > static constexpr int digits = (sizeof(signed char) * 8 - ((signed char)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(signed char) * 8 - ((signed char)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = true; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr signed char > epsilon() noexcept { return 0; } > > static constexpr signed char > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr signed char > infinity() noexcept { return static_cast<signed char>(0); } > > static constexpr signed char > quiet_NaN() noexcept { return static_cast<signed char>(0); } > > static constexpr signed char > signaling_NaN() noexcept > { return static_cast<signed char>(0); } > > static constexpr signed char > denorm_min() noexcept > { return static_cast<signed char>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<unsigned char> > { > static constexpr bool is_specialized = true; > > static constexpr unsigned char > min() noexcept { return 0; } > > static constexpr unsigned char > max() noexcept { return 127 * 2U + 1; } > > > static constexpr unsigned char > lowest() noexcept { return min(); } > > > static constexpr int digits > = (sizeof(unsigned char) * 8 - ((unsigned char)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(unsigned char) * 8 - ((unsigned char)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = false; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr unsigned char > epsilon() noexcept { return 0; } > > static constexpr unsigned char > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr unsigned char > infinity() noexcept > { return static_cast<unsigned char>(0); } > > static constexpr unsigned char > quiet_NaN() noexcept > { return static_cast<unsigned char>(0); } > > static constexpr unsigned char > signaling_NaN() noexcept > { return static_cast<unsigned char>(0); } > > static constexpr unsigned char > denorm_min() noexcept > { return static_cast<unsigned char>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = true; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<wchar_t> > { > static constexpr bool is_specialized = true; > > static constexpr wchar_t > min() noexcept { return (((wchar_t)(-1) < 0) ? -(((wchar_t)(-1) < 0) ? (((((wchar_t)1 << ((sizeof(wchar_t) * 8 - ((wchar_t)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(wchar_t)0) - 1 : (wchar_t)0); } > > static constexpr wchar_t > max() noexcept { return (((wchar_t)(-1) < 0) ? (((((wchar_t)1 << ((sizeof(wchar_t) * 8 - ((wchar_t)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(wchar_t)0); } > > > static constexpr wchar_t > lowest() noexcept { return min(); } > > > static constexpr int digits = (sizeof(wchar_t) * 8 - ((wchar_t)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(wchar_t) * 8 - ((wchar_t)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = ((wchar_t)(-1) < 0); > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr wchar_t > epsilon() noexcept { return 0; } > > static constexpr wchar_t > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr wchar_t > infinity() noexcept { return wchar_t(); } > > static constexpr wchar_t > quiet_NaN() noexcept { return wchar_t(); } > > static constexpr wchar_t > signaling_NaN() noexcept { return wchar_t(); } > > static constexpr wchar_t > denorm_min() noexcept { return wchar_t(); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = !is_signed; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > > template<> > struct numeric_limits<char16_t> > { > static constexpr bool is_specialized = true; > > static constexpr char16_t > min() noexcept { return (((char16_t)(-1) < 0) ? -(((char16_t)(-1) < 0) ? (((((char16_t)1 << ((sizeof(char16_t) * 8 - ((char16_t)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(char16_t)0) - 1 : (char16_t)0); } > > static constexpr char16_t > max() noexcept { return (((char16_t)(-1) < 0) ? (((((char16_t)1 << ((sizeof(char16_t) * 8 - ((char16_t)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(char16_t)0); } > > static constexpr char16_t > lowest() noexcept { return min(); } > > static constexpr int digits = (sizeof(char16_t) * 8 - ((char16_t)(-1) < 0)); > static constexpr int digits10 = ((sizeof(char16_t) * 8 - ((char16_t)(-1) < 0)) * 643L / 2136); > static constexpr int max_digits10 = 0; > static constexpr bool is_signed = ((char16_t)(-1) < 0); > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr char16_t > epsilon() noexcept { return 0; } > > static constexpr char16_t > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr char16_t > infinity() noexcept { return char16_t(); } > > static constexpr char16_t > quiet_NaN() noexcept { return char16_t(); } > > static constexpr char16_t > signaling_NaN() noexcept { return char16_t(); } > > static constexpr char16_t > denorm_min() noexcept { return char16_t(); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = !is_signed; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style = round_toward_zero; > }; > > > template<> > struct numeric_limits<char32_t> > { > static constexpr bool is_specialized = true; > > static constexpr char32_t > min() noexcept { return (((char32_t)(-1) < 0) ? -(((char32_t)(-1) < 0) ? (((((char32_t)1 << ((sizeof(char32_t) * 8 - ((char32_t)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(char32_t)0) - 1 : (char32_t)0); } > > static constexpr char32_t > max() noexcept { return (((char32_t)(-1) < 0) ? (((((char32_t)1 << ((sizeof(char32_t) * 8 - ((char32_t)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(char32_t)0); } > > static constexpr char32_t > lowest() noexcept { return min(); } > > static constexpr int digits = (sizeof(char32_t) * 8 - ((char32_t)(-1) < 0)); > static constexpr int digits10 = ((sizeof(char32_t) * 8 - ((char32_t)(-1) < 0)) * 643L / 2136); > static constexpr int max_digits10 = 0; > static constexpr bool is_signed = ((char32_t)(-1) < 0); > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr char32_t > epsilon() noexcept { return 0; } > > static constexpr char32_t > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr char32_t > infinity() noexcept { return char32_t(); } > > static constexpr char32_t > quiet_NaN() noexcept { return char32_t(); } > > static constexpr char32_t > signaling_NaN() noexcept { return char32_t(); } > > static constexpr char32_t > denorm_min() noexcept { return char32_t(); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = !is_signed; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style = round_toward_zero; > }; > > > > template<> > struct numeric_limits<short> > { > static constexpr bool is_specialized = true; > > static constexpr short > min() noexcept { return -32767 - 1; } > > static constexpr short > max() noexcept { return 32767; } > > > static constexpr short > lowest() noexcept { return min(); } > > > static constexpr int digits = (sizeof(short) * 8 - ((short)(-1) < 0)); > static constexpr int digits10 = ((sizeof(short) * 8 - ((short)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = true; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr short > epsilon() noexcept { return 0; } > > static constexpr short > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr short > infinity() noexcept { return short(); } > > static constexpr short > quiet_NaN() noexcept { return short(); } > > static constexpr short > signaling_NaN() noexcept { return short(); } > > static constexpr short > denorm_min() noexcept { return short(); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<unsigned short> > { > static constexpr bool is_specialized = true; > > static constexpr unsigned short > min() noexcept { return 0; } > > static constexpr unsigned short > max() noexcept { return 32767 * 2U + 1; } > > > static constexpr unsigned short > lowest() noexcept { return min(); } > > > static constexpr int digits > = (sizeof(unsigned short) * 8 - ((unsigned short)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(unsigned short) * 8 - ((unsigned short)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = false; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr unsigned short > epsilon() noexcept { return 0; } > > static constexpr unsigned short > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr unsigned short > infinity() noexcept > { return static_cast<unsigned short>(0); } > > static constexpr unsigned short > quiet_NaN() noexcept > { return static_cast<unsigned short>(0); } > > static constexpr unsigned short > signaling_NaN() noexcept > { return static_cast<unsigned short>(0); } > > static constexpr unsigned short > denorm_min() noexcept > { return static_cast<unsigned short>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = true; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<int> > { > static constexpr bool is_specialized = true; > > static constexpr int > min() noexcept { return -2147483647 - 1; } > > static constexpr int > max() noexcept { return 2147483647; } > > > static constexpr int > lowest() noexcept { return min(); } > > > static constexpr int digits = (sizeof(int) * 8 - ((int)(-1) < 0)); > static constexpr int digits10 = ((sizeof(int) * 8 - ((int)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = true; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr int > epsilon() noexcept { return 0; } > > static constexpr int > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr int > infinity() noexcept { return static_cast<int>(0); } > > static constexpr int > quiet_NaN() noexcept { return static_cast<int>(0); } > > static constexpr int > signaling_NaN() noexcept { return static_cast<int>(0); } > > static constexpr int > denorm_min() noexcept { return static_cast<int>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<unsigned int> > { > static constexpr bool is_specialized = true; > > static constexpr unsigned int > min() noexcept { return 0; } > > static constexpr unsigned int > max() noexcept { return 2147483647 * 2U + 1; } > > > static constexpr unsigned int > lowest() noexcept { return min(); } > > > static constexpr int digits > = (sizeof(unsigned int) * 8 - ((unsigned int)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(unsigned int) * 8 - ((unsigned int)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = false; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr unsigned int > epsilon() noexcept { return 0; } > > static constexpr unsigned int > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr unsigned int > infinity() noexcept { return static_cast<unsigned int>(0); } > > static constexpr unsigned int > quiet_NaN() noexcept > { return static_cast<unsigned int>(0); } > > static constexpr unsigned int > signaling_NaN() noexcept > { return static_cast<unsigned int>(0); } > > static constexpr unsigned int > denorm_min() noexcept > { return static_cast<unsigned int>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = true; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<long> > { > static constexpr bool is_specialized = true; > > static constexpr long > min() noexcept { return -9223372036854775807L - 1; } > > static constexpr long > max() noexcept { return 9223372036854775807L; } > > > static constexpr long > lowest() noexcept { return min(); } > > > static constexpr int digits = (sizeof(long) * 8 - ((long)(-1) < 0)); > static constexpr int digits10 = ((sizeof(long) * 8 - ((long)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = true; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr long > epsilon() noexcept { return 0; } > > static constexpr long > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr long > infinity() noexcept { return static_cast<long>(0); } > > static constexpr long > quiet_NaN() noexcept { return static_cast<long>(0); } > > static constexpr long > signaling_NaN() noexcept { return static_cast<long>(0); } > > static constexpr long > denorm_min() noexcept { return static_cast<long>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<unsigned long> > { > static constexpr bool is_specialized = true; > > static constexpr unsigned long > min() noexcept { return 0; } > > static constexpr unsigned long > max() noexcept { return 9223372036854775807L * 2UL + 1; } > > > static constexpr unsigned long > lowest() noexcept { return min(); } > > > static constexpr int digits > = (sizeof(unsigned long) * 8 - ((unsigned long)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(unsigned long) * 8 - ((unsigned long)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = false; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr unsigned long > epsilon() noexcept { return 0; } > > static constexpr unsigned long > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr unsigned long > infinity() noexcept > { return static_cast<unsigned long>(0); } > > static constexpr unsigned long > quiet_NaN() noexcept > { return static_cast<unsigned long>(0); } > > static constexpr unsigned long > signaling_NaN() noexcept > { return static_cast<unsigned long>(0); } > > static constexpr unsigned long > denorm_min() noexcept > { return static_cast<unsigned long>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = true; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<long long> > { > static constexpr bool is_specialized = true; > > static constexpr long long > min() noexcept { return -9223372036854775807LL - 1; } > > static constexpr long long > max() noexcept { return 9223372036854775807LL; } > > > static constexpr long long > lowest() noexcept { return min(); } > > > static constexpr int digits > = (sizeof(long long) * 8 - ((long long)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(long long) * 8 - ((long long)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = true; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr long long > epsilon() noexcept { return 0; } > > static constexpr long long > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr long long > infinity() noexcept { return static_cast<long long>(0); } > > static constexpr long long > quiet_NaN() noexcept { return static_cast<long long>(0); } > > static constexpr long long > signaling_NaN() noexcept > { return static_cast<long long>(0); } > > static constexpr long long > denorm_min() noexcept { return static_cast<long long>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<unsigned long long> > { > static constexpr bool is_specialized = true; > > static constexpr unsigned long long > min() noexcept { return 0; } > > static constexpr unsigned long long > max() noexcept { return 9223372036854775807LL * 2ULL + 1; } > > > static constexpr unsigned long long > lowest() noexcept { return min(); } > > > static constexpr int digits > = (sizeof(unsigned long long) * 8 - ((unsigned long long)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(unsigned long long) * 8 - ((unsigned long long)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = false; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr unsigned long long > epsilon() noexcept { return 0; } > > static constexpr unsigned long long > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr unsigned long long > infinity() noexcept > { return static_cast<unsigned long long>(0); } > > static constexpr unsigned long long > quiet_NaN() noexcept > { return static_cast<unsigned long long>(0); } > > static constexpr unsigned long long > signaling_NaN() noexcept > { return static_cast<unsigned long long>(0); } > > static constexpr unsigned long long > denorm_min() noexcept > { return static_cast<unsigned long long>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = true; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > > template<> > struct numeric_limits<__int128> > { > static constexpr bool is_specialized = true; > > static constexpr __int128 > min() noexcept { return (((__int128)(-1) < 0) ? -(((__int128)(-1) < 0) ? (((((__int128)1 << ((sizeof(__int128) * 8 - ((__int128)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(__int128)0) - 1 : (__int128)0); } > > static constexpr __int128 > max() noexcept { return (((__int128)(-1) < 0) ? (((((__int128)1 << ((sizeof(__int128) * 8 - ((__int128)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(__int128)0); } > > > static constexpr __int128 > lowest() noexcept { return min(); } > > > static constexpr int digits > = (sizeof(__int128) * 8 - ((__int128)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(__int128) * 8 - ((__int128)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = true; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr __int128 > epsilon() noexcept { return 0; } > > static constexpr __int128 > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr __int128 > infinity() noexcept > { return static_cast<__int128>(0); } > > static constexpr __int128 > quiet_NaN() noexcept > { return static_cast<__int128>(0); } > > static constexpr __int128 > signaling_NaN() noexcept > { return static_cast<__int128>(0); } > > static constexpr __int128 > denorm_min() noexcept > { return static_cast<__int128>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > static constexpr bool traps > = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > template<> > struct numeric_limits<unsigned __int128> > { > static constexpr bool is_specialized = true; > > static constexpr unsigned __int128 > min() noexcept { return 0; } > > static constexpr unsigned __int128 > max() noexcept { return (((unsigned __int128)(-1) < 0) ? (((((unsigned __int128)1 << ((sizeof(unsigned __int128) * 8 - ((unsigned __int128)(-1) < 0)) - 1)) - 1) << 1) + 1) : ~(unsigned __int128)0); } > > > static constexpr unsigned __int128 > lowest() noexcept { return min(); } > > > static constexpr int digits > = (sizeof(unsigned __int128) * 8 - ((unsigned __int128)(-1) < 0)); > static constexpr int digits10 > = ((sizeof(unsigned __int128) * 8 - ((unsigned __int128)(-1) < 0)) * 643L / 2136); > > static constexpr int max_digits10 = 0; > > static constexpr bool is_signed = false; > static constexpr bool is_integer = true; > static constexpr bool is_exact = true; > static constexpr int radix = 2; > > static constexpr unsigned __int128 > epsilon() noexcept { return 0; } > > static constexpr unsigned __int128 > round_error() noexcept { return 0; } > > static constexpr int min_exponent = 0; > static constexpr int min_exponent10 = 0; > static constexpr int max_exponent = 0; > static constexpr int max_exponent10 = 0; > > static constexpr bool has_infinity = false; > static constexpr bool has_quiet_NaN = false; > static constexpr bool has_signaling_NaN = false; > static constexpr float_denorm_style has_denorm > = denorm_absent; > static constexpr bool has_denorm_loss = false; > > static constexpr unsigned __int128 > infinity() noexcept > { return static_cast<unsigned __int128>(0); } > > static constexpr unsigned __int128 > quiet_NaN() noexcept > { return static_cast<unsigned __int128>(0); } > > static constexpr unsigned __int128 > signaling_NaN() noexcept > { return static_cast<unsigned __int128>(0); } > > static constexpr unsigned __int128 > denorm_min() noexcept > { return static_cast<unsigned __int128>(0); } > > static constexpr bool is_iec559 = false; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = true; > > static constexpr bool traps = true; > static constexpr bool tinyness_before = false; > static constexpr float_round_style round_style > = round_toward_zero; > }; > > > > template<> > struct numeric_limits<float> > { > static constexpr bool is_specialized = true; > > static constexpr float > min() noexcept { return 1.17549435082228750797e-38F; } > > static constexpr float > max() noexcept { return 3.40282346638528859812e+38F; } > > > static constexpr float > lowest() noexcept { return -3.40282346638528859812e+38F; } > > > static constexpr int digits = 24; > static constexpr int digits10 = 6; > > static constexpr int max_digits10 > = (2 + (24) * 643L / 2136); > > static constexpr bool is_signed = true; > static constexpr bool is_integer = false; > static constexpr bool is_exact = false; > static constexpr int radix = 2; > > static constexpr float > epsilon() noexcept { return 1.19209289550781250000e-7F; } > > static constexpr float > round_error() noexcept { return 0.5F; } > > static constexpr int min_exponent = (-125); > static constexpr int min_exponent10 = (-37); > static constexpr int max_exponent = 128; > static constexpr int max_exponent10 = 38; > > static constexpr bool has_infinity = 1; > static constexpr bool has_quiet_NaN = 1; > static constexpr bool has_signaling_NaN = has_quiet_NaN; > static constexpr float_denorm_style has_denorm > = bool(1) ? denorm_present : denorm_absent; > static constexpr bool has_denorm_loss > = false; > > static constexpr float > infinity() noexcept { return __builtin_huge_valf(); } > > static constexpr float > quiet_NaN() noexcept { return __builtin_nanf(""); } > > static constexpr float > signaling_NaN() noexcept { return __builtin_nansf(""); } > > static constexpr float > denorm_min() noexcept { return 1.40129846432481707092e-45F; } > > static constexpr bool is_iec559 > = has_infinity && has_quiet_NaN && has_denorm == denorm_present; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > static constexpr bool traps = false; > static constexpr bool tinyness_before > = false; > static constexpr float_round_style round_style > = round_to_nearest; > }; > > > > > > > template<> > struct numeric_limits<double> > { > static constexpr bool is_specialized = true; > > static constexpr double > min() noexcept { return double(2.22507385850720138309e-308L); } > > static constexpr double > max() noexcept { return double(1.79769313486231570815e+308L); } > > > static constexpr double > lowest() noexcept { return -double(1.79769313486231570815e+308L); } > > > static constexpr int digits = 53; > static constexpr int digits10 = 15; > > static constexpr int max_digits10 > = (2 + (53) * 643L / 2136); > > static constexpr bool is_signed = true; > static constexpr bool is_integer = false; > static constexpr bool is_exact = false; > static constexpr int radix = 2; > > static constexpr double > epsilon() noexcept { return double(2.22044604925031308085e-16L); } > > static constexpr double > round_error() noexcept { return 0.5; } > > static constexpr int min_exponent = (-1021); > static constexpr int min_exponent10 = (-307); > static constexpr int max_exponent = 1024; > static constexpr int max_exponent10 = 308; > > static constexpr bool has_infinity = 1; > static constexpr bool has_quiet_NaN = 1; > static constexpr bool has_signaling_NaN = has_quiet_NaN; > static constexpr float_denorm_style has_denorm > = bool(1) ? denorm_present : denorm_absent; > static constexpr bool has_denorm_loss > = false; > > static constexpr double > infinity() noexcept { return __builtin_huge_val(); } > > static constexpr double > quiet_NaN() noexcept { return __builtin_nan(""); } > > static constexpr double > signaling_NaN() noexcept { return __builtin_nans(""); } > > static constexpr double > denorm_min() noexcept { return double(4.94065645841246544177e-324L); } > > static constexpr bool is_iec559 > = has_infinity && has_quiet_NaN && has_denorm == denorm_present; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > static constexpr bool traps = false; > static constexpr bool tinyness_before > = false; > static constexpr float_round_style round_style > = round_to_nearest; > }; > > > > > > > template<> > struct numeric_limits<long double> > { > static constexpr bool is_specialized = true; > > static constexpr long double > min() noexcept { return 3.36210314311209350626e-4932L; } > > static constexpr long double > max() noexcept { return 1.18973149535723176502e+4932L; } > > > static constexpr long double > lowest() noexcept { return -1.18973149535723176502e+4932L; } > > > static constexpr int digits = 64; > static constexpr int digits10 = 18; > > static constexpr int max_digits10 > = (2 + (64) * 643L / 2136); > > static constexpr bool is_signed = true; > static constexpr bool is_integer = false; > static constexpr bool is_exact = false; > static constexpr int radix = 2; > > static constexpr long double > epsilon() noexcept { return 1.08420217248550443401e-19L; } > > static constexpr long double > round_error() noexcept { return 0.5L; } > > static constexpr int min_exponent = (-16381); > static constexpr int min_exponent10 = (-4931); > static constexpr int max_exponent = 16384; > static constexpr int max_exponent10 = 4932; > > static constexpr bool has_infinity = 1; > static constexpr bool has_quiet_NaN = 1; > static constexpr bool has_signaling_NaN = has_quiet_NaN; > static constexpr float_denorm_style has_denorm > = bool(1) ? denorm_present : denorm_absent; > static constexpr bool has_denorm_loss > = false; > > static constexpr long double > infinity() noexcept { return __builtin_huge_vall(); } > > static constexpr long double > quiet_NaN() noexcept { return __builtin_nanl(""); } > > static constexpr long double > signaling_NaN() noexcept { return __builtin_nansl(""); } > > static constexpr long double > denorm_min() noexcept { return 3.64519953188247460253e-4951L; } > > static constexpr bool is_iec559 > = has_infinity && has_quiet_NaN && has_denorm == denorm_present; > static constexpr bool is_bounded = true; > static constexpr bool is_modulo = false; > > static constexpr bool traps = false; > static constexpr bool tinyness_before = > false; > static constexpr float_round_style round_style = > round_to_nearest; > }; > > > > > > >} ># 43 "/usr/include/c++/4.9.0/random" 2 3 > > > > > > ># 1 "/usr/include/c++/4.9.0/bits/random.h" 1 3 ># 34 "/usr/include/c++/4.9.0/bits/random.h" 3 ># 1 "/usr/include/c++/4.9.0/vector" 1 3 ># 58 "/usr/include/c++/4.9.0/vector" 3 ># 59 "/usr/include/c++/4.9.0/vector" 3 > > > > ># 1 "/usr/include/c++/4.9.0/bits/stl_uninitialized.h" 1 3 ># 59 "/usr/include/c++/4.9.0/bits/stl_uninitialized.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<bool _TrivialValueTypes> > struct __uninitialized_copy > { > template<typename _InputIterator, typename _ForwardIterator> > static _ForwardIterator > __uninit_copy(_InputIterator __first, _InputIterator __last, > _ForwardIterator __result) > { > _ForwardIterator __cur = __result; > try > { > for (; __first != __last; ++__first, ++__cur) > std::_Construct(std::__addressof(*__cur), *__first); > return __cur; > } > catch(...) > { > std::_Destroy(__result, __cur); > throw; > } > } > }; > > template<> > struct __uninitialized_copy<true> > { > template<typename _InputIterator, typename _ForwardIterator> > static _ForwardIterator > __uninit_copy(_InputIterator __first, _InputIterator __last, > _ForwardIterator __result) > { return std::copy(__first, __last, __result); } > }; ># 105 "/usr/include/c++/4.9.0/bits/stl_uninitialized.h" 3 > template<typename _InputIterator, typename _ForwardIterator> > inline _ForwardIterator > uninitialized_copy(_InputIterator __first, _InputIterator __last, > _ForwardIterator __result) > { > typedef typename iterator_traits<_InputIterator>::value_type > _ValueType1; > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType2; > > > > > typedef typename iterator_traits<_InputIterator>::reference _RefType; > const bool __assignable = is_assignable<_ValueType1, _RefType>::value; > > > return std::__uninitialized_copy<__is_trivial(_ValueType1) > && __is_trivial(_ValueType2) > && __assignable>:: > __uninit_copy(__first, __last, __result); > } > > > template<bool _TrivialValueType> > struct __uninitialized_fill > { > template<typename _ForwardIterator, typename _Tp> > static void > __uninit_fill(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __x) > { > _ForwardIterator __cur = __first; > try > { > for (; __cur != __last; ++__cur) > std::_Construct(std::__addressof(*__cur), __x); > } > catch(...) > { > std::_Destroy(__first, __cur); > throw; > } > } > }; > > template<> > struct __uninitialized_fill<true> > { > template<typename _ForwardIterator, typename _Tp> > static void > __uninit_fill(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __x) > { std::fill(__first, __last, __x); } > }; ># 170 "/usr/include/c++/4.9.0/bits/stl_uninitialized.h" 3 > template<typename _ForwardIterator, typename _Tp> > inline void > uninitialized_fill(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __x) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > > > > const bool __assignable = is_copy_assignable<_ValueType>::value; > > > std::__uninitialized_fill<__is_trivial(_ValueType) && __assignable>:: > __uninit_fill(__first, __last, __x); > } > > > template<bool _TrivialValueType> > struct __uninitialized_fill_n > { > template<typename _ForwardIterator, typename _Size, typename _Tp> > static void > __uninit_fill_n(_ForwardIterator __first, _Size __n, > const _Tp& __x) > { > _ForwardIterator __cur = __first; > try > { > for (; __n > 0; --__n, ++__cur) > std::_Construct(std::__addressof(*__cur), __x); > } > catch(...) > { > std::_Destroy(__first, __cur); > throw; > } > } > }; > > template<> > struct __uninitialized_fill_n<true> > { > template<typename _ForwardIterator, typename _Size, typename _Tp> > static void > __uninit_fill_n(_ForwardIterator __first, _Size __n, > const _Tp& __x) > { std::fill_n(__first, __n, __x); } > }; ># 230 "/usr/include/c++/4.9.0/bits/stl_uninitialized.h" 3 > template<typename _ForwardIterator, typename _Size, typename _Tp> > inline void > uninitialized_fill_n(_ForwardIterator __first, _Size __n, const _Tp& __x) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > > > > const bool __assignable = is_copy_assignable<_ValueType>::value; > > > std::__uninitialized_fill_n<__is_trivial(_ValueType) && __assignable>:: > __uninit_fill_n(__first, __n, __x); > } > > > > > > > > template<typename _InputIterator, typename _ForwardIterator, > typename _Allocator> > _ForwardIterator > __uninitialized_copy_a(_InputIterator __first, _InputIterator __last, > _ForwardIterator __result, _Allocator& __alloc) > { > _ForwardIterator __cur = __result; > try > { > typedef __gnu_cxx::__alloc_traits<_Allocator> __traits; > for (; __first != __last; ++__first, ++__cur) > __traits::construct(__alloc, std::__addressof(*__cur), *__first); > return __cur; > } > catch(...) > { > std::_Destroy(__result, __cur, __alloc); > throw; > } > } > > template<typename _InputIterator, typename _ForwardIterator, typename _Tp> > inline _ForwardIterator > __uninitialized_copy_a(_InputIterator __first, _InputIterator __last, > _ForwardIterator __result, allocator<_Tp>&) > { return std::uninitialized_copy(__first, __last, __result); } > > template<typename _InputIterator, typename _ForwardIterator, > typename _Allocator> > inline _ForwardIterator > __uninitialized_move_a(_InputIterator __first, _InputIterator __last, > _ForwardIterator __result, _Allocator& __alloc) > { > return std::__uninitialized_copy_a(std::make_move_iterator(__first), > std::make_move_iterator(__last), > __result, __alloc); > } > > template<typename _InputIterator, typename _ForwardIterator, > typename _Allocator> > inline _ForwardIterator > __uninitialized_move_if_noexcept_a(_InputIterator __first, > _InputIterator __last, > _ForwardIterator __result, > _Allocator& __alloc) > { > return std::__uninitialized_copy_a > (std::__make_move_if_noexcept_iterator(__first), > std::__make_move_if_noexcept_iterator(__last), __result, __alloc); > } > > template<typename _ForwardIterator, typename _Tp, typename _Allocator> > void > __uninitialized_fill_a(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __x, _Allocator& __alloc) > { > _ForwardIterator __cur = __first; > try > { > typedef __gnu_cxx::__alloc_traits<_Allocator> __traits; > for (; __cur != __last; ++__cur) > __traits::construct(__alloc, std::__addressof(*__cur), __x); > } > catch(...) > { > std::_Destroy(__first, __cur, __alloc); > throw; > } > } > > template<typename _ForwardIterator, typename _Tp, typename _Tp2> > inline void > __uninitialized_fill_a(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __x, allocator<_Tp2>&) > { std::uninitialized_fill(__first, __last, __x); } > > template<typename _ForwardIterator, typename _Size, typename _Tp, > typename _Allocator> > void > __uninitialized_fill_n_a(_ForwardIterator __first, _Size __n, > const _Tp& __x, _Allocator& __alloc) > { > _ForwardIterator __cur = __first; > try > { > typedef __gnu_cxx::__alloc_traits<_Allocator> __traits; > for (; __n > 0; --__n, ++__cur) > __traits::construct(__alloc, std::__addressof(*__cur), __x); > } > catch(...) > { > std::_Destroy(__first, __cur, __alloc); > throw; > } > } > > template<typename _ForwardIterator, typename _Size, typename _Tp, > typename _Tp2> > inline void > __uninitialized_fill_n_a(_ForwardIterator __first, _Size __n, > const _Tp& __x, allocator<_Tp2>&) > { std::uninitialized_fill_n(__first, __n, __x); } ># 366 "/usr/include/c++/4.9.0/bits/stl_uninitialized.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _ForwardIterator, typename _Allocator> > inline _ForwardIterator > __uninitialized_copy_move(_InputIterator1 __first1, > _InputIterator1 __last1, > _InputIterator2 __first2, > _InputIterator2 __last2, > _ForwardIterator __result, > _Allocator& __alloc) > { > _ForwardIterator __mid = std::__uninitialized_copy_a(__first1, __last1, > __result, > __alloc); > try > { > return std::__uninitialized_move_a(__first2, __last2, __mid, __alloc); > } > catch(...) > { > std::_Destroy(__result, __mid, __alloc); > throw; > } > } > > > > > > template<typename _InputIterator1, typename _InputIterator2, > typename _ForwardIterator, typename _Allocator> > inline _ForwardIterator > __uninitialized_move_copy(_InputIterator1 __first1, > _InputIterator1 __last1, > _InputIterator2 __first2, > _InputIterator2 __last2, > _ForwardIterator __result, > _Allocator& __alloc) > { > _ForwardIterator __mid = std::__uninitialized_move_a(__first1, __last1, > __result, > __alloc); > try > { > return std::__uninitialized_copy_a(__first2, __last2, __mid, __alloc); > } > catch(...) > { > std::_Destroy(__result, __mid, __alloc); > throw; > } > } > > > > > template<typename _ForwardIterator, typename _Tp, typename _InputIterator, > typename _Allocator> > inline _ForwardIterator > __uninitialized_fill_move(_ForwardIterator __result, _ForwardIterator __mid, > const _Tp& __x, _InputIterator __first, > _InputIterator __last, _Allocator& __alloc) > { > std::__uninitialized_fill_a(__result, __mid, __x, __alloc); > try > { > return std::__uninitialized_move_a(__first, __last, __mid, __alloc); > } > catch(...) > { > std::_Destroy(__result, __mid, __alloc); > throw; > } > } > > > > > template<typename _InputIterator, typename _ForwardIterator, typename _Tp, > typename _Allocator> > inline void > __uninitialized_move_fill(_InputIterator __first1, _InputIterator __last1, > _ForwardIterator __first2, > _ForwardIterator __last2, const _Tp& __x, > _Allocator& __alloc) > { > _ForwardIterator __mid2 = std::__uninitialized_move_a(__first1, __last1, > __first2, > __alloc); > try > { > std::__uninitialized_fill_a(__mid2, __last2, __x, __alloc); > } > catch(...) > { > std::_Destroy(__first2, __mid2, __alloc); > throw; > } > } > > > > > > template<bool _TrivialValueType> > struct __uninitialized_default_1 > { > template<typename _ForwardIterator> > static void > __uninit_default(_ForwardIterator __first, _ForwardIterator __last) > { > _ForwardIterator __cur = __first; > try > { > for (; __cur != __last; ++__cur) > std::_Construct(std::__addressof(*__cur)); > } > catch(...) > { > std::_Destroy(__first, __cur); > throw; > } > } > }; > > template<> > struct __uninitialized_default_1<true> > { > template<typename _ForwardIterator> > static void > __uninit_default(_ForwardIterator __first, _ForwardIterator __last) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > std::fill(__first, __last, _ValueType()); > } > }; > > template<bool _TrivialValueType> > struct __uninitialized_default_n_1 > { > template<typename _ForwardIterator, typename _Size> > static void > __uninit_default_n(_ForwardIterator __first, _Size __n) > { > _ForwardIterator __cur = __first; > try > { > for (; __n > 0; --__n, ++__cur) > std::_Construct(std::__addressof(*__cur)); > } > catch(...) > { > std::_Destroy(__first, __cur); > throw; > } > } > }; > > template<> > struct __uninitialized_default_n_1<true> > { > template<typename _ForwardIterator, typename _Size> > static void > __uninit_default_n(_ForwardIterator __first, _Size __n) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > std::fill_n(__first, __n, _ValueType()); > } > }; > > > > > template<typename _ForwardIterator> > inline void > __uninitialized_default(_ForwardIterator __first, > _ForwardIterator __last) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > const bool __assignable = is_copy_assignable<_ValueType>::value; > > std::__uninitialized_default_1<__is_trivial(_ValueType) > && __assignable>:: > __uninit_default(__first, __last); > } > > > > template<typename _ForwardIterator, typename _Size> > inline void > __uninitialized_default_n(_ForwardIterator __first, _Size __n) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > const bool __assignable = is_copy_assignable<_ValueType>::value; > > std::__uninitialized_default_n_1<__is_trivial(_ValueType) > && __assignable>:: > __uninit_default_n(__first, __n); > } > > > > > > template<typename _ForwardIterator, typename _Allocator> > void > __uninitialized_default_a(_ForwardIterator __first, > _ForwardIterator __last, > _Allocator& __alloc) > { > _ForwardIterator __cur = __first; > try > { > typedef __gnu_cxx::__alloc_traits<_Allocator> __traits; > for (; __cur != __last; ++__cur) > __traits::construct(__alloc, std::__addressof(*__cur)); > } > catch(...) > { > std::_Destroy(__first, __cur, __alloc); > throw; > } > } > > template<typename _ForwardIterator, typename _Tp> > inline void > __uninitialized_default_a(_ForwardIterator __first, > _ForwardIterator __last, > allocator<_Tp>&) > { std::__uninitialized_default(__first, __last); } > > > > > > template<typename _ForwardIterator, typename _Size, typename _Allocator> > void > __uninitialized_default_n_a(_ForwardIterator __first, _Size __n, > _Allocator& __alloc) > { > _ForwardIterator __cur = __first; > try > { > typedef __gnu_cxx::__alloc_traits<_Allocator> __traits; > for (; __n > 0; --__n, ++__cur) > __traits::construct(__alloc, std::__addressof(*__cur)); > } > catch(...) > { > std::_Destroy(__first, __cur, __alloc); > throw; > } > } > > template<typename _ForwardIterator, typename _Size, typename _Tp> > inline void > __uninitialized_default_n_a(_ForwardIterator __first, _Size __n, > allocator<_Tp>&) > { std::__uninitialized_default_n(__first, __n); } > > > template<typename _InputIterator, typename _Size, > typename _ForwardIterator> > _ForwardIterator > __uninitialized_copy_n(_InputIterator __first, _Size __n, > _ForwardIterator __result, input_iterator_tag) > { > _ForwardIterator __cur = __result; > try > { > for (; __n > 0; --__n, ++__first, ++__cur) > std::_Construct(std::__addressof(*__cur), *__first); > return __cur; > } > catch(...) > { > std::_Destroy(__result, __cur); > throw; > } > } > > template<typename _RandomAccessIterator, typename _Size, > typename _ForwardIterator> > inline _ForwardIterator > __uninitialized_copy_n(_RandomAccessIterator __first, _Size __n, > _ForwardIterator __result, > random_access_iterator_tag) > { return std::uninitialized_copy(__first, __first + __n, __result); } ># 671 "/usr/include/c++/4.9.0/bits/stl_uninitialized.h" 3 > template<typename _InputIterator, typename _Size, typename _ForwardIterator> > inline _ForwardIterator > uninitialized_copy_n(_InputIterator __first, _Size __n, > _ForwardIterator __result) > { return std::__uninitialized_copy_n(__first, __n, __result, > std::__iterator_category(__first)); } > > > >} ># 64 "/usr/include/c++/4.9.0/vector" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_vector.h" 1 3 ># 66 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template<typename _Tp, typename _Alloc> > struct _Vector_base > { > typedef typename __gnu_cxx::__alloc_traits<_Alloc>::template > rebind<_Tp>::other _Tp_alloc_type; > typedef typename __gnu_cxx::__alloc_traits<_Tp_alloc_type>::pointer > pointer; > > struct _Vector_impl > : public _Tp_alloc_type > { > pointer _M_start; > pointer _M_finish; > pointer _M_end_of_storage; > > _Vector_impl() > : _Tp_alloc_type(), _M_start(0), _M_finish(0), _M_end_of_storage(0) > { } > > _Vector_impl(_Tp_alloc_type const& __a) noexcept > : _Tp_alloc_type(__a), _M_start(0), _M_finish(0), _M_end_of_storage(0) > { } > > > _Vector_impl(_Tp_alloc_type&& __a) noexcept > : _Tp_alloc_type(std::move(__a)), > _M_start(0), _M_finish(0), _M_end_of_storage(0) > { } > > > void _M_swap_data(_Vector_impl& __x) noexcept > { > std::swap(_M_start, __x._M_start); > std::swap(_M_finish, __x._M_finish); > std::swap(_M_end_of_storage, __x._M_end_of_storage); > } > }; > > public: > typedef _Alloc allocator_type; > > _Tp_alloc_type& > _M_get_Tp_allocator() noexcept > { return *static_cast<_Tp_alloc_type*>(&this->_M_impl); } > > const _Tp_alloc_type& > _M_get_Tp_allocator() const noexcept > { return *static_cast<const _Tp_alloc_type*>(&this->_M_impl); } > > allocator_type > get_allocator() const noexcept > { return allocator_type(_M_get_Tp_allocator()); } > > _Vector_base() > : _M_impl() { } > > _Vector_base(const allocator_type& __a) noexcept > : _M_impl(__a) { } > > _Vector_base(size_t __n) > : _M_impl() > { _M_create_storage(__n); } > > _Vector_base(size_t __n, const allocator_type& __a) > : _M_impl(__a) > { _M_create_storage(__n); } > > > _Vector_base(_Tp_alloc_type&& __a) noexcept > : _M_impl(std::move(__a)) { } > > _Vector_base(_Vector_base&& __x) noexcept > : _M_impl(std::move(__x._M_get_Tp_allocator())) > { this->_M_impl._M_swap_data(__x._M_impl); } > > _Vector_base(_Vector_base&& __x, const allocator_type& __a) > : _M_impl(__a) > { > if (__x.get_allocator() == __a) > this->_M_impl._M_swap_data(__x._M_impl); > else > { > size_t __n = __x._M_impl._M_finish - __x._M_impl._M_start; > _M_create_storage(__n); > } > } > > > ~_Vector_base() noexcept > { _M_deallocate(this->_M_impl._M_start, this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); } > > public: > _Vector_impl _M_impl; > > pointer > _M_allocate(size_t __n) > { > typedef __gnu_cxx::__alloc_traits<_Tp_alloc_type> _Tr; > return __n != 0 ? _Tr::allocate(_M_impl, __n) : 0; > } > > void > _M_deallocate(pointer __p, size_t __n) > { > typedef __gnu_cxx::__alloc_traits<_Tp_alloc_type> _Tr; > if (__p) > _Tr::deallocate(_M_impl, __p, __n); > } > > private: > void > _M_create_storage(size_t __n) > { > this->_M_impl._M_start = this->_M_allocate(__n); > this->_M_impl._M_finish = this->_M_impl._M_start; > this->_M_impl._M_end_of_storage = this->_M_impl._M_start + __n; > } > }; ># 213 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename _Tp, typename _Alloc = std::allocator<_Tp> > > class vector : protected _Vector_base<_Tp, _Alloc> > { > > typedef typename _Alloc::value_type _Alloc_value_type; > > > > typedef _Vector_base<_Tp, _Alloc> _Base; > typedef typename _Base::_Tp_alloc_type _Tp_alloc_type; > typedef __gnu_cxx::__alloc_traits<_Tp_alloc_type> _Alloc_traits; > > public: > typedef _Tp value_type; > typedef typename _Base::pointer pointer; > typedef typename _Alloc_traits::const_pointer const_pointer; > typedef typename _Alloc_traits::reference reference; > typedef typename _Alloc_traits::const_reference const_reference; > typedef __gnu_cxx::__normal_iterator<pointer, vector> iterator; > typedef __gnu_cxx::__normal_iterator<const_pointer, vector> > const_iterator; > typedef std::reverse_iterator<const_iterator> const_reverse_iterator; > typedef std::reverse_iterator<iterator> reverse_iterator; > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef _Alloc allocator_type; > > protected: > using _Base::_M_allocate; > using _Base::_M_deallocate; > using _Base::_M_impl; > using _Base::_M_get_Tp_allocator; > > public: > > > > > > > vector() > > noexcept(is_nothrow_default_constructible<_Alloc>::value) > > : _Base() { } > > > > > > explicit > vector(const allocator_type& __a) noexcept > : _Base(__a) { } ># 276 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > explicit > vector(size_type __n, const allocator_type& __a = allocator_type()) > : _Base(__n, __a) > { _M_default_initialize(__n); } ># 289 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > vector(size_type __n, const value_type& __value, > const allocator_type& __a = allocator_type()) > : _Base(__n, __a) > { _M_fill_initialize(__n, __value); } ># 318 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > vector(const vector& __x) > : _Base(__x.size(), > _Alloc_traits::_S_select_on_copy(__x._M_get_Tp_allocator())) > { this->_M_impl._M_finish = > std::__uninitialized_copy_a(__x.begin(), __x.end(), > this->_M_impl._M_start, > _M_get_Tp_allocator()); > } ># 335 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > vector(vector&& __x) noexcept > : _Base(std::move(__x)) { } > > > vector(const vector& __x, const allocator_type& __a) > : _Base(__x.size(), __a) > { this->_M_impl._M_finish = > std::__uninitialized_copy_a(__x.begin(), __x.end(), > this->_M_impl._M_start, > _M_get_Tp_allocator()); > } > > > vector(vector&& __rv, const allocator_type& __m) > noexcept(_Alloc_traits::_S_always_equal()) > : _Base(std::move(__rv), __m) > { > if (__rv.get_allocator() != __m) > { > this->_M_impl._M_finish = > std::__uninitialized_move_a(__rv.begin(), __rv.end(), > this->_M_impl._M_start, > _M_get_Tp_allocator()); > __rv.clear(); > } > } ># 373 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > vector(initializer_list<value_type> __l, > const allocator_type& __a = allocator_type()) > : _Base(__a) > { > _M_range_initialize(__l.begin(), __l.end(), > random_access_iterator_tag()); > } ># 399 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > vector(_InputIterator __first, _InputIterator __last, > const allocator_type& __a = allocator_type()) > : _Base(__a) > { _M_initialize_dispatch(__first, __last, __false_type()); } ># 423 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > ~vector() noexcept > { std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish, > _M_get_Tp_allocator()); } ># 435 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > vector& > operator=(const vector& __x); ># 447 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > vector& > operator=(vector&& __x) noexcept(_Alloc_traits::_S_nothrow_move()) > { > constexpr bool __move_storage = > _Alloc_traits::_S_propagate_on_move_assign() > || _Alloc_traits::_S_always_equal(); > _M_move_assign(std::move(__x), > integral_constant<bool, __move_storage>()); > return *this; > } ># 469 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > vector& > operator=(initializer_list<value_type> __l) > { > this->assign(__l.begin(), __l.end()); > return *this; > } ># 487 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > void > assign(size_type __n, const value_type& __val) > { _M_fill_assign(__n, __val); } ># 504 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > void > assign(_InputIterator __first, _InputIterator __last) > { _M_assign_dispatch(__first, __last, __false_type()); } ># 532 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > void > assign(initializer_list<value_type> __l) > { this->assign(__l.begin(), __l.end()); } > > > > using _Base::get_allocator; > > > > > > > > iterator > begin() noexcept > { return iterator(this->_M_impl._M_start); } > > > > > > > const_iterator > begin() const noexcept > { return const_iterator(this->_M_impl._M_start); } > > > > > > > iterator > end() noexcept > { return iterator(this->_M_impl._M_finish); } > > > > > > > const_iterator > end() const noexcept > { return const_iterator(this->_M_impl._M_finish); } > > > > > > > reverse_iterator > rbegin() noexcept > { return reverse_iterator(end()); } > > > > > > > const_reverse_iterator > rbegin() const noexcept > { return const_reverse_iterator(end()); } > > > > > > > reverse_iterator > rend() noexcept > { return reverse_iterator(begin()); } > > > > > > > const_reverse_iterator > rend() const noexcept > { return const_reverse_iterator(begin()); } > > > > > > > > const_iterator > cbegin() const noexcept > { return const_iterator(this->_M_impl._M_start); } > > > > > > > const_iterator > cend() const noexcept > { return const_iterator(this->_M_impl._M_finish); } > > > > > > > const_reverse_iterator > crbegin() const noexcept > { return const_reverse_iterator(end()); } > > > > > > > const_reverse_iterator > crend() const noexcept > { return const_reverse_iterator(begin()); } > > > > > size_type > size() const noexcept > { return size_type(this->_M_impl._M_finish - this->_M_impl._M_start); } > > > size_type > max_size() const noexcept > { return _Alloc_traits::max_size(_M_get_Tp_allocator()); } ># 672 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > void > resize(size_type __new_size) > { > if (__new_size > size()) > _M_default_append(__new_size - size()); > else if (__new_size < size()) > _M_erase_at_end(this->_M_impl._M_start + __new_size); > } ># 692 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > void > resize(size_type __new_size, const value_type& __x) > { > if (__new_size > size()) > insert(end(), __new_size - size(), __x); > else if (__new_size < size()) > _M_erase_at_end(this->_M_impl._M_start + __new_size); > } ># 724 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > void > shrink_to_fit() > { _M_shrink_to_fit(); } > > > > > > > size_type > capacity() const noexcept > { return size_type(this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); } > > > > > > bool > empty() const noexcept > { return begin() == end(); } ># 763 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > void > reserve(size_type __n); ># 778 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > reference > operator[](size_type __n) noexcept > { return *(this->_M_impl._M_start + __n); } ># 793 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > const_reference > operator[](size_type __n) const noexcept > { return *(this->_M_impl._M_start + __n); } > > protected: > > void > _M_range_check(size_type __n) const > { > if (__n >= this->size()) > __throw_out_of_range_fmt(("vector::_M_range_check: __n " "(which is %zu) >= this->size() " "(which is %zu)") > > , > __n, this->size()); > } > > public: ># 821 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > reference > at(size_type __n) > { > _M_range_check(__n); > return (*this)[__n]; > } ># 839 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > const_reference > at(size_type __n) const > { > _M_range_check(__n); > return (*this)[__n]; > } > > > > > > reference > front() noexcept > { return *begin(); } > > > > > > const_reference > front() const noexcept > { return *begin(); } > > > > > > reference > back() noexcept > { return *(end() - 1); } > > > > > > const_reference > back() const noexcept > { return *(end() - 1); } ># 886 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > _Tp* > > > > data() noexcept > { return _M_data_ptr(this->_M_impl._M_start); } > > > const _Tp* > > > > data() const noexcept > { return _M_data_ptr(this->_M_impl._M_start); } ># 912 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > void > push_back(const value_type& __x) > { > if (this->_M_impl._M_finish != this->_M_impl._M_end_of_storage) > { > _Alloc_traits::construct(this->_M_impl, this->_M_impl._M_finish, > __x); > ++this->_M_impl._M_finish; > } > else > > _M_emplace_back_aux(__x); > > > > } > > > void > push_back(value_type&& __x) > { emplace_back(std::move(__x)); } > > template<typename... _Args> > void > emplace_back(_Args&&... __args); ># 948 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > void > pop_back() noexcept > { > --this->_M_impl._M_finish; > _Alloc_traits::destroy(this->_M_impl, this->_M_impl._M_finish); > } ># 968 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename... _Args> > iterator > emplace(const_iterator __position, _Args&&... __args); ># 983 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > iterator > insert(const_iterator __position, const value_type& __x); ># 1013 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > iterator > insert(const_iterator __position, value_type&& __x) > { return emplace(__position, std::move(__x)); } ># 1030 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > iterator > insert(const_iterator __position, initializer_list<value_type> __l) > { return this->insert(__position, __l.begin(), __l.end()); } ># 1050 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > iterator > insert(const_iterator __position, size_type __n, const value_type& __x) > { > difference_type __offset = __position - cbegin(); > _M_fill_insert(__position._M_const_cast(), __n, __x); > return begin() + __offset; > } ># 1092 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > iterator > insert(const_iterator __position, _InputIterator __first, > _InputIterator __last) > { > difference_type __offset = __position - cbegin(); > _M_insert_dispatch(__position._M_const_cast(), > __first, __last, __false_type()); > return begin() + __offset; > } ># 1144 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > iterator > > erase(const_iterator __position) > > > > { return _M_erase(__position._M_const_cast()); } ># 1170 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > iterator > > erase(const_iterator __first, const_iterator __last) > > > > { return _M_erase(__first._M_const_cast(), __last._M_const_cast()); } ># 1187 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > void > swap(vector& __x) > > noexcept(_Alloc_traits::_S_nothrow_swap()) > > { > this->_M_impl._M_swap_data(__x._M_impl); > _Alloc_traits::_S_on_swap(_M_get_Tp_allocator(), > __x._M_get_Tp_allocator()); > } > > > > > > > > void > clear() noexcept > { _M_erase_at_end(this->_M_impl._M_start); } > > protected: > > > > > template<typename _ForwardIterator> > pointer > _M_allocate_and_copy(size_type __n, > _ForwardIterator __first, _ForwardIterator __last) > { > pointer __result = this->_M_allocate(__n); > try > { > std::__uninitialized_copy_a(__first, __last, __result, > _M_get_Tp_allocator()); > return __result; > } > catch(...) > { > _M_deallocate(__result, __n); > throw; > } > } ># 1239 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename _Integer> > void > _M_initialize_dispatch(_Integer __n, _Integer __value, __true_type) > { > this->_M_impl._M_start = _M_allocate(static_cast<size_type>(__n)); > this->_M_impl._M_end_of_storage = > this->_M_impl._M_start + static_cast<size_type>(__n); > _M_fill_initialize(static_cast<size_type>(__n), __value); > } > > > template<typename _InputIterator> > void > _M_initialize_dispatch(_InputIterator __first, _InputIterator __last, > __false_type) > { > typedef typename std::iterator_traits<_InputIterator>:: > iterator_category _IterCategory; > _M_range_initialize(__first, __last, _IterCategory()); > } > > > template<typename _InputIterator> > void > _M_range_initialize(_InputIterator __first, > _InputIterator __last, std::input_iterator_tag) > { > for (; __first != __last; ++__first) > > emplace_back(*__first); > > > > } > > > template<typename _ForwardIterator> > void > _M_range_initialize(_ForwardIterator __first, > _ForwardIterator __last, std::forward_iterator_tag) > { > const size_type __n = std::distance(__first, __last); > this->_M_impl._M_start = this->_M_allocate(__n); > this->_M_impl._M_end_of_storage = this->_M_impl._M_start + __n; > this->_M_impl._M_finish = > std::__uninitialized_copy_a(__first, __last, > this->_M_impl._M_start, > _M_get_Tp_allocator()); > } > > > > void > _M_fill_initialize(size_type __n, const value_type& __value) > { > std::__uninitialized_fill_n_a(this->_M_impl._M_start, __n, __value, > _M_get_Tp_allocator()); > this->_M_impl._M_finish = this->_M_impl._M_end_of_storage; > } > > > > void > _M_default_initialize(size_type __n) > { > std::__uninitialized_default_n_a(this->_M_impl._M_start, __n, > _M_get_Tp_allocator()); > this->_M_impl._M_finish = this->_M_impl._M_end_of_storage; > } ># 1317 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename _Integer> > void > _M_assign_dispatch(_Integer __n, _Integer __val, __true_type) > { _M_fill_assign(__n, __val); } > > > template<typename _InputIterator> > void > _M_assign_dispatch(_InputIterator __first, _InputIterator __last, > __false_type) > { > typedef typename std::iterator_traits<_InputIterator>:: > iterator_category _IterCategory; > _M_assign_aux(__first, __last, _IterCategory()); > } > > > template<typename _InputIterator> > void > _M_assign_aux(_InputIterator __first, _InputIterator __last, > std::input_iterator_tag); > > > template<typename _ForwardIterator> > void > _M_assign_aux(_ForwardIterator __first, _ForwardIterator __last, > std::forward_iterator_tag); > > > > void > _M_fill_assign(size_type __n, const value_type& __val); ># 1357 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename _Integer> > void > _M_insert_dispatch(iterator __pos, _Integer __n, _Integer __val, > __true_type) > { _M_fill_insert(__pos, __n, __val); } > > > template<typename _InputIterator> > void > _M_insert_dispatch(iterator __pos, _InputIterator __first, > _InputIterator __last, __false_type) > { > typedef typename std::iterator_traits<_InputIterator>:: > iterator_category _IterCategory; > _M_range_insert(__pos, __first, __last, _IterCategory()); > } > > > template<typename _InputIterator> > void > _M_range_insert(iterator __pos, _InputIterator __first, > _InputIterator __last, std::input_iterator_tag); > > > template<typename _ForwardIterator> > void > _M_range_insert(iterator __pos, _ForwardIterator __first, > _ForwardIterator __last, std::forward_iterator_tag); > > > > void > _M_fill_insert(iterator __pos, size_type __n, const value_type& __x); > > > > void > _M_default_append(size_type __n); > > bool > _M_shrink_to_fit(); > > > > > > > > template<typename... _Args> > void > _M_insert_aux(iterator __position, _Args&&... __args); > > template<typename... _Args> > void > _M_emplace_back_aux(_Args&&... __args); > > > > size_type > _M_check_len(size_type __n, const char* __s) const > { > if (max_size() - size() < __n) > __throw_length_error((__s)); > > const size_type __len = size() + std::max(size(), __n); > return (__len < size() || __len > max_size()) ? max_size() : __len; > } > > > > > > void > _M_erase_at_end(pointer __pos) noexcept > { > std::_Destroy(__pos, this->_M_impl._M_finish, _M_get_Tp_allocator()); > this->_M_impl._M_finish = __pos; > } > > iterator > _M_erase(iterator __position); > > iterator > _M_erase(iterator __first, iterator __last); > > > private: > > > > void > _M_move_assign(vector&& __x, std::true_type) noexcept > { > vector __tmp(get_allocator()); > this->_M_impl._M_swap_data(__tmp._M_impl); > this->_M_impl._M_swap_data(__x._M_impl); > std::__alloc_on_move(_M_get_Tp_allocator(), __x._M_get_Tp_allocator()); > } > > > > void > _M_move_assign(vector&& __x, std::false_type) > { > if (__x._M_get_Tp_allocator() == this->_M_get_Tp_allocator()) > _M_move_assign(std::move(__x), std::true_type()); > else > { > > > this->assign(std::__make_move_if_noexcept_iterator(__x.begin()), > std::__make_move_if_noexcept_iterator(__x.end())); > __x.clear(); > } > } > > > > template<typename _Up> > _Up* > _M_data_ptr(_Up* __ptr) const > { return __ptr; } > > template<typename _Ptr> > typename std::pointer_traits<_Ptr>::element_type* > _M_data_ptr(_Ptr __ptr) const > { return empty() ? nullptr : std::__addressof(*__ptr); } > > > > > > > }; ># 1503 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename _Tp, typename _Alloc> > inline bool > operator==(const vector<_Tp, _Alloc>& __x, const vector<_Tp, _Alloc>& __y) > { return (__x.size() == __y.size() > && std::equal(__x.begin(), __x.end(), __y.begin())); } ># 1520 "/usr/include/c++/4.9.0/bits/stl_vector.h" 3 > template<typename _Tp, typename _Alloc> > inline bool > operator<(const vector<_Tp, _Alloc>& __x, const vector<_Tp, _Alloc>& __y) > { return std::lexicographical_compare(__x.begin(), __x.end(), > __y.begin(), __y.end()); } > > > template<typename _Tp, typename _Alloc> > inline bool > operator!=(const vector<_Tp, _Alloc>& __x, const vector<_Tp, _Alloc>& __y) > { return !(__x == __y); } > > > template<typename _Tp, typename _Alloc> > inline bool > operator>(const vector<_Tp, _Alloc>& __x, const vector<_Tp, _Alloc>& __y) > { return __y < __x; } > > > template<typename _Tp, typename _Alloc> > inline bool > operator<=(const vector<_Tp, _Alloc>& __x, const vector<_Tp, _Alloc>& __y) > { return !(__y < __x); } > > > template<typename _Tp, typename _Alloc> > inline bool > operator>=(const vector<_Tp, _Alloc>& __x, const vector<_Tp, _Alloc>& __y) > { return !(__x < __y); } > > > template<typename _Tp, typename _Alloc> > inline void > swap(vector<_Tp, _Alloc>& __x, vector<_Tp, _Alloc>& __y) > { __x.swap(__y); } > > >} ># 65 "/usr/include/c++/4.9.0/vector" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_bvector.h" 1 3 ># 63 "/usr/include/c++/4.9.0/bits/stl_bvector.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > typedef unsigned long _Bit_type; > enum { _S_word_bit = int(8 * sizeof(_Bit_type)) }; > > struct _Bit_reference > { > _Bit_type * _M_p; > _Bit_type _M_mask; > > _Bit_reference(_Bit_type * __x, _Bit_type __y) > : _M_p(__x), _M_mask(__y) { } > > _Bit_reference() noexcept : _M_p(0), _M_mask(0) { } > > operator bool() const noexcept > { return !!(*_M_p & _M_mask); } > > _Bit_reference& > operator=(bool __x) noexcept > { > if (__x) > *_M_p |= _M_mask; > else > *_M_p &= ~_M_mask; > return *this; > } > > _Bit_reference& > operator=(const _Bit_reference& __x) noexcept > { return *this = bool(__x); } > > bool > operator==(const _Bit_reference& __x) const > { return bool(*this) == bool(__x); } > > bool > operator<(const _Bit_reference& __x) const > { return !bool(*this) && bool(__x); } > > void > flip() noexcept > { *_M_p ^= _M_mask; } > }; > > > inline void > swap(_Bit_reference __x, _Bit_reference __y) noexcept > { > bool __tmp = __x; > __x = __y; > __y = __tmp; > } > > inline void > swap(_Bit_reference __x, bool& __y) noexcept > { > bool __tmp = __x; > __x = __y; > __y = __tmp; > } > > inline void > swap(bool& __x, _Bit_reference __y) noexcept > { > bool __tmp = __x; > __x = __y; > __y = __tmp; > } > > > struct _Bit_iterator_base > : public std::iterator<std::random_access_iterator_tag, bool> > { > _Bit_type * _M_p; > unsigned int _M_offset; > > _Bit_iterator_base(_Bit_type * __x, unsigned int __y) > : _M_p(__x), _M_offset(__y) { } > > void > _M_bump_up() > { > if (_M_offset++ == int(_S_word_bit) - 1) > { > _M_offset = 0; > ++_M_p; > } > } > > void > _M_bump_down() > { > if (_M_offset-- == 0) > { > _M_offset = int(_S_word_bit) - 1; > --_M_p; > } > } > > void > _M_incr(ptrdiff_t __i) > { > difference_type __n = __i + _M_offset; > _M_p += __n / int(_S_word_bit); > __n = __n % int(_S_word_bit); > if (__n < 0) > { > __n += int(_S_word_bit); > --_M_p; > } > _M_offset = static_cast<unsigned int>(__n); > } > > bool > operator==(const _Bit_iterator_base& __i) const > { return _M_p == __i._M_p && _M_offset == __i._M_offset; } > > bool > operator<(const _Bit_iterator_base& __i) const > { > return _M_p < __i._M_p > || (_M_p == __i._M_p && _M_offset < __i._M_offset); > } > > bool > operator!=(const _Bit_iterator_base& __i) const > { return !(*this == __i); } > > bool > operator>(const _Bit_iterator_base& __i) const > { return __i < *this; } > > bool > operator<=(const _Bit_iterator_base& __i) const > { return !(__i < *this); } > > bool > operator>=(const _Bit_iterator_base& __i) const > { return !(*this < __i); } > }; > > inline ptrdiff_t > operator-(const _Bit_iterator_base& __x, const _Bit_iterator_base& __y) > { > return (int(_S_word_bit) * (__x._M_p - __y._M_p) > + __x._M_offset - __y._M_offset); > } > > struct _Bit_iterator : public _Bit_iterator_base > { > typedef _Bit_reference reference; > typedef _Bit_reference* pointer; > typedef _Bit_iterator iterator; > > _Bit_iterator() : _Bit_iterator_base(0, 0) { } > > _Bit_iterator(_Bit_type * __x, unsigned int __y) > : _Bit_iterator_base(__x, __y) { } > > iterator > _M_const_cast() const > { return *this; } > > reference > operator*() const > { return reference(_M_p, 1UL << _M_offset); } > > iterator& > operator++() > { > _M_bump_up(); > return *this; > } > > iterator > operator++(int) > { > iterator __tmp = *this; > _M_bump_up(); > return __tmp; > } > > iterator& > operator--() > { > _M_bump_down(); > return *this; > } > > iterator > operator--(int) > { > iterator __tmp = *this; > _M_bump_down(); > return __tmp; > } > > iterator& > operator+=(difference_type __i) > { > _M_incr(__i); > return *this; > } > > iterator& > operator-=(difference_type __i) > { > *this += -__i; > return *this; > } > > iterator > operator+(difference_type __i) const > { > iterator __tmp = *this; > return __tmp += __i; > } > > iterator > operator-(difference_type __i) const > { > iterator __tmp = *this; > return __tmp -= __i; > } > > reference > operator[](difference_type __i) const > { return *(*this + __i); } > }; > > inline _Bit_iterator > operator+(ptrdiff_t __n, const _Bit_iterator& __x) > { return __x + __n; } > > struct _Bit_const_iterator : public _Bit_iterator_base > { > typedef bool reference; > typedef bool const_reference; > typedef const bool* pointer; > typedef _Bit_const_iterator const_iterator; > > _Bit_const_iterator() : _Bit_iterator_base(0, 0) { } > > _Bit_const_iterator(_Bit_type * __x, unsigned int __y) > : _Bit_iterator_base(__x, __y) { } > > _Bit_const_iterator(const _Bit_iterator& __x) > : _Bit_iterator_base(__x._M_p, __x._M_offset) { } > > _Bit_iterator > _M_const_cast() const > { return _Bit_iterator(_M_p, _M_offset); } > > const_reference > operator*() const > { return _Bit_reference(_M_p, 1UL << _M_offset); } > > const_iterator& > operator++() > { > _M_bump_up(); > return *this; > } > > const_iterator > operator++(int) > { > const_iterator __tmp = *this; > _M_bump_up(); > return __tmp; > } > > const_iterator& > operator--() > { > _M_bump_down(); > return *this; > } > > const_iterator > operator--(int) > { > const_iterator __tmp = *this; > _M_bump_down(); > return __tmp; > } > > const_iterator& > operator+=(difference_type __i) > { > _M_incr(__i); > return *this; > } > > const_iterator& > operator-=(difference_type __i) > { > *this += -__i; > return *this; > } > > const_iterator > operator+(difference_type __i) const > { > const_iterator __tmp = *this; > return __tmp += __i; > } > > const_iterator > operator-(difference_type __i) const > { > const_iterator __tmp = *this; > return __tmp -= __i; > } > > const_reference > operator[](difference_type __i) const > { return *(*this + __i); } > }; > > inline _Bit_const_iterator > operator+(ptrdiff_t __n, const _Bit_const_iterator& __x) > { return __x + __n; } > > inline void > __fill_bvector(_Bit_iterator __first, _Bit_iterator __last, bool __x) > { > for (; __first != __last; ++__first) > *__first = __x; > } > > inline void > fill(_Bit_iterator __first, _Bit_iterator __last, const bool& __x) > { > if (__first._M_p != __last._M_p) > { > std::fill(__first._M_p + 1, __last._M_p, __x ? ~0 : 0); > __fill_bvector(__first, _Bit_iterator(__first._M_p + 1, 0), __x); > __fill_bvector(_Bit_iterator(__last._M_p, 0), __last, __x); > } > else > __fill_bvector(__first, __last, __x); > } > > template<typename _Alloc> > struct _Bvector_base > { > typedef typename _Alloc::template rebind<_Bit_type>::other > _Bit_alloc_type; > > struct _Bvector_impl > : public _Bit_alloc_type > { > _Bit_iterator _M_start; > _Bit_iterator _M_finish; > _Bit_type* _M_end_of_storage; > > _Bvector_impl() > : _Bit_alloc_type(), _M_start(), _M_finish(), _M_end_of_storage(0) > { } > > _Bvector_impl(const _Bit_alloc_type& __a) > : _Bit_alloc_type(__a), _M_start(), _M_finish(), _M_end_of_storage(0) > { } > > > _Bvector_impl(_Bit_alloc_type&& __a) > : _Bit_alloc_type(std::move(__a)), _M_start(), _M_finish(), > _M_end_of_storage(0) > { } > > }; > > public: > typedef _Alloc allocator_type; > > _Bit_alloc_type& > _M_get_Bit_allocator() noexcept > { return *static_cast<_Bit_alloc_type*>(&this->_M_impl); } > > const _Bit_alloc_type& > _M_get_Bit_allocator() const noexcept > { return *static_cast<const _Bit_alloc_type*>(&this->_M_impl); } > > allocator_type > get_allocator() const noexcept > { return allocator_type(_M_get_Bit_allocator()); } > > _Bvector_base() > : _M_impl() { } > > _Bvector_base(const allocator_type& __a) > : _M_impl(__a) { } > > > _Bvector_base(_Bvector_base&& __x) noexcept > : _M_impl(std::move(__x._M_get_Bit_allocator())) > { > this->_M_impl._M_start = __x._M_impl._M_start; > this->_M_impl._M_finish = __x._M_impl._M_finish; > this->_M_impl._M_end_of_storage = __x._M_impl._M_end_of_storage; > __x._M_impl._M_start = _Bit_iterator(); > __x._M_impl._M_finish = _Bit_iterator(); > __x._M_impl._M_end_of_storage = 0; > } > > > ~_Bvector_base() > { this->_M_deallocate(); } > > protected: > _Bvector_impl _M_impl; > > _Bit_type* > _M_allocate(size_t __n) > { return _M_impl.allocate(_S_nword(__n)); } > > void > _M_deallocate() > { > if (_M_impl._M_start._M_p) > _M_impl.deallocate(_M_impl._M_start._M_p, > _M_impl._M_end_of_storage - _M_impl._M_start._M_p); > } > > static size_t > _S_nword(size_t __n) > { return (__n + int(_S_word_bit) - 1) / int(_S_word_bit); } > }; > > >} > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 525 "/usr/include/c++/4.9.0/bits/stl_bvector.h" 3 >template<typename _Alloc> > class vector<bool, _Alloc> : protected _Bvector_base<_Alloc> > { > typedef _Bvector_base<_Alloc> _Base; > > > template<typename> friend struct hash; > > > public: > typedef bool value_type; > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef _Bit_reference reference; > typedef bool const_reference; > typedef _Bit_reference* pointer; > typedef const bool* const_pointer; > typedef _Bit_iterator iterator; > typedef _Bit_const_iterator const_iterator; > typedef std::reverse_iterator<const_iterator> const_reverse_iterator; > typedef std::reverse_iterator<iterator> reverse_iterator; > typedef _Alloc allocator_type; > > allocator_type get_allocator() const > { return _Base::get_allocator(); } > > protected: > using _Base::_M_allocate; > using _Base::_M_deallocate; > using _Base::_S_nword; > using _Base::_M_get_Bit_allocator; > > public: > vector() > : _Base() { } > > explicit > vector(const allocator_type& __a) > : _Base(__a) { } > > > explicit > vector(size_type __n, const allocator_type& __a = allocator_type()) > : vector(__n, false, __a) > { } > > vector(size_type __n, const bool& __value, > const allocator_type& __a = allocator_type()) > : _Base(__a) > { > _M_initialize(__n); > std::fill(this->_M_impl._M_start._M_p, this->_M_impl._M_end_of_storage, > __value ? ~0 : 0); > } ># 591 "/usr/include/c++/4.9.0/bits/stl_bvector.h" 3 > vector(const vector& __x) > : _Base(__x._M_get_Bit_allocator()) > { > _M_initialize(__x.size()); > _M_copy_aligned(__x.begin(), __x.end(), this->_M_impl._M_start); > } > > > vector(vector&& __x) noexcept > : _Base(std::move(__x)) { } > > vector(initializer_list<bool> __l, > const allocator_type& __a = allocator_type()) > : _Base(__a) > { > _M_initialize_range(__l.begin(), __l.end(), > random_access_iterator_tag()); > } > > > > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > vector(_InputIterator __first, _InputIterator __last, > const allocator_type& __a = allocator_type()) > : _Base(__a) > { _M_initialize_dispatch(__first, __last, __false_type()); } ># 629 "/usr/include/c++/4.9.0/bits/stl_bvector.h" 3 > ~vector() noexcept { } > > vector& > operator=(const vector& __x) > { > if (&__x == this) > return *this; > if (__x.size() > capacity()) > { > this->_M_deallocate(); > _M_initialize(__x.size()); > } > this->_M_impl._M_finish = _M_copy_aligned(__x.begin(), __x.end(), > begin()); > return *this; > } > > > vector& > operator=(vector&& __x) > { > > > this->clear(); > this->swap(__x); > return *this; > } > > vector& > operator=(initializer_list<bool> __l) > { > this->assign (__l.begin(), __l.end()); > return *this; > } > > > > > > > void > assign(size_type __n, const bool& __x) > { _M_fill_assign(__n, __x); } > > > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > void > assign(_InputIterator __first, _InputIterator __last) > { _M_assign_dispatch(__first, __last, __false_type()); } ># 690 "/usr/include/c++/4.9.0/bits/stl_bvector.h" 3 > void > assign(initializer_list<bool> __l) > { this->assign(__l.begin(), __l.end()); } > > > iterator > begin() noexcept > { return this->_M_impl._M_start; } > > const_iterator > begin() const noexcept > { return this->_M_impl._M_start; } > > iterator > end() noexcept > { return this->_M_impl._M_finish; } > > const_iterator > end() const noexcept > { return this->_M_impl._M_finish; } > > reverse_iterator > rbegin() noexcept > { return reverse_iterator(end()); } > > const_reverse_iterator > rbegin() const noexcept > { return const_reverse_iterator(end()); } > > reverse_iterator > rend() noexcept > { return reverse_iterator(begin()); } > > const_reverse_iterator > rend() const noexcept > { return const_reverse_iterator(begin()); } > > > const_iterator > cbegin() const noexcept > { return this->_M_impl._M_start; } > > const_iterator > cend() const noexcept > { return this->_M_impl._M_finish; } > > const_reverse_iterator > crbegin() const noexcept > { return const_reverse_iterator(end()); } > > const_reverse_iterator > crend() const noexcept > { return const_reverse_iterator(begin()); } > > > size_type > size() const noexcept > { return size_type(end() - begin()); } > > size_type > max_size() const noexcept > { > const size_type __isize = > __gnu_cxx::__numeric_traits<difference_type>::__max > - int(_S_word_bit) + 1; > const size_type __asize = _M_get_Bit_allocator().max_size(); > return (__asize <= __isize / int(_S_word_bit) > ? __asize * int(_S_word_bit) : __isize); > } > > size_type > capacity() const noexcept > { return size_type(const_iterator(this->_M_impl._M_end_of_storage, 0) > - begin()); } > > bool > empty() const noexcept > { return begin() == end(); } > > reference > operator[](size_type __n) > { > return *iterator(this->_M_impl._M_start._M_p > + __n / int(_S_word_bit), __n % int(_S_word_bit)); > } > > const_reference > operator[](size_type __n) const > { > return *const_iterator(this->_M_impl._M_start._M_p > + __n / int(_S_word_bit), __n % int(_S_word_bit)); > } > > protected: > void > _M_range_check(size_type __n) const > { > if (__n >= this->size()) > __throw_out_of_range_fmt(("vector<bool>::_M_range_check: __n " "(which is %zu) >= this->size() " "(which is %zu)") > > , > __n, this->size()); > } > > public: > reference > at(size_type __n) > { _M_range_check(__n); return (*this)[__n]; } > > const_reference > at(size_type __n) const > { _M_range_check(__n); return (*this)[__n]; } > > void > reserve(size_type __n) > { > if (__n > max_size()) > __throw_length_error(("vector::reserve")); > if (capacity() < __n) > _M_reallocate(__n); > } > > reference > front() > { return *begin(); } > > const_reference > front() const > { return *begin(); } > > reference > back() > { return *(end() - 1); } > > const_reference > back() const > { return *(end() - 1); } > > > > > > > void > data() noexcept { } > > void > push_back(bool __x) > { > if (this->_M_impl._M_finish._M_p != this->_M_impl._M_end_of_storage) > *this->_M_impl._M_finish++ = __x; > else > _M_insert_aux(end(), __x); > } > > void > swap(vector& __x) > { > std::swap(this->_M_impl._M_start, __x._M_impl._M_start); > std::swap(this->_M_impl._M_finish, __x._M_impl._M_finish); > std::swap(this->_M_impl._M_end_of_storage, > __x._M_impl._M_end_of_storage); > > > > std::__alloc_swap<typename _Base::_Bit_alloc_type>:: > _S_do_it(_M_get_Bit_allocator(), __x._M_get_Bit_allocator()); > } > > > static void > swap(reference __x, reference __y) noexcept > { > bool __tmp = __x; > __x = __y; > __y = __tmp; > } > > iterator > > insert(const_iterator __position, const bool& __x = bool()) > > > > { > const difference_type __n = __position - begin(); > if (this->_M_impl._M_finish._M_p != this->_M_impl._M_end_of_storage > && __position == end()) > *this->_M_impl._M_finish++ = __x; > else > _M_insert_aux(__position._M_const_cast(), __x); > return begin() + __n; > } > > > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > iterator > insert(const_iterator __position, > _InputIterator __first, _InputIterator __last) > { > difference_type __offset = __position - cbegin(); > _M_insert_dispatch(__position._M_const_cast(), > __first, __last, __false_type()); > return begin() + __offset; > } ># 908 "/usr/include/c++/4.9.0/bits/stl_bvector.h" 3 > iterator > insert(const_iterator __position, size_type __n, const bool& __x) > { > difference_type __offset = __position - cbegin(); > _M_fill_insert(__position._M_const_cast(), __n, __x); > return begin() + __offset; > } > > > > > > > > iterator > insert(const_iterator __p, initializer_list<bool> __l) > { return this->insert(__p, __l.begin(), __l.end()); } > > > void > pop_back() > { --this->_M_impl._M_finish; } > > iterator > > erase(const_iterator __position) > > > > { return _M_erase(__position._M_const_cast()); } > > iterator > > erase(const_iterator __first, const_iterator __last) > > > > { return _M_erase(__first._M_const_cast(), __last._M_const_cast()); } > > void > resize(size_type __new_size, bool __x = bool()) > { > if (__new_size < size()) > _M_erase_at_end(begin() + difference_type(__new_size)); > else > insert(end(), __new_size - size(), __x); > } > > > void > shrink_to_fit() > { _M_shrink_to_fit(); } > > > void > flip() noexcept > { > for (_Bit_type * __p = this->_M_impl._M_start._M_p; > __p != this->_M_impl._M_end_of_storage; ++__p) > *__p = ~*__p; > } > > void > clear() noexcept > { _M_erase_at_end(begin()); } > > > template<typename... _Args> > void > emplace_back(_Args&&... __args) > { push_back(bool(__args...)); } > > template<typename... _Args> > iterator > emplace(const_iterator __pos, _Args&&... __args) > { return insert(__pos, bool(__args...)); } > > > protected: > > iterator > _M_copy_aligned(const_iterator __first, const_iterator __last, > iterator __result) > { > _Bit_type* __q = std::copy(__first._M_p, __last._M_p, __result._M_p); > return std::copy(const_iterator(__last._M_p, 0), __last, > iterator(__q, 0)); > } > > void > _M_initialize(size_type __n) > { > _Bit_type* __q = this->_M_allocate(__n); > this->_M_impl._M_end_of_storage = __q + _S_nword(__n); > this->_M_impl._M_start = iterator(__q, 0); > this->_M_impl._M_finish = this->_M_impl._M_start + difference_type(__n); > } > > void > _M_reallocate(size_type __n); > > > bool > _M_shrink_to_fit(); > > > > > > > template<typename _Integer> > void > _M_initialize_dispatch(_Integer __n, _Integer __x, __true_type) > { > _M_initialize(static_cast<size_type>(__n)); > std::fill(this->_M_impl._M_start._M_p, > this->_M_impl._M_end_of_storage, __x ? ~0 : 0); > } > > template<typename _InputIterator> > void > _M_initialize_dispatch(_InputIterator __first, _InputIterator __last, > __false_type) > { _M_initialize_range(__first, __last, > std::__iterator_category(__first)); } > > template<typename _InputIterator> > void > _M_initialize_range(_InputIterator __first, _InputIterator __last, > std::input_iterator_tag) > { > for (; __first != __last; ++__first) > push_back(*__first); > } > > template<typename _ForwardIterator> > void > _M_initialize_range(_ForwardIterator __first, _ForwardIterator __last, > std::forward_iterator_tag) > { > const size_type __n = std::distance(__first, __last); > _M_initialize(__n); > std::copy(__first, __last, this->_M_impl._M_start); > } > > > > template<typename _Integer> > void > _M_assign_dispatch(_Integer __n, _Integer __val, __true_type) > { _M_fill_assign(__n, __val); } > > template<class _InputIterator> > void > _M_assign_dispatch(_InputIterator __first, _InputIterator __last, > __false_type) > { _M_assign_aux(__first, __last, std::__iterator_category(__first)); } > > void > _M_fill_assign(size_t __n, bool __x) > { > if (__n > size()) > { > std::fill(this->_M_impl._M_start._M_p, > this->_M_impl._M_end_of_storage, __x ? ~0 : 0); > insert(end(), __n - size(), __x); > } > else > { > _M_erase_at_end(begin() + __n); > std::fill(this->_M_impl._M_start._M_p, > this->_M_impl._M_end_of_storage, __x ? ~0 : 0); > } > } > > template<typename _InputIterator> > void > _M_assign_aux(_InputIterator __first, _InputIterator __last, > std::input_iterator_tag) > { > iterator __cur = begin(); > for (; __first != __last && __cur != end(); ++__cur, ++__first) > *__cur = *__first; > if (__first == __last) > _M_erase_at_end(__cur); > else > insert(end(), __first, __last); > } > > template<typename _ForwardIterator> > void > _M_assign_aux(_ForwardIterator __first, _ForwardIterator __last, > std::forward_iterator_tag) > { > const size_type __len = std::distance(__first, __last); > if (__len < size()) > _M_erase_at_end(std::copy(__first, __last, begin())); > else > { > _ForwardIterator __mid = __first; > std::advance(__mid, size()); > std::copy(__first, __mid, begin()); > insert(end(), __mid, __last); > } > } > > > > > > template<typename _Integer> > void > _M_insert_dispatch(iterator __pos, _Integer __n, _Integer __x, > __true_type) > { _M_fill_insert(__pos, __n, __x); } > > template<typename _InputIterator> > void > _M_insert_dispatch(iterator __pos, > _InputIterator __first, _InputIterator __last, > __false_type) > { _M_insert_range(__pos, __first, __last, > std::__iterator_category(__first)); } > > void > _M_fill_insert(iterator __position, size_type __n, bool __x); > > template<typename _InputIterator> > void > _M_insert_range(iterator __pos, _InputIterator __first, > _InputIterator __last, std::input_iterator_tag) > { > for (; __first != __last; ++__first) > { > __pos = insert(__pos, *__first); > ++__pos; > } > } > > template<typename _ForwardIterator> > void > _M_insert_range(iterator __position, _ForwardIterator __first, > _ForwardIterator __last, std::forward_iterator_tag); > > void > _M_insert_aux(iterator __position, bool __x); > > size_type > _M_check_len(size_type __n, const char* __s) const > { > if (max_size() - size() < __n) > __throw_length_error((__s)); > > const size_type __len = size() + std::max(size(), __n); > return (__len < size() || __len > max_size()) ? max_size() : __len; > } > > void > _M_erase_at_end(iterator __pos) > { this->_M_impl._M_finish = __pos; } > > iterator > _M_erase(iterator __pos); > > iterator > _M_erase(iterator __first, iterator __last); > }; > > >} > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > template<typename _Alloc> > struct hash<std::vector<bool, _Alloc>> > : public __hash_base<size_t, std::vector<bool, _Alloc>> > { > size_t > operator()(const std::vector<bool, _Alloc>&) const noexcept; > }; > > >} ># 66 "/usr/include/c++/4.9.0/vector" 2 3 > > > ># 1 "/usr/include/c++/4.9.0/bits/vector.tcc" 1 3 ># 59 "/usr/include/c++/4.9.0/bits/vector.tcc" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Tp, typename _Alloc> > void > vector<_Tp, _Alloc>:: > reserve(size_type __n) > { > if (__n > this->max_size()) > __throw_length_error(("vector::reserve")); > if (this->capacity() < __n) > { > const size_type __old_size = size(); > pointer __tmp = _M_allocate_and_copy(__n, > std::__make_move_if_noexcept_iterator(this->_M_impl._M_start), > std::__make_move_if_noexcept_iterator(this->_M_impl._M_finish)); > std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish, > _M_get_Tp_allocator()); > _M_deallocate(this->_M_impl._M_start, > this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); > this->_M_impl._M_start = __tmp; > this->_M_impl._M_finish = __tmp + __old_size; > this->_M_impl._M_end_of_storage = this->_M_impl._M_start + __n; > } > } > > > template<typename _Tp, typename _Alloc> > template<typename... _Args> > void > vector<_Tp, _Alloc>:: > emplace_back(_Args&&... __args) > { > if (this->_M_impl._M_finish != this->_M_impl._M_end_of_storage) > { > _Alloc_traits::construct(this->_M_impl, this->_M_impl._M_finish, > std::forward<_Args>(__args)...); > ++this->_M_impl._M_finish; > } > else > _M_emplace_back_aux(std::forward<_Args>(__args)...); > } > > > template<typename _Tp, typename _Alloc> > typename vector<_Tp, _Alloc>::iterator > vector<_Tp, _Alloc>:: > > insert(const_iterator __position, const value_type& __x) > > > > { > const size_type __n = __position - begin(); > if (this->_M_impl._M_finish != this->_M_impl._M_end_of_storage > && __position == end()) > { > _Alloc_traits::construct(this->_M_impl, this->_M_impl._M_finish, __x); > ++this->_M_impl._M_finish; > } > else > { > > if (this->_M_impl._M_finish != this->_M_impl._M_end_of_storage) > { > _Tp __x_copy = __x; > _M_insert_aux(__position._M_const_cast(), std::move(__x_copy)); > } > else > > _M_insert_aux(__position._M_const_cast(), __x); > } > return iterator(this->_M_impl._M_start + __n); > } > > template<typename _Tp, typename _Alloc> > typename vector<_Tp, _Alloc>::iterator > vector<_Tp, _Alloc>:: > _M_erase(iterator __position) > { > if (__position + 1 != end()) > std::move(__position + 1, end(), __position); > --this->_M_impl._M_finish; > _Alloc_traits::destroy(this->_M_impl, this->_M_impl._M_finish); > return __position; > } > > template<typename _Tp, typename _Alloc> > typename vector<_Tp, _Alloc>::iterator > vector<_Tp, _Alloc>:: > _M_erase(iterator __first, iterator __last) > { > if (__first != __last) > { > if (__last != end()) > std::move(__last, end(), __first); > _M_erase_at_end(__first.base() + (end() - __last)); > } > return __first; > } > > template<typename _Tp, typename _Alloc> > vector<_Tp, _Alloc>& > vector<_Tp, _Alloc>:: > operator=(const vector<_Tp, _Alloc>& __x) > { > if (&__x != this) > { > > if (_Alloc_traits::_S_propagate_on_copy_assign()) > { > if (!_Alloc_traits::_S_always_equal() > && _M_get_Tp_allocator() != __x._M_get_Tp_allocator()) > { > > this->clear(); > _M_deallocate(this->_M_impl._M_start, > this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); > this->_M_impl._M_start = nullptr; > this->_M_impl._M_finish = nullptr; > this->_M_impl._M_end_of_storage = nullptr; > } > std::__alloc_on_copy(_M_get_Tp_allocator(), > __x._M_get_Tp_allocator()); > } > > const size_type __xlen = __x.size(); > if (__xlen > capacity()) > { > pointer __tmp = _M_allocate_and_copy(__xlen, __x.begin(), > __x.end()); > std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish, > _M_get_Tp_allocator()); > _M_deallocate(this->_M_impl._M_start, > this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); > this->_M_impl._M_start = __tmp; > this->_M_impl._M_end_of_storage = this->_M_impl._M_start + __xlen; > } > else if (size() >= __xlen) > { > std::_Destroy(std::copy(__x.begin(), __x.end(), begin()), > end(), _M_get_Tp_allocator()); > } > else > { > std::copy(__x._M_impl._M_start, __x._M_impl._M_start + size(), > this->_M_impl._M_start); > std::__uninitialized_copy_a(__x._M_impl._M_start + size(), > __x._M_impl._M_finish, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > } > this->_M_impl._M_finish = this->_M_impl._M_start + __xlen; > } > return *this; > } > > template<typename _Tp, typename _Alloc> > void > vector<_Tp, _Alloc>:: > _M_fill_assign(size_t __n, const value_type& __val) > { > if (__n > capacity()) > { > vector __tmp(__n, __val, _M_get_Tp_allocator()); > __tmp.swap(*this); > } > else if (__n > size()) > { > std::fill(begin(), end(), __val); > std::__uninitialized_fill_n_a(this->_M_impl._M_finish, > __n - size(), __val, > _M_get_Tp_allocator()); > this->_M_impl._M_finish += __n - size(); > } > else > _M_erase_at_end(std::fill_n(this->_M_impl._M_start, __n, __val)); > } > > template<typename _Tp, typename _Alloc> > template<typename _InputIterator> > void > vector<_Tp, _Alloc>:: > _M_assign_aux(_InputIterator __first, _InputIterator __last, > std::input_iterator_tag) > { > pointer __cur(this->_M_impl._M_start); > for (; __first != __last && __cur != this->_M_impl._M_finish; > ++__cur, ++__first) > *__cur = *__first; > if (__first == __last) > _M_erase_at_end(__cur); > else > insert(end(), __first, __last); > } > > template<typename _Tp, typename _Alloc> > template<typename _ForwardIterator> > void > vector<_Tp, _Alloc>:: > _M_assign_aux(_ForwardIterator __first, _ForwardIterator __last, > std::forward_iterator_tag) > { > const size_type __len = std::distance(__first, __last); > > if (__len > capacity()) > { > pointer __tmp(_M_allocate_and_copy(__len, __first, __last)); > std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish, > _M_get_Tp_allocator()); > _M_deallocate(this->_M_impl._M_start, > this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); > this->_M_impl._M_start = __tmp; > this->_M_impl._M_finish = this->_M_impl._M_start + __len; > this->_M_impl._M_end_of_storage = this->_M_impl._M_finish; > } > else if (size() >= __len) > _M_erase_at_end(std::copy(__first, __last, this->_M_impl._M_start)); > else > { > _ForwardIterator __mid = __first; > std::advance(__mid, size()); > std::copy(__first, __mid, this->_M_impl._M_start); > this->_M_impl._M_finish = > std::__uninitialized_copy_a(__mid, __last, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > } > } > > > template<typename _Tp, typename _Alloc> > template<typename... _Args> > typename vector<_Tp, _Alloc>::iterator > vector<_Tp, _Alloc>:: > emplace(const_iterator __position, _Args&&... __args) > { > const size_type __n = __position - begin(); > if (this->_M_impl._M_finish != this->_M_impl._M_end_of_storage > && __position == end()) > { > _Alloc_traits::construct(this->_M_impl, this->_M_impl._M_finish, > std::forward<_Args>(__args)...); > ++this->_M_impl._M_finish; > } > else > _M_insert_aux(__position._M_const_cast(), > std::forward<_Args>(__args)...); > return iterator(this->_M_impl._M_start + __n); > } > > template<typename _Tp, typename _Alloc> > template<typename... _Args> > void > vector<_Tp, _Alloc>:: > _M_insert_aux(iterator __position, _Args&&... __args) > > > > > > > { > if (this->_M_impl._M_finish != this->_M_impl._M_end_of_storage) > { > _Alloc_traits::construct(this->_M_impl, this->_M_impl._M_finish, > std::move(*(this->_M_impl._M_finish - 1)) > ); > ++this->_M_impl._M_finish; > > > > std::move_backward(__position.base(), this->_M_impl._M_finish - 2, this->_M_impl._M_finish - 1) > > ; > > > > *__position = _Tp(std::forward<_Args>(__args)...); > > } > else > { > const size_type __len = > _M_check_len(size_type(1), "vector::_M_insert_aux"); > const size_type __elems_before = __position - begin(); > pointer __new_start(this->_M_allocate(__len)); > pointer __new_finish(__new_start); > try > { > > > > > _Alloc_traits::construct(this->_M_impl, > __new_start + __elems_before, > > std::forward<_Args>(__args)...); > > > > __new_finish = 0; > > __new_finish > = std::__uninitialized_move_if_noexcept_a > (this->_M_impl._M_start, __position.base(), > __new_start, _M_get_Tp_allocator()); > > ++__new_finish; > > __new_finish > = std::__uninitialized_move_if_noexcept_a > (__position.base(), this->_M_impl._M_finish, > __new_finish, _M_get_Tp_allocator()); > } > catch(...) > { > if (!__new_finish) > _Alloc_traits::destroy(this->_M_impl, > __new_start + __elems_before); > else > std::_Destroy(__new_start, __new_finish, _M_get_Tp_allocator()); > _M_deallocate(__new_start, __len); > throw; > } > std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish, > _M_get_Tp_allocator()); > _M_deallocate(this->_M_impl._M_start, > this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); > this->_M_impl._M_start = __new_start; > this->_M_impl._M_finish = __new_finish; > this->_M_impl._M_end_of_storage = __new_start + __len; > } > } > > > template<typename _Tp, typename _Alloc> > template<typename... _Args> > void > vector<_Tp, _Alloc>:: > _M_emplace_back_aux(_Args&&... __args) > { > const size_type __len = > _M_check_len(size_type(1), "vector::_M_emplace_back_aux"); > pointer __new_start(this->_M_allocate(__len)); > pointer __new_finish(__new_start); > try > { > _Alloc_traits::construct(this->_M_impl, __new_start + size(), > std::forward<_Args>(__args)...); > __new_finish = 0; > > __new_finish > = std::__uninitialized_move_if_noexcept_a > (this->_M_impl._M_start, this->_M_impl._M_finish, > __new_start, _M_get_Tp_allocator()); > > ++__new_finish; > } > catch(...) > { > if (!__new_finish) > _Alloc_traits::destroy(this->_M_impl, __new_start + size()); > else > std::_Destroy(__new_start, __new_finish, _M_get_Tp_allocator()); > _M_deallocate(__new_start, __len); > throw; > } > std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish, > _M_get_Tp_allocator()); > _M_deallocate(this->_M_impl._M_start, > this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); > this->_M_impl._M_start = __new_start; > this->_M_impl._M_finish = __new_finish; > this->_M_impl._M_end_of_storage = __new_start + __len; > } > > > template<typename _Tp, typename _Alloc> > void > vector<_Tp, _Alloc>:: > _M_fill_insert(iterator __position, size_type __n, const value_type& __x) > { > if (__n != 0) > { > if (size_type(this->_M_impl._M_end_of_storage > - this->_M_impl._M_finish) >= __n) > { > value_type __x_copy = __x; > const size_type __elems_after = end() - __position; > pointer __old_finish(this->_M_impl._M_finish); > if (__elems_after > __n) > { > std::__uninitialized_move_a(this->_M_impl._M_finish - __n, > this->_M_impl._M_finish, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish += __n; > std::move_backward(__position.base(), __old_finish - __n, __old_finish) > ; > std::fill(__position.base(), __position.base() + __n, > __x_copy); > } > else > { > std::__uninitialized_fill_n_a(this->_M_impl._M_finish, > __n - __elems_after, > __x_copy, > _M_get_Tp_allocator()); > this->_M_impl._M_finish += __n - __elems_after; > std::__uninitialized_move_a(__position.base(), __old_finish, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish += __elems_after; > std::fill(__position.base(), __old_finish, __x_copy); > } > } > else > { > const size_type __len = > _M_check_len(__n, "vector::_M_fill_insert"); > const size_type __elems_before = __position - begin(); > pointer __new_start(this->_M_allocate(__len)); > pointer __new_finish(__new_start); > try > { > > std::__uninitialized_fill_n_a(__new_start + __elems_before, > __n, __x, > _M_get_Tp_allocator()); > __new_finish = 0; > > __new_finish > = std::__uninitialized_move_if_noexcept_a > (this->_M_impl._M_start, __position.base(), > __new_start, _M_get_Tp_allocator()); > > __new_finish += __n; > > __new_finish > = std::__uninitialized_move_if_noexcept_a > (__position.base(), this->_M_impl._M_finish, > __new_finish, _M_get_Tp_allocator()); > } > catch(...) > { > if (!__new_finish) > std::_Destroy(__new_start + __elems_before, > __new_start + __elems_before + __n, > _M_get_Tp_allocator()); > else > std::_Destroy(__new_start, __new_finish, > _M_get_Tp_allocator()); > _M_deallocate(__new_start, __len); > throw; > } > std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish, > _M_get_Tp_allocator()); > _M_deallocate(this->_M_impl._M_start, > this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); > this->_M_impl._M_start = __new_start; > this->_M_impl._M_finish = __new_finish; > this->_M_impl._M_end_of_storage = __new_start + __len; > } > } > } > > > template<typename _Tp, typename _Alloc> > void > vector<_Tp, _Alloc>:: > _M_default_append(size_type __n) > { > if (__n != 0) > { > if (size_type(this->_M_impl._M_end_of_storage > - this->_M_impl._M_finish) >= __n) > { > std::__uninitialized_default_n_a(this->_M_impl._M_finish, > __n, _M_get_Tp_allocator()); > this->_M_impl._M_finish += __n; > } > else > { > const size_type __len = > _M_check_len(__n, "vector::_M_default_append"); > const size_type __old_size = this->size(); > pointer __new_start(this->_M_allocate(__len)); > pointer __new_finish(__new_start); > try > { > __new_finish > = std::__uninitialized_move_if_noexcept_a > (this->_M_impl._M_start, this->_M_impl._M_finish, > __new_start, _M_get_Tp_allocator()); > std::__uninitialized_default_n_a(__new_finish, __n, > _M_get_Tp_allocator()); > __new_finish += __n; > } > catch(...) > { > std::_Destroy(__new_start, __new_finish, > _M_get_Tp_allocator()); > _M_deallocate(__new_start, __len); > throw; > } > std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish, > _M_get_Tp_allocator()); > _M_deallocate(this->_M_impl._M_start, > this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); > this->_M_impl._M_start = __new_start; > this->_M_impl._M_finish = __new_finish; > this->_M_impl._M_end_of_storage = __new_start + __len; > } > } > } > > template<typename _Tp, typename _Alloc> > bool > vector<_Tp, _Alloc>:: > _M_shrink_to_fit() > { > if (capacity() == size()) > return false; > return std::__shrink_to_fit_aux<vector>::_S_do_it(*this); > } > > > template<typename _Tp, typename _Alloc> > template<typename _InputIterator> > void > vector<_Tp, _Alloc>:: > _M_range_insert(iterator __pos, _InputIterator __first, > _InputIterator __last, std::input_iterator_tag) > { > for (; __first != __last; ++__first) > { > __pos = insert(__pos, *__first); > ++__pos; > } > } > > template<typename _Tp, typename _Alloc> > template<typename _ForwardIterator> > void > vector<_Tp, _Alloc>:: > _M_range_insert(iterator __position, _ForwardIterator __first, > _ForwardIterator __last, std::forward_iterator_tag) > { > if (__first != __last) > { > const size_type __n = std::distance(__first, __last); > if (size_type(this->_M_impl._M_end_of_storage > - this->_M_impl._M_finish) >= __n) > { > const size_type __elems_after = end() - __position; > pointer __old_finish(this->_M_impl._M_finish); > if (__elems_after > __n) > { > std::__uninitialized_move_a(this->_M_impl._M_finish - __n, > this->_M_impl._M_finish, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish += __n; > std::move_backward(__position.base(), __old_finish - __n, __old_finish) > ; > std::copy(__first, __last, __position); > } > else > { > _ForwardIterator __mid = __first; > std::advance(__mid, __elems_after); > std::__uninitialized_copy_a(__mid, __last, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish += __n - __elems_after; > std::__uninitialized_move_a(__position.base(), > __old_finish, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish += __elems_after; > std::copy(__first, __mid, __position); > } > } > else > { > const size_type __len = > _M_check_len(__n, "vector::_M_range_insert"); > pointer __new_start(this->_M_allocate(__len)); > pointer __new_finish(__new_start); > try > { > __new_finish > = std::__uninitialized_move_if_noexcept_a > (this->_M_impl._M_start, __position.base(), > __new_start, _M_get_Tp_allocator()); > __new_finish > = std::__uninitialized_copy_a(__first, __last, > __new_finish, > _M_get_Tp_allocator()); > __new_finish > = std::__uninitialized_move_if_noexcept_a > (__position.base(), this->_M_impl._M_finish, > __new_finish, _M_get_Tp_allocator()); > } > catch(...) > { > std::_Destroy(__new_start, __new_finish, > _M_get_Tp_allocator()); > _M_deallocate(__new_start, __len); > throw; > } > std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish, > _M_get_Tp_allocator()); > _M_deallocate(this->_M_impl._M_start, > this->_M_impl._M_end_of_storage > - this->_M_impl._M_start); > this->_M_impl._M_start = __new_start; > this->_M_impl._M_finish = __new_finish; > this->_M_impl._M_end_of_storage = __new_start + __len; > } > } > } > > > > template<typename _Alloc> > void > vector<bool, _Alloc>:: > _M_reallocate(size_type __n) > { > _Bit_type* __q = this->_M_allocate(__n); > this->_M_impl._M_finish = _M_copy_aligned(begin(), end(), > iterator(__q, 0)); > this->_M_deallocate(); > this->_M_impl._M_start = iterator(__q, 0); > this->_M_impl._M_end_of_storage = __q + _S_nword(__n); > } > > template<typename _Alloc> > void > vector<bool, _Alloc>:: > _M_fill_insert(iterator __position, size_type __n, bool __x) > { > if (__n == 0) > return; > if (capacity() - size() >= __n) > { > std::copy_backward(__position, end(), > this->_M_impl._M_finish + difference_type(__n)); > std::fill(__position, __position + difference_type(__n), __x); > this->_M_impl._M_finish += difference_type(__n); > } > else > { > const size_type __len = > _M_check_len(__n, "vector<bool>::_M_fill_insert"); > _Bit_type * __q = this->_M_allocate(__len); > iterator __i = _M_copy_aligned(begin(), __position, > iterator(__q, 0)); > std::fill(__i, __i + difference_type(__n), __x); > this->_M_impl._M_finish = std::copy(__position, end(), > __i + difference_type(__n)); > this->_M_deallocate(); > this->_M_impl._M_end_of_storage = __q + _S_nword(__len); > this->_M_impl._M_start = iterator(__q, 0); > } > } > > template<typename _Alloc> > template<typename _ForwardIterator> > void > vector<bool, _Alloc>:: > _M_insert_range(iterator __position, _ForwardIterator __first, > _ForwardIterator __last, std::forward_iterator_tag) > { > if (__first != __last) > { > size_type __n = std::distance(__first, __last); > if (capacity() - size() >= __n) > { > std::copy_backward(__position, end(), > this->_M_impl._M_finish > + difference_type(__n)); > std::copy(__first, __last, __position); > this->_M_impl._M_finish += difference_type(__n); > } > else > { > const size_type __len = > _M_check_len(__n, "vector<bool>::_M_insert_range"); > _Bit_type * __q = this->_M_allocate(__len); > iterator __i = _M_copy_aligned(begin(), __position, > iterator(__q, 0)); > __i = std::copy(__first, __last, __i); > this->_M_impl._M_finish = std::copy(__position, end(), __i); > this->_M_deallocate(); > this->_M_impl._M_end_of_storage = __q + _S_nword(__len); > this->_M_impl._M_start = iterator(__q, 0); > } > } > } > > template<typename _Alloc> > void > vector<bool, _Alloc>:: > _M_insert_aux(iterator __position, bool __x) > { > if (this->_M_impl._M_finish._M_p != this->_M_impl._M_end_of_storage) > { > std::copy_backward(__position, this->_M_impl._M_finish, > this->_M_impl._M_finish + 1); > *__position = __x; > ++this->_M_impl._M_finish; > } > else > { > const size_type __len = > _M_check_len(size_type(1), "vector<bool>::_M_insert_aux"); > _Bit_type * __q = this->_M_allocate(__len); > iterator __i = _M_copy_aligned(begin(), __position, > iterator(__q, 0)); > *__i++ = __x; > this->_M_impl._M_finish = std::copy(__position, end(), __i); > this->_M_deallocate(); > this->_M_impl._M_end_of_storage = __q + _S_nword(__len); > this->_M_impl._M_start = iterator(__q, 0); > } > } > > template<typename _Alloc> > typename vector<bool, _Alloc>::iterator > vector<bool, _Alloc>:: > _M_erase(iterator __position) > { > if (__position + 1 != end()) > std::copy(__position + 1, end(), __position); > --this->_M_impl._M_finish; > return __position; > } > > template<typename _Alloc> > typename vector<bool, _Alloc>::iterator > vector<bool, _Alloc>:: > _M_erase(iterator __first, iterator __last) > { > if (__first != __last) > _M_erase_at_end(std::copy(__last, end(), __first)); > return __first; > } > > > template<typename _Alloc> > bool > vector<bool, _Alloc>:: > _M_shrink_to_fit() > { > if (capacity() - size() < int(_S_word_bit)) > return false; > try > { > _M_reallocate(size()); > return true; > } > catch(...) > { return false; } > } > > > >} > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Alloc> > size_t > hash<std::vector<bool, _Alloc>>:: > operator()(const std::vector<bool, _Alloc>& __b) const noexcept > { > size_t __hash = 0; > using std::_S_word_bit; > using std::_Bit_type; > > const size_t __words = __b.size() / _S_word_bit; > if (__words) > { > const size_t __clength = __words * sizeof(_Bit_type); > __hash = std::_Hash_impl::hash(__b._M_impl._M_start._M_p, __clength); > } > > const size_t __extrabits = __b.size() % _S_word_bit; > if (__extrabits) > { > _Bit_type __hiword = *__b._M_impl._M_finish._M_p; > __hiword &= ~((~static_cast<_Bit_type>(0)) << __extrabits); > > const size_t __clength > = (__extrabits + 8 - 1) / 8; > if (__words) > __hash = std::_Hash_impl::hash(&__hiword, __clength, __hash); > else > __hash = std::_Hash_impl::hash(&__hiword, __clength); > } > > return __hash; > } > > >} ># 70 "/usr/include/c++/4.9.0/vector" 2 3 ># 35 "/usr/include/c++/4.9.0/bits/random.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 55 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, size_t __bits, > typename _UniformRandomNumberGenerator> > _RealType > generate_canonical(_UniformRandomNumberGenerator& __g); > > > > > > > namespace __detail > { > > > template<typename _UIntType, size_t __w, > bool = __w < static_cast<size_t> > (std::numeric_limits<_UIntType>::digits)> > struct _Shift > { static const _UIntType __value = 0; }; > > template<typename _UIntType, size_t __w> > struct _Shift<_UIntType, __w, true> > { static const _UIntType __value = _UIntType(1) << __w; }; > > template<int __s, > int __which = ((__s <= 8 * sizeof (int)) > + (__s <= 8 * sizeof (long)) > + (__s <= 8 * sizeof (long long)) > > + (__s <= 128))> > struct _Select_uint_least_t > { > static_assert(__which < 0, > "sorry, would be too much trouble for a slow result"); > }; > > template<int __s> > struct _Select_uint_least_t<__s, 4> > { typedef unsigned int type; }; > > template<int __s> > struct _Select_uint_least_t<__s, 3> > { typedef unsigned long type; }; > > template<int __s> > struct _Select_uint_least_t<__s, 2> > { typedef unsigned long long type; }; > > > template<int __s> > struct _Select_uint_least_t<__s, 1> > { typedef unsigned __int128 type; }; > > > > template<typename _Tp, _Tp __m, _Tp __a, _Tp __c, > bool __big_enough = (!(__m & (__m - 1)) > || (_Tp(-1) - __c) / __a >= __m - 1), > bool __schrage_ok = __m % __a < __m / __a> > struct _Mod > { > typedef typename _Select_uint_least_t<std::__lg(__a) > + std::__lg(__m) + 2>::type _Tp2; > static _Tp > __calc(_Tp __x) > { return static_cast<_Tp>((_Tp2(__a) * __x + __c) % __m); } > }; > > > template<typename _Tp, _Tp __m, _Tp __a, _Tp __c> > struct _Mod<_Tp, __m, __a, __c, false, true> > { > static _Tp > __calc(_Tp __x); > }; > > > > > template<typename _Tp, _Tp __m, _Tp __a, _Tp __c, bool __s> > struct _Mod<_Tp, __m, __a, __c, true, __s> > { > static _Tp > __calc(_Tp __x) > { > _Tp __res = __a * __x + __c; > if (__m) > __res %= __m; > return __res; > } > }; > > template<typename _Tp, _Tp __m, _Tp __a = 1, _Tp __c = 0> > inline _Tp > __mod(_Tp __x) > { return _Mod<_Tp, __m, __a, __c>::__calc(__x); } > > > template<typename _Tp> > inline bool > _Power_of_2(_Tp __x) > { > return ((__x - 1) & __x) == 0; > }; > > > > > > template<typename _Engine, typename _DInputType> > struct _Adaptor > { > > public: > _Adaptor(_Engine& __g) > : _M_g(__g) { } > > _DInputType > min() const > { return _DInputType(0); } > > _DInputType > max() const > { return _DInputType(1); } > > > > > > > _DInputType > operator()() > { > return std::generate_canonical<_DInputType, > std::numeric_limits<_DInputType>::digits, > _Engine>(_M_g); > } > > private: > _Engine& _M_g; > }; > > > } ># 240 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m> > class linear_congruential_engine > { > static_assert(std::is_unsigned<_UIntType>::value, "template argument " > "substituting _UIntType not an unsigned integral type"); > static_assert(__m == 0u || (__a < __m && __c < __m), > "template argument substituting __m out of bounds"); > > public: > > typedef _UIntType result_type; > > > static constexpr result_type multiplier = __a; > > static constexpr result_type increment = __c; > > static constexpr result_type modulus = __m; > static constexpr result_type default_seed = 1u; ># 267 "/usr/include/c++/4.9.0/bits/random.h" 3 > explicit > linear_congruential_engine(result_type __s = default_seed) > { seed(__s); } > > > > > > > > template<typename _Sseq, typename = typename > std::enable_if<!std::is_same<_Sseq, linear_congruential_engine>::value> > ::type> > explicit > linear_congruential_engine(_Sseq& __q) > { seed(__q); } > > > > > > > > void > seed(result_type __s = default_seed); ># 300 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _Sseq> > typename std::enable_if<std::is_class<_Sseq>::value>::type > seed(_Sseq& __q); > > > > > > > > static constexpr result_type > min() > { return __c == 0u ? 1u : 0u; } > > > > > static constexpr result_type > max() > { return __m - 1u; } > > > > > void > discard(unsigned long long __z) > { > for (; __z != 0ULL; --__z) > (*this)(); > } > > > > > result_type > operator()() > { > _M_x = __detail::__mod<_UIntType, __m, __a, __c>(_M_x); > return _M_x; > } ># 352 "/usr/include/c++/4.9.0/bits/random.h" 3 > friend bool > operator==(const linear_congruential_engine& __lhs, > const linear_congruential_engine& __rhs) > { return __lhs._M_x == __rhs._M_x; } ># 365 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType1, _UIntType1 __a1, _UIntType1 __c1, > _UIntType1 __m1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::linear_congruential_engine<_UIntType1, > __a1, __c1, __m1>& __lcr); ># 385 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType1, _UIntType1 __a1, _UIntType1 __c1, > _UIntType1 __m1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::linear_congruential_engine<_UIntType1, __a1, > __c1, __m1>& __lcr); > > private: > _UIntType _M_x; > }; ># 407 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m> > inline bool > operator!=(const std::linear_congruential_engine<_UIntType, __a, > __c, __m>& __lhs, > const std::linear_congruential_engine<_UIntType, __a, > __c, __m>& __rhs) > { return !(__lhs == __rhs); } ># 444 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType, size_t __w, > size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, > _UIntType __c, size_t __l, _UIntType __f> > class mersenne_twister_engine > { > static_assert(std::is_unsigned<_UIntType>::value, "template argument " > "substituting _UIntType not an unsigned integral type"); > static_assert(1u <= __m && __m <= __n, > "template argument substituting __m out of bounds"); > static_assert(__r <= __w, "template argument substituting " > "__r out of bound"); > static_assert(__u <= __w, "template argument substituting " > "__u out of bound"); > static_assert(__s <= __w, "template argument substituting " > "__s out of bound"); > static_assert(__t <= __w, "template argument substituting " > "__t out of bound"); > static_assert(__l <= __w, "template argument substituting " > "__l out of bound"); > static_assert(__w <= std::numeric_limits<_UIntType>::digits, > "template argument substituting __w out of bound"); > static_assert(__a <= (__detail::_Shift<_UIntType, __w>::__value - 1), > "template argument substituting __a out of bound"); > static_assert(__b <= (__detail::_Shift<_UIntType, __w>::__value - 1), > "template argument substituting __b out of bound"); > static_assert(__c <= (__detail::_Shift<_UIntType, __w>::__value - 1), > "template argument substituting __c out of bound"); > static_assert(__d <= (__detail::_Shift<_UIntType, __w>::__value - 1), > "template argument substituting __d out of bound"); > static_assert(__f <= (__detail::_Shift<_UIntType, __w>::__value - 1), > "template argument substituting __f out of bound"); > > public: > > typedef _UIntType result_type; > > > static constexpr size_t word_size = __w; > static constexpr size_t state_size = __n; > static constexpr size_t shift_size = __m; > static constexpr size_t mask_bits = __r; > static constexpr result_type xor_mask = __a; > static constexpr size_t tempering_u = __u; > static constexpr result_type tempering_d = __d; > static constexpr size_t tempering_s = __s; > static constexpr result_type tempering_b = __b; > static constexpr size_t tempering_t = __t; > static constexpr result_type tempering_c = __c; > static constexpr size_t tempering_l = __l; > static constexpr result_type initialization_multiplier = __f; > static constexpr result_type default_seed = 5489u; > > > explicit > mersenne_twister_engine(result_type __sd = default_seed) > { seed(__sd); } > > > > > > > > template<typename _Sseq, typename = typename > std::enable_if<!std::is_same<_Sseq, mersenne_twister_engine>::value> > ::type> > explicit > mersenne_twister_engine(_Sseq& __q) > { seed(__q); } > > void > seed(result_type __sd = default_seed); > > template<typename _Sseq> > typename std::enable_if<std::is_class<_Sseq>::value>::type > seed(_Sseq& __q); > > > > > static constexpr result_type > min() > { return 0; }; > > > > > static constexpr result_type > max() > { return __detail::_Shift<_UIntType, __w>::__value - 1; } > > > > > void > discard(unsigned long long __z); > > result_type > operator()(); ># 558 "/usr/include/c++/4.9.0/bits/random.h" 3 > friend bool > operator==(const mersenne_twister_engine& __lhs, > const mersenne_twister_engine& __rhs) > { return (std::equal(__lhs._M_x, __lhs._M_x + state_size, __rhs._M_x) > && __lhs._M_p == __rhs._M_p); } ># 576 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType1, > size_t __w1, size_t __n1, > size_t __m1, size_t __r1, > _UIntType1 __a1, size_t __u1, > _UIntType1 __d1, size_t __s1, > _UIntType1 __b1, size_t __t1, > _UIntType1 __c1, size_t __l1, _UIntType1 __f1, > typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::mersenne_twister_engine<_UIntType1, __w1, __n1, > __m1, __r1, __a1, __u1, __d1, __s1, __b1, __t1, __c1, > __l1, __f1>& __x); ># 602 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType1, > size_t __w1, size_t __n1, > size_t __m1, size_t __r1, > _UIntType1 __a1, size_t __u1, > _UIntType1 __d1, size_t __s1, > _UIntType1 __b1, size_t __t1, > _UIntType1 __c1, size_t __l1, _UIntType1 __f1, > typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::mersenne_twister_engine<_UIntType1, __w1, __n1, __m1, > __r1, __a1, __u1, __d1, __s1, __b1, __t1, __c1, > __l1, __f1>& __x); > > private: > void _M_gen_rand(); > > _UIntType _M_x[state_size]; > size_t _M_p; > }; ># 635 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType, size_t __w, > size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, > _UIntType __c, size_t __l, _UIntType __f> > inline bool > operator!=(const std::mersenne_twister_engine<_UIntType, __w, __n, __m, > __r, __a, __u, __d, __s, __b, __t, __c, __l, __f>& __lhs, > const std::mersenne_twister_engine<_UIntType, __w, __n, __m, > __r, __a, __u, __d, __s, __b, __t, __c, __l, __f>& __rhs) > { return !(__lhs == __rhs); } ># 667 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType, size_t __w, size_t __s, size_t __r> > class subtract_with_carry_engine > { > static_assert(std::is_unsigned<_UIntType>::value, "template argument " > "substituting _UIntType not an unsigned integral type"); > static_assert(0u < __s && __s < __r, > "template argument substituting __s out of bounds"); > static_assert(0u < __w && __w <= std::numeric_limits<_UIntType>::digits, > "template argument substituting __w out of bounds"); > > public: > > typedef _UIntType result_type; > > > static constexpr size_t word_size = __w; > static constexpr size_t short_lag = __s; > static constexpr size_t long_lag = __r; > static constexpr result_type default_seed = 19780503u; > > > > > > explicit > subtract_with_carry_engine(result_type __sd = default_seed) > { seed(__sd); } > > > > > > > > template<typename _Sseq, typename = typename > std::enable_if<!std::is_same<_Sseq, subtract_with_carry_engine>::value> > ::type> > explicit > subtract_with_carry_engine(_Sseq& __q) > { seed(__q); } ># 720 "/usr/include/c++/4.9.0/bits/random.h" 3 > void > seed(result_type __sd = default_seed); > > > > > > template<typename _Sseq> > typename std::enable_if<std::is_class<_Sseq>::value>::type > seed(_Sseq& __q); > > > > > > static constexpr result_type > min() > { return 0; } > > > > > > static constexpr result_type > max() > { return __detail::_Shift<_UIntType, __w>::__value - 1; } > > > > > void > discard(unsigned long long __z) > { > for (; __z != 0ULL; --__z) > (*this)(); > } > > > > > result_type > operator()(); ># 775 "/usr/include/c++/4.9.0/bits/random.h" 3 > friend bool > operator==(const subtract_with_carry_engine& __lhs, > const subtract_with_carry_engine& __rhs) > { return (std::equal(__lhs._M_x, __lhs._M_x + long_lag, __rhs._M_x) > && __lhs._M_carry == __rhs._M_carry > && __lhs._M_p == __rhs._M_p); } ># 794 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType1, size_t __w1, size_t __s1, size_t __r1, > typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>&, > const std::subtract_with_carry_engine<_UIntType1, __w1, > __s1, __r1>&); ># 813 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType1, size_t __w1, size_t __s1, size_t __r1, > typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>&, > std::subtract_with_carry_engine<_UIntType1, __w1, > __s1, __r1>&); > > private: > _UIntType _M_x[long_lag]; > _UIntType _M_carry; > size_t _M_p; > }; ># 838 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _UIntType, size_t __w, size_t __s, size_t __r> > inline bool > operator!=(const std::subtract_with_carry_engine<_UIntType, __w, > __s, __r>& __lhs, > const std::subtract_with_carry_engine<_UIntType, __w, > __s, __r>& __rhs) > { return !(__lhs == __rhs); } ># 853 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RandomNumberEngine, size_t __p, size_t __r> > class discard_block_engine > { > static_assert(1 <= __r && __r <= __p, > "template argument substituting __r out of bounds"); > > public: > > typedef typename _RandomNumberEngine::result_type result_type; > > > static constexpr size_t block_size = __p; > static constexpr size_t used_block = __r; > > > > > > > discard_block_engine() > : _M_b(), _M_n(0) { } > > > > > > > > explicit > discard_block_engine(const _RandomNumberEngine& __rng) > : _M_b(__rng), _M_n(0) { } > > > > > > > > explicit > discard_block_engine(_RandomNumberEngine&& __rng) > : _M_b(std::move(__rng)), _M_n(0) { } > > > > > > > > explicit > discard_block_engine(result_type __s) > : _M_b(__s), _M_n(0) { } > > > > > > > template<typename _Sseq, typename = typename > std::enable_if<!std::is_same<_Sseq, discard_block_engine>::value > && !std::is_same<_Sseq, _RandomNumberEngine>::value> > ::type> > explicit > discard_block_engine(_Sseq& __q) > : _M_b(__q), _M_n(0) > { } > > > > > > void > seed() > { > _M_b.seed(); > _M_n = 0; > } > > > > > > void > seed(result_type __s) > { > _M_b.seed(__s); > _M_n = 0; > } > > > > > > > template<typename _Sseq> > void > seed(_Sseq& __q) > { > _M_b.seed(__q); > _M_n = 0; > } > > > > > > const _RandomNumberEngine& > base() const noexcept > { return _M_b; } > > > > > static constexpr result_type > min() > { return _RandomNumberEngine::min(); } > > > > > static constexpr result_type > max() > { return _RandomNumberEngine::max(); } > > > > > void > discard(unsigned long long __z) > { > for (; __z != 0ULL; --__z) > (*this)(); > } > > > > > result_type > operator()(); ># 1003 "/usr/include/c++/4.9.0/bits/random.h" 3 > friend bool > operator==(const discard_block_engine& __lhs, > const discard_block_engine& __rhs) > { return __lhs._M_b == __rhs._M_b && __lhs._M_n == __rhs._M_n; } ># 1019 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RandomNumberEngine1, size_t __p1, size_t __r1, > typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::discard_block_engine<_RandomNumberEngine1, > __p1, __r1>& __x); ># 1037 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RandomNumberEngine1, size_t __p1, size_t __r1, > typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::discard_block_engine<_RandomNumberEngine1, > __p1, __r1>& __x); > > private: > _RandomNumberEngine _M_b; > size_t _M_n; > }; ># 1060 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RandomNumberEngine, size_t __p, size_t __r> > inline bool > operator!=(const std::discard_block_engine<_RandomNumberEngine, __p, > __r>& __lhs, > const std::discard_block_engine<_RandomNumberEngine, __p, > __r>& __rhs) > { return !(__lhs == __rhs); } > > > > > > > template<typename _RandomNumberEngine, size_t __w, typename _UIntType> > class independent_bits_engine > { > static_assert(std::is_unsigned<_UIntType>::value, "template argument " > "substituting _UIntType not an unsigned integral type"); > static_assert(0u < __w && __w <= std::numeric_limits<_UIntType>::digits, > "template argument substituting __w out of bounds"); > > public: > > typedef _UIntType result_type; > > > > > > > independent_bits_engine() > : _M_b() { } > > > > > > > > explicit > independent_bits_engine(const _RandomNumberEngine& __rng) > : _M_b(__rng) { } > > > > > > > > explicit > independent_bits_engine(_RandomNumberEngine&& __rng) > : _M_b(std::move(__rng)) { } > > > > > > > > explicit > independent_bits_engine(result_type __s) > : _M_b(__s) { } > > > > > > > template<typename _Sseq, typename = typename > std::enable_if<!std::is_same<_Sseq, independent_bits_engine>::value > && !std::is_same<_Sseq, _RandomNumberEngine>::value> > ::type> > explicit > independent_bits_engine(_Sseq& __q) > : _M_b(__q) > { } > > > > > > void > seed() > { _M_b.seed(); } > > > > > > void > seed(result_type __s) > { _M_b.seed(__s); } > > > > > > > template<typename _Sseq> > void > seed(_Sseq& __q) > { _M_b.seed(__q); } > > > > > > const _RandomNumberEngine& > base() const noexcept > { return _M_b; } > > > > > static constexpr result_type > min() > { return 0U; } > > > > > static constexpr result_type > max() > { return __detail::_Shift<_UIntType, __w>::__value - 1; } > > > > > void > discard(unsigned long long __z) > { > for (; __z != 0ULL; --__z) > (*this)(); > } > > > > > result_type > operator()(); ># 1213 "/usr/include/c++/4.9.0/bits/random.h" 3 > friend bool > operator==(const independent_bits_engine& __lhs, > const independent_bits_engine& __rhs) > { return __lhs._M_b == __rhs._M_b; } ># 1230 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::independent_bits_engine<_RandomNumberEngine, > __w, _UIntType>& __x) > { > __is >> __x._M_b; > return __is; > } > > private: > _RandomNumberEngine _M_b; > }; ># 1256 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RandomNumberEngine, size_t __w, typename _UIntType> > inline bool > operator!=(const std::independent_bits_engine<_RandomNumberEngine, __w, > _UIntType>& __lhs, > const std::independent_bits_engine<_RandomNumberEngine, __w, > _UIntType>& __rhs) > { return !(__lhs == __rhs); } ># 1274 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RandomNumberEngine, size_t __w, typename _UIntType, > typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::independent_bits_engine<_RandomNumberEngine, > __w, _UIntType>& __x) > { > __os << __x.base(); > return __os; > } > > > > > > > > template<typename _RandomNumberEngine, size_t __k> > class shuffle_order_engine > { > static_assert(1u <= __k, "template argument substituting " > "__k out of bound"); > > public: > > typedef typename _RandomNumberEngine::result_type result_type; > > static constexpr size_t table_size = __k; > > > > > > > shuffle_order_engine() > : _M_b() > { _M_initialize(); } > > > > > > > > explicit > shuffle_order_engine(const _RandomNumberEngine& __rng) > : _M_b(__rng) > { _M_initialize(); } > > > > > > > > explicit > shuffle_order_engine(_RandomNumberEngine&& __rng) > : _M_b(std::move(__rng)) > { _M_initialize(); } > > > > > > > > explicit > shuffle_order_engine(result_type __s) > : _M_b(__s) > { _M_initialize(); } > > > > > > > template<typename _Sseq, typename = typename > std::enable_if<!std::is_same<_Sseq, shuffle_order_engine>::value > && !std::is_same<_Sseq, _RandomNumberEngine>::value> > ::type> > explicit > shuffle_order_engine(_Sseq& __q) > : _M_b(__q) > { _M_initialize(); } > > > > > > void > seed() > { > _M_b.seed(); > _M_initialize(); > } > > > > > > void > seed(result_type __s) > { > _M_b.seed(__s); > _M_initialize(); > } > > > > > > > template<typename _Sseq> > void > seed(_Sseq& __q) > { > _M_b.seed(__q); > _M_initialize(); > } > > > > > const _RandomNumberEngine& > base() const noexcept > { return _M_b; } > > > > > static constexpr result_type > min() > { return _RandomNumberEngine::min(); } > > > > > static constexpr result_type > max() > { return _RandomNumberEngine::max(); } > > > > > void > discard(unsigned long long __z) > { > for (; __z != 0ULL; --__z) > (*this)(); > } > > > > > result_type > operator()(); ># 1442 "/usr/include/c++/4.9.0/bits/random.h" 3 > friend bool > operator==(const shuffle_order_engine& __lhs, > const shuffle_order_engine& __rhs) > { return (__lhs._M_b == __rhs._M_b > && std::equal(__lhs._M_v, __lhs._M_v + __k, __rhs._M_v) > && __lhs._M_y == __rhs._M_y); } ># 1460 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RandomNumberEngine1, size_t __k1, > typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::shuffle_order_engine<_RandomNumberEngine1, > __k1>& __x); ># 1478 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RandomNumberEngine1, size_t __k1, > typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::shuffle_order_engine<_RandomNumberEngine1, __k1>& __x); > > private: > void _M_initialize() > { > for (size_t __i = 0; __i < __k; ++__i) > _M_v[__i] = _M_b(); > _M_y = _M_b(); > } > > _RandomNumberEngine _M_b; > result_type _M_v[__k]; > result_type _M_y; > }; ># 1508 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RandomNumberEngine, size_t __k> > inline bool > operator!=(const std::shuffle_order_engine<_RandomNumberEngine, > __k>& __lhs, > const std::shuffle_order_engine<_RandomNumberEngine, > __k>& __rhs) > { return !(__lhs == __rhs); } > > > > > > typedef linear_congruential_engine<uint_fast32_t, 16807UL, 0UL, 2147483647UL> > minstd_rand0; > > > > > typedef linear_congruential_engine<uint_fast32_t, 48271UL, 0UL, 2147483647UL> > minstd_rand; ># 1537 "/usr/include/c++/4.9.0/bits/random.h" 3 > typedef mersenne_twister_engine< > uint_fast32_t, > 32, 624, 397, 31, > 0x9908b0dfUL, 11, > 0xffffffffUL, 7, > 0x9d2c5680UL, 15, > 0xefc60000UL, 18, 1812433253UL> mt19937; > > > > > typedef mersenne_twister_engine< > uint_fast64_t, > 64, 312, 156, 31, > 0xb5026f5aa96619e9ULL, 29, > 0x5555555555555555ULL, 17, > 0x71d67fffeda60000ULL, 37, > 0xfff7eee000000000ULL, 43, > 6364136223846793005ULL> mt19937_64; > > typedef subtract_with_carry_engine<uint_fast32_t, 24, 10, 24> > ranlux24_base; > > typedef subtract_with_carry_engine<uint_fast64_t, 48, 5, 12> > ranlux48_base; > > typedef discard_block_engine<ranlux24_base, 223, 23> ranlux24; > > typedef discard_block_engine<ranlux48_base, 389, 11> ranlux48; > > typedef shuffle_order_engine<minstd_rand0, 256> knuth_b; > > typedef minstd_rand0 default_random_engine; > > > > > > class random_device > { > public: > > typedef unsigned int result_type; > > > > > > explicit > random_device(const std::string& __token = "default") > { > _M_init(__token); > } > > ~random_device() > { _M_fini(); } ># 1604 "/usr/include/c++/4.9.0/bits/random.h" 3 > static constexpr result_type > min() > { return std::numeric_limits<result_type>::min(); } > > static constexpr result_type > max() > { return std::numeric_limits<result_type>::max(); } > > double > entropy() const noexcept > { return 0.0; } > > result_type > operator()() > { > > return this->_M_getval(); > > > > } > > > random_device(const random_device&) = delete; > void operator=(const random_device&) = delete; > > private: > > void _M_init(const std::string& __token); > void _M_init_pretr1(const std::string& __token); > void _M_fini(); > > result_type _M_getval(); > result_type _M_getval_pretr1(); > > union > { > void* _M_file; > mt19937 _M_mt; > }; > }; ># 1665 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType = int> > class uniform_int_distribution > { > static_assert(std::is_integral<_IntType>::value, > "template argument not an integral type"); > > public: > > typedef _IntType result_type; > > struct param_type > { > typedef uniform_int_distribution<_IntType> distribution_type; > > explicit > param_type(_IntType __a = 0, > _IntType __b = std::numeric_limits<_IntType>::max()) > : _M_a(__a), _M_b(__b) > { > ; > } > > result_type > a() const > { return _M_a; } > > result_type > b() const > { return _M_b; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_a == __p2._M_a && __p1._M_b == __p2._M_b; } > > private: > _IntType _M_a; > _IntType _M_b; > }; > > public: > > > > explicit > uniform_int_distribution(_IntType __a = 0, > _IntType __b = std::numeric_limits<_IntType>::max()) > : _M_param(__a, __b) > { } > > explicit > uniform_int_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > > > void > reset() { } > > result_type > a() const > { return _M_param.a(); } > > result_type > b() const > { return _M_param.b(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return this->a(); } > > > > > result_type > max() const > { return this->b(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const uniform_int_distribution& __d1, > const uniform_int_distribution& __d2) > { return __d1._M_param == __d2._M_param; } > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _IntType> > inline bool > operator!=(const std::uniform_int_distribution<_IntType>& __d1, > const std::uniform_int_distribution<_IntType>& __d2) > { return !(__d1 == __d2); } ># 1839 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>&, > const std::uniform_int_distribution<_IntType>&); ># 1853 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>&, > std::uniform_int_distribution<_IntType>&); ># 1866 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class uniform_real_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef uniform_real_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __a = _RealType(0), > _RealType __b = _RealType(1)) > : _M_a(__a), _M_b(__b) > { > ; > } > > result_type > a() const > { return _M_a; } > > result_type > b() const > { return _M_b; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_a == __p2._M_a && __p1._M_b == __p2._M_b; } > > private: > _RealType _M_a; > _RealType _M_b; > }; > > public: > > > > > > > explicit > uniform_real_distribution(_RealType __a = _RealType(0), > _RealType __b = _RealType(1)) > : _M_param(__a, __b) > { } > > explicit > uniform_real_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > > > void > reset() { } > > result_type > a() const > { return _M_param.a(); } > > result_type > b() const > { return _M_param.b(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return this->a(); } > > > > > result_type > max() const > { return this->b(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > return (__aurng() * (__p.b() - __p.a())) + __p.a(); > } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const uniform_real_distribution& __d1, > const uniform_real_distribution& __d2) > { return __d1._M_param == __d2._M_param; } > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _IntType> > inline bool > operator!=(const std::uniform_real_distribution<_IntType>& __d1, > const std::uniform_real_distribution<_IntType>& __d2) > { return !(__d1 == __d2); } ># 2048 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>&, > const std::uniform_real_distribution<_RealType>&); ># 2062 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>&, > std::uniform_real_distribution<_RealType>&); ># 2084 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class normal_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef normal_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __mean = _RealType(0), > _RealType __stddev = _RealType(1)) > : _M_mean(__mean), _M_stddev(__stddev) > { > ; > } > > _RealType > mean() const > { return _M_mean; } > > _RealType > stddev() const > { return _M_stddev; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return (__p1._M_mean == __p2._M_mean > && __p1._M_stddev == __p2._M_stddev); } > > private: > _RealType _M_mean; > _RealType _M_stddev; > }; > > public: > > > > > explicit > normal_distribution(result_type __mean = result_type(0), > result_type __stddev = result_type(1)) > : _M_param(__mean, __stddev), _M_saved_available(false) > { } > > explicit > normal_distribution(const param_type& __p) > : _M_param(__p), _M_saved_available(false) > { } > > > > > void > reset() > { _M_saved_available = false; } > > > > > _RealType > mean() const > { return _M_param.mean(); } > > > > > _RealType > stddev() const > { return _M_param.stddev(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return std::numeric_limits<result_type>::lowest(); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > > template<typename _RealType1> > friend bool > operator==(const std::normal_distribution<_RealType1>& __d1, > const std::normal_distribution<_RealType1>& __d2); ># 2245 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::normal_distribution<_RealType1>& __x); ># 2260 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::normal_distribution<_RealType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > result_type _M_saved; > bool _M_saved_available; > }; > > > > > template<typename _RealType> > inline bool > operator!=(const std::normal_distribution<_RealType>& __d1, > const std::normal_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 2297 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class lognormal_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef lognormal_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __m = _RealType(0), > _RealType __s = _RealType(1)) > : _M_m(__m), _M_s(__s) > { } > > _RealType > m() const > { return _M_m; } > > _RealType > s() const > { return _M_s; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_m == __p2._M_m && __p1._M_s == __p2._M_s; } > > private: > _RealType _M_m; > _RealType _M_s; > }; > > explicit > lognormal_distribution(_RealType __m = _RealType(0), > _RealType __s = _RealType(1)) > : _M_param(__m, __s), _M_nd() > { } > > explicit > lognormal_distribution(const param_type& __p) > : _M_param(__p), _M_nd() > { } > > > > > void > reset() > { _M_nd.reset(); } > > > > > _RealType > m() const > { return _M_param.m(); } > > _RealType > s() const > { return _M_param.s(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return result_type(0); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { return std::exp(__p.s() * _M_nd(__urng) + __p.m()); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > > friend bool > operator==(const lognormal_distribution& __d1, > const lognormal_distribution& __d2) > { return (__d1._M_param == __d2._M_param > && __d1._M_nd == __d2._M_nd); } ># 2449 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::lognormal_distribution<_RealType1>& __x); ># 2464 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::lognormal_distribution<_RealType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > > std::normal_distribution<result_type> _M_nd; > }; > > > > > template<typename _RealType> > inline bool > operator!=(const std::lognormal_distribution<_RealType>& __d1, > const std::lognormal_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 2501 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class gamma_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef gamma_distribution<_RealType> distribution_type; > friend class gamma_distribution<_RealType>; > > explicit > param_type(_RealType __alpha_val = _RealType(1), > _RealType __beta_val = _RealType(1)) > : _M_alpha(__alpha_val), _M_beta(__beta_val) > { > ; > _M_initialize(); > } > > _RealType > alpha() const > { return _M_alpha; } > > _RealType > beta() const > { return _M_beta; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return (__p1._M_alpha == __p2._M_alpha > && __p1._M_beta == __p2._M_beta); } > > private: > void > _M_initialize(); > > _RealType _M_alpha; > _RealType _M_beta; > > _RealType _M_malpha, _M_a2; > }; > > public: > > > > > explicit > gamma_distribution(_RealType __alpha_val = _RealType(1), > _RealType __beta_val = _RealType(1)) > : _M_param(__alpha_val, __beta_val), _M_nd() > { } > > explicit > gamma_distribution(const param_type& __p) > : _M_param(__p), _M_nd() > { } > > > > > void > reset() > { _M_nd.reset(); } > > > > > _RealType > alpha() const > { return _M_param.alpha(); } > > > > > _RealType > beta() const > { return _M_param.beta(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return result_type(0); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > > friend bool > operator==(const gamma_distribution& __d1, > const gamma_distribution& __d2) > { return (__d1._M_param == __d2._M_param > && __d1._M_nd == __d2._M_nd); } ># 2670 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::gamma_distribution<_RealType1>& __x); ># 2684 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::gamma_distribution<_RealType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > > std::normal_distribution<result_type> _M_nd; > }; > > > > > template<typename _RealType> > inline bool > operator!=(const std::gamma_distribution<_RealType>& __d1, > const std::gamma_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 2718 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class chi_squared_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef chi_squared_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __n = _RealType(1)) > : _M_n(__n) > { } > > _RealType > n() const > { return _M_n; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_n == __p2._M_n; } > > private: > _RealType _M_n; > }; > > explicit > chi_squared_distribution(_RealType __n = _RealType(1)) > : _M_param(__n), _M_gd(__n / 2) > { } > > explicit > chi_squared_distribution(const param_type& __p) > : _M_param(__p), _M_gd(__p.n() / 2) > { } > > > > > void > reset() > { _M_gd.reset(); } > > > > > _RealType > n() const > { return _M_param.n(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return result_type(0); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return 2 * _M_gd(__urng); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > typedef typename std::gamma_distribution<result_type>::param_type > param_type; > return 2 * _M_gd(__urng, param_type(__p.n() / 2)); > } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate_impl(__f, __t, __urng); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { typename std::gamma_distribution<result_type>::param_type > __p2(__p.n() / 2); > this->__generate_impl(__f, __t, __urng, __p2); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate_impl(__f, __t, __urng); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { typename std::gamma_distribution<result_type>::param_type > __p2(__p.n() / 2); > this->__generate_impl(__f, __t, __urng, __p2); } > > > > > > > friend bool > operator==(const chi_squared_distribution& __d1, > const chi_squared_distribution& __d2) > { return __d1._M_param == __d2._M_param && __d1._M_gd == __d2._M_gd; } ># 2872 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::chi_squared_distribution<_RealType1>& __x); ># 2887 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::chi_squared_distribution<_RealType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const typename > std::gamma_distribution<result_type>::param_type& __p); > > param_type _M_param; > > std::gamma_distribution<result_type> _M_gd; > }; > > > > > template<typename _RealType> > inline bool > operator!=(const std::chi_squared_distribution<_RealType>& __d1, > const std::chi_squared_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 2928 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class cauchy_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef cauchy_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __a = _RealType(0), > _RealType __b = _RealType(1)) > : _M_a(__a), _M_b(__b) > { } > > _RealType > a() const > { return _M_a; } > > _RealType > b() const > { return _M_b; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_a == __p2._M_a && __p1._M_b == __p2._M_b; } > > private: > _RealType _M_a; > _RealType _M_b; > }; > > explicit > cauchy_distribution(_RealType __a = _RealType(0), > _RealType __b = _RealType(1)) > : _M_param(__a, __b) > { } > > explicit > cauchy_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > void > reset() > { } > > > > > _RealType > a() const > { return _M_param.a(); } > > _RealType > b() const > { return _M_param.b(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return std::numeric_limits<result_type>::lowest(); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const cauchy_distribution& __d1, > const cauchy_distribution& __d2) > { return __d1._M_param == __d2._M_param; } > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _RealType> > inline bool > operator!=(const std::cauchy_distribution<_RealType>& __d1, > const std::cauchy_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 3098 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::cauchy_distribution<_RealType>& __x); ># 3113 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::cauchy_distribution<_RealType>& __x); ># 3129 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class fisher_f_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef fisher_f_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __m = _RealType(1), > _RealType __n = _RealType(1)) > : _M_m(__m), _M_n(__n) > { } > > _RealType > m() const > { return _M_m; } > > _RealType > n() const > { return _M_n; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_m == __p2._M_m && __p1._M_n == __p2._M_n; } > > private: > _RealType _M_m; > _RealType _M_n; > }; > > explicit > fisher_f_distribution(_RealType __m = _RealType(1), > _RealType __n = _RealType(1)) > : _M_param(__m, __n), _M_gd_x(__m / 2), _M_gd_y(__n / 2) > { } > > explicit > fisher_f_distribution(const param_type& __p) > : _M_param(__p), _M_gd_x(__p.m() / 2), _M_gd_y(__p.n() / 2) > { } > > > > > void > reset() > { > _M_gd_x.reset(); > _M_gd_y.reset(); > } > > > > > _RealType > m() const > { return _M_param.m(); } > > _RealType > n() const > { return _M_param.n(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return result_type(0); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return (_M_gd_x(__urng) * n()) / (_M_gd_y(__urng) * m()); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > typedef typename std::gamma_distribution<result_type>::param_type > param_type; > return ((_M_gd_x(__urng, param_type(__p.m() / 2)) * n()) > / (_M_gd_y(__urng, param_type(__p.n() / 2)) * m())); > } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate_impl(__f, __t, __urng); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate_impl(__f, __t, __urng); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > > friend bool > operator==(const fisher_f_distribution& __d1, > const fisher_f_distribution& __d2) > { return (__d1._M_param == __d2._M_param > && __d1._M_gd_x == __d2._M_gd_x > && __d1._M_gd_y == __d2._M_gd_y); } ># 3296 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::fisher_f_distribution<_RealType1>& __x); ># 3311 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::fisher_f_distribution<_RealType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > > std::gamma_distribution<result_type> _M_gd_x, _M_gd_y; > }; > > > > > template<typename _RealType> > inline bool > operator!=(const std::fisher_f_distribution<_RealType>& __d1, > const std::fisher_f_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 3353 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class student_t_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef student_t_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __n = _RealType(1)) > : _M_n(__n) > { } > > _RealType > n() const > { return _M_n; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_n == __p2._M_n; } > > private: > _RealType _M_n; > }; > > explicit > student_t_distribution(_RealType __n = _RealType(1)) > : _M_param(__n), _M_nd(), _M_gd(__n / 2, 2) > { } > > explicit > student_t_distribution(const param_type& __p) > : _M_param(__p), _M_nd(), _M_gd(__p.n() / 2, 2) > { } > > > > > void > reset() > { > _M_nd.reset(); > _M_gd.reset(); > } > > > > > _RealType > n() const > { return _M_param.n(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return std::numeric_limits<result_type>::lowest(); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return _M_nd(__urng) * std::sqrt(n() / _M_gd(__urng)); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > typedef typename std::gamma_distribution<result_type>::param_type > param_type; > > const result_type __g = _M_gd(__urng, param_type(__p.n() / 2, 2)); > return _M_nd(__urng) * std::sqrt(__p.n() / __g); > } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate_impl(__f, __t, __urng); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate_impl(__f, __t, __urng); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > > friend bool > operator==(const student_t_distribution& __d1, > const student_t_distribution& __d2) > { return (__d1._M_param == __d2._M_param > && __d1._M_nd == __d2._M_nd && __d1._M_gd == __d2._M_gd); } ># 3509 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::student_t_distribution<_RealType1>& __x); ># 3524 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::student_t_distribution<_RealType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng); > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > > std::normal_distribution<result_type> _M_nd; > std::gamma_distribution<result_type> _M_gd; > }; > > > > > template<typename _RealType> > inline bool > operator!=(const std::student_t_distribution<_RealType>& __d1, > const std::student_t_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 3572 "/usr/include/c++/4.9.0/bits/random.h" 3 > class bernoulli_distribution > { > public: > > typedef bool result_type; > > struct param_type > { > typedef bernoulli_distribution distribution_type; > > explicit > param_type(double __p = 0.5) > : _M_p(__p) > { > ; > } > > double > p() const > { return _M_p; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_p == __p2._M_p; } > > private: > double _M_p; > }; > > public: > > > > > > > explicit > bernoulli_distribution(double __p = 0.5) > : _M_param(__p) > { } > > explicit > bernoulli_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > > > void > reset() { } > > > > > double > p() const > { return _M_param.p(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return std::numeric_limits<result_type>::min(); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > if ((__aurng() - __aurng.min()) > < __p.p() * (__aurng.max() - __aurng.min())) > return true; > return false; > } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const bernoulli_distribution& __d1, > const bernoulli_distribution& __d2) > { return __d1._M_param == __d2._M_param; } > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > inline bool > operator!=(const std::bernoulli_distribution& __d1, > const std::bernoulli_distribution& __d2) > { return !(__d1 == __d2); } ># 3743 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::bernoulli_distribution& __x); ># 3757 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::bernoulli_distribution& __x) > { > double __p; > __is >> __p; > __x.param(bernoulli_distribution::param_type(__p)); > return __is; > } ># 3776 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType = int> > class binomial_distribution > { > static_assert(std::is_integral<_IntType>::value, > "template argument not an integral type"); > > public: > > typedef _IntType result_type; > > struct param_type > { > typedef binomial_distribution<_IntType> distribution_type; > friend class binomial_distribution<_IntType>; > > explicit > param_type(_IntType __t = _IntType(1), double __p = 0.5) > : _M_t(__t), _M_p(__p) > { > > > ; > _M_initialize(); > } > > _IntType > t() const > { return _M_t; } > > double > p() const > { return _M_p; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_t == __p2._M_t && __p1._M_p == __p2._M_p; } > > private: > void > _M_initialize(); > > _IntType _M_t; > double _M_p; > > double _M_q; > > double _M_d1, _M_d2, _M_s1, _M_s2, _M_c, > _M_a1, _M_a123, _M_s, _M_lf, _M_lp1p; > > bool _M_easy; > }; > > > explicit > binomial_distribution(_IntType __t = _IntType(1), > double __p = 0.5) > : _M_param(__t, __p), _M_nd() > { } > > explicit > binomial_distribution(const param_type& __p) > : _M_param(__p), _M_nd() > { } > > > > > void > reset() > { _M_nd.reset(); } > > > > > _IntType > t() const > { return _M_param.t(); } > > > > > double > p() const > { return _M_param.p(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return 0; } > > > > > result_type > max() const > { return _M_param.t(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > > friend bool > operator==(const binomial_distribution& __d1, > const binomial_distribution& __d2) > > { return __d1._M_param == __d2._M_param && __d1._M_nd == __d2._M_nd; } ># 3949 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType1, > typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::binomial_distribution<_IntType1>& __x); ># 3965 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType1, > typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::binomial_distribution<_IntType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _UniformRandomNumberGenerator> > result_type > _M_waiting(_UniformRandomNumberGenerator& __urng, > _IntType __t, double __q); > > param_type _M_param; > > > std::normal_distribution<double> _M_nd; > }; > > > > > template<typename _IntType> > inline bool > operator!=(const std::binomial_distribution<_IntType>& __d1, > const std::binomial_distribution<_IntType>& __d2) > { return !(__d1 == __d2); } ># 4007 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType = int> > class geometric_distribution > { > static_assert(std::is_integral<_IntType>::value, > "template argument not an integral type"); > > public: > > typedef _IntType result_type; > > struct param_type > { > typedef geometric_distribution<_IntType> distribution_type; > friend class geometric_distribution<_IntType>; > > explicit > param_type(double __p = 0.5) > : _M_p(__p) > { > ; > _M_initialize(); > } > > double > p() const > { return _M_p; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_p == __p2._M_p; } > > private: > void > _M_initialize() > { _M_log_1_p = std::log(1.0 - _M_p); } > > double _M_p; > > double _M_log_1_p; > }; > > > explicit > geometric_distribution(double __p = 0.5) > : _M_param(__p) > { } > > explicit > geometric_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > > > void > reset() { } > > > > > double > p() const > { return _M_param.p(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return 0; } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const geometric_distribution& __d1, > const geometric_distribution& __d2) > { return __d1._M_param == __d2._M_param; } > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _IntType> > inline bool > operator!=(const std::geometric_distribution<_IntType>& __d1, > const std::geometric_distribution<_IntType>& __d2) > { return !(__d1 == __d2); } ># 4178 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType, > typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::geometric_distribution<_IntType>& __x); ># 4193 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType, > typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::geometric_distribution<_IntType>& __x); ># 4207 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType = int> > class negative_binomial_distribution > { > static_assert(std::is_integral<_IntType>::value, > "template argument not an integral type"); > > public: > > typedef _IntType result_type; > > struct param_type > { > typedef negative_binomial_distribution<_IntType> distribution_type; > > explicit > param_type(_IntType __k = 1, double __p = 0.5) > : _M_k(__k), _M_p(__p) > { > ; > } > > _IntType > k() const > { return _M_k; } > > double > p() const > { return _M_p; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_k == __p2._M_k && __p1._M_p == __p2._M_p; } > > private: > _IntType _M_k; > double _M_p; > }; > > explicit > negative_binomial_distribution(_IntType __k = 1, double __p = 0.5) > : _M_param(__k, __p), _M_gd(__k, (1.0 - __p) / __p) > { } > > explicit > negative_binomial_distribution(const param_type& __p) > : _M_param(__p), _M_gd(__p.k(), (1.0 - __p.p()) / __p.p()) > { } > > > > > void > reset() > { _M_gd.reset(); } > > > > > _IntType > k() const > { return _M_param.k(); } > > > > > double > p() const > { return _M_param.p(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return result_type(0); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng); > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate_impl(__f, __t, __urng); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate_impl(__f, __t, __urng); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > > friend bool > operator==(const negative_binomial_distribution& __d1, > const negative_binomial_distribution& __d2) > { return __d1._M_param == __d2._M_param && __d1._M_gd == __d2._M_gd; } ># 4366 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::negative_binomial_distribution<_IntType1>& __x); ># 4381 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::negative_binomial_distribution<_IntType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng); > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > > std::gamma_distribution<double> _M_gd; > }; > > > > > template<typename _IntType> > inline bool > operator!=(const std::negative_binomial_distribution<_IntType>& __d1, > const std::negative_binomial_distribution<_IntType>& __d2) > { return !(__d1 == __d2); } ># 4429 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType = int> > class poisson_distribution > { > static_assert(std::is_integral<_IntType>::value, > "template argument not an integral type"); > > public: > > typedef _IntType result_type; > > struct param_type > { > typedef poisson_distribution<_IntType> distribution_type; > friend class poisson_distribution<_IntType>; > > explicit > param_type(double __mean = 1.0) > : _M_mean(__mean) > { > ; > _M_initialize(); > } > > double > mean() const > { return _M_mean; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_mean == __p2._M_mean; } > > private: > > void > _M_initialize(); > > double _M_mean; > > double _M_lm_thr; > > double _M_lfm, _M_sm, _M_d, _M_scx, _M_1cx, _M_c2b, _M_cb; > > }; > > > explicit > poisson_distribution(double __mean = 1.0) > : _M_param(__mean), _M_nd() > { } > > explicit > poisson_distribution(const param_type& __p) > : _M_param(__p), _M_nd() > { } > > > > > void > reset() > { _M_nd.reset(); } > > > > > double > mean() const > { return _M_param.mean(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return 0; } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > > friend bool > operator==(const poisson_distribution& __d1, > const poisson_distribution& __d2) > > { return __d1._M_param == __d2._M_param && __d1._M_nd == __d2._M_nd; } ># 4586 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::poisson_distribution<_IntType1>& __x); ># 4601 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::poisson_distribution<_IntType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > > > std::normal_distribution<double> _M_nd; > }; > > > > > template<typename _IntType> > inline bool > operator!=(const std::poisson_distribution<_IntType>& __d1, > const std::poisson_distribution<_IntType>& __d2) > { return !(__d1 == __d2); } ># 4645 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class exponential_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef exponential_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __lambda = _RealType(1)) > : _M_lambda(__lambda) > { > ; > } > > _RealType > lambda() const > { return _M_lambda; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_lambda == __p2._M_lambda; } > > private: > _RealType _M_lambda; > }; > > public: > > > > > explicit > exponential_distribution(const result_type& __lambda = result_type(1)) > : _M_param(__lambda) > { } > > explicit > exponential_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > > > void > reset() { } > > > > > _RealType > lambda() const > { return _M_param.lambda(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return result_type(0); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > return -std::log(result_type(1) - __aurng()) / __p.lambda(); > } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const exponential_distribution& __d1, > const exponential_distribution& __d2) > { return __d1._M_param == __d2._M_param; } > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _RealType> > inline bool > operator!=(const std::exponential_distribution<_RealType>& __d1, > const std::exponential_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 4817 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::exponential_distribution<_RealType>& __x); ># 4832 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::exponential_distribution<_RealType>& __x); ># 4847 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class weibull_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef weibull_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __a = _RealType(1), > _RealType __b = _RealType(1)) > : _M_a(__a), _M_b(__b) > { } > > _RealType > a() const > { return _M_a; } > > _RealType > b() const > { return _M_b; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_a == __p2._M_a && __p1._M_b == __p2._M_b; } > > private: > _RealType _M_a; > _RealType _M_b; > }; > > explicit > weibull_distribution(_RealType __a = _RealType(1), > _RealType __b = _RealType(1)) > : _M_param(__a, __b) > { } > > explicit > weibull_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > void > reset() > { } > > > > > _RealType > a() const > { return _M_param.a(); } > > > > > _RealType > b() const > { return _M_param.b(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return result_type(0); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const weibull_distribution& __d1, > const weibull_distribution& __d2) > { return __d1._M_param == __d2._M_param; } > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _RealType> > inline bool > operator!=(const std::weibull_distribution<_RealType>& __d1, > const std::weibull_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 5020 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::weibull_distribution<_RealType>& __x); ># 5035 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::weibull_distribution<_RealType>& __x); ># 5050 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class extreme_value_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef extreme_value_distribution<_RealType> distribution_type; > > explicit > param_type(_RealType __a = _RealType(0), > _RealType __b = _RealType(1)) > : _M_a(__a), _M_b(__b) > { } > > _RealType > a() const > { return _M_a; } > > _RealType > b() const > { return _M_b; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_a == __p2._M_a && __p1._M_b == __p2._M_b; } > > private: > _RealType _M_a; > _RealType _M_b; > }; > > explicit > extreme_value_distribution(_RealType __a = _RealType(0), > _RealType __b = _RealType(1)) > : _M_param(__a, __b) > { } > > explicit > extreme_value_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > void > reset() > { } > > > > > _RealType > a() const > { return _M_param.a(); } > > > > > _RealType > b() const > { return _M_param.b(); } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return std::numeric_limits<result_type>::lowest(); } > > > > > result_type > max() const > { return std::numeric_limits<result_type>::max(); } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const extreme_value_distribution& __d1, > const extreme_value_distribution& __d2) > { return __d1._M_param == __d2._M_param; } > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _RealType> > inline bool > operator!=(const std::extreme_value_distribution<_RealType>& __d1, > const std::extreme_value_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 5223 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::extreme_value_distribution<_RealType>& __x); ># 5238 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::extreme_value_distribution<_RealType>& __x); ># 5250 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType = int> > class discrete_distribution > { > static_assert(std::is_integral<_IntType>::value, > "template argument not an integral type"); > > public: > > typedef _IntType result_type; > > struct param_type > { > typedef discrete_distribution<_IntType> distribution_type; > friend class discrete_distribution<_IntType>; > > param_type() > : _M_prob(), _M_cp() > { } > > template<typename _InputIterator> > param_type(_InputIterator __wbegin, > _InputIterator __wend) > : _M_prob(__wbegin, __wend), _M_cp() > { _M_initialize(); } > > param_type(initializer_list<double> __wil) > : _M_prob(__wil.begin(), __wil.end()), _M_cp() > { _M_initialize(); } > > template<typename _Func> > param_type(size_t __nw, double __xmin, double __xmax, > _Func __fw); > > > param_type(const param_type&) = default; > param_type& operator=(const param_type&) = default; > > std::vector<double> > probabilities() const > { return _M_prob.empty() ? std::vector<double>(1, 1.0) : _M_prob; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_prob == __p2._M_prob; } > > private: > void > _M_initialize(); > > std::vector<double> _M_prob; > std::vector<double> _M_cp; > }; > > discrete_distribution() > : _M_param() > { } > > template<typename _InputIterator> > discrete_distribution(_InputIterator __wbegin, > _InputIterator __wend) > : _M_param(__wbegin, __wend) > { } > > discrete_distribution(initializer_list<double> __wl) > : _M_param(__wl) > { } > > template<typename _Func> > discrete_distribution(size_t __nw, double __xmin, double __xmax, > _Func __fw) > : _M_param(__nw, __xmin, __xmax, __fw) > { } > > explicit > discrete_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > void > reset() > { } > > > > > std::vector<double> > probabilities() const > { > return _M_param._M_prob.empty() > ? std::vector<double>(1, 1.0) : _M_param._M_prob; > } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { return result_type(0); } > > > > > result_type > max() const > { > return _M_param._M_prob.empty() > ? result_type(0) : result_type(_M_param._M_prob.size() - 1); > } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const discrete_distribution& __d1, > const discrete_distribution& __d2) > { return __d1._M_param == __d2._M_param; } ># 5431 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::discrete_distribution<_IntType1>& __x); ># 5447 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _IntType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::discrete_distribution<_IntType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _IntType> > inline bool > operator!=(const std::discrete_distribution<_IntType>& __d1, > const std::discrete_distribution<_IntType>& __d2) > { return !(__d1 == __d2); } ># 5480 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class piecewise_constant_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef piecewise_constant_distribution<_RealType> distribution_type; > friend class piecewise_constant_distribution<_RealType>; > > param_type() > : _M_int(), _M_den(), _M_cp() > { } > > template<typename _InputIteratorB, typename _InputIteratorW> > param_type(_InputIteratorB __bfirst, > _InputIteratorB __bend, > _InputIteratorW __wbegin); > > template<typename _Func> > param_type(initializer_list<_RealType> __bi, _Func __fw); > > template<typename _Func> > param_type(size_t __nw, _RealType __xmin, _RealType __xmax, > _Func __fw); > > > param_type(const param_type&) = default; > param_type& operator=(const param_type&) = default; > > std::vector<_RealType> > intervals() const > { > if (_M_int.empty()) > { > std::vector<_RealType> __tmp(2); > __tmp[1] = _RealType(1); > return __tmp; > } > else > return _M_int; > } > > std::vector<double> > densities() const > { return _M_den.empty() ? std::vector<double>(1, 1.0) : _M_den; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return __p1._M_int == __p2._M_int && __p1._M_den == __p2._M_den; } > > private: > void > _M_initialize(); > > std::vector<_RealType> _M_int; > std::vector<double> _M_den; > std::vector<double> _M_cp; > }; > > explicit > piecewise_constant_distribution() > : _M_param() > { } > > template<typename _InputIteratorB, typename _InputIteratorW> > piecewise_constant_distribution(_InputIteratorB __bfirst, > _InputIteratorB __bend, > _InputIteratorW __wbegin) > : _M_param(__bfirst, __bend, __wbegin) > { } > > template<typename _Func> > piecewise_constant_distribution(initializer_list<_RealType> __bl, > _Func __fw) > : _M_param(__bl, __fw) > { } > > template<typename _Func> > piecewise_constant_distribution(size_t __nw, > _RealType __xmin, _RealType __xmax, > _Func __fw) > : _M_param(__nw, __xmin, __xmax, __fw) > { } > > explicit > piecewise_constant_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > void > reset() > { } > > > > > std::vector<_RealType> > intervals() const > { > if (_M_param._M_int.empty()) > { > std::vector<_RealType> __tmp(2); > __tmp[1] = _RealType(1); > return __tmp; > } > else > return _M_param._M_int; > } > > > > > std::vector<double> > densities() const > { > return _M_param._M_den.empty() > ? std::vector<double>(1, 1.0) : _M_param._M_den; > } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { > return _M_param._M_int.empty() > ? result_type(0) : _M_param._M_int.front(); > } > > > > > result_type > max() const > { > return _M_param._M_int.empty() > ? result_type(1) : _M_param._M_int.back(); > } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const piecewise_constant_distribution& __d1, > const piecewise_constant_distribution& __d2) > { return __d1._M_param == __d2._M_param; } ># 5698 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::piecewise_constant_distribution<_RealType1>& __x); ># 5714 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::piecewise_constant_distribution<_RealType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _RealType> > inline bool > operator!=(const std::piecewise_constant_distribution<_RealType>& __d1, > const std::piecewise_constant_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 5747 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType = double> > class piecewise_linear_distribution > { > static_assert(std::is_floating_point<_RealType>::value, > "template argument not a floating point type"); > > public: > > typedef _RealType result_type; > > struct param_type > { > typedef piecewise_linear_distribution<_RealType> distribution_type; > friend class piecewise_linear_distribution<_RealType>; > > param_type() > : _M_int(), _M_den(), _M_cp(), _M_m() > { } > > template<typename _InputIteratorB, typename _InputIteratorW> > param_type(_InputIteratorB __bfirst, > _InputIteratorB __bend, > _InputIteratorW __wbegin); > > template<typename _Func> > param_type(initializer_list<_RealType> __bl, _Func __fw); > > template<typename _Func> > param_type(size_t __nw, _RealType __xmin, _RealType __xmax, > _Func __fw); > > > param_type(const param_type&) = default; > param_type& operator=(const param_type&) = default; > > std::vector<_RealType> > intervals() const > { > if (_M_int.empty()) > { > std::vector<_RealType> __tmp(2); > __tmp[1] = _RealType(1); > return __tmp; > } > else > return _M_int; > } > > std::vector<double> > densities() const > { return _M_den.empty() ? std::vector<double>(2, 1.0) : _M_den; } > > friend bool > operator==(const param_type& __p1, const param_type& __p2) > { return (__p1._M_int == __p2._M_int > && __p1._M_den == __p2._M_den); } > > private: > void > _M_initialize(); > > std::vector<_RealType> _M_int; > std::vector<double> _M_den; > std::vector<double> _M_cp; > std::vector<double> _M_m; > }; > > explicit > piecewise_linear_distribution() > : _M_param() > { } > > template<typename _InputIteratorB, typename _InputIteratorW> > piecewise_linear_distribution(_InputIteratorB __bfirst, > _InputIteratorB __bend, > _InputIteratorW __wbegin) > : _M_param(__bfirst, __bend, __wbegin) > { } > > template<typename _Func> > piecewise_linear_distribution(initializer_list<_RealType> __bl, > _Func __fw) > : _M_param(__bl, __fw) > { } > > template<typename _Func> > piecewise_linear_distribution(size_t __nw, > _RealType __xmin, _RealType __xmax, > _Func __fw) > : _M_param(__nw, __xmin, __xmax, __fw) > { } > > explicit > piecewise_linear_distribution(const param_type& __p) > : _M_param(__p) > { } > > > > > void > reset() > { } > > > > > std::vector<_RealType> > intervals() const > { > if (_M_param._M_int.empty()) > { > std::vector<_RealType> __tmp(2); > __tmp[1] = _RealType(1); > return __tmp; > } > else > return _M_param._M_int; > } > > > > > > std::vector<double> > densities() const > { > return _M_param._M_den.empty() > ? std::vector<double>(2, 1.0) : _M_param._M_den; > } > > > > > param_type > param() const > { return _M_param; } > > > > > > void > param(const param_type& __param) > { _M_param = __param; } > > > > > result_type > min() const > { > return _M_param._M_int.empty() > ? result_type(0) : _M_param._M_int.front(); > } > > > > > result_type > max() const > { > return _M_param._M_int.empty() > ? result_type(1) : _M_param._M_int.back(); > } > > > > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng) > { return this->operator()(__urng, _M_param); } > > template<typename _UniformRandomNumberGenerator> > result_type > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p); > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { this->__generate(__f, __t, __urng, _M_param); } > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > template<typename _UniformRandomNumberGenerator> > void > __generate(result_type* __f, result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { this->__generate_impl(__f, __t, __urng, __p); } > > > > > > friend bool > operator==(const piecewise_linear_distribution& __d1, > const piecewise_linear_distribution& __d2) > { return __d1._M_param == __d2._M_param; } ># 5968 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const std::piecewise_linear_distribution<_RealType1>& __x); ># 5984 "/usr/include/c++/4.9.0/bits/random.h" 3 > template<typename _RealType1, typename _CharT, typename _Traits> > friend std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > std::piecewise_linear_distribution<_RealType1>& __x); > > private: > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p); > > param_type _M_param; > }; > > > > > > template<typename _RealType> > inline bool > operator!=(const std::piecewise_linear_distribution<_RealType>& __d1, > const std::piecewise_linear_distribution<_RealType>& __d2) > { return !(__d1 == __d2); } ># 6025 "/usr/include/c++/4.9.0/bits/random.h" 3 > class seed_seq > { > > public: > > typedef uint_least32_t result_type; > > > seed_seq() > : _M_v() > { } > > template<typename _IntType> > seed_seq(std::initializer_list<_IntType> il); > > template<typename _InputIterator> > seed_seq(_InputIterator __begin, _InputIterator __end); > > > template<typename _RandomAccessIterator> > void > generate(_RandomAccessIterator __begin, _RandomAccessIterator __end); > > > size_t size() const > { return _M_v.size(); } > > template<typename OutputIterator> > void > param(OutputIterator __dest) const > { std::copy(_M_v.begin(), _M_v.end(), __dest); } > > private: > > std::vector<result_type> _M_v; > }; > > > > > > >} ># 50 "/usr/include/c++/4.9.0/random" 2 3 ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/opt_random.h" 1 3 ># 33 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/opt_random.h" 3 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 1 3 4 ># 27 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/ia32intrin.h" 1 3 4 ># 29 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/ia32intrin.h" 3 4 >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bsfd (int __X) >{ > return __builtin_ctz (__X); >} > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bsrd (int __X) >{ > return __builtin_ia32_bsrsi (__X); >} > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bswapd (int __X) >{ > return __builtin_bswap32 (__X); >} ># 59 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/ia32intrin.h" 3 4 >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__crc32b (unsigned int __C, unsigned char __V) >{ > return __builtin_ia32_crc32qi (__C, __V); >} > >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__crc32w (unsigned int __C, unsigned short __V) >{ > return __builtin_ia32_crc32hi (__C, __V); >} > >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__crc32d (unsigned int __C, unsigned int __V) >{ > return __builtin_ia32_crc32si (__C, __V); >} > > > > > > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__popcntd (unsigned int __X) >{ > return __builtin_popcount (__X); >} > > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rdpmc (int __S) >{ > return __builtin_ia32_rdpmc (__S); >} > > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rdtsc (void) >{ > return __builtin_ia32_rdtsc (); >} > > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rdtscp (unsigned int *__A) >{ > return __builtin_ia32_rdtscp (__A); >} > > >extern __inline unsigned char >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rolb (unsigned char __X, int __C) >{ > return __builtin_ia32_rolqi (__X, __C); >} > > >extern __inline unsigned short >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rolw (unsigned short __X, int __C) >{ > return __builtin_ia32_rolhi (__X, __C); >} > > >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rold (unsigned int __X, int __C) >{ > return (__X << __C) | (__X >> (32 - __C)); >} > > >extern __inline unsigned char >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rorb (unsigned char __X, int __C) >{ > return __builtin_ia32_rorqi (__X, __C); >} > > >extern __inline unsigned short >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rorw (unsigned short __X, int __C) >{ > return __builtin_ia32_rorhi (__X, __C); >} > > >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rord (unsigned int __X, int __C) >{ > return (__X >> __C) | (__X << (32 - __C)); >} > > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__pause (void) >{ > __builtin_ia32_pause (); >} > > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bsfq (long long __X) >{ > return __builtin_ctzll (__X); >} > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bsrq (long long __X) >{ > return __builtin_ia32_bsrdi (__X); >} > > >extern __inline long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bswapq (long long __X) >{ > return __builtin_bswap64 (__X); >} ># 205 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/ia32intrin.h" 3 4 >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__crc32q (unsigned long long __C, unsigned long long __V) >{ > return __builtin_ia32_crc32di (__C, __V); >} > > > > > > > >extern __inline long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__popcntq (unsigned long long __X) >{ > return __builtin_popcountll (__X); >} > > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rolq (unsigned long long __X, int __C) >{ > return (__X << __C) | (__X >> (64 - __C)); >} > > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__rorq (unsigned long long __X, int __C) >{ > return (__X >> __C) | (__X << (64 - __C)); >} > > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__readeflags (void) >{ > return __builtin_ia32_readeflags_u64 (); >} > > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__writeeflags (unsigned long long X) >{ > __builtin_ia32_writeeflags_u64 (X); >} ># 28 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mmintrin.h" 1 3 4 ># 38 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mmintrin.h" 3 4 >typedef int __m64 __attribute__ ((__vector_size__ (8), __may_alias__)); > > >typedef int __v2si __attribute__ ((__vector_size__ (8))); >typedef short __v4hi __attribute__ ((__vector_size__ (8))); >typedef char __v8qi __attribute__ ((__vector_size__ (8))); >typedef long long __v1di __attribute__ ((__vector_size__ (8))); >typedef float __v2sf __attribute__ ((__vector_size__ (8))); > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_empty (void) >{ > __builtin_ia32_emms (); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_empty (void) >{ > _mm_empty (); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi32_si64 (int __i) >{ > return (__m64) __builtin_ia32_vec_init_v2si (__i, 0); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_from_int (int __i) >{ > return _mm_cvtsi32_si64 (__i); >} > > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_from_int64 (long long __i) >{ > return (__m64) __i; >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64_m64 (long long __i) >{ > return (__m64) __i; >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64x_si64 (long long __i) >{ > return (__m64) __i; >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_pi64x (long long __i) >{ > return (__m64) __i; >} > > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64_si32 (__m64 __i) >{ > return __builtin_ia32_vec_ext_v2si ((__v2si)__i, 0); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_to_int (__m64 __i) >{ > return _mm_cvtsi64_si32 (__i); >} > > > > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_to_int64 (__m64 __i) >{ > return (long long)__i; >} > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtm64_si64 (__m64 __i) >{ > return (long long)__i; >} > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64_si64x (__m64 __i) >{ > return (long long)__i; >} > > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_packs_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_packsswb ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_packsswb (__m64 __m1, __m64 __m2) >{ > return _mm_packs_pi16 (__m1, __m2); >} > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_packs_pi32 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_packssdw ((__v2si)__m1, (__v2si)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_packssdw (__m64 __m1, __m64 __m2) >{ > return _mm_packs_pi32 (__m1, __m2); >} > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_packs_pu16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_packuswb ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_packuswb (__m64 __m1, __m64 __m2) >{ > return _mm_packs_pu16 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpackhi_pi8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_punpckhbw ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_punpckhbw (__m64 __m1, __m64 __m2) >{ > return _mm_unpackhi_pi8 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpackhi_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_punpckhwd ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_punpckhwd (__m64 __m1, __m64 __m2) >{ > return _mm_unpackhi_pi16 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpackhi_pi32 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_punpckhdq ((__v2si)__m1, (__v2si)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_punpckhdq (__m64 __m1, __m64 __m2) >{ > return _mm_unpackhi_pi32 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpacklo_pi8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_punpcklbw ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_punpcklbw (__m64 __m1, __m64 __m2) >{ > return _mm_unpacklo_pi8 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpacklo_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_punpcklwd ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_punpcklwd (__m64 __m1, __m64 __m2) >{ > return _mm_unpacklo_pi16 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpacklo_pi32 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_punpckldq ((__v2si)__m1, (__v2si)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_punpckldq (__m64 __m1, __m64 __m2) >{ > return _mm_unpacklo_pi32 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_pi8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_paddb ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_paddb (__m64 __m1, __m64 __m2) >{ > return _mm_add_pi8 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_paddw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_paddw (__m64 __m1, __m64 __m2) >{ > return _mm_add_pi16 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_pi32 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_paddd ((__v2si)__m1, (__v2si)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_paddd (__m64 __m1, __m64 __m2) >{ > return _mm_add_pi32 (__m1, __m2); >} ># 315 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mmintrin.h" 3 4 >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_si64 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_paddq ((__v1di)__m1, (__v1di)__m2); >} > > > > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_adds_pi8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_paddsb ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_paddsb (__m64 __m1, __m64 __m2) >{ > return _mm_adds_pi8 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_adds_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_paddsw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_paddsw (__m64 __m1, __m64 __m2) >{ > return _mm_adds_pi16 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_adds_pu8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_paddusb ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_paddusb (__m64 __m1, __m64 __m2) >{ > return _mm_adds_pu8 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_adds_pu16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_paddusw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_paddusw (__m64 __m1, __m64 __m2) >{ > return _mm_adds_pu16 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_pi8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_psubb ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psubb (__m64 __m1, __m64 __m2) >{ > return _mm_sub_pi8 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_psubw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psubw (__m64 __m1, __m64 __m2) >{ > return _mm_sub_pi16 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_pi32 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_psubd ((__v2si)__m1, (__v2si)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psubd (__m64 __m1, __m64 __m2) >{ > return _mm_sub_pi32 (__m1, __m2); >} ># 427 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mmintrin.h" 3 4 >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_si64 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_psubq ((__v1di)__m1, (__v1di)__m2); >} > > > > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_subs_pi8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_psubsb ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psubsb (__m64 __m1, __m64 __m2) >{ > return _mm_subs_pi8 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_subs_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_psubsw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psubsw (__m64 __m1, __m64 __m2) >{ > return _mm_subs_pi16 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_subs_pu8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_psubusb ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psubusb (__m64 __m1, __m64 __m2) >{ > return _mm_subs_pu8 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_subs_pu16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_psubusw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psubusw (__m64 __m1, __m64 __m2) >{ > return _mm_subs_pu16 (__m1, __m2); >} > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_madd_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_pmaddwd ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pmaddwd (__m64 __m1, __m64 __m2) >{ > return _mm_madd_pi16 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mulhi_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_pmulhw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pmulhw (__m64 __m1, __m64 __m2) >{ > return _mm_mulhi_pi16 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mullo_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_pmullw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pmullw (__m64 __m1, __m64 __m2) >{ > return _mm_mullo_pi16 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sll_pi16 (__m64 __m, __m64 __count) >{ > return (__m64) __builtin_ia32_psllw ((__v4hi)__m, (__v4hi)__count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psllw (__m64 __m, __m64 __count) >{ > return _mm_sll_pi16 (__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_slli_pi16 (__m64 __m, int __count) >{ > return (__m64) __builtin_ia32_psllwi ((__v4hi)__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psllwi (__m64 __m, int __count) >{ > return _mm_slli_pi16 (__m, __count); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sll_pi32 (__m64 __m, __m64 __count) >{ > return (__m64) __builtin_ia32_pslld ((__v2si)__m, (__v2si)__count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pslld (__m64 __m, __m64 __count) >{ > return _mm_sll_pi32 (__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_slli_pi32 (__m64 __m, int __count) >{ > return (__m64) __builtin_ia32_pslldi ((__v2si)__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pslldi (__m64 __m, int __count) >{ > return _mm_slli_pi32 (__m, __count); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sll_si64 (__m64 __m, __m64 __count) >{ > return (__m64) __builtin_ia32_psllq ((__v1di)__m, (__v1di)__count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psllq (__m64 __m, __m64 __count) >{ > return _mm_sll_si64 (__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_slli_si64 (__m64 __m, int __count) >{ > return (__m64) __builtin_ia32_psllqi ((__v1di)__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psllqi (__m64 __m, int __count) >{ > return _mm_slli_si64 (__m, __count); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sra_pi16 (__m64 __m, __m64 __count) >{ > return (__m64) __builtin_ia32_psraw ((__v4hi)__m, (__v4hi)__count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psraw (__m64 __m, __m64 __count) >{ > return _mm_sra_pi16 (__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srai_pi16 (__m64 __m, int __count) >{ > return (__m64) __builtin_ia32_psrawi ((__v4hi)__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psrawi (__m64 __m, int __count) >{ > return _mm_srai_pi16 (__m, __count); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sra_pi32 (__m64 __m, __m64 __count) >{ > return (__m64) __builtin_ia32_psrad ((__v2si)__m, (__v2si)__count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psrad (__m64 __m, __m64 __count) >{ > return _mm_sra_pi32 (__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srai_pi32 (__m64 __m, int __count) >{ > return (__m64) __builtin_ia32_psradi ((__v2si)__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psradi (__m64 __m, int __count) >{ > return _mm_srai_pi32 (__m, __count); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srl_pi16 (__m64 __m, __m64 __count) >{ > return (__m64) __builtin_ia32_psrlw ((__v4hi)__m, (__v4hi)__count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psrlw (__m64 __m, __m64 __count) >{ > return _mm_srl_pi16 (__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srli_pi16 (__m64 __m, int __count) >{ > return (__m64) __builtin_ia32_psrlwi ((__v4hi)__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psrlwi (__m64 __m, int __count) >{ > return _mm_srli_pi16 (__m, __count); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srl_pi32 (__m64 __m, __m64 __count) >{ > return (__m64) __builtin_ia32_psrld ((__v2si)__m, (__v2si)__count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psrld (__m64 __m, __m64 __count) >{ > return _mm_srl_pi32 (__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srli_pi32 (__m64 __m, int __count) >{ > return (__m64) __builtin_ia32_psrldi ((__v2si)__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psrldi (__m64 __m, int __count) >{ > return _mm_srli_pi32 (__m, __count); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srl_si64 (__m64 __m, __m64 __count) >{ > return (__m64) __builtin_ia32_psrlq ((__v1di)__m, (__v1di)__count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psrlq (__m64 __m, __m64 __count) >{ > return _mm_srl_si64 (__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srli_si64 (__m64 __m, int __count) >{ > return (__m64) __builtin_ia32_psrlqi ((__v1di)__m, __count); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psrlqi (__m64 __m, int __count) >{ > return _mm_srli_si64 (__m, __count); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_and_si64 (__m64 __m1, __m64 __m2) >{ > return __builtin_ia32_pand (__m1, __m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pand (__m64 __m1, __m64 __m2) >{ > return _mm_and_si64 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_andnot_si64 (__m64 __m1, __m64 __m2) >{ > return __builtin_ia32_pandn (__m1, __m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pandn (__m64 __m1, __m64 __m2) >{ > return _mm_andnot_si64 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_or_si64 (__m64 __m1, __m64 __m2) >{ > return __builtin_ia32_por (__m1, __m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_por (__m64 __m1, __m64 __m2) >{ > return _mm_or_si64 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_xor_si64 (__m64 __m1, __m64 __m2) >{ > return __builtin_ia32_pxor (__m1, __m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pxor (__m64 __m1, __m64 __m2) >{ > return _mm_xor_si64 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_pi8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_pcmpeqb ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pcmpeqb (__m64 __m1, __m64 __m2) >{ > return _mm_cmpeq_pi8 (__m1, __m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_pi8 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_pcmpgtb ((__v8qi)__m1, (__v8qi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pcmpgtb (__m64 __m1, __m64 __m2) >{ > return _mm_cmpgt_pi8 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_pcmpeqw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pcmpeqw (__m64 __m1, __m64 __m2) >{ > return _mm_cmpeq_pi16 (__m1, __m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_pi16 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_pcmpgtw ((__v4hi)__m1, (__v4hi)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pcmpgtw (__m64 __m1, __m64 __m2) >{ > return _mm_cmpgt_pi16 (__m1, __m2); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_pi32 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_pcmpeqd ((__v2si)__m1, (__v2si)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pcmpeqd (__m64 __m1, __m64 __m2) >{ > return _mm_cmpeq_pi32 (__m1, __m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_pi32 (__m64 __m1, __m64 __m2) >{ > return (__m64) __builtin_ia32_pcmpgtd ((__v2si)__m1, (__v2si)__m2); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pcmpgtd (__m64 __m1, __m64 __m2) >{ > return _mm_cmpgt_pi32 (__m1, __m2); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setzero_si64 (void) >{ > return (__m64)0LL; >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_pi32 (int __i1, int __i0) >{ > return (__m64) __builtin_ia32_vec_init_v2si (__i0, __i1); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_pi16 (short __w3, short __w2, short __w1, short __w0) >{ > return (__m64) __builtin_ia32_vec_init_v4hi (__w0, __w1, __w2, __w3); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_pi8 (char __b7, char __b6, char __b5, char __b4, > char __b3, char __b2, char __b1, char __b0) >{ > return (__m64) __builtin_ia32_vec_init_v8qi (__b0, __b1, __b2, __b3, > __b4, __b5, __b6, __b7); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setr_pi32 (int __i0, int __i1) >{ > return _mm_set_pi32 (__i1, __i0); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setr_pi16 (short __w0, short __w1, short __w2, short __w3) >{ > return _mm_set_pi16 (__w3, __w2, __w1, __w0); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setr_pi8 (char __b0, char __b1, char __b2, char __b3, > char __b4, char __b5, char __b6, char __b7) >{ > return _mm_set_pi8 (__b7, __b6, __b5, __b4, __b3, __b2, __b1, __b0); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_pi32 (int __i) >{ > return _mm_set_pi32 (__i, __i); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_pi16 (short __w) >{ > return _mm_set_pi16 (__w, __w, __w, __w); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_pi8 (char __b) >{ > return _mm_set_pi8 (__b, __b, __b, __b, __b, __b, __b, __b); >} ># 30 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 1 3 4 ># 34 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mm_malloc.h" 1 3 4 ># 34 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mm_malloc.h" 3 4 >extern "C" int posix_memalign (void **, size_t, size_t) throw (); > > >static __inline void * >_mm_malloc (size_t size, size_t alignment) >{ > void *ptr; > if (alignment == 1) > return malloc (size); > if (alignment == 2 || (sizeof (void *) == 8 && alignment == 4)) > alignment = sizeof (void *); > if (posix_memalign (&ptr, alignment, size) == 0) > return ptr; > else > return __null; >} > >static __inline void >_mm_free (void * ptr) >{ > free (ptr); >} ># 35 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 2 3 4 > > >enum _mm_hint >{ > > _MM_HINT_ET0 = 7, > _MM_HINT_ET1 = 6, > _MM_HINT_T0 = 3, > _MM_HINT_T1 = 2, > _MM_HINT_T2 = 1, > _MM_HINT_NTA = 0 >}; > > > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_prefetch (const void *__P, enum _mm_hint __I) >{ > __builtin_prefetch (__P, (__I & 0x4) >> 2, __I & 0x3); >} ># 69 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 3 4 >typedef float __m128 __attribute__ ((__vector_size__ (16), __may_alias__)); > > >typedef float __v4sf __attribute__ ((__vector_size__ (16))); ># 106 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 3 4 >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_undefined_ps (void) >{ > __m128 __Y = __Y; > return __Y; >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setzero_ps (void) >{ > return __extension__ (__m128){ 0.0f, 0.0f, 0.0f, 0.0f }; >} > > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_addss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_subss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mul_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_mulss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_div_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_divss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sqrt_ss (__m128 __A) >{ > return (__m128) __builtin_ia32_sqrtss ((__v4sf)__A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rcp_ss (__m128 __A) >{ > return (__m128) __builtin_ia32_rcpss ((__v4sf)__A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rsqrt_ss (__m128 __A) >{ > return (__m128) __builtin_ia32_rsqrtss ((__v4sf)__A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_minss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_maxss ((__v4sf)__A, (__v4sf)__B); >} > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_addps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_subps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mul_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_mulps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_div_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_divps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sqrt_ps (__m128 __A) >{ > return (__m128) __builtin_ia32_sqrtps ((__v4sf)__A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rcp_ps (__m128 __A) >{ > return (__m128) __builtin_ia32_rcpps ((__v4sf)__A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rsqrt_ps (__m128 __A) >{ > return (__m128) __builtin_ia32_rsqrtps ((__v4sf)__A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_minps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_maxps ((__v4sf)__A, (__v4sf)__B); >} > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_and_ps (__m128 __A, __m128 __B) >{ > return __builtin_ia32_andps (__A, __B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_andnot_ps (__m128 __A, __m128 __B) >{ > return __builtin_ia32_andnps (__A, __B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_or_ps (__m128 __A, __m128 __B) >{ > return __builtin_ia32_orps (__A, __B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_xor_ps (__m128 __A, __m128 __B) >{ > return __builtin_ia32_xorps (__A, __B); >} > > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpeqss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmplt_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpltss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmple_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpless ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_movss ((__v4sf) __A, > (__v4sf) > __builtin_ia32_cmpltss ((__v4sf) __B, > (__v4sf) > __A)); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpge_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_movss ((__v4sf) __A, > (__v4sf) > __builtin_ia32_cmpless ((__v4sf) __B, > (__v4sf) > __A)); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpneq_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpneqss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnlt_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpnltss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnle_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpnless ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpngt_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_movss ((__v4sf) __A, > (__v4sf) > __builtin_ia32_cmpnltss ((__v4sf) __B, > (__v4sf) > __A)); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnge_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_movss ((__v4sf) __A, > (__v4sf) > __builtin_ia32_cmpnless ((__v4sf) __B, > (__v4sf) > __A)); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpord_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpordss ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpunord_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpunordss ((__v4sf)__A, (__v4sf)__B); >} > > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpeqps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmplt_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpltps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmple_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpleps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpgtps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpge_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpgeps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpneq_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpneqps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnlt_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpnltps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnle_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpnleps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpngt_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpngtps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnge_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpngeps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpord_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpordps ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpunord_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_cmpunordps ((__v4sf)__A, (__v4sf)__B); >} > > > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comieq_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_comieq ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comilt_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_comilt ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comile_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_comile ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comigt_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_comigt ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comige_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_comige ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comineq_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_comineq ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomieq_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_ucomieq ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomilt_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_ucomilt ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomile_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_ucomile ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomigt_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_ucomigt ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomige_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_ucomige ((__v4sf)__A, (__v4sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomineq_ss (__m128 __A, __m128 __B) >{ > return __builtin_ia32_ucomineq ((__v4sf)__A, (__v4sf)__B); >} > > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtss_si32 (__m128 __A) >{ > return __builtin_ia32_cvtss2si ((__v4sf) __A); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_ss2si (__m128 __A) >{ > return _mm_cvtss_si32 (__A); >} > > > > > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtss_si64 (__m128 __A) >{ > return __builtin_ia32_cvtss2si64 ((__v4sf) __A); >} > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtss_si64x (__m128 __A) >{ > return __builtin_ia32_cvtss2si64 ((__v4sf) __A); >} > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtps_pi32 (__m128 __A) >{ > return (__m64) __builtin_ia32_cvtps2pi ((__v4sf) __A); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_ps2pi (__m128 __A) >{ > return _mm_cvtps_pi32 (__A); >} > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttss_si32 (__m128 __A) >{ > return __builtin_ia32_cvttss2si ((__v4sf) __A); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_ss2si (__m128 __A) >{ > return _mm_cvttss_si32 (__A); >} > > > > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttss_si64 (__m128 __A) >{ > return __builtin_ia32_cvttss2si64 ((__v4sf) __A); >} > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttss_si64x (__m128 __A) >{ > return __builtin_ia32_cvttss2si64 ((__v4sf) __A); >} > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttps_pi32 (__m128 __A) >{ > return (__m64) __builtin_ia32_cvttps2pi ((__v4sf) __A); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_ps2pi (__m128 __A) >{ > return _mm_cvttps_pi32 (__A); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi32_ss (__m128 __A, int __B) >{ > return (__m128) __builtin_ia32_cvtsi2ss ((__v4sf) __A, __B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_si2ss (__m128 __A, int __B) >{ > return _mm_cvtsi32_ss (__A, __B); >} > > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64_ss (__m128 __A, long long __B) >{ > return (__m128) __builtin_ia32_cvtsi642ss ((__v4sf) __A, __B); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64x_ss (__m128 __A, long long __B) >{ > return (__m128) __builtin_ia32_cvtsi642ss ((__v4sf) __A, __B); >} > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpi32_ps (__m128 __A, __m64 __B) >{ > return (__m128) __builtin_ia32_cvtpi2ps ((__v4sf) __A, (__v2si)__B); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_pi2ps (__m128 __A, __m64 __B) >{ > return _mm_cvtpi32_ps (__A, __B); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpi16_ps (__m64 __A) >{ > __v4hi __sign; > __v2si __hisi, __losi; > __v4sf __zero, __ra, __rb; > > > > > __sign = __builtin_ia32_pcmpgtw ((__v4hi)0LL, (__v4hi)__A); > > > __losi = (__v2si) __builtin_ia32_punpcklwd ((__v4hi)__A, __sign); > __hisi = (__v2si) __builtin_ia32_punpckhwd ((__v4hi)__A, __sign); > > > __zero = (__v4sf) _mm_setzero_ps (); > __ra = __builtin_ia32_cvtpi2ps (__zero, __losi); > __rb = __builtin_ia32_cvtpi2ps (__ra, __hisi); > > return (__m128) __builtin_ia32_movlhps (__ra, __rb); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpu16_ps (__m64 __A) >{ > __v2si __hisi, __losi; > __v4sf __zero, __ra, __rb; > > > __losi = (__v2si) __builtin_ia32_punpcklwd ((__v4hi)__A, (__v4hi)0LL); > __hisi = (__v2si) __builtin_ia32_punpckhwd ((__v4hi)__A, (__v4hi)0LL); > > > __zero = (__v4sf) _mm_setzero_ps (); > __ra = __builtin_ia32_cvtpi2ps (__zero, __losi); > __rb = __builtin_ia32_cvtpi2ps (__ra, __hisi); > > return (__m128) __builtin_ia32_movlhps (__ra, __rb); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpi8_ps (__m64 __A) >{ > __v8qi __sign; > > > > > __sign = __builtin_ia32_pcmpgtb ((__v8qi)0LL, (__v8qi)__A); > > > __A = (__m64) __builtin_ia32_punpcklbw ((__v8qi)__A, __sign); > > return _mm_cvtpi16_ps(__A); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpu8_ps(__m64 __A) >{ > __A = (__m64) __builtin_ia32_punpcklbw ((__v8qi)__A, (__v8qi)0LL); > return _mm_cvtpu16_ps(__A); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpi32x2_ps(__m64 __A, __m64 __B) >{ > __v4sf __zero = (__v4sf) _mm_setzero_ps (); > __v4sf __sfa = __builtin_ia32_cvtpi2ps (__zero, (__v2si)__A); > __v4sf __sfb = __builtin_ia32_cvtpi2ps (__sfa, (__v2si)__B); > return (__m128) __builtin_ia32_movlhps (__sfa, __sfb); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtps_pi16(__m128 __A) >{ > __v4sf __hisf = (__v4sf)__A; > __v4sf __losf = __builtin_ia32_movhlps (__hisf, __hisf); > __v2si __hisi = __builtin_ia32_cvtps2pi (__hisf); > __v2si __losi = __builtin_ia32_cvtps2pi (__losf); > return (__m64) __builtin_ia32_packssdw (__hisi, __losi); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtps_pi8(__m128 __A) >{ > __v4hi __tmp = (__v4hi) _mm_cvtps_pi16 (__A); > return (__m64) __builtin_ia32_packsswb (__tmp, (__v4hi)0LL); >} > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shuffle_ps (__m128 __A, __m128 __B, int const __mask) >{ > return (__m128) __builtin_ia32_shufps ((__v4sf)__A, (__v4sf)__B, __mask); >} > > > > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpackhi_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_unpckhps ((__v4sf)__A, (__v4sf)__B); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpacklo_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_unpcklps ((__v4sf)__A, (__v4sf)__B); >} > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadh_pi (__m128 __A, __m64 const *__P) >{ > return (__m128) __builtin_ia32_loadhps ((__v4sf)__A, (const __v2sf *)__P); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storeh_pi (__m64 *__P, __m128 __A) >{ > __builtin_ia32_storehps ((__v2sf *)__P, (__v4sf)__A); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movehl_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_movhlps ((__v4sf)__A, (__v4sf)__B); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movelh_ps (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_movlhps ((__v4sf)__A, (__v4sf)__B); >} > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadl_pi (__m128 __A, __m64 const *__P) >{ > return (__m128) __builtin_ia32_loadlps ((__v4sf)__A, (const __v2sf *)__P); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storel_pi (__m64 *__P, __m128 __A) >{ > __builtin_ia32_storelps ((__v2sf *)__P, (__v4sf)__A); >} > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movemask_ps (__m128 __A) >{ > return __builtin_ia32_movmskps ((__v4sf)__A); >} > > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_getcsr (void) >{ > return __builtin_ia32_stmxcsr (); >} > > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_MM_GET_EXCEPTION_STATE (void) >{ > return _mm_getcsr() & 0x003f; >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_MM_GET_EXCEPTION_MASK (void) >{ > return _mm_getcsr() & 0x1f80; >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_MM_GET_ROUNDING_MODE (void) >{ > return _mm_getcsr() & 0x6000; >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_MM_GET_FLUSH_ZERO_MODE (void) >{ > return _mm_getcsr() & 0x8000; >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setcsr (unsigned int __I) >{ > __builtin_ia32_ldmxcsr (__I); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_MM_SET_EXCEPTION_STATE(unsigned int __mask) >{ > _mm_setcsr((_mm_getcsr() & ~0x003f) | __mask); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_MM_SET_EXCEPTION_MASK (unsigned int __mask) >{ > _mm_setcsr((_mm_getcsr() & ~0x1f80) | __mask); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_MM_SET_ROUNDING_MODE (unsigned int __mode) >{ > _mm_setcsr((_mm_getcsr() & ~0x6000) | __mode); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_MM_SET_FLUSH_ZERO_MODE (unsigned int __mode) >{ > _mm_setcsr((_mm_getcsr() & ~0x8000) | __mode); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_ss (float __F) >{ > return __extension__ (__m128)(__v4sf){ __F, 0.0f, 0.0f, 0.0f }; >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_ps (float __F) >{ > return __extension__ (__m128)(__v4sf){ __F, __F, __F, __F }; >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_ps1 (float __F) >{ > return _mm_set1_ps (__F); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_load_ss (float const *__P) >{ > return _mm_set_ss (*__P); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_load1_ps (float const *__P) >{ > return _mm_set1_ps (*__P); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_load_ps1 (float const *__P) >{ > return _mm_load1_ps (__P); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_load_ps (float const *__P) >{ > return (__m128) *(__v4sf *)__P; >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadu_ps (float const *__P) >{ > return (__m128) __builtin_ia32_loadups (__P); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadr_ps (float const *__P) >{ > __v4sf __tmp = *(__v4sf *)__P; > return (__m128) __builtin_ia32_shufps (__tmp, __tmp, (((0) << 6) | ((1) << 4) | ((2) << 2) | (3))); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_ps (const float __Z, const float __Y, const float __X, const float __W) >{ > return __extension__ (__m128)(__v4sf){ __W, __X, __Y, __Z }; >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setr_ps (float __Z, float __Y, float __X, float __W) >{ > return __extension__ (__m128)(__v4sf){ __Z, __Y, __X, __W }; >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_store_ss (float *__P, __m128 __A) >{ > *__P = __builtin_ia32_vec_ext_v4sf ((__v4sf)__A, 0); >} > >extern __inline float __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtss_f32 (__m128 __A) >{ > return __builtin_ia32_vec_ext_v4sf ((__v4sf)__A, 0); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_store_ps (float *__P, __m128 __A) >{ > *(__v4sf *)__P = (__v4sf)__A; >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storeu_ps (float *__P, __m128 __A) >{ > __builtin_ia32_storeups (__P, (__v4sf)__A); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_store1_ps (float *__P, __m128 __A) >{ > __v4sf __va = (__v4sf)__A; > __v4sf __tmp = __builtin_ia32_shufps (__va, __va, (((0) << 6) | ((0) << 4) | ((0) << 2) | (0))); > _mm_storeu_ps (__P, __tmp); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_store_ps1 (float *__P, __m128 __A) >{ > _mm_store1_ps (__P, __A); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storer_ps (float *__P, __m128 __A) >{ > __v4sf __va = (__v4sf)__A; > __v4sf __tmp = __builtin_ia32_shufps (__va, __va, (((0) << 6) | ((1) << 4) | ((2) << 2) | (3))); > _mm_store_ps (__P, __tmp); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_move_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_movss ((__v4sf)__A, (__v4sf)__B); >} > > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_extract_pi16 (__m64 const __A, int const __N) >{ > return __builtin_ia32_vec_ext_v4hi ((__v4hi)__A, __N); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pextrw (__m64 const __A, int const __N) >{ > return _mm_extract_pi16 (__A, __N); >} ># 1037 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 3 4 >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_insert_pi16 (__m64 const __A, int const __D, int const __N) >{ > return (__m64) __builtin_ia32_vec_set_v4hi ((__v4hi)__A, __D, __N); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pinsrw (__m64 const __A, int const __D, int const __N) >{ > return _mm_insert_pi16 (__A, __D, __N); >} ># 1057 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 3 4 >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_pi16 (__m64 __A, __m64 __B) >{ > return (__m64) __builtin_ia32_pmaxsw ((__v4hi)__A, (__v4hi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pmaxsw (__m64 __A, __m64 __B) >{ > return _mm_max_pi16 (__A, __B); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_pu8 (__m64 __A, __m64 __B) >{ > return (__m64) __builtin_ia32_pmaxub ((__v8qi)__A, (__v8qi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pmaxub (__m64 __A, __m64 __B) >{ > return _mm_max_pu8 (__A, __B); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_pi16 (__m64 __A, __m64 __B) >{ > return (__m64) __builtin_ia32_pminsw ((__v4hi)__A, (__v4hi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pminsw (__m64 __A, __m64 __B) >{ > return _mm_min_pi16 (__A, __B); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_pu8 (__m64 __A, __m64 __B) >{ > return (__m64) __builtin_ia32_pminub ((__v8qi)__A, (__v8qi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pminub (__m64 __A, __m64 __B) >{ > return _mm_min_pu8 (__A, __B); >} > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movemask_pi8 (__m64 __A) >{ > return __builtin_ia32_pmovmskb ((__v8qi)__A); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pmovmskb (__m64 __A) >{ > return _mm_movemask_pi8 (__A); >} > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mulhi_pu16 (__m64 __A, __m64 __B) >{ > return (__m64) __builtin_ia32_pmulhuw ((__v4hi)__A, (__v4hi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pmulhuw (__m64 __A, __m64 __B) >{ > return _mm_mulhi_pu16 (__A, __B); >} > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shuffle_pi16 (__m64 __A, int const __N) >{ > return (__m64) __builtin_ia32_pshufw ((__v4hi)__A, __N); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pshufw (__m64 __A, int const __N) >{ > return _mm_shuffle_pi16 (__A, __N); >} ># 1159 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 3 4 >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskmove_si64 (__m64 __A, __m64 __N, char *__P) >{ > __builtin_ia32_maskmovq ((__v8qi)__A, (__v8qi)__N, __P); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_maskmovq (__m64 __A, __m64 __N, char *__P) >{ > _mm_maskmove_si64 (__A, __N, __P); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_avg_pu8 (__m64 __A, __m64 __B) >{ > return (__m64) __builtin_ia32_pavgb ((__v8qi)__A, (__v8qi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pavgb (__m64 __A, __m64 __B) >{ > return _mm_avg_pu8 (__A, __B); >} > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_avg_pu16 (__m64 __A, __m64 __B) >{ > return (__m64) __builtin_ia32_pavgw ((__v4hi)__A, (__v4hi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pavgw (__m64 __A, __m64 __B) >{ > return _mm_avg_pu16 (__A, __B); >} > > > > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sad_pu8 (__m64 __A, __m64 __B) >{ > return (__m64) __builtin_ia32_psadbw ((__v8qi)__A, (__v8qi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_psadbw (__m64 __A, __m64 __B) >{ > return _mm_sad_pu8 (__A, __B); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_stream_pi (__m64 *__P, __m64 __A) >{ > __builtin_ia32_movntq ((unsigned long long *)__P, (unsigned long long)__A); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_stream_ps (float *__P, __m128 __A) >{ > __builtin_ia32_movntps (__P, (__v4sf)__A); >} > > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sfence (void) >{ > __builtin_ia32_sfence (); >} > > > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_pause (void) >{ > __builtin_ia32_pause (); >} ># 1258 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/emmintrin.h" 1 3 4 ># 31 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/emmintrin.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/emmintrin.h" 2 3 4 ># 40 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/emmintrin.h" 3 4 >typedef double __v2df __attribute__ ((__vector_size__ (16))); >typedef long long __v2di __attribute__ ((__vector_size__ (16))); >typedef int __v4si __attribute__ ((__vector_size__ (16))); >typedef short __v8hi __attribute__ ((__vector_size__ (16))); >typedef char __v16qi __attribute__ ((__vector_size__ (16))); > > > >typedef long long __m128i __attribute__ ((__vector_size__ (16), __may_alias__)); >typedef double __m128d __attribute__ ((__vector_size__ (16), __may_alias__)); > > > > > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_sd (double __F) >{ > return __extension__ (__m128d){ __F, 0.0 }; >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_pd (double __F) >{ > return __extension__ (__m128d){ __F, __F }; >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_pd1 (double __F) >{ > return _mm_set1_pd (__F); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_pd (double __W, double __X) >{ > return __extension__ (__m128d){ __X, __W }; >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setr_pd (double __W, double __X) >{ > return __extension__ (__m128d){ __W, __X }; >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_undefined_pd (void) >{ > __m128d __Y = __Y; > return __Y; >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setzero_pd (void) >{ > return __extension__ (__m128d){ 0.0, 0.0 }; >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_move_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_movsd ((__v2df)__A, (__v2df)__B); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_load_pd (double const *__P) >{ > return *(__m128d *)__P; >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadu_pd (double const *__P) >{ > return __builtin_ia32_loadupd (__P); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_load1_pd (double const *__P) >{ > return _mm_set1_pd (*__P); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_load_sd (double const *__P) >{ > return _mm_set_sd (*__P); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_load_pd1 (double const *__P) >{ > return _mm_load1_pd (__P); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadr_pd (double const *__P) >{ > __m128d __tmp = _mm_load_pd (__P); > return __builtin_ia32_shufpd (__tmp, __tmp, (((0) << 1) | (1))); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_store_pd (double *__P, __m128d __A) >{ > *(__m128d *)__P = __A; >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storeu_pd (double *__P, __m128d __A) >{ > __builtin_ia32_storeupd (__P, __A); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_store_sd (double *__P, __m128d __A) >{ > *__P = __builtin_ia32_vec_ext_v2df (__A, 0); >} > >extern __inline double __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsd_f64 (__m128d __A) >{ > return __builtin_ia32_vec_ext_v2df (__A, 0); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storel_pd (double *__P, __m128d __A) >{ > _mm_store_sd (__P, __A); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storeh_pd (double *__P, __m128d __A) >{ > *__P = __builtin_ia32_vec_ext_v2df (__A, 1); >} > > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_store1_pd (double *__P, __m128d __A) >{ > _mm_store_pd (__P, __builtin_ia32_shufpd (__A, __A, (((0) << 1) | (0)))); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_store_pd1 (double *__P, __m128d __A) >{ > _mm_store1_pd (__P, __A); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storer_pd (double *__P, __m128d __A) >{ > _mm_store_pd (__P, __builtin_ia32_shufpd (__A, __A, (((0) << 1) | (1)))); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi128_si32 (__m128i __A) >{ > return __builtin_ia32_vec_ext_v4si ((__v4si)__A, 0); >} > > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi128_si64 (__m128i __A) >{ > return __builtin_ia32_vec_ext_v2di ((__v2di)__A, 0); >} > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi128_si64x (__m128i __A) >{ > return __builtin_ia32_vec_ext_v2di ((__v2di)__A, 0); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_addpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_addsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_subpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_subsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mul_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_mulpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mul_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_mulsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_div_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_divpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_div_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_divsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sqrt_pd (__m128d __A) >{ > return (__m128d)__builtin_ia32_sqrtpd ((__v2df)__A); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sqrt_sd (__m128d __A, __m128d __B) >{ > __v2df __tmp = __builtin_ia32_movsd ((__v2df)__A, (__v2df)__B); > return (__m128d)__builtin_ia32_sqrtsd ((__v2df)__tmp); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_minpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_minsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_maxpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_maxsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_and_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_andpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_andnot_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_andnpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_or_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_orpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_xor_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_xorpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpeqpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmplt_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpltpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmple_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmplepd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpgtpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpge_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpgepd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpneq_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpneqpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnlt_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpnltpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnle_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpnlepd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpngt_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpngtpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnge_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpngepd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpord_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpordpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpunord_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpunordpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpeqsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmplt_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpltsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmple_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmplesd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_movsd ((__v2df) __A, > (__v2df) > __builtin_ia32_cmpltsd ((__v2df) __B, > (__v2df) > __A)); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpge_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_movsd ((__v2df) __A, > (__v2df) > __builtin_ia32_cmplesd ((__v2df) __B, > (__v2df) > __A)); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpneq_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpneqsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnlt_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpnltsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnle_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpnlesd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpngt_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_movsd ((__v2df) __A, > (__v2df) > __builtin_ia32_cmpnltsd ((__v2df) __B, > (__v2df) > __A)); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpnge_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_movsd ((__v2df) __A, > (__v2df) > __builtin_ia32_cmpnlesd ((__v2df) __B, > (__v2df) > __A)); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpord_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpordsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpunord_sd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_cmpunordsd ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comieq_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_comisdeq ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comilt_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_comisdlt ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comile_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_comisdle ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comigt_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_comisdgt ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comige_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_comisdge ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comineq_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_comisdneq ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomieq_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_ucomisdeq ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomilt_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_ucomisdlt ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomile_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_ucomisdle ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomigt_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_ucomisdgt ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomige_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_ucomisdge ((__v2df)__A, (__v2df)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_ucomineq_sd (__m128d __A, __m128d __B) >{ > return __builtin_ia32_ucomisdneq ((__v2df)__A, (__v2df)__B); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_epi64x (long long __q1, long long __q0) >{ > return __extension__ (__m128i)(__v2di){ __q0, __q1 }; >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_epi64 (__m64 __q1, __m64 __q0) >{ > return _mm_set_epi64x ((long long)__q1, (long long)__q0); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_epi32 (int __q3, int __q2, int __q1, int __q0) >{ > return __extension__ (__m128i)(__v4si){ __q0, __q1, __q2, __q3 }; >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_epi16 (short __q7, short __q6, short __q5, short __q4, > short __q3, short __q2, short __q1, short __q0) >{ > return __extension__ (__m128i)(__v8hi){ > __q0, __q1, __q2, __q3, __q4, __q5, __q6, __q7 }; >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set_epi8 (char __q15, char __q14, char __q13, char __q12, > char __q11, char __q10, char __q09, char __q08, > char __q07, char __q06, char __q05, char __q04, > char __q03, char __q02, char __q01, char __q00) >{ > return __extension__ (__m128i)(__v16qi){ > __q00, __q01, __q02, __q03, __q04, __q05, __q06, __q07, > __q08, __q09, __q10, __q11, __q12, __q13, __q14, __q15 > }; >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_epi64x (long long __A) >{ > return _mm_set_epi64x (__A, __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_epi64 (__m64 __A) >{ > return _mm_set_epi64 (__A, __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_epi32 (int __A) >{ > return _mm_set_epi32 (__A, __A, __A, __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_epi16 (short __A) >{ > return _mm_set_epi16 (__A, __A, __A, __A, __A, __A, __A, __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_set1_epi8 (char __A) >{ > return _mm_set_epi8 (__A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A); >} > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setr_epi64 (__m64 __q0, __m64 __q1) >{ > return _mm_set_epi64 (__q1, __q0); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setr_epi32 (int __q0, int __q1, int __q2, int __q3) >{ > return _mm_set_epi32 (__q3, __q2, __q1, __q0); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setr_epi16 (short __q0, short __q1, short __q2, short __q3, > short __q4, short __q5, short __q6, short __q7) >{ > return _mm_set_epi16 (__q7, __q6, __q5, __q4, __q3, __q2, __q1, __q0); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setr_epi8 (char __q00, char __q01, char __q02, char __q03, > char __q04, char __q05, char __q06, char __q07, > char __q08, char __q09, char __q10, char __q11, > char __q12, char __q13, char __q14, char __q15) >{ > return _mm_set_epi8 (__q15, __q14, __q13, __q12, __q11, __q10, __q09, __q08, > __q07, __q06, __q05, __q04, __q03, __q02, __q01, __q00); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_load_si128 (__m128i const *__P) >{ > return *__P; >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadu_si128 (__m128i const *__P) >{ > return (__m128i) __builtin_ia32_loaddqu ((char const *)__P); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadl_epi64 (__m128i const *__P) >{ > return _mm_set_epi64 ((__m64)0LL, *(__m64 *)__P); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_store_si128 (__m128i *__P, __m128i __B) >{ > *__P = __B; >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storeu_si128 (__m128i *__P, __m128i __B) >{ > __builtin_ia32_storedqu ((char *)__P, (__v16qi)__B); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_storel_epi64 (__m128i *__P, __m128i __B) >{ > *(long long *)__P = __builtin_ia32_vec_ext_v2di ((__v2di)__B, 0); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movepi64_pi64 (__m128i __B) >{ > return (__m64) __builtin_ia32_vec_ext_v2di ((__v2di)__B, 0); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movpi64_epi64 (__m64 __A) >{ > return _mm_set_epi64 ((__m64)0LL, __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_move_epi64 (__m128i __A) >{ > return (__m128i)__builtin_ia32_movq128 ((__v2di) __A); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_undefined_si128 (void) >{ > __m128i __Y = __Y; > return __Y; >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_setzero_si128 (void) >{ > return __extension__ (__m128i)(__v4si){ 0, 0, 0, 0 }; >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepi32_pd (__m128i __A) >{ > return (__m128d)__builtin_ia32_cvtdq2pd ((__v4si) __A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepi32_ps (__m128i __A) >{ > return (__m128)__builtin_ia32_cvtdq2ps ((__v4si) __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpd_epi32 (__m128d __A) >{ > return (__m128i)__builtin_ia32_cvtpd2dq ((__v2df) __A); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpd_pi32 (__m128d __A) >{ > return (__m64)__builtin_ia32_cvtpd2pi ((__v2df) __A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpd_ps (__m128d __A) >{ > return (__m128)__builtin_ia32_cvtpd2ps ((__v2df) __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttpd_epi32 (__m128d __A) >{ > return (__m128i)__builtin_ia32_cvttpd2dq ((__v2df) __A); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttpd_pi32 (__m128d __A) >{ > return (__m64)__builtin_ia32_cvttpd2pi ((__v2df) __A); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtpi32_pd (__m64 __A) >{ > return (__m128d)__builtin_ia32_cvtpi2pd ((__v2si) __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtps_epi32 (__m128 __A) >{ > return (__m128i)__builtin_ia32_cvtps2dq ((__v4sf) __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttps_epi32 (__m128 __A) >{ > return (__m128i)__builtin_ia32_cvttps2dq ((__v4sf) __A); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtps_pd (__m128 __A) >{ > return (__m128d)__builtin_ia32_cvtps2pd ((__v4sf) __A); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsd_si32 (__m128d __A) >{ > return __builtin_ia32_cvtsd2si ((__v2df) __A); >} > > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsd_si64 (__m128d __A) >{ > return __builtin_ia32_cvtsd2si64 ((__v2df) __A); >} > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsd_si64x (__m128d __A) >{ > return __builtin_ia32_cvtsd2si64 ((__v2df) __A); >} > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttsd_si32 (__m128d __A) >{ > return __builtin_ia32_cvttsd2si ((__v2df) __A); >} > > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttsd_si64 (__m128d __A) >{ > return __builtin_ia32_cvttsd2si64 ((__v2df) __A); >} > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttsd_si64x (__m128d __A) >{ > return __builtin_ia32_cvttsd2si64 ((__v2df) __A); >} > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsd_ss (__m128 __A, __m128d __B) >{ > return (__m128)__builtin_ia32_cvtsd2ss ((__v4sf) __A, (__v2df) __B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi32_sd (__m128d __A, int __B) >{ > return (__m128d)__builtin_ia32_cvtsi2sd ((__v2df) __A, __B); >} > > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64_sd (__m128d __A, long long __B) >{ > return (__m128d)__builtin_ia32_cvtsi642sd ((__v2df) __A, __B); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64x_sd (__m128d __A, long long __B) >{ > return (__m128d)__builtin_ia32_cvtsi642sd ((__v2df) __A, __B); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtss_sd (__m128d __A, __m128 __B) >{ > return (__m128d)__builtin_ia32_cvtss2sd ((__v2df) __A, (__v4sf)__B); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shuffle_pd(__m128d __A, __m128d __B, const int __mask) >{ > return (__m128d)__builtin_ia32_shufpd ((__v2df)__A, (__v2df)__B, __mask); >} > > > > > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpackhi_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_unpckhpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpacklo_pd (__m128d __A, __m128d __B) >{ > return (__m128d)__builtin_ia32_unpcklpd ((__v2df)__A, (__v2df)__B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadh_pd (__m128d __A, double const *__B) >{ > return (__m128d)__builtin_ia32_loadhpd ((__v2df)__A, __B); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loadl_pd (__m128d __A, double const *__B) >{ > return (__m128d)__builtin_ia32_loadlpd ((__v2df)__A, __B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movemask_pd (__m128d __A) >{ > return __builtin_ia32_movmskpd ((__v2df)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_packs_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_packsswb128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_packs_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_packssdw128 ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_packus_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_packuswb128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpackhi_epi8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_punpckhbw128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpackhi_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_punpckhwd128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpackhi_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_punpckhdq128 ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpackhi_epi64 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_punpckhqdq128 ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpacklo_epi8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_punpcklbw128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpacklo_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_punpcklwd128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpacklo_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_punpckldq128 ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_unpacklo_epi64 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_punpcklqdq128 ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_epi8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_paddb128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_paddw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_paddd128 ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_epi64 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_paddq128 ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_adds_epi8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_paddsb128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_adds_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_paddsw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_adds_epu8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_paddusb128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_adds_epu16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_paddusw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_epi8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psubb128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psubw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psubd128 ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_epi64 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psubq128 ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_subs_epi8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psubsb128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_subs_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psubsw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_subs_epu8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psubusb128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_subs_epu16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psubusw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_madd_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pmaddwd128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mulhi_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pmulhw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mullo_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pmullw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mul_su32 (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pmuludq ((__v2si)__A, (__v2si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mul_epu32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pmuludq128 ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_slli_epi16 (__m128i __A, int __B) >{ > return (__m128i)__builtin_ia32_psllwi128 ((__v8hi)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_slli_epi32 (__m128i __A, int __B) >{ > return (__m128i)__builtin_ia32_pslldi128 ((__v4si)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_slli_epi64 (__m128i __A, int __B) >{ > return (__m128i)__builtin_ia32_psllqi128 ((__v2di)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srai_epi16 (__m128i __A, int __B) >{ > return (__m128i)__builtin_ia32_psrawi128 ((__v8hi)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srai_epi32 (__m128i __A, int __B) >{ > return (__m128i)__builtin_ia32_psradi128 ((__v4si)__A, __B); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srli_si128 (__m128i __A, const int __N) >{ > return (__m128i)__builtin_ia32_psrldqi128 (__A, __N * 8); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_slli_si128 (__m128i __A, const int __N) >{ > return (__m128i)__builtin_ia32_pslldqi128 (__A, __N * 8); >} > > > > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srli_epi16 (__m128i __A, int __B) >{ > return (__m128i)__builtin_ia32_psrlwi128 ((__v8hi)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srli_epi32 (__m128i __A, int __B) >{ > return (__m128i)__builtin_ia32_psrldi128 ((__v4si)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srli_epi64 (__m128i __A, int __B) >{ > return (__m128i)__builtin_ia32_psrlqi128 ((__v2di)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sll_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psllw128((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sll_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pslld128((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sll_epi64 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psllq128((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sra_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psraw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sra_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psrad128 ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srl_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psrlw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srl_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psrld128 ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srl_epi64 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psrlq128 ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_and_si128 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pand128 ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_andnot_si128 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pandn128 ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_or_si128 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_por128 ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_xor_si128 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pxor128 ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_epi8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pcmpeqb128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pcmpeqw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pcmpeqd128 ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmplt_epi8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pcmpgtb128 ((__v16qi)__B, (__v16qi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmplt_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pcmpgtw128 ((__v8hi)__B, (__v8hi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmplt_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pcmpgtd128 ((__v4si)__B, (__v4si)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_epi8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pcmpgtb128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pcmpgtw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_epi32 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pcmpgtd128 ((__v4si)__A, (__v4si)__B); >} > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_extract_epi16 (__m128i const __A, int const __N) >{ > return (unsigned short) __builtin_ia32_vec_ext_v8hi ((__v8hi)__A, __N); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_insert_epi16 (__m128i const __A, int const __D, int const __N) >{ > return (__m128i) __builtin_ia32_vec_set_v8hi ((__v8hi)__A, __D, __N); >} ># 1345 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/emmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pmaxsw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_epu8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pmaxub128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_epi16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pminsw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_epu8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pminub128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movemask_epi8 (__m128i __A) >{ > return __builtin_ia32_pmovmskb128 ((__v16qi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mulhi_epu16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pmulhuw128 ((__v8hi)__A, (__v8hi)__B); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shufflehi_epi16 (__m128i __A, const int __mask) >{ > return (__m128i)__builtin_ia32_pshufhw ((__v8hi)__A, __mask); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shufflelo_epi16 (__m128i __A, const int __mask) >{ > return (__m128i)__builtin_ia32_pshuflw ((__v8hi)__A, __mask); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shuffle_epi32 (__m128i __A, const int __mask) >{ > return (__m128i)__builtin_ia32_pshufd ((__v4si)__A, __mask); >} ># 1408 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/emmintrin.h" 3 4 >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskmoveu_si128 (__m128i __A, __m128i __B, char *__C) >{ > __builtin_ia32_maskmovdqu ((__v16qi)__A, (__v16qi)__B, __C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_avg_epu8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pavgb128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_avg_epu16 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_pavgw128 ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sad_epu8 (__m128i __A, __m128i __B) >{ > return (__m128i)__builtin_ia32_psadbw128 ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_stream_si32 (int *__A, int __B) >{ > __builtin_ia32_movnti (__A, __B); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_stream_si64 (long long int *__A, long long int __B) >{ > __builtin_ia32_movnti64 (__A, __B); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_stream_si128 (__m128i *__A, __m128i __B) >{ > __builtin_ia32_movntdq ((__v2di *)__A, (__v2di)__B); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_stream_pd (double *__A, __m128d __B) >{ > __builtin_ia32_movntpd (__A, (__v2df)__B); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_clflush (void const *__A) >{ > __builtin_ia32_clflush (__A); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_lfence (void) >{ > __builtin_ia32_lfence (); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mfence (void) >{ > __builtin_ia32_mfence (); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi32_si128 (int __A) >{ > return _mm_set_epi32 (0, 0, 0, __A); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64_si128 (long long __A) >{ > return _mm_set_epi64x (0, __A); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsi64x_si128 (long long __A) >{ > return _mm_set_epi64x (0, __A); >} > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_castpd_ps(__m128d __A) >{ > return (__m128) __A; >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_castpd_si128(__m128d __A) >{ > return (__m128i) __A; >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_castps_pd(__m128 __A) >{ > return (__m128d) __A; >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_castps_si128(__m128 __A) >{ > return (__m128i) __A; >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_castsi128_ps(__m128i __A) >{ > return (__m128) __A; >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_castsi128_pd(__m128i __A) >{ > return (__m128d) __A; >} ># 1259 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xmmintrin.h" 2 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/pmmintrin.h" 1 3 4 ># 49 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/pmmintrin.h" 3 4 >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_addsub_ps (__m128 __X, __m128 __Y) >{ > return (__m128) __builtin_ia32_addsubps ((__v4sf)__X, (__v4sf)__Y); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hadd_ps (__m128 __X, __m128 __Y) >{ > return (__m128) __builtin_ia32_haddps ((__v4sf)__X, (__v4sf)__Y); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsub_ps (__m128 __X, __m128 __Y) >{ > return (__m128) __builtin_ia32_hsubps ((__v4sf)__X, (__v4sf)__Y); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movehdup_ps (__m128 __X) >{ > return (__m128) __builtin_ia32_movshdup ((__v4sf)__X); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_moveldup_ps (__m128 __X) >{ > return (__m128) __builtin_ia32_movsldup ((__v4sf)__X); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_addsub_pd (__m128d __X, __m128d __Y) >{ > return (__m128d) __builtin_ia32_addsubpd ((__v2df)__X, (__v2df)__Y); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hadd_pd (__m128d __X, __m128d __Y) >{ > return (__m128d) __builtin_ia32_haddpd ((__v2df)__X, (__v2df)__Y); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsub_pd (__m128d __X, __m128d __Y) >{ > return (__m128d) __builtin_ia32_hsubpd ((__v2df)__X, (__v2df)__Y); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_loaddup_pd (double const *__P) >{ > return _mm_load1_pd (__P); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_movedup_pd (__m128d __X) >{ > return _mm_shuffle_pd (__X, __X, (((0) << 1) | (0))); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_lddqu_si128 (__m128i const *__P) >{ > return (__m128i) __builtin_ia32_lddqu ((char const *)__P); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_monitor (void const * __P, unsigned int __E, unsigned int __H) >{ > __builtin_ia32_monitor (__P, __E, __H); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mwait (unsigned int __E, unsigned int __H) >{ > __builtin_ia32_mwait (__E, __H); >} ># 36 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/tmmintrin.h" 1 3 4 ># 39 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/tmmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hadd_epi16 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_phaddw128 ((__v8hi)__X, (__v8hi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hadd_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_phaddd128 ((__v4si)__X, (__v4si)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hadds_epi16 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_phaddsw128 ((__v8hi)__X, (__v8hi)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hadd_pi16 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_phaddw ((__v4hi)__X, (__v4hi)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hadd_pi32 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_phaddd ((__v2si)__X, (__v2si)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hadds_pi16 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_phaddsw ((__v4hi)__X, (__v4hi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsub_epi16 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_phsubw128 ((__v8hi)__X, (__v8hi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsub_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_phsubd128 ((__v4si)__X, (__v4si)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsubs_epi16 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_phsubsw128 ((__v8hi)__X, (__v8hi)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsub_pi16 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_phsubw ((__v4hi)__X, (__v4hi)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsub_pi32 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_phsubd ((__v2si)__X, (__v2si)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsubs_pi16 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_phsubsw ((__v4hi)__X, (__v4hi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maddubs_epi16 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pmaddubsw128 ((__v16qi)__X, (__v16qi)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maddubs_pi16 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_pmaddubsw ((__v8qi)__X, (__v8qi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mulhrs_epi16 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pmulhrsw128 ((__v8hi)__X, (__v8hi)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mulhrs_pi16 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_pmulhrsw ((__v4hi)__X, (__v4hi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shuffle_epi8 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pshufb128 ((__v16qi)__X, (__v16qi)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shuffle_pi8 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_pshufb ((__v8qi)__X, (__v8qi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sign_epi8 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_psignb128 ((__v16qi)__X, (__v16qi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sign_epi16 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_psignw128 ((__v8hi)__X, (__v8hi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sign_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_psignd128 ((__v4si)__X, (__v4si)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sign_pi8 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_psignb ((__v8qi)__X, (__v8qi)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sign_pi16 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_psignw ((__v4hi)__X, (__v4hi)__Y); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sign_pi32 (__m64 __X, __m64 __Y) >{ > return (__m64) __builtin_ia32_psignd ((__v2si)__X, (__v2si)__Y); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_alignr_epi8(__m128i __X, __m128i __Y, const int __N) >{ > return (__m128i) __builtin_ia32_palignr128 ((__v2di)__X, > (__v2di)__Y, __N * 8); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_alignr_pi8(__m64 __X, __m64 __Y, const int __N) >{ > return (__m64) __builtin_ia32_palignr ((__v1di)__X, > (__v1di)__Y, __N * 8); >} ># 208 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/tmmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_abs_epi8 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pabsb128 ((__v16qi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_abs_epi16 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pabsw128 ((__v8hi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_abs_epi32 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pabsd128 ((__v4si)__X); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_abs_pi8 (__m64 __X) >{ > return (__m64) __builtin_ia32_pabsb ((__v8qi)__X); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_abs_pi16 (__m64 __X) >{ > return (__m64) __builtin_ia32_pabsw ((__v4hi)__X); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_abs_pi32 (__m64 __X) >{ > return (__m64) __builtin_ia32_pabsd ((__v2si)__X); >} ># 38 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/ammintrin.h" 1 3 4 ># 34 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/ammintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("sse4a") > > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_stream_sd (double * __P, __m128d __Y) >{ > __builtin_ia32_movntsd (__P, (__v2df) __Y); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_stream_ss (float * __P, __m128 __Y) >{ > __builtin_ia32_movntss (__P, (__v4sf) __Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_extract_si64 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_extrq ((__v2di) __X, (__v16qi) __Y); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_extracti_si64 (__m128i __X, unsigned const int __I, unsigned const int __L) >{ > return (__m128i) __builtin_ia32_extrqi ((__v2di) __X, __I, __L); >} > > > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_insert_si64 (__m128i __X,__m128i __Y) >{ > return (__m128i) __builtin_ia32_insertq ((__v2di)__X, (__v2di)__Y); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_inserti_si64(__m128i __X, __m128i __Y, unsigned const int __I, unsigned const int __L) >{ > return (__m128i) __builtin_ia32_insertqi ((__v2di)__X, (__v2di)__Y, __I, __L); >} ># 90 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/ammintrin.h" 3 4 >#pragma GCC pop_options ># 40 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 1 3 4 ># 66 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_testz_si128 (__m128i __M, __m128i __V) >{ > return __builtin_ia32_ptestz128 ((__v2di)__M, (__v2di)__V); >} > > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_testc_si128 (__m128i __M, __m128i __V) >{ > return __builtin_ia32_ptestc128 ((__v2di)__M, (__v2di)__V); >} > > > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_testnzc_si128 (__m128i __M, __m128i __V) >{ > return __builtin_ia32_ptestnzc128 ((__v2di)__M, (__v2di)__V); >} ># 99 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_round_pd (__m128d __V, const int __M) >{ > return (__m128d) __builtin_ia32_roundpd ((__v2df)__V, __M); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_round_sd(__m128d __D, __m128d __V, const int __M) >{ > return (__m128d) __builtin_ia32_roundsd ((__v2df)__D, > (__v2df)__V, > __M); >} ># 124 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_round_ps (__m128 __V, const int __M) >{ > return (__m128) __builtin_ia32_roundps ((__v4sf)__V, __M); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_round_ss (__m128 __D, __m128 __V, const int __M) >{ > return (__m128) __builtin_ia32_roundss ((__v4sf)__D, > (__v4sf)__V, > __M); >} ># 165 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_blend_epi16 (__m128i __X, __m128i __Y, const int __M) >{ > return (__m128i) __builtin_ia32_pblendw128 ((__v8hi)__X, > (__v8hi)__Y, > __M); >} > > > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_blendv_epi8 (__m128i __X, __m128i __Y, __m128i __M) >{ > return (__m128i) __builtin_ia32_pblendvb128 ((__v16qi)__X, > (__v16qi)__Y, > (__v16qi)__M); >} > > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_blend_ps (__m128 __X, __m128 __Y, const int __M) >{ > return (__m128) __builtin_ia32_blendps ((__v4sf)__X, > (__v4sf)__Y, > __M); >} > > > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_blendv_ps (__m128 __X, __m128 __Y, __m128 __M) >{ > return (__m128) __builtin_ia32_blendvps ((__v4sf)__X, > (__v4sf)__Y, > (__v4sf)__M); >} > > > > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_blend_pd (__m128d __X, __m128d __Y, const int __M) >{ > return (__m128d) __builtin_ia32_blendpd ((__v2df)__X, > (__v2df)__Y, > __M); >} > > > > > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_blendv_pd (__m128d __X, __m128d __Y, __m128d __M) >{ > return (__m128d) __builtin_ia32_blendvpd ((__v2df)__X, > (__v2df)__Y, > (__v2df)__M); >} > > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_dp_ps (__m128 __X, __m128 __Y, const int __M) >{ > return (__m128) __builtin_ia32_dpps ((__v4sf)__X, > (__v4sf)__Y, > __M); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_dp_pd (__m128d __X, __m128d __Y, const int __M) >{ > return (__m128d) __builtin_ia32_dppd ((__v2df)__X, > (__v2df)__Y, > __M); >} ># 267 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpeq_epi64 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pcmpeqq ((__v2di)__X, (__v2di)__Y); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_epi8 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pminsb128 ((__v16qi)__X, (__v16qi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_epi8 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pmaxsb128 ((__v16qi)__X, (__v16qi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_epu16 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pminuw128 ((__v8hi)__X, (__v8hi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_epu16 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pmaxuw128 ((__v8hi)__X, (__v8hi)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pminsd128 ((__v4si)__X, (__v4si)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pmaxsd128 ((__v4si)__X, (__v4si)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_epu32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pminud128 ((__v4si)__X, (__v4si)__Y); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_epu32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pmaxud128 ((__v4si)__X, (__v4si)__Y); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mullo_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pmulld128 ((__v4si)__X, (__v4si)__Y); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mul_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pmuldq128 ((__v4si)__X, (__v4si)__Y); >} > > > > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_insert_ps (__m128 __D, __m128 __S, const int __N) >{ > return (__m128) __builtin_ia32_insertps128 ((__v4sf)__D, > (__v4sf)__S, > __N); >} ># 365 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_extract_ps (__m128 __X, const int __N) >{ > union { int i; float f; } __tmp; > __tmp.f = __builtin_ia32_vec_ext_v4sf ((__v4sf)__X, __N); > return __tmp.i; >} ># 398 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_insert_epi8 (__m128i __D, int __S, const int __N) >{ > return (__m128i) __builtin_ia32_vec_set_v16qi ((__v16qi)__D, > __S, __N); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_insert_epi32 (__m128i __D, int __S, const int __N) >{ > return (__m128i) __builtin_ia32_vec_set_v4si ((__v4si)__D, > __S, __N); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_insert_epi64 (__m128i __D, long long __S, const int __N) >{ > return (__m128i) __builtin_ia32_vec_set_v2di ((__v2di)__D, > __S, __N); >} ># 440 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_extract_epi8 (__m128i __X, const int __N) >{ > return (unsigned char) __builtin_ia32_vec_ext_v16qi ((__v16qi)__X, __N); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_extract_epi32 (__m128i __X, const int __N) >{ > return __builtin_ia32_vec_ext_v4si ((__v4si)__X, __N); >} > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_extract_epi64 (__m128i __X, const int __N) >{ > return __builtin_ia32_vec_ext_v2di ((__v2di)__X, __N); >} ># 473 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_minpos_epu16 (__m128i __X) >{ > return (__m128i) __builtin_ia32_phminposuw128 ((__v8hi)__X); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepi8_epi32 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovsxbd128 ((__v16qi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepi16_epi32 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovsxwd128 ((__v8hi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepi8_epi64 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovsxbq128 ((__v16qi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepi32_epi64 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovsxdq128 ((__v4si)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepi16_epi64 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovsxwq128 ((__v8hi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepi8_epi16 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovsxbw128 ((__v16qi)__X); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepu8_epi32 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovzxbd128 ((__v16qi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepu16_epi32 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovzxwd128 ((__v8hi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepu8_epi64 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovzxbq128 ((__v16qi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepu32_epi64 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovzxdq128 ((__v4si)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepu16_epi64 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovzxwq128 ((__v8hi)__X); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtepu8_epi16 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pmovzxbw128 ((__v16qi)__X); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_packus_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_packusdw128 ((__v4si)__X, (__v4si)__Y); >} > > > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mpsadbw_epu8 (__m128i __X, __m128i __Y, const int __M) >{ > return (__m128i) __builtin_ia32_mpsadbw128 ((__v16qi)__X, > (__v16qi)__Y, __M); >} > > > > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_stream_load_si128 (__m128i *__X) >{ > return (__m128i) __builtin_ia32_movntdqa ((__v2di *) __X); >} ># 622 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpistrm (__m128i __X, __m128i __Y, const int __M) >{ > return (__m128i) __builtin_ia32_pcmpistrm128 ((__v16qi)__X, > (__v16qi)__Y, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpistri (__m128i __X, __m128i __Y, const int __M) >{ > return __builtin_ia32_pcmpistri128 ((__v16qi)__X, > (__v16qi)__Y, > __M); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpestrm (__m128i __X, int __LX, __m128i __Y, int __LY, const int __M) >{ > return (__m128i) __builtin_ia32_pcmpestrm128 ((__v16qi)__X, __LX, > (__v16qi)__Y, __LY, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpestri (__m128i __X, int __LX, __m128i __Y, int __LY, const int __M) >{ > return __builtin_ia32_pcmpestri128 ((__v16qi)__X, __LX, > (__v16qi)__Y, __LY, > __M); >} ># 675 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpistra (__m128i __X, __m128i __Y, const int __M) >{ > return __builtin_ia32_pcmpistria128 ((__v16qi)__X, > (__v16qi)__Y, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpistrc (__m128i __X, __m128i __Y, const int __M) >{ > return __builtin_ia32_pcmpistric128 ((__v16qi)__X, > (__v16qi)__Y, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpistro (__m128i __X, __m128i __Y, const int __M) >{ > return __builtin_ia32_pcmpistrio128 ((__v16qi)__X, > (__v16qi)__Y, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpistrs (__m128i __X, __m128i __Y, const int __M) >{ > return __builtin_ia32_pcmpistris128 ((__v16qi)__X, > (__v16qi)__Y, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpistrz (__m128i __X, __m128i __Y, const int __M) >{ > return __builtin_ia32_pcmpistriz128 ((__v16qi)__X, > (__v16qi)__Y, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpestra (__m128i __X, int __LX, __m128i __Y, int __LY, const int __M) >{ > return __builtin_ia32_pcmpestria128 ((__v16qi)__X, __LX, > (__v16qi)__Y, __LY, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpestrc (__m128i __X, int __LX, __m128i __Y, int __LY, const int __M) >{ > return __builtin_ia32_pcmpestric128 ((__v16qi)__X, __LX, > (__v16qi)__Y, __LY, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpestro (__m128i __X, int __LX, __m128i __Y, int __LY, const int __M) >{ > return __builtin_ia32_pcmpestrio128 ((__v16qi)__X, __LX, > (__v16qi)__Y, __LY, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpestrs (__m128i __X, int __LX, __m128i __Y, int __LY, const int __M) >{ > return __builtin_ia32_pcmpestris128 ((__v16qi)__X, __LX, > (__v16qi)__Y, __LY, > __M); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpestrz (__m128i __X, int __LX, __m128i __Y, int __LY, const int __M) >{ > return __builtin_ia32_pcmpestriz128 ((__v16qi)__X, __LX, > (__v16qi)__Y, __LY, > __M); >} ># 795 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmpgt_epi64 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_pcmpgtq ((__v2di)__X, (__v2di)__Y); >} ># 811 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/popcntintrin.h" 1 3 4 ># 34 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/popcntintrin.h" 3 4 >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_popcnt_u32 (unsigned int __X) >{ > return __builtin_popcount (__X); >} > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_popcnt_u64 (unsigned long long __X) >{ > return __builtin_popcountll (__X); >} ># 812 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 2 3 4 ># 826 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/smmintrin.h" 3 4 >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_crc32_u8 (unsigned int __C, unsigned char __V) >{ > return __builtin_ia32_crc32qi (__C, __V); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_crc32_u16 (unsigned int __C, unsigned short __V) >{ > return __builtin_ia32_crc32hi (__C, __V); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_crc32_u32 (unsigned int __C, unsigned int __V) >{ > return __builtin_ia32_crc32si (__C, __V); >} > > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_crc32_u64 (unsigned long long __C, unsigned long long __V) >{ > return __builtin_ia32_crc32di (__C, __V); >} ># 42 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/wmmintrin.h" 1 3 4 ># 43 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/wmmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_aesdec_si128 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_aesdec128 ((__v2di)__X, (__v2di)__Y); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_aesdeclast_si128 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_aesdeclast128 ((__v2di)__X, > (__v2di)__Y); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_aesenc_si128 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_aesenc128 ((__v2di)__X, (__v2di)__Y); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_aesenclast_si128 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_aesenclast128 ((__v2di)__X, (__v2di)__Y); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_aesimc_si128 (__m128i __X) >{ > return (__m128i) __builtin_ia32_aesimc128 ((__v2di)__X); >} > > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_aeskeygenassist_si128 (__m128i __X, const int __C) >{ > return (__m128i) __builtin_ia32_aeskeygenassist128 ((__v2di)__X, __C); >} ># 115 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/wmmintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_clmulepi64_si128 (__m128i __X, __m128i __Y, const int __I) >{ > return (__m128i) __builtin_ia32_pclmulqdq128 ((__v2di)__X, > (__v2di)__Y, __I); >} ># 44 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 1 3 4 ># 41 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 1 3 4 ># 41 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >typedef double __v4df __attribute__ ((__vector_size__ (32))); >typedef float __v8sf __attribute__ ((__vector_size__ (32))); >typedef long long __v4di __attribute__ ((__vector_size__ (32))); >typedef int __v8si __attribute__ ((__vector_size__ (32))); >typedef short __v16hi __attribute__ ((__vector_size__ (32))); >typedef char __v32qi __attribute__ ((__vector_size__ (32))); > > > >typedef float __m256 __attribute__ ((__vector_size__ (32), > __may_alias__)); >typedef long long __m256i __attribute__ ((__vector_size__ (32), > __may_alias__)); >typedef double __m256d __attribute__ ((__vector_size__ (32), > __may_alias__)); ># 124 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_add_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_addpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_add_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_addps256 ((__v8sf)__A, (__v8sf)__B); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_addsub_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_addsubpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_addsub_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_addsubps256 ((__v8sf)__A, (__v8sf)__B); >} > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_and_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_andpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_and_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_andps256 ((__v8sf)__A, (__v8sf)__B); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_andnot_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_andnpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_andnot_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_andnps256 ((__v8sf)__A, (__v8sf)__B); >} > > > > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_blend_pd (__m256d __X, __m256d __Y, const int __M) >{ > return (__m256d) __builtin_ia32_blendpd256 ((__v4df)__X, > (__v4df)__Y, > __M); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_blend_ps (__m256 __X, __m256 __Y, const int __M) >{ > return (__m256) __builtin_ia32_blendps256 ((__v8sf)__X, > (__v8sf)__Y, > __M); >} ># 202 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_blendv_pd (__m256d __X, __m256d __Y, __m256d __M) >{ > return (__m256d) __builtin_ia32_blendvpd256 ((__v4df)__X, > (__v4df)__Y, > (__v4df)__M); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_blendv_ps (__m256 __X, __m256 __Y, __m256 __M) >{ > return (__m256) __builtin_ia32_blendvps256 ((__v8sf)__X, > (__v8sf)__Y, > (__v8sf)__M); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_div_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_divpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_div_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_divps256 ((__v8sf)__A, (__v8sf)__B); >} > > > > > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_dp_ps (__m256 __X, __m256 __Y, const int __M) >{ > return (__m256) __builtin_ia32_dpps256 ((__v8sf)__X, > (__v8sf)__Y, > __M); >} > > > > > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hadd_pd (__m256d __X, __m256d __Y) >{ > return (__m256d) __builtin_ia32_haddpd256 ((__v4df)__X, (__v4df)__Y); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hadd_ps (__m256 __X, __m256 __Y) >{ > return (__m256) __builtin_ia32_haddps256 ((__v8sf)__X, (__v8sf)__Y); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hsub_pd (__m256d __X, __m256d __Y) >{ > return (__m256d) __builtin_ia32_hsubpd256 ((__v4df)__X, (__v4df)__Y); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hsub_ps (__m256 __X, __m256 __Y) >{ > return (__m256) __builtin_ia32_hsubps256 ((__v8sf)__X, (__v8sf)__Y); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_max_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_maxpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_max_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_maxps256 ((__v8sf)__A, (__v8sf)__B); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_min_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_minpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_min_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_minps256 ((__v8sf)__A, (__v8sf)__B); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mul_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_mulpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mul_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_mulps256 ((__v8sf)__A, (__v8sf)__B); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_or_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_orpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_or_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_orps256 ((__v8sf)__A, (__v8sf)__B); >} > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_shuffle_pd (__m256d __A, __m256d __B, const int __mask) >{ > return (__m256d) __builtin_ia32_shufpd256 ((__v4df)__A, (__v4df)__B, > __mask); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_shuffle_ps (__m256 __A, __m256 __B, const int __mask) >{ > return (__m256) __builtin_ia32_shufps256 ((__v8sf)__A, (__v8sf)__B, > __mask); >} ># 343 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sub_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_subpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sub_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_subps256 ((__v8sf)__A, (__v8sf)__B); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_xor_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_xorpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_xor_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_xorps256 ((__v8sf)__A, (__v8sf)__B); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmp_pd (__m128d __X, __m128d __Y, const int __P) >{ > return (__m128d) __builtin_ia32_cmppd ((__v2df)__X, (__v2df)__Y, __P); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmp_ps (__m128 __X, __m128 __Y, const int __P) >{ > return (__m128) __builtin_ia32_cmpps ((__v4sf)__X, (__v4sf)__Y, __P); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmp_pd (__m256d __X, __m256d __Y, const int __P) >{ > return (__m256d) __builtin_ia32_cmppd256 ((__v4df)__X, (__v4df)__Y, > __P); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmp_ps (__m256 __X, __m256 __Y, const int __P) >{ > return (__m256) __builtin_ia32_cmpps256 ((__v8sf)__X, (__v8sf)__Y, > __P); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmp_sd (__m128d __X, __m128d __Y, const int __P) >{ > return (__m128d) __builtin_ia32_cmpsd ((__v2df)__X, (__v2df)__Y, __P); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmp_ss (__m128 __X, __m128 __Y, const int __P) >{ > return (__m128) __builtin_ia32_cmpss ((__v4sf)__X, (__v4sf)__Y, __P); >} ># 431 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepi32_pd (__m128i __A) >{ > return (__m256d)__builtin_ia32_cvtdq2pd256 ((__v4si) __A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepi32_ps (__m256i __A) >{ > return (__m256)__builtin_ia32_cvtdq2ps256 ((__v8si) __A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtpd_ps (__m256d __A) >{ > return (__m128)__builtin_ia32_cvtpd2ps256 ((__v4df) __A); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtps_epi32 (__m256 __A) >{ > return (__m256i)__builtin_ia32_cvtps2dq256 ((__v8sf) __A); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtps_pd (__m128 __A) >{ > return (__m256d)__builtin_ia32_cvtps2pd256 ((__v4sf) __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvttpd_epi32 (__m256d __A) >{ > return (__m128i)__builtin_ia32_cvttpd2dq256 ((__v4df) __A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtpd_epi32 (__m256d __A) >{ > return (__m128i)__builtin_ia32_cvtpd2dq256 ((__v4df) __A); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvttps_epi32 (__m256 __A) >{ > return (__m256i)__builtin_ia32_cvttps2dq256 ((__v8sf) __A); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_extractf128_pd (__m256d __X, const int __N) >{ > return (__m128d) __builtin_ia32_vextractf128_pd256 ((__v4df)__X, __N); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_extractf128_ps (__m256 __X, const int __N) >{ > return (__m128) __builtin_ia32_vextractf128_ps256 ((__v8sf)__X, __N); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_extractf128_si256 (__m256i __X, const int __N) >{ > return (__m128i) __builtin_ia32_vextractf128_si256 ((__v8si)__X, __N); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_extract_epi32 (__m256i __X, int const __N) >{ > __m128i __Y = _mm256_extractf128_si256 (__X, __N >> 2); > return _mm_extract_epi32 (__Y, __N % 4); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_extract_epi16 (__m256i __X, int const __N) >{ > __m128i __Y = _mm256_extractf128_si256 (__X, __N >> 3); > return _mm_extract_epi16 (__Y, __N % 8); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_extract_epi8 (__m256i __X, int const __N) >{ > __m128i __Y = _mm256_extractf128_si256 (__X, __N >> 4); > return _mm_extract_epi8 (__Y, __N % 16); >} > > >extern __inline long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_extract_epi64 (__m256i __X, const int __N) >{ > __m128i __Y = _mm256_extractf128_si256 (__X, __N >> 1); > return _mm_extract_epi64 (__Y, __N % 2); >} ># 571 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_zeroall (void) >{ > __builtin_ia32_vzeroall (); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_zeroupper (void) >{ > __builtin_ia32_vzeroupper (); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_permutevar_pd (__m128d __A, __m128i __C) >{ > return (__m128d) __builtin_ia32_vpermilvarpd ((__v2df)__A, > (__v2di)__C); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permutevar_pd (__m256d __A, __m256i __C) >{ > return (__m256d) __builtin_ia32_vpermilvarpd256 ((__v4df)__A, > (__v4di)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_permutevar_ps (__m128 __A, __m128i __C) >{ > return (__m128) __builtin_ia32_vpermilvarps ((__v4sf)__A, > (__v4si)__C); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permutevar_ps (__m256 __A, __m256i __C) >{ > return (__m256) __builtin_ia32_vpermilvarps256 ((__v8sf)__A, > (__v8si)__C); >} > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_permute_pd (__m128d __X, const int __C) >{ > return (__m128d) __builtin_ia32_vpermilpd ((__v2df)__X, __C); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute_pd (__m256d __X, const int __C) >{ > return (__m256d) __builtin_ia32_vpermilpd256 ((__v4df)__X, __C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_permute_ps (__m128 __X, const int __C) >{ > return (__m128) __builtin_ia32_vpermilps ((__v4sf)__X, __C); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute_ps (__m256 __X, const int __C) >{ > return (__m256) __builtin_ia32_vpermilps256 ((__v8sf)__X, __C); >} ># 650 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute2f128_pd (__m256d __X, __m256d __Y, const int __C) >{ > return (__m256d) __builtin_ia32_vperm2f128_pd256 ((__v4df)__X, > (__v4df)__Y, > __C); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute2f128_ps (__m256 __X, __m256 __Y, const int __C) >{ > return (__m256) __builtin_ia32_vperm2f128_ps256 ((__v8sf)__X, > (__v8sf)__Y, > __C); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute2f128_si256 (__m256i __X, __m256i __Y, const int __C) >{ > return (__m256i) __builtin_ia32_vperm2f128_si256 ((__v8si)__X, > (__v8si)__Y, > __C); >} ># 690 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_broadcast_ss (float const *__X) >{ > return (__m128) __builtin_ia32_vbroadcastss (__X); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcast_sd (double const *__X) >{ > return (__m256d) __builtin_ia32_vbroadcastsd256 (__X); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcast_ss (float const *__X) >{ > return (__m256) __builtin_ia32_vbroadcastss256 (__X); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcast_pd (__m128d const *__X) >{ > return (__m256d) __builtin_ia32_vbroadcastf128_pd256 (__X); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcast_ps (__m128 const *__X) >{ > return (__m256) __builtin_ia32_vbroadcastf128_ps256 (__X); >} > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_insertf128_pd (__m256d __X, __m128d __Y, const int __O) >{ > return (__m256d) __builtin_ia32_vinsertf128_pd256 ((__v4df)__X, > (__v2df)__Y, > __O); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_insertf128_ps (__m256 __X, __m128 __Y, const int __O) >{ > return (__m256) __builtin_ia32_vinsertf128_ps256 ((__v8sf)__X, > (__v4sf)__Y, > __O); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_insertf128_si256 (__m256i __X, __m128i __Y, const int __O) >{ > return (__m256i) __builtin_ia32_vinsertf128_si256 ((__v8si)__X, > (__v4si)__Y, > __O); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_insert_epi32 (__m256i __X, int __D, int const __N) >{ > __m128i __Y = _mm256_extractf128_si256 (__X, __N >> 2); > __Y = _mm_insert_epi32 (__Y, __D, __N % 4); > return _mm256_insertf128_si256 (__X, __Y, __N >> 2); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_insert_epi16 (__m256i __X, int __D, int const __N) >{ > __m128i __Y = _mm256_extractf128_si256 (__X, __N >> 3); > __Y = _mm_insert_epi16 (__Y, __D, __N % 8); > return _mm256_insertf128_si256 (__X, __Y, __N >> 3); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_insert_epi8 (__m256i __X, int __D, int const __N) >{ > __m128i __Y = _mm256_extractf128_si256 (__X, __N >> 4); > __Y = _mm_insert_epi8 (__Y, __D, __N % 16); > return _mm256_insertf128_si256 (__X, __Y, __N >> 4); >} > > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_insert_epi64 (__m256i __X, long long __D, int const __N) >{ > __m128i __Y = _mm256_extractf128_si256 (__X, __N >> 1); > __Y = _mm_insert_epi64 (__Y, __D, __N % 2); > return _mm256_insertf128_si256 (__X, __Y, __N >> 1); >} ># 829 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_load_pd (double const *__P) >{ > return *(__m256d *)__P; >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_store_pd (double *__P, __m256d __A) >{ > *(__m256d *)__P = __A; >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_load_ps (float const *__P) >{ > return *(__m256 *)__P; >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_store_ps (float *__P, __m256 __A) >{ > *(__m256 *)__P = __A; >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_loadu_pd (double const *__P) >{ > return (__m256d) __builtin_ia32_loadupd256 (__P); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_storeu_pd (double *__P, __m256d __A) >{ > __builtin_ia32_storeupd256 (__P, (__v4df)__A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_loadu_ps (float const *__P) >{ > return (__m256) __builtin_ia32_loadups256 (__P); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_storeu_ps (float *__P, __m256 __A) >{ > __builtin_ia32_storeups256 (__P, (__v8sf)__A); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_load_si256 (__m256i const *__P) >{ > return *__P; >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_store_si256 (__m256i *__P, __m256i __A) >{ > *__P = __A; >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_loadu_si256 (__m256i const *__P) >{ > return (__m256i) __builtin_ia32_loaddqu256 ((char const *)__P); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_storeu_si256 (__m256i *__P, __m256i __A) >{ > __builtin_ia32_storedqu256 ((char *)__P, (__v32qi)__A); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskload_pd (double const *__P, __m128i __M) >{ > return (__m128d) __builtin_ia32_maskloadpd ((const __v2df *)__P, > (__v2di)__M); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskstore_pd (double *__P, __m128i __M, __m128d __A) >{ > __builtin_ia32_maskstorepd ((__v2df *)__P, (__v2di)__M, (__v2df)__A); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maskload_pd (double const *__P, __m256i __M) >{ > return (__m256d) __builtin_ia32_maskloadpd256 ((const __v4df *)__P, > (__v4di)__M); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maskstore_pd (double *__P, __m256i __M, __m256d __A) >{ > __builtin_ia32_maskstorepd256 ((__v4df *)__P, (__v4di)__M, (__v4df)__A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskload_ps (float const *__P, __m128i __M) >{ > return (__m128) __builtin_ia32_maskloadps ((const __v4sf *)__P, > (__v4si)__M); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskstore_ps (float *__P, __m128i __M, __m128 __A) >{ > __builtin_ia32_maskstoreps ((__v4sf *)__P, (__v4si)__M, (__v4sf)__A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maskload_ps (float const *__P, __m256i __M) >{ > return (__m256) __builtin_ia32_maskloadps256 ((const __v8sf *)__P, > (__v8si)__M); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maskstore_ps (float *__P, __m256i __M, __m256 __A) >{ > __builtin_ia32_maskstoreps256 ((__v8sf *)__P, (__v8si)__M, (__v8sf)__A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_movehdup_ps (__m256 __X) >{ > return (__m256) __builtin_ia32_movshdup256 ((__v8sf)__X); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_moveldup_ps (__m256 __X) >{ > return (__m256) __builtin_ia32_movsldup256 ((__v8sf)__X); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_movedup_pd (__m256d __X) >{ > return (__m256d) __builtin_ia32_movddup256 ((__v4df)__X); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_lddqu_si256 (__m256i const *__P) >{ > return (__m256i) __builtin_ia32_lddqu256 ((char const *)__P); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_stream_si256 (__m256i *__A, __m256i __B) >{ > __builtin_ia32_movntdq256 ((__v4di *)__A, (__v4di)__B); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_stream_pd (double *__A, __m256d __B) >{ > __builtin_ia32_movntpd256 (__A, (__v4df)__B); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_stream_ps (float *__P, __m256 __A) >{ > __builtin_ia32_movntps256 (__P, (__v8sf)__A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_rcp_ps (__m256 __A) >{ > return (__m256) __builtin_ia32_rcpps256 ((__v8sf)__A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_rsqrt_ps (__m256 __A) >{ > return (__m256) __builtin_ia32_rsqrtps256 ((__v8sf)__A); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sqrt_pd (__m256d __A) >{ > return (__m256d) __builtin_ia32_sqrtpd256 ((__v4df)__A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sqrt_ps (__m256 __A) >{ > return (__m256) __builtin_ia32_sqrtps256 ((__v8sf)__A); >} > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_round_pd (__m256d __V, const int __M) >{ > return (__m256d) __builtin_ia32_roundpd256 ((__v4df)__V, __M); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_round_ps (__m256 __V, const int __M) >{ > return (__m256) __builtin_ia32_roundps256 ((__v8sf)__V, __M); >} ># 1044 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avxintrin.h" 3 4 >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpackhi_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_unpckhpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpacklo_pd (__m256d __A, __m256d __B) >{ > return (__m256d) __builtin_ia32_unpcklpd256 ((__v4df)__A, (__v4df)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpackhi_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_unpckhps256 ((__v8sf)__A, (__v8sf)__B); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpacklo_ps (__m256 __A, __m256 __B) >{ > return (__m256) __builtin_ia32_unpcklps256 ((__v8sf)__A, (__v8sf)__B); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_testz_pd (__m128d __M, __m128d __V) >{ > return __builtin_ia32_vtestzpd ((__v2df)__M, (__v2df)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_testc_pd (__m128d __M, __m128d __V) >{ > return __builtin_ia32_vtestcpd ((__v2df)__M, (__v2df)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_testnzc_pd (__m128d __M, __m128d __V) >{ > return __builtin_ia32_vtestnzcpd ((__v2df)__M, (__v2df)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_testz_ps (__m128 __M, __m128 __V) >{ > return __builtin_ia32_vtestzps ((__v4sf)__M, (__v4sf)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_testc_ps (__m128 __M, __m128 __V) >{ > return __builtin_ia32_vtestcps ((__v4sf)__M, (__v4sf)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_testnzc_ps (__m128 __M, __m128 __V) >{ > return __builtin_ia32_vtestnzcps ((__v4sf)__M, (__v4sf)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_testz_pd (__m256d __M, __m256d __V) >{ > return __builtin_ia32_vtestzpd256 ((__v4df)__M, (__v4df)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_testc_pd (__m256d __M, __m256d __V) >{ > return __builtin_ia32_vtestcpd256 ((__v4df)__M, (__v4df)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_testnzc_pd (__m256d __M, __m256d __V) >{ > return __builtin_ia32_vtestnzcpd256 ((__v4df)__M, (__v4df)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_testz_ps (__m256 __M, __m256 __V) >{ > return __builtin_ia32_vtestzps256 ((__v8sf)__M, (__v8sf)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_testc_ps (__m256 __M, __m256 __V) >{ > return __builtin_ia32_vtestcps256 ((__v8sf)__M, (__v8sf)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_testnzc_ps (__m256 __M, __m256 __V) >{ > return __builtin_ia32_vtestnzcps256 ((__v8sf)__M, (__v8sf)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_testz_si256 (__m256i __M, __m256i __V) >{ > return __builtin_ia32_ptestz256 ((__v4di)__M, (__v4di)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_testc_si256 (__m256i __M, __m256i __V) >{ > return __builtin_ia32_ptestc256 ((__v4di)__M, (__v4di)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_testnzc_si256 (__m256i __M, __m256i __V) >{ > return __builtin_ia32_ptestnzc256 ((__v4di)__M, (__v4di)__V); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_movemask_pd (__m256d __A) >{ > return __builtin_ia32_movmskpd256 ((__v4df)__A); >} > >extern __inline int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_movemask_ps (__m256 __A) >{ > return __builtin_ia32_movmskps256 ((__v8sf)__A); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_undefined_pd (void) >{ > __m256d __Y = __Y; > return __Y; >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_undefined_ps (void) >{ > __m256 __Y = __Y; > return __Y; >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_undefined_si256 (void) >{ > __m256i __Y = __Y; > return __Y; >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_setzero_pd (void) >{ > return __extension__ (__m256d){ 0.0, 0.0, 0.0, 0.0 }; >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_setzero_ps (void) >{ > return __extension__ (__m256){ 0.0, 0.0, 0.0, 0.0, > 0.0, 0.0, 0.0, 0.0 }; >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_setzero_si256 (void) >{ > return __extension__ (__m256i)(__v4di){ 0, 0, 0, 0 }; >} > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set_pd (double __A, double __B, double __C, double __D) >{ > return __extension__ (__m256d){ __D, __C, __B, __A }; >} > > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set_ps (float __A, float __B, float __C, float __D, > float __E, float __F, float __G, float __H) >{ > return __extension__ (__m256){ __H, __G, __F, __E, > __D, __C, __B, __A }; >} > > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set_epi32 (int __A, int __B, int __C, int __D, > int __E, int __F, int __G, int __H) >{ > return __extension__ (__m256i)(__v8si){ __H, __G, __F, __E, > __D, __C, __B, __A }; >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set_epi16 (short __q15, short __q14, short __q13, short __q12, > short __q11, short __q10, short __q09, short __q08, > short __q07, short __q06, short __q05, short __q04, > short __q03, short __q02, short __q01, short __q00) >{ > return __extension__ (__m256i)(__v16hi){ > __q00, __q01, __q02, __q03, __q04, __q05, __q06, __q07, > __q08, __q09, __q10, __q11, __q12, __q13, __q14, __q15 > }; >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set_epi8 (char __q31, char __q30, char __q29, char __q28, > char __q27, char __q26, char __q25, char __q24, > char __q23, char __q22, char __q21, char __q20, > char __q19, char __q18, char __q17, char __q16, > char __q15, char __q14, char __q13, char __q12, > char __q11, char __q10, char __q09, char __q08, > char __q07, char __q06, char __q05, char __q04, > char __q03, char __q02, char __q01, char __q00) >{ > return __extension__ (__m256i)(__v32qi){ > __q00, __q01, __q02, __q03, __q04, __q05, __q06, __q07, > __q08, __q09, __q10, __q11, __q12, __q13, __q14, __q15, > __q16, __q17, __q18, __q19, __q20, __q21, __q22, __q23, > __q24, __q25, __q26, __q27, __q28, __q29, __q30, __q31 > }; >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set_epi64x (long long __A, long long __B, long long __C, > long long __D) >{ > return __extension__ (__m256i)(__v4di){ __D, __C, __B, __A }; >} > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set1_pd (double __A) >{ > return __extension__ (__m256d){ __A, __A, __A, __A }; >} > > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set1_ps (float __A) >{ > return __extension__ (__m256){ __A, __A, __A, __A, > __A, __A, __A, __A }; >} > > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set1_epi32 (int __A) >{ > return __extension__ (__m256i)(__v8si){ __A, __A, __A, __A, > __A, __A, __A, __A }; >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set1_epi16 (short __A) >{ > return _mm256_set_epi16 (__A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set1_epi8 (char __A) >{ > return _mm256_set_epi8 (__A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_set1_epi64x (long long __A) >{ > return __extension__ (__m256i)(__v4di){ __A, __A, __A, __A }; >} > > > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_setr_pd (double __A, double __B, double __C, double __D) >{ > return _mm256_set_pd (__D, __C, __B, __A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_setr_ps (float __A, float __B, float __C, float __D, > float __E, float __F, float __G, float __H) >{ > return _mm256_set_ps (__H, __G, __F, __E, __D, __C, __B, __A); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_setr_epi32 (int __A, int __B, int __C, int __D, > int __E, int __F, int __G, int __H) >{ > return _mm256_set_epi32 (__H, __G, __F, __E, __D, __C, __B, __A); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_setr_epi16 (short __q15, short __q14, short __q13, short __q12, > short __q11, short __q10, short __q09, short __q08, > short __q07, short __q06, short __q05, short __q04, > short __q03, short __q02, short __q01, short __q00) >{ > return _mm256_set_epi16 (__q00, __q01, __q02, __q03, > __q04, __q05, __q06, __q07, > __q08, __q09, __q10, __q11, > __q12, __q13, __q14, __q15); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_setr_epi8 (char __q31, char __q30, char __q29, char __q28, > char __q27, char __q26, char __q25, char __q24, > char __q23, char __q22, char __q21, char __q20, > char __q19, char __q18, char __q17, char __q16, > char __q15, char __q14, char __q13, char __q12, > char __q11, char __q10, char __q09, char __q08, > char __q07, char __q06, char __q05, char __q04, > char __q03, char __q02, char __q01, char __q00) >{ > return _mm256_set_epi8 (__q00, __q01, __q02, __q03, > __q04, __q05, __q06, __q07, > __q08, __q09, __q10, __q11, > __q12, __q13, __q14, __q15, > __q16, __q17, __q18, __q19, > __q20, __q21, __q22, __q23, > __q24, __q25, __q26, __q27, > __q28, __q29, __q30, __q31); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_setr_epi64x (long long __A, long long __B, long long __C, > long long __D) >{ > return _mm256_set_epi64x (__D, __C, __B, __A); >} > > > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castpd_ps (__m256d __A) >{ > return (__m256) __A; >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castpd_si256 (__m256d __A) >{ > return (__m256i) __A; >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castps_pd (__m256 __A) >{ > return (__m256d) __A; >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castps_si256(__m256 __A) >{ > return (__m256i) __A; >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castsi256_ps (__m256i __A) >{ > return (__m256) __A; >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castsi256_pd (__m256i __A) >{ > return (__m256d) __A; >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castpd256_pd128 (__m256d __A) >{ > return (__m128d) __builtin_ia32_pd_pd256 ((__v4df)__A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castps256_ps128 (__m256 __A) >{ > return (__m128) __builtin_ia32_ps_ps256 ((__v8sf)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castsi256_si128 (__m256i __A) >{ > return (__m128i) __builtin_ia32_si_si256 ((__v8si)__A); >} > > > > > > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castpd128_pd256 (__m128d __A) >{ > return (__m256d) __builtin_ia32_pd256_pd ((__v2df)__A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castps128_ps256 (__m128 __A) >{ > return (__m256) __builtin_ia32_ps256_ps ((__v4sf)__A); >} > >extern __inline __m256i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_castsi128_si256 (__m128i __A) >{ > return (__m256i) __builtin_ia32_si256_si ((__v4si)__A); >} ># 42 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx2intrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx2intrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("avx2") > > > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mpsadbw_epu8 (__m256i __X, __m256i __Y, const int __M) >{ > return (__m256i) __builtin_ia32_mpsadbw256 ((__v32qi)__X, > (__v32qi)__Y, __M); >} > > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_abs_epi8 (__m256i __A) >{ > return (__m256i)__builtin_ia32_pabsb256 ((__v32qi)__A); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_abs_epi16 (__m256i __A) >{ > return (__m256i)__builtin_ia32_pabsw256 ((__v16hi)__A); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_abs_epi32 (__m256i __A) >{ > return (__m256i)__builtin_ia32_pabsd256 ((__v8si)__A); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_packs_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_packssdw256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_packs_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_packsswb256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_packus_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_packusdw256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_packus_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_packuswb256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_add_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_paddb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_add_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_paddw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_add_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_paddd256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_add_epi64 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_paddq256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_adds_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_paddsb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_adds_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_paddsw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_adds_epu8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_paddusb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_adds_epu16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_paddusw256 ((__v16hi)__A, (__v16hi)__B); >} > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_alignr_epi8 (__m256i __A, __m256i __B, const int __N) >{ > return (__m256i) __builtin_ia32_palignr256 ((__v4di)__A, > (__v4di)__B, > __N * 8); >} ># 177 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx2intrin.h" 3 4 >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_and_si256 (__m256i __A, __m256i __B) >{ > return (__m256i) __builtin_ia32_andsi256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_andnot_si256 (__m256i __A, __m256i __B) >{ > return (__m256i) __builtin_ia32_andnotsi256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_avg_epu8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pavgb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_avg_epu16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pavgw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_blendv_epi8 (__m256i __X, __m256i __Y, __m256i __M) >{ > return (__m256i) __builtin_ia32_pblendvb256 ((__v32qi)__X, > (__v32qi)__Y, > (__v32qi)__M); >} > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_blend_epi16 (__m256i __X, __m256i __Y, const int __M) >{ > return (__m256i) __builtin_ia32_pblendw256 ((__v16hi)__X, > (__v16hi)__Y, > __M); >} > > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmpeq_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pcmpeqb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmpeq_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pcmpeqw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmpeq_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pcmpeqd256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmpeq_epi64 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pcmpeqq256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmpgt_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pcmpgtb256 ((__v32qi)__A, > (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmpgt_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pcmpgtw256 ((__v16hi)__A, > (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmpgt_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pcmpgtd256 ((__v8si)__A, > (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cmpgt_epi64 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pcmpgtq256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hadd_epi16 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_phaddw256 ((__v16hi)__X, > (__v16hi)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hadd_epi32 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_phaddd256 ((__v8si)__X, (__v8si)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hadds_epi16 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_phaddsw256 ((__v16hi)__X, > (__v16hi)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hsub_epi16 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_phsubw256 ((__v16hi)__X, > (__v16hi)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hsub_epi32 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_phsubd256 ((__v8si)__X, (__v8si)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_hsubs_epi16 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_phsubsw256 ((__v16hi)__X, > (__v16hi)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maddubs_epi16 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_pmaddubsw256 ((__v32qi)__X, > (__v32qi)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_madd_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmaddwd256 ((__v16hi)__A, > (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_max_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmaxsb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_max_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmaxsw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_max_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmaxsd256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_max_epu8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmaxub256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_max_epu16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmaxuw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_max_epu32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmaxud256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_min_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pminsb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_min_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pminsw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_min_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pminsd256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_min_epu8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pminub256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_min_epu16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pminuw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_min_epu32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pminud256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_movemask_epi8 (__m256i __A) >{ > return __builtin_ia32_pmovmskb256 ((__v32qi)__A); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepi8_epi16 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovsxbw256 ((__v16qi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepi8_epi32 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovsxbd256 ((__v16qi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepi8_epi64 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovsxbq256 ((__v16qi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepi16_epi32 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovsxwd256 ((__v8hi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepi16_epi64 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovsxwq256 ((__v8hi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepi32_epi64 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovsxdq256 ((__v4si)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepu8_epi16 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovzxbw256 ((__v16qi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepu8_epi32 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovzxbd256 ((__v16qi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepu8_epi64 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovzxbq256 ((__v16qi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepu16_epi32 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovzxwd256 ((__v8hi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepu16_epi64 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovzxwq256 ((__v8hi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtepu32_epi64 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pmovzxdq256 ((__v4si)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mul_epi32 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_pmuldq256 ((__v8si)__X, (__v8si)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mulhrs_epi16 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_pmulhrsw256 ((__v16hi)__X, > (__v16hi)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mulhi_epu16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmulhuw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mulhi_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmulhw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mullo_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmullw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mullo_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmulld256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mul_epu32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pmuludq256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_or_si256 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_por256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sad_epu8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_psadbw256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_shuffle_epi8 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_pshufb256 ((__v32qi)__X, > (__v32qi)__Y); >} > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_shuffle_epi32 (__m256i __A, const int __mask) >{ > return (__m256i)__builtin_ia32_pshufd256 ((__v8si)__A, __mask); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_shufflehi_epi16 (__m256i __A, const int __mask) >{ > return (__m256i)__builtin_ia32_pshufhw256 ((__v16hi)__A, __mask); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_shufflelo_epi16 (__m256i __A, const int __mask) >{ > return (__m256i)__builtin_ia32_pshuflw256 ((__v16hi)__A, __mask); >} ># 627 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx2intrin.h" 3 4 >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sign_epi8 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_psignb256 ((__v32qi)__X, (__v32qi)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sign_epi16 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_psignw256 ((__v16hi)__X, (__v16hi)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sign_epi32 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_psignd256 ((__v8si)__X, (__v8si)__Y); >} > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_slli_si256 (__m256i __A, const int __N) >{ > return (__m256i)__builtin_ia32_pslldqi256 (__A, __N * 8); >} > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_slli_epi16 (__m256i __A, int __B) >{ > return (__m256i)__builtin_ia32_psllwi256 ((__v16hi)__A, __B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sll_epi16 (__m256i __A, __m128i __B) >{ > return (__m256i)__builtin_ia32_psllw256((__v16hi)__A, (__v8hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_slli_epi32 (__m256i __A, int __B) >{ > return (__m256i)__builtin_ia32_pslldi256 ((__v8si)__A, __B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sll_epi32 (__m256i __A, __m128i __B) >{ > return (__m256i)__builtin_ia32_pslld256((__v8si)__A, (__v4si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_slli_epi64 (__m256i __A, int __B) >{ > return (__m256i)__builtin_ia32_psllqi256 ((__v4di)__A, __B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sll_epi64 (__m256i __A, __m128i __B) >{ > return (__m256i)__builtin_ia32_psllq256((__v4di)__A, (__v2di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srai_epi16 (__m256i __A, int __B) >{ > return (__m256i)__builtin_ia32_psrawi256 ((__v16hi)__A, __B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sra_epi16 (__m256i __A, __m128i __B) >{ > return (__m256i)__builtin_ia32_psraw256 ((__v16hi)__A, (__v8hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srai_epi32 (__m256i __A, int __B) >{ > return (__m256i)__builtin_ia32_psradi256 ((__v8si)__A, __B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sra_epi32 (__m256i __A, __m128i __B) >{ > return (__m256i)__builtin_ia32_psrad256 ((__v8si)__A, (__v4si)__B); >} > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srli_si256 (__m256i __A, const int __N) >{ > return (__m256i)__builtin_ia32_psrldqi256 (__A, __N * 8); >} > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srli_epi16 (__m256i __A, int __B) >{ > return (__m256i)__builtin_ia32_psrlwi256 ((__v16hi)__A, __B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srl_epi16 (__m256i __A, __m128i __B) >{ > return (__m256i)__builtin_ia32_psrlw256((__v16hi)__A, (__v8hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srli_epi32 (__m256i __A, int __B) >{ > return (__m256i)__builtin_ia32_psrldi256 ((__v8si)__A, __B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srl_epi32 (__m256i __A, __m128i __B) >{ > return (__m256i)__builtin_ia32_psrld256((__v8si)__A, (__v4si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srli_epi64 (__m256i __A, int __B) >{ > return (__m256i)__builtin_ia32_psrlqi256 ((__v4di)__A, __B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srl_epi64 (__m256i __A, __m128i __B) >{ > return (__m256i)__builtin_ia32_psrlq256((__v4di)__A, (__v2di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sub_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_psubb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sub_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_psubw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sub_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_psubd256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sub_epi64 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_psubq256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_subs_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_psubsb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_subs_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_psubsw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_subs_epu8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_psubusb256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_subs_epu16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_psubusw256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpackhi_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_punpckhbw256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpackhi_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_punpckhwd256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpackhi_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_punpckhdq256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpackhi_epi64 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_punpckhqdq256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpacklo_epi8 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_punpcklbw256 ((__v32qi)__A, (__v32qi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpacklo_epi16 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_punpcklwd256 ((__v16hi)__A, (__v16hi)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpacklo_epi32 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_punpckldq256 ((__v8si)__A, (__v8si)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_unpacklo_epi64 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_punpcklqdq256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_xor_si256 (__m256i __A, __m256i __B) >{ > return (__m256i)__builtin_ia32_pxor256 ((__v4di)__A, (__v4di)__B); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_stream_load_si256 (__m256i const *__X) >{ > return (__m256i) __builtin_ia32_movntdqa256 ((__v4di *) __X); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_broadcastss_ps (__m128 __X) >{ > return (__m128) __builtin_ia32_vbroadcastss_ps ((__v4sf)__X); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcastss_ps (__m128 __X) >{ > return (__m256) __builtin_ia32_vbroadcastss_ps256 ((__v4sf)__X); >} > >extern __inline __m256d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcastsd_pd (__m128d __X) >{ > return (__m256d) __builtin_ia32_vbroadcastsd_pd256 ((__v2df)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcastsi128_si256 (__m128i __X) >{ > return (__m256i) __builtin_ia32_vbroadcastsi256 ((__v2di)__X); >} > > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_blend_epi32 (__m128i __X, __m128i __Y, const int __M) >{ > return (__m128i) __builtin_ia32_pblendd128 ((__v4si)__X, > (__v4si)__Y, > __M); >} > > > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_blend_epi32 (__m256i __X, __m256i __Y, const int __M) >{ > return (__m256i) __builtin_ia32_pblendd256 ((__v8si)__X, > (__v8si)__Y, > __M); >} > > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcastb_epi8 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pbroadcastb256 ((__v16qi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcastw_epi16 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pbroadcastw256 ((__v8hi)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcastd_epi32 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pbroadcastd256 ((__v4si)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_broadcastq_epi64 (__m128i __X) >{ > return (__m256i) __builtin_ia32_pbroadcastq256 ((__v2di)__X); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_broadcastb_epi8 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pbroadcastb128 ((__v16qi)__X); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_broadcastw_epi16 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pbroadcastw128 ((__v8hi)__X); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_broadcastd_epi32 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pbroadcastd128 ((__v4si)__X); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_broadcastq_epi64 (__m128i __X) >{ > return (__m128i) __builtin_ia32_pbroadcastq128 ((__v2di)__X); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permutevar8x32_epi32 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_permvarsi256 ((__v8si)__X, (__v8si)__Y); >} > > >extern __inline __m256d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute4x64_pd (__m256d __X, const int __M) >{ > return (__m256d) __builtin_ia32_permdf256 ((__v4df)__X, __M); >} > > > > > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permutevar8x32_ps (__m256 __X, __m256i __Y) >{ > return (__m256) __builtin_ia32_permvarsf256 ((__v8sf)__X, (__v8si)__Y); >} > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute4x64_epi64 (__m256i __X, const int __M) >{ > return (__m256i) __builtin_ia32_permdi256 ((__v4di)__X, __M); >} > > > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute2x128_si256 (__m256i __X, __m256i __Y, const int __M) >{ > return (__m256i) __builtin_ia32_permti256 ((__v4di)__X, (__v4di)__Y, __M); >} > > > > > > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_extracti128_si256 (__m256i __X, const int __M) >{ > return (__m128i) __builtin_ia32_extract128i256 ((__v4di)__X, __M); >} > > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_inserti128_si256 (__m256i __X, __m128i __Y, const int __M) >{ > return (__m256i) __builtin_ia32_insert128i256 ((__v4di)__X, (__v2di)__Y, __M); >} > > > > > > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maskload_epi32 (int const *__X, __m256i __M ) >{ > return (__m256i) __builtin_ia32_maskloadd256 ((const __v8si *)__X, > (__v8si)__M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maskload_epi64 (long long const *__X, __m256i __M ) >{ > return (__m256i) __builtin_ia32_maskloadq256 ((const __v4di *)__X, > (__v4di)__M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskload_epi32 (int const *__X, __m128i __M ) >{ > return (__m128i) __builtin_ia32_maskloadd ((const __v4si *)__X, > (__v4si)__M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskload_epi64 (long long const *__X, __m128i __M ) >{ > return (__m128i) __builtin_ia32_maskloadq ((const __v2di *)__X, > (__v2di)__M); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maskstore_epi32 (int *__X, __m256i __M, __m256i __Y ) >{ > __builtin_ia32_maskstored256 ((__v8si *)__X, (__v8si)__M, (__v8si)__Y); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maskstore_epi64 (long long *__X, __m256i __M, __m256i __Y ) >{ > __builtin_ia32_maskstoreq256 ((__v4di *)__X, (__v4di)__M, (__v4di)__Y); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskstore_epi32 (int *__X, __m128i __M, __m128i __Y ) >{ > __builtin_ia32_maskstored ((__v4si *)__X, (__v4si)__M, (__v4si)__Y); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskstore_epi64 (long long *__X, __m128i __M, __m128i __Y ) >{ > __builtin_ia32_maskstoreq (( __v2di *)__X, (__v2di)__M, (__v2di)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sllv_epi32 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_psllv8si ((__v8si)__X, (__v8si)__Y); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sllv_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_psllv4si ((__v4si)__X, (__v4si)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_sllv_epi64 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_psllv4di ((__v4di)__X, (__v4di)__Y); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sllv_epi64 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_psllv2di ((__v2di)__X, (__v2di)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srav_epi32 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_psrav8si ((__v8si)__X, (__v8si)__Y); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srav_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_psrav4si ((__v4si)__X, (__v4si)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srlv_epi32 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_psrlv8si ((__v8si)__X, (__v8si)__Y); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srlv_epi32 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_psrlv4si ((__v4si)__X, (__v4si)__Y); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_srlv_epi64 (__m256i __X, __m256i __Y) >{ > return (__m256i) __builtin_ia32_psrlv4di ((__v4di)__X, (__v4di)__Y); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_srlv_epi64 (__m128i __X, __m128i __Y) >{ > return (__m128i) __builtin_ia32_psrlv2di ((__v2di)__X, (__v2di)__Y); >} > > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_i32gather_pd (double const *base, __m128i index, const int scale) >{ > __v2df zero = _mm_setzero_pd (); > __v2df mask = _mm_cmpeq_pd (zero, zero); > > return (__m128d) __builtin_ia32_gathersiv2df (_mm_undefined_pd (), > base, > (__v4si)index, > mask, > scale); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_i32gather_pd (__m128d src, double const *base, __m128i index, > __m128d mask, const int scale) >{ > return (__m128d) __builtin_ia32_gathersiv2df ((__v2df)src, > base, > (__v4si)index, > (__v2df)mask, > scale); >} > >extern __inline __m256d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_i32gather_pd (double const *base, __m128i index, const int scale) >{ > __v4df zero = _mm256_setzero_pd (); > __v4df mask = _mm256_cmp_pd (zero, zero, 0x00); > > return (__m256d) __builtin_ia32_gathersiv4df (_mm256_undefined_pd (), > base, > (__v4si)index, > mask, > scale); >} > >extern __inline __m256d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mask_i32gather_pd (__m256d src, double const *base, > __m128i index, __m256d mask, const int scale) >{ > return (__m256d) __builtin_ia32_gathersiv4df ((__v4df)src, > base, > (__v4si)index, > (__v4df)mask, > scale); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_i64gather_pd (double const *base, __m128i index, const int scale) >{ > __v2df src = _mm_setzero_pd (); > __v2df mask = _mm_cmpeq_pd (src, src); > > return (__m128d) __builtin_ia32_gatherdiv2df (src, > base, > (__v2di)index, > mask, > scale); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_i64gather_pd (__m128d src, double const *base, __m128i index, > __m128d mask, const int scale) >{ > return (__m128d) __builtin_ia32_gatherdiv2df ((__v2df)src, > base, > (__v2di)index, > (__v2df)mask, > scale); >} > >extern __inline __m256d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_i64gather_pd (double const *base, __m256i index, const int scale) >{ > __v4df src = _mm256_setzero_pd (); > __v4df mask = _mm256_cmp_pd (src, src, 0x00); > > return (__m256d) __builtin_ia32_gatherdiv4df (src, > base, > (__v4di)index, > mask, > scale); >} > >extern __inline __m256d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mask_i64gather_pd (__m256d src, double const *base, > __m256i index, __m256d mask, const int scale) >{ > return (__m256d) __builtin_ia32_gatherdiv4df ((__v4df)src, > base, > (__v4di)index, > (__v4df)mask, > scale); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_i32gather_ps (float const *base, __m128i index, const int scale) >{ > __v4sf src = _mm_setzero_ps (); > __v4sf mask = _mm_cmpeq_ps (src, src); > > return (__m128) __builtin_ia32_gathersiv4sf (src, > base, > (__v4si)index, > mask, > scale); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_i32gather_ps (__m128 src, float const *base, __m128i index, > __m128 mask, const int scale) >{ > return (__m128) __builtin_ia32_gathersiv4sf ((__v4sf)src, > base, > (__v4si)index, > (__v4sf)mask, > scale); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_i32gather_ps (float const *base, __m256i index, const int scale) >{ > __v8sf src = _mm256_setzero_ps (); > __v8sf mask = _mm256_cmp_ps (src, src, 0x00); > > return (__m256) __builtin_ia32_gathersiv8sf (src, > base, > (__v8si)index, > mask, > scale); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mask_i32gather_ps (__m256 src, float const *base, > __m256i index, __m256 mask, const int scale) >{ > return (__m256) __builtin_ia32_gathersiv8sf ((__v8sf)src, > base, > (__v8si)index, > (__v8sf)mask, > scale); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_i64gather_ps (float const *base, __m128i index, const int scale) >{ > __v4sf src = _mm_setzero_ps (); > __v4sf mask = _mm_cmpeq_ps (src, src); > > return (__m128) __builtin_ia32_gatherdiv4sf (src, > base, > (__v2di)index, > mask, > scale); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_i64gather_ps (__m128 src, float const *base, __m128i index, > __m128 mask, const int scale) >{ > return (__m128) __builtin_ia32_gatherdiv4sf ((__v4sf)src, > base, > (__v2di)index, > (__v4sf)mask, > scale); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_i64gather_ps (float const *base, __m256i index, const int scale) >{ > __v4sf src = _mm_setzero_ps (); > __v4sf mask = _mm_cmpeq_ps (src, src); > > return (__m128) __builtin_ia32_gatherdiv4sf256 (src, > base, > (__v4di)index, > mask, > scale); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mask_i64gather_ps (__m128 src, float const *base, > __m256i index, __m128 mask, const int scale) >{ > return (__m128) __builtin_ia32_gatherdiv4sf256 ((__v4sf)src, > base, > (__v4di)index, > (__v4sf)mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_i32gather_epi64 (long long int const *base, > __m128i index, const int scale) >{ > __v2di src = __extension__ (__v2di){ 0, 0 }; > __v2di mask = __extension__ (__v2di){ ~0, ~0 }; > > return (__m128i) __builtin_ia32_gathersiv2di (src, > base, > (__v4si)index, > mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_i32gather_epi64 (__m128i src, long long int const *base, > __m128i index, __m128i mask, const int scale) >{ > return (__m128i) __builtin_ia32_gathersiv2di ((__v2di)src, > base, > (__v4si)index, > (__v2di)mask, > scale); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_i32gather_epi64 (long long int const *base, > __m128i index, const int scale) >{ > __v4di src = __extension__ (__v4di){ 0, 0, 0, 0 }; > __v4di mask = __extension__ (__v4di){ ~0, ~0, ~0, ~0 }; > > return (__m256i) __builtin_ia32_gathersiv4di (src, > base, > (__v4si)index, > mask, > scale); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mask_i32gather_epi64 (__m256i src, long long int const *base, > __m128i index, __m256i mask, const int scale) >{ > return (__m256i) __builtin_ia32_gathersiv4di ((__v4di)src, > base, > (__v4si)index, > (__v4di)mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_i64gather_epi64 (long long int const *base, > __m128i index, const int scale) >{ > __v2di src = __extension__ (__v2di){ 0, 0 }; > __v2di mask = __extension__ (__v2di){ ~0, ~0 }; > > return (__m128i) __builtin_ia32_gatherdiv2di (src, > base, > (__v2di)index, > mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_i64gather_epi64 (__m128i src, long long int const *base, __m128i index, > __m128i mask, const int scale) >{ > return (__m128i) __builtin_ia32_gatherdiv2di ((__v2di)src, > base, > (__v2di)index, > (__v2di)mask, > scale); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_i64gather_epi64 (long long int const *base, > __m256i index, const int scale) >{ > __v4di src = __extension__ (__v4di){ 0, 0, 0, 0 }; > __v4di mask = __extension__ (__v4di){ ~0, ~0, ~0, ~0 }; > > return (__m256i) __builtin_ia32_gatherdiv4di (src, > base, > (__v4di)index, > mask, > scale); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mask_i64gather_epi64 (__m256i src, long long int const *base, > __m256i index, __m256i mask, const int scale) >{ > return (__m256i) __builtin_ia32_gatherdiv4di ((__v4di)src, > base, > (__v4di)index, > (__v4di)mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_i32gather_epi32 (int const *base, __m128i index, const int scale) >{ > __v4si src = __extension__ (__v4si){ 0, 0, 0, 0 }; > __v4si mask = __extension__ (__v4si){ ~0, ~0, ~0, ~0 }; > > return (__m128i) __builtin_ia32_gathersiv4si (src, > base, > (__v4si)index, > mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_i32gather_epi32 (__m128i src, int const *base, __m128i index, > __m128i mask, const int scale) >{ > return (__m128i) __builtin_ia32_gathersiv4si ((__v4si)src, > base, > (__v4si)index, > (__v4si)mask, > scale); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_i32gather_epi32 (int const *base, __m256i index, const int scale) >{ > __v8si src = __extension__ (__v8si){ 0, 0, 0, 0, 0, 0, 0, 0 }; > __v8si mask = __extension__ (__v8si){ ~0, ~0, ~0, ~0, ~0, ~0, ~0, ~0 }; > > return (__m256i) __builtin_ia32_gathersiv8si (src, > base, > (__v8si)index, > mask, > scale); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mask_i32gather_epi32 (__m256i src, int const *base, > __m256i index, __m256i mask, const int scale) >{ > return (__m256i) __builtin_ia32_gathersiv8si ((__v8si)src, > base, > (__v8si)index, > (__v8si)mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_i64gather_epi32 (int const *base, __m128i index, const int scale) >{ > __v4si src = __extension__ (__v4si){ 0, 0, 0, 0 }; > __v4si mask = __extension__ (__v4si){ ~0, ~0, ~0, ~0 }; > > return (__m128i) __builtin_ia32_gatherdiv4si (src, > base, > (__v2di)index, > mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_i64gather_epi32 (__m128i src, int const *base, __m128i index, > __m128i mask, const int scale) >{ > return (__m128i) __builtin_ia32_gatherdiv4si ((__v4si)src, > base, > (__v2di)index, > (__v4si)mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_i64gather_epi32 (int const *base, __m256i index, const int scale) >{ > __v4si src = __extension__ (__v4si){ 0, 0, 0, 0 }; > __v4si mask = __extension__ (__v4si){ ~0, ~0, ~0, ~0 }; > > return (__m128i) __builtin_ia32_gatherdiv4si256 (src, > base, > (__v4di)index, > mask, > scale); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_mask_i64gather_epi32 (__m128i src, int const *base, > __m256i index, __m128i mask, const int scale) >{ > return (__m128i) __builtin_ia32_gatherdiv4si256 ((__v4si)src, > base, > (__v4di)index, > (__v4si)mask, > scale); >} ># 1886 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx2intrin.h" 3 4 >#pragma GCC pop_options ># 44 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("avx512f") > > > > >typedef double __v8df __attribute__ ((__vector_size__ (64))); >typedef float __v16sf __attribute__ ((__vector_size__ (64))); >typedef long long __v8di __attribute__ ((__vector_size__ (64))); >typedef int __v16si __attribute__ ((__vector_size__ (64))); >typedef short __v32hi __attribute__ ((__vector_size__ (64))); >typedef char __v64qi __attribute__ ((__vector_size__ (64))); > > > >typedef float __m512 __attribute__ ((__vector_size__ (64), __may_alias__)); >typedef long long __m512i __attribute__ ((__vector_size__ (64), __may_alias__)); >typedef double __m512d __attribute__ ((__vector_size__ (64), __may_alias__)); > >typedef unsigned char __mmask8; >typedef unsigned short __mmask16; > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set_epi64 (long long __A, long long __B, long long __C, > long long __D, long long __E, long long __F, > long long __G, long long __H) >{ > return __extension__ (__m512i) (__v8di) > { __H, __G, __F, __E, __D, __C, __B, __A }; >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set_epi32 (int __A, int __B, int __C, int __D, > int __E, int __F, int __G, int __H, > int __I, int __J, int __K, int __L, > int __M, int __N, int __O, int __P) >{ > return __extension__ (__m512i)(__v16si) > { __P, __O, __N, __M, __L, __K, __J, __I, > __H, __G, __F, __E, __D, __C, __B, __A }; >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set_pd (double __A, double __B, double __C, double __D, > double __E, double __F, double __G, double __H) >{ > return __extension__ (__m512d) > { __H, __G, __F, __E, __D, __C, __B, __A }; >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set_ps (float __A, float __B, float __C, float __D, > float __E, float __F, float __G, float __H, > float __I, float __J, float __K, float __L, > float __M, float __N, float __O, float __P) >{ > return __extension__ (__m512) > { __P, __O, __N, __M, __L, __K, __J, __I, > __H, __G, __F, __E, __D, __C, __B, __A }; >} ># 111 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_undefined_ps (void) >{ > __m512 __Y = __Y; > return __Y; >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_undefined_pd (void) >{ > __m512d __Y = __Y; > return __Y; >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_undefined_si512 (void) >{ > __m512i __Y = __Y; > return __Y; >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set1_epi8 (char __A) >{ > return __extension__ (__m512i)(__v64qi) > { __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A }; >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set1_epi16 (short __A) >{ > return __extension__ (__m512i)(__v32hi) > { __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A, > __A, __A, __A, __A, __A, __A, __A, __A }; >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set1_pd (double __A) >{ > return (__m512d) __builtin_ia32_broadcastsd512 (__extension__ > (__v2df) { __A, }, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set1_ps (float __A) >{ > return (__m512) __builtin_ia32_broadcastss512 (__extension__ > (__v4sf) { __A, }, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set4_epi32 (int __A, int __B, int __C, int __D) >{ > return __extension__ (__m512i)(__v16si) > { __D, __C, __B, __A, __D, __C, __B, __A, > __D, __C, __B, __A, __D, __C, __B, __A }; >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set4_epi64 (long long __A, long long __B, long long __C, > long long __D) >{ > return __extension__ (__m512i) (__v8di) > { __D, __C, __B, __A, __D, __C, __B, __A }; >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set4_pd (double __A, double __B, double __C, double __D) >{ > return __extension__ (__m512d) > { __D, __C, __B, __A, __D, __C, __B, __A }; >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set4_ps (float __A, float __B, float __C, float __D) >{ > return __extension__ (__m512) > { __D, __C, __B, __A, __D, __C, __B, __A, > __D, __C, __B, __A, __D, __C, __B, __A }; >} ># 231 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_setzero_ps (void) >{ > return __extension__ (__m512){ 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 }; >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_setzero_pd (void) >{ > return __extension__ (__m512d) { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 }; >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_setzero_epi32 (void) >{ > return __extension__ (__m512i)(__v8di){ 0, 0, 0, 0, 0, 0, 0, 0 }; >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_setzero_si512 (void) >{ > return __extension__ (__m512i)(__v8di){ 0, 0, 0, 0, 0, 0, 0, 0 }; >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mov_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_movapd512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mov_pd (__mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_movapd512_mask ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mov_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_movaps512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mov_ps (__mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_movaps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_load_pd (void const *__P) >{ > return *(__m512d *) __P; >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_load_pd (__m512d __W, __mmask8 __U, void const *__P) >{ > return (__m512d) __builtin_ia32_loadapd512_mask ((const __v8df *) __P, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_load_pd (__mmask8 __U, void const *__P) >{ > return (__m512d) __builtin_ia32_loadapd512_mask ((const __v8df *) __P, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_store_pd (void *__P, __m512d __A) >{ > *(__m512d *) __P = __A; >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_store_pd (void *__P, __mmask8 __U, __m512d __A) >{ > __builtin_ia32_storeapd512_mask ((__v8df *) __P, (__v8df) __A, > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_load_ps (void const *__P) >{ > return *(__m512 *) __P; >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_load_ps (__m512 __W, __mmask16 __U, void const *__P) >{ > return (__m512) __builtin_ia32_loadaps512_mask ((const __v16sf *) __P, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_load_ps (__mmask16 __U, void const *__P) >{ > return (__m512) __builtin_ia32_loadaps512_mask ((const __v16sf *) __P, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_store_ps (void *__P, __m512 __A) >{ > *(__m512 *) __P = __A; >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_store_ps (void *__P, __mmask16 __U, __m512 __A) >{ > __builtin_ia32_storeaps512_mask ((__v16sf *) __P, (__v16sf) __A, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mov_epi64 (__m512i __W, __mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_movdqa64_512_mask ((__v8di) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mov_epi64 (__mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_movdqa64_512_mask ((__v8di) __A, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_load_epi64 (void const *__P) >{ > return *(__m512i *) __P; >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_load_epi64 (__m512i __W, __mmask8 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_movdqa64load512_mask ((const __v8di *) __P, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_load_epi64 (__mmask8 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_movdqa64load512_mask ((const __v8di *) __P, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_store_epi64 (void *__P, __m512i __A) >{ > *(__m512i *) __P = __A; >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_store_epi64 (void *__P, __mmask8 __U, __m512i __A) >{ > __builtin_ia32_movdqa64store512_mask ((__v8di *) __P, (__v8di) __A, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mov_epi32 (__m512i __W, __mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_movdqa32_512_mask ((__v16si) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mov_epi32 (__mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_movdqa32_512_mask ((__v16si) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_load_si512 (void const *__P) >{ > return *(__m512i *) __P; >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_load_epi32 (void const *__P) >{ > return *(__m512i *) __P; >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_load_epi32 (__m512i __W, __mmask16 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_movdqa32load512_mask ((const __v16si *) __P, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_load_epi32 (__mmask16 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_movdqa32load512_mask ((const __v16si *) __P, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_store_si512 (void *__P, __m512i __A) >{ > *(__m512i *) __P = __A; >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_store_epi32 (void *__P, __m512i __A) >{ > *(__m512i *) __P = __A; >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_store_epi32 (void *__P, __mmask16 __U, __m512i __A) >{ > __builtin_ia32_movdqa32store512_mask ((__v16si *) __P, (__v16si) __A, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mullo_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmulld512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mullo_epi32 (__mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmulld512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mullo_epi32 (__m512i __W, __mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmulld512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sllv_epi32 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psllv16si_mask ((__v16si) __X, > (__v16si) __Y, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sllv_epi32 (__m512i __W, __mmask16 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psllv16si_mask ((__v16si) __X, > (__v16si) __Y, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sllv_epi32 (__mmask16 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psllv16si_mask ((__v16si) __X, > (__v16si) __Y, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srav_epi32 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrav16si_mask ((__v16si) __X, > (__v16si) __Y, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srav_epi32 (__m512i __W, __mmask16 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrav16si_mask ((__v16si) __X, > (__v16si) __Y, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srav_epi32 (__mmask16 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrav16si_mask ((__v16si) __X, > (__v16si) __Y, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srlv_epi32 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrlv16si_mask ((__v16si) __X, > (__v16si) __Y, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srlv_epi32 (__m512i __W, __mmask16 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrlv16si_mask ((__v16si) __X, > (__v16si) __Y, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srlv_epi32 (__mmask16 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrlv16si_mask ((__v16si) __X, > (__v16si) __Y, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_add_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_paddq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_add_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_paddq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_add_epi64 (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_paddq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sub_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_psubq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sub_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_psubq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sub_epi64 (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_psubq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sllv_epi64 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psllv8di_mask ((__v8di) __X, > (__v8di) __Y, > (__v8di) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sllv_epi64 (__m512i __W, __mmask8 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psllv8di_mask ((__v8di) __X, > (__v8di) __Y, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sllv_epi64 (__mmask8 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psllv8di_mask ((__v8di) __X, > (__v8di) __Y, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srav_epi64 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrav8di_mask ((__v8di) __X, > (__v8di) __Y, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srav_epi64 (__m512i __W, __mmask8 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrav8di_mask ((__v8di) __X, > (__v8di) __Y, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srav_epi64 (__mmask8 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrav8di_mask ((__v8di) __X, > (__v8di) __Y, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srlv_epi64 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrlv8di_mask ((__v8di) __X, > (__v8di) __Y, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srlv_epi64 (__m512i __W, __mmask8 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrlv8di_mask ((__v8di) __X, > (__v8di) __Y, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srlv_epi64 (__mmask8 __U, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_psrlv8di_mask ((__v8di) __X, > (__v8di) __Y, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_add_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_paddd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_add_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_paddd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_add_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_paddd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mul_epi32 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_pmuldq512_mask ((__v16si) __X, > (__v16si) __Y, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mul_epi32 (__m512i __W, __mmask8 __M, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_pmuldq512_mask ((__v16si) __X, > (__v16si) __Y, > (__v8di) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mul_epi32 (__mmask8 __M, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_pmuldq512_mask ((__v16si) __X, > (__v16si) __Y, > (__v8di) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sub_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_psubd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sub_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_psubd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sub_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_psubd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mul_epu32 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_pmuludq512_mask ((__v16si) __X, > (__v16si) __Y, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mul_epu32 (__m512i __W, __mmask8 __M, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_pmuludq512_mask ((__v16si) __X, > (__v16si) __Y, > (__v8di) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mul_epu32 (__mmask8 __M, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_pmuludq512_mask ((__v16si) __X, > (__v16si) __Y, > (__v8di) > _mm512_setzero_si512 (), > __M); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_slli_epi64 (__m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psllqi512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_slli_epi64 (__m512i __W, __mmask8 __U, __m512i __A, > unsigned int __B) >{ > return (__m512i) __builtin_ia32_psllqi512_mask ((__v8di) __A, __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_slli_epi64 (__mmask8 __U, __m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psllqi512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} ># 974 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sll_epi64 (__m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psllq512_mask ((__v8di) __A, > (__v2di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sll_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psllq512_mask ((__v8di) __A, > (__v2di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sll_epi64 (__mmask8 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psllq512_mask ((__v8di) __A, > (__v2di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srli_epi64 (__m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psrlqi512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srli_epi64 (__m512i __W, __mmask8 __U, > __m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psrlqi512_mask ((__v8di) __A, __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srli_epi64 (__mmask8 __U, __m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psrlqi512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} ># 1053 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srl_epi64 (__m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psrlq512_mask ((__v8di) __A, > (__v2di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srl_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psrlq512_mask ((__v8di) __A, > (__v2di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srl_epi64 (__mmask8 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psrlq512_mask ((__v8di) __A, > (__v2di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srai_epi64 (__m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psraqi512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srai_epi64 (__m512i __W, __mmask8 __U, __m512i __A, > unsigned int __B) >{ > return (__m512i) __builtin_ia32_psraqi512_mask ((__v8di) __A, __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srai_epi64 (__mmask8 __U, __m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psraqi512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} ># 1132 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sra_epi64 (__m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psraq512_mask ((__v8di) __A, > (__v2di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sra_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psraq512_mask ((__v8di) __A, > (__v2di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sra_epi64 (__mmask8 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psraq512_mask ((__v8di) __A, > (__v2di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_slli_epi32 (__m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_pslldi512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_slli_epi32 (__m512i __W, __mmask16 __U, __m512i __A, > unsigned int __B) >{ > return (__m512i) __builtin_ia32_pslldi512_mask ((__v16si) __A, __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_slli_epi32 (__mmask16 __U, __m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_pslldi512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} ># 1211 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sll_epi32 (__m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_pslld512_mask ((__v16si) __A, > (__v4si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sll_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_pslld512_mask ((__v16si) __A, > (__v4si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sll_epi32 (__mmask16 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_pslld512_mask ((__v16si) __A, > (__v4si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srli_epi32 (__m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psrldi512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srli_epi32 (__m512i __W, __mmask16 __U, > __m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psrldi512_mask ((__v16si) __A, __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srli_epi32 (__mmask16 __U, __m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psrldi512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} ># 1290 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srl_epi32 (__m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psrld512_mask ((__v16si) __A, > (__v4si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srl_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psrld512_mask ((__v16si) __A, > (__v4si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srl_epi32 (__mmask16 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psrld512_mask ((__v16si) __A, > (__v4si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_srai_epi32 (__m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psradi512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_srai_epi32 (__m512i __W, __mmask16 __U, __m512i __A, > unsigned int __B) >{ > return (__m512i) __builtin_ia32_psradi512_mask ((__v16si) __A, __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_srai_epi32 (__mmask16 __U, __m512i __A, unsigned int __B) >{ > return (__m512i) __builtin_ia32_psradi512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} ># 1369 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sra_epi32 (__m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psrad512_mask ((__v16si) __A, > (__v4si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sra_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psrad512_mask ((__v16si) __A, > (__v4si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sra_epi32 (__mmask16 __U, __m512i __A, __m128i __B) >{ > return (__m512i) __builtin_ia32_psrad512_mask ((__v16si) __A, > (__v4si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_round_sd (__m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_addsd_round ((__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_add_round_ss (__m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_addss_round ((__v4sf) __A, > (__v4sf) __B, > __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_round_sd (__m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_subsd_round ((__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sub_round_ss (__m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_subss_round ((__v4sf) __A, > (__v4sf) __B, > __R); >} ># 1453 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_ternarylogic_epi64 (__m512i __A, __m512i __B, __m512i __C, const int imm) >{ > return (__m512i) __builtin_ia32_pternlogq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __C, imm, > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_ternarylogic_epi64 (__m512i __A, __mmask8 __U, __m512i __B, > __m512i __C, const int imm) >{ > return (__m512i) __builtin_ia32_pternlogq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __C, imm, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_ternarylogic_epi64 (__mmask8 __U, __m512i __A, __m512i __B, > __m512i __C, const int imm) >{ > return (__m512i) __builtin_ia32_pternlogq512_maskz ((__v8di) __A, > (__v8di) __B, > (__v8di) __C, > imm, (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_ternarylogic_epi32 (__m512i __A, __m512i __B, __m512i __C, const int imm) >{ > return (__m512i) __builtin_ia32_pternlogd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __C, > imm, (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_ternarylogic_epi32 (__m512i __A, __mmask16 __U, __m512i __B, > __m512i __C, const int imm) >{ > return (__m512i) __builtin_ia32_pternlogd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __C, > imm, (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_ternarylogic_epi32 (__mmask16 __U, __m512i __A, __m512i __B, > __m512i __C, const int imm) >{ > return (__m512i) __builtin_ia32_pternlogd512_maskz ((__v16si) __A, > (__v16si) __B, > (__v16si) __C, > imm, (__mmask16) __U); >} ># 1540 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rcp14_pd (__m512d __A) >{ > return (__m512d) __builtin_ia32_rcp14pd512_mask ((__v8df) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rcp14_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_rcp14pd512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rcp14_pd (__mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_rcp14pd512_mask ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rcp14_ps (__m512 __A) >{ > return (__m512) __builtin_ia32_rcp14ps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rcp14_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_rcp14ps512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rcp14_ps (__mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_rcp14ps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rcp14_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_rcp14sd ((__v2df) __B, > (__v2df) __A); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rcp14_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_rcp14ss ((__v4sf) __B, > (__v4sf) __A); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rsqrt14_pd (__m512d __A) >{ > return (__m512d) __builtin_ia32_rsqrt14pd512_mask ((__v8df) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rsqrt14_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_rsqrt14pd512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rsqrt14_pd (__mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_rsqrt14pd512_mask ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rsqrt14_ps (__m512 __A) >{ > return (__m512) __builtin_ia32_rsqrt14ps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rsqrt14_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_rsqrt14ps512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rsqrt14_ps (__mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_rsqrt14ps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rsqrt14_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_rsqrt14sd ((__v2df) __B, > (__v2df) __A); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rsqrt14_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_rsqrt14ss ((__v4sf) __B, > (__v4sf) __A); >} > > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sqrt_round_pd (__m512d __A, const int __R) >{ > return (__m512d) __builtin_ia32_sqrtpd512_mask ((__v8df) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sqrt_round_pd (__m512d __W, __mmask8 __U, __m512d __A, > const int __R) >{ > return (__m512d) __builtin_ia32_sqrtpd512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sqrt_round_pd (__mmask8 __U, __m512d __A, const int __R) >{ > return (__m512d) __builtin_ia32_sqrtpd512_mask ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sqrt_round_ps (__m512 __A, const int __R) >{ > return (__m512) __builtin_ia32_sqrtps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sqrt_round_ps (__m512 __W, __mmask16 __U, __m512 __A, const int __R) >{ > return (__m512) __builtin_ia32_sqrtps512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sqrt_round_ps (__mmask16 __U, __m512 __A, const int __R) >{ > return (__m512) __builtin_ia32_sqrtps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sqrt_round_sd (__m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_sqrtsd_round ((__v2df) __B, > (__v2df) __A, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sqrt_round_ss (__m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_sqrtss_round ((__v4sf) __B, > (__v4sf) __A, > __R); >} ># 1791 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi8_epi32 (__m128i __A) >{ > return (__m512i) __builtin_ia32_pmovsxbd512_mask ((__v16qi) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi8_epi32 (__m512i __W, __mmask16 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovsxbd512_mask ((__v16qi) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi8_epi32 (__mmask16 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovsxbd512_mask ((__v16qi) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi8_epi64 (__m128i __A) >{ > return (__m512i) __builtin_ia32_pmovsxbq512_mask ((__v16qi) __A, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi8_epi64 (__m512i __W, __mmask8 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovsxbq512_mask ((__v16qi) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi8_epi64 (__mmask8 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovsxbq512_mask ((__v16qi) __A, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi16_epi32 (__m256i __A) >{ > return (__m512i) __builtin_ia32_pmovsxwd512_mask ((__v16hi) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi16_epi32 (__m512i __W, __mmask16 __U, __m256i __A) >{ > return (__m512i) __builtin_ia32_pmovsxwd512_mask ((__v16hi) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi16_epi32 (__mmask16 __U, __m256i __A) >{ > return (__m512i) __builtin_ia32_pmovsxwd512_mask ((__v16hi) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi16_epi64 (__m128i __A) >{ > return (__m512i) __builtin_ia32_pmovsxwq512_mask ((__v8hi) __A, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi16_epi64 (__m512i __W, __mmask8 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovsxwq512_mask ((__v8hi) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi16_epi64 (__mmask8 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovsxwq512_mask ((__v8hi) __A, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi32_epi64 (__m256i __X) >{ > return (__m512i) __builtin_ia32_pmovsxdq512_mask ((__v8si) __X, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi32_epi64 (__m512i __W, __mmask8 __U, __m256i __X) >{ > return (__m512i) __builtin_ia32_pmovsxdq512_mask ((__v8si) __X, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi32_epi64 (__mmask8 __U, __m256i __X) >{ > return (__m512i) __builtin_ia32_pmovsxdq512_mask ((__v8si) __X, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepu8_epi32 (__m128i __A) >{ > return (__m512i) __builtin_ia32_pmovzxbd512_mask ((__v16qi) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepu8_epi32 (__m512i __W, __mmask16 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovzxbd512_mask ((__v16qi) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepu8_epi32 (__mmask16 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovzxbd512_mask ((__v16qi) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepu8_epi64 (__m128i __A) >{ > return (__m512i) __builtin_ia32_pmovzxbq512_mask ((__v16qi) __A, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepu8_epi64 (__m512i __W, __mmask8 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovzxbq512_mask ((__v16qi) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepu8_epi64 (__mmask8 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovzxbq512_mask ((__v16qi) __A, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepu16_epi32 (__m256i __A) >{ > return (__m512i) __builtin_ia32_pmovzxwd512_mask ((__v16hi) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepu16_epi32 (__m512i __W, __mmask16 __U, __m256i __A) >{ > return (__m512i) __builtin_ia32_pmovzxwd512_mask ((__v16hi) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepu16_epi32 (__mmask16 __U, __m256i __A) >{ > return (__m512i) __builtin_ia32_pmovzxwd512_mask ((__v16hi) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepu16_epi64 (__m128i __A) >{ > return (__m512i) __builtin_ia32_pmovzxwq512_mask ((__v8hi) __A, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepu16_epi64 (__m512i __W, __mmask8 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovzxwq512_mask ((__v8hi) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepu16_epi64 (__mmask8 __U, __m128i __A) >{ > return (__m512i) __builtin_ia32_pmovzxwq512_mask ((__v8hi) __A, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepu32_epi64 (__m256i __X) >{ > return (__m512i) __builtin_ia32_pmovzxdq512_mask ((__v8si) __X, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepu32_epi64 (__m512i __W, __mmask8 __U, __m256i __X) >{ > return (__m512i) __builtin_ia32_pmovzxdq512_mask ((__v8si) __X, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepu32_epi64 (__mmask8 __U, __m256i __X) >{ > return (__m512i) __builtin_ia32_pmovzxdq512_mask ((__v8si) __X, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_add_round_pd (__m512d __A, __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_addpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_add_round_pd (__m512d __W, __mmask8 __U, __m512d __A, > __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_addpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_add_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > const int __R) >{ > return (__m512d) __builtin_ia32_addpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_add_round_ps (__m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_addps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_add_round_ps (__m512 __W, __mmask16 __U, __m512 __A, > __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_addps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_add_round_ps (__mmask16 __U, __m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_addps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sub_round_pd (__m512d __A, __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_subpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sub_round_pd (__m512d __W, __mmask8 __U, __m512d __A, > __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_subpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sub_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > const int __R) >{ > return (__m512d) __builtin_ia32_subpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sub_round_ps (__m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_subps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sub_round_ps (__m512 __W, __mmask16 __U, __m512 __A, > __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_subps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sub_round_ps (__mmask16 __U, __m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_subps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} ># 2254 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mul_round_pd (__m512d __A, __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_mulpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mul_round_pd (__m512d __W, __mmask8 __U, __m512d __A, > __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_mulpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mul_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > const int __R) >{ > return (__m512d) __builtin_ia32_mulpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mul_round_ps (__m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_mulps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mul_round_ps (__m512 __W, __mmask16 __U, __m512 __A, > __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_mulps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mul_round_ps (__mmask16 __U, __m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_mulps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_div_round_pd (__m512d __M, __m512d __V, const int __R) >{ > return (__m512d) __builtin_ia32_divpd512_mask ((__v8df) __M, > (__v8df) __V, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_div_round_pd (__m512d __W, __mmask8 __U, __m512d __M, > __m512d __V, const int __R) >{ > return (__m512d) __builtin_ia32_divpd512_mask ((__v8df) __M, > (__v8df) __V, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_div_round_pd (__mmask8 __U, __m512d __M, __m512d __V, > const int __R) >{ > return (__m512d) __builtin_ia32_divpd512_mask ((__v8df) __M, > (__v8df) __V, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_div_round_ps (__m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_divps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_div_round_ps (__m512 __W, __mmask16 __U, __m512 __A, > __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_divps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_div_round_ps (__mmask16 __U, __m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_divps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mul_round_sd (__m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_mulsd_round ((__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mul_round_ss (__m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_mulss_round ((__v4sf) __A, > (__v4sf) __B, > __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_div_round_sd (__m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_divsd_round ((__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_div_round_ss (__m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_divss_round ((__v4sf) __A, > (__v4sf) __B, > __R); >} ># 2475 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_max_round_pd (__m512d __A, __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_maxpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_max_round_pd (__m512d __W, __mmask8 __U, __m512d __A, > __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_maxpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_max_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > const int __R) >{ > return (__m512d) __builtin_ia32_maxpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_max_round_ps (__m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_maxps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_max_round_ps (__m512 __W, __mmask16 __U, __m512 __A, > __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_maxps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_max_round_ps (__mmask16 __U, __m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_maxps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_min_round_pd (__m512d __A, __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_minpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_min_round_pd (__m512d __W, __mmask8 __U, __m512d __A, > __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_minpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_min_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > const int __R) >{ > return (__m512d) __builtin_ia32_minpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_min_round_ps (__m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_minps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_min_round_ps (__m512 __W, __mmask16 __U, __m512 __A, > __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_minps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_min_round_ps (__mmask16 __U, __m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_minps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} ># 2647 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_scalef_round_pd (__m512d __A, __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_scalefpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_scalef_round_pd (__m512d __W, __mmask8 __U, __m512d __A, > __m512d __B, const int __R) >{ > return (__m512d) __builtin_ia32_scalefpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_scalef_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > const int __R) >{ > return (__m512d) __builtin_ia32_scalefpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_scalef_round_ps (__m512 __A, __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_scalefps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_scalef_round_ps (__m512 __W, __mmask16 __U, __m512 __A, > __m512 __B, const int __R) >{ > return (__m512) __builtin_ia32_scalefps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_scalef_round_ps (__mmask16 __U, __m512 __A, __m512 __B, > const int __R) >{ > return (__m512) __builtin_ia32_scalefps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_scalef_round_sd (__m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_scalefsd_round ((__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_scalef_round_ss (__m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_scalefss_round ((__v4sf) __A, > (__v4sf) __B, > __R); >} ># 2759 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmadd_round_pd (__m512d __A, __m512d __B, __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmadd_round_pd (__m512d __A, __mmask8 __U, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmadd_round_pd (__m512d __A, __m512d __B, __m512d __C, > __mmask8 __U, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmadd_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_maskz ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmadd_round_ps (__m512 __A, __m512 __B, __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmadd_round_ps (__m512 __A, __mmask16 __U, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmadd_round_ps (__m512 __A, __m512 __B, __m512 __C, > __mmask16 __U, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmadd_round_ps (__mmask16 __U, __m512 __A, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_maskz ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmsub_round_pd (__m512d __A, __m512d __B, __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmsub_round_pd (__m512d __A, __mmask8 __U, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmsub_round_pd (__m512d __A, __m512d __B, __m512d __C, > __mmask8 __U, const int __R) >{ > return (__m512d) __builtin_ia32_vfmsubpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmsub_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_maskz ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmsub_round_ps (__m512 __A, __m512 __B, __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmsub_round_ps (__m512 __A, __mmask16 __U, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmsub_round_ps (__m512 __A, __m512 __B, __m512 __C, > __mmask16 __U, const int __R) >{ > return (__m512) __builtin_ia32_vfmsubps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmsub_round_ps (__mmask16 __U, __m512 __A, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_maskz ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmaddsub_round_pd (__m512d __A, __m512d __B, __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmaddsub_round_pd (__m512d __A, __mmask8 __U, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmaddsub_round_pd (__m512d __A, __m512d __B, __m512d __C, > __mmask8 __U, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmaddsub_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_maskz ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmaddsub_round_ps (__m512 __A, __m512 __B, __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmaddsub_round_ps (__m512 __A, __mmask16 __U, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmaddsub_round_ps (__m512 __A, __m512 __B, __m512 __C, > __mmask16 __U, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmaddsub_round_ps (__mmask16 __U, __m512 __A, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_maskz ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmsubadd_round_pd (__m512d __A, __m512d __B, __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmsubadd_round_pd (__m512d __A, __mmask8 __U, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmsubadd_round_pd (__m512d __A, __m512d __B, __m512d __C, > __mmask8 __U, const int __R) >{ > return (__m512d) __builtin_ia32_vfmsubaddpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmsubadd_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_maskz ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmsubadd_round_ps (__m512 __A, __m512 __B, __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmsubadd_round_ps (__m512 __A, __mmask16 __U, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmsubadd_round_ps (__m512 __A, __m512 __B, __m512 __C, > __mmask16 __U, const int __R) >{ > return (__m512) __builtin_ia32_vfmsubaddps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmsubadd_round_ps (__mmask16 __U, __m512 __A, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_maskz ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fnmadd_round_pd (__m512d __A, __m512d __B, __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask (-(__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fnmadd_round_pd (__m512d __A, __mmask8 __U, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfnmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fnmadd_round_pd (__m512d __A, __m512d __B, __m512d __C, > __mmask8 __U, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask3 (-(__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fnmadd_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_maskz (-(__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fnmadd_round_ps (__m512 __A, __m512 __B, __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask (-(__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fnmadd_round_ps (__m512 __A, __mmask16 __U, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfnmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fnmadd_round_ps (__m512 __A, __m512 __B, __m512 __C, > __mmask16 __U, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask3 (-(__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fnmadd_round_ps (__mmask16 __U, __m512 __A, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_maskz (-(__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fnmsub_round_pd (__m512d __A, __m512d __B, __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask (-(__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fnmsub_round_pd (__m512d __A, __mmask8 __U, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfnmsubpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fnmsub_round_pd (__m512d __A, __m512d __B, __m512d __C, > __mmask8 __U, const int __R) >{ > return (__m512d) __builtin_ia32_vfnmsubpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fnmsub_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > __m512d __C, const int __R) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_maskz (-(__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fnmsub_round_ps (__m512 __A, __m512 __B, __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask (-(__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fnmsub_round_ps (__m512 __A, __mmask16 __U, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfnmsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fnmsub_round_ps (__m512 __A, __m512 __B, __m512 __C, > __mmask16 __U, const int __R) >{ > return (__m512) __builtin_ia32_vfnmsubps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fnmsub_round_ps (__mmask16 __U, __m512 __A, __m512 __B, > __m512 __C, const int __R) >{ > return (__m512) __builtin_ia32_vfmaddps512_maskz (-(__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, __R); >} ># 3420 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_abs_epi64 (__m512i __A) >{ > return (__m512i) __builtin_ia32_pabsq512_mask ((__v8di) __A, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_abs_epi64 (__m512i __W, __mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_pabsq512_mask ((__v8di) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_abs_epi64 (__mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_pabsq512_mask ((__v8di) __A, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_abs_epi32 (__m512i __A) >{ > return (__m512i) __builtin_ia32_pabsd512_mask ((__v16si) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_abs_epi32 (__m512i __W, __mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_pabsd512_mask ((__v16si) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_abs_epi32 (__mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_pabsd512_mask ((__v16si) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcastss_ps (__m128 __A) >{ > return (__m512) __builtin_ia32_broadcastss512 ((__v4sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_broadcastss_ps (__m512 __O, __mmask16 __M, __m128 __A) >{ > return (__m512) __builtin_ia32_broadcastss512 ((__v4sf) __A, > (__v16sf) __O, __M); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_broadcastss_ps (__mmask16 __M, __m128 __A) >{ > return (__m512) __builtin_ia32_broadcastss512 ((__v4sf) __A, > (__v16sf) > _mm512_setzero_ps (), > __M); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcastsd_pd (__m128d __A) >{ > return (__m512d) __builtin_ia32_broadcastsd512 ((__v2df) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_broadcastsd_pd (__m512d __O, __mmask8 __M, __m128d __A) >{ > return (__m512d) __builtin_ia32_broadcastsd512 ((__v2df) __A, > (__v8df) __O, __M); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_broadcastsd_pd (__mmask8 __M, __m128d __A) >{ > return (__m512d) __builtin_ia32_broadcastsd512 ((__v2df) __A, > (__v8df) > _mm512_setzero_pd (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcastd_epi32 (__m128i __A) >{ > return (__m512i) __builtin_ia32_pbroadcastd512 ((__v4si) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_broadcastd_epi32 (__m512i __O, __mmask16 __M, __m128i __A) >{ > return (__m512i) __builtin_ia32_pbroadcastd512 ((__v4si) __A, > (__v16si) __O, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_broadcastd_epi32 (__mmask16 __M, __m128i __A) >{ > return (__m512i) __builtin_ia32_pbroadcastd512 ((__v4si) __A, > (__v16si) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set1_epi32 (int __A) >{ > return (__m512i) __builtin_ia32_pbroadcastd512_gpr_mask (__A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16)(-1)); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_set1_epi32 (__m512i __O, __mmask16 __M, int __A) >{ > return (__m512i) __builtin_ia32_pbroadcastd512_gpr_mask (__A, (__v16si) __O, > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_set1_epi32 (__mmask16 __M, int __A) >{ > return (__m512i) > __builtin_ia32_pbroadcastd512_gpr_mask (__A, > (__v16si) _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcastq_epi64 (__m128i __A) >{ > return (__m512i) __builtin_ia32_pbroadcastq512 ((__v2di) __A, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_broadcastq_epi64 (__m512i __O, __mmask8 __M, __m128i __A) >{ > return (__m512i) __builtin_ia32_pbroadcastq512 ((__v2di) __A, > (__v8di) __O, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_broadcastq_epi64 (__mmask8 __M, __m128i __A) >{ > return (__m512i) __builtin_ia32_pbroadcastq512 ((__v2di) __A, > (__v8di) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_set1_epi64 (long long __A) >{ > > > > > > > return (__m512i) __builtin_ia32_pbroadcastq512_mem_mask (__A, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8)(-1)); > >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_set1_epi64 (__m512i __O, __mmask8 __M, long long __A) >{ > > > > > return (__m512i) __builtin_ia32_pbroadcastq512_mem_mask (__A, (__v8di) __O, > __M); > >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_set1_epi64 (__mmask8 __M, long long __A) >{ > > > > > > > return (__m512i) > __builtin_ia32_pbroadcastq512_mem_mask (__A, > (__v8di) _mm512_setzero_si512 (), > __M); > >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcast_f32x4 (__m128 __A) >{ > return (__m512) __builtin_ia32_broadcastf32x4_512 ((__v4sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_broadcast_f32x4 (__m512 __O, __mmask16 __M, __m128 __A) >{ > return (__m512) __builtin_ia32_broadcastf32x4_512 ((__v4sf) __A, > (__v16sf) __O, > __M); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_broadcast_f32x4 (__mmask16 __M, __m128 __A) >{ > return (__m512) __builtin_ia32_broadcastf32x4_512 ((__v4sf) __A, > (__v16sf) > _mm512_setzero_ps (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcast_i32x4 (__m128i __A) >{ > return (__m512i) __builtin_ia32_broadcasti32x4_512 ((__v4si) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_broadcast_i32x4 (__m512i __O, __mmask16 __M, __m128i __A) >{ > return (__m512i) __builtin_ia32_broadcasti32x4_512 ((__v4si) __A, > (__v16si) __O, > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_broadcast_i32x4 (__mmask16 __M, __m128i __A) >{ > return (__m512i) __builtin_ia32_broadcasti32x4_512 ((__v4si) __A, > (__v16si) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcast_f64x4 (__m256d __A) >{ > return (__m512d) __builtin_ia32_broadcastf64x4_512 ((__v4df) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_broadcast_f64x4 (__m512d __O, __mmask8 __M, __m256d __A) >{ > return (__m512d) __builtin_ia32_broadcastf64x4_512 ((__v4df) __A, > (__v8df) __O, > __M); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_broadcast_f64x4 (__mmask8 __M, __m256d __A) >{ > return (__m512d) __builtin_ia32_broadcastf64x4_512 ((__v4df) __A, > (__v8df) > _mm512_setzero_pd (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcast_i64x4 (__m256i __A) >{ > return (__m512i) __builtin_ia32_broadcasti64x4_512 ((__v4di) __A, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_broadcast_i64x4 (__m512i __O, __mmask8 __M, __m256i __A) >{ > return (__m512i) __builtin_ia32_broadcasti64x4_512 ((__v4di) __A, > (__v8di) __O, > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_broadcast_i64x4 (__mmask8 __M, __m256i __A) >{ > return (__m512i) __builtin_ia32_broadcasti64x4_512 ((__v4di) __A, > (__v8di) > _mm512_setzero_si512 (), > __M); >} > >typedef enum >{ > _MM_PERM_AAAA = 0x00, _MM_PERM_AAAB = 0x01, _MM_PERM_AAAC = 0x02, > _MM_PERM_AAAD = 0x03, _MM_PERM_AABA = 0x04, _MM_PERM_AABB = 0x05, > _MM_PERM_AABC = 0x06, _MM_PERM_AABD = 0x07, _MM_PERM_AACA = 0x08, > _MM_PERM_AACB = 0x09, _MM_PERM_AACC = 0x0A, _MM_PERM_AACD = 0x0B, > _MM_PERM_AADA = 0x0C, _MM_PERM_AADB = 0x0D, _MM_PERM_AADC = 0x0E, > _MM_PERM_AADD = 0x0F, _MM_PERM_ABAA = 0x10, _MM_PERM_ABAB = 0x11, > _MM_PERM_ABAC = 0x12, _MM_PERM_ABAD = 0x13, _MM_PERM_ABBA = 0x14, > _MM_PERM_ABBB = 0x15, _MM_PERM_ABBC = 0x16, _MM_PERM_ABBD = 0x17, > _MM_PERM_ABCA = 0x18, _MM_PERM_ABCB = 0x19, _MM_PERM_ABCC = 0x1A, > _MM_PERM_ABCD = 0x1B, _MM_PERM_ABDA = 0x1C, _MM_PERM_ABDB = 0x1D, > _MM_PERM_ABDC = 0x1E, _MM_PERM_ABDD = 0x1F, _MM_PERM_ACAA = 0x20, > _MM_PERM_ACAB = 0x21, _MM_PERM_ACAC = 0x22, _MM_PERM_ACAD = 0x23, > _MM_PERM_ACBA = 0x24, _MM_PERM_ACBB = 0x25, _MM_PERM_ACBC = 0x26, > _MM_PERM_ACBD = 0x27, _MM_PERM_ACCA = 0x28, _MM_PERM_ACCB = 0x29, > _MM_PERM_ACCC = 0x2A, _MM_PERM_ACCD = 0x2B, _MM_PERM_ACDA = 0x2C, > _MM_PERM_ACDB = 0x2D, _MM_PERM_ACDC = 0x2E, _MM_PERM_ACDD = 0x2F, > _MM_PERM_ADAA = 0x30, _MM_PERM_ADAB = 0x31, _MM_PERM_ADAC = 0x32, > _MM_PERM_ADAD = 0x33, _MM_PERM_ADBA = 0x34, _MM_PERM_ADBB = 0x35, > _MM_PERM_ADBC = 0x36, _MM_PERM_ADBD = 0x37, _MM_PERM_ADCA = 0x38, > _MM_PERM_ADCB = 0x39, _MM_PERM_ADCC = 0x3A, _MM_PERM_ADCD = 0x3B, > _MM_PERM_ADDA = 0x3C, _MM_PERM_ADDB = 0x3D, _MM_PERM_ADDC = 0x3E, > _MM_PERM_ADDD = 0x3F, _MM_PERM_BAAA = 0x40, _MM_PERM_BAAB = 0x41, > _MM_PERM_BAAC = 0x42, _MM_PERM_BAAD = 0x43, _MM_PERM_BABA = 0x44, > _MM_PERM_BABB = 0x45, _MM_PERM_BABC = 0x46, _MM_PERM_BABD = 0x47, > _MM_PERM_BACA = 0x48, _MM_PERM_BACB = 0x49, _MM_PERM_BACC = 0x4A, > _MM_PERM_BACD = 0x4B, _MM_PERM_BADA = 0x4C, _MM_PERM_BADB = 0x4D, > _MM_PERM_BADC = 0x4E, _MM_PERM_BADD = 0x4F, _MM_PERM_BBAA = 0x50, > _MM_PERM_BBAB = 0x51, _MM_PERM_BBAC = 0x52, _MM_PERM_BBAD = 0x53, > _MM_PERM_BBBA = 0x54, _MM_PERM_BBBB = 0x55, _MM_PERM_BBBC = 0x56, > _MM_PERM_BBBD = 0x57, _MM_PERM_BBCA = 0x58, _MM_PERM_BBCB = 0x59, > _MM_PERM_BBCC = 0x5A, _MM_PERM_BBCD = 0x5B, _MM_PERM_BBDA = 0x5C, > _MM_PERM_BBDB = 0x5D, _MM_PERM_BBDC = 0x5E, _MM_PERM_BBDD = 0x5F, > _MM_PERM_BCAA = 0x60, _MM_PERM_BCAB = 0x61, _MM_PERM_BCAC = 0x62, > _MM_PERM_BCAD = 0x63, _MM_PERM_BCBA = 0x64, _MM_PERM_BCBB = 0x65, > _MM_PERM_BCBC = 0x66, _MM_PERM_BCBD = 0x67, _MM_PERM_BCCA = 0x68, > _MM_PERM_BCCB = 0x69, _MM_PERM_BCCC = 0x6A, _MM_PERM_BCCD = 0x6B, > _MM_PERM_BCDA = 0x6C, _MM_PERM_BCDB = 0x6D, _MM_PERM_BCDC = 0x6E, > _MM_PERM_BCDD = 0x6F, _MM_PERM_BDAA = 0x70, _MM_PERM_BDAB = 0x71, > _MM_PERM_BDAC = 0x72, _MM_PERM_BDAD = 0x73, _MM_PERM_BDBA = 0x74, > _MM_PERM_BDBB = 0x75, _MM_PERM_BDBC = 0x76, _MM_PERM_BDBD = 0x77, > _MM_PERM_BDCA = 0x78, _MM_PERM_BDCB = 0x79, _MM_PERM_BDCC = 0x7A, > _MM_PERM_BDCD = 0x7B, _MM_PERM_BDDA = 0x7C, _MM_PERM_BDDB = 0x7D, > _MM_PERM_BDDC = 0x7E, _MM_PERM_BDDD = 0x7F, _MM_PERM_CAAA = 0x80, > _MM_PERM_CAAB = 0x81, _MM_PERM_CAAC = 0x82, _MM_PERM_CAAD = 0x83, > _MM_PERM_CABA = 0x84, _MM_PERM_CABB = 0x85, _MM_PERM_CABC = 0x86, > _MM_PERM_CABD = 0x87, _MM_PERM_CACA = 0x88, _MM_PERM_CACB = 0x89, > _MM_PERM_CACC = 0x8A, _MM_PERM_CACD = 0x8B, _MM_PERM_CADA = 0x8C, > _MM_PERM_CADB = 0x8D, _MM_PERM_CADC = 0x8E, _MM_PERM_CADD = 0x8F, > _MM_PERM_CBAA = 0x90, _MM_PERM_CBAB = 0x91, _MM_PERM_CBAC = 0x92, > _MM_PERM_CBAD = 0x93, _MM_PERM_CBBA = 0x94, _MM_PERM_CBBB = 0x95, > _MM_PERM_CBBC = 0x96, _MM_PERM_CBBD = 0x97, _MM_PERM_CBCA = 0x98, > _MM_PERM_CBCB = 0x99, _MM_PERM_CBCC = 0x9A, _MM_PERM_CBCD = 0x9B, > _MM_PERM_CBDA = 0x9C, _MM_PERM_CBDB = 0x9D, _MM_PERM_CBDC = 0x9E, > _MM_PERM_CBDD = 0x9F, _MM_PERM_CCAA = 0xA0, _MM_PERM_CCAB = 0xA1, > _MM_PERM_CCAC = 0xA2, _MM_PERM_CCAD = 0xA3, _MM_PERM_CCBA = 0xA4, > _MM_PERM_CCBB = 0xA5, _MM_PERM_CCBC = 0xA6, _MM_PERM_CCBD = 0xA7, > _MM_PERM_CCCA = 0xA8, _MM_PERM_CCCB = 0xA9, _MM_PERM_CCCC = 0xAA, > _MM_PERM_CCCD = 0xAB, _MM_PERM_CCDA = 0xAC, _MM_PERM_CCDB = 0xAD, > _MM_PERM_CCDC = 0xAE, _MM_PERM_CCDD = 0xAF, _MM_PERM_CDAA = 0xB0, > _MM_PERM_CDAB = 0xB1, _MM_PERM_CDAC = 0xB2, _MM_PERM_CDAD = 0xB3, > _MM_PERM_CDBA = 0xB4, _MM_PERM_CDBB = 0xB5, _MM_PERM_CDBC = 0xB6, > _MM_PERM_CDBD = 0xB7, _MM_PERM_CDCA = 0xB8, _MM_PERM_CDCB = 0xB9, > _MM_PERM_CDCC = 0xBA, _MM_PERM_CDCD = 0xBB, _MM_PERM_CDDA = 0xBC, > _MM_PERM_CDDB = 0xBD, _MM_PERM_CDDC = 0xBE, _MM_PERM_CDDD = 0xBF, > _MM_PERM_DAAA = 0xC0, _MM_PERM_DAAB = 0xC1, _MM_PERM_DAAC = 0xC2, > _MM_PERM_DAAD = 0xC3, _MM_PERM_DABA = 0xC4, _MM_PERM_DABB = 0xC5, > _MM_PERM_DABC = 0xC6, _MM_PERM_DABD = 0xC7, _MM_PERM_DACA = 0xC8, > _MM_PERM_DACB = 0xC9, _MM_PERM_DACC = 0xCA, _MM_PERM_DACD = 0xCB, > _MM_PERM_DADA = 0xCC, _MM_PERM_DADB = 0xCD, _MM_PERM_DADC = 0xCE, > _MM_PERM_DADD = 0xCF, _MM_PERM_DBAA = 0xD0, _MM_PERM_DBAB = 0xD1, > _MM_PERM_DBAC = 0xD2, _MM_PERM_DBAD = 0xD3, _MM_PERM_DBBA = 0xD4, > _MM_PERM_DBBB = 0xD5, _MM_PERM_DBBC = 0xD6, _MM_PERM_DBBD = 0xD7, > _MM_PERM_DBCA = 0xD8, _MM_PERM_DBCB = 0xD9, _MM_PERM_DBCC = 0xDA, > _MM_PERM_DBCD = 0xDB, _MM_PERM_DBDA = 0xDC, _MM_PERM_DBDB = 0xDD, > _MM_PERM_DBDC = 0xDE, _MM_PERM_DBDD = 0xDF, _MM_PERM_DCAA = 0xE0, > _MM_PERM_DCAB = 0xE1, _MM_PERM_DCAC = 0xE2, _MM_PERM_DCAD = 0xE3, > _MM_PERM_DCBA = 0xE4, _MM_PERM_DCBB = 0xE5, _MM_PERM_DCBC = 0xE6, > _MM_PERM_DCBD = 0xE7, _MM_PERM_DCCA = 0xE8, _MM_PERM_DCCB = 0xE9, > _MM_PERM_DCCC = 0xEA, _MM_PERM_DCCD = 0xEB, _MM_PERM_DCDA = 0xEC, > _MM_PERM_DCDB = 0xED, _MM_PERM_DCDC = 0xEE, _MM_PERM_DCDD = 0xEF, > _MM_PERM_DDAA = 0xF0, _MM_PERM_DDAB = 0xF1, _MM_PERM_DDAC = 0xF2, > _MM_PERM_DDAD = 0xF3, _MM_PERM_DDBA = 0xF4, _MM_PERM_DDBB = 0xF5, > _MM_PERM_DDBC = 0xF6, _MM_PERM_DDBD = 0xF7, _MM_PERM_DDCA = 0xF8, > _MM_PERM_DDCB = 0xF9, _MM_PERM_DDCC = 0xFA, _MM_PERM_DDCD = 0xFB, > _MM_PERM_DDDA = 0xFC, _MM_PERM_DDDB = 0xFD, _MM_PERM_DDDC = 0xFE, > _MM_PERM_DDDD = 0xFF >} _MM_PERM_ENUM; > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_shuffle_epi32 (__m512i __A, _MM_PERM_ENUM __mask) >{ > return (__m512i) __builtin_ia32_pshufd512_mask ((__v16si) __A, > __mask, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_shuffle_epi32 (__m512i __W, __mmask16 __U, __m512i __A, > _MM_PERM_ENUM __mask) >{ > return (__m512i) __builtin_ia32_pshufd512_mask ((__v16si) __A, > __mask, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_shuffle_epi32 (__mmask16 __U, __m512i __A, _MM_PERM_ENUM __mask) >{ > return (__m512i) __builtin_ia32_pshufd512_mask ((__v16si) __A, > __mask, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_shuffle_i64x2 (__m512i __A, __m512i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_shuf_i64x2_mask ((__v8di) __A, > (__v8di) __B, __imm, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_shuffle_i64x2 (__m512i __W, __mmask8 __U, __m512i __A, > __m512i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_shuf_i64x2_mask ((__v8di) __A, > (__v8di) __B, __imm, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_shuffle_i64x2 (__mmask8 __U, __m512i __A, __m512i __B, > const int __imm) >{ > return (__m512i) __builtin_ia32_shuf_i64x2_mask ((__v8di) __A, > (__v8di) __B, __imm, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_shuffle_i32x4 (__m512i __A, __m512i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_shuf_i32x4_mask ((__v16si) __A, > (__v16si) __B, > __imm, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_shuffle_i32x4 (__m512i __W, __mmask16 __U, __m512i __A, > __m512i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_shuf_i32x4_mask ((__v16si) __A, > (__v16si) __B, > __imm, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_shuffle_i32x4 (__mmask16 __U, __m512i __A, __m512i __B, > const int __imm) >{ > return (__m512i) __builtin_ia32_shuf_i32x4_mask ((__v16si) __A, > (__v16si) __B, > __imm, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_shuffle_f64x2 (__m512d __A, __m512d __B, const int __imm) >{ > return (__m512d) __builtin_ia32_shuf_f64x2_mask ((__v8df) __A, > (__v8df) __B, __imm, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_shuffle_f64x2 (__m512d __W, __mmask8 __U, __m512d __A, > __m512d __B, const int __imm) >{ > return (__m512d) __builtin_ia32_shuf_f64x2_mask ((__v8df) __A, > (__v8df) __B, __imm, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_shuffle_f64x2 (__mmask8 __U, __m512d __A, __m512d __B, > const int __imm) >{ > return (__m512d) __builtin_ia32_shuf_f64x2_mask ((__v8df) __A, > (__v8df) __B, __imm, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_shuffle_f32x4 (__m512 __A, __m512 __B, const int __imm) >{ > return (__m512) __builtin_ia32_shuf_f32x4_mask ((__v16sf) __A, > (__v16sf) __B, __imm, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_shuffle_f32x4 (__m512 __W, __mmask16 __U, __m512 __A, > __m512 __B, const int __imm) >{ > return (__m512) __builtin_ia32_shuf_f32x4_mask ((__v16sf) __A, > (__v16sf) __B, __imm, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_shuffle_f32x4 (__mmask16 __U, __m512 __A, __m512 __B, > const int __imm) >{ > return (__m512) __builtin_ia32_shuf_f32x4_mask ((__v16sf) __A, > (__v16sf) __B, __imm, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} ># 4133 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rolv_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prolvd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rolv_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prolvd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rolv_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prolvd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rorv_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prorvd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rorv_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prorvd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rorv_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prorvd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rolv_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prolvq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rolv_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prolvq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rolv_epi64 (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prolvq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rorv_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prorvq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rorv_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prorvq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rorv_epi64 (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_prorvq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtt_roundpd_epi32 (__m512d __A, const int __R) >{ > return (__m256i) __builtin_ia32_cvttpd2dq512_mask ((__v8df) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtt_roundpd_epi32 (__m256i __W, __mmask8 __U, __m512d __A, > const int __R) >{ > return (__m256i) __builtin_ia32_cvttpd2dq512_mask ((__v8df) __A, > (__v8si) __W, > (__mmask8) __U, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtt_roundpd_epi32 (__mmask8 __U, __m512d __A, const int __R) >{ > return (__m256i) __builtin_ia32_cvttpd2dq512_mask ((__v8df) __A, > (__v8si) > _mm256_setzero_si256 (), > (__mmask8) __U, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtt_roundpd_epu32 (__m512d __A, const int __R) >{ > return (__m256i) __builtin_ia32_cvttpd2udq512_mask ((__v8df) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtt_roundpd_epu32 (__m256i __W, __mmask8 __U, __m512d __A, > const int __R) >{ > return (__m256i) __builtin_ia32_cvttpd2udq512_mask ((__v8df) __A, > (__v8si) __W, > (__mmask8) __U, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtt_roundpd_epu32 (__mmask8 __U, __m512d __A, const int __R) >{ > return (__m256i) __builtin_ia32_cvttpd2udq512_mask ((__v8df) __A, > (__v8si) > _mm256_setzero_si256 (), > (__mmask8) __U, __R); >} ># 4342 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundpd_epi32 (__m512d __A, const int __R) >{ > return (__m256i) __builtin_ia32_cvtpd2dq512_mask ((__v8df) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundpd_epi32 (__m256i __W, __mmask8 __U, __m512d __A, > const int __R) >{ > return (__m256i) __builtin_ia32_cvtpd2dq512_mask ((__v8df) __A, > (__v8si) __W, > (__mmask8) __U, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundpd_epi32 (__mmask8 __U, __m512d __A, const int __R) >{ > return (__m256i) __builtin_ia32_cvtpd2dq512_mask ((__v8df) __A, > (__v8si) > _mm256_setzero_si256 (), > (__mmask8) __U, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundpd_epu32 (__m512d __A, const int __R) >{ > return (__m256i) __builtin_ia32_cvtpd2udq512_mask ((__v8df) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundpd_epu32 (__m256i __W, __mmask8 __U, __m512d __A, > const int __R) >{ > return (__m256i) __builtin_ia32_cvtpd2udq512_mask ((__v8df) __A, > (__v8si) __W, > (__mmask8) __U, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundpd_epu32 (__mmask8 __U, __m512d __A, const int __R) >{ > return (__m256i) __builtin_ia32_cvtpd2udq512_mask ((__v8df) __A, > (__v8si) > _mm256_setzero_si256 (), > (__mmask8) __U, __R); >} ># 4422 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtt_roundps_epi32 (__m512 __A, const int __R) >{ > return (__m512i) __builtin_ia32_cvttps2dq512_mask ((__v16sf) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtt_roundps_epi32 (__m512i __W, __mmask16 __U, __m512 __A, > const int __R) >{ > return (__m512i) __builtin_ia32_cvttps2dq512_mask ((__v16sf) __A, > (__v16si) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtt_roundps_epi32 (__mmask16 __U, __m512 __A, const int __R) >{ > return (__m512i) __builtin_ia32_cvttps2dq512_mask ((__v16sf) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtt_roundps_epu32 (__m512 __A, const int __R) >{ > return (__m512i) __builtin_ia32_cvttps2udq512_mask ((__v16sf) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtt_roundps_epu32 (__m512i __W, __mmask16 __U, __m512 __A, > const int __R) >{ > return (__m512i) __builtin_ia32_cvttps2udq512_mask ((__v16sf) __A, > (__v16si) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtt_roundps_epu32 (__mmask16 __U, __m512 __A, const int __R) >{ > return (__m512i) __builtin_ia32_cvttps2udq512_mask ((__v16sf) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U, __R); >} ># 4502 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundps_epi32 (__m512 __A, const int __R) >{ > return (__m512i) __builtin_ia32_cvtps2dq512_mask ((__v16sf) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundps_epi32 (__m512i __W, __mmask16 __U, __m512 __A, > const int __R) >{ > return (__m512i) __builtin_ia32_cvtps2dq512_mask ((__v16sf) __A, > (__v16si) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundps_epi32 (__mmask16 __U, __m512 __A, const int __R) >{ > return (__m512i) __builtin_ia32_cvtps2dq512_mask ((__v16sf) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundps_epu32 (__m512 __A, const int __R) >{ > return (__m512i) __builtin_ia32_cvtps2udq512_mask ((__v16sf) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundps_epu32 (__m512i __W, __mmask16 __U, __m512 __A, > const int __R) >{ > return (__m512i) __builtin_ia32_cvtps2udq512_mask ((__v16sf) __A, > (__v16si) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundps_epu32 (__mmask16 __U, __m512 __A, const int __R) >{ > return (__m512i) __builtin_ia32_cvtps2udq512_mask ((__v16sf) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U, __R); >} ># 4581 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtu32_sd (__m128d __A, unsigned __B) >{ > return (__m128d) __builtin_ia32_cvtusi2sd32 ((__v2df) __A, __B); >} > > > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundu64_sd (__m128d __A, unsigned long long __B, const int __R) >{ > return (__m128d) __builtin_ia32_cvtusi2sd64 ((__v2df) __A, __B, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundi64_sd (__m128d __A, long long __B, const int __R) >{ > return (__m128d) __builtin_ia32_cvtsi2sd64 ((__v2df) __A, __B, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsi64_sd (__m128d __A, long long __B, const int __R) >{ > return (__m128d) __builtin_ia32_cvtsi2sd64 ((__v2df) __A, __B, __R); >} ># 4624 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundu32_ss (__m128 __A, unsigned __B, const int __R) >{ > return (__m128) __builtin_ia32_cvtusi2ss32 ((__v4sf) __A, __B, __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsi32_ss (__m128 __A, int __B, const int __R) >{ > return (__m128) __builtin_ia32_cvtsi2ss32 ((__v4sf) __A, __B, __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundi32_ss (__m128 __A, int __B, const int __R) >{ > return (__m128) __builtin_ia32_cvtsi2ss32 ((__v4sf) __A, __B, __R); >} ># 4657 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundu64_ss (__m128 __A, unsigned long long __B, const int __R) >{ > return (__m128) __builtin_ia32_cvtusi2ss64 ((__v4sf) __A, __B, __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsi64_ss (__m128 __A, long long __B, const int __R) >{ > return (__m128) __builtin_ia32_cvtsi2ss64 ((__v4sf) __A, __B, __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundi64_ss (__m128 __A, long long __B, const int __R) >{ > return (__m128) __builtin_ia32_cvtsi2ss64 ((__v4sf) __A, __B, __R); >} ># 4690 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi32_epi8 (__m512i __A) >{ > return (__m128i) __builtin_ia32_pmovdb512_mask ((__v16si) __A, > (__v16qi) > _mm_undefined_si128 (), > (__mmask16) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi32_storeu_epi8 (void * __P, __mmask16 __M, __m512i __A) >{ > __builtin_ia32_pmovdb512mem_mask ((__v16qi *) __P, (__v16si) __A, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi32_epi8 (__m128i __O, __mmask16 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovdb512_mask ((__v16si) __A, > (__v16qi) __O, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi32_epi8 (__mmask16 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovdb512_mask ((__v16si) __A, > (__v16qi) > _mm_setzero_si128 (), > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtsepi32_epi8 (__m512i __A) >{ > return (__m128i) __builtin_ia32_pmovsdb512_mask ((__v16si) __A, > (__v16qi) > _mm_undefined_si128 (), > (__mmask16) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi32_storeu_epi8 (void * __P, __mmask16 __M, __m512i __A) >{ > __builtin_ia32_pmovsdb512mem_mask ((__v16qi *) __P, (__v16si) __A, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi32_epi8 (__m128i __O, __mmask16 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovsdb512_mask ((__v16si) __A, > (__v16qi) __O, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtsepi32_epi8 (__mmask16 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovsdb512_mask ((__v16si) __A, > (__v16qi) > _mm_setzero_si128 (), > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtusepi32_epi8 (__m512i __A) >{ > return (__m128i) __builtin_ia32_pmovusdb512_mask ((__v16si) __A, > (__v16qi) > _mm_undefined_si128 (), > (__mmask16) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi32_storeu_epi8 (void * __P, __mmask16 __M, __m512i __A) >{ > __builtin_ia32_pmovusdb512mem_mask ((__v16qi *) __P, (__v16si) __A, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi32_epi8 (__m128i __O, __mmask16 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovusdb512_mask ((__v16si) __A, > (__v16qi) __O, > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtusepi32_epi8 (__mmask16 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovusdb512_mask ((__v16si) __A, > (__v16qi) > _mm_setzero_si128 (), > __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi32_epi16 (__m512i __A) >{ > return (__m256i) __builtin_ia32_pmovdw512_mask ((__v16si) __A, > (__v16hi) > _mm256_undefined_si256 (), > (__mmask16) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi32_storeu_epi16 (void * __P, __mmask16 __M, __m512i __A) >{ > __builtin_ia32_pmovdw512mem_mask ((__v16hi *) __P, (__v16si) __A, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi32_epi16 (__m256i __O, __mmask16 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovdw512_mask ((__v16si) __A, > (__v16hi) __O, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi32_epi16 (__mmask16 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovdw512_mask ((__v16si) __A, > (__v16hi) > _mm256_setzero_si256 (), > __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtsepi32_epi16 (__m512i __A) >{ > return (__m256i) __builtin_ia32_pmovsdw512_mask ((__v16si) __A, > (__v16hi) > _mm256_undefined_si256 (), > (__mmask16) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi32_storeu_epi16 (void *__P, __mmask16 __M, __m512i __A) >{ > __builtin_ia32_pmovsdw512mem_mask ((__v16hi*) __P, (__v16si) __A, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi32_epi16 (__m256i __O, __mmask16 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovsdw512_mask ((__v16si) __A, > (__v16hi) __O, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtsepi32_epi16 (__mmask16 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovsdw512_mask ((__v16si) __A, > (__v16hi) > _mm256_setzero_si256 (), > __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtusepi32_epi16 (__m512i __A) >{ > return (__m256i) __builtin_ia32_pmovusdw512_mask ((__v16si) __A, > (__v16hi) > _mm256_undefined_si256 (), > (__mmask16) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi32_storeu_epi16 (void *__P, __mmask16 __M, __m512i __A) >{ > __builtin_ia32_pmovusdw512mem_mask ((__v16hi*) __P, (__v16si) __A, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi32_epi16 (__m256i __O, __mmask16 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovusdw512_mask ((__v16si) __A, > (__v16hi) __O, > __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtusepi32_epi16 (__mmask16 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovusdw512_mask ((__v16si) __A, > (__v16hi) > _mm256_setzero_si256 (), > __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi64_epi32 (__m512i __A) >{ > return (__m256i) __builtin_ia32_pmovqd512_mask ((__v8di) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi64_storeu_epi32 (void* __P, __mmask8 __M, __m512i __A) >{ > __builtin_ia32_pmovqd512mem_mask ((__v8si *) __P, (__v8di) __A, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi64_epi32 (__m256i __O, __mmask8 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovqd512_mask ((__v8di) __A, > (__v8si) __O, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi64_epi32 (__mmask8 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovqd512_mask ((__v8di) __A, > (__v8si) > _mm256_setzero_si256 (), > __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtsepi64_epi32 (__m512i __A) >{ > __v8si __O; > return (__m256i) __builtin_ia32_pmovsqd512_mask ((__v8di) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi64_storeu_epi32 (void *__P, __mmask8 __M, __m512i __A) >{ > __builtin_ia32_pmovsqd512mem_mask ((__v8si *) __P, (__v8di) __A, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi64_epi32 (__m256i __O, __mmask8 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovsqd512_mask ((__v8di) __A, > (__v8si) __O, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtsepi64_epi32 (__mmask8 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovsqd512_mask ((__v8di) __A, > (__v8si) > _mm256_setzero_si256 (), > __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtusepi64_epi32 (__m512i __A) >{ > return (__m256i) __builtin_ia32_pmovusqd512_mask ((__v8di) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi64_storeu_epi32 (void* __P, __mmask8 __M, __m512i __A) >{ > __builtin_ia32_pmovusqd512mem_mask ((__v8si*) __P, (__v8di) __A, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi64_epi32 (__m256i __O, __mmask8 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovusqd512_mask ((__v8di) __A, > (__v8si) __O, __M); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtusepi64_epi32 (__mmask8 __M, __m512i __A) >{ > return (__m256i) __builtin_ia32_pmovusqd512_mask ((__v8di) __A, > (__v8si) > _mm256_setzero_si256 (), > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi64_epi16 (__m512i __A) >{ > return (__m128i) __builtin_ia32_pmovqw512_mask ((__v8di) __A, > (__v8hi) > _mm_undefined_si128 (), > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi64_storeu_epi16 (void *__P, __mmask8 __M, __m512i __A) >{ > __builtin_ia32_pmovqw512mem_mask ((__v8hi *) __P, (__v8di) __A, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi64_epi16 (__m128i __O, __mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovqw512_mask ((__v8di) __A, > (__v8hi) __O, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi64_epi16 (__mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovqw512_mask ((__v8di) __A, > (__v8hi) > _mm_setzero_si128 (), > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtsepi64_epi16 (__m512i __A) >{ > return (__m128i) __builtin_ia32_pmovsqw512_mask ((__v8di) __A, > (__v8hi) > _mm_undefined_si128 (), > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi64_storeu_epi16 (void * __P, __mmask8 __M, __m512i __A) >{ > __builtin_ia32_pmovsqw512mem_mask ((__v8hi *) __P, (__v8di) __A, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi64_epi16 (__m128i __O, __mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovsqw512_mask ((__v8di) __A, > (__v8hi) __O, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtsepi64_epi16 (__mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovsqw512_mask ((__v8di) __A, > (__v8hi) > _mm_setzero_si128 (), > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtusepi64_epi16 (__m512i __A) >{ > return (__m128i) __builtin_ia32_pmovusqw512_mask ((__v8di) __A, > (__v8hi) > _mm_undefined_si128 (), > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi64_storeu_epi16 (void *__P, __mmask8 __M, __m512i __A) >{ > __builtin_ia32_pmovusqw512mem_mask ((__v8hi*) __P, (__v8di) __A, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi64_epi16 (__m128i __O, __mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovusqw512_mask ((__v8di) __A, > (__v8hi) __O, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtusepi64_epi16 (__mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovusqw512_mask ((__v8di) __A, > (__v8hi) > _mm_setzero_si128 (), > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi64_epi8 (__m512i __A) >{ > return (__m128i) __builtin_ia32_pmovqb512_mask ((__v8di) __A, > (__v16qi) > _mm_undefined_si128 (), > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi64_storeu_epi8 (void * __P, __mmask8 __M, __m512i __A) >{ > __builtin_ia32_pmovqb512mem_mask ((__v16qi *) __P, (__v8di) __A, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi64_epi8 (__m128i __O, __mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovqb512_mask ((__v8di) __A, > (__v16qi) __O, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi64_epi8 (__mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovqb512_mask ((__v8di) __A, > (__v16qi) > _mm_setzero_si128 (), > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtsepi64_epi8 (__m512i __A) >{ > return (__m128i) __builtin_ia32_pmovsqb512_mask ((__v8di) __A, > (__v16qi) > _mm_undefined_si128 (), > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi64_storeu_epi8 (void * __P, __mmask8 __M, __m512i __A) >{ > __builtin_ia32_pmovsqb512mem_mask ((__v16qi *) __P, (__v8di) __A, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtsepi64_epi8 (__m128i __O, __mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovsqb512_mask ((__v8di) __A, > (__v16qi) __O, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtsepi64_epi8 (__mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovsqb512_mask ((__v8di) __A, > (__v16qi) > _mm_setzero_si128 (), > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtusepi64_epi8 (__m512i __A) >{ > return (__m128i) __builtin_ia32_pmovusqb512_mask ((__v8di) __A, > (__v16qi) > _mm_undefined_si128 (), > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi64_storeu_epi8 (void * __P, __mmask8 __M, __m512i __A) >{ > __builtin_ia32_pmovusqb512mem_mask ((__v16qi *) __P, (__v8di) __A, __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtusepi64_epi8 (__m128i __O, __mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovusqb512_mask ((__v8di) __A, > (__v16qi) __O, > __M); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtusepi64_epi8 (__mmask8 __M, __m512i __A) >{ > return (__m128i) __builtin_ia32_pmovusqb512_mask ((__v8di) __A, > (__v16qi) > _mm_setzero_si128 (), > __M); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi32_pd (__m256i __A) >{ > return (__m512d) __builtin_ia32_cvtdq2pd512_mask ((__v8si) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi32_pd (__m512d __W, __mmask8 __U, __m256i __A) >{ > return (__m512d) __builtin_ia32_cvtdq2pd512_mask ((__v8si) __A, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi32_pd (__mmask8 __U, __m256i __A) >{ > return (__m512d) __builtin_ia32_cvtdq2pd512_mask ((__v8si) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepu32_pd (__m256i __A) >{ > return (__m512d) __builtin_ia32_cvtudq2pd512_mask ((__v8si) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepu32_pd (__m512d __W, __mmask8 __U, __m256i __A) >{ > return (__m512d) __builtin_ia32_cvtudq2pd512_mask ((__v8si) __A, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepu32_pd (__mmask8 __U, __m256i __A) >{ > return (__m512d) __builtin_ia32_cvtudq2pd512_mask ((__v8si) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundepi32_ps (__m512i __A, const int __R) >{ > return (__m512) __builtin_ia32_cvtdq2ps512_mask ((__v16si) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundepi32_ps (__m512 __W, __mmask16 __U, __m512i __A, > const int __R) >{ > return (__m512) __builtin_ia32_cvtdq2ps512_mask ((__v16si) __A, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundepi32_ps (__mmask16 __U, __m512i __A, const int __R) >{ > return (__m512) __builtin_ia32_cvtdq2ps512_mask ((__v16si) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundepu32_ps (__m512i __A, const int __R) >{ > return (__m512) __builtin_ia32_cvtudq2ps512_mask ((__v16si) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundepu32_ps (__m512 __W, __mmask16 __U, __m512i __A, > const int __R) >{ > return (__m512) __builtin_ia32_cvtudq2ps512_mask ((__v16si) __A, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundepu32_ps (__mmask16 __U, __m512i __A, const int __R) >{ > return (__m512) __builtin_ia32_cvtudq2ps512_mask ((__v16si) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} ># 5359 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m256d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_extractf64x4_pd (__m512d __A, const int __imm) >{ > return (__m256d) __builtin_ia32_extractf64x4_mask ((__v8df) __A, > __imm, > (__v4df) > _mm256_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m256d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_extractf64x4_pd (__m256d __W, __mmask8 __U, __m512d __A, > const int __imm) >{ > return (__m256d) __builtin_ia32_extractf64x4_mask ((__v8df) __A, > __imm, > (__v4df) __W, > (__mmask8) __U); >} > >extern __inline __m256d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_extractf64x4_pd (__mmask8 __U, __m512d __A, const int __imm) >{ > return (__m256d) __builtin_ia32_extractf64x4_mask ((__v8df) __A, > __imm, > (__v4df) > _mm256_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_extractf32x4_ps (__m512 __A, const int __imm) >{ > return (__m128) __builtin_ia32_extractf32x4_mask ((__v16sf) __A, > __imm, > (__v4sf) > _mm_undefined_ps (), > (__mmask8) -1); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_extractf32x4_ps (__m128 __W, __mmask8 __U, __m512 __A, > const int __imm) >{ > return (__m128) __builtin_ia32_extractf32x4_mask ((__v16sf) __A, > __imm, > (__v4sf) __W, > (__mmask8) __U); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_extractf32x4_ps (__mmask8 __U, __m512 __A, const int __imm) >{ > return (__m128) __builtin_ia32_extractf32x4_mask ((__v16sf) __A, > __imm, > (__v4sf) > _mm_setzero_ps (), > (__mmask8) __U); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_extracti64x4_epi64 (__m512i __A, const int __imm) >{ > return (__m256i) __builtin_ia32_extracti64x4_mask ((__v8di) __A, > __imm, > (__v4di) > _mm256_undefined_si256 (), > (__mmask8) -1); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_extracti64x4_epi64 (__m256i __W, __mmask8 __U, __m512i __A, > const int __imm) >{ > return (__m256i) __builtin_ia32_extracti64x4_mask ((__v8di) __A, > __imm, > (__v4di) __W, > (__mmask8) __U); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_extracti64x4_epi64 (__mmask8 __U, __m512i __A, const int __imm) >{ > return (__m256i) __builtin_ia32_extracti64x4_mask ((__v8di) __A, > __imm, > (__v4di) > _mm256_setzero_si256 (), > (__mmask8) __U); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_extracti32x4_epi32 (__m512i __A, const int __imm) >{ > return (__m128i) __builtin_ia32_extracti32x4_mask ((__v16si) __A, > __imm, > (__v4si) > _mm_undefined_si128 (), > (__mmask8) -1); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_extracti32x4_epi32 (__m128i __W, __mmask8 __U, __m512i __A, > const int __imm) >{ > return (__m128i) __builtin_ia32_extracti32x4_mask ((__v16si) __A, > __imm, > (__v4si) __W, > (__mmask8) __U); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_extracti32x4_epi32 (__mmask8 __U, __m512i __A, const int __imm) >{ > return (__m128i) __builtin_ia32_extracti32x4_mask ((__v16si) __A, > __imm, > (__v4si) > _mm_setzero_si128 (), > (__mmask8) __U); >} ># 5566 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_inserti32x4 (__m512i __A, __m128i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_inserti32x4_mask ((__v16si) __A, > (__v4si) __B, > __imm, > (__v16si) __A, -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_insertf32x4 (__m512 __A, __m128 __B, const int __imm) >{ > return (__m512) __builtin_ia32_insertf32x4_mask ((__v16sf) __A, > (__v4sf) __B, > __imm, > (__v16sf) __A, -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_inserti64x4 (__m512i __A, __m256i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_inserti64x4_mask ((__v8di) __A, > (__v4di) __B, > __imm, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_inserti64x4 (__m512i __W, __mmask8 __U, __m512i __A, > __m256i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_inserti64x4_mask ((__v8di) __A, > (__v4di) __B, > __imm, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_inserti64x4 (__mmask8 __U, __m512i __A, __m256i __B, > const int __imm) >{ > return (__m512i) __builtin_ia32_inserti64x4_mask ((__v8di) __A, > (__v4di) __B, > __imm, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_insertf64x4 (__m512d __A, __m256d __B, const int __imm) >{ > return (__m512d) __builtin_ia32_insertf64x4_mask ((__v8df) __A, > (__v4df) __B, > __imm, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_insertf64x4 (__m512d __W, __mmask8 __U, __m512d __A, > __m256d __B, const int __imm) >{ > return (__m512d) __builtin_ia32_insertf64x4_mask ((__v8df) __A, > (__v4df) __B, > __imm, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_insertf64x4 (__mmask8 __U, __m512d __A, __m256d __B, > const int __imm) >{ > return (__m512d) __builtin_ia32_insertf64x4_mask ((__v8df) __A, > (__v4df) __B, > __imm, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} ># 5705 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_loadu_pd (void const *__P) >{ > return (__m512d) __builtin_ia32_loadupd512_mask ((const __v8df *) __P, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_loadu_pd (__m512d __W, __mmask8 __U, void const *__P) >{ > return (__m512d) __builtin_ia32_loadupd512_mask ((const __v8df *) __P, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_loadu_pd (__mmask8 __U, void const *__P) >{ > return (__m512d) __builtin_ia32_loadupd512_mask ((const __v8df *) __P, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_storeu_pd (void *__P, __m512d __A) >{ > __builtin_ia32_storeupd512_mask ((__v8df *) __P, (__v8df) __A, > (__mmask8) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_storeu_pd (void *__P, __mmask8 __U, __m512d __A) >{ > __builtin_ia32_storeupd512_mask ((__v8df *) __P, (__v8df) __A, > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_loadu_ps (void const *__P) >{ > return (__m512) __builtin_ia32_loadups512_mask ((const __v16sf *) __P, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_loadu_ps (__m512 __W, __mmask16 __U, void const *__P) >{ > return (__m512) __builtin_ia32_loadups512_mask ((const __v16sf *) __P, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_loadu_ps (__mmask16 __U, void const *__P) >{ > return (__m512) __builtin_ia32_loadups512_mask ((const __v16sf *) __P, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_storeu_ps (void *__P, __m512 __A) >{ > __builtin_ia32_storeups512_mask ((__v16sf *) __P, (__v16sf) __A, > (__mmask16) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_storeu_ps (void *__P, __mmask16 __U, __m512 __A) >{ > __builtin_ia32_storeups512_mask ((__v16sf *) __P, (__v16sf) __A, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_loadu_epi64 (__m512i __W, __mmask8 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_loaddqudi512_mask ((const __v8di *) __P, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_loadu_epi64 (__mmask8 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_loaddqudi512_mask ((const __v8di *) __P, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_storeu_epi64 (void *__P, __mmask8 __U, __m512i __A) >{ > __builtin_ia32_storedqudi512_mask ((__v8di *) __P, (__v8di) __A, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_loadu_si512 (void const *__P) >{ > return (__m512i) __builtin_ia32_loaddqusi512_mask ((const __v16si *) __P, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_loadu_epi32 (__m512i __W, __mmask16 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_loaddqusi512_mask ((const __v16si *) __P, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_loadu_epi32 (__mmask16 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_loaddqusi512_mask ((const __v16si *) __P, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_storeu_si512 (void *__P, __m512i __A) >{ > __builtin_ia32_storedqusi512_mask ((__v16si *) __P, (__v16si) __A, > (__mmask16) -1); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_storeu_epi32 (void *__P, __mmask16 __U, __m512i __A) >{ > __builtin_ia32_storedqusi512_mask ((__v16si *) __P, (__v16si) __A, > (__mmask16) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutevar_pd (__m512d __A, __m512i __C) >{ > return (__m512d) __builtin_ia32_vpermilvarpd512_mask ((__v8df) __A, > (__v8di) __C, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutevar_pd (__m512d __W, __mmask8 __U, __m512d __A, __m512i __C) >{ > return (__m512d) __builtin_ia32_vpermilvarpd512_mask ((__v8df) __A, > (__v8di) __C, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutevar_pd (__mmask8 __U, __m512d __A, __m512i __C) >{ > return (__m512d) __builtin_ia32_vpermilvarpd512_mask ((__v8df) __A, > (__v8di) __C, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutevar_ps (__m512 __A, __m512i __C) >{ > return (__m512) __builtin_ia32_vpermilvarps512_mask ((__v16sf) __A, > (__v16si) __C, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutevar_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512i __C) >{ > return (__m512) __builtin_ia32_vpermilvarps512_mask ((__v16sf) __A, > (__v16si) __C, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutevar_ps (__mmask16 __U, __m512 __A, __m512i __C) >{ > return (__m512) __builtin_ia32_vpermilvarps512_mask ((__v16sf) __A, > (__v16si) __C, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutex2var_epi64 (__m512i __A, __m512i __I, __m512i __B) >{ > return (__m512i) __builtin_ia32_vpermt2varq512_mask ((__v8di) __I > , > (__v8di) __A, > (__v8di) __B, > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutex2var_epi64 (__m512i __A, __mmask8 __U, __m512i __I, > __m512i __B) >{ > return (__m512i) __builtin_ia32_vpermt2varq512_mask ((__v8di) __I > , > (__v8di) __A, > (__v8di) __B, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask2_permutex2var_epi64 (__m512i __A, __m512i __I, > __mmask8 __U, __m512i __B) >{ > return (__m512i) __builtin_ia32_vpermi2varq512_mask ((__v8di) __A, > (__v8di) __I > , > (__v8di) __B, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutex2var_epi64 (__mmask8 __U, __m512i __A, > __m512i __I, __m512i __B) >{ > return (__m512i) __builtin_ia32_vpermt2varq512_maskz ((__v8di) __I > , > (__v8di) __A, > (__v8di) __B, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutex2var_epi32 (__m512i __A, __m512i __I, __m512i __B) >{ > return (__m512i) __builtin_ia32_vpermt2vard512_mask ((__v16si) __I > , > (__v16si) __A, > (__v16si) __B, > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutex2var_epi32 (__m512i __A, __mmask16 __U, > __m512i __I, __m512i __B) >{ > return (__m512i) __builtin_ia32_vpermt2vard512_mask ((__v16si) __I > , > (__v16si) __A, > (__v16si) __B, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask2_permutex2var_epi32 (__m512i __A, __m512i __I, > __mmask16 __U, __m512i __B) >{ > return (__m512i) __builtin_ia32_vpermi2vard512_mask ((__v16si) __A, > (__v16si) __I > , > (__v16si) __B, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutex2var_epi32 (__mmask16 __U, __m512i __A, > __m512i __I, __m512i __B) >{ > return (__m512i) __builtin_ia32_vpermt2vard512_maskz ((__v16si) __I > , > (__v16si) __A, > (__v16si) __B, > (__mmask16) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutex2var_pd (__m512d __A, __m512i __I, __m512d __B) >{ > return (__m512d) __builtin_ia32_vpermt2varpd512_mask ((__v8di) __I > , > (__v8df) __A, > (__v8df) __B, > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutex2var_pd (__m512d __A, __mmask8 __U, __m512i __I, > __m512d __B) >{ > return (__m512d) __builtin_ia32_vpermt2varpd512_mask ((__v8di) __I > , > (__v8df) __A, > (__v8df) __B, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask2_permutex2var_pd (__m512d __A, __m512i __I, __mmask8 __U, > __m512d __B) >{ > return (__m512d) __builtin_ia32_vpermi2varpd512_mask ((__v8df) __A, > (__v8di) __I > , > (__v8df) __B, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutex2var_pd (__mmask8 __U, __m512d __A, __m512i __I, > __m512d __B) >{ > return (__m512d) __builtin_ia32_vpermt2varpd512_maskz ((__v8di) __I > , > (__v8df) __A, > (__v8df) __B, > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutex2var_ps (__m512 __A, __m512i __I, __m512 __B) >{ > return (__m512) __builtin_ia32_vpermt2varps512_mask ((__v16si) __I > , > (__v16sf) __A, > (__v16sf) __B, > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutex2var_ps (__m512 __A, __mmask16 __U, __m512i __I, __m512 __B) >{ > return (__m512) __builtin_ia32_vpermt2varps512_mask ((__v16si) __I > , > (__v16sf) __A, > (__v16sf) __B, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask2_permutex2var_ps (__m512 __A, __m512i __I, __mmask16 __U, > __m512 __B) >{ > return (__m512) __builtin_ia32_vpermi2varps512_mask ((__v16sf) __A, > (__v16si) __I > , > (__v16sf) __B, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutex2var_ps (__mmask16 __U, __m512 __A, __m512i __I, > __m512 __B) >{ > return (__m512) __builtin_ia32_vpermt2varps512_maskz ((__v16si) __I > , > (__v16sf) __A, > (__v16sf) __B, > (__mmask16) __U); >} > > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permute_pd (__m512d __X, const int __C) >{ > return (__m512d) __builtin_ia32_vpermilpd512_mask ((__v8df) __X, __C, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permute_pd (__m512d __W, __mmask8 __U, __m512d __X, const int __C) >{ > return (__m512d) __builtin_ia32_vpermilpd512_mask ((__v8df) __X, __C, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permute_pd (__mmask8 __U, __m512d __X, const int __C) >{ > return (__m512d) __builtin_ia32_vpermilpd512_mask ((__v8df) __X, __C, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permute_ps (__m512 __X, const int __C) >{ > return (__m512) __builtin_ia32_vpermilps512_mask ((__v16sf) __X, __C, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permute_ps (__m512 __W, __mmask16 __U, __m512 __X, const int __C) >{ > return (__m512) __builtin_ia32_vpermilps512_mask ((__v16sf) __X, __C, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permute_ps (__mmask16 __U, __m512 __X, const int __C) >{ > return (__m512) __builtin_ia32_vpermilps512_mask ((__v16sf) __X, __C, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} ># 6209 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutex_epi64 (__m512i __X, const int __I) >{ > return (__m512i) __builtin_ia32_permdi512_mask ((__v8di) __X, __I, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) (-1)); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutex_epi64 (__m512i __W, __mmask8 __M, > __m512i __X, const int __I) >{ > return (__m512i) __builtin_ia32_permdi512_mask ((__v8di) __X, __I, > (__v8di) __W, > (__mmask8) __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutex_epi64 (__mmask8 __M, __m512i __X, const int __I) >{ > return (__m512i) __builtin_ia32_permdi512_mask ((__v8di) __X, __I, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __M); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutex_pd (__m512d __X, const int __M) >{ > return (__m512d) __builtin_ia32_permdf512_mask ((__v8df) __X, __M, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutex_pd (__m512d __W, __mmask8 __U, __m512d __X, const int __M) >{ > return (__m512d) __builtin_ia32_permdf512_mask ((__v8df) __X, __M, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutex_pd (__mmask8 __U, __m512d __X, const int __M) >{ > return (__m512d) __builtin_ia32_permdf512_mask ((__v8df) __X, __M, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} ># 6303 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutexvar_epi64 (__mmask8 __M, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_permvardi512_mask ((__v8di) __Y, > (__v8di) __X, > (__v8di) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutexvar_epi64 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_permvardi512_mask ((__v8di) __Y, > (__v8di) __X, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutexvar_epi64 (__m512i __W, __mmask8 __M, __m512i __X, > __m512i __Y) >{ > return (__m512i) __builtin_ia32_permvardi512_mask ((__v8di) __Y, > (__v8di) __X, > (__v8di) __W, > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutexvar_epi32 (__mmask16 __M, __m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_permvarsi512_mask ((__v16si) __Y, > (__v16si) __X, > (__v16si) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutexvar_epi32 (__m512i __X, __m512i __Y) >{ > return (__m512i) __builtin_ia32_permvarsi512_mask ((__v16si) __Y, > (__v16si) __X, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutexvar_epi32 (__m512i __W, __mmask16 __M, __m512i __X, > __m512i __Y) >{ > return (__m512i) __builtin_ia32_permvarsi512_mask ((__v16si) __Y, > (__v16si) __X, > (__v16si) __W, > __M); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutexvar_pd (__m512i __X, __m512d __Y) >{ > return (__m512d) __builtin_ia32_permvardf512_mask ((__v8df) __Y, > (__v8di) __X, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutexvar_pd (__m512d __W, __mmask8 __U, __m512i __X, __m512d __Y) >{ > return (__m512d) __builtin_ia32_permvardf512_mask ((__v8df) __Y, > (__v8di) __X, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutexvar_pd (__mmask8 __U, __m512i __X, __m512d __Y) >{ > return (__m512d) __builtin_ia32_permvardf512_mask ((__v8df) __Y, > (__v8di) __X, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_permutexvar_ps (__m512i __X, __m512 __Y) >{ > return (__m512) __builtin_ia32_permvarsf512_mask ((__v16sf) __Y, > (__v16si) __X, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_permutexvar_ps (__m512 __W, __mmask16 __U, __m512i __X, __m512 __Y) >{ > return (__m512) __builtin_ia32_permvarsf512_mask ((__v16sf) __Y, > (__v16si) __X, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_permutexvar_ps (__mmask16 __U, __m512i __X, __m512 __Y) >{ > return (__m512) __builtin_ia32_permvarsf512_mask ((__v16sf) __Y, > (__v16si) __X, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_shuffle_ps (__m512 __M, __m512 __V, const int __imm) >{ > return (__m512) __builtin_ia32_shufps512_mask ((__v16sf) __M, > (__v16sf) __V, __imm, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_shuffle_ps (__m512 __W, __mmask16 __U, __m512 __M, > __m512 __V, const int __imm) >{ > return (__m512) __builtin_ia32_shufps512_mask ((__v16sf) __M, > (__v16sf) __V, __imm, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_shuffle_ps (__mmask16 __U, __m512 __M, __m512 __V, const int __imm) >{ > return (__m512) __builtin_ia32_shufps512_mask ((__v16sf) __M, > (__v16sf) __V, __imm, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_shuffle_pd (__m512d __M, __m512d __V, const int __imm) >{ > return (__m512d) __builtin_ia32_shufpd512_mask ((__v8df) __M, > (__v8df) __V, __imm, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_shuffle_pd (__m512d __W, __mmask8 __U, __m512d __M, > __m512d __V, const int __imm) >{ > return (__m512d) __builtin_ia32_shufpd512_mask ((__v8df) __M, > (__v8df) __V, __imm, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_shuffle_pd (__mmask8 __U, __m512d __M, __m512d __V, > const int __imm) >{ > return (__m512d) __builtin_ia32_shufpd512_mask ((__v8df) __M, > (__v8df) __V, __imm, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fixupimm_round_pd (__m512d __A, __m512d __B, __m512i __C, > const int __imm, const int __R) >{ > return (__m512d) __builtin_ia32_fixupimmpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8di) __C, > __imm, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fixupimm_round_pd (__m512d __A, __mmask8 __U, __m512d __B, > __m512i __C, const int __imm, const int __R) >{ > return (__m512d) __builtin_ia32_fixupimmpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8di) __C, > __imm, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fixupimm_round_pd (__mmask8 __U, __m512d __A, __m512d __B, > __m512i __C, const int __imm, const int __R) >{ > return (__m512d) __builtin_ia32_fixupimmpd512_maskz ((__v8df) __A, > (__v8df) __B, > (__v8di) __C, > __imm, > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fixupimm_round_ps (__m512 __A, __m512 __B, __m512i __C, > const int __imm, const int __R) >{ > return (__m512) __builtin_ia32_fixupimmps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16si) __C, > __imm, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fixupimm_round_ps (__m512 __A, __mmask16 __U, __m512 __B, > __m512i __C, const int __imm, const int __R) >{ > return (__m512) __builtin_ia32_fixupimmps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16si) __C, > __imm, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fixupimm_round_ps (__mmask16 __U, __m512 __A, __m512 __B, > __m512i __C, const int __imm, const int __R) >{ > return (__m512) __builtin_ia32_fixupimmps512_maskz ((__v16sf) __A, > (__v16sf) __B, > (__v16si) __C, > __imm, > (__mmask16) __U, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fixupimm_round_sd (__m128d __A, __m128d __B, __m128i __C, > const int __imm, const int __R) >{ > return (__m128d) __builtin_ia32_fixupimmsd_mask ((__v2df) __A, > (__v2df) __B, > (__v2di) __C, __imm, > (__mmask8) -1, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_fixupimm_round_sd (__m128d __A, __mmask8 __U, __m128d __B, > __m128i __C, const int __imm, const int __R) >{ > return (__m128d) __builtin_ia32_fixupimmsd_mask ((__v2df) __A, > (__v2df) __B, > (__v2di) __C, __imm, > (__mmask8) __U, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskz_fixupimm_round_sd (__mmask8 __U, __m128d __A, __m128d __B, > __m128i __C, const int __imm, const int __R) >{ > return (__m128d) __builtin_ia32_fixupimmsd_maskz ((__v2df) __A, > (__v2df) __B, > (__v2di) __C, > __imm, > (__mmask8) __U, __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fixupimm_round_ss (__m128 __A, __m128 __B, __m128i __C, > const int __imm, const int __R) >{ > return (__m128) __builtin_ia32_fixupimmss_mask ((__v4sf) __A, > (__v4sf) __B, > (__v4si) __C, __imm, > (__mmask8) -1, __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_fixupimm_round_ss (__m128 __A, __mmask8 __U, __m128 __B, > __m128i __C, const int __imm, const int __R) >{ > return (__m128) __builtin_ia32_fixupimmss_mask ((__v4sf) __A, > (__v4sf) __B, > (__v4si) __C, __imm, > (__mmask8) __U, __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskz_fixupimm_round_ss (__mmask8 __U, __m128 __A, __m128 __B, > __m128i __C, const int __imm, const int __R) >{ > return (__m128) __builtin_ia32_fixupimmss_maskz ((__v4sf) __A, > (__v4sf) __B, > (__v4si) __C, __imm, > (__mmask8) __U, __R); >} ># 6738 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_movehdup_ps (__m512 __A) >{ > return (__m512) __builtin_ia32_movshdup512_mask ((__v16sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_movehdup_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_movshdup512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_movehdup_ps (__mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_movshdup512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_moveldup_ps (__m512 __A) >{ > return (__m512) __builtin_ia32_movsldup512_mask ((__v16sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_moveldup_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_movsldup512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_moveldup_ps (__mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_movsldup512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_or_si512 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pord512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_or_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pord512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_or_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pord512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_or_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pord512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_or_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_porq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_or_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_porq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_or_epi64 (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_porq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_xor_si512 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pxord512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_xor_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pxord512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_xor_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pxord512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_xor_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pxord512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_xor_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pxorq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_xor_epi64 (__m512i __W, __mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pxorq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_xor_epi64 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pxorq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rol_epi32 (__m512i __A, const int __B) >{ > return (__m512i) __builtin_ia32_prold512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rol_epi32 (__m512i __W, __mmask16 __U, __m512i __A, const int __B) >{ > return (__m512i) __builtin_ia32_prold512_mask ((__v16si) __A, __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rol_epi32 (__mmask16 __U, __m512i __A, const int __B) >{ > return (__m512i) __builtin_ia32_prold512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_ror_epi32 (__m512i __A, int __B) >{ > return (__m512i) __builtin_ia32_prord512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_ror_epi32 (__m512i __W, __mmask16 __U, __m512i __A, int __B) >{ > return (__m512i) __builtin_ia32_prord512_mask ((__v16si) __A, __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_ror_epi32 (__mmask16 __U, __m512i __A, int __B) >{ > return (__m512i) __builtin_ia32_prord512_mask ((__v16si) __A, __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rol_epi64 (__m512i __A, const int __B) >{ > return (__m512i) __builtin_ia32_prolq512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rol_epi64 (__m512i __W, __mmask8 __U, __m512i __A, const int __B) >{ > return (__m512i) __builtin_ia32_prolq512_mask ((__v8di) __A, __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rol_epi64 (__mmask8 __U, __m512i __A, const int __B) >{ > return (__m512i) __builtin_ia32_prolq512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_ror_epi64 (__m512i __A, int __B) >{ > return (__m512i) __builtin_ia32_prorq512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_ror_epi64 (__m512i __W, __mmask8 __U, __m512i __A, int __B) >{ > return (__m512i) __builtin_ia32_prorq512_mask ((__v8di) __A, __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_ror_epi64 (__mmask8 __U, __m512i __A, int __B) >{ > return (__m512i) __builtin_ia32_prorq512_mask ((__v8di) __A, __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} ># 7127 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_and_si512 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_and_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_and_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_and_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_and_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_and_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_and_epi64 (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_pd (), > __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_andnot_si512 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandnd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_andnot_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandnd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_andnot_epi32 (__m512i __W, __mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandnd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_andnot_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandnd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_andnot_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandnq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_andnot_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandnq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_andnot_epi64 (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pandnq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_pd (), > __U); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_test_epi32_mask (__m512i __A, __m512i __B) >{ > return (__mmask16) __builtin_ia32_ptestmd512 ((__v16si) __A, > (__v16si) __B, > (__mmask16) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_test_epi32_mask (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__mmask16) __builtin_ia32_ptestmd512 ((__v16si) __A, > (__v16si) __B, __U); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_test_epi64_mask (__m512i __A, __m512i __B) >{ > return (__mmask8) __builtin_ia32_ptestmq512 ((__v8di) __A, > (__v8di) __B, > (__mmask8) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_test_epi64_mask (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__mmask8) __builtin_ia32_ptestmq512 ((__v8di) __A, (__v8di) __B, __U); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_testn_epi32_mask (__m512i __A, __m512i __B) >{ > return (__mmask16) __builtin_ia32_ptestnmd512 ((__v16si) __A, > (__v16si) __B, > (__mmask16) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_testn_epi32_mask (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__mmask16) __builtin_ia32_ptestnmd512 ((__v16si) __A, > (__v16si) __B, __U); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_testn_epi64_mask (__m512i __A, __m512i __B) >{ > return (__mmask8) __builtin_ia32_ptestnmq512 ((__v8di) __A, > (__v8di) __B, > (__mmask8) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_testn_epi64_mask (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__mmask8) __builtin_ia32_ptestnmq512 ((__v8di) __A, > (__v8di) __B, __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_unpackhi_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpckhdq512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_unpackhi_epi32 (__m512i __W, __mmask16 __U, __m512i __A, > __m512i __B) >{ > return (__m512i) __builtin_ia32_punpckhdq512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_unpackhi_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpckhdq512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_unpackhi_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpckhqdq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_unpackhi_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpckhqdq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_unpackhi_epi64 (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpckhqdq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_unpacklo_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpckldq512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_unpacklo_epi32 (__m512i __W, __mmask16 __U, __m512i __A, > __m512i __B) >{ > return (__m512i) __builtin_ia32_punpckldq512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_unpacklo_epi32 (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpckldq512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_unpacklo_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpcklqdq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_unpacklo_epi64 (__m512i __W, __mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpcklqdq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_unpacklo_epi64 (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_punpcklqdq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > > > >extern __inline unsigned long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundss_u64 (__m128 __A, const int __R) >{ > return (unsigned long long) __builtin_ia32_vcvtss2usi64 ((__v4sf) __A, __R); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundss_si64 (__m128 __A, const int __R) >{ > return (long long) __builtin_ia32_vcvtss2si64 ((__v4sf) __A, __R); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundss_i64 (__m128 __A, const int __R) >{ > return (long long) __builtin_ia32_vcvtss2si64 ((__v4sf) __A, __R); >} > >extern __inline unsigned long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundss_u64 (__m128 __A, const int __R) >{ > return (unsigned long long) __builtin_ia32_vcvttss2usi64 ((__v4sf) __A, __R); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundss_i64 (__m128 __A, const int __R) >{ > return (long long) __builtin_ia32_vcvttss2si64 ((__v4sf) __A, __R); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundss_si64 (__m128 __A, const int __R) >{ > return (long long) __builtin_ia32_vcvttss2si64 ((__v4sf) __A, __R); >} ># 7537 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline unsigned >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundss_u32 (__m128 __A, const int __R) >{ > return (unsigned) __builtin_ia32_vcvtss2usi32 ((__v4sf) __A, __R); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundss_si32 (__m128 __A, const int __R) >{ > return (int) __builtin_ia32_vcvtss2si32 ((__v4sf) __A, __R); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundss_i32 (__m128 __A, const int __R) >{ > return (int) __builtin_ia32_vcvtss2si32 ((__v4sf) __A, __R); >} > >extern __inline unsigned >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundss_u32 (__m128 __A, const int __R) >{ > return (unsigned) __builtin_ia32_vcvttss2usi32 ((__v4sf) __A, __R); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundss_i32 (__m128 __A, const int __R) >{ > return (int) __builtin_ia32_vcvttss2si32 ((__v4sf) __A, __R); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundss_si32 (__m128 __A, const int __R) >{ > return (int) __builtin_ia32_vcvttss2si32 ((__v4sf) __A, __R); >} ># 7600 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline unsigned long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsd_u64 (__m128d __A, const int __R) >{ > return (unsigned long long) __builtin_ia32_vcvtsd2usi64 ((__v2df) __A, __R); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsd_si64 (__m128d __A, const int __R) >{ > return (long long) __builtin_ia32_vcvtsd2si64 ((__v2df) __A, __R); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsd_i64 (__m128d __A, const int __R) >{ > return (long long) __builtin_ia32_vcvtsd2si64 ((__v2df) __A, __R); >} > >extern __inline unsigned long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundsd_u64 (__m128d __A, const int __R) >{ > return (unsigned long long) __builtin_ia32_vcvttsd2usi64 ((__v2df) __A, __R); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundsd_si64 (__m128d __A, const int __R) >{ > return (long long) __builtin_ia32_vcvttsd2si64 ((__v2df) __A, __R); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundsd_i64 (__m128d __A, const int __R) >{ > return (long long) __builtin_ia32_vcvttsd2si64 ((__v2df) __A, __R); >} ># 7663 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline unsigned >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsd_u32 (__m128d __A, const int __R) >{ > return (unsigned) __builtin_ia32_vcvtsd2usi32 ((__v2df) __A, __R); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsd_si32 (__m128d __A, const int __R) >{ > return (int) __builtin_ia32_vcvtsd2si32 ((__v2df) __A, __R); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsd_i32 (__m128d __A, const int __R) >{ > return (int) __builtin_ia32_vcvtsd2si32 ((__v2df) __A, __R); >} > >extern __inline unsigned >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundsd_u32 (__m128d __A, const int __R) >{ > return (unsigned) __builtin_ia32_vcvttsd2usi32 ((__v2df) __A, __R); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundsd_i32 (__m128d __A, const int __R) >{ > return (int) __builtin_ia32_vcvttsd2si32 ((__v2df) __A, __R); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtt_roundsd_si32 (__m128d __A, const int __R) >{ > return (int) __builtin_ia32_vcvttsd2si32 ((__v2df) __A, __R); >} ># 7724 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_movedup_pd (__m512d __A) >{ > return (__m512d) __builtin_ia32_movddup512_mask ((__v8df) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_movedup_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_movddup512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_movedup_pd (__mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_movddup512_mask ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_unpacklo_pd (__m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_unpcklpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_unpacklo_pd (__m512d __W, __mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_unpcklpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_unpacklo_pd (__mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_unpcklpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_unpackhi_pd (__m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_unpckhpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_unpackhi_pd (__m512d __W, __mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_unpckhpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_unpackhi_pd (__mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_unpckhpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_unpackhi_ps (__m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_unpckhps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_unpackhi_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_unpckhps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_unpackhi_ps (__mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_unpckhps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundps_pd (__m256 __A, const int __R) >{ > return (__m512d) __builtin_ia32_cvtps2pd512_mask ((__v8sf) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundps_pd (__m512d __W, __mmask8 __U, __m256 __A, > const int __R) >{ > return (__m512d) __builtin_ia32_cvtps2pd512_mask ((__v8sf) __A, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundps_pd (__mmask8 __U, __m256 __A, const int __R) >{ > return (__m512d) __builtin_ia32_cvtps2pd512_mask ((__v8sf) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundph_ps (__m256i __A, const int __R) >{ > return (__m512) __builtin_ia32_vcvtph2ps512_mask ((__v16hi) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundph_ps (__m512 __W, __mmask16 __U, __m256i __A, > const int __R) >{ > return (__m512) __builtin_ia32_vcvtph2ps512_mask ((__v16hi) __A, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundph_ps (__mmask16 __U, __m256i __A, const int __R) >{ > return (__m512) __builtin_ia32_vcvtph2ps512_mask ((__v16hi) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundps_ph (__m512 __A, const int __I) >{ > return (__m256i) __builtin_ia32_vcvtps2ph512_mask ((__v16sf) __A, > __I, > (__v16hi) > _mm256_undefined_si256 (), > -1); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtps_ph (__m512 __A, const int __I) >{ > return (__m256i) __builtin_ia32_vcvtps2ph512_mask ((__v16sf) __A, > __I, > (__v16hi) > _mm256_undefined_si256 (), > -1); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundps_ph (__m256i __U, __mmask16 __W, __m512 __A, > const int __I) >{ > return (__m256i) __builtin_ia32_vcvtps2ph512_mask ((__v16sf) __A, > __I, > (__v16hi) __U, > (__mmask16) __W); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtps_ph (__m256i __U, __mmask16 __W, __m512 __A, const int __I) >{ > return (__m256i) __builtin_ia32_vcvtps2ph512_mask ((__v16sf) __A, > __I, > (__v16hi) __U, > (__mmask16) __W); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundps_ph (__mmask16 __W, __m512 __A, const int __I) >{ > return (__m256i) __builtin_ia32_vcvtps2ph512_mask ((__v16sf) __A, > __I, > (__v16hi) > _mm256_setzero_si256 (), > (__mmask16) __W); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtps_ph (__mmask16 __W, __m512 __A, const int __I) >{ > return (__m256i) __builtin_ia32_vcvtps2ph512_mask ((__v16sf) __A, > __I, > (__v16hi) > _mm256_setzero_si256 (), > (__mmask16) __W); >} ># 8014 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvt_roundpd_ps (__m512d __A, const int __R) >{ > return (__m256) __builtin_ia32_cvtpd2ps512_mask ((__v8df) __A, > (__v8sf) > _mm256_undefined_ps (), > (__mmask8) -1, __R); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvt_roundpd_ps (__m256 __W, __mmask8 __U, __m512d __A, > const int __R) >{ > return (__m256) __builtin_ia32_cvtpd2ps512_mask ((__v8df) __A, > (__v8sf) __W, > (__mmask8) __U, __R); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvt_roundpd_ps (__mmask8 __U, __m512d __A, const int __R) >{ > return (__m256) __builtin_ia32_cvtpd2ps512_mask ((__v8df) __A, > (__v8sf) > _mm256_setzero_ps (), > (__mmask8) __U, __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundsd_ss (__m128 __A, __m128d __B, const int __R) >{ > return (__m128) __builtin_ia32_cvtsd2ss_round ((__v4sf) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvt_roundss_sd (__m128d __A, __m128 __B, const int __R) >{ > return (__m128d) __builtin_ia32_cvtss2sd_round ((__v2df) __A, > (__v4sf) __B, > __R); >} ># 8078 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_stream_si512 (__m512i * __P, __m512i __A) >{ > __builtin_ia32_movntdq512 ((__v8di *) __P, (__v8di) __A); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_stream_ps (float *__P, __m512 __A) >{ > __builtin_ia32_movntps512 (__P, (__v16sf) __A); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_stream_pd (double *__P, __m512d __A) >{ > __builtin_ia32_movntpd512 (__P, (__v8df) __A); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_stream_load_si512 (void *__P) >{ > return __builtin_ia32_movntdqa512 ((__v8di *)__P); >} > > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_getexp_round_ss (__m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_getexpss128_round ((__v4sf) __A, > (__v4sf) __B, > __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_getexp_round_sd (__m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_getexpsd128_round ((__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_getexp_round_ps (__m512 __A, const int __R) >{ > return (__m512) __builtin_ia32_getexpps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_getexp_round_ps (__m512 __W, __mmask16 __U, __m512 __A, > const int __R) >{ > return (__m512) __builtin_ia32_getexpps512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_getexp_round_ps (__mmask16 __U, __m512 __A, const int __R) >{ > return (__m512) __builtin_ia32_getexpps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_getexp_round_pd (__m512d __A, const int __R) >{ > return (__m512d) __builtin_ia32_getexppd512_mask ((__v8df) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_getexp_round_pd (__m512d __W, __mmask8 __U, __m512d __A, > const int __R) >{ > return (__m512d) __builtin_ia32_getexppd512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_getexp_round_pd (__mmask8 __U, __m512d __A, const int __R) >{ > return (__m512d) __builtin_ia32_getexppd512_mask ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > > >typedef enum >{ > _MM_MANT_NORM_1_2, > _MM_MANT_NORM_p5_2, > _MM_MANT_NORM_p5_1, > _MM_MANT_NORM_p75_1p5 >} _MM_MANTISSA_NORM_ENUM; > >typedef enum >{ > _MM_MANT_SIGN_src, > _MM_MANT_SIGN_zero, > _MM_MANT_SIGN_nan >} _MM_MANTISSA_SIGN_ENUM; > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_getmant_round_pd (__m512d __A, _MM_MANTISSA_NORM_ENUM __B, > _MM_MANTISSA_SIGN_ENUM __C, const int __R) >{ > return (__m512d) __builtin_ia32_getmantpd512_mask ((__v8df) __A, > (__C << 2) | __B, > _mm512_undefined_pd (), > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_getmant_round_pd (__m512d __W, __mmask8 __U, __m512d __A, > _MM_MANTISSA_NORM_ENUM __B, > _MM_MANTISSA_SIGN_ENUM __C, const int __R) >{ > return (__m512d) __builtin_ia32_getmantpd512_mask ((__v8df) __A, > (__C << 2) | __B, > (__v8df) __W, __U, > __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_getmant_round_pd (__mmask8 __U, __m512d __A, > _MM_MANTISSA_NORM_ENUM __B, > _MM_MANTISSA_SIGN_ENUM __C, const int __R) >{ > return (__m512d) __builtin_ia32_getmantpd512_mask ((__v8df) __A, > (__C << 2) | __B, > (__v8df) > _mm512_setzero_pd (), > __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_getmant_round_ps (__m512 __A, _MM_MANTISSA_NORM_ENUM __B, > _MM_MANTISSA_SIGN_ENUM __C, const int __R) >{ > return (__m512) __builtin_ia32_getmantps512_mask ((__v16sf) __A, > (__C << 2) | __B, > _mm512_undefined_ps (), > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_getmant_round_ps (__m512 __W, __mmask16 __U, __m512 __A, > _MM_MANTISSA_NORM_ENUM __B, > _MM_MANTISSA_SIGN_ENUM __C, const int __R) >{ > return (__m512) __builtin_ia32_getmantps512_mask ((__v16sf) __A, > (__C << 2) | __B, > (__v16sf) __W, __U, > __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_getmant_round_ps (__mmask16 __U, __m512 __A, > _MM_MANTISSA_NORM_ENUM __B, > _MM_MANTISSA_SIGN_ENUM __C, const int __R) >{ > return (__m512) __builtin_ia32_getmantps512_mask ((__v16sf) __A, > (__C << 2) | __B, > (__v16sf) > _mm512_setzero_ps (), > __U, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_getmant_round_sd (__m128d __A, __m128d __B, > _MM_MANTISSA_NORM_ENUM __C, > _MM_MANTISSA_SIGN_ENUM __D, const int __R) >{ > return (__m128d) __builtin_ia32_getmantsd_round ((__v2df) __A, > (__v2df) __B, > (__D << 2) | __C, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_getmant_round_ss (__m128 __A, __m128 __B, > _MM_MANTISSA_NORM_ENUM __C, > _MM_MANTISSA_SIGN_ENUM __D, const int __R) >{ > return (__m128) __builtin_ia32_getmantss_round ((__v4sf) __A, > (__v4sf) __B, > (__D << 2) | __C, > __R); >} ># 8382 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_roundscale_round_ps (__m512 __A, const int __imm, const int __R) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __A, __imm, > (__v16sf) > _mm512_undefined_ps (), > -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_roundscale_round_ps (__m512 __A, __mmask16 __B, __m512 __C, > const int __imm, const int __R) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __C, __imm, > (__v16sf) __A, > (__mmask16) __B, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_roundscale_round_ps (__mmask16 __A, __m512 __B, > const int __imm, const int __R) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __B, > __imm, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __A, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_roundscale_round_pd (__m512d __A, const int __imm, const int __R) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __A, __imm, > (__v8df) > _mm512_undefined_pd (), > -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_roundscale_round_pd (__m512d __A, __mmask8 __B, > __m512d __C, const int __imm, const int __R) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __C, __imm, > (__v8df) __A, > (__mmask8) __B, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_roundscale_round_pd (__mmask8 __A, __m512d __B, > const int __imm, const int __R) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __B, > __imm, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __A, __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_roundscale_round_ss (__m128 __A, __m128 __B, const int __imm, const int __R) >{ > return (__m128) __builtin_ia32_rndscaless_round ((__v4sf) __A, > (__v4sf) __B, __imm, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_roundscale_round_sd (__m128d __A, __m128d __B, const int __imm, > const int __R) >{ > return (__m128d) __builtin_ia32_rndscalesd_round ((__v2df) __A, > (__v2df) __B, __imm, __R); >} ># 8498 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_floor_ps (__m512 __A) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __A, > (0x01 | 0x00), > (__v16sf) __A, -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_floor_pd (__m512d __A) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __A, > (0x01 | 0x00), > (__v8df) __A, -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_ceil_ps (__m512 __A) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __A, > (0x02 | 0x00), > (__v16sf) __A, -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_ceil_pd (__m512d __A) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __A, > (0x02 | 0x00), > (__v8df) __A, -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_floor_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __A, > (0x01 | 0x00), > (__v16sf) __W, __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_floor_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __A, > (0x01 | 0x00), > (__v8df) __W, __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_ceil_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __A, > (0x02 | 0x00), > (__v16sf) __W, __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_ceil_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __A, > (0x02 | 0x00), > (__v8df) __W, __U, > 0x04); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_alignr_epi32 (__m512i __A, __m512i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_alignd512_mask ((__v16si) __A, > (__v16si) __B, __imm, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_alignr_epi32 (__m512i __W, __mmask16 __U, __m512i __A, > __m512i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_alignd512_mask ((__v16si) __A, > (__v16si) __B, __imm, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_alignr_epi32 (__mmask16 __U, __m512i __A, __m512i __B, > const int __imm) >{ > return (__m512i) __builtin_ia32_alignd512_mask ((__v16si) __A, > (__v16si) __B, __imm, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_alignr_epi64 (__m512i __A, __m512i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_alignq512_mask ((__v8di) __A, > (__v8di) __B, __imm, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_alignr_epi64 (__m512i __W, __mmask8 __U, __m512i __A, > __m512i __B, const int __imm) >{ > return (__m512i) __builtin_ia32_alignq512_mask ((__v8di) __A, > (__v8di) __B, __imm, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_alignr_epi64 (__mmask8 __U, __m512i __A, __m512i __B, > const int __imm) >{ > return (__m512i) __builtin_ia32_alignq512_mask ((__v8di) __A, > (__v8di) __B, __imm, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} ># 8677 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpeq_epi32_mask (__m512i __A, __m512i __B) >{ > return (__mmask16) __builtin_ia32_pcmpeqd512_mask ((__v16si) __A, > (__v16si) __B, > (__mmask16) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmpeq_epi32_mask (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__mmask16) __builtin_ia32_pcmpeqd512_mask ((__v16si) __A, > (__v16si) __B, __U); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmpeq_epi64_mask (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__mmask8) __builtin_ia32_pcmpeqq512_mask ((__v8di) __A, > (__v8di) __B, __U); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpeq_epi64_mask (__m512i __A, __m512i __B) >{ > return (__mmask8) __builtin_ia32_pcmpeqq512_mask ((__v8di) __A, > (__v8di) __B, > (__mmask8) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpgt_epi32_mask (__m512i __A, __m512i __B) >{ > return (__mmask16) __builtin_ia32_pcmpgtd512_mask ((__v16si) __A, > (__v16si) __B, > (__mmask16) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmpgt_epi32_mask (__mmask16 __U, __m512i __A, __m512i __B) >{ > return (__mmask16) __builtin_ia32_pcmpgtd512_mask ((__v16si) __A, > (__v16si) __B, __U); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmpgt_epi64_mask (__mmask8 __U, __m512i __A, __m512i __B) >{ > return (__mmask8) __builtin_ia32_pcmpgtq512_mask ((__v8di) __A, > (__v8di) __B, __U); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpgt_epi64_mask (__m512i __A, __m512i __B) >{ > return (__mmask8) __builtin_ia32_pcmpgtq512_mask ((__v8di) __A, > (__v8di) __B, > (__mmask8) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpge_epi32_mask (__m512i __X, __m512i __Y) >{ > return (__mmask16) __builtin_ia32_cmpd512_mask ((__v16si) __X, > (__v16si) __Y, 5, > (__mmask16) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpge_epu32_mask (__m512i __X, __m512i __Y) >{ > return (__mmask16) __builtin_ia32_ucmpd512_mask ((__v16si) __X, > (__v16si) __Y, 5, > (__mmask16) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpge_epi64_mask (__m512i __X, __m512i __Y) >{ > return (__mmask8) __builtin_ia32_cmpq512_mask ((__v8di) __X, > (__v8di) __Y, 5, > (__mmask8) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpge_epu64_mask (__m512i __X, __m512i __Y) >{ > return (__mmask8) __builtin_ia32_ucmpq512_mask ((__v8di) __X, > (__v8di) __Y, 5, > (__mmask8) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmple_epi32_mask (__m512i __X, __m512i __Y) >{ > return (__mmask16) __builtin_ia32_cmpd512_mask ((__v16si) __X, > (__v16si) __Y, 2, > (__mmask16) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmple_epu32_mask (__m512i __X, __m512i __Y) >{ > return (__mmask16) __builtin_ia32_ucmpd512_mask ((__v16si) __X, > (__v16si) __Y, 2, > (__mmask16) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmple_epi64_mask (__m512i __X, __m512i __Y) >{ > return (__mmask8) __builtin_ia32_cmpq512_mask ((__v8di) __X, > (__v8di) __Y, 2, > (__mmask8) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmple_epu64_mask (__m512i __X, __m512i __Y) >{ > return (__mmask8) __builtin_ia32_ucmpq512_mask ((__v8di) __X, > (__v8di) __Y, 2, > (__mmask8) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmplt_epi32_mask (__m512i __X, __m512i __Y) >{ > return (__mmask16) __builtin_ia32_cmpd512_mask ((__v16si) __X, > (__v16si) __Y, 1, > (__mmask16) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmplt_epu32_mask (__m512i __X, __m512i __Y) >{ > return (__mmask16) __builtin_ia32_ucmpd512_mask ((__v16si) __X, > (__v16si) __Y, 1, > (__mmask16) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmplt_epi64_mask (__m512i __X, __m512i __Y) >{ > return (__mmask8) __builtin_ia32_cmpq512_mask ((__v8di) __X, > (__v8di) __Y, 1, > (__mmask8) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmplt_epu64_mask (__m512i __X, __m512i __Y) >{ > return (__mmask8) __builtin_ia32_ucmpq512_mask ((__v8di) __X, > (__v8di) __Y, 1, > (__mmask8) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpneq_epi32_mask (__m512i __X, __m512i __Y) >{ > return (__mmask16) __builtin_ia32_cmpd512_mask ((__v16si) __X, > (__v16si) __Y, 4, > (__mmask16) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpneq_epu32_mask (__m512i __X, __m512i __Y) >{ > return (__mmask16) __builtin_ia32_ucmpd512_mask ((__v16si) __X, > (__v16si) __Y, 4, > (__mmask16) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpneq_epi64_mask (__m512i __X, __m512i __Y) >{ > return (__mmask8) __builtin_ia32_cmpq512_mask ((__v8di) __X, > (__v8di) __Y, 4, > (__mmask8) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmpneq_epu64_mask (__m512i __X, __m512i __Y) >{ > return (__mmask8) __builtin_ia32_ucmpq512_mask ((__v8di) __X, > (__v8di) __Y, 4, > (__mmask8) -1); >} ># 8900 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmp_epi64_mask (__m512i __X, __m512i __Y, const int __P) >{ > return (__mmask8) __builtin_ia32_cmpq512_mask ((__v8di) __X, > (__v8di) __Y, __P, > (__mmask8) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmp_epi32_mask (__m512i __X, __m512i __Y, const int __P) >{ > return (__mmask16) __builtin_ia32_cmpd512_mask ((__v16si) __X, > (__v16si) __Y, __P, > (__mmask16) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmp_epu64_mask (__m512i __X, __m512i __Y, const int __P) >{ > return (__mmask8) __builtin_ia32_ucmpq512_mask ((__v8di) __X, > (__v8di) __Y, __P, > (__mmask8) -1); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmp_epu32_mask (__m512i __X, __m512i __Y, const int __P) >{ > return (__mmask16) __builtin_ia32_ucmpd512_mask ((__v16si) __X, > (__v16si) __Y, __P, > (__mmask16) -1); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmp_round_pd_mask (__m512d __X, __m512d __Y, const int __P, > const int __R) >{ > return (__mmask8) __builtin_ia32_cmppd512_mask ((__v8df) __X, > (__v8df) __Y, __P, > (__mmask8) -1, __R); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmp_round_ps_mask (__m512 __X, __m512 __Y, const int __P, const int __R) >{ > return (__mmask16) __builtin_ia32_cmpps512_mask ((__v16sf) __X, > (__v16sf) __Y, __P, > (__mmask16) -1, __R); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmp_epi64_mask (__mmask8 __U, __m512i __X, __m512i __Y, > const int __P) >{ > return (__mmask8) __builtin_ia32_cmpq512_mask ((__v8di) __X, > (__v8di) __Y, __P, > (__mmask8) __U); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmp_epi32_mask (__mmask16 __U, __m512i __X, __m512i __Y, > const int __P) >{ > return (__mmask16) __builtin_ia32_cmpd512_mask ((__v16si) __X, > (__v16si) __Y, __P, > (__mmask16) __U); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmp_epu64_mask (__mmask8 __U, __m512i __X, __m512i __Y, > const int __P) >{ > return (__mmask8) __builtin_ia32_ucmpq512_mask ((__v8di) __X, > (__v8di) __Y, __P, > (__mmask8) __U); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmp_epu32_mask (__mmask16 __U, __m512i __X, __m512i __Y, > const int __P) >{ > return (__mmask16) __builtin_ia32_ucmpd512_mask ((__v16si) __X, > (__v16si) __Y, __P, > (__mmask16) __U); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmp_round_pd_mask (__mmask8 __U, __m512d __X, __m512d __Y, > const int __P, const int __R) >{ > return (__mmask8) __builtin_ia32_cmppd512_mask ((__v8df) __X, > (__v8df) __Y, __P, > (__mmask8) __U, __R); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmp_round_ps_mask (__mmask16 __U, __m512 __X, __m512 __Y, > const int __P, const int __R) >{ > return (__mmask16) __builtin_ia32_cmpps512_mask ((__v16sf) __X, > (__v16sf) __Y, __P, > (__mmask16) __U, __R); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmp_round_sd_mask (__m128d __X, __m128d __Y, const int __P, const int __R) >{ > return (__mmask8) __builtin_ia32_cmpsd_mask ((__v2df) __X, > (__v2df) __Y, __P, > (__mmask8) -1, __R); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_cmp_round_sd_mask (__mmask8 __M, __m128d __X, __m128d __Y, > const int __P, const int __R) >{ > return (__mmask8) __builtin_ia32_cmpsd_mask ((__v2df) __X, > (__v2df) __Y, __P, > (__mmask8) __M, __R); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmp_round_ss_mask (__m128 __X, __m128 __Y, const int __P, const int __R) >{ > return (__mmask8) __builtin_ia32_cmpss_mask ((__v4sf) __X, > (__v4sf) __Y, __P, > (__mmask8) -1, __R); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_cmp_round_ss_mask (__mmask8 __M, __m128 __X, __m128 __Y, > const int __P, const int __R) >{ > return (__mmask8) __builtin_ia32_cmpss_mask ((__v4sf) __X, > (__v4sf) __Y, __P, > (__mmask8) __M, __R); >} ># 9136 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i32gather_ps (__m512i __index, float const *__addr, int __scale) >{ > __m512 v1_old = _mm512_undefined_ps (); > __mmask16 mask = 0xFFFF; > > return (__m512) __builtin_ia32_gathersiv16sf ((__v16sf) v1_old, > __addr, > (__v16si) __index, > mask, __scale); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i32gather_ps (__m512 v1_old, __mmask16 __mask, > __m512i __index, float const *__addr, int __scale) >{ > return (__m512) __builtin_ia32_gathersiv16sf ((__v16sf) v1_old, > __addr, > (__v16si) __index, > __mask, __scale); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i32gather_pd (__m256i __index, double const *__addr, int __scale) >{ > __m512d v1_old = _mm512_undefined_pd (); > __mmask8 mask = 0xFF; > > return (__m512d) __builtin_ia32_gathersiv8df ((__v8df) v1_old, > __addr, > (__v8si) __index, mask, > __scale); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i32gather_pd (__m512d __v1_old, __mmask8 __mask, > __m256i __index, double const *__addr, int __scale) >{ > return (__m512d) __builtin_ia32_gathersiv8df ((__v8df) __v1_old, > __addr, > (__v8si) __index, > __mask, __scale); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i64gather_ps (__m512i __index, float const *__addr, int __scale) >{ > __m256 v1_old = _mm256_undefined_ps (); > __mmask8 mask = 0xFF; > > return (__m256) __builtin_ia32_gatherdiv16sf ((__v8sf) v1_old, > __addr, > (__v8di) __index, mask, > __scale); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i64gather_ps (__m256 __v1_old, __mmask8 __mask, > __m512i __index, float const *__addr, int __scale) >{ > return (__m256) __builtin_ia32_gatherdiv16sf ((__v8sf) __v1_old, > __addr, > (__v8di) __index, > __mask, __scale); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i64gather_pd (__m512i __index, double const *__addr, int __scale) >{ > __m512d v1_old = _mm512_undefined_pd (); > __mmask8 mask = 0xFF; > > return (__m512d) __builtin_ia32_gatherdiv8df ((__v8df) v1_old, > __addr, > (__v8di) __index, mask, > __scale); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i64gather_pd (__m512d __v1_old, __mmask8 __mask, > __m512i __index, double const *__addr, int __scale) >{ > return (__m512d) __builtin_ia32_gatherdiv8df ((__v8df) __v1_old, > __addr, > (__v8di) __index, > __mask, __scale); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i32gather_epi32 (__m512i __index, int const *__addr, int __scale) >{ > __m512i v1_old = _mm512_undefined_si512 (); > __mmask16 mask = 0xFFFF; > > return (__m512i) __builtin_ia32_gathersiv16si ((__v16si) v1_old, > __addr, > (__v16si) __index, > mask, __scale); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i32gather_epi32 (__m512i __v1_old, __mmask16 __mask, > __m512i __index, int const *__addr, int __scale) >{ > return (__m512i) __builtin_ia32_gathersiv16si ((__v16si) __v1_old, > __addr, > (__v16si) __index, > __mask, __scale); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i32gather_epi64 (__m256i __index, long long const *__addr, int __scale) >{ > __m512i v1_old = _mm512_undefined_si512 (); > __mmask8 mask = 0xFF; > > return (__m512i) __builtin_ia32_gathersiv8di ((__v8di) v1_old, > __addr, > (__v8si) __index, mask, > __scale); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i32gather_epi64 (__m512i __v1_old, __mmask8 __mask, > __m256i __index, long long const *__addr, > int __scale) >{ > return (__m512i) __builtin_ia32_gathersiv8di ((__v8di) __v1_old, > __addr, > (__v8si) __index, > __mask, __scale); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i64gather_epi32 (__m512i __index, int const *__addr, int __scale) >{ > __m256i v1_old = _mm256_undefined_si256 (); > __mmask8 mask = 0xFF; > > return (__m256i) __builtin_ia32_gatherdiv16si ((__v8si) v1_old, > __addr, > (__v8di) __index, > mask, __scale); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i64gather_epi32 (__m256i __v1_old, __mmask8 __mask, > __m512i __index, int const *__addr, int __scale) >{ > return (__m256i) __builtin_ia32_gatherdiv16si ((__v8si) __v1_old, > __addr, > (__v8di) __index, > __mask, __scale); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i64gather_epi64 (__m512i __index, long long const *__addr, int __scale) >{ > __m512i v1_old = _mm512_undefined_si512 (); > __mmask8 mask = 0xFF; > > return (__m512i) __builtin_ia32_gatherdiv8di ((__v8di) v1_old, > __addr, > (__v8di) __index, mask, > __scale); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i64gather_epi64 (__m512i __v1_old, __mmask8 __mask, > __m512i __index, long long const *__addr, > int __scale) >{ > return (__m512i) __builtin_ia32_gatherdiv8di ((__v8di) __v1_old, > __addr, > (__v8di) __index, > __mask, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i32scatter_ps (float *__addr, __m512i __index, __m512 __v1, int __scale) >{ > __builtin_ia32_scattersiv16sf (__addr, (__mmask16) 0xFFFF, > (__v16si) __index, (__v16sf) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i32scatter_ps (float *__addr, __mmask16 __mask, > __m512i __index, __m512 __v1, int __scale) >{ > __builtin_ia32_scattersiv16sf (__addr, __mask, (__v16si) __index, > (__v16sf) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i32scatter_pd (double *__addr, __m256i __index, __m512d __v1, > int __scale) >{ > __builtin_ia32_scattersiv8df (__addr, (__mmask8) 0xFF, > (__v8si) __index, (__v8df) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i32scatter_pd (double *__addr, __mmask8 __mask, > __m256i __index, __m512d __v1, int __scale) >{ > __builtin_ia32_scattersiv8df (__addr, __mask, (__v8si) __index, > (__v8df) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i64scatter_ps (float *__addr, __m512i __index, __m256 __v1, int __scale) >{ > __builtin_ia32_scatterdiv16sf (__addr, (__mmask8) 0xFF, > (__v8di) __index, (__v8sf) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i64scatter_ps (float *__addr, __mmask8 __mask, > __m512i __index, __m256 __v1, int __scale) >{ > __builtin_ia32_scatterdiv16sf (__addr, __mask, (__v8di) __index, > (__v8sf) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i64scatter_pd (double *__addr, __m512i __index, __m512d __v1, > int __scale) >{ > __builtin_ia32_scatterdiv8df (__addr, (__mmask8) 0xFF, > (__v8di) __index, (__v8df) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i64scatter_pd (double *__addr, __mmask8 __mask, > __m512i __index, __m512d __v1, int __scale) >{ > __builtin_ia32_scatterdiv8df (__addr, __mask, (__v8di) __index, > (__v8df) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i32scatter_epi32 (int *__addr, __m512i __index, > __m512i __v1, int __scale) >{ > __builtin_ia32_scattersiv16si (__addr, (__mmask16) 0xFFFF, > (__v16si) __index, (__v16si) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i32scatter_epi32 (int *__addr, __mmask16 __mask, > __m512i __index, __m512i __v1, int __scale) >{ > __builtin_ia32_scattersiv16si (__addr, __mask, (__v16si) __index, > (__v16si) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i32scatter_epi64 (long long *__addr, __m256i __index, > __m512i __v1, int __scale) >{ > __builtin_ia32_scattersiv8di (__addr, (__mmask8) 0xFF, > (__v8si) __index, (__v8di) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i32scatter_epi64 (long long *__addr, __mmask8 __mask, > __m256i __index, __m512i __v1, int __scale) >{ > __builtin_ia32_scattersiv8di (__addr, __mask, (__v8si) __index, > (__v8di) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i64scatter_epi32 (int *__addr, __m512i __index, > __m256i __v1, int __scale) >{ > __builtin_ia32_scatterdiv16si (__addr, (__mmask8) 0xFF, > (__v8di) __index, (__v8si) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i64scatter_epi32 (int *__addr, __mmask8 __mask, > __m512i __index, __m256i __v1, int __scale) >{ > __builtin_ia32_scatterdiv16si (__addr, __mask, (__v8di) __index, > (__v8si) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_i64scatter_epi64 (long long *__addr, __m512i __index, > __m512i __v1, int __scale) >{ > __builtin_ia32_scatterdiv8di (__addr, (__mmask8) 0xFF, > (__v8di) __index, (__v8di) __v1, __scale); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_i64scatter_epi64 (long long *__addr, __mmask8 __mask, > __m512i __index, __m512i __v1, int __scale) >{ > __builtin_ia32_scatterdiv8di (__addr, __mask, (__v8di) __index, > (__v8di) __v1, __scale); >} ># 9649 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_compress_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_compressdf512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_compress_pd (__mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_compressdf512_mask ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_compressstoreu_pd (void *__P, __mmask8 __U, __m512d __A) >{ > __builtin_ia32_compressstoredf512_mask ((__v8df *) __P, (__v8df) __A, > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_compress_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_compresssf512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_compress_ps (__mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_compresssf512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_compressstoreu_ps (void *__P, __mmask16 __U, __m512 __A) >{ > __builtin_ia32_compressstoresf512_mask ((__v16sf *) __P, (__v16sf) __A, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_compress_epi64 (__m512i __W, __mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_compressdi512_mask ((__v8di) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_compress_epi64 (__mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_compressdi512_mask ((__v8di) __A, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_compressstoreu_epi64 (void *__P, __mmask8 __U, __m512i __A) >{ > __builtin_ia32_compressstoredi512_mask ((__v8di *) __P, (__v8di) __A, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_compress_epi32 (__m512i __W, __mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_compresssi512_mask ((__v16si) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_compress_epi32 (__mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_compresssi512_mask ((__v16si) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_compressstoreu_epi32 (void *__P, __mmask16 __U, __m512i __A) >{ > __builtin_ia32_compressstoresi512_mask ((__v16si *) __P, (__v16si) __A, > (__mmask16) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_expand_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_expanddf512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_expand_pd (__mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_expanddf512_maskz ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_expandloadu_pd (__m512d __W, __mmask8 __U, void const *__P) >{ > return (__m512d) __builtin_ia32_expandloaddf512_mask ((const __v8df *) __P, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_expandloadu_pd (__mmask8 __U, void const *__P) >{ > return (__m512d) __builtin_ia32_expandloaddf512_maskz ((const __v8df *) __P, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_expand_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_expandsf512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_expand_ps (__mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_expandsf512_maskz ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_expandloadu_ps (__m512 __W, __mmask16 __U, void const *__P) >{ > return (__m512) __builtin_ia32_expandloadsf512_mask ((const __v16sf *) __P, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_expandloadu_ps (__mmask16 __U, void const *__P) >{ > return (__m512) __builtin_ia32_expandloadsf512_maskz ((const __v16sf *) __P, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_expand_epi64 (__m512i __W, __mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_expanddi512_mask ((__v8di) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_expand_epi64 (__mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_expanddi512_maskz ((__v8di) __A, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_expandloadu_epi64 (__m512i __W, __mmask8 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_expandloaddi512_mask ((const __v8di *) __P, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_expandloadu_epi64 (__mmask8 __U, void const *__P) >{ > return (__m512i) > __builtin_ia32_expandloaddi512_maskz ((const __v8di *) __P, > (__v8di) > _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_expand_epi32 (__m512i __W, __mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_expandsi512_mask ((__v16si) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_expand_epi32 (__mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_expandsi512_maskz ((__v16si) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_expandloadu_epi32 (__m512i __W, __mmask16 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_expandloadsi512_mask ((const __v16si *) __P, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_expandloadu_epi32 (__mmask16 __U, void const *__P) >{ > return (__m512i) __builtin_ia32_expandloadsi512_maskz ((const __v16si *) __P, > (__v16si) > _mm512_setzero_si512 > (), (__mmask16) __U); >} > > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_kand (__mmask16 __A, __mmask16 __B) >{ > return (__mmask16) __builtin_ia32_kandhi ((__mmask16) __A, (__mmask16) __B); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_kandn (__mmask16 __A, __mmask16 __B) >{ > return (__mmask16) __builtin_ia32_kandnhi ((__mmask16) __A, (__mmask16) __B); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_kor (__mmask16 __A, __mmask16 __B) >{ > return (__mmask16) __builtin_ia32_korhi ((__mmask16) __A, (__mmask16) __B); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_kortestz (__mmask16 __A, __mmask16 __B) >{ > return (__mmask16) __builtin_ia32_kortestzhi ((__mmask16) __A, > (__mmask16) __B); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_kortestc (__mmask16 __A, __mmask16 __B) >{ > return (__mmask16) __builtin_ia32_kortestchi ((__mmask16) __A, > (__mmask16) __B); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_kxnor (__mmask16 __A, __mmask16 __B) >{ > return (__mmask16) __builtin_ia32_kxnorhi ((__mmask16) __A, (__mmask16) __B); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_kxor (__mmask16 __A, __mmask16 __B) >{ > return (__mmask16) __builtin_ia32_kxorhi ((__mmask16) __A, (__mmask16) __B); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_knot (__mmask16 __A) >{ > return (__mmask16) __builtin_ia32_knothi ((__mmask16) __A); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_kunpackb (__mmask16 __A, __mmask16 __B) >{ > return (__mmask16) __builtin_ia32_kunpckhi ((__mmask16) __A, (__mmask16) __B); >} > > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_inserti32x4 (__mmask16 __B, __m512i __C, __m128i __D, > const int __imm) >{ > return (__m512i) __builtin_ia32_inserti32x4_mask ((__v16si) __C, > (__v4si) __D, > __imm, > (__v16si) > _mm512_setzero_si512 (), > __B); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_insertf32x4 (__mmask16 __B, __m512 __C, __m128 __D, > const int __imm) >{ > return (__m512) __builtin_ia32_insertf32x4_mask ((__v16sf) __C, > (__v4sf) __D, > __imm, > (__v16sf) > _mm512_setzero_ps (), __B); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_inserti32x4 (__m512i __A, __mmask16 __B, __m512i __C, > __m128i __D, const int __imm) >{ > return (__m512i) __builtin_ia32_inserti32x4_mask ((__v16si) __C, > (__v4si) __D, > __imm, > (__v16si) __A, > __B); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_insertf32x4 (__m512 __A, __mmask16 __B, __m512 __C, > __m128 __D, const int __imm) >{ > return (__m512) __builtin_ia32_insertf32x4_mask ((__v16sf) __C, > (__v4sf) __D, > __imm, > (__v16sf) __A, __B); >} ># 10046 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_max_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxsq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_max_epi64 (__mmask8 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxsq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_max_epi64 (__m512i __W, __mmask8 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxsq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_min_epi64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminsq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_min_epi64 (__m512i __W, __mmask8 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminsq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_min_epi64 (__mmask8 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminsq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_max_epu64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxuq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_max_epu64 (__mmask8 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxuq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_max_epu64 (__m512i __W, __mmask8 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxuq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_min_epu64 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminuq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_undefined_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_min_epu64 (__m512i __W, __mmask8 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminuq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_min_epu64 (__mmask8 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminuq512_mask ((__v8di) __A, > (__v8di) __B, > (__v8di) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_max_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxsd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_max_epi32 (__mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxsd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_max_epi32 (__m512i __W, __mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxsd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_min_epi32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminsd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_min_epi32 (__mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminsd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_min_epi32 (__m512i __W, __mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminsd512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_max_epu32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxud512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_max_epu32 (__mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxud512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_max_epu32 (__m512i __W, __mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pmaxud512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_min_epu32 (__m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminud512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_min_epu32 (__mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminud512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) > _mm512_setzero_si512 (), > __M); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_min_epu32 (__m512i __W, __mmask16 __M, __m512i __A, __m512i __B) >{ > return (__m512i) __builtin_ia32_pminud512_mask ((__v16si) __A, > (__v16si) __B, > (__v16si) __W, __M); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_unpacklo_ps (__m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_unpcklps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_unpacklo_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_unpcklps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_unpacklo_ps (__mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_unpcklps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U); >} > > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_round_sd (__m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_maxsd_round ((__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_max_round_ss (__m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_maxss_round ((__v4sf) __A, > (__v4sf) __B, > __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_round_sd (__m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_minsd_round ((__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_min_round_ss (__m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_minss_round ((__v4sf) __A, > (__v4sf) __B, > __R); >} ># 10377 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_blend_pd (__mmask8 __U, __m512d __A, __m512d __W) >{ > return (__m512d) __builtin_ia32_blendmpd_512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_blend_ps (__mmask16 __U, __m512 __A, __m512 __W) >{ > return (__m512) __builtin_ia32_blendmps_512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_blend_epi64 (__mmask8 __U, __m512i __A, __m512i __W) >{ > return (__m512i) __builtin_ia32_blendmq_512_mask ((__v8di) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_blend_epi32 (__mmask16 __U, __m512i __A, __m512i __W) >{ > return (__m512i) __builtin_ia32_blendmd_512_mask ((__v16si) __A, > (__v16si) __W, > (__mmask16) __U); >} > > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmadd_round_sd (__m128d __W, __m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_vfmaddsd3_round ((__v2df) __W, > (__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmadd_round_ss (__m128 __W, __m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_vfmaddss3_round ((__v4sf) __W, > (__v4sf) __A, > (__v4sf) __B, > __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmsub_round_sd (__m128d __W, __m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_vfmaddsd3_round ((__v2df) __W, > (__v2df) __A, > -(__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmsub_round_ss (__m128 __W, __m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_vfmaddss3_round ((__v4sf) __W, > (__v4sf) __A, > -(__v4sf) __B, > __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmadd_round_sd (__m128d __W, __m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_vfmaddsd3_round ((__v2df) __W, > -(__v2df) __A, > (__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmadd_round_ss (__m128 __W, __m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_vfmaddss3_round ((__v4sf) __W, > -(__v4sf) __A, > (__v4sf) __B, > __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmsub_round_sd (__m128d __W, __m128d __A, __m128d __B, const int __R) >{ > return (__m128d) __builtin_ia32_vfmaddsd3_round ((__v2df) __W, > -(__v2df) __A, > -(__v2df) __B, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmsub_round_ss (__m128 __W, __m128 __A, __m128 __B, const int __R) >{ > return (__m128) __builtin_ia32_vfmaddss3_round ((__v4sf) __W, > -(__v4sf) __A, > -(__v4sf) __B, > __R); >} ># 10520 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comi_round_ss (__m128 __A, __m128 __B, const int __P, const int __R) >{ > return __builtin_ia32_vcomiss ((__v4sf) __A, (__v4sf) __B, __P, __R); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comi_round_sd (__m128d __A, __m128d __B, const int __P, const int __R) >{ > return __builtin_ia32_vcomisd ((__v2df) __A, (__v2df) __B, __P, __R); >} > > > > > > > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sqrt_pd (__m512d __A) >{ > return (__m512d) __builtin_ia32_sqrtpd512_mask ((__v8df) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sqrt_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_sqrtpd512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sqrt_pd (__mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_sqrtpd512_mask ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sqrt_ps (__m512 __A) >{ > return (__m512) __builtin_ia32_sqrtps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sqrt_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_sqrtps512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sqrt_ps (__mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_sqrtps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_add_pd (__m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_addpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_add_pd (__m512d __W, __mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_addpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_add_pd (__mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_addpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_add_ps (__m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_addps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_add_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_addps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_add_ps (__mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_addps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sub_pd (__m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_subpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sub_pd (__m512d __W, __mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_subpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sub_pd (__mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_subpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_sub_ps (__m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_subps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_sub_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_subps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_sub_ps (__mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_subps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mul_pd (__m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_mulpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mul_pd (__m512d __W, __mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_mulpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mul_pd (__mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_mulpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mul_ps (__m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_mulps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_mul_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_mulps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_mul_ps (__mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_mulps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_div_pd (__m512d __M, __m512d __V) >{ > return (__m512d) __builtin_ia32_divpd512_mask ((__v8df) __M, > (__v8df) __V, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_div_pd (__m512d __W, __mmask8 __U, __m512d __M, __m512d __V) >{ > return (__m512d) __builtin_ia32_divpd512_mask ((__v8df) __M, > (__v8df) __V, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_div_pd (__mmask8 __U, __m512d __M, __m512d __V) >{ > return (__m512d) __builtin_ia32_divpd512_mask ((__v8df) __M, > (__v8df) __V, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_div_ps (__m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_divps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_div_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_divps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_div_ps (__mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_divps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_max_pd (__m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_maxpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_max_pd (__m512d __W, __mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_maxpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_max_pd (__mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_maxpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_max_ps (__m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_maxps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_max_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_maxps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_max_ps (__mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_maxps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_min_pd (__m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_minpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_min_pd (__m512d __W, __mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_minpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_min_pd (__mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_minpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_min_ps (__m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_minps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_min_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_minps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_min_ps (__mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_minps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_scalef_pd (__m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_scalefpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_scalef_pd (__m512d __W, __mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_scalefpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_scalef_pd (__mmask8 __U, __m512d __A, __m512d __B) >{ > return (__m512d) __builtin_ia32_scalefpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_scalef_ps (__m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_scalefps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_scalef_ps (__m512 __W, __mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_scalefps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_scalef_ps (__mmask16 __U, __m512 __A, __m512 __B) >{ > return (__m512) __builtin_ia32_scalefps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_scalef_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_scalefsd_round ((__v2df) __A, > (__v2df) __B, > 0x04); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_scalef_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_scalefss_round ((__v4sf) __A, > (__v4sf) __B, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmadd_pd (__m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmadd_pd (__m512d __A, __mmask8 __U, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmadd_pd (__m512d __A, __m512d __B, __m512d __C, __mmask8 __U) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmadd_pd (__mmask8 __U, __m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_maskz ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmadd_ps (__m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmadd_ps (__m512 __A, __mmask16 __U, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmadd_ps (__m512 __A, __m512 __B, __m512 __C, __mmask16 __U) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmadd_ps (__mmask16 __U, __m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_maskz ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmsub_pd (__m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmsub_pd (__m512d __A, __mmask8 __U, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmsub_pd (__m512d __A, __m512d __B, __m512d __C, __mmask8 __U) >{ > return (__m512d) __builtin_ia32_vfmsubpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmsub_pd (__mmask8 __U, __m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_maskz ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmsub_ps (__m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmsub_ps (__m512 __A, __mmask16 __U, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmsub_ps (__m512 __A, __m512 __B, __m512 __C, __mmask16 __U) >{ > return (__m512) __builtin_ia32_vfmsubps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmsub_ps (__mmask16 __U, __m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_maskz ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmaddsub_pd (__m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmaddsub_pd (__m512d __A, __mmask8 __U, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmaddsub_pd (__m512d __A, __m512d __B, __m512d __C, __mmask8 __U) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmaddsub_pd (__mmask8 __U, __m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_maskz ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmaddsub_ps (__m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmaddsub_ps (__m512 __A, __mmask16 __U, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmaddsub_ps (__m512 __A, __m512 __B, __m512 __C, __mmask16 __U) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmaddsub_ps (__mmask16 __U, __m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_maskz ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmsubadd_pd (__m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmsubadd_pd (__m512d __A, __mmask8 __U, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_mask ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmsubadd_pd (__m512d __A, __m512d __B, __m512d __C, __mmask8 __U) >{ > return (__m512d) __builtin_ia32_vfmsubaddpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmsubadd_pd (__mmask8 __U, __m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddsubpd512_maskz ((__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fmsubadd_ps (__m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fmsubadd_ps (__m512 __A, __mmask16 __U, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fmsubadd_ps (__m512 __A, __m512 __B, __m512 __C, __mmask16 __U) >{ > return (__m512) __builtin_ia32_vfmsubaddps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fmsubadd_ps (__mmask16 __U, __m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddsubps512_maskz ((__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fnmadd_pd (__m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask (-(__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fnmadd_pd (__m512d __A, __mmask8 __U, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfnmaddpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fnmadd_pd (__m512d __A, __m512d __B, __m512d __C, __mmask8 __U) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask3 (-(__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fnmadd_pd (__mmask8 __U, __m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_maskz (-(__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fnmadd_ps (__m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask (-(__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fnmadd_ps (__m512 __A, __mmask16 __U, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfnmaddps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fnmadd_ps (__m512 __A, __m512 __B, __m512 __C, __mmask16 __U) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask3 (-(__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fnmadd_ps (__mmask16 __U, __m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_maskz (-(__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fnmsub_pd (__m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_mask (-(__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fnmsub_pd (__m512d __A, __mmask8 __U, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfnmsubpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fnmsub_pd (__m512d __A, __m512d __B, __m512d __C, __mmask8 __U) >{ > return (__m512d) __builtin_ia32_vfnmsubpd512_mask3 ((__v8df) __A, > (__v8df) __B, > (__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fnmsub_pd (__mmask8 __U, __m512d __A, __m512d __B, __m512d __C) >{ > return (__m512d) __builtin_ia32_vfmaddpd512_maskz (-(__v8df) __A, > (__v8df) __B, > -(__v8df) __C, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fnmsub_ps (__m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_mask (-(__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fnmsub_ps (__m512 __A, __mmask16 __U, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfnmsubps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask3_fnmsub_ps (__m512 __A, __m512 __B, __m512 __C, __mmask16 __U) >{ > return (__m512) __builtin_ia32_vfnmsubps512_mask3 ((__v16sf) __A, > (__v16sf) __B, > (__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fnmsub_ps (__mmask16 __U, __m512 __A, __m512 __B, __m512 __C) >{ > return (__m512) __builtin_ia32_vfmaddps512_maskz (-(__v16sf) __A, > (__v16sf) __B, > -(__v16sf) __C, > (__mmask16) __U, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvttpd_epi32 (__m512d __A) >{ > return (__m256i) __builtin_ia32_cvttpd2dq512_mask ((__v8df) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvttpd_epi32 (__m256i __W, __mmask8 __U, __m512d __A) >{ > return (__m256i) __builtin_ia32_cvttpd2dq512_mask ((__v8df) __A, > (__v8si) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvttpd_epi32 (__mmask8 __U, __m512d __A) >{ > return (__m256i) __builtin_ia32_cvttpd2dq512_mask ((__v8df) __A, > (__v8si) > _mm256_setzero_si256 (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvttpd_epu32 (__m512d __A) >{ > return (__m256i) __builtin_ia32_cvttpd2udq512_mask ((__v8df) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvttpd_epu32 (__m256i __W, __mmask8 __U, __m512d __A) >{ > return (__m256i) __builtin_ia32_cvttpd2udq512_mask ((__v8df) __A, > (__v8si) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvttpd_epu32 (__mmask8 __U, __m512d __A) >{ > return (__m256i) __builtin_ia32_cvttpd2udq512_mask ((__v8df) __A, > (__v8si) > _mm256_setzero_si256 (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtpd_epi32 (__m512d __A) >{ > return (__m256i) __builtin_ia32_cvtpd2dq512_mask ((__v8df) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtpd_epi32 (__m256i __W, __mmask8 __U, __m512d __A) >{ > return (__m256i) __builtin_ia32_cvtpd2dq512_mask ((__v8df) __A, > (__v8si) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtpd_epi32 (__mmask8 __U, __m512d __A) >{ > return (__m256i) __builtin_ia32_cvtpd2dq512_mask ((__v8df) __A, > (__v8si) > _mm256_setzero_si256 (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtpd_epu32 (__m512d __A) >{ > return (__m256i) __builtin_ia32_cvtpd2udq512_mask ((__v8df) __A, > (__v8si) > _mm256_undefined_si256 (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtpd_epu32 (__m256i __W, __mmask8 __U, __m512d __A) >{ > return (__m256i) __builtin_ia32_cvtpd2udq512_mask ((__v8df) __A, > (__v8si) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m256i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtpd_epu32 (__mmask8 __U, __m512d __A) >{ > return (__m256i) __builtin_ia32_cvtpd2udq512_mask ((__v8df) __A, > (__v8si) > _mm256_setzero_si256 (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvttps_epi32 (__m512 __A) >{ > return (__m512i) __builtin_ia32_cvttps2dq512_mask ((__v16sf) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvttps_epi32 (__m512i __W, __mmask16 __U, __m512 __A) >{ > return (__m512i) __builtin_ia32_cvttps2dq512_mask ((__v16sf) __A, > (__v16si) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvttps_epi32 (__mmask16 __U, __m512 __A) >{ > return (__m512i) __builtin_ia32_cvttps2dq512_mask ((__v16sf) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvttps_epu32 (__m512 __A) >{ > return (__m512i) __builtin_ia32_cvttps2udq512_mask ((__v16sf) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvttps_epu32 (__m512i __W, __mmask16 __U, __m512 __A) >{ > return (__m512i) __builtin_ia32_cvttps2udq512_mask ((__v16sf) __A, > (__v16si) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvttps_epu32 (__mmask16 __U, __m512 __A) >{ > return (__m512i) __builtin_ia32_cvttps2udq512_mask ((__v16sf) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtps_epi32 (__m512 __A) >{ > return (__m512i) __builtin_ia32_cvtps2dq512_mask ((__v16sf) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtps_epi32 (__m512i __W, __mmask16 __U, __m512 __A) >{ > return (__m512i) __builtin_ia32_cvtps2dq512_mask ((__v16sf) __A, > (__v16si) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtps_epi32 (__mmask16 __U, __m512 __A) >{ > return (__m512i) __builtin_ia32_cvtps2dq512_mask ((__v16sf) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtps_epu32 (__m512 __A) >{ > return (__m512i) __builtin_ia32_cvtps2udq512_mask ((__v16sf) __A, > (__v16si) > _mm512_undefined_si512 (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtps_epu32 (__m512i __W, __mmask16 __U, __m512 __A) >{ > return (__m512i) __builtin_ia32_cvtps2udq512_mask ((__v16sf) __A, > (__v16si) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtps_epu32 (__mmask16 __U, __m512 __A) >{ > return (__m512i) __builtin_ia32_cvtps2udq512_mask ((__v16sf) __A, > (__v16si) > _mm512_setzero_si512 (), > (__mmask16) __U, > 0x04); >} > > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtu64_ss (__m128 __A, unsigned long long __B) >{ > return (__m128) __builtin_ia32_cvtusi2ss64 ((__v4sf) __A, __B, > 0x04); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtu64_sd (__m128d __A, unsigned long long __B) >{ > return (__m128d) __builtin_ia32_cvtusi2sd64 ((__v2df) __A, __B, > 0x04); >} > > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtu32_ss (__m128 __A, unsigned __B) >{ > return (__m128) __builtin_ia32_cvtusi2ss32 ((__v4sf) __A, __B, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepi32_ps (__m512i __A) >{ > return (__m512) __builtin_ia32_cvtdq2ps512_mask ((__v16si) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepi32_ps (__m512 __W, __mmask16 __U, __m512i __A) >{ > return (__m512) __builtin_ia32_cvtdq2ps512_mask ((__v16si) __A, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepi32_ps (__mmask16 __U, __m512i __A) >{ > return (__m512) __builtin_ia32_cvtdq2ps512_mask ((__v16si) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtepu32_ps (__m512i __A) >{ > return (__m512) __builtin_ia32_cvtudq2ps512_mask ((__v16si) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtepu32_ps (__m512 __W, __mmask16 __U, __m512i __A) >{ > return (__m512) __builtin_ia32_cvtudq2ps512_mask ((__v16si) __A, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtepu32_ps (__mmask16 __U, __m512i __A) >{ > return (__m512) __builtin_ia32_cvtudq2ps512_mask ((__v16si) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fixupimm_pd (__m512d __A, __m512d __B, __m512i __C, const int __imm) >{ > return (__m512d) __builtin_ia32_fixupimmpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8di) __C, > __imm, > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fixupimm_pd (__m512d __A, __mmask8 __U, __m512d __B, > __m512i __C, const int __imm) >{ > return (__m512d) __builtin_ia32_fixupimmpd512_mask ((__v8df) __A, > (__v8df) __B, > (__v8di) __C, > __imm, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fixupimm_pd (__mmask8 __U, __m512d __A, __m512d __B, > __m512i __C, const int __imm) >{ > return (__m512d) __builtin_ia32_fixupimmpd512_maskz ((__v8df) __A, > (__v8df) __B, > (__v8di) __C, > __imm, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_fixupimm_ps (__m512 __A, __m512 __B, __m512i __C, const int __imm) >{ > return (__m512) __builtin_ia32_fixupimmps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16si) __C, > __imm, > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_fixupimm_ps (__m512 __A, __mmask16 __U, __m512 __B, > __m512i __C, const int __imm) >{ > return (__m512) __builtin_ia32_fixupimmps512_mask ((__v16sf) __A, > (__v16sf) __B, > (__v16si) __C, > __imm, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_fixupimm_ps (__mmask16 __U, __m512 __A, __m512 __B, > __m512i __C, const int __imm) >{ > return (__m512) __builtin_ia32_fixupimmps512_maskz ((__v16sf) __A, > (__v16sf) __B, > (__v16si) __C, > __imm, > (__mmask16) __U, > 0x04); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fixupimm_sd (__m128d __A, __m128d __B, __m128i __C, const int __imm) >{ > return (__m128d) __builtin_ia32_fixupimmsd_mask ((__v2df) __A, > (__v2df) __B, > (__v2di) __C, __imm, > (__mmask8) -1, > 0x04); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_fixupimm_sd (__m128d __A, __mmask8 __U, __m128d __B, > __m128i __C, const int __imm) >{ > return (__m128d) __builtin_ia32_fixupimmsd_mask ((__v2df) __A, > (__v2df) __B, > (__v2di) __C, __imm, > (__mmask8) __U, > 0x04); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskz_fixupimm_sd (__mmask8 __U, __m128d __A, __m128d __B, > __m128i __C, const int __imm) >{ > return (__m128d) __builtin_ia32_fixupimmsd_maskz ((__v2df) __A, > (__v2df) __B, > (__v2di) __C, > __imm, > (__mmask8) __U, > 0x04); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fixupimm_ss (__m128 __A, __m128 __B, __m128i __C, const int __imm) >{ > return (__m128) __builtin_ia32_fixupimmss_mask ((__v4sf) __A, > (__v4sf) __B, > (__v4si) __C, __imm, > (__mmask8) -1, > 0x04); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_fixupimm_ss (__m128 __A, __mmask8 __U, __m128 __B, > __m128i __C, const int __imm) >{ > return (__m128) __builtin_ia32_fixupimmss_mask ((__v4sf) __A, > (__v4sf) __B, > (__v4si) __C, __imm, > (__mmask8) __U, > 0x04); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maskz_fixupimm_ss (__mmask8 __U, __m128 __A, __m128 __B, > __m128i __C, const int __imm) >{ > return (__m128) __builtin_ia32_fixupimmss_maskz ((__v4sf) __A, > (__v4sf) __B, > (__v4si) __C, __imm, > (__mmask8) __U, > 0x04); >} ># 12196 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline unsigned long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtss_u64 (__m128 __A) >{ > return (unsigned long long) __builtin_ia32_vcvtss2usi64 ((__v4sf) > __A, > 0x04); >} > >extern __inline unsigned long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttss_u64 (__m128 __A) >{ > return (unsigned long long) __builtin_ia32_vcvttss2usi64 ((__v4sf) > __A, > 0x04); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttss_i64 (__m128 __A) >{ > return (long long) __builtin_ia32_vcvttss2si64 ((__v4sf) __A, > 0x04); >} > > >extern __inline unsigned >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtss_u32 (__m128 __A) >{ > return (unsigned) __builtin_ia32_vcvtss2usi32 ((__v4sf) __A, > 0x04); >} > >extern __inline unsigned >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttss_u32 (__m128 __A) >{ > return (unsigned) __builtin_ia32_vcvttss2usi32 ((__v4sf) __A, > 0x04); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttss_i32 (__m128 __A) >{ > return (int) __builtin_ia32_vcvttss2si32 ((__v4sf) __A, > 0x04); >} > > >extern __inline unsigned long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsd_u64 (__m128d __A) >{ > return (unsigned long long) __builtin_ia32_vcvtsd2usi64 ((__v2df) > __A, > 0x04); >} > >extern __inline unsigned long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttsd_u64 (__m128d __A) >{ > return (unsigned long long) __builtin_ia32_vcvttsd2usi64 ((__v2df) > __A, > 0x04); >} > >extern __inline long long >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttsd_i64 (__m128d __A) >{ > return (long long) __builtin_ia32_vcvttsd2si64 ((__v2df) __A, > 0x04); >} > > >extern __inline unsigned >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtsd_u32 (__m128d __A) >{ > return (unsigned) __builtin_ia32_vcvtsd2usi32 ((__v2df) __A, > 0x04); >} > >extern __inline unsigned >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttsd_u32 (__m128d __A) >{ > return (unsigned) __builtin_ia32_vcvttsd2usi32 ((__v2df) __A, > 0x04); >} > >extern __inline int >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvttsd_i32 (__m128d __A) >{ > return (int) __builtin_ia32_vcvttsd2si32 ((__v2df) __A, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtps_pd (__m256 __A) >{ > return (__m512d) __builtin_ia32_cvtps2pd512_mask ((__v8sf) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtps_pd (__m512d __W, __mmask8 __U, __m256 __A) >{ > return (__m512d) __builtin_ia32_cvtps2pd512_mask ((__v8sf) __A, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtps_pd (__mmask8 __U, __m256 __A) >{ > return (__m512d) __builtin_ia32_cvtps2pd512_mask ((__v8sf) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtph_ps (__m256i __A) >{ > return (__m512) __builtin_ia32_vcvtph2ps512_mask ((__v16hi) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtph_ps (__m512 __W, __mmask16 __U, __m256i __A) >{ > return (__m512) __builtin_ia32_vcvtph2ps512_mask ((__v16hi) __A, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtph_ps (__mmask16 __U, __m256i __A) >{ > return (__m512) __builtin_ia32_vcvtph2ps512_mask ((__v16hi) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cvtpd_ps (__m512d __A) >{ > return (__m256) __builtin_ia32_cvtpd2ps512_mask ((__v8df) __A, > (__v8sf) > _mm256_undefined_ps (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cvtpd_ps (__m256 __W, __mmask8 __U, __m512d __A) >{ > return (__m256) __builtin_ia32_cvtpd2ps512_mask ((__v8df) __A, > (__v8sf) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m256 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_cvtpd_ps (__mmask8 __U, __m512d __A) >{ > return (__m256) __builtin_ia32_cvtpd2ps512_mask ((__v8df) __A, > (__v8sf) > _mm256_setzero_ps (), > (__mmask8) __U, > 0x04); >} > > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_getexp_ps (__m512 __A) >{ > return (__m512) __builtin_ia32_getexpps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_getexp_ps (__m512 __W, __mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_getexpps512_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_getexp_ps (__mmask16 __U, __m512 __A) >{ > return (__m512) __builtin_ia32_getexpps512_mask ((__v16sf) __A, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_getexp_pd (__m512d __A) >{ > return (__m512d) __builtin_ia32_getexppd512_mask ((__v8df) __A, > (__v8df) > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_getexp_pd (__m512d __W, __mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_getexppd512_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_getexp_pd (__mmask8 __U, __m512d __A) >{ > return (__m512d) __builtin_ia32_getexppd512_mask ((__v8df) __A, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __U, > 0x04); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_getexp_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_getexpss128_round ((__v4sf) __A, > (__v4sf) __B, > 0x04); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_getexp_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_getexpsd128_round ((__v2df) __A, > (__v2df) __B, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_getmant_pd (__m512d __A, _MM_MANTISSA_NORM_ENUM __B, > _MM_MANTISSA_SIGN_ENUM __C) >{ > return (__m512d) __builtin_ia32_getmantpd512_mask ((__v8df) __A, > (__C << 2) | __B, > _mm512_undefined_pd (), > (__mmask8) -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_getmant_pd (__m512d __W, __mmask8 __U, __m512d __A, > _MM_MANTISSA_NORM_ENUM __B, _MM_MANTISSA_SIGN_ENUM __C) >{ > return (__m512d) __builtin_ia32_getmantpd512_mask ((__v8df) __A, > (__C << 2) | __B, > (__v8df) __W, __U, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_getmant_pd (__mmask8 __U, __m512d __A, > _MM_MANTISSA_NORM_ENUM __B, _MM_MANTISSA_SIGN_ENUM __C) >{ > return (__m512d) __builtin_ia32_getmantpd512_mask ((__v8df) __A, > (__C << 2) | __B, > (__v8df) > _mm512_setzero_pd (), > __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_getmant_ps (__m512 __A, _MM_MANTISSA_NORM_ENUM __B, > _MM_MANTISSA_SIGN_ENUM __C) >{ > return (__m512) __builtin_ia32_getmantps512_mask ((__v16sf) __A, > (__C << 2) | __B, > _mm512_undefined_ps (), > (__mmask16) -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_getmant_ps (__m512 __W, __mmask16 __U, __m512 __A, > _MM_MANTISSA_NORM_ENUM __B, _MM_MANTISSA_SIGN_ENUM __C) >{ > return (__m512) __builtin_ia32_getmantps512_mask ((__v16sf) __A, > (__C << 2) | __B, > (__v16sf) __W, __U, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_getmant_ps (__mmask16 __U, __m512 __A, > _MM_MANTISSA_NORM_ENUM __B, _MM_MANTISSA_SIGN_ENUM __C) >{ > return (__m512) __builtin_ia32_getmantps512_mask ((__v16sf) __A, > (__C << 2) | __B, > (__v16sf) > _mm512_setzero_ps (), > __U, > 0x04); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_getmant_sd (__m128d __A, __m128d __B, _MM_MANTISSA_NORM_ENUM __C, > _MM_MANTISSA_SIGN_ENUM __D) >{ > return (__m128d) __builtin_ia32_getmantsd_round ((__v2df) __A, > (__v2df) __B, > (__D << 2) | __C, > 0x04); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_getmant_ss (__m128 __A, __m128 __B, _MM_MANTISSA_NORM_ENUM __C, > _MM_MANTISSA_SIGN_ENUM __D) >{ > return (__m128) __builtin_ia32_getmantss_round ((__v4sf) __A, > (__v4sf) __B, > (__D << 2) | __C, > 0x04); >} ># 12659 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_roundscale_ps (__m512 __A, const int __imm) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __A, __imm, > (__v16sf) > _mm512_undefined_ps (), > -1, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_roundscale_ps (__m512 __A, __mmask16 __B, __m512 __C, > const int __imm) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __C, __imm, > (__v16sf) __A, > (__mmask16) __B, > 0x04); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_roundscale_ps (__mmask16 __A, __m512 __B, const int __imm) >{ > return (__m512) __builtin_ia32_rndscaleps_mask ((__v16sf) __B, > __imm, > (__v16sf) > _mm512_setzero_ps (), > (__mmask16) __A, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_roundscale_pd (__m512d __A, const int __imm) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __A, __imm, > (__v8df) > _mm512_undefined_pd (), > -1, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_roundscale_pd (__m512d __A, __mmask8 __B, __m512d __C, > const int __imm) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __C, __imm, > (__v8df) __A, > (__mmask8) __B, > 0x04); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_roundscale_pd (__mmask8 __A, __m512d __B, const int __imm) >{ > return (__m512d) __builtin_ia32_rndscalepd_mask ((__v8df) __B, > __imm, > (__v8df) > _mm512_setzero_pd (), > (__mmask8) __A, > 0x04); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_roundscale_ss (__m128 __A, __m128 __B, const int __imm) >{ > return (__m128) __builtin_ia32_rndscaless_round ((__v4sf) __A, > (__v4sf) __B, __imm, > 0x04); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_roundscale_sd (__m128d __A, __m128d __B, const int __imm) >{ > return (__m128d) __builtin_ia32_rndscalesd_round ((__v2df) __A, > (__v2df) __B, __imm, > 0x04); >} ># 12781 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmp_pd_mask (__m512d __X, __m512d __Y, const int __P) >{ > return (__mmask8) __builtin_ia32_cmppd512_mask ((__v8df) __X, > (__v8df) __Y, __P, > (__mmask8) -1, > 0x04); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_cmp_ps_mask (__m512 __X, __m512 __Y, const int __P) >{ > return (__mmask16) __builtin_ia32_cmpps512_mask ((__v16sf) __X, > (__v16sf) __Y, __P, > (__mmask16) -1, > 0x04); >} > >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmp_ps_mask (__mmask16 __U, __m512 __X, __m512 __Y, const int __P) >{ > return (__mmask16) __builtin_ia32_cmpps512_mask ((__v16sf) __X, > (__v16sf) __Y, __P, > (__mmask16) __U, > 0x04); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_cmp_pd_mask (__mmask8 __U, __m512d __X, __m512d __Y, const int __P) >{ > return (__mmask8) __builtin_ia32_cmppd512_mask ((__v8df) __X, > (__v8df) __Y, __P, > (__mmask8) __U, > 0x04); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmp_sd_mask (__m128d __X, __m128d __Y, const int __P) >{ > return (__mmask8) __builtin_ia32_cmpsd_mask ((__v2df) __X, > (__v2df) __Y, __P, > (__mmask8) -1, > 0x04); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_cmp_sd_mask (__mmask8 __M, __m128d __X, __m128d __Y, const int __P) >{ > return (__mmask8) __builtin_ia32_cmpsd_mask ((__v2df) __X, > (__v2df) __Y, __P, > (__mmask8) __M, > 0x04); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmp_ss_mask (__m128 __X, __m128 __Y, const int __P) >{ > return (__mmask8) __builtin_ia32_cmpss_mask ((__v4sf) __X, > (__v4sf) __Y, __P, > (__mmask8) -1, > 0x04); >} > >extern __inline __mmask8 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_mask_cmp_ss_mask (__mmask8 __M, __m128 __X, __m128 __Y, const int __P) >{ > return (__mmask8) __builtin_ia32_cmpss_mask ((__v4sf) __X, > (__v4sf) __Y, __P, > (__mmask8) __M, > 0x04); >} ># 12903 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512fintrin.h" 3 4 >extern __inline __mmask16 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_kmov (__mmask16 __A) >{ > return __builtin_ia32_kmov16 (__A); >} > > > >#pragma GCC pop_options ># 46 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512erintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512erintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("avx512er") > > > > >typedef double __v8df __attribute__ ((__vector_size__ (64))); >typedef float __v16sf __attribute__ ((__vector_size__ (64))); > > > >typedef float __m512 __attribute__ ((__vector_size__ (64), __may_alias__)); >typedef double __m512d __attribute__ ((__vector_size__ (64), __may_alias__)); > >typedef unsigned char __mmask8; >typedef unsigned short __mmask16; > > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_exp2a23_round_pd (__m512d __A, int __R) >{ > __m512d __W; > return (__m512d) __builtin_ia32_exp2pd_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_exp2a23_round_pd (__m512d __W, __mmask8 __U, __m512d __A, int __R) >{ > return (__m512d) __builtin_ia32_exp2pd_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_exp2a23_round_pd (__mmask8 __U, __m512d __A, int __R) >{ > return (__m512d) __builtin_ia32_exp2pd_mask ((__v8df) __A, > (__v8df) _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_exp2a23_round_ps (__m512 __A, int __R) >{ > __m512 __W; > return (__m512) __builtin_ia32_exp2ps_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_exp2a23_round_ps (__m512 __W, __mmask16 __U, __m512 __A, int __R) >{ > return (__m512) __builtin_ia32_exp2ps_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_exp2a23_round_ps (__mmask16 __U, __m512 __A, int __R) >{ > return (__m512) __builtin_ia32_exp2ps_mask ((__v16sf) __A, > (__v16sf) _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rcp28_round_pd (__m512d __A, int __R) >{ > __m512d __W; > return (__m512d) __builtin_ia32_rcp28pd_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rcp28_round_pd (__m512d __W, __mmask8 __U, __m512d __A, int __R) >{ > return (__m512d) __builtin_ia32_rcp28pd_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rcp28_round_pd (__mmask8 __U, __m512d __A, int __R) >{ > return (__m512d) __builtin_ia32_rcp28pd_mask ((__v8df) __A, > (__v8df) _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rcp28_round_ps (__m512 __A, int __R) >{ > __m512 __W; > return (__m512) __builtin_ia32_rcp28ps_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rcp28_round_ps (__m512 __W, __mmask16 __U, __m512 __A, int __R) >{ > return (__m512) __builtin_ia32_rcp28ps_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rcp28_round_ps (__mmask16 __U, __m512 __A, int __R) >{ > return (__m512) __builtin_ia32_rcp28ps_mask ((__v16sf) __A, > (__v16sf) _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rcp28_round_sd (__m128d __A, __m128d __B, int __R) >{ > return (__m128d) __builtin_ia32_rcp28sd_round ((__v2df) __B, > (__v2df) __A, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rcp28_round_ss (__m128 __A, __m128 __B, int __R) >{ > return (__m128) __builtin_ia32_rcp28ss_round ((__v4sf) __B, > (__v4sf) __A, > __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rsqrt28_round_pd (__m512d __A, int __R) >{ > __m512d __W; > return (__m512d) __builtin_ia32_rsqrt28pd_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) -1, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rsqrt28_round_pd (__m512d __W, __mmask8 __U, __m512d __A, int __R) >{ > return (__m512d) __builtin_ia32_rsqrt28pd_mask ((__v8df) __A, > (__v8df) __W, > (__mmask8) __U, __R); >} > >extern __inline __m512d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rsqrt28_round_pd (__mmask8 __U, __m512d __A, int __R) >{ > return (__m512d) __builtin_ia32_rsqrt28pd_mask ((__v8df) __A, > (__v8df) _mm512_setzero_pd (), > (__mmask8) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_rsqrt28_round_ps (__m512 __A, int __R) >{ > __m512 __W; > return (__m512) __builtin_ia32_rsqrt28ps_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) -1, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_rsqrt28_round_ps (__m512 __W, __mmask16 __U, __m512 __A, int __R) >{ > return (__m512) __builtin_ia32_rsqrt28ps_mask ((__v16sf) __A, > (__v16sf) __W, > (__mmask16) __U, __R); >} > >extern __inline __m512 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_rsqrt28_round_ps (__mmask16 __U, __m512 __A, int __R) >{ > return (__m512) __builtin_ia32_rsqrt28ps_mask ((__v16sf) __A, > (__v16sf) _mm512_setzero_ps (), > (__mmask16) __U, __R); >} > >extern __inline __m128d >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rsqrt28_round_sd (__m128d __A, __m128d __B, int __R) >{ > return (__m128d) __builtin_ia32_rsqrt28sd_round ((__v2df) __B, > (__v2df) __A, > __R); >} > >extern __inline __m128 >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rsqrt28_round_ss (__m128 __A, __m128 __B, int __R) >{ > return (__m128) __builtin_ia32_rsqrt28ss_round ((__v4sf) __B, > (__v4sf) __A, > __R); >} ># 391 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512erintrin.h" 3 4 >#pragma GCC pop_options ># 48 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512pfintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512pfintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("avx512pf") > > > > >typedef long long __v8di __attribute__ ((__vector_size__ (64))); >typedef int __v16si __attribute__ ((__vector_size__ (64))); > > > >typedef long long __m512i __attribute__ ((__vector_size__ (64), __may_alias__)); > >typedef unsigned char __mmask8; >typedef unsigned short __mmask16; > > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_prefetch_i32gather_pd (__m256i index, __mmask8 mask, > void *addr, int scale, int hint) >{ > __builtin_ia32_gatherpfdpd (mask, (__v8si) index, (long long const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_prefetch_i32gather_ps (__m512i index, __mmask16 mask, > void *addr, int scale, int hint) >{ > __builtin_ia32_gatherpfdps (mask, (__v16si) index, (int const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_prefetch_i64gather_pd (__m512i index, __mmask8 mask, > void *addr, int scale, int hint) >{ > __builtin_ia32_gatherpfqpd (mask, (__v8di) index, (long long const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_prefetch_i64gather_ps (__m512i index, __mmask8 mask, > void *addr, int scale, int hint) >{ > __builtin_ia32_gatherpfqps (mask, (__v8di) index, (int const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_prefetch_i32scatter_pd (void *addr, __m256i index, int scale, > int hint) >{ > __builtin_ia32_scatterpfdpd ((__mmask8) 0xFF, (__v8si) index, > (long long const *)addr, scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_prefetch_i32scatter_ps (void *addr, __m512i index, int scale, > int hint) >{ > __builtin_ia32_scatterpfdps ((__mmask16) 0xFFFF, (__v16si) index, (int const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_prefetch_i32scatter_pd (void *addr, __mmask8 mask, > __m256i index, int scale, int hint) >{ > __builtin_ia32_scatterpfdpd (mask, (__v8si) index, (long long const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_prefetch_i32scatter_ps (void *addr, __mmask16 mask, > __m512i index, int scale, int hint) >{ > __builtin_ia32_scatterpfdps (mask, (__v16si) index, (int const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_prefetch_i64scatter_pd (void *addr, __m512i index, int scale, > int hint) >{ > __builtin_ia32_scatterpfqpd ((__mmask8) 0xFF, (__v8di) index, (long long const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_prefetch_i64scatter_ps (void *addr, __m512i index, int scale, > int hint) >{ > __builtin_ia32_scatterpfqps ((__mmask8) 0xFF, (__v8di) index, (int const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_prefetch_i64scatter_pd (void *addr, __mmask16 mask, > __m512i index, int scale, int hint) >{ > __builtin_ia32_scatterpfqpd (mask, (__v8di) index, (long long const *) addr, > scale, hint); >} > >extern __inline void >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_prefetch_i64scatter_ps (void *addr, __mmask16 mask, > __m512i index, int scale, int hint) >{ > __builtin_ia32_scatterpfqps (mask, (__v8di) index, (int const *) addr, > scale, hint); >} ># 209 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512pfintrin.h" 3 4 >#pragma GCC pop_options ># 50 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512cdintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/avx512cdintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("avx512cd") > > > > >typedef long long __v8di __attribute__ ((__vector_size__ (64))); >typedef int __v16si __attribute__ ((__vector_size__ (64))); > > > >typedef long long __m512i __attribute__ ((__vector_size__ (64), __may_alias__)); >typedef double __m512d __attribute__ ((__vector_size__ (64), __may_alias__)); > >typedef unsigned char __mmask8; >typedef unsigned short __mmask16; > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_conflict_epi32 (__m512i __A) >{ > return (__m512i) > __builtin_ia32_vpconflictsi_512_mask ((__v16si) __A, > (__v16si) _mm512_setzero_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_conflict_epi32 (__m512i __W, __mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_vpconflictsi_512_mask ((__v16si) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_conflict_epi32 (__mmask16 __U, __m512i __A) >{ > return (__m512i) > __builtin_ia32_vpconflictsi_512_mask ((__v16si) __A, > (__v16si) _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_conflict_epi64 (__m512i __A) >{ > return (__m512i) > __builtin_ia32_vpconflictdi_512_mask ((__v8di) __A, > (__v8di) _mm512_setzero_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_conflict_epi64 (__m512i __W, __mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_vpconflictdi_512_mask ((__v8di) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_conflict_epi64 (__mmask8 __U, __m512i __A) >{ > return (__m512i) > __builtin_ia32_vpconflictdi_512_mask ((__v8di) __A, > (__v8di) _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_lzcnt_epi64 (__m512i __A) >{ > return (__m512i) > __builtin_ia32_vplzcntq_512_mask ((__v8di) __A, > (__v8di) _mm512_setzero_si512 (), > (__mmask8) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_lzcnt_epi64 (__m512i __W, __mmask8 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_vplzcntq_512_mask ((__v8di) __A, > (__v8di) __W, > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_lzcnt_epi64 (__mmask8 __U, __m512i __A) >{ > return (__m512i) > __builtin_ia32_vplzcntq_512_mask ((__v8di) __A, > (__v8di) _mm512_setzero_si512 (), > (__mmask8) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_lzcnt_epi32 (__m512i __A) >{ > return (__m512i) > __builtin_ia32_vplzcntd_512_mask ((__v16si) __A, > (__v16si) _mm512_setzero_si512 (), > (__mmask16) -1); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_mask_lzcnt_epi32 (__m512i __W, __mmask16 __U, __m512i __A) >{ > return (__m512i) __builtin_ia32_vplzcntd_512_mask ((__v16si) __A, > (__v16si) __W, > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_maskz_lzcnt_epi32 (__mmask16 __U, __m512i __A) >{ > return (__m512i) > __builtin_ia32_vplzcntd_512_mask ((__v16si) __A, > (__v16si) _mm512_setzero_si512 (), > (__mmask16) __U); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcastmb_epi64 (__mmask8 __A) >{ > return (__m512i) __builtin_ia32_broadcastmb512 (__A); >} > >extern __inline __m512i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm512_broadcastmw_epi32 (__mmask16 __A) >{ > return (__m512i) __builtin_ia32_broadcastmw512 (__A); >} > > > >#pragma GCC pop_options ># 52 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/shaintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/shaintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("sha") > > > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha1msg1_epu32 (__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_sha1msg1 ((__v4si) __A, (__v4si) __B); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha1msg2_epu32 (__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_sha1msg2 ((__v4si) __A, (__v4si) __B); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha1nexte_epu32 (__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_sha1nexte ((__v4si) __A, (__v4si) __B); >} > > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha1rnds4_epu32 (__m128i __A, __m128i __B, const int __I) >{ > return (__m128i) __builtin_ia32_sha1rnds4 ((__v4si) __A, (__v4si) __B, __I); >} > > > > > > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha256msg1_epu32 (__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_sha256msg1 ((__v4si) __A, (__v4si) __B); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha256msg2_epu32 (__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_sha256msg2 ((__v4si) __A, (__v4si) __B); >} > >extern __inline __m128i >__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha256rnds2_epu32 (__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_sha256rnds2 ((__v4si) __A, (__v4si) __B, > (__v4si) __C); >} > > > >#pragma GCC pop_options ># 54 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/lzcntintrin.h" 1 3 4 ># 33 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/lzcntintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("lzcnt") > > > >extern __inline unsigned short __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__lzcnt16 (unsigned short __X) >{ > return __builtin_clzs (__X); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__lzcnt32 (unsigned int __X) >{ > return __builtin_clz (__X); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_lzcnt_u32 (unsigned int __X) >{ > return __builtin_clz (__X); >} > > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__lzcnt64 (unsigned long long __X) >{ > return __builtin_clzll (__X); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_lzcnt_u64 (unsigned long long __X) >{ > return __builtin_clzll (__X); >} > > > > >#pragma GCC pop_options ># 56 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/bmiintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/bmiintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("bmi") > > > >extern __inline unsigned short __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__tzcnt_u16 (unsigned short __X) >{ > return __builtin_ctzs (__X); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__andn_u32 (unsigned int __X, unsigned int __Y) >{ > return ~__X & __Y; >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bextr_u32 (unsigned int __X, unsigned int __Y) >{ > return __builtin_ia32_bextr_u32 (__X, __Y); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_bextr_u32 (unsigned int __X, unsigned int __Y, unsigned __Z) >{ > return __builtin_ia32_bextr_u32 (__X, ((__Y & 0xff) | ((__Z & 0xff) << 8))); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsi_u32 (unsigned int __X) >{ > return __X & -__X; >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_blsi_u32 (unsigned int __X) >{ > return __blsi_u32 (__X); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsmsk_u32 (unsigned int __X) >{ > return __X ^ (__X - 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_blsmsk_u32 (unsigned int __X) >{ > return __blsmsk_u32 (__X); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsr_u32 (unsigned int __X) >{ > return __X & (__X - 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_blsr_u32 (unsigned int __X) >{ > return __blsr_u32 (__X); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__tzcnt_u32 (unsigned int __X) >{ > return __builtin_ctz (__X); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_tzcnt_u32 (unsigned int __X) >{ > return __builtin_ctz (__X); >} > > > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__andn_u64 (unsigned long long __X, unsigned long long __Y) >{ > return ~__X & __Y; >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bextr_u64 (unsigned long long __X, unsigned long long __Y) >{ > return __builtin_ia32_bextr_u64 (__X, __Y); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_bextr_u64 (unsigned long long __X, unsigned int __Y, unsigned int __Z) >{ > return __builtin_ia32_bextr_u64 (__X, ((__Y & 0xff) | ((__Z & 0xff) << 8))); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsi_u64 (unsigned long long __X) >{ > return __X & -__X; >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_blsi_u64 (unsigned long long __X) >{ > return __blsi_u64 (__X); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsmsk_u64 (unsigned long long __X) >{ > return __X ^ (__X - 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_blsmsk_u64 (unsigned long long __X) >{ > return __blsmsk_u64 (__X); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsr_u64 (unsigned long long __X) >{ > return __X & (__X - 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_blsr_u64 (unsigned long long __X) >{ > return __blsr_u64 (__X); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__tzcnt_u64 (unsigned long long __X) >{ > return __builtin_ctzll (__X); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_tzcnt_u64 (unsigned long long __X) >{ > return __builtin_ctzll (__X); >} > > > > > >#pragma GCC pop_options ># 58 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/bmi2intrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/bmi2intrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("bmi2") > > > >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_bzhi_u32 (unsigned int __X, unsigned int __Y) >{ > return __builtin_ia32_bzhi_si (__X, __Y); >} > >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_pdep_u32 (unsigned int __X, unsigned int __Y) >{ > return __builtin_ia32_pdep_si (__X, __Y); >} > >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_pext_u32 (unsigned int __X, unsigned int __Y) >{ > return __builtin_ia32_pext_si (__X, __Y); >} > > > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_bzhi_u64 (unsigned long long __X, unsigned long long __Y) >{ > return __builtin_ia32_bzhi_di (__X, __Y); >} > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_pdep_u64 (unsigned long long __X, unsigned long long __Y) >{ > return __builtin_ia32_pdep_di (__X, __Y); >} > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_pext_u64 (unsigned long long __X, unsigned long long __Y) >{ > return __builtin_ia32_pext_di (__X, __Y); >} > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mulx_u64 (unsigned long long __X, unsigned long long __Y, > unsigned long long *__P) >{ > unsigned __int128 __res = (unsigned __int128) __X * __Y; > *__P = (unsigned long long) (__res >> 64); > return (unsigned long long) __res; >} ># 106 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/bmi2intrin.h" 3 4 >#pragma GCC pop_options ># 60 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/fmaintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/fmaintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("fma") > > > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmadd_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d)__builtin_ia32_vfmaddpd ((__v2df)__A, (__v2df)__B, > (__v2df)__C); >} > >extern __inline __m256d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fmadd_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d)__builtin_ia32_vfmaddpd256 ((__v4df)__A, (__v4df)__B, > (__v4df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmadd_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128)__builtin_ia32_vfmaddps ((__v4sf)__A, (__v4sf)__B, > (__v4sf)__C); >} > >extern __inline __m256 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fmadd_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256)__builtin_ia32_vfmaddps256 ((__v8sf)__A, (__v8sf)__B, > (__v8sf)__C); >} > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmadd_sd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddsd3 ((__v2df)__A, (__v2df)__B, > (__v2df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmadd_ss (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddss3 ((__v4sf)__A, (__v4sf)__B, > (__v4sf)__C); >} > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmsub_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d)__builtin_ia32_vfmaddpd ((__v2df)__A, (__v2df)__B, > -(__v2df)__C); >} > >extern __inline __m256d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fmsub_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d)__builtin_ia32_vfmaddpd256 ((__v4df)__A, (__v4df)__B, > -(__v4df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmsub_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128)__builtin_ia32_vfmaddps ((__v4sf)__A, (__v4sf)__B, > -(__v4sf)__C); >} > >extern __inline __m256 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fmsub_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256)__builtin_ia32_vfmaddps256 ((__v8sf)__A, (__v8sf)__B, > -(__v8sf)__C); >} > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmsub_sd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d)__builtin_ia32_vfmaddsd3 ((__v2df)__A, (__v2df)__B, > -(__v2df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmsub_ss (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128)__builtin_ia32_vfmaddss3 ((__v4sf)__A, (__v4sf)__B, > -(__v4sf)__C); >} > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmadd_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d)__builtin_ia32_vfmaddpd (-(__v2df)__A, (__v2df)__B, > (__v2df)__C); >} > >extern __inline __m256d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fnmadd_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d)__builtin_ia32_vfmaddpd256 (-(__v4df)__A, (__v4df)__B, > (__v4df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmadd_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128)__builtin_ia32_vfmaddps (-(__v4sf)__A, (__v4sf)__B, > (__v4sf)__C); >} > >extern __inline __m256 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fnmadd_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256)__builtin_ia32_vfmaddps256 (-(__v8sf)__A, (__v8sf)__B, > (__v8sf)__C); >} > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmadd_sd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d)__builtin_ia32_vfmaddsd3 ((__v2df)__A, -(__v2df)__B, > (__v2df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmadd_ss (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128)__builtin_ia32_vfmaddss3 ((__v4sf)__A, -(__v4sf)__B, > (__v4sf)__C); >} > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmsub_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d)__builtin_ia32_vfmaddpd (-(__v2df)__A, (__v2df)__B, > -(__v2df)__C); >} > >extern __inline __m256d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fnmsub_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d)__builtin_ia32_vfmaddpd256 (-(__v4df)__A, (__v4df)__B, > -(__v4df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmsub_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128)__builtin_ia32_vfmaddps (-(__v4sf)__A, (__v4sf)__B, > -(__v4sf)__C); >} > >extern __inline __m256 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fnmsub_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256)__builtin_ia32_vfmaddps256 (-(__v8sf)__A, (__v8sf)__B, > -(__v8sf)__C); >} > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmsub_sd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d)__builtin_ia32_vfmaddsd3 ((__v2df)__A, -(__v2df)__B, > -(__v2df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fnmsub_ss (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128)__builtin_ia32_vfmaddss3 ((__v4sf)__A, -(__v4sf)__B, > -(__v4sf)__C); >} > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmaddsub_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d)__builtin_ia32_vfmaddsubpd ((__v2df)__A, (__v2df)__B, > (__v2df)__C); >} > >extern __inline __m256d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fmaddsub_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d)__builtin_ia32_vfmaddsubpd256 ((__v4df)__A, > (__v4df)__B, > (__v4df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmaddsub_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128)__builtin_ia32_vfmaddsubps ((__v4sf)__A, (__v4sf)__B, > (__v4sf)__C); >} > >extern __inline __m256 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fmaddsub_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256)__builtin_ia32_vfmaddsubps256 ((__v8sf)__A, > (__v8sf)__B, > (__v8sf)__C); >} > >extern __inline __m128d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmsubadd_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d)__builtin_ia32_vfmaddsubpd ((__v2df)__A, (__v2df)__B, > -(__v2df)__C); >} > >extern __inline __m256d >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fmsubadd_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d)__builtin_ia32_vfmaddsubpd256 ((__v4df)__A, > (__v4df)__B, > -(__v4df)__C); >} > >extern __inline __m128 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_fmsubadd_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128)__builtin_ia32_vfmaddsubps ((__v4sf)__A, (__v4sf)__B, > -(__v4sf)__C); >} > >extern __inline __m256 >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_fmsubadd_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256)__builtin_ia32_vfmaddsubps256 ((__v8sf)__A, > (__v8sf)__B, > -(__v8sf)__C); >} > > > >#pragma GCC pop_options ># 62 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/f16cintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/f16cintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("f16c") > > > >extern __inline float __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_cvtsh_ss (unsigned short __S) >{ > __v8hi __H = __extension__ (__v8hi){ (short) __S, 0, 0, 0, 0, 0, 0, 0 }; > __v4sf __A = __builtin_ia32_vcvtph2ps (__H); > return __builtin_ia32_vec_ext_v4sf (__A, 0); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtph_ps (__m128i __A) >{ > return (__m128) __builtin_ia32_vcvtph2ps ((__v8hi) __A); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtph_ps (__m128i __A) >{ > return (__m256) __builtin_ia32_vcvtph2ps256 ((__v8hi) __A); >} > > >extern __inline unsigned short __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_cvtss_sh (float __F, const int __I) >{ > __v4sf __A = __extension__ (__v4sf){ __F, 0, 0, 0 }; > __v8hi __H = __builtin_ia32_vcvtps2ph (__A, __I); > return (unsigned short) __builtin_ia32_vec_ext_v8hi (__H, 0); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cvtps_ph (__m128 __A, const int __I) >{ > return (__m128i) __builtin_ia32_vcvtps2ph ((__v4sf) __A, __I); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_cvtps_ph (__m256 __A, const int __I) >{ > return (__m128i) __builtin_ia32_vcvtps2ph256 ((__v8sf) __A, __I); >} ># 95 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/f16cintrin.h" 3 4 >#pragma GCC pop_options ># 64 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/rtmintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/rtmintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("rtm") ># 48 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/rtmintrin.h" 3 4 >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xbegin (void) >{ > return __builtin_ia32_xbegin (); >} > > > > > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xend (void) >{ > __builtin_ia32_xend (); >} > > > > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xabort (const unsigned int imm) >{ > __builtin_ia32_xabort (imm); >} > > > > > > >#pragma GCC pop_options ># 66 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xtestintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xtestintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("rtm") > > > > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xtest (void) >{ > return __builtin_ia32_xtest (); >} > > > >#pragma GCC pop_options ># 68 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/immintrin.h" 2 3 4 > > >#pragma GCC push_options >#pragma GCC target("rdrnd") > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_rdrand16_step (unsigned short *__P) >{ > return __builtin_ia32_rdrand16_step (__P); >} > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_rdrand32_step (unsigned int *__P) >{ > return __builtin_ia32_rdrand32_step (__P); >} > > >#pragma GCC pop_options > > > > > >#pragma GCC push_options >#pragma GCC target("fsgsbase") > > >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_readfsbase_u32 (void) >{ > return __builtin_ia32_rdfsbase32 (); >} > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_readfsbase_u64 (void) >{ > return __builtin_ia32_rdfsbase64 (); >} > >extern __inline unsigned int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_readgsbase_u32 (void) >{ > return __builtin_ia32_rdgsbase32 (); >} > >extern __inline unsigned long long >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_readgsbase_u64 (void) >{ > return __builtin_ia32_rdgsbase64 (); >} > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_writefsbase_u32 (unsigned int __B) >{ > __builtin_ia32_wrfsbase32 (__B); >} > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_writefsbase_u64 (unsigned long long __B) >{ > __builtin_ia32_wrfsbase64 (__B); >} > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_writegsbase_u32 (unsigned int __B) >{ > __builtin_ia32_wrgsbase32 (__B); >} > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_writegsbase_u64 (unsigned long long __B) >{ > __builtin_ia32_wrgsbase64 (__B); >} > > >#pragma GCC pop_options > > > >#pragma GCC push_options >#pragma GCC target("rdrnd") > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_rdrand64_step (unsigned long long *__P) >{ > return __builtin_ia32_rdrand64_step (__P); >} > > >#pragma GCC pop_options ># 47 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mm3dnow.h" 1 3 4 ># 31 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mm3dnow.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/prfchwintrin.h" 1 3 4 ># 31 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/prfchwintrin.h" 3 4 >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_prefetchw (void *__P) >{ > __builtin_prefetch (__P, 1, 3 ); >} ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mm3dnow.h" 2 3 4 > > >#pragma GCC push_options >#pragma GCC target("3dnow") > > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_femms (void) >{ > __builtin_ia32_femms(); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pavgusb (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pavgusb ((__v8qi)__A, (__v8qi)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pf2id (__m64 __A) >{ > return (__m64)__builtin_ia32_pf2id ((__v2sf)__A); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfacc (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfacc ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfadd (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfadd ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfcmpeq (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfcmpeq ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfcmpge (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfcmpge ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfcmpgt (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfcmpgt ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfmax (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfmax ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfmin (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfmin ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfmul (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfmul ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfrcp (__m64 __A) >{ > return (__m64)__builtin_ia32_pfrcp ((__v2sf)__A); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfrcpit1 (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfrcpit1 ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfrcpit2 (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfrcpit2 ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfrsqrt (__m64 __A) >{ > return (__m64)__builtin_ia32_pfrsqrt ((__v2sf)__A); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfrsqit1 (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfrsqit1 ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfsub (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfsub ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pfsubr (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pfsubr ((__v2sf)__A, (__v2sf)__B); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pi2fd (__m64 __A) >{ > return (__m64)__builtin_ia32_pi2fd ((__v2si)__A); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_pmulhrw (__m64 __A, __m64 __B) >{ > return (__m64)__builtin_ia32_pmulhrw ((__v4hi)__A, (__v4hi)__B); >} > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_prefetch (void *__P) >{ > __builtin_prefetch (__P, 0, 3 ); >} > >extern __inline __m64 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_from_float (float __A) >{ > return __extension__ (__m64)(__v2sf){ __A, 0.0f }; >} > >extern __inline float __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_m_to_float (__m64 __A) >{ > union { __v2sf v; float a[2]; } __tmp; > __tmp.v = (__v2sf)__A; > return __tmp.a[0]; >} ># 215 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/mm3dnow.h" 3 4 >#pragma GCC pop_options ># 49 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/fma4intrin.h" 1 3 4 ># 35 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/fma4intrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("fma4") > > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_macc_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddps ((__v4sf)__A, (__v4sf)__B, (__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_macc_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddpd ((__v2df)__A, (__v2df)__B, (__v2df)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_macc_ss (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddss ((__v4sf)__A, (__v4sf)__B, (__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_macc_sd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddsd ((__v2df)__A, (__v2df)__B, (__v2df)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_msub_ps (__m128 __A, __m128 __B, __m128 __C) > >{ > return (__m128) __builtin_ia32_vfmaddps ((__v4sf)__A, (__v4sf)__B, -(__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_msub_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddpd ((__v2df)__A, (__v2df)__B, -(__v2df)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_msub_ss (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddss ((__v4sf)__A, (__v4sf)__B, -(__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_msub_sd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddsd ((__v2df)__A, (__v2df)__B, -(__v2df)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_nmacc_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddps (-(__v4sf)__A, (__v4sf)__B, (__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_nmacc_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddpd (-(__v2df)__A, (__v2df)__B, (__v2df)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_nmacc_ss (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddss (-(__v4sf)__A, (__v4sf)__B, (__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_nmacc_sd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddsd (-(__v2df)__A, (__v2df)__B, (__v2df)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_nmsub_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddps (-(__v4sf)__A, (__v4sf)__B, -(__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_nmsub_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddpd (-(__v2df)__A, (__v2df)__B, -(__v2df)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_nmsub_ss (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddss (-(__v4sf)__A, (__v4sf)__B, -(__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_nmsub_sd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddsd (-(__v2df)__A, (__v2df)__B, -(__v2df)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maddsub_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddsubps ((__v4sf)__A, (__v4sf)__B, (__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maddsub_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddsubpd ((__v2df)__A, (__v2df)__B, (__v2df)__C); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_msubadd_ps (__m128 __A, __m128 __B, __m128 __C) >{ > return (__m128) __builtin_ia32_vfmaddsubps ((__v4sf)__A, (__v4sf)__B, -(__v4sf)__C); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_msubadd_pd (__m128d __A, __m128d __B, __m128d __C) >{ > return (__m128d) __builtin_ia32_vfmaddsubpd ((__v2df)__A, (__v2df)__B, -(__v2df)__C); >} > > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_macc_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256) __builtin_ia32_vfmaddps256 ((__v8sf)__A, (__v8sf)__B, (__v8sf)__C); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_macc_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d) __builtin_ia32_vfmaddpd256 ((__v4df)__A, (__v4df)__B, (__v4df)__C); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_msub_ps (__m256 __A, __m256 __B, __m256 __C) > >{ > return (__m256) __builtin_ia32_vfmaddps256 ((__v8sf)__A, (__v8sf)__B, -(__v8sf)__C); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_msub_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d) __builtin_ia32_vfmaddpd256 ((__v4df)__A, (__v4df)__B, -(__v4df)__C); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_nmacc_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256) __builtin_ia32_vfmaddps256 (-(__v8sf)__A, (__v8sf)__B, (__v8sf)__C); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_nmacc_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d) __builtin_ia32_vfmaddpd256 (-(__v4df)__A, (__v4df)__B, (__v4df)__C); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_nmsub_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256) __builtin_ia32_vfmaddps256 (-(__v8sf)__A, (__v8sf)__B, -(__v8sf)__C); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_nmsub_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d) __builtin_ia32_vfmaddpd256 (-(__v4df)__A, (__v4df)__B, -(__v4df)__C); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maddsub_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256) __builtin_ia32_vfmaddsubps256 ((__v8sf)__A, (__v8sf)__B, (__v8sf)__C); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_maddsub_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d) __builtin_ia32_vfmaddsubpd256 ((__v4df)__A, (__v4df)__B, (__v4df)__C); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_msubadd_ps (__m256 __A, __m256 __B, __m256 __C) >{ > return (__m256) __builtin_ia32_vfmaddsubps256 ((__v8sf)__A, (__v8sf)__B, -(__v8sf)__C); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_msubadd_pd (__m256d __A, __m256d __B, __m256d __C) >{ > return (__m256d) __builtin_ia32_vfmaddsubpd256 ((__v4df)__A, (__v4df)__B, -(__v4df)__C); >} > > > >#pragma GCC pop_options ># 51 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xopintrin.h" 1 3 4 ># 31 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xopintrin.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/fma4intrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xopintrin.h" 2 3 4 > > >#pragma GCC push_options >#pragma GCC target("xop") > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maccs_epi16(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacssww ((__v8hi)__A,(__v8hi)__B, (__v8hi)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_macc_epi16(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacsww ((__v8hi)__A, (__v8hi)__B, (__v8hi)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maccsd_epi16(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacsswd ((__v8hi)__A, (__v8hi)__B, (__v4si)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maccd_epi16(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacswd ((__v8hi)__A, (__v8hi)__B, (__v4si)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maccs_epi32(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacssdd ((__v4si)__A, (__v4si)__B, (__v4si)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_macc_epi32(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacsdd ((__v4si)__A, (__v4si)__B, (__v4si)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maccslo_epi32(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacssdql ((__v4si)__A, (__v4si)__B, (__v2di)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_macclo_epi32(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacsdql ((__v4si)__A, (__v4si)__B, (__v2di)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maccshi_epi32(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacssdqh ((__v4si)__A, (__v4si)__B, (__v2di)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_macchi_epi32(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmacsdqh ((__v4si)__A, (__v4si)__B, (__v2di)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maddsd_epi16(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmadcsswd ((__v8hi)__A,(__v8hi)__B,(__v4si)__C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_maddd_epi16(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpmadcswd ((__v8hi)__A,(__v8hi)__B,(__v4si)__C); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddw_epi8(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphaddbw ((__v16qi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddd_epi8(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphaddbd ((__v16qi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddq_epi8(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphaddbq ((__v16qi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddd_epi16(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphaddwd ((__v8hi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddq_epi16(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphaddwq ((__v8hi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddq_epi32(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphadddq ((__v4si)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddw_epu8(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphaddubw ((__v16qi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddd_epu8(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphaddubd ((__v16qi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddq_epu8(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphaddubq ((__v16qi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddd_epu16(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphadduwd ((__v8hi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddq_epu16(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphadduwq ((__v8hi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_haddq_epu32(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphaddudq ((__v4si)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsubw_epi8(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphsubbw ((__v16qi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsubd_epi16(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphsubwd ((__v8hi)__A); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_hsubq_epi32(__m128i __A) >{ > return (__m128i) __builtin_ia32_vphsubdq ((__v4si)__A); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_cmov_si128(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpcmov (__A, __B, __C); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_perm_epi8(__m128i __A, __m128i __B, __m128i __C) >{ > return (__m128i) __builtin_ia32_vpperm ((__v16qi)__A, (__v16qi)__B, (__v16qi)__C); >} > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rot_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vprotb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rot_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vprotw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rot_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vprotd ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_rot_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vprotq ((__v2di)__A, (__v2di)__B); >} > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_roti_epi8(__m128i __A, const int __B) >{ > return (__m128i) __builtin_ia32_vprotbi ((__v16qi)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_roti_epi16(__m128i __A, const int __B) >{ > return (__m128i) __builtin_ia32_vprotwi ((__v8hi)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_roti_epi32(__m128i __A, const int __B) >{ > return (__m128i) __builtin_ia32_vprotdi ((__v4si)__A, __B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_roti_epi64(__m128i __A, const int __B) >{ > return (__m128i) __builtin_ia32_vprotqi ((__v2di)__A, __B); >} ># 283 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xopintrin.h" 3 4 >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shl_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpshlb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shl_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpshlw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shl_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpshld ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_shl_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpshlq ((__v2di)__A, (__v2di)__B); >} > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpshab ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpshaw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpshad ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_sha_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpshaq ((__v2di)__A, (__v2di)__B); >} > > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comlt_epu8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomltub ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comle_epu8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomleub ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comgt_epu8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgtub ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comge_epu8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgeub ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comeq_epu8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomequb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comneq_epu8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomnequb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comfalse_epu8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomfalseub ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comtrue_epu8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomtrueub ((__v16qi)__A, (__v16qi)__B); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comlt_epu16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomltuw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comle_epu16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomleuw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comgt_epu16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgtuw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comge_epu16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgeuw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comeq_epu16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomequw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comneq_epu16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomnequw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comfalse_epu16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomfalseuw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comtrue_epu16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomtrueuw ((__v8hi)__A, (__v8hi)__B); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comlt_epu32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomltud ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comle_epu32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomleud ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comgt_epu32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgtud ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comge_epu32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgeud ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comeq_epu32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomequd ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comneq_epu32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomnequd ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comfalse_epu32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomfalseud ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comtrue_epu32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomtrueud ((__v4si)__A, (__v4si)__B); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comlt_epu64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomltuq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comle_epu64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomleuq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comgt_epu64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgtuq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comge_epu64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgeuq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comeq_epu64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomequq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comneq_epu64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomnequq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comfalse_epu64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomfalseuq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comtrue_epu64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomtrueuq ((__v2di)__A, (__v2di)__B); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comlt_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomltb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comle_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomleb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comgt_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgtb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comge_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgeb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comeq_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomeqb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comneq_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomneqb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comfalse_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomfalseb ((__v16qi)__A, (__v16qi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comtrue_epi8(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomtrueb ((__v16qi)__A, (__v16qi)__B); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comlt_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomltw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comle_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomlew ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comgt_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgtw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comge_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgew ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comeq_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomeqw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comneq_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomneqw ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comfalse_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomfalsew ((__v8hi)__A, (__v8hi)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comtrue_epi16(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomtruew ((__v8hi)__A, (__v8hi)__B); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comlt_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomltd ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comle_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomled ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comgt_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgtd ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comge_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomged ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comeq_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomeqd ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comneq_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomneqd ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comfalse_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomfalsed ((__v4si)__A, (__v4si)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comtrue_epi32(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomtrued ((__v4si)__A, (__v4si)__B); >} > > > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comlt_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomltq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comle_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomleq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comgt_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgtq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comge_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomgeq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comeq_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomeqq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comneq_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomneqq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comfalse_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomfalseq ((__v2di)__A, (__v2di)__B); >} > >extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_comtrue_epi64(__m128i __A, __m128i __B) >{ > return (__m128i) __builtin_ia32_vpcomtrueq ((__v2di)__A, (__v2di)__B); >} > > > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_frcz_ps (__m128 __A) >{ > return (__m128) __builtin_ia32_vfrczps ((__v4sf)__A); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_frcz_pd (__m128d __A) >{ > return (__m128d) __builtin_ia32_vfrczpd ((__v2df)__A); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_frcz_ss (__m128 __A, __m128 __B) >{ > return (__m128) __builtin_ia32_movss ((__v4sf)__A, > (__v4sf) > __builtin_ia32_vfrczss ((__v4sf)__B)); >} > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_frcz_sd (__m128d __A, __m128d __B) >{ > return (__m128d) __builtin_ia32_movsd ((__v2df)__A, > (__v2df) > __builtin_ia32_vfrczsd ((__v2df)__B)); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_frcz_ps (__m256 __A) >{ > return (__m256) __builtin_ia32_vfrczps256 ((__v8sf)__A); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_frcz_pd (__m256d __A) >{ > return (__m256d) __builtin_ia32_vfrczpd256 ((__v4df)__A); >} > > > > >extern __inline __m128d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_permute2_pd (__m128d __X, __m128d __Y, __m128i __C, const int __I) >{ > return (__m128d) __builtin_ia32_vpermil2pd ((__v2df)__X, > (__v2df)__Y, > (__v2di)__C, > __I); >} > >extern __inline __m256d __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute2_pd (__m256d __X, __m256d __Y, __m256i __C, const int __I) >{ > return (__m256d) __builtin_ia32_vpermil2pd256 ((__v4df)__X, > (__v4df)__Y, > (__v4di)__C, > __I); >} > >extern __inline __m128 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm_permute2_ps (__m128 __X, __m128 __Y, __m128i __C, const int __I) >{ > return (__m128) __builtin_ia32_vpermil2ps ((__v4sf)__X, > (__v4sf)__Y, > (__v4si)__C, > __I); >} > >extern __inline __m256 __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_mm256_permute2_ps (__m256 __X, __m256 __Y, __m256i __C, const int __I) >{ > return (__m256) __builtin_ia32_vpermil2ps256 ((__v8sf)__X, > (__v8sf)__Y, > (__v8si)__C, > __I); >} ># 841 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xopintrin.h" 3 4 >#pragma GCC pop_options ># 53 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/lwpintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/lwpintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("lwp") > > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__llwpcb (void *pcbAddress) >{ > __builtin_ia32_llwpcb (pcbAddress); >} > >extern __inline void * __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__slwpcb (void) >{ > return __builtin_ia32_slwpcb (); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__lwpval32 (unsigned int data2, unsigned int data1, unsigned int flags) >{ > __builtin_ia32_lwpval32 (data2, data1, flags); >} > > >extern __inline void __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__lwpval64 (unsigned long long data2, unsigned int data1, unsigned int flags) >{ > __builtin_ia32_lwpval64 (data2, data1, flags); >} ># 76 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/lwpintrin.h" 3 4 >extern __inline unsigned char __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__lwpins32 (unsigned int data2, unsigned int data1, unsigned int flags) >{ > return __builtin_ia32_lwpins32 (data2, data1, flags); >} > > >extern __inline unsigned char __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__lwpins64 (unsigned long long data2, unsigned int data1, unsigned int flags) >{ > return __builtin_ia32_lwpins64 (data2, data1, flags); >} ># 102 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/lwpintrin.h" 3 4 >#pragma GCC pop_options ># 55 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/bmiintrin.h" 1 3 4 ># 57 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/bmi2intrin.h" 1 3 4 ># 59 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/tbmintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/tbmintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("tbm") > > > > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bextri_u32 (unsigned int __X, const unsigned int __I) >{ > return __builtin_ia32_bextri_u32 (__X, __I); >} > > > > > > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blcfill_u32 (unsigned int __X) >{ > return __X & (__X + 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blci_u32 (unsigned int __X) >{ > return __X | ~(__X + 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blcic_u32 (unsigned int __X) >{ > return ~__X & (__X + 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blcmsk_u32 (unsigned int __X) >{ > return __X ^ (__X + 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blcs_u32 (unsigned int __X) >{ > return __X | (__X + 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsfill_u32 (unsigned int __X) >{ > return __X | (__X - 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsic_u32 (unsigned int __X) >{ > return ~__X | (__X - 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__t1mskc_u32 (unsigned int __X) >{ > return ~__X | (__X + 1); >} > >extern __inline unsigned int __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__tzmsk_u32 (unsigned int __X) >{ > return ~__X & (__X - 1); >} > > > > > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__bextri_u64 (unsigned long long __X, const unsigned int __I) >{ > return __builtin_ia32_bextri_u64 (__X, __I); >} > > > > > > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blcfill_u64 (unsigned long long __X) >{ > return __X & (__X + 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blci_u64 (unsigned long long __X) >{ > return __X | ~(__X + 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blcic_u64 (unsigned long long __X) >{ > return ~__X & (__X + 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blcmsk_u64 (unsigned long long __X) >{ > return __X ^ (__X + 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blcs_u64 (unsigned long long __X) >{ > return __X | (__X + 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsfill_u64 (unsigned long long __X) >{ > return __X | (__X - 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__blsic_u64 (unsigned long long __X) >{ > return ~__X | (__X - 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__t1mskc_u64 (unsigned long long __X) >{ > return ~__X | (__X + 1); >} > >extern __inline unsigned long long __attribute__((__gnu_inline__, __always_inline__, __artificial__)) >__tzmsk_u64 (unsigned long long __X) >{ > return ~__X & (__X - 1); >} > > > > > > >#pragma GCC pop_options ># 61 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/lzcntintrin.h" 1 3 4 ># 63 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/rdseedintrin.h" 1 3 4 ># 32 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/rdseedintrin.h" 3 4 >#pragma GCC push_options >#pragma GCC target("rdseed") > > > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_rdseed16_step (unsigned short *p) >{ > return __builtin_ia32_rdseed_hi_step (p); >} > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_rdseed32_step (unsigned int *p) >{ > return __builtin_ia32_rdseed_si_step (p); >} > > >extern __inline int >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_rdseed64_step (unsigned long long *p) >{ > return __builtin_ia32_rdseed_di_step (p); >} > > > > >#pragma GCC pop_options ># 67 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/prfchwintrin.h" 1 3 4 ># 69 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/fxsrintrin.h" 1 3 4 ># 37 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/fxsrintrin.h" 3 4 >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_fxsave (void *__P) >{ > return __builtin_ia32_fxsave (__P); >} > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_fxrstor (void *__P) >{ > return __builtin_ia32_fxrstor (__P); >} > > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_fxsave64 (void *__P) >{ > return __builtin_ia32_fxsave64 (__P); >} > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_fxrstor64 (void *__P) >{ > return __builtin_ia32_fxrstor64 (__P); >} ># 71 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xsaveintrin.h" 1 3 4 ># 37 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xsaveintrin.h" 3 4 >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xsave (void *__P, long long __M) >{ > return __builtin_ia32_xsave (__P, __M); >} > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xrstor (void *__P, long long __M) >{ > return __builtin_ia32_xrstor (__P, __M); >} > > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xsave64 (void *__P, long long __M) >{ > return __builtin_ia32_xsave64 (__P, __M); >} > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xrstor64 (void *__P, long long __M) >{ > return __builtin_ia32_xrstor64 (__P, __M); >} ># 73 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xsaveoptintrin.h" 1 3 4 ># 37 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/xsaveoptintrin.h" 3 4 >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xsaveopt (void *__P, long long __M) >{ > return __builtin_ia32_xsaveopt (__P, __M); >} > > >extern __inline void >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_xsaveopt64 (void *__P, long long __M) >{ > return __builtin_ia32_xsaveopt64 (__P, __M); >} ># 75 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/adxintrin.h" 1 3 4 ># 31 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/adxintrin.h" 3 4 >extern __inline unsigned char >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_addcarryx_u32 (unsigned char __CF, unsigned int __X, > unsigned int __Y, unsigned int *__P) >{ > return __builtin_ia32_addcarryx_u32 (__CF, __X, __Y, __P); >} > > >extern __inline unsigned char >__attribute__((__gnu_inline__, __always_inline__, __artificial__)) >_addcarryx_u64 (unsigned char __CF, unsigned long __X, > unsigned long __Y, unsigned long long *__P) >{ > return __builtin_ia32_addcarryx_u64 (__CF, __X, __Y, __P); >} ># 77 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/x86intrin.h" 2 3 4 ># 34 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/opt_random.h" 2 3 ># 37 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/opt_random.h" 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template<> > template<typename _UniformRandomNumberGenerator> > void > normal_distribution<double>:: > __generate(typename normal_distribution<double>::result_type* __f, > typename normal_distribution<double>::result_type* __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > typedef uint64_t __uctype; > > if (__f == __t) > return; > > if (_M_saved_available) > { > _M_saved_available = false; > *__f++ = _M_saved * __param.stddev() + __param.mean(); > > if (__f == __t) > return; > } > > constexpr uint64_t __maskval = 0xfffffffffffffull; > static const __m128i __mask = _mm_set1_epi64x(__maskval); > static const __m128i __two = _mm_set1_epi64x(0x4000000000000000ull); > static const __m128d __three = _mm_set1_pd(3.0); > const __m128d __av = _mm_set1_pd(__param.mean()); > > const __uctype __urngmin = __urng.min(); > const __uctype __urngmax = __urng.max(); > const __uctype __urngrange = __urngmax - __urngmin; > const __uctype __uerngrange = __urngrange + 1; > > while (__f + 1 < __t) > { > double __le; > __m128d __x; > do > { > union > { > __m128i __i; > __m128d __d; > } __v; > > if (__urngrange > __maskval) > { > if (__detail::_Power_of_2(__uerngrange)) > __v.__i = _mm_and_si128(_mm_set_epi64x(__urng(), > __urng()), > __mask); > else > { > const __uctype __uerange = __maskval + 1; > const __uctype __scaling = __urngrange / __uerange; > const __uctype __past = __uerange * __scaling; > uint64_t __v1; > do > __v1 = __uctype(__urng()) - __urngmin; > while (__v1 >= __past); > __v1 /= __scaling; > uint64_t __v2; > do > __v2 = __uctype(__urng()) - __urngmin; > while (__v2 >= __past); > __v2 /= __scaling; > > __v.__i = _mm_set_epi64x(__v1, __v2); > } > } > else if (__urngrange == __maskval) > __v.__i = _mm_set_epi64x(__urng(), __urng()); > else if ((__urngrange + 2) * __urngrange >= __maskval > && __detail::_Power_of_2(__uerngrange)) > { > uint64_t __v1 = __urng() * __uerngrange + __urng(); > uint64_t __v2 = __urng() * __uerngrange + __urng(); > > __v.__i = _mm_and_si128(_mm_set_epi64x(__v1, __v2), > __mask); > } > else > { > size_t __nrng = 2; > __uctype __high = __maskval / __uerngrange / __uerngrange; > while (__high > __uerngrange) > { > ++__nrng; > __high /= __uerngrange; > } > const __uctype __highrange = __high + 1; > const __uctype __scaling = __urngrange / __highrange; > const __uctype __past = __highrange * __scaling; > __uctype __tmp; > > uint64_t __v1; > do > { > do > __tmp = __uctype(__urng()) - __urngmin; > while (__tmp >= __past); > __v1 = __tmp / __scaling; > for (size_t __cnt = 0; __cnt < __nrng; ++__cnt) > { > __tmp = __v1; > __v1 *= __uerngrange; > __v1 += __uctype(__urng()) - __urngmin; > } > } > while (__v1 > __maskval || __v1 < __tmp); > > uint64_t __v2; > do > { > do > __tmp = __uctype(__urng()) - __urngmin; > while (__tmp >= __past); > __v2 = __tmp / __scaling; > for (size_t __cnt = 0; __cnt < __nrng; ++__cnt) > { > __tmp = __v2; > __v2 *= __uerngrange; > __v2 += __uctype(__urng()) - __urngmin; > } > } > while (__v2 > __maskval || __v2 < __tmp); > > __v.__i = _mm_set_epi64x(__v1, __v2); > } > > __v.__i = _mm_or_si128(__v.__i, __two); > __x = _mm_sub_pd(__v.__d, __three); > __m128d __m = _mm_mul_pd(__x, __x); > __le = _mm_cvtsd_f64(_mm_hadd_pd (__m, __m)); > } > while (__le == 0.0 || __le >= 1.0); > > double __mult = (std::sqrt(-2.0 * std::log(__le) / __le) > * __param.stddev()); > > __x = _mm_add_pd(_mm_mul_pd(__x, _mm_set1_pd(__mult)), __av); > > _mm_storeu_pd(__f, __x); > __f += 2; > } > > if (__f != __t) > { > result_type __x, __y, __r2; > > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > > do > { > __x = result_type(2.0) * __aurng() - 1.0; > __y = result_type(2.0) * __aurng() - 1.0; > __r2 = __x * __x + __y * __y; > } > while (__r2 > 1.0 || __r2 == 0.0); > > const result_type __mult = std::sqrt(-2 * std::log(__r2) / __r2); > _M_saved = __x * __mult; > _M_saved_available = true; > *__f = __y * __mult * __param.stddev() + __param.mean(); > } > } > > > > >} ># 51 "/usr/include/c++/4.9.0/random" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/random.tcc" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/random.tcc" 3 ># 1 "/usr/include/c++/4.9.0/numeric" 1 3 ># 58 "/usr/include/c++/4.9.0/numeric" 3 ># 59 "/usr/include/c++/4.9.0/numeric" 3 > > > ># 1 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 1 3 ># 65 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 80 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 > template<typename _ForwardIterator, typename _Tp> > void > iota(_ForwardIterator __first, _ForwardIterator __last, _Tp __value) > { > > > > > > ; > > for (; __first != __last; ++__first) > { > *__first = __value; > ++__value; > } > } > > >} > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 118 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 > template<typename _InputIterator, typename _Tp> > inline _Tp > accumulate(_InputIterator __first, _InputIterator __last, _Tp __init) > { > > > ; > > for (; __first != __last; ++__first) > __init = __init + *__first; > return __init; > } ># 144 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 > template<typename _InputIterator, typename _Tp, typename _BinaryOperation> > inline _Tp > accumulate(_InputIterator __first, _InputIterator __last, _Tp __init, > _BinaryOperation __binary_op) > { > > > ; > > for (; __first != __last; ++__first) > __init = __binary_op(__init, *__first); > return __init; > } ># 172 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 > template<typename _InputIterator1, typename _InputIterator2, typename _Tp> > inline _Tp > inner_product(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _Tp __init) > { > > > > ; > > for (; __first1 != __last1; ++__first1, ++__first2) > __init = __init + (*__first1 * *__first2); > return __init; > } ># 203 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 > template<typename _InputIterator1, typename _InputIterator2, typename _Tp, > typename _BinaryOperation1, typename _BinaryOperation2> > inline _Tp > inner_product(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _Tp __init, > _BinaryOperation1 __binary_op1, > _BinaryOperation2 __binary_op2) > { > > > > ; > > for (; __first1 != __last1; ++__first1, ++__first2) > __init = __binary_op1(__init, __binary_op2(*__first1, *__first2)); > return __init; > } ># 235 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 > template<typename _InputIterator, typename _OutputIterator> > _OutputIterator > partial_sum(_InputIterator __first, _InputIterator __last, > _OutputIterator __result) > { > typedef typename iterator_traits<_InputIterator>::value_type _ValueType; > > > > > > ; > > if (__first == __last) > return __result; > _ValueType __value = *__first; > *__result = __value; > while (++__first != __last) > { > __value = __value + *__first; > *++__result = __value; > } > return ++__result; > } ># 275 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 > template<typename _InputIterator, typename _OutputIterator, > typename _BinaryOperation> > _OutputIterator > partial_sum(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, _BinaryOperation __binary_op) > { > typedef typename iterator_traits<_InputIterator>::value_type _ValueType; > > > > > > ; > > if (__first == __last) > return __result; > _ValueType __value = *__first; > *__result = __value; > while (++__first != __last) > { > __value = __binary_op(__value, *__first); > *++__result = __value; > } > return ++__result; > } ># 315 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 > template<typename _InputIterator, typename _OutputIterator> > _OutputIterator > adjacent_difference(_InputIterator __first, > _InputIterator __last, _OutputIterator __result) > { > typedef typename iterator_traits<_InputIterator>::value_type _ValueType; > > > > > > ; > > if (__first == __last) > return __result; > _ValueType __value = *__first; > *__result = __value; > while (++__first != __last) > { > _ValueType __tmp = *__first; > *++__result = __tmp - __value; > __value = std::move(__tmp); > } > return ++__result; > } ># 357 "/usr/include/c++/4.9.0/bits/stl_numeric.h" 3 > template<typename _InputIterator, typename _OutputIterator, > typename _BinaryOperation> > _OutputIterator > adjacent_difference(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, _BinaryOperation __binary_op) > { > typedef typename iterator_traits<_InputIterator>::value_type _ValueType; > > > > > > ; > > if (__first == __last) > return __result; > _ValueType __value = *__first; > *__result = __value; > while (++__first != __last) > { > _ValueType __tmp = *__first; > *++__result = __binary_op(__tmp, __value); > __value = std::move(__tmp); > } > return ++__result; > } > > >} ># 63 "/usr/include/c++/4.9.0/numeric" 2 3 ># 34 "/usr/include/c++/4.9.0/bits/random.tcc" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > namespace __detail > { ># 50 "/usr/include/c++/4.9.0/bits/random.tcc" 3 > template<typename _Tp, _Tp __m, _Tp __a, _Tp __c> > _Tp > _Mod<_Tp, __m, __a, __c, false, true>:: > __calc(_Tp __x) > { > if (__a == 1) > __x %= __m; > else > { > static const _Tp __q = __m / __a; > static const _Tp __r = __m % __a; > > _Tp __t1 = __a * (__x % __q); > _Tp __t2 = __r * (__x / __q); > if (__t1 >= __t2) > __x = __t1 - __t2; > else > __x = __m - __t2 + __t1; > } > > if (__c != 0) > { > const _Tp __d = __m - __x; > if (__d > __c) > __x += __c; > else > __x = __c - __d; > } > return __x; > } > > template<typename _InputIterator, typename _OutputIterator, > typename _Tp> > _OutputIterator > __normalize(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, const _Tp& __factor) > { > for (; __first != __last; ++__first, ++__result) > *__result = *__first / __factor; > return __result; > } > > > } > > > > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m> > constexpr _UIntType > linear_congruential_engine<_UIntType, __a, __c, __m>::multiplier; > > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m> > constexpr _UIntType > linear_congruential_engine<_UIntType, __a, __c, __m>::increment; > > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m> > constexpr _UIntType > linear_congruential_engine<_UIntType, __a, __c, __m>::modulus; > > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m> > constexpr _UIntType > linear_congruential_engine<_UIntType, __a, __c, __m>::default_seed; > > > > > > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m> > void > linear_congruential_engine<_UIntType, __a, __c, __m>:: > seed(result_type __s) > { > if ((__detail::__mod<_UIntType, __m>(__c) == 0) > && (__detail::__mod<_UIntType, __m>(__s) == 0)) > _M_x = 1; > else > _M_x = __detail::__mod<_UIntType, __m>(__s); > } > > > > > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m> > template<typename _Sseq> > typename std::enable_if<std::is_class<_Sseq>::value>::type > linear_congruential_engine<_UIntType, __a, __c, __m>:: > seed(_Sseq& __q) > { > const _UIntType __k0 = __m == 0 ? std::numeric_limits<_UIntType>::digits > : std::__lg(__m); > const _UIntType __k = (__k0 + 31) / 32; > uint_least32_t __arr[__k + 3]; > __q.generate(__arr + 0, __arr + __k + 3); > _UIntType __factor = 1u; > _UIntType __sum = 0u; > for (size_t __j = 0; __j < __k; ++__j) > { > __sum += __arr[__j + 3] * __factor; > __factor *= __detail::_Shift<_UIntType, 32>::__value; > } > seed(__sum); > } > > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m, > typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const linear_congruential_engine<_UIntType, > __a, __c, __m>& __lcr) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > __os.flags(__ios_base::dec | __ios_base::fixed | __ios_base::left); > __os.fill(__os.widen(' ')); > > __os << __lcr._M_x; > > __os.flags(__flags); > __os.fill(__fill); > return __os; > } > > template<typename _UIntType, _UIntType __a, _UIntType __c, _UIntType __m, > typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > linear_congruential_engine<_UIntType, __a, __c, __m>& __lcr) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec); > > __is >> __lcr._M_x; > > __is.flags(__flags); > return __is; > } > > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr size_t > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::word_size; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr size_t > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::state_size; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr size_t > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::shift_size; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr size_t > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::mask_bits; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr _UIntType > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::xor_mask; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr size_t > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::tempering_u; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr _UIntType > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::tempering_d; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr size_t > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::tempering_s; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr _UIntType > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::tempering_b; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr size_t > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::tempering_t; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr _UIntType > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::tempering_c; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr size_t > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::tempering_l; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr _UIntType > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>:: > initialization_multiplier; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > constexpr _UIntType > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::default_seed; > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > void > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>:: > seed(result_type __sd) > { > _M_x[0] = __detail::__mod<_UIntType, > __detail::_Shift<_UIntType, __w>::__value>(__sd); > > for (size_t __i = 1; __i < state_size; ++__i) > { > _UIntType __x = _M_x[__i - 1]; > __x ^= __x >> (__w - 2); > __x *= __f; > __x += __detail::__mod<_UIntType, __n>(__i); > _M_x[__i] = __detail::__mod<_UIntType, > __detail::_Shift<_UIntType, __w>::__value>(__x); > } > _M_p = state_size; > } > > template<typename _UIntType, > size_t __w, size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > template<typename _Sseq> > typename std::enable_if<std::is_class<_Sseq>::value>::type > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>:: > seed(_Sseq& __q) > { > const _UIntType __upper_mask = (~_UIntType()) << __r; > const size_t __k = (__w + 31) / 32; > uint_least32_t __arr[__n * __k]; > __q.generate(__arr + 0, __arr + __n * __k); > > bool __zero = true; > for (size_t __i = 0; __i < state_size; ++__i) > { > _UIntType __factor = 1u; > _UIntType __sum = 0u; > for (size_t __j = 0; __j < __k; ++__j) > { > __sum += __arr[__k * __i + __j] * __factor; > __factor *= __detail::_Shift<_UIntType, 32>::__value; > } > _M_x[__i] = __detail::__mod<_UIntType, > __detail::_Shift<_UIntType, __w>::__value>(__sum); > > if (__zero) > { > if (__i == 0) > { > if ((_M_x[0] & __upper_mask) != 0u) > __zero = false; > } > else if (_M_x[__i] != 0u) > __zero = false; > } > } > if (__zero) > _M_x[0] = __detail::_Shift<_UIntType, __w - 1>::__value; > _M_p = state_size; > } > > template<typename _UIntType, size_t __w, > size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > void > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>:: > _M_gen_rand(void) > { > const _UIntType __upper_mask = (~_UIntType()) << __r; > const _UIntType __lower_mask = ~__upper_mask; > > for (size_t __k = 0; __k < (__n - __m); ++__k) > { > _UIntType __y = ((_M_x[__k] & __upper_mask) > | (_M_x[__k + 1] & __lower_mask)); > _M_x[__k] = (_M_x[__k + __m] ^ (__y >> 1) > ^ ((__y & 0x01) ? __a : 0)); > } > > for (size_t __k = (__n - __m); __k < (__n - 1); ++__k) > { > _UIntType __y = ((_M_x[__k] & __upper_mask) > | (_M_x[__k + 1] & __lower_mask)); > _M_x[__k] = (_M_x[__k + (__m - __n)] ^ (__y >> 1) > ^ ((__y & 0x01) ? __a : 0)); > } > > _UIntType __y = ((_M_x[__n - 1] & __upper_mask) > | (_M_x[0] & __lower_mask)); > _M_x[__n - 1] = (_M_x[__m - 1] ^ (__y >> 1) > ^ ((__y & 0x01) ? __a : 0)); > _M_p = 0; > } > > template<typename _UIntType, size_t __w, > size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > void > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>:: > discard(unsigned long long __z) > { > while (__z > state_size - _M_p) > { > __z -= state_size - _M_p; > _M_gen_rand(); > } > _M_p += __z; > } > > template<typename _UIntType, size_t __w, > size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f> > typename > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>::result_type > mersenne_twister_engine<_UIntType, __w, __n, __m, __r, __a, __u, __d, > __s, __b, __t, __c, __l, __f>:: > operator()() > { > > if (_M_p >= state_size) > _M_gen_rand(); > > > result_type __z = _M_x[_M_p++]; > __z ^= (__z >> __u) & __d; > __z ^= (__z << __s) & __b; > __z ^= (__z << __t) & __c; > __z ^= (__z >> __l); > > return __z; > } > > template<typename _UIntType, size_t __w, > size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const mersenne_twister_engine<_UIntType, __w, __n, __m, > __r, __a, __u, __d, __s, __b, __t, __c, __l, __f>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::dec | __ios_base::fixed | __ios_base::left); > __os.fill(__space); > > for (size_t __i = 0; __i < __n; ++__i) > __os << __x._M_x[__i] << __space; > __os << __x._M_p; > > __os.flags(__flags); > __os.fill(__fill); > return __os; > } > > template<typename _UIntType, size_t __w, > size_t __n, size_t __m, size_t __r, > _UIntType __a, size_t __u, _UIntType __d, size_t __s, > _UIntType __b, size_t __t, _UIntType __c, size_t __l, > _UIntType __f, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > mersenne_twister_engine<_UIntType, __w, __n, __m, > __r, __a, __u, __d, __s, __b, __t, __c, __l, __f>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > for (size_t __i = 0; __i < __n; ++__i) > __is >> __x._M_x[__i]; > __is >> __x._M_p; > > __is.flags(__flags); > return __is; > } > > > template<typename _UIntType, size_t __w, size_t __s, size_t __r> > constexpr size_t > subtract_with_carry_engine<_UIntType, __w, __s, __r>::word_size; > > template<typename _UIntType, size_t __w, size_t __s, size_t __r> > constexpr size_t > subtract_with_carry_engine<_UIntType, __w, __s, __r>::short_lag; > > template<typename _UIntType, size_t __w, size_t __s, size_t __r> > constexpr size_t > subtract_with_carry_engine<_UIntType, __w, __s, __r>::long_lag; > > template<typename _UIntType, size_t __w, size_t __s, size_t __r> > constexpr _UIntType > subtract_with_carry_engine<_UIntType, __w, __s, __r>::default_seed; > > template<typename _UIntType, size_t __w, size_t __s, size_t __r> > void > subtract_with_carry_engine<_UIntType, __w, __s, __r>:: > seed(result_type __value) > { > std::linear_congruential_engine<result_type, 40014u, 0u, 2147483563u> > __lcg(__value == 0u ? default_seed : __value); > > const size_t __n = (__w + 31) / 32; > > for (size_t __i = 0; __i < long_lag; ++__i) > { > _UIntType __sum = 0u; > _UIntType __factor = 1u; > for (size_t __j = 0; __j < __n; ++__j) > { > __sum += __detail::__mod<uint_least32_t, > __detail::_Shift<uint_least32_t, 32>::__value> > (__lcg()) * __factor; > __factor *= __detail::_Shift<_UIntType, 32>::__value; > } > _M_x[__i] = __detail::__mod<_UIntType, > __detail::_Shift<_UIntType, __w>::__value>(__sum); > } > _M_carry = (_M_x[long_lag - 1] == 0) ? 1 : 0; > _M_p = 0; > } > > template<typename _UIntType, size_t __w, size_t __s, size_t __r> > template<typename _Sseq> > typename std::enable_if<std::is_class<_Sseq>::value>::type > subtract_with_carry_engine<_UIntType, __w, __s, __r>:: > seed(_Sseq& __q) > { > const size_t __k = (__w + 31) / 32; > uint_least32_t __arr[__r * __k]; > __q.generate(__arr + 0, __arr + __r * __k); > > for (size_t __i = 0; __i < long_lag; ++__i) > { > _UIntType __sum = 0u; > _UIntType __factor = 1u; > for (size_t __j = 0; __j < __k; ++__j) > { > __sum += __arr[__k * __i + __j] * __factor; > __factor *= __detail::_Shift<_UIntType, 32>::__value; > } > _M_x[__i] = __detail::__mod<_UIntType, > __detail::_Shift<_UIntType, __w>::__value>(__sum); > } > _M_carry = (_M_x[long_lag - 1] == 0) ? 1 : 0; > _M_p = 0; > } > > template<typename _UIntType, size_t __w, size_t __s, size_t __r> > typename subtract_with_carry_engine<_UIntType, __w, __s, __r>:: > result_type > subtract_with_carry_engine<_UIntType, __w, __s, __r>:: > operator()() > { > > long __ps = _M_p - short_lag; > if (__ps < 0) > __ps += long_lag; > > > > > _UIntType __xi; > if (_M_x[__ps] >= _M_x[_M_p] + _M_carry) > { > __xi = _M_x[__ps] - _M_x[_M_p] - _M_carry; > _M_carry = 0; > } > else > { > __xi = (__detail::_Shift<_UIntType, __w>::__value > - _M_x[_M_p] - _M_carry + _M_x[__ps]); > _M_carry = 1; > } > _M_x[_M_p] = __xi; > > > if (++_M_p >= long_lag) > _M_p = 0; > > return __xi; > } > > template<typename _UIntType, size_t __w, size_t __s, size_t __r, > typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const subtract_with_carry_engine<_UIntType, > __w, __s, __r>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::dec | __ios_base::fixed | __ios_base::left); > __os.fill(__space); > > for (size_t __i = 0; __i < __r; ++__i) > __os << __x._M_x[__i] << __space; > __os << __x._M_carry << __space << __x._M_p; > > __os.flags(__flags); > __os.fill(__fill); > return __os; > } > > template<typename _UIntType, size_t __w, size_t __s, size_t __r, > typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > subtract_with_carry_engine<_UIntType, __w, __s, __r>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > for (size_t __i = 0; __i < __r; ++__i) > __is >> __x._M_x[__i]; > __is >> __x._M_carry; > __is >> __x._M_p; > > __is.flags(__flags); > return __is; > } > > > template<typename _RandomNumberEngine, size_t __p, size_t __r> > constexpr size_t > discard_block_engine<_RandomNumberEngine, __p, __r>::block_size; > > template<typename _RandomNumberEngine, size_t __p, size_t __r> > constexpr size_t > discard_block_engine<_RandomNumberEngine, __p, __r>::used_block; > > template<typename _RandomNumberEngine, size_t __p, size_t __r> > typename discard_block_engine<_RandomNumberEngine, > __p, __r>::result_type > discard_block_engine<_RandomNumberEngine, __p, __r>:: > operator()() > { > if (_M_n >= used_block) > { > _M_b.discard(block_size - _M_n); > _M_n = 0; > } > ++_M_n; > return _M_b(); > } > > template<typename _RandomNumberEngine, size_t __p, size_t __r, > typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const discard_block_engine<_RandomNumberEngine, > __p, __r>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::dec | __ios_base::fixed | __ios_base::left); > __os.fill(__space); > > __os << __x.base() << __space << __x._M_n; > > __os.flags(__flags); > __os.fill(__fill); > return __os; > } > > template<typename _RandomNumberEngine, size_t __p, size_t __r, > typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > discard_block_engine<_RandomNumberEngine, __p, __r>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > __is >> __x._M_b >> __x._M_n; > > __is.flags(__flags); > return __is; > } > > > template<typename _RandomNumberEngine, size_t __w, typename _UIntType> > typename independent_bits_engine<_RandomNumberEngine, __w, _UIntType>:: > result_type > independent_bits_engine<_RandomNumberEngine, __w, _UIntType>:: > operator()() > { > typedef typename _RandomNumberEngine::result_type _Eresult_type; > const _Eresult_type __r > = (_M_b.max() - _M_b.min() < std::numeric_limits<_Eresult_type>::max() > ? _M_b.max() - _M_b.min() + 1 : 0); > const unsigned __edig = std::numeric_limits<_Eresult_type>::digits; > const unsigned __m = __r ? std::__lg(__r) : __edig; > > typedef typename std::common_type<_Eresult_type, result_type>::type > __ctype; > const unsigned __cdig = std::numeric_limits<__ctype>::digits; > > unsigned __n, __n0; > __ctype __s0, __s1, __y0, __y1; > > for (size_t __i = 0; __i < 2; ++__i) > { > __n = (__w + __m - 1) / __m + __i; > __n0 = __n - __w % __n; > const unsigned __w0 = __w / __n; > > __s0 = 0; > __s1 = 0; > if (__w0 < __cdig) > { > __s0 = __ctype(1) << __w0; > __s1 = __s0 << 1; > } > > __y0 = 0; > __y1 = 0; > if (__r) > { > __y0 = __s0 * (__r / __s0); > if (__s1) > __y1 = __s1 * (__r / __s1); > > if (__r - __y0 <= __y0 / __n) > break; > } > else > break; > } > > result_type __sum = 0; > for (size_t __k = 0; __k < __n0; ++__k) > { > __ctype __u; > do > __u = _M_b() - _M_b.min(); > while (__y0 && __u >= __y0); > __sum = __s0 * __sum + (__s0 ? __u % __s0 : __u); > } > for (size_t __k = __n0; __k < __n; ++__k) > { > __ctype __u; > do > __u = _M_b() - _M_b.min(); > while (__y1 && __u >= __y1); > __sum = __s1 * __sum + (__s1 ? __u % __s1 : __u); > } > return __sum; > } > > > template<typename _RandomNumberEngine, size_t __k> > constexpr size_t > shuffle_order_engine<_RandomNumberEngine, __k>::table_size; > > template<typename _RandomNumberEngine, size_t __k> > typename shuffle_order_engine<_RandomNumberEngine, __k>::result_type > shuffle_order_engine<_RandomNumberEngine, __k>:: > operator()() > { > size_t __j = __k * ((_M_y - _M_b.min()) > / (_M_b.max() - _M_b.min() + 1.0L)); > _M_y = _M_v[__j]; > _M_v[__j] = _M_b(); > > return _M_y; > } > > template<typename _RandomNumberEngine, size_t __k, > typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const shuffle_order_engine<_RandomNumberEngine, __k>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::dec | __ios_base::fixed | __ios_base::left); > __os.fill(__space); > > __os << __x.base(); > for (size_t __i = 0; __i < __k; ++__i) > __os << __space << __x._M_v[__i]; > __os << __space << __x._M_y; > > __os.flags(__flags); > __os.fill(__fill); > return __os; > } > > template<typename _RandomNumberEngine, size_t __k, > typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > shuffle_order_engine<_RandomNumberEngine, __k>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > __is >> __x._M_b; > for (size_t __i = 0; __i < __k; ++__i) > __is >> __x._M_v[__i]; > __is >> __x._M_y; > > __is.flags(__flags); > return __is; > } > > > template<typename _IntType> > template<typename _UniformRandomNumberGenerator> > typename uniform_int_distribution<_IntType>::result_type > uniform_int_distribution<_IntType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > typedef typename _UniformRandomNumberGenerator::result_type > _Gresult_type; > typedef typename std::make_unsigned<result_type>::type __utype; > typedef typename std::common_type<_Gresult_type, __utype>::type > __uctype; > > const __uctype __urngmin = __urng.min(); > const __uctype __urngmax = __urng.max(); > const __uctype __urngrange = __urngmax - __urngmin; > const __uctype __urange > = __uctype(__param.b()) - __uctype(__param.a()); > > __uctype __ret; > > if (__urngrange > __urange) > { > > const __uctype __uerange = __urange + 1; > const __uctype __scaling = __urngrange / __uerange; > const __uctype __past = __uerange * __scaling; > do > __ret = __uctype(__urng()) - __urngmin; > while (__ret >= __past); > __ret /= __scaling; > } > else if (__urngrange < __urange) > { ># 924 "/usr/include/c++/4.9.0/bits/random.tcc" 3 > __uctype __tmp; > do > { > const __uctype __uerngrange = __urngrange + 1; > __tmp = (__uerngrange * operator() > (__urng, param_type(0, __urange / __uerngrange))); > __ret = __tmp + (__uctype(__urng()) - __urngmin); > } > while (__ret > __urange || __ret < __tmp); > } > else > __ret = __uctype(__urng()) - __urngmin; > > return __ret + __param.a(); > } > > > template<typename _IntType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > uniform_int_distribution<_IntType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > typedef typename _UniformRandomNumberGenerator::result_type > _Gresult_type; > typedef typename std::make_unsigned<result_type>::type __utype; > typedef typename std::common_type<_Gresult_type, __utype>::type > __uctype; > > const __uctype __urngmin = __urng.min(); > const __uctype __urngmax = __urng.max(); > const __uctype __urngrange = __urngmax - __urngmin; > const __uctype __urange > = __uctype(__param.b()) - __uctype(__param.a()); > > __uctype __ret; > > if (__urngrange > __urange) > { > if (__detail::_Power_of_2(__urngrange + 1) > && __detail::_Power_of_2(__urange + 1)) > { > while (__f != __t) > { > __ret = __uctype(__urng()) - __urngmin; > *__f++ = (__ret & __urange) + __param.a(); > } > } > else > { > > const __uctype __uerange = __urange + 1; > const __uctype __scaling = __urngrange / __uerange; > const __uctype __past = __uerange * __scaling; > while (__f != __t) > { > do > __ret = __uctype(__urng()) - __urngmin; > while (__ret >= __past); > *__f++ = __ret / __scaling + __param.a(); > } > } > } > else if (__urngrange < __urange) > { ># 1008 "/usr/include/c++/4.9.0/bits/random.tcc" 3 > __uctype __tmp; > while (__f != __t) > { > do > { > const __uctype __uerngrange = __urngrange + 1; > __tmp = (__uerngrange * operator() > (__urng, param_type(0, __urange / __uerngrange))); > __ret = __tmp + (__uctype(__urng()) - __urngmin); > } > while (__ret > __urange || __ret < __tmp); > *__f++ = __ret; > } > } > else > while (__f != __t) > *__f++ = __uctype(__urng()) - __urngmin + __param.a(); > } > > template<typename _IntType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const uniform_int_distribution<_IntType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > > __os << __x.a() << __space << __x.b(); > > __os.flags(__flags); > __os.fill(__fill); > return __os; > } > > template<typename _IntType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > uniform_int_distribution<_IntType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _IntType __a, __b; > __is >> __a >> __b; > __x.param(typename uniform_int_distribution<_IntType>:: > param_type(__a, __b)); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > uniform_real_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > auto __range = __p.b() - __p.a(); > while (__f != __t) > *__f++ = __aurng() * __range + __p.a(); > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const uniform_real_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.a() << __space << __x.b(); > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > uniform_real_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::skipws); > > _RealType __a, __b; > __is >> __a >> __b; > __x.param(typename uniform_real_distribution<_RealType>:: > param_type(__a, __b)); > > __is.flags(__flags); > return __is; > } > > > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > std::bernoulli_distribution:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > auto __limit = __p.p() * (__aurng.max() - __aurng.min()); > > while (__f != __t) > *__f++ = (__aurng() - __aurng.min()) < __limit; > } > > template<typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const bernoulli_distribution& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__os.widen(' ')); > __os.precision(std::numeric_limits<double>::max_digits10); > > __os << __x.p(); > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > > template<typename _IntType> > template<typename _UniformRandomNumberGenerator> > typename geometric_distribution<_IntType>::result_type > geometric_distribution<_IntType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > > const double __naf = > (1 - std::numeric_limits<double>::epsilon()) / 2; > > const double __thr = > std::numeric_limits<_IntType>::max() + __naf; > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > double __cand; > do > __cand = std::floor(std::log(1.0 - __aurng()) / __param._M_log_1_p); > while (__cand >= __thr); > > return result_type(__cand + __naf); > } > > template<typename _IntType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > geometric_distribution<_IntType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > > > const double __naf = > (1 - std::numeric_limits<double>::epsilon()) / 2; > > const double __thr = > std::numeric_limits<_IntType>::max() + __naf; > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > while (__f != __t) > { > double __cand; > do > __cand = std::floor(std::log(1.0 - __aurng()) > / __param._M_log_1_p); > while (__cand >= __thr); > > *__f++ = __cand + __naf; > } > } > > template<typename _IntType, > typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const geometric_distribution<_IntType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__os.widen(' ')); > __os.precision(std::numeric_limits<double>::max_digits10); > > __os << __x.p(); > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _IntType, > typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > geometric_distribution<_IntType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::skipws); > > double __p; > __is >> __p; > __x.param(typename geometric_distribution<_IntType>::param_type(__p)); > > __is.flags(__flags); > return __is; > } > > > template<typename _IntType> > template<typename _UniformRandomNumberGenerator> > typename negative_binomial_distribution<_IntType>::result_type > negative_binomial_distribution<_IntType>:: > operator()(_UniformRandomNumberGenerator& __urng) > { > const double __y = _M_gd(__urng); > > > std::poisson_distribution<result_type> __poisson(__y); > return __poisson(__urng); > } > > template<typename _IntType> > template<typename _UniformRandomNumberGenerator> > typename negative_binomial_distribution<_IntType>::result_type > negative_binomial_distribution<_IntType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > typedef typename std::gamma_distribution<double>::param_type > param_type; > > const double __y = > _M_gd(__urng, param_type(__p.k(), (1.0 - __p.p()) / __p.p())); > > std::poisson_distribution<result_type> __poisson(__y); > return __poisson(__urng); > } > > template<typename _IntType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > negative_binomial_distribution<_IntType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { > > while (__f != __t) > { > const double __y = _M_gd(__urng); > > > std::poisson_distribution<result_type> __poisson(__y); > *__f++ = __poisson(__urng); > } > } > > template<typename _IntType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > negative_binomial_distribution<_IntType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > typename std::gamma_distribution<result_type>::param_type > __p2(__p.k(), (1.0 - __p.p()) / __p.p()); > > while (__f != __t) > { > const double __y = _M_gd(__urng, __p2); > > std::poisson_distribution<result_type> __poisson(__y); > *__f++ = __poisson(__urng); > } > } > > template<typename _IntType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const negative_binomial_distribution<_IntType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__os.widen(' ')); > __os.precision(std::numeric_limits<double>::max_digits10); > > __os << __x.k() << __space << __x.p() > << __space << __x._M_gd; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _IntType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > negative_binomial_distribution<_IntType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::skipws); > > _IntType __k; > double __p; > __is >> __k >> __p >> __x._M_gd; > __x.param(typename negative_binomial_distribution<_IntType>:: > param_type(__k, __p)); > > __is.flags(__flags); > return __is; > } > > > template<typename _IntType> > void > poisson_distribution<_IntType>::param_type:: > _M_initialize() > { > > if (_M_mean >= 12) > { > const double __m = std::floor(_M_mean); > _M_lm_thr = std::log(_M_mean); > _M_lfm = std::lgamma(__m + 1); > _M_sm = std::sqrt(__m); > > const double __pi_4 = 0.7853981633974483096156608458198757L; > const double __dx = std::sqrt(2 * __m * std::log(32 * __m > / __pi_4)); > _M_d = std::round(std::max(6.0, std::min(__m, __dx))); > const double __cx = 2 * __m + _M_d; > _M_scx = std::sqrt(__cx / 2); > _M_1cx = 1 / __cx; > > _M_c2b = std::sqrt(__pi_4 * __cx) * std::exp(_M_1cx); > _M_cb = 2 * __cx * std::exp(-_M_d * _M_1cx * (1 + _M_d / 2)) > / _M_d; > } > else > > _M_lm_thr = std::exp(-_M_mean); > } ># 1432 "/usr/include/c++/4.9.0/bits/random.tcc" 3 > template<typename _IntType> > template<typename _UniformRandomNumberGenerator> > typename poisson_distribution<_IntType>::result_type > poisson_distribution<_IntType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > if (__param.mean() >= 12) > { > double __x; > > > const double __naf = > (1 - std::numeric_limits<double>::epsilon()) / 2; > const double __thr = > std::numeric_limits<_IntType>::max() + __naf; > > const double __m = std::floor(__param.mean()); > > const double __spi_2 = 1.2533141373155002512078826424055226L; > const double __c1 = __param._M_sm * __spi_2; > const double __c2 = __param._M_c2b + __c1; > const double __c3 = __c2 + 1; > const double __c4 = __c3 + 1; > > const double __e178 = 1.0129030479320018583185514777512983L; > const double __c5 = __c4 + __e178; > const double __c = __param._M_cb + __c5; > const double __2cx = 2 * (2 * __m + __param._M_d); > > bool __reject = true; > do > { > const double __u = __c * __aurng(); > const double __e = -std::log(1.0 - __aurng()); > > double __w = 0.0; > > if (__u <= __c1) > { > const double __n = _M_nd(__urng); > const double __y = -std::abs(__n) * __param._M_sm - 1; > __x = std::floor(__y); > __w = -__n * __n / 2; > if (__x < -__m) > continue; > } > else if (__u <= __c2) > { > const double __n = _M_nd(__urng); > const double __y = 1 + std::abs(__n) * __param._M_scx; > __x = std::ceil(__y); > __w = __y * (2 - __y) * __param._M_1cx; > if (__x > __param._M_d) > continue; > } > else if (__u <= __c3) > > > __x = -1; > else if (__u <= __c4) > __x = 0; > else if (__u <= __c5) > __x = 1; > else > { > const double __v = -std::log(1.0 - __aurng()); > const double __y = __param._M_d > + __v * __2cx / __param._M_d; > __x = std::ceil(__y); > __w = -__param._M_d * __param._M_1cx * (1 + __y / 2); > } > > __reject = (__w - __e - __x * __param._M_lm_thr > > __param._M_lfm - std::lgamma(__x + __m + 1)); > > __reject |= __x + __m >= __thr; > > } while (__reject); > > return result_type(__x + __m + __naf); > } > else > > { > _IntType __x = 0; > double __prod = 1.0; > > do > { > __prod *= __aurng(); > __x += 1; > } > while (__prod > __param._M_lm_thr); > > return __x - 1; > } > } > > template<typename _IntType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > poisson_distribution<_IntType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > > while (__f != __t) > *__f++ = this->operator()(__urng, __param); > } > > template<typename _IntType, > typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const poisson_distribution<_IntType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<double>::max_digits10); > > __os << __x.mean() << __space << __x._M_nd; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _IntType, > typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > poisson_distribution<_IntType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::skipws); > > double __mean; > __is >> __mean >> __x._M_nd; > __x.param(typename poisson_distribution<_IntType>::param_type(__mean)); > > __is.flags(__flags); > return __is; > } > > > template<typename _IntType> > void > binomial_distribution<_IntType>::param_type:: > _M_initialize() > { > const double __p12 = _M_p <= 0.5 ? _M_p : 1.0 - _M_p; > > _M_easy = true; > > > if (_M_t * __p12 >= 8) > { > _M_easy = false; > const double __np = std::floor(_M_t * __p12); > const double __pa = __np / _M_t; > const double __1p = 1 - __pa; > > const double __pi_4 = 0.7853981633974483096156608458198757L; > const double __d1x = > std::sqrt(__np * __1p * std::log(32 * __np > / (81 * __pi_4 * __1p))); > _M_d1 = std::round(std::max(1.0, __d1x)); > const double __d2x = > std::sqrt(__np * __1p * std::log(32 * _M_t * __1p > / (__pi_4 * __pa))); > _M_d2 = std::round(std::max(1.0, __d2x)); > > > const double __spi_2 = 1.2533141373155002512078826424055226L; > _M_s1 = std::sqrt(__np * __1p) * (1 + _M_d1 / (4 * __np)); > _M_s2 = std::sqrt(__np * __1p) * (1 + _M_d2 / (4 * _M_t * __1p)); > _M_c = 2 * _M_d1 / __np; > _M_a1 = std::exp(_M_c) * _M_s1 * __spi_2; > const double __a12 = _M_a1 + _M_s2 * __spi_2; > const double __s1s = _M_s1 * _M_s1; > _M_a123 = __a12 + (std::exp(_M_d1 / (_M_t * __1p)) > * 2 * __s1s / _M_d1 > * std::exp(-_M_d1 * _M_d1 / (2 * __s1s))); > const double __s2s = _M_s2 * _M_s2; > _M_s = (_M_a123 + 2 * __s2s / _M_d2 > * std::exp(-_M_d2 * _M_d2 / (2 * __s2s))); > _M_lf = (std::lgamma(__np + 1) > + std::lgamma(_M_t - __np + 1)); > _M_lp1p = std::log(__pa / __1p); > > _M_q = -std::log(1 - (__p12 - __pa) / __1p); > } > else > > _M_q = -std::log(1 - __p12); > } > > template<typename _IntType> > template<typename _UniformRandomNumberGenerator> > typename binomial_distribution<_IntType>::result_type > binomial_distribution<_IntType>:: > _M_waiting(_UniformRandomNumberGenerator& __urng, > _IntType __t, double __q) > { > _IntType __x = 0; > double __sum = 0.0; > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > do > { > if (__t == __x) > return __x; > const double __e = -std::log(1.0 - __aurng()); > __sum += __e / (__t - __x); > __x += 1; > } > while (__sum <= __q); > > return __x - 1; > } ># 1682 "/usr/include/c++/4.9.0/bits/random.tcc" 3 > template<typename _IntType> > template<typename _UniformRandomNumberGenerator> > typename binomial_distribution<_IntType>::result_type > binomial_distribution<_IntType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > result_type __ret; > const _IntType __t = __param.t(); > const double __p = __param.p(); > const double __p12 = __p <= 0.5 ? __p : 1.0 - __p; > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > > if (!__param._M_easy) > { > double __x; > > > const double __naf = > (1 - std::numeric_limits<double>::epsilon()) / 2; > const double __thr = > std::numeric_limits<_IntType>::max() + __naf; > > const double __np = std::floor(__t * __p12); > > > const double __spi_2 = 1.2533141373155002512078826424055226L; > const double __a1 = __param._M_a1; > const double __a12 = __a1 + __param._M_s2 * __spi_2; > const double __a123 = __param._M_a123; > const double __s1s = __param._M_s1 * __param._M_s1; > const double __s2s = __param._M_s2 * __param._M_s2; > > bool __reject; > do > { > const double __u = __param._M_s * __aurng(); > > double __v; > > if (__u <= __a1) > { > const double __n = _M_nd(__urng); > const double __y = __param._M_s1 * std::abs(__n); > __reject = __y >= __param._M_d1; > if (!__reject) > { > const double __e = -std::log(1.0 - __aurng()); > __x = std::floor(__y); > __v = -__e - __n * __n / 2 + __param._M_c; > } > } > else if (__u <= __a12) > { > const double __n = _M_nd(__urng); > const double __y = __param._M_s2 * std::abs(__n); > __reject = __y >= __param._M_d2; > if (!__reject) > { > const double __e = -std::log(1.0 - __aurng()); > __x = std::floor(-__y); > __v = -__e - __n * __n / 2; > } > } > else if (__u <= __a123) > { > const double __e1 = -std::log(1.0 - __aurng()); > const double __e2 = -std::log(1.0 - __aurng()); > > const double __y = __param._M_d1 > + 2 * __s1s * __e1 / __param._M_d1; > __x = std::floor(__y); > __v = (-__e2 + __param._M_d1 * (1 / (__t - __np) > -__y / (2 * __s1s))); > __reject = false; > } > else > { > const double __e1 = -std::log(1.0 - __aurng()); > const double __e2 = -std::log(1.0 - __aurng()); > > const double __y = __param._M_d2 > + 2 * __s2s * __e1 / __param._M_d2; > __x = std::floor(-__y); > __v = -__e2 - __param._M_d2 * __y / (2 * __s2s); > __reject = false; > } > > __reject = __reject || __x < -__np || __x > __t - __np; > if (!__reject) > { > const double __lfx = > std::lgamma(__np + __x + 1) > + std::lgamma(__t - (__np + __x) + 1); > __reject = __v > __param._M_lf - __lfx > + __x * __param._M_lp1p; > } > > __reject |= __x + __np >= __thr; > } > while (__reject); > > __x += __np + __naf; > > const _IntType __z = _M_waiting(__urng, __t - _IntType(__x), > __param._M_q); > __ret = _IntType(__x) + __z; > } > else > > __ret = _M_waiting(__urng, __t, __param._M_q); > > if (__p12 != __p) > __ret = __t - __ret; > return __ret; > } > > template<typename _IntType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > binomial_distribution<_IntType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > > while (__f != __t) > *__f++ = this->operator()(__urng, __param); > } > > template<typename _IntType, > typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const binomial_distribution<_IntType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<double>::max_digits10); > > __os << __x.t() << __space << __x.p() > << __space << __x._M_nd; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _IntType, > typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > binomial_distribution<_IntType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _IntType __t; > double __p; > __is >> __t >> __p >> __x._M_nd; > __x.param(typename binomial_distribution<_IntType>:: > param_type(__t, __p)); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > std::exponential_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > while (__f != __t) > *__f++ = -std::log(result_type(1) - __aurng()) / __p.lambda(); > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const exponential_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__os.widen(' ')); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.lambda(); > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > exponential_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _RealType __lambda; > __is >> __lambda; > __x.param(typename exponential_distribution<_RealType>:: > param_type(__lambda)); > > __is.flags(__flags); > return __is; > } ># 1931 "/usr/include/c++/4.9.0/bits/random.tcc" 3 > template<typename _RealType> > template<typename _UniformRandomNumberGenerator> > typename normal_distribution<_RealType>::result_type > normal_distribution<_RealType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > result_type __ret; > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > > if (_M_saved_available) > { > _M_saved_available = false; > __ret = _M_saved; > } > else > { > result_type __x, __y, __r2; > do > { > __x = result_type(2.0) * __aurng() - 1.0; > __y = result_type(2.0) * __aurng() - 1.0; > __r2 = __x * __x + __y * __y; > } > while (__r2 > 1.0 || __r2 == 0.0); > > const result_type __mult = std::sqrt(-2 * std::log(__r2) / __r2); > _M_saved = __x * __mult; > _M_saved_available = true; > __ret = __y * __mult; > } > > __ret = __ret * __param.stddev() + __param.mean(); > return __ret; > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > normal_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > > if (__f == __t) > return; > > if (_M_saved_available) > { > _M_saved_available = false; > *__f++ = _M_saved * __param.stddev() + __param.mean(); > > if (__f == __t) > return; > } > > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > > while (__f + 1 < __t) > { > result_type __x, __y, __r2; > do > { > __x = result_type(2.0) * __aurng() - 1.0; > __y = result_type(2.0) * __aurng() - 1.0; > __r2 = __x * __x + __y * __y; > } > while (__r2 > 1.0 || __r2 == 0.0); > > const result_type __mult = std::sqrt(-2 * std::log(__r2) / __r2); > *__f++ = __y * __mult * __param.stddev() + __param.mean(); > *__f++ = __x * __mult * __param.stddev() + __param.mean(); > } > > if (__f != __t) > { > result_type __x, __y, __r2; > do > { > __x = result_type(2.0) * __aurng() - 1.0; > __y = result_type(2.0) * __aurng() - 1.0; > __r2 = __x * __x + __y * __y; > } > while (__r2 > 1.0 || __r2 == 0.0); > > const result_type __mult = std::sqrt(-2 * std::log(__r2) / __r2); > _M_saved = __x * __mult; > _M_saved_available = true; > *__f = __y * __mult * __param.stddev() + __param.mean(); > } > } > > template<typename _RealType> > bool > operator==(const std::normal_distribution<_RealType>& __d1, > const std::normal_distribution<_RealType>& __d2) > { > if (__d1._M_param == __d2._M_param > && __d1._M_saved_available == __d2._M_saved_available) > { > if (__d1._M_saved_available > && __d1._M_saved == __d2._M_saved) > return true; > else if(!__d1._M_saved_available) > return true; > else > return false; > } > else > return false; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const normal_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.mean() << __space << __x.stddev() > << __space << __x._M_saved_available; > if (__x._M_saved_available) > __os << __space << __x._M_saved; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > normal_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > double __mean, __stddev; > __is >> __mean >> __stddev > >> __x._M_saved_available; > if (__x._M_saved_available) > __is >> __x._M_saved; > __x.param(typename normal_distribution<_RealType>:: > param_type(__mean, __stddev)); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > lognormal_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > while (__f != __t) > *__f++ = std::exp(__p.s() * _M_nd(__urng) + __p.m()); > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const lognormal_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.m() << __space << __x.s() > << __space << __x._M_nd; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > lognormal_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _RealType __m, __s; > __is >> __m >> __s >> __x._M_nd; > __x.param(typename lognormal_distribution<_RealType>:: > param_type(__m, __s)); > > __is.flags(__flags); > return __is; > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > std::chi_squared_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { > > while (__f != __t) > *__f++ = 2 * _M_gd(__urng); > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > std::chi_squared_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const typename > std::gamma_distribution<result_type>::param_type& __p) > { > > while (__f != __t) > *__f++ = 2 * _M_gd(__urng, __p); > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const chi_squared_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.n() << __space << __x._M_gd; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > chi_squared_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _RealType __n; > __is >> __n >> __x._M_gd; > __x.param(typename chi_squared_distribution<_RealType>:: > param_type(__n)); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > template<typename _UniformRandomNumberGenerator> > typename cauchy_distribution<_RealType>::result_type > cauchy_distribution<_RealType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > _RealType __u; > do > __u = __aurng(); > while (__u == 0.5); > > const _RealType __pi = 3.1415926535897932384626433832795029L; > return __p.a() + __p.b() * std::tan(__pi * __u); > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > cauchy_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > const _RealType __pi = 3.1415926535897932384626433832795029L; > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > while (__f != __t) > { > _RealType __u; > do > __u = __aurng(); > while (__u == 0.5); > > *__f++ = __p.a() + __p.b() * std::tan(__pi * __u); > } > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const cauchy_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.a() << __space << __x.b(); > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > cauchy_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _RealType __a, __b; > __is >> __a >> __b; > __x.param(typename cauchy_distribution<_RealType>:: > param_type(__a, __b)); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > std::fisher_f_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { > > while (__f != __t) > *__f++ = ((_M_gd_x(__urng) * n()) / (_M_gd_y(__urng) * m())); > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > std::fisher_f_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > typedef typename std::gamma_distribution<result_type>::param_type > param_type; > param_type __p1(__p.m() / 2); > param_type __p2(__p.n() / 2); > while (__f != __t) > *__f++ = ((_M_gd_x(__urng, __p1) * n()) > / (_M_gd_y(__urng, __p2) * m())); > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const fisher_f_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.m() << __space << __x.n() > << __space << __x._M_gd_x << __space << __x._M_gd_y; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > fisher_f_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _RealType __m, __n; > __is >> __m >> __n >> __x._M_gd_x >> __x._M_gd_y; > __x.param(typename fisher_f_distribution<_RealType>:: > param_type(__m, __n)); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > std::student_t_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng) > { > > while (__f != __t) > *__f++ = _M_nd(__urng) * std::sqrt(n() / _M_gd(__urng)); > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > std::student_t_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > typename std::gamma_distribution<result_type>::param_type > __p2(__p.n() / 2, 2); > while (__f != __t) > *__f++ = _M_nd(__urng) * std::sqrt(__p.n() / _M_gd(__urng, __p2)); > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const student_t_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.n() << __space << __x._M_nd << __space << __x._M_gd; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > student_t_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _RealType __n; > __is >> __n >> __x._M_nd >> __x._M_gd; > __x.param(typename student_t_distribution<_RealType>::param_type(__n)); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > void > gamma_distribution<_RealType>::param_type:: > _M_initialize() > { > _M_malpha = _M_alpha < 1.0 ? _M_alpha + _RealType(1.0) : _M_alpha; > > const _RealType __a1 = _M_malpha - _RealType(1.0) / _RealType(3.0); > _M_a2 = _RealType(1.0) / std::sqrt(_RealType(9.0) * __a1); > } > > > > > > > template<typename _RealType> > template<typename _UniformRandomNumberGenerator> > typename gamma_distribution<_RealType>::result_type > gamma_distribution<_RealType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > > result_type __u, __v, __n; > const result_type __a1 = (__param._M_malpha > - _RealType(1.0) / _RealType(3.0)); > > do > { > do > { > __n = _M_nd(__urng); > __v = result_type(1.0) + __param._M_a2 * __n; > } > while (__v <= 0.0); > > __v = __v * __v * __v; > __u = __aurng(); > } > while (__u > result_type(1.0) - 0.331 * __n * __n * __n * __n > && (std::log(__u) > (0.5 * __n * __n + __a1 > * (1.0 - __v + std::log(__v))))); > > if (__param.alpha() == __param._M_malpha) > return __a1 * __v * __param.beta(); > else > { > do > __u = __aurng(); > while (__u == 0.0); > > return (std::pow(__u, result_type(1.0) / __param.alpha()) > * __a1 * __v * __param.beta()); > } > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > gamma_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > > result_type __u, __v, __n; > const result_type __a1 = (__param._M_malpha > - _RealType(1.0) / _RealType(3.0)); > > if (__param.alpha() == __param._M_malpha) > while (__f != __t) > { > do > { > do > { > __n = _M_nd(__urng); > __v = result_type(1.0) + __param._M_a2 * __n; > } > while (__v <= 0.0); > > __v = __v * __v * __v; > __u = __aurng(); > } > while (__u > result_type(1.0) - 0.331 * __n * __n * __n * __n > && (std::log(__u) > (0.5 * __n * __n + __a1 > * (1.0 - __v + std::log(__v))))); > > *__f++ = __a1 * __v * __param.beta(); > } > else > while (__f != __t) > { > do > { > do > { > __n = _M_nd(__urng); > __v = result_type(1.0) + __param._M_a2 * __n; > } > while (__v <= 0.0); > > __v = __v * __v * __v; > __u = __aurng(); > } > while (__u > result_type(1.0) - 0.331 * __n * __n * __n * __n > && (std::log(__u) > (0.5 * __n * __n + __a1 > * (1.0 - __v + std::log(__v))))); > > do > __u = __aurng(); > while (__u == 0.0); > > *__f++ = (std::pow(__u, result_type(1.0) / __param.alpha()) > * __a1 * __v * __param.beta()); > } > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const gamma_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.alpha() << __space << __x.beta() > << __space << __x._M_nd; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > gamma_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _RealType __alpha_val, __beta_val; > __is >> __alpha_val >> __beta_val >> __x._M_nd; > __x.param(typename gamma_distribution<_RealType>:: > param_type(__alpha_val, __beta_val)); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > template<typename _UniformRandomNumberGenerator> > typename weibull_distribution<_RealType>::result_type > weibull_distribution<_RealType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > return __p.b() * std::pow(-std::log(result_type(1) - __aurng()), > result_type(1) / __p.a()); > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > weibull_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > auto __inv_a = result_type(1) / __p.a(); > > while (__f != __t) > *__f++ = __p.b() * std::pow(-std::log(result_type(1) - __aurng()), > __inv_a); > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const weibull_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.a() << __space << __x.b(); > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > weibull_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _RealType __a, __b; > __is >> __a >> __b; > __x.param(typename weibull_distribution<_RealType>:: > param_type(__a, __b)); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > template<typename _UniformRandomNumberGenerator> > typename extreme_value_distribution<_RealType>::result_type > extreme_value_distribution<_RealType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > return __p.a() - __p.b() * std::log(-std::log(result_type(1) > - __aurng())); > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > extreme_value_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __p) > { > > __detail::_Adaptor<_UniformRandomNumberGenerator, result_type> > __aurng(__urng); > > while (__f != __t) > *__f++ = __p.a() - __p.b() * std::log(-std::log(result_type(1) > - __aurng())); > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const extreme_value_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > __os << __x.a() << __space << __x.b(); > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > extreme_value_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > _RealType __a, __b; > __is >> __a >> __b; > __x.param(typename extreme_value_distribution<_RealType>:: > param_type(__a, __b)); > > __is.flags(__flags); > return __is; > } > > > template<typename _IntType> > void > discrete_distribution<_IntType>::param_type:: > _M_initialize() > { > if (_M_prob.size() < 2) > { > _M_prob.clear(); > return; > } > > const double __sum = std::accumulate(_M_prob.begin(), > _M_prob.end(), 0.0); > > __detail::__normalize(_M_prob.begin(), _M_prob.end(), _M_prob.begin(), > __sum); > > _M_cp.reserve(_M_prob.size()); > std::partial_sum(_M_prob.begin(), _M_prob.end(), > std::back_inserter(_M_cp)); > > _M_cp[_M_cp.size() - 1] = 1.0; > } > > template<typename _IntType> > template<typename _Func> > discrete_distribution<_IntType>::param_type:: > param_type(size_t __nw, double __xmin, double __xmax, _Func __fw) > : _M_prob(), _M_cp() > { > const size_t __n = __nw == 0 ? 1 : __nw; > const double __delta = (__xmax - __xmin) / __n; > > _M_prob.reserve(__n); > for (size_t __k = 0; __k < __nw; ++__k) > _M_prob.push_back(__fw(__xmin + __k * __delta + 0.5 * __delta)); > > _M_initialize(); > } > > template<typename _IntType> > template<typename _UniformRandomNumberGenerator> > typename discrete_distribution<_IntType>::result_type > discrete_distribution<_IntType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > if (__param._M_cp.empty()) > return result_type(0); > > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > const double __p = __aurng(); > auto __pos = std::lower_bound(__param._M_cp.begin(), > __param._M_cp.end(), __p); > > return __pos - __param._M_cp.begin(); > } > > template<typename _IntType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > discrete_distribution<_IntType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > > if (__param._M_cp.empty()) > { > while (__f != __t) > *__f++ = result_type(0); > return; > } > > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > while (__f != __t) > { > const double __p = __aurng(); > auto __pos = std::lower_bound(__param._M_cp.begin(), > __param._M_cp.end(), __p); > > *__f++ = __pos - __param._M_cp.begin(); > } > } > > template<typename _IntType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const discrete_distribution<_IntType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<double>::max_digits10); > > std::vector<double> __prob = __x.probabilities(); > __os << __prob.size(); > for (auto __dit = __prob.begin(); __dit != __prob.end(); ++__dit) > __os << __space << *__dit; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _IntType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > discrete_distribution<_IntType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > size_t __n; > __is >> __n; > > std::vector<double> __prob_vec; > __prob_vec.reserve(__n); > for (; __n != 0; --__n) > { > double __prob; > __is >> __prob; > __prob_vec.push_back(__prob); > } > > __x.param(typename discrete_distribution<_IntType>:: > param_type(__prob_vec.begin(), __prob_vec.end())); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > void > piecewise_constant_distribution<_RealType>::param_type:: > _M_initialize() > { > if (_M_int.size() < 2 > || (_M_int.size() == 2 > && _M_int[0] == _RealType(0) > && _M_int[1] == _RealType(1))) > { > _M_int.clear(); > _M_den.clear(); > return; > } > > const double __sum = std::accumulate(_M_den.begin(), > _M_den.end(), 0.0); > > __detail::__normalize(_M_den.begin(), _M_den.end(), _M_den.begin(), > __sum); > > _M_cp.reserve(_M_den.size()); > std::partial_sum(_M_den.begin(), _M_den.end(), > std::back_inserter(_M_cp)); > > > _M_cp[_M_cp.size() - 1] = 1.0; > > for (size_t __k = 0; __k < _M_den.size(); ++__k) > _M_den[__k] /= _M_int[__k + 1] - _M_int[__k]; > } > > template<typename _RealType> > template<typename _InputIteratorB, typename _InputIteratorW> > piecewise_constant_distribution<_RealType>::param_type:: > param_type(_InputIteratorB __bbegin, > _InputIteratorB __bend, > _InputIteratorW __wbegin) > : _M_int(), _M_den(), _M_cp() > { > if (__bbegin != __bend) > { > for (;;) > { > _M_int.push_back(*__bbegin); > ++__bbegin; > if (__bbegin == __bend) > break; > > _M_den.push_back(*__wbegin); > ++__wbegin; > } > } > > _M_initialize(); > } > > template<typename _RealType> > template<typename _Func> > piecewise_constant_distribution<_RealType>::param_type:: > param_type(initializer_list<_RealType> __bl, _Func __fw) > : _M_int(), _M_den(), _M_cp() > { > _M_int.reserve(__bl.size()); > for (auto __biter = __bl.begin(); __biter != __bl.end(); ++__biter) > _M_int.push_back(*__biter); > > _M_den.reserve(_M_int.size() - 1); > for (size_t __k = 0; __k < _M_int.size() - 1; ++__k) > _M_den.push_back(__fw(0.5 * (_M_int[__k + 1] + _M_int[__k]))); > > _M_initialize(); > } > > template<typename _RealType> > template<typename _Func> > piecewise_constant_distribution<_RealType>::param_type:: > param_type(size_t __nw, _RealType __xmin, _RealType __xmax, _Func __fw) > : _M_int(), _M_den(), _M_cp() > { > const size_t __n = __nw == 0 ? 1 : __nw; > const _RealType __delta = (__xmax - __xmin) / __n; > > _M_int.reserve(__n + 1); > for (size_t __k = 0; __k <= __nw; ++__k) > _M_int.push_back(__xmin + __k * __delta); > > _M_den.reserve(__n); > for (size_t __k = 0; __k < __nw; ++__k) > _M_den.push_back(__fw(_M_int[__k] + 0.5 * __delta)); > > _M_initialize(); > } > > template<typename _RealType> > template<typename _UniformRandomNumberGenerator> > typename piecewise_constant_distribution<_RealType>::result_type > piecewise_constant_distribution<_RealType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > const double __p = __aurng(); > if (__param._M_cp.empty()) > return __p; > > auto __pos = std::lower_bound(__param._M_cp.begin(), > __param._M_cp.end(), __p); > const size_t __i = __pos - __param._M_cp.begin(); > > const double __pref = __i > 0 ? __param._M_cp[__i - 1] : 0.0; > > return __param._M_int[__i] + (__p - __pref) / __param._M_den[__i]; > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > piecewise_constant_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > if (__param._M_cp.empty()) > { > while (__f != __t) > *__f++ = __aurng(); > return; > } > > while (__f != __t) > { > const double __p = __aurng(); > > auto __pos = std::lower_bound(__param._M_cp.begin(), > __param._M_cp.end(), __p); > const size_t __i = __pos - __param._M_cp.begin(); > > const double __pref = __i > 0 ? __param._M_cp[__i - 1] : 0.0; > > *__f++ = (__param._M_int[__i] > + (__p - __pref) / __param._M_den[__i]); > } > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const piecewise_constant_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > std::vector<_RealType> __int = __x.intervals(); > __os << __int.size() - 1; > > for (auto __xit = __int.begin(); __xit != __int.end(); ++__xit) > __os << __space << *__xit; > > std::vector<double> __den = __x.densities(); > for (auto __dit = __den.begin(); __dit != __den.end(); ++__dit) > __os << __space << *__dit; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > piecewise_constant_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > size_t __n; > __is >> __n; > > std::vector<_RealType> __int_vec; > __int_vec.reserve(__n + 1); > for (size_t __i = 0; __i <= __n; ++__i) > { > _RealType __int; > __is >> __int; > __int_vec.push_back(__int); > } > > std::vector<double> __den_vec; > __den_vec.reserve(__n); > for (size_t __i = 0; __i < __n; ++__i) > { > double __den; > __is >> __den; > __den_vec.push_back(__den); > } > > __x.param(typename piecewise_constant_distribution<_RealType>:: > param_type(__int_vec.begin(), __int_vec.end(), __den_vec.begin())); > > __is.flags(__flags); > return __is; > } > > > template<typename _RealType> > void > piecewise_linear_distribution<_RealType>::param_type:: > _M_initialize() > { > if (_M_int.size() < 2 > || (_M_int.size() == 2 > && _M_int[0] == _RealType(0) > && _M_int[1] == _RealType(1) > && _M_den[0] == _M_den[1])) > { > _M_int.clear(); > _M_den.clear(); > return; > } > > double __sum = 0.0; > _M_cp.reserve(_M_int.size() - 1); > _M_m.reserve(_M_int.size() - 1); > for (size_t __k = 0; __k < _M_int.size() - 1; ++__k) > { > const _RealType __delta = _M_int[__k + 1] - _M_int[__k]; > __sum += 0.5 * (_M_den[__k + 1] + _M_den[__k]) * __delta; > _M_cp.push_back(__sum); > _M_m.push_back((_M_den[__k + 1] - _M_den[__k]) / __delta); > } > > > __detail::__normalize(_M_den.begin(), _M_den.end(), _M_den.begin(), > __sum); > > __detail::__normalize(_M_cp.begin(), _M_cp.end(), _M_cp.begin(), __sum); > > __detail::__normalize(_M_m.begin(), _M_m.end(), _M_m.begin(), __sum); > > > _M_cp[_M_cp.size() - 1] = 1.0; > } > > template<typename _RealType> > template<typename _InputIteratorB, typename _InputIteratorW> > piecewise_linear_distribution<_RealType>::param_type:: > param_type(_InputIteratorB __bbegin, > _InputIteratorB __bend, > _InputIteratorW __wbegin) > : _M_int(), _M_den(), _M_cp(), _M_m() > { > for (; __bbegin != __bend; ++__bbegin, ++__wbegin) > { > _M_int.push_back(*__bbegin); > _M_den.push_back(*__wbegin); > } > > _M_initialize(); > } > > template<typename _RealType> > template<typename _Func> > piecewise_linear_distribution<_RealType>::param_type:: > param_type(initializer_list<_RealType> __bl, _Func __fw) > : _M_int(), _M_den(), _M_cp(), _M_m() > { > _M_int.reserve(__bl.size()); > _M_den.reserve(__bl.size()); > for (auto __biter = __bl.begin(); __biter != __bl.end(); ++__biter) > { > _M_int.push_back(*__biter); > _M_den.push_back(__fw(*__biter)); > } > > _M_initialize(); > } > > template<typename _RealType> > template<typename _Func> > piecewise_linear_distribution<_RealType>::param_type:: > param_type(size_t __nw, _RealType __xmin, _RealType __xmax, _Func __fw) > : _M_int(), _M_den(), _M_cp(), _M_m() > { > const size_t __n = __nw == 0 ? 1 : __nw; > const _RealType __delta = (__xmax - __xmin) / __n; > > _M_int.reserve(__n + 1); > _M_den.reserve(__n + 1); > for (size_t __k = 0; __k <= __nw; ++__k) > { > _M_int.push_back(__xmin + __k * __delta); > _M_den.push_back(__fw(_M_int[__k] + __delta)); > } > > _M_initialize(); > } > > template<typename _RealType> > template<typename _UniformRandomNumberGenerator> > typename piecewise_linear_distribution<_RealType>::result_type > piecewise_linear_distribution<_RealType>:: > operator()(_UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > __detail::_Adaptor<_UniformRandomNumberGenerator, double> > __aurng(__urng); > > const double __p = __aurng(); > if (__param._M_cp.empty()) > return __p; > > auto __pos = std::lower_bound(__param._M_cp.begin(), > __param._M_cp.end(), __p); > const size_t __i = __pos - __param._M_cp.begin(); > > const double __pref = __i > 0 ? __param._M_cp[__i - 1] : 0.0; > > const double __a = 0.5 * __param._M_m[__i]; > const double __b = __param._M_den[__i]; > const double __cm = __p - __pref; > > _RealType __x = __param._M_int[__i]; > if (__a == 0) > __x += __cm / __b; > else > { > const double __d = __b * __b + 4.0 * __a * __cm; > __x += 0.5 * (std::sqrt(__d) - __b) / __a; > } > > return __x; > } > > template<typename _RealType> > template<typename _ForwardIterator, > typename _UniformRandomNumberGenerator> > void > piecewise_linear_distribution<_RealType>:: > __generate_impl(_ForwardIterator __f, _ForwardIterator __t, > _UniformRandomNumberGenerator& __urng, > const param_type& __param) > { > > > while (__f != __t) > *__f++ = this->operator()(__urng, __param); > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const piecewise_linear_distribution<_RealType>& __x) > { > typedef std::basic_ostream<_CharT, _Traits> __ostream_type; > typedef typename __ostream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __os.flags(); > const _CharT __fill = __os.fill(); > const std::streamsize __precision = __os.precision(); > const _CharT __space = __os.widen(' '); > __os.flags(__ios_base::scientific | __ios_base::left); > __os.fill(__space); > __os.precision(std::numeric_limits<_RealType>::max_digits10); > > std::vector<_RealType> __int = __x.intervals(); > __os << __int.size() - 1; > > for (auto __xit = __int.begin(); __xit != __int.end(); ++__xit) > __os << __space << *__xit; > > std::vector<double> __den = __x.densities(); > for (auto __dit = __den.begin(); __dit != __den.end(); ++__dit) > __os << __space << *__dit; > > __os.flags(__flags); > __os.fill(__fill); > __os.precision(__precision); > return __os; > } > > template<typename _RealType, typename _CharT, typename _Traits> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, > piecewise_linear_distribution<_RealType>& __x) > { > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > const typename __ios_base::fmtflags __flags = __is.flags(); > __is.flags(__ios_base::dec | __ios_base::skipws); > > size_t __n; > __is >> __n; > > std::vector<_RealType> __int_vec; > __int_vec.reserve(__n + 1); > for (size_t __i = 0; __i <= __n; ++__i) > { > _RealType __int; > __is >> __int; > __int_vec.push_back(__int); > } > > std::vector<double> __den_vec; > __den_vec.reserve(__n + 1); > for (size_t __i = 0; __i <= __n; ++__i) > { > double __den; > __is >> __den; > __den_vec.push_back(__den); > } > > __x.param(typename piecewise_linear_distribution<_RealType>:: > param_type(__int_vec.begin(), __int_vec.end(), __den_vec.begin())); > > __is.flags(__flags); > return __is; > } > > > template<typename _IntType> > seed_seq::seed_seq(std::initializer_list<_IntType> __il) > { > for (auto __iter = __il.begin(); __iter != __il.end(); ++__iter) > _M_v.push_back(__detail::__mod<result_type, > __detail::_Shift<result_type, 32>::__value>(*__iter)); > } > > template<typename _InputIterator> > seed_seq::seed_seq(_InputIterator __begin, _InputIterator __end) > { > for (_InputIterator __iter = __begin; __iter != __end; ++__iter) > _M_v.push_back(__detail::__mod<result_type, > __detail::_Shift<result_type, 32>::__value>(*__iter)); > } > > template<typename _RandomAccessIterator> > void > seed_seq::generate(_RandomAccessIterator __begin, > _RandomAccessIterator __end) > { > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _Type; > > if (__begin == __end) > return; > > std::fill(__begin, __end, _Type(0x8b8b8b8bu)); > > const size_t __n = __end - __begin; > const size_t __s = _M_v.size(); > const size_t __t = (__n >= 623) ? 11 > : (__n >= 68) ? 7 > : (__n >= 39) ? 5 > : (__n >= 7) ? 3 > : (__n - 1) / 2; > const size_t __p = (__n - __t) / 2; > const size_t __q = __p + __t; > const size_t __m = std::max(size_t(__s + 1), __n); > > for (size_t __k = 0; __k < __m; ++__k) > { > _Type __arg = (__begin[__k % __n] > ^ __begin[(__k + __p) % __n] > ^ __begin[(__k - 1) % __n]); > _Type __r1 = __arg ^ (__arg >> 27); > __r1 = __detail::__mod<_Type, > __detail::_Shift<_Type, 32>::__value>(1664525u * __r1); > _Type __r2 = __r1; > if (__k == 0) > __r2 += __s; > else if (__k <= __s) > __r2 += __k % __n + _M_v[__k - 1]; > else > __r2 += __k % __n; > __r2 = __detail::__mod<_Type, > __detail::_Shift<_Type, 32>::__value>(__r2); > __begin[(__k + __p) % __n] += __r1; > __begin[(__k + __q) % __n] += __r2; > __begin[__k % __n] = __r2; > } > > for (size_t __k = __m; __k < __m + __n; ++__k) > { > _Type __arg = (__begin[__k % __n] > + __begin[(__k + __p) % __n] > + __begin[(__k - 1) % __n]); > _Type __r3 = __arg ^ (__arg >> 27); > __r3 = __detail::__mod<_Type, > __detail::_Shift<_Type, 32>::__value>(1566083941u * __r3); > _Type __r4 = __r3 - __k % __n; > __r4 = __detail::__mod<_Type, > __detail::_Shift<_Type, 32>::__value>(__r4); > __begin[(__k + __p) % __n] ^= __r3; > __begin[(__k + __q) % __n] ^= __r4; > __begin[__k % __n] = __r4; > } > } > > template<typename _RealType, size_t __bits, > typename _UniformRandomNumberGenerator> > _RealType > generate_canonical(_UniformRandomNumberGenerator& __urng) > { > const size_t __b > = std::min(static_cast<size_t>(std::numeric_limits<_RealType>::digits), > __bits); > const long double __r = static_cast<long double>(__urng.max()) > - static_cast<long double>(__urng.min()) + 1.0L; > const size_t __log2r = std::log(__r) / std::log(2.0L); > size_t __k = std::max<size_t>(1UL, (__b + __log2r - 1UL) / __log2r); > _RealType __sum = _RealType(0); > _RealType __tmp = _RealType(1); > for (; __k != 0; --__k) > { > __sum += _RealType(__urng() - __urng.min()) * __tmp; > __tmp *= __r; > } > return __sum / __tmp; > } > > >} ># 52 "/usr/include/c++/4.9.0/random" 2 3 ># 67 "/usr/include/c++/4.9.0/bits/stl_algo.h" 2 3 > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template<typename _Iterator, typename _Compare> > void > __move_median_to_first(_Iterator __result,_Iterator __a, _Iterator __b, > _Iterator __c, _Compare __comp) > { > if (__comp(__a, __b)) > { > if (__comp(__b, __c)) > std::iter_swap(__result, __b); > else if (__comp(__a, __c)) > std::iter_swap(__result, __c); > else > std::iter_swap(__result, __a); > } > else if (__comp(__a, __c)) > std::iter_swap(__result, __a); > else if (__comp(__b, __c)) > std::iter_swap(__result, __c); > else > std::iter_swap(__result, __b); > } > > > template<typename _InputIterator, typename _Predicate> > inline _InputIterator > __find_if(_InputIterator __first, _InputIterator __last, > _Predicate __pred, input_iterator_tag) > { > while (__first != __last && !__pred(__first)) > ++__first; > return __first; > } > > > template<typename _RandomAccessIterator, typename _Predicate> > _RandomAccessIterator > __find_if(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Predicate __pred, random_access_iterator_tag) > { > typename iterator_traits<_RandomAccessIterator>::difference_type > __trip_count = (__last - __first) >> 2; > > for (; __trip_count > 0; --__trip_count) > { > if (__pred(__first)) > return __first; > ++__first; > > if (__pred(__first)) > return __first; > ++__first; > > if (__pred(__first)) > return __first; > ++__first; > > if (__pred(__first)) > return __first; > ++__first; > } > > switch (__last - __first) > { > case 3: > if (__pred(__first)) > return __first; > ++__first; > case 2: > if (__pred(__first)) > return __first; > ++__first; > case 1: > if (__pred(__first)) > return __first; > ++__first; > case 0: > default: > return __last; > } > } > > template<typename _Iterator, typename _Predicate> > inline _Iterator > __find_if(_Iterator __first, _Iterator __last, _Predicate __pred) > { > return __find_if(__first, __last, __pred, > std::__iterator_category(__first)); > } > > > template<typename _InputIterator, typename _Predicate> > inline _InputIterator > __find_if_not(_InputIterator __first, _InputIterator __last, > _Predicate __pred) > { > return std::__find_if(__first, __last, > __gnu_cxx::__ops::__negate(__pred), > std::__iterator_category(__first)); > } > > > > > template<typename _InputIterator, typename _Predicate, typename _Distance> > _InputIterator > __find_if_not_n(_InputIterator __first, _Distance& __len, _Predicate __pred) > { > for (; __len; --__len, ++__first) > if (!__pred(__first)) > break; > return __first; > } ># 202 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator1, typename _ForwardIterator2, > typename _BinaryPredicate> > _ForwardIterator1 > __search(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2, _ForwardIterator2 __last2, > _BinaryPredicate __predicate) > { > > if (__first1 == __last1 || __first2 == __last2) > return __first1; > > > _ForwardIterator2 __p1(__first2); > if (++__p1 == __last2) > return std::__find_if(__first1, __last1, > __gnu_cxx::__ops::__iter_comp_iter(__predicate, __first2)); > > > _ForwardIterator2 __p; > _ForwardIterator1 __current = __first1; > > for (;;) > { > __first1 = > std::__find_if(__first1, __last1, > __gnu_cxx::__ops::__iter_comp_iter(__predicate, __first2)); > > if (__first1 == __last1) > return __last1; > > __p = __p1; > __current = __first1; > if (++__current == __last1) > return __last1; > > while (__predicate(__current, __p)) > { > if (++__p == __last2) > return __first1; > if (++__current == __last1) > return __last1; > } > ++__first1; > } > return __first1; > } > > > > > > > template<typename _ForwardIterator, typename _Integer, > typename _UnaryPredicate> > _ForwardIterator > __search_n_aux(_ForwardIterator __first, _ForwardIterator __last, > _Integer __count, _UnaryPredicate __unary_pred, > std::forward_iterator_tag) > { > __first = std::__find_if(__first, __last, __unary_pred); > while (__first != __last) > { > typename iterator_traits<_ForwardIterator>::difference_type > __n = __count; > _ForwardIterator __i = __first; > ++__i; > while (__i != __last && __n != 1 && __unary_pred(__i)) > { > ++__i; > --__n; > } > if (__n == 1) > return __first; > if (__i == __last) > return __last; > __first = std::__find_if(++__i, __last, __unary_pred); > } > return __last; > } > > > > > > template<typename _RandomAccessIter, typename _Integer, > typename _UnaryPredicate> > _RandomAccessIter > __search_n_aux(_RandomAccessIter __first, _RandomAccessIter __last, > _Integer __count, _UnaryPredicate __unary_pred, > std::random_access_iterator_tag) > { > typedef typename std::iterator_traits<_RandomAccessIter>::difference_type > _DistanceType; > > _DistanceType __tailSize = __last - __first; > _DistanceType __remainder = __count; > > while (__remainder <= __tailSize) > { > __first += __remainder; > __tailSize -= __remainder; > > > _RandomAccessIter __backTrack = __first; > while (__unary_pred(--__backTrack)) > { > if (--__remainder == 0) > return (__first - __count); > } > __remainder = __count + 1 - (__first - __backTrack); > } > return __last; > } > > template<typename _ForwardIterator, typename _Integer, > typename _UnaryPredicate> > _ForwardIterator > __search_n(_ForwardIterator __first, _ForwardIterator __last, > _Integer __count, > _UnaryPredicate __unary_pred) > { > if (__count <= 0) > return __first; > > if (__count == 1) > return std::__find_if(__first, __last, __unary_pred); > > return std::__search_n_aux(__first, __last, __count, __unary_pred, > std::__iterator_category(__first)); > } > > > template<typename _ForwardIterator1, typename _ForwardIterator2, > typename _BinaryPredicate> > _ForwardIterator1 > __find_end(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2, _ForwardIterator2 __last2, > forward_iterator_tag, forward_iterator_tag, > _BinaryPredicate __comp) > { > if (__first2 == __last2) > return __last1; > > _ForwardIterator1 __result = __last1; > while (1) > { > _ForwardIterator1 __new_result > = std::__search(__first1, __last1, __first2, __last2, __comp); > if (__new_result == __last1) > return __result; > else > { > __result = __new_result; > __first1 = __new_result; > ++__first1; > } > } > } > > > template<typename _BidirectionalIterator1, typename _BidirectionalIterator2, > typename _BinaryPredicate> > _BidirectionalIterator1 > __find_end(_BidirectionalIterator1 __first1, > _BidirectionalIterator1 __last1, > _BidirectionalIterator2 __first2, > _BidirectionalIterator2 __last2, > bidirectional_iterator_tag, bidirectional_iterator_tag, > _BinaryPredicate __comp) > { > > > > > > > typedef reverse_iterator<_BidirectionalIterator1> _RevIterator1; > typedef reverse_iterator<_BidirectionalIterator2> _RevIterator2; > > _RevIterator1 __rlast1(__first1); > _RevIterator2 __rlast2(__first2); > _RevIterator1 __rresult = std::__search(_RevIterator1(__last1), __rlast1, > _RevIterator2(__last2), __rlast2, > __comp); > > if (__rresult == __rlast1) > return __last1; > else > { > _BidirectionalIterator1 __result = __rresult.base(); > std::advance(__result, -std::distance(__first2, __last2)); > return __result; > } > } ># 423 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator1, typename _ForwardIterator2> > inline _ForwardIterator1 > find_end(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2, _ForwardIterator2 __last2) > { > > > > > > > ; > ; > > return std::__find_end(__first1, __last1, __first2, __last2, > std::__iterator_category(__first1), > std::__iterator_category(__first2), > __gnu_cxx::__ops::__iter_equal_to_iter()); > } ># 471 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator1, typename _ForwardIterator2, > typename _BinaryPredicate> > inline _ForwardIterator1 > find_end(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2, _ForwardIterator2 __last2, > _BinaryPredicate __comp) > { > > > > > > > ; > ; > > return std::__find_end(__first1, __last1, __first2, __last2, > std::__iterator_category(__first1), > std::__iterator_category(__first2), > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } ># 506 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Predicate> > inline bool > all_of(_InputIterator __first, _InputIterator __last, _Predicate __pred) > { return __last == std::find_if_not(__first, __last, __pred); } ># 523 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Predicate> > inline bool > none_of(_InputIterator __first, _InputIterator __last, _Predicate __pred) > { return __last == std::find_if(__first, __last, __pred); } ># 541 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Predicate> > inline bool > any_of(_InputIterator __first, _InputIterator __last, _Predicate __pred) > { return !std::none_of(__first, __last, __pred); } ># 556 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Predicate> > inline _InputIterator > find_if_not(_InputIterator __first, _InputIterator __last, > _Predicate __pred) > { > > > > > ; > return std::__find_if_not(__first, __last, > __gnu_cxx::__ops::__pred_iter(__pred)); > } ># 580 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Predicate> > inline bool > is_partitioned(_InputIterator __first, _InputIterator __last, > _Predicate __pred) > { > __first = std::find_if_not(__first, __last, __pred); > return std::none_of(__first, __last, __pred); > } ># 598 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Predicate> > _ForwardIterator > partition_point(_ForwardIterator __first, _ForwardIterator __last, > _Predicate __pred) > { > > > > > > > ; > > typedef typename iterator_traits<_ForwardIterator>::difference_type > _DistanceType; > > _DistanceType __len = std::distance(__first, __last); > _DistanceType __half; > _ForwardIterator __middle; > > while (__len > 0) > { > __half = __len >> 1; > __middle = __first; > std::advance(__middle, __half); > if (__pred(*__middle)) > { > __first = __middle; > ++__first; > __len = __len - __half - 1; > } > else > __len = __half; > } > return __first; > } > > > template<typename _InputIterator, typename _OutputIterator, > typename _Predicate> > _OutputIterator > __remove_copy_if(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, _Predicate __pred) > { > for (; __first != __last; ++__first) > if (!__pred(__first)) > { > *__result = *__first; > ++__result; > } > return __result; > } ># 665 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _OutputIterator, typename _Tp> > inline _OutputIterator > remove_copy(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, const _Tp& __value) > { > > > > > > > ; > > return std::__remove_copy_if(__first, __last, __result, > __gnu_cxx::__ops::__iter_equals_val(__value)); > } ># 697 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _OutputIterator, > typename _Predicate> > inline _OutputIterator > remove_copy_if(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, _Predicate __pred) > { > > > > > > > ; > > return std::__remove_copy_if(__first, __last, __result, > __gnu_cxx::__ops::__pred_iter(__pred)); > } ># 731 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _OutputIterator, > typename _Predicate> > _OutputIterator > copy_if(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, _Predicate __pred) > { > > > > > > > ; > > for (; __first != __last; ++__first) > if (__pred(*__first)) > { > *__result = *__first; > ++__result; > } > return __result; > } > > template<typename _InputIterator, typename _Size, typename _OutputIterator> > _OutputIterator > __copy_n(_InputIterator __first, _Size __n, > _OutputIterator __result, input_iterator_tag) > { > if (__n > 0) > { > while (true) > { > *__result = *__first; > ++__result; > if (--__n > 0) > ++__first; > else > break; > } > } > return __result; > } > > template<typename _RandomAccessIterator, typename _Size, > typename _OutputIterator> > inline _OutputIterator > __copy_n(_RandomAccessIterator __first, _Size __n, > _OutputIterator __result, random_access_iterator_tag) > { return std::copy(__first, __first + __n, __result); } ># 794 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Size, typename _OutputIterator> > inline _OutputIterator > copy_n(_InputIterator __first, _Size __n, _OutputIterator __result) > { > > > > > > return std::__copy_n(__first, __n, __result, > std::__iterator_category(__first)); > } ># 822 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _OutputIterator1, > typename _OutputIterator2, typename _Predicate> > pair<_OutputIterator1, _OutputIterator2> > partition_copy(_InputIterator __first, _InputIterator __last, > _OutputIterator1 __out_true, _OutputIterator2 __out_false, > _Predicate __pred) > { ># 837 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > > for (; __first != __last; ++__first) > if (__pred(*__first)) > { > *__out_true = *__first; > ++__out_true; > } > else > { > *__out_false = *__first; > ++__out_false; > } > > return pair<_OutputIterator1, _OutputIterator2>(__out_true, __out_false); > } > > > template<typename _ForwardIterator, typename _Predicate> > _ForwardIterator > __remove_if(_ForwardIterator __first, _ForwardIterator __last, > _Predicate __pred) > { > __first = std::__find_if(__first, __last, __pred); > if (__first == __last) > return __first; > _ForwardIterator __result = __first; > ++__first; > for (; __first != __last; ++__first) > if (!__pred(__first)) > { > *__result = std::move(*__first); > ++__result; > } > return __result; > } ># 891 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Tp> > inline _ForwardIterator > remove(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __value) > { > > > > > > ; > > return std::__remove_if(__first, __last, > __gnu_cxx::__ops::__iter_equals_val(__value)); > } ># 924 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Predicate> > inline _ForwardIterator > remove_if(_ForwardIterator __first, _ForwardIterator __last, > _Predicate __pred) > { > > > > > > ; > > return std::__remove_if(__first, __last, > __gnu_cxx::__ops::__pred_iter(__pred)); > } > > template<typename _ForwardIterator, typename _BinaryPredicate> > _ForwardIterator > __adjacent_find(_ForwardIterator __first, _ForwardIterator __last, > _BinaryPredicate __binary_pred) > { > if (__first == __last) > return __last; > _ForwardIterator __next = __first; > while (++__next != __last) > { > if (__binary_pred(__first, __next)) > return __first; > __first = __next; > } > return __last; > } > > template<typename _ForwardIterator, typename _BinaryPredicate> > _ForwardIterator > __unique(_ForwardIterator __first, _ForwardIterator __last, > _BinaryPredicate __binary_pred) > { > > __first = std::__adjacent_find(__first, __last, __binary_pred); > if (__first == __last) > return __last; > > > _ForwardIterator __dest = __first; > ++__first; > while (++__first != __last) > if (!__binary_pred(__dest, __first)) > *++__dest = std::move(*__first); > return ++__dest; > } ># 990 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator> > inline _ForwardIterator > unique(_ForwardIterator __first, _ForwardIterator __last) > { > > > > > > ; > > return std::__unique(__first, __last, > __gnu_cxx::__ops::__iter_equal_to_iter()); > } ># 1020 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _BinaryPredicate> > inline _ForwardIterator > unique(_ForwardIterator __first, _ForwardIterator __last, > _BinaryPredicate __binary_pred) > { > > > > > > > ; > > return std::__unique(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__binary_pred)); > } > > > > > > > > template<typename _ForwardIterator, typename _OutputIterator, > typename _BinaryPredicate> > _OutputIterator > __unique_copy(_ForwardIterator __first, _ForwardIterator __last, > _OutputIterator __result, _BinaryPredicate __binary_pred, > forward_iterator_tag, output_iterator_tag) > { > > > > > > _ForwardIterator __next = __first; > *__result = *__first; > while (++__next != __last) > if (!__binary_pred(__first, __next)) > { > __first = __next; > *++__result = *__first; > } > return ++__result; > } > > > > > > > > template<typename _InputIterator, typename _OutputIterator, > typename _BinaryPredicate> > _OutputIterator > __unique_copy(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, _BinaryPredicate __binary_pred, > input_iterator_tag, output_iterator_tag) > { > > > > > > typename iterator_traits<_InputIterator>::value_type __value = *__first; > __decltype(__gnu_cxx::__ops::__iter_comp_val(__binary_pred)) > __rebound_pred > = __gnu_cxx::__ops::__iter_comp_val(__binary_pred); > *__result = __value; > while (++__first != __last) > if (!__rebound_pred(__first, __value)) > { > __value = *__first; > *++__result = __value; > } > return ++__result; > } > > > > > > > > template<typename _InputIterator, typename _ForwardIterator, > typename _BinaryPredicate> > _ForwardIterator > __unique_copy(_InputIterator __first, _InputIterator __last, > _ForwardIterator __result, _BinaryPredicate __binary_pred, > input_iterator_tag, forward_iterator_tag) > { > > > > > *__result = *__first; > while (++__first != __last) > if (!__binary_pred(__result, __first)) > *++__result = *__first; > return ++__result; > } > > > > > > > template<typename _BidirectionalIterator> > void > __reverse(_BidirectionalIterator __first, _BidirectionalIterator __last, > bidirectional_iterator_tag) > { > while (true) > if (__first == __last || __first == --__last) > return; > else > { > std::iter_swap(__first, __last); > ++__first; > } > } > > > > > > > template<typename _RandomAccessIterator> > void > __reverse(_RandomAccessIterator __first, _RandomAccessIterator __last, > random_access_iterator_tag) > { > if (__first == __last) > return; > --__last; > while (__first < __last) > { > std::iter_swap(__first, __last); > ++__first; > --__last; > } > } ># 1175 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _BidirectionalIterator> > inline void > reverse(_BidirectionalIterator __first, _BidirectionalIterator __last) > { > > > > ; > std::__reverse(__first, __last, std::__iterator_category(__first)); > } ># 1202 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _BidirectionalIterator, typename _OutputIterator> > _OutputIterator > reverse_copy(_BidirectionalIterator __first, _BidirectionalIterator __last, > _OutputIterator __result) > { > > > > > > ; > > while (__first != __last) > { > --__last; > *__result = *__last; > ++__result; > } > return __result; > } > > > > > > template<typename _EuclideanRingElement> > _EuclideanRingElement > __gcd(_EuclideanRingElement __m, _EuclideanRingElement __n) > { > while (__n != 0) > { > _EuclideanRingElement __t = __m % __n; > __m = __n; > __n = __t; > } > return __m; > } > > > template<typename _ForwardIterator> > void > __rotate(_ForwardIterator __first, > _ForwardIterator __middle, > _ForwardIterator __last, > forward_iterator_tag) > { > if (__first == __middle || __last == __middle) > return; > > _ForwardIterator __first2 = __middle; > do > { > std::iter_swap(__first, __first2); > ++__first; > ++__first2; > if (__first == __middle) > __middle = __first2; > } > while (__first2 != __last); > > __first2 = __middle; > > while (__first2 != __last) > { > std::iter_swap(__first, __first2); > ++__first; > ++__first2; > if (__first == __middle) > __middle = __first2; > else if (__first2 == __last) > __first2 = __middle; > } > } > > > template<typename _BidirectionalIterator> > void > __rotate(_BidirectionalIterator __first, > _BidirectionalIterator __middle, > _BidirectionalIterator __last, > bidirectional_iterator_tag) > { > > > > > if (__first == __middle || __last == __middle) > return; > > std::__reverse(__first, __middle, bidirectional_iterator_tag()); > std::__reverse(__middle, __last, bidirectional_iterator_tag()); > > while (__first != __middle && __middle != __last) > { > std::iter_swap(__first, --__last); > ++__first; > } > > if (__first == __middle) > std::__reverse(__middle, __last, bidirectional_iterator_tag()); > else > std::__reverse(__first, __middle, bidirectional_iterator_tag()); > } > > > template<typename _RandomAccessIterator> > void > __rotate(_RandomAccessIterator __first, > _RandomAccessIterator __middle, > _RandomAccessIterator __last, > random_access_iterator_tag) > { > > > > > if (__first == __middle || __last == __middle) > return; > > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _Distance; > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _ValueType; > > _Distance __n = __last - __first; > _Distance __k = __middle - __first; > > if (__k == __n - __k) > { > std::swap_ranges(__first, __middle, __middle); > return; > } > > _RandomAccessIterator __p = __first; > > for (;;) > { > if (__k < __n - __k) > { > if (__is_pod(_ValueType) && __k == 1) > { > _ValueType __t = std::move(*__p); > std::move(__p + 1, __p + __n, __p); > *(__p + __n - 1) = std::move(__t); > return; > } > _RandomAccessIterator __q = __p + __k; > for (_Distance __i = 0; __i < __n - __k; ++ __i) > { > std::iter_swap(__p, __q); > ++__p; > ++__q; > } > __n %= __k; > if (__n == 0) > return; > std::swap(__n, __k); > __k = __n - __k; > } > else > { > __k = __n - __k; > if (__is_pod(_ValueType) && __k == 1) > { > _ValueType __t = std::move(*(__p + __n - 1)); > std::move_backward(__p, __p + __n - 1, __p + __n); > *__p = std::move(__t); > return; > } > _RandomAccessIterator __q = __p + __n; > __p = __q - __k; > for (_Distance __i = 0; __i < __n - __k; ++ __i) > { > --__p; > --__q; > std::iter_swap(__p, __q); > } > __n %= __k; > if (__n == 0) > return; > std::swap(__n, __k); > } > } > } ># 1408 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator> > inline void > rotate(_ForwardIterator __first, _ForwardIterator __middle, > _ForwardIterator __last) > { > > > > ; > ; > > std::__rotate(__first, __middle, __last, > std::__iterator_category(__first)); > } ># 1443 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _OutputIterator> > inline _OutputIterator > rotate_copy(_ForwardIterator __first, _ForwardIterator __middle, > _ForwardIterator __last, _OutputIterator __result) > { > > > > > ; > ; > > return std::copy(__first, __middle, > std::copy(__middle, __last, __result)); > } > > > template<typename _ForwardIterator, typename _Predicate> > _ForwardIterator > __partition(_ForwardIterator __first, _ForwardIterator __last, > _Predicate __pred, forward_iterator_tag) > { > if (__first == __last) > return __first; > > while (__pred(*__first)) > if (++__first == __last) > return __first; > > _ForwardIterator __next = __first; > > while (++__next != __last) > if (__pred(*__next)) > { > std::iter_swap(__first, __next); > ++__first; > } > > return __first; > } > > > template<typename _BidirectionalIterator, typename _Predicate> > _BidirectionalIterator > __partition(_BidirectionalIterator __first, _BidirectionalIterator __last, > _Predicate __pred, bidirectional_iterator_tag) > { > while (true) > { > while (true) > if (__first == __last) > return __first; > else if (__pred(*__first)) > ++__first; > else > break; > --__last; > while (true) > if (__first == __last) > return __first; > else if (!bool(__pred(*__last))) > --__last; > else > break; > std::iter_swap(__first, __last); > ++__first; > } > } > > > > > > > template<typename _ForwardIterator, typename _Predicate, typename _Distance> > _ForwardIterator > __inplace_stable_partition(_ForwardIterator __first, > _Predicate __pred, _Distance __len) > { > if (__len == 1) > return __first; > _ForwardIterator __middle = __first; > std::advance(__middle, __len / 2); > _ForwardIterator __left_split = > std::__inplace_stable_partition(__first, __pred, __len / 2); > > > _Distance __right_len = __len - __len / 2; > _ForwardIterator __right_split = > std::__find_if_not_n(__middle, __right_len, __pred); > if (__right_len) > __right_split = std::__inplace_stable_partition(__middle, > __pred, > __right_len); > std::rotate(__left_split, __middle, __right_split); > std::advance(__left_split, std::distance(__middle, __right_split)); > return __left_split; > } > > > > > > > > template<typename _ForwardIterator, typename _Pointer, typename _Predicate, > typename _Distance> > _ForwardIterator > __stable_partition_adaptive(_ForwardIterator __first, > _ForwardIterator __last, > _Predicate __pred, _Distance __len, > _Pointer __buffer, > _Distance __buffer_size) > { > if (__len <= __buffer_size) > { > _ForwardIterator __result1 = __first; > _Pointer __result2 = __buffer; > > > > *__result2 = std::move(*__first); > ++__result2; > ++__first; > for (; __first != __last; ++__first) > if (__pred(__first)) > { > *__result1 = std::move(*__first); > ++__result1; > } > else > { > *__result2 = std::move(*__first); > ++__result2; > } > std::move(__buffer, __result2, __result1); > return __result1; > } > else > { > _ForwardIterator __middle = __first; > std::advance(__middle, __len / 2); > _ForwardIterator __left_split = > std::__stable_partition_adaptive(__first, __middle, __pred, > __len / 2, __buffer, > __buffer_size); > > > _Distance __right_len = __len - __len / 2; > _ForwardIterator __right_split = > std::__find_if_not_n(__middle, __right_len, __pred); > if (__right_len) > __right_split = > std::__stable_partition_adaptive(__right_split, __last, __pred, > __right_len, > __buffer, __buffer_size); > std::rotate(__left_split, __middle, __right_split); > std::advance(__left_split, std::distance(__middle, __right_split)); > return __left_split; > } > } > > template<typename _ForwardIterator, typename _Predicate> > _ForwardIterator > __stable_partition(_ForwardIterator __first, _ForwardIterator __last, > _Predicate __pred) > { > __first = std::__find_if_not(__first, __last, __pred); > > if (__first == __last) > return __first; > > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > typedef typename iterator_traits<_ForwardIterator>::difference_type > _DistanceType; > > _Temporary_buffer<_ForwardIterator, _ValueType> __buf(__first, __last); > if (__buf.size() > 0) > return > std::__stable_partition_adaptive(__first, __last, __pred, > _DistanceType(__buf.requested_size()), > __buf.begin(), > _DistanceType(__buf.size())); > else > return > std::__inplace_stable_partition(__first, __pred, > _DistanceType(__buf.requested_size())); > } ># 1650 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Predicate> > inline _ForwardIterator > stable_partition(_ForwardIterator __first, _ForwardIterator __last, > _Predicate __pred) > { > > > > > > ; > > return std::__stable_partition(__first, __last, > __gnu_cxx::__ops::__pred_iter(__pred)); > } > > > template<typename _RandomAccessIterator, typename _Compare> > void > __heap_select(_RandomAccessIterator __first, > _RandomAccessIterator __middle, > _RandomAccessIterator __last, _Compare __comp) > { > std::__make_heap(__first, __middle, __comp); > for (_RandomAccessIterator __i = __middle; __i < __last; ++__i) > if (__comp(__i, __first)) > std::__pop_heap(__first, __middle, __i, __comp); > } > > > > template<typename _InputIterator, typename _RandomAccessIterator, > typename _Compare> > _RandomAccessIterator > __partial_sort_copy(_InputIterator __first, _InputIterator __last, > _RandomAccessIterator __result_first, > _RandomAccessIterator __result_last, > _Compare __comp) > { > typedef typename iterator_traits<_InputIterator>::value_type > _InputValueType; > typedef iterator_traits<_RandomAccessIterator> _RItTraits; > typedef typename _RItTraits::difference_type _DistanceType; > > if (__result_first == __result_last) > return __result_last; > _RandomAccessIterator __result_real_last = __result_first; > while (__first != __last && __result_real_last != __result_last) > { > *__result_real_last = *__first; > ++__result_real_last; > ++__first; > } > > std::__make_heap(__result_first, __result_real_last, __comp); > while (__first != __last) > { > if (__comp(__first, __result_first)) > std::__adjust_heap(__result_first, _DistanceType(0), > _DistanceType(__result_real_last > - __result_first), > _InputValueType(*__first), __comp); > ++__first; > } > std::__sort_heap(__result_first, __result_real_last, __comp); > return __result_real_last; > } ># 1736 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _RandomAccessIterator> > inline _RandomAccessIterator > partial_sort_copy(_InputIterator __first, _InputIterator __last, > _RandomAccessIterator __result_first, > _RandomAccessIterator __result_last) > { > typedef typename iterator_traits<_InputIterator>::value_type > _InputValueType; > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _OutputValueType; > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _DistanceType; ># 1756 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__partial_sort_copy(__first, __last, > __result_first, __result_last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 1784 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _RandomAccessIterator, > typename _Compare> > inline _RandomAccessIterator > partial_sort_copy(_InputIterator __first, _InputIterator __last, > _RandomAccessIterator __result_first, > _RandomAccessIterator __result_last, > _Compare __comp) > { > typedef typename iterator_traits<_InputIterator>::value_type > _InputValueType; > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _OutputValueType; > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _DistanceType; ># 1809 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__partial_sort_copy(__first, __last, > __result_first, __result_last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > > template<typename _RandomAccessIterator, typename _Compare> > void > __unguarded_linear_insert(_RandomAccessIterator __last, > _Compare __comp) > { > typename iterator_traits<_RandomAccessIterator>::value_type > __val = std::move(*__last); > _RandomAccessIterator __next = __last; > --__next; > while (__comp(__val, __next)) > { > *__last = std::move(*__next); > __last = __next; > --__next; > } > *__last = std::move(__val); > } > > > template<typename _RandomAccessIterator, typename _Compare> > void > __insertion_sort(_RandomAccessIterator __first, > _RandomAccessIterator __last, _Compare __comp) > { > if (__first == __last) return; > > for (_RandomAccessIterator __i = __first + 1; __i != __last; ++__i) > { > if (__comp(__i, __first)) > { > typename iterator_traits<_RandomAccessIterator>::value_type > __val = std::move(*__i); > std::move_backward(__first, __i, __i + 1); > *__first = std::move(__val); > } > else > std::__unguarded_linear_insert(__i, > __gnu_cxx::__ops::__val_comp_iter(__comp)); > } > } > > > template<typename _RandomAccessIterator, typename _Compare> > inline void > __unguarded_insertion_sort(_RandomAccessIterator __first, > _RandomAccessIterator __last, _Compare __comp) > { > for (_RandomAccessIterator __i = __first; __i != __last; ++__i) > std::__unguarded_linear_insert(__i, > __gnu_cxx::__ops::__val_comp_iter(__comp)); > } > > > > > > enum { _S_threshold = 16 }; > > > template<typename _RandomAccessIterator, typename _Compare> > void > __final_insertion_sort(_RandomAccessIterator __first, > _RandomAccessIterator __last, _Compare __comp) > { > if (__last - __first > int(_S_threshold)) > { > std::__insertion_sort(__first, __first + int(_S_threshold), __comp); > std::__unguarded_insertion_sort(__first + int(_S_threshold), __last, > __comp); > } > else > std::__insertion_sort(__first, __last, __comp); > } > > > template<typename _RandomAccessIterator, typename _Compare> > _RandomAccessIterator > __unguarded_partition(_RandomAccessIterator __first, > _RandomAccessIterator __last, > _RandomAccessIterator __pivot, _Compare __comp) > { > while (true) > { > while (__comp(__first, __pivot)) > ++__first; > --__last; > while (__comp(__pivot, __last)) > --__last; > if (!(__first < __last)) > return __first; > std::iter_swap(__first, __last); > ++__first; > } > } > > > template<typename _RandomAccessIterator, typename _Compare> > inline _RandomAccessIterator > __unguarded_partition_pivot(_RandomAccessIterator __first, > _RandomAccessIterator __last, _Compare __comp) > { > _RandomAccessIterator __mid = __first + (__last - __first) / 2; > std::__move_median_to_first(__first, __first + 1, __mid, __last - 1, > __comp); > return std::__unguarded_partition(__first + 1, __last, __first, __comp); > } > > template<typename _RandomAccessIterator, typename _Compare> > inline void > __partial_sort(_RandomAccessIterator __first, > _RandomAccessIterator __middle, > _RandomAccessIterator __last, > _Compare __comp) > { > std::__heap_select(__first, __middle, __last, __comp); > std::__sort_heap(__first, __middle, __comp); > } > > > template<typename _RandomAccessIterator, typename _Size, typename _Compare> > void > __introsort_loop(_RandomAccessIterator __first, > _RandomAccessIterator __last, > _Size __depth_limit, _Compare __comp) > { > while (__last - __first > int(_S_threshold)) > { > if (__depth_limit == 0) > { > std::__partial_sort(__first, __last, __last, __comp); > return; > } > --__depth_limit; > _RandomAccessIterator __cut = > std::__unguarded_partition_pivot(__first, __last, __comp); > std::__introsort_loop(__cut, __last, __depth_limit, __comp); > __last = __cut; > } > } > > > > template<typename _RandomAccessIterator, typename _Compare> > inline void > __sort(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > if (__first != __last) > { > std::__introsort_loop(__first, __last, > std::__lg(__last - __first) * 2, > __comp); > std::__final_insertion_sort(__first, __last, __comp); > } > } > > template<typename _RandomAccessIterator, typename _Size, typename _Compare> > void > __introselect(_RandomAccessIterator __first, _RandomAccessIterator __nth, > _RandomAccessIterator __last, _Size __depth_limit, > _Compare __comp) > { > while (__last - __first > 3) > { > if (__depth_limit == 0) > { > std::__heap_select(__first, __nth + 1, __last, __comp); > > std::iter_swap(__first, __nth); > return; > } > --__depth_limit; > _RandomAccessIterator __cut = > std::__unguarded_partition_pivot(__first, __last, __comp); > if (__cut <= __nth) > __first = __cut; > else > __last = __cut; > } > std::__insertion_sort(__first, __last, __comp); > } ># 2020 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Tp, typename _Compare> > inline _ForwardIterator > lower_bound(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val, _Compare __comp) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > > > > > > ; > > return std::__lower_bound(__first, __last, __val, > __gnu_cxx::__ops::__iter_comp_val(__comp)); > } > > template<typename _ForwardIterator, typename _Tp, typename _Compare> > _ForwardIterator > __upper_bound(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val, _Compare __comp) > { > typedef typename iterator_traits<_ForwardIterator>::difference_type > _DistanceType; > > _DistanceType __len = std::distance(__first, __last); > > while (__len > 0) > { > _DistanceType __half = __len >> 1; > _ForwardIterator __middle = __first; > std::advance(__middle, __half); > if (__comp(__val, __middle)) > __len = __half; > else > { > __first = __middle; > ++__first; > __len = __len - __half - 1; > } > } > return __first; > } ># 2077 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Tp> > inline _ForwardIterator > upper_bound(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > > > > ; > > return std::__upper_bound(__first, __last, __val, > __gnu_cxx::__ops::__val_less_iter()); > } ># 2109 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Tp, typename _Compare> > inline _ForwardIterator > upper_bound(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val, _Compare __comp) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > > > > > > ; > > return std::__upper_bound(__first, __last, __val, > __gnu_cxx::__ops::__val_comp_iter(__comp)); > } > > template<typename _ForwardIterator, typename _Tp, > typename _CompareItTp, typename _CompareTpIt> > pair<_ForwardIterator, _ForwardIterator> > __equal_range(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val, > _CompareItTp __comp_it_val, _CompareTpIt __comp_val_it) > { > typedef typename iterator_traits<_ForwardIterator>::difference_type > _DistanceType; > > _DistanceType __len = std::distance(__first, __last); > > while (__len > 0) > { > _DistanceType __half = __len >> 1; > _ForwardIterator __middle = __first; > std::advance(__middle, __half); > if (__comp_it_val(__middle, __val)) > { > __first = __middle; > ++__first; > __len = __len - __half - 1; > } > else if (__comp_val_it(__val, __middle)) > __len = __half; > else > { > _ForwardIterator __left > = std::__lower_bound(__first, __middle, __val, __comp_it_val); > std::advance(__first, __len); > _ForwardIterator __right > = std::__upper_bound(++__middle, __first, __val, __comp_val_it); > return pair<_ForwardIterator, _ForwardIterator>(__left, __right); > } > } > return pair<_ForwardIterator, _ForwardIterator>(__first, __first); > } ># 2183 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Tp> > inline pair<_ForwardIterator, _ForwardIterator> > equal_range(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > > > > > ; > ; > > return std::__equal_range(__first, __last, __val, > __gnu_cxx::__ops::__iter_less_val(), > __gnu_cxx::__ops::__val_less_iter()); > } ># 2220 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Tp, typename _Compare> > inline pair<_ForwardIterator, _ForwardIterator> > equal_range(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val, _Compare __comp) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; ># 2235 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > > ; > > return std::__equal_range(__first, __last, __val, > __gnu_cxx::__ops::__iter_comp_val(__comp), > __gnu_cxx::__ops::__val_comp_iter(__comp)); > } ># 2256 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Tp> > bool > binary_search(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > > > > ; > ; > > _ForwardIterator __i > = std::__lower_bound(__first, __last, __val, > __gnu_cxx::__ops::__iter_less_val()); > return __i != __last && !(__val < *__i); > } ># 2291 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Tp, typename _Compare> > bool > binary_search(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __val, _Compare __comp) > { > typedef typename iterator_traits<_ForwardIterator>::value_type > _ValueType; > > > > > > > ; > > ; > > _ForwardIterator __i > = std::__lower_bound(__first, __last, __val, > __gnu_cxx::__ops::__iter_comp_val(__comp)); > return __i != __last && !bool(__comp(__val, *__i)); > } > > > > > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, typename _Compare> > void > __move_merge_adaptive(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, _Compare __comp) > { > while (__first1 != __last1 && __first2 != __last2) > { > if (__comp(__first2, __first1)) > { > *__result = std::move(*__first2); > ++__first2; > } > else > { > *__result = std::move(*__first1); > ++__first1; > } > ++__result; > } > if (__first1 != __last1) > std::move(__first1, __last1, __result); > } > > > template<typename _BidirectionalIterator1, typename _BidirectionalIterator2, > typename _BidirectionalIterator3, typename _Compare> > void > __move_merge_adaptive_backward(_BidirectionalIterator1 __first1, > _BidirectionalIterator1 __last1, > _BidirectionalIterator2 __first2, > _BidirectionalIterator2 __last2, > _BidirectionalIterator3 __result, > _Compare __comp) > { > if (__first1 == __last1) > { > std::move_backward(__first2, __last2, __result); > return; > } > else if (__first2 == __last2) > return; > > --__last1; > --__last2; > while (true) > { > if (__comp(__last2, __last1)) > { > *--__result = std::move(*__last1); > if (__first1 == __last1) > { > std::move_backward(__first2, ++__last2, __result); > return; > } > --__last1; > } > else > { > *--__result = std::move(*__last2); > if (__first2 == __last2) > return; > --__last2; > } > } > } > > > template<typename _BidirectionalIterator1, typename _BidirectionalIterator2, > typename _Distance> > _BidirectionalIterator1 > __rotate_adaptive(_BidirectionalIterator1 __first, > _BidirectionalIterator1 __middle, > _BidirectionalIterator1 __last, > _Distance __len1, _Distance __len2, > _BidirectionalIterator2 __buffer, > _Distance __buffer_size) > { > _BidirectionalIterator2 __buffer_end; > if (__len1 > __len2 && __len2 <= __buffer_size) > { > if (__len2) > { > __buffer_end = std::move(__middle, __last, __buffer); > std::move_backward(__first, __middle, __last); > return std::move(__buffer, __buffer_end, __first); > } > else > return __first; > } > else if (__len1 <= __buffer_size) > { > if (__len1) > { > __buffer_end = std::move(__first, __middle, __buffer); > std::move(__middle, __last, __first); > return std::move_backward(__buffer, __buffer_end, __last); > } > else > return __last; > } > else > { > std::rotate(__first, __middle, __last); > std::advance(__first, std::distance(__middle, __last)); > return __first; > } > } > > > template<typename _BidirectionalIterator, typename _Distance, > typename _Pointer, typename _Compare> > void > __merge_adaptive(_BidirectionalIterator __first, > _BidirectionalIterator __middle, > _BidirectionalIterator __last, > _Distance __len1, _Distance __len2, > _Pointer __buffer, _Distance __buffer_size, > _Compare __comp) > { > if (__len1 <= __len2 && __len1 <= __buffer_size) > { > _Pointer __buffer_end = std::move(__first, __middle, __buffer); > std::__move_merge_adaptive(__buffer, __buffer_end, __middle, __last, > __first, __comp); > } > else if (__len2 <= __buffer_size) > { > _Pointer __buffer_end = std::move(__middle, __last, __buffer); > std::__move_merge_adaptive_backward(__first, __middle, __buffer, > __buffer_end, __last, __comp); > } > else > { > _BidirectionalIterator __first_cut = __first; > _BidirectionalIterator __second_cut = __middle; > _Distance __len11 = 0; > _Distance __len22 = 0; > if (__len1 > __len2) > { > __len11 = __len1 / 2; > std::advance(__first_cut, __len11); > __second_cut > = std::__lower_bound(__middle, __last, *__first_cut, > __gnu_cxx::__ops::__iter_comp_val(__comp)); > __len22 = std::distance(__middle, __second_cut); > } > else > { > __len22 = __len2 / 2; > std::advance(__second_cut, __len22); > __first_cut > = std::__upper_bound(__first, __middle, *__second_cut, > __gnu_cxx::__ops::__val_comp_iter(__comp)); > __len11 = std::distance(__first, __first_cut); > } > _BidirectionalIterator __new_middle > = std::__rotate_adaptive(__first_cut, __middle, __second_cut, > __len1 - __len11, __len22, __buffer, > __buffer_size); > std::__merge_adaptive(__first, __first_cut, __new_middle, __len11, > __len22, __buffer, __buffer_size, __comp); > std::__merge_adaptive(__new_middle, __second_cut, __last, > __len1 - __len11, > __len2 - __len22, __buffer, > __buffer_size, __comp); > } > } > > > template<typename _BidirectionalIterator, typename _Distance, > typename _Compare> > void > __merge_without_buffer(_BidirectionalIterator __first, > _BidirectionalIterator __middle, > _BidirectionalIterator __last, > _Distance __len1, _Distance __len2, > _Compare __comp) > { > if (__len1 == 0 || __len2 == 0) > return; > if (__len1 + __len2 == 2) > { > if (__comp(__middle, __first)) > std::iter_swap(__first, __middle); > return; > } > _BidirectionalIterator __first_cut = __first; > _BidirectionalIterator __second_cut = __middle; > _Distance __len11 = 0; > _Distance __len22 = 0; > if (__len1 > __len2) > { > __len11 = __len1 / 2; > std::advance(__first_cut, __len11); > __second_cut > = std::__lower_bound(__middle, __last, *__first_cut, > __gnu_cxx::__ops::__iter_comp_val(__comp)); > __len22 = std::distance(__middle, __second_cut); > } > else > { > __len22 = __len2 / 2; > std::advance(__second_cut, __len22); > __first_cut > = std::__upper_bound(__first, __middle, *__second_cut, > __gnu_cxx::__ops::__val_comp_iter(__comp)); > __len11 = std::distance(__first, __first_cut); > } > std::rotate(__first_cut, __middle, __second_cut); > _BidirectionalIterator __new_middle = __first_cut; > std::advance(__new_middle, std::distance(__middle, __second_cut)); > std::__merge_without_buffer(__first, __first_cut, __new_middle, > __len11, __len22, __comp); > std::__merge_without_buffer(__new_middle, __second_cut, __last, > __len1 - __len11, __len2 - __len22, __comp); > } > > template<typename _BidirectionalIterator, typename _Compare> > void > __inplace_merge(_BidirectionalIterator __first, > _BidirectionalIterator __middle, > _BidirectionalIterator __last, > _Compare __comp) > { > typedef typename iterator_traits<_BidirectionalIterator>::value_type > _ValueType; > typedef typename iterator_traits<_BidirectionalIterator>::difference_type > _DistanceType; > > if (__first == __middle || __middle == __last) > return; > > const _DistanceType __len1 = std::distance(__first, __middle); > const _DistanceType __len2 = std::distance(__middle, __last); > > typedef _Temporary_buffer<_BidirectionalIterator, _ValueType> _TmpBuf; > _TmpBuf __buf(__first, __last); > > if (__buf.begin() == 0) > std::__merge_without_buffer > (__first, __middle, __last, __len1, __len2, __comp); > else > std::__merge_adaptive > (__first, __middle, __last, __len1, __len2, __buf.begin(), > _DistanceType(__buf.size()), __comp); > } ># 2584 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _BidirectionalIterator> > inline void > inplace_merge(_BidirectionalIterator __first, > _BidirectionalIterator __middle, > _BidirectionalIterator __last) > { > > > > > > ; > ; > > std::__inplace_merge(__first, __middle, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 2624 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _BidirectionalIterator, typename _Compare> > inline void > inplace_merge(_BidirectionalIterator __first, > _BidirectionalIterator __middle, > _BidirectionalIterator __last, > _Compare __comp) > { > > > > > > > ; > ; > > std::__inplace_merge(__first, __middle, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > > > template<typename _InputIterator, typename _OutputIterator, > typename _Compare> > _OutputIterator > __move_merge(_InputIterator __first1, _InputIterator __last1, > _InputIterator __first2, _InputIterator __last2, > _OutputIterator __result, _Compare __comp) > { > while (__first1 != __last1 && __first2 != __last2) > { > if (__comp(__first2, __first1)) > { > *__result = std::move(*__first2); > ++__first2; > } > else > { > *__result = std::move(*__first1); > ++__first1; > } > ++__result; > } > return std::move(__first2, __last2, std::move(__first1, __last1, __result)) > > ; > } > > template<typename _RandomAccessIterator1, typename _RandomAccessIterator2, > typename _Distance, typename _Compare> > void > __merge_sort_loop(_RandomAccessIterator1 __first, > _RandomAccessIterator1 __last, > _RandomAccessIterator2 __result, _Distance __step_size, > _Compare __comp) > { > const _Distance __two_step = 2 * __step_size; > > while (__last - __first >= __two_step) > { > __result = std::__move_merge(__first, __first + __step_size, > __first + __step_size, > __first + __two_step, > __result, __comp); > __first += __two_step; > } > __step_size = std::min(_Distance(__last - __first), __step_size); > > std::__move_merge(__first, __first + __step_size, > __first + __step_size, __last, __result, __comp); > } > > template<typename _RandomAccessIterator, typename _Distance, > typename _Compare> > void > __chunk_insertion_sort(_RandomAccessIterator __first, > _RandomAccessIterator __last, > _Distance __chunk_size, _Compare __comp) > { > while (__last - __first >= __chunk_size) > { > std::__insertion_sort(__first, __first + __chunk_size, __comp); > __first += __chunk_size; > } > std::__insertion_sort(__first, __last, __comp); > } > > enum { _S_chunk_size = 7 }; > > template<typename _RandomAccessIterator, typename _Pointer, typename _Compare> > void > __merge_sort_with_buffer(_RandomAccessIterator __first, > _RandomAccessIterator __last, > _Pointer __buffer, _Compare __comp) > { > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _Distance; > > const _Distance __len = __last - __first; > const _Pointer __buffer_last = __buffer + __len; > > _Distance __step_size = _S_chunk_size; > std::__chunk_insertion_sort(__first, __last, __step_size, __comp); > > while (__step_size < __len) > { > std::__merge_sort_loop(__first, __last, __buffer, > __step_size, __comp); > __step_size *= 2; > std::__merge_sort_loop(__buffer, __buffer_last, __first, > __step_size, __comp); > __step_size *= 2; > } > } > > template<typename _RandomAccessIterator, typename _Pointer, > typename _Distance, typename _Compare> > void > __stable_sort_adaptive(_RandomAccessIterator __first, > _RandomAccessIterator __last, > _Pointer __buffer, _Distance __buffer_size, > _Compare __comp) > { > const _Distance __len = (__last - __first + 1) / 2; > const _RandomAccessIterator __middle = __first + __len; > if (__len > __buffer_size) > { > std::__stable_sort_adaptive(__first, __middle, __buffer, > __buffer_size, __comp); > std::__stable_sort_adaptive(__middle, __last, __buffer, > __buffer_size, __comp); > } > else > { > std::__merge_sort_with_buffer(__first, __middle, __buffer, __comp); > std::__merge_sort_with_buffer(__middle, __last, __buffer, __comp); > } > std::__merge_adaptive(__first, __middle, __last, > _Distance(__middle - __first), > _Distance(__last - __middle), > __buffer, __buffer_size, > __comp); > } > > > template<typename _RandomAccessIterator, typename _Compare> > void > __inplace_stable_sort(_RandomAccessIterator __first, > _RandomAccessIterator __last, _Compare __comp) > { > if (__last - __first < 15) > { > std::__insertion_sort(__first, __last, __comp); > return; > } > _RandomAccessIterator __middle = __first + (__last - __first) / 2; > std::__inplace_stable_sort(__first, __middle, __comp); > std::__inplace_stable_sort(__middle, __last, __comp); > std::__merge_without_buffer(__first, __middle, __last, > __middle - __first, > __last - __middle, > __comp); > } ># 2795 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _Compare> > bool > __includes(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _Compare __comp) > { > while (__first1 != __last1 && __first2 != __last2) > if (__comp(__first2, __first1)) > return false; > else if (__comp(__first1, __first2)) > ++__first1; > else > ++__first1, ++__first2; > > return __first2 == __last2; > } ># 2831 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2> > inline bool > includes(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2) > { ># 2845 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__includes(__first1, __last1, __first2, __last2, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 2873 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _Compare> > inline bool > includes(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _Compare __comp) > { ># 2889 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__includes(__first1, __last1, __first2, __last2, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } ># 2906 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _BidirectionalIterator, typename _Compare> > bool > __next_permutation(_BidirectionalIterator __first, > _BidirectionalIterator __last, _Compare __comp) > { > if (__first == __last) > return false; > _BidirectionalIterator __i = __first; > ++__i; > if (__i == __last) > return false; > __i = __last; > --__i; > > for(;;) > { > _BidirectionalIterator __ii = __i; > --__i; > if (__comp(__i, __ii)) > { > _BidirectionalIterator __j = __last; > while (!__comp(__i, --__j)) > {} > std::iter_swap(__i, __j); > std::__reverse(__ii, __last, > std::__iterator_category(__first)); > return true; > } > if (__i == __first) > { > std::__reverse(__first, __last, > std::__iterator_category(__first)); > return false; > } > } > } ># 2955 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _BidirectionalIterator> > inline bool > next_permutation(_BidirectionalIterator __first, > _BidirectionalIterator __last) > { > > > > > > ; > > return std::__next_permutation > (__first, __last, __gnu_cxx::__ops::__iter_less_iter()); > } ># 2986 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _BidirectionalIterator, typename _Compare> > inline bool > next_permutation(_BidirectionalIterator __first, > _BidirectionalIterator __last, _Compare __comp) > { > > > > > > > ; > > return std::__next_permutation > (__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _BidirectionalIterator, typename _Compare> > bool > __prev_permutation(_BidirectionalIterator __first, > _BidirectionalIterator __last, _Compare __comp) > { > if (__first == __last) > return false; > _BidirectionalIterator __i = __first; > ++__i; > if (__i == __last) > return false; > __i = __last; > --__i; > > for(;;) > { > _BidirectionalIterator __ii = __i; > --__i; > if (__comp(__ii, __i)) > { > _BidirectionalIterator __j = __last; > while (!__comp(--__j, __i)) > {} > std::iter_swap(__i, __j); > std::__reverse(__ii, __last, > std::__iterator_category(__first)); > return true; > } > if (__i == __first) > { > std::__reverse(__first, __last, > std::__iterator_category(__first)); > return false; > } > } > } ># 3053 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _BidirectionalIterator> > inline bool > prev_permutation(_BidirectionalIterator __first, > _BidirectionalIterator __last) > { > > > > > > ; > > return std::__prev_permutation(__first, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 3084 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _BidirectionalIterator, typename _Compare> > inline bool > prev_permutation(_BidirectionalIterator __first, > _BidirectionalIterator __last, _Compare __comp) > { > > > > > > > ; > > return std::__prev_permutation(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > > > > template<typename _InputIterator, typename _OutputIterator, > typename _Predicate, typename _Tp> > _OutputIterator > __replace_copy_if(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, > _Predicate __pred, const _Tp& __new_value) > { > for (; __first != __last; ++__first, ++__result) > if (__pred(__first)) > *__result = __new_value; > else > *__result = *__first; > return __result; > } ># 3133 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _OutputIterator, typename _Tp> > inline _OutputIterator > replace_copy(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, > const _Tp& __old_value, const _Tp& __new_value) > { > > > > > > > ; > > return std::__replace_copy_if(__first, __last, __result, > __gnu_cxx::__ops::__iter_equals_val(__old_value), > __new_value); > } ># 3167 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _OutputIterator, > typename _Predicate, typename _Tp> > inline _OutputIterator > replace_copy_if(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, > _Predicate __pred, const _Tp& __new_value) > { > > > > > > > ; > > return std::__replace_copy_if(__first, __last, __result, > __gnu_cxx::__ops::__pred_iter(__pred), > __new_value); > } > > template<typename _InputIterator, typename _Predicate> > typename iterator_traits<_InputIterator>::difference_type > __count_if(_InputIterator __first, _InputIterator __last, _Predicate __pred) > { > typename iterator_traits<_InputIterator>::difference_type __n = 0; > for (; __first != __last; ++__first) > if (__pred(__first)) > ++__n; > return __n; > } ># 3206 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator> > inline bool > is_sorted(_ForwardIterator __first, _ForwardIterator __last) > { return std::is_sorted_until(__first, __last) == __last; } ># 3220 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Compare> > inline bool > is_sorted(_ForwardIterator __first, _ForwardIterator __last, > _Compare __comp) > { return std::is_sorted_until(__first, __last, __comp) == __last; } > > template<typename _ForwardIterator, typename _Compare> > _ForwardIterator > __is_sorted_until(_ForwardIterator __first, _ForwardIterator __last, > _Compare __comp) > { > if (__first == __last) > return __last; > > _ForwardIterator __next = __first; > for (++__next; __next != __last; __first = __next, ++__next) > if (__comp(__next, __first)) > return __next; > return __next; > } ># 3249 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator> > inline _ForwardIterator > is_sorted_until(_ForwardIterator __first, _ForwardIterator __last) > { > > > > > ; > > return std::__is_sorted_until(__first, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 3272 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Compare> > inline _ForwardIterator > is_sorted_until(_ForwardIterator __first, _ForwardIterator __last, > _Compare __comp) > { > > > > > > ; > > return std::__is_sorted_until(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } ># 3296 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _Tp> > inline pair<const _Tp&, const _Tp&> > minmax(const _Tp& __a, const _Tp& __b) > { > > > > return __b < __a ? pair<const _Tp&, const _Tp&>(__b, __a) > : pair<const _Tp&, const _Tp&>(__a, __b); > } ># 3316 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _Tp, typename _Compare> > inline pair<const _Tp&, const _Tp&> > minmax(const _Tp& __a, const _Tp& __b, _Compare __comp) > { > return __comp(__b, __a) ? pair<const _Tp&, const _Tp&>(__b, __a) > : pair<const _Tp&, const _Tp&>(__a, __b); > } > > template<typename _ForwardIterator, typename _Compare> > pair<_ForwardIterator, _ForwardIterator> > __minmax_element(_ForwardIterator __first, _ForwardIterator __last, > _Compare __comp) > { > _ForwardIterator __next = __first; > if (__first == __last > || ++__next == __last) > return std::make_pair(__first, __first); > > _ForwardIterator __min, __max; > if (__comp(__next, __first)) > { > __min = __next; > __max = __first; > } > else > { > __min = __first; > __max = __next; > } > > __first = __next; > ++__first; > > while (__first != __last) > { > __next = __first; > if (++__next == __last) > { > if (__comp(__first, __min)) > __min = __first; > else if (!__comp(__first, __max)) > __max = __first; > break; > } > > if (__comp(__next, __first)) > { > if (__comp(__next, __min)) > __min = __next; > if (!__comp(__first, __max)) > __max = __first; > } > else > { > if (__comp(__first, __min)) > __min = __first; > if (!__comp(__next, __max)) > __max = __next; > } > > __first = __next; > ++__first; > } > > return std::make_pair(__min, __max); > } ># 3394 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator> > inline pair<_ForwardIterator, _ForwardIterator> > minmax_element(_ForwardIterator __first, _ForwardIterator __last) > { > > > > > ; > > return std::__minmax_element(__first, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 3420 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Compare> > inline pair<_ForwardIterator, _ForwardIterator> > minmax_element(_ForwardIterator __first, _ForwardIterator __last, > _Compare __comp) > { > > > > > > ; > > return std::__minmax_element(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > > template<typename _Tp> > inline _Tp > min(initializer_list<_Tp> __l) > { return *std::min_element(__l.begin(), __l.end()); } > > template<typename _Tp, typename _Compare> > inline _Tp > min(initializer_list<_Tp> __l, _Compare __comp) > { return *std::min_element(__l.begin(), __l.end(), __comp); } > > template<typename _Tp> > inline _Tp > max(initializer_list<_Tp> __l) > { return *std::max_element(__l.begin(), __l.end()); } > > template<typename _Tp, typename _Compare> > inline _Tp > max(initializer_list<_Tp> __l, _Compare __comp) > { return *std::max_element(__l.begin(), __l.end(), __comp); } > > template<typename _Tp> > inline pair<_Tp, _Tp> > minmax(initializer_list<_Tp> __l) > { > pair<const _Tp*, const _Tp*> __p = > std::minmax_element(__l.begin(), __l.end()); > return std::make_pair(*__p.first, *__p.second); > } > > template<typename _Tp, typename _Compare> > inline pair<_Tp, _Tp> > minmax(initializer_list<_Tp> __l, _Compare __comp) > { > pair<const _Tp*, const _Tp*> __p = > std::minmax_element(__l.begin(), __l.end(), __comp); > return std::make_pair(*__p.first, *__p.second); > } > > template<typename _ForwardIterator1, typename _ForwardIterator2, > typename _BinaryPredicate> > bool > __is_permutation(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2, _BinaryPredicate __pred) > { > > > for (; __first1 != __last1; ++__first1, ++__first2) > if (!__pred(__first1, __first2)) > break; > > if (__first1 == __last1) > return true; > > > > _ForwardIterator2 __last2 = __first2; > std::advance(__last2, std::distance(__first1, __last1)); > for (_ForwardIterator1 __scan = __first1; __scan != __last1; ++__scan) > { > if (__scan != std::__find_if(__first1, __scan, > __gnu_cxx::__ops::__iter_comp_iter(__pred, __scan))) > continue; > > auto __matches > = std::__count_if(__first2, __last2, > __gnu_cxx::__ops::__iter_comp_iter(__pred, __scan)); > if (0 == __matches || > std::__count_if(__scan, __last1, > __gnu_cxx::__ops::__iter_comp_iter(__pred, __scan)) > != __matches) > return false; > } > return true; > } ># 3524 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator1, typename _ForwardIterator2> > inline bool > is_permutation(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2) > { > > > > > > > ; > > return std::__is_permutation(__first1, __last1, __first2, > __gnu_cxx::__ops::__iter_equal_to_iter()); > } ># 3555 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator1, typename _ForwardIterator2, > typename _BinaryPredicate> > inline bool > is_permutation(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2, _BinaryPredicate __pred) > { > > > > > > > ; > > return std::__is_permutation(__first1, __last1, __first2, > __gnu_cxx::__ops::__iter_comp_iter(__pred)); > } ># 3702 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator, > typename _UniformRandomNumberGenerator> > void > shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last, > _UniformRandomNumberGenerator&& __g) > { > > > > ; > > if (__first == __last) > return; > > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _DistanceType; > > typedef typename std::make_unsigned<_DistanceType>::type __ud_type; > typedef typename std::uniform_int_distribution<__ud_type> __distr_type; > typedef typename __distr_type::param_type __p_type; > __distr_type __d; > > for (_RandomAccessIterator __i = __first + 1; __i != __last; ++__i) > std::iter_swap(__i, __first + __d(__g, __p_type(0, __i - __first))); > } ># 3747 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Function> > _Function > for_each(_InputIterator __first, _InputIterator __last, _Function __f) > { > > > ; > for (; __first != __last; ++__first) > __f(*__first); > return std::move(__f); > } ># 3768 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Tp> > inline _InputIterator > find(_InputIterator __first, _InputIterator __last, > const _Tp& __val) > { > > > > > ; > return std::__find_if(__first, __last, > __gnu_cxx::__ops::__iter_equals_val(__val)); > } ># 3792 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Predicate> > inline _InputIterator > find_if(_InputIterator __first, _InputIterator __last, > _Predicate __pred) > { > > > > > ; > > return std::__find_if(__first, __last, > __gnu_cxx::__ops::__pred_iter(__pred)); > } ># 3823 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _ForwardIterator> > _InputIterator > find_first_of(_InputIterator __first1, _InputIterator __last1, > _ForwardIterator __first2, _ForwardIterator __last2) > { > > > > > > > ; > ; > > for (; __first1 != __last1; ++__first1) > for (_ForwardIterator __iter = __first2; __iter != __last2; ++__iter) > if (*__first1 == *__iter) > return __first1; > return __last1; > } ># 3863 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _ForwardIterator, > typename _BinaryPredicate> > _InputIterator > find_first_of(_InputIterator __first1, _InputIterator __last1, > _ForwardIterator __first2, _ForwardIterator __last2, > _BinaryPredicate __comp) > { > > > > > > > ; > ; > > for (; __first1 != __last1; ++__first1) > for (_ForwardIterator __iter = __first2; __iter != __last2; ++__iter) > if (__comp(*__first1, *__iter)) > return __first1; > return __last1; > } ># 3895 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator> > inline _ForwardIterator > adjacent_find(_ForwardIterator __first, _ForwardIterator __last) > { > > > > > ; > > return std::__adjacent_find(__first, __last, > __gnu_cxx::__ops::__iter_equal_to_iter()); > } ># 3920 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _BinaryPredicate> > inline _ForwardIterator > adjacent_find(_ForwardIterator __first, _ForwardIterator __last, > _BinaryPredicate __binary_pred) > { > > > > > > ; > > return std::__adjacent_find(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__binary_pred)); > } ># 3945 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Tp> > inline typename iterator_traits<_InputIterator>::difference_type > count(_InputIterator __first, _InputIterator __last, const _Tp& __value) > { > > > > > ; > > return std::__count_if(__first, __last, > __gnu_cxx::__ops::__iter_equals_val(__value)); > } ># 3968 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _Predicate> > inline typename iterator_traits<_InputIterator>::difference_type > count_if(_InputIterator __first, _InputIterator __last, _Predicate __pred) > { > > > > > ; > > return std::__count_if(__first, __last, > __gnu_cxx::__ops::__pred_iter(__pred)); > } ># 4008 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator1, typename _ForwardIterator2> > inline _ForwardIterator1 > search(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2, _ForwardIterator2 __last2) > { > > > > > > > ; > ; > > return std::__search(__first1, __last1, __first2, __last2, > __gnu_cxx::__ops::__iter_equal_to_iter()); > } ># 4047 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator1, typename _ForwardIterator2, > typename _BinaryPredicate> > inline _ForwardIterator1 > search(_ForwardIterator1 __first1, _ForwardIterator1 __last1, > _ForwardIterator2 __first2, _ForwardIterator2 __last2, > _BinaryPredicate __predicate) > { > > > > > > > ; > ; > > return std::__search(__first1, __last1, __first2, __last2, > __gnu_cxx::__ops::__iter_comp_iter(__predicate)); > } ># 4082 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Integer, typename _Tp> > inline _ForwardIterator > search_n(_ForwardIterator __first, _ForwardIterator __last, > _Integer __count, const _Tp& __val) > { > > > > > ; > > return std::__search_n(__first, __last, __count, > __gnu_cxx::__ops::__iter_equals_val(__val)); > } ># 4115 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Integer, typename _Tp, > typename _BinaryPredicate> > inline _ForwardIterator > search_n(_ForwardIterator __first, _ForwardIterator __last, > _Integer __count, const _Tp& __val, > _BinaryPredicate __binary_pred) > { > > > > > ; > > return std::__search_n(__first, __last, __count, > __gnu_cxx::__ops::__iter_comp_val(__binary_pred, __val)); > } ># 4149 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _OutputIterator, > typename _UnaryOperation> > _OutputIterator > transform(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, _UnaryOperation __unary_op) > { > > > > > > ; > > for (; __first != __last; ++__first, ++__result) > *__result = __unary_op(*__first); > return __result; > } ># 4186 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, typename _BinaryOperation> > _OutputIterator > transform(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _OutputIterator __result, > _BinaryOperation __binary_op) > { > > > > > > > ; > > for (; __first1 != __last1; ++__first1, ++__first2, ++__result) > *__result = __binary_op(*__first1, *__first2); > return __result; > } ># 4219 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Tp> > void > replace(_ForwardIterator __first, _ForwardIterator __last, > const _Tp& __old_value, const _Tp& __new_value) > { > > > > > > > > ; > > for (; __first != __last; ++__first) > if (*__first == __old_value) > *__first = __new_value; > } ># 4251 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Predicate, typename _Tp> > void > replace_if(_ForwardIterator __first, _ForwardIterator __last, > _Predicate __pred, const _Tp& __new_value) > { > > > > > > > > ; > > for (; __first != __last; ++__first) > if (__pred(*__first)) > *__first = __new_value; > } ># 4283 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Generator> > void > generate(_ForwardIterator __first, _ForwardIterator __last, > _Generator __gen) > { > > > > > ; > > for (; __first != __last; ++__first) > *__first = __gen(); > } ># 4314 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _OutputIterator, typename _Size, typename _Generator> > _OutputIterator > generate_n(_OutputIterator __first, _Size __n, _Generator __gen) > { > > > > > > for (__decltype(__n + 0) __niter = __n; > __niter > 0; --__niter, ++__first) > *__first = __gen(); > return __first; > } ># 4350 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _OutputIterator> > inline _OutputIterator > unique_copy(_InputIterator __first, _InputIterator __last, > _OutputIterator __result) > { > > > > > > > ; > > if (__first == __last) > return __result; > return std::__unique_copy(__first, __last, __result, > __gnu_cxx::__ops::__iter_equal_to_iter(), > std::__iterator_category(__first), > std::__iterator_category(__result)); > } ># 4390 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator, typename _OutputIterator, > typename _BinaryPredicate> > inline _OutputIterator > unique_copy(_InputIterator __first, _InputIterator __last, > _OutputIterator __result, > _BinaryPredicate __binary_pred) > { > > > > > ; > > if (__first == __last) > return __result; > return std::__unique_copy(__first, __last, __result, > __gnu_cxx::__ops::__iter_comp_iter(__binary_pred), > std::__iterator_category(__first), > std::__iterator_category(__result)); > } ># 4422 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator> > inline void > random_shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last) > { > > > > ; > > if (__first != __last) > for (_RandomAccessIterator __i = __first + 1; __i != __last; ++__i) > std::iter_swap(__i, __first + (std::rand() % ((__i - __first) + 1))); > } ># 4450 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator, typename _RandomNumberGenerator> > void > random_shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last, > > _RandomNumberGenerator&& __rand) > > > > { > > > > ; > > if (__first == __last) > return; > for (_RandomAccessIterator __i = __first + 1; __i != __last; ++__i) > std::iter_swap(__i, __first + __rand((__i - __first) + 1)); > } ># 4486 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Predicate> > inline _ForwardIterator > partition(_ForwardIterator __first, _ForwardIterator __last, > _Predicate __pred) > { > > > > > > ; > > return std::__partition(__first, __last, __pred, > std::__iterator_category(__first)); > } ># 4519 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator> > inline void > partial_sort(_RandomAccessIterator __first, > _RandomAccessIterator __middle, > _RandomAccessIterator __last) > { > > > > > > ; > ; > > std::__partial_sort(__first, __middle, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 4556 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline void > partial_sort(_RandomAccessIterator __first, > _RandomAccessIterator __middle, > _RandomAccessIterator __last, > _Compare __comp) > { > > > > > > > ; > ; > > std::__partial_sort(__first, __middle, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } ># 4591 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator> > inline void > nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, > _RandomAccessIterator __last) > { > > > > > > ; > ; > > if (__first == __last || __nth == __last) > return; > > std::__introselect(__first, __nth, __last, > std::__lg(__last - __first) * 2, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 4629 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline void > nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, > _RandomAccessIterator __last, _Compare __comp) > { > > > > > > > ; > ; > > if (__first == __last || __nth == __last) > return; > > std::__introselect(__first, __nth, __last, > std::__lg(__last - __first) * 2, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } ># 4665 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator> > inline void > sort(_RandomAccessIterator __first, _RandomAccessIterator __last) > { > > > > > > ; > > std::__sort(__first, __last, __gnu_cxx::__ops::__iter_less_iter()); > } ># 4694 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline void > sort(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > > > > > > > ; > > std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, typename _Compare> > _OutputIterator > __merge(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, _Compare __comp) > { > while (__first1 != __last1 && __first2 != __last2) > { > if (__comp(__first2, __first1)) > { > *__result = *__first2; > ++__first2; > } > else > { > *__result = *__first1; > ++__first1; > } > ++__result; > } > return std::copy(__first2, __last2, > std::copy(__first1, __last1, __result)); > } ># 4754 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator> > inline _OutputIterator > merge(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result) > { ># 4771 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__merge(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 4802 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, typename _Compare> > inline _OutputIterator > merge(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, _Compare __comp) > { ># 4819 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__merge(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _RandomAccessIterator, typename _Compare> > inline void > __stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > typedef typename iterator_traits<_RandomAccessIterator>::value_type > _ValueType; > typedef typename iterator_traits<_RandomAccessIterator>::difference_type > _DistanceType; > > typedef _Temporary_buffer<_RandomAccessIterator, _ValueType> _TmpBuf; > _TmpBuf __buf(__first, __last); > > if (__buf.begin() == 0) > std::__inplace_stable_sort(__first, __last, __comp); > else > std::__stable_sort_adaptive(__first, __last, __buf.begin(), > _DistanceType(__buf.size()), __comp); > } ># 4864 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator> > inline void > stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last) > { > > > > > > ; > > std::__stable_sort(__first, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 4897 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _RandomAccessIterator, typename _Compare> > inline void > stable_sort(_RandomAccessIterator __first, _RandomAccessIterator __last, > _Compare __comp) > { > > > > > > > ; > > std::__stable_sort(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, > typename _Compare> > _OutputIterator > __set_union(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, _Compare __comp) > { > while (__first1 != __last1 && __first2 != __last2) > { > if (__comp(__first1, __first2)) > { > *__result = *__first1; > ++__first1; > } > else if (__comp(__first2, __first1)) > { > *__result = *__first2; > ++__first2; > } > else > { > *__result = *__first1; > ++__first1; > ++__first2; > } > ++__result; > } > return std::copy(__first2, __last2, > std::copy(__first1, __last1, __result)); > } ># 4964 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator> > inline _OutputIterator > set_union(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result) > { ># 4984 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__set_union(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 5011 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, typename _Compare> > inline _OutputIterator > set_union(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, _Compare __comp) > { ># 5031 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__set_union(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, > typename _Compare> > _OutputIterator > __set_intersection(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, _Compare __comp) > { > while (__first1 != __last1 && __first2 != __last2) > if (__comp(__first1, __first2)) > ++__first1; > else if (__comp(__first2, __first1)) > ++__first2; > else > { > *__result = *__first1; > ++__first1; > ++__first2; > ++__result; > } > return __result; > } ># 5079 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator> > inline _OutputIterator > set_intersection(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result) > { ># 5097 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__set_intersection(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 5125 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, typename _Compare> > inline _OutputIterator > set_intersection(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, _Compare __comp) > { ># 5143 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__set_intersection(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, > typename _Compare> > _OutputIterator > __set_difference(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, _Compare __comp) > { > while (__first1 != __last1 && __first2 != __last2) > if (__comp(__first1, __first2)) > { > *__result = *__first1; > ++__first1; > ++__result; > } > else if (__comp(__first2, __first1)) > ++__first2; > else > { > ++__first1; > ++__first2; > } > return std::copy(__first1, __last1, __result); > } ># 5195 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator> > inline _OutputIterator > set_difference(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result) > { ># 5213 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__set_difference(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 5243 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, typename _Compare> > inline _OutputIterator > set_difference(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, _Compare __comp) > { ># 5261 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__set_difference(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, > typename _Compare> > _OutputIterator > __set_symmetric_difference(_InputIterator1 __first1, > _InputIterator1 __last1, > _InputIterator2 __first2, > _InputIterator2 __last2, > _OutputIterator __result, > _Compare __comp) > { > while (__first1 != __last1 && __first2 != __last2) > if (__comp(__first1, __first2)) > { > *__result = *__first1; > ++__first1; > ++__result; > } > else if (__comp(__first2, __first1)) > { > *__result = *__first2; > ++__first2; > ++__result; > } > else > { > ++__first1; > ++__first2; > } > return std::copy(__first2, __last2, > std::copy(__first1, __last1, __result)); > } ># 5319 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator> > inline _OutputIterator > set_symmetric_difference(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result) > { ># 5339 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__set_symmetric_difference(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 5367 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _InputIterator1, typename _InputIterator2, > typename _OutputIterator, typename _Compare> > inline _OutputIterator > set_symmetric_difference(_InputIterator1 __first1, _InputIterator1 __last1, > _InputIterator2 __first2, _InputIterator2 __last2, > _OutputIterator __result, > _Compare __comp) > { ># 5388 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > ; > ; > > return std::__set_symmetric_difference(__first1, __last1, > __first2, __last2, __result, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _ForwardIterator, typename _Compare> > _ForwardIterator > __min_element(_ForwardIterator __first, _ForwardIterator __last, > _Compare __comp) > { > if (__first == __last) > return __first; > _ForwardIterator __result = __first; > while (++__first != __last) > if (__comp(__first, __result)) > __result = __first; > return __result; > } ># 5417 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator> > _ForwardIterator > inline min_element(_ForwardIterator __first, _ForwardIterator __last) > { > > > > > ; > > return std::__min_element(__first, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 5440 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Compare> > inline _ForwardIterator > min_element(_ForwardIterator __first, _ForwardIterator __last, > _Compare __comp) > { > > > > > > ; > > return std::__min_element(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > template<typename _ForwardIterator, typename _Compare> > _ForwardIterator > __max_element(_ForwardIterator __first, _ForwardIterator __last, > _Compare __comp) > { > if (__first == __last) return __first; > _ForwardIterator __result = __first; > while (++__first != __last) > if (__comp(__result, __first)) > __result = __first; > return __result; > } ># 5476 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator> > inline _ForwardIterator > max_element(_ForwardIterator __first, _ForwardIterator __last) > { > > > > > ; > > return std::__max_element(__first, __last, > __gnu_cxx::__ops::__iter_less_iter()); > } ># 5499 "/usr/include/c++/4.9.0/bits/stl_algo.h" 3 > template<typename _ForwardIterator, typename _Compare> > inline _ForwardIterator > max_element(_ForwardIterator __first, _ForwardIterator __last, > _Compare __comp) > { > > > > > > ; > > return std::__max_element(__first, __last, > __gnu_cxx::__ops::__iter_comp_iter(__comp)); > } > > >} ># 63 "/usr/include/c++/4.9.0/algorithm" 2 3 ># 39 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/usr/include/c++/4.9.0/list" 1 3 ># 58 "/usr/include/c++/4.9.0/list" 3 ># 59 "/usr/include/c++/4.9.0/list" 3 > > > > ># 1 "/usr/include/c++/4.9.0/bits/stl_list.h" 1 3 ># 64 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > namespace __detail > { ># 77 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > struct _List_node_base > { > _List_node_base* _M_next; > _List_node_base* _M_prev; > > static void > swap(_List_node_base& __x, _List_node_base& __y) noexcept; > > void > _M_transfer(_List_node_base* const __first, > _List_node_base* const __last) noexcept; > > void > _M_reverse() noexcept; > > void > _M_hook(_List_node_base* const __position) noexcept; > > void > _M_unhook() noexcept; > }; > > > } > > > > > template<typename _Tp> > struct _List_node : public __detail::_List_node_base > { > > _Tp _M_data; > > > template<typename... _Args> > _List_node(_Args&&... __args) > : __detail::_List_node_base(), _M_data(std::forward<_Args>(__args)...) > { } > > }; > > > > > > > template<typename _Tp> > struct _List_iterator > { > typedef _List_iterator<_Tp> _Self; > typedef _List_node<_Tp> _Node; > > typedef ptrdiff_t difference_type; > typedef std::bidirectional_iterator_tag iterator_category; > typedef _Tp value_type; > typedef _Tp* pointer; > typedef _Tp& reference; > > _List_iterator() noexcept > : _M_node() { } > > explicit > _List_iterator(__detail::_List_node_base* __x) noexcept > : _M_node(__x) { } > > _Self > _M_const_cast() const noexcept > { return *this; } > > > reference > operator*() const noexcept > { return static_cast<_Node*>(_M_node)->_M_data; } > > pointer > operator->() const noexcept > { return std::__addressof(static_cast<_Node*>(_M_node)->_M_data); } > > _Self& > operator++() noexcept > { > _M_node = _M_node->_M_next; > return *this; > } > > _Self > operator++(int) noexcept > { > _Self __tmp = *this; > _M_node = _M_node->_M_next; > return __tmp; > } > > _Self& > operator--() noexcept > { > _M_node = _M_node->_M_prev; > return *this; > } > > _Self > operator--(int) noexcept > { > _Self __tmp = *this; > _M_node = _M_node->_M_prev; > return __tmp; > } > > bool > operator==(const _Self& __x) const noexcept > { return _M_node == __x._M_node; } > > bool > operator!=(const _Self& __x) const noexcept > { return _M_node != __x._M_node; } > > > __detail::_List_node_base* _M_node; > }; > > > > > > > template<typename _Tp> > struct _List_const_iterator > { > typedef _List_const_iterator<_Tp> _Self; > typedef const _List_node<_Tp> _Node; > typedef _List_iterator<_Tp> iterator; > > typedef ptrdiff_t difference_type; > typedef std::bidirectional_iterator_tag iterator_category; > typedef _Tp value_type; > typedef const _Tp* pointer; > typedef const _Tp& reference; > > _List_const_iterator() noexcept > : _M_node() { } > > explicit > _List_const_iterator(const __detail::_List_node_base* __x) > noexcept > : _M_node(__x) { } > > _List_const_iterator(const iterator& __x) noexcept > : _M_node(__x._M_node) { } > > iterator > _M_const_cast() const noexcept > { return iterator(const_cast<__detail::_List_node_base*>(_M_node)); } > > > > reference > operator*() const noexcept > { return static_cast<_Node*>(_M_node)->_M_data; } > > pointer > operator->() const noexcept > { return std::__addressof(static_cast<_Node*>(_M_node)->_M_data); } > > _Self& > operator++() noexcept > { > _M_node = _M_node->_M_next; > return *this; > } > > _Self > operator++(int) noexcept > { > _Self __tmp = *this; > _M_node = _M_node->_M_next; > return __tmp; > } > > _Self& > operator--() noexcept > { > _M_node = _M_node->_M_prev; > return *this; > } > > _Self > operator--(int) noexcept > { > _Self __tmp = *this; > _M_node = _M_node->_M_prev; > return __tmp; > } > > bool > operator==(const _Self& __x) const noexcept > { return _M_node == __x._M_node; } > > bool > operator!=(const _Self& __x) const noexcept > { return _M_node != __x._M_node; } > > > const __detail::_List_node_base* _M_node; > }; > > template<typename _Val> > inline bool > operator==(const _List_iterator<_Val>& __x, > const _List_const_iterator<_Val>& __y) noexcept > { return __x._M_node == __y._M_node; } > > template<typename _Val> > inline bool > operator!=(const _List_iterator<_Val>& __x, > const _List_const_iterator<_Val>& __y) noexcept > { return __x._M_node != __y._M_node; } > > > > template<typename _Tp, typename _Alloc> > class _List_base > { > protected: ># 314 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > typedef typename _Alloc::template rebind<_List_node<_Tp> >::other > _Node_alloc_type; > > typedef typename _Alloc::template rebind<_Tp>::other _Tp_alloc_type; > > struct _List_impl > : public _Node_alloc_type > { > __detail::_List_node_base _M_node; > > _List_impl() > : _Node_alloc_type(), _M_node() > { } > > _List_impl(const _Node_alloc_type& __a) noexcept > : _Node_alloc_type(__a), _M_node() > { } > > > _List_impl(_Node_alloc_type&& __a) noexcept > : _Node_alloc_type(std::move(__a)), _M_node() > { } > > }; > > _List_impl _M_impl; > > _List_node<_Tp>* > _M_get_node() > { return _M_impl._Node_alloc_type::allocate(1); } > > void > _M_put_node(_List_node<_Tp>* __p) noexcept > { _M_impl._Node_alloc_type::deallocate(__p, 1); } > > public: > typedef _Alloc allocator_type; > > _Node_alloc_type& > _M_get_Node_allocator() noexcept > { return *static_cast<_Node_alloc_type*>(&_M_impl); } > > const _Node_alloc_type& > _M_get_Node_allocator() const noexcept > { return *static_cast<const _Node_alloc_type*>(&_M_impl); } > > _Tp_alloc_type > _M_get_Tp_allocator() const noexcept > { return _Tp_alloc_type(_M_get_Node_allocator()); } > > allocator_type > get_allocator() const noexcept > { return allocator_type(_M_get_Node_allocator()); } > > _List_base() > : _M_impl() > { _M_init(); } > > _List_base(const _Node_alloc_type& __a) noexcept > : _M_impl(__a) > { _M_init(); } > > > _List_base(_List_base&& __x) noexcept > : _M_impl(std::move(__x._M_get_Node_allocator())) > { > _M_init(); > __detail::_List_node_base::swap(_M_impl._M_node, __x._M_impl._M_node); > } > > > > ~_List_base() noexcept > { _M_clear(); } > > void > _M_clear() noexcept; > > void > _M_init() noexcept > { > this->_M_impl._M_node._M_next = &this->_M_impl._M_node; > this->_M_impl._M_node._M_prev = &this->_M_impl._M_node; > } > }; ># 446 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _Tp, typename _Alloc = std::allocator<_Tp> > > class list : protected _List_base<_Tp, _Alloc> > { > > typedef typename _Alloc::value_type _Alloc_value_type; > > > > typedef _List_base<_Tp, _Alloc> _Base; > typedef typename _Base::_Tp_alloc_type _Tp_alloc_type; > typedef typename _Base::_Node_alloc_type _Node_alloc_type; > > public: > typedef _Tp value_type; > typedef typename _Tp_alloc_type::pointer pointer; > typedef typename _Tp_alloc_type::const_pointer const_pointer; > typedef typename _Tp_alloc_type::reference reference; > typedef typename _Tp_alloc_type::const_reference const_reference; > typedef _List_iterator<_Tp> iterator; > typedef _List_const_iterator<_Tp> const_iterator; > typedef std::reverse_iterator<const_iterator> const_reverse_iterator; > typedef std::reverse_iterator<iterator> reverse_iterator; > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef _Alloc allocator_type; > > protected: > > > typedef _List_node<_Tp> _Node; > > using _Base::_M_impl; > using _Base::_M_put_node; > using _Base::_M_get_node; > using _Base::_M_get_Tp_allocator; > using _Base::_M_get_Node_allocator; ># 507 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename... _Args> > _Node* > _M_create_node(_Args&&... __args) > { > _Node* __p = this->_M_get_node(); > try > { > _M_get_Node_allocator().construct(__p, > std::forward<_Args>(__args)...); > } > catch(...) > { > _M_put_node(__p); > throw; > } > return __p; > } > > > public: > > > > > > > list() > > noexcept(is_nothrow_default_constructible<_Node_alloc_type>::value) > > : _Base() { } > > > > > > explicit > list(const allocator_type& __a) noexcept > : _Base(_Node_alloc_type(__a)) { } ># 555 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > explicit > list(size_type __n) > : _Base() > { _M_default_initialize(__n); } ># 568 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > list(size_type __n, const value_type& __value, > const allocator_type& __a = allocator_type()) > : _Base(_Node_alloc_type(__a)) > { _M_fill_initialize(__n, __value); } ># 595 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > list(const list& __x) > : _Base(__x._M_get_Node_allocator()) > { _M_initialize_dispatch(__x.begin(), __x.end(), __false_type()); } ># 607 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > list(list&& __x) noexcept > : _Base(std::move(__x)) { } ># 618 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > list(initializer_list<value_type> __l, > const allocator_type& __a = allocator_type()) > : _Base(_Node_alloc_type(__a)) > { _M_initialize_dispatch(__l.begin(), __l.end(), __false_type()); } ># 635 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > list(_InputIterator __first, _InputIterator __last, > const allocator_type& __a = allocator_type()) > : _Base(_Node_alloc_type(__a)) > { _M_initialize_dispatch(__first, __last, __false_type()); } ># 668 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > list& > operator=(const list& __x); ># 679 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > list& > operator=(list&& __x) > { > > > this->clear(); > this->swap(__x); > return *this; > } ># 696 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > list& > operator=(initializer_list<value_type> __l) > { > this->assign(__l.begin(), __l.end()); > return *this; > } ># 714 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > assign(size_type __n, const value_type& __val) > { _M_fill_assign(__n, __val); } ># 731 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > void > assign(_InputIterator __first, _InputIterator __last) > { _M_assign_dispatch(__first, __last, __false_type()); } ># 755 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > assign(initializer_list<value_type> __l) > { this->assign(__l.begin(), __l.end()); } > > > > allocator_type > get_allocator() const noexcept > { return _Base::get_allocator(); } > > > > > > > iterator > begin() noexcept > { return iterator(this->_M_impl._M_node._M_next); } > > > > > > > const_iterator > begin() const noexcept > { return const_iterator(this->_M_impl._M_node._M_next); } > > > > > > > iterator > end() noexcept > { return iterator(&this->_M_impl._M_node); } > > > > > > > const_iterator > end() const noexcept > { return const_iterator(&this->_M_impl._M_node); } > > > > > > > reverse_iterator > rbegin() noexcept > { return reverse_iterator(end()); } > > > > > > > const_reverse_iterator > rbegin() const noexcept > { return const_reverse_iterator(end()); } > > > > > > > reverse_iterator > rend() noexcept > { return reverse_iterator(begin()); } > > > > > > > const_reverse_iterator > rend() const noexcept > { return const_reverse_iterator(begin()); } > > > > > > > > const_iterator > cbegin() const noexcept > { return const_iterator(this->_M_impl._M_node._M_next); } > > > > > > > const_iterator > cend() const noexcept > { return const_iterator(&this->_M_impl._M_node); } > > > > > > > const_reverse_iterator > crbegin() const noexcept > { return const_reverse_iterator(end()); } > > > > > > > const_reverse_iterator > crend() const noexcept > { return const_reverse_iterator(begin()); } > > > > > > > > bool > empty() const noexcept > { return this->_M_impl._M_node._M_next == &this->_M_impl._M_node; } > > > size_type > size() const noexcept > { return std::distance(begin(), end()); } > > > size_type > max_size() const noexcept > { return _M_get_Node_allocator().max_size(); } ># 904 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > resize(size_type __new_size); ># 917 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > resize(size_type __new_size, const value_type& __x); ># 939 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > reference > front() noexcept > { return *begin(); } > > > > > > const_reference > front() const noexcept > { return *begin(); } > > > > > > reference > back() noexcept > { > iterator __tmp = end(); > --__tmp; > return *__tmp; > } > > > > > > const_reference > back() const noexcept > { > const_iterator __tmp = end(); > --__tmp; > return *__tmp; > } ># 986 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > push_front(const value_type& __x) > { this->_M_insert(begin(), __x); } > > > void > push_front(value_type&& __x) > { this->_M_insert(begin(), std::move(__x)); } > > template<typename... _Args> > void > emplace_front(_Args&&... __args) > { this->_M_insert(begin(), std::forward<_Args>(__args)...); } ># 1013 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > pop_front() noexcept > { this->_M_erase(begin()); } ># 1027 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > push_back(const value_type& __x) > { this->_M_insert(end(), __x); } > > > void > push_back(value_type&& __x) > { this->_M_insert(end(), std::move(__x)); } > > template<typename... _Args> > void > emplace_back(_Args&&... __args) > { this->_M_insert(end(), std::forward<_Args>(__args)...); } ># 1053 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > pop_back() noexcept > { this->_M_erase(iterator(this->_M_impl._M_node._M_prev)); } ># 1070 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename... _Args> > iterator > emplace(const_iterator __position, _Args&&... __args); ># 1085 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > iterator > insert(const_iterator __position, const value_type& __x); ># 1115 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > iterator > insert(const_iterator __position, value_type&& __x) > { return emplace(__position, std::move(__x)); } ># 1134 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > iterator > insert(const_iterator __p, initializer_list<value_type> __l) > { return this->insert(__p, __l.begin(), __l.end()); } ># 1154 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > iterator > insert(const_iterator __position, size_type __n, const value_type& __x); ># 1193 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > iterator > insert(const_iterator __position, _InputIterator __first, > _InputIterator __last); ># 1237 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > iterator > > erase(const_iterator __position) noexcept; ># 1262 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > iterator > > erase(const_iterator __first, const_iterator __last) noexcept > > > > { > while (__first != __last) > __first = erase(__first); > return __last._M_const_cast(); > } ># 1283 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > swap(list& __x) > { > __detail::_List_node_base::swap(this->_M_impl._M_node, > __x._M_impl._M_node); > > > > std::__alloc_swap<typename _Base::_Node_alloc_type>:: > _S_do_it(_M_get_Node_allocator(), __x._M_get_Node_allocator()); > } > > > > > > > > void > clear() noexcept > { > _Base::_M_clear(); > _Base::_M_init(); > } ># 1320 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > > splice(const_iterator __position, list&& __x) noexcept > > > > { > if (!__x.empty()) > { > _M_check_equal_allocators(__x); > > this->_M_transfer(__position._M_const_cast(), > __x.begin(), __x.end()); > } > } > > > void > splice(const_iterator __position, list& __x) noexcept > { splice(__position, std::move(__x)); } ># 1353 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > splice(const_iterator __position, list&& __x, const_iterator __i) noexcept ># 1368 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > { > iterator __j = __i._M_const_cast(); > ++__j; > if (__position == __i || __position == __j) > return; > > if (this != &__x) > _M_check_equal_allocators(__x); > > this->_M_transfer(__position._M_const_cast(), > __i._M_const_cast(), __j); > } ># 1392 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > splice(const_iterator __position, list& __x, const_iterator __i) noexcept > { splice(__position, std::move(__x), __i); } ># 1411 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > splice(const_iterator __position, list&& __x, const_iterator __first, > const_iterator __last) noexcept ># 1431 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > { > if (__first != __last) > { > if (this != &__x) > _M_check_equal_allocators(__x); > > this->_M_transfer(__position._M_const_cast(), > __first._M_const_cast(), > __last._M_const_cast()); > } > } ># 1457 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > splice(const_iterator __position, list& __x, const_iterator __first, > const_iterator __last) noexcept > { splice(__position, std::move(__x), __first, __last); } ># 1474 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > remove(const _Tp& __value); ># 1488 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _Predicate> > void > remove_if(_Predicate); ># 1502 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > unique(); ># 1517 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _BinaryPredicate> > void > unique(_BinaryPredicate); ># 1531 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > merge(list&& __x); > > void > merge(list& __x) > { merge(std::move(__x)); } ># 1556 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _StrictWeakOrdering> > void > merge(list&& __x, _StrictWeakOrdering __comp); > > template<typename _StrictWeakOrdering> > void > merge(list& __x, _StrictWeakOrdering __comp) > { merge(std::move(__x), __comp); } ># 1575 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > void > reverse() noexcept > { this->_M_impl._M_node._M_reverse(); } > > > > > > > > void > sort(); > > > > > > > > template<typename _StrictWeakOrdering> > void > sort(_StrictWeakOrdering); > > protected: > > > > > > > template<typename _Integer> > void > _M_initialize_dispatch(_Integer __n, _Integer __x, __true_type) > { _M_fill_initialize(static_cast<size_type>(__n), __x); } > > > template<typename _InputIterator> > void > _M_initialize_dispatch(_InputIterator __first, _InputIterator __last, > __false_type) > { > for (; __first != __last; ++__first) > > emplace_back(*__first); > > > > } > > > > void > _M_fill_initialize(size_type __n, const value_type& __x) > { > for (; __n; --__n) > push_back(__x); > } > > > > void > _M_default_initialize(size_type __n) > { > for (; __n; --__n) > emplace_back(); > } > > > void > _M_default_append(size_type __n); ># 1653 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _Integer> > void > _M_assign_dispatch(_Integer __n, _Integer __val, __true_type) > { _M_fill_assign(__n, __val); } > > > template<typename _InputIterator> > void > _M_assign_dispatch(_InputIterator __first, _InputIterator __last, > __false_type); > > > > void > _M_fill_assign(size_type __n, const value_type& __val); > > > > void > _M_transfer(iterator __position, iterator __first, iterator __last) > { __position._M_node->_M_transfer(__first._M_node, __last._M_node); } ># 1684 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename... _Args> > void > _M_insert(iterator __position, _Args&&... __args) > { > _Node* __tmp = _M_create_node(std::forward<_Args>(__args)...); > __tmp->_M_hook(__position._M_node); > } > > > > void > _M_erase(iterator __position) noexcept > { > __position._M_node->_M_unhook(); > _Node* __n = static_cast<_Node*>(__position._M_node); > > _M_get_Node_allocator().destroy(__n); > > > > _M_put_node(__n); > } > > > void > _M_check_equal_allocators(list& __x) noexcept > { > if (std::__alloc_neq<typename _Base::_Node_alloc_type>:: > _S_do_it(_M_get_Node_allocator(), __x._M_get_Node_allocator())) > __builtin_abort(); > } > }; ># 1727 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _Tp, typename _Alloc> > inline bool > operator==(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) > { > typedef typename list<_Tp, _Alloc>::const_iterator const_iterator; > const_iterator __end1 = __x.end(); > const_iterator __end2 = __y.end(); > > const_iterator __i1 = __x.begin(); > const_iterator __i2 = __y.begin(); > while (__i1 != __end1 && __i2 != __end2 && *__i1 == *__i2) > { > ++__i1; > ++__i2; > } > return __i1 == __end1 && __i2 == __end2; > } ># 1756 "/usr/include/c++/4.9.0/bits/stl_list.h" 3 > template<typename _Tp, typename _Alloc> > inline bool > operator<(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) > { return std::lexicographical_compare(__x.begin(), __x.end(), > __y.begin(), __y.end()); } > > > template<typename _Tp, typename _Alloc> > inline bool > operator!=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) > { return !(__x == __y); } > > > template<typename _Tp, typename _Alloc> > inline bool > operator>(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) > { return __y < __x; } > > > template<typename _Tp, typename _Alloc> > inline bool > operator<=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) > { return !(__y < __x); } > > > template<typename _Tp, typename _Alloc> > inline bool > operator>=(const list<_Tp, _Alloc>& __x, const list<_Tp, _Alloc>& __y) > { return !(__x < __y); } > > > template<typename _Tp, typename _Alloc> > inline void > swap(list<_Tp, _Alloc>& __x, list<_Tp, _Alloc>& __y) > { __x.swap(__y); } > > >} ># 64 "/usr/include/c++/4.9.0/list" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/list.tcc" 1 3 ># 59 "/usr/include/c++/4.9.0/bits/list.tcc" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Tp, typename _Alloc> > void > _List_base<_Tp, _Alloc>:: > _M_clear() noexcept > { > typedef _List_node<_Tp> _Node; > _Node* __cur = static_cast<_Node*>(_M_impl._M_node._M_next); > while (__cur != &_M_impl._M_node) > { > _Node* __tmp = __cur; > __cur = static_cast<_Node*>(__cur->_M_next); > > _M_get_Node_allocator().destroy(__tmp); > > > > _M_put_node(__tmp); > } > } > > > template<typename _Tp, typename _Alloc> > template<typename... _Args> > typename list<_Tp, _Alloc>::iterator > list<_Tp, _Alloc>:: > emplace(const_iterator __position, _Args&&... __args) > { > _Node* __tmp = _M_create_node(std::forward<_Args>(__args)...); > __tmp->_M_hook(__position._M_const_cast()._M_node); > return iterator(__tmp); > } > > > template<typename _Tp, typename _Alloc> > typename list<_Tp, _Alloc>::iterator > list<_Tp, _Alloc>:: > > insert(const_iterator __position, const value_type& __x) > > > > { > _Node* __tmp = _M_create_node(__x); > __tmp->_M_hook(__position._M_const_cast()._M_node); > return iterator(__tmp); > } > > > template<typename _Tp, typename _Alloc> > typename list<_Tp, _Alloc>::iterator > list<_Tp, _Alloc>:: > insert(const_iterator __position, size_type __n, const value_type& __x) > { > if (__n) > { > list __tmp(__n, __x, get_allocator()); > iterator __it = __tmp.begin(); > splice(__position, __tmp); > return __it; > } > return __position._M_const_cast(); > } > > template<typename _Tp, typename _Alloc> > template<typename _InputIterator, typename> > typename list<_Tp, _Alloc>::iterator > list<_Tp, _Alloc>:: > insert(const_iterator __position, _InputIterator __first, > _InputIterator __last) > { > list __tmp(__first, __last, get_allocator()); > if (!__tmp.empty()) > { > iterator __it = __tmp.begin(); > splice(__position, __tmp); > return __it; > } > return __position._M_const_cast(); > } > > > template<typename _Tp, typename _Alloc> > typename list<_Tp, _Alloc>::iterator > list<_Tp, _Alloc>:: > > erase(const_iterator __position) noexcept > > > > { > iterator __ret = iterator(__position._M_node->_M_next); > _M_erase(__position._M_const_cast()); > return __ret; > } > > > template<typename _Tp, typename _Alloc> > void > list<_Tp, _Alloc>:: > _M_default_append(size_type __n) > { > size_type __i = 0; > try > { > for (; __i < __n; ++__i) > emplace_back(); > } > catch(...) > { > for (; __i; --__i) > pop_back(); > throw; > } > } > > template<typename _Tp, typename _Alloc> > void > list<_Tp, _Alloc>:: > resize(size_type __new_size) > { > iterator __i = begin(); > size_type __len = 0; > for (; __i != end() && __len < __new_size; ++__i, ++__len) > ; > if (__len == __new_size) > erase(__i, end()); > else > _M_default_append(__new_size - __len); > } > > template<typename _Tp, typename _Alloc> > void > list<_Tp, _Alloc>:: > resize(size_type __new_size, const value_type& __x) > { > iterator __i = begin(); > size_type __len = 0; > for (; __i != end() && __len < __new_size; ++__i, ++__len) > ; > if (__len == __new_size) > erase(__i, end()); > else > insert(end(), __new_size - __len, __x); > } ># 224 "/usr/include/c++/4.9.0/bits/list.tcc" 3 > template<typename _Tp, typename _Alloc> > list<_Tp, _Alloc>& > list<_Tp, _Alloc>:: > operator=(const list& __x) > { > if (this != &__x) > { > iterator __first1 = begin(); > iterator __last1 = end(); > const_iterator __first2 = __x.begin(); > const_iterator __last2 = __x.end(); > for (; __first1 != __last1 && __first2 != __last2; > ++__first1, ++__first2) > *__first1 = *__first2; > if (__first2 == __last2) > erase(__first1, __last1); > else > insert(__last1, __first2, __last2); > } > return *this; > } > > template<typename _Tp, typename _Alloc> > void > list<_Tp, _Alloc>:: > _M_fill_assign(size_type __n, const value_type& __val) > { > iterator __i = begin(); > for (; __i != end() && __n > 0; ++__i, --__n) > *__i = __val; > if (__n > 0) > insert(end(), __n, __val); > else > erase(__i, end()); > } > > template<typename _Tp, typename _Alloc> > template <typename _InputIterator> > void > list<_Tp, _Alloc>:: > _M_assign_dispatch(_InputIterator __first2, _InputIterator __last2, > __false_type) > { > iterator __first1 = begin(); > iterator __last1 = end(); > for (; __first1 != __last1 && __first2 != __last2; > ++__first1, ++__first2) > *__first1 = *__first2; > if (__first2 == __last2) > erase(__first1, __last1); > else > insert(__last1, __first2, __last2); > } > > template<typename _Tp, typename _Alloc> > void > list<_Tp, _Alloc>:: > remove(const value_type& __value) > { > iterator __first = begin(); > iterator __last = end(); > iterator __extra = __last; > while (__first != __last) > { > iterator __next = __first; > ++__next; > if (*__first == __value) > { > > > > if (std::__addressof(*__first) != std::__addressof(__value)) > _M_erase(__first); > else > __extra = __first; > } > __first = __next; > } > if (__extra != __last) > _M_erase(__extra); > } > > template<typename _Tp, typename _Alloc> > void > list<_Tp, _Alloc>:: > unique() > { > iterator __first = begin(); > iterator __last = end(); > if (__first == __last) > return; > iterator __next = __first; > while (++__next != __last) > { > if (*__first == *__next) > _M_erase(__next); > else > __first = __next; > __next = __first; > } > } > > template<typename _Tp, typename _Alloc> > void > list<_Tp, _Alloc>:: > > merge(list&& __x) > > > > { > > > if (this != &__x) > { > _M_check_equal_allocators(__x); > > iterator __first1 = begin(); > iterator __last1 = end(); > iterator __first2 = __x.begin(); > iterator __last2 = __x.end(); > while (__first1 != __last1 && __first2 != __last2) > if (*__first2 < *__first1) > { > iterator __next = __first2; > _M_transfer(__first1, __first2, ++__next); > __first2 = __next; > } > else > ++__first1; > if (__first2 != __last2) > _M_transfer(__last1, __first2, __last2); > } > } > > template<typename _Tp, typename _Alloc> > template <typename _StrictWeakOrdering> > void > list<_Tp, _Alloc>:: > > merge(list&& __x, _StrictWeakOrdering __comp) > > > > { > > > if (this != &__x) > { > _M_check_equal_allocators(__x); > > iterator __first1 = begin(); > iterator __last1 = end(); > iterator __first2 = __x.begin(); > iterator __last2 = __x.end(); > while (__first1 != __last1 && __first2 != __last2) > if (__comp(*__first2, *__first1)) > { > iterator __next = __first2; > _M_transfer(__first1, __first2, ++__next); > __first2 = __next; > } > else > ++__first1; > if (__first2 != __last2) > _M_transfer(__last1, __first2, __last2); > } > } > > template<typename _Tp, typename _Alloc> > void > list<_Tp, _Alloc>:: > sort() > { > > if (this->_M_impl._M_node._M_next != &this->_M_impl._M_node > && this->_M_impl._M_node._M_next->_M_next != &this->_M_impl._M_node) > { > list __carry; > list __tmp[64]; > list * __fill = &__tmp[0]; > list * __counter; > > do > { > __carry.splice(__carry.begin(), *this, begin()); > > for(__counter = &__tmp[0]; > __counter != __fill && !__counter->empty(); > ++__counter) > { > __counter->merge(__carry); > __carry.swap(*__counter); > } > __carry.swap(*__counter); > if (__counter == __fill) > ++__fill; > } > while ( !empty() ); > > for (__counter = &__tmp[1]; __counter != __fill; ++__counter) > __counter->merge(*(__counter - 1)); > swap( *(__fill - 1) ); > } > } > > template<typename _Tp, typename _Alloc> > template <typename _Predicate> > void > list<_Tp, _Alloc>:: > remove_if(_Predicate __pred) > { > iterator __first = begin(); > iterator __last = end(); > while (__first != __last) > { > iterator __next = __first; > ++__next; > if (__pred(*__first)) > _M_erase(__first); > __first = __next; > } > } > > template<typename _Tp, typename _Alloc> > template <typename _BinaryPredicate> > void > list<_Tp, _Alloc>:: > unique(_BinaryPredicate __binary_pred) > { > iterator __first = begin(); > iterator __last = end(); > if (__first == __last) > return; > iterator __next = __first; > while (++__next != __last) > { > if (__binary_pred(*__first, *__next)) > _M_erase(__next); > else > __first = __next; > __next = __first; > } > } > > template<typename _Tp, typename _Alloc> > template <typename _StrictWeakOrdering> > void > list<_Tp, _Alloc>:: > sort(_StrictWeakOrdering __comp) > { > > if (this->_M_impl._M_node._M_next != &this->_M_impl._M_node > && this->_M_impl._M_node._M_next->_M_next != &this->_M_impl._M_node) > { > list __carry; > list __tmp[64]; > list * __fill = &__tmp[0]; > list * __counter; > > do > { > __carry.splice(__carry.begin(), *this, begin()); > > for(__counter = &__tmp[0]; > __counter != __fill && !__counter->empty(); > ++__counter) > { > __counter->merge(__carry, __comp); > __carry.swap(*__counter); > } > __carry.swap(*__counter); > if (__counter == __fill) > ++__fill; > } > while ( !empty() ); > > for (__counter = &__tmp[1]; __counter != __fill; ++__counter) > __counter->merge(*(__counter - 1), __comp); > swap(*(__fill - 1)); > } > } > > >} ># 65 "/usr/include/c++/4.9.0/list" 2 3 ># 40 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/usr/include/c++/4.9.0/map" 1 3 ># 58 "/usr/include/c++/4.9.0/map" 3 ># 59 "/usr/include/c++/4.9.0/map" 3 > ># 1 "/usr/include/c++/4.9.0/bits/stl_tree.h" 1 3 ># 67 "/usr/include/c++/4.9.0/bits/stl_tree.h" 3 ># 1 "/usr/include/c++/4.9.0/ext/aligned_buffer.h" 1 3 ># 32 "/usr/include/c++/4.9.0/ext/aligned_buffer.h" 3 ># 33 "/usr/include/c++/4.9.0/ext/aligned_buffer.h" 3 > > > > > > > >namespace __gnu_cxx >{ > template<typename _Tp> > struct __aligned_buffer > : std::aligned_storage<sizeof(_Tp), std::alignment_of<_Tp>::value> > { > typename > std::aligned_storage<sizeof(_Tp), std::alignment_of<_Tp>::value>::type > _M_storage; > > void* > _M_addr() noexcept > { > return static_cast<void*>(&_M_storage); > } > > const void* > _M_addr() const noexcept > { > return static_cast<const void*>(&_M_storage); > } > > _Tp* > _M_ptr() noexcept > { return static_cast<_Tp*>(_M_addr()); } > > const _Tp* > _M_ptr() const noexcept > { return static_cast<const _Tp*>(_M_addr()); } > }; > >} ># 68 "/usr/include/c++/4.9.0/bits/stl_tree.h" 2 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 90 "/usr/include/c++/4.9.0/bits/stl_tree.h" 3 > enum _Rb_tree_color { _S_red = false, _S_black = true }; > > struct _Rb_tree_node_base > { > typedef _Rb_tree_node_base* _Base_ptr; > typedef const _Rb_tree_node_base* _Const_Base_ptr; > > _Rb_tree_color _M_color; > _Base_ptr _M_parent; > _Base_ptr _M_left; > _Base_ptr _M_right; > > static _Base_ptr > _S_minimum(_Base_ptr __x) noexcept > { > while (__x->_M_left != 0) __x = __x->_M_left; > return __x; > } > > static _Const_Base_ptr > _S_minimum(_Const_Base_ptr __x) noexcept > { > while (__x->_M_left != 0) __x = __x->_M_left; > return __x; > } > > static _Base_ptr > _S_maximum(_Base_ptr __x) noexcept > { > while (__x->_M_right != 0) __x = __x->_M_right; > return __x; > } > > static _Const_Base_ptr > _S_maximum(_Const_Base_ptr __x) noexcept > { > while (__x->_M_right != 0) __x = __x->_M_right; > return __x; > } > }; > > template<typename _Val> > struct _Rb_tree_node : public _Rb_tree_node_base > { > typedef _Rb_tree_node<_Val>* _Link_type; ># 147 "/usr/include/c++/4.9.0/bits/stl_tree.h" 3 > __gnu_cxx::__aligned_buffer<_Val> _M_storage; > > _Val* > _M_valptr() > { return _M_storage._M_ptr(); } > > const _Val* > _M_valptr() const > { return _M_storage._M_ptr(); } > > }; > > __attribute__ ((__pure__)) _Rb_tree_node_base* > _Rb_tree_increment(_Rb_tree_node_base* __x) throw (); > > __attribute__ ((__pure__)) const _Rb_tree_node_base* > _Rb_tree_increment(const _Rb_tree_node_base* __x) throw (); > > __attribute__ ((__pure__)) _Rb_tree_node_base* > _Rb_tree_decrement(_Rb_tree_node_base* __x) throw (); > > __attribute__ ((__pure__)) const _Rb_tree_node_base* > _Rb_tree_decrement(const _Rb_tree_node_base* __x) throw (); > > template<typename _Tp> > struct _Rb_tree_iterator > { > typedef _Tp value_type; > typedef _Tp& reference; > typedef _Tp* pointer; > > typedef bidirectional_iterator_tag iterator_category; > typedef ptrdiff_t difference_type; > > typedef _Rb_tree_iterator<_Tp> _Self; > typedef _Rb_tree_node_base::_Base_ptr _Base_ptr; > typedef _Rb_tree_node<_Tp>* _Link_type; > > _Rb_tree_iterator() noexcept > : _M_node() { } > > explicit > _Rb_tree_iterator(_Link_type __x) noexcept > : _M_node(__x) { } > > reference > operator*() const noexcept > { return *static_cast<_Link_type>(_M_node)->_M_valptr(); } > > pointer > operator->() const noexcept > { return static_cast<_Link_type> (_M_node)->_M_valptr(); } > > _Self& > operator++() noexcept > { > _M_node = _Rb_tree_increment(_M_node); > return *this; > } > > _Self > operator++(int) noexcept > { > _Self __tmp = *this; > _M_node = _Rb_tree_increment(_M_node); > return __tmp; > } > > _Self& > operator--() noexcept > { > _M_node = _Rb_tree_decrement(_M_node); > return *this; > } > > _Self > operator--(int) noexcept > { > _Self __tmp = *this; > _M_node = _Rb_tree_decrement(_M_node); > return __tmp; > } > > bool > operator==(const _Self& __x) const noexcept > { return _M_node == __x._M_node; } > > bool > operator!=(const _Self& __x) const noexcept > { return _M_node != __x._M_node; } > > _Base_ptr _M_node; > }; > > template<typename _Tp> > struct _Rb_tree_const_iterator > { > typedef _Tp value_type; > typedef const _Tp& reference; > typedef const _Tp* pointer; > > typedef _Rb_tree_iterator<_Tp> iterator; > > typedef bidirectional_iterator_tag iterator_category; > typedef ptrdiff_t difference_type; > > typedef _Rb_tree_const_iterator<_Tp> _Self; > typedef _Rb_tree_node_base::_Const_Base_ptr _Base_ptr; > typedef const _Rb_tree_node<_Tp>* _Link_type; > > _Rb_tree_const_iterator() noexcept > : _M_node() { } > > explicit > _Rb_tree_const_iterator(_Link_type __x) noexcept > : _M_node(__x) { } > > _Rb_tree_const_iterator(const iterator& __it) noexcept > : _M_node(__it._M_node) { } > > iterator > _M_const_cast() const noexcept > { return iterator(static_cast<typename iterator::_Link_type> > (const_cast<typename iterator::_Base_ptr>(_M_node))); } > > reference > operator*() const noexcept > { return *static_cast<_Link_type>(_M_node)->_M_valptr(); } > > pointer > operator->() const noexcept > { return static_cast<_Link_type>(_M_node)->_M_valptr(); } > > _Self& > operator++() noexcept > { > _M_node = _Rb_tree_increment(_M_node); > return *this; > } > > _Self > operator++(int) noexcept > { > _Self __tmp = *this; > _M_node = _Rb_tree_increment(_M_node); > return __tmp; > } > > _Self& > operator--() noexcept > { > _M_node = _Rb_tree_decrement(_M_node); > return *this; > } > > _Self > operator--(int) noexcept > { > _Self __tmp = *this; > _M_node = _Rb_tree_decrement(_M_node); > return __tmp; > } > > bool > operator==(const _Self& __x) const noexcept > { return _M_node == __x._M_node; } > > bool > operator!=(const _Self& __x) const noexcept > { return _M_node != __x._M_node; } > > _Base_ptr _M_node; > }; > > template<typename _Val> > inline bool > operator==(const _Rb_tree_iterator<_Val>& __x, > const _Rb_tree_const_iterator<_Val>& __y) noexcept > { return __x._M_node == __y._M_node; } > > template<typename _Val> > inline bool > operator!=(const _Rb_tree_iterator<_Val>& __x, > const _Rb_tree_const_iterator<_Val>& __y) noexcept > { return __x._M_node != __y._M_node; } > > void > _Rb_tree_insert_and_rebalance(const bool __insert_left, > _Rb_tree_node_base* __x, > _Rb_tree_node_base* __p, > _Rb_tree_node_base& __header) throw (); > > _Rb_tree_node_base* > _Rb_tree_rebalance_for_erase(_Rb_tree_node_base* const __z, > _Rb_tree_node_base& __header) throw (); > > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc = allocator<_Val> > > class _Rb_tree > { > typedef typename __gnu_cxx::__alloc_traits<_Alloc>::template > rebind<_Rb_tree_node<_Val> >::other _Node_allocator; > > typedef __gnu_cxx::__alloc_traits<_Node_allocator> _Alloc_traits; > > protected: > typedef _Rb_tree_node_base* _Base_ptr; > typedef const _Rb_tree_node_base* _Const_Base_ptr; > > public: > typedef _Key key_type; > typedef _Val value_type; > typedef value_type* pointer; > typedef const value_type* const_pointer; > typedef value_type& reference; > typedef const value_type& const_reference; > typedef _Rb_tree_node<_Val>* _Link_type; > typedef const _Rb_tree_node<_Val>* _Const_Link_type; > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef _Alloc allocator_type; > > _Node_allocator& > _M_get_Node_allocator() noexcept > { return *static_cast<_Node_allocator*>(&this->_M_impl); } > > const _Node_allocator& > _M_get_Node_allocator() const noexcept > { return *static_cast<const _Node_allocator*>(&this->_M_impl); } > > allocator_type > get_allocator() const noexcept > { return allocator_type(_M_get_Node_allocator()); } > > protected: > _Link_type > _M_get_node() > { return _Alloc_traits::allocate(_M_get_Node_allocator(), 1); } > > void > _M_put_node(_Link_type __p) noexcept > { _Alloc_traits::deallocate(_M_get_Node_allocator(), __p, 1); } ># 413 "/usr/include/c++/4.9.0/bits/stl_tree.h" 3 > template<typename... _Args> > _Link_type > _M_create_node(_Args&&... __args) > { > _Link_type __tmp = _M_get_node(); > try > { > ::new(__tmp) _Rb_tree_node<_Val>; > _Alloc_traits::construct(_M_get_Node_allocator(), > __tmp->_M_valptr(), > std::forward<_Args>(__args)...); > } > catch(...) > { > _M_put_node(__tmp); > throw; > } > return __tmp; > } > > void > _M_destroy_node(_Link_type __p) noexcept > { > _Alloc_traits::destroy(_M_get_Node_allocator(), __p->_M_valptr()); > __p->~_Rb_tree_node<_Val>(); > _M_put_node(__p); > } > > > _Link_type > _M_clone_node(_Const_Link_type __x) > { > _Link_type __tmp = _M_create_node(*__x->_M_valptr()); > __tmp->_M_color = __x->_M_color; > __tmp->_M_left = 0; > __tmp->_M_right = 0; > return __tmp; > } > > protected: > template<typename _Key_compare, > bool _Is_pod_comparator = __is_pod(_Key_compare)> > struct _Rb_tree_impl : public _Node_allocator > { > _Key_compare _M_key_compare; > _Rb_tree_node_base _M_header; > size_type _M_node_count; > > _Rb_tree_impl() > : _Node_allocator(), _M_key_compare(), _M_header(), > _M_node_count(0) > { _M_initialize(); } > > _Rb_tree_impl(const _Key_compare& __comp, const _Node_allocator& __a) > : _Node_allocator(__a), _M_key_compare(__comp), _M_header(), > _M_node_count(0) > { _M_initialize(); } > > > _Rb_tree_impl(const _Key_compare& __comp, _Node_allocator&& __a) > : _Node_allocator(std::move(__a)), _M_key_compare(__comp), > _M_header(), _M_node_count(0) > { _M_initialize(); } > > > private: > void > _M_initialize() > { > this->_M_header._M_color = _S_red; > this->_M_header._M_parent = 0; > this->_M_header._M_left = &this->_M_header; > this->_M_header._M_right = &this->_M_header; > } > }; > > _Rb_tree_impl<_Compare> _M_impl; > > protected: > _Base_ptr& > _M_root() noexcept > { return this->_M_impl._M_header._M_parent; } > > _Const_Base_ptr > _M_root() const noexcept > { return this->_M_impl._M_header._M_parent; } > > _Base_ptr& > _M_leftmost() noexcept > { return this->_M_impl._M_header._M_left; } > > _Const_Base_ptr > _M_leftmost() const noexcept > { return this->_M_impl._M_header._M_left; } > > _Base_ptr& > _M_rightmost() noexcept > { return this->_M_impl._M_header._M_right; } > > _Const_Base_ptr > _M_rightmost() const noexcept > { return this->_M_impl._M_header._M_right; } > > _Link_type > _M_begin() noexcept > { return static_cast<_Link_type>(this->_M_impl._M_header._M_parent); } > > _Const_Link_type > _M_begin() const noexcept > { > return static_cast<_Const_Link_type> > (this->_M_impl._M_header._M_parent); > } > > _Link_type > _M_end() noexcept > { return static_cast<_Link_type>(&this->_M_impl._M_header); } > > _Const_Link_type > _M_end() const noexcept > { return static_cast<_Const_Link_type>(&this->_M_impl._M_header); } > > static const_reference > _S_value(_Const_Link_type __x) > { return *__x->_M_valptr(); } > > static const _Key& > _S_key(_Const_Link_type __x) > { return _KeyOfValue()(_S_value(__x)); } > > static _Link_type > _S_left(_Base_ptr __x) noexcept > { return static_cast<_Link_type>(__x->_M_left); } > > static _Const_Link_type > _S_left(_Const_Base_ptr __x) noexcept > { return static_cast<_Const_Link_type>(__x->_M_left); } > > static _Link_type > _S_right(_Base_ptr __x) noexcept > { return static_cast<_Link_type>(__x->_M_right); } > > static _Const_Link_type > _S_right(_Const_Base_ptr __x) noexcept > { return static_cast<_Const_Link_type>(__x->_M_right); } > > static const_reference > _S_value(_Const_Base_ptr __x) > { return *static_cast<_Const_Link_type>(__x)->_M_valptr(); } > > static const _Key& > _S_key(_Const_Base_ptr __x) > { return _KeyOfValue()(_S_value(__x)); } > > static _Base_ptr > _S_minimum(_Base_ptr __x) noexcept > { return _Rb_tree_node_base::_S_minimum(__x); } > > static _Const_Base_ptr > _S_minimum(_Const_Base_ptr __x) noexcept > { return _Rb_tree_node_base::_S_minimum(__x); } > > static _Base_ptr > _S_maximum(_Base_ptr __x) noexcept > { return _Rb_tree_node_base::_S_maximum(__x); } > > static _Const_Base_ptr > _S_maximum(_Const_Base_ptr __x) noexcept > { return _Rb_tree_node_base::_S_maximum(__x); } > > public: > typedef _Rb_tree_iterator<value_type> iterator; > typedef _Rb_tree_const_iterator<value_type> const_iterator; > > typedef std::reverse_iterator<iterator> reverse_iterator; > typedef std::reverse_iterator<const_iterator> const_reverse_iterator; > > private: > pair<_Base_ptr, _Base_ptr> > _M_get_insert_unique_pos(const key_type& __k); > > pair<_Base_ptr, _Base_ptr> > _M_get_insert_equal_pos(const key_type& __k); > > pair<_Base_ptr, _Base_ptr> > _M_get_insert_hint_unique_pos(const_iterator __pos, > const key_type& __k); > > pair<_Base_ptr, _Base_ptr> > _M_get_insert_hint_equal_pos(const_iterator __pos, > const key_type& __k); > > > template<typename _Arg> > iterator > _M_insert_(_Base_ptr __x, _Base_ptr __y, _Arg&& __v); > > iterator > _M_insert_node(_Base_ptr __x, _Base_ptr __y, _Link_type __z); > > template<typename _Arg> > iterator > _M_insert_lower(_Base_ptr __y, _Arg&& __v); > > template<typename _Arg> > iterator > _M_insert_equal_lower(_Arg&& __x); > > iterator > _M_insert_lower_node(_Base_ptr __p, _Link_type __z); > > iterator > _M_insert_equal_lower_node(_Link_type __z); ># 640 "/usr/include/c++/4.9.0/bits/stl_tree.h" 3 > _Link_type > _M_copy(_Const_Link_type __x, _Link_type __p); > > void > _M_erase(_Link_type __x); > > iterator > _M_lower_bound(_Link_type __x, _Link_type __y, > const _Key& __k); > > const_iterator > _M_lower_bound(_Const_Link_type __x, _Const_Link_type __y, > const _Key& __k) const; > > iterator > _M_upper_bound(_Link_type __x, _Link_type __y, > const _Key& __k); > > const_iterator > _M_upper_bound(_Const_Link_type __x, _Const_Link_type __y, > const _Key& __k) const; > > public: > > _Rb_tree() { } > > _Rb_tree(const _Compare& __comp, > const allocator_type& __a = allocator_type()) > : _M_impl(__comp, _Node_allocator(__a)) { } > > _Rb_tree(const _Rb_tree& __x) > : _M_impl(__x._M_impl._M_key_compare, > _Alloc_traits::_S_select_on_copy(__x._M_get_Node_allocator())) > { > if (__x._M_root() != 0) > { > _M_root() = _M_copy(__x._M_begin(), _M_end()); > _M_leftmost() = _S_minimum(_M_root()); > _M_rightmost() = _S_maximum(_M_root()); > _M_impl._M_node_count = __x._M_impl._M_node_count; > } > } > > > _Rb_tree(const allocator_type& __a) > : _M_impl(_Compare(), _Node_allocator(__a)) > { } > > _Rb_tree(const _Rb_tree& __x, const allocator_type& __a) > : _M_impl(__x._M_impl._M_key_compare, _Node_allocator(__a)) > { > if (__x._M_root() != 0) > { > _M_root() = _M_copy(__x._M_begin(), _M_end()); > _M_leftmost() = _S_minimum(_M_root()); > _M_rightmost() = _S_maximum(_M_root()); > _M_impl._M_node_count = __x._M_impl._M_node_count; > } > } > > _Rb_tree(_Rb_tree&& __x) > : _M_impl(__x._M_impl._M_key_compare, __x._M_get_Node_allocator()) > { > if (__x._M_root() != 0) > _M_move_data(__x, std::true_type()); > } > > _Rb_tree(_Rb_tree&& __x, const allocator_type& __a) > : _Rb_tree(std::move(__x), _Node_allocator(__a)) > { } > > _Rb_tree(_Rb_tree&& __x, _Node_allocator&& __a); > > > ~_Rb_tree() noexcept > { _M_erase(_M_begin()); } > > _Rb_tree& > operator=(const _Rb_tree& __x); > > > _Compare > key_comp() const > { return _M_impl._M_key_compare; } > > iterator > begin() noexcept > { > return iterator(static_cast<_Link_type> > (this->_M_impl._M_header._M_left)); > } > > const_iterator > begin() const noexcept > { > return const_iterator(static_cast<_Const_Link_type> > (this->_M_impl._M_header._M_left)); > } > > iterator > end() noexcept > { return iterator(static_cast<_Link_type>(&this->_M_impl._M_header)); } > > const_iterator > end() const noexcept > { > return const_iterator(static_cast<_Const_Link_type> > (&this->_M_impl._M_header)); > } > > reverse_iterator > rbegin() noexcept > { return reverse_iterator(end()); } > > const_reverse_iterator > rbegin() const noexcept > { return const_reverse_iterator(end()); } > > reverse_iterator > rend() noexcept > { return reverse_iterator(begin()); } > > const_reverse_iterator > rend() const noexcept > { return const_reverse_iterator(begin()); } > > bool > empty() const noexcept > { return _M_impl._M_node_count == 0; } > > size_type > size() const noexcept > { return _M_impl._M_node_count; } > > size_type > max_size() const noexcept > { return _Alloc_traits::max_size(_M_get_Node_allocator()); } > > void > > swap(_Rb_tree& __t) noexcept(_Alloc_traits::_S_nothrow_swap()); > > > > > > > template<typename _Arg> > pair<iterator, bool> > _M_insert_unique(_Arg&& __x); > > template<typename _Arg> > iterator > _M_insert_equal(_Arg&& __x); > > template<typename _Arg> > iterator > _M_insert_unique_(const_iterator __position, _Arg&& __x); > > template<typename _Arg> > iterator > _M_insert_equal_(const_iterator __position, _Arg&& __x); > > template<typename... _Args> > pair<iterator, bool> > _M_emplace_unique(_Args&&... __args); > > template<typename... _Args> > iterator > _M_emplace_equal(_Args&&... __args); > > template<typename... _Args> > iterator > _M_emplace_hint_unique(const_iterator __pos, _Args&&... __args); > > template<typename... _Args> > iterator > _M_emplace_hint_equal(const_iterator __pos, _Args&&... __args); ># 832 "/usr/include/c++/4.9.0/bits/stl_tree.h" 3 > template<typename _InputIterator> > void > _M_insert_unique(_InputIterator __first, _InputIterator __last); > > template<typename _InputIterator> > void > _M_insert_equal(_InputIterator __first, _InputIterator __last); > > private: > void > _M_erase_aux(const_iterator __position); > > void > _M_erase_aux(const_iterator __first, const_iterator __last); > > public: > > > > __attribute ((__abi_tag__ ("cxx11"))) > iterator > erase(const_iterator __position) > { > const_iterator __result = __position; > ++__result; > _M_erase_aux(__position); > return __result._M_const_cast(); > } > > > __attribute ((__abi_tag__ ("cxx11"))) > iterator > erase(iterator __position) > { > iterator __result = __position; > ++__result; > _M_erase_aux(__position); > return __result; > } ># 880 "/usr/include/c++/4.9.0/bits/stl_tree.h" 3 > size_type > erase(const key_type& __x); > > > > > __attribute ((__abi_tag__ ("cxx11"))) > iterator > erase(const_iterator __first, const_iterator __last) > { > _M_erase_aux(__first, __last); > return __last._M_const_cast(); > } ># 902 "/usr/include/c++/4.9.0/bits/stl_tree.h" 3 > void > erase(const key_type* __first, const key_type* __last); > > void > clear() noexcept > { > _M_erase(_M_begin()); > _M_leftmost() = _M_end(); > _M_root() = 0; > _M_rightmost() = _M_end(); > _M_impl._M_node_count = 0; > } > > > iterator > find(const key_type& __k); > > const_iterator > find(const key_type& __k) const; > > size_type > count(const key_type& __k) const; > > iterator > lower_bound(const key_type& __k) > { return _M_lower_bound(_M_begin(), _M_end(), __k); } > > const_iterator > lower_bound(const key_type& __k) const > { return _M_lower_bound(_M_begin(), _M_end(), __k); } > > iterator > upper_bound(const key_type& __k) > { return _M_upper_bound(_M_begin(), _M_end(), __k); } > > const_iterator > upper_bound(const key_type& __k) const > { return _M_upper_bound(_M_begin(), _M_end(), __k); } > > pair<iterator, iterator> > equal_range(const key_type& __k); > > pair<const_iterator, const_iterator> > equal_range(const key_type& __k) const; > > > bool > __rb_verify() const; > > > bool > _M_move_assign(_Rb_tree&); > > private: > > void > _M_move_data(_Rb_tree&, std::true_type); > > > > void > _M_move_data(_Rb_tree&, std::false_type); > > }; > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > inline bool > operator==(const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __x, > const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __y) > { > return __x.size() == __y.size() > && std::equal(__x.begin(), __x.end(), __y.begin()); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > inline bool > operator<(const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __x, > const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __y) > { > return std::lexicographical_compare(__x.begin(), __x.end(), > __y.begin(), __y.end()); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > inline bool > operator!=(const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __x, > const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __y) > { return !(__x == __y); } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > inline bool > operator>(const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __x, > const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __y) > { return __y < __x; } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > inline bool > operator<=(const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __x, > const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __y) > { return !(__y < __x); } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > inline bool > operator>=(const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __x, > const _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __y) > { return !(__x < __y); } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > inline void > swap(_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __x, > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __y) > { __x.swap(__y); } > > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _Rb_tree(_Rb_tree&& __x, _Node_allocator&& __a) > : _M_impl(__x._M_impl._M_key_compare, std::move(__a)) > { > using __eq = integral_constant<bool, _Alloc_traits::_S_always_equal()>; > if (__x._M_root() != 0) > _M_move_data(__x, __eq()); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > void > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_move_data(_Rb_tree& __x, std::true_type) > { > _M_root() = __x._M_root(); > _M_leftmost() = __x._M_leftmost(); > _M_rightmost() = __x._M_rightmost(); > _M_root()->_M_parent = _M_end(); > > __x._M_root() = 0; > __x._M_leftmost() = __x._M_end(); > __x._M_rightmost() = __x._M_end(); > > this->_M_impl._M_node_count = __x._M_impl._M_node_count; > __x._M_impl._M_node_count = 0; > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > void > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_move_data(_Rb_tree& __x, std::false_type) > { > if (_M_get_Node_allocator() == __x._M_get_Node_allocator()) > _M_move_data(__x, std::true_type()); > else > { > _M_root() = _M_copy(__x._M_begin(), _M_end()); > _M_leftmost() = _S_minimum(_M_root()); > _M_rightmost() = _S_maximum(_M_root()); > _M_impl._M_node_count = __x._M_impl._M_node_count; > } > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > bool > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_move_assign(_Rb_tree& __x) > { > if (_Alloc_traits::_S_propagate_on_move_assign() > || _Alloc_traits::_S_always_equal() > || _M_get_Node_allocator() == __x._M_get_Node_allocator()) > { > clear(); > if (__x._M_root() != 0) > _M_move_data(__x, std::true_type()); > std::__alloc_on_move(_M_get_Node_allocator(), > __x._M_get_Node_allocator()); > return true; > } > return false; > } > > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > operator=(const _Rb_tree& __x) > { > if (this != &__x) > { > > clear(); > > if (_Alloc_traits::_S_propagate_on_copy_assign()) > { > auto& __this_alloc = this->_M_get_Node_allocator(); > auto& __that_alloc = __x._M_get_Node_allocator(); > if (!_Alloc_traits::_S_always_equal() > && __this_alloc != __that_alloc) > { > std::__alloc_on_copy(__this_alloc, __that_alloc); > } > } > > _M_impl._M_key_compare = __x._M_impl._M_key_compare; > if (__x._M_root() != 0) > { > _M_root() = _M_copy(__x._M_begin(), _M_end()); > _M_leftmost() = _S_minimum(_M_root()); > _M_rightmost() = _S_maximum(_M_root()); > _M_impl._M_node_count = __x._M_impl._M_node_count; > } > } > return *this; > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > > template<typename _Arg> > > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > > _M_insert_(_Base_ptr __x, _Base_ptr __p, _Arg&& __v) > > > > { > bool __insert_left = (__x != 0 || __p == _M_end() > || _M_impl._M_key_compare(_KeyOfValue()(__v), > _S_key(__p))); > > _Link_type __z = _M_create_node(std::forward<_Arg>(__v)); > > _Rb_tree_insert_and_rebalance(__insert_left, __z, __p, > this->_M_impl._M_header); > ++_M_impl._M_node_count; > return iterator(__z); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > > template<typename _Arg> > > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > > _M_insert_lower(_Base_ptr __p, _Arg&& __v) > > > > { > bool __insert_left = (__p == _M_end() > || !_M_impl._M_key_compare(_S_key(__p), > _KeyOfValue()(__v))); > > _Link_type __z = _M_create_node(std::forward<_Arg>(__v)); > > _Rb_tree_insert_and_rebalance(__insert_left, __z, __p, > this->_M_impl._M_header); > ++_M_impl._M_node_count; > return iterator(__z); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > > template<typename _Arg> > > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > > _M_insert_equal_lower(_Arg&& __v) > > > > { > _Link_type __x = _M_begin(); > _Link_type __y = _M_end(); > while (__x != 0) > { > __y = __x; > __x = !_M_impl._M_key_compare(_S_key(__x), _KeyOfValue()(__v)) ? > _S_left(__x) : _S_right(__x); > } > return _M_insert_lower(__y, std::forward<_Arg>(__v)); > } > > template<typename _Key, typename _Val, typename _KoV, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KoV, _Compare, _Alloc>::_Link_type > _Rb_tree<_Key, _Val, _KoV, _Compare, _Alloc>:: > _M_copy(_Const_Link_type __x, _Link_type __p) > { > > _Link_type __top = _M_clone_node(__x); > __top->_M_parent = __p; > > try > { > if (__x->_M_right) > __top->_M_right = _M_copy(_S_right(__x), __top); > __p = __top; > __x = _S_left(__x); > > while (__x != 0) > { > _Link_type __y = _M_clone_node(__x); > __p->_M_left = __y; > __y->_M_parent = __p; > if (__x->_M_right) > __y->_M_right = _M_copy(_S_right(__x), __y); > __p = __y; > __x = _S_left(__x); > } > } > catch(...) > { > _M_erase(__top); > throw; > } > return __top; > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > void > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_erase(_Link_type __x) > { > > while (__x != 0) > { > _M_erase(_S_right(__x)); > _Link_type __y = _S_left(__x); > _M_destroy_node(__x); > __x = __y; > } > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_lower_bound(_Link_type __x, _Link_type __y, > const _Key& __k) > { > while (__x != 0) > if (!_M_impl._M_key_compare(_S_key(__x), __k)) > __y = __x, __x = _S_left(__x); > else > __x = _S_right(__x); > return iterator(__y); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::const_iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_lower_bound(_Const_Link_type __x, _Const_Link_type __y, > const _Key& __k) const > { > while (__x != 0) > if (!_M_impl._M_key_compare(_S_key(__x), __k)) > __y = __x, __x = _S_left(__x); > else > __x = _S_right(__x); > return const_iterator(__y); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_upper_bound(_Link_type __x, _Link_type __y, > const _Key& __k) > { > while (__x != 0) > if (_M_impl._M_key_compare(__k, _S_key(__x))) > __y = __x, __x = _S_left(__x); > else > __x = _S_right(__x); > return iterator(__y); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::const_iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_upper_bound(_Const_Link_type __x, _Const_Link_type __y, > const _Key& __k) const > { > while (__x != 0) > if (_M_impl._M_key_compare(__k, _S_key(__x))) > __y = __x, __x = _S_left(__x); > else > __x = _S_right(__x); > return const_iterator(__y); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > pair<typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::iterator, > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::iterator> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > equal_range(const _Key& __k) > { > _Link_type __x = _M_begin(); > _Link_type __y = _M_end(); > while (__x != 0) > { > if (_M_impl._M_key_compare(_S_key(__x), __k)) > __x = _S_right(__x); > else if (_M_impl._M_key_compare(__k, _S_key(__x))) > __y = __x, __x = _S_left(__x); > else > { > _Link_type __xu(__x), __yu(__y); > __y = __x, __x = _S_left(__x); > __xu = _S_right(__xu); > return pair<iterator, > iterator>(_M_lower_bound(__x, __y, __k), > _M_upper_bound(__xu, __yu, __k)); > } > } > return pair<iterator, iterator>(iterator(__y), > iterator(__y)); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > pair<typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::const_iterator, > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::const_iterator> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > equal_range(const _Key& __k) const > { > _Const_Link_type __x = _M_begin(); > _Const_Link_type __y = _M_end(); > while (__x != 0) > { > if (_M_impl._M_key_compare(_S_key(__x), __k)) > __x = _S_right(__x); > else if (_M_impl._M_key_compare(__k, _S_key(__x))) > __y = __x, __x = _S_left(__x); > else > { > _Const_Link_type __xu(__x), __yu(__y); > __y = __x, __x = _S_left(__x); > __xu = _S_right(__xu); > return pair<const_iterator, > const_iterator>(_M_lower_bound(__x, __y, __k), > _M_upper_bound(__xu, __yu, __k)); > } > } > return pair<const_iterator, const_iterator>(const_iterator(__y), > const_iterator(__y)); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > void > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > swap(_Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>& __t) > > noexcept(_Alloc_traits::_S_nothrow_swap()) > > { > if (_M_root() == 0) > { > if (__t._M_root() != 0) > { > _M_root() = __t._M_root(); > _M_leftmost() = __t._M_leftmost(); > _M_rightmost() = __t._M_rightmost(); > _M_root()->_M_parent = _M_end(); > > __t._M_root() = 0; > __t._M_leftmost() = __t._M_end(); > __t._M_rightmost() = __t._M_end(); > } > } > else if (__t._M_root() == 0) > { > __t._M_root() = _M_root(); > __t._M_leftmost() = _M_leftmost(); > __t._M_rightmost() = _M_rightmost(); > __t._M_root()->_M_parent = __t._M_end(); > > _M_root() = 0; > _M_leftmost() = _M_end(); > _M_rightmost() = _M_end(); > } > else > { > std::swap(_M_root(),__t._M_root()); > std::swap(_M_leftmost(),__t._M_leftmost()); > std::swap(_M_rightmost(),__t._M_rightmost()); > > _M_root()->_M_parent = _M_end(); > __t._M_root()->_M_parent = __t._M_end(); > } > > std::swap(this->_M_impl._M_node_count, __t._M_impl._M_node_count); > std::swap(this->_M_impl._M_key_compare, __t._M_impl._M_key_compare); > > _Alloc_traits::_S_on_swap(_M_get_Node_allocator(), > __t._M_get_Node_allocator()); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > pair<typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::_Base_ptr, > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::_Base_ptr> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_get_insert_unique_pos(const key_type& __k) > { > typedef pair<_Base_ptr, _Base_ptr> _Res; > _Link_type __x = _M_begin(); > _Link_type __y = _M_end(); > bool __comp = true; > while (__x != 0) > { > __y = __x; > __comp = _M_impl._M_key_compare(__k, _S_key(__x)); > __x = __comp ? _S_left(__x) : _S_right(__x); > } > iterator __j = iterator(__y); > if (__comp) > { > if (__j == begin()) > return _Res(__x, __y); > else > --__j; > } > if (_M_impl._M_key_compare(_S_key(__j._M_node), __k)) > return _Res(__x, __y); > return _Res(__j._M_node, 0); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > pair<typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::_Base_ptr, > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::_Base_ptr> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_get_insert_equal_pos(const key_type& __k) > { > typedef pair<_Base_ptr, _Base_ptr> _Res; > _Link_type __x = _M_begin(); > _Link_type __y = _M_end(); > while (__x != 0) > { > __y = __x; > __x = _M_impl._M_key_compare(__k, _S_key(__x)) ? > _S_left(__x) : _S_right(__x); > } > return _Res(__x, __y); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > > template<typename _Arg> > > pair<typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::iterator, bool> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > > _M_insert_unique(_Arg&& __v) > > > > { > typedef pair<iterator, bool> _Res; > pair<_Base_ptr, _Base_ptr> __res > = _M_get_insert_unique_pos(_KeyOfValue()(__v)); > > if (__res.second) > return _Res(_M_insert_(__res.first, __res.second, > std::forward<_Arg>(__v)), > true); > > return _Res(iterator(static_cast<_Link_type>(__res.first)), false); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > > template<typename _Arg> > > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > > _M_insert_equal(_Arg&& __v) > > > > { > pair<_Base_ptr, _Base_ptr> __res > = _M_get_insert_equal_pos(_KeyOfValue()(__v)); > return _M_insert_(__res.first, __res.second, std::forward<_Arg>(__v)); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > pair<typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::_Base_ptr, > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::_Base_ptr> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_get_insert_hint_unique_pos(const_iterator __position, > const key_type& __k) > { > iterator __pos = __position._M_const_cast(); > typedef pair<_Base_ptr, _Base_ptr> _Res; > > > if (__pos._M_node == _M_end()) > { > if (size() > 0 > && _M_impl._M_key_compare(_S_key(_M_rightmost()), __k)) > return _Res(0, _M_rightmost()); > else > return _M_get_insert_unique_pos(__k); > } > else if (_M_impl._M_key_compare(__k, _S_key(__pos._M_node))) > { > > iterator __before = __pos; > if (__pos._M_node == _M_leftmost()) > return _Res(_M_leftmost(), _M_leftmost()); > else if (_M_impl._M_key_compare(_S_key((--__before)._M_node), __k)) > { > if (_S_right(__before._M_node) == 0) > return _Res(0, __before._M_node); > else > return _Res(__pos._M_node, __pos._M_node); > } > else > return _M_get_insert_unique_pos(__k); > } > else if (_M_impl._M_key_compare(_S_key(__pos._M_node), __k)) > { > > iterator __after = __pos; > if (__pos._M_node == _M_rightmost()) > return _Res(0, _M_rightmost()); > else if (_M_impl._M_key_compare(__k, _S_key((++__after)._M_node))) > { > if (_S_right(__pos._M_node) == 0) > return _Res(0, __pos._M_node); > else > return _Res(__after._M_node, __after._M_node); > } > else > return _M_get_insert_unique_pos(__k); > } > else > > return _Res(__pos._M_node, 0); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > > template<typename _Arg> > > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > > _M_insert_unique_(const_iterator __position, _Arg&& __v) > > > > { > pair<_Base_ptr, _Base_ptr> __res > = _M_get_insert_hint_unique_pos(__position, _KeyOfValue()(__v)); > > if (__res.second) > return _M_insert_(__res.first, __res.second, > std::forward<_Arg>(__v)); > return iterator(static_cast<_Link_type>(__res.first)); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > pair<typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::_Base_ptr, > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::_Base_ptr> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_get_insert_hint_equal_pos(const_iterator __position, const key_type& __k) > { > iterator __pos = __position._M_const_cast(); > typedef pair<_Base_ptr, _Base_ptr> _Res; > > > if (__pos._M_node == _M_end()) > { > if (size() > 0 > && !_M_impl._M_key_compare(__k, _S_key(_M_rightmost()))) > return _Res(0, _M_rightmost()); > else > return _M_get_insert_equal_pos(__k); > } > else if (!_M_impl._M_key_compare(_S_key(__pos._M_node), __k)) > { > > iterator __before = __pos; > if (__pos._M_node == _M_leftmost()) > return _Res(_M_leftmost(), _M_leftmost()); > else if (!_M_impl._M_key_compare(__k, _S_key((--__before)._M_node))) > { > if (_S_right(__before._M_node) == 0) > return _Res(0, __before._M_node); > else > return _Res(__pos._M_node, __pos._M_node); > } > else > return _M_get_insert_equal_pos(__k); > } > else > { > > iterator __after = __pos; > if (__pos._M_node == _M_rightmost()) > return _Res(0, _M_rightmost()); > else if (!_M_impl._M_key_compare(_S_key((++__after)._M_node), __k)) > { > if (_S_right(__pos._M_node) == 0) > return _Res(0, __pos._M_node); > else > return _Res(__after._M_node, __after._M_node); > } > else > return _Res(0, 0); > } > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > > template<typename _Arg> > > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > > _M_insert_equal_(const_iterator __position, _Arg&& __v) > > > > { > pair<_Base_ptr, _Base_ptr> __res > = _M_get_insert_hint_equal_pos(__position, _KeyOfValue()(__v)); > > if (__res.second) > return _M_insert_(__res.first, __res.second, > std::forward<_Arg>(__v)); > > return _M_insert_equal_lower(std::forward<_Arg>(__v)); > } > > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_insert_node(_Base_ptr __x, _Base_ptr __p, _Link_type __z) > { > bool __insert_left = (__x != 0 || __p == _M_end() > || _M_impl._M_key_compare(_S_key(__z), > _S_key(__p))); > > _Rb_tree_insert_and_rebalance(__insert_left, __z, __p, > this->_M_impl._M_header); > ++_M_impl._M_node_count; > return iterator(__z); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_insert_lower_node(_Base_ptr __p, _Link_type __z) > { > bool __insert_left = (__p == _M_end() > || !_M_impl._M_key_compare(_S_key(__p), > _S_key(__z))); > > _Rb_tree_insert_and_rebalance(__insert_left, __z, __p, > this->_M_impl._M_header); > ++_M_impl._M_node_count; > return iterator(__z); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_insert_equal_lower_node(_Link_type __z) > { > _Link_type __x = _M_begin(); > _Link_type __y = _M_end(); > while (__x != 0) > { > __y = __x; > __x = !_M_impl._M_key_compare(_S_key(__x), _S_key(__z)) ? > _S_left(__x) : _S_right(__x); > } > return _M_insert_lower_node(__y, __z); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > template<typename... _Args> > pair<typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::iterator, bool> > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_emplace_unique(_Args&&... __args) > { > _Link_type __z = _M_create_node(std::forward<_Args>(__args)...); > > try > { > typedef pair<iterator, bool> _Res; > auto __res = _M_get_insert_unique_pos(_S_key(__z)); > if (__res.second) > return _Res(_M_insert_node(__res.first, __res.second, __z), true); > > _M_destroy_node(__z); > return _Res(iterator(static_cast<_Link_type>(__res.first)), false); > } > catch(...) > { > _M_destroy_node(__z); > throw; > } > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > template<typename... _Args> > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_emplace_equal(_Args&&... __args) > { > _Link_type __z = _M_create_node(std::forward<_Args>(__args)...); > > try > { > auto __res = _M_get_insert_equal_pos(_S_key(__z)); > return _M_insert_node(__res.first, __res.second, __z); > } > catch(...) > { > _M_destroy_node(__z); > throw; > } > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > template<typename... _Args> > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_emplace_hint_unique(const_iterator __pos, _Args&&... __args) > { > _Link_type __z = _M_create_node(std::forward<_Args>(__args)...); > > try > { > auto __res = _M_get_insert_hint_unique_pos(__pos, _S_key(__z)); > > if (__res.second) > return _M_insert_node(__res.first, __res.second, __z); > > _M_destroy_node(__z); > return iterator(static_cast<_Link_type>(__res.first)); > } > catch(...) > { > _M_destroy_node(__z); > throw; > } > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > template<typename... _Args> > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_emplace_hint_equal(const_iterator __pos, _Args&&... __args) > { > _Link_type __z = _M_create_node(std::forward<_Args>(__args)...); > > try > { > auto __res = _M_get_insert_hint_equal_pos(__pos, _S_key(__z)); > > if (__res.second) > return _M_insert_node(__res.first, __res.second, __z); > > return _M_insert_equal_lower_node(__z); > } > catch(...) > { > _M_destroy_node(__z); > throw; > } > } > > > template<typename _Key, typename _Val, typename _KoV, > typename _Cmp, typename _Alloc> > template<class _II> > void > _Rb_tree<_Key, _Val, _KoV, _Cmp, _Alloc>:: > _M_insert_unique(_II __first, _II __last) > { > for (; __first != __last; ++__first) > _M_insert_unique_(end(), *__first); > } > > template<typename _Key, typename _Val, typename _KoV, > typename _Cmp, typename _Alloc> > template<class _II> > void > _Rb_tree<_Key, _Val, _KoV, _Cmp, _Alloc>:: > _M_insert_equal(_II __first, _II __last) > { > for (; __first != __last; ++__first) > _M_insert_equal_(end(), *__first); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > void > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_erase_aux(const_iterator __position) > { > _Link_type __y = > static_cast<_Link_type>(_Rb_tree_rebalance_for_erase > (const_cast<_Base_ptr>(__position._M_node), > this->_M_impl._M_header)); > _M_destroy_node(__y); > --_M_impl._M_node_count; > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > void > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > _M_erase_aux(const_iterator __first, const_iterator __last) > { > if (__first == begin() && __last == end()) > clear(); > else > while (__first != __last) > erase(__first++); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::size_type > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > erase(const _Key& __x) > { > pair<iterator, iterator> __p = equal_range(__x); > const size_type __old_size = size(); > erase(__p.first, __p.second); > return __old_size - size(); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > void > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > erase(const _Key* __first, const _Key* __last) > { > while (__first != __last) > erase(*__first++); > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > find(const _Key& __k) > { > iterator __j = _M_lower_bound(_M_begin(), _M_end(), __k); > return (__j == end() > || _M_impl._M_key_compare(__k, > _S_key(__j._M_node))) ? end() : __j; > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, > _Compare, _Alloc>::const_iterator > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > find(const _Key& __k) const > { > const_iterator __j = _M_lower_bound(_M_begin(), _M_end(), __k); > return (__j == end() > || _M_impl._M_key_compare(__k, > _S_key(__j._M_node))) ? end() : __j; > } > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > typename _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::size_type > _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>:: > count(const _Key& __k) const > { > pair<const_iterator, const_iterator> __p = equal_range(__k); > const size_type __n = std::distance(__p.first, __p.second); > return __n; > } > > __attribute__ ((__pure__)) unsigned int > _Rb_tree_black_count(const _Rb_tree_node_base* __node, > const _Rb_tree_node_base* __root) throw (); > > template<typename _Key, typename _Val, typename _KeyOfValue, > typename _Compare, typename _Alloc> > bool > _Rb_tree<_Key,_Val,_KeyOfValue,_Compare,_Alloc>::__rb_verify() const > { > if (_M_impl._M_node_count == 0 || begin() == end()) > return _M_impl._M_node_count == 0 && begin() == end() > && this->_M_impl._M_header._M_left == _M_end() > && this->_M_impl._M_header._M_right == _M_end(); > > unsigned int __len = _Rb_tree_black_count(_M_leftmost(), _M_root()); > for (const_iterator __it = begin(); __it != end(); ++__it) > { > _Const_Link_type __x = static_cast<_Const_Link_type>(__it._M_node); > _Const_Link_type __L = _S_left(__x); > _Const_Link_type __R = _S_right(__x); > > if (__x->_M_color == _S_red) > if ((__L && __L->_M_color == _S_red) > || (__R && __R->_M_color == _S_red)) > return false; > > if (__L && _M_impl._M_key_compare(_S_key(__x), _S_key(__L))) > return false; > if (__R && _M_impl._M_key_compare(_S_key(__R), _S_key(__x))) > return false; > > if (!__L && !__R && _Rb_tree_black_count(__x, _M_root()) != __len) > return false; > } > > if (_M_leftmost() != _Rb_tree_node_base::_S_minimum(_M_root())) > return false; > if (_M_rightmost() != _Rb_tree_node_base::_S_maximum(_M_root())) > return false; > return true; > } > > >} ># 61 "/usr/include/c++/4.9.0/map" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_map.h" 1 3 ># 63 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 ># 1 "/usr/include/c++/4.9.0/tuple" 1 3 ># 32 "/usr/include/c++/4.9.0/tuple" 3 ># 33 "/usr/include/c++/4.9.0/tuple" 3 > > > > > > ># 1 "/usr/include/c++/4.9.0/array" 1 3 ># 32 "/usr/include/c++/4.9.0/array" 3 ># 33 "/usr/include/c++/4.9.0/array" 3 > > > > > ># 1 "/usr/include/c++/4.9.0/stdexcept" 1 3 ># 36 "/usr/include/c++/4.9.0/stdexcept" 3 ># 37 "/usr/include/c++/4.9.0/stdexcept" 3 > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 55 "/usr/include/c++/4.9.0/stdexcept" 3 > class logic_error : public exception > { > string _M_msg; > > public: > > explicit > logic_error(const string& __arg); > > virtual ~logic_error() noexcept; > > > > virtual const char* > what() const noexcept; > }; > > > > class domain_error : public logic_error > { > public: > explicit domain_error(const string& __arg); > virtual ~domain_error() noexcept; > }; > > > class invalid_argument : public logic_error > { > public: > explicit invalid_argument(const string& __arg); > virtual ~invalid_argument() noexcept; > }; > > > > class length_error : public logic_error > { > public: > explicit length_error(const string& __arg); > virtual ~length_error() noexcept; > }; > > > > class out_of_range : public logic_error > { > public: > explicit out_of_range(const string& __arg); > virtual ~out_of_range() noexcept; > }; > > > > > > > class runtime_error : public exception > { > string _M_msg; > > public: > > explicit > runtime_error(const string& __arg); > > virtual ~runtime_error() noexcept; > > > > virtual const char* > what() const noexcept; > }; > > > class range_error : public runtime_error > { > public: > explicit range_error(const string& __arg); > virtual ~range_error() noexcept; > }; > > > class overflow_error : public runtime_error > { > public: > explicit overflow_error(const string& __arg); > virtual ~overflow_error() noexcept; > }; > > > class underflow_error : public runtime_error > { > public: > explicit underflow_error(const string& __arg); > virtual ~underflow_error() noexcept; > }; > > > > >} ># 39 "/usr/include/c++/4.9.0/array" 2 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Tp, std::size_t _Nm> > struct __array_traits > { > typedef _Tp _Type[_Nm]; > > static constexpr _Tp& > _S_ref(const _Type& __t, std::size_t __n) noexcept > { return const_cast<_Tp&>(__t[__n]); } > }; > > template<typename _Tp> > struct __array_traits<_Tp, 0> > { > struct _Type { }; > > static constexpr _Tp& > _S_ref(const _Type&, std::size_t) noexcept > { return *static_cast<_Tp*>(nullptr); } > }; ># 80 "/usr/include/c++/4.9.0/array" 3 > template<typename _Tp, std::size_t _Nm> > struct array > { > typedef _Tp value_type; > typedef value_type* pointer; > typedef const value_type* const_pointer; > typedef value_type& reference; > typedef const value_type& const_reference; > typedef value_type* iterator; > typedef const value_type* const_iterator; > typedef std::size_t size_type; > typedef std::ptrdiff_t difference_type; > typedef std::reverse_iterator<iterator> reverse_iterator; > typedef std::reverse_iterator<const_iterator> const_reverse_iterator; > > > typedef std::__array_traits<_Tp, _Nm> _AT_Type; > typename _AT_Type::_Type _M_elems; > > > > > void > fill(const value_type& __u) > { std::fill_n(begin(), size(), __u); } > > void > swap(array& __other) > noexcept(noexcept(swap(std::declval<_Tp&>(), std::declval<_Tp&>()))) > { std::swap_ranges(begin(), end(), __other.begin()); } > > > iterator > begin() noexcept > { return iterator(data()); } > > const_iterator > begin() const noexcept > { return const_iterator(data()); } > > iterator > end() noexcept > { return iterator(data() + _Nm); } > > const_iterator > end() const noexcept > { return const_iterator(data() + _Nm); } > > reverse_iterator > rbegin() noexcept > { return reverse_iterator(end()); } > > const_reverse_iterator > rbegin() const noexcept > { return const_reverse_iterator(end()); } > > reverse_iterator > rend() noexcept > { return reverse_iterator(begin()); } > > const_reverse_iterator > rend() const noexcept > { return const_reverse_iterator(begin()); } > > const_iterator > cbegin() const noexcept > { return const_iterator(data()); } > > const_iterator > cend() const noexcept > { return const_iterator(data() + _Nm); } > > const_reverse_iterator > crbegin() const noexcept > { return const_reverse_iterator(end()); } > > const_reverse_iterator > crend() const noexcept > { return const_reverse_iterator(begin()); } > > > constexpr size_type > size() const noexcept { return _Nm; } > > constexpr size_type > max_size() const noexcept { return _Nm; } > > constexpr bool > empty() const noexcept { return size() == 0; } > > > reference > operator[](size_type __n) noexcept > { return _AT_Type::_S_ref(_M_elems, __n); } > > constexpr const_reference > operator[](size_type __n) const noexcept > { return _AT_Type::_S_ref(_M_elems, __n); } > > reference > at(size_type __n) > { > if (__n >= _Nm) > std::__throw_out_of_range_fmt(("array::at: __n (which is %zu) " ">= _Nm (which is %zu)") > , > __n, _Nm); > return _AT_Type::_S_ref(_M_elems, __n); > } > > constexpr const_reference > at(size_type __n) const > { > > > return __n < _Nm ? _AT_Type::_S_ref(_M_elems, __n) > : (std::__throw_out_of_range_fmt(("array::at: __n (which is %zu) " ">= _Nm (which is %zu)") > , > __n, _Nm), > _AT_Type::_S_ref(_M_elems, 0)); > } > > reference > front() noexcept > { return *begin(); } > > constexpr const_reference > front() const noexcept > { return _AT_Type::_S_ref(_M_elems, 0); } > > reference > back() noexcept > { return _Nm ? *(end() - 1) : *end(); } > > constexpr const_reference > back() const noexcept > { > return _Nm ? _AT_Type::_S_ref(_M_elems, _Nm - 1) > : _AT_Type::_S_ref(_M_elems, 0); > } > > pointer > data() noexcept > { return std::__addressof(_AT_Type::_S_ref(_M_elems, 0)); } > > const_pointer > data() const noexcept > { return std::__addressof(_AT_Type::_S_ref(_M_elems, 0)); } > }; > > > template<typename _Tp, std::size_t _Nm> > inline bool > operator==(const array<_Tp, _Nm>& __one, const array<_Tp, _Nm>& __two) > { return std::equal(__one.begin(), __one.end(), __two.begin()); } > > template<typename _Tp, std::size_t _Nm> > inline bool > operator!=(const array<_Tp, _Nm>& __one, const array<_Tp, _Nm>& __two) > { return !(__one == __two); } > > template<typename _Tp, std::size_t _Nm> > inline bool > operator<(const array<_Tp, _Nm>& __a, const array<_Tp, _Nm>& __b) > { > return std::lexicographical_compare(__a.begin(), __a.end(), > __b.begin(), __b.end()); > } > > template<typename _Tp, std::size_t _Nm> > inline bool > operator>(const array<_Tp, _Nm>& __one, const array<_Tp, _Nm>& __two) > { return __two < __one; } > > template<typename _Tp, std::size_t _Nm> > inline bool > operator<=(const array<_Tp, _Nm>& __one, const array<_Tp, _Nm>& __two) > { return !(__one > __two); } > > template<typename _Tp, std::size_t _Nm> > inline bool > operator>=(const array<_Tp, _Nm>& __one, const array<_Tp, _Nm>& __two) > { return !(__one < __two); } > > > template<typename _Tp, std::size_t _Nm> > inline void > swap(array<_Tp, _Nm>& __one, array<_Tp, _Nm>& __two) > noexcept(noexcept(__one.swap(__two))) > { __one.swap(__two); } > > template<std::size_t _Int, typename _Tp, std::size_t _Nm> > constexpr _Tp& > get(array<_Tp, _Nm>& __arr) noexcept > { > static_assert(_Int < _Nm, "index is out of bounds"); > return std::__array_traits<_Tp, _Nm>:: > _S_ref(__arr._M_elems, _Int); > } > > template<std::size_t _Int, typename _Tp, std::size_t _Nm> > constexpr _Tp&& > get(array<_Tp, _Nm>&& __arr) noexcept > { > static_assert(_Int < _Nm, "index is out of bounds"); > return std::move(get<_Int>(__arr)); > } > > template<std::size_t _Int, typename _Tp, std::size_t _Nm> > constexpr const _Tp& > get(const array<_Tp, _Nm>& __arr) noexcept > { > static_assert(_Int < _Nm, "index is out of bounds"); > return std::__array_traits<_Tp, _Nm>:: > _S_ref(__arr._M_elems, _Int); > } > > >} > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > template<typename _Tp> > class tuple_size; > > template<typename _Tp, std::size_t _Nm> > struct tuple_size<std::array<_Tp, _Nm>> > : public integral_constant<std::size_t, _Nm> { }; > > > template<std::size_t _Int, typename _Tp> > class tuple_element; > > template<std::size_t _Int, typename _Tp, std::size_t _Nm> > struct tuple_element<_Int, std::array<_Tp, _Nm>> > { > static_assert(_Int < _Nm, "index is out of bounds"); > typedef _Tp type; > }; > > >} ># 40 "/usr/include/c++/4.9.0/tuple" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/uses_allocator.h" 1 3 ># 34 "/usr/include/c++/4.9.0/bits/uses_allocator.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > struct allocator_arg_t { }; > > constexpr allocator_arg_t allocator_arg = allocator_arg_t(); > >template<typename _Tp> class __has_allocator_type_helper { template<typename _Up> struct _Wrap_type { }; template<typename _Up> static true_type __test(_Wrap_type<typename _Up::allocator_type>*); template<typename _Up> static false_type __test(...); public: typedef decltype(__test<_Tp>(0)) type; }; template<typename _Tp> struct __has_allocator_type : public __has_allocator_type_helper <typename remove_cv<_Tp>::type>::type { }; > > template<typename _Tp, typename _Alloc, > bool = __has_allocator_type<_Tp>::value> > struct __uses_allocator_helper > : public false_type { }; > > template<typename _Tp, typename _Alloc> > struct __uses_allocator_helper<_Tp, _Alloc, true> > : public integral_constant<bool, is_convertible<_Alloc, > typename _Tp::allocator_type>::value> > { }; > > > template<typename _Tp, typename _Alloc> > struct uses_allocator > : public integral_constant<bool, > __uses_allocator_helper<_Tp, _Alloc>::value> > { }; > > template<typename _Tp, typename _Alloc, typename... _Args> > struct __uses_allocator_arg > : is_constructible<_Tp, _Alloc, _Args...> > { static_assert( uses_allocator<_Tp, _Alloc>::value, "uses allocator" ); }; > > struct __uses_alloc_base { }; > struct __uses_alloc0 : __uses_alloc_base > { struct _Anything { _Anything(...) { } } _M_a; }; > template<typename _Alloc> > struct __uses_alloc1 : __uses_alloc_base { const _Alloc* _M_a; }; > template<typename _Alloc> > struct __uses_alloc2 : __uses_alloc_base { const _Alloc* _M_a; }; > > template<bool, typename _Alloc, typename... _Args> > struct __uses_alloc; > > template<typename _Tp, typename _Alloc, typename... _Args> > struct __uses_alloc<true, _Tp, _Alloc, _Args...> > : conditional< > is_constructible<_Tp, allocator_arg_t, _Alloc, _Args...>::value, > __uses_alloc1<_Alloc>, > __uses_alloc2<_Alloc>>::type > { }; > > template<typename _Tp, typename _Alloc, typename... _Args> > struct __uses_alloc<false, _Tp, _Alloc, _Args...> > : __uses_alloc0 { }; > > template<typename _Tp, typename _Alloc, typename... _Args> > struct __uses_alloc_impl > : __uses_alloc<uses_allocator<_Tp, _Alloc>::value, _Tp, _Alloc, _Args...> > { }; > > template<typename _Tp, typename _Alloc, typename... _Args> > __uses_alloc_impl<_Tp, _Alloc, _Args...> > __use_alloc(const _Alloc& __a) > { > __uses_alloc_impl<_Tp, _Alloc, _Args...> __ret; > __ret._M_a = &__a; > return __ret; > } > > >} ># 41 "/usr/include/c++/4.9.0/tuple" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 52 "/usr/include/c++/4.9.0/tuple" 3 > template<typename _Tp> > struct __add_c_ref > { typedef const _Tp& type; }; > > template<typename _Tp> > struct __add_c_ref<_Tp&> > { typedef _Tp& type; }; > > > template<typename _Tp> > struct __add_ref > { typedef _Tp& type; }; > > template<typename _Tp> > struct __add_ref<_Tp&> > { typedef _Tp& type; }; > > > template<typename _Tp> > struct __add_r_ref > { typedef _Tp&& type; }; > > template<typename _Tp> > struct __add_r_ref<_Tp&> > { typedef _Tp& type; }; > > template<std::size_t _Idx, typename _Head, bool _IsEmptyNotFinal> > struct _Head_base; > > template<std::size_t _Idx, typename _Head> > struct _Head_base<_Idx, _Head, true> > : public _Head > { > constexpr _Head_base() > : _Head() { } > > constexpr _Head_base(const _Head& __h) > : _Head(__h) { } > > template<typename _UHead, typename = typename > enable_if<!is_convertible<_UHead, > __uses_alloc_base>::value>::type> > constexpr _Head_base(_UHead&& __h) > : _Head(std::forward<_UHead>(__h)) { } > > _Head_base(__uses_alloc0) > : _Head() { } > > template<typename _Alloc> > _Head_base(__uses_alloc1<_Alloc> __a) > : _Head(allocator_arg, *__a._M_a) { } > > template<typename _Alloc> > _Head_base(__uses_alloc2<_Alloc> __a) > : _Head(*__a._M_a) { } > > template<typename _UHead> > _Head_base(__uses_alloc0, _UHead&& __uhead) > : _Head(std::forward<_UHead>(__uhead)) { } > > template<typename _Alloc, typename _UHead> > _Head_base(__uses_alloc1<_Alloc> __a, _UHead&& __uhead) > : _Head(allocator_arg, *__a._M_a, std::forward<_UHead>(__uhead)) { } > > template<typename _Alloc, typename _UHead> > _Head_base(__uses_alloc2<_Alloc> __a, _UHead&& __uhead) > : _Head(std::forward<_UHead>(__uhead), *__a._M_a) { } > > static constexpr _Head& > _M_head(_Head_base& __b) noexcept { return __b; } > > static constexpr const _Head& > _M_head(const _Head_base& __b) noexcept { return __b; } > }; > > template<std::size_t _Idx, typename _Head> > struct _Head_base<_Idx, _Head, false> > { > constexpr _Head_base() > : _M_head_impl() { } > > constexpr _Head_base(const _Head& __h) > : _M_head_impl(__h) { } > > template<typename _UHead, typename = typename > enable_if<!is_convertible<_UHead, > __uses_alloc_base>::value>::type> > constexpr _Head_base(_UHead&& __h) > : _M_head_impl(std::forward<_UHead>(__h)) { } > > _Head_base(__uses_alloc0) > : _M_head_impl() { } > > template<typename _Alloc> > _Head_base(__uses_alloc1<_Alloc> __a) > : _M_head_impl(allocator_arg, *__a._M_a) { } > > template<typename _Alloc> > _Head_base(__uses_alloc2<_Alloc> __a) > : _M_head_impl(*__a._M_a) { } > > template<typename _UHead> > _Head_base(__uses_alloc0, _UHead&& __uhead) > : _M_head_impl(std::forward<_UHead>(__uhead)) { } > > template<typename _Alloc, typename _UHead> > _Head_base(__uses_alloc1<_Alloc> __a, _UHead&& __uhead) > : _M_head_impl(allocator_arg, *__a._M_a, std::forward<_UHead>(__uhead)) > { } > > template<typename _Alloc, typename _UHead> > _Head_base(__uses_alloc2<_Alloc> __a, _UHead&& __uhead) > : _M_head_impl(std::forward<_UHead>(__uhead), *__a._M_a) { } > > static constexpr _Head& > _M_head(_Head_base& __b) noexcept { return __b._M_head_impl; } > > static constexpr const _Head& > _M_head(const _Head_base& __b) noexcept { return __b._M_head_impl; } > > _Head _M_head_impl; > }; ># 183 "/usr/include/c++/4.9.0/tuple" 3 > template<std::size_t _Idx, typename... _Elements> > struct _Tuple_impl; > > > > > > template<std::size_t _Idx> > struct _Tuple_impl<_Idx> > { > template<std::size_t, typename...> friend class _Tuple_impl; > > _Tuple_impl() = default; > > template<typename _Alloc> > _Tuple_impl(allocator_arg_t, const _Alloc&) { } > > template<typename _Alloc> > _Tuple_impl(allocator_arg_t, const _Alloc&, const _Tuple_impl&) { } > > template<typename _Alloc> > _Tuple_impl(allocator_arg_t, const _Alloc&, _Tuple_impl&&) { } > > protected: > void _M_swap(_Tuple_impl&) noexcept { } > }; > > template<typename _Tp> > struct __is_empty_non_tuple : is_empty<_Tp> { }; > > > template<typename _El0, typename... _El> > struct __is_empty_non_tuple<tuple<_El0, _El...>> : false_type { }; > > > template<typename _Tp> > using __empty_not_final > = typename conditional<__is_final(_Tp), false_type, > __is_empty_non_tuple<_Tp>>::type; > > > > > > > template<std::size_t _Idx, typename _Head, typename... _Tail> > struct _Tuple_impl<_Idx, _Head, _Tail...> > : public _Tuple_impl<_Idx + 1, _Tail...>, > private _Head_base<_Idx, _Head, __empty_not_final<_Head>::value> > { > template<std::size_t, typename...> friend class _Tuple_impl; > > typedef _Tuple_impl<_Idx + 1, _Tail...> _Inherited; > typedef _Head_base<_Idx, _Head, __empty_not_final<_Head>::value> _Base; > > static constexpr _Head& > _M_head(_Tuple_impl& __t) noexcept { return _Base::_M_head(__t); } > > static constexpr const _Head& > _M_head(const _Tuple_impl& __t) noexcept { return _Base::_M_head(__t); } > > static constexpr _Inherited& > _M_tail(_Tuple_impl& __t) noexcept { return __t; } > > static constexpr const _Inherited& > _M_tail(const _Tuple_impl& __t) noexcept { return __t; } > > constexpr _Tuple_impl() > : _Inherited(), _Base() { } > > explicit > constexpr _Tuple_impl(const _Head& __head, const _Tail&... __tail) > : _Inherited(__tail...), _Base(__head) { } > > template<typename _UHead, typename... _UTail, typename = typename > enable_if<sizeof...(_Tail) == sizeof...(_UTail)>::type> > explicit > constexpr _Tuple_impl(_UHead&& __head, _UTail&&... __tail) > : _Inherited(std::forward<_UTail>(__tail)...), > _Base(std::forward<_UHead>(__head)) { } > > constexpr _Tuple_impl(const _Tuple_impl&) = default; > > constexpr > _Tuple_impl(_Tuple_impl&& __in) > noexcept(__and_<is_nothrow_move_constructible<_Head>, > is_nothrow_move_constructible<_Inherited>>::value) > : _Inherited(std::move(_M_tail(__in))), > _Base(std::forward<_Head>(_M_head(__in))) { } > > template<typename... _UElements> > constexpr _Tuple_impl(const _Tuple_impl<_Idx, _UElements...>& __in) > : _Inherited(_Tuple_impl<_Idx, _UElements...>::_M_tail(__in)), > _Base(_Tuple_impl<_Idx, _UElements...>::_M_head(__in)) { } > > template<typename _UHead, typename... _UTails> > constexpr _Tuple_impl(_Tuple_impl<_Idx, _UHead, _UTails...>&& __in) > : _Inherited(std::move > (_Tuple_impl<_Idx, _UHead, _UTails...>::_M_tail(__in))), > _Base(std::forward<_UHead> > (_Tuple_impl<_Idx, _UHead, _UTails...>::_M_head(__in))) { } > > template<typename _Alloc> > _Tuple_impl(allocator_arg_t __tag, const _Alloc& __a) > : _Inherited(__tag, __a), > _Base(__use_alloc<_Head>(__a)) { } > > template<typename _Alloc> > _Tuple_impl(allocator_arg_t __tag, const _Alloc& __a, > const _Head& __head, const _Tail&... __tail) > : _Inherited(__tag, __a, __tail...), > _Base(__use_alloc<_Head, _Alloc, _Head>(__a), __head) { } > > template<typename _Alloc, typename _UHead, typename... _UTail, > typename = typename enable_if<sizeof...(_Tail) > == sizeof...(_UTail)>::type> > _Tuple_impl(allocator_arg_t __tag, const _Alloc& __a, > _UHead&& __head, _UTail&&... __tail) > : _Inherited(__tag, __a, std::forward<_UTail>(__tail)...), > _Base(__use_alloc<_Head, _Alloc, _UHead>(__a), > std::forward<_UHead>(__head)) { } > > template<typename _Alloc> > _Tuple_impl(allocator_arg_t __tag, const _Alloc& __a, > const _Tuple_impl& __in) > : _Inherited(__tag, __a, _M_tail(__in)), > _Base(__use_alloc<_Head, _Alloc, _Head>(__a), _M_head(__in)) { } > > template<typename _Alloc> > _Tuple_impl(allocator_arg_t __tag, const _Alloc& __a, > _Tuple_impl&& __in) > : _Inherited(__tag, __a, std::move(_M_tail(__in))), > _Base(__use_alloc<_Head, _Alloc, _Head>(__a), > std::forward<_Head>(_M_head(__in))) { } > > template<typename _Alloc, typename... _UElements> > _Tuple_impl(allocator_arg_t __tag, const _Alloc& __a, > const _Tuple_impl<_Idx, _UElements...>& __in) > : _Inherited(__tag, __a, > _Tuple_impl<_Idx, _UElements...>::_M_tail(__in)), > _Base(__use_alloc<_Head, _Alloc, _Head>(__a), > _Tuple_impl<_Idx, _UElements...>::_M_head(__in)) { } > > template<typename _Alloc, typename _UHead, typename... _UTails> > _Tuple_impl(allocator_arg_t __tag, const _Alloc& __a, > _Tuple_impl<_Idx, _UHead, _UTails...>&& __in) > : _Inherited(__tag, __a, std::move > (_Tuple_impl<_Idx, _UHead, _UTails...>::_M_tail(__in))), > _Base(__use_alloc<_Head, _Alloc, _UHead>(__a), > std::forward<_UHead> > (_Tuple_impl<_Idx, _UHead, _UTails...>::_M_head(__in))) { } > > _Tuple_impl& > operator=(const _Tuple_impl& __in) > { > _M_head(*this) = _M_head(__in); > _M_tail(*this) = _M_tail(__in); > return *this; > } > > _Tuple_impl& > operator=(_Tuple_impl&& __in) > noexcept(__and_<is_nothrow_move_assignable<_Head>, > is_nothrow_move_assignable<_Inherited>>::value) > { > _M_head(*this) = std::forward<_Head>(_M_head(__in)); > _M_tail(*this) = std::move(_M_tail(__in)); > return *this; > } > > template<typename... _UElements> > _Tuple_impl& > operator=(const _Tuple_impl<_Idx, _UElements...>& __in) > { > _M_head(*this) = _Tuple_impl<_Idx, _UElements...>::_M_head(__in); > _M_tail(*this) = _Tuple_impl<_Idx, _UElements...>::_M_tail(__in); > return *this; > } > > template<typename _UHead, typename... _UTails> > _Tuple_impl& > operator=(_Tuple_impl<_Idx, _UHead, _UTails...>&& __in) > { > _M_head(*this) = std::forward<_UHead> > (_Tuple_impl<_Idx, _UHead, _UTails...>::_M_head(__in)); > _M_tail(*this) = std::move > (_Tuple_impl<_Idx, _UHead, _UTails...>::_M_tail(__in)); > return *this; > } > > protected: > void > _M_swap(_Tuple_impl& __in) > noexcept(noexcept(swap(std::declval<_Head&>(), > std::declval<_Head&>())) > && noexcept(_M_tail(__in)._M_swap(_M_tail(__in)))) > { > using std::swap; > swap(_M_head(*this), _M_head(__in)); > _Inherited::_M_swap(_M_tail(__in)); > } > }; > > > template<typename... _Elements> > class tuple : public _Tuple_impl<0, _Elements...> > { > typedef _Tuple_impl<0, _Elements...> _Inherited; > > public: > constexpr tuple() > : _Inherited() { } > > explicit > constexpr tuple(const _Elements&... __elements) > : _Inherited(__elements...) { } > > template<typename... _UElements, typename = typename > enable_if<__and_<is_convertible<_UElements, > _Elements>...>::value>::type> > explicit > constexpr tuple(_UElements&&... __elements) > : _Inherited(std::forward<_UElements>(__elements)...) { } > > constexpr tuple(const tuple&) = default; > > constexpr tuple(tuple&&) = default; > > template<typename... _UElements, typename = typename > enable_if<__and_<is_convertible<const _UElements&, > _Elements>...>::value>::type> > constexpr tuple(const tuple<_UElements...>& __in) > : _Inherited(static_cast<const _Tuple_impl<0, _UElements...>&>(__in)) > { } > > template<typename... _UElements, typename = typename > enable_if<__and_<is_convertible<_UElements, > _Elements>...>::value>::type> > constexpr tuple(tuple<_UElements...>&& __in) > : _Inherited(static_cast<_Tuple_impl<0, _UElements...>&&>(__in)) { } > > > > template<typename _Alloc> > tuple(allocator_arg_t __tag, const _Alloc& __a) > : _Inherited(__tag, __a) { } > > template<typename _Alloc> > tuple(allocator_arg_t __tag, const _Alloc& __a, > const _Elements&... __elements) > : _Inherited(__tag, __a, __elements...) { } > > template<typename _Alloc, typename... _UElements, typename = typename > enable_if<sizeof...(_UElements) > == sizeof...(_Elements)>::type> > tuple(allocator_arg_t __tag, const _Alloc& __a, > _UElements&&... __elements) > : _Inherited(__tag, __a, std::forward<_UElements>(__elements)...) > { } > > template<typename _Alloc> > tuple(allocator_arg_t __tag, const _Alloc& __a, const tuple& __in) > : _Inherited(__tag, __a, static_cast<const _Inherited&>(__in)) { } > > template<typename _Alloc> > tuple(allocator_arg_t __tag, const _Alloc& __a, tuple&& __in) > : _Inherited(__tag, __a, static_cast<_Inherited&&>(__in)) { } > > template<typename _Alloc, typename... _UElements, typename = typename > enable_if<sizeof...(_UElements) > == sizeof...(_Elements)>::type> > tuple(allocator_arg_t __tag, const _Alloc& __a, > const tuple<_UElements...>& __in) > : _Inherited(__tag, __a, > static_cast<const _Tuple_impl<0, _UElements...>&>(__in)) > { } > > template<typename _Alloc, typename... _UElements, typename = typename > enable_if<sizeof...(_UElements) > == sizeof...(_Elements)>::type> > tuple(allocator_arg_t __tag, const _Alloc& __a, > tuple<_UElements...>&& __in) > : _Inherited(__tag, __a, > static_cast<_Tuple_impl<0, _UElements...>&&>(__in)) > { } > > tuple& > operator=(const tuple& __in) > { > static_cast<_Inherited&>(*this) = __in; > return *this; > } > > tuple& > operator=(tuple&& __in) > noexcept(is_nothrow_move_assignable<_Inherited>::value) > { > static_cast<_Inherited&>(*this) = std::move(__in); > return *this; > } > > template<typename... _UElements, typename = typename > enable_if<sizeof...(_UElements) > == sizeof...(_Elements)>::type> > tuple& > operator=(const tuple<_UElements...>& __in) > { > static_cast<_Inherited&>(*this) = __in; > return *this; > } > > template<typename... _UElements, typename = typename > enable_if<sizeof...(_UElements) > == sizeof...(_Elements)>::type> > tuple& > operator=(tuple<_UElements...>&& __in) > { > static_cast<_Inherited&>(*this) = std::move(__in); > return *this; > } > > void > swap(tuple& __in) > noexcept(noexcept(__in._M_swap(__in))) > { _Inherited::_M_swap(__in); } > }; > > > template<> > class tuple<> > { > public: > void swap(tuple&) noexcept { } > }; > > > > template<typename _T1, typename _T2> > class tuple<_T1, _T2> : public _Tuple_impl<0, _T1, _T2> > { > typedef _Tuple_impl<0, _T1, _T2> _Inherited; > > public: > constexpr tuple() > : _Inherited() { } > > explicit > constexpr tuple(const _T1& __a1, const _T2& __a2) > : _Inherited(__a1, __a2) { } > > template<typename _U1, typename _U2, typename = typename > enable_if<__and_<is_convertible<_U1, _T1>, > is_convertible<_U2, _T2>>::value>::type> > explicit > constexpr tuple(_U1&& __a1, _U2&& __a2) > : _Inherited(std::forward<_U1>(__a1), std::forward<_U2>(__a2)) { } > > constexpr tuple(const tuple&) = default; > > constexpr tuple(tuple&&) = default; > > template<typename _U1, typename _U2, typename = typename > enable_if<__and_<is_convertible<const _U1&, _T1>, > is_convertible<const _U2&, _T2>>::value>::type> > constexpr tuple(const tuple<_U1, _U2>& __in) > : _Inherited(static_cast<const _Tuple_impl<0, _U1, _U2>&>(__in)) { } > > template<typename _U1, typename _U2, typename = typename > enable_if<__and_<is_convertible<_U1, _T1>, > is_convertible<_U2, _T2>>::value>::type> > constexpr tuple(tuple<_U1, _U2>&& __in) > : _Inherited(static_cast<_Tuple_impl<0, _U1, _U2>&&>(__in)) { } > > template<typename _U1, typename _U2, typename = typename > enable_if<__and_<is_convertible<const _U1&, _T1>, > is_convertible<const _U2&, _T2>>::value>::type> > constexpr tuple(const pair<_U1, _U2>& __in) > : _Inherited(__in.first, __in.second) { } > > template<typename _U1, typename _U2, typename = typename > enable_if<__and_<is_convertible<_U1, _T1>, > is_convertible<_U2, _T2>>::value>::type> > constexpr tuple(pair<_U1, _U2>&& __in) > : _Inherited(std::forward<_U1>(__in.first), > std::forward<_U2>(__in.second)) { } > > > > template<typename _Alloc> > tuple(allocator_arg_t __tag, const _Alloc& __a) > : _Inherited(__tag, __a) { } > > template<typename _Alloc> > tuple(allocator_arg_t __tag, const _Alloc& __a, > const _T1& __a1, const _T2& __a2) > : _Inherited(__tag, __a, __a1, __a2) { } > > template<typename _Alloc, typename _U1, typename _U2> > tuple(allocator_arg_t __tag, const _Alloc& __a, _U1&& __a1, _U2&& __a2) > : _Inherited(__tag, __a, std::forward<_U1>(__a1), > std::forward<_U2>(__a2)) { } > > template<typename _Alloc> > tuple(allocator_arg_t __tag, const _Alloc& __a, const tuple& __in) > : _Inherited(__tag, __a, static_cast<const _Inherited&>(__in)) { } > > template<typename _Alloc> > tuple(allocator_arg_t __tag, const _Alloc& __a, tuple&& __in) > : _Inherited(__tag, __a, static_cast<_Inherited&&>(__in)) { } > > template<typename _Alloc, typename _U1, typename _U2> > tuple(allocator_arg_t __tag, const _Alloc& __a, > const tuple<_U1, _U2>& __in) > : _Inherited(__tag, __a, > static_cast<const _Tuple_impl<0, _U1, _U2>&>(__in)) > { } > > template<typename _Alloc, typename _U1, typename _U2> > tuple(allocator_arg_t __tag, const _Alloc& __a, tuple<_U1, _U2>&& __in) > : _Inherited(__tag, __a, static_cast<_Tuple_impl<0, _U1, _U2>&&>(__in)) > { } > > template<typename _Alloc, typename _U1, typename _U2> > tuple(allocator_arg_t __tag, const _Alloc& __a, > const pair<_U1, _U2>& __in) > : _Inherited(__tag, __a, __in.first, __in.second) { } > > template<typename _Alloc, typename _U1, typename _U2> > tuple(allocator_arg_t __tag, const _Alloc& __a, pair<_U1, _U2>&& __in) > : _Inherited(__tag, __a, std::forward<_U1>(__in.first), > std::forward<_U2>(__in.second)) { } > > tuple& > operator=(const tuple& __in) > { > static_cast<_Inherited&>(*this) = __in; > return *this; > } > > tuple& > operator=(tuple&& __in) > noexcept(is_nothrow_move_assignable<_Inherited>::value) > { > static_cast<_Inherited&>(*this) = std::move(__in); > return *this; > } > > template<typename _U1, typename _U2> > tuple& > operator=(const tuple<_U1, _U2>& __in) > { > static_cast<_Inherited&>(*this) = __in; > return *this; > } > > template<typename _U1, typename _U2> > tuple& > operator=(tuple<_U1, _U2>&& __in) > { > static_cast<_Inherited&>(*this) = std::move(__in); > return *this; > } > > template<typename _U1, typename _U2> > tuple& > operator=(const pair<_U1, _U2>& __in) > { > this->_M_head(*this) = __in.first; > this->_M_tail(*this)._M_head(*this) = __in.second; > return *this; > } > > template<typename _U1, typename _U2> > tuple& > operator=(pair<_U1, _U2>&& __in) > { > this->_M_head(*this) = std::forward<_U1>(__in.first); > this->_M_tail(*this)._M_head(*this) = std::forward<_U2>(__in.second); > return *this; > } > > void > swap(tuple& __in) > noexcept(noexcept(__in._M_swap(__in))) > { _Inherited::_M_swap(__in); } > }; > > > > template<std::size_t __i, typename _Tp> > struct tuple_element; > > > > > > template<std::size_t __i, typename _Head, typename... _Tail> > struct tuple_element<__i, tuple<_Head, _Tail...> > > : tuple_element<__i - 1, tuple<_Tail...> > { }; > > > > > template<typename _Head, typename... _Tail> > struct tuple_element<0, tuple<_Head, _Tail...> > > { > typedef _Head type; > }; > > template<std::size_t __i, typename _Tp> > struct tuple_element<__i, const _Tp> > { > typedef typename > add_const<typename tuple_element<__i, _Tp>::type>::type type; > }; > > template<std::size_t __i, typename _Tp> > struct tuple_element<__i, volatile _Tp> > { > typedef typename > add_volatile<typename tuple_element<__i, _Tp>::type>::type type; > }; > > template<std::size_t __i, typename _Tp> > struct tuple_element<__i, const volatile _Tp> > { > typedef typename > add_cv<typename tuple_element<__i, _Tp>::type>::type type; > }; > > > > > > > > template<typename _Tp> > struct tuple_size; > > template<typename _Tp> > struct tuple_size<const _Tp> > : public integral_constant< > typename remove_cv<decltype(tuple_size<_Tp>::value)>::type, > tuple_size<_Tp>::value> { }; > > template<typename _Tp> > struct tuple_size<volatile _Tp> > : public integral_constant< > typename remove_cv<decltype(tuple_size<_Tp>::value)>::type, > tuple_size<_Tp>::value> { }; > > template<typename _Tp> > struct tuple_size<const volatile _Tp> > : public integral_constant< > typename remove_cv<decltype(tuple_size<_Tp>::value)>::type, > tuple_size<_Tp>::value> { }; > > > template<typename... _Elements> > struct tuple_size<tuple<_Elements...>> > : public integral_constant<std::size_t, sizeof...(_Elements)> { }; > > template<std::size_t __i, typename _Head, typename... _Tail> > constexpr typename __add_ref<_Head>::type > __get_helper(_Tuple_impl<__i, _Head, _Tail...>& __t) noexcept > { return _Tuple_impl<__i, _Head, _Tail...>::_M_head(__t); } > > template<std::size_t __i, typename _Head, typename... _Tail> > constexpr typename __add_c_ref<_Head>::type > __get_helper(const _Tuple_impl<__i, _Head, _Tail...>& __t) noexcept > { return _Tuple_impl<__i, _Head, _Tail...>::_M_head(__t); } > > > > > template<std::size_t __i, typename... _Elements> > constexpr typename __add_ref< > typename tuple_element<__i, tuple<_Elements...>>::type > >::type > get(tuple<_Elements...>& __t) noexcept > { return std::__get_helper<__i>(__t); } > > template<std::size_t __i, typename... _Elements> > constexpr typename __add_c_ref< > typename tuple_element<__i, tuple<_Elements...>>::type > >::type > get(const tuple<_Elements...>& __t) noexcept > { return std::__get_helper<__i>(__t); } > > template<std::size_t __i, typename... _Elements> > constexpr typename __add_r_ref< > typename tuple_element<__i, tuple<_Elements...>>::type > >::type > get(tuple<_Elements...>&& __t) noexcept > { return std::forward<typename tuple_element<__i, > tuple<_Elements...>>::type&&>(get<__i>(__t)); } ># 808 "/usr/include/c++/4.9.0/tuple" 3 > template<std::size_t __check_equal_size, std::size_t __i, std::size_t __j, > typename _Tp, typename _Up> > struct __tuple_compare; > > template<std::size_t __i, std::size_t __j, typename _Tp, typename _Up> > struct __tuple_compare<0, __i, __j, _Tp, _Up> > { > static constexpr bool > __eq(const _Tp& __t, const _Up& __u) > { > return (get<__i>(__t) == get<__i>(__u) && > __tuple_compare<0, __i + 1, __j, _Tp, _Up>::__eq(__t, __u)); > } > > static constexpr bool > __less(const _Tp& __t, const _Up& __u) > { > return ((get<__i>(__t) < get<__i>(__u)) > || !(get<__i>(__u) < get<__i>(__t)) && > __tuple_compare<0, __i + 1, __j, _Tp, _Up>::__less(__t, __u)); > } > }; > > template<std::size_t __i, typename _Tp, typename _Up> > struct __tuple_compare<0, __i, __i, _Tp, _Up> > { > static constexpr bool > __eq(const _Tp&, const _Up&) { return true; } > > static constexpr bool > __less(const _Tp&, const _Up&) { return false; } > }; > > template<typename... _TElements, typename... _UElements> > constexpr bool > operator==(const tuple<_TElements...>& __t, > const tuple<_UElements...>& __u) > { > typedef tuple<_TElements...> _Tp; > typedef tuple<_UElements...> _Up; > return bool(__tuple_compare<tuple_size<_Tp>::value - tuple_size<_Up>::value, > 0, tuple_size<_Tp>::value, _Tp, _Up>::__eq(__t, __u)); > } > > template<typename... _TElements, typename... _UElements> > constexpr bool > operator<(const tuple<_TElements...>& __t, > const tuple<_UElements...>& __u) > { > typedef tuple<_TElements...> _Tp; > typedef tuple<_UElements...> _Up; > return bool(__tuple_compare<tuple_size<_Tp>::value - tuple_size<_Up>::value, > 0, tuple_size<_Tp>::value, _Tp, _Up>::__less(__t, __u)); > } > > template<typename... _TElements, typename... _UElements> > constexpr bool > operator!=(const tuple<_TElements...>& __t, > const tuple<_UElements...>& __u) > { return !(__t == __u); } > > template<typename... _TElements, typename... _UElements> > constexpr bool > operator>(const tuple<_TElements...>& __t, > const tuple<_UElements...>& __u) > { return __u < __t; } > > template<typename... _TElements, typename... _UElements> > constexpr bool > operator<=(const tuple<_TElements...>& __t, > const tuple<_UElements...>& __u) > { return !(__u < __t); } > > template<typename... _TElements, typename... _UElements> > constexpr bool > operator>=(const tuple<_TElements...>& __t, > const tuple<_UElements...>& __u) > { return !(__t < __u); } > > > template<typename... _Elements> > constexpr tuple<typename __decay_and_strip<_Elements>::__type...> > make_tuple(_Elements&&... __args) > { > typedef tuple<typename __decay_and_strip<_Elements>::__type...> > __result_type; > return __result_type(std::forward<_Elements>(__args)...); > } > > template<typename... _Elements> > tuple<_Elements&&...> > forward_as_tuple(_Elements&&... __args) noexcept > { return tuple<_Elements&&...>(std::forward<_Elements>(__args)...); } > > template<typename> > struct __is_tuple_like_impl : false_type > { }; > > template<typename... _Tps> > struct __is_tuple_like_impl<tuple<_Tps...>> : true_type > { }; > > template<typename _T1, typename _T2> > struct __is_tuple_like_impl<pair<_T1, _T2>> : true_type > { }; > > template<typename _Tp, std::size_t _Nm> > struct __is_tuple_like_impl<array<_Tp, _Nm>> : true_type > { }; > > > template<typename _Tp> > struct __is_tuple_like > : public __is_tuple_like_impl<typename std::remove_cv > <typename std::remove_reference<_Tp>::type>::type>::type > { }; > > template<std::size_t, typename, typename, std::size_t> > struct __make_tuple_impl; > > template<std::size_t _Idx, typename _Tuple, typename... _Tp, > std::size_t _Nm> > struct __make_tuple_impl<_Idx, tuple<_Tp...>, _Tuple, _Nm> > { > typedef typename __make_tuple_impl<_Idx + 1, tuple<_Tp..., > typename std::tuple_element<_Idx, _Tuple>::type>, _Tuple, _Nm>::__type > __type; > }; > > template<std::size_t _Nm, typename _Tuple, typename... _Tp> > struct __make_tuple_impl<_Nm, tuple<_Tp...>, _Tuple, _Nm> > { > typedef tuple<_Tp...> __type; > }; > > template<typename _Tuple> > struct __do_make_tuple > : public __make_tuple_impl<0, tuple<>, _Tuple, > std::tuple_size<_Tuple>::value> > { }; > > > template<typename _Tuple> > struct __make_tuple > : public __do_make_tuple<typename std::remove_cv > <typename std::remove_reference<_Tuple>::type>::type> > { }; > > > template<typename...> > struct __combine_tuples; > > template<> > struct __combine_tuples<> > { > typedef tuple<> __type; > }; > > template<typename... _Ts> > struct __combine_tuples<tuple<_Ts...>> > { > typedef tuple<_Ts...> __type; > }; > > template<typename... _T1s, typename... _T2s, typename... _Rem> > struct __combine_tuples<tuple<_T1s...>, tuple<_T2s...>, _Rem...> > { > typedef typename __combine_tuples<tuple<_T1s..., _T2s...>, > _Rem...>::__type __type; > }; > > > template<typename... _Tpls> > struct __tuple_cat_result > { > typedef typename __combine_tuples > <typename __make_tuple<_Tpls>::__type...>::__type __type; > }; > > > > template<typename...> > struct __make_1st_indices; > > template<> > struct __make_1st_indices<> > { > typedef std::_Index_tuple<> __type; > }; > > template<typename _Tp, typename... _Tpls> > struct __make_1st_indices<_Tp, _Tpls...> > { > typedef typename std::_Build_index_tuple<std::tuple_size< > typename std::remove_reference<_Tp>::type>::value>::__type __type; > }; > > > > > template<typename _Ret, typename _Indices, typename... _Tpls> > struct __tuple_concater; > > template<typename _Ret, std::size_t... _Is, typename _Tp, typename... _Tpls> > struct __tuple_concater<_Ret, std::_Index_tuple<_Is...>, _Tp, _Tpls...> > { > template<typename... _Us> > static constexpr _Ret > _S_do(_Tp&& __tp, _Tpls&&... __tps, _Us&&... __us) > { > typedef typename __make_1st_indices<_Tpls...>::__type __idx; > typedef __tuple_concater<_Ret, __idx, _Tpls...> __next; > return __next::_S_do(std::forward<_Tpls>(__tps)..., > std::forward<_Us>(__us)..., > std::get<_Is>(std::forward<_Tp>(__tp))...); > } > }; > > template<typename _Ret> > struct __tuple_concater<_Ret, std::_Index_tuple<>> > { > template<typename... _Us> > static constexpr _Ret > _S_do(_Us&&... __us) > { > return _Ret(std::forward<_Us>(__us)...); > } > }; > > > template<typename... _Tpls, typename = typename > enable_if<__and_<__is_tuple_like<_Tpls>...>::value>::type> > constexpr auto > tuple_cat(_Tpls&&... __tpls) > -> typename __tuple_cat_result<_Tpls...>::__type > { > typedef typename __tuple_cat_result<_Tpls...>::__type __ret; > typedef typename __make_1st_indices<_Tpls...>::__type __idx; > typedef __tuple_concater<__ret, __idx, _Tpls...> __concater; > return __concater::_S_do(std::forward<_Tpls>(__tpls)...); > } > > > template<typename... _Elements> > inline tuple<_Elements&...> > tie(_Elements&... __args) noexcept > { return tuple<_Elements&...>(__args...); } > > > template<typename... _Elements> > inline void > swap(tuple<_Elements...>& __x, tuple<_Elements...>& __y) > noexcept(noexcept(__x.swap(__y))) > { __x.swap(__y); } > > > > struct _Swallow_assign > { > template<class _Tp> > const _Swallow_assign& > operator=(const _Tp&) const > { return *this; } > }; > > const _Swallow_assign ignore{}; > > > template<typename... _Types, typename _Alloc> > struct uses_allocator<tuple<_Types...>, _Alloc> : true_type { }; > > > template<class _T1, class _T2> > template<typename... _Args1, typename... _Args2> > inline > pair<_T1, _T2>:: > pair(piecewise_construct_t, > tuple<_Args1...> __first, tuple<_Args2...> __second) > : pair(__first, __second, > typename _Build_index_tuple<sizeof...(_Args1)>::__type(), > typename _Build_index_tuple<sizeof...(_Args2)>::__type()) > { } > > template<class _T1, class _T2> > template<typename... _Args1, std::size_t... _Indexes1, > typename... _Args2, std::size_t... _Indexes2> > inline > pair<_T1, _T2>:: > pair(tuple<_Args1...>& __tuple1, tuple<_Args2...>& __tuple2, > _Index_tuple<_Indexes1...>, _Index_tuple<_Indexes2...>) > : first(std::forward<_Args1>(std::get<_Indexes1>(__tuple1))...), > second(std::forward<_Args2>(std::get<_Indexes2>(__tuple2))...) > { } > > > > >} ># 64 "/usr/include/c++/4.9.0/bits/stl_map.h" 2 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 94 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > template <typename _Key, typename _Tp, typename _Compare = std::less<_Key>, > typename _Alloc = std::allocator<std::pair<const _Key, _Tp> > > > class map > { > public: > typedef _Key key_type; > typedef _Tp mapped_type; > typedef std::pair<const _Key, _Tp> value_type; > typedef _Compare key_compare; > typedef _Alloc allocator_type; > > private: > > typedef typename _Alloc::value_type _Alloc_value_type; > > > > > > public: > class value_compare > : public std::binary_function<value_type, value_type, bool> > { > friend class map<_Key, _Tp, _Compare, _Alloc>; > protected: > _Compare comp; > > value_compare(_Compare __c) > : comp(__c) { } > > public: > bool operator()(const value_type& __x, const value_type& __y) const > { return comp(__x.first, __y.first); } > }; > > private: > > typedef typename __gnu_cxx::__alloc_traits<_Alloc>::template > rebind<value_type>::other _Pair_alloc_type; > > typedef _Rb_tree<key_type, value_type, _Select1st<value_type>, > key_compare, _Pair_alloc_type> _Rep_type; > > > _Rep_type _M_t; > > typedef __gnu_cxx::__alloc_traits<_Pair_alloc_type> _Alloc_traits; > > public: > > > typedef typename _Alloc_traits::pointer pointer; > typedef typename _Alloc_traits::const_pointer const_pointer; > typedef typename _Alloc_traits::reference reference; > typedef typename _Alloc_traits::const_reference const_reference; > typedef typename _Rep_type::iterator iterator; > typedef typename _Rep_type::const_iterator const_iterator; > typedef typename _Rep_type::size_type size_type; > typedef typename _Rep_type::difference_type difference_type; > typedef typename _Rep_type::reverse_iterator reverse_iterator; > typedef typename _Rep_type::const_reverse_iterator const_reverse_iterator; > > > > > > > > map() > : _M_t() { } > > > > > > > explicit > map(const _Compare& __comp, > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Pair_alloc_type(__a)) { } ># 182 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > map(const map& __x) > : _M_t(__x._M_t) { } ># 193 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > map(map&& __x) > noexcept(is_nothrow_copy_constructible<_Compare>::value) > : _M_t(std::move(__x._M_t)) { } ># 208 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > map(initializer_list<value_type> __l, > const _Compare& __comp = _Compare(), > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Pair_alloc_type(__a)) > { _M_t._M_insert_unique(__l.begin(), __l.end()); } > > > explicit > map(const allocator_type& __a) > : _M_t(_Compare(), _Pair_alloc_type(__a)) { } > > > map(const map& __m, const allocator_type& __a) > : _M_t(__m._M_t, _Pair_alloc_type(__a)) { } > > > map(map&& __m, const allocator_type& __a) > noexcept(is_nothrow_copy_constructible<_Compare>::value > && _Alloc_traits::_S_always_equal()) > : _M_t(std::move(__m._M_t), _Pair_alloc_type(__a)) { } > > > map(initializer_list<value_type> __l, const allocator_type& __a) > : _M_t(_Compare(), _Pair_alloc_type(__a)) > { _M_t._M_insert_unique(__l.begin(), __l.end()); } > > > template<typename _InputIterator> > map(_InputIterator __first, _InputIterator __last, > const allocator_type& __a) > : _M_t(_Compare(), _Pair_alloc_type(__a)) > { _M_t._M_insert_unique(__first, __last); } ># 252 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > template<typename _InputIterator> > map(_InputIterator __first, _InputIterator __last) > : _M_t() > { _M_t._M_insert_unique(__first, __last); } ># 269 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > template<typename _InputIterator> > map(_InputIterator __first, _InputIterator __last, > const _Compare& __comp, > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Pair_alloc_type(__a)) > { _M_t._M_insert_unique(__first, __last); } ># 292 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > map& > operator=(const map& __x) > { > _M_t = __x._M_t; > return *this; > } ># 308 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > map& > operator=(map&& __x) noexcept(_Alloc_traits::_S_nothrow_move()) > { > if (!_M_t._M_move_assign(__x._M_t)) > { > > > clear(); > insert(std::__make_move_if_noexcept_iterator(__x.begin()), > std::__make_move_if_noexcept_iterator(__x.end())); > __x.clear(); > } > return *this; > } ># 334 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > map& > operator=(initializer_list<value_type> __l) > { > this->clear(); > this->insert(__l.begin(), __l.end()); > return *this; > } > > > > allocator_type > get_allocator() const noexcept > { return allocator_type(_M_t.get_allocator()); } > > > > > > > > iterator > begin() noexcept > { return _M_t.begin(); } > > > > > > > const_iterator > begin() const noexcept > { return _M_t.begin(); } > > > > > > > iterator > end() noexcept > { return _M_t.end(); } > > > > > > > const_iterator > end() const noexcept > { return _M_t.end(); } > > > > > > > reverse_iterator > rbegin() noexcept > { return _M_t.rbegin(); } > > > > > > > const_reverse_iterator > rbegin() const noexcept > { return _M_t.rbegin(); } > > > > > > > reverse_iterator > rend() noexcept > { return _M_t.rend(); } > > > > > > > const_reverse_iterator > rend() const noexcept > { return _M_t.rend(); } > > > > > > > > const_iterator > cbegin() const noexcept > { return _M_t.begin(); } > > > > > > > const_iterator > cend() const noexcept > { return _M_t.end(); } > > > > > > > const_reverse_iterator > crbegin() const noexcept > { return _M_t.rbegin(); } > > > > > > > const_reverse_iterator > crend() const noexcept > { return _M_t.rend(); } > > > > > > > bool > empty() const noexcept > { return _M_t.empty(); } > > > size_type > size() const noexcept > { return _M_t.size(); } > > > size_type > max_size() const noexcept > { return _M_t.max_size(); } ># 490 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > mapped_type& > operator[](const key_type& __k) > { > > > > iterator __i = lower_bound(__k); > > if (__i == end() || key_comp()(__k, (*__i).first)) > > __i = _M_t._M_emplace_hint_unique(__i, std::piecewise_construct, > std::tuple<const key_type&>(__k), > std::tuple<>()); > > > > return (*__i).second; > } > > > mapped_type& > operator[](key_type&& __k) > { > > > > iterator __i = lower_bound(__k); > > if (__i == end() || key_comp()(__k, (*__i).first)) > __i = _M_t._M_emplace_hint_unique(__i, std::piecewise_construct, > std::forward_as_tuple(std::move(__k)), > std::tuple<>()); > return (*__i).second; > } ># 535 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > mapped_type& > at(const key_type& __k) > { > iterator __i = lower_bound(__k); > if (__i == end() || key_comp()(__k, (*__i).first)) > __throw_out_of_range(("map::at")); > return (*__i).second; > } > > const mapped_type& > at(const key_type& __k) const > { > const_iterator __i = lower_bound(__k); > if (__i == end() || key_comp()(__k, (*__i).first)) > __throw_out_of_range(("map::at")); > return (*__i).second; > } ># 573 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > template<typename... _Args> > std::pair<iterator, bool> > emplace(_Args&&... __args) > { return _M_t._M_emplace_unique(std::forward<_Args>(__args)...); } ># 603 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > template<typename... _Args> > iterator > emplace_hint(const_iterator __pos, _Args&&... __args) > { > return _M_t._M_emplace_hint_unique(__pos, > std::forward<_Args>(__args)...); > } ># 628 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > std::pair<iterator, bool> > insert(const value_type& __x) > { return _M_t._M_insert_unique(__x); } > > > template<typename _Pair, typename = typename > std::enable_if<std::is_constructible<value_type, > _Pair&&>::value>::type> > std::pair<iterator, bool> > insert(_Pair&& __x) > { return _M_t._M_insert_unique(std::forward<_Pair>(__x)); } ># 649 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > void > insert(std::initializer_list<value_type> __list) > { insert(__list.begin(), __list.end()); } ># 677 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > iterator > > insert(const_iterator __position, const value_type& __x) > > > > { return _M_t._M_insert_unique_(__position, __x); } > > > template<typename _Pair, typename = typename > std::enable_if<std::is_constructible<value_type, > _Pair&&>::value>::type> > iterator > insert(const_iterator __position, _Pair&& __x) > { return _M_t._M_insert_unique_(__position, > std::forward<_Pair>(__x)); } ># 703 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > template<typename _InputIterator> > void > insert(_InputIterator __first, _InputIterator __last) > { _M_t._M_insert_unique(__first, __last); } ># 724 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > iterator > erase(const_iterator __position) > { return _M_t.erase(__position); } > > > __attribute ((__abi_tag__ ("cxx11"))) > iterator > erase(iterator __position) > { return _M_t.erase(__position); } ># 760 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > size_type > erase(const key_type& __x) > { return _M_t.erase(__x); } ># 780 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > iterator > erase(const_iterator __first, const_iterator __last) > { return _M_t.erase(__first, __last); } ># 812 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > void > swap(map& __x) > > noexcept(_Alloc_traits::_S_nothrow_swap()) > > { _M_t.swap(__x._M_t); } > > > > > > > > void > clear() noexcept > { _M_t.clear(); } > > > > > > > key_compare > key_comp() const > { return _M_t.key_comp(); } > > > > > > value_compare > value_comp() const > { return value_compare(_M_t.key_comp()); } ># 858 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > iterator > find(const key_type& __x) > { return _M_t.find(__x); } ># 873 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > const_iterator > find(const key_type& __x) const > { return _M_t.find(__x); } ># 885 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > size_type > count(const key_type& __x) const > { return _M_t.find(__x) == _M_t.end() ? 0 : 1; } ># 900 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > iterator > lower_bound(const key_type& __x) > { return _M_t.lower_bound(__x); } ># 915 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > const_iterator > lower_bound(const key_type& __x) const > { return _M_t.lower_bound(__x); } > > > > > > > > iterator > upper_bound(const key_type& __x) > { return _M_t.upper_bound(__x); } > > > > > > > > const_iterator > upper_bound(const key_type& __x) const > { return _M_t.upper_bound(__x); } ># 954 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > std::pair<iterator, iterator> > equal_range(const key_type& __x) > { return _M_t.equal_range(__x); } ># 973 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > std::pair<const_iterator, const_iterator> > equal_range(const key_type& __x) const > { return _M_t.equal_range(__x); } > > template<typename _K1, typename _T1, typename _C1, typename _A1> > friend bool > operator==(const map<_K1, _T1, _C1, _A1>&, > const map<_K1, _T1, _C1, _A1>&); > > template<typename _K1, typename _T1, typename _C1, typename _A1> > friend bool > operator<(const map<_K1, _T1, _C1, _A1>&, > const map<_K1, _T1, _C1, _A1>&); > }; ># 998 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator==(const map<_Key, _Tp, _Compare, _Alloc>& __x, > const map<_Key, _Tp, _Compare, _Alloc>& __y) > { return __x._M_t == __y._M_t; } ># 1015 "/usr/include/c++/4.9.0/bits/stl_map.h" 3 > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator<(const map<_Key, _Tp, _Compare, _Alloc>& __x, > const map<_Key, _Tp, _Compare, _Alloc>& __y) > { return __x._M_t < __y._M_t; } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator!=(const map<_Key, _Tp, _Compare, _Alloc>& __x, > const map<_Key, _Tp, _Compare, _Alloc>& __y) > { return !(__x == __y); } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator>(const map<_Key, _Tp, _Compare, _Alloc>& __x, > const map<_Key, _Tp, _Compare, _Alloc>& __y) > { return __y < __x; } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator<=(const map<_Key, _Tp, _Compare, _Alloc>& __x, > const map<_Key, _Tp, _Compare, _Alloc>& __y) > { return !(__y < __x); } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator>=(const map<_Key, _Tp, _Compare, _Alloc>& __x, > const map<_Key, _Tp, _Compare, _Alloc>& __y) > { return !(__x < __y); } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline void > swap(map<_Key, _Tp, _Compare, _Alloc>& __x, > map<_Key, _Tp, _Compare, _Alloc>& __y) > { __x.swap(__y); } > > >} ># 62 "/usr/include/c++/4.9.0/map" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 1 3 ># 64 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 92 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > template <typename _Key, typename _Tp, > typename _Compare = std::less<_Key>, > typename _Alloc = std::allocator<std::pair<const _Key, _Tp> > > > class multimap > { > public: > typedef _Key key_type; > typedef _Tp mapped_type; > typedef std::pair<const _Key, _Tp> value_type; > typedef _Compare key_compare; > typedef _Alloc allocator_type; > > private: > > typedef typename _Alloc::value_type _Alloc_value_type; > > > > > > public: > class value_compare > : public std::binary_function<value_type, value_type, bool> > { > friend class multimap<_Key, _Tp, _Compare, _Alloc>; > protected: > _Compare comp; > > value_compare(_Compare __c) > : comp(__c) { } > > public: > bool operator()(const value_type& __x, const value_type& __y) const > { return comp(__x.first, __y.first); } > }; > > private: > > typedef typename __gnu_cxx::__alloc_traits<_Alloc>::template > rebind<value_type>::other _Pair_alloc_type; > > typedef _Rb_tree<key_type, value_type, _Select1st<value_type>, > key_compare, _Pair_alloc_type> _Rep_type; > > _Rep_type _M_t; > > typedef __gnu_cxx::__alloc_traits<_Pair_alloc_type> _Alloc_traits; > > public: > > > typedef typename _Alloc_traits::pointer pointer; > typedef typename _Alloc_traits::const_pointer const_pointer; > typedef typename _Alloc_traits::reference reference; > typedef typename _Alloc_traits::const_reference const_reference; > typedef typename _Rep_type::iterator iterator; > typedef typename _Rep_type::const_iterator const_iterator; > typedef typename _Rep_type::size_type size_type; > typedef typename _Rep_type::difference_type difference_type; > typedef typename _Rep_type::reverse_iterator reverse_iterator; > typedef typename _Rep_type::const_reverse_iterator const_reverse_iterator; > > > > > > > > multimap() > : _M_t() { } > > > > > > > explicit > multimap(const _Compare& __comp, > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Pair_alloc_type(__a)) { } ># 180 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > multimap(const multimap& __x) > : _M_t(__x._M_t) { } ># 191 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > multimap(multimap&& __x) > noexcept(is_nothrow_copy_constructible<_Compare>::value) > : _M_t(std::move(__x._M_t)) { } ># 205 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > multimap(initializer_list<value_type> __l, > const _Compare& __comp = _Compare(), > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Pair_alloc_type(__a)) > { _M_t._M_insert_equal(__l.begin(), __l.end()); } > > > explicit > multimap(const allocator_type& __a) > : _M_t(_Compare(), _Pair_alloc_type(__a)) { } > > > multimap(const multimap& __m, const allocator_type& __a) > : _M_t(__m._M_t, _Pair_alloc_type(__a)) { } > > > multimap(multimap&& __m, const allocator_type& __a) > noexcept(is_nothrow_copy_constructible<_Compare>::value > && _Alloc_traits::_S_always_equal()) > : _M_t(std::move(__m._M_t), _Pair_alloc_type(__a)) { } > > > multimap(initializer_list<value_type> __l, const allocator_type& __a) > : _M_t(_Compare(), _Pair_alloc_type(__a)) > { _M_t._M_insert_equal(__l.begin(), __l.end()); } > > > template<typename _InputIterator> > multimap(_InputIterator __first, _InputIterator __last, > const allocator_type& __a) > : _M_t(_Compare(), _Pair_alloc_type(__a)) > { _M_t._M_insert_equal(__first, __last); } ># 248 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > template<typename _InputIterator> > multimap(_InputIterator __first, _InputIterator __last) > : _M_t() > { _M_t._M_insert_equal(__first, __last); } ># 264 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > template<typename _InputIterator> > multimap(_InputIterator __first, _InputIterator __last, > const _Compare& __comp, > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Pair_alloc_type(__a)) > { _M_t._M_insert_equal(__first, __last); } ># 287 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > multimap& > operator=(const multimap& __x) > { > _M_t = __x._M_t; > return *this; > } ># 303 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > multimap& > operator=(multimap&& __x) noexcept(_Alloc_traits::_S_nothrow_move()) > { > if (!_M_t._M_move_assign(__x._M_t)) > { > > > clear(); > insert(std::__make_move_if_noexcept_iterator(__x.begin()), > std::__make_move_if_noexcept_iterator(__x.end())); > __x.clear(); > } > return *this; > } ># 329 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > multimap& > operator=(initializer_list<value_type> __l) > { > this->clear(); > this->insert(__l.begin(), __l.end()); > return *this; > } > > > > allocator_type > get_allocator() const noexcept > { return allocator_type(_M_t.get_allocator()); } > > > > > > > > iterator > begin() noexcept > { return _M_t.begin(); } > > > > > > > const_iterator > begin() const noexcept > { return _M_t.begin(); } > > > > > > > iterator > end() noexcept > { return _M_t.end(); } > > > > > > > const_iterator > end() const noexcept > { return _M_t.end(); } > > > > > > > reverse_iterator > rbegin() noexcept > { return _M_t.rbegin(); } > > > > > > > const_reverse_iterator > rbegin() const noexcept > { return _M_t.rbegin(); } > > > > > > > reverse_iterator > rend() noexcept > { return _M_t.rend(); } > > > > > > > const_reverse_iterator > rend() const noexcept > { return _M_t.rend(); } > > > > > > > > const_iterator > cbegin() const noexcept > { return _M_t.begin(); } > > > > > > > const_iterator > cend() const noexcept > { return _M_t.end(); } > > > > > > > const_reverse_iterator > crbegin() const noexcept > { return _M_t.rbegin(); } > > > > > > > const_reverse_iterator > crend() const noexcept > { return _M_t.rend(); } > > > > > bool > empty() const noexcept > { return _M_t.empty(); } > > > size_type > size() const noexcept > { return _M_t.size(); } > > > size_type > max_size() const noexcept > { return _M_t.max_size(); } ># 488 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > template<typename... _Args> > iterator > emplace(_Args&&... __args) > { return _M_t._M_emplace_equal(std::forward<_Args>(__args)...); } ># 515 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > template<typename... _Args> > iterator > emplace_hint(const_iterator __pos, _Args&&... __args) > { > return _M_t._M_emplace_hint_equal(__pos, > std::forward<_Args>(__args)...); > } ># 536 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > iterator > insert(const value_type& __x) > { return _M_t._M_insert_equal(__x); } > > > template<typename _Pair, typename = typename > std::enable_if<std::is_constructible<value_type, > _Pair&&>::value>::type> > iterator > insert(_Pair&& __x) > { return _M_t._M_insert_equal(std::forward<_Pair>(__x)); } ># 569 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > iterator > > insert(const_iterator __position, const value_type& __x) > > > > { return _M_t._M_insert_equal_(__position, __x); } > > > template<typename _Pair, typename = typename > std::enable_if<std::is_constructible<value_type, > _Pair&&>::value>::type> > iterator > insert(const_iterator __position, _Pair&& __x) > { return _M_t._M_insert_equal_(__position, > std::forward<_Pair>(__x)); } ># 596 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > template<typename _InputIterator> > void > insert(_InputIterator __first, _InputIterator __last) > { _M_t._M_insert_equal(__first, __last); } ># 609 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > void > insert(initializer_list<value_type> __l) > { this->insert(__l.begin(), __l.end()); } ># 630 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > iterator > erase(const_iterator __position) > { return _M_t.erase(__position); } > > > __attribute ((__abi_tag__ ("cxx11"))) > iterator > erase(iterator __position) > { return _M_t.erase(__position); } ># 666 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > size_type > erase(const key_type& __x) > { return _M_t.erase(__x); } ># 687 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > iterator > erase(const_iterator __first, const_iterator __last) > { return _M_t.erase(__first, __last); } ># 722 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > void > swap(multimap& __x) > > noexcept(_Alloc_traits::_S_nothrow_swap()) > > { _M_t.swap(__x._M_t); } > > > > > > > > void > clear() noexcept > { _M_t.clear(); } > > > > > > > key_compare > key_comp() const > { return _M_t.key_comp(); } > > > > > > value_compare > value_comp() const > { return value_compare(_M_t.key_comp()); } ># 768 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > iterator > find(const key_type& __x) > { return _M_t.find(__x); } ># 783 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > const_iterator > find(const key_type& __x) const > { return _M_t.find(__x); } > > > > > > > size_type > count(const key_type& __x) const > { return _M_t.count(__x); } ># 807 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > iterator > lower_bound(const key_type& __x) > { return _M_t.lower_bound(__x); } ># 822 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > const_iterator > lower_bound(const key_type& __x) const > { return _M_t.lower_bound(__x); } > > > > > > > > iterator > upper_bound(const key_type& __x) > { return _M_t.upper_bound(__x); } > > > > > > > > const_iterator > upper_bound(const key_type& __x) const > { return _M_t.upper_bound(__x); } ># 859 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > std::pair<iterator, iterator> > equal_range(const key_type& __x) > { return _M_t.equal_range(__x); } ># 876 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > std::pair<const_iterator, const_iterator> > equal_range(const key_type& __x) const > { return _M_t.equal_range(__x); } > > template<typename _K1, typename _T1, typename _C1, typename _A1> > friend bool > operator==(const multimap<_K1, _T1, _C1, _A1>&, > const multimap<_K1, _T1, _C1, _A1>&); > > template<typename _K1, typename _T1, typename _C1, typename _A1> > friend bool > operator<(const multimap<_K1, _T1, _C1, _A1>&, > const multimap<_K1, _T1, _C1, _A1>&); > }; ># 901 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator==(const multimap<_Key, _Tp, _Compare, _Alloc>& __x, > const multimap<_Key, _Tp, _Compare, _Alloc>& __y) > { return __x._M_t == __y._M_t; } ># 918 "/usr/include/c++/4.9.0/bits/stl_multimap.h" 3 > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator<(const multimap<_Key, _Tp, _Compare, _Alloc>& __x, > const multimap<_Key, _Tp, _Compare, _Alloc>& __y) > { return __x._M_t < __y._M_t; } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator!=(const multimap<_Key, _Tp, _Compare, _Alloc>& __x, > const multimap<_Key, _Tp, _Compare, _Alloc>& __y) > { return !(__x == __y); } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator>(const multimap<_Key, _Tp, _Compare, _Alloc>& __x, > const multimap<_Key, _Tp, _Compare, _Alloc>& __y) > { return __y < __x; } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator<=(const multimap<_Key, _Tp, _Compare, _Alloc>& __x, > const multimap<_Key, _Tp, _Compare, _Alloc>& __y) > { return !(__y < __x); } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline bool > operator>=(const multimap<_Key, _Tp, _Compare, _Alloc>& __x, > const multimap<_Key, _Tp, _Compare, _Alloc>& __y) > { return !(__x < __y); } > > > template<typename _Key, typename _Tp, typename _Compare, typename _Alloc> > inline void > swap(multimap<_Key, _Tp, _Compare, _Alloc>& __x, > multimap<_Key, _Tp, _Compare, _Alloc>& __y) > { __x.swap(__y); } > > >} ># 63 "/usr/include/c++/4.9.0/map" 2 3 ># 41 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 > ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 103 "/usr/include/boost/cstdint.hpp" 3 4 >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; > > > > using ::int64_t; > using ::int_least64_t; > using ::int_fast64_t; > using ::uint64_t; > using ::uint_least64_t; > using ::uint_fast64_t; > > > > using ::intmax_t; > using ::uintmax_t; > >} ># 379 "/usr/include/boost/cstdint.hpp" 3 4 >namespace boost { > using ::intptr_t; > using ::uintptr_t; >} ># 43 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/usr/include/boost/thread.hpp" 1 3 4 ># 13 "/usr/include/boost/thread.hpp" 3 4 ># 1 "/usr/include/boost/thread/thread.hpp" 1 3 4 ># 12 "/usr/include/boost/thread/thread.hpp" 3 4 ># 1 "/usr/include/boost/thread/thread_only.hpp" 1 3 4 ># 12 "/usr/include/boost/thread/thread_only.hpp" 3 4 ># 1 "/usr/include/boost/thread/detail/platform.hpp" 1 3 4 ># 17 "/usr/include/boost/thread/detail/platform.hpp" 3 4 ># 1 "/usr/include/boost/config/requires_threads.hpp" 1 3 4 ># 18 "/usr/include/boost/thread/detail/platform.hpp" 2 3 4 ># 13 "/usr/include/boost/thread/thread_only.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/thread/pthread/thread_data.hpp" 1 3 4 ># 9 "/usr/include/boost/thread/pthread/thread_data.hpp" 3 4 ># 1 "/usr/include/boost/thread/detail/config.hpp" 1 3 4 ># 433 "/usr/include/boost/thread/detail/config.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 434 "/usr/include/boost/thread/detail/config.hpp" 2 3 4 ># 10 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/exceptions.hpp" 1 3 4 ># 22 "/usr/include/boost/thread/exceptions.hpp" 3 4 ># 1 "/usr/include/boost/system/system_error.hpp" 1 3 4 ># 13 "/usr/include/boost/system/system_error.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cassert" 1 3 4 ># 41 "/usr/include/c++/4.9.0/cassert" 3 4 ># 42 "/usr/include/c++/4.9.0/cassert" 3 > ># 1 "/usr/include/assert.h" 1 3 4 ># 43 "/usr/include/c++/4.9.0/cassert" 2 3 ># 14 "/usr/include/boost/system/system_error.hpp" 2 3 4 ># 1 "/usr/include/boost/system/error_code.hpp" 1 3 4 ># 14 "/usr/include/boost/system/error_code.hpp" 3 4 ># 1 "/usr/include/boost/system/config.hpp" 1 3 4 ># 14 "/usr/include/boost/system/config.hpp" 3 4 ># 1 "/usr/include/boost/system/api_config.hpp" 1 3 4 ># 15 "/usr/include/boost/system/config.hpp" 2 3 4 ># 65 "/usr/include/boost/system/config.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 66 "/usr/include/boost/system/config.hpp" 2 3 4 ># 15 "/usr/include/boost/system/error_code.hpp" 2 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 16 "/usr/include/boost/system/error_code.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 17 "/usr/include/boost/system/error_code.hpp" 2 3 4 ># 1 "/usr/include/boost/operators.hpp" 1 3 4 ># 97 "/usr/include/boost/operators.hpp" 3 4 >namespace boost { >namespace detail { > >template <typename T> class empty_base { > > > > > > >}; > >} >} ># 120 "/usr/include/boost/operators.hpp" 3 4 >namespace boost >{ > > > > > > > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct less_than_comparable2 : B >{ > friend bool operator<=(const T& x, const U& y) { return !static_cast<bool>(x > y); } > friend bool operator>=(const T& x, const U& y) { return !static_cast<bool>(x < y); } > friend bool operator>(const U& x, const T& y) { return y < x; } > friend bool operator<(const U& x, const T& y) { return y > x; } > friend bool operator<=(const U& x, const T& y) { return !static_cast<bool>(y < x); } > friend bool operator>=(const U& x, const T& y) { return !static_cast<bool>(y > x); } >}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct less_than_comparable1 : B >{ > friend bool operator>(const T& x, const T& y) { return y < x; } > friend bool operator<=(const T& x, const T& y) { return !static_cast<bool>(y < x); } > friend bool operator>=(const T& x, const T& y) { return !static_cast<bool>(x < y); } >}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct equality_comparable2 : B >{ > friend bool operator==(const U& y, const T& x) { return x == y; } > friend bool operator!=(const U& y, const T& x) { return !static_cast<bool>(x == y); } > friend bool operator!=(const T& y, const U& x) { return !static_cast<bool>(y == x); } >}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct equality_comparable1 : B >{ > friend bool operator!=(const T& x, const T& y) { return !static_cast<bool>(x == y); } >}; ># 256 "/usr/include/boost/operators.hpp" 3 4 >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct multipliable2 : B { friend T operator *( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv *= rhs; return nrv; } friend T operator *( const U& lhs, const T& rhs ) { T nrv( rhs ); nrv *= lhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct multipliable1 : B { friend T operator *( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv *= rhs; return nrv; } }; >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct addable2 : B { friend T operator +( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv += rhs; return nrv; } friend T operator +( const U& lhs, const T& rhs ) { T nrv( rhs ); nrv += lhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct addable1 : B { friend T operator +( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv += rhs; return nrv; } }; >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct subtractable2 : B { friend T operator -( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv -= rhs; return nrv; } }; template <class T, class U, class B = ::boost::detail::empty_base<T> > struct subtractable2_left : B { friend T operator -( const U& lhs, const T& rhs ) { T nrv( lhs ); nrv -= rhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct subtractable1 : B { friend T operator -( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv -= rhs; return nrv; } }; >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct dividable2 : B { friend T operator /( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv /= rhs; return nrv; } }; template <class T, class U, class B = ::boost::detail::empty_base<T> > struct dividable2_left : B { friend T operator /( const U& lhs, const T& rhs ) { T nrv( lhs ); nrv /= rhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct dividable1 : B { friend T operator /( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv /= rhs; return nrv; } }; >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct modable2 : B { friend T operator %( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv %= rhs; return nrv; } }; template <class T, class U, class B = ::boost::detail::empty_base<T> > struct modable2_left : B { friend T operator %( const U& lhs, const T& rhs ) { T nrv( lhs ); nrv %= rhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct modable1 : B { friend T operator %( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv %= rhs; return nrv; } }; >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct xorable2 : B { friend T operator ^( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv ^= rhs; return nrv; } friend T operator ^( const U& lhs, const T& rhs ) { T nrv( rhs ); nrv ^= lhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct xorable1 : B { friend T operator ^( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv ^= rhs; return nrv; } }; >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct andable2 : B { friend T operator &( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv &= rhs; return nrv; } friend T operator &( const U& lhs, const T& rhs ) { T nrv( rhs ); nrv &= lhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct andable1 : B { friend T operator &( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv &= rhs; return nrv; } }; >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct orable2 : B { friend T operator |( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv |= rhs; return nrv; } friend T operator |( const U& lhs, const T& rhs ) { T nrv( rhs ); nrv |= lhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct orable1 : B { friend T operator |( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv |= rhs; return nrv; } }; > > > > > > > >template <class T, class B = ::boost::detail::empty_base<T> > >struct incrementable : B >{ > friend T operator++(T& x, int) > { > incrementable_type nrv(x); > ++x; > return nrv; > } >private: > typedef T incrementable_type; >}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct decrementable : B >{ > friend T operator--(T& x, int) > { > decrementable_type nrv(x); > --x; > return nrv; > } >private: > typedef T decrementable_type; >}; > > > >template <class T, class P, class B = ::boost::detail::empty_base<T> > >struct dereferenceable : B >{ > P operator->() const > { > return &*static_cast<const T&>(*this); > } >}; > >template <class T, class I, class R, class B = ::boost::detail::empty_base<T> > >struct indexable : B >{ > R operator[](I n) const > { > return *(static_cast<const T&>(*this) + n); > } >}; ># 354 "/usr/include/boost/operators.hpp" 3 4 >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct left_shiftable2 : B { friend T operator <<( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv <<= rhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct left_shiftable1 : B { friend T operator <<( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv <<= rhs; return nrv; } }; >template <class T, class U, class B = ::boost::detail::empty_base<T> > struct right_shiftable2 : B { friend T operator >>( const T& lhs, const U& rhs ) { T nrv( lhs ); nrv >>= rhs; return nrv; } }; template <class T, class B = ::boost::detail::empty_base<T> > struct right_shiftable1 : B { friend T operator >>( const T& lhs, const T& rhs ) { T nrv( lhs ); nrv >>= rhs; return nrv; } }; > > > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct equivalent2 : B >{ > friend bool operator==(const T& x, const U& y) > { > return !static_cast<bool>(x < y) && !static_cast<bool>(x > y); > } >}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct equivalent1 : B >{ > friend bool operator==(const T&x, const T&y) > { > return !static_cast<bool>(x < y) && !static_cast<bool>(y < x); > } >}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct partially_ordered2 : B >{ > friend bool operator<=(const T& x, const U& y) > { return static_cast<bool>(x < y) || static_cast<bool>(x == y); } > friend bool operator>=(const T& x, const U& y) > { return static_cast<bool>(x > y) || static_cast<bool>(x == y); } > friend bool operator>(const U& x, const T& y) > { return y < x; } > friend bool operator<(const U& x, const T& y) > { return y > x; } > friend bool operator<=(const U& x, const T& y) > { return static_cast<bool>(y > x) || static_cast<bool>(y == x); } > friend bool operator>=(const U& x, const T& y) > { return static_cast<bool>(y < x) || static_cast<bool>(y == x); } >}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct partially_ordered1 : B >{ > friend bool operator>(const T& x, const T& y) > { return y < x; } > friend bool operator<=(const T& x, const T& y) > { return static_cast<bool>(x < y) || static_cast<bool>(x == y); } > friend bool operator>=(const T& x, const T& y) > { return static_cast<bool>(y < x) || static_cast<bool>(x == y); } >}; > > > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct totally_ordered2 > : less_than_comparable2<T, U > , equality_comparable2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct totally_ordered1 > : less_than_comparable1<T > , equality_comparable1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct additive2 > : addable2<T, U > , subtractable2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct additive1 > : addable1<T > , subtractable1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct multiplicative2 > : multipliable2<T, U > , dividable2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct multiplicative1 > : multipliable1<T > , dividable1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct integer_multiplicative2 > : multiplicative2<T, U > , modable2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct integer_multiplicative1 > : multiplicative1<T > , modable1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct arithmetic2 > : additive2<T, U > , multiplicative2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct arithmetic1 > : additive1<T > , multiplicative1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct integer_arithmetic2 > : additive2<T, U > , integer_multiplicative2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct integer_arithmetic1 > : additive1<T > , integer_multiplicative1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct bitwise2 > : xorable2<T, U > , andable2<T, U > , orable2<T, U, B > > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct bitwise1 > : xorable1<T > , andable1<T > , orable1<T, B > > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct unit_steppable > : incrementable<T > , decrementable<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct shiftable2 > : left_shiftable2<T, U > , right_shiftable2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct shiftable1 > : left_shiftable1<T > , right_shiftable1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct ring_operators2 > : additive2<T, U > , subtractable2_left<T, U > , multipliable2<T, U, B > > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct ring_operators1 > : additive1<T > , multipliable1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct ordered_ring_operators2 > : ring_operators2<T, U > , totally_ordered2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct ordered_ring_operators1 > : ring_operators1<T > , totally_ordered1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct field_operators2 > : ring_operators2<T, U > , dividable2<T, U > , dividable2_left<T, U, B > > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct field_operators1 > : ring_operators1<T > , dividable1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct ordered_field_operators2 > : field_operators2<T, U > , totally_ordered2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct ordered_field_operators1 > : field_operators1<T > , totally_ordered1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct euclidian_ring_operators2 > : ring_operators2<T, U > , dividable2<T, U > , dividable2_left<T, U > , modable2<T, U > , modable2_left<T, U, B > > > > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct euclidian_ring_operators1 > : ring_operators1<T > , dividable1<T > , modable1<T, B > > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct ordered_euclidian_ring_operators2 > : totally_ordered2<T, U > , euclidian_ring_operators2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct ordered_euclidian_ring_operators1 > : totally_ordered1<T > , euclidian_ring_operators1<T, B > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct euclidean_ring_operators2 > : ring_operators2<T, U > , dividable2<T, U > , dividable2_left<T, U > , modable2<T, U > , modable2_left<T, U, B > > > > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct euclidean_ring_operators1 > : ring_operators1<T > , dividable1<T > , modable1<T, B > > > > {}; > >template <class T, class U, class B = ::boost::detail::empty_base<T> > >struct ordered_euclidean_ring_operators2 > : totally_ordered2<T, U > , euclidean_ring_operators2<T, U, B > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct ordered_euclidean_ring_operators1 > : totally_ordered1<T > , euclidean_ring_operators1<T, B > > > {}; > >template <class T, class P, class B = ::boost::detail::empty_base<T> > >struct input_iteratable > : equality_comparable1<T > , incrementable<T > , dereferenceable<T, P, B > > > > {}; > >template <class T, class B = ::boost::detail::empty_base<T> > >struct output_iteratable > : incrementable<T, B > > {}; > >template <class T, class P, class B = ::boost::detail::empty_base<T> > >struct forward_iteratable > : input_iteratable<T, P, B > > {}; > >template <class T, class P, class B = ::boost::detail::empty_base<T> > >struct bidirectional_iteratable > : forward_iteratable<T, P > , decrementable<T, B > > > {}; > > > > > >template <class T, class P, class D, class R, class B = ::boost::detail::empty_base<T> > >struct random_access_iteratable > : bidirectional_iteratable<T, P > , less_than_comparable1<T > , additive2<T, D > , indexable<T, D, R, B > > > > > {}; > > >} ># 720 "/usr/include/boost/operators.hpp" 3 4 >namespace boost { > > >namespace detail { > struct true_t {}; > struct false_t {}; >} > > > > >template<class T> struct is_chained_base { > typedef ::boost::detail::false_t value; >}; > >} ># 831 "/usr/include/boost/operators.hpp" 3 4 >namespace boost { > >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct less_than_comparable : less_than_comparable2<T, U, B> {}; template<class T, class U, class B> struct less_than_comparable<T, U, B, ::boost::detail::true_t> : less_than_comparable1<T, U> {}; template <class T, class B> struct less_than_comparable<T, T, B, ::boost::detail::false_t> : less_than_comparable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::less_than_comparable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::less_than_comparable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::less_than_comparable1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct equality_comparable : equality_comparable2<T, U, B> {}; template<class T, class U, class B> struct equality_comparable<T, U, B, ::boost::detail::true_t> : equality_comparable1<T, U> {}; template <class T, class B> struct equality_comparable<T, T, B, ::boost::detail::false_t> : equality_comparable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::equality_comparable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::equality_comparable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::equality_comparable1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct multipliable : multipliable2<T, U, B> {}; template<class T, class U, class B> struct multipliable<T, U, B, ::boost::detail::true_t> : multipliable1<T, U> {}; template <class T, class B> struct multipliable<T, T, B, ::boost::detail::false_t> : multipliable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::multipliable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::multipliable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::multipliable1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct addable : addable2<T, U, B> {}; template<class T, class U, class B> struct addable<T, U, B, ::boost::detail::true_t> : addable1<T, U> {}; template <class T, class B> struct addable<T, T, B, ::boost::detail::false_t> : addable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::addable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::addable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::addable1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct subtractable : subtractable2<T, U, B> {}; template<class T, class U, class B> struct subtractable<T, U, B, ::boost::detail::true_t> : subtractable1<T, U> {}; template <class T, class B> struct subtractable<T, T, B, ::boost::detail::false_t> : subtractable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::subtractable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::subtractable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::subtractable1<T, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class U, class B> struct is_chained_base< ::boost::subtractable2_left<T, U, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct dividable : dividable2<T, U, B> {}; template<class T, class U, class B> struct dividable<T, U, B, ::boost::detail::true_t> : dividable1<T, U> {}; template <class T, class B> struct dividable<T, T, B, ::boost::detail::false_t> : dividable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::dividable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::dividable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::dividable1<T, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class U, class B> struct is_chained_base< ::boost::dividable2_left<T, U, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct modable : modable2<T, U, B> {}; template<class T, class U, class B> struct modable<T, U, B, ::boost::detail::true_t> : modable1<T, U> {}; template <class T, class B> struct modable<T, T, B, ::boost::detail::false_t> : modable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::modable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::modable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::modable1<T, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class U, class B> struct is_chained_base< ::boost::modable2_left<T, U, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct xorable : xorable2<T, U, B> {}; template<class T, class U, class B> struct xorable<T, U, B, ::boost::detail::true_t> : xorable1<T, U> {}; template <class T, class B> struct xorable<T, T, B, ::boost::detail::false_t> : xorable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::xorable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::xorable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::xorable1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct andable : andable2<T, U, B> {}; template<class T, class U, class B> struct andable<T, U, B, ::boost::detail::true_t> : andable1<T, U> {}; template <class T, class B> struct andable<T, T, B, ::boost::detail::false_t> : andable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::andable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::andable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::andable1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct orable : orable2<T, U, B> {}; template<class T, class U, class B> struct orable<T, U, B, ::boost::detail::true_t> : orable1<T, U> {}; template <class T, class B> struct orable<T, T, B, ::boost::detail::false_t> : orable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::orable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::orable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::orable1<T, B> > { typedef ::boost::detail::true_t value; }; > > template<class T, class B> struct is_chained_base< ::boost::incrementable<T, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class B> struct is_chained_base< ::boost::decrementable<T, B> > { typedef ::boost::detail::true_t value; }; > > template<class T, class U, class B> struct is_chained_base< ::boost::dereferenceable<T, U, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class U, class V, class B> struct is_chained_base< ::boost::indexable<T, U, V, B> > { typedef ::boost::detail::true_t value; }; > >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct left_shiftable : left_shiftable2<T, U, B> {}; template<class T, class U, class B> struct left_shiftable<T, U, B, ::boost::detail::true_t> : left_shiftable1<T, U> {}; template <class T, class B> struct left_shiftable<T, T, B, ::boost::detail::false_t> : left_shiftable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::left_shiftable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::left_shiftable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::left_shiftable1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct right_shiftable : right_shiftable2<T, U, B> {}; template<class T, class U, class B> struct right_shiftable<T, U, B, ::boost::detail::true_t> : right_shiftable1<T, U> {}; template <class T, class B> struct right_shiftable<T, T, B, ::boost::detail::false_t> : right_shiftable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::right_shiftable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::right_shiftable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::right_shiftable1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct equivalent : equivalent2<T, U, B> {}; template<class T, class U, class B> struct equivalent<T, U, B, ::boost::detail::true_t> : equivalent1<T, U> {}; template <class T, class B> struct equivalent<T, T, B, ::boost::detail::false_t> : equivalent1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::equivalent<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::equivalent2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::equivalent1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct partially_ordered : partially_ordered2<T, U, B> {}; template<class T, class U, class B> struct partially_ordered<T, U, B, ::boost::detail::true_t> : partially_ordered1<T, U> {}; template <class T, class B> struct partially_ordered<T, T, B, ::boost::detail::false_t> : partially_ordered1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::partially_ordered<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::partially_ordered2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::partially_ordered1<T, B> > { typedef ::boost::detail::true_t value; }; > >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct totally_ordered : totally_ordered2<T, U, B> {}; template<class T, class U, class B> struct totally_ordered<T, U, B, ::boost::detail::true_t> : totally_ordered1<T, U> {}; template <class T, class B> struct totally_ordered<T, T, B, ::boost::detail::false_t> : totally_ordered1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::totally_ordered<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::totally_ordered2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::totally_ordered1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct additive : additive2<T, U, B> {}; template<class T, class U, class B> struct additive<T, U, B, ::boost::detail::true_t> : additive1<T, U> {}; template <class T, class B> struct additive<T, T, B, ::boost::detail::false_t> : additive1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::additive<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::additive2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::additive1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct multiplicative : multiplicative2<T, U, B> {}; template<class T, class U, class B> struct multiplicative<T, U, B, ::boost::detail::true_t> : multiplicative1<T, U> {}; template <class T, class B> struct multiplicative<T, T, B, ::boost::detail::false_t> : multiplicative1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::multiplicative<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::multiplicative2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::multiplicative1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct integer_multiplicative : integer_multiplicative2<T, U, B> {}; template<class T, class U, class B> struct integer_multiplicative<T, U, B, ::boost::detail::true_t> : integer_multiplicative1<T, U> {}; template <class T, class B> struct integer_multiplicative<T, T, B, ::boost::detail::false_t> : integer_multiplicative1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::integer_multiplicative<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::integer_multiplicative2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::integer_multiplicative1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct arithmetic : arithmetic2<T, U, B> {}; template<class T, class U, class B> struct arithmetic<T, U, B, ::boost::detail::true_t> : arithmetic1<T, U> {}; template <class T, class B> struct arithmetic<T, T, B, ::boost::detail::false_t> : arithmetic1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::arithmetic<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::arithmetic2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::arithmetic1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct integer_arithmetic : integer_arithmetic2<T, U, B> {}; template<class T, class U, class B> struct integer_arithmetic<T, U, B, ::boost::detail::true_t> : integer_arithmetic1<T, U> {}; template <class T, class B> struct integer_arithmetic<T, T, B, ::boost::detail::false_t> : integer_arithmetic1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::integer_arithmetic<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::integer_arithmetic2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::integer_arithmetic1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct bitwise : bitwise2<T, U, B> {}; template<class T, class U, class B> struct bitwise<T, U, B, ::boost::detail::true_t> : bitwise1<T, U> {}; template <class T, class B> struct bitwise<T, T, B, ::boost::detail::false_t> : bitwise1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::bitwise<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::bitwise2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::bitwise1<T, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class B> struct is_chained_base< ::boost::unit_steppable<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct shiftable : shiftable2<T, U, B> {}; template<class T, class U, class B> struct shiftable<T, U, B, ::boost::detail::true_t> : shiftable1<T, U> {}; template <class T, class B> struct shiftable<T, T, B, ::boost::detail::false_t> : shiftable1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::shiftable<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::shiftable2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::shiftable1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct ring_operators : ring_operators2<T, U, B> {}; template<class T, class U, class B> struct ring_operators<T, U, B, ::boost::detail::true_t> : ring_operators1<T, U> {}; template <class T, class B> struct ring_operators<T, T, B, ::boost::detail::false_t> : ring_operators1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::ring_operators<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::ring_operators2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::ring_operators1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct ordered_ring_operators : ordered_ring_operators2<T, U, B> {}; template<class T, class U, class B> struct ordered_ring_operators<T, U, B, ::boost::detail::true_t> : ordered_ring_operators1<T, U> {}; template <class T, class B> struct ordered_ring_operators<T, T, B, ::boost::detail::false_t> : ordered_ring_operators1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::ordered_ring_operators<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::ordered_ring_operators2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::ordered_ring_operators1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct field_operators : field_operators2<T, U, B> {}; template<class T, class U, class B> struct field_operators<T, U, B, ::boost::detail::true_t> : field_operators1<T, U> {}; template <class T, class B> struct field_operators<T, T, B, ::boost::detail::false_t> : field_operators1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::field_operators<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::field_operators2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::field_operators1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct ordered_field_operators : ordered_field_operators2<T, U, B> {}; template<class T, class U, class B> struct ordered_field_operators<T, U, B, ::boost::detail::true_t> : ordered_field_operators1<T, U> {}; template <class T, class B> struct ordered_field_operators<T, T, B, ::boost::detail::false_t> : ordered_field_operators1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::ordered_field_operators<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::ordered_field_operators2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::ordered_field_operators1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct euclidian_ring_operators : euclidian_ring_operators2<T, U, B> {}; template<class T, class U, class B> struct euclidian_ring_operators<T, U, B, ::boost::detail::true_t> : euclidian_ring_operators1<T, U> {}; template <class T, class B> struct euclidian_ring_operators<T, T, B, ::boost::detail::false_t> : euclidian_ring_operators1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::euclidian_ring_operators<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::euclidian_ring_operators2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::euclidian_ring_operators1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct ordered_euclidian_ring_operators : ordered_euclidian_ring_operators2<T, U, B> {}; template<class T, class U, class B> struct ordered_euclidian_ring_operators<T, U, B, ::boost::detail::true_t> : ordered_euclidian_ring_operators1<T, U> {}; template <class T, class B> struct ordered_euclidian_ring_operators<T, T, B, ::boost::detail::false_t> : ordered_euclidian_ring_operators1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::ordered_euclidian_ring_operators<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::ordered_euclidian_ring_operators2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::ordered_euclidian_ring_operators1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct euclidean_ring_operators : euclidean_ring_operators2<T, U, B> {}; template<class T, class U, class B> struct euclidean_ring_operators<T, U, B, ::boost::detail::true_t> : euclidean_ring_operators1<T, U> {}; template <class T, class B> struct euclidean_ring_operators<T, T, B, ::boost::detail::false_t> : euclidean_ring_operators1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::euclidean_ring_operators<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::euclidean_ring_operators2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::euclidean_ring_operators1<T, B> > { typedef ::boost::detail::true_t value; }; >template <class T ,class U = T ,class B = ::boost::detail::empty_base<T> ,class O = typename is_chained_base<U>::value > struct ordered_euclidean_ring_operators : ordered_euclidean_ring_operators2<T, U, B> {}; template<class T, class U, class B> struct ordered_euclidean_ring_operators<T, U, B, ::boost::detail::true_t> : ordered_euclidean_ring_operators1<T, U> {}; template <class T, class B> struct ordered_euclidean_ring_operators<T, T, B, ::boost::detail::false_t> : ordered_euclidean_ring_operators1<T, B> {}; template<class T, class U, class B, class O> struct is_chained_base< ::boost::ordered_euclidean_ring_operators<T, U, B, O> > { typedef ::boost::detail::true_t value; }; template<class T, class U, class B> struct is_chained_base< ::boost::ordered_euclidean_ring_operators2<T, U, B> > { typedef ::boost::detail::true_t value; }; template<class T, class B> struct is_chained_base< ::boost::ordered_euclidean_ring_operators1<T, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class U, class B> struct is_chained_base< ::boost::input_iteratable<T, U, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class B> struct is_chained_base< ::boost::output_iteratable<T, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class U, class B> struct is_chained_base< ::boost::forward_iteratable<T, U, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class U, class B> struct is_chained_base< ::boost::bidirectional_iteratable<T, U, B> > { typedef ::boost::detail::true_t value; }; > template<class T, class U, class V, class W, class B> struct is_chained_base< ::boost::random_access_iteratable<T, U, V, W, B> > { typedef ::boost::detail::true_t value; }; ># 893 "/usr/include/boost/operators.hpp" 3 4 >template <class T, class U> >struct operators2 > : totally_ordered2<T,U > , integer_arithmetic2<T,U > , bitwise2<T,U > > > > {}; > > >template <class T, class U = T> >struct operators : operators2<T, U> {}; > >template <class T> struct operators<T, T> > > > > : totally_ordered<T > , integer_arithmetic<T > , bitwise<T > , unit_steppable<T > > > > > {}; > > > > >template <class T, > class V, > class D = std::ptrdiff_t, > class P = V const *, > class R = V const &> >struct input_iterator_helper > : input_iteratable<T, P > , boost::iterator<std::input_iterator_tag, V, D, P, R > > > {}; > >template<class T> >struct output_iterator_helper > : output_iteratable<T > , boost::iterator<std::output_iterator_tag, void, void, void, void > > > >{ > T& operator*() { return static_cast<T&>(*this); } > T& operator++() { return static_cast<T&>(*this); } >}; > >template <class T, > class V, > class D = std::ptrdiff_t, > class P = V*, > class R = V&> >struct forward_iterator_helper > : forward_iteratable<T, P > , boost::iterator<std::forward_iterator_tag, V, D, P, R > > > {}; > >template <class T, > class V, > class D = std::ptrdiff_t, > class P = V*, > class R = V&> >struct bidirectional_iterator_helper > : bidirectional_iteratable<T, P > , boost::iterator<std::bidirectional_iterator_tag, V, D, P, R > > > {}; > >template <class T, > class V, > class D = std::ptrdiff_t, > class P = V*, > class R = V&> >struct random_access_iterator_helper > : random_access_iteratable<T, P, D, R > , boost::iterator<std::random_access_iterator_tag, V, D, P, R > > > >{ > friend D requires_difference_operator(const T& x, const T& y) { > return x - y; > } >}; > >} ># 18 "/usr/include/boost/system/error_code.hpp" 2 3 4 > ># 1 "/usr/include/boost/utility/enable_if.hpp" 1 3 4 ># 24 "/usr/include/boost/utility/enable_if.hpp" 3 4 >namespace boost >{ > > template <bool B, class T = void> > struct enable_if_c { > typedef T type; > }; > > template <class T> > struct enable_if_c<false, T> {}; > > template <class Cond, class T = void> > struct enable_if : public enable_if_c<Cond::value, T> {}; > > template <bool B, class T> > struct lazy_enable_if_c { > typedef typename T::type type; > }; > > template <class T> > struct lazy_enable_if_c<false, T> {}; > > template <class Cond, class T> > struct lazy_enable_if : public lazy_enable_if_c<Cond::value, T> {}; > > > template <bool B, class T = void> > struct disable_if_c { > typedef T type; > }; > > template <class T> > struct disable_if_c<true, T> {}; > > template <class Cond, class T = void> > struct disable_if : public disable_if_c<Cond::value, T> {}; > > template <bool B, class T> > struct lazy_disable_if_c { > typedef typename T::type type; > }; > > template <class T> > struct lazy_disable_if_c<true, T> {}; > > template <class Cond, class T> > struct lazy_disable_if : public lazy_disable_if_c<Cond::value, T> {}; > >} ># 20 "/usr/include/boost/system/error_code.hpp" 2 3 4 > > > ># 1 "/usr/include/c++/4.9.0/functional" 1 3 4 ># 46 "/usr/include/c++/4.9.0/functional" 3 4 ># 47 "/usr/include/c++/4.9.0/functional" 3 > > > > > > ># 1 "/usr/include/c++/4.9.0/typeinfo" 1 3 ># 32 "/usr/include/c++/4.9.0/typeinfo" 3 ># 33 "/usr/include/c++/4.9.0/typeinfo" 3 > > > > > > >#pragma GCC visibility push(default) > >extern "C++" { > >namespace __cxxabiv1 >{ > class __class_type_info; >} ># 80 "/usr/include/c++/4.9.0/typeinfo" 3 >namespace std >{ > > > > > > > class type_info > { > public: > > > > > virtual ~type_info(); > > > > const char* name() const noexcept > { return __name[0] == '*' ? __name + 1 : __name; } ># 115 "/usr/include/c++/4.9.0/typeinfo" 3 > bool before(const type_info& __arg) const noexcept > { return (__name[0] == '*' && __arg.__name[0] == '*') > ? __name < __arg.__name > : __builtin_strcmp (__name, __arg.__name) < 0; } > > bool operator==(const type_info& __arg) const noexcept > { > return ((__name == __arg.__name) > || (__name[0] != '*' && > __builtin_strcmp (__name, __arg.__name) == 0)); > } ># 136 "/usr/include/c++/4.9.0/typeinfo" 3 > bool operator!=(const type_info& __arg) const noexcept > { return !operator==(__arg); } > > > size_t hash_code() const noexcept > { > > return _Hash_bytes(name(), __builtin_strlen(name()), > static_cast<size_t>(0xc70f6907UL)); > > > > } > > > > virtual bool __is_pointer_p() const; > > > virtual bool __is_function_p() const; > > > > > > > > virtual bool __do_catch(const type_info *__thr_type, void **__thr_obj, > unsigned __outer) const; > > > virtual bool __do_upcast(const __cxxabiv1::__class_type_info *__target, > void **__obj_ptr) const; > > protected: > const char *__name; > > explicit type_info(const char *__n): __name(__n) { } > > private: > > type_info& operator=(const type_info&); > type_info(const type_info&); > }; > > > > > > > > class bad_cast : public exception > { > public: > bad_cast() noexcept { } > > > > virtual ~bad_cast() noexcept; > > > virtual const char* what() const noexcept; > }; > > > > > > class bad_typeid : public exception > { > public: > bad_typeid () noexcept { } > > > > virtual ~bad_typeid() noexcept; > > > virtual const char* what() const noexcept; > }; >} > >} > >#pragma GCC visibility pop ># 54 "/usr/include/c++/4.9.0/functional" 2 3 > > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _MemberPointer> > class _Mem_fn; > template<typename _Tp, typename _Class> > _Mem_fn<_Tp _Class::*> > mem_fn(_Tp _Class::*) noexcept; > >template<typename _Tp> class __has_result_type_helper { template<typename _Up> struct _Wrap_type { }; template<typename _Up> static true_type __test(_Wrap_type<typename _Up::result_type>*); template<typename _Up> static false_type __test(...); public: typedef decltype(__test<_Tp>(0)) type; }; template<typename _Tp> struct __has_result_type : public __has_result_type_helper <typename remove_cv<_Tp>::type>::type { }; > > > template<bool _Has_result_type, typename _Functor> > struct _Maybe_get_result_type > { }; > > template<typename _Functor> > struct _Maybe_get_result_type<true, _Functor> > { typedef typename _Functor::result_type result_type; }; > > > > > > template<typename _Functor> > struct _Weak_result_type_impl > : _Maybe_get_result_type<__has_result_type<_Functor>::value, _Functor> > { }; > > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(_ArgTypes...)> > { typedef _Res result_type; }; > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(_ArgTypes......)> > { typedef _Res result_type; }; > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(_ArgTypes...) const> > { typedef _Res result_type; }; > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(_ArgTypes......) const> > { typedef _Res result_type; }; > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(_ArgTypes...) volatile> > { typedef _Res result_type; }; > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(_ArgTypes......) volatile> > { typedef _Res result_type; }; > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(_ArgTypes...) const volatile> > { typedef _Res result_type; }; > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(_ArgTypes......) const volatile> > { typedef _Res result_type; }; > > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(&)(_ArgTypes...)> > { typedef _Res result_type; }; > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(&)(_ArgTypes......)> > { typedef _Res result_type; }; > > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(*)(_ArgTypes...)> > { typedef _Res result_type; }; > > template<typename _Res, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res(*)(_ArgTypes......)> > { typedef _Res result_type; }; > > > template<typename _Res, typename _Class, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes...)> > { typedef _Res result_type; }; > > template<typename _Res, typename _Class, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes......)> > { typedef _Res result_type; }; > > > template<typename _Res, typename _Class, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes...) const> > { typedef _Res result_type; }; > > template<typename _Res, typename _Class, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes......) const> > { typedef _Res result_type; }; > > > template<typename _Res, typename _Class, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes...) volatile> > { typedef _Res result_type; }; > > template<typename _Res, typename _Class, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes......) volatile> > { typedef _Res result_type; }; > > > template<typename _Res, typename _Class, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes...) > const volatile> > { typedef _Res result_type; }; > > template<typename _Res, typename _Class, typename... _ArgTypes> > struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes......) > const volatile> > { typedef _Res result_type; }; > > > > > > template<typename _Functor> > struct _Weak_result_type > : _Weak_result_type_impl<typename remove_cv<_Functor>::type> > { }; > > > > > > template<typename _Functor, typename... _Args> > inline > typename enable_if< > (!is_member_pointer<_Functor>::value > && !is_function<_Functor>::value > && !is_function<typename remove_pointer<_Functor>::type>::value), > typename result_of<_Functor&(_Args&&...)>::type > >::type > __invoke(_Functor& __f, _Args&&... __args) > { > return __f(std::forward<_Args>(__args)...); > } > > template<typename _Functor, typename... _Args> > inline > typename enable_if< > (is_member_pointer<_Functor>::value > && !is_function<_Functor>::value > && !is_function<typename remove_pointer<_Functor>::type>::value), > typename result_of<_Functor(_Args&&...)>::type > >::type > __invoke(_Functor& __f, _Args&&... __args) > { > return std::mem_fn(__f)(std::forward<_Args>(__args)...); > } > > > template<typename _Functor, typename... _Args> > inline > typename enable_if< > (is_pointer<_Functor>::value > && is_function<typename remove_pointer<_Functor>::type>::value), > typename result_of<_Functor(_Args&&...)>::type > >::type > __invoke(_Functor __f, _Args&&... __args) > { > return __f(std::forward<_Args>(__args)...); > } > > > > > > > template<bool _Unary, bool _Binary, typename _Tp> > struct _Reference_wrapper_base_impl; > > > template<typename _Tp> > struct _Reference_wrapper_base_impl<false, false, _Tp> > : _Weak_result_type<_Tp> > { }; > > > template<typename _Tp> > struct _Reference_wrapper_base_impl<true, false, _Tp> > : _Weak_result_type<_Tp> > { > typedef typename _Tp::argument_type argument_type; > }; > > > template<typename _Tp> > struct _Reference_wrapper_base_impl<false, true, _Tp> > : _Weak_result_type<_Tp> > { > typedef typename _Tp::first_argument_type first_argument_type; > typedef typename _Tp::second_argument_type second_argument_type; > }; > > > template<typename _Tp> > struct _Reference_wrapper_base_impl<true, true, _Tp> > : _Weak_result_type<_Tp> > { > typedef typename _Tp::argument_type argument_type; > typedef typename _Tp::first_argument_type first_argument_type; > typedef typename _Tp::second_argument_type second_argument_type; > }; > > template<typename _Tp> class __has_argument_type_helper { template<typename _Up> struct _Wrap_type { }; template<typename _Up> static true_type __test(_Wrap_type<typename _Up::argument_type>*); template<typename _Up> static false_type __test(...); public: typedef decltype(__test<_Tp>(0)) type; }; template<typename _Tp> struct __has_argument_type : public __has_argument_type_helper <typename remove_cv<_Tp>::type>::type { }; > template<typename _Tp> class __has_first_argument_type_helper { template<typename _Up> struct _Wrap_type { }; template<typename _Up> static true_type __test(_Wrap_type<typename _Up::first_argument_type>*); template<typename _Up> static false_type __test(...); public: typedef decltype(__test<_Tp>(0)) type; }; template<typename _Tp> struct __has_first_argument_type : public __has_first_argument_type_helper <typename remove_cv<_Tp>::type>::type { }; > template<typename _Tp> class __has_second_argument_type_helper { template<typename _Up> struct _Wrap_type { }; template<typename _Up> static true_type __test(_Wrap_type<typename _Up::second_argument_type>*); template<typename _Up> static false_type __test(...); public: typedef decltype(__test<_Tp>(0)) type; }; template<typename _Tp> struct __has_second_argument_type : public __has_second_argument_type_helper <typename remove_cv<_Tp>::type>::type { }; > > > > > > > > template<typename _Tp> > struct _Reference_wrapper_base > : _Reference_wrapper_base_impl< > __has_argument_type<_Tp>::value, > __has_first_argument_type<_Tp>::value > && __has_second_argument_type<_Tp>::value, > _Tp> > { }; > > > template<typename _Res, typename _T1> > struct _Reference_wrapper_base<_Res(_T1)> > : unary_function<_T1, _Res> > { }; > > template<typename _Res, typename _T1> > struct _Reference_wrapper_base<_Res(_T1) const> > : unary_function<_T1, _Res> > { }; > > template<typename _Res, typename _T1> > struct _Reference_wrapper_base<_Res(_T1) volatile> > : unary_function<_T1, _Res> > { }; > > template<typename _Res, typename _T1> > struct _Reference_wrapper_base<_Res(_T1) const volatile> > : unary_function<_T1, _Res> > { }; > > > template<typename _Res, typename _T1, typename _T2> > struct _Reference_wrapper_base<_Res(_T1, _T2)> > : binary_function<_T1, _T2, _Res> > { }; > > template<typename _Res, typename _T1, typename _T2> > struct _Reference_wrapper_base<_Res(_T1, _T2) const> > : binary_function<_T1, _T2, _Res> > { }; > > template<typename _Res, typename _T1, typename _T2> > struct _Reference_wrapper_base<_Res(_T1, _T2) volatile> > : binary_function<_T1, _T2, _Res> > { }; > > template<typename _Res, typename _T1, typename _T2> > struct _Reference_wrapper_base<_Res(_T1, _T2) const volatile> > : binary_function<_T1, _T2, _Res> > { }; > > > template<typename _Res, typename _T1> > struct _Reference_wrapper_base<_Res(*)(_T1)> > : unary_function<_T1, _Res> > { }; > > > template<typename _Res, typename _T1, typename _T2> > struct _Reference_wrapper_base<_Res(*)(_T1, _T2)> > : binary_function<_T1, _T2, _Res> > { }; > > > template<typename _Res, typename _T1> > struct _Reference_wrapper_base<_Res (_T1::*)()> > : unary_function<_T1*, _Res> > { }; > > > template<typename _Res, typename _T1, typename _T2> > struct _Reference_wrapper_base<_Res (_T1::*)(_T2)> > : binary_function<_T1*, _T2, _Res> > { }; > > > template<typename _Res, typename _T1> > struct _Reference_wrapper_base<_Res (_T1::*)() const> > : unary_function<const _T1*, _Res> > { }; > > > template<typename _Res, typename _T1, typename _T2> > struct _Reference_wrapper_base<_Res (_T1::*)(_T2) const> > : binary_function<const _T1*, _T2, _Res> > { }; > > > template<typename _Res, typename _T1> > struct _Reference_wrapper_base<_Res (_T1::*)() volatile> > : unary_function<volatile _T1*, _Res> > { }; > > > template<typename _Res, typename _T1, typename _T2> > struct _Reference_wrapper_base<_Res (_T1::*)(_T2) volatile> > : binary_function<volatile _T1*, _T2, _Res> > { }; > > > template<typename _Res, typename _T1> > struct _Reference_wrapper_base<_Res (_T1::*)() const volatile> > : unary_function<const volatile _T1*, _Res> > { }; > > > template<typename _Res, typename _T1, typename _T2> > struct _Reference_wrapper_base<_Res (_T1::*)(_T2) const volatile> > : binary_function<const volatile _T1*, _T2, _Res> > { }; > > > > > > > template<typename _Tp> > class reference_wrapper > : public _Reference_wrapper_base<typename remove_cv<_Tp>::type> > { > _Tp* _M_data; > > public: > typedef _Tp type; > > reference_wrapper(_Tp& __indata) noexcept > : _M_data(std::__addressof(__indata)) > { } > > reference_wrapper(_Tp&&) = delete; > > reference_wrapper(const reference_wrapper<_Tp>& __inref) noexcept > : _M_data(__inref._M_data) > { } > > reference_wrapper& > operator=(const reference_wrapper<_Tp>& __inref) noexcept > { > _M_data = __inref._M_data; > return *this; > } > > operator _Tp&() const noexcept > { return this->get(); } > > _Tp& > get() const noexcept > { return *_M_data; } > > template<typename... _Args> > typename result_of<_Tp&(_Args&&...)>::type > operator()(_Args&&... __args) const > { > return __invoke(get(), std::forward<_Args>(__args)...); > } > }; > > > > template<typename _Tp> > inline reference_wrapper<_Tp> > ref(_Tp& __t) noexcept > { return reference_wrapper<_Tp>(__t); } > > > template<typename _Tp> > inline reference_wrapper<const _Tp> > cref(const _Tp& __t) noexcept > { return reference_wrapper<const _Tp>(__t); } > > template<typename _Tp> > void ref(const _Tp&&) = delete; > > template<typename _Tp> > void cref(const _Tp&&) = delete; > > > template<typename _Tp> > inline reference_wrapper<_Tp> > ref(reference_wrapper<_Tp> __t) noexcept > { return ref(__t.get()); } > > > template<typename _Tp> > inline reference_wrapper<const _Tp> > cref(reference_wrapper<_Tp> __t) noexcept > { return cref(__t.get()); } > > > > template<typename... _Types> > struct _Pack : integral_constant<size_t, sizeof...(_Types)> > { }; > > template<typename _From, typename _To, bool = _From::value == _To::value> > struct _AllConvertible : false_type > { }; > > template<typename... _From, typename... _To> > struct _AllConvertible<_Pack<_From...>, _Pack<_To...>, true> > : __and_<is_convertible<_From, _To>...> > { }; > > template<typename _Tp1, typename _Tp2> > using _NotSame = __not_<is_same<typename std::decay<_Tp1>::type, > typename std::decay<_Tp2>::type>>; > > > > > > > template<typename _Res, typename... _ArgTypes> > struct _Maybe_unary_or_binary_function { }; > > > template<typename _Res, typename _T1> > struct _Maybe_unary_or_binary_function<_Res, _T1> > : std::unary_function<_T1, _Res> { }; > > > template<typename _Res, typename _T1, typename _T2> > struct _Maybe_unary_or_binary_function<_Res, _T1, _T2> > : std::binary_function<_T1, _T2, _Res> { }; > > > template<typename _Res, typename _Class, typename... _ArgTypes> > class _Mem_fn<_Res (_Class::*)(_ArgTypes...)> > : public _Maybe_unary_or_binary_function<_Res, _Class*, _ArgTypes...> > { > typedef _Res (_Class::*_Functor)(_ArgTypes...); > > template<typename _Tp, typename... _Args> > _Res > _M_call(_Tp&& __object, const volatile _Class *, > _Args&&... __args) const > { > return (std::forward<_Tp>(__object).*__pmf) > (std::forward<_Args>(__args)...); > } > > template<typename _Tp, typename... _Args> > _Res > _M_call(_Tp&& __ptr, const volatile void *, _Args&&... __args) const > { return ((*__ptr).*__pmf)(std::forward<_Args>(__args)...); } > > > template<typename... _Args> > using _RequireValidArgs > = _Require<_AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > > > template<typename _Tp, typename... _Args> > using _RequireValidArgs2 > = _Require<_NotSame<_Class, _Tp>, _NotSame<_Class*, _Tp>, > _AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > > > template<typename _Tp, typename... _Args> > using _RequireValidArgs3 > = _Require<is_base_of<_Class, _Tp>, > _AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > public: > typedef _Res result_type; > > explicit _Mem_fn(_Functor __pmf) : __pmf(__pmf) { } > > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(_Class& __object, _Args&&... __args) const > { return (__object.*__pmf)(std::forward<_Args>(__args)...); } > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(_Class&& __object, _Args&&... __args) const > { > return (std::move(__object).*__pmf)(std::forward<_Args>(__args)...); > } > > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(_Class* __object, _Args&&... __args) const > { return (__object->*__pmf)(std::forward<_Args>(__args)...); } > > > template<typename _Tp, typename... _Args, > typename _Req = _RequireValidArgs2<_Tp, _Args...>> > _Res > operator()(_Tp&& __object, _Args&&... __args) const > { > return _M_call(std::forward<_Tp>(__object), &__object, > std::forward<_Args>(__args)...); > } > > template<typename _Tp, typename... _Args, > typename _Req = _RequireValidArgs3<_Tp, _Args...>> > _Res > operator()(reference_wrapper<_Tp> __ref, _Args&&... __args) const > { return operator()(__ref.get(), std::forward<_Args>(__args)...); } > > private: > _Functor __pmf; > }; > > > template<typename _Res, typename _Class, typename... _ArgTypes> > class _Mem_fn<_Res (_Class::*)(_ArgTypes...) const> > : public _Maybe_unary_or_binary_function<_Res, const _Class*, > _ArgTypes...> > { > typedef _Res (_Class::*_Functor)(_ArgTypes...) const; > > template<typename _Tp, typename... _Args> > _Res > _M_call(_Tp&& __object, const volatile _Class *, > _Args&&... __args) const > { > return (std::forward<_Tp>(__object).*__pmf) > (std::forward<_Args>(__args)...); > } > > template<typename _Tp, typename... _Args> > _Res > _M_call(_Tp&& __ptr, const volatile void *, _Args&&... __args) const > { return ((*__ptr).*__pmf)(std::forward<_Args>(__args)...); } > > template<typename... _Args> > using _RequireValidArgs > = _Require<_AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > template<typename _Tp, typename... _Args> > using _RequireValidArgs2 > = _Require<_NotSame<_Class, _Tp>, _NotSame<const _Class*, _Tp>, > _AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > template<typename _Tp, typename... _Args> > using _RequireValidArgs3 > = _Require<is_base_of<_Class, _Tp>, > _AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > public: > typedef _Res result_type; > > explicit _Mem_fn(_Functor __pmf) : __pmf(__pmf) { } > > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(const _Class& __object, _Args&&... __args) const > { return (__object.*__pmf)(std::forward<_Args>(__args)...); } > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(const _Class&& __object, _Args&&... __args) const > { > return (std::move(__object).*__pmf)(std::forward<_Args>(__args)...); > } > > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(const _Class* __object, _Args&&... __args) const > { return (__object->*__pmf)(std::forward<_Args>(__args)...); } > > > template<typename _Tp, typename... _Args, > typename _Req = _RequireValidArgs2<_Tp, _Args...>> > _Res operator()(_Tp&& __object, _Args&&... __args) const > { > return _M_call(std::forward<_Tp>(__object), &__object, > std::forward<_Args>(__args)...); > } > > template<typename _Tp, typename... _Args, > typename _Req = _RequireValidArgs3<_Tp, _Args...>> > _Res > operator()(reference_wrapper<_Tp> __ref, _Args&&... __args) const > { return operator()(__ref.get(), std::forward<_Args>(__args)...); } > > private: > _Functor __pmf; > }; > > > template<typename _Res, typename _Class, typename... _ArgTypes> > class _Mem_fn<_Res (_Class::*)(_ArgTypes...) volatile> > : public _Maybe_unary_or_binary_function<_Res, volatile _Class*, > _ArgTypes...> > { > typedef _Res (_Class::*_Functor)(_ArgTypes...) volatile; > > template<typename _Tp, typename... _Args> > _Res > _M_call(_Tp&& __object, const volatile _Class *, > _Args&&... __args) const > { > return (std::forward<_Tp>(__object).*__pmf) > (std::forward<_Args>(__args)...); > } > > template<typename _Tp, typename... _Args> > _Res > _M_call(_Tp&& __ptr, const volatile void *, _Args&&... __args) const > { return ((*__ptr).*__pmf)(std::forward<_Args>(__args)...); } > > template<typename... _Args> > using _RequireValidArgs > = _Require<_AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > template<typename _Tp, typename... _Args> > using _RequireValidArgs2 > = _Require<_NotSame<_Class, _Tp>, _NotSame<volatile _Class*, _Tp>, > _AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > template<typename _Tp, typename... _Args> > using _RequireValidArgs3 > = _Require<is_base_of<_Class, _Tp>, > _AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > public: > typedef _Res result_type; > > explicit _Mem_fn(_Functor __pmf) : __pmf(__pmf) { } > > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(volatile _Class& __object, _Args&&... __args) const > { return (__object.*__pmf)(std::forward<_Args>(__args)...); } > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(volatile _Class&& __object, _Args&&... __args) const > { > return (std::move(__object).*__pmf)(std::forward<_Args>(__args)...); > } > > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(volatile _Class* __object, _Args&&... __args) const > { return (__object->*__pmf)(std::forward<_Args>(__args)...); } > > > template<typename _Tp, typename... _Args, > typename _Req = _RequireValidArgs2<_Tp, _Args...>> > _Res > operator()(_Tp&& __object, _Args&&... __args) const > { > return _M_call(std::forward<_Tp>(__object), &__object, > std::forward<_Args>(__args)...); > } > > template<typename _Tp, typename... _Args, > typename _Req = _RequireValidArgs3<_Tp, _Args...>> > _Res > operator()(reference_wrapper<_Tp> __ref, _Args&&... __args) const > { return operator()(__ref.get(), std::forward<_Args>(__args)...); } > > private: > _Functor __pmf; > }; > > > template<typename _Res, typename _Class, typename... _ArgTypes> > class _Mem_fn<_Res (_Class::*)(_ArgTypes...) const volatile> > : public _Maybe_unary_or_binary_function<_Res, const volatile _Class*, > _ArgTypes...> > { > typedef _Res (_Class::*_Functor)(_ArgTypes...) const volatile; > > template<typename _Tp, typename... _Args> > _Res > _M_call(_Tp&& __object, const volatile _Class *, > _Args&&... __args) const > { > return (std::forward<_Tp>(__object).*__pmf) > (std::forward<_Args>(__args)...); > } > > template<typename _Tp, typename... _Args> > _Res > _M_call(_Tp&& __ptr, const volatile void *, _Args&&... __args) const > { return ((*__ptr).*__pmf)(std::forward<_Args>(__args)...); } > > template<typename... _Args> > using _RequireValidArgs > = _Require<_AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > template<typename _Tp, typename... _Args> > using _RequireValidArgs2 > = _Require<_NotSame<_Class, _Tp>, > _NotSame<const volatile _Class*, _Tp>, > _AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > template<typename _Tp, typename... _Args> > using _RequireValidArgs3 > = _Require<is_base_of<_Class, _Tp>, > _AllConvertible<_Pack<_Args...>, _Pack<_ArgTypes...>>>; > > public: > typedef _Res result_type; > > explicit _Mem_fn(_Functor __pmf) : __pmf(__pmf) { } > > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(const volatile _Class& __object, _Args&&... __args) const > { return (__object.*__pmf)(std::forward<_Args>(__args)...); } > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(const volatile _Class&& __object, _Args&&... __args) const > { > return (std::move(__object).*__pmf)(std::forward<_Args>(__args)...); > } > > > template<typename... _Args, typename _Req = _RequireValidArgs<_Args...>> > _Res > operator()(const volatile _Class* __object, _Args&&... __args) const > { return (__object->*__pmf)(std::forward<_Args>(__args)...); } > > > template<typename _Tp, typename... _Args, > typename _Req = _RequireValidArgs2<_Tp, _Args...>> > _Res operator()(_Tp&& __object, _Args&&... __args) const > { > return _M_call(std::forward<_Tp>(__object), &__object, > std::forward<_Args>(__args)...); > } > > template<typename _Tp, typename... _Args, > typename _Req = _RequireValidArgs3<_Tp, _Args...>> > _Res > operator()(reference_wrapper<_Tp> __ref, _Args&&... __args) const > { return operator()(__ref.get(), std::forward<_Args>(__args)...); } > > private: > _Functor __pmf; > }; > > > template<typename _Tp, bool> > struct _Mem_fn_const_or_non > { > typedef const _Tp& type; > }; > > template<typename _Tp> > struct _Mem_fn_const_or_non<_Tp, false> > { > typedef _Tp& type; > }; > > template<typename _Res, typename _Class> > class _Mem_fn<_Res _Class::*> > { > using __pm_type = _Res _Class::*; > > > > > template<typename _Tp> > auto > _M_call(_Tp&& __object, const _Class *) const noexcept > -> decltype(std::forward<_Tp>(__object).*std::declval<__pm_type&>()) > { return std::forward<_Tp>(__object).*__pm; } > > template<typename _Tp, typename _Up> > auto > _M_call(_Tp&& __object, _Up * const *) const noexcept > -> decltype((*std::forward<_Tp>(__object)).*std::declval<__pm_type&>()) > { return (*std::forward<_Tp>(__object)).*__pm; } > > template<typename _Tp> > auto > _M_call(_Tp&& __ptr, const volatile void*) const > noexcept(noexcept((*__ptr).*std::declval<__pm_type&>())) > -> decltype((*__ptr).*std::declval<__pm_type&>()) > { return (*__ptr).*__pm; } > > public: > explicit > _Mem_fn(_Res _Class::*__pm) noexcept : __pm(__pm) { } > > > _Res& > operator()(_Class& __object) const noexcept > { return __object.*__pm; } > > const _Res& > operator()(const _Class& __object) const noexcept > { return __object.*__pm; } > > _Res&& > operator()(_Class&& __object) const noexcept > { return std::forward<_Class>(__object).*__pm; } > > const _Res&& > operator()(const _Class&& __object) const noexcept > { return std::forward<const _Class>(__object).*__pm; } > > > _Res& > operator()(_Class* __object) const noexcept > { return __object->*__pm; } > > const _Res& > operator()(const _Class* __object) const noexcept > { return __object->*__pm; } > > > template<typename _Tp, typename _Req = _Require<_NotSame<_Class*, _Tp>>> > auto > operator()(_Tp&& __unknown) const > noexcept(noexcept(std::declval<_Mem_fn*>()->_M_call > (std::forward<_Tp>(__unknown), &__unknown))) > -> decltype(this->_M_call(std::forward<_Tp>(__unknown), &__unknown)) > { return _M_call(std::forward<_Tp>(__unknown), &__unknown); } > > template<typename _Tp, typename _Req = _Require<is_base_of<_Class, _Tp>>> > auto > operator()(reference_wrapper<_Tp> __ref) const > noexcept(noexcept(std::declval<_Mem_fn&>()(__ref.get()))) > -> decltype((*this)(__ref.get())) > { return (*this)(__ref.get()); } > > private: > _Res _Class::*__pm; > }; ># 927 "/usr/include/c++/4.9.0/functional" 3 > template<typename _Tp, typename _Class> > inline _Mem_fn<_Tp _Class::*> > mem_fn(_Tp _Class::* __pm) noexcept > { > return _Mem_fn<_Tp _Class::*>(__pm); > } > > > > > > > > template<typename _Tp> > struct is_bind_expression > : public false_type { }; > > > > > > > template<typename _Tp> > struct is_placeholder > : public integral_constant<int, 0> > { }; > > > > > template<int _Num> struct _Placeholder { }; > > > > > > > > namespace placeholders > { > > > > > > extern const _Placeholder<1> _1; > extern const _Placeholder<2> _2; > extern const _Placeholder<3> _3; > extern const _Placeholder<4> _4; > extern const _Placeholder<5> _5; > extern const _Placeholder<6> _6; > extern const _Placeholder<7> _7; > extern const _Placeholder<8> _8; > extern const _Placeholder<9> _9; > extern const _Placeholder<10> _10; > extern const _Placeholder<11> _11; > extern const _Placeholder<12> _12; > extern const _Placeholder<13> _13; > extern const _Placeholder<14> _14; > extern const _Placeholder<15> _15; > extern const _Placeholder<16> _16; > extern const _Placeholder<17> _17; > extern const _Placeholder<18> _18; > extern const _Placeholder<19> _19; > extern const _Placeholder<20> _20; > extern const _Placeholder<21> _21; > extern const _Placeholder<22> _22; > extern const _Placeholder<23> _23; > extern const _Placeholder<24> _24; > extern const _Placeholder<25> _25; > extern const _Placeholder<26> _26; > extern const _Placeholder<27> _27; > extern const _Placeholder<28> _28; > extern const _Placeholder<29> _29; > > } ># 1011 "/usr/include/c++/4.9.0/functional" 3 > template<int _Num> > struct is_placeholder<_Placeholder<_Num> > > : public integral_constant<int, _Num> > { }; > > template<int _Num> > struct is_placeholder<const _Placeholder<_Num> > > : public integral_constant<int, _Num> > { }; > > > > > > struct _No_tuple_element; > > > > > > > template<std::size_t __i, typename _Tuple, bool _IsSafe> > struct _Safe_tuple_element_impl > : tuple_element<__i, _Tuple> { }; > > > > > > > template<std::size_t __i, typename _Tuple> > struct _Safe_tuple_element_impl<__i, _Tuple, false> > { > typedef _No_tuple_element type; > }; > > > > > > template<std::size_t __i, typename _Tuple> > struct _Safe_tuple_element > : _Safe_tuple_element_impl<__i, _Tuple, > (__i < tuple_size<_Tuple>::value)> > { }; ># 1068 "/usr/include/c++/4.9.0/functional" 3 > template<typename _Arg, > bool _IsBindExp = is_bind_expression<_Arg>::value, > bool _IsPlaceholder = (is_placeholder<_Arg>::value > 0)> > class _Mu; > > > > > > template<typename _Tp> > class _Mu<reference_wrapper<_Tp>, false, false> > { > public: > typedef _Tp& result_type; > > > > > > template<typename _CVRef, typename _Tuple> > result_type > operator()(_CVRef& __arg, _Tuple&) const volatile > { return __arg.get(); } > }; > > > > > > > template<typename _Arg> > class _Mu<_Arg, true, false> > { > public: > template<typename _CVArg, typename... _Args> > auto > operator()(_CVArg& __arg, > tuple<_Args...>& __tuple) const volatile > -> decltype(__arg(declval<_Args>()...)) > { > > typedef typename _Build_index_tuple<sizeof...(_Args)>::__type > _Indexes; > return this->__call(__arg, __tuple, _Indexes()); > } > > private: > > > template<typename _CVArg, typename... _Args, std::size_t... _Indexes> > auto > __call(_CVArg& __arg, tuple<_Args...>& __tuple, > const _Index_tuple<_Indexes...>&) const volatile > -> decltype(__arg(declval<_Args>()...)) > { > return __arg(std::forward<_Args>(get<_Indexes>(__tuple))...); > } > }; > > > > > > > template<typename _Arg> > class _Mu<_Arg, false, true> > { > public: > template<typename _Signature> class result; > > template<typename _CVMu, typename _CVArg, typename _Tuple> > class result<_CVMu(_CVArg, _Tuple)> > { > > > > typedef typename _Safe_tuple_element<(is_placeholder<_Arg>::value > - 1), _Tuple>::type > __base_type; > > public: > typedef typename add_rvalue_reference<__base_type>::type type; > }; > > template<typename _Tuple> > typename result<_Mu(_Arg, _Tuple)>::type > operator()(const volatile _Arg&, _Tuple& __tuple) const volatile > { > return std::forward<typename result<_Mu(_Arg, _Tuple)>::type>( > ::std::get<(is_placeholder<_Arg>::value - 1)>(__tuple)); > } > }; > > > > > > > template<typename _Arg> > class _Mu<_Arg, false, false> > { > public: > template<typename _Signature> struct result; > > template<typename _CVMu, typename _CVArg, typename _Tuple> > struct result<_CVMu(_CVArg, _Tuple)> > { > typedef typename add_lvalue_reference<_CVArg>::type type; > }; > > > template<typename _CVArg, typename _Tuple> > _CVArg&& > operator()(_CVArg&& __arg, _Tuple&) const volatile > { return std::forward<_CVArg>(__arg); } > }; > > > > > > > template<typename _Tp> > struct _Maybe_wrap_member_pointer > { > typedef _Tp type; > > static const _Tp& > __do_wrap(const _Tp& __x) > { return __x; } > > static _Tp&& > __do_wrap(_Tp&& __x) > { return static_cast<_Tp&&>(__x); } > }; > > > > > > > template<typename _Tp, typename _Class> > struct _Maybe_wrap_member_pointer<_Tp _Class::*> > { > typedef _Mem_fn<_Tp _Class::*> type; > > static type > __do_wrap(_Tp _Class::* __pm) > { return type(__pm); } > }; > > > > > > template<> > struct _Maybe_wrap_member_pointer<void> > { > typedef void type; > }; > > > template<std::size_t _Ind, typename... _Tp> > inline auto > __volget(volatile tuple<_Tp...>& __tuple) > -> typename tuple_element<_Ind, tuple<_Tp...>>::type volatile& > { return std::get<_Ind>(const_cast<tuple<_Tp...>&>(__tuple)); } > > > template<std::size_t _Ind, typename... _Tp> > inline auto > __volget(const volatile tuple<_Tp...>& __tuple) > -> typename tuple_element<_Ind, tuple<_Tp...>>::type const volatile& > { return std::get<_Ind>(const_cast<const tuple<_Tp...>&>(__tuple)); } > > > template<typename _Signature> > struct _Bind; > > template<typename _Functor, typename... _Bound_args> > class _Bind<_Functor(_Bound_args...)> > : public _Weak_result_type<_Functor> > { > typedef _Bind __self_type; > typedef typename _Build_index_tuple<sizeof...(_Bound_args)>::__type > _Bound_indexes; > > _Functor _M_f; > tuple<_Bound_args...> _M_bound_args; > > > template<typename _Result, typename... _Args, std::size_t... _Indexes> > _Result > __call(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>) > { > return _M_f(_Mu<_Bound_args>() > (get<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Result, typename... _Args, std::size_t... _Indexes> > _Result > __call_c(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>) const > { > return _M_f(_Mu<_Bound_args>() > (get<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Result, typename... _Args, std::size_t... _Indexes> > _Result > __call_v(tuple<_Args...>&& __args, > _Index_tuple<_Indexes...>) volatile > { > return _M_f(_Mu<_Bound_args>() > (__volget<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Result, typename... _Args, std::size_t... _Indexes> > _Result > __call_c_v(tuple<_Args...>&& __args, > _Index_tuple<_Indexes...>) const volatile > { > return _M_f(_Mu<_Bound_args>() > (__volget<_Indexes>(_M_bound_args), __args)...); > } > > public: > template<typename... _Args> > explicit _Bind(const _Functor& __f, _Args&&... __args) > : _M_f(__f), _M_bound_args(std::forward<_Args>(__args)...) > { } > > template<typename... _Args> > explicit _Bind(_Functor&& __f, _Args&&... __args) > : _M_f(std::move(__f)), _M_bound_args(std::forward<_Args>(__args)...) > { } > > _Bind(const _Bind&) = default; > > _Bind(_Bind&& __b) > : _M_f(std::move(__b._M_f)), _M_bound_args(std::move(__b._M_bound_args)) > { } > > > template<typename... _Args, typename _Result > = decltype( std::declval<_Functor>()( > _Mu<_Bound_args>()( std::declval<_Bound_args&>(), > std::declval<tuple<_Args...>&>() )... ) )> > _Result > operator()(_Args&&... __args) > { > return this->__call<_Result>( > std::forward_as_tuple(std::forward<_Args>(__args)...), > _Bound_indexes()); > } > > > template<typename... _Args, typename _Result > = decltype( std::declval<typename enable_if<(sizeof...(_Args) >= 0), > typename add_const<_Functor>::type>::type>()( > _Mu<_Bound_args>()( std::declval<const _Bound_args&>(), > std::declval<tuple<_Args...>&>() )... ) )> > _Result > operator()(_Args&&... __args) const > { > return this->__call_c<_Result>( > std::forward_as_tuple(std::forward<_Args>(__args)...), > _Bound_indexes()); > } > > > template<typename... _Args, typename _Result > = decltype( std::declval<typename enable_if<(sizeof...(_Args) >= 0), > typename add_volatile<_Functor>::type>::type>()( > _Mu<_Bound_args>()( std::declval<volatile _Bound_args&>(), > std::declval<tuple<_Args...>&>() )... ) )> > _Result > operator()(_Args&&... __args) volatile > { > return this->__call_v<_Result>( > std::forward_as_tuple(std::forward<_Args>(__args)...), > _Bound_indexes()); > } > > > template<typename... _Args, typename _Result > = decltype( std::declval<typename enable_if<(sizeof...(_Args) >= 0), > typename add_cv<_Functor>::type>::type>()( > _Mu<_Bound_args>()( std::declval<const volatile _Bound_args&>(), > std::declval<tuple<_Args...>&>() )... ) )> > _Result > operator()(_Args&&... __args) const volatile > { > return this->__call_c_v<_Result>( > std::forward_as_tuple(std::forward<_Args>(__args)...), > _Bound_indexes()); > } > }; > > > template<typename _Result, typename _Signature> > struct _Bind_result; > > template<typename _Result, typename _Functor, typename... _Bound_args> > class _Bind_result<_Result, _Functor(_Bound_args...)> > { > typedef _Bind_result __self_type; > typedef typename _Build_index_tuple<sizeof...(_Bound_args)>::__type > _Bound_indexes; > > _Functor _M_f; > tuple<_Bound_args...> _M_bound_args; > > > template<typename _Res> > struct __enable_if_void : enable_if<is_void<_Res>::value, int> { }; > template<typename _Res> > struct __disable_if_void : enable_if<!is_void<_Res>::value, int> { }; > > > template<typename _Res, typename... _Args, std::size_t... _Indexes> > _Result > __call(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>, > typename __disable_if_void<_Res>::type = 0) > { > return _M_f(_Mu<_Bound_args>() > (get<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Res, typename... _Args, std::size_t... _Indexes> > void > __call(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>, > typename __enable_if_void<_Res>::type = 0) > { > _M_f(_Mu<_Bound_args>() > (get<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Res, typename... _Args, std::size_t... _Indexes> > _Result > __call(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>, > typename __disable_if_void<_Res>::type = 0) const > { > return _M_f(_Mu<_Bound_args>() > (get<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Res, typename... _Args, std::size_t... _Indexes> > void > __call(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>, > typename __enable_if_void<_Res>::type = 0) const > { > _M_f(_Mu<_Bound_args>() > (get<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Res, typename... _Args, std::size_t... _Indexes> > _Result > __call(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>, > typename __disable_if_void<_Res>::type = 0) volatile > { > return _M_f(_Mu<_Bound_args>() > (__volget<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Res, typename... _Args, std::size_t... _Indexes> > void > __call(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>, > typename __enable_if_void<_Res>::type = 0) volatile > { > _M_f(_Mu<_Bound_args>() > (__volget<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Res, typename... _Args, std::size_t... _Indexes> > _Result > __call(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>, > typename __disable_if_void<_Res>::type = 0) const volatile > { > return _M_f(_Mu<_Bound_args>() > (__volget<_Indexes>(_M_bound_args), __args)...); > } > > > template<typename _Res, typename... _Args, std::size_t... _Indexes> > void > __call(tuple<_Args...>&& __args, > _Index_tuple<_Indexes...>, > typename __enable_if_void<_Res>::type = 0) const volatile > { > _M_f(_Mu<_Bound_args>() > (__volget<_Indexes>(_M_bound_args), __args)...); > } > > public: > typedef _Result result_type; > > template<typename... _Args> > explicit _Bind_result(const _Functor& __f, _Args&&... __args) > : _M_f(__f), _M_bound_args(std::forward<_Args>(__args)...) > { } > > template<typename... _Args> > explicit _Bind_result(_Functor&& __f, _Args&&... __args) > : _M_f(std::move(__f)), _M_bound_args(std::forward<_Args>(__args)...) > { } > > _Bind_result(const _Bind_result&) = default; > > _Bind_result(_Bind_result&& __b) > : _M_f(std::move(__b._M_f)), _M_bound_args(std::move(__b._M_bound_args)) > { } > > > template<typename... _Args> > result_type > operator()(_Args&&... __args) > { > return this->__call<_Result>( > std::forward_as_tuple(std::forward<_Args>(__args)...), > _Bound_indexes()); > } > > > template<typename... _Args> > result_type > operator()(_Args&&... __args) const > { > return this->__call<_Result>( > std::forward_as_tuple(std::forward<_Args>(__args)...), > _Bound_indexes()); > } > > > template<typename... _Args> > result_type > operator()(_Args&&... __args) volatile > { > return this->__call<_Result>( > std::forward_as_tuple(std::forward<_Args>(__args)...), > _Bound_indexes()); > } > > > template<typename... _Args> > result_type > operator()(_Args&&... __args) const volatile > { > return this->__call<_Result>( > std::forward_as_tuple(std::forward<_Args>(__args)...), > _Bound_indexes()); > } > }; > > > > > > template<typename _Signature> > struct is_bind_expression<_Bind<_Signature> > > : public true_type { }; > > > > > > template<typename _Signature> > struct is_bind_expression<const _Bind<_Signature> > > : public true_type { }; > > > > > > template<typename _Signature> > struct is_bind_expression<volatile _Bind<_Signature> > > : public true_type { }; > > > > > > template<typename _Signature> > struct is_bind_expression<const volatile _Bind<_Signature>> > : public true_type { }; > > > > > > template<typename _Result, typename _Signature> > struct is_bind_expression<_Bind_result<_Result, _Signature>> > : public true_type { }; > > > > > > template<typename _Result, typename _Signature> > struct is_bind_expression<const _Bind_result<_Result, _Signature>> > : public true_type { }; > > > > > > template<typename _Result, typename _Signature> > struct is_bind_expression<volatile _Bind_result<_Result, _Signature>> > : public true_type { }; > > > > > > template<typename _Result, typename _Signature> > struct is_bind_expression<const volatile _Bind_result<_Result, _Signature>> > : public true_type { }; > > > > > template<typename _Tp, typename _Tp2 = typename decay<_Tp>::type> > using __is_socketlike = __or_<is_integral<_Tp2>, is_enum<_Tp2>>; > > template<bool _SocketLike, typename _Func, typename... _BoundArgs> > struct _Bind_helper > { > typedef _Maybe_wrap_member_pointer<typename decay<_Func>::type> > __maybe_type; > typedef typename __maybe_type::type __func_type; > typedef _Bind<__func_type(typename decay<_BoundArgs>::type...)> type; > }; > > > > > template<typename _Func, typename... _BoundArgs> > struct _Bind_helper<true, _Func, _BoundArgs...> > { }; > > > > > > template<typename _Func, typename... _BoundArgs> > inline typename > _Bind_helper<__is_socketlike<_Func>::value, _Func, _BoundArgs...>::type > bind(_Func&& __f, _BoundArgs&&... __args) > { > typedef _Bind_helper<false, _Func, _BoundArgs...> __helper_type; > typedef typename __helper_type::__maybe_type __maybe_type; > typedef typename __helper_type::type __result_type; > return __result_type(__maybe_type::__do_wrap(std::forward<_Func>(__f)), > std::forward<_BoundArgs>(__args)...); > } > > template<typename _Result, typename _Func, typename... _BoundArgs> > struct _Bindres_helper > { > typedef _Maybe_wrap_member_pointer<typename decay<_Func>::type> > __maybe_type; > typedef typename __maybe_type::type __functor_type; > typedef _Bind_result<_Result, > __functor_type(typename decay<_BoundArgs>::type...)> > type; > }; > > > > > > template<typename _Result, typename _Func, typename... _BoundArgs> > inline > typename _Bindres_helper<_Result, _Func, _BoundArgs...>::type > bind(_Func&& __f, _BoundArgs&&... __args) > { > typedef _Bindres_helper<_Result, _Func, _BoundArgs...> __helper_type; > typedef typename __helper_type::__maybe_type __maybe_type; > typedef typename __helper_type::type __result_type; > return __result_type(__maybe_type::__do_wrap(std::forward<_Func>(__f)), > std::forward<_BoundArgs>(__args)...); > } > > template<typename _Signature> > struct _Bind_simple; > > template<typename _Callable, typename... _Args> > struct _Bind_simple<_Callable(_Args...)> > { > typedef typename result_of<_Callable(_Args...)>::type result_type; > > template<typename... _Args2, typename = typename > enable_if< sizeof...(_Args) == sizeof...(_Args2)>::type> > explicit > _Bind_simple(const _Callable& __callable, _Args2&&... __args) > : _M_bound(__callable, std::forward<_Args2>(__args)...) > { } > > template<typename... _Args2, typename = typename > enable_if< sizeof...(_Args) == sizeof...(_Args2)>::type> > explicit > _Bind_simple(_Callable&& __callable, _Args2&&... __args) > : _M_bound(std::move(__callable), std::forward<_Args2>(__args)...) > { } > > _Bind_simple(const _Bind_simple&) = default; > _Bind_simple(_Bind_simple&&) = default; > > result_type > operator()() > { > typedef typename _Build_index_tuple<sizeof...(_Args)>::__type _Indices; > return _M_invoke(_Indices()); > } > > private: > > template<std::size_t... _Indices> > typename result_of<_Callable(_Args...)>::type > _M_invoke(_Index_tuple<_Indices...>) > { > > > return std::forward<_Callable>(std::get<0>(_M_bound))( > std::forward<_Args>(std::get<_Indices+1>(_M_bound))...); > } > > std::tuple<_Callable, _Args...> _M_bound; > }; > > template<typename _Func, typename... _BoundArgs> > struct _Bind_simple_helper > { > typedef _Maybe_wrap_member_pointer<typename decay<_Func>::type> > __maybe_type; > typedef typename __maybe_type::type __func_type; > typedef _Bind_simple<__func_type(typename decay<_BoundArgs>::type...)> > __type; > }; > > > > template<typename _Callable, typename... _Args> > typename _Bind_simple_helper<_Callable, _Args...>::__type > __bind_simple(_Callable&& __callable, _Args&&... __args) > { > typedef _Bind_simple_helper<_Callable, _Args...> __helper_type; > typedef typename __helper_type::__maybe_type __maybe_type; > typedef typename __helper_type::__type __result_type; > return __result_type( > __maybe_type::__do_wrap( std::forward<_Callable>(__callable)), > std::forward<_Args>(__args)...); > } > > > > > > > class bad_function_call : public std::exception > { > public: > virtual ~bad_function_call() noexcept; > > const char* what() const noexcept; > }; > > > > > > > template<typename _Tp> > struct __is_location_invariant > : integral_constant<bool, (is_pointer<_Tp>::value > || is_member_pointer<_Tp>::value)> > { }; > > class _Undefined_class; > > union _Nocopy_types > { > void* _M_object; > const void* _M_const_object; > void (*_M_function_pointer)(); > void (_Undefined_class::*_M_member_pointer)(); > }; > > union _Any_data > { > void* _M_access() { return &_M_pod_data[0]; } > const void* _M_access() const { return &_M_pod_data[0]; } > > template<typename _Tp> > _Tp& > _M_access() > { return *static_cast<_Tp*>(_M_access()); } > > template<typename _Tp> > const _Tp& > _M_access() const > { return *static_cast<const _Tp*>(_M_access()); } > > _Nocopy_types _M_unused; > char _M_pod_data[sizeof(_Nocopy_types)]; > }; > > enum _Manager_operation > { > __get_type_info, > __get_functor_ptr, > __clone_functor, > __destroy_functor > }; > > > > template<typename _Tp> > struct _Simple_type_wrapper > { > _Simple_type_wrapper(_Tp __value) : __value(__value) { } > > _Tp __value; > }; > > template<typename _Tp> > struct __is_location_invariant<_Simple_type_wrapper<_Tp> > > : __is_location_invariant<_Tp> > { }; > > > > template<typename _Functor> > inline _Functor& > __callable_functor(_Functor& __f) > { return __f; } > > template<typename _Member, typename _Class> > inline _Mem_fn<_Member _Class::*> > __callable_functor(_Member _Class::* &__p) > { return std::mem_fn(__p); } > > template<typename _Member, typename _Class> > inline _Mem_fn<_Member _Class::*> > __callable_functor(_Member _Class::* const &__p) > { return std::mem_fn(__p); } > > template<typename _Member, typename _Class> > inline _Mem_fn<_Member _Class::*> > __callable_functor(_Member _Class::* volatile &__p) > { return std::mem_fn(__p); } > > template<typename _Member, typename _Class> > inline _Mem_fn<_Member _Class::*> > __callable_functor(_Member _Class::* const volatile &__p) > { return std::mem_fn(__p); } > > template<typename _Signature> > class function; > > > class _Function_base > { > public: > static const std::size_t _M_max_size = sizeof(_Nocopy_types); > static const std::size_t _M_max_align = __alignof__(_Nocopy_types); > > template<typename _Functor> > class _Base_manager > { > protected: > static const bool __stored_locally = > (__is_location_invariant<_Functor>::value > && sizeof(_Functor) <= _M_max_size > && __alignof__(_Functor) <= _M_max_align > && (_M_max_align % __alignof__(_Functor) == 0)); > > typedef integral_constant<bool, __stored_locally> _Local_storage; > > > static _Functor* > _M_get_pointer(const _Any_data& __source) > { > const _Functor* __ptr = > __stored_locally? std::__addressof(__source._M_access<_Functor>()) > : __source._M_access<_Functor*>(); > return const_cast<_Functor*>(__ptr); > } > > > > static void > _M_clone(_Any_data& __dest, const _Any_data& __source, true_type) > { > new (__dest._M_access()) _Functor(__source._M_access<_Functor>()); > } > > > > static void > _M_clone(_Any_data& __dest, const _Any_data& __source, false_type) > { > __dest._M_access<_Functor*>() = > new _Functor(*__source._M_access<_Functor*>()); > } > > > > static void > _M_destroy(_Any_data& __victim, true_type) > { > __victim._M_access<_Functor>().~_Functor(); > } > > > static void > _M_destroy(_Any_data& __victim, false_type) > { > delete __victim._M_access<_Functor*>(); > } > > public: > static bool > _M_manager(_Any_data& __dest, const _Any_data& __source, > _Manager_operation __op) > { > switch (__op) > { > > case __get_type_info: > __dest._M_access<const type_info*>() = &typeid(_Functor); > break; > > case __get_functor_ptr: > __dest._M_access<_Functor*>() = _M_get_pointer(__source); > break; > > case __clone_functor: > _M_clone(__dest, __source, _Local_storage()); > break; > > case __destroy_functor: > _M_destroy(__dest, _Local_storage()); > break; > } > return false; > } > > static void > _M_init_functor(_Any_data& __functor, _Functor&& __f) > { _M_init_functor(__functor, std::move(__f), _Local_storage()); } > > template<typename _Signature> > static bool > _M_not_empty_function(const function<_Signature>& __f) > { return static_cast<bool>(__f); } > > template<typename _Tp> > static bool > _M_not_empty_function(_Tp* const& __fp) > { return __fp; } > > template<typename _Class, typename _Tp> > static bool > _M_not_empty_function(_Tp _Class::* const& __mp) > { return __mp; } > > template<typename _Tp> > static bool > _M_not_empty_function(const _Tp&) > { return true; } > > private: > static void > _M_init_functor(_Any_data& __functor, _Functor&& __f, true_type) > { new (__functor._M_access()) _Functor(std::move(__f)); } > > static void > _M_init_functor(_Any_data& __functor, _Functor&& __f, false_type) > { __functor._M_access<_Functor*>() = new _Functor(std::move(__f)); } > }; > > template<typename _Functor> > class _Ref_manager : public _Base_manager<_Functor*> > { > typedef _Function_base::_Base_manager<_Functor*> _Base; > > public: > static bool > _M_manager(_Any_data& __dest, const _Any_data& __source, > _Manager_operation __op) > { > switch (__op) > { > > case __get_type_info: > __dest._M_access<const type_info*>() = &typeid(_Functor); > break; > > case __get_functor_ptr: > __dest._M_access<_Functor*>() = *_Base::_M_get_pointer(__source); > return is_const<_Functor>::value; > break; > > default: > _Base::_M_manager(__dest, __source, __op); > } > return false; > } > > static void > _M_init_functor(_Any_data& __functor, reference_wrapper<_Functor> __f) > { > _Base::_M_init_functor(__functor, std::__addressof(__f.get())); > } > }; > > _Function_base() : _M_manager(0) { } > > ~_Function_base() > { > if (_M_manager) > _M_manager(_M_functor, _M_functor, __destroy_functor); > } > > > bool _M_empty() const { return !_M_manager; } > > typedef bool (*_Manager_type)(_Any_data&, const _Any_data&, > _Manager_operation); > > _Any_data _M_functor; > _Manager_type _M_manager; > }; > > template<typename _Signature, typename _Functor> > class _Function_handler; > > template<typename _Res, typename _Functor, typename... _ArgTypes> > class _Function_handler<_Res(_ArgTypes...), _Functor> > : public _Function_base::_Base_manager<_Functor> > { > typedef _Function_base::_Base_manager<_Functor> _Base; > > public: > static _Res > _M_invoke(const _Any_data& __functor, _ArgTypes... __args) > { > return (*_Base::_M_get_pointer(__functor))( > std::forward<_ArgTypes>(__args)...); > } > }; > > template<typename _Functor, typename... _ArgTypes> > class _Function_handler<void(_ArgTypes...), _Functor> > : public _Function_base::_Base_manager<_Functor> > { > typedef _Function_base::_Base_manager<_Functor> _Base; > > public: > static void > _M_invoke(const _Any_data& __functor, _ArgTypes... __args) > { > (*_Base::_M_get_pointer(__functor))( > std::forward<_ArgTypes>(__args)...); > } > }; > > template<typename _Res, typename _Functor, typename... _ArgTypes> > class _Function_handler<_Res(_ArgTypes...), reference_wrapper<_Functor> > > : public _Function_base::_Ref_manager<_Functor> > { > typedef _Function_base::_Ref_manager<_Functor> _Base; > > public: > static _Res > _M_invoke(const _Any_data& __functor, _ArgTypes... __args) > { > return __callable_functor(**_Base::_M_get_pointer(__functor))( > std::forward<_ArgTypes>(__args)...); > } > }; > > template<typename _Functor, typename... _ArgTypes> > class _Function_handler<void(_ArgTypes...), reference_wrapper<_Functor> > > : public _Function_base::_Ref_manager<_Functor> > { > typedef _Function_base::_Ref_manager<_Functor> _Base; > > public: > static void > _M_invoke(const _Any_data& __functor, _ArgTypes... __args) > { > __callable_functor(**_Base::_M_get_pointer(__functor))( > std::forward<_ArgTypes>(__args)...); > } > }; > > template<typename _Class, typename _Member, typename _Res, > typename... _ArgTypes> > class _Function_handler<_Res(_ArgTypes...), _Member _Class::*> > : public _Function_handler<void(_ArgTypes...), _Member _Class::*> > { > typedef _Function_handler<void(_ArgTypes...), _Member _Class::*> > _Base; > > public: > static _Res > _M_invoke(const _Any_data& __functor, _ArgTypes... __args) > { > return std::mem_fn(_Base::_M_get_pointer(__functor)->__value)( > std::forward<_ArgTypes>(__args)...); > } > }; > > template<typename _Class, typename _Member, typename... _ArgTypes> > class _Function_handler<void(_ArgTypes...), _Member _Class::*> > : public _Function_base::_Base_manager< > _Simple_type_wrapper< _Member _Class::* > > > { > typedef _Member _Class::* _Functor; > typedef _Simple_type_wrapper<_Functor> _Wrapper; > typedef _Function_base::_Base_manager<_Wrapper> _Base; > > public: > static bool > _M_manager(_Any_data& __dest, const _Any_data& __source, > _Manager_operation __op) > { > switch (__op) > { > > case __get_type_info: > __dest._M_access<const type_info*>() = &typeid(_Functor); > break; > > case __get_functor_ptr: > __dest._M_access<_Functor*>() = > &_Base::_M_get_pointer(__source)->__value; > break; > > default: > _Base::_M_manager(__dest, __source, __op); > } > return false; > } > > static void > _M_invoke(const _Any_data& __functor, _ArgTypes... __args) > { > std::mem_fn(_Base::_M_get_pointer(__functor)->__value)( > std::forward<_ArgTypes>(__args)...); > } > }; > > template<typename _From, typename _To> > using __check_func_return_type > = __or_<is_void<_To>, is_convertible<_From, _To>>; > > > > > > > > template<typename _Res, typename... _ArgTypes> > class function<_Res(_ArgTypes...)> > : public _Maybe_unary_or_binary_function<_Res, _ArgTypes...>, > private _Function_base > { > typedef _Res _Signature_type(_ArgTypes...); > > template<typename _Functor> > using _Invoke = decltype(__callable_functor(std::declval<_Functor&>()) > (std::declval<_ArgTypes>()...) ); > > template<typename _Functor> > using _Callable = __check_func_return_type<_Invoke<_Functor>, _Res>; > > template<typename _Cond, typename _Tp> > using _Requires = typename enable_if<_Cond::value, _Tp>::type; > > public: > typedef _Res result_type; > > > > > > > > function() noexcept > : _Function_base() { } > > > > > > function(nullptr_t) noexcept > : _Function_base() { } ># 2185 "/usr/include/c++/4.9.0/functional" 3 > function(const function& __x); ># 2194 "/usr/include/c++/4.9.0/functional" 3 > function(function&& __x) : _Function_base() > { > __x.swap(*this); > } ># 2217 "/usr/include/c++/4.9.0/functional" 3 > template<typename _Functor, > typename = _Requires<_Callable<_Functor>, void>> > function(_Functor); ># 2233 "/usr/include/c++/4.9.0/functional" 3 > function& > operator=(const function& __x) > { > function(__x).swap(*this); > return *this; > } ># 2251 "/usr/include/c++/4.9.0/functional" 3 > function& > operator=(function&& __x) > { > function(std::move(__x)).swap(*this); > return *this; > } ># 2265 "/usr/include/c++/4.9.0/functional" 3 > function& > operator=(nullptr_t) > { > if (_M_manager) > { > _M_manager(_M_functor, _M_functor, __destroy_functor); > _M_manager = 0; > _M_invoker = 0; > } > return *this; > } ># 2293 "/usr/include/c++/4.9.0/functional" 3 > template<typename _Functor> > _Requires<_Callable<_Functor>, function&> > operator=(_Functor&& __f) > { > function(std::forward<_Functor>(__f)).swap(*this); > return *this; > } > > > template<typename _Functor> > function& > operator=(reference_wrapper<_Functor> __f) noexcept > { > function(__f).swap(*this); > return *this; > } ># 2319 "/usr/include/c++/4.9.0/functional" 3 > void swap(function& __x) > { > std::swap(_M_functor, __x._M_functor); > std::swap(_M_manager, __x._M_manager); > std::swap(_M_invoker, __x._M_invoker); > } ># 2347 "/usr/include/c++/4.9.0/functional" 3 > explicit operator bool() const noexcept > { return !_M_empty(); } ># 2360 "/usr/include/c++/4.9.0/functional" 3 > _Res operator()(_ArgTypes... __args) const; ># 2373 "/usr/include/c++/4.9.0/functional" 3 > const type_info& target_type() const noexcept; ># 2384 "/usr/include/c++/4.9.0/functional" 3 > template<typename _Functor> _Functor* target() noexcept; > > > template<typename _Functor> const _Functor* target() const noexcept; > > > private: > typedef _Res (*_Invoker_type)(const _Any_data&, _ArgTypes...); > _Invoker_type _M_invoker; > }; > > > template<typename _Res, typename... _ArgTypes> > function<_Res(_ArgTypes...)>:: > function(const function& __x) > : _Function_base() > { > if (static_cast<bool>(__x)) > { > _M_invoker = __x._M_invoker; > _M_manager = __x._M_manager; > __x._M_manager(_M_functor, __x._M_functor, __clone_functor); > } > } > > template<typename _Res, typename... _ArgTypes> > template<typename _Functor, typename> > function<_Res(_ArgTypes...)>:: > function(_Functor __f) > : _Function_base() > { > typedef _Function_handler<_Signature_type, _Functor> _My_handler; > > if (_My_handler::_M_not_empty_function(__f)) > { > _My_handler::_M_init_functor(_M_functor, std::move(__f)); > _M_invoker = &_My_handler::_M_invoke; > _M_manager = &_My_handler::_M_manager; > } > } > > template<typename _Res, typename... _ArgTypes> > _Res > function<_Res(_ArgTypes...)>:: > operator()(_ArgTypes... __args) const > { > if (_M_empty()) > __throw_bad_function_call(); > return _M_invoker(_M_functor, std::forward<_ArgTypes>(__args)...); > } > > > template<typename _Res, typename... _ArgTypes> > const type_info& > function<_Res(_ArgTypes...)>:: > target_type() const noexcept > { > if (_M_manager) > { > _Any_data __typeinfo_result; > _M_manager(__typeinfo_result, _M_functor, __get_type_info); > return *__typeinfo_result._M_access<const type_info*>(); > } > else > return typeid(void); > } > > template<typename _Res, typename... _ArgTypes> > template<typename _Functor> > _Functor* > function<_Res(_ArgTypes...)>:: > target() noexcept > { > if (typeid(_Functor) == target_type() && _M_manager) > { > _Any_data __ptr; > if (_M_manager(__ptr, _M_functor, __get_functor_ptr) > && !is_const<_Functor>::value) > return 0; > else > return __ptr._M_access<_Functor*>(); > } > else > return 0; > } > > template<typename _Res, typename... _ArgTypes> > template<typename _Functor> > const _Functor* > function<_Res(_ArgTypes...)>:: > target() const noexcept > { > if (typeid(_Functor) == target_type() && _M_manager) > { > _Any_data __ptr; > _M_manager(__ptr, _M_functor, __get_functor_ptr); > return __ptr._M_access<const _Functor*>(); > } > else > return 0; > } ># 2496 "/usr/include/c++/4.9.0/functional" 3 > template<typename _Res, typename... _Args> > inline bool > operator==(const function<_Res(_Args...)>& __f, nullptr_t) noexcept > { return !static_cast<bool>(__f); } > > > template<typename _Res, typename... _Args> > inline bool > operator==(nullptr_t, const function<_Res(_Args...)>& __f) noexcept > { return !static_cast<bool>(__f); } ># 2514 "/usr/include/c++/4.9.0/functional" 3 > template<typename _Res, typename... _Args> > inline bool > operator!=(const function<_Res(_Args...)>& __f, nullptr_t) noexcept > { return static_cast<bool>(__f); } > > > template<typename _Res, typename... _Args> > inline bool > operator!=(nullptr_t, const function<_Res(_Args...)>& __f) noexcept > { return static_cast<bool>(__f); } ># 2532 "/usr/include/c++/4.9.0/functional" 3 > template<typename _Res, typename... _Args> > inline void > swap(function<_Res(_Args...)>& __x, function<_Res(_Args...)>& __y) > { __x.swap(__y); } > > >} ># 24 "/usr/include/boost/system/error_code.hpp" 2 3 4 > > ># 1 "/usr/include/boost/cerrno.hpp" 1 3 4 ># 13 "/usr/include/boost/cerrno.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cerrno" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cerrno" 3 4 ># 40 "/usr/include/c++/4.9.0/cerrno" 3 > ># 1 "/usr/include/errno.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/cerrno" 2 3 ># 14 "/usr/include/boost/cerrno.hpp" 2 3 4 ># 27 "/usr/include/boost/system/error_code.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 33 "/usr/include/boost/system/error_code.hpp" 2 3 4 > > > > > >namespace boost >{ > namespace system > { > > class error_code; > class error_condition; > > > > template< class T > > struct is_error_code_enum { static const bool value = false; }; > > template< class T > > struct is_error_condition_enum { static const bool value = false; }; > > > > namespace errc > { > enum errc_t > { > success = 0, > address_family_not_supported = 97, > address_in_use = 98, > address_not_available = 99, > already_connected = 106, > argument_list_too_long = 7, > argument_out_of_domain = 33, > bad_address = 14, > bad_file_descriptor = 9, > bad_message = 74, > broken_pipe = 32, > connection_aborted = 103, > connection_already_in_progress = 114, > connection_refused = 111, > connection_reset = 104, > cross_device_link = 18, > destination_address_required = 89, > device_or_resource_busy = 16, > directory_not_empty = 39, > executable_format_error = 8, > file_exists = 17, > file_too_large = 27, > filename_too_long = 36, > function_not_supported = 38, > host_unreachable = 113, > identifier_removed = 43, > illegal_byte_sequence = 84, > inappropriate_io_control_operation = 25, > interrupted = 4, > invalid_argument = 22, > invalid_seek = 29, > io_error = 5, > is_a_directory = 21, > message_size = 90, > network_down = 100, > network_reset = 102, > network_unreachable = 101, > no_buffer_space = 105, > no_child_process = 10, > no_link = 67, > no_lock_available = 37, > no_message_available = 61, > no_message = 42, > no_protocol_option = 92, > no_space_on_device = 28, > no_stream_resources = 63, > no_such_device_or_address = 6, > no_such_device = 19, > no_such_file_or_directory = 2, > no_such_process = 3, > not_a_directory = 20, > not_a_socket = 88, > not_a_stream = 60, > not_connected = 107, > not_enough_memory = 12, > not_supported = 95, > operation_canceled = 125, > operation_in_progress = 115, > operation_not_permitted = 1, > operation_not_supported = 95, > operation_would_block = 11, > owner_dead = 130, > permission_denied = 13, > protocol_error = 71, > protocol_not_supported = 93, > read_only_file_system = 30, > resource_deadlock_would_occur = 35, > resource_unavailable_try_again = 11, > result_out_of_range = 34, > state_not_recoverable = 131, > stream_timeout = 62, > text_file_busy = 26, > timed_out = 110, > too_many_files_open_in_system = 23, > too_many_files_open = 24, > too_many_links = 31, > too_many_symbolic_link_levels = 40, > value_too_large = 75, > wrong_protocol_type = 91 > }; > > } > > > namespace posix = errc; > namespace posix_error = errc; > > > template<> struct is_error_condition_enum<errc::errc_t> > { static const bool value = true; }; ># 186 "/usr/include/boost/system/error_code.hpp" 3 4 > class error_category : public noncopyable > { > public: > virtual ~error_category(){} > > virtual const char * name() const noexcept = 0; > virtual std::string message( int ev ) const = 0; > inline virtual error_condition default_error_condition( int ev ) const noexcept; > inline virtual bool equivalent( int code, > const error_condition & condition ) const noexcept; > inline virtual bool equivalent( const error_code & code, > int condition ) const noexcept; > > bool operator==(const error_category & rhs) const noexcept { return this == &rhs; } > bool operator!=(const error_category & rhs) const noexcept { return this != &rhs; } > bool operator<( const error_category & rhs ) const noexcept > { > return std::less<const error_category*>()( this, &rhs ); > } > }; > > > > > > > > const error_category & system_category() noexcept; > const error_category & generic_category() noexcept; > > > > > inline const error_category & get_system_category() { return system_category(); } > inline const error_category & get_generic_category() { return generic_category(); } > inline const error_category & get_posix_category() { return generic_category(); } > static const error_category & posix_category = generic_category(); > static const error_category & errno_ecat = generic_category(); > static const error_category & native_ecat = system_category(); > > > > > > > class error_condition > { > public: > > > error_condition() noexcept : m_val(0), m_cat(&generic_category()) {} > error_condition( int val, const error_category & cat ) noexcept : m_val(val), m_cat(&cat) {} > > template <class ErrorConditionEnum> > error_condition(ErrorConditionEnum e, > typename boost::enable_if<is_error_condition_enum<ErrorConditionEnum> >::type* = 0) noexcept > { > *this = make_error_condition(e); > } > > > > void assign( int val, const error_category & cat ) noexcept > { > m_val = val; > m_cat = &cat; > } > > template<typename ErrorConditionEnum> > typename boost::enable_if<is_error_condition_enum<ErrorConditionEnum>, error_condition>::type & > operator=( ErrorConditionEnum val ) noexcept > { > *this = make_error_condition(val); > return *this; > } > > void clear() noexcept > { > m_val = 0; > m_cat = &generic_category(); > } > > > int value() const noexcept { return m_val; } > const error_category & category() const noexcept { return *m_cat; } > std::string message() const { return m_cat->message(value()); } > > typedef void (*unspecified_bool_type)(); > static void unspecified_bool_true() {} > > operator unspecified_bool_type() const noexcept > { > return m_val == 0 ? 0 : unspecified_bool_true; > } > > bool operator!() const noexcept > { > return m_val == 0; > } > > > > > inline friend bool operator==( const error_condition & lhs, > const error_condition & rhs ) noexcept > { > return lhs.m_cat == rhs.m_cat && lhs.m_val == rhs.m_val; > } > > inline friend bool operator<( const error_condition & lhs, > const error_condition & rhs ) noexcept > > > { > return lhs.m_cat < rhs.m_cat > || (lhs.m_cat == rhs.m_cat && lhs.m_val < rhs.m_val); > } > > private: > int m_val; > const error_category * m_cat; > > }; ># 318 "/usr/include/boost/system/error_code.hpp" 3 4 > class error_code > { > public: > > > error_code() noexcept : m_val(0), m_cat(&system_category()) {} > error_code( int val, const error_category & cat ) noexcept : m_val(val), m_cat(&cat) {} > > template <class ErrorCodeEnum> > error_code(ErrorCodeEnum e, > typename boost::enable_if<is_error_code_enum<ErrorCodeEnum> >::type* = 0) noexcept > { > *this = make_error_code(e); > } > > > void assign( int val, const error_category & cat ) noexcept > { > m_val = val; > m_cat = &cat; > } > > template<typename ErrorCodeEnum> > typename boost::enable_if<is_error_code_enum<ErrorCodeEnum>, error_code>::type & > operator=( ErrorCodeEnum val ) noexcept > { > *this = make_error_code(val); > return *this; > } > > void clear() noexcept > { > m_val = 0; > m_cat = &system_category(); > } > > > int value() const noexcept { return m_val; } > const error_category & category() const noexcept { return *m_cat; } > error_condition default_error_condition() const noexcept { return m_cat->default_error_condition(value()); } > std::string message() const { return m_cat->message(value()); } > > typedef void (*unspecified_bool_type)(); > static void unspecified_bool_true() {} > > operator unspecified_bool_type() const noexcept > { > return m_val == 0 ? 0 : unspecified_bool_true; > } > > bool operator!() const noexcept > { > return m_val == 0; > } > > > inline friend bool operator==( const error_code & lhs, > const error_code & rhs ) noexcept > > > { > return lhs.m_cat == rhs.m_cat && lhs.m_val == rhs.m_val; > } > > inline friend bool operator<( const error_code & lhs, > const error_code & rhs ) noexcept > > > { > return lhs.m_cat < rhs.m_cat > || (lhs.m_cat == rhs.m_cat && lhs.m_val < rhs.m_val); > } > > private: > int m_val; > const error_category * m_cat; > > }; > > > > extern error_code throws; > > > > > > > } > > namespace detail { inline system::error_code * throws() { return 0; } } ># 417 "/usr/include/boost/system/error_code.hpp" 3 4 > inline system::error_code & throws() > { return *detail::throws(); } > > namespace system > { > > > inline bool operator!=( const error_code & lhs, > const error_code & rhs ) noexcept > { > return !(lhs == rhs); > } > > inline bool operator!=( const error_condition & lhs, > const error_condition & rhs ) noexcept > { > return !(lhs == rhs); > } > > inline bool operator==( const error_code & code, > const error_condition & condition ) noexcept > { > return code.category().equivalent( code.value(), condition ) > || condition.category().equivalent( code, condition.value() ); > } > > inline bool operator!=( const error_code & lhs, > const error_condition & rhs ) noexcept > { > return !(lhs == rhs); > } > > inline bool operator==( const error_condition & condition, > const error_code & code ) noexcept > { > return condition.category().equivalent( code, condition.value() ) > || code.category().equivalent( code.value(), condition ); > } > > inline bool operator!=( const error_condition & lhs, > const error_code & rhs ) noexcept > { > return !(lhs == rhs); > } > > > > template <class charT, class traits> > inline std::basic_ostream<charT,traits>& > operator<< (std::basic_ostream<charT,traits>& os, error_code ec) > { > os << ec.category().name() << ':' << ec.value(); > return os; > } > > inline std::size_t hash_value( const error_code & ec ) > { > return static_cast<std::size_t>(ec.value()) > + reinterpret_cast<std::size_t>(&ec.category()); > } > > > > namespace errc > { > > inline error_code make_error_code( errc_t e ) noexcept > { return error_code( e, generic_category() ); } > > > inline error_condition make_error_condition( errc_t e ) noexcept > { return error_condition( e, generic_category() ); } > } > > > > error_condition error_category::default_error_condition( int ev ) const noexcept > { > return error_condition( ev, *this ); > } > > bool error_category::equivalent( int code, > const error_condition & condition ) const noexcept > { > return default_error_condition( code ) == condition; > } > > bool error_category::equivalent( const error_code & code, > int condition ) const noexcept > { > return *this == code.category() && code.value() == condition; > } > > } >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 514 "/usr/include/boost/system/error_code.hpp" 2 3 4 ># 15 "/usr/include/boost/system/system_error.hpp" 2 3 4 > >namespace boost >{ > namespace system > { > > > class __attribute__((__visibility__("default"))) system_error : public std::runtime_error > > > { > public: > system_error( error_code ec ) > : std::runtime_error(""), m_error_code(ec) {} > > system_error( error_code ec, const std::string & what_arg ) > : std::runtime_error(what_arg), m_error_code(ec) {} > > system_error( error_code ec, const char* what_arg ) > : std::runtime_error(what_arg), m_error_code(ec) {} > > system_error( int ev, const error_category & ecat ) > : std::runtime_error(""), m_error_code(ev,ecat) {} > > system_error( int ev, const error_category & ecat, > const std::string & what_arg ) > : std::runtime_error(what_arg), m_error_code(ev,ecat) {} > > system_error( int ev, const error_category & ecat, > const char * what_arg ) > : std::runtime_error(what_arg), m_error_code(ev,ecat) {} > > virtual ~system_error() throw() {} > > const error_code & code() const throw() { return m_error_code; } > const char * what() const throw(); > > private: > error_code m_error_code; > mutable std::string m_what; > }; > > > > inline const char * system_error::what() const throw() > > { > if ( m_what.empty() ) > { > > try > > { > m_what = this->std::runtime_error::what(); > if ( !m_what.empty() ) m_what += ": "; > m_what += m_error_code.message(); > } > > catch (...) { return std::runtime_error::what(); } > > } > return m_what.c_str(); > } > > } >} ># 23 "/usr/include/boost/thread/exceptions.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 27 "/usr/include/boost/thread/exceptions.hpp" 2 3 4 > >namespace boost >{ > > > class __attribute__((__visibility__("default"))) thread_interrupted > {}; > > > class __attribute__((__visibility__("default"))) thread_exception: > public system::system_error > > { > typedef system::system_error base_type; > public: > thread_exception() > : base_type(0,system::system_category()) > {} > > thread_exception(int sys_error_code) > : base_type(sys_error_code, system::system_category()) > {} > > thread_exception( int ev, const char * what_arg ) > : base_type(system::error_code(ev, system::system_category()), what_arg) > { > } > thread_exception( int ev, const std::string & what_arg ) > : base_type(system::error_code(ev, system::system_category()), what_arg) > { > } > > ~thread_exception() throw() > {} > > > int native_error() const > { > return code().value(); > } > > }; > > class __attribute__((__visibility__("default"))) condition_error: > public system::system_error > > { > typedef system::system_error base_type; > public: > condition_error() > : base_type(system::error_code(0, system::system_category()), "Condition error") > {} > condition_error( int ev ) > : base_type(system::error_code(ev, system::system_category()), "Condition error") > { > } > condition_error( int ev, const char * what_arg ) > : base_type(system::error_code(ev, system::system_category()), what_arg) > { > } > condition_error( int ev, const std::string & what_arg ) > : base_type(system::error_code(ev, system::system_category()), what_arg) > { > } > }; > > > class __attribute__((__visibility__("default"))) lock_error: > public thread_exception > { > typedef thread_exception base_type; > public: > lock_error() > : base_type(0, "boost::lock_error") > {} > > lock_error( int ev ) > : base_type(ev, "boost::lock_error") > { > } > lock_error( int ev, const char * what_arg ) > : base_type(ev, what_arg) > { > } > lock_error( int ev, const std::string & what_arg ) > : base_type(ev, what_arg) > { > } > > ~lock_error() throw() > {} > > }; > > class __attribute__((__visibility__("default"))) thread_resource_error: > public thread_exception > { > typedef thread_exception base_type; > public: > thread_resource_error() > : base_type(system::errc::resource_unavailable_try_again, "boost::thread_resource_error") > {} > > thread_resource_error( int ev ) > : base_type(ev, "boost::thread_resource_error") > { > } > thread_resource_error( int ev, const char * what_arg ) > : base_type(ev, what_arg) > { > } > thread_resource_error( int ev, const std::string & what_arg ) > : base_type(ev, what_arg) > { > } > > > ~thread_resource_error() throw() > {} > > }; > > class __attribute__((__visibility__("default"))) unsupported_thread_option: > public thread_exception > { > typedef thread_exception base_type; > public: > unsupported_thread_option() > : base_type(system::errc::invalid_argument, "boost::unsupported_thread_option") > {} > > unsupported_thread_option( int ev ) > : base_type(ev, "boost::unsupported_thread_option") > { > } > unsupported_thread_option( int ev, const char * what_arg ) > : base_type(ev, what_arg) > { > } > unsupported_thread_option( int ev, const std::string & what_arg ) > : base_type(ev, what_arg) > { > } > > }; > > class __attribute__((__visibility__("default"))) invalid_thread_argument: > public thread_exception > { > typedef thread_exception base_type; > public: > invalid_thread_argument() > : base_type(system::errc::invalid_argument, "boost::invalid_thread_argument") > {} > > invalid_thread_argument( int ev ) > : base_type(ev, "boost::invalid_thread_argument") > { > } > invalid_thread_argument( int ev, const char * what_arg ) > : base_type(ev, what_arg) > { > } > invalid_thread_argument( int ev, const std::string & what_arg ) > : base_type(ev, what_arg) > { > } > > }; > > class __attribute__((__visibility__("default"))) thread_permission_error: > public thread_exception > { > typedef thread_exception base_type; > public: > thread_permission_error() > : base_type(system::errc::permission_denied, "boost::thread_permission_error") > {} > > thread_permission_error( int ev ) > : base_type(ev, "boost::thread_permission_error") > { > } > thread_permission_error( int ev, const char * what_arg ) > : base_type(ev, what_arg) > { > } > thread_permission_error( int ev, const std::string & what_arg ) > : base_type(ev, what_arg) > { > } > > }; > >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 224 "/usr/include/boost/thread/exceptions.hpp" 2 3 4 ># 11 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/lock_guard.hpp" 1 3 4 ># 11 "/usr/include/boost/thread/lock_guard.hpp" 3 4 ># 1 "/usr/include/boost/thread/detail/delete.hpp" 1 3 4 ># 12 "/usr/include/boost/thread/lock_guard.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/detail/move.hpp" 1 3 4 ># 16 "/usr/include/boost/thread/detail/move.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/decay.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/decay.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/remove_bounds.hpp" 1 3 4 ># 21 "/usr/include/boost/type_traits/remove_bounds.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 22 "/usr/include/boost/type_traits/remove_bounds.hpp" 2 3 4 > > > >namespace boost { > >template< typename T > struct remove_bounds { public: typedef T type; }; > > >template< typename T, std::size_t N > struct remove_bounds<T[N]> { public: typedef T type; }; >template< typename T, std::size_t N > struct remove_bounds<T const[N]> { public: typedef T const type; }; >template< typename T, std::size_t N > struct remove_bounds<T volatile[N]> { public: typedef T volatile type; }; >template< typename T, std::size_t N > struct remove_bounds<T const volatile[N]> { public: typedef T const volatile type; }; > >template< typename T > struct remove_bounds<T[]> { public: typedef T type; }; >template< typename T > struct remove_bounds<T const[]> { public: typedef T const type; }; >template< typename T > struct remove_bounds<T volatile[]> { public: typedef T volatile type; }; >template< typename T > struct remove_bounds<T const volatile[]> { public: typedef T const volatile type; }; > > > >} > > > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 47 "/usr/include/boost/type_traits/remove_bounds.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/decay.hpp" 2 3 4 > > > > > >namespace boost >{ > > template< class T > > struct decay > { > private: > typedef typename remove_reference<T>::type Ty; > public: > typedef typename mpl::eval_if< > is_array<Ty>, > mpl::identity<typename remove_bounds<Ty>::type*>, > typename mpl::eval_if< > is_function<Ty>, > add_pointer<Ty>, > mpl::identity<Ty> > > > >::type type; > }; > >} ># 17 "/usr/include/boost/thread/detail/move.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/move/utility.hpp" 1 3 4 ># 17 "/usr/include/boost/move/utility.hpp" 3 4 ># 1 "/usr/include/boost/move/detail/config_begin.hpp" 1 3 4 ># 18 "/usr/include/boost/move/utility.hpp" 2 3 4 ># 1 "/usr/include/boost/move/core.hpp" 1 3 4 ># 19 "/usr/include/boost/move/core.hpp" 3 4 ># 1 "/usr/include/boost/move/detail/config_begin.hpp" 1 3 4 ># 20 "/usr/include/boost/move/core.hpp" 2 3 4 ># 249 "/usr/include/boost/move/core.hpp" 3 4 > namespace boost { > > > > > template<class T> > struct has_move_emulation_enabled > { > static const bool value = false; > }; > > } ># 337 "/usr/include/boost/move/core.hpp" 3 4 ># 1 "/usr/include/boost/move/detail/config_end.hpp" 1 3 4 ># 338 "/usr/include/boost/move/core.hpp" 2 3 4 ># 19 "/usr/include/boost/move/utility.hpp" 2 3 4 ># 1 "/usr/include/boost/move/detail/meta_utils.hpp" 1 3 4 ># 17 "/usr/include/boost/move/detail/meta_utils.hpp" 3 4 ># 1 "/usr/include/boost/move/detail/config_begin.hpp" 1 3 4 ># 18 "/usr/include/boost/move/detail/meta_utils.hpp" 2 3 4 > > > >namespace boost { >namespace move_detail { > > >template<bool C, typename T1, typename T2> >struct if_c >{ > typedef T1 type; >}; > >template<typename T1, typename T2> >struct if_c<false,T1,T2> >{ > typedef T2 type; >}; > >template<typename T1, typename T2, typename T3> >struct if_ >{ > typedef typename if_c<0 != T1::value, T2, T3>::type type; >}; > > >template <bool B, class T = void> >struct enable_if_c >{ > typedef T type; >}; > >template <class T> >struct enable_if_c<false, T> {}; > >template <class Cond, class T = void> >struct enable_if : public enable_if_c<Cond::value, T> {}; > >template <class Cond, class T = void> >struct disable_if : public enable_if_c<!Cond::value, T> {}; > > >template<class T, T v> >struct integral_constant >{ > static const T value = v; > typedef T value_type; > typedef integral_constant<T, v> type; >}; > > >template <class T> >struct identity >{ > typedef T type; >}; > > >template <class T, class U> >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 <typename Condition1, typename Condition2, typename Condition3 = integral_constant<bool, true> > >struct and_ > : public integral_constant<bool, Condition1::value && Condition2::value && Condition3::value> >{}; > >template <typename Boolean> >struct not_ > : public integral_constant<bool, !Boolean::value> >{}; > > >template<class T> >struct is_lvalue_reference > : public integral_constant<bool, false> >{}; > >template<class T> >struct is_lvalue_reference<T&> > : public integral_constant<bool, true> >{}; > >template<class T> >struct is_class_or_union >{ > struct twochar { char _[2]; }; > template <class U> > static char is_class_or_union_tester(void(U::*)(void)); > template <class U> > static twochar is_class_or_union_tester(...); > static const bool value = sizeof(is_class_or_union_tester<T>(0)) == sizeof(char); >}; > >struct empty{}; > > >template<class T> struct addr_impl_ref >{ > T & v_; > inline addr_impl_ref( T & v ): v_( v ) {} > inline operator T& () const { return v_; } > > private: > addr_impl_ref & operator=(const addr_impl_ref &); >}; > >template<class T> struct addressof_impl >{ > static inline T * f( T & v, long ) > { > return reinterpret_cast<T*>( > &const_cast<char&>(reinterpret_cast<const volatile char &>(v))); > } > > static inline T * f( T * v, int ) > { return v; } >}; > >template<class T> >inline T * addressof( T & v ) >{ > return ::boost::move_detail::addressof_impl<T>::f > ( ::boost::move_detail::addr_impl_ref<T>( v ), 0 ); >} > >} >} > ># 1 "/usr/include/boost/move/detail/config_end.hpp" 1 3 4 ># 157 "/usr/include/boost/move/detail/meta_utils.hpp" 2 3 4 ># 20 "/usr/include/boost/move/utility.hpp" 2 3 4 ># 101 "/usr/include/boost/move/utility.hpp" 3 4 > namespace boost { > > > > > > > > template<class T> > struct enable_move_utility_emulation > { > static const bool value = false; > }; ># 137 "/usr/include/boost/move/utility.hpp" 3 4 > template <class T> > inline typename remove_reference<T>::type && move(T&& t) noexcept > { return static_cast<typename remove_reference<T>::type &&>(t); } ># 175 "/usr/include/boost/move/utility.hpp" 3 4 > template <class T, class U> > inline T&& forward(U&& t > , typename ::boost::move_detail::enable_if_c< > move_detail::is_lvalue_reference<T>::value ? move_detail::is_lvalue_reference<U>::value : true>::type * = 0 > > > ) noexcept > { return static_cast<T&&>(t); } > > > > } > > > > > ># 1 "/usr/include/boost/move/detail/config_end.hpp" 1 3 4 ># 193 "/usr/include/boost/move/utility.hpp" 2 3 4 ># 21 "/usr/include/boost/thread/detail/move.hpp" 2 3 4 ># 1 "/usr/include/boost/move/traits.hpp" 1 3 4 ># 17 "/usr/include/boost/move/traits.hpp" 3 4 ># 1 "/usr/include/boost/move/detail/config_begin.hpp" 1 3 4 ># 18 "/usr/include/boost/move/traits.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/has_trivial_destructor.hpp" 1 3 4 ># 18 "/usr/include/boost/type_traits/has_trivial_destructor.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 19 "/usr/include/boost/type_traits/has_trivial_destructor.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct has_trivial_dtor_impl >{ > > static const bool value = (__has_trivial_destructor(T) ); > > > >}; > >} > >template< typename T > struct has_trivial_destructor : public ::boost::integral_constant<bool,::boost::detail::has_trivial_dtor_impl<T>::value> { public: }; > >template<> struct has_trivial_destructor< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_trivial_destructor< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_destructor< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_destructor< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 48 "/usr/include/boost/type_traits/has_trivial_destructor.hpp" 2 3 4 ># 19 "/usr/include/boost/move/traits.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_nothrow_move_constructible.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/is_nothrow_move_constructible.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/has_trivial_move_constructor.hpp" 1 3 4 ># 22 "/usr/include/boost/type_traits/has_trivial_move_constructor.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 23 "/usr/include/boost/type_traits/has_trivial_move_constructor.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct has_trivial_move_ctor_impl >{ > > > > static const bool value = (::boost::type_traits::ice_and< ::boost::is_pod<T>::value, ::boost::type_traits::ice_not< ::boost::is_volatile<T>::value >::value >::value) > > > > ; > >}; > >} > >template< typename T > struct has_trivial_move_constructor : public ::boost::integral_constant<bool,::boost::detail::has_trivial_move_ctor_impl<T>::value> { public: }; > >template<> struct has_trivial_move_constructor< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_trivial_move_constructor< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_move_constructor< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_move_constructor< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 56 "/usr/include/boost/type_traits/has_trivial_move_constructor.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/is_nothrow_move_constructible.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/has_nothrow_copy.hpp" 1 3 4 ># 12 "/usr/include/boost/type_traits/has_nothrow_copy.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/has_trivial_copy.hpp" 1 3 4 ># 21 "/usr/include/boost/type_traits/has_trivial_copy.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 22 "/usr/include/boost/type_traits/has_trivial_copy.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct has_trivial_copy_impl >{ > > static const bool value = ((__has_trivial_copy(T) ) && !is_reference<T>::value && ! ::boost::is_volatile<T>::value); > > > > > > > >}; > >} > >template< typename T > struct has_trivial_copy : public ::boost::integral_constant<bool,::boost::detail::has_trivial_copy_impl<T>::value> { public: }; >template< typename T > struct has_trivial_copy_constructor : public ::boost::integral_constant<bool,::boost::detail::has_trivial_copy_impl<T>::value> { public: }; > >template<> struct has_trivial_copy< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_trivial_copy< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_copy< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_copy< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >template<> struct has_trivial_copy_constructor< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_trivial_copy_constructor< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_copy_constructor< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_copy_constructor< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 63 "/usr/include/boost/type_traits/has_trivial_copy.hpp" 2 3 4 ># 13 "/usr/include/boost/type_traits/has_nothrow_copy.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/has_nothrow_copy.hpp" 2 3 4 > >namespace boost { > >namespace detail{ > >template <class T> >struct has_nothrow_copy_imp{ > > static const bool value = ((__has_nothrow_copy(T) ) && !is_volatile<T>::value && !is_reference<T>::value); > > > >}; > >} > >template< typename T > struct has_nothrow_copy : public ::boost::integral_constant<bool,::boost::detail::has_nothrow_copy_imp<T>::value> { public: }; >template< typename T > struct has_nothrow_copy_constructor : public ::boost::integral_constant<bool,::boost::detail::has_nothrow_copy_imp<T>::value> { public: }; > >template<> struct has_nothrow_copy< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_nothrow_copy< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_copy< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_copy< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >template<> struct has_nothrow_copy_constructor< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_nothrow_copy_constructor< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_copy_constructor< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_copy_constructor< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 52 "/usr/include/boost/type_traits/has_nothrow_copy.hpp" 2 3 4 ># 17 "/usr/include/boost/type_traits/is_nothrow_move_constructible.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/declval.hpp" 1 3 4 ># 37 "/usr/include/boost/utility/declval.hpp" 3 4 >namespace boost { > > template <typename T> > typename add_rvalue_reference<T>::type declval() noexcept; > >} ># 22 "/usr/include/boost/type_traits/is_nothrow_move_constructible.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 26 "/usr/include/boost/type_traits/is_nothrow_move_constructible.hpp" 2 3 4 > >namespace boost { > >namespace detail{ > > > >template <class T, class Enable = void> >struct false_or_cpp11_noexcept_move_constructible: public ::boost::false_type {}; > >template <class T> >struct false_or_cpp11_noexcept_move_constructible < > T, > typename ::boost::enable_if_c<sizeof(T) && noexcept((T(::boost::declval<T>())))>::type > > : public ::boost::integral_constant<bool, noexcept((T(::boost::declval<T>())))> >{}; > >template <class T> >struct is_nothrow_move_constructible_imp{ > static const bool value = (::boost::type_traits::ice_and< ::boost::type_traits::ice_not< ::boost::is_volatile<T>::value >::value, ::boost::type_traits::ice_not< ::boost::is_reference<T>::value >::value, ::boost::detail::false_or_cpp11_noexcept_move_constructible<T>::value >::value) > > > > > ; >}; ># 69 "/usr/include/boost/type_traits/is_nothrow_move_constructible.hpp" 3 4 >} > >template< typename T > struct is_nothrow_move_constructible : public ::boost::integral_constant<bool,::boost::detail::is_nothrow_move_constructible_imp<T>::value> { public: }; > >template<> struct is_nothrow_move_constructible< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct is_nothrow_move_constructible< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct is_nothrow_move_constructible< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct is_nothrow_move_constructible< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 83 "/usr/include/boost/type_traits/is_nothrow_move_constructible.hpp" 2 3 4 ># 20 "/usr/include/boost/move/traits.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_nothrow_move_assignable.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/is_nothrow_move_assignable.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/has_trivial_move_assign.hpp" 1 3 4 ># 22 "/usr/include/boost/type_traits/has_trivial_move_assign.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 23 "/usr/include/boost/type_traits/has_trivial_move_assign.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct has_trivial_move_assign_impl >{ > > > > static const bool value = (::boost::type_traits::ice_and< ::boost::is_pod<T>::value, ::boost::type_traits::ice_not< ::boost::is_const<T>::value >::value, ::boost::type_traits::ice_not< ::boost::is_volatile<T>::value >::value >::value) > > > > > ; > >}; > >} > >template< typename T > struct has_trivial_move_assign : public ::boost::integral_constant<bool,::boost::detail::has_trivial_move_assign_impl<T>::value> { public: }; >template<> struct has_trivial_move_assign< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_trivial_move_assign< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_move_assign< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_move_assign< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 56 "/usr/include/boost/type_traits/has_trivial_move_assign.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/is_nothrow_move_assignable.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/has_nothrow_assign.hpp" 1 3 4 ># 12 "/usr/include/boost/type_traits/has_nothrow_assign.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/has_trivial_assign.hpp" 1 3 4 ># 22 "/usr/include/boost/type_traits/has_trivial_assign.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 23 "/usr/include/boost/type_traits/has_trivial_assign.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct has_trivial_assign_impl >{ > > static const bool value = ((__has_trivial_assign(T) ) && ! ::boost::is_volatile<T>::value && ! ::boost::is_const<T>::value); ># 41 "/usr/include/boost/type_traits/has_trivial_assign.hpp" 3 4 >}; > >} > >template< typename T > struct has_trivial_assign : public ::boost::integral_constant<bool,::boost::detail::has_trivial_assign_impl<T>::value> { public: }; >template<> struct has_trivial_assign< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_trivial_assign< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_assign< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_trivial_assign< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 56 "/usr/include/boost/type_traits/has_trivial_assign.hpp" 2 3 4 ># 13 "/usr/include/boost/type_traits/has_nothrow_assign.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/has_nothrow_assign.hpp" 2 3 4 > >namespace boost { > >namespace detail{ > >template <class T> >struct has_nothrow_assign_imp{ > > > > static const bool value = ((__has_nothrow_assign(T) ) && !is_volatile<T>::value && !is_const<T>::value); > >}; > >} > >template< typename T > struct has_nothrow_assign : public ::boost::integral_constant<bool,::boost::detail::has_nothrow_assign_imp<T>::value> { public: }; >template<> struct has_nothrow_assign< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_nothrow_assign< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_assign< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_assign< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 43 "/usr/include/boost/type_traits/has_nothrow_assign.hpp" 2 3 4 ># 17 "/usr/include/boost/type_traits/is_nothrow_move_assignable.hpp" 2 3 4 ># 26 "/usr/include/boost/type_traits/is_nothrow_move_assignable.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 27 "/usr/include/boost/type_traits/is_nothrow_move_assignable.hpp" 2 3 4 > >namespace boost { > >namespace detail{ > > > >template <class T, class Enable = void> >struct false_or_cpp11_noexcept_move_assignable: public ::boost::false_type {}; > >template <class T> >struct false_or_cpp11_noexcept_move_assignable < > T, > typename ::boost::enable_if_c<sizeof(T) && noexcept((::boost::declval<T&>() = ::boost::declval<T>()))>::type > > : public ::boost::integral_constant<bool, noexcept((::boost::declval<T&>() = ::boost::declval<T>()))> >{}; > >template <class T> >struct is_nothrow_move_assignable_imp{ > static const bool value = ( ::boost::type_traits::ice_and< ::boost::type_traits::ice_not< ::boost::is_volatile<T>::value >::value, ::boost::type_traits::ice_not< ::boost::is_reference<T>::value >::value, ::boost::detail::false_or_cpp11_noexcept_move_assignable<T>::value >::value) > > > > > ; >}; ># 70 "/usr/include/boost/type_traits/is_nothrow_move_assignable.hpp" 3 4 >} > >template< typename T > struct is_nothrow_move_assignable : public ::boost::integral_constant<bool,::boost::detail::is_nothrow_move_assignable_imp<T>::value> { public: }; >template<> struct is_nothrow_move_assignable< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct is_nothrow_move_assignable< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct is_nothrow_move_assignable< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct is_nothrow_move_assignable< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 83 "/usr/include/boost/type_traits/is_nothrow_move_assignable.hpp" 2 3 4 ># 21 "/usr/include/boost/move/traits.hpp" 2 3 4 > > > > > > >namespace boost { ># 38 "/usr/include/boost/move/traits.hpp" 3 4 >template <class T> >struct has_trivial_destructor_after_move > : ::boost::has_trivial_destructor<T> >{}; > > > > > >template <class T> >struct has_nothrow_move > : public ::boost::move_detail::integral_constant > < bool > , boost::is_nothrow_move_constructible<T>::value && > boost::is_nothrow_move_assignable<T>::value > > >{}; > >namespace move_detail { > > > > > template< class T> struct forward_type { typedef T type; }; ># 72 "/usr/include/boost/move/traits.hpp" 3 4 >template< class T > struct is_rvalue_reference : ::boost::move_detail::integral_constant<bool, false> { }; > > template< class T > struct is_rvalue_reference< T&& > : ::boost::move_detail::integral_constant<bool, true> { }; ># 86 "/usr/include/boost/move/traits.hpp" 3 4 > template< class T > struct add_rvalue_reference { typedef T&& type; }; ># 113 "/usr/include/boost/move/traits.hpp" 3 4 >template< class T > struct remove_rvalue_reference { typedef T type; }; > > > template< class T > struct remove_rvalue_reference< T&& > { typedef T type; }; ># 128 "/usr/include/boost/move/traits.hpp" 3 4 >template <typename T> >typename boost::move_detail::add_rvalue_reference<T>::type declval(); > >} ># 146 "/usr/include/boost/move/traits.hpp" 3 4 >} > ># 1 "/usr/include/boost/move/detail/config_end.hpp" 1 3 4 ># 149 "/usr/include/boost/move/traits.hpp" 2 3 4 ># 22 "/usr/include/boost/thread/detail/move.hpp" 2 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 23 "/usr/include/boost/thread/detail/move.hpp" 2 3 4 > >namespace boost >{ > > namespace detail > { > template <typename T> > struct enable_move_utility_emulation_dummy_specialization; > template<typename T> > struct thread_move_t > { > T& t; > explicit thread_move_t(T& t_): > t(t_) > {} > > T& operator*() const > { > return t; > } > > T* operator->() const > { > return &t; > } > private: > void operator=(thread_move_t&); > }; > } > > > > > template<typename T> > typename enable_if<boost::is_convertible<T&,boost::detail::thread_move_t<T> >, boost::detail::thread_move_t<T> >::type move(T& t) > { > return boost::detail::thread_move_t<T>(t); > } > > > template<typename T> > boost::detail::thread_move_t<T> move(boost::detail::thread_move_t<T> t) > { > return t; > } > > >} ># 239 "/usr/include/boost/thread/detail/move.hpp" 3 4 >namespace boost >{ namespace thread_detail > { > > template <class T> > typename decay<T>::type > decay_copy(T&& t) > { > return boost::forward<T>(t); > } ># 257 "/usr/include/boost/thread/detail/move.hpp" 3 4 > } >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 261 "/usr/include/boost/thread/detail/move.hpp" 2 3 4 ># 13 "/usr/include/boost/thread/lock_guard.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/detail/lockable_wrapper.hpp" 1 3 4 ># 14 "/usr/include/boost/thread/detail/lockable_wrapper.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 15 "/usr/include/boost/thread/detail/lockable_wrapper.hpp" 2 3 4 > >namespace boost >{ > > > namespace thread_detail > { > template <typename Mutex> > struct lockable_wrapper > { > Mutex* m; > explicit lockable_wrapper(Mutex& m_) : > m(&m_) > {} > }; > template <typename Mutex> > struct lockable_adopt_wrapper > { > Mutex* m; > explicit lockable_adopt_wrapper(Mutex& m_) : > m(&m_) > {} > }; > } > > >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 44 "/usr/include/boost/thread/detail/lockable_wrapper.hpp" 2 3 4 ># 14 "/usr/include/boost/thread/lock_guard.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/lock_options.hpp" 1 3 4 ># 10 "/usr/include/boost/thread/lock_options.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/thread/lock_options.hpp" 2 3 4 > >namespace boost >{ > struct defer_lock_t > { > }; > struct try_to_lock_t > { > }; > struct adopt_lock_t > { > }; > > constexpr defer_lock_t defer_lock = {}; > constexpr try_to_lock_t try_to_lock = {}; > constexpr adopt_lock_t adopt_lock = {}; > >} ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 30 "/usr/include/boost/thread/lock_options.hpp" 2 3 4 ># 15 "/usr/include/boost/thread/lock_guard.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 21 "/usr/include/boost/thread/lock_guard.hpp" 2 3 4 > >namespace boost >{ > > template <typename Mutex> > class lock_guard > { > private: > Mutex& m; > > public: > typedef Mutex mutex_type; > lock_guard(lock_guard const&) = delete; lock_guard& operator=(lock_guard const&) = delete; > > explicit lock_guard(Mutex& m_) : > m(m_) > { > m.lock(); > } > > lock_guard(Mutex& m_, adopt_lock_t) : > m(m_) > { > > > > } > > > lock_guard(std::initializer_list<thread_detail::lockable_wrapper<Mutex> > l_) : > m(*(const_cast<thread_detail::lockable_wrapper<Mutex>*>(l_.begin())->m)) > { > m.lock(); > } > > lock_guard(std::initializer_list<thread_detail::lockable_adopt_wrapper<Mutex> > l_) : > m(*(const_cast<thread_detail::lockable_adopt_wrapper<Mutex>*>(l_.begin())->m)) > { > > > > } > > > ~lock_guard() > { > m.unlock(); > } > }; > > > > template <typename Lockable> > lock_guard<Lockable> make_lock_guard(Lockable& mtx) > { > return { thread_detail::lockable_wrapper<Lockable>(mtx) }; > } > template <typename Lockable> > lock_guard<Lockable> make_lock_guard(Lockable& mtx, adopt_lock_t) > { > return { thread_detail::lockable_adopt_wrapper<Lockable>(mtx) }; > } > >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 87 "/usr/include/boost/thread/lock_guard.hpp" 2 3 4 ># 12 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/lock_types.hpp" 1 3 4 ># 14 "/usr/include/boost/thread/lock_types.hpp" 3 4 ># 1 "/usr/include/boost/thread/lockable_traits.hpp" 1 3 4 ># 12 "/usr/include/boost/thread/lockable_traits.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 13 "/usr/include/boost/thread/lockable_traits.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 17 "/usr/include/boost/thread/lockable_traits.hpp" 2 3 4 > > > >namespace boost >{ > namespace sync > { ># 34 "/usr/include/boost/thread/lockable_traits.hpp" 3 4 > namespace detail > { ># 70 "/usr/include/boost/thread/lockable_traits.hpp" 3 4 > template<typename T, bool=boost::is_class<T>::value> struct has_member_called_lock { static const bool value=false; }; template<typename T> struct has_member_called_lock<T,true> { typedef char true_type; struct false_type { true_type dummy[2]; }; struct fallback { int lock; }; struct derived: T, fallback { derived(); }; template<int fallback::*> struct tester; template<typename U> static false_type has_member(tester<&U::lock>*); template<typename U> static true_type has_member(...); static const bool value=sizeof(has_member<derived>(0))==sizeof(true_type); } >; template<typename T, bool=boost::is_class<T>::value> struct has_member_called_unlock { static const bool value=false; }; template<typename T> struct has_member_called_unlock<T,true> { typedef char true_type; struct false_type { true_type dummy[2]; }; struct fallback { int unlock; }; struct derived: T, fallback { derived(); }; template<int fallback::*> struct tester; template<typename U> static false_type has_member(tester<&U::unlock>*); template<typename U> static true_type has_member(...); static const bool value=sizeof(has_member<derived>(0))==sizeof(true_type); }; > template<typename T, bool=boost::is_class<T>::value> struct has_member_called_try_lock { static const bool value=false; }; template<typename T> struct has_member_called_try_lock<T,true> { typedef char true_type; struct false_type { true_type dummy[2]; }; struct fallback { int try_lock; }; struct derived: T, fallback { derived(); }; template<int fallback::*> struct tester; template<typename U> static false_type has_member(tester<&U::try_lock>*); template<typename U> static true_type has_member(...); static const bool value=sizeof(has_member<derived>(0))==sizeof(true_type); }; > > template<typename T,bool=has_member_called_lock<T>::value > > struct has_member_lock > { > static const bool value=false; > }; > > template<typename T> > struct has_member_lock<T,true> > { > typedef char true_type; > struct false_type > { > true_type dummy[2]; > }; > > template<typename U,typename V> > static true_type has_member(V (U::*)()); > template<typename U> > static false_type has_member(U); > > static const bool value=sizeof(has_member_lock<T>::has_member(&T::lock))==sizeof(true_type) > ; > }; > > template<typename T,bool=has_member_called_unlock<T>::value > > struct has_member_unlock > { > static const bool value=false; > }; > > template<typename T> > struct has_member_unlock<T,true> > { > typedef char true_type; > struct false_type > { > true_type dummy[2]; > }; > > template<typename U,typename V> > static true_type has_member(V (U::*)()); > template<typename U> > static false_type has_member(U); > > static const bool value=sizeof(has_member_unlock<T>::has_member(&T::unlock))==sizeof(true_type) > ; > }; > > template<typename T,bool=has_member_called_try_lock<T>::value > > struct has_member_try_lock > { > static const bool value=false; > }; > > template<typename T> > struct has_member_try_lock<T,true> > { > typedef char true_type; > struct false_type > { > true_type dummy[2]; > }; > > template<typename U> > static true_type has_member(bool (U::*)()); > template<typename U> > static false_type has_member(U); > > static const bool value=sizeof(has_member_try_lock<T>::has_member(&T::try_lock))==sizeof(true_type) > ; > }; > > } > > template<typename T> > struct is_basic_lockable > { > static const bool value = detail::has_member_lock<T>::value && detail::has_member_unlock<T>::value > ; > }; > template<typename T> > struct is_lockable > { > static const bool value = is_basic_lockable<T>::value && detail::has_member_try_lock<T>::value > > ; > }; ># 175 "/usr/include/boost/thread/lockable_traits.hpp" 3 4 > template<typename T> > struct is_recursive_mutex_sur_parole > { > static const bool value = false; > }; > template<typename T> > struct is_recursive_mutex_sur_parolle : is_recursive_mutex_sur_parole<T> > { > }; > > template<typename T> > struct is_recursive_basic_lockable > { > static const bool value = is_basic_lockable<T>::value && is_recursive_mutex_sur_parolle<T>::value > ; > }; > template<typename T> > struct is_recursive_lockable > { > static const bool value = is_lockable<T>::value && is_recursive_mutex_sur_parolle<T>::value > ; > }; > } > template<typename T> > struct is_mutex_type > { > static const bool value = sync::is_lockable<T>::value; > }; > >} ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 206 "/usr/include/boost/thread/lockable_traits.hpp" 2 3 4 ># 15 "/usr/include/boost/thread/lock_types.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/thread/thread_time.hpp" 1 3 4 ># 9 "/usr/include/boost/thread/thread_time.hpp" 3 4 ># 1 "/usr/include/boost/date_time/time_clock.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/time_clock.hpp" 3 4 ># 1 "/usr/include/boost/date_time/c_time.hpp" 1 3 4 ># 17 "/usr/include/boost/date_time/c_time.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/ctime" 1 3 4 ># 39 "/usr/include/c++/4.9.0/ctime" 3 4 ># 40 "/usr/include/c++/4.9.0/ctime" 3 ># 18 "/usr/include/boost/date_time/c_time.hpp" 2 3 4 > > ># 1 "/usr/include/boost/throw_exception.hpp" 1 3 4 ># 5 "/usr/include/boost/throw_exception.hpp" 3 ># 29 "/usr/include/boost/throw_exception.hpp" 3 ># 1 "/usr/include/boost/exception/detail/attribute_noreturn.hpp" 1 3 4 ># 30 "/usr/include/boost/throw_exception.hpp" 2 3 ># 43 "/usr/include/boost/throw_exception.hpp" 3 ># 1 "/usr/include/boost/exception/exception.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/exception.hpp" 3 4 ># 10 "/usr/include/boost/exception/exception.hpp" 3 > > > > > >namespace >boost > { > namespace > exception_detail > { > template <class T> > 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 Tag,class T> > class error_info; > > typedef error_info<struct throw_function_,char const *> throw_function; > typedef error_info<struct throw_file_,char const *> throw_file; > typedef error_info<struct throw_line_,int> throw_line; > > template <> > class > error_info<throw_function_,char const *> > { > public: > typedef char const * value_type; > value_type v_; > explicit > error_info( value_type v ): > v_(v) > { > } > }; > > template <> > class > error_info<throw_file_,char const *> > { > public: > typedef char const * value_type; > value_type v_; > explicit > error_info( value_type v ): > v_(v) > { > } > }; > > template <> > class > error_info<throw_line_,int> > { > public: > typedef int value_type; > value_type v_; > explicit > error_info( value_type v ): > v_(v) > { > } > }; > > > >#pragma GCC visibility push (default) > > > class exception; > > >#pragma GCC visibility pop > > > > template <class T> > 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<error_info_base> get( type_info_ const & ) const = 0; > virtual void set( shared_ptr<error_info_base> const &, type_info_ const & ) = 0; > virtual void add_ref() const = 0; > virtual bool release() const = 0; > virtual refcount_ptr<exception_detail::error_info_container> clone() const = 0; > > protected: > > ~error_info_container() throw() > { > } > }; > > template <class> > struct get_info; > > template <> > struct get_info<throw_function>; > > template <> > struct get_info<throw_file>; > > template <> > struct get_info<throw_line>; > > char const * get_diagnostic_information( exception const &, char const * ); > > void copy_boost_exception( exception *, exception const * ); > > template <class E,class Tag,class T> > E const & set_info( E const &, error_info<Tag,T> const & ); > > template <class E> > E const & set_info( E const &, throw_function const & ); > > template <class E> > E const & set_info( E const &, throw_file const & ); > > template <class E> > E const & set_info( E const &, throw_line const & ); > } > > > >#pragma GCC visibility push (default) > > > class > exception > { > protected: > > exception(): > throw_function_(0), > throw_file_(0), > throw_line_(-1) > { > } ># 231 "/usr/include/boost/exception/exception.hpp" 3 > virtual ~exception() throw() > > = 0 > > ; > > > > > private: > > template <class E> > friend E const & exception_detail::set_info( E const &, throw_function const & ); > > template <class E> > friend E const & exception_detail::set_info( E const &, throw_file const & ); > > template <class E> > friend E const & exception_detail::set_info( E const &, throw_line const & ); > > template <class E,class Tag,class T> > friend E const & exception_detail::set_info( E const &, error_info<Tag,T> const & ); > > friend char const * exception_detail::get_diagnostic_information( exception const &, char const * ); > > template <class> > friend struct exception_detail::get_info; > friend struct exception_detail::get_info<throw_function>; > friend struct exception_detail::get_info<throw_file>; > friend struct exception_detail::get_info<throw_line>; > friend void exception_detail::copy_boost_exception( exception *, exception const * ); > > mutable exception_detail::refcount_ptr<exception_detail::error_info_container> data_; > mutable char const * throw_function_; > mutable char const * throw_file_; > mutable int throw_line_; > }; > > >#pragma GCC visibility pop > > > > inline > exception:: > ~exception() throw() > { > } > > namespace > exception_detail > { > template <class E> > E const & > set_info( E const & x, throw_function const & y ) > { > x.throw_function_=y.v_; > return x; > } > > template <class E> > E const & > set_info( E const & x, throw_file const & y ) > { > x.throw_file_=y.v_; > return x; > } > > template <class E> > E const & > set_info( E const & x, throw_line const & y ) > { > x.throw_line_=y.v_; > return x; > } > } > > > > namespace > exception_detail > { > > >#pragma GCC visibility push (default) > > > template <class T> > struct > error_info_injector: > public T, > public exception > { > explicit > error_info_injector( T const & x ): > T(x) > { > } > > ~error_info_injector() throw() > { > } > }; > > >#pragma GCC visibility pop > > > > struct large_size { char c[256]; }; > large_size dispatch_boost_exception( exception const * ); > > struct small_size { }; > small_size dispatch_boost_exception( void const * ); > > template <class,int> > struct enable_error_info_helper; > > template <class T> > struct > enable_error_info_helper<T,sizeof(large_size)> > { > typedef T type; > }; > > template <class T> > struct > enable_error_info_helper<T,sizeof(small_size)> > { > typedef error_info_injector<T> type; > }; > > template <class T> > struct > enable_error_info_return_type > { > typedef typename enable_error_info_helper<T,sizeof(exception_detail::dispatch_boost_exception(static_cast<T *>(0)))>::type type; > }; > } > > template <class T> > inline > typename > exception_detail::enable_error_info_return_type<T>::type > enable_error_info( T const & x ) > { > typedef typename exception_detail::enable_error_info_return_type<T>::type rt; > return rt(x); > } > > > > namespace > exception_detail > { > > >#pragma GCC visibility push (default) > > > class > clone_base > { > public: > > virtual clone_base const * clone() const = 0; > virtual void rethrow() const = 0; > > virtual > ~clone_base() throw() > { > } > }; > > >#pragma GCC visibility pop > > > > inline > void > copy_boost_exception( exception * a, exception const * b ) > { > refcount_ptr<error_info_container> 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 T> > 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 <class T> > inline > exception_detail::clone_impl<T> > enable_current_exception( T const & x ) > { > return exception_detail::clone_impl<T>(x); > } > } ># 44 "/usr/include/boost/throw_exception.hpp" 2 3 > ># 1 "/usr/include/boost/current_function.hpp" 1 3 4 ># 22 "/usr/include/boost/current_function.hpp" 3 4 >namespace boost >{ > >namespace detail >{ > >inline void current_function_helper() >{ ># 61 "/usr/include/boost/current_function.hpp" 3 4 >} > >} > >} ># 46 "/usr/include/boost/throw_exception.hpp" 2 3 > > > > > > > >namespace boost >{ > > > > > > >inline void throw_exception_assert_compatibility( std::exception const & ) { } > >template<class E> __attribute__((__noreturn__)) inline void throw_exception( E const & e ) >{ > > > throw_exception_assert_compatibility(e); > > > throw enable_current_exception(enable_error_info(e)); > > > >} > > > > > namespace > exception_detail > { > template <class E> > __attribute__((__noreturn__)) > void > throw_exception_( E const & x, char const * current_function, char const * file, int line ) > { > boost::throw_exception( > set_info( > set_info( > set_info( > enable_error_info(x), > throw_function(current_function)), > throw_file(file)), > throw_line(line))); > } > } > >} ># 21 "/usr/include/boost/date_time/c_time.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/compiler_config.hpp" 1 3 4 ># 11 "/usr/include/boost/date_time/compiler_config.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 12 "/usr/include/boost/date_time/compiler_config.hpp" 2 3 4 ># 31 "/usr/include/boost/date_time/compiler_config.hpp" 3 4 ># 1 "/usr/include/boost/date_time/locale_config.hpp" 1 3 4 ># 32 "/usr/include/boost/date_time/compiler_config.hpp" 2 3 4 ># 54 "/usr/include/boost/date_time/compiler_config.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 55 "/usr/include/boost/date_time/compiler_config.hpp" 2 3 4 ># 157 "/usr/include/boost/date_time/compiler_config.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 158 "/usr/include/boost/date_time/compiler_config.hpp" 2 3 4 ># 22 "/usr/include/boost/date_time/c_time.hpp" 2 3 4 ># 31 "/usr/include/boost/date_time/c_time.hpp" 3 4 ># 1 "/usr/include/sys/time.h" 1 3 4 ># 27 "/usr/include/sys/time.h" 3 4 ># 1 "/usr/include/bits/time.h" 1 3 4 ># 28 "/usr/include/sys/time.h" 2 3 4 ># 37 "/usr/include/sys/time.h" 3 4 >extern "C" { ># 55 "/usr/include/sys/time.h" 3 4 >struct timezone > { > int tz_minuteswest; > int tz_dsttime; > }; > >typedef struct timezone *__restrict __timezone_ptr_t; ># 71 "/usr/include/sys/time.h" 3 4 >extern int gettimeofday (struct timeval *__restrict __tv, > __timezone_ptr_t __tz) throw () __attribute__ ((__nonnull__ (1))); > > > > >extern int settimeofday (const struct timeval *__tv, > const struct timezone *__tz) > throw (); > > > > > >extern int adjtime (const struct timeval *__delta, > struct timeval *__olddelta) throw (); > > > > >enum __itimer_which > { > > ITIMER_REAL = 0, > > > ITIMER_VIRTUAL = 1, > > > > ITIMER_PROF = 2 > > }; > > > >struct itimerval > { > > struct timeval it_interval; > > struct timeval it_value; > }; > > > > > > >typedef int __itimer_which_t; > > > > >extern int getitimer (__itimer_which_t __which, > struct itimerval *__value) throw (); > > > > >extern int setitimer (__itimer_which_t __which, > const struct itimerval *__restrict __new, > struct itimerval *__restrict __old) throw (); > > > > >extern int utimes (const char *__file, const struct timeval __tvp[2]) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int lutimes (const char *__file, const struct timeval __tvp[2]) > throw () __attribute__ ((__nonnull__ (1))); > > >extern int futimes (int __fd, const struct timeval __tvp[2]) throw (); > > > > > > >extern int futimesat (int __fd, const char *__file, > const struct timeval __tvp[2]) throw (); ># 189 "/usr/include/sys/time.h" 3 4 >} ># 32 "/usr/include/boost/date_time/c_time.hpp" 2 3 4 > > > > > > >namespace boost { >namespace date_time { ># 52 "/usr/include/boost/date_time/c_time.hpp" 3 4 > struct c_time { > public: > > > inline > static std::tm* localtime(const std::time_t* t, std::tm* result) > { ># 67 "/usr/include/boost/date_time/c_time.hpp" 3 4 > result = localtime_r(t, result); > > if (!result) > boost::throw_exception(std::runtime_error("could not convert calendar time to local time")); > return result; > } > > inline > static std::tm* gmtime(const std::time_t* t, std::tm* result) > { ># 85 "/usr/include/boost/date_time/c_time.hpp" 3 4 > result = gmtime_r(t, result); > > if (!result) > boost::throw_exception(std::runtime_error("could not convert calendar time to UTC time")); > return result; > } ># 120 "/usr/include/boost/date_time/c_time.hpp" 3 4 > }; >}} ># 17 "/usr/include/boost/date_time/time_clock.hpp" 2 3 4 ># 1 "/usr/include/boost/shared_ptr.hpp" 1 3 4 ># 17 "/usr/include/boost/shared_ptr.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 1 3 4 ># 27 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 ># 1 "/usr/include/boost/config/no_tr1/memory.hpp" 1 3 4 ># 21 "/usr/include/boost/config/no_tr1/memory.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/memory" 1 3 4 ># 46 "/usr/include/c++/4.9.0/memory" 3 4 ># 47 "/usr/include/c++/4.9.0/memory" 3 ># 67 "/usr/include/c++/4.9.0/memory" 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_raw_storage_iter.h" 1 3 ># 59 "/usr/include/c++/4.9.0/bits/stl_raw_storage_iter.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > template <class _OutputIterator, class _Tp> > class raw_storage_iterator > : public iterator<output_iterator_tag, void, void, void, void> > { > protected: > _OutputIterator _M_iter; > > public: > explicit > raw_storage_iterator(_OutputIterator __x) > : _M_iter(__x) {} > > raw_storage_iterator& > operator*() { return *this; } > > raw_storage_iterator& > operator=(const _Tp& __element) > { > std::_Construct(std::__addressof(*_M_iter), __element); > return *this; > } > > raw_storage_iterator<_OutputIterator, _Tp>& > operator++() > { > ++_M_iter; > return *this; > } > > raw_storage_iterator<_OutputIterator, _Tp> > operator++(int) > { > raw_storage_iterator<_OutputIterator, _Tp> __tmp = *this; > ++_M_iter; > return __tmp; > } > }; > > >} ># 68 "/usr/include/c++/4.9.0/memory" 2 3 > > > > > > ># 1 "/usr/include/c++/4.9.0/ext/concurrence.h" 1 3 ># 32 "/usr/include/c++/4.9.0/ext/concurrence.h" 3 ># 33 "/usr/include/c++/4.9.0/ext/concurrence.h" 3 > > > > > > > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > > enum _Lock_policy { _S_single, _S_mutex, _S_atomic }; > > > > static const _Lock_policy __default_lock_policy = > > > > _S_atomic; ># 67 "/usr/include/c++/4.9.0/ext/concurrence.h" 3 > class __concurrence_lock_error : public std::exception > { > public: > virtual char const* > what() const throw() > { return "__gnu_cxx::__concurrence_lock_error"; } > }; > > class __concurrence_unlock_error : public std::exception > { > public: > virtual char const* > what() const throw() > { return "__gnu_cxx::__concurrence_unlock_error"; } > }; > > class __concurrence_broadcast_error : public std::exception > { > public: > virtual char const* > what() const throw() > { return "__gnu_cxx::__concurrence_broadcast_error"; } > }; > > class __concurrence_wait_error : public std::exception > { > public: > virtual char const* > what() const throw() > { return "__gnu_cxx::__concurrence_wait_error"; } > }; > > > inline void > __throw_concurrence_lock_error() > { (throw (__concurrence_lock_error())); } > > inline void > __throw_concurrence_unlock_error() > { (throw (__concurrence_unlock_error())); } > > > inline void > __throw_concurrence_broadcast_error() > { (throw (__concurrence_broadcast_error())); } > > inline void > __throw_concurrence_wait_error() > { (throw (__concurrence_wait_error())); } > > > class __mutex > { > private: > > __gthread_mutex_t _M_mutex = { { 0, 0, 0, 0, 0, 0, 0, { 0, 0 } } }; > > > > > __mutex(const __mutex&); > __mutex& operator=(const __mutex&); > > public: > __mutex() > { > > > > > } ># 147 "/usr/include/c++/4.9.0/ext/concurrence.h" 3 > void lock() > { > > if (__gthread_active_p()) > { > if (__gthread_mutex_lock(&_M_mutex) != 0) > __throw_concurrence_lock_error(); > } > > } > > void unlock() > { > > if (__gthread_active_p()) > { > if (__gthread_mutex_unlock(&_M_mutex) != 0) > __throw_concurrence_unlock_error(); > } > > } > > __gthread_mutex_t* gthread_mutex(void) > { return &_M_mutex; } > }; > > class __recursive_mutex > { > private: > > __gthread_recursive_mutex_t _M_mutex = { { 0, 0, 0, 0, PTHREAD_MUTEX_RECURSIVE_NP, 0, 0, { 0, 0 } } }; > > > > > __recursive_mutex(const __recursive_mutex&); > __recursive_mutex& operator=(const __recursive_mutex&); > > public: > __recursive_mutex() > { > > > > > } ># 202 "/usr/include/c++/4.9.0/ext/concurrence.h" 3 > void lock() > { > > if (__gthread_active_p()) > { > if (__gthread_recursive_mutex_lock(&_M_mutex) != 0) > __throw_concurrence_lock_error(); > } > > } > > void unlock() > { > > if (__gthread_active_p()) > { > if (__gthread_recursive_mutex_unlock(&_M_mutex) != 0) > __throw_concurrence_unlock_error(); > } > > } > > __gthread_recursive_mutex_t* gthread_recursive_mutex(void) > { return &_M_mutex; } > }; > > > > > class __scoped_lock > { > public: > typedef __mutex __mutex_type; > > private: > __mutex_type& _M_device; > > __scoped_lock(const __scoped_lock&); > __scoped_lock& operator=(const __scoped_lock&); > > public: > explicit __scoped_lock(__mutex_type& __name) : _M_device(__name) > { _M_device.lock(); } > > ~__scoped_lock() throw() > { _M_device.unlock(); } > }; > > > class __cond > { > private: > > __gthread_cond_t _M_cond = { { 0, 0, 0, 0, 0, (void *) 0, 0, 0 } }; > > > > > __cond(const __cond&); > __cond& operator=(const __cond&); > > public: > __cond() > { > > > > > } ># 280 "/usr/include/c++/4.9.0/ext/concurrence.h" 3 > void broadcast() > { > > if (__gthread_active_p()) > { > if (__gthread_cond_broadcast(&_M_cond) != 0) > __throw_concurrence_broadcast_error(); > } > > } > > void wait(__mutex *mutex) > { > > { > if (__gthread_cond_wait(&_M_cond, mutex->gthread_mutex()) != 0) > __throw_concurrence_wait_error(); > } > > } > > void wait_recursive(__recursive_mutex *mutex) > { > > { > if (__gthread_cond_wait_recursive(&_M_cond, > mutex->gthread_recursive_mutex()) > != 0) > __throw_concurrence_wait_error(); > } > > } > }; > > > >} ># 75 "/usr/include/c++/4.9.0/memory" 2 3 > > > > > > ># 1 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 1 3 ># 39 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 49 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > template<typename> class auto_ptr; > > > > template<typename _Tp> > struct default_delete > { > > constexpr default_delete() noexcept = default; > > > > > > > template<typename _Up, typename = typename > enable_if<is_convertible<_Up*, _Tp*>::value>::type> > default_delete(const default_delete<_Up>&) noexcept { } > > > void > operator()(_Tp* __ptr) const > { > static_assert(!is_void<_Tp>::value, > "can't delete pointer to incomplete type"); > static_assert(sizeof(_Tp)>0, > "can't delete pointer to incomplete type"); > delete __ptr; > } > }; > > > > > template<typename _Tp> > struct default_delete<_Tp[]> > { > private: > template<typename _Up> > using __remove_cv = typename remove_cv<_Up>::type; > > > template<typename _Up> > using __is_derived_Tp > = __and_< is_base_of<_Tp, _Up>, > __not_<is_same<__remove_cv<_Tp>, __remove_cv<_Up>>> >; > > public: > > constexpr default_delete() noexcept = default; ># 109 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > template<typename _Up, typename = typename > enable_if<!__is_derived_Tp<_Up>::value>::type> > default_delete(const default_delete<_Up[]>&) noexcept { } > > > void > operator()(_Tp* __ptr) const > { > static_assert(sizeof(_Tp)>0, > "can't delete pointer to incomplete type"); > delete [] __ptr; > } > > template<typename _Up> > typename enable_if<__is_derived_Tp<_Up>::value>::type > operator()(_Up*) const = delete; > }; > > > template <typename _Tp, typename _Dp = default_delete<_Tp> > > class unique_ptr > { > > class _Pointer > { > template<typename _Up> > static typename _Up::pointer __test(typename _Up::pointer*); > > template<typename _Up> > static _Tp* __test(...); > > typedef typename remove_reference<_Dp>::type _Del; > > public: > typedef decltype(__test<_Del>(0)) type; > }; > > typedef std::tuple<typename _Pointer::type, _Dp> __tuple_type; > __tuple_type _M_t; > > public: > typedef typename _Pointer::type pointer; > typedef _Tp element_type; > typedef _Dp deleter_type; > > > > > constexpr unique_ptr() noexcept > : _M_t() > { static_assert(!is_pointer<deleter_type>::value, > "constructed with null function pointer deleter"); } > > > > > > > > explicit > unique_ptr(pointer __p) noexcept > : _M_t(__p, deleter_type()) > { static_assert(!is_pointer<deleter_type>::value, > "constructed with null function pointer deleter"); } ># 181 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > unique_ptr(pointer __p, > typename conditional<is_reference<deleter_type>::value, > deleter_type, const deleter_type&>::type __d) noexcept > : _M_t(__p, __d) { } ># 193 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > unique_ptr(pointer __p, > typename remove_reference<deleter_type>::type&& __d) noexcept > : _M_t(std::move(__p), std::move(__d)) > { static_assert(!std::is_reference<deleter_type>::value, > "rvalue deleter bound to reference"); } > > > constexpr unique_ptr(nullptr_t) noexcept : unique_ptr() { } > > > > > unique_ptr(unique_ptr&& __u) noexcept > : _M_t(__u.release(), std::forward<deleter_type>(__u.get_deleter())) { } > > > > > > > > template<typename _Up, typename _Ep, typename = _Require< > is_convertible<typename unique_ptr<_Up, _Ep>::pointer, pointer>, > __not_<is_array<_Up>>, > typename conditional<is_reference<_Dp>::value, > is_same<_Ep, _Dp>, > is_convertible<_Ep, _Dp>>::type>> > unique_ptr(unique_ptr<_Up, _Ep>&& __u) noexcept > : _M_t(__u.release(), std::forward<_Ep>(__u.get_deleter())) > { } > > > > template<typename _Up, typename = _Require< > is_convertible<_Up*, _Tp*>, is_same<_Dp, default_delete<_Tp>>>> > unique_ptr(auto_ptr<_Up>&& __u) noexcept; > > > > ~unique_ptr() noexcept > { > auto& __ptr = std::get<0>(_M_t); > if (__ptr != nullptr) > get_deleter()(__ptr); > __ptr = pointer(); > } ># 248 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > unique_ptr& > operator=(unique_ptr&& __u) noexcept > { > reset(__u.release()); > get_deleter() = std::forward<deleter_type>(__u.get_deleter()); > return *this; > } ># 263 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > template<typename _Up, typename _Ep> > typename enable_if< __and_< > is_convertible<typename unique_ptr<_Up, _Ep>::pointer, pointer>, > __not_<is_array<_Up>> > >::value, > unique_ptr&>::type > operator=(unique_ptr<_Up, _Ep>&& __u) noexcept > { > reset(__u.release()); > get_deleter() = std::forward<_Ep>(__u.get_deleter()); > return *this; > } > > > unique_ptr& > operator=(nullptr_t) noexcept > { > reset(); > return *this; > } > > > > > typename add_lvalue_reference<element_type>::type > operator*() const > { > ; > return *get(); > } > > > pointer > operator->() const noexcept > { > ; > return get(); > } > > > pointer > get() const noexcept > { return std::get<0>(_M_t); } > > > deleter_type& > get_deleter() noexcept > { return std::get<1>(_M_t); } > > > const deleter_type& > get_deleter() const noexcept > { return std::get<1>(_M_t); } > > > explicit operator bool() const noexcept > { return get() == pointer() ? false : true; } > > > > > pointer > release() noexcept > { > pointer __p = get(); > std::get<0>(_M_t) = pointer(); > return __p; > } > > > > > > > > void > reset(pointer __p = pointer()) noexcept > { > using std::swap; > swap(std::get<0>(_M_t), __p); > if (__p != pointer()) > get_deleter()(__p); > } > > > void > swap(unique_ptr& __u) noexcept > { > using std::swap; > swap(_M_t, __u._M_t); > } > > > unique_ptr(const unique_ptr&) = delete; > unique_ptr& operator=(const unique_ptr&) = delete; > }; > > > > > > template<typename _Tp, typename _Dp> > class unique_ptr<_Tp[], _Dp> > { > > class _Pointer > { > template<typename _Up> > static typename _Up::pointer __test(typename _Up::pointer*); > > template<typename _Up> > static _Tp* __test(...); > > typedef typename remove_reference<_Dp>::type _Del; > > public: > typedef decltype(__test<_Del>(0)) type; > }; > > typedef std::tuple<typename _Pointer::type, _Dp> __tuple_type; > __tuple_type _M_t; > > template<typename _Up> > using __remove_cv = typename remove_cv<_Up>::type; > > > template<typename _Up> > using __is_derived_Tp > = __and_< is_base_of<_Tp, _Up>, > __not_<is_same<__remove_cv<_Tp>, __remove_cv<_Up>>> >; > > template<typename _Up, typename _Ep, > typename _Tp_pointer = typename _Pointer::type, > typename _Up_pointer = typename unique_ptr<_Up, _Ep>::pointer> > using __safe_conversion = __and_< > is_convertible<_Up_pointer, _Tp_pointer>, > is_array<_Up>, > __or_<__not_<is_pointer<_Up_pointer>>, > __not_<is_pointer<_Tp_pointer>>, > __not_<__is_derived_Tp<typename remove_extent<_Up>::type>> > > > >; > > public: > typedef typename _Pointer::type pointer; > typedef _Tp element_type; > typedef _Dp deleter_type; > > > > > constexpr unique_ptr() noexcept > : _M_t() > { static_assert(!std::is_pointer<deleter_type>::value, > "constructed with null function pointer deleter"); } > > > > > > > > explicit > unique_ptr(pointer __p) noexcept > : _M_t(__p, deleter_type()) > { static_assert(!is_pointer<deleter_type>::value, > "constructed with null function pointer deleter"); } > > > template<typename _Up, typename = _Require<is_pointer<pointer>, > is_convertible<_Up*, pointer>, __is_derived_Tp<_Up>>> > explicit > unique_ptr(_Up* __p) = delete; ># 444 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > unique_ptr(pointer __p, > typename conditional<is_reference<deleter_type>::value, > deleter_type, const deleter_type&>::type __d) noexcept > : _M_t(__p, __d) { } ># 456 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > unique_ptr(pointer __p, typename > remove_reference<deleter_type>::type&& __d) noexcept > : _M_t(std::move(__p), std::move(__d)) > { static_assert(!is_reference<deleter_type>::value, > "rvalue deleter bound to reference"); } > > > unique_ptr(unique_ptr&& __u) noexcept > : _M_t(__u.release(), std::forward<deleter_type>(__u.get_deleter())) { } > > > constexpr unique_ptr(nullptr_t) noexcept : unique_ptr() { } > > template<typename _Up, typename _Ep, > typename = _Require<__safe_conversion<_Up, _Ep>, > typename conditional<is_reference<_Dp>::value, > is_same<_Ep, _Dp>, > is_convertible<_Ep, _Dp>>::type > >> > unique_ptr(unique_ptr<_Up, _Ep>&& __u) noexcept > : _M_t(__u.release(), std::forward<_Ep>(__u.get_deleter())) > { } > > > ~unique_ptr() > { > auto& __ptr = std::get<0>(_M_t); > if (__ptr != nullptr) > get_deleter()(__ptr); > __ptr = pointer(); > } ># 496 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > unique_ptr& > operator=(unique_ptr&& __u) noexcept > { > reset(__u.release()); > get_deleter() = std::forward<deleter_type>(__u.get_deleter()); > return *this; > } ># 511 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > template<typename _Up, typename _Ep> > typename > enable_if<__safe_conversion<_Up, _Ep>::value, unique_ptr&>::type > operator=(unique_ptr<_Up, _Ep>&& __u) noexcept > { > reset(__u.release()); > get_deleter() = std::forward<_Ep>(__u.get_deleter()); > return *this; > } > > > unique_ptr& > operator=(nullptr_t) noexcept > { > reset(); > return *this; > } > > > > > typename std::add_lvalue_reference<element_type>::type > operator[](size_t __i) const > { > ; > return get()[__i]; > } > > > pointer > get() const noexcept > { return std::get<0>(_M_t); } > > > deleter_type& > get_deleter() noexcept > { return std::get<1>(_M_t); } > > > const deleter_type& > get_deleter() const noexcept > { return std::get<1>(_M_t); } > > > explicit operator bool() const noexcept > { return get() == pointer() ? false : true; } > > > > > pointer > release() noexcept > { > pointer __p = get(); > std::get<0>(_M_t) = pointer(); > return __p; > } > > > > > > > > void > reset(pointer __p = pointer()) noexcept > { > using std::swap; > swap(std::get<0>(_M_t), __p); > if (__p != nullptr) > get_deleter()(__p); > } > > > template<typename _Up, typename = _Require<is_pointer<pointer>, > is_convertible<_Up*, pointer>, __is_derived_Tp<_Up>>> > void reset(_Up*) = delete; > > > void > swap(unique_ptr& __u) noexcept > { > using std::swap; > swap(_M_t, __u._M_t); > } > > > unique_ptr(const unique_ptr&) = delete; > unique_ptr& operator=(const unique_ptr&) = delete; > > > template<typename _Up, typename = _Require<is_pointer<pointer>, > is_convertible<_Up*, pointer>, __is_derived_Tp<_Up>>> > unique_ptr(_Up*, typename > conditional<is_reference<deleter_type>::value, > deleter_type, const deleter_type&>::type) = delete; > > > template<typename _Up, typename = _Require<is_pointer<pointer>, > is_convertible<_Up*, pointer>, __is_derived_Tp<_Up>>> > unique_ptr(_Up*, typename > remove_reference<deleter_type>::type&&) = delete; > }; > > template<typename _Tp, typename _Dp> > inline void > swap(unique_ptr<_Tp, _Dp>& __x, > unique_ptr<_Tp, _Dp>& __y) noexcept > { __x.swap(__y); } > > template<typename _Tp, typename _Dp, > typename _Up, typename _Ep> > inline bool > operator==(const unique_ptr<_Tp, _Dp>& __x, > const unique_ptr<_Up, _Ep>& __y) > { return __x.get() == __y.get(); } > > template<typename _Tp, typename _Dp> > inline bool > operator==(const unique_ptr<_Tp, _Dp>& __x, nullptr_t) noexcept > { return !__x; } > > template<typename _Tp, typename _Dp> > inline bool > operator==(nullptr_t, const unique_ptr<_Tp, _Dp>& __x) noexcept > { return !__x; } > > template<typename _Tp, typename _Dp, > typename _Up, typename _Ep> > inline bool > operator!=(const unique_ptr<_Tp, _Dp>& __x, > const unique_ptr<_Up, _Ep>& __y) > { return __x.get() != __y.get(); } > > template<typename _Tp, typename _Dp> > inline bool > operator!=(const unique_ptr<_Tp, _Dp>& __x, nullptr_t) noexcept > { return (bool)__x; } > > template<typename _Tp, typename _Dp> > inline bool > operator!=(nullptr_t, const unique_ptr<_Tp, _Dp>& __x) noexcept > { return (bool)__x; } > > template<typename _Tp, typename _Dp, > typename _Up, typename _Ep> > inline bool > operator<(const unique_ptr<_Tp, _Dp>& __x, > const unique_ptr<_Up, _Ep>& __y) > { > typedef typename > std::common_type<typename unique_ptr<_Tp, _Dp>::pointer, > typename unique_ptr<_Up, _Ep>::pointer>::type _CT; > return std::less<_CT>()(__x.get(), __y.get()); > } > > template<typename _Tp, typename _Dp> > inline bool > operator<(const unique_ptr<_Tp, _Dp>& __x, nullptr_t) > { return std::less<typename unique_ptr<_Tp, _Dp>::pointer>()(__x.get(), > nullptr); } > > template<typename _Tp, typename _Dp> > inline bool > operator<(nullptr_t, const unique_ptr<_Tp, _Dp>& __x) > { return std::less<typename unique_ptr<_Tp, _Dp>::pointer>()(nullptr, > __x.get()); } > > template<typename _Tp, typename _Dp, > typename _Up, typename _Ep> > inline bool > operator<=(const unique_ptr<_Tp, _Dp>& __x, > const unique_ptr<_Up, _Ep>& __y) > { return !(__y < __x); } > > template<typename _Tp, typename _Dp> > inline bool > operator<=(const unique_ptr<_Tp, _Dp>& __x, nullptr_t) > { return !(nullptr < __x); } > > template<typename _Tp, typename _Dp> > inline bool > operator<=(nullptr_t, const unique_ptr<_Tp, _Dp>& __x) > { return !(__x < nullptr); } > > template<typename _Tp, typename _Dp, > typename _Up, typename _Ep> > inline bool > operator>(const unique_ptr<_Tp, _Dp>& __x, > const unique_ptr<_Up, _Ep>& __y) > { return (__y < __x); } > > template<typename _Tp, typename _Dp> > inline bool > operator>(const unique_ptr<_Tp, _Dp>& __x, nullptr_t) > { return std::less<typename unique_ptr<_Tp, _Dp>::pointer>()(nullptr, > __x.get()); } > > template<typename _Tp, typename _Dp> > inline bool > operator>(nullptr_t, const unique_ptr<_Tp, _Dp>& __x) > { return std::less<typename unique_ptr<_Tp, _Dp>::pointer>()(__x.get(), > nullptr); } > > template<typename _Tp, typename _Dp, > typename _Up, typename _Ep> > inline bool > operator>=(const unique_ptr<_Tp, _Dp>& __x, > const unique_ptr<_Up, _Ep>& __y) > { return !(__x < __y); } > > template<typename _Tp, typename _Dp> > inline bool > operator>=(const unique_ptr<_Tp, _Dp>& __x, nullptr_t) > { return !(__x < nullptr); } > > template<typename _Tp, typename _Dp> > inline bool > operator>=(nullptr_t, const unique_ptr<_Tp, _Dp>& __x) > { return !(nullptr < __x); } > > > template<typename _Tp, typename _Dp> > struct hash<unique_ptr<_Tp, _Dp>> > : public __hash_base<size_t, unique_ptr<_Tp, _Dp>> > { > size_t > operator()(const unique_ptr<_Tp, _Dp>& __u) const noexcept > { > typedef unique_ptr<_Tp, _Dp> _UP; > return std::hash<typename _UP::pointer>()(__u.get()); > } > }; ># 778 "/usr/include/c++/4.9.0/bits/unique_ptr.h" 3 > >} ># 82 "/usr/include/c++/4.9.0/memory" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 1 3 ># 52 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 ># 1 "/usr/include/c++/4.9.0/bits/shared_ptr_base.h" 1 3 ># 54 "/usr/include/c++/4.9.0/bits/shared_ptr_base.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template<typename> class auto_ptr; > > > > > > > class bad_weak_ptr : public std::exception > { > public: > virtual char const* > what() const noexcept; > > virtual ~bad_weak_ptr() noexcept; > }; > > > inline void > __throw_bad_weak_ptr() > { (throw (bad_weak_ptr())); } > > using __gnu_cxx::_Lock_policy; > using __gnu_cxx::__default_lock_policy; > using __gnu_cxx::_S_single; > using __gnu_cxx::_S_mutex; > using __gnu_cxx::_S_atomic; > > > template<_Lock_policy _Lp> > class _Mutex_base > { > protected: > > enum { _S_need_barriers = 0 }; > }; > > template<> > class _Mutex_base<_S_mutex> > : public __gnu_cxx::__mutex > { > protected: > > > > enum { _S_need_barriers = 1 }; > }; > > template<_Lock_policy _Lp = __default_lock_policy> > class _Sp_counted_base > : public _Mutex_base<_Lp> > { > public: > _Sp_counted_base() noexcept > : _M_use_count(1), _M_weak_count(1) { } > > virtual > ~_Sp_counted_base() noexcept > { } > > > > virtual void > _M_dispose() noexcept = 0; > > > virtual void > _M_destroy() noexcept > { delete this; } > > virtual void* > _M_get_deleter(const std::type_info&) noexcept = 0; > > void > _M_add_ref_copy() > { __gnu_cxx::__atomic_add_dispatch(&_M_use_count, 1); } > > void > _M_add_ref_lock(); > > bool > _M_add_ref_lock_nothrow(); > > void > _M_release() noexcept > { > > ; > if (__gnu_cxx::__exchange_and_add_dispatch(&_M_use_count, -1) == 1) > { > ; > _M_dispose(); > > > > > if (_Mutex_base<_Lp>::_S_need_barriers) > { > __asm __volatile ("":::"memory"); > __asm __volatile ("":::"memory"); > } > > > ; > if (__gnu_cxx::__exchange_and_add_dispatch(&_M_weak_count, > -1) == 1) > { > ; > _M_destroy(); > } > } > } > > void > _M_weak_add_ref() noexcept > { __gnu_cxx::__atomic_add_dispatch(&_M_weak_count, 1); } > > void > _M_weak_release() noexcept > { > > ; > if (__gnu_cxx::__exchange_and_add_dispatch(&_M_weak_count, -1) == 1) > { > ; > if (_Mutex_base<_Lp>::_S_need_barriers) > { > > > __asm __volatile ("":::"memory"); > __asm __volatile ("":::"memory"); > } > _M_destroy(); > } > } > > long > _M_get_use_count() const noexcept > { > > > return __atomic_load_n(&_M_use_count, 0); > } > > private: > _Sp_counted_base(_Sp_counted_base const&) = delete; > _Sp_counted_base& operator=(_Sp_counted_base const&) = delete; > > _Atomic_word _M_use_count; > _Atomic_word _M_weak_count; > }; > > template<> > inline void > _Sp_counted_base<_S_single>:: > _M_add_ref_lock() > { > if (_M_use_count == 0) > __throw_bad_weak_ptr(); > ++_M_use_count; > } > > template<> > inline void > _Sp_counted_base<_S_mutex>:: > _M_add_ref_lock() > { > __gnu_cxx::__scoped_lock sentry(*this); > if (__gnu_cxx::__exchange_and_add_dispatch(&_M_use_count, 1) == 0) > { > _M_use_count = 0; > __throw_bad_weak_ptr(); > } > } > > template<> > inline void > _Sp_counted_base<_S_atomic>:: > _M_add_ref_lock() > { > > _Atomic_word __count = _M_get_use_count(); > do > { > if (__count == 0) > __throw_bad_weak_ptr(); > > > } > while (!__atomic_compare_exchange_n(&_M_use_count, &__count, __count + 1, > true, 4, > 0)); > } > > template<> > inline bool > _Sp_counted_base<_S_single>:: > _M_add_ref_lock_nothrow() > { > if (_M_use_count == 0) > return false; > ++_M_use_count; > return true; > } > > template<> > inline bool > _Sp_counted_base<_S_mutex>:: > _M_add_ref_lock_nothrow() > { > __gnu_cxx::__scoped_lock sentry(*this); > if (__gnu_cxx::__exchange_and_add_dispatch(&_M_use_count, 1) == 0) > { > _M_use_count = 0; > return false; > } > return true; > } > > template<> > inline bool > _Sp_counted_base<_S_atomic>:: > _M_add_ref_lock_nothrow() > { > > _Atomic_word __count = _M_get_use_count(); > do > { > if (__count == 0) > return false; > > > } > while (!__atomic_compare_exchange_n(&_M_use_count, &__count, __count + 1, > true, 4, > 0)); > return true; > } > > template<> > inline void > _Sp_counted_base<_S_single>::_M_add_ref_copy() > { ++_M_use_count; } > > template<> > inline void > _Sp_counted_base<_S_single>::_M_release() noexcept > { > if (--_M_use_count == 0) > { > _M_dispose(); > if (--_M_weak_count == 0) > _M_destroy(); > } > } > > template<> > inline void > _Sp_counted_base<_S_single>::_M_weak_add_ref() noexcept > { ++_M_weak_count; } > > template<> > inline void > _Sp_counted_base<_S_single>::_M_weak_release() noexcept > { > if (--_M_weak_count == 0) > _M_destroy(); > } > > template<> > inline long > _Sp_counted_base<_S_single>::_M_get_use_count() const noexcept > { return _M_use_count; } > > > > template<typename _Tp, _Lock_policy _Lp = __default_lock_policy> > class __shared_ptr; > > template<typename _Tp, _Lock_policy _Lp = __default_lock_policy> > class __weak_ptr; > > template<typename _Tp, _Lock_policy _Lp = __default_lock_policy> > class __enable_shared_from_this; > > template<typename _Tp> > class shared_ptr; > > template<typename _Tp> > class weak_ptr; > > template<typename _Tp> > struct owner_less; > > template<typename _Tp> > class enable_shared_from_this; > > template<_Lock_policy _Lp = __default_lock_policy> > class __weak_count; > > template<_Lock_policy _Lp = __default_lock_policy> > class __shared_count; > > > > template<typename _Ptr, _Lock_policy _Lp> > class _Sp_counted_ptr final : public _Sp_counted_base<_Lp> > { > public: > explicit > _Sp_counted_ptr(_Ptr __p) noexcept > : _M_ptr(__p) { } > > virtual void > _M_dispose() noexcept > { delete _M_ptr; } > > virtual void > _M_destroy() noexcept > { delete this; } > > virtual void* > _M_get_deleter(const std::type_info&) noexcept > { return nullptr; } > > _Sp_counted_ptr(const _Sp_counted_ptr&) = delete; > _Sp_counted_ptr& operator=(const _Sp_counted_ptr&) = delete; > > private: > _Ptr _M_ptr; > }; > > template<> > inline void > _Sp_counted_ptr<nullptr_t, _S_single>::_M_dispose() noexcept { } > > template<> > inline void > _Sp_counted_ptr<nullptr_t, _S_mutex>::_M_dispose() noexcept { } > > template<> > inline void > _Sp_counted_ptr<nullptr_t, _S_atomic>::_M_dispose() noexcept { } > > template<int _Nm, typename _Tp, > bool __use_ebo = !__is_final(_Tp) && __is_empty(_Tp)> > struct _Sp_ebo_helper; > > > template<int _Nm, typename _Tp> > struct _Sp_ebo_helper<_Nm, _Tp, true> : private _Tp > { > explicit _Sp_ebo_helper(const _Tp& __tp) : _Tp(__tp) { } > > static _Tp& > _S_get(_Sp_ebo_helper& __eboh) { return static_cast<_Tp&>(__eboh); } > }; > > > template<int _Nm, typename _Tp> > struct _Sp_ebo_helper<_Nm, _Tp, false> > { > explicit _Sp_ebo_helper(const _Tp& __tp) : _M_tp(__tp) { } > > static _Tp& > _S_get(_Sp_ebo_helper& __eboh) > { return __eboh._M_tp; } > > private: > _Tp _M_tp; > }; > > > template<typename _Ptr, typename _Deleter, typename _Alloc, _Lock_policy _Lp> > class _Sp_counted_deleter final : public _Sp_counted_base<_Lp> > { > class _Impl : _Sp_ebo_helper<0, _Deleter>, _Sp_ebo_helper<1, _Alloc> > { > typedef _Sp_ebo_helper<0, _Deleter> _Del_base; > typedef _Sp_ebo_helper<1, _Alloc> _Alloc_base; > > public: > _Impl(_Ptr __p, _Deleter __d, const _Alloc& __a) noexcept > : _M_ptr(__p), _Del_base(__d), _Alloc_base(__a) > { } > > _Deleter& _M_del() noexcept { return _Del_base::_S_get(*this); } > _Alloc& _M_alloc() noexcept { return _Alloc_base::_S_get(*this); } > > _Ptr _M_ptr; > }; > > public: > > _Sp_counted_deleter(_Ptr __p, _Deleter __d) noexcept > : _M_impl(__p, __d, _Alloc()) { } > > > _Sp_counted_deleter(_Ptr __p, _Deleter __d, const _Alloc& __a) noexcept > : _M_impl(__p, __d, __a) { } > > ~_Sp_counted_deleter() noexcept { } > > virtual void > _M_dispose() noexcept > { _M_impl._M_del()(_M_impl._M_ptr); } > > virtual void > _M_destroy() noexcept > { > typedef typename allocator_traits<_Alloc>::template > rebind_traits<_Sp_counted_deleter> _Alloc_traits; > typename _Alloc_traits::allocator_type __a(_M_impl._M_alloc()); > _Alloc_traits::destroy(__a, this); > _Alloc_traits::deallocate(__a, this, 1); > } > > virtual void* > _M_get_deleter(const std::type_info& __ti) noexcept > { > > return __ti == typeid(_Deleter) ? &_M_impl._M_del() : nullptr; > > > > } > > private: > _Impl _M_impl; > }; > > > > struct _Sp_make_shared_tag { }; > > template<typename _Tp, typename _Alloc, _Lock_policy _Lp> > class _Sp_counted_ptr_inplace final : public _Sp_counted_base<_Lp> > { > class _Impl : _Sp_ebo_helper<0, _Alloc> > { > typedef _Sp_ebo_helper<0, _Alloc> _A_base; > > public: > explicit _Impl(_Alloc __a) noexcept : _A_base(__a) { } > > _Alloc& _M_alloc() noexcept { return _A_base::_S_get(*this); } > > __gnu_cxx::__aligned_buffer<_Tp> _M_storage; > }; > > public: > template<typename... _Args> > _Sp_counted_ptr_inplace(_Alloc __a, _Args&&... __args) > : _M_impl(__a) > { > > > allocator_traits<_Alloc>::construct(__a, _M_ptr(), > std::forward<_Args>(__args)...); > } > > ~_Sp_counted_ptr_inplace() noexcept { } > > virtual void > _M_dispose() noexcept > { > allocator_traits<_Alloc>::destroy(_M_impl._M_alloc(), _M_ptr()); > } > > > virtual void > _M_destroy() noexcept > { > typedef typename allocator_traits<_Alloc>::template > rebind_traits<_Sp_counted_ptr_inplace> _Alloc_traits; > typename _Alloc_traits::allocator_type __a(_M_impl._M_alloc()); > _Alloc_traits::destroy(__a, this); > _Alloc_traits::deallocate(__a, this, 1); > } > > > virtual void* > _M_get_deleter(const std::type_info& __ti) noexcept > { > > if (__ti == typeid(_Sp_make_shared_tag)) > return const_cast<typename remove_cv<_Tp>::type*>(_M_ptr()); > > return nullptr; > } > > private: > _Tp* _M_ptr() noexcept { return _M_impl._M_storage._M_ptr(); } > > _Impl _M_impl; > }; > > > template<_Lock_policy _Lp> > class __shared_count > { > public: > constexpr __shared_count() noexcept : _M_pi(0) > { } > > template<typename _Ptr> > explicit > __shared_count(_Ptr __p) : _M_pi(0) > { > try > { > _M_pi = new _Sp_counted_ptr<_Ptr, _Lp>(__p); > } > catch(...) > { > delete __p; > throw; > } > } > > template<typename _Ptr, typename _Deleter> > __shared_count(_Ptr __p, _Deleter __d) > : __shared_count(__p, std::move(__d), allocator<void>()) > { } > > template<typename _Ptr, typename _Deleter, typename _Alloc> > __shared_count(_Ptr __p, _Deleter __d, _Alloc __a) : _M_pi(0) > { > typedef _Sp_counted_deleter<_Ptr, _Deleter, _Alloc, _Lp> _Sp_cd_type; > typedef typename allocator_traits<_Alloc>::template > rebind_traits<_Sp_cd_type> _Alloc_traits; > typename _Alloc_traits::allocator_type __a2(__a); > _Sp_cd_type* __mem = 0; > try > { > __mem = _Alloc_traits::allocate(__a2, 1); > _Alloc_traits::construct(__a2, __mem, > __p, std::move(__d), std::move(__a)); > _M_pi = __mem; > } > catch(...) > { > __d(__p); > if (__mem) > _Alloc_traits::deallocate(__a2, __mem, 1); > throw; > } > } > > template<typename _Tp, typename _Alloc, typename... _Args> > __shared_count(_Sp_make_shared_tag, _Tp*, const _Alloc& __a, > _Args&&... __args) > : _M_pi(0) > { > typedef _Sp_counted_ptr_inplace<_Tp, _Alloc, _Lp> _Sp_cp_type; > typedef typename allocator_traits<_Alloc>::template > rebind_traits<_Sp_cp_type> _Alloc_traits; > typename _Alloc_traits::allocator_type __a2(__a); > _Sp_cp_type* __mem = _Alloc_traits::allocate(__a2, 1); > try > { > _Alloc_traits::construct(__a2, __mem, std::move(__a), > std::forward<_Args>(__args)...); > _M_pi = __mem; > } > catch(...) > { > _Alloc_traits::deallocate(__a2, __mem, 1); > throw; > } > } > > > > template<typename _Tp> > explicit > __shared_count(std::auto_ptr<_Tp>&& __r); > > > > template<typename _Tp, typename _Del> > explicit > __shared_count(std::unique_ptr<_Tp, _Del>&& __r) : _M_pi(0) > { > using _Ptr = typename unique_ptr<_Tp, _Del>::pointer; > using _Del2 = typename conditional<is_reference<_Del>::value, > reference_wrapper<typename remove_reference<_Del>::type>, > _Del>::type; > using _Sp_cd_type > = _Sp_counted_deleter<_Ptr, _Del2, allocator<void>, _Lp>; > using _Alloc = allocator<_Sp_cd_type>; > using _Alloc_traits = allocator_traits<_Alloc>; > _Alloc __a; > _Sp_cd_type* __mem = _Alloc_traits::allocate(__a, 1); > _Alloc_traits::construct(__a, __mem, __r.release(), > __r.get_deleter()); > _M_pi = __mem; > } > > > explicit __shared_count(const __weak_count<_Lp>& __r); > > > explicit __shared_count(const __weak_count<_Lp>& __r, std::nothrow_t); > > ~__shared_count() noexcept > { > if (_M_pi != nullptr) > _M_pi->_M_release(); > } > > __shared_count(const __shared_count& __r) noexcept > : _M_pi(__r._M_pi) > { > if (_M_pi != 0) > _M_pi->_M_add_ref_copy(); > } > > __shared_count& > operator=(const __shared_count& __r) noexcept > { > _Sp_counted_base<_Lp>* __tmp = __r._M_pi; > if (__tmp != _M_pi) > { > if (__tmp != 0) > __tmp->_M_add_ref_copy(); > if (_M_pi != 0) > _M_pi->_M_release(); > _M_pi = __tmp; > } > return *this; > } > > void > _M_swap(__shared_count& __r) noexcept > { > _Sp_counted_base<_Lp>* __tmp = __r._M_pi; > __r._M_pi = _M_pi; > _M_pi = __tmp; > } > > long > _M_get_use_count() const noexcept > { return _M_pi != 0 ? _M_pi->_M_get_use_count() : 0; } > > bool > _M_unique() const noexcept > { return this->_M_get_use_count() == 1; } > > void* > _M_get_deleter(const std::type_info& __ti) const noexcept > { return _M_pi ? _M_pi->_M_get_deleter(__ti) : nullptr; } > > bool > _M_less(const __shared_count& __rhs) const noexcept > { return std::less<_Sp_counted_base<_Lp>*>()(this->_M_pi, __rhs._M_pi); } > > bool > _M_less(const __weak_count<_Lp>& __rhs) const noexcept > { return std::less<_Sp_counted_base<_Lp>*>()(this->_M_pi, __rhs._M_pi); } > > > friend inline bool > operator==(const __shared_count& __a, const __shared_count& __b) noexcept > { return __a._M_pi == __b._M_pi; } > > private: > friend class __weak_count<_Lp>; > > _Sp_counted_base<_Lp>* _M_pi; > }; > > > template<_Lock_policy _Lp> > class __weak_count > { > public: > constexpr __weak_count() noexcept : _M_pi(0) > { } > > __weak_count(const __shared_count<_Lp>& __r) noexcept > : _M_pi(__r._M_pi) > { > if (_M_pi != 0) > _M_pi->_M_weak_add_ref(); > } > > __weak_count(const __weak_count<_Lp>& __r) noexcept > : _M_pi(__r._M_pi) > { > if (_M_pi != 0) > _M_pi->_M_weak_add_ref(); > } > > ~__weak_count() noexcept > { > if (_M_pi != 0) > _M_pi->_M_weak_release(); > } > > __weak_count<_Lp>& > operator=(const __shared_count<_Lp>& __r) noexcept > { > _Sp_counted_base<_Lp>* __tmp = __r._M_pi; > if (__tmp != 0) > __tmp->_M_weak_add_ref(); > if (_M_pi != 0) > _M_pi->_M_weak_release(); > _M_pi = __tmp; > return *this; > } > > __weak_count<_Lp>& > operator=(const __weak_count<_Lp>& __r) noexcept > { > _Sp_counted_base<_Lp>* __tmp = __r._M_pi; > if (__tmp != 0) > __tmp->_M_weak_add_ref(); > if (_M_pi != 0) > _M_pi->_M_weak_release(); > _M_pi = __tmp; > return *this; > } > > void > _M_swap(__weak_count<_Lp>& __r) noexcept > { > _Sp_counted_base<_Lp>* __tmp = __r._M_pi; > __r._M_pi = _M_pi; > _M_pi = __tmp; > } > > long > _M_get_use_count() const noexcept > { return _M_pi != 0 ? _M_pi->_M_get_use_count() : 0; } > > bool > _M_less(const __weak_count& __rhs) const noexcept > { return std::less<_Sp_counted_base<_Lp>*>()(this->_M_pi, __rhs._M_pi); } > > bool > _M_less(const __shared_count<_Lp>& __rhs) const noexcept > { return std::less<_Sp_counted_base<_Lp>*>()(this->_M_pi, __rhs._M_pi); } > > > friend inline bool > operator==(const __weak_count& __a, const __weak_count& __b) noexcept > { return __a._M_pi == __b._M_pi; } > > private: > friend class __shared_count<_Lp>; > > _Sp_counted_base<_Lp>* _M_pi; > }; > > > template<_Lock_policy _Lp> > inline > __shared_count<_Lp>::__shared_count(const __weak_count<_Lp>& __r) > : _M_pi(__r._M_pi) > { > if (_M_pi != nullptr) > _M_pi->_M_add_ref_lock(); > else > __throw_bad_weak_ptr(); > } > > > template<_Lock_policy _Lp> > inline > __shared_count<_Lp>:: > __shared_count(const __weak_count<_Lp>& __r, std::nothrow_t) > : _M_pi(__r._M_pi) > { > if (_M_pi != nullptr) > if (!_M_pi->_M_add_ref_lock_nothrow()) > _M_pi = nullptr; > } > > > > > template<_Lock_policy _Lp, typename _Tp1, typename _Tp2> > void > __enable_shared_from_this_helper(const __shared_count<_Lp>&, > const __enable_shared_from_this<_Tp1, > _Lp>*, const _Tp2*) noexcept; > > > template<typename _Tp1, typename _Tp2> > void > __enable_shared_from_this_helper(const __shared_count<>&, > const enable_shared_from_this<_Tp1>*, > const _Tp2*) noexcept; > > template<_Lock_policy _Lp> > inline void > __enable_shared_from_this_helper(const __shared_count<_Lp>&, ...) noexcept > { } > > > template<typename _Tp, _Lock_policy _Lp> > class __shared_ptr > { > public: > typedef _Tp element_type; > > constexpr __shared_ptr() noexcept > : _M_ptr(0), _M_refcount() > { } > > template<typename _Tp1> > explicit __shared_ptr(_Tp1* __p) > : _M_ptr(__p), _M_refcount(__p) > { > > static_assert( !is_void<_Tp1>::value, "incomplete type" ); > static_assert( sizeof(_Tp1) > 0, "incomplete type" ); > __enable_shared_from_this_helper(_M_refcount, __p, __p); > } > > template<typename _Tp1, typename _Deleter> > __shared_ptr(_Tp1* __p, _Deleter __d) > : _M_ptr(__p), _M_refcount(__p, __d) > { > > > __enable_shared_from_this_helper(_M_refcount, __p, __p); > } > > template<typename _Tp1, typename _Deleter, typename _Alloc> > __shared_ptr(_Tp1* __p, _Deleter __d, _Alloc __a) > : _M_ptr(__p), _M_refcount(__p, __d, std::move(__a)) > { > > > __enable_shared_from_this_helper(_M_refcount, __p, __p); > } > > template<typename _Deleter> > __shared_ptr(nullptr_t __p, _Deleter __d) > : _M_ptr(0), _M_refcount(__p, __d) > { } > > template<typename _Deleter, typename _Alloc> > __shared_ptr(nullptr_t __p, _Deleter __d, _Alloc __a) > : _M_ptr(0), _M_refcount(__p, __d, std::move(__a)) > { } > > template<typename _Tp1> > __shared_ptr(const __shared_ptr<_Tp1, _Lp>& __r, _Tp* __p) noexcept > : _M_ptr(__p), _M_refcount(__r._M_refcount) > { } > > __shared_ptr(const __shared_ptr&) noexcept = default; > __shared_ptr& operator=(const __shared_ptr&) noexcept = default; > ~__shared_ptr() = default; > > template<typename _Tp1, typename = typename > std::enable_if<std::is_convertible<_Tp1*, _Tp*>::value>::type> > __shared_ptr(const __shared_ptr<_Tp1, _Lp>& __r) noexcept > : _M_ptr(__r._M_ptr), _M_refcount(__r._M_refcount) > { } > > __shared_ptr(__shared_ptr&& __r) noexcept > : _M_ptr(__r._M_ptr), _M_refcount() > { > _M_refcount._M_swap(__r._M_refcount); > __r._M_ptr = 0; > } > > template<typename _Tp1, typename = typename > std::enable_if<std::is_convertible<_Tp1*, _Tp*>::value>::type> > __shared_ptr(__shared_ptr<_Tp1, _Lp>&& __r) noexcept > : _M_ptr(__r._M_ptr), _M_refcount() > { > _M_refcount._M_swap(__r._M_refcount); > __r._M_ptr = 0; > } > > template<typename _Tp1> > explicit __shared_ptr(const __weak_ptr<_Tp1, _Lp>& __r) > : _M_refcount(__r._M_refcount) > { > > > > > _M_ptr = __r._M_ptr; > } > > > template<typename _Tp1, typename _Del> > __shared_ptr(std::unique_ptr<_Tp1, _Del>&& __r) > : _M_ptr(__r.get()), _M_refcount() > { > > auto __raw = _S_raw_ptr(__r.get()); > _M_refcount = __shared_count<_Lp>(std::move(__r)); > __enable_shared_from_this_helper(_M_refcount, __raw, __raw); > } > > > > template<typename _Tp1> > __shared_ptr(std::auto_ptr<_Tp1>&& __r); > > > > constexpr __shared_ptr(nullptr_t) noexcept > : _M_ptr(0), _M_refcount() > { } > > template<typename _Tp1> > __shared_ptr& > operator=(const __shared_ptr<_Tp1, _Lp>& __r) noexcept > { > _M_ptr = __r._M_ptr; > _M_refcount = __r._M_refcount; > return *this; > } > > > template<typename _Tp1> > __shared_ptr& > operator=(std::auto_ptr<_Tp1>&& __r) > { > __shared_ptr(std::move(__r)).swap(*this); > return *this; > } > > > __shared_ptr& > operator=(__shared_ptr&& __r) noexcept > { > __shared_ptr(std::move(__r)).swap(*this); > return *this; > } > > template<class _Tp1> > __shared_ptr& > operator=(__shared_ptr<_Tp1, _Lp>&& __r) noexcept > { > __shared_ptr(std::move(__r)).swap(*this); > return *this; > } > > template<typename _Tp1, typename _Del> > __shared_ptr& > operator=(std::unique_ptr<_Tp1, _Del>&& __r) > { > __shared_ptr(std::move(__r)).swap(*this); > return *this; > } > > void > reset() noexcept > { __shared_ptr().swap(*this); } > > template<typename _Tp1> > void > reset(_Tp1* __p) > { > > ; > __shared_ptr(__p).swap(*this); > } > > template<typename _Tp1, typename _Deleter> > void > reset(_Tp1* __p, _Deleter __d) > { __shared_ptr(__p, __d).swap(*this); } > > template<typename _Tp1, typename _Deleter, typename _Alloc> > void > reset(_Tp1* __p, _Deleter __d, _Alloc __a) > { __shared_ptr(__p, __d, std::move(__a)).swap(*this); } > > > typename std::add_lvalue_reference<_Tp>::type > operator*() const noexcept > { > ; > return *_M_ptr; > } > > _Tp* > operator->() const noexcept > { > ; > return _M_ptr; > } > > _Tp* > get() const noexcept > { return _M_ptr; } > > explicit operator bool() const > { return _M_ptr == 0 ? false : true; } > > bool > unique() const noexcept > { return _M_refcount._M_unique(); } > > long > use_count() const noexcept > { return _M_refcount._M_get_use_count(); } > > void > swap(__shared_ptr<_Tp, _Lp>& __other) noexcept > { > std::swap(_M_ptr, __other._M_ptr); > _M_refcount._M_swap(__other._M_refcount); > } > > template<typename _Tp1> > bool > owner_before(__shared_ptr<_Tp1, _Lp> const& __rhs) const > { return _M_refcount._M_less(__rhs._M_refcount); } > > template<typename _Tp1> > bool > owner_before(__weak_ptr<_Tp1, _Lp> const& __rhs) const > { return _M_refcount._M_less(__rhs._M_refcount); } > > > protected: > > template<typename _Alloc, typename... _Args> > __shared_ptr(_Sp_make_shared_tag __tag, const _Alloc& __a, > _Args&&... __args) > : _M_ptr(), _M_refcount(__tag, (_Tp*)0, __a, > std::forward<_Args>(__args)...) > { > > > void* __p = _M_refcount._M_get_deleter(typeid(__tag)); > _M_ptr = static_cast<_Tp*>(__p); > __enable_shared_from_this_helper(_M_refcount, _M_ptr, _M_ptr); > } ># 1138 "/usr/include/c++/4.9.0/bits/shared_ptr_base.h" 3 > template<typename _Tp1, _Lock_policy _Lp1, typename _Alloc, > typename... _Args> > friend __shared_ptr<_Tp1, _Lp1> > __allocate_shared(const _Alloc& __a, _Args&&... __args); > > > > __shared_ptr(const __weak_ptr<_Tp, _Lp>& __r, std::nothrow_t) > : _M_refcount(__r._M_refcount, std::nothrow) > { > _M_ptr = _M_refcount._M_get_use_count() ? __r._M_ptr : nullptr; > } > > friend class __weak_ptr<_Tp, _Lp>; > > private: > void* > _M_get_deleter(const std::type_info& __ti) const noexcept > { return _M_refcount._M_get_deleter(__ti); } > > template<typename _Tp1> > static _Tp1* > _S_raw_ptr(_Tp1* __ptr) > { return __ptr; } > > template<typename _Tp1> > static auto > _S_raw_ptr(_Tp1 __ptr) -> decltype(std::__addressof(*__ptr)) > { return std::__addressof(*__ptr); } > > template<typename _Tp1, _Lock_policy _Lp1> friend class __shared_ptr; > template<typename _Tp1, _Lock_policy _Lp1> friend class __weak_ptr; > > template<typename _Del, typename _Tp1, _Lock_policy _Lp1> > friend _Del* get_deleter(const __shared_ptr<_Tp1, _Lp1>&) noexcept; > > _Tp* _M_ptr; > __shared_count<_Lp> _M_refcount; > }; > > > > template<typename _Tp1, typename _Tp2, _Lock_policy _Lp> > inline bool > operator==(const __shared_ptr<_Tp1, _Lp>& __a, > const __shared_ptr<_Tp2, _Lp>& __b) noexcept > { return __a.get() == __b.get(); } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator==(const __shared_ptr<_Tp, _Lp>& __a, nullptr_t) noexcept > { return !__a; } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator==(nullptr_t, const __shared_ptr<_Tp, _Lp>& __a) noexcept > { return !__a; } > > template<typename _Tp1, typename _Tp2, _Lock_policy _Lp> > inline bool > operator!=(const __shared_ptr<_Tp1, _Lp>& __a, > const __shared_ptr<_Tp2, _Lp>& __b) noexcept > { return __a.get() != __b.get(); } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator!=(const __shared_ptr<_Tp, _Lp>& __a, nullptr_t) noexcept > { return (bool)__a; } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator!=(nullptr_t, const __shared_ptr<_Tp, _Lp>& __a) noexcept > { return (bool)__a; } > > template<typename _Tp1, typename _Tp2, _Lock_policy _Lp> > inline bool > operator<(const __shared_ptr<_Tp1, _Lp>& __a, > const __shared_ptr<_Tp2, _Lp>& __b) noexcept > { > typedef typename std::common_type<_Tp1*, _Tp2*>::type _CT; > return std::less<_CT>()(__a.get(), __b.get()); > } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator<(const __shared_ptr<_Tp, _Lp>& __a, nullptr_t) noexcept > { return std::less<_Tp*>()(__a.get(), nullptr); } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator<(nullptr_t, const __shared_ptr<_Tp, _Lp>& __a) noexcept > { return std::less<_Tp*>()(nullptr, __a.get()); } > > template<typename _Tp1, typename _Tp2, _Lock_policy _Lp> > inline bool > operator<=(const __shared_ptr<_Tp1, _Lp>& __a, > const __shared_ptr<_Tp2, _Lp>& __b) noexcept > { return !(__b < __a); } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator<=(const __shared_ptr<_Tp, _Lp>& __a, nullptr_t) noexcept > { return !(nullptr < __a); } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator<=(nullptr_t, const __shared_ptr<_Tp, _Lp>& __a) noexcept > { return !(__a < nullptr); } > > template<typename _Tp1, typename _Tp2, _Lock_policy _Lp> > inline bool > operator>(const __shared_ptr<_Tp1, _Lp>& __a, > const __shared_ptr<_Tp2, _Lp>& __b) noexcept > { return (__b < __a); } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator>(const __shared_ptr<_Tp, _Lp>& __a, nullptr_t) noexcept > { return std::less<_Tp*>()(nullptr, __a.get()); } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator>(nullptr_t, const __shared_ptr<_Tp, _Lp>& __a) noexcept > { return std::less<_Tp*>()(__a.get(), nullptr); } > > template<typename _Tp1, typename _Tp2, _Lock_policy _Lp> > inline bool > operator>=(const __shared_ptr<_Tp1, _Lp>& __a, > const __shared_ptr<_Tp2, _Lp>& __b) noexcept > { return !(__a < __b); } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator>=(const __shared_ptr<_Tp, _Lp>& __a, nullptr_t) noexcept > { return !(__a < nullptr); } > > template<typename _Tp, _Lock_policy _Lp> > inline bool > operator>=(nullptr_t, const __shared_ptr<_Tp, _Lp>& __a) noexcept > { return !(nullptr < __a); } > > template<typename _Sp> > struct _Sp_less : public binary_function<_Sp, _Sp, bool> > { > bool > operator()(const _Sp& __lhs, const _Sp& __rhs) const noexcept > { > typedef typename _Sp::element_type element_type; > return std::less<element_type*>()(__lhs.get(), __rhs.get()); > } > }; > > template<typename _Tp, _Lock_policy _Lp> > struct less<__shared_ptr<_Tp, _Lp>> > : public _Sp_less<__shared_ptr<_Tp, _Lp>> > { }; > > > template<typename _Tp, _Lock_policy _Lp> > inline void > swap(__shared_ptr<_Tp, _Lp>& __a, __shared_ptr<_Tp, _Lp>& __b) noexcept > { __a.swap(__b); } ># 1308 "/usr/include/c++/4.9.0/bits/shared_ptr_base.h" 3 > template<typename _Tp, typename _Tp1, _Lock_policy _Lp> > inline __shared_ptr<_Tp, _Lp> > static_pointer_cast(const __shared_ptr<_Tp1, _Lp>& __r) noexcept > { return __shared_ptr<_Tp, _Lp>(__r, static_cast<_Tp*>(__r.get())); } > > > > > > > template<typename _Tp, typename _Tp1, _Lock_policy _Lp> > inline __shared_ptr<_Tp, _Lp> > const_pointer_cast(const __shared_ptr<_Tp1, _Lp>& __r) noexcept > { return __shared_ptr<_Tp, _Lp>(__r, const_cast<_Tp*>(__r.get())); } > > > > > > > template<typename _Tp, typename _Tp1, _Lock_policy _Lp> > inline __shared_ptr<_Tp, _Lp> > dynamic_pointer_cast(const __shared_ptr<_Tp1, _Lp>& __r) noexcept > { > if (_Tp* __p = dynamic_cast<_Tp*>(__r.get())) > return __shared_ptr<_Tp, _Lp>(__r, __p); > return __shared_ptr<_Tp, _Lp>(); > } > > > template<typename _Tp, _Lock_policy _Lp> > class __weak_ptr > { > public: > typedef _Tp element_type; > > constexpr __weak_ptr() noexcept > : _M_ptr(0), _M_refcount() > { } > > __weak_ptr(const __weak_ptr&) noexcept = default; > __weak_ptr& operator=(const __weak_ptr&) noexcept = default; > ~__weak_ptr() = default; ># 1366 "/usr/include/c++/4.9.0/bits/shared_ptr_base.h" 3 > template<typename _Tp1, typename = typename > std::enable_if<std::is_convertible<_Tp1*, _Tp*>::value>::type> > __weak_ptr(const __weak_ptr<_Tp1, _Lp>& __r) noexcept > : _M_refcount(__r._M_refcount) > { _M_ptr = __r.lock().get(); } > > template<typename _Tp1, typename = typename > std::enable_if<std::is_convertible<_Tp1*, _Tp*>::value>::type> > __weak_ptr(const __shared_ptr<_Tp1, _Lp>& __r) noexcept > : _M_ptr(__r._M_ptr), _M_refcount(__r._M_refcount) > { } > > template<typename _Tp1> > __weak_ptr& > operator=(const __weak_ptr<_Tp1, _Lp>& __r) noexcept > { > _M_ptr = __r.lock().get(); > _M_refcount = __r._M_refcount; > return *this; > } > > template<typename _Tp1> > __weak_ptr& > operator=(const __shared_ptr<_Tp1, _Lp>& __r) noexcept > { > _M_ptr = __r._M_ptr; > _M_refcount = __r._M_refcount; > return *this; > } > > __shared_ptr<_Tp, _Lp> > lock() const noexcept > { return __shared_ptr<element_type, _Lp>(*this, std::nothrow); } > > long > use_count() const noexcept > { return _M_refcount._M_get_use_count(); } > > bool > expired() const noexcept > { return _M_refcount._M_get_use_count() == 0; } > > template<typename _Tp1> > bool > owner_before(const __shared_ptr<_Tp1, _Lp>& __rhs) const > { return _M_refcount._M_less(__rhs._M_refcount); } > > template<typename _Tp1> > bool > owner_before(const __weak_ptr<_Tp1, _Lp>& __rhs) const > { return _M_refcount._M_less(__rhs._M_refcount); } > > void > reset() noexcept > { __weak_ptr().swap(*this); } > > void > swap(__weak_ptr& __s) noexcept > { > std::swap(_M_ptr, __s._M_ptr); > _M_refcount._M_swap(__s._M_refcount); > } > > private: > > void > _M_assign(_Tp* __ptr, const __shared_count<_Lp>& __refcount) noexcept > { > _M_ptr = __ptr; > _M_refcount = __refcount; > } > > template<typename _Tp1, _Lock_policy _Lp1> friend class __shared_ptr; > template<typename _Tp1, _Lock_policy _Lp1> friend class __weak_ptr; > friend class __enable_shared_from_this<_Tp, _Lp>; > friend class enable_shared_from_this<_Tp>; > > _Tp* _M_ptr; > __weak_count<_Lp> _M_refcount; > }; > > > template<typename _Tp, _Lock_policy _Lp> > inline void > swap(__weak_ptr<_Tp, _Lp>& __a, __weak_ptr<_Tp, _Lp>& __b) noexcept > { __a.swap(__b); } > > template<typename _Tp, typename _Tp1> > struct _Sp_owner_less : public binary_function<_Tp, _Tp, bool> > { > bool > operator()(const _Tp& __lhs, const _Tp& __rhs) const > { return __lhs.owner_before(__rhs); } > > bool > operator()(const _Tp& __lhs, const _Tp1& __rhs) const > { return __lhs.owner_before(__rhs); } > > bool > operator()(const _Tp1& __lhs, const _Tp& __rhs) const > { return __lhs.owner_before(__rhs); } > }; > > template<typename _Tp, _Lock_policy _Lp> > struct owner_less<__shared_ptr<_Tp, _Lp>> > : public _Sp_owner_less<__shared_ptr<_Tp, _Lp>, __weak_ptr<_Tp, _Lp>> > { }; > > template<typename _Tp, _Lock_policy _Lp> > struct owner_less<__weak_ptr<_Tp, _Lp>> > : public _Sp_owner_less<__weak_ptr<_Tp, _Lp>, __shared_ptr<_Tp, _Lp>> > { }; > > > template<typename _Tp, _Lock_policy _Lp> > class __enable_shared_from_this > { > protected: > constexpr __enable_shared_from_this() noexcept { } > > __enable_shared_from_this(const __enable_shared_from_this&) noexcept { } > > __enable_shared_from_this& > operator=(const __enable_shared_from_this&) noexcept > { return *this; } > > ~__enable_shared_from_this() { } > > public: > __shared_ptr<_Tp, _Lp> > shared_from_this() > { return __shared_ptr<_Tp, _Lp>(this->_M_weak_this); } > > __shared_ptr<const _Tp, _Lp> > shared_from_this() const > { return __shared_ptr<const _Tp, _Lp>(this->_M_weak_this); } > > private: > template<typename _Tp1> > void > _M_weak_assign(_Tp1* __p, const __shared_count<_Lp>& __n) const noexcept > { _M_weak_this._M_assign(__p, __n); } > > template<typename _Tp1> > friend void > __enable_shared_from_this_helper(const __shared_count<_Lp>& __pn, > const __enable_shared_from_this* __pe, > const _Tp1* __px) noexcept > { > if (__pe != 0) > __pe->_M_weak_assign(const_cast<_Tp1*>(__px), __pn); > } > > mutable __weak_ptr<_Tp, _Lp> _M_weak_this; > }; > > > template<typename _Tp, _Lock_policy _Lp, typename _Alloc, typename... _Args> > inline __shared_ptr<_Tp, _Lp> > __allocate_shared(const _Alloc& __a, _Args&&... __args) > { > return __shared_ptr<_Tp, _Lp>(_Sp_make_shared_tag(), __a, > std::forward<_Args>(__args)...); > } > > template<typename _Tp, _Lock_policy _Lp, typename... _Args> > inline __shared_ptr<_Tp, _Lp> > __make_shared(_Args&&... __args) > { > typedef typename std::remove_const<_Tp>::type _Tp_nc; > return std::__allocate_shared<_Tp, _Lp>(std::allocator<_Tp_nc>(), > std::forward<_Args>(__args)...); > } > > > template<typename _Tp, _Lock_policy _Lp> > struct hash<__shared_ptr<_Tp, _Lp>> > : public __hash_base<size_t, __shared_ptr<_Tp, _Lp>> > { > size_t > operator()(const __shared_ptr<_Tp, _Lp>& __s) const noexcept > { return std::hash<_Tp*>()(__s.get()); } > }; > > >} ># 53 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 64 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Ch, typename _Tr, typename _Tp, _Lock_policy _Lp> > inline std::basic_ostream<_Ch, _Tr>& > operator<<(std::basic_ostream<_Ch, _Tr>& __os, > const __shared_ptr<_Tp, _Lp>& __p) > { > __os << __p.get(); > return __os; > } > > > template<typename _Del, typename _Tp, _Lock_policy _Lp> > inline _Del* > get_deleter(const __shared_ptr<_Tp, _Lp>& __p) noexcept > { > > return static_cast<_Del*>(__p._M_get_deleter(typeid(_Del))); > > > > } ># 92 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Tp> > class shared_ptr : public __shared_ptr<_Tp> > { > public: > > > > > constexpr shared_ptr() noexcept > : __shared_ptr<_Tp>() { } > > shared_ptr(const shared_ptr&) noexcept = default; > > > > > > > > template<typename _Tp1> > explicit shared_ptr(_Tp1* __p) > : __shared_ptr<_Tp>(__p) { } ># 128 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Tp1, typename _Deleter> > shared_ptr(_Tp1* __p, _Deleter __d) > : __shared_ptr<_Tp>(__p, __d) { } ># 145 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Deleter> > shared_ptr(nullptr_t __p, _Deleter __d) > : __shared_ptr<_Tp>(__p, __d) { } ># 164 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Tp1, typename _Deleter, typename _Alloc> > shared_ptr(_Tp1* __p, _Deleter __d, _Alloc __a) > : __shared_ptr<_Tp>(__p, __d, std::move(__a)) { } ># 183 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Deleter, typename _Alloc> > shared_ptr(nullptr_t __p, _Deleter __d, _Alloc __a) > : __shared_ptr<_Tp>(__p, __d, std::move(__a)) { } ># 205 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Tp1> > shared_ptr(const shared_ptr<_Tp1>& __r, _Tp* __p) noexcept > : __shared_ptr<_Tp>(__r, __p) { } ># 216 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Tp1, typename = typename > std::enable_if<std::is_convertible<_Tp1*, _Tp*>::value>::type> > shared_ptr(const shared_ptr<_Tp1>& __r) noexcept > : __shared_ptr<_Tp>(__r) { } > > > > > > > shared_ptr(shared_ptr&& __r) noexcept > : __shared_ptr<_Tp>(std::move(__r)) { } > > > > > > > template<typename _Tp1, typename = typename > std::enable_if<std::is_convertible<_Tp1*, _Tp*>::value>::type> > shared_ptr(shared_ptr<_Tp1>&& __r) noexcept > : __shared_ptr<_Tp>(std::move(__r)) { } ># 247 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Tp1> > explicit shared_ptr(const weak_ptr<_Tp1>& __r) > : __shared_ptr<_Tp>(__r) { } > > > template<typename _Tp1> > shared_ptr(std::auto_ptr<_Tp1>&& __r); > > > template<typename _Tp1, typename _Del> > shared_ptr(std::unique_ptr<_Tp1, _Del>&& __r) > : __shared_ptr<_Tp>(std::move(__r)) { } > > > > > > > constexpr shared_ptr(nullptr_t __p) noexcept > : __shared_ptr<_Tp>(__p) { } > > shared_ptr& operator=(const shared_ptr&) noexcept = default; > > template<typename _Tp1> > shared_ptr& > operator=(const shared_ptr<_Tp1>& __r) noexcept > { > this->__shared_ptr<_Tp>::operator=(__r); > return *this; > } > > > template<typename _Tp1> > shared_ptr& > operator=(std::auto_ptr<_Tp1>&& __r) > { > this->__shared_ptr<_Tp>::operator=(std::move(__r)); > return *this; > } > > > shared_ptr& > operator=(shared_ptr&& __r) noexcept > { > this->__shared_ptr<_Tp>::operator=(std::move(__r)); > return *this; > } > > template<class _Tp1> > shared_ptr& > operator=(shared_ptr<_Tp1>&& __r) noexcept > { > this->__shared_ptr<_Tp>::operator=(std::move(__r)); > return *this; > } > > template<typename _Tp1, typename _Del> > shared_ptr& > operator=(std::unique_ptr<_Tp1, _Del>&& __r) > { > this->__shared_ptr<_Tp>::operator=(std::move(__r)); > return *this; > } > > private: > > template<typename _Alloc, typename... _Args> > shared_ptr(_Sp_make_shared_tag __tag, const _Alloc& __a, > _Args&&... __args) > : __shared_ptr<_Tp>(__tag, __a, std::forward<_Args>(__args)...) > { } > > template<typename _Tp1, typename _Alloc, typename... _Args> > friend shared_ptr<_Tp1> > allocate_shared(const _Alloc& __a, _Args&&... __args); > > > shared_ptr(const weak_ptr<_Tp>& __r, std::nothrow_t) > : __shared_ptr<_Tp>(__r, std::nothrow) { } > > friend class weak_ptr<_Tp>; > }; > > > template<typename _Tp1, typename _Tp2> > inline bool > operator==(const shared_ptr<_Tp1>& __a, > const shared_ptr<_Tp2>& __b) noexcept > { return __a.get() == __b.get(); } > > template<typename _Tp> > inline bool > operator==(const shared_ptr<_Tp>& __a, nullptr_t) noexcept > { return !__a; } > > template<typename _Tp> > inline bool > operator==(nullptr_t, const shared_ptr<_Tp>& __a) noexcept > { return !__a; } > > template<typename _Tp1, typename _Tp2> > inline bool > operator!=(const shared_ptr<_Tp1>& __a, > const shared_ptr<_Tp2>& __b) noexcept > { return __a.get() != __b.get(); } > > template<typename _Tp> > inline bool > operator!=(const shared_ptr<_Tp>& __a, nullptr_t) noexcept > { return (bool)__a; } > > template<typename _Tp> > inline bool > operator!=(nullptr_t, const shared_ptr<_Tp>& __a) noexcept > { return (bool)__a; } > > template<typename _Tp1, typename _Tp2> > inline bool > operator<(const shared_ptr<_Tp1>& __a, > const shared_ptr<_Tp2>& __b) noexcept > { > typedef typename std::common_type<_Tp1*, _Tp2*>::type _CT; > return std::less<_CT>()(__a.get(), __b.get()); > } > > template<typename _Tp> > inline bool > operator<(const shared_ptr<_Tp>& __a, nullptr_t) noexcept > { return std::less<_Tp*>()(__a.get(), nullptr); } > > template<typename _Tp> > inline bool > operator<(nullptr_t, const shared_ptr<_Tp>& __a) noexcept > { return std::less<_Tp*>()(nullptr, __a.get()); } > > template<typename _Tp1, typename _Tp2> > inline bool > operator<=(const shared_ptr<_Tp1>& __a, > const shared_ptr<_Tp2>& __b) noexcept > { return !(__b < __a); } > > template<typename _Tp> > inline bool > operator<=(const shared_ptr<_Tp>& __a, nullptr_t) noexcept > { return !(nullptr < __a); } > > template<typename _Tp> > inline bool > operator<=(nullptr_t, const shared_ptr<_Tp>& __a) noexcept > { return !(__a < nullptr); } > > template<typename _Tp1, typename _Tp2> > inline bool > operator>(const shared_ptr<_Tp1>& __a, > const shared_ptr<_Tp2>& __b) noexcept > { return (__b < __a); } > > template<typename _Tp> > inline bool > operator>(const shared_ptr<_Tp>& __a, nullptr_t) noexcept > { return std::less<_Tp*>()(nullptr, __a.get()); } > > template<typename _Tp> > inline bool > operator>(nullptr_t, const shared_ptr<_Tp>& __a) noexcept > { return std::less<_Tp*>()(__a.get(), nullptr); } > > template<typename _Tp1, typename _Tp2> > inline bool > operator>=(const shared_ptr<_Tp1>& __a, > const shared_ptr<_Tp2>& __b) noexcept > { return !(__a < __b); } > > template<typename _Tp> > inline bool > operator>=(const shared_ptr<_Tp>& __a, nullptr_t) noexcept > { return !(__a < nullptr); } > > template<typename _Tp> > inline bool > operator>=(nullptr_t, const shared_ptr<_Tp>& __a) noexcept > { return !(nullptr < __a); } > > template<typename _Tp> > struct less<shared_ptr<_Tp>> : public _Sp_less<shared_ptr<_Tp>> > { }; > > > template<typename _Tp> > inline void > swap(shared_ptr<_Tp>& __a, shared_ptr<_Tp>& __b) noexcept > { __a.swap(__b); } > > > template<typename _Tp, typename _Tp1> > inline shared_ptr<_Tp> > static_pointer_cast(const shared_ptr<_Tp1>& __r) noexcept > { return shared_ptr<_Tp>(__r, static_cast<_Tp*>(__r.get())); } > > template<typename _Tp, typename _Tp1> > inline shared_ptr<_Tp> > const_pointer_cast(const shared_ptr<_Tp1>& __r) noexcept > { return shared_ptr<_Tp>(__r, const_cast<_Tp*>(__r.get())); } > > template<typename _Tp, typename _Tp1> > inline shared_ptr<_Tp> > dynamic_pointer_cast(const shared_ptr<_Tp1>& __r) noexcept > { > if (_Tp* __p = dynamic_cast<_Tp*>(__r.get())) > return shared_ptr<_Tp>(__r, __p); > return shared_ptr<_Tp>(); > } > > > > > > > > template<typename _Tp> > class weak_ptr : public __weak_ptr<_Tp> > { > public: > constexpr weak_ptr() noexcept > : __weak_ptr<_Tp>() { } > > template<typename _Tp1, typename = typename > std::enable_if<std::is_convertible<_Tp1*, _Tp*>::value>::type> > weak_ptr(const weak_ptr<_Tp1>& __r) noexcept > : __weak_ptr<_Tp>(__r) { } > > template<typename _Tp1, typename = typename > std::enable_if<std::is_convertible<_Tp1*, _Tp*>::value>::type> > weak_ptr(const shared_ptr<_Tp1>& __r) noexcept > : __weak_ptr<_Tp>(__r) { } > > template<typename _Tp1> > weak_ptr& > operator=(const weak_ptr<_Tp1>& __r) noexcept > { > this->__weak_ptr<_Tp>::operator=(__r); > return *this; > } > > template<typename _Tp1> > weak_ptr& > operator=(const shared_ptr<_Tp1>& __r) noexcept > { > this->__weak_ptr<_Tp>::operator=(__r); > return *this; > } > > shared_ptr<_Tp> > lock() const noexcept > { return shared_ptr<_Tp>(*this, std::nothrow); } > }; > > > template<typename _Tp> > inline void > swap(weak_ptr<_Tp>& __a, weak_ptr<_Tp>& __b) noexcept > { __a.swap(__b); } > > > > template<typename _Tp> > struct owner_less; > > > template<typename _Tp> > struct owner_less<shared_ptr<_Tp>> > : public _Sp_owner_less<shared_ptr<_Tp>, weak_ptr<_Tp>> > { }; > > > template<typename _Tp> > struct owner_less<weak_ptr<_Tp>> > : public _Sp_owner_less<weak_ptr<_Tp>, shared_ptr<_Tp>> > { }; > > > > > template<typename _Tp> > class enable_shared_from_this > { > protected: > constexpr enable_shared_from_this() noexcept { } > > enable_shared_from_this(const enable_shared_from_this&) noexcept { } > > enable_shared_from_this& > operator=(const enable_shared_from_this&) noexcept > { return *this; } > > ~enable_shared_from_this() { } > > public: > shared_ptr<_Tp> > shared_from_this() > { return shared_ptr<_Tp>(this->_M_weak_this); } > > shared_ptr<const _Tp> > shared_from_this() const > { return shared_ptr<const _Tp>(this->_M_weak_this); } > > private: > template<typename _Tp1> > void > _M_weak_assign(_Tp1* __p, const __shared_count<>& __n) const noexcept > { _M_weak_this._M_assign(__p, __n); } > > template<typename _Tp1> > friend void > __enable_shared_from_this_helper(const __shared_count<>& __pn, > const enable_shared_from_this* __pe, > const _Tp1* __px) noexcept > { > if (__pe != 0) > __pe->_M_weak_assign(const_cast<_Tp1*>(__px), __pn); > } > > mutable weak_ptr<_Tp> _M_weak_this; > }; ># 583 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Tp, typename _Alloc, typename... _Args> > inline shared_ptr<_Tp> > allocate_shared(const _Alloc& __a, _Args&&... __args) > { > return shared_ptr<_Tp>(_Sp_make_shared_tag(), __a, > std::forward<_Args>(__args)...); > } ># 598 "/usr/include/c++/4.9.0/bits/shared_ptr.h" 3 > template<typename _Tp, typename... _Args> > inline shared_ptr<_Tp> > make_shared(_Args&&... __args) > { > typedef typename std::remove_const<_Tp>::type _Tp_nc; > return std::allocate_shared<_Tp>(std::allocator<_Tp_nc>(), > std::forward<_Args>(__args)...); > } > > > template<typename _Tp> > struct hash<shared_ptr<_Tp>> > : public __hash_base<size_t, shared_ptr<_Tp>> > { > size_t > operator()(const shared_ptr<_Tp>& __s) const noexcept > { return std::hash<_Tp*>()(__s.get()); } > }; > > > > >} ># 83 "/usr/include/c++/4.9.0/memory" 2 3 > ># 1 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 1 3 ># 36 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 47 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > template<typename _Tp1> > struct auto_ptr_ref > { > _Tp1* _M_ptr; > > explicit > auto_ptr_ref(_Tp1* __p): _M_ptr(__p) { } > } __attribute__ ((__deprecated__)); ># 86 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > template<typename _Tp> > class auto_ptr > { > private: > _Tp* _M_ptr; > > public: > > typedef _Tp element_type; > > > > > > > > explicit > auto_ptr(element_type* __p = 0) throw() : _M_ptr(__p) { } ># 112 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > auto_ptr(auto_ptr& __a) throw() : _M_ptr(__a.release()) { } ># 124 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > template<typename _Tp1> > auto_ptr(auto_ptr<_Tp1>& __a) throw() : _M_ptr(__a.release()) { } ># 135 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > auto_ptr& > operator=(auto_ptr& __a) throw() > { > reset(__a.release()); > return *this; > } ># 152 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > template<typename _Tp1> > auto_ptr& > operator=(auto_ptr<_Tp1>& __a) throw() > { > reset(__a.release()); > return *this; > } ># 170 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > ~auto_ptr() { delete _M_ptr; } ># 180 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > element_type& > operator*() const throw() > { > ; > return *_M_ptr; > } > > > > > > > > element_type* > operator->() const throw() > { > ; > return _M_ptr; > } ># 210 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > element_type* > get() const throw() { return _M_ptr; } ># 224 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > element_type* > release() throw() > { > element_type* __tmp = _M_ptr; > _M_ptr = 0; > return __tmp; > } ># 239 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > void > reset(element_type* __p = 0) throw() > { > if (__p != _M_ptr) > { > delete _M_ptr; > _M_ptr = __p; > } > } ># 260 "/usr/include/c++/4.9.0/backward/auto_ptr.h" 3 > auto_ptr(auto_ptr_ref<element_type> __ref) throw() > : _M_ptr(__ref._M_ptr) { } > > auto_ptr& > operator=(auto_ptr_ref<element_type> __ref) throw() > { > if (__ref._M_ptr != this->get()) > { > delete _M_ptr; > _M_ptr = __ref._M_ptr; > } > return *this; > } > > template<typename _Tp1> > operator auto_ptr_ref<_Tp1>() throw() > { return auto_ptr_ref<_Tp1>(this->release()); } > > template<typename _Tp1> > operator auto_ptr<_Tp1>() throw() > { return auto_ptr<_Tp1>(this->release()); } > } __attribute__ ((__deprecated__)); > > > > template<> > class auto_ptr<void> > { > public: > typedef void element_type; > } __attribute__ ((__deprecated__)); > > > template<_Lock_policy _Lp> > template<typename _Tp> > inline > __shared_count<_Lp>::__shared_count(std::auto_ptr<_Tp>&& __r) > : _M_pi(new _Sp_counted_ptr<_Tp*, _Lp>(__r.get())) > { __r.release(); } > > template<typename _Tp, _Lock_policy _Lp> > template<typename _Tp1> > inline > __shared_ptr<_Tp, _Lp>::__shared_ptr(std::auto_ptr<_Tp1>&& __r) > : _M_ptr(__r.get()), _M_refcount() > { > > static_assert( sizeof(_Tp1) > 0, "incomplete type" ); > _Tp1* __tmp = __r.get(); > _M_refcount = __shared_count<_Lp>(std::move(__r)); > __enable_shared_from_this_helper(_M_refcount, __tmp, __tmp); > } > > template<typename _Tp> > template<typename _Tp1> > inline > shared_ptr<_Tp>::shared_ptr(std::auto_ptr<_Tp1>&& __r) > : __shared_ptr<_Tp>(std::move(__r)) { } > > template<typename _Tp, typename _Dp> > template<typename _Up, typename> > inline > unique_ptr<_Tp, _Dp>::unique_ptr(auto_ptr<_Up>&& __u) noexcept > : _M_t(__u.release(), deleter_type()) { } > > > >} ># 85 "/usr/include/c++/4.9.0/memory" 2 3 ># 22 "/usr/include/boost/config/no_tr1/memory.hpp" 2 3 4 ># 28 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 2 3 4 > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 30 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 2 3 4 ># 1 "/usr/include/boost/checked_delete.hpp" 1 3 4 ># 24 "/usr/include/boost/checked_delete.hpp" 3 4 >namespace boost >{ > > > >template<class T> inline void checked_delete(T * x) >{ > > typedef char type_must_be_complete[ sizeof(T)? 1: -1 ]; > (void) sizeof(type_must_be_complete); > delete x; >} > >template<class T> 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<class T> struct checked_deleter >{ > typedef void result_type; > typedef T * argument_type; > > void operator()(T * x) const > { > > boost::checked_delete(x); > } >}; > >template<class T> struct checked_array_deleter >{ > typedef void result_type; > typedef T * argument_type; > > void operator()(T * x) const > { > boost::checked_array_delete(x); > } >}; > >} ># 31 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 2 3 4 > ># 1 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 1 3 4 ># 28 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/bad_weak_ptr.hpp" 1 3 4 ># 26 "/usr/include/boost/smart_ptr/bad_weak_ptr.hpp" 3 4 >namespace boost >{ ># 39 "/usr/include/boost/smart_ptr/bad_weak_ptr.hpp" 3 4 >class bad_weak_ptr: public std::exception >{ >public: > > virtual char const * what() const throw() > { > return "tr1::bad_weak_ptr"; > } >}; > > > > > >} ># 29 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 2 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/sp_counted_base.hpp" 1 3 4 ># 21 "/usr/include/boost/smart_ptr/detail/sp_counted_base.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/sp_has_sync.hpp" 1 3 4 ># 22 "/usr/include/boost/smart_ptr/detail/sp_counted_base.hpp" 2 3 4 ># 39 "/usr/include/boost/smart_ptr/detail/sp_counted_base.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp" 1 3 4 ># 27 "/usr/include/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp" 3 4 ># 1 "/usr/include/boost/detail/sp_typeinfo.hpp" 1 3 4 ># 111 "/usr/include/boost/detail/sp_typeinfo.hpp" 3 4 >namespace boost >{ > >namespace detail >{ > > > > > > > >typedef std::type_info sp_typeinfo; > > > >} > >} ># 28 "/usr/include/boost/smart_ptr/detail/sp_counted_base_gcc_x86.hpp" 2 3 4 > >namespace boost >{ > >namespace detail >{ > >inline int atomic_exchange_and_add( int * pw, int dv ) >{ > > > > > int r; > > __asm__ __volatile__ > ( > "lock\n\t" > "xadd %1, %0": > "=m"( *pw ), "=r"( r ): > "m"( *pw ), "1"( dv ): > "memory", "cc" > ); > > return r; >} > >inline void atomic_increment( int * pw ) >{ > > > __asm__ > ( > "lock\n\t" > "incl %0": > "=m"( *pw ): > "m"( *pw ): > "cc" > ); >} > >inline int atomic_conditional_increment( int * pw ) >{ > > > > > int rv, tmp; > > __asm__ > ( > "movl %0, %%eax\n\t" > "0:\n\t" > "test %%eax, %%eax\n\t" > "je 1f\n\t" > "movl %%eax, %2\n\t" > "incl %2\n\t" > "lock\n\t" > "cmpxchgl %2, %0\n\t" > "jne 0b\n\t" > "1:": > "=m"( *pw ), "=&a"( rv ), "=&r"( tmp ): > "m"( *pw ): > "cc" > ); > > return rv; >} > >class sp_counted_base >{ >private: > > sp_counted_base( sp_counted_base const & ); > sp_counted_base & operator= ( sp_counted_base const & ); > > int use_count_; > int weak_count_; > >public: > > sp_counted_base(): use_count_( 1 ), weak_count_( 1 ) > { > } > > virtual ~sp_counted_base() > { > } > > > > > virtual void dispose() = 0; > > > > virtual void destroy() > { > delete this; > } > > virtual void * get_deleter( sp_typeinfo const & ti ) = 0; > virtual void * get_untyped_deleter() = 0; > > void add_ref_copy() > { > atomic_increment( &use_count_ ); > } > > bool add_ref_lock() > { > return atomic_conditional_increment( &use_count_ ) != 0; > } > > void release() > { > if( atomic_exchange_and_add( &use_count_, -1 ) == 1 ) > { > dispose(); > weak_release(); > } > } > > void weak_add_ref() > { > atomic_increment( &weak_count_ ); > } > > void weak_release() > { > if( atomic_exchange_and_add( &weak_count_, -1 ) == 1 ) > { > destroy(); > } > } > > long use_count() const > { > return static_cast<int const volatile &>( use_count_ ); > } >}; > >} > >} ># 40 "/usr/include/boost/smart_ptr/detail/sp_counted_base.hpp" 2 3 4 ># 30 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 2 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/sp_counted_impl.hpp" 1 3 4 ># 40 "/usr/include/boost/smart_ptr/detail/sp_counted_impl.hpp" 3 4 >namespace boost >{ ># 50 "/usr/include/boost/smart_ptr/detail/sp_counted_impl.hpp" 3 4 >namespace detail >{ > >template<class X> class sp_counted_impl_p: public sp_counted_base >{ >private: > > X * px_; > > sp_counted_impl_p( sp_counted_impl_p const & ); > sp_counted_impl_p & operator= ( sp_counted_impl_p const & ); > > typedef sp_counted_impl_p<X> this_type; > >public: > > explicit sp_counted_impl_p( X * px ): px_( px ) > { > > > > } > > virtual void dispose() > { > > > > boost::checked_delete( px_ ); > } > > virtual void * get_deleter( detail::sp_typeinfo const & ) > { > return 0; > } > > virtual void * get_untyped_deleter() > { > return 0; > } ># 118 "/usr/include/boost/smart_ptr/detail/sp_counted_impl.hpp" 3 4 >}; ># 127 "/usr/include/boost/smart_ptr/detail/sp_counted_impl.hpp" 3 4 >template<class P, class D> class sp_counted_impl_pd: public sp_counted_base >{ >private: > > P ptr; > D del; > > sp_counted_impl_pd( sp_counted_impl_pd const & ); > sp_counted_impl_pd & operator= ( sp_counted_impl_pd const & ); > > typedef sp_counted_impl_pd<P, D> this_type; > >public: > > > > sp_counted_impl_pd( P p, D & d ): ptr( p ), del( d ) > { > } > > sp_counted_impl_pd( P p ): ptr( p ), del() > { > } > > virtual void dispose() > { > del( ptr ); > } > > virtual void * get_deleter( detail::sp_typeinfo const & ti ) > { > return ti == typeid(D)? &reinterpret_cast<char&>( del ): 0; > } > > virtual void * get_untyped_deleter() > { > return &reinterpret_cast<char&>( del ); > } ># 193 "/usr/include/boost/smart_ptr/detail/sp_counted_impl.hpp" 3 4 >}; > >template<class P, class D, class A> class sp_counted_impl_pda: public sp_counted_base >{ >private: > > P p_; > D d_; > A a_; > > sp_counted_impl_pda( sp_counted_impl_pda const & ); > sp_counted_impl_pda & operator= ( sp_counted_impl_pda const & ); > > typedef sp_counted_impl_pda<P, D, A> this_type; > >public: > > > > sp_counted_impl_pda( P p, D & d, A a ): p_( p ), d_( d ), a_( a ) > { > } > > sp_counted_impl_pda( P p, A a ): p_( p ), d_(), a_( a ) > { > } > > virtual void dispose() > { > d_( p_ ); > } > > virtual void destroy() > { > typedef typename A::template rebind< this_type >::other A2; > > A2 a2( a_ ); > > this->~this_type(); > a2.deallocate( this, 1 ); > } > > virtual void * get_deleter( detail::sp_typeinfo const & ti ) > { > return ti == typeid(D)? &reinterpret_cast<char&>( d_ ): 0; > } > > virtual void * get_untyped_deleter() > { > return &reinterpret_cast<char&>( d_ ); > } >}; > > > > > >} > >} ># 31 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 2 3 4 ># 47 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 >namespace boost >{ > >namespace detail >{ ># 60 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 >struct sp_nothrow_tag {}; > >template< class D > struct sp_inplace_tag >{ >}; > > > >template< class T > class sp_reference_wrapper >{ >public: > > explicit sp_reference_wrapper( T & t): t_( boost::addressof( t ) ) > { > } > > template< class Y > void operator()( Y * p ) const > { > (*t_)( p ); > } > >private: > > T * t_; >}; > >template< class D > struct sp_convert_reference >{ > typedef D type; >}; > >template< class D > struct sp_convert_reference< D& > >{ > typedef sp_reference_wrapper< D > type; >}; > > > >class weak_count; > >class shared_count >{ >private: > > sp_counted_base * pi_; > > > > > > friend class weak_count; > >public: > > shared_count(): pi_(0) > > > > { > } > > template<class Y> explicit shared_count( Y * p ): pi_( 0 ) > > > > { > > > try > { > pi_ = new sp_counted_impl_p<Y>( p ); > } > catch(...) > { > boost::checked_delete( p ); > throw; > } ># 149 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 > } > > > > > template<class P, class D> shared_count( P p, D d ): pi_(0) > > > > > { > > > > > > try > { > pi_ = new sp_counted_impl_pd<P, D>(p, d); > } > catch(...) > { > d(p); > throw; > } ># 186 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 > } > > > > template< class P, class D > shared_count( P p, sp_inplace_tag<D> ): pi_( 0 ) > > > > { > > > try > { > pi_ = new sp_counted_impl_pd< P, D >( p ); > } > catch( ... ) > { > D::operator_fn( p ); > throw; > } ># 218 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 > } > > > > template<class P, class D, class A> shared_count( P p, D d, A a ): pi_( 0 ) > > > > { > typedef sp_counted_impl_pda<P, D, A> impl_type; > typedef typename A::template rebind< impl_type >::other A2; > > A2 a2( a ); > > > > try > { > pi_ = a2.allocate( 1, static_cast< impl_type* >( 0 ) ); > new( static_cast< void* >( pi_ ) ) impl_type( p, d, a ); > } > catch(...) > { > d( p ); > > if( pi_ != 0 ) > { > a2.deallocate( static_cast< impl_type* >( pi_ ), 1 ); > } > > throw; > } ># 266 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 > } > > > > template< class P, class D, class A > shared_count( P p, sp_inplace_tag< D >, A a ): pi_( 0 ) > > > > { > typedef sp_counted_impl_pda< P, D, A > impl_type; > typedef typename A::template rebind< impl_type >::other A2; > > A2 a2( a ); > > > > try > { > pi_ = a2.allocate( 1, static_cast< impl_type* >( 0 ) ); > new( static_cast< void* >( pi_ ) ) impl_type( p, a ); > } > catch(...) > { > D::operator_fn( p ); > > if( pi_ != 0 ) > { > a2.deallocate( static_cast< impl_type* >( pi_ ), 1 ); > } > > throw; > } ># 314 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 > } > > > > > > > > template<class Y> > explicit shared_count( std::auto_ptr<Y> & r ): pi_( new sp_counted_impl_p<Y>( r.get() ) ) > > > > { ># 337 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 > r.release(); > } > > > > > > template<class Y, class D> > explicit shared_count( std::unique_ptr<Y, D> & r ): pi_( 0 ) > > > > { > typedef typename sp_convert_reference<D>::type D2; > > D2 d2( r.get_deleter() ); > pi_ = new sp_counted_impl_pd< typename std::unique_ptr<Y, D>::pointer, D2 >( r.get(), d2 ); ># 364 "/usr/include/boost/smart_ptr/detail/shared_count.hpp" 3 4 > r.release(); > } > > > > ~shared_count() > { > if( pi_ != 0 ) pi_->release(); > > > > } > > shared_count(shared_count const & r): pi_(r.pi_) > > > > { > if( pi_ != 0 ) pi_->add_ref_copy(); > } > > > > shared_count(shared_count && r): pi_(r.pi_) > > > > { > r.pi_ = 0; > } > > > > explicit shared_count(weak_count const & r); > shared_count( weak_count const & r, sp_nothrow_tag ); > > shared_count & operator= (shared_count const & r) > { > sp_counted_base * tmp = r.pi_; > > if( tmp != pi_ ) > { > if( tmp != 0 ) tmp->add_ref_copy(); > if( pi_ != 0 ) pi_->release(); > pi_ = tmp; > } > > return *this; > } > > void swap(shared_count & r) > { > sp_counted_base * tmp = r.pi_; > r.pi_ = pi_; > pi_ = tmp; > } > > long use_count() const > { > return pi_ != 0? pi_->use_count(): 0; > } > > bool unique() const > { > return use_count() == 1; > } > > bool empty() const > { > return pi_ == 0; > } > > friend inline bool operator==(shared_count const & a, shared_count const & b) > { > return a.pi_ == b.pi_; > } > > friend inline bool operator<(shared_count const & a, shared_count const & b) > { > return std::less<sp_counted_base *>()( a.pi_, b.pi_ ); > } > > void * get_deleter( sp_typeinfo const & ti ) const > { > return pi_? pi_->get_deleter( ti ): 0; > } > > void * get_untyped_deleter() const > { > return pi_? pi_->get_untyped_deleter(): 0; > } >}; > > >class weak_count >{ >private: > > sp_counted_base * pi_; > > > > > > friend class shared_count; > >public: > > weak_count(): pi_(0) > > > > { > } > > weak_count(shared_count const & r): pi_(r.pi_) > > > > { > if(pi_ != 0) pi_->weak_add_ref(); > } > > weak_count(weak_count const & r): pi_(r.pi_) > > > > { > if(pi_ != 0) pi_->weak_add_ref(); > } > > > > > > weak_count(weak_count && r): pi_(r.pi_) > > > > { > r.pi_ = 0; > } > > > > ~weak_count() > { > if(pi_ != 0) pi_->weak_release(); > > > > } > > weak_count & operator= (shared_count const & r) > { > sp_counted_base * tmp = r.pi_; > > if( tmp != pi_ ) > { > if(tmp != 0) tmp->weak_add_ref(); > if(pi_ != 0) pi_->weak_release(); > pi_ = tmp; > } > > return *this; > } > > weak_count & operator= (weak_count const & r) > { > sp_counted_base * tmp = r.pi_; > > if( tmp != pi_ ) > { > if(tmp != 0) tmp->weak_add_ref(); > if(pi_ != 0) pi_->weak_release(); > pi_ = tmp; > } > > return *this; > } > > void swap(weak_count & r) > { > sp_counted_base * tmp = r.pi_; > r.pi_ = pi_; > pi_ = tmp; > } > > long use_count() const > { > return pi_ != 0? pi_->use_count(): 0; > } > > bool empty() const > { > return pi_ == 0; > } > > friend inline bool operator==(weak_count const & a, weak_count const & b) > { > return a.pi_ == b.pi_; > } > > friend inline bool operator<(weak_count const & a, weak_count const & b) > { > return std::less<sp_counted_base *>()(a.pi_, b.pi_); > } >}; > >inline shared_count::shared_count( weak_count const & r ): pi_( r.pi_ ) > > > >{ > if( pi_ == 0 || !pi_->add_ref_lock() ) > { > boost::throw_exception( boost::bad_weak_ptr() ); > } >} > >inline shared_count::shared_count( weak_count const & r, sp_nothrow_tag ): pi_( r.pi_ ) > > > >{ > if( pi_ != 0 && !pi_->add_ref_lock() ) > { > pi_ = 0; > } >} > >} > >} ># 33 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 2 3 4 > ># 1 "/usr/include/boost/smart_ptr/detail/sp_convertible.hpp" 1 3 4 ># 34 "/usr/include/boost/smart_ptr/detail/sp_convertible.hpp" 3 4 >namespace boost >{ > >namespace detail >{ > >template< class Y, class T > struct sp_convertible >{ > typedef char (&yes) [1]; > typedef char (&no) [2]; > > static yes f( T* ); > static no f( ... ); > > enum _vt { value = sizeof( (f)( static_cast<Y*>(0) ) ) == sizeof(yes) }; >}; > >template< class Y, class T > struct sp_convertible< Y, T[] > >{ > enum _vt { value = false }; >}; > >template< class Y, class T > struct sp_convertible< Y[], T[] > >{ > enum _vt { value = sp_convertible< Y[1], T[1] >::value }; >}; > >template< class Y, std::size_t N, class T > struct sp_convertible< Y[N], T[] > >{ > enum _vt { value = sp_convertible< Y[1], T[1] >::value }; >}; > >struct sp_empty >{ >}; > >template< bool > struct sp_enable_if_convertible_impl; > >template<> struct sp_enable_if_convertible_impl<true> >{ > typedef sp_empty type; >}; > >template<> struct sp_enable_if_convertible_impl<false> >{ >}; > >template< class Y, class T > struct sp_enable_if_convertible: public sp_enable_if_convertible_impl< sp_convertible< Y, T >::value > >{ >}; > >} > >} ># 35 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 2 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/sp_nullptr_t.hpp" 1 3 4 ># 23 "/usr/include/boost/smart_ptr/detail/sp_nullptr_t.hpp" 3 4 >namespace boost >{ > >namespace detail >{ > > > > > > > > typedef std::nullptr_t sp_nullptr_t; > > > >} > >} ># 36 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 2 3 4 > > ># 1 "/usr/include/boost/smart_ptr/detail/spinlock_pool.hpp" 1 3 4 ># 25 "/usr/include/boost/smart_ptr/detail/spinlock_pool.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/spinlock.hpp" 1 3 4 ># 41 "/usr/include/boost/smart_ptr/detail/spinlock.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/spinlock_sync.hpp" 1 3 4 ># 18 "/usr/include/boost/smart_ptr/detail/spinlock_sync.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/yield_k.hpp" 1 3 4 ># 90 "/usr/include/boost/smart_ptr/detail/yield_k.hpp" 3 4 >namespace boost >{ > >namespace detail >{ > >inline void yield( unsigned k ) >{ > if( k < 4 ) > { > } > > else if( k < 16 ) > { > __asm__ __volatile__( "rep; nop" : : : "memory" ); > } > > else if( k < 32 || k & 1 ) > { > sched_yield(); > } > else > { > > struct timespec rqtp = { 0, 0 }; > > > > > rqtp.tv_sec = 0; > rqtp.tv_nsec = 1000; > > nanosleep( &rqtp, 0 ); > } >} > >} > >} ># 19 "/usr/include/boost/smart_ptr/detail/spinlock_sync.hpp" 2 3 4 > > > > > >namespace boost >{ > >namespace detail >{ > >class spinlock >{ >public: > > int v_; > >public: > > bool try_lock() > { > int r = __sync_lock_test_and_set( &v_, 1 ); > return r == 0; > } > > void lock() > { > for( unsigned k = 0; !try_lock(); ++k ) > { > boost::detail::yield( k ); > } > } > > void unlock() > { > __sync_lock_release( &v_ ); > } > >public: > > class scoped_lock > { > private: > > spinlock & sp_; > > scoped_lock( scoped_lock const & ); > scoped_lock & operator=( scoped_lock const & ); > > public: > > explicit scoped_lock( spinlock & sp ): sp_( sp ) > { > sp.lock(); > } > > ~scoped_lock() > { > sp_.unlock(); > } > }; >}; > >} >} ># 42 "/usr/include/boost/smart_ptr/detail/spinlock.hpp" 2 3 4 ># 26 "/usr/include/boost/smart_ptr/detail/spinlock_pool.hpp" 2 3 4 > > >namespace boost >{ > >namespace detail >{ > >template< int I > class spinlock_pool >{ >private: > > static spinlock pool_[ 41 ]; > >public: > > static spinlock & spinlock_for( void const * pv ) > { > > > > std::size_t i = reinterpret_cast< std::size_t >( pv ) % 41; > > return pool_[ i ]; > } > > class scoped_lock > { > private: > > spinlock & sp_; > > scoped_lock( scoped_lock const & ); > scoped_lock & operator=( scoped_lock const & ); > > public: > > explicit scoped_lock( void const * pv ): sp_( spinlock_for( pv ) ) > { > sp_.lock(); > } > > ~scoped_lock() > { > sp_.unlock(); > } > }; >}; > >template< int I > spinlock spinlock_pool< I >::pool_[ 41 ] = >{ > {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} >}; > >} >} ># 39 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 2 3 4 ># 1 "/usr/include/boost/memory_order.hpp" 1 3 4 ># 21 "/usr/include/boost/memory_order.hpp" 3 4 >namespace boost >{ ># 41 "/usr/include/boost/memory_order.hpp" 3 4 >enum memory_order >{ > memory_order_relaxed = 0, > memory_order_acquire = 1, > memory_order_release = 2, > memory_order_acq_rel = 3, > memory_order_seq_cst = 7, > memory_order_consume = 8 >}; > >} ># 40 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 2 3 4 ># 55 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 >namespace boost >{ > >template<class T> class shared_ptr; >template<class T> class weak_ptr; >template<class T> class enable_shared_from_this; >class enable_shared_from_raw; > >namespace detail >{ > > > >template< class T > struct sp_element >{ > typedef T type; >}; > > > >template< class T > struct sp_element< T[] > >{ > typedef T type; >}; > > > >template< class T, std::size_t N > struct sp_element< T[N] > >{ > typedef T type; >}; > > > > > > > >template< class T > struct sp_dereference >{ > typedef T & type; >}; > >template<> struct sp_dereference< void > >{ > typedef void type; >}; > > > >template<> struct sp_dereference< void const > >{ > typedef void type; >}; > >template<> struct sp_dereference< void volatile > >{ > typedef void type; >}; > >template<> struct sp_dereference< void const volatile > >{ > typedef void type; >}; > > > > > >template< class T > struct sp_dereference< T[] > >{ > typedef void type; >}; > > > >template< class T, std::size_t N > struct sp_dereference< T[N] > >{ > typedef void type; >}; > > > > > > > >template< class T > struct sp_member_access >{ > typedef T * type; >}; > > > >template< class T > struct sp_member_access< T[] > >{ > typedef void type; >}; > > > >template< class T, std::size_t N > struct sp_member_access< T[N] > >{ > typedef void type; >}; > > > > > > > >template< class T > struct sp_array_access >{ > typedef void type; >}; > > > >template< class T > struct sp_array_access< T[] > >{ > typedef T & type; >}; > > > >template< class T, std::size_t N > struct sp_array_access< T[N] > >{ > typedef T & type; >}; > > > > > > > >template< class T > struct sp_extent >{ > enum _vt { value = 0 }; >}; > > > >template< class T, std::size_t N > struct sp_extent< T[N] > >{ > enum _vt { value = N }; >}; > > > > > >template< class X, class Y, class T > inline void sp_enable_shared_from_this( boost::shared_ptr<X> const * ppx, Y const * py, boost::enable_shared_from_this< T > const * pe ) >{ > if( pe != 0 ) > { > pe->_internal_accept_owner( ppx, const_cast< Y* >( py ) ); > } >} > >template< class X, class Y > inline void sp_enable_shared_from_this( boost::shared_ptr<X> * ppx, Y const * py, boost::enable_shared_from_raw const * pe ); ># 233 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 >inline void sp_enable_shared_from_this( ... ) >{ >} > > > > > > > >template< class T, class R > struct sp_enable_if_auto_ptr >{ >}; > >template< class T, class R > struct sp_enable_if_auto_ptr< std::auto_ptr< T >, R > >{ > typedef R type; >}; > > > > > >template< class Y, class T > inline void sp_assert_convertible() >{ > > > > typedef char tmp[ sp_convertible< Y, T >::value? 1: -1 ]; > (void)sizeof( tmp ); > > > > > > > >} > > > >template< class T, class Y > inline void sp_pointer_construct( boost::shared_ptr< T > * ppx, Y * p, boost::detail::shared_count & pn ) >{ > boost::detail::shared_count( p ).swap( pn ); > boost::detail::sp_enable_shared_from_this( ppx, p, p ); >} > > > >template< class T, class Y > inline void sp_pointer_construct( boost::shared_ptr< T[] > * , Y * p, boost::detail::shared_count & pn ) >{ > sp_assert_convertible< Y[], T[] >(); > boost::detail::shared_count( p, boost::checked_array_deleter< T >() ).swap( pn ); >} > >template< class T, std::size_t N, class Y > inline void sp_pointer_construct( boost::shared_ptr< T[N] > * , Y * p, boost::detail::shared_count & pn ) >{ > sp_assert_convertible< Y[N], T[N] >(); > boost::detail::shared_count( p, boost::checked_array_deleter< T >() ).swap( pn ); >} > > > > > >template< class T, class Y > inline void sp_deleter_construct( boost::shared_ptr< T > * ppx, Y * p ) >{ > boost::detail::sp_enable_shared_from_this( ppx, p, p ); >} > > > >template< class T, class Y > inline void sp_deleter_construct( boost::shared_ptr< T[] > * , Y * ) >{ > sp_assert_convertible< Y[], T[] >(); >} > >template< class T, std::size_t N, class Y > inline void sp_deleter_construct( boost::shared_ptr< T[N] > * , Y * ) >{ > sp_assert_convertible< Y[N], T[N] >(); >} > > > >} ># 328 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 >template<class T> class shared_ptr >{ >private: > > > typedef shared_ptr<T> this_type; > >public: > > typedef typename boost::detail::sp_element< T >::type element_type; > > shared_ptr() noexcept : px( 0 ), pn() > { > } > > > > shared_ptr( boost::detail::sp_nullptr_t ) noexcept : px( 0 ), pn() > { > } > > > > template<class Y> > explicit shared_ptr( Y * p ): px( p ), pn() > { > boost::detail::sp_pointer_construct( this, p, pn ); > } > > > > > > > > template<class Y, class D> shared_ptr( Y * p, D d ): px( p ), pn( p, d ) > { > boost::detail::sp_deleter_construct( this, p ); > } > > > > template<class D> shared_ptr( boost::detail::sp_nullptr_t p, D d ): px( p ), pn( p, d ) > { > } > > > > > > template<class Y, class D, class A> shared_ptr( Y * p, D d, A a ): px( p ), pn( p, d, a ) > { > boost::detail::sp_deleter_construct( this, p ); > } > > > > template<class D, class A> shared_ptr( boost::detail::sp_nullptr_t p, D d, A a ): px( p ), pn( p, d, a ) > { > } ># 397 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 > shared_ptr( shared_ptr const & r ) noexcept : px( r.px ), pn( r.pn ) > { > } > > > > template<class Y> > explicit shared_ptr( weak_ptr<Y> const & r ): pn( r.pn ) > { > boost::detail::sp_assert_convertible< Y, T >(); > > > px = r.px; > } > > template<class Y> > shared_ptr( weak_ptr<Y> const & r, boost::detail::sp_nothrow_tag ) > noexcept : px( 0 ), pn( r.pn, boost::detail::sp_nothrow_tag() ) > { > if( !pn.empty() ) > { > px = r.px; > } > } > > template<class Y> > > > shared_ptr( shared_ptr<Y> const & r, typename boost::detail::sp_enable_if_convertible<Y,T>::type = boost::detail::sp_empty() ) > > > > > > > noexcept : px( r.px ), pn( r.pn ) > { > boost::detail::sp_assert_convertible< Y, T >(); > } > > > template< class Y > > shared_ptr( shared_ptr<Y> const & r, element_type * p ) noexcept : px( p ), pn( r.pn ) > { > } > > > > template<class Y> > explicit shared_ptr( std::auto_ptr<Y> & r ): px(r.get()), pn() > { > boost::detail::sp_assert_convertible< Y, T >(); > > Y * tmp = r.get(); > pn = boost::detail::shared_count( r ); > > boost::detail::sp_deleter_construct( this, tmp ); > } > > > > template<class Y> > shared_ptr( std::auto_ptr<Y> && r ): px(r.get()), pn() > { > boost::detail::sp_assert_convertible< Y, T >(); > > Y * tmp = r.get(); > pn = boost::detail::shared_count( r ); > > boost::detail::sp_deleter_construct( this, tmp ); > } ># 490 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 > template< class Y, class D > > shared_ptr( std::unique_ptr< Y, D > && r ): px( r.get() ), pn() > { > boost::detail::sp_assert_convertible< Y, T >(); > > typename std::unique_ptr< Y, D >::pointer tmp = r.get(); > pn = boost::detail::shared_count( r ); > > boost::detail::sp_deleter_construct( this, tmp ); > } > > > > > > shared_ptr & operator=( shared_ptr const & r ) noexcept > { > this_type(r).swap(*this); > return *this; > } > > > > template<class Y> > shared_ptr & operator=(shared_ptr<Y> const & r) noexcept > { > this_type(r).swap(*this); > return *this; > } > > > > > > template<class Y> > shared_ptr & operator=( std::auto_ptr<Y> & r ) > { > this_type( r ).swap( *this ); > return *this; > } > > > > template<class Y> > shared_ptr & operator=( std::auto_ptr<Y> && r ) > { > this_type( static_cast< std::auto_ptr<Y> && >( r ) ).swap( *this ); > return *this; > } ># 555 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 > template<class Y, class D> > shared_ptr & operator=( std::unique_ptr<Y, D> && r ) > { > this_type( static_cast< std::unique_ptr<Y, D> && >( r ) ).swap(*this); > return *this; > } > > > > > > > > shared_ptr( shared_ptr && r ) noexcept : px( r.px ), pn() > { > pn.swap( r.pn ); > r.px = 0; > } > > template<class Y> > > > shared_ptr( shared_ptr<Y> && r, typename boost::detail::sp_enable_if_convertible<Y,T>::type = boost::detail::sp_empty() ) > > > > > > > noexcept : px( r.px ), pn() > { > boost::detail::sp_assert_convertible< Y, T >(); > > pn.swap( r.pn ); > r.px = 0; > } > > shared_ptr & operator=( shared_ptr && r ) noexcept > { > this_type( static_cast< shared_ptr && >( r ) ).swap( *this ); > return *this; > } > > template<class Y> > shared_ptr & operator=( shared_ptr<Y> && r ) noexcept > { > this_type( static_cast< shared_ptr<Y> && >( r ) ).swap( *this ); > return *this; > } > > > > > > shared_ptr & operator=( boost::detail::sp_nullptr_t ) noexcept > { > this_type().swap(*this); > return *this; > } > > > > void reset() noexcept > { > this_type().swap(*this); > } > > template<class Y> void reset( Y * p ) > { > (static_cast<void> (0)); > this_type( p ).swap( *this ); > } > > template<class Y, class D> void reset( Y * p, D d ) > { > this_type( p, d ).swap( *this ); > } > > template<class Y, class D, class A> void reset( Y * p, D d, A a ) > { > this_type( p, d, a ).swap( *this ); > } > > template<class Y> void reset( shared_ptr<Y> const & r, element_type * p ) > { > this_type( r, p ).swap( *this ); > } > > > typename boost::detail::sp_dereference< T >::type operator* () const > { > (static_cast<void> (0)); > return *px; > } > > > typename boost::detail::sp_member_access< T >::type operator-> () const > { > (static_cast<void> (0)); > return px; > } > > > typename boost::detail::sp_array_access< T >::type operator[] ( std::ptrdiff_t i ) const > { > (static_cast<void> (0)); > (static_cast<void> (0)); > > return px[ i ]; > } > > element_type * get() const noexcept > { > return px; > } > > ># 1 "/usr/include/boost/smart_ptr/detail/operator_bool.hpp" 1 3 4 ># 11 "/usr/include/boost/smart_ptr/detail/operator_bool.hpp" 3 4 > explicit operator bool () const noexcept > { > return px != 0; > } ># 60 "/usr/include/boost/smart_ptr/detail/operator_bool.hpp" 3 4 > bool operator! () const noexcept > { > return px == 0; > } ># 673 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 2 3 4 > > bool unique() const noexcept > { > return pn.unique(); > } > > long use_count() const noexcept > { > return pn.use_count(); > } > > void swap( shared_ptr & other ) noexcept > { > std::swap(px, other.px); > pn.swap(other.pn); > } > > template<class Y> bool owner_before( shared_ptr<Y> const & rhs ) const noexcept > { > return pn < rhs.pn; > } > > template<class Y> bool owner_before( weak_ptr<Y> const & rhs ) const noexcept > { > return pn < rhs.pn; > } > > void * _internal_get_deleter( boost::detail::sp_typeinfo const & ti ) const noexcept > { > return pn.get_deleter( ti ); > } > > void * _internal_get_untyped_deleter() const noexcept > { > return pn.get_untyped_deleter(); > } > > bool _internal_equiv( shared_ptr const & r ) const noexcept > { > return px == r.px && pn == r.pn; > } > > > > > > >private: > > template<class Y> friend class shared_ptr; > template<class Y> friend class weak_ptr; > > > > > element_type * px; > boost::detail::shared_count pn; > >}; > >template<class T, class U> inline bool operator==(shared_ptr<T> const & a, shared_ptr<U> const & b) noexcept >{ > return a.get() == b.get(); >} > >template<class T, class U> inline bool operator!=(shared_ptr<T> const & a, shared_ptr<U> const & b) noexcept >{ > return a.get() != b.get(); >} ># 756 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 >template<class T> inline bool operator==( shared_ptr<T> const & p, boost::detail::sp_nullptr_t ) noexcept >{ > return p.get() == 0; >} > >template<class T> inline bool operator==( boost::detail::sp_nullptr_t, shared_ptr<T> const & p ) noexcept >{ > return p.get() == 0; >} > >template<class T> inline bool operator!=( shared_ptr<T> const & p, boost::detail::sp_nullptr_t ) noexcept >{ > return p.get() != 0; >} > >template<class T> inline bool operator!=( boost::detail::sp_nullptr_t, shared_ptr<T> const & p ) noexcept >{ > return p.get() != 0; >} > > > >template<class T, class U> inline bool operator<(shared_ptr<T> const & a, shared_ptr<U> const & b) noexcept >{ > return a.owner_before( b ); >} > >template<class T> inline void swap(shared_ptr<T> & a, shared_ptr<T> & b) noexcept >{ > a.swap(b); >} > >template<class T, class U> shared_ptr<T> static_pointer_cast( shared_ptr<U> const & r ) noexcept >{ > (void) static_cast< T* >( static_cast< U* >( 0 ) ); > > typedef typename shared_ptr<T>::element_type E; > > E * p = static_cast< E* >( r.get() ); > return shared_ptr<T>( r, p ); >} > >template<class T, class U> shared_ptr<T> const_pointer_cast( shared_ptr<U> const & r ) noexcept >{ > (void) const_cast< T* >( static_cast< U* >( 0 ) ); > > typedef typename shared_ptr<T>::element_type E; > > E * p = const_cast< E* >( r.get() ); > return shared_ptr<T>( r, p ); >} > >template<class T, class U> shared_ptr<T> dynamic_pointer_cast( shared_ptr<U> const & r ) noexcept >{ > (void) dynamic_cast< T* >( static_cast< U* >( 0 ) ); > > typedef typename shared_ptr<T>::element_type E; > > E * p = dynamic_cast< E* >( r.get() ); > return p? shared_ptr<T>( r, p ): shared_ptr<T>(); >} > >template<class T, class U> shared_ptr<T> reinterpret_pointer_cast( shared_ptr<U> const & r ) noexcept >{ > (void) reinterpret_cast< T* >( static_cast< U* >( 0 ) ); > > typedef typename shared_ptr<T>::element_type E; > > E * p = reinterpret_cast< E* >( r.get() ); > return shared_ptr<T>( r, p ); >} > > > >template<class T> inline typename shared_ptr<T>::element_type * get_pointer(shared_ptr<T> const & p) noexcept >{ > return p.get(); >} ># 857 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 >template<class E, class T, class Y> std::basic_ostream<E, T> & operator<< (std::basic_ostream<E, T> & os, shared_ptr<Y> const & p) > >{ > os << p.get(); > return os; >} ># 872 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 >namespace detail >{ ># 890 "/usr/include/boost/smart_ptr/shared_ptr.hpp" 3 4 >template<class D, class T> D * basic_get_deleter( shared_ptr<T> const & p ) noexcept >{ > return static_cast<D *>( p._internal_get_deleter(typeid(D)) ); >} > > > >class esft2_deleter_wrapper >{ >private: > > shared_ptr<void> deleter_; > >public: > > esft2_deleter_wrapper() > { > } > > template< class T > void set_deleter( shared_ptr<T> const & deleter ) > { > deleter_ = deleter; > } > > template<typename D> D* get_deleter() const noexcept > { > return boost::detail::basic_get_deleter<D>( deleter_ ); > } > > template< class T> void operator()( T* ) > { > (static_cast<void> (0)); > deleter_.reset(); > } >}; > >} > >template<class D, class T> D * get_deleter( shared_ptr<T> const & p ) noexcept >{ > D *del = boost::detail::basic_get_deleter<D>(p); > > if(del == 0) > { > boost::detail::esft2_deleter_wrapper *del_wrapper = boost::detail::basic_get_deleter<boost::detail::esft2_deleter_wrapper>(p); > > > if(del_wrapper) del = del_wrapper->::boost::detail::esft2_deleter_wrapper::get_deleter<D>(); > } > > return del; >} > > > > > >template<class T> inline bool atomic_is_lock_free( shared_ptr<T> const * ) noexcept >{ > return false; >} > >template<class T> shared_ptr<T> atomic_load( shared_ptr<T> const * p ) >{ > boost::detail::spinlock_pool<2>::scoped_lock lock( p ); > return *p; >} > >template<class T> inline shared_ptr<T> atomic_load_explicit( shared_ptr<T> const * p, memory_order ) >{ > return atomic_load( p ); >} > >template<class T> void atomic_store( shared_ptr<T> * p, shared_ptr<T> r ) >{ > boost::detail::spinlock_pool<2>::scoped_lock lock( p ); > p->swap( r ); >} > >template<class T> inline void atomic_store_explicit( shared_ptr<T> * p, shared_ptr<T> r, memory_order ) >{ > atomic_store( p, r ); >} > >template<class T> shared_ptr<T> atomic_exchange( shared_ptr<T> * p, shared_ptr<T> r ) >{ > boost::detail::spinlock & sp = boost::detail::spinlock_pool<2>::spinlock_for( p ); > > sp.lock(); > p->swap( r ); > sp.unlock(); > > return r; >} > >template<class T> shared_ptr<T> atomic_exchange_explicit( shared_ptr<T> * p, shared_ptr<T> r, memory_order ) >{ > return atomic_exchange( p, r ); >} > >template<class T> bool atomic_compare_exchange( shared_ptr<T> * p, shared_ptr<T> * v, shared_ptr<T> w ) >{ > boost::detail::spinlock & sp = boost::detail::spinlock_pool<2>::spinlock_for( p ); > > sp.lock(); > > if( p->_internal_equiv( *v ) ) > { > p->swap( w ); > > sp.unlock(); > > return true; > } > else > { > shared_ptr<T> tmp( *p ); > > sp.unlock(); > > tmp.swap( *v ); > return false; > } >} > >template<class T> inline bool atomic_compare_exchange_explicit( shared_ptr<T> * p, shared_ptr<T> * v, shared_ptr<T> w, memory_order , memory_order ) >{ > return atomic_compare_exchange( p, v, w ); >} > > > > > >template< class T > struct hash; > >template< class T > std::size_t hash_value( boost::shared_ptr<T> const & p ) noexcept >{ > return boost::hash< T* >()( p.get() ); >} > >} ># 18 "/usr/include/boost/shared_ptr.hpp" 2 3 4 ># 18 "/usr/include/boost/date_time/time_clock.hpp" 2 3 4 > >namespace boost { >namespace date_time { > > > > > > template<class time_type> > 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 = c_time::localtime(&t, &curr); > return create_time(curr_ptr); > } > > > > static time_type universal_time() > { > > ::std::time_t t; > ::std::time(&t); > ::std::tm curr, *curr_ptr; > > curr_ptr = c_time::gmtime(&t, &curr); > return create_time(curr_ptr); > } > > template<class time_zone_type> > static time_type local_time(boost::shared_ptr<time_zone_type> tz_ptr) > { > typedef typename time_type::utc_time_type utc_time_type; > utc_time_type utc_time = second_clock<utc_time_type>::universal_time(); > return time_type(utc_time, tz_ptr); > } > > > private: > static time_type create_time(::std::tm* current) > { > date_type d(static_cast<unsigned short>(current->tm_year + 1900), > static_cast<unsigned short>(current->tm_mon + 1), > static_cast<unsigned short>(current->tm_mday)); > time_duration_type td(current->tm_hour, > current->tm_min, > current->tm_sec); > return time_type(d,td); > } > > }; > > >} } ># 10 "/usr/include/boost/thread/thread_time.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/microsec_time_clock.hpp" 1 3 4 ># 17 "/usr/include/boost/date_time/microsec_time_clock.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 18 "/usr/include/boost/date_time/microsec_time_clock.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/date_time/filetime_functions.hpp" 1 3 4 ># 24 "/usr/include/boost/date_time/microsec_time_clock.hpp" 2 3 4 > > > >namespace boost { >namespace date_time { ># 38 "/usr/include/boost/date_time/microsec_time_clock.hpp" 3 4 > template<class time_type> > class microsec_clock > { > private: > > 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; > > > > template<class time_zone_type> > static time_type local_time(shared_ptr<time_zone_type> tz_ptr) > { > typedef typename time_type::utc_time_type utc_time_type; > typedef second_clock<utc_time_type> second_clock; > > > utc_time_type utc_time = second_clock::universal_time(); > time_duration_type utc_offset = second_clock::local_time() - utc_time; > > > utc_time = microsec_clock<utc_time_type>::local_time() - utc_offset; > return time_type(utc_time, tz_ptr); > } > > > static time_type local_time() > { > return create_time(&c_time::localtime); > } > > > static time_type universal_time() > { > return create_time(&c_time::gmtime); > } > > private: > static time_type create_time(time_converter converter) > { > > timeval tv; > gettimeofday(&tv, 0); > std::time_t t = tv.tv_sec; > boost::uint32_t sub_sec = tv.tv_usec; ># 99 "/usr/include/boost/date_time/microsec_time_clock.hpp" 3 4 > 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)); > > > > > > 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); > } > }; > > >} } ># 11 "/usr/include/boost/thread/thread_time.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/posix_time/posix_time_types.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/posix_time/posix_time_types.hpp" 3 4 ># 1 "/usr/include/boost/date_time/posix_time/ptime.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/posix_time/ptime.hpp" 3 4 ># 1 "/usr/include/boost/date_time/posix_time/posix_time_system.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/posix_time/posix_time_system.hpp" 3 4 ># 1 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 13 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 2 3 4 ># 1 "/usr/include/boost/limits.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 2 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 15 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 2 3 4 ># 1 "/usr/include/boost/config/no_tr1/cmath.hpp" 1 3 4 ># 21 "/usr/include/boost/config/no_tr1/cmath.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cmath" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cmath" 3 4 ># 40 "/usr/include/c++/4.9.0/cmath" 3 ># 22 "/usr/include/boost/config/no_tr1/cmath.hpp" 2 3 4 ># 16 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/time_duration.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/time_duration.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/time_duration.hpp" 2 3 4 > > ># 1 "/usr/include/boost/date_time/time_defs.hpp" 1 3 4 ># 19 "/usr/include/boost/date_time/time_defs.hpp" 3 4 >namespace boost { >namespace date_time { > > > enum time_resolutions { > sec, > tenth, > hundreth, > hundredth = hundreth, > milli, > ten_thousandth, > micro, > nano, > NumResolutions > }; > > > enum dst_flags {not_dst, is_dst, calculate}; > > >} } ># 16 "/usr/include/boost/date_time/time_duration.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/special_defs.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/special_defs.hpp" 3 4 >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}; > > >} } ># 17 "/usr/include/boost/date_time/time_duration.hpp" 2 3 4 > > >namespace boost { >namespace date_time { ># 33 "/usr/include/boost/date_time/time_duration.hpp" 3 4 > template<class T, typename rep_type> > class time_duration : private > boost::less_than_comparable<T > , boost::equality_comparable<T > > > > > > > > > { > public: > typedef T duration_type; > 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)) > {} > > > time_duration(const time_duration<T, rep_type>& other) > : ticks_(other.ticks_) > {} > > time_duration(special_values sv) : ticks_(impl_type::from_special(sv)) > {} > > static duration_type unit() > { > return duration_type(0,0,0,1); > } > > static tick_type ticks_per_second() > { > return rep_type::res_adjust(); > } > > static time_resolutions resolution() > { > return rep_type::resolution(); > } > > hour_type hours() const > { > return static_cast<hour_type>(ticks() / (3600*ticks_per_second())); > } > > min_type minutes() const > { > return static_cast<min_type>((ticks() / (60*ticks_per_second())) % 60); > } > > sec_type seconds() const > { > return static_cast<sec_type>((ticks()/ticks_per_second()) % 60); > } > > sec_type total_seconds() const > { > return static_cast<sec_type>(ticks() / ticks_per_second()); > } > > tick_type total_milliseconds() const > { > if (ticks_per_second() < 1000) { > return ticks() * (static_cast<tick_type>(1000) / ticks_per_second()); > } > return ticks() / (ticks_per_second() / static_cast<tick_type>(1000)) ; > } > > tick_type total_nanoseconds() const > { > if (ticks_per_second() < 1000000000) { > return ticks() * (static_cast<tick_type>(1000000000) / ticks_per_second()); > } > return ticks() / (ticks_per_second() / static_cast<tick_type>(1000000000)) ; > } > > tick_type total_microseconds() const > { > if (ticks_per_second() < 1000000) { > return ticks() * (static_cast<tick_type>(1000000) / ticks_per_second()); > } > return ticks() / (ticks_per_second() / static_cast<tick_type>(1000000)) ; > } > > fractional_seconds_type fractional_seconds() const > { > return (ticks() % ticks_per_second()); > } > > 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_; > } > > 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_); > } > > duration_type operator/=(int divisor) > { > ticks_ = ticks_ / divisor; > return duration_type(ticks_); > } > > 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_); > } > > > bool is_special()const > { > if(traits_type::is_adapted()) > { > return ticks_.is_special(); > } > else{ > return false; > } > } > > bool is_pos_infinity()const > { > if(traits_type::is_adapted()) > { > return ticks_.is_pos_infinity(); > } > else{ > return false; > } > } > > bool is_neg_infinity()const > { > if(traits_type::is_adapted()) > { > return ticks_.is_neg_infinity(); > } > else{ > return false; > } > } > > bool is_not_a_date_time()const > { > if(traits_type::is_adapted()) > { > return ticks_.is_nan(); > } > else{ > return false; > } > } > > > impl_type get_rep()const > { > return ticks_; > } > > protected: > explicit time_duration(impl_type in) : ticks_(in) {} > impl_type ticks_; > }; > > > > > > > > template<class base_duration, boost::int64_t frac_of_second> > class subsecond_duration : public base_duration > { > public: > typedef typename base_duration::impl_type impl_type; > typedef typename base_duration::traits_type traits_type; > > private: > > static_assert((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") > ; > static const 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)) > { > } > }; > > > >} } ># 17 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/time_resolution_traits.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/time_resolution_traits.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/time_resolution_traits.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/int_adapter.hpp" 1 3 4 ># 21 "/usr/include/boost/date_time/int_adapter.hpp" 3 4 >namespace boost { >namespace date_time { ># 39 "/usr/include/boost/date_time/int_adapter.hpp" 3 4 >template<typename int_type_> >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<int_type>::max)(); > } > static const int_adapter neg_infinity() > { > return (::std::numeric_limits<int_type>::min)(); > } > static const int_adapter not_a_number() > { > return (::std::numeric_limits<int_type>::max)()-1; > } > static int_adapter max () > { > return (::std::numeric_limits<int_type>::max)()-2; > } > static int_adapter min () > { > return (::std::numeric_limits<int_type>::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()); > } > > 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; > } > > > static int_type maxcount() > { > return (::std::numeric_limits<int_type>::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 > { > > bool is_signed = std::numeric_limits<int_type>::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 > { > > bool is_signed = std::numeric_limits<int_type>::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 > { > > bool is_signed = std::numeric_limits<int_type>::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_; > } > > special_values as_special() const > { > return int_adapter::to_special(value_); > } ># 205 "/usr/include/boost/date_time/int_adapter.hpp" 3 4 > template<class rhs_type> > inline > int_adapter operator+(const int_adapter<rhs_type>& 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<int_type>(value_ + rhs.as_number()); > } > > int_adapter operator+(const int_type rhs) const > { > if(is_special()) > { > if (is_nan()) > { > return int_adapter<int_type>(not_a_number()); > } > if (is_infinity()) > { > return *this; > } > } > return int_adapter<int_type>(value_ + rhs); > } > > > > template<class rhs_type> > inline > int_adapter operator-(const int_adapter<rhs_type>& 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<int_type>(value_ - rhs.as_number()); > } > int_adapter operator-(const int_type rhs) const > { > if(is_special()) > { > if (is_nan()) > { > return int_adapter<int_type>(not_a_number()); > } > if (is_infinity()) > { > return *this; > } > } > return int_adapter<int_type>(value_ - rhs); > } > > > int_adapter operator*(const int_adapter& rhs)const > { > if(this->is_special() || rhs.is_special()) > { > return mult_div_specials(rhs); > } > return int_adapter<int_type>(value_ * rhs.value_); > } > > > int_adapter operator*(const int rhs) const > { > if(is_special()) > { > return mult_div_specials(rhs); > } > return int_adapter<int_type>(value_ * rhs); > } > > > int_adapter operator/(const int_adapter& rhs)const > { > if(this->is_special() || rhs.is_special()) > { > if(is_infinity() && rhs.is_infinity()) > { > return int_adapter<int_type>(not_a_number()); > } > if(rhs != 0) > { > return mult_div_specials(rhs); > } > else { > return int_adapter<int_type>(value_ / rhs.value_); > } > } > return int_adapter<int_type>(value_ / rhs.value_); > } > > > int_adapter operator/(const int rhs) const > { > if(is_special() && rhs != 0) > { > return mult_div_specials(rhs); > } > return int_adapter<int_type>(value_ / rhs); > } > > > int_adapter operator%(const int_adapter& rhs)const > { > if(this->is_special() || rhs.is_special()) > { > if(is_infinity() && rhs.is_infinity()) > { > return int_adapter<int_type>(not_a_number()); > } > if(rhs != 0) > { > return mult_div_specials(rhs); > } > else { > return int_adapter<int_type>(value_ % rhs.value_); > } > } > return int_adapter<int_type>(value_ % rhs.value_); > } > > > int_adapter operator%(const int rhs) const > { > if(is_special() && rhs != 0) > { > return mult_div_specials(rhs); > } > return int_adapter<int_type>(value_ % rhs); > } >private: > int_type value_; > > > 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; > } > else { > return 2; > } > } > if((is_neg_inf(value_) && !is_neg_inf(rhs.value_)) || > (is_pos_inf(rhs.value_) && !is_pos_inf(value_)) ) > { > return -1; > } > if((is_pos_inf(value_) && !is_pos_inf(rhs.value_)) || > (is_neg_inf(rhs.value_) && !is_neg_inf(value_)) ) { > return 1; > } > } > if(value_ < rhs.value_) return -1; > if(value_ > rhs.value_) return 1; > > return 0; > } > > > > > > int_adapter mult_div_specials(const int_adapter& rhs)const > { > int min_value; > > bool is_signed = std::numeric_limits<int_type>::is_signed; > if(is_signed) { > min_value = 0; > } > else { > min_value = 1; > } > if(this->is_nan() || rhs.is_nan()) { > return int_adapter<int_type>(not_a_number()); > } > if((*this > 0 && rhs > 0) || (*this < min_value && rhs < min_value)) { > return int_adapter<int_type>(pos_infinity()); > } > if((*this > 0 && rhs < min_value) || (*this < min_value && rhs > 0)) { > return int_adapter<int_type>(neg_infinity()); > } > > return int_adapter<int_type>(not_a_number()); > } > > > > > > > int_adapter mult_div_specials(const int& rhs) const > { > int min_value; > > bool is_signed = std::numeric_limits<int_type>::is_signed; > if(is_signed) { > min_value = 0; > } > else { > min_value = 1; > } > if(this->is_nan()) { > return int_adapter<int_type>(not_a_number()); > } > if((*this > 0 && rhs > 0) || (*this < min_value && rhs < 0)) { > return int_adapter<int_type>(pos_infinity()); > } > if((*this > 0 && rhs < 0) || (*this < min_value && rhs > 0)) { > return int_adapter<int_type>(neg_infinity()); > } > > return int_adapter<int_type>(not_a_number()); > } > >}; > > > > > > > template<class charT, class traits, typename int_type> > inline > std::basic_ostream<charT, traits>& > operator<<(std::basic_ostream<charT, traits>& os, const int_adapter<int_type>& ia) > { > if(ia.is_special()) { > > 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; > } > > > >} } ># 16 "/usr/include/boost/date_time/time_resolution_traits.hpp" 2 3 4 > > >namespace boost { >namespace date_time { > > > template <typename T> > > > inline T absolute_value(T x) > { > return x < 0 ? -x : x; > } > > > 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;} > > static bool is_adapted() { return false;} > }; > > struct time_resolution_traits_adapted32_impl { > typedef boost::int32_t int_type; > typedef boost::date_time::int_adapter<boost::int32_t> impl_type; > static int_type as_number(impl_type i){ return i.as_number();} > > static bool is_adapted() { return true;} > }; > > 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;} > > static bool is_adapted() { return false;} > }; > > struct time_resolution_traits_adapted64_impl { > typedef boost::int64_t int_type; > typedef boost::date_time::int_adapter<boost::int64_t> impl_type; > static int_type as_number(impl_type i){ return i.as_number();} > > static bool is_adapted() { return true;} > }; > > template<typename frac_sec_type, > time_resolutions res, > > > > typename frac_sec_type::int_type resolution_adjust, > > unsigned short frac_digits, > typename v_type = boost::int32_t > > 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; > > > 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(); > } > > > > > > static const fractional_seconds_type ticks_per_second = resolution_adjust; > > > static time_resolutions resolution() > { > return res; > } > static unsigned short num_fractional_digits() > { > return frac_digits; > } > static fractional_seconds_type res_adjust() > { > return resolution_adjust; > } > > 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<time_resolution_traits_adapted32_impl, milli, 1000, 3 > milli_res; > typedef time_resolution_traits<time_resolution_traits_adapted64_impl, micro, 1000000, 6 > micro_res; > typedef time_resolution_traits<time_resolution_traits_adapted64_impl, nano, 1000000000, 9 > nano_res; > > >} } ># 18 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 1 3 4 ># 17 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 3 4 ># 1 "/usr/include/boost/date_time/date.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/date.hpp" 3 4 ># 1 "/usr/include/boost/date_time/year_month_day.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/year_month_day.hpp" 3 4 >namespace boost { >namespace date_time { > > > template<typename YearType, typename MonthType, typename DayType> > 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; > }; > > > > template<typename YearType, typename MonthType, typename DayType> > inline > year_month_day_base<YearType,MonthType,DayType>::year_month_day_base(YearType y, > MonthType m, > DayType d) : > year(y), > month(m), > day(d) > {} > >} } ># 14 "/usr/include/boost/date_time/date.hpp" 2 3 4 > > >namespace boost { >namespace date_time { ># 52 "/usr/include/boost/date_time/date.hpp" 3 4 > template<class T, class calendar, class duration_type_> > class date : private > boost::less_than_comparable<T > , boost::equality_comparable<T > > > > { > 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)) > {} > > 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_; > } > > bool is_special()const > { > return(is_not_a_date() || is_infinity()); > } > > bool is_not_a_date() const > { > return traits_type::is_not_a_number(days_); > } > > bool is_infinity() const > { > return traits_type::is_inf(days_); > } > > bool is_pos_infinity() const > { > return traits_type::is_pos_inf(days_); > } > > bool is_neg_infinity() const > { > return traits_type::is_neg_inf(days_); > } > > 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()) > { > > > 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 > { > > 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_; > } > > 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_); > } > > > protected: > > > > > explicit date(date_int_type days) : days_(days) {} > explicit date(date_rep_type days) : days_(days.as_number()) {} > date_int_type days_; > > }; > > > > >} } ># 18 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/period.hpp" 1 3 4 ># 23 "/usr/include/boost/date_time/period.hpp" 3 4 >namespace boost { >namespace date_time { ># 50 "/usr/include/boost/date_time/period.hpp" 3 4 > template<class point_rep, class duration_rep> > class period : private > boost::less_than_comparable<period<point_rep, duration_rep> > , boost::equality_comparable< period<point_rep, duration_rep> > > > > { > 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_; > }; > > > > > template<class point_rep, class duration_rep> > inline > period<point_rep,duration_rep>::period(point_rep first_point, > point_rep end_point) : > begin_(first_point), > last_(end_point - duration_rep::unit()) > {} > > > > > template<class point_rep, class duration_rep> > inline > period<point_rep,duration_rep>::period(point_rep first_point, duration_rep len) : > begin_(first_point), > last_(first_point + len-duration_rep::unit()) > { } > > > > template<class point_rep, class duration_rep> > inline > point_rep period<point_rep,duration_rep>::begin() const > { > return begin_; > } > > > template<class point_rep, class duration_rep> > inline > point_rep period<point_rep,duration_rep>::end() const > { > return last_ + duration_rep::unit(); > } > > > template<class point_rep, class duration_rep> > inline > point_rep period<point_rep,duration_rep>::last() const > { > return last_; > } > > > template<class point_rep, class duration_rep> > inline > bool period<point_rep,duration_rep>::is_null() const > { > return end() <= begin_; > } > > > template<class point_rep, class duration_rep> > inline > duration_rep period<point_rep,duration_rep>::length() const > { > if(last_ < begin_){ > return last_+duration_rep::unit() - begin_; > } > else{ > return end() - begin_; > } > } > > > template<class point_rep, class duration_rep> > inline > bool period<point_rep,duration_rep>::operator==(const period& rhs) const > { > return ((begin_ == rhs.begin_) && > (last_ == rhs.last_)); > } > > > template<class point_rep, class duration_rep> > inline > bool period<point_rep,duration_rep>::operator<(const period& rhs) const > { > return (last_ < rhs.begin_); > } > > > > template<class point_rep, class duration_rep> > inline > void period<point_rep,duration_rep>::shift(const duration_rep& d) > { > begin_ = begin_ + d; > last_ = last_ + d; > } ># 198 "/usr/include/boost/date_time/period.hpp" 3 4 > template<class point_rep, class duration_rep> > inline > void period<point_rep,duration_rep>::expand(const duration_rep& d) > { > begin_ = begin_ - d; > last_ = last_ + d; > } > > > template<class point_rep, class duration_rep> > inline > bool period<point_rep,duration_rep>::contains(const point_rep& point) const > { > return ((point >= begin_) && > (point <= last_)); > } > > > > template<class point_rep, class duration_rep> > inline > bool period<point_rep,duration_rep>::contains(const period<point_rep,duration_rep>& other) const > { > return ((begin_ <= other.begin_) && (last_ >= other.last_)); > } ># 234 "/usr/include/boost/date_time/period.hpp" 3 4 > template<class point_rep, class duration_rep> > inline > bool > period<point_rep,duration_rep>::is_adjacent(const period<point_rep,duration_rep>& other) const > { > return (other.begin() == end() || > begin_ == other.end()); > } ># 253 "/usr/include/boost/date_time/period.hpp" 3 4 > template<class point_rep, class duration_rep> > inline > bool > period<point_rep,duration_rep>::is_after(const point_rep& t) const > { > if (is_null()) > { > return false; > } > > return t < begin_; > } ># 275 "/usr/include/boost/date_time/period.hpp" 3 4 > template<class point_rep, class duration_rep> > inline > bool > period<point_rep,duration_rep>::is_before(const point_rep& t) const > { > if (is_null()) > { > return false; > } > > return last_ < t; > } ># 300 "/usr/include/boost/date_time/period.hpp" 3 4 > template<class point_rep, class duration_rep> > inline > bool period<point_rep,duration_rep>::intersects(const period<point_rep,duration_rep>& other) const > { > return ( contains(other.begin_) || > other.contains(begin_) || > ((other.begin_ < begin_) && (other.last_ >= begin_))); > } > > > template<class point_rep, class duration_rep> > inline > period<point_rep,duration_rep> > period<point_rep,duration_rep>::intersection(const period<point_rep,duration_rep>& other) const > { > if (begin_ > other.begin_) { > if (last_ <= other.last_) { > return *this; > } > > return period<point_rep,duration_rep>(begin_, other.end()); > } > else { > if (last_ <= other.last_) { > return period<point_rep,duration_rep>(other.begin_, this->end()); > } > > return other; > } > > } > > > > > template<class point_rep, class duration_rep> > inline > period<point_rep,duration_rep> > period<point_rep,duration_rep>::merge(const period<point_rep,duration_rep>& other) const > { > if (this->intersects(other)) { > if (begin_ < other.begin_) { > return period<point_rep,duration_rep>(begin_, last_ > other.last_ ? this->end() : other.end()); > } > > return period<point_rep,duration_rep>(other.begin_, last_ > other.last_ ? this->end() : other.end()); > > } > return period<point_rep,duration_rep>(begin_,begin_); > } ># 362 "/usr/include/boost/date_time/period.hpp" 3 4 > template<class point_rep, class duration_rep> > inline > period<point_rep,duration_rep> > period<point_rep,duration_rep>::span(const period<point_rep,duration_rep>& other) const > { > point_rep start((begin_ < other.begin_) ? begin() : other.begin()); > point_rep newend((last_ < other.last_) ? other.end() : this->end()); > return period<point_rep,duration_rep>(start, newend); > } > > >} } ># 19 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/gregorian/greg_calendar.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/gregorian/greg_calendar.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/gregorian/greg_calendar.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/gregorian/greg_weekday.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/gregorian/greg_weekday.hpp" 3 4 ># 1 "/usr/include/boost/date_time/constrained_value.hpp" 1 3 4 ># 17 "/usr/include/boost/date_time/constrained_value.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_base_of.hpp" 1 3 4 ># 19 "/usr/include/boost/type_traits/is_base_of.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 20 "/usr/include/boost/type_traits/is_base_of.hpp" 2 3 4 > >namespace boost { > > namespace detail{ > template <class B, class D> > struct is_base_of_imp > { > typedef typename remove_cv<B>::type ncvB; > typedef typename remove_cv<D>::type ncvD; > static const bool value = (::boost::type_traits::ice_or< (::boost::detail::is_base_and_derived_impl<ncvB,ncvD>::value), (::boost::type_traits::ice_and< ::boost::is_same<ncvB,ncvD>::value, ::boost::is_class<ncvB>::value>::value)>::value) > > ; > }; > } > >template< typename Base, typename Derived > struct is_base_of : public ::boost::integral_constant<bool,(::boost::detail::is_base_of_imp<Base, Derived>::value)> { public: }; > > > > > > >template< typename Base, typename Derived > struct is_base_of< Base&,Derived > : public ::boost::integral_constant<bool,false> { public: }; >template< typename Base, typename Derived > struct is_base_of< Base,Derived& > : public ::boost::integral_constant<bool,false> { public: }; >template< typename Base, typename Derived > struct is_base_of< Base&,Derived& > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 50 "/usr/include/boost/type_traits/is_base_of.hpp" 2 3 4 ># 18 "/usr/include/boost/date_time/constrained_value.hpp" 2 3 4 > >namespace boost { > > >namespace CV { > > enum violation_enum {min_violation, max_violation}; ># 41 "/usr/include/boost/date_time/constrained_value.hpp" 3 4 > template<class value_policies> > class constrained_value { > public: > typedef typename value_policies::value_type value_type; > > constrained_value(value_type value) : value_((min)()) > { > assign(value); > } > constrained_value& operator=(value_type v) > { > assign(v); > return *this; > } > > static value_type max () {return (value_policies::max)();} > > static value_type min () {return (value_policies::min)();} > > operator value_type() const {return value_;} > protected: > value_type value_; > private: > void assign(value_type value) > { > > > 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<typename rep_type, rep_type min_value, > rep_type max_value, class exception_type> > class simple_exception_policy > { > struct exception_wrapper : public exception_type > { > > > > > operator std::out_of_range () const > { > > 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 () { return min_value; } > static rep_type max () { return max_value; } > static void on_error(rep_type, rep_type, violation_enum) > { > boost::throw_exception(actual_exception_type()); > } > }; > > > >} } ># 13 "/usr/include/boost/date_time/gregorian/greg_weekday.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/date_defs.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/date_defs.hpp" 3 4 >namespace boost { >namespace date_time { > > > enum weekdays {Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday}; > > > enum months_of_year {Jan=1,Feb,Mar,Apr,May,Jun,Jul,Aug,Sep,Oct,Nov,Dec,NotAMonth,NumMonths}; > >} } ># 14 "/usr/include/boost/date_time/gregorian/greg_weekday.hpp" 2 3 4 > > > > >namespace boost { >namespace gregorian { > > > 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; > > > > 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<unsigned short, 0, 6, bad_weekday> greg_weekday_policies; > typedef CV::constrained_value<greg_weekday_policies> greg_weekday_rep; > > > > class 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; > > const wchar_t* as_short_wstring() const; > const wchar_t* as_long_wstring() const; > > weekday_enum as_enum() const {return static_cast<weekday_enum>(value_);} > > > }; > > > >} } ># 14 "/usr/include/boost/date_time/gregorian/greg_calendar.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/gregorian/greg_day_of_year.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/gregorian/greg_day_of_year.hpp" 3 4 >namespace boost { >namespace gregorian { > > > 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")) > {} > }; > > > typedef CV::simple_exception_policy<unsigned short,1,366,bad_day_of_year> greg_day_of_year_policies; > > > typedef CV::constrained_value<greg_day_of_year_policies> greg_day_of_year_rep; > > >} } ># 15 "/usr/include/boost/date_time/gregorian/greg_calendar.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/gregorian_calendar.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/gregorian_calendar.hpp" 3 4 >namespace boost { >namespace date_time { ># 27 "/usr/include/boost/date_time/gregorian_calendar.hpp" 3 4 > template<typename ymd_type_, typename date_int_type_> > class gregorian_calendar_base { > public: > > typedef ymd_type_ ymd_type; > > typedef typename ymd_type::month_type month_type; > > typedef typename ymd_type::day_type day_type; > > typedef typename ymd_type::year_type year_type; > > 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 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(); > > }; > > > >} } > > ># 1 "/usr/include/boost/date_time/gregorian_calendar.ipp" 1 3 4 ># 14 "/usr/include/boost/date_time/gregorian_calendar.ipp" 3 4 >namespace boost { >namespace date_time { > > > > template<typename ymd_type_, typename date_int_type_> > inline > unsigned short > gregorian_calendar_base<ymd_type_,date_int_type_>::day_of_week(const ymd_type& ymd) { > unsigned short a = static_cast<unsigned short>((14-ymd.month)/12); > unsigned short y = static_cast<unsigned short>(ymd.year - a); > unsigned short m = static_cast<unsigned short>(ymd.month + 12*a - 2); > unsigned short d = static_cast<unsigned short>((ymd.day + y + (y/4) - (y/100) + (y/400) + (31*m)/12) % 7); > > return d; > } > > > > > > > > template<typename ymd_type_, typename date_int_type_> > inline > int > gregorian_calendar_base<ymd_type_,date_int_type_>::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; > } else { > return 1; > } > } > > else if (week == 0) { > julianbegin = julian_day_number(ymd_type(static_cast<unsigned short>(ymd.year-1),1,1)); > juliantoday = julian_day_number(ymd); > day = (julianbegin + 3) % 7; > week = (juliantoday + day - julianbegin + 4)/7; > return week; > } > > return week; > > } > > > > > template<typename ymd_type_, typename date_int_type_> > inline > date_int_type_ > gregorian_calendar_base<ymd_type_,date_int_type_>::day_number(const ymd_type& ymd) > { > unsigned short a = static_cast<unsigned short>((14-ymd.month)/12); > unsigned short y = static_cast<unsigned short>(ymd.year + 4800 - a); > unsigned short m = static_cast<unsigned short>(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; > } > > > > > template<typename ymd_type_, typename date_int_type_> > inline > date_int_type_ > gregorian_calendar_base<ymd_type_,date_int_type_>::julian_day_number(const ymd_type& ymd) > { > return day_number(ymd); > } > > > > > > template<typename ymd_type_, typename date_int_type_> > inline > date_int_type_ > gregorian_calendar_base<ymd_type_,date_int_type_>::modjulian_day_number(const ymd_type& ymd) > { > return julian_day_number(ymd)-2400001; > } > > > template<typename ymd_type_, typename date_int_type_> > inline > ymd_type_ > gregorian_calendar_base<ymd_type_,date_int_type_>::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<unsigned short>(e - ((153*m + 2)/5) + 1); > unsigned short month = static_cast<unsigned short>(m + 3 - 12 * (m/10)); > year_type year = static_cast<unsigned short>(100*b + d - 4800 + (m/10)); > > > return ymd_type(static_cast<unsigned short>(year),month,day); > } > > > template<typename ymd_type_, typename date_int_type_> > inline > ymd_type_ > gregorian_calendar_base<ymd_type_,date_int_type_>::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<unsigned short>(e - ((153*m + 2)/5) + 1); > unsigned short month = static_cast<unsigned short>(m + 3 - 12 * (m/10)); > year_type year = static_cast<year_type>(100*b + d - 4800 + (m/10)); > > > return ymd_type(year,month,day); > } > > > template<typename ymd_type_, typename date_int_type_> > inline > ymd_type_ > gregorian_calendar_base<ymd_type_,date_int_type_>::from_modjulian_day_number(date_int_type dayNumber) { > date_int_type jd = dayNumber + 2400001; > return from_julian_day_number(jd); > } > > > > > > template<typename ymd_type_, typename date_int_type_> > inline > bool > gregorian_calendar_base<ymd_type_,date_int_type_>::is_leap_year(year_type year) > { > > return (!(year % 4)) && ((year % 100) || (!(year % 400))); > } > > > > > > template<typename ymd_type_, typename date_int_type_> > inline > unsigned short > gregorian_calendar_base<ymd_type_,date_int_type_>::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; > }; > > } > > > template<typename ymd_type_, typename date_int_type_> > inline > ymd_type_ > gregorian_calendar_base<ymd_type_,date_int_type_>::epoch() > { > return ymd_type(1400,1,1); > } > > > template<typename ymd_type_, typename date_int_type_> > inline > unsigned short > gregorian_calendar_base<ymd_type_,date_int_type_>::days_in_week() > { > return 7; > } > > >} } ># 64 "/usr/include/boost/date_time/gregorian_calendar.hpp" 2 3 4 ># 16 "/usr/include/boost/date_time/gregorian/greg_calendar.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/gregorian/greg_ymd.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/gregorian/greg_ymd.hpp" 3 4 ># 1 "/usr/include/boost/date_time/gregorian/greg_day.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/gregorian/greg_day.hpp" 3 4 >namespace boost { >namespace gregorian { > > > 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")) > {} > > bad_day_of_month(const std::string& s) : > std::out_of_range(s) > {} > }; > > typedef CV::simple_exception_policy<unsigned short, 1, 31, bad_day_of_month> greg_day_policies; > > > typedef CV::constrained_value<greg_day_policies> greg_day_rep; > > > > > > > > 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: > > }; > > > >} } ># 15 "/usr/include/boost/date_time/gregorian/greg_ymd.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/gregorian/greg_year.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/gregorian/greg_year.hpp" 3 4 >namespace boost { >namespace gregorian { > > > struct bad_year : public std::out_of_range > { > bad_year() : > std::out_of_range(std::string("Year is out of valid range: 1400..10000")) > {} > }; > > typedef CV::simple_exception_policy<unsigned short, 1400, 10000, bad_year> greg_year_policies; > > > typedef CV::constrained_value<greg_year_policies> greg_year_rep; ># 39 "/usr/include/boost/date_time/gregorian/greg_year.hpp" 3 4 > class greg_year : public greg_year_rep { > public: > greg_year(unsigned short year) : greg_year_rep(year) {} > operator unsigned short() const {return value_;} > private: > > }; > > > >} } ># 16 "/usr/include/boost/date_time/gregorian/greg_ymd.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/gregorian/greg_month.hpp" 1 3 4 ># 20 "/usr/include/boost/date_time/gregorian/greg_month.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cctype" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cctype" 3 4 ># 40 "/usr/include/c++/4.9.0/cctype" 3 ># 21 "/usr/include/boost/date_time/gregorian/greg_month.hpp" 2 3 4 > >namespace boost { >namespace gregorian { > > typedef date_time::months_of_year months_of_year; > > > 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; > > > struct bad_month : public std::out_of_range > { > bad_month() : std::out_of_range(std::string("Month number is out of range 1..12")) {} > }; > > typedef CV::simple_exception_policy<unsigned short, 1, 12, bad_month> greg_month_policies; > > typedef CV::constrained_value<greg_month_policies> greg_month_rep; > > > > class greg_month : public greg_month_rep { > public: > typedef date_time::months_of_year month_enum; > typedef std::map<std::string, unsigned short> month_map_type; > typedef boost::shared_ptr<month_map_type> month_map_ptr_type; > > greg_month(month_enum theMonth) : > greg_month_rep(static_cast<greg_month_rep::value_type>(theMonth)) {} > > greg_month(unsigned short theMonth) : greg_month_rep(theMonth) {} > > operator unsigned short() const {return value_;} > > unsigned short as_number() const {return value_;} > month_enum as_enum() const {return static_cast<month_enum>(value_);} > const char* as_short_string() const; > const char* as_long_string() const; > > const wchar_t* as_short_wstring() const; > const wchar_t* as_long_wstring() const; > > > static month_map_ptr_type get_month_map_ptr(); > > > > const char* as_short_string(char) const > { > return as_short_string(); > } > const char* as_long_string(char) const > { > return as_long_string(); > } > > 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(); > } > > }; > >} } ># 17 "/usr/include/boost/date_time/gregorian/greg_ymd.hpp" 2 3 4 > >namespace boost { >namespace gregorian { > > typedef date_time::year_month_day_base<greg_year, > greg_month, > greg_day> greg_year_month_day; > > > >} } ># 17 "/usr/include/boost/date_time/gregorian/greg_calendar.hpp" 2 3 4 > > >namespace boost { >namespace gregorian { > > > typedef date_time::int_adapter<uint32_t> fancy_date_rep; > > > class gregorian_calendar : > public date_time::gregorian_calendar_base<greg_year_month_day, fancy_date_rep::int_type> { > public: > > typedef greg_weekday day_of_week_type; > > typedef greg_day_of_year_rep day_of_year_type; > > typedef fancy_date_rep date_rep_type; > > typedef fancy_date_rep date_traits_type; > > > private: > }; > >} } ># 20 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/gregorian/greg_duration.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/gregorian/greg_duration.hpp" 3 4 ># 1 "/usr/include/boost/date_time/date_duration.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/date_duration.hpp" 3 4 >namespace boost { >namespace date_time { > > > > template<class duration_rep_traits> > 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; > > > explicit date_duration(duration_rep day_count) : days_(day_count) {} > > > > date_duration(special_values sv) : > days_(duration_rep::from_special(sv)) > {} > > > > date_duration(const date_duration<duration_rep_traits>& other) : > days_(other.days_) > {} > > > duration_rep get_rep()const > { > return days_; > } > bool is_special()const > { > return days_.is_special(); > } > > duration_rep_type days() const > { > return duration_rep_traits::as_number(days_); > } > > static date_duration unit() > { > return date_duration<duration_rep_traits>(1); > } > > bool operator==(const date_duration& rhs) const > { > return days_ == rhs.days_; > } > > bool operator<(const date_duration& rhs) const > { > return days_ < rhs.days_; > } > > > > > > > > date_duration& operator-=(const date_duration& rhs) > { > > days_ = days_ - rhs.days_; > return *this; > } > > date_duration& operator+=(const date_duration& rhs) > { > days_ = days_ + rhs.days_; > return *this; > } > > > date_duration operator-() const > { > return date_duration<duration_rep_traits>(get_rep() * (-1)); > } > > date_duration& operator/=(int divisor) > { > days_ = days_ / divisor; > return *this; > } > > > bool is_negative() const > { > return days_ < 0; > } > > private: > duration_rep days_; > }; > > > > > > struct duration_traits_long > { > typedef long int_type; > typedef long impl_type; > static int_type as_number(impl_type i) { return i; } > }; > > > > > struct duration_traits_adapted > { > typedef long int_type; > typedef boost::date_time::int_adapter<long> impl_type; > static int_type as_number(impl_type i) { return i.as_number(); } > }; > > >} } ># 13 "/usr/include/boost/date_time/gregorian/greg_duration.hpp" 2 3 4 > > > >namespace boost { >namespace gregorian { > > > typedef boost::date_time::duration_traits_adapted date_duration_rep; > > > > > 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; > > > explicit date_duration(duration_rep day_count = 0) : base_type(day_count) {} > > > date_duration(date_time::special_values sv) : base_type(sv) {} > > > date_duration(const date_duration& other) : base_type(static_cast< base_type const& >(other)) > {} > > > date_duration(const base_type& other) : base_type(other) > {} > > > > > > 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); > } > > > 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; > } > > > 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; > } > > > date_duration operator- ()const > { > return date_duration(get_rep() * (-1)); > } > > > date_duration& operator/= (int divisor) > { > base_type::operator/= (divisor); > return *this; > } > friend date_duration operator/ (date_duration rhs, int lhs) > { > rhs /= lhs; > return rhs; > } > > > static date_duration unit() > { > return date_duration(base_type::unit().get_rep()); > } > }; > > > typedef date_duration days; > >} } > > ># 1 "/usr/include/boost/date_time/date_duration_types.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/date_duration_types.hpp" 3 4 >namespace boost { >namespace date_time { > > > > template <class duration_config> > class weeks_duration : public date_duration<duration_config> { > public: > weeks_duration(typename duration_config::impl_type w) > : date_duration<duration_config>(w * 7) {} > weeks_duration(special_values sv) > : date_duration<duration_config>(sv) {} > }; > > > template<class t> > class years_duration; > > > > > > > template<class base_config> > 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<base_config> months_type; > typedef years_duration<base_config> 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; } > > 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) > { > > return d + m.get_neg_offset(d); > } > friend date_type operator-=(date_type& d, const months_type& m) > { > > return d += m.get_neg_offset(d); > } > > private: > int_rep _m; > }; > > > > > > > > template<class base_config> > 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<base_config> years_type; > typedef months_duration<base_config> 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; } > > 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) > { > > return d + y.get_neg_offset(d); > } > friend date_type operator-=(date_type& d, const years_type& y) > { > > return d += y.get_neg_offset(d); > } > > private: > int_rep _y; > }; > >}} ># 132 "/usr/include/boost/date_time/gregorian/greg_duration.hpp" 2 3 4 ># 21 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/gregorian/greg_duration_types.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/gregorian/greg_duration_types.hpp" 3 4 ># 1 "/usr/include/boost/date_time/gregorian/greg_date.hpp" 1 3 4 ># 18 "/usr/include/boost/date_time/gregorian/greg_date.hpp" 3 4 >namespace boost { >namespace gregorian { > > > 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; ># 37 "/usr/include/boost/date_time/gregorian/greg_date.hpp" 3 4 > class date : public date_time::date<date, gregorian_calendar, date_duration> > { > 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; > > > date(): > date_time::date<date, gregorian_calendar, date_duration>(date_rep_type::from_special(not_a_date_time)) > {} > > > date(year_type y, month_type m, day_type d) > : date_time::date<date, gregorian_calendar, date_duration>(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"))); > } > } > > explicit date(const ymd_type& ymd) > : date_time::date<date, gregorian_calendar, date_duration>(ymd) > {} > > explicit date(const date_int_type& rhs): > date_time::date<date,gregorian_calendar, date_duration>(rhs) > {} > > explicit date(date_rep_type rhs): > date_time::date<date,gregorian_calendar, date_duration>(rhs) > {} > > explicit date(special_values sv): > date_time::date<date, gregorian_calendar, date_duration>(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); > } > > } > > date_int_type julian_day() const > { > ymd_type ymd = year_month_day(); > return gregorian_calendar::julian_day_number(ymd); > } > > day_of_year_type day_of_year() const > { > date start_of_year(year(), 1, 1); > unsigned short doy = static_cast<unsigned short>((*this-start_of_year).days() + 1); > return day_of_year_type(doy); > } > > date_int_type modjulian_day() const > { > ymd_type ymd = year_month_day(); > return gregorian_calendar::modjulian_day_number(ymd); > } > > int week_number() const > { > ymd_type ymd = year_month_day(); > return gregorian_calendar::week_number(ymd); > } > > date_int_type day_number() const > { > return days_; > } > > 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: > > }; > > > >} } ># 13 "/usr/include/boost/date_time/gregorian/greg_duration_types.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/adjust_functors.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/adjust_functors.hpp" 3 4 ># 1 "/usr/include/boost/date_time/wrapping_int.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/wrapping_int.hpp" 3 4 >namespace boost { >namespace date_time { ># 30 "/usr/include/boost/date_time/wrapping_int.hpp" 3 4 >template<typename int_type_, int_type_ wrap_val> >class wrapping_int { >public: > typedef int_type_ int_type; > > static int_type wrap_value() {return wrap_val;} > > wrapping_int(int_type v) : value_(v) {} > > int_type as_int() const {return value_;} > operator int_type() const {return value_;} > > > > > > template< typename IntT > > IntT add(IntT v) > { > int_type remainder = static_cast<int_type>(v % (wrap_val)); > IntT overflow = static_cast<IntT>(v / (wrap_val)); > value_ = static_cast<int_type>(value_ + remainder); > return calculate_wrap(overflow); > } > > > > > > > template< typename IntT > > IntT subtract(IntT v) > { > int_type remainder = static_cast<int_type>(v % (wrap_val)); > IntT underflow = static_cast<IntT>(-(v / (wrap_val))); > value_ = static_cast<int_type>(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; > } > >}; > > > > > > >template<typename int_type_, int_type_ wrap_min, int_type_ wrap_max> >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;} > > > wrapping_int2(int_type v) : value_(v) { > if(value_ < wrap_min) > { > value_ = wrap_min; > } > if(value_ > wrap_max) > { > value_ = wrap_max; > } > } > > int_type as_int() const {return value_;} > operator int_type() const {return value_;} > > > > > > template< typename IntT > > IntT add(IntT v) > { > int_type remainder = static_cast<int_type>(v % (wrap_max - wrap_min + 1)); > IntT overflow = static_cast<IntT>(v / (wrap_max - wrap_min + 1)); > value_ = static_cast<int_type>(value_ + remainder); > return calculate_wrap(overflow); > } > > > > > > template< typename IntT > > IntT subtract(IntT v) > { > int_type remainder = static_cast<int_type>(v % (wrap_max - wrap_min + 1)); > IntT underflow = static_cast<IntT>(-(v / (wrap_max - wrap_min + 1))); > value_ = static_cast<int_type>(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; > } >}; > > > >} } ># 14 "/usr/include/boost/date_time/adjust_functors.hpp" 2 3 4 > >namespace boost { >namespace date_time { > > > > template<class date_type> > 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 > { > > > d.year(); > return duration_type(f_); > } > duration_type get_neg_offset(const date_type& d) const > { > > d.year(); > return duration_type(-f_); > } > private: > int f_; > }; ># 53 "/usr/include/boost/date_time/adjust_functors.hpp" 3 4 > template<class date_type> > 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; > } > } > typedef date_time::wrapping_int2<short,1,12> wrap_int2; > typedef typename wrap_int2::int_type int_type; > wrap_int2 wi(ymd.month); > > int_type year = wi.add(static_cast<int_type>(f_)); > year = static_cast<int_type>(year + ymd.year); > > > > day_type resultingEndOfMonthDay(cal_type::end_of_month_day(year, wi.as_int())); > > 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; > } > > 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; > } > } > typedef date_time::wrapping_int2<short,1,12> wrap_int2; > typedef typename wrap_int2::int_type int_type; > wrap_int2 wi(ymd.month); > > int_type year = wi.subtract(static_cast<int_type>(f_)); > year = static_cast<int_type>(year + ymd.year); > > day_type resultingEndOfMonthDay(cal_type::end_of_month_day(year, wi.as_int())); > > 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_; > }; > > > > template<class date_type> > 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 > { > > > d.year(); > return duration_type(f_*calendar_type::days_in_week()); > } > duration_type get_neg_offset(const date_type& d) const > { > > d.year(); > return duration_type(-f_*calendar_type::days_in_week()); > } > private: > int f_; > }; > > > template<class date_type> > class year_functor > { > public: > > 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<date_type> _mf; > }; > > >} } ># 15 "/usr/include/boost/date_time/gregorian/greg_duration_types.hpp" 2 3 4 > > > >namespace boost { >namespace gregorian { > > > struct greg_durations_config { > typedef date date_type; > typedef date_time::int_adapter<int> int_rep; > typedef date_time::month_functor<date_type> month_adjustor_type; > }; > > typedef date_time::months_duration<greg_durations_config> months; > typedef date_time::years_duration<greg_durations_config> 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; > >}} ># 23 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 2 3 4 > > ># 1 "/usr/include/boost/date_time/date_generators.hpp" 1 3 4 ># 22 "/usr/include/boost/date_time/date_generators.hpp" 3 4 >namespace boost { >namespace date_time { > > > > > > > > template<class date_type> > 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; > > virtual std::string to_string() const =0; > }; ># 55 "/usr/include/boost/date_time/date_generators.hpp" 3 4 > template<class date_type> > class partial_date : public year_based_generator<date_type> > { > 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(duration_rep days) : > day_(1), > month_(1) > { > date_type d1(2000,1,1); > if(days > 1) { > if(days > 366) > { > days = 366; > } > days = days - 1; > duration_type dd(days); > d1 = d1 + dd; > } > day_ = d1.day(); > month_ = d1.month(); > } ># 101 "/usr/include/boost/date_time/date_generators.hpp" 3 4 > 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); > > } > 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; > > return (day_ < rhs.day_); > } > > > month_type month() const > { > return month_; > } > day_type day() const > { > return day_; > } > > > > > > > virtual std::string to_string() const > { > std::ostringstream ss; > date_type d(2004, month_, day_); > unsigned short c = d.day_of_year(); > c--; > ss << c; > return ss.str(); > } > private: > day_type day_; > month_type month_; > }; > > > > const char* nth_as_str(int n); ># 177 "/usr/include/boost/date_time/date_generators.hpp" 3 4 > template<class date_type> > class nth_kday_of_month : public year_based_generator<date_type> > { > 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) > {} > > date_type get_date(year_type y) const > { > date_type d(y, month_, 1); > 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++; > } > > if(d.month() != month_) { > d = d - one_week; > } > return d; > } > > 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_); > } > > > virtual std::string to_string() const > { > std::ostringstream ss; > ss << 'M' > << static_cast<int>(month_) << '.' > << static_cast<int>(wn_) << '.' > << static_cast<int>(dow_); > return ss.str(); > } > private: > month_type month_; > week_num wn_; > day_of_week_type dow_; > }; > > > > > > template<class date_type> > class first_kday_of_month : public year_based_generator<date_type> > { > 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; > > > > > first_kday_of_month(day_of_week_type dow, month_type m) : > month_(m), > dow_(dow) > {} > > 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; > } > > month_type month() const > { > return month_; > } > day_of_week_type day_of_week() const > { > return dow_; > } > > > virtual std::string to_string() const > { > std::ostringstream ss; > ss << 'M' > << static_cast<int>(month_) << '.' > << 1 << '.' > << static_cast<int>(dow_); > return ss.str(); > } > private: > month_type month_; > day_of_week_type dow_; > }; ># 313 "/usr/include/boost/date_time/date_generators.hpp" 3 4 > template<class date_type> > class last_kday_of_month : public year_based_generator<date_type> > { > 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; > > > > > last_kday_of_month(day_of_week_type dow, month_type m) : > month_(m), > dow_(dow) > {} > > 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; > } > > month_type month() const > { > return month_; > } > day_of_week_type day_of_week() const > { > return dow_; > } > > > virtual std::string to_string() const > { > std::ostringstream ss; > ss << 'M' > << static_cast<int>(month_) << '.' > << 5 << '.' > << static_cast<int>(dow_); > return ss.str(); > } > private: > month_type month_; > day_of_week_type dow_; > }; ># 375 "/usr/include/boost/date_time/date_generators.hpp" 3 4 > template<class date_type> > 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) > {} > > 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; > } > > day_of_week_type day_of_week() const > { > return dow_; > } > private: > day_of_week_type dow_; > }; ># 413 "/usr/include/boost/date_time/date_generators.hpp" 3 4 > template<class date_type> > 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) > {} > > 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; > } > > day_of_week_type day_of_week() const > { > return dow_; > } > private: > day_of_week_type dow_; > }; > > > > > > template<typename date_type, class weekday_type> > 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; > } > > > > > > > template<typename date_type, class weekday_type> > 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); > } > > > return (-dd + wks); > } > > > > > > > template<class date_type, class weekday_type> > inline > date_type next_weekday(const date_type& d, const weekday_type& wd) > { > return d + days_until_weekday(d, wd); > } > > > > > > > template<class date_type, class weekday_type> > inline > date_type previous_weekday(const date_type& d, const weekday_type& wd) > { > return d - days_before_weekday(d, wd); > } > >} } ># 26 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/date_clock_device.hpp" 1 3 4 ># 15 "/usr/include/boost/date_time/date_clock_device.hpp" 3 4 >namespace boost { >namespace date_time { > > > > > > > > template<class date_type> > class day_clock > { > public: > typedef typename date_type::ymd_type ymd_type; > > static date_type local_day() > { > return date_type(local_day_ymd()); > } > > 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); > } > > 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); > } > > 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); > } > > }; > >} } ># 27 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/date_iterator.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/date_iterator.hpp" 3 4 >namespace boost { >namespace date_time { > > enum date_resolutions {day, week, months, year, decade, century, NumDateResolutions}; ># 32 "/usr/include/boost/date_time/date_iterator.hpp" 3 4 > template<class date_type> > class date_itr_base { > > > > 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_; > }; ># 76 "/usr/include/boost/date_time/date_iterator.hpp" 3 4 > template<class offset_functor, class date_type> > class date_itr : public date_itr_base<date_type> { > public: > typedef typename date_type::duration_type duration_type; > date_itr(date_type d, int factor=1) : > date_itr_base<date_type>(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_; > }; > > > >} } ># 28 "/usr/include/boost/date_time/gregorian/gregorian_types.hpp" 2 3 4 > > >namespace boost { > > > > > > >namespace gregorian { > > > > typedef date_time::period<date, date_duration> date_period; > > > > > > > typedef date_time::year_based_generator<date> year_based_generator; > > > typedef date_time::partial_date<date> partial_date; > > typedef date_time::nth_kday_of_month<date> nth_kday_of_month; > typedef nth_kday_of_month nth_day_of_the_week_in_month; > > typedef date_time::first_kday_of_month<date> first_kday_of_month; > typedef first_kday_of_month first_day_of_the_week_in_month; > > typedef date_time::last_kday_of_month<date> last_kday_of_month; > typedef last_kday_of_month last_day_of_the_week_in_month; > > typedef date_time::first_kday_after<date> first_kday_after; > typedef first_kday_after first_day_of_the_week_after; > > typedef date_time::first_kday_before<date> first_kday_before; > typedef first_kday_before first_day_of_the_week_before; > > > > > typedef date_time::day_clock<date> day_clock; > > > > > typedef date_time::date_itr_base<date> date_iterator; > > > > > typedef date_time::date_itr<date_time::day_functor<date>, > date> day_iterator; > > > > typedef date_time::date_itr<date_time::week_functor<date>, > date> week_iterator; > > > > typedef date_time::date_itr<date_time::month_functor<date>, > date> month_iterator; > > > > typedef date_time::date_itr<date_time::year_functor<date>, > date> year_iterator; > > > using date_time::days_until_weekday; > using date_time::days_before_weekday; > using date_time::next_weekday; > using date_time::previous_weekday; > >} } ># 19 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 2 3 4 > > > >namespace boost { >namespace posix_time { ># 40 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 3 4 > typedef date_time::time_resolution_traits< > boost::date_time::time_resolution_traits_adapted64_impl, boost::date_time::micro, > 1000000, 6 > time_res_traits; ># 57 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 3 4 > class time_duration : > public date_time::time_duration<time_duration, time_res_traits> > { > 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<time_duration, time_res_traits>(hour,min,sec,fs) > {} > time_duration() : > date_time::time_duration<time_duration, time_res_traits>(0,0,0) > {} > > time_duration(boost::date_time::special_values sv) : > date_time::time_duration<time_duration, time_res_traits>(sv) > {} > > friend class date_time::time_duration<time_duration, time_res_traits>; > protected: > explicit time_duration(impl_type tick_count) : > date_time::time_duration<time_duration, time_res_traits>(tick_count) > {} > }; ># 154 "/usr/include/boost/date_time/posix_time/posix_time_config.hpp" 3 4 > class millisec_posix_time_system_config > { > public: > typedef boost::int64_t 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; > > > static const boost::int64_t tick_per_second = 1000000; > > }; > > > >} } ># 14 "/usr/include/boost/date_time/posix_time/posix_time_system.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/time_system_split.hpp" 1 3 4 ># 17 "/usr/include/boost/date_time/time_system_split.hpp" 3 4 >namespace boost { >namespace date_time { > > > > > > template<typename config> > > 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; > > > > > > private: > static const int_type ticks_per_day = 86400L * config::tick_per_second; > public: > > > > typedef date_time::wrapping_int<int_type, ticks_per_day> wrap_int_type; > > > > 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 = 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<typename date_duration_type::duration_rep_type>(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); > time_duration_type td2 = lhs.time_of_day - rhs.time_of_day; > return td+td2; > > } > > }; > >} } ># 15 "/usr/include/boost/date_time/posix_time/posix_time_system.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/time_system_counted.hpp" 1 3 4 ># 18 "/usr/include/boost/date_time/time_system_counted.hpp" 3 4 >namespace boost { >namespace date_time { > > > template<class config> > 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(); > > } > 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(); > > ymd_type ymd = calendar_type::from_day_number(dc); > return date_type(ymd); > } > } > > unsigned long day_count() const > { ># 78 "/usr/include/boost/date_time/time_system_counted.hpp" 3 4 > return static_cast<unsigned long>(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_; > }; > > > template<class time_rep> > 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<class T> 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); > } > } > > }; > > >} } ># 16 "/usr/include/boost/date_time/posix_time/posix_time_system.hpp" 2 3 4 > > > >namespace boost { >namespace posix_time { ># 32 "/usr/include/boost/date_time/posix_time/posix_time_system.hpp" 3 4 > typedef date_time::counted_time_rep<millisec_posix_time_system_config> int64_time_rep; > typedef date_time::counted_time_system<int64_time_rep> posix_time_system; > > > >} } ># 13 "/usr/include/boost/date_time/posix_time/ptime.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/time.hpp" 1 3 4 ># 21 "/usr/include/boost/date_time/time.hpp" 3 4 >namespace boost { >namespace date_time { ># 45 "/usr/include/boost/date_time/time.hpp" 3 4 > template <class T, class time_system> > class base_time : private > boost::less_than_comparable<T > , boost::equality_comparable<T > > > > { > 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; > > > 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_); > } > > > > std::string zone_name(bool =false) const > { > return time_system::zone_name(time_); > } > > > > std::string zone_abbrev(bool =false) const > { > return time_system::zone_name(time_); > } > > std::string zone_as_posix_string() const > { > return std::string(); > } > > > bool is_not_a_date_time() const > { > return time_.is_not_a_date_time(); > } > > bool is_infinity() const > { > return (is_pos_infinity() || is_neg_infinity()); > } > > bool is_pos_infinity() const > { > return time_.is_pos_infinity(); > } > > bool is_neg_infinity() const > { > return time_.is_neg_infinity(); > } > > bool is_special() const > { > return(is_not_a_date_time() || is_infinity()); > } > > bool operator==(const time_type& rhs) const > { > return time_system::is_equal(time_,rhs.time_); > } > > bool operator<(const time_type& rhs) const > { > return time_system::is_less(time_,rhs.time_); > } > > time_duration_type operator-(const time_type& rhs) const > { > return time_system::subtract_times(time_, rhs.time_); > } > > 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_); > } > > 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_); > } > > 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_); > } > > 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_; > }; > > > > > >} } ># 14 "/usr/include/boost/date_time/posix_time/ptime.hpp" 2 3 4 > >namespace boost { > >namespace posix_time { > > > 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; > > > > > class ptime : public date_time::base_time<ptime, posix_time_system> > { > 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; > > ptime(gregorian::date d,time_duration_type td) : date_time::base_time<time_type,time_system_type>(d,td) > {} > > explicit ptime(gregorian::date d) : date_time::base_time<time_type,time_system_type>(d,time_duration_type(0,0,0)) > {} > > ptime(const time_rep_type& rhs): > date_time::base_time<time_type,time_system_type>(rhs) > {} > > ptime(const special_values sv) : date_time::base_time<time_type,time_system_type>(sv) > {} > > > ptime() : date_time::base_time<time_type,time_system_type>(gregorian::date(not_a_date_time), time_duration_type(not_a_date_time)) > {} > > > }; > > > >} } ># 13 "/usr/include/boost/date_time/posix_time/posix_time_types.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/posix_time/date_duration_operators.hpp" 1 3 4 ># 15 "/usr/include/boost/date_time/posix_time/date_duration_operators.hpp" 3 4 >namespace boost { >namespace posix_time { ># 29 "/usr/include/boost/date_time/posix_time/date_duration_operators.hpp" 3 4 > inline > ptime > operator+(const ptime& t, const boost::gregorian::months& m) > { > return t + m.get_offset(t.date()); > } > > > > > inline > ptime > operator+=(ptime& t, const boost::gregorian::months& m) > { > > return t += m.get_offset(t.date()); > } > > > > > inline > ptime > operator-(const ptime& t, const boost::gregorian::months& m) > { > > return t + m.get_neg_offset(t.date()); > } > > > > > inline > ptime > operator-=(ptime& t, const boost::gregorian::months& m) > { > return t += m.get_neg_offset(t.date()); > } > > > > > > > inline > ptime > operator+(const ptime& t, const boost::gregorian::years& y) > { > return t + y.get_offset(t.date()); > } > > > > > inline > ptime > operator+=(ptime& t, const boost::gregorian::years& y) > { > return t += y.get_offset(t.date()); > } > > > > > inline > ptime > operator-(const ptime& t, const boost::gregorian::years& y) > { > > return t + y.get_neg_offset(t.date()); > } > > > > > inline > ptime > operator-=(ptime& t, const boost::gregorian::years& y) > { > > return t += y.get_neg_offset(t.date()); > } > >}} ># 15 "/usr/include/boost/date_time/posix_time/posix_time_types.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/posix_time/posix_time_duration.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/posix_time/posix_time_duration.hpp" 3 4 >namespace boost { >namespace posix_time { > > > > > class hours : public time_duration > { > public: > explicit hours(long h) : > time_duration(h,0,0) > {} > }; > > > > > class minutes : public time_duration > { > public: > explicit minutes(long m) : > time_duration(0,m,0) > {} > }; > > > > > class seconds : public time_duration > { > public: > explicit seconds(long s) : > time_duration(0,0,s) > {} > }; > > > > > > typedef date_time::subsecond_duration<time_duration,1000> millisec; > typedef date_time::subsecond_duration<time_duration,1000> milliseconds; > > > > > typedef date_time::subsecond_duration<time_duration,1000000> microsec; > typedef date_time::subsecond_duration<time_duration,1000000> microseconds; ># 78 "/usr/include/boost/date_time/posix_time/posix_time_duration.hpp" 3 4 >} } ># 17 "/usr/include/boost/date_time/posix_time/posix_time_types.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/posix_time/time_period.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/posix_time/time_period.hpp" 3 4 >namespace boost { >namespace posix_time { > > > > > typedef date_time::period<ptime, time_duration> time_period; > > >} } ># 19 "/usr/include/boost/date_time/posix_time/posix_time_types.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/time_iterator.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/time_iterator.hpp" 3 4 >namespace boost { >namespace date_time { > > > > template<class time_type> > 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_; > }; > > > >} } ># 20 "/usr/include/boost/date_time/posix_time/posix_time_types.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/dst_rules.hpp" 1 3 4 ># 21 "/usr/include/boost/date_time/dst_rules.hpp" 3 4 >namespace boost { > namespace date_time { > > enum time_is_dst_result {is_not_in_dst, is_in_dst, > ambiguous, invalid_time_label}; > > > > template<class date_type_, > class time_duration_type_> > class dst_calculator > { > public: > typedef time_duration_type_ time_duration_type; > typedef date_type_ date_type; ># 47 "/usr/include/boost/date_time/dst_rules.hpp" 3 4 > 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) > { > > 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; > } ># 72 "/usr/include/boost/date_time/dst_rules.hpp" 3 4 > 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) > { > > 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; > } ># 100 "/usr/include/boost/date_time/dst_rules.hpp" 3 4 > 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); > } ># 136 "/usr/include/boost/date_time/dst_rules.hpp" 3 4 > 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) > { > > 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 { > 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); > } > > return invalid_time_label; > } > > }; ># 208 "/usr/include/boost/date_time/dst_rules.hpp" 3 4 > template<class date_type, > class time_duration_type, > class dst_traits> > class dst_calc_engine > { > public: > typedef typename date_type::year_type year_type; > typedef typename date_type::calendar_type calendar_type; > typedef dst_calculator<date_type, time_duration_type> dstcalc; > > > > > > > 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))); > } > > > 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); > } > > > }; > > > > > > > template<class date_type_, > class time_duration_type_, > unsigned int dst_start_offset_minutes=120, > short dst_length_minutes=60> > 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<date_type> lkday; > typedef date_time::first_kday_of_month<date_type> fkday; > typedef date_time::nth_kday_of_month<date_type> nkday; > typedef dst_calculator<date_type, time_duration_type> dstcalc; > > > > > > > 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)) { > > nkday ssim(nkday::second, Sunday, gregorian::Mar); > return ssim.get_date(year); > } else { > > 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)) { > > fkday fsin(Sunday, gregorian::Nov); > return fsin.get_date(year); > } else { > > 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: > > > }; > > > template<class date_type_, class time_duration_type_> > class null_dst_rules > { > public: > typedef time_duration_type_ time_duration_type; > typedef date_type_ date_type; > > > > > > static time_is_dst_result local_is_dst(const date_type&, > const time_duration_type&) > { > return is_not_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 ) > { > return false; > } > > static time_duration_type dst_offset() > { > return time_duration_type(0,0,0); > } > > }; > > > } } ># 21 "/usr/include/boost/date_time/posix_time/posix_time_types.hpp" 2 3 4 > >namespace boost { > > >namespace posix_time { > > > > > typedef date_time::time_itr<ptime> time_iterator; > > > > typedef date_time::second_clock<ptime> second_clock; > > > > > > typedef date_time::microsec_clock<ptime> microsec_clock; > > > > typedef date_time::null_dst_rules<ptime::date_type, time_duration> no_dst; > > typedef date_time::us_dst_rules<ptime::date_type, time_duration> us_dst; > > >} } ># 12 "/usr/include/boost/thread/thread_time.hpp" 2 3 4 > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 14 "/usr/include/boost/thread/thread_time.hpp" 2 3 4 > >namespace boost >{ > typedef boost::posix_time::ptime system_time; > > inline system_time get_system_time() > { > > return boost::date_time::microsec_clock<system_time>::universal_time(); > > > > } > > namespace detail > { > inline system_time get_system_time_sentinel() > { > return system_time(boost::posix_time::pos_infin); > } > > inline unsigned long get_milliseconds_until(system_time const& target_time) > { > if(target_time.is_pos_infinity()) > { > return ~(unsigned long)0; > } > system_time const now=get_system_time(); > if(target_time<=now) > { > return 0; > } > return static_cast<unsigned long>((target_time-now).total_milliseconds()+1); > } > > } > >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 54 "/usr/include/boost/thread/thread_time.hpp" 2 3 4 ># 19 "/usr/include/boost/thread/lock_types.hpp" 2 3 4 > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 21 "/usr/include/boost/thread/lock_types.hpp" 2 3 4 > ># 1 "/usr/include/boost/chrono/time_point.hpp" 1 3 4 ># 33 "/usr/include/boost/chrono/time_point.hpp" 3 4 ># 1 "/usr/include/boost/chrono/duration.hpp" 1 3 4 ># 33 "/usr/include/boost/chrono/duration.hpp" 3 4 ># 1 "/usr/include/boost/chrono/config.hpp" 1 3 4 ># 216 "/usr/include/boost/chrono/config.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 217 "/usr/include/boost/chrono/config.hpp" 2 3 4 ># 34 "/usr/include/boost/chrono/duration.hpp" 2 3 4 ># 1 "/usr/include/boost/chrono/detail/static_assert.hpp" 1 3 4 ># 35 "/usr/include/boost/chrono/duration.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 34 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/syslimits.h" 1 3 4 > > > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 168 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 3 4 ># 1 "/usr/include/limits.h" 1 3 4 ># 143 "/usr/include/limits.h" 3 4 ># 1 "/usr/include/bits/posix1_lim.h" 1 3 4 ># 160 "/usr/include/bits/posix1_lim.h" 3 4 ># 1 "/usr/include/bits/local_lim.h" 1 3 4 ># 38 "/usr/include/bits/local_lim.h" 3 4 ># 1 "/usr/include/linux/limits.h" 1 3 4 ># 39 "/usr/include/bits/local_lim.h" 2 3 4 ># 161 "/usr/include/bits/posix1_lim.h" 2 3 4 ># 144 "/usr/include/limits.h" 2 3 4 > > > ># 1 "/usr/include/bits/posix2_lim.h" 1 3 4 ># 148 "/usr/include/limits.h" 2 3 4 > > > ># 1 "/usr/include/bits/xopen_lim.h" 1 3 4 ># 33 "/usr/include/bits/xopen_lim.h" 3 4 ># 1 "/usr/include/bits/stdio_lim.h" 1 3 4 ># 34 "/usr/include/bits/xopen_lim.h" 2 3 4 ># 152 "/usr/include/limits.h" 2 3 4 ># 169 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 2 3 4 ># 8 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/syslimits.h" 2 3 4 ># 35 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 2 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 37 "/usr/include/boost/chrono/duration.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/ratio/ratio.hpp" 1 3 4 ># 35 "/usr/include/boost/ratio/ratio.hpp" 3 4 ># 1 "/usr/include/boost/ratio/config.hpp" 1 3 4 ># 13 "/usr/include/boost/ratio/config.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 14 "/usr/include/boost/ratio/config.hpp" 2 3 4 ># 36 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 ># 1 "/usr/include/boost/ratio/detail/mpl/abs.hpp" 1 3 4 ># 32 "/usr/include/boost/ratio/detail/mpl/abs.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct abs_impl; > >template< typename T > struct abs_tag >{ > typedef typename T::tag type; >}; > >template< > typename N = na > > >struct abs > : abs_impl< > typename abs_tag<N>::type > >::template apply<N>::type >{ > >}; > >template<> struct abs< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : abs< T1 > { }; }; template< typename Tag > struct lambda< abs< na > , Tag , int_<-1> > { typedef false_ is_le; typedef abs< na > result_; typedef abs< na > type; }; namespace aux { template< typename T1 > struct template_arity< abs< T1 > > : int_<1> { }; template<> struct template_arity< abs< na > > : int_<-1> { }; } > >template< > typename T > , T n1 > > >struct abs_c > : abs<integral_c<T,n1> > >{ >}; ># 73 "/usr/include/boost/ratio/detail/mpl/abs.hpp" 3 4 >template<> >struct abs_impl<integral_c_tag> >{ > > > > > template< typename N > struct apply > : integral_c< typename N::value_type, ((N::value < 0) ? (-N::value) : N::value ) > > > { > }; >}; > >}} ># 37 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 ># 1 "/usr/include/boost/ratio/detail/mpl/sign.hpp" 1 3 4 ># 32 "/usr/include/boost/ratio/detail/mpl/sign.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct sign_impl; > >template< typename T > struct sign_tag >{ > typedef typename T::tag type; >}; > >template< > typename N = na > > >struct sign > : sign_impl< > typename sign_tag<N>::type > >::template apply<N>::type >{ > >}; > >template<> struct sign< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : sign< T1 > { }; }; template< typename Tag > struct lambda< sign< na > , Tag , int_<-1> > { typedef false_ is_le; typedef sign< na > result_; typedef sign< na > type; }; namespace aux { template< typename T1 > struct template_arity< sign< T1 > > : int_<1> { }; template<> struct template_arity< sign< na > > : int_<-1> { }; } > >template< > typename T > , T n1 > > >struct sign_c > : sign<integral_c<T,n1> > >{ >}; ># 73 "/usr/include/boost/ratio/detail/mpl/sign.hpp" 3 4 >template<> >struct sign_impl<integral_c_tag> >{ > > > > > template< typename N > struct apply > : integral_c< typename N::value_type, (N::value == 0 ? 0 : (N::value < 0 ? -1 : 1)) > > > { > }; >}; > >}} ># 38 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 ># 1 "/usr/include/boost/ratio/detail/mpl/gcd.hpp" 1 3 4 ># 17 "/usr/include/boost/ratio/detail/mpl/gcd.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/largest_int.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/largest_int.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >template< typename T > struct integral_rank; > >template<> struct integral_rank<bool> : int_<1> {}; >template<> struct integral_rank<signed char> : int_<2> {}; >template<> struct integral_rank<char> : int_<3> {}; >template<> struct integral_rank<unsigned char> : int_<4> {}; > >template<> struct integral_rank<wchar_t> : int_<5> {}; > >template<> struct integral_rank<short> : int_<6> {}; >template<> struct integral_rank<unsigned short> : int_<7> {}; >template<> struct integral_rank<int> : int_<8> {}; >template<> struct integral_rank<unsigned int> : int_<9> {}; >template<> struct integral_rank<long> : int_<10> {}; >template<> struct integral_rank<unsigned long> : int_<11> {}; > > >template<> struct integral_rank<long_long_type> : int_<12> {}; >template<> struct integral_rank<ulong_long_type>: int_<13> {}; > > >template< typename T1, typename T2 > struct largest_int > > : if_c< > ( integral_rank<T1>::value >= integral_rank<T2>::value ) > , T1 > , T2 > > >{ > > > > > > >}; > >}}} ># 18 "/usr/include/boost/ratio/detail/mpl/gcd.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/mpl/aux_/config/dependent_nttp.hpp" 1 3 4 ># 24 "/usr/include/boost/ratio/detail/mpl/gcd.hpp" 2 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 25 "/usr/include/boost/ratio/detail/mpl/gcd.hpp" 2 3 4 ># 36 "/usr/include/boost/ratio/detail/mpl/gcd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag1, typename Tag2 > struct gcd_impl; > >template< typename T > struct gcd_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > > >struct gcd > : gcd_impl< > typename gcd_tag<N1>::type > , typename gcd_tag<N2>::type > >::template apply<N1, N2>::type >{ > >}; > >template<> struct gcd< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : gcd< T1 , T2 > { }; }; template< typename Tag > struct lambda< gcd< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef gcd< na , na > result_; typedef gcd< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< gcd< T1 , T2 > > : int_<2> { }; template<> struct template_arity< gcd< na , na > > : int_<-1> { }; } > >template< > typename T > , T n1 > , T n2 > > >struct gcd_c > : gcd<integral_c<T,n1>,integral_c<T,n2> > >{ >}; > >namespace aux { > > > > > > > template< typename T1, boost::intmax_t n1, bool n1_is_0 > , typename T2, boost::intmax_t n2, bool n2_is_0 > > struct gcd_aux > : gcd_aux<T2, n2, n2==0, T1, (n1 % n2), (n1 % n2)==0> > {}; > > template <typename T1, boost::intmax_t n1, typename T2, boost::intmax_t n2> > struct gcd_aux<T1, n1, false, T2, n2, true> : integral_c<T1, n1> > {}; > > template <typename T1, boost::intmax_t n1, typename T2, boost::intmax_t n2, bool C> > struct gcd_aux<T1, n1, true, T2, n2, C> : integral_c<T2, n2> > {}; ># 110 "/usr/include/boost/ratio/detail/mpl/gcd.hpp" 3 4 >} > >template<> >struct gcd_impl<integral_c_tag, integral_c_tag> >{ > template< typename N1, typename N2 > struct apply > : abs<aux::gcd_aux< typename N1::value_type, N1::value, N1::value==0, > typename N2::value_type, N2::value, N2::value==0 > > > { > }; >}; > >}} ># 39 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 ># 1 "/usr/include/boost/ratio/detail/mpl/lcm.hpp" 1 3 4 ># 24 "/usr/include/boost/ratio/detail/mpl/lcm.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 25 "/usr/include/boost/ratio/detail/mpl/lcm.hpp" 2 3 4 ># 36 "/usr/include/boost/ratio/detail/mpl/lcm.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag1, typename Tag2 > struct lcm_impl; > >template< typename T > struct lcm_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > > >struct lcm > : lcm_impl< > typename lcm_tag<N1>::type > , typename lcm_tag<N2>::type > >::template apply<N1, N2>::type >{ > >}; > >template<> struct lcm< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : lcm< T1 , T2 > { }; }; template< typename Tag > struct lambda< lcm< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef lcm< na , na > result_; typedef lcm< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< lcm< T1 , T2 > > : int_<2> { }; template<> struct template_arity< lcm< na , na > > : int_<-1> { }; } > >template< > typename T > , T n1 > , T n2 > > >struct lcm_c > : lcm<integral_c<T,n1>,integral_c<T,n2> > >{ >}; > > >namespace aux { > > > > > template< typename T1, boost::intmax_t n1, bool n1_is_0 > , typename T2, boost::intmax_t n2, bool n2_is_0 > > struct lcm_aux > : abs<integral_c< typename aux::largest_int<T1, T2>::type, > ( n1 / gcd<integral_c<T1,n1>, integral_c<T2,n2> >::value * n2 ) > > > > {}; > > template <typename T1, boost::intmax_t n1, typename T2, boost::intmax_t n2> > struct lcm_aux<T1, n1, false, T2, n2, true> : integral_c<T2, 0> > {}; > > template <typename T1, boost::intmax_t n1, typename T2, boost::intmax_t n2, bool C> > struct lcm_aux<T1, n1, true, T2, n2, C> : integral_c<T1, 0> > {}; ># 112 "/usr/include/boost/ratio/detail/mpl/lcm.hpp" 3 4 >} > >template<> >struct lcm_impl<integral_c_tag, integral_c_tag> >{ > template< typename N1, typename N2 > struct apply > : abs<aux::lcm_aux< typename N1::value_type, N1::value, N1::value==0, > typename N2::value_type, N2::value, N2::value==0 > > > { > }; >}; > >}} ># 40 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 41 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 42 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 > ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 44 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 > > ># 1 "/usr/include/boost/integer_traits.hpp" 1 3 4 ># 23 "/usr/include/boost/integer_traits.hpp" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 24 "/usr/include/boost/integer_traits.hpp" 2 3 4 > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 28 "/usr/include/boost/integer_traits.hpp" 2 3 4 ># 39 "/usr/include/boost/integer_traits.hpp" 3 4 ># 40 "/usr/include/boost/integer_traits.hpp" 3 > > >namespace boost { >template<class T> >class integer_traits : public std::numeric_limits<T> >{ >public: > static const bool is_integral = false; >}; > >namespace detail { >template<class T, T min_val, T max_val> >class integer_traits_base >{ >public: > static const bool is_integral = true; > static const T const_min = min_val; > static const T const_max = max_val; >}; > > > >template<class T, T min_val, T max_val> >const bool integer_traits_base<T, min_val, max_val>::is_integral; > >template<class T, T min_val, T max_val> >const T integer_traits_base<T, min_val, max_val>::const_min; > >template<class T, T min_val, T max_val> >const T integer_traits_base<T, min_val, max_val>::const_max; > > >} > >template<> >class integer_traits<bool> > : public std::numeric_limits<bool>, > public detail::integer_traits_base<bool, false, true> >{ }; > >template<> >class integer_traits<char> > : public std::numeric_limits<char>, > public detail::integer_traits_base<char, (-127 - 1), 127> >{ }; > >template<> >class integer_traits<signed char> > : public std::numeric_limits<signed char>, > public detail::integer_traits_base<signed char, (-127 - 1), 127> >{ }; > >template<> >class integer_traits<unsigned char> > : public std::numeric_limits<unsigned char>, > public detail::integer_traits_base<unsigned char, 0, (127 * 2 + 1)> >{ }; > > >template<> >class integer_traits<wchar_t> > : public std::numeric_limits<wchar_t>, > > > > public detail::integer_traits_base<wchar_t, (-2147483647 - 1), 2147483647> ># 130 "/usr/include/boost/integer_traits.hpp" 3 >{ }; > > >template<> >class integer_traits<short> > : public std::numeric_limits<short>, > public detail::integer_traits_base<short, (-32767 - 1), 32767> >{ }; > >template<> >class integer_traits<unsigned short> > : public std::numeric_limits<unsigned short>, > public detail::integer_traits_base<unsigned short, 0, (32767 * 2 + 1)> >{ }; > >template<> >class integer_traits<int> > : public std::numeric_limits<int>, > public detail::integer_traits_base<int, (-2147483647 - 1), 2147483647> >{ }; > >template<> >class integer_traits<unsigned int> > : public std::numeric_limits<unsigned int>, > public detail::integer_traits_base<unsigned int, 0, (2147483647 * 2U + 1U)> >{ }; > >template<> >class integer_traits<long> > : public std::numeric_limits<long>, > public detail::integer_traits_base<long, (-9223372036854775807L - 1L), 9223372036854775807L> >{ }; > >template<> >class integer_traits<unsigned long> > : public std::numeric_limits<unsigned long>, > public detail::integer_traits_base<unsigned long, 0, (9223372036854775807L * 2UL + 1UL)> >{ }; > > > > >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, (-9223372036854775807LL -1), 9223372036854775807LL> >{ }; > >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, (9223372036854775807LL * 2ULL + 1)> >{ }; ># 256 "/usr/include/boost/integer_traits.hpp" 3 >} ># 47 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 ># 1 "/usr/include/boost/ratio/ratio_fwd.hpp" 1 3 4 ># 37 "/usr/include/boost/ratio/ratio_fwd.hpp" 3 4 >namespace boost >{ ># 47 "/usr/include/boost/ratio/ratio_fwd.hpp" 3 4 >template <boost::intmax_t N, boost::intmax_t D = 1> class ratio; > > >template <class R1, class R2> struct ratio_add; >template <class R1, class R2> struct ratio_subtract; >template <class R1, class R2> struct ratio_multiply; >template <class R1, class R2> struct ratio_divide; > > >template <class R1, class R2> struct ratio_equal; >template <class R1, class R2> struct ratio_not_equal; >template <class R1, class R2> struct ratio_less; >template <class R1, class R2> struct ratio_less_equal; >template <class R1, class R2> struct ratio_greater; >template <class R1, class R2> struct ratio_greater_equal; > > >typedef ratio<1L, 1000000000000000000L> atto; >typedef ratio<1L, 1000000000000000L> femto; >typedef ratio<1L, 1000000000000L> pico; >typedef ratio<1L, 1000000000L> nano; >typedef ratio<1L, 1000000L> micro; >typedef ratio<1L, 1000L> milli; >typedef ratio<1L, 100L> centi; >typedef ratio<1L, 10L> deci; >typedef ratio< 10L, 1L> deca; >typedef ratio< 100L, 1L> hecto; >typedef ratio< 1000L, 1L> kilo; >typedef ratio< 1000000L, 1L> mega; >typedef ratio< 1000000000L, 1L> giga; >typedef ratio< 1000000000000L, 1L> tera; >typedef ratio< 1000000000000000L, 1L> peta; >typedef ratio<1000000000000000000L, 1L> exa; > >} ># 48 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 ># 1 "/usr/include/boost/ratio/detail/overflow_helpers.hpp" 1 3 4 ># 38 "/usr/include/boost/ratio/detail/overflow_helpers.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 39 "/usr/include/boost/ratio/detail/overflow_helpers.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 40 "/usr/include/boost/ratio/detail/overflow_helpers.hpp" 2 3 4 > ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 42 "/usr/include/boost/ratio/detail/overflow_helpers.hpp" 2 3 4 ># 55 "/usr/include/boost/ratio/detail/overflow_helpers.hpp" 3 4 ># 56 "/usr/include/boost/ratio/detail/overflow_helpers.hpp" 3 > > >namespace boost >{ > > > > > >namespace ratio_detail >{ > > template <boost::intmax_t X, boost::intmax_t Y, boost::intmax_t = mpl::sign_c<boost::intmax_t, Y>::value> > class br_add; > > template <boost::intmax_t X, boost::intmax_t Y> > class br_add<X, Y, 1> > { > static const boost::intmax_t min = boost::integer_traits<boost::intmax_t>::const_min; > static const boost::intmax_t max = boost::integer_traits<boost::intmax_t>::const_max; > > static_assert(X <= max - Y,"overflow in ratio add"); > public: > static const boost::intmax_t value = X + Y; > }; > > template <boost::intmax_t X, boost::intmax_t Y> > class br_add<X, Y, 0> > { > public: > static const boost::intmax_t value = X; > }; > > template <boost::intmax_t X, boost::intmax_t Y> > class br_add<X, Y, -1> > { > static const boost::intmax_t min = boost::integer_traits<boost::intmax_t>::const_min; > static const boost::intmax_t max = boost::integer_traits<boost::intmax_t>::const_max; > > static_assert(min - Y <= X,"overflow in ratio add"); > public: > static const boost::intmax_t value = X + Y; > }; > > template <boost::intmax_t X, boost::intmax_t Y, boost::intmax_t = mpl::sign_c<boost::intmax_t, Y>::value> > class br_sub; > > template <boost::intmax_t X, boost::intmax_t Y> > class br_sub<X, Y, 1> > { > static const boost::intmax_t min = boost::integer_traits<boost::intmax_t>::const_min; > static const boost::intmax_t max = boost::integer_traits<boost::intmax_t>::const_max; > > static_assert(min + Y <= X,"overflow in ratio sub"); > public: > static const boost::intmax_t value = X - Y; > }; > > template <boost::intmax_t X, boost::intmax_t Y> > class br_sub<X, Y, 0> > { > public: > static const boost::intmax_t value = X; > }; > > template <boost::intmax_t X, boost::intmax_t Y> > class br_sub<X, Y, -1> > { > static const boost::intmax_t min = boost::integer_traits<boost::intmax_t>::const_min; > static const boost::intmax_t max = boost::integer_traits<boost::intmax_t>::const_max; > > static_assert(X <= max + Y,"overflow in ratio sub"); > public: > static const boost::intmax_t value = X - Y; > }; > > template <boost::intmax_t X, boost::intmax_t Y> > class br_mul > { > static const boost::intmax_t nan = > boost::intmax_t(1UL << (sizeof(boost::intmax_t) * 8 - 1)); > static const boost::intmax_t min = boost::integer_traits<boost::intmax_t>::const_min; > static const boost::intmax_t max = boost::integer_traits<boost::intmax_t>::const_max; > > static const boost::intmax_t a_x = mpl::abs_c<boost::intmax_t, X>::value; > static const boost::intmax_t a_y = mpl::abs_c<boost::intmax_t, Y>::value; > > static_assert(X != nan,"overflow in ratio mul"); > static_assert(Y != nan,"overflow in ratio mul"); > static_assert(a_x <= max / a_y,"overflow in ratio mul"); > public: > static const boost::intmax_t value = X * Y; > }; > > template <boost::intmax_t Y> > class br_mul<0, Y> > { > public: > static const boost::intmax_t value = 0; > }; > > template <boost::intmax_t X> > class br_mul<X, 0> > { > public: > static const boost::intmax_t value = 0; > }; > > template <> > class br_mul<0, 0> > { > public: > static const boost::intmax_t value = 0; > }; > > > template <boost::intmax_t X, boost::intmax_t Y> > class br_div > { > static const boost::intmax_t nan = boost::intmax_t(1UL << (sizeof(boost::intmax_t) * 8 - 1)); > static const boost::intmax_t min = boost::integer_traits<boost::intmax_t>::const_min; > static const boost::intmax_t max = boost::integer_traits<boost::intmax_t>::const_max; > > static_assert(X != nan,"overflow in ratio div"); > static_assert(Y != nan,"overflow in ratio div"); > static_assert(Y != 0,"ratio divide by 0"); > public: > static const boost::intmax_t value = X / Y; > }; > > > template <class R1, class R2> struct ratio_add; > template <class R1, class R2> struct ratio_subtract; > template <class R1, class R2> struct ratio_multiply; > template <class R1, class R2> struct ratio_divide; > > template <class R1, class R2> > struct ratio_add > { > > > > private: > static const boost::intmax_t gcd_n1_n2 = mpl::gcd_c<boost::intmax_t, R1::num, R2::num>::value; > static const boost::intmax_t gcd_d1_d2 = mpl::gcd_c<boost::intmax_t, R1::den, R2::den>::value; > public: > > typedef typename ratio_multiply > < > ratio<gcd_n1_n2, R1::den / gcd_d1_d2>, > ratio > < > boost::ratio_detail::br_add > < > boost::ratio_detail::br_mul<R1::num / gcd_n1_n2, R2::den / gcd_d1_d2>::value, > boost::ratio_detail::br_mul<R2::num / gcd_n1_n2, R1::den / gcd_d1_d2>::value > >::value, > R2::den > > > >::type type; > }; > template <class R, boost::intmax_t D> > struct ratio_add<R, ratio<0,D> > > { > typedef R type; > }; > > template <class R1, class R2> > struct ratio_subtract > { > > > > private: > static const boost::intmax_t gcd_n1_n2 = mpl::gcd_c<boost::intmax_t, R1::num, R2::num>::value; > static const boost::intmax_t gcd_d1_d2 = mpl::gcd_c<boost::intmax_t, R1::den, R2::den>::value; > public: > > typedef typename ratio_multiply > < > ratio<gcd_n1_n2, R1::den / gcd_d1_d2>, > ratio > < > boost::ratio_detail::br_sub > < > boost::ratio_detail::br_mul<R1::num / gcd_n1_n2, R2::den / gcd_d1_d2>::value, > boost::ratio_detail::br_mul<R2::num / gcd_n1_n2, R1::den / gcd_d1_d2>::value > >::value, > R2::den > > > >::type type; > }; > > template <class R, boost::intmax_t D> > struct ratio_subtract<R, ratio<0,D> > > { > typedef R type; > }; > > template <class R1, class R2> > struct ratio_multiply > { > > > private: > static const boost::intmax_t gcd_n1_d2 = mpl::gcd_c<boost::intmax_t, R1::num, R2::den>::value; > static const boost::intmax_t gcd_d1_n2 = mpl::gcd_c<boost::intmax_t, R1::den, R2::num>::value; > public: > typedef typename ratio > < > boost::ratio_detail::br_mul<R1::num / gcd_n1_d2, R2::num / gcd_d1_n2>::value, > boost::ratio_detail::br_mul<R2::den / gcd_n1_d2, R1::den / gcd_d1_n2>::value > >::type type; > }; > > template <class R1, class R2> > struct ratio_divide > { > > > private: > static const boost::intmax_t gcd_n1_n2 = mpl::gcd_c<boost::intmax_t, R1::num, R2::num>::value; > static const boost::intmax_t gcd_d1_d2 = mpl::gcd_c<boost::intmax_t, R1::den, R2::den>::value; > public: > typedef typename ratio > < > boost::ratio_detail::br_mul<R1::num / gcd_n1_n2, R2::den / gcd_d1_d2>::value, > boost::ratio_detail::br_mul<R2::num / gcd_n1_n2, R1::den / gcd_d1_d2>::value > >::type type; > }; > template <class R1, class R2> > struct is_evenly_divisible_by > { > private: > static const boost::intmax_t gcd_n1_n2 = mpl::gcd_c<boost::intmax_t, R1::num, R2::num>::value; > static const boost::intmax_t gcd_d1_d2 = mpl::gcd_c<boost::intmax_t, R1::den, R2::den>::value; > public: > typedef integral_constant<bool, > ((R2::num / gcd_n1_n2 ==1) && (R1::den / gcd_d1_d2)==1) > > type; > }; > > template <class T> > struct is_ratio : public boost::false_type > {}; > template <boost::intmax_t N, boost::intmax_t D> > struct is_ratio<ratio<N, D> > : public boost::true_type > {}; > > template <class R1, class R2, > boost::intmax_t Q1 = R1::num / R1::den, boost::intmax_t M1 = R1::num % R1::den, > boost::intmax_t Q2 = R2::num / R2::den, boost::intmax_t M2 = R2::num % R2::den> > struct ratio_less1 > { > static const bool value = Q1 < Q2; > }; > > template <class R1, class R2, boost::intmax_t Q> > struct ratio_less1<R1, R2, Q, 0, Q, 0> > { > static const bool value = false; > }; > > template <class R1, class R2, boost::intmax_t Q, boost::intmax_t M2> > struct ratio_less1<R1, R2, Q, 0, Q, M2> > { > static const bool value = true; > }; > > template <class R1, class R2, boost::intmax_t Q, boost::intmax_t M1> > struct ratio_less1<R1, R2, Q, M1, Q, 0> > { > static const bool value = false; > }; > > template <class R1, class R2, boost::intmax_t Q, boost::intmax_t M1, boost::intmax_t M2> > struct ratio_less1<R1, R2, Q, M1, Q, M2> > { > static const bool value = ratio_less1<ratio<R2::den, M2>, ratio<R1::den, M1> > >::value; > }; > > template < > class R1, > class R2, > boost::intmax_t S1 = mpl::sign_c<boost::intmax_t, R1::num>::value, > boost::intmax_t S2 = mpl::sign_c<boost::intmax_t, R2::num>::value >> > struct ratio_less > { > static const bool value = S1 < S2; > }; > > template <class R1, class R2> > struct ratio_less<R1, R2, 1LL, 1LL> > { > static const bool value = ratio_less1<R1, R2>::value; > }; > > template <class R1, class R2> > struct ratio_less<R1, R2, -1LL, -1LL> > { > static const bool value = ratio_less1<ratio<-R2::num, R2::den>, > ratio<-R1::num, R1::den> >::value; > }; > > >} > >} ># 49 "/usr/include/boost/ratio/ratio.hpp" 2 3 4 ># 63 "/usr/include/boost/ratio/ratio.hpp" 3 4 ># 64 "/usr/include/boost/ratio/ratio.hpp" 3 > > >namespace boost >{ ># 76 "/usr/include/boost/ratio/ratio.hpp" 3 >template <boost::intmax_t N, boost::intmax_t D> >class ratio >{ > static const boost::intmax_t ABS_N = mpl::abs_c<boost::intmax_t, N>::value; > static const boost::intmax_t ABS_D = mpl::abs_c<boost::intmax_t, D>::value; > static_assert(ABS_N >= 0,"ratio numerator is out of range"); > static_assert(ABS_D > 0,"ratio denominator is out of range"); > static_assert(D != 0,"ratio divide by 0"); > static const boost::intmax_t SIGN_N = mpl::sign_c<boost::intmax_t,N>::value > * mpl::sign_c<boost::intmax_t,D>::value; > static const boost::intmax_t GCD = mpl::gcd_c<boost::intmax_t, ABS_N, ABS_D>::value; >public: > static constexpr boost::intmax_t num = SIGN_N * ABS_N / GCD; > static constexpr boost::intmax_t den = ABS_D / GCD; ># 119 "/usr/include/boost/ratio/ratio.hpp" 3 > typedef ratio<num, den> type; >}; ># 135 "/usr/include/boost/ratio/ratio.hpp" 3 >template <class R1, class R2> >struct ratio_add >: boost::ratio_detail::ratio_add<R1, R2>::type >{ >}; > >template <class R1, class R2> >struct ratio_subtract >: boost::ratio_detail::ratio_subtract<R1, R2>::type >{ >}; > >template <class R1, class R2> >struct ratio_multiply >: boost::ratio_detail::ratio_multiply<R1, R2>::type >{ >}; > >template <class R1, class R2> >struct ratio_divide >: boost::ratio_detail::ratio_divide<R1, R2>::type >{ >}; ># 167 "/usr/include/boost/ratio/ratio.hpp" 3 >template <class R1, class R2> >struct ratio_equal > : public boost::integral_constant<bool, > (R1::num == R2::num && R1::den == R2::den)> >{}; > >template <class R1, class R2> >struct ratio_not_equal > : public boost::integral_constant<bool, !ratio_equal<R1, R2>::value> >{}; > > > >template <class R1, class R2> >struct ratio_less > : boost::integral_constant<bool, boost::ratio_detail::ratio_less<R1, R2>::value> >{}; > >template <class R1, class R2> >struct ratio_less_equal > : boost::integral_constant<bool, !ratio_less<R2, R1>::value> >{}; > >template <class R1, class R2> >struct ratio_greater > : boost::integral_constant<bool, ratio_less<R2, R1>::value> >{}; > >template <class R1, class R2> >struct ratio_greater_equal > : boost::integral_constant<bool, !ratio_less<R1, R2>::value> >{}; > >template <class R1, class R2> >struct ratio_gcd : > ratio<mpl::gcd_c<boost::intmax_t, R1::num, R2::num>::value, > mpl::lcm_c<boost::intmax_t, R1::den, R2::den>::value>::type >{ >}; ># 230 "/usr/include/boost/ratio/ratio.hpp" 3 >} ># 42 "/usr/include/boost/chrono/duration.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/common_type.hpp" 1 3 4 ># 65 "/usr/include/boost/type_traits/common_type.hpp" 3 4 >namespace boost { > > > > template<typename... T> > struct common_type; ># 82 "/usr/include/boost/type_traits/common_type.hpp" 3 4 > template<typename T> > > struct common_type<T> > > > > > { > static_assert(sizeof(T) > 0,"must be complete type"); > public: > typedef T type; > }; > > >namespace type_traits_detail { > > template <class T, class U> > struct common_type_2 > { > private: > static_assert(sizeof(T) > 0,"must be complete type"); > static_assert(sizeof(U) > 0,"must be complete type"); > static bool declval_bool(); > static typename add_rvalue_reference<T>::type declval_T(); > static typename add_rvalue_reference<U>::type declval_U(); > static typename add_rvalue_reference<bool>::type declval_b(); > > > public: > typedef decltype(declval<bool>() ? declval<T>() : declval<U>()) type; ># 127 "/usr/include/boost/type_traits/common_type.hpp" 3 4 > }; > > template <class T> > struct common_type_2<T, T> > { > typedef T type; > }; > } > > > template <class T, class U> > struct common_type<T, U> > > > > > : public type_traits_detail::common_type_2<T,U> > { }; > > > > > template<typename T, typename U, typename... V> > struct common_type<T, U, V...> { > public: > typedef typename common_type<typename common_type<T, U>::type, V...>::type type; > }; > >} ># 43 "/usr/include/boost/chrono/duration.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/is_floating_point.hpp" 1 3 4 ># 13 "/usr/include/boost/type_traits/is_floating_point.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 14 "/usr/include/boost/type_traits/is_floating_point.hpp" 2 3 4 > >namespace boost { > > >template< typename T > struct is_floating_point : public ::boost::integral_constant<bool,false> { public: }; >template<> struct is_floating_point< float > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_floating_point< float const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_floating_point< float volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_floating_point< float const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_floating_point< double > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_floating_point< double const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_floating_point< double volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_floating_point< double const volatile > : public ::boost::integral_constant<bool,true> { public: }; >template<> struct is_floating_point< long double > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_floating_point< long double const > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_floating_point< long double volatile > : public ::boost::integral_constant<bool,true> { public: }; template<> struct is_floating_point< long double const volatile > : public ::boost::integral_constant<bool,true> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 26 "/usr/include/boost/type_traits/is_floating_point.hpp" 2 3 4 ># 46 "/usr/include/boost/chrono/duration.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_unsigned.hpp" 1 3 4 ># 19 "/usr/include/boost/type_traits/is_unsigned.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 20 "/usr/include/boost/type_traits/is_unsigned.hpp" 2 3 4 > >namespace boost { > > > >namespace detail{ > > > >template <class T> >struct is_unsigned_values >{ > > > > > > typedef typename remove_cv<T>::type no_cv_t; > static const no_cv_t minus_one = (static_cast<no_cv_t>(-1)); > static const no_cv_t zero = (static_cast<no_cv_t>(0)); >}; > >template <class T> >struct is_ununsigned_helper >{ > static const bool value = (::boost::detail::is_unsigned_values<T>::minus_one > ::boost::detail::is_unsigned_values<T>::zero); >}; > >template <bool integral_type> >struct is_ununsigned_select_helper >{ > template <class T> > struct rebind > { > typedef is_ununsigned_helper<T> type; > }; >}; > >template <> >struct is_ununsigned_select_helper<false> >{ > template <class T> > struct rebind > { > typedef false_type type; > }; >}; > >template <class T> >struct is_unsigned_imp >{ > typedef is_ununsigned_select_helper< > ::boost::type_traits::ice_or< > ::boost::is_integral<T>::value, > ::boost::is_enum<T>::value>::value > > selector; > typedef typename selector::template rebind<T> binder; > typedef typename binder::type type; > static const bool value = type::value; >}; ># 121 "/usr/include/boost/type_traits/is_unsigned.hpp" 3 4 >} > > > > > > >template< typename T > struct is_unsigned : public ::boost::integral_constant<bool,::boost::detail::is_unsigned_imp<T>::value> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 134 "/usr/include/boost/type_traits/is_unsigned.hpp" 2 3 4 ># 47 "/usr/include/boost/chrono/duration.hpp" 2 3 4 ># 1 "/usr/include/boost/chrono/detail/is_evenly_divisible_by.hpp" 1 3 4 ># 16 "/usr/include/boost/chrono/detail/is_evenly_divisible_by.hpp" 3 4 >namespace boost { >namespace chrono { >namespace chrono_detail { > > > > > template <class R1, class R2> > struct is_evenly_divisible_by : public boost::ratio_detail::is_evenly_divisible_by<R1, R2> > {}; > >} >} >} ># 48 "/usr/include/boost/chrono/duration.hpp" 2 3 4 > ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 50 "/usr/include/boost/chrono/duration.hpp" 2 3 4 ># 63 "/usr/include/boost/chrono/duration.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 64 "/usr/include/boost/chrono/duration.hpp" 2 3 4 ># 73 "/usr/include/boost/chrono/duration.hpp" 3 4 >namespace boost { >namespace chrono { > > template <class Rep, class Period = ratio<1> > > class duration; > > namespace detail > { > template <class T> > struct is_duration > : boost::false_type {}; > > template <class Rep, class Period> > struct is_duration<duration<Rep, Period> > > : boost::true_type {}; > > template <class Duration, class Rep, bool = is_duration<Rep>::value> > struct duration_divide_result > { > }; > > template <class Duration, class Rep2, > bool = ( > ((boost::is_convertible<typename Duration::rep, > typename common_type<typename Duration::rep, Rep2>::type>::value)) > && ((boost::is_convertible<Rep2, > typename common_type<typename Duration::rep, Rep2>::type>::value)) > ) > > > struct duration_divide_imp > { > }; > > template <class Rep1, class Period, class Rep2> > struct duration_divide_imp<duration<Rep1, Period>, Rep2, true> > { > typedef duration<typename common_type<Rep1, Rep2>::type, Period> type; > }; > > template <class Rep1, class Period, class Rep2> > struct duration_divide_result<duration<Rep1, Period>, Rep2, false> > : duration_divide_imp<duration<Rep1, Period>, Rep2> > { > }; > > > template <class Rep, class Duration, bool = is_duration<Rep>::value> > struct duration_divide_result2 > { > }; > > template <class Rep, class Duration, > bool = ( > ((boost::is_convertible<typename Duration::rep, > typename common_type<typename Duration::rep, Rep>::type>::value)) > && ((boost::is_convertible<Rep, > typename common_type<typename Duration::rep, Rep>::type>::value)) > ) > > > struct duration_divide_imp2 > { > }; > > template <class Rep1, class Rep2, class Period > > struct duration_divide_imp2<Rep1, duration<Rep2, Period>, true> > { > > typedef double type; > }; > > template <class Rep1, class Rep2, class Period > > struct duration_divide_result2<Rep1, duration<Rep2, Period>, false> > : duration_divide_imp2<Rep1, duration<Rep2, Period> > > { > }; > > > template <class Duration, class Rep, bool = is_duration<Rep>::value> > struct duration_modulo_result > { > }; > > template <class Duration, class Rep2, > bool = ( > > > > boost::is_convertible<Rep2, > typename common_type<typename Duration::rep, Rep2>::type>::value > ) > > > struct duration_modulo_imp > { > }; > > template <class Rep1, class Period, class Rep2> > struct duration_modulo_imp<duration<Rep1, Period>, Rep2, true> > { > typedef duration<typename common_type<Rep1, Rep2>::type, Period> type; > }; > > template <class Rep1, class Period, class Rep2> > struct duration_modulo_result<duration<Rep1, Period>, Rep2, false> > : duration_modulo_imp<duration<Rep1, Period>, Rep2> > { > }; > >} >} > > > > >template <class Rep1, class Period1, class Rep2, class Period2> >struct common_type<chrono::duration<Rep1, Period1>, > chrono::duration<Rep2, Period2> >; > > >namespace chrono { > > > template <class Rep> struct treat_as_floating_point; > template <class Rep> struct duration_values; > > > typedef duration<boost::int_least64_t, nano> nanoseconds; > typedef duration<boost::int_least64_t, micro> microseconds; > typedef duration<boost::int_least64_t, milli> milliseconds; > typedef duration<boost::int_least64_t> seconds; > typedef duration<boost::int_least32_t, ratio< 60> > minutes; > typedef duration<boost::int_least32_t, ratio<3600> > hours; > > > > > >namespace detail >{ ># 223 "/usr/include/boost/chrono/duration.hpp" 3 4 > template <class FromDuration, class ToDuration, > class Period, > bool PeriodNumEq1, > bool PeriodDenEq1> > struct duration_cast_aux; > > > > > > template <class FromDuration, class ToDuration, class Period> > struct duration_cast_aux<FromDuration, ToDuration, Period, true, true> > { > constexpr ToDuration operator()(const FromDuration& fd) const > { > return ToDuration(static_cast<typename ToDuration::rep>(fd.count())); > } > }; > > > > > > > > template <class FromDuration, class ToDuration, class Period> > struct duration_cast_aux<FromDuration, ToDuration, Period, true, false> > { > 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<typename ToDuration::rep>( > static_cast<C>(fd.count()) / static_cast<C>(Period::den))); > } > }; > > > > > > > template <class FromDuration, class ToDuration, class Period> > struct duration_cast_aux<FromDuration, ToDuration, Period, false, true> > { > 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<typename ToDuration::rep>( > static_cast<C>(fd.count()) * static_cast<C>(Period::num))); > } > }; > > > > > > > > template <class FromDuration, class ToDuration, class Period> > struct duration_cast_aux<FromDuration, ToDuration, Period, false, false> > { > 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<typename ToDuration::rep>( > static_cast<C>(fd.count()) * static_cast<C>(Period::num) > / static_cast<C>(Period::den))); > } > }; > > template <class FromDuration, class ToDuration> > struct duration_cast { > typedef typename ratio_divide<typename FromDuration::period, > typename ToDuration::period>::type Period; > typedef duration_cast_aux< > FromDuration, > ToDuration, > Period, > Period::num == 1, > Period::den == 1 > > Aux; > constexpr ToDuration operator()(const FromDuration& fd) const > { > return Aux()(fd); > } > }; > >} ># 333 "/usr/include/boost/chrono/duration.hpp" 3 4 > template <class Rep> > struct treat_as_floating_point : boost::is_floating_point<Rep> {}; > > > > > >namespace detail { > template <class T, bool = is_arithmetic<T>::value> > struct chrono_numeric_limits { > static constexpr T lowest() noexcept {return (std::numeric_limits<T>::min) ();} > }; > > template <class T> > struct chrono_numeric_limits<T,true> { > static constexpr T lowest() noexcept {return (std::numeric_limits<T>::min) ();} > }; > > template <> > struct chrono_numeric_limits<float,true> { > static constexpr float lowest() noexcept > { > return -(std::numeric_limits<float>::max) (); > } > }; > > template <> > struct chrono_numeric_limits<double,true> { > static constexpr double lowest() noexcept > { > return -(std::numeric_limits<double>::max) (); > } > }; > > template <> > struct chrono_numeric_limits<long double,true> { > static constexpr long double lowest() noexcept > { > return -(std::numeric_limits<long double>::max)(); > } > }; > > template <class T> > struct numeric_limits : chrono_numeric_limits<typename remove_cv<T>::type> > {}; > >} >template <class Rep> >struct duration_values >{ > static constexpr Rep zero() {return Rep(0);} > static constexpr Rep max () > { > return (std::numeric_limits<Rep>::max)(); > } > > static constexpr Rep min () > { > return detail::numeric_limits<Rep>::lowest(); > } >}; > >} > > > > > >template <class Rep1, class Period1, class Rep2, class Period2> >struct common_type<chrono::duration<Rep1, Period1>, > chrono::duration<Rep2, Period2> > >{ > typedef chrono::duration<typename common_type<Rep1, Rep2>::type, > typename boost::ratio_gcd<Period1, Period2>::type> type; >}; ># 417 "/usr/include/boost/chrono/duration.hpp" 3 4 >namespace chrono { > > template <class Rep, class Period> > class __attribute__((__visibility__("default"))) duration > { > > static_assert(!boost::chrono::detail::is_duration<Rep>::value,"A duration representation can not be a duration") > ; > static_assert(boost::ratio_detail::is_ratio<typename Period::type>::value,"Second template parameter of duration must be a boost::ratio") > ; > static_assert(Period::num>0,"duration period must be positive") > ; > public: > typedef Rep rep; > typedef Period period; > private: > rep rep_; > public: > > inline __attribute__ ((__always_inline__)) constexpr > duration() : rep_(duration_values<rep>::zero()) { } > template <class Rep2> > __attribute__((__visibility__("default"))) inline __attribute__ ((__always_inline__)) constexpr > explicit duration(const Rep2& r > , typename boost::enable_if < > mpl::and_ < > boost::is_convertible<Rep2, rep>, > mpl::or_ < > treat_as_floating_point<rep>, > mpl::and_ < > mpl::not_ < treat_as_floating_point<rep> >, > mpl::not_ < treat_as_floating_point<Rep2> > > > > > > > > >::type* = 0 > ) : rep_(r) { } > > > duration& operator=(const duration& rhs) > { > if (&rhs != this) rep_= rhs.rep_; > return *this; > } > > > template <class Rep2, class Period2> > inline __attribute__ ((__always_inline__)) constexpr > duration(const duration<Rep2, Period2>& d > , typename boost::enable_if < > mpl::or_ < > treat_as_floating_point<rep>, > mpl::and_ < > chrono_detail::is_evenly_divisible_by<Period2, period>, > mpl::not_ < treat_as_floating_point<Rep2> > > > > > > >::type* = 0 > ) > : rep_(chrono::detail::duration_cast<duration<Rep2, Period2>, duration>()(d).count()) {} > > > > constexpr > rep count() const {return rep_;} > > > > constexpr > duration operator+() const {return duration(rep_);;} > 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; > } > > > static constexpr duration zero() > { > return duration(duration_values<rep>::zero()); > } > static constexpr duration min () > { > return duration((duration_values<rep>::min)()); > } > static constexpr duration max () > { > return duration((duration_values<rep>::max)()); > } > }; > > > > > > > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > typename common_type<duration<Rep1, Period1>, duration<Rep2, Period2> >::type > operator+(const duration<Rep1, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > typedef typename common_type<duration<Rep1, Period1>, > duration<Rep2, Period2> >::type CD; > return CD(CD(lhs).count()+CD(rhs).count()); > } > > > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > typename common_type<duration<Rep1, Period1>, duration<Rep2, Period2> >::type > operator-(const duration<Rep1, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > typedef typename common_type<duration<Rep1, Period1>, > duration<Rep2, Period2> >::type CD; > return CD(CD(lhs).count()-CD(rhs).count()); > } > > > > template <class Rep1, class Period, class Rep2> > inline constexpr > typename boost::enable_if < > mpl::and_ < > boost::is_convertible<Rep1, typename common_type<Rep1, Rep2>::type>, > boost::is_convertible<Rep2, typename common_type<Rep1, Rep2>::type> > >, > duration<typename common_type<Rep1, Rep2>::type, Period> > >::type > operator*(const duration<Rep1, Period>& d, const Rep2& s) > { > typedef typename common_type<Rep1, Rep2>::type CR; > typedef duration<CR, Period> CD; > return CD(CD(d).count()*static_cast<CR>(s)); > } > > template <class Rep1, class Period, class Rep2> > inline constexpr > typename boost::enable_if < > mpl::and_ < > boost::is_convertible<Rep1, typename common_type<Rep1, Rep2>::type>, > boost::is_convertible<Rep2, typename common_type<Rep1, Rep2>::type> > >, > duration<typename common_type<Rep1, Rep2>::type, Period> > >::type > operator*(const Rep1& s, const duration<Rep2, Period>& d) > { > return d * s; > } > > > > template <class Rep1, class Period, class Rep2> > inline constexpr > typename boost::disable_if <boost::chrono::detail::is_duration<Rep2>, > typename boost::chrono::detail::duration_divide_result< > duration<Rep1, Period>, Rep2>::type > >::type > operator/(const duration<Rep1, Period>& d, const Rep2& s) > { > typedef typename common_type<Rep1, Rep2>::type CR; > typedef duration<CR, Period> CD; > > return CD(CD(d).count()/static_cast<CR>(s)); > } > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > typename common_type<Rep1, Rep2>::type > operator/(const duration<Rep1, Period1>& lhs, const duration<Rep2, Period2>& rhs) > { > typedef typename common_type<duration<Rep1, Period1>, > duration<Rep2, Period2> >::type CD; > return CD(lhs).count() / CD(rhs).count(); > } ># 631 "/usr/include/boost/chrono/duration.hpp" 3 4 > template <class Rep1, class Period, class Rep2> > inline constexpr > typename boost::disable_if <boost::chrono::detail::is_duration<Rep2>, > typename boost::chrono::detail::duration_modulo_result< > duration<Rep1, Period>, Rep2>::type > >::type > operator%(const duration<Rep1, Period>& d, const Rep2& s) > { > typedef typename common_type<Rep1, Rep2>::type CR; > typedef duration<CR, Period> CD; > > return CD(CD(d).count()%static_cast<CR>(s)); > } > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > typename common_type<duration<Rep1, Period1>, duration<Rep2, Period2> >::type > operator%(const duration<Rep1, Period1>& lhs, > const duration<Rep2, Period2>& rhs) { > typedef typename common_type<duration<Rep1, Period1>, > duration<Rep2, Period2> >::type CD; > > return CD(CD(lhs).count()%CD(rhs).count()); > } > > > > > > >namespace detail >{ > template <class LhsDuration, class RhsDuration> > struct duration_eq > { > constexpr bool operator()(const LhsDuration& lhs, const RhsDuration& rhs) const > { > typedef typename common_type<LhsDuration, RhsDuration>::type CD; > return CD(lhs).count() == CD(rhs).count(); > } > }; > > template <class LhsDuration> > struct duration_eq<LhsDuration, LhsDuration> > { > constexpr bool operator()(const LhsDuration& lhs, const LhsDuration& rhs) const > { > return lhs.count() == rhs.count(); > } > }; > > template <class LhsDuration, class RhsDuration> > struct duration_lt > { > constexpr bool operator()(const LhsDuration& lhs, const RhsDuration& rhs) const > { > typedef typename common_type<LhsDuration, RhsDuration>::type CD; > return CD(lhs).count() < CD(rhs).count(); > } > }; > > template <class LhsDuration> > struct duration_lt<LhsDuration, LhsDuration> > { > constexpr bool operator()(const LhsDuration& lhs, const LhsDuration& rhs) const > { > return lhs.count() < rhs.count(); > } > }; > >} > > > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator==(const duration<Rep1, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > return boost::chrono::detail::duration_eq< > duration<Rep1, Period1>, duration<Rep2, Period2> >()(lhs, rhs); > } > > > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator!=(const duration<Rep1, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > return !(lhs == rhs); > } > > > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator< (const duration<Rep1, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > return boost::chrono::detail::duration_lt< > duration<Rep1, Period1>, duration<Rep2, Period2> >()(lhs, rhs); > } > > > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator> (const duration<Rep1, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > return rhs < lhs; > } > > > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator<=(const duration<Rep1, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > return !(rhs < lhs); > } > > > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator>=(const duration<Rep1, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > return !(lhs < rhs); > } > > > > > > > template <class ToDuration, class Rep, class Period> > inline constexpr > typename boost::enable_if < > boost::chrono::detail::is_duration<ToDuration>, ToDuration>::type > duration_cast(const duration<Rep, Period>& fd) > { > return boost::chrono::detail::duration_cast< > duration<Rep, Period>, ToDuration>()(fd); > } > >} >} > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 792 "/usr/include/boost/chrono/duration.hpp" 2 3 4 ># 34 "/usr/include/boost/chrono/time_point.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 39 "/usr/include/boost/chrono/time_point.hpp" 2 3 4 ># 48 "/usr/include/boost/chrono/time_point.hpp" 3 4 >namespace boost { >namespace chrono { > > template <class Clock, class Duration = typename Clock::duration> > class time_point; > > >} > > > > >template <class Clock, class Duration1, class Duration2> > struct common_type<chrono::time_point<Clock, Duration1>, > chrono::time_point<Clock, Duration2> >; > > > > > > > >template <class Clock, class Duration1, class Duration2> >struct common_type<chrono::time_point<Clock, Duration1>, > chrono::time_point<Clock, Duration2> > >{ > typedef chrono::time_point<Clock, > typename common_type<Duration1, Duration2>::type> type; >}; > > > >namespace chrono { > > > template <class Clock, class Duration1, class Rep2, class Period2> > inline constexpr > time_point<Clock, > typename common_type<Duration1, duration<Rep2, Period2> >::type> > operator+( > const time_point<Clock, Duration1>& lhs, > const duration<Rep2, Period2>& rhs); > template <class Rep1, class Period1, class Clock, class Duration2> > inline constexpr > time_point<Clock, > typename common_type<duration<Rep1, Period1>, Duration2>::type> > operator+( > const duration<Rep1, Period1>& lhs, > const time_point<Clock, Duration2>& rhs); > template <class Clock, class Duration1, class Rep2, class Period2> > inline constexpr > time_point<Clock, > typename common_type<Duration1, duration<Rep2, Period2> >::type> > operator-( > const time_point<Clock, Duration1>& lhs, > const duration<Rep2, Period2>& rhs); > template <class Clock, class Duration1, class Duration2> > inline constexpr > typename common_type<Duration1, Duration2>::type > operator-( > const time_point<Clock, Duration1>& lhs, > const time_point<Clock, > Duration2>& rhs); > > > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool operator==( > const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs); > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool operator!=( > const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs); > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool operator< ( > const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs); > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool operator<=( > const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs); > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool operator> ( > const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs); > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool operator>=( > const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs); > > > template <class ToDuration, class Clock, class Duration> > inline constexpr > time_point<Clock, ToDuration> time_point_cast(const time_point<Clock, Duration>& t); > > > > > > > > template <class Clock, class Duration> > class time_point > { > static_assert(boost::chrono::detail::is_duration<Duration>::value,"Second template parameter of time_point must be a boost::chrono::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: > inline __attribute__ ((__always_inline__)) constexpr > time_point() : d_(duration::zero()) > {} > inline __attribute__ ((__always_inline__)) constexpr > explicit time_point(const duration& d) > : d_(d) > {} > > > template <class Duration2> > inline __attribute__ ((__always_inline__)) constexpr > time_point(const time_point<clock, Duration2>& t > , typename boost::enable_if > < > boost::is_convertible<Duration2, duration> > >::type* = 0 > ) > : d_(t.time_since_epoch()) > { > } > > > constexpr > duration time_since_epoch() const > { > return d_; > } ># 216 "/usr/include/boost/chrono/time_point.hpp" 3 4 > time_point& operator+=(const duration& d) {d_ += d; return *this;} > time_point& operator-=(const duration& d) {d_ -= d; return *this;} > > > > static constexpr time_point > min () > { > return time_point((duration::min)()); > } > static constexpr time_point > max () > { > return time_point((duration::max)()); > } > }; > > > > > > > > template <class Clock, class Duration1, class Rep2, class Period2> > inline constexpr > time_point<Clock, > typename common_type<Duration1, duration<Rep2, Period2> >::type> > operator+(const time_point<Clock, Duration1>& lhs, > const duration<Rep2, Period2>& rhs) > { > typedef typename common_type<Duration1, duration<Rep2, Period2> >::type CDuration; > typedef time_point< > Clock, > CDuration > > TimeResult; > return TimeResult(lhs.time_since_epoch() + CDuration(rhs)); > } > > > > template <class Rep1, class Period1, class Clock, class Duration2> > inline constexpr > time_point<Clock, > typename common_type<duration<Rep1, Period1>, Duration2>::type> > operator+(const duration<Rep1, Period1>& lhs, > const time_point<Clock, Duration2>& rhs) > { > return rhs + lhs; > } > > > > template <class Clock, class Duration1, class Rep2, class Period2> > inline constexpr > time_point<Clock, > typename common_type<Duration1, duration<Rep2, Period2> >::type> > operator-(const time_point<Clock, Duration1>& lhs, > const duration<Rep2, Period2>& rhs) > { > return lhs + (-rhs); > } > > > > template <class Clock, class Duration1, class Duration2> > inline constexpr > typename common_type<Duration1, Duration2>::type > operator-(const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs) > { > return lhs.time_since_epoch() - rhs.time_since_epoch(); > } > > > > > > > > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool > operator==(const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs) > { > return lhs.time_since_epoch() == rhs.time_since_epoch(); > } > > > > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool > operator!=(const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs) > { > return !(lhs == rhs); > } > > > > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool > operator<(const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs) > { > return lhs.time_since_epoch() < rhs.time_since_epoch(); > } > > > > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool > operator>(const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs) > { > return rhs < lhs; > } > > > > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool > operator<=(const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs) > { > return !(rhs < lhs); > } > > > > template <class Clock, class Duration1, class Duration2> > inline constexpr > bool > operator>=(const time_point<Clock, Duration1>& lhs, > const time_point<Clock, Duration2>& rhs) > { > return !(lhs < rhs); > } > > > > > > template <class ToDuration, class Clock, class Duration> > inline constexpr > time_point<Clock, ToDuration> > time_point_cast(const time_point<Clock, Duration>& t) > { > return time_point<Clock, ToDuration>( > duration_cast<ToDuration>(t.time_since_epoch())); > } > >} >} > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 378 "/usr/include/boost/chrono/time_point.hpp" 2 3 4 ># 23 "/usr/include/boost/thread/lock_types.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 28 "/usr/include/boost/thread/lock_types.hpp" 2 3 4 > >namespace boost >{ > struct xtime; > > template <typename Mutex> > class shared_lock; > > template <typename Mutex> > class upgrade_lock; > > template <typename Mutex> > class unique_lock; > > namespace detail > { > template <typename Mutex> > class try_lock_wrapper; > } ># 98 "/usr/include/boost/thread/lock_types.hpp" 3 4 > template <typename Mutex> > class unique_lock > { > private: > Mutex* m; > bool is_locked; > > private: > explicit unique_lock(upgrade_lock<Mutex>&); > unique_lock& operator=(upgrade_lock<Mutex>& other); > public: > typedef Mutex mutex_type; > unique_lock(unique_lock const&) = delete; unique_lock& operator=(unique_lock const&) = delete; > > > > > > > unique_lock()noexcept : > m(0),is_locked(false) > {} > > explicit unique_lock(Mutex& m_) : > m(&m_), is_locked(false) > { > lock(); > } > unique_lock(Mutex& m_, adopt_lock_t) : > m(&m_), is_locked(true) > { > > > > } > unique_lock(Mutex& m_, defer_lock_t)noexcept: > m(&m_),is_locked(false) > {} > unique_lock(Mutex& m_, try_to_lock_t) : > m(&m_), is_locked(false) > { > try_lock(); > } > > template<typename TimeDuration> > unique_lock(Mutex& m_,TimeDuration const& target_time): > m(&m_),is_locked(false) > { > timed_lock(target_time); > } > unique_lock(Mutex& m_,system_time const& target_time): > m(&m_),is_locked(false) > { > timed_lock(target_time); > } > > > template <class Clock, class Duration> > unique_lock(Mutex& mtx, const chrono::time_point<Clock, Duration>& t) > : m(&mtx), is_locked(mtx.try_lock_until(t)) > { > } > template <class Rep, class Period> > unique_lock(Mutex& mtx, const chrono::duration<Rep, Period>& d) > : m(&mtx), is_locked(mtx.try_lock_for(d)) > { > } > > > unique_lock(unique_lock && other) noexcept: > m(other.m),is_locked(other.is_locked) > { > other.is_locked=false; > other.m=0; > } > > unique_lock( upgrade_lock<Mutex> && other); > > > > unique_lock& operator=( upgrade_lock<Mutex> && other) > { > unique_lock temp(::boost::move(other)); > swap(temp); > return *this; > } > > > > unique_lock& operator=(unique_lock && other) > { > unique_lock temp(::boost::move(other)); > swap(temp); > return *this; > } ># 204 "/usr/include/boost/thread/lock_types.hpp" 3 4 > unique_lock( upgrade_lock<mutex_type> && ul, try_to_lock_t) > : m(0),is_locked(false) > { > if (ul.owns_lock()) > { > if (ul.mutex()->try_unlock_upgrade_and_lock()) > { > m = ul.release(); > is_locked = true; > } > } > else > { > m = ul.release(); > } > } > > > template <class Clock, class Duration> > unique_lock( upgrade_lock<mutex_type> && ul, > const chrono::time_point<Clock, Duration>& abs_time) > : m(0),is_locked(false) > { > if (ul.owns_lock()) > { > if (ul.mutex()->try_unlock_upgrade_and_lock_until(abs_time)) > { > m = ul.release(); > is_locked = true; > } > } > else > { > m = ul.release(); > } > } > > template <class Rep, class Period> > unique_lock( upgrade_lock<mutex_type> && ul, > const chrono::duration<Rep, Period>& rel_time) > : m(0),is_locked(false) > { > if (ul.owns_lock()) > { > if (ul.mutex()->try_unlock_upgrade_and_lock_for(rel_time)) > { > m = ul.release(); > is_locked = true; > } > } > else > { > m = ul.release(); > } > } ># 321 "/usr/include/boost/thread/lock_types.hpp" 3 4 > void swap(unique_lock& other)noexcept > { > std::swap(m,other.m); > std::swap(is_locked,other.is_locked); > } > > ~unique_lock() > { > if (owns_lock()) > { > m->unlock(); > } > } > void lock() > { > if (m == 0) > { > boost::throw_exception( > boost::lock_error(system::errc::operation_not_permitted, "boost unique_lock has no mutex")); > } > if (owns_lock()) > { > boost::throw_exception( > boost::lock_error(system::errc::resource_deadlock_would_occur, "boost unique_lock owns already the mutex")); > } > m->lock(); > is_locked = true; > } > bool try_lock() > { > if (m == 0) > { > boost::throw_exception( > boost::lock_error(system::errc::operation_not_permitted, "boost unique_lock has no mutex")); > } > if (owns_lock()) > { > boost::throw_exception( > boost::lock_error(system::errc::resource_deadlock_would_occur, "boost unique_lock owns already the mutex")); > } > is_locked = m->try_lock(); > return is_locked; > } > > template<typename TimeDuration> > bool timed_lock(TimeDuration const& relative_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost unique_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost unique_lock owns already the mutex")); > } > is_locked=m->timed_lock(relative_time); > return is_locked; > } > > bool timed_lock(::boost::system_time const& absolute_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost unique_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost unique_lock owns already the mutex")); > } > is_locked=m->timed_lock(absolute_time); > return is_locked; > } > bool timed_lock(::boost::xtime const& absolute_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost unique_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost unique_lock owns already the mutex")); > } > is_locked=m->timed_lock(absolute_time); > return is_locked; > } > > > > template <class Rep, class Period> > bool try_lock_for(const chrono::duration<Rep, Period>& rel_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost unique_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost unique_lock owns already the mutex")); > } > is_locked=m->try_lock_for(rel_time); > return is_locked; > } > template <class Clock, class Duration> > bool try_lock_until(const chrono::time_point<Clock, Duration>& abs_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost unique_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost unique_lock owns already the mutex")); > } > is_locked=m->try_lock_until(abs_time); > return is_locked; > } > > > void unlock() > { > if (m == 0) > { > boost::throw_exception( > boost::lock_error(system::errc::operation_not_permitted, "boost unique_lock has no mutex")); > } > if (!owns_lock()) > { > boost::throw_exception( > boost::lock_error(system::errc::operation_not_permitted, "boost unique_lock doesn't own the mutex")); > } > m->unlock(); > is_locked = false; > } ># 466 "/usr/include/boost/thread/lock_types.hpp" 3 4 > explicit operator bool() const noexcept > { > return owns_lock(); > } > > bool owns_lock() const noexcept > { > return is_locked; > } > > Mutex* mutex() const noexcept > { > return m; > } > > Mutex* release()noexcept > { > Mutex* const res=m; > m=0; > is_locked=false; > return res; > } > > friend class shared_lock<Mutex> ; > friend class upgrade_lock<Mutex> ; > }; > > template<typename Mutex> > void swap(unique_lock<Mutex>& lhs, unique_lock<Mutex>& rhs) > noexcept > { > lhs.swap(rhs); > } > > namespace detail { template <typename Mutex> struct enable_move_utility_emulation_dummy_specialization< unique_lock<Mutex> > : integral_constant<bool, false> {}; } > > template<typename Mutex> > class shared_lock > { > protected: > Mutex* m; > bool is_locked; > > public: > typedef Mutex mutex_type; > shared_lock(shared_lock const&) = delete; shared_lock& operator=(shared_lock const&) = delete; > > shared_lock() noexcept: > m(0),is_locked(false) > {} > > explicit shared_lock(Mutex& m_): > m(&m_),is_locked(false) > { > lock(); > } > shared_lock(Mutex& m_,adopt_lock_t): > m(&m_),is_locked(true) > { > > > > } > shared_lock(Mutex& m_,defer_lock_t) noexcept: > m(&m_),is_locked(false) > {} > shared_lock(Mutex& m_,try_to_lock_t): > m(&m_),is_locked(false) > { > try_lock(); > } > > shared_lock(Mutex& m_,system_time const& target_time): > m(&m_),is_locked(false) > { > timed_lock(target_time); > } > > > template <class Clock, class Duration> > shared_lock(Mutex& mtx, const chrono::time_point<Clock, Duration>& t) > : m(&mtx), is_locked(mtx.try_lock_shared_until(t)) > { > } > template <class Rep, class Period> > shared_lock(Mutex& mtx, const chrono::duration<Rep, Period>& d) > : m(&mtx), is_locked(mtx.try_lock_shared_for(d)) > { > } > > > shared_lock( shared_lock<Mutex> && other) noexcept: > m(other.m),is_locked(other.is_locked) > { > other.is_locked=false; > other.m=0; > } > > shared_lock( unique_lock<Mutex> && other): > m(other.m),is_locked(other.is_locked) > { > if(is_locked) > { > m->unlock_and_lock_shared(); > } > other.is_locked=false; > other.m=0; > } > > shared_lock( upgrade_lock<Mutex> && other): > m(other.m),is_locked(other.is_locked) > { > if(is_locked) > { > m->unlock_upgrade_and_lock_shared(); > } > other.is_locked=false; > other.m=0; > } > > > shared_lock& operator=( shared_lock<Mutex> && other) > { > shared_lock temp(::boost::move(other)); > swap(temp); > return *this; > } > > shared_lock& operator=( unique_lock<Mutex> && other) > { > shared_lock temp(::boost::move(other)); > swap(temp); > return *this; > } > > shared_lock& operator=( upgrade_lock<Mutex> && other) > { > shared_lock temp(::boost::move(other)); > swap(temp); > return *this; > } > > > void swap(shared_lock& other) noexcept > { > std::swap(m,other.m); > std::swap(is_locked,other.is_locked); > } > > Mutex* mutex() const noexcept > { > return m; > } > > Mutex* release() noexcept > { > Mutex* const res=m; > m=0; > is_locked=false; > return res; > } > > ~shared_lock() > { > if(owns_lock()) > { > m->unlock_shared(); > } > } > void lock() > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost shared_lock owns already the mutex")); > } > m->lock_shared(); > is_locked=true; > } > bool try_lock() > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost shared_lock owns already the mutex")); > } > is_locked=m->try_lock_shared(); > return is_locked; > } > > bool timed_lock(boost::system_time const& target_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost shared_lock owns already the mutex")); > } > is_locked=m->timed_lock_shared(target_time); > return is_locked; > } > template<typename Duration> > bool timed_lock(Duration const& target_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost shared_lock owns already the mutex")); > } > is_locked=m->timed_lock_shared(target_time); > return is_locked; > } > > > template <class Rep, class Period> > bool try_lock_for(const chrono::duration<Rep, Period>& rel_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost shared_lock owns already the mutex")); > } > is_locked=m->try_lock_shared_for(rel_time); > return is_locked; > } > template <class Clock, class Duration> > bool try_lock_until(const chrono::time_point<Clock, Duration>& abs_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost shared_lock owns already the mutex")); > } > is_locked=m->try_lock_shared_until(abs_time); > return is_locked; > } > > void unlock() > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if(!owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock doesn't own the mutex")); > } > m->unlock_shared(); > is_locked=false; > } ># 745 "/usr/include/boost/thread/lock_types.hpp" 3 4 > explicit operator bool() const noexcept > { > return owns_lock(); > } > > bool owns_lock() const noexcept > { > return is_locked; > } > > }; > > namespace detail { template <typename Mutex> struct enable_move_utility_emulation_dummy_specialization< shared_lock<Mutex> > : integral_constant<bool, false> {}; } > > template<typename Mutex> > void swap(shared_lock<Mutex>& lhs,shared_lock<Mutex>& rhs) noexcept > { > lhs.swap(rhs); > } > > template <typename Mutex> > class upgrade_lock > { > protected: > Mutex* m; > bool is_locked; > > public: > typedef Mutex mutex_type; > upgrade_lock(upgrade_lock const&) = delete; upgrade_lock& operator=(upgrade_lock const&) = delete; > > upgrade_lock()noexcept: > m(0),is_locked(false) > {} > > explicit upgrade_lock(Mutex& m_) : > m(&m_), is_locked(false) > { > lock(); > } > upgrade_lock(Mutex& m_, adopt_lock_t) : > m(&m_), is_locked(true) > { > > > > } > upgrade_lock(Mutex& m_, defer_lock_t)noexcept: > m(&m_),is_locked(false) > {} > upgrade_lock(Mutex& m_, try_to_lock_t) : > m(&m_), is_locked(false) > { > try_lock(); > } > > > template <class Clock, class Duration> > upgrade_lock(Mutex& mtx, const chrono::time_point<Clock, Duration>& t) > : m(&mtx), is_locked(mtx.try_lock_upgrade_until(t)) > { > } > template <class Rep, class Period> > upgrade_lock(Mutex& mtx, const chrono::duration<Rep, Period>& d) > : m(&mtx), is_locked(mtx.try_lock_upgrade_for(d)) > { > } > > > upgrade_lock( upgrade_lock<Mutex> && other) noexcept: > m(other.m),is_locked(other.is_locked) > { > other.is_locked=false; > other.m=0; > } > > upgrade_lock( unique_lock<Mutex> && other): > m(other.m),is_locked(other.is_locked) > { > if(is_locked) > { > m->unlock_and_lock_upgrade(); > } > other.is_locked=false; > other.m=0; > } > > > upgrade_lock& operator=( upgrade_lock<Mutex> && other) > { > upgrade_lock temp(::boost::move(other)); > swap(temp); > return *this; > } > > > upgrade_lock& operator=( unique_lock<Mutex> && other) > { > upgrade_lock temp(::boost::move(other)); > swap(temp); > return *this; > } ># 908 "/usr/include/boost/thread/lock_types.hpp" 3 4 > void swap(upgrade_lock& other)noexcept > { > std::swap(m,other.m); > std::swap(is_locked,other.is_locked); > } > Mutex* mutex() const noexcept > { > return m; > } > > Mutex* release()noexcept > { > Mutex* const res=m; > m=0; > is_locked=false; > return res; > } > ~upgrade_lock() > { > if (owns_lock()) > { > m->unlock_upgrade(); > } > } > void lock() > { > if (m == 0) > { > boost::throw_exception( > boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if (owns_lock()) > { > boost::throw_exception( > boost::lock_error(system::errc::resource_deadlock_would_occur, "boost upgrade_lock owns already the mutex")); > } > m->lock_upgrade(); > is_locked = true; > } > bool try_lock() > { > if (m == 0) > { > boost::throw_exception( > boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if (owns_lock()) > { > boost::throw_exception( > boost::lock_error(system::errc::resource_deadlock_would_occur, "boost upgrade_lock owns already the mutex")); > } > is_locked = m->try_lock_upgrade(); > return is_locked; > } > void unlock() > { > if (m == 0) > { > boost::throw_exception( > boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if (!owns_lock()) > { > boost::throw_exception( > boost::lock_error(system::errc::operation_not_permitted, "boost upgrade_lock doesn't own the mutex")); > } > m->unlock_upgrade(); > is_locked = false; > } > > template <class Rep, class Period> > bool try_lock_for(const chrono::duration<Rep, Period>& rel_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost shared_lock owns already the mutex")); > } > is_locked=m->try_lock_upgrade_for(rel_time); > return is_locked; > } > template <class Clock, class Duration> > bool try_lock_until(const chrono::time_point<Clock, Duration>& abs_time) > { > if(m==0) > { > boost::throw_exception(boost::lock_error(system::errc::operation_not_permitted, "boost shared_lock has no mutex")); > } > if(owns_lock()) > { > boost::throw_exception(boost::lock_error(system::errc::resource_deadlock_would_occur, "boost shared_lock owns already the mutex")); > } > is_locked=m->try_lock_upgrade_until(abs_time); > return is_locked; > } ># 1018 "/usr/include/boost/thread/lock_types.hpp" 3 4 > explicit operator bool() const noexcept > { > return owns_lock(); > } > > bool owns_lock() const noexcept > { > return is_locked; > } > friend class shared_lock<Mutex> ; > friend class unique_lock<Mutex> ; > }; > > template<typename Mutex> > void swap(upgrade_lock<Mutex>& lhs, upgrade_lock<Mutex>& rhs) > noexcept > { > lhs.swap(rhs); > } > > namespace detail { template <typename Mutex> struct enable_move_utility_emulation_dummy_specialization< upgrade_lock<Mutex> > : integral_constant<bool, false> {}; } > > template<typename Mutex> > unique_lock<Mutex>::unique_lock( upgrade_lock<Mutex> && other): > m(other.m),is_locked(other.is_locked) > { > if(is_locked) > { > m->unlock_upgrade_and_lock(); > } > other.release(); > } > > template <class Mutex> > class upgrade_to_unique_lock > { > private: > upgrade_lock<Mutex>* source; > unique_lock<Mutex> exclusive; > > public: > typedef Mutex mutex_type; > upgrade_to_unique_lock(upgrade_to_unique_lock const&) = delete; upgrade_to_unique_lock& operator=(upgrade_to_unique_lock const&) = delete; > > explicit upgrade_to_unique_lock(upgrade_lock<Mutex>& m_) : > source(&m_), exclusive(::boost::move(*source)) > { > } > ~upgrade_to_unique_lock() > { > if (source) > { > *source = upgrade_lock<Mutex> (::boost::move(exclusive)); > } > } > > upgrade_to_unique_lock( upgrade_to_unique_lock<Mutex> && other) noexcept: > source(other.source),exclusive(::boost::move(other.exclusive)) > { > other.source=0; > } > > > upgrade_to_unique_lock& operator=( upgrade_to_unique_lock<Mutex> && other) > { > upgrade_to_unique_lock temp(other); > swap(temp); > return *this; > } > > void swap(upgrade_to_unique_lock& other)noexcept > { > std::swap(source,other.source); > exclusive.swap(other.exclusive); > } ># 1105 "/usr/include/boost/thread/lock_types.hpp" 3 4 > explicit operator bool() const noexcept > { > return owns_lock(); > } > > > bool owns_lock() const noexcept > { > return exclusive.owns_lock(); > } > Mutex* mutex() const noexcept > { > return exclusive.mutex(); > } > }; > >namespace detail { template <typename Mutex> struct enable_move_utility_emulation_dummy_specialization< upgrade_to_unique_lock<Mutex> > : integral_constant<bool, false> {}; } > >namespace detail >{ > template<typename Mutex> > class try_lock_wrapper: >private unique_lock<Mutex> > { > typedef unique_lock<Mutex> base; > public: > try_lock_wrapper(try_lock_wrapper const&) = delete; try_lock_wrapper& operator=(try_lock_wrapper const&) = delete; > > try_lock_wrapper() > {} > > explicit try_lock_wrapper(Mutex& m): > base(m,try_to_lock) > {} > > try_lock_wrapper(Mutex& m_,adopt_lock_t): > base(m_,adopt_lock) > { > > > > } > try_lock_wrapper(Mutex& m_,defer_lock_t): > base(m_,defer_lock) > {} > try_lock_wrapper(Mutex& m_,try_to_lock_t): > base(m_,try_to_lock) > {} > > try_lock_wrapper(try_lock_wrapper && other): > base(::boost::move(other)) > {} ># 1168 "/usr/include/boost/thread/lock_types.hpp" 3 4 > try_lock_wrapper& operator=( try_lock_wrapper<Mutex> && other) > { > try_lock_wrapper temp(other); > swap(temp); > return *this; > } > void swap(try_lock_wrapper& other) > { > base::swap(other); > } > void lock() > { > base::lock(); > } > bool try_lock() > { > return base::try_lock(); > } > void unlock() > { > base::unlock(); > } > bool owns_lock() const > { > return base::owns_lock(); > } > Mutex* mutex() const noexcept > { > return base::mutex(); > } > Mutex* release() > { > return base::release(); > } ># 1214 "/usr/include/boost/thread/lock_types.hpp" 3 4 > explicit operator bool() const > { > return owns_lock(); > } > > }; > > template<typename Mutex> > void swap(try_lock_wrapper<Mutex>& lhs,try_lock_wrapper<Mutex>& rhs) > { > lhs.swap(rhs); > } >} >} ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 1229 "/usr/include/boost/thread/lock_types.hpp" 2 3 4 ># 13 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/mutex.hpp" 1 3 4 ># 16 "/usr/include/boost/thread/mutex.hpp" 3 4 ># 1 "/usr/include/boost/thread/pthread/mutex.hpp" 1 3 4 ># 17 "/usr/include/boost/thread/pthread/mutex.hpp" 3 4 ># 1 "/usr/include/boost/thread/xtime.hpp" 1 3 4 ># 14 "/usr/include/boost/thread/xtime.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 15 "/usr/include/boost/thread/xtime.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/posix_time/conversion.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/posix_time/conversion.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 71 "/usr/include/c++/4.9.0/cstring" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > using ::memchr; > using ::memcmp; > using ::memcpy; > using ::memmove; > using ::memset; > using ::strcat; > using ::strcmp; > using ::strcoll; > using ::strcpy; > using ::strcspn; > using ::strerror; > using ::strlen; > using ::strncat; > using ::strncmp; > using ::strncpy; > using ::strspn; > using ::strtok; > using ::strxfrm; > using ::strchr; > using ::strpbrk; > using ::strrchr; > using ::strstr; ># 120 "/usr/include/c++/4.9.0/cstring" 3 > >} ># 13 "/usr/include/boost/date_time/posix_time/conversion.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/date_time/gregorian/conversion.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/gregorian/conversion.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 13 "/usr/include/boost/date_time/gregorian/conversion.hpp" 2 3 4 > > > > > > > >namespace boost { > >namespace gregorian { > > > 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; > return datetm; > } > > > inline > date date_from_tm(const std::tm& datetm) > { > return date(static_cast<unsigned short>(datetm.tm_year+1900), > static_cast<unsigned short>(datetm.tm_mon+1), > static_cast<unsigned short>(datetm.tm_mday)); > } > >} } ># 19 "/usr/include/boost/date_time/posix_time/conversion.hpp" 2 3 4 > >namespace boost { > >namespace posix_time { > > > > inline > ptime from_time_t(std::time_t t) > { > ptime start(gregorian::date(1970,1,1)); > return start + seconds(static_cast<long>(t)); > } > > > 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; > return timetm; > } > > 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; > return timetm; > } > > > 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)); > } ># 88 "/usr/include/boost/date_time/posix_time/conversion.hpp" 3 4 >} } ># 17 "/usr/include/boost/thread/xtime.hpp" 2 3 4 > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 19 "/usr/include/boost/thread/xtime.hpp" 2 3 4 > >namespace boost { > >enum xtime_clock_types >{ > TIME_UTC_=1 > > > > > > > >}; > >struct xtime >{ > > > > typedef int_fast64_t xtime_sec_t; > > > typedef int_fast32_t xtime_nsec_t; > > xtime_sec_t sec; > xtime_nsec_t nsec; > > operator system_time() const > { > return boost::posix_time::from_time_t(0)+ > boost::posix_time::seconds(static_cast<long>(sec))+ > > > > boost::posix_time::microseconds((nsec+500)/1000); > > } > >}; > >inline xtime get_xtime(boost::system_time const& abs_time) >{ > xtime res; > boost::posix_time::time_duration const time_since_epoch=abs_time-boost::posix_time::from_time_t(0); > > res.sec=static_cast<xtime::xtime_sec_t>(time_since_epoch.total_seconds()); > res.nsec=static_cast<xtime::xtime_nsec_t>(time_since_epoch.fractional_seconds()*(1000000000/time_since_epoch.ticks_per_second())); > return res; >} > >inline int xtime_get(struct xtime* xtp, int clock_type) >{ > if (clock_type == TIME_UTC_) > { > *xtp=get_xtime(get_system_time()); > return clock_type; > } > return 0; >} > > >inline int xtime_cmp(const xtime& xt1, const xtime& xt2) >{ > if (xt1.sec == xt2.sec) > return (int)(xt1.nsec - xt2.nsec); > else > return (xt1.sec > xt2.sec) ? 1 : -1; >} > >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 92 "/usr/include/boost/thread/xtime.hpp" 2 3 4 ># 18 "/usr/include/boost/thread/pthread/mutex.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 19 "/usr/include/boost/thread/pthread/mutex.hpp" 2 3 4 ># 1 "/usr/include/errno.h" 1 3 4 ># 20 "/usr/include/boost/thread/pthread/mutex.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/pthread/timespec.hpp" 1 3 4 ># 30 "/usr/include/boost/thread/pthread/timespec.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 31 "/usr/include/boost/thread/pthread/timespec.hpp" 2 3 4 > >namespace boost >{ > namespace detail > { > > inline struct timespec to_timespec(boost::system_time const& abs_time) > { > struct timespec timeout = { 0,0}; > boost::posix_time::time_duration const time_since_epoch=abs_time-boost::posix_time::from_time_t(0); > > timeout.tv_sec=time_since_epoch.total_seconds(); > timeout.tv_nsec=(long)(time_since_epoch.fractional_seconds()*(1000000000l/time_since_epoch.ticks_per_second())); > return timeout; > } > > > inline timespec to_timespec(chrono::nanoseconds const& ns) > { > struct timespec ts; > ts.tv_sec = static_cast<long>(chrono::duration_cast<chrono::seconds>(ns).count()); > ts.tv_nsec = static_cast<long>((ns - chrono::duration_cast<chrono::seconds>(ns)).count()); > return ts; > } > > > > inline timespec to_timespec(boost::intmax_t const& ns) > { > boost::intmax_t s = ns / 1000000000l; > struct timespec ts; > ts.tv_sec = static_cast<long> (s); > ts.tv_nsec = static_cast<long> (ns - s * 1000000000l); > return ts; > } > inline boost::intmax_t to_nanoseconds_int_max(timespec const& ts) > { > return static_cast<boost::intmax_t>(ts.tv_sec) * 1000000000l + ts.tv_nsec; > } > inline bool timespec_ge_zero(timespec const& ts) > { > return (ts.tv_sec >= 0) || (ts.tv_nsec >= 0); > } > inline timespec timespec_now() > { > timespec ts; > > > > > > > > if ( ::clock_gettime( 0, &ts ) ) > { > (static_cast<void> (0)); > } > > return ts; > } > inline timespec timespec_zero() > { > timespec ts; > ts.tv_sec = 0; > ts.tv_nsec = 0; > return ts; > } > inline timespec timespec_plus(timespec const& lhs, timespec const& rhs) > { > return to_timespec(to_nanoseconds_int_max(lhs) + to_nanoseconds_int_max(rhs)); > } > inline timespec timespec_minus(timespec const& lhs, timespec const& rhs) > { > return to_timespec(to_nanoseconds_int_max(lhs) - to_nanoseconds_int_max(rhs)); > } > inline bool timespec_gt(timespec const& lhs, timespec const& rhs) > { > return to_nanoseconds_int_max(lhs) > to_nanoseconds_int_max(rhs); > } > inline bool timespec_ge(timespec const& lhs, timespec const& rhs) > { > return to_nanoseconds_int_max(lhs) >= to_nanoseconds_int_max(rhs); > } > > } >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 119 "/usr/include/boost/thread/pthread/timespec.hpp" 2 3 4 ># 21 "/usr/include/boost/thread/pthread/mutex.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/pthread/pthread_mutex_scoped_lock.hpp" 1 3 4 ># 10 "/usr/include/boost/thread/pthread/pthread_mutex_scoped_lock.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 11 "/usr/include/boost/thread/pthread/pthread_mutex_scoped_lock.hpp" 2 3 4 > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 13 "/usr/include/boost/thread/pthread/pthread_mutex_scoped_lock.hpp" 2 3 4 > >namespace boost >{ > namespace pthread > { > class pthread_mutex_scoped_lock > { > pthread_mutex_t* m; > bool locked; > public: > explicit pthread_mutex_scoped_lock(pthread_mutex_t* m_): > m(m_),locked(true) > { > ((void)(!pthread_mutex_lock(m))); > } > void unlock() > { > ((void)(!pthread_mutex_unlock(m))); > locked=false; > } > > ~pthread_mutex_scoped_lock() > { > if(locked) > { > unlock(); > } > } > > }; > > class pthread_mutex_scoped_unlock > { > pthread_mutex_t* m; > public: > explicit pthread_mutex_scoped_unlock(pthread_mutex_t* m_): > m(m_) > { > ((void)(!pthread_mutex_unlock(m))); > } > ~pthread_mutex_scoped_unlock() > { > ((void)(!pthread_mutex_lock(m))); > } > > }; > } >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 63 "/usr/include/boost/thread/pthread/pthread_mutex_scoped_lock.hpp" 2 3 4 ># 22 "/usr/include/boost/thread/pthread/mutex.hpp" 2 3 4 > ># 1 "/usr/include/boost/chrono/system_clocks.hpp" 1 3 4 ># 64 "/usr/include/boost/chrono/system_clocks.hpp" 3 4 ># 1 "/usr/include/boost/chrono/detail/system.hpp" 1 3 4 ># 11 "/usr/include/boost/chrono/detail/system.hpp" 3 4 ># 1 "/usr/include/boost/version.hpp" 1 3 4 ># 12 "/usr/include/boost/chrono/detail/system.hpp" 2 3 4 ># 65 "/usr/include/boost/chrono/system_clocks.hpp" 2 3 4 ># 1 "/usr/include/boost/chrono/clock_string.hpp" 1 3 4 ># 13 "/usr/include/boost/chrono/clock_string.hpp" 3 4 >namespace boost >{ > namespace chrono > { > > template<class Clock, class CharT> > struct clock_string; > > } > >} ># 66 "/usr/include/boost/chrono/system_clocks.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/ctime" 1 3 4 ># 39 "/usr/include/c++/4.9.0/ctime" 3 4 ># 40 "/usr/include/c++/4.9.0/ctime" 3 ># 68 "/usr/include/boost/chrono/system_clocks.hpp" 2 3 4 ># 84 "/usr/include/boost/chrono/system_clocks.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 85 "/usr/include/boost/chrono/system_clocks.hpp" 2 3 4 ># 95 "/usr/include/boost/chrono/system_clocks.hpp" 3 4 >namespace boost { >namespace chrono { > > > class system_clock; > > class steady_clock; > > > > typedef steady_clock high_resolution_clock; ># 127 "/usr/include/boost/chrono/system_clocks.hpp" 3 4 > class system_clock > { > public: > typedef boost::chrono::nanoseconds duration; > typedef duration::rep rep; > typedef duration::period period; > typedef chrono::time_point<system_clock> time_point; > static constexpr bool is_steady = false; > > static time_point now() noexcept; > > static time_point now(system::error_code & ec); > > > static std::time_t to_time_t(const time_point& t) noexcept; > static time_point from_time_t(std::time_t t) noexcept; > }; ># 153 "/usr/include/boost/chrono/system_clocks.hpp" 3 4 > class steady_clock > { > public: > typedef nanoseconds duration; > typedef duration::rep rep; > typedef duration::period period; > typedef chrono::time_point<steady_clock> time_point; > static constexpr bool is_steady = true; > > static time_point now() noexcept; > > static time_point now(system::error_code & ec); > > }; ># 176 "/usr/include/boost/chrono/system_clocks.hpp" 3 4 > template<class CharT> > struct clock_string<system_clock, CharT> > { > static std::basic_string<CharT> name() > { > static const CharT u[] = > { 's', 'y', 's', 't', 'e', 'm', '_', 'c', 'l', 'o', 'c', 'k' }; > static const std::basic_string<CharT> str(u, u + sizeof(u) > / sizeof(u[0])); > return str; > } > static std::basic_string<CharT> since() > { > static const CharT > u[] = > { ' ', 's', 'i', 'n', 'c', 'e', ' ', 'J', 'a', 'n', ' ', '1', ',', ' ', '1', '9', '7', '0' }; > static const std::basic_string<CharT> str(u, u + sizeof(u) > / sizeof(u[0])); > return str; > } > }; > > > > template<class CharT> > struct clock_string<steady_clock, CharT> > { > static std::basic_string<CharT> name() > { > static const CharT > u[] = > { 's', 't', 'e', 'a', 'd', 'y', '_', 'c', 'l', 'o', 'c', 'k' }; > static const std::basic_string<CharT> str(u, u + sizeof(u) > / sizeof(u[0])); > return str; > } > static std::basic_string<CharT> since() > { > const CharT u[] = > { ' ', 's', 'i', 'n', 'c', 'e', ' ', 'b', 'o', 'o', 't' }; > const std::basic_string<CharT> str(u, u + sizeof(u) / sizeof(u[0])); > return str; > } > }; > > > >} >} > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 229 "/usr/include/boost/chrono/system_clocks.hpp" 2 3 4 ># 24 "/usr/include/boost/thread/pthread/mutex.hpp" 2 3 4 ># 1 "/usr/include/boost/chrono/ceil.hpp" 1 3 4 ># 16 "/usr/include/boost/chrono/ceil.hpp" 3 4 >namespace boost >{ > namespace chrono > { > > > > > template <class To, class Rep, class Period> > To ceil(const duration<Rep, Period>& d) > { > To t = duration_cast<To>(d); > if (t < d) > ++t; > return t; > } > > } >} ># 25 "/usr/include/boost/thread/pthread/mutex.hpp" 2 3 4 ># 37 "/usr/include/boost/thread/pthread/mutex.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 38 "/usr/include/boost/thread/pthread/mutex.hpp" 2 3 4 > > > > > >namespace boost >{ > namespace posix { > > inline __attribute__ ((__always_inline__)) int pthread_mutex_destroy(pthread_mutex_t* m) > { > int ret; > do > { > ret = ::pthread_mutex_destroy(m); > } while (ret == 4); > return ret; > } > inline __attribute__ ((__always_inline__)) int pthread_mutex_lock(pthread_mutex_t* m) > { > int ret; > do > { > ret = ::pthread_mutex_lock(m); > } while (ret == 4); > return ret; > } > inline __attribute__ ((__always_inline__)) int pthread_mutex_unlock(pthread_mutex_t* m) > { > int ret; > do > { > ret = ::pthread_mutex_unlock(m); > } while (ret == 4); > return ret; > } ># 90 "/usr/include/boost/thread/pthread/mutex.hpp" 3 4 > } > class mutex > { > private: > pthread_mutex_t m; > public: > mutex(mutex const&) = delete; mutex& operator=(mutex const&) = delete; > > mutex() > { > int const res=pthread_mutex_init(&m,__null); > if(res) > { > boost::throw_exception(thread_resource_error(res, "boost:: mutex constructor failed in pthread_mutex_init")); > } > } > ~mutex() > { > ((void)(!posix::pthread_mutex_destroy(&m))); > } > > void lock() > { > int res = posix::pthread_mutex_lock(&m); > if (res) > { > boost::throw_exception(lock_error(res,"boost: mutex lock failed in pthread_mutex_lock")); > } > } > > void unlock() > { > int res = posix::pthread_mutex_unlock(&m); > if (res) > { > boost::throw_exception(lock_error(res,"boost: mutex unlock failed in pthread_mutex_unlock")); > } > } > > bool try_lock() > { > int res; > do > { > res = pthread_mutex_trylock(&m); > } while (res == 4); > if (res==16) > { > return false; > } > > return !res; > } > > > typedef pthread_mutex_t* native_handle_type; > native_handle_type native_handle() > { > return &m; > } > > > typedef unique_lock<mutex> scoped_lock; > typedef detail::try_lock_wrapper<mutex> scoped_try_lock; > > }; > > typedef mutex try_mutex; > > class timed_mutex > { > private: > pthread_mutex_t m; > > > > > public: > timed_mutex(timed_mutex const&) = delete; timed_mutex& operator=(timed_mutex const&) = delete; > timed_mutex() > { > int const res=pthread_mutex_init(&m,__null); > if(res) > { > boost::throw_exception(thread_resource_error(res, "boost:: timed_mutex constructor failed in pthread_mutex_init")); > } ># 186 "/usr/include/boost/thread/pthread/mutex.hpp" 3 4 > } > ~timed_mutex() > { > ((void)(!posix::pthread_mutex_destroy(&m))); > > > > } > > > template<typename TimeDuration> > bool timed_lock(TimeDuration const & relative_time) > { > return timed_lock(get_system_time()+relative_time); > } > bool timed_lock(boost::xtime const & absolute_time) > { > return timed_lock(system_time(absolute_time)); > } > > > void lock() > { > int res = posix::pthread_mutex_lock(&m); > if (res) > { > boost::throw_exception(lock_error(res,"boost: mutex lock failed in pthread_mutex_lock")); > } > } > > void unlock() > { > int res = posix::pthread_mutex_unlock(&m); > if (res) > { > boost::throw_exception(lock_error(res,"boost: mutex unlock failed in pthread_mutex_unlock")); > } > } > > bool try_lock() > { > int res; > do > { > res = pthread_mutex_trylock(&m); > } while (res == 4); > if (res==16) > { > return false; > } > > return !res; > } > > > private: > bool do_try_lock_until(struct timespec const &timeout) > { > int const res=pthread_mutex_timedlock(&m,&timeout); > (static_cast<void> (0)); > return !res; > } > public: ># 299 "/usr/include/boost/thread/pthread/mutex.hpp" 3 4 > bool timed_lock(system_time const & abs_time) > { > struct timespec const ts=boost::detail::to_timespec(abs_time); > return do_try_lock_until(ts); > } > > > template <class Rep, class Period> > bool try_lock_for(const chrono::duration<Rep, Period>& rel_time) > { > return try_lock_until(chrono::steady_clock::now() + rel_time); > } > template <class Clock, class Duration> > bool try_lock_until(const chrono::time_point<Clock, Duration>& t) > { > using namespace chrono; > system_clock::time_point s_now = system_clock::now(); > typename Clock::time_point c_now = Clock::now(); > return try_lock_until(s_now + ceil<nanoseconds>(t - c_now)); > } > template <class Duration> > bool try_lock_until(const chrono::time_point<chrono::system_clock, Duration>& t) > { > using namespace chrono; > typedef time_point<system_clock, nanoseconds> nano_sys_tmpt; > return try_lock_until(nano_sys_tmpt(ceil<nanoseconds>(t.time_since_epoch()))); > } > bool try_lock_until(const chrono::time_point<chrono::system_clock, chrono::nanoseconds>& tp) > { > > chrono::nanoseconds d = tp.time_since_epoch(); > timespec ts = boost::detail::to_timespec(d); > return do_try_lock_until(ts); > } > > > > typedef pthread_mutex_t* native_handle_type; > native_handle_type native_handle() > { > return &m; > } > > > typedef unique_lock<timed_mutex> scoped_timed_lock; > typedef detail::try_lock_wrapper<timed_mutex> scoped_try_lock; > typedef scoped_timed_lock scoped_lock; > > }; > >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 352 "/usr/include/boost/thread/pthread/mutex.hpp" 2 3 4 ># 17 "/usr/include/boost/thread/mutex.hpp" 2 3 4 > > > > > > > >namespace boost >{ > namespace sync > { ># 50 "/usr/include/boost/thread/mutex.hpp" 3 4 > } >} ># 14 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/pthread/condition_variable_fwd.hpp" 1 3 4 ># 9 "/usr/include/boost/thread/pthread/condition_variable_fwd.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 10 "/usr/include/boost/thread/pthread/condition_variable_fwd.hpp" 2 3 4 > > ># 1 "/usr/include/boost/thread/cv_status.hpp" 1 3 4 ># 12 "/usr/include/boost/thread/cv_status.hpp" 3 4 ># 1 "/usr/include/boost/detail/scoped_enum_emulation.hpp" 1 3 4 ># 130 "/usr/include/boost/detail/scoped_enum_emulation.hpp" 3 4 >namespace boost >{ ># 198 "/usr/include/boost/detail/scoped_enum_emulation.hpp" 3 4 > template <typename EnumType> > struct underlying_type > { > > }; > > template <typename EnumType> > struct native_type > { > typedef EnumType type; > }; > > template <typename UnderlyingType, typename EnumType> > UnderlyingType underlying_cast(EnumType v) > { > return static_cast<UnderlyingType>(v); > } > > template <typename EnumType> > inline > EnumType native_value(EnumType e) > { > return e; > } > > >} ># 13 "/usr/include/boost/thread/cv_status.hpp" 2 3 4 > >namespace boost >{ > > > enum class cv_status > { > no_timeout, > timeout > } > ; >} ># 13 "/usr/include/boost/thread/pthread/condition_variable_fwd.hpp" 2 3 4 ># 27 "/usr/include/boost/thread/pthread/condition_variable_fwd.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 28 "/usr/include/boost/thread/pthread/condition_variable_fwd.hpp" 2 3 4 > >namespace boost >{ > > class condition_variable > { > private: > > pthread_mutex_t internal_mutex; > > pthread_cond_t cond; > > public: > > > inline bool do_wait_until( > unique_lock<mutex>& lock, > struct timespec const &timeout); > > bool do_wait_for( > unique_lock<mutex>& lock, > struct timespec const &timeout) > { > return do_wait_until(lock, boost::detail::timespec_plus(timeout, boost::detail::timespec_now())); > } > > public: > condition_variable(condition_variable const&) = delete; condition_variable& operator=(condition_variable const&) = delete; > condition_variable() > { > > int const res=pthread_mutex_init(&internal_mutex,__null); > if(res) > { > boost::throw_exception(thread_resource_error(res, "boost::condition_variable::condition_variable() constructor failed in pthread_mutex_init")); > } > > int const res2=pthread_cond_init(&cond,__null); > if(res2) > { > > ((void)(!pthread_mutex_destroy(&internal_mutex))); > > boost::throw_exception(thread_resource_error(res2, "boost::condition_variable::condition_variable() constructor failed in pthread_cond_init")); > } > } > ~condition_variable() > { > int ret; > > do { > ret = pthread_mutex_destroy(&internal_mutex); > } while (ret == 4); > (static_cast<void> (0)); > > do { > ret = pthread_cond_destroy(&cond); > } while (ret == 4); > (static_cast<void> (0)); > } > > void wait(unique_lock<mutex>& m); > > template<typename predicate_type> > void wait(unique_lock<mutex>& m,predicate_type pred) > { > while(!pred()) wait(m); > } > > > > inline bool timed_wait( > unique_lock<mutex>& m, > boost::system_time const& abs_time) > { > > > > > struct timespec const timeout=detail::to_timespec(abs_time); > return do_wait_until(m, timeout); > > } > bool timed_wait( > unique_lock<mutex>& m, > xtime const& abs_time) > { > return timed_wait(m,system_time(abs_time)); > } > > template<typename duration_type> > bool timed_wait( > unique_lock<mutex>& m, > duration_type const& wait_duration) > { > return timed_wait(m,get_system_time()+wait_duration); > } > > template<typename predicate_type> > bool timed_wait( > unique_lock<mutex>& m, > boost::system_time const& abs_time,predicate_type pred) > { > while (!pred()) > { > if(!timed_wait(m, abs_time)) > return pred(); > } > return true; > } > > template<typename predicate_type> > bool timed_wait( > unique_lock<mutex>& m, > xtime const& abs_time,predicate_type pred) > { > return timed_wait(m,system_time(abs_time),pred); > } > > template<typename duration_type,typename predicate_type> > bool timed_wait( > unique_lock<mutex>& m, > duration_type const& wait_duration,predicate_type pred) > { > return timed_wait(m,get_system_time()+wait_duration,pred); > } > > > > > template <class Duration> > cv_status > wait_until( > unique_lock<mutex>& lock, > const chrono::time_point<chrono::system_clock, Duration>& t) > { > using namespace chrono; > typedef time_point<system_clock, nanoseconds> nano_sys_tmpt; > wait_until(lock, > nano_sys_tmpt(ceil<nanoseconds>(t.time_since_epoch()))); > return system_clock::now() < t ? cv_status::no_timeout : > cv_status::timeout; > } > > template <class Clock, class Duration> > cv_status > wait_until( > unique_lock<mutex>& lock, > const chrono::time_point<Clock, Duration>& t) > { > using namespace chrono; > system_clock::time_point s_now = system_clock::now(); > typename Clock::time_point c_now = Clock::now(); > wait_until(lock, s_now + ceil<nanoseconds>(t - c_now)); > return Clock::now() < t ? cv_status::no_timeout : cv_status::timeout; > } > > template <class Clock, class Duration, class Predicate> > bool > wait_until( > unique_lock<mutex>& lock, > const chrono::time_point<Clock, Duration>& t, > Predicate pred) > { > while (!pred()) > { > if (wait_until(lock, t) == cv_status::timeout) > return pred(); > } > return true; > } > > > template <class Rep, class Period> > cv_status > wait_for( > unique_lock<mutex>& lock, > const chrono::duration<Rep, Period>& d) > { > using namespace chrono; > system_clock::time_point s_now = system_clock::now(); > steady_clock::time_point c_now = steady_clock::now(); > wait_until(lock, s_now + ceil<nanoseconds>(d)); > return steady_clock::now() - c_now < d ? cv_status::no_timeout : > cv_status::timeout; > > } > > > template <class Rep, class Period, class Predicate> > bool > wait_for( > unique_lock<mutex>& lock, > const chrono::duration<Rep, Period>& d, > Predicate pred) > { > return wait_until(lock, chrono::steady_clock::now() + d, boost::move(pred)); > > > > > > > > } > > > > typedef pthread_cond_t* native_handle_type; > native_handle_type native_handle() > { > return &cond; > } > > void notify_one() noexcept; > void notify_all() noexcept; > > > inline cv_status wait_until( > unique_lock<mutex>& lk, > chrono::time_point<chrono::system_clock, chrono::nanoseconds> tp) > { > using namespace chrono; > nanoseconds d = tp.time_since_epoch(); > timespec ts = boost::detail::to_timespec(d); > if (do_wait_until(lk, ts)) return cv_status::no_timeout; > else return cv_status::timeout; > } > > }; > > __attribute__((__visibility__("default"))) void notify_all_at_thread_exit(condition_variable& cond, unique_lock<mutex> lk); > >} > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 265 "/usr/include/boost/thread/pthread/condition_variable_fwd.hpp" 2 3 4 ># 15 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 > > ># 1 "/usr/include/boost/enable_shared_from_this.hpp" 1 3 4 ># 16 "/usr/include/boost/enable_shared_from_this.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/enable_shared_from_this.hpp" 1 3 4 ># 16 "/usr/include/boost/smart_ptr/enable_shared_from_this.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/weak_ptr.hpp" 1 3 4 ># 20 "/usr/include/boost/smart_ptr/weak_ptr.hpp" 3 4 >namespace boost >{ > >template<class T> class weak_ptr >{ >private: > > > typedef weak_ptr<T> this_type; > >public: > > typedef typename boost::detail::sp_element< T >::type element_type; > > weak_ptr() noexcept : px(0), pn() > { > } > > > > > > > > weak_ptr( weak_ptr const & r ) noexcept : px( r.px ), pn( r.pn ) > { > } > > weak_ptr & operator=( weak_ptr const & r ) noexcept > { > px = r.px; > pn = r.pn; > return *this; > } ># 74 "/usr/include/boost/smart_ptr/weak_ptr.hpp" 3 4 > template<class Y> > > > weak_ptr( weak_ptr<Y> const & r, typename boost::detail::sp_enable_if_convertible<Y,T>::type = boost::detail::sp_empty() ) > > > > > > > noexcept : px(r.lock().get()), pn(r.pn) > { > boost::detail::sp_assert_convertible< Y, T >(); > } > > > > template<class Y> > > > weak_ptr( weak_ptr<Y> && r, typename boost::detail::sp_enable_if_convertible<Y,T>::type = boost::detail::sp_empty() ) > > > > > > > noexcept : px( r.lock().get() ), pn( static_cast< boost::detail::weak_count && >( r.pn ) ) > { > boost::detail::sp_assert_convertible< Y, T >(); > r.px = 0; > } > > > weak_ptr( weak_ptr && r ) > noexcept : px( r.px ), pn( static_cast< boost::detail::weak_count && >( r.pn ) ) > { > r.px = 0; > } > > > weak_ptr & operator=( weak_ptr && r ) noexcept > { > this_type( static_cast< weak_ptr && >( r ) ).swap( *this ); > return *this; > } > > > > > template<class Y> > > > weak_ptr( shared_ptr<Y> const & r, typename boost::detail::sp_enable_if_convertible<Y,T>::type = boost::detail::sp_empty() ) > > > > > > > noexcept : px( r.px ), pn( r.pn ) > { > boost::detail::sp_assert_convertible< Y, T >(); > } > > > > template<class Y> > weak_ptr & operator=( weak_ptr<Y> const & r ) noexcept > { > boost::detail::sp_assert_convertible< Y, T >(); > > px = r.lock().get(); > pn = r.pn; > > return *this; > } > > > > template<class Y> > weak_ptr & operator=( weak_ptr<Y> && r ) noexcept > { > this_type( static_cast< weak_ptr<Y> && >( r ) ).swap( *this ); > return *this; > } > > > > template<class Y> > weak_ptr & operator=( shared_ptr<Y> const & r ) noexcept > { > boost::detail::sp_assert_convertible< Y, T >(); > > px = r.px; > pn = r.pn; > > return *this; > } > > > > shared_ptr<T> lock() const noexcept > { > return shared_ptr<T>( *this, boost::detail::sp_nothrow_tag() ); > } > > long use_count() const noexcept > { > return pn.use_count(); > } > > bool expired() const noexcept > { > return pn.use_count() == 0; > } > > bool _empty() const > { > return pn.empty(); > } > > void reset() noexcept > { > this_type().swap(*this); > } > > void swap(this_type & other) noexcept > { > std::swap(px, other.px); > pn.swap(other.pn); > } > > template<typename Y> > void _internal_aliasing_assign(weak_ptr<Y> const & r, element_type * px2) > { > px = px2; > pn = r.pn; > } > > template<class Y> bool owner_before( weak_ptr<Y> const & rhs ) const noexcept > { > return pn < rhs.pn; > } > > template<class Y> bool owner_before( shared_ptr<Y> const & rhs ) const noexcept > { > return pn < rhs.pn; > } > > > > > > >private: > > template<class Y> friend class weak_ptr; > template<class Y> friend class shared_ptr; > > > > element_type * px; > boost::detail::weak_count pn; > >}; > >template<class T, class U> inline bool operator<(weak_ptr<T> const & a, weak_ptr<U> const & b) noexcept >{ > return a.owner_before( b ); >} > >template<class T> void swap(weak_ptr<T> & a, weak_ptr<T> & b) noexcept >{ > a.swap(b); >} > >} ># 17 "/usr/include/boost/smart_ptr/enable_shared_from_this.hpp" 2 3 4 > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 19 "/usr/include/boost/smart_ptr/enable_shared_from_this.hpp" 2 3 4 > > >namespace boost >{ > >template<class T> class enable_shared_from_this >{ >protected: > > enable_shared_from_this() noexcept > { > } > > enable_shared_from_this(enable_shared_from_this const &) noexcept > { > } > > enable_shared_from_this & operator=(enable_shared_from_this const &) noexcept > { > return *this; > } > > ~enable_shared_from_this() noexcept > { > } > >public: > > shared_ptr<T> shared_from_this() > { > shared_ptr<T> p( weak_this_ ); > (static_cast<void> (0)); > return p; > } > > shared_ptr<T const> shared_from_this() const > { > shared_ptr<T const> p( weak_this_ ); > (static_cast<void> (0)); > return p; > } > >public: > > > template<class X, class Y> void _internal_accept_owner( shared_ptr<X> const * ppx, Y * py ) const > { > if( weak_this_.expired() ) > { > weak_this_ = shared_ptr<T>( *ppx, py ); > } > } > >private: > > mutable weak_ptr<T> weak_this_; >}; > >} ># 17 "/usr/include/boost/enable_shared_from_this.hpp" 2 3 4 ># 18 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 ># 1 "/usr/include/boost/optional.hpp" 1 3 4 ># 15 "/usr/include/boost/optional.hpp" 3 4 ># 1 "/usr/include/boost/optional/optional.hpp" 1 3 4 ># 22 "/usr/include/boost/optional/optional.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 23 "/usr/include/boost/optional/optional.hpp" 2 3 4 ># 1 "/usr/include/boost/type.hpp" 1 3 4 ># 9 "/usr/include/boost/type.hpp" 3 4 >namespace boost { > > > > template <class T> > struct type {}; > >} ># 24 "/usr/include/boost/optional/optional.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/alignment_of.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/alignment_of.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/size_t_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/size_t_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/size_t_trait_def.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/size_t.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/size_t.hpp" 3 4 ># 1 "/usr/include/boost/mpl/size_t_fwd.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/size_t_fwd.hpp" 3 4 >namespace mpl_ { > >template< std::size_t N > struct size_t; > >} >namespace boost { namespace mpl { using ::mpl_::size_t; } } ># 18 "/usr/include/boost/mpl/size_t.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 1 3 4 ># 40 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 3 4 >namespace mpl_ { > >template< std::size_t N > >struct size_t >{ > static const std::size_t value = N; > > > > > > typedef size_t type; > > typedef std::size_t value_type; > typedef integral_c_tag tag; ># 72 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 3 4 > typedef mpl_::size_t< static_cast<std::size_t>((value + 1)) > next; > typedef mpl_::size_t< static_cast<std::size_t>((value - 1)) > prior; > > > > > > > operator std::size_t() const { return static_cast<std::size_t>(this->value); } >}; > > >template< std::size_t N > >std::size_t const mpl_::size_t< N >::value; > > >} ># 24 "/usr/include/boost/mpl/size_t.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/detail/size_t_trait_def.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/alignment_of.hpp" 2 3 4 ># 27 "/usr/include/boost/type_traits/alignment_of.hpp" 3 4 >namespace boost { > >template <typename T> struct alignment_of; > > >namespace detail { > > > > > >template <typename T> >struct alignment_of_hack >{ > char c; > T t; > alignment_of_hack(); >}; > > > > >template <unsigned A, unsigned S> >struct alignment_logic >{ > static const std::size_t value = A < S ? A : S; >}; > > >template< typename T > >struct alignment_of_impl >{ ># 83 "/usr/include/boost/type_traits/alignment_of.hpp" 3 4 > static const std::size_t value = __alignof__(T); > >}; > >} > >template< typename T > struct alignment_of : public ::boost::integral_constant<std::size_t,::boost::detail::alignment_of_impl<T>::value> { public: }; > > > > >template <typename T> >struct alignment_of<T&> > : public alignment_of<T*> >{ >}; ># 109 "/usr/include/boost/type_traits/alignment_of.hpp" 3 4 >template<> struct alignment_of<void> : public ::boost::integral_constant<std::size_t,0> { public: }; > >template<> struct alignment_of<void const> : public ::boost::integral_constant<std::size_t,0> { public: }; >template<> struct alignment_of<void volatile> : public ::boost::integral_constant<std::size_t,0> { public: }; >template<> struct alignment_of<void const volatile> : public ::boost::integral_constant<std::size_t,0> { public: }; > > >} ># 125 "/usr/include/boost/type_traits/alignment_of.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/size_t_trait_undef.hpp" 1 3 4 ># 126 "/usr/include/boost/type_traits/alignment_of.hpp" 2 3 4 ># 25 "/usr/include/boost/optional/optional.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/has_nothrow_constructor.hpp" 1 3 4 ># 12 "/usr/include/boost/type_traits/has_nothrow_constructor.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/has_trivial_constructor.hpp" 1 3 4 ># 18 "/usr/include/boost/type_traits/has_trivial_constructor.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 19 "/usr/include/boost/type_traits/has_trivial_constructor.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct has_trivial_ctor_impl >{ > > static const bool value = (::boost::type_traits::ice_or< ::boost::is_pod<T>::value, ((__has_trivial_constructor(T) ) && ! ::boost::is_volatile<T>::value) >::value) > > > > ; > > > > > > > >}; > >} > >template< typename T > struct has_trivial_constructor : public ::boost::integral_constant<bool,::boost::detail::has_trivial_ctor_impl<T>::value> { public: }; >template< typename T > struct has_trivial_default_constructor : public ::boost::integral_constant<bool,::boost::detail::has_trivial_ctor_impl<T>::value> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 50 "/usr/include/boost/type_traits/has_trivial_constructor.hpp" 2 3 4 ># 13 "/usr/include/boost/type_traits/has_nothrow_constructor.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 16 "/usr/include/boost/type_traits/has_nothrow_constructor.hpp" 2 3 4 > >namespace boost { > >namespace detail{ > >template <class T> >struct has_nothrow_constructor_imp{ > > static const bool value = (__has_nothrow_constructor(T) ); > > > >}; > >} > >template< typename T > struct has_nothrow_constructor : public ::boost::integral_constant<bool,::boost::detail::has_nothrow_constructor_imp<T>::value> { public: }; >template< typename T > struct has_nothrow_default_constructor : public ::boost::integral_constant<bool,::boost::detail::has_nothrow_constructor_imp<T>::value> { public: }; > >template<> struct has_nothrow_constructor< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_nothrow_constructor< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_constructor< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_constructor< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >template<> struct has_nothrow_default_constructor< void > : public ::boost::integral_constant<bool,false> { public: }; > >template<> struct has_nothrow_default_constructor< void const > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_default_constructor< void const volatile > : public ::boost::integral_constant<bool,false> { public: }; >template<> struct has_nothrow_default_constructor< void volatile > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 52 "/usr/include/boost/type_traits/has_nothrow_constructor.hpp" 2 3 4 ># 26 "/usr/include/boost/optional/optional.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/type_with_alignment.hpp" 1 3 4 ># 12 "/usr/include/boost/type_traits/type_with_alignment.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/list/for_each_i.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/list/for_each_i.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/repetition/for.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/repetition/for.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/repetition/for.hpp" 2 3 4 ># 42 "/usr/include/boost/preprocessor/repetition/for.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/repetition/detail/for.hpp" 1 3 4 ># 43 "/usr/include/boost/preprocessor/repetition/for.hpp" 2 3 4 ># 21 "/usr/include/boost/preprocessor/list/for_each_i.hpp" 2 3 4 ># 13 "/usr/include/boost/type_traits/type_with_alignment.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/tuple/to_list.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/type_with_alignment.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/list/transform.hpp" 1 3 4 ># 16 "/usr/include/boost/type_traits/type_with_alignment.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/list/append.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/type_with_alignment.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 24 "/usr/include/boost/type_traits/type_with_alignment.hpp" 2 3 4 ># 32 "/usr/include/boost/type_traits/type_with_alignment.hpp" 3 4 >namespace boost { > > > >namespace detail { > >class alignment_dummy; >typedef void (*function_ptr)(); >typedef int (alignment_dummy::*member_ptr); >typedef int (alignment_dummy::*member_function_ptr)(); ># 101 "/usr/include/boost/type_traits/type_with_alignment.hpp" 3 4 >template <bool found, std::size_t target, class TestType> >struct lower_alignment_helper >{ > typedef char type; > enum { value = true }; >}; > >template <std::size_t target, class TestType> >struct lower_alignment_helper<false,target,TestType> >{ > enum { value = (alignment_of<TestType>::value == target) }; > typedef typename mpl::if_c<value, TestType, char>::type type; >}; ># 127 "/usr/include/boost/type_traits/type_with_alignment.hpp" 3 4 >template <typename T> >struct has_one_T >{ > T data; >}; > >template <std::size_t target> >union lower_alignment >{ > enum { found0 = false }; > > typename lower_alignment_helper< found0,target,char >::type t0; enum { found1 = lower_alignment_helper<found0,target,char >::value }; typename lower_alignment_helper< found1,target,short >::type t1; enum { found2 = lower_alignment_helper<found1,target,short >::value }; typename lower_alignment_helper< found2,target,int >::type t2; enum { found3 = lower_alignment_helper<found2,target,int >::value }; typename lower_alignment_helper< found3,target,long >::type t3; enum { found4 = lower_alignment_helper<found3,target,long >::value }; typename lower_alignment_helper< found4,target,::boost::long_long_type >::type t4; enum { found5 = lower_alignment_helper<found4,target,::boost::long_long_type >::value }; typename lower_alignment_helper< found5,target,float >::type t5; enum { found6 = lower_alignment_helper<found5,target,float >::value }; typename lower_alignment_helper< found6,target,double >::type t6; enum { found7 = lower_alignment_helper<found6,target,double >::value }; typename lower_alignment_helper< found7,target,long double >::type t7; enum { found8 = lower_alignment_helper<found7,target,long double >::value }; typename lower_alignment_helper< found8,target,void* >::type t8; enum { found9 = lower_alignment_helper<found8,target,void* >::value }; typename lower_alignment_helper< found9,target,function_ptr >::type t9; enum { found10 = lower_alignment_helper<found9,target,function_ptr >::value }; typename lower_alignment_helper< found10,target,member_ptr >::type t10; enum { found11 = lower_alignment_helper<found10,target,member_ptr >::value }; typename lower_alignment_helper< found11,target,member_function_ptr >::type t11; enum { found12 = lower_alignment_helper<found11,target,member_function_ptr >::value }; typename lower_alignment_helper< found12,target,boost::detail::has_one_T< char > >::type t12; enum { found13 = lower_alignment_helper<found12,target,boost::detail::has_one_T< char > >::value }; typename lower_alignment_helper< found13,target,boost::detail::has_one_T< short > >::type t13; enum { found14 = lower_alignment_helper<found13,target,boost::detail::has_one_T< short > >::value }; typename lower_alignment_helper< found14,target,boost::detail::has_one_T< int > >::type t14; enum { found15 = lower_alignment_helper<found14,target,boost::detail::has_one_T< int > >::value }; typename lower_alignment_helper< found15,target,boost::detail::has_one_T< long > >::type t15; enum { found16 = lower_alignment_helper<found15,target,boost::detail::has_one_T< long > >::value }; typename lower_alignment_helper< found16,target,boost::detail::has_one_T< ::boost::long_long_type > >::type t16; enum { found17 = lower_alignment_helper<found16,target,boost::detail::has_one_T< ::boost::long_long_type > >::value }; typename lower_alignment_helper< found17,target,boost::detail::has_one_T< float > >::type t17; enum { found18 = lower_alignment_helper<found17,target,boost::detail::has_one_T< float > >::value }; typename lower_alignment_helper< found18,target,boost::detail::has_one_T< double > >::type t18; enum { found19 = lower_alignment_helper<found18,target,boost::detail::has_one_T< double > >::value }; typename lower_alignment_helper< found19,target,boost::detail::has_one_T< long double > >::type t19; enum { found20 = lower_alignment_helper<found19,target,boost::detail::has_one_T< long double > >::value }; typename lower_alignment_helper< found20,target,boost::detail::has_one_T< void* > >::type t20; enum { found21 = lower_alignment_helper<found20,target,boost::detail::has_one_T< void* > >::value }; typename lower_alignment_helper< found21,target,boost::detail::has_one_T< function_ptr > >::type t21; enum { found22 = lower_alignment_helper<found21,target,boost::detail::has_one_T< function_ptr > >::value }; typename lower_alignment_helper< found22,target,boost::detail::has_one_T< member_ptr > >::type t22; enum { found23 = lower_alignment_helper<found22,target,boost::detail::has_one_T< member_ptr > >::value }; typename lower_alignment_helper< found23,target,boost::detail::has_one_T< member_function_ptr > >::type t23; enum { found24 = lower_alignment_helper<found23,target,boost::detail::has_one_T< member_function_ptr > >::value }; > > > > >}; > >union max_align >{ > char t0; short t1; int t2; long t3; ::boost::long_long_type t4; float t5; double t6; long double t7; void* t8; function_ptr t9; member_ptr t10; member_function_ptr t11; boost::detail::has_one_T< char > t12; boost::detail::has_one_T< short > t13; boost::detail::has_one_T< int > t14; boost::detail::has_one_T< long > t15; boost::detail::has_one_T< ::boost::long_long_type > t16; boost::detail::has_one_T< float > t17; boost::detail::has_one_T< double > t18; boost::detail::has_one_T< long double > t19; boost::detail::has_one_T< void* > t20; boost::detail::has_one_T< function_ptr > t21; boost::detail::has_one_T< member_ptr > t22; boost::detail::has_one_T< member_function_ptr > t23; > > > > >}; ># 161 "/usr/include/boost/type_traits/type_with_alignment.hpp" 3 4 >template<std::size_t TAlign, std::size_t Align> >struct is_aligned >{ > static const bool value = (TAlign >= Align) & (TAlign % Align == 0) > > ; >}; ># 180 "/usr/include/boost/type_traits/type_with_alignment.hpp" 3 4 >} > > >template<std::size_t Align> >struct is_pod< ::boost::detail::lower_alignment<Align> > >{ > static const std::size_t value = true; >}; > > > > >namespace detail{ > >template <std::size_t Align> >class type_with_alignment_imp >{ > typedef ::boost::detail::lower_alignment<Align> t1; > typedef typename mpl::if_c< > ::boost::detail::is_aligned< ::boost::alignment_of<t1>::value,Align >::value > , t1 > , ::boost::detail::max_align > >::type align_t; > > static const std::size_t found = alignment_of<align_t>::value; > > static_assert(found >= Align, "found >= Align"); > static_assert(found % Align == 0, "found % Align == 0"); > > public: > typedef align_t type; >}; > >} > >template <std::size_t Align> >class type_with_alignment > : public ::boost::detail::type_with_alignment_imp<Align> >{ >}; > > >namespace align { >struct __attribute__((__aligned__(2))) a2 {}; >struct __attribute__((__aligned__(4))) a4 {}; >struct __attribute__((__aligned__(8))) a8 {}; >struct __attribute__((__aligned__(16))) a16 {}; >struct __attribute__((__aligned__(32))) a32 {}; >struct __attribute__((__aligned__(64))) a64 {}; >struct __attribute__((__aligned__(128))) a128 {}; >} > >template<> class type_with_alignment<1> { public: typedef char type; }; >template<> class type_with_alignment<2> { public: typedef align::a2 type; }; >template<> class type_with_alignment<4> { public: typedef align::a4 type; }; >template<> class type_with_alignment<8> { public: typedef align::a8 type; }; >template<> class type_with_alignment<16> { public: typedef align::a16 type; }; >template<> class type_with_alignment<32> { public: typedef align::a32 type; }; >template<> class type_with_alignment<64> { public: typedef align::a64 type; }; >template<> class type_with_alignment<128> { public: typedef align::a128 type; }; > >namespace detail { >template<> struct is_pod_impl< ::boost::align::a2 > { public: static const bool value = (true); }; >template<> struct is_pod_impl< ::boost::align::a4 > { public: static const bool value = (true); }; >template<> struct is_pod_impl< ::boost::align::a8 > { public: static const bool value = (true); }; >template<> struct is_pod_impl< ::boost::align::a16 > { public: static const bool value = (true); }; >template<> struct is_pod_impl< ::boost::align::a32 > { public: static const bool value = (true); }; >template<> struct is_pod_impl< ::boost::align::a64 > { public: static const bool value = (true); }; >template<> struct is_pod_impl< ::boost::align::a128 > { public: static const bool value = (true); }; >} ># 389 "/usr/include/boost/type_traits/type_with_alignment.hpp" 3 4 >} > > > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 396 "/usr/include/boost/type_traits/type_with_alignment.hpp" 2 3 4 ># 27 "/usr/include/boost/optional/optional.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/detail/reference_content.hpp" 1 3 4 ># 28 "/usr/include/boost/detail/reference_content.hpp" 3 4 >namespace boost { > >namespace detail { > > > > > > >template <typename RefT> >class reference_content >{ >private: > > RefT content_; > >public: > > ~reference_content() > { > } > > reference_content(RefT r) > : content_( r ) > { > } > > reference_content(const reference_content& operand) > : content_( operand.content_ ) > { > } > >private: > > reference_content& operator=(const reference_content&); > >public: > > RefT get() const > { > return content_; > } > >}; > > > > > > > >template <typename T = mpl::void_> struct make_reference_content; > > > >template <typename T> >struct make_reference_content >{ > typedef T type; >}; > >template <typename T> >struct make_reference_content< T& > >{ > typedef reference_content<T&> type; >}; ># 109 "/usr/include/boost/detail/reference_content.hpp" 3 4 >template <> >struct make_reference_content< mpl::void_ > >{ > template <typename T> > struct apply > : make_reference_content<T> > { > }; > > typedef mpl::void_ type; >}; > >} > > > > > > > >template <typename T> >struct has_nothrow_copy< > ::boost::detail::reference_content< T& > > > > : mpl::true_ >{ >}; > > > >} ># 33 "/usr/include/boost/optional/optional.hpp" 2 3 4 ># 1 "/usr/include/boost/none.hpp" 1 3 4 ># 15 "/usr/include/boost/none.hpp" 3 4 ># 1 "/usr/include/boost/none_t.hpp" 1 3 4 ># 15 "/usr/include/boost/none_t.hpp" 3 4 >namespace boost { > >namespace detail { struct none_helper{}; } > >typedef int detail::none_helper::*none_t ; > >} ># 16 "/usr/include/boost/none.hpp" 2 3 4 > > > > > >namespace boost { > >none_t const none = (static_cast<none_t>(0)) ; > >} ># 34 "/usr/include/boost/optional/optional.hpp" 2 3 4 ># 1 "/usr/include/boost/utility/swap.hpp" 1 3 4 ># 27 "/usr/include/boost/utility/swap.hpp" 3 4 >namespace boost_swap_impl >{ > template<class T> > void swap_impl(T& left, T& right) > { > using namespace std; > swap(left,right); > } > > template<class T, std::size_t N> > void swap_impl(T (& left)[N], T (& right)[N]) > { > for (std::size_t i = 0; i < N; ++i) > { > ::boost_swap_impl::swap_impl(left[i], right[i]); > } > } >} > >namespace boost >{ > template<class T1, class T2> > void swap(T1& left, T2& right) > { > ::boost_swap_impl::swap_impl(left, right); > } >} ># 35 "/usr/include/boost/optional/optional.hpp" 2 3 4 > ># 1 "/usr/include/boost/utility/compare_pointees.hpp" 1 3 4 ># 17 "/usr/include/boost/utility/compare_pointees.hpp" 3 4 >namespace boost { ># 28 "/usr/include/boost/utility/compare_pointees.hpp" 3 4 >template<class OptionalPointee> >inline >bool equal_pointees ( OptionalPointee const& x, OptionalPointee const& y ) >{ > return (!x) != (!y) ? false : ( !x ? true : (*x) == (*y) ) ; >} > >template<class OptionalPointee> >struct equal_pointees_t : std::binary_function<OptionalPointee,OptionalPointee,bool> >{ > bool operator() ( OptionalPointee const& x, OptionalPointee const& y ) const > { return equal_pointees(x,y) ; } >} ; ># 51 "/usr/include/boost/utility/compare_pointees.hpp" 3 4 >template<class OptionalPointee> >inline >bool less_pointees ( OptionalPointee const& x, OptionalPointee const& y ) >{ > return !y ? false : ( !x ? true : (*x) < (*y) ) ; >} > >template<class OptionalPointee> >struct less_pointees_t : std::binary_function<OptionalPointee,OptionalPointee,bool> >{ > bool operator() ( OptionalPointee const& x, OptionalPointee const& y ) const > { return less_pointees(x,y) ; } >} ; > >} ># 37 "/usr/include/boost/optional/optional.hpp" 2 3 4 ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 16 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 ># 1 "/usr/include/boost/utility/detail/in_place_factory_prefix.hpp" 1 3 4 ># 20 "/usr/include/boost/utility/detail/in_place_factory_prefix.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/punctuation/paren.hpp" 1 3 4 ># 21 "/usr/include/boost/utility/detail/in_place_factory_prefix.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/iterate.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/iteration/iterate.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/slot.hpp" 1 3 4 ># 16 "/usr/include/boost/preprocessor/slot/slot.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/def.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/slot/slot.hpp" 2 3 4 ># 21 "/usr/include/boost/preprocessor/iteration/iterate.hpp" 2 3 4 ># 22 "/usr/include/boost/utility/detail/in_place_factory_prefix.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/repetition/enum.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/repetition/enum.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 21 "/usr/include/boost/preprocessor/repetition/enum.hpp" 2 3 4 ># 24 "/usr/include/boost/utility/detail/in_place_factory_prefix.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/repetition/enum_binary_params.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/in_place_factory_prefix.hpp" 2 3 4 ># 17 "/usr/include/boost/utility/in_place_factory.hpp" 2 3 4 > >namespace boost { > >class in_place_factory_base {} ; > > > ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 18 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 20 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 37 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >class in_place_factory0 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory0 > ( ) > > > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > >}; ># 79 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >inline in_place_factory0 in_place() >{ > return in_place_factory0(); >} ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 > > >class in_place_factory1 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory1 > ( A0 const& a0 ) > > : m_a0 ( a0 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; >}; > > >template< class A0 > >inline in_place_factory1< A0 > >in_place( A0 const& a0 ) >{ > return in_place_factory1< A0 > > ( a0 ); >} ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 , class A1 > > >class in_place_factory2 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory2 > ( A0 const& a0 , A1 const& a1 ) > > : m_a0 ( a0 ) , m_a1 ( a1 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 , m_a1 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; A1 const& m_a1; >}; > > >template< class A0 , class A1 > >inline in_place_factory2< A0 , A1 > >in_place( A0 const& a0 , A1 const& a1 ) >{ > return in_place_factory2< A0 , A1 > > ( a0 , a1 ); >} ># 58 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 , class A1 , class A2 > > >class in_place_factory3 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory3 > ( A0 const& a0 , A1 const& a1 , A2 const& a2 ) > > : m_a0 ( a0 ) , m_a1 ( a1 ) , m_a2 ( a2 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 , m_a1 , m_a2 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; A1 const& m_a1; A2 const& m_a2; >}; > > >template< class A0 , class A1 , class A2 > >inline in_place_factory3< A0 , A1 , A2 > >in_place( A0 const& a0 , A1 const& a1 , A2 const& a2 ) >{ > return in_place_factory3< A0 , A1 , A2 > > ( a0 , a1 , a2 ); >} ># 63 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 , class A1 , class A2 , class A3 > > >class in_place_factory4 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory4 > ( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 ) > > : m_a0 ( a0 ) , m_a1 ( a1 ) , m_a2 ( a2 ) , m_a3 ( a3 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 , m_a1 , m_a2 , m_a3 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; A1 const& m_a1; A2 const& m_a2; A3 const& m_a3; >}; > > >template< class A0 , class A1 , class A2 , class A3 > >inline in_place_factory4< A0 , A1 , A2 , A3 > >in_place( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 ) >{ > return in_place_factory4< A0 , A1 , A2 , A3 > > ( a0 , a1 , a2 , a3 ); >} ># 68 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 , class A1 , class A2 , class A3 , class A4 > > >class in_place_factory5 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory5 > ( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 ) > > : m_a0 ( a0 ) , m_a1 ( a1 ) , m_a2 ( a2 ) , m_a3 ( a3 ) , m_a4 ( a4 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 , m_a1 , m_a2 , m_a3 , m_a4 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; A1 const& m_a1; A2 const& m_a2; A3 const& m_a3; A4 const& m_a4; >}; > > >template< class A0 , class A1 , class A2 , class A3 , class A4 > >inline in_place_factory5< A0 , A1 , A2 , A3 , A4 > >in_place( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 ) >{ > return in_place_factory5< A0 , A1 , A2 , A3 , A4 > > ( a0 , a1 , a2 , a3 , a4 ); >} ># 73 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 > > >class in_place_factory6 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory6 > ( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 , A5 const& a5 ) > > : m_a0 ( a0 ) , m_a1 ( a1 ) , m_a2 ( a2 ) , m_a3 ( a3 ) , m_a4 ( a4 ) , m_a5 ( a5 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 , m_a1 , m_a2 , m_a3 , m_a4 , m_a5 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; A1 const& m_a1; A2 const& m_a2; A3 const& m_a3; A4 const& m_a4; A5 const& m_a5; >}; > > >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 > >inline in_place_factory6< A0 , A1 , A2 , A3 , A4 , A5 > >in_place( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 , A5 const& a5 ) >{ > return in_place_factory6< A0 , A1 , A2 , A3 , A4 , A5 > > ( a0 , a1 , a2 , a3 , a4 , a5 ); >} ># 78 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 , class A6 > > >class in_place_factory7 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory7 > ( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 , A5 const& a5 , A6 const& a6 ) > > : m_a0 ( a0 ) , m_a1 ( a1 ) , m_a2 ( a2 ) , m_a3 ( a3 ) , m_a4 ( a4 ) , m_a5 ( a5 ) , m_a6 ( a6 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 , m_a1 , m_a2 , m_a3 , m_a4 , m_a5 , m_a6 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; A1 const& m_a1; A2 const& m_a2; A3 const& m_a3; A4 const& m_a4; A5 const& m_a5; A6 const& m_a6; >}; > > >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 , class A6 > >inline in_place_factory7< A0 , A1 , A2 , A3 , A4 , A5 , A6 > >in_place( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 , A5 const& a5 , A6 const& a6 ) >{ > return in_place_factory7< A0 , A1 , A2 , A3 , A4 , A5 , A6 > > ( a0 , a1 , a2 , a3 , a4 , a5 , a6 ); >} ># 83 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 , class A6 , class A7 > > >class in_place_factory8 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory8 > ( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 , A5 const& a5 , A6 const& a6 , A7 const& a7 ) > > : m_a0 ( a0 ) , m_a1 ( a1 ) , m_a2 ( a2 ) , m_a3 ( a3 ) , m_a4 ( a4 ) , m_a5 ( a5 ) , m_a6 ( a6 ) , m_a7 ( a7 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 , m_a1 , m_a2 , m_a3 , m_a4 , m_a5 , m_a6 , m_a7 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; A1 const& m_a1; A2 const& m_a2; A3 const& m_a3; A4 const& m_a4; A5 const& m_a5; A6 const& m_a6; A7 const& m_a7; >}; > > >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 , class A6 , class A7 > >inline in_place_factory8< A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 > >in_place( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 , A5 const& a5 , A6 const& a6 , A7 const& a7 ) >{ > return in_place_factory8< A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 > > ( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 ); >} ># 88 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 , class A6 , class A7 , class A8 > > >class in_place_factory9 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory9 > ( A0 const& a0 , A1 const& a1 , A2 const& a2 , A3 const& a3 , A4 const& a4 , A5 const& a5 , A6 const& a6 , A7 const& a7 , A8 const& a8 ) > > : m_a0 ( a0 ) , m_a1 ( a1 ) , m_a2 ( a2 ) , m_a3 ( a3 ) , m_a4 ( a4 ) , m_a5 ( a5 ) , m_a6 ( a6 ) , m_a7 ( a7 ) , m_a8 ( a8 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 , m_a1 , m_a2 , m_a3 , m_a4 , m_a5 , m_a6 , m_a7 , m_a8 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; A1 const& m_a1; A2 const& m_a2; A3 const& m_a3; A4 const& m_a4; A5 const& m_a5; A6 const& m_a6; A7 const& m_a7; A8 const& m_a8; >}; > > >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 , class A6 , class A7 , class A8 > >inline in_place_factory9< A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8 > >in_place( A0 const& a0 , 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 in_place_factory9< A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8 > > ( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 ); >} ># 93 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/in_place_factory.hpp" 1 3 4 ># 35 "/usr/include/boost/utility/in_place_factory.hpp" 3 4 >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 , class A6 , class A7 , class A8 , class A9 > > >class in_place_factory10 > : > public in_place_factory_base >{ >public: > > explicit in_place_factory10 > ( A0 const& a0 , 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 ) > > : m_a0 ( a0 ) , m_a1 ( a1 ) , m_a2 ( a2 ) , m_a3 ( a3 ) , m_a4 ( a4 ) , m_a5 ( a5 ) , m_a6 ( a6 ) , m_a7 ( a7 ) , m_a8 ( a8 ) , m_a9 ( a9 ) > > {} > > template<class T> > void* apply(void* address > ) const > { > return new(address) T( m_a0 , m_a1 , m_a2 , m_a3 , m_a4 , m_a5 , m_a6 , m_a7 , m_a8 , m_a9 ); > } > > template<class T> > void* apply(void* address, std::size_t n > ) const > { > for(char* next = address = this->template apply<T>(address); > !! --n;) > this->template apply<T>(next = next+sizeof(T)); > return address; > } > > A0 const& m_a0; A1 const& m_a1; A2 const& m_a2; A3 const& m_a3; A4 const& m_a4; A5 const& m_a5; A6 const& m_a6; A7 const& m_a7; A8 const& m_a8; A9 const& m_a9; >}; > > >template< class A0 , class A1 , class A2 , class A3 , class A4 , class A5 , class A6 , class A7 , class A8 , class A9 > >inline in_place_factory10< A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8 , A9 > >in_place( A0 const& a0 , 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 in_place_factory10< A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8 , A9 > > ( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9 ); >} ># 98 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 25 "/usr/include/boost/utility/in_place_factory.hpp" 2 3 4 > >} > ># 1 "/usr/include/boost/utility/detail/in_place_factory_suffix.hpp" 1 3 4 ># 29 "/usr/include/boost/utility/in_place_factory.hpp" 2 3 4 ># 38 "/usr/include/boost/optional/optional.hpp" 2 3 4 > ># 1 "/usr/include/boost/optional/optional_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/optional/optional_fwd.hpp" 3 4 >namespace boost { > >template<class T> class optional ; > >template<class T> void swap ( optional<T>& , optional<T>& ) ; > >template<class T> struct optional_swap_should_use_default_constructor ; > >} ># 40 "/usr/include/boost/optional/optional.hpp" 2 3 4 ># 99 "/usr/include/boost/optional/optional.hpp" 3 4 >namespace boost_optional_detail >{ > template <class T, class Factory> > inline void construct(Factory const& factory, void* address) > { > factory.template apply<T>(address); > } >} > > >namespace boost { > >class in_place_factory_base ; >class typed_in_place_factory_base ; > > >template<class T> void swap ( optional<T>& x, optional<T>& y ); > >namespace optional_detail { > > > > > >template <class T> >class aligned_storage >{ > > union > > > __attribute__((may_alias)) > > dummy_u > { > char data[ sizeof(T) ]; > typename type_with_alignment< > ::boost::alignment_of<T>::value >::type aligner_; > } dummy_ ; > > public: > > > void const* address() const { return &dummy_; } > void * address() { return &dummy_; } > > > > >} ; > >template<class T> >struct types_when_isnt_ref >{ > typedef T const& reference_const_type ; > typedef T & reference_type ; > typedef T const* pointer_const_type ; > typedef T * pointer_type ; > typedef T const& argument_type ; >} ; >template<class T> >struct types_when_is_ref >{ > typedef typename remove_reference<T>::type raw_type ; > > typedef raw_type& reference_const_type ; > typedef raw_type& reference_type ; > typedef raw_type* pointer_const_type ; > typedef raw_type* pointer_type ; > typedef raw_type& argument_type ; >} ; > >struct optional_tag {} ; > >template<class T> >class optional_base : public optional_tag >{ > private : > > typedef > > typename > > ::boost::detail::make_reference_content<T>::type internal_type ; > > typedef aligned_storage<internal_type> storage_type ; > > typedef types_when_isnt_ref<T> types_when_not_ref ; > typedef types_when_is_ref<T> types_when_ref ; > > typedef optional_base<T> this_type ; > > protected : > > typedef T value_type ; > > typedef mpl::true_ is_reference_tag ; > typedef mpl::false_ is_not_reference_tag ; > > typedef typename is_reference<T>::type is_reference_predicate ; > > public: > typedef typename mpl::if_<is_reference_predicate,types_when_ref,types_when_not_ref>::type types ; > > protected: > typedef bool (this_type::*unspecified_bool_type)() const; > > typedef typename types::reference_type reference_type ; > typedef typename types::reference_const_type reference_const_type ; > typedef typename types::pointer_type pointer_type ; > typedef typename types::pointer_const_type pointer_const_type ; > typedef typename types::argument_type argument_type ; > > > > optional_base() > : > m_initialized(false) {} > > > > optional_base ( none_t ) > : > m_initialized(false) {} > > > > optional_base ( argument_type val ) > : > m_initialized(false) > { > construct(val); > } > > > > optional_base ( bool cond, argument_type val ) > : > m_initialized(false) > { > if ( cond ) > construct(val); > } > > > > optional_base ( optional_base const& rhs ) > : > m_initialized(false) > { > if ( rhs.is_initialized() ) > construct(rhs.get_impl()); > } > > > > > > template<class Expr> > explicit optional_base ( Expr const& expr, Expr const* tag ) > : > m_initialized(false) > { > construct(expr,tag); > } > > > > > ~optional_base() { destroy() ; } > > > void assign ( optional_base const& rhs ) > { > if (is_initialized()) > { > if ( rhs.is_initialized() ) > assign_value(rhs.get_impl(), is_reference_predicate() ); > else destroy(); > } > else > { > if ( rhs.is_initialized() ) > construct(rhs.get_impl()); > } > } > > > template<class U> > void assign ( optional<U> const& rhs ) > { > if (is_initialized()) > { > if ( rhs.is_initialized() ) > assign_value(static_cast<value_type>(rhs.get()), is_reference_predicate() ); > else destroy(); > } > else > { > if ( rhs.is_initialized() ) > construct(static_cast<value_type>(rhs.get())); > } > } > > > void assign ( argument_type val ) > { > if (is_initialized()) > assign_value(val, is_reference_predicate() ); > else construct(val); > } > > > > void assign ( none_t ) { destroy(); } > > > template<class Expr> > void assign_expr ( Expr const& expr, Expr const* tag ) > { > if (is_initialized()) > assign_expr_to_initialized(expr,tag); > else construct(expr,tag); > } > > > public : > > > > void reset() { destroy(); } > > > void reset ( argument_type val ) { assign(val); } > > > > > pointer_const_type get_ptr() const { return m_initialized ? get_ptr_impl() : 0 ; } > pointer_type get_ptr() { return m_initialized ? get_ptr_impl() : 0 ; } > > bool is_initialized() const { return m_initialized ; } > > protected : > > void construct ( argument_type val ) > { > new (m_storage.address()) internal_type(val) ; > m_initialized = true ; > } > > > > template<class Expr> > void construct ( Expr const& factory, in_place_factory_base const* ) > { > static_assert(::boost::mpl::not_<is_reference_predicate>::value, "::boost::mpl::not_<is_reference_predicate>::value") ; > boost_optional_detail::construct<value_type>(factory, m_storage.address()); > m_initialized = true ; > } > > > template<class Expr> > void construct ( Expr const& factory, typed_in_place_factory_base const* ) > { > static_assert(::boost::mpl::not_<is_reference_predicate>::value, "::boost::mpl::not_<is_reference_predicate>::value") ; > factory.apply(m_storage.address()) ; > m_initialized = true ; > } > > template<class Expr> > void assign_expr_to_initialized ( Expr const& factory, in_place_factory_base const* tag ) > { > destroy(); > construct(factory,tag); > } > > > template<class Expr> > void assign_expr_to_initialized ( Expr const& factory, typed_in_place_factory_base const* tag ) > { > destroy(); > construct(factory,tag); > } > > > > > > > template<class Expr> > void construct ( Expr const& expr, void const* ) > { > new (m_storage.address()) internal_type(expr) ; > m_initialized = true ; > } > > > > > > template<class Expr> > void assign_expr_to_initialized ( Expr const& expr, void const* ) > { > assign_value(expr, is_reference_predicate()); > } ># 433 "/usr/include/boost/optional/optional.hpp" 3 4 > void assign_value ( argument_type val, is_not_reference_tag ) { get_impl() = val; } > void assign_value ( argument_type val, is_reference_tag ) { construct(val); } > > void destroy() > { > if ( m_initialized ) > destroy_impl(is_reference_predicate()) ; > } > > unspecified_bool_type safe_bool() const { return m_initialized ? &this_type::is_initialized : 0 ; } > > reference_const_type get_impl() const { return dereference(get_object(), is_reference_predicate() ) ; } > reference_type get_impl() { return dereference(get_object(), is_reference_predicate() ) ; } > > pointer_const_type get_ptr_impl() const { return cast_ptr(get_object(), is_reference_predicate() ) ; } > pointer_type get_ptr_impl() { return cast_ptr(get_object(), is_reference_predicate() ) ; } > > private : > > > > > internal_type const* get_object() const > { > union { void const* ap_pvoid; internal_type const* as_ptype; } caster = { m_storage.address() }; > return caster.as_ptype; > } > internal_type * get_object() > { > union { void* ap_pvoid; internal_type* as_ptype; } caster = { m_storage.address() }; > return caster.as_ptype; > } > > > > > > > reference_const_type dereference( internal_type const* p, is_not_reference_tag ) const { return *p ; } > reference_type dereference( internal_type* p, is_not_reference_tag ) { return *p ; } > reference_const_type dereference( internal_type const* p, is_reference_tag ) const { return p->get() ; } > reference_type dereference( internal_type* p, is_reference_tag ) { return p->get() ; } > > > > > void destroy_impl ( is_not_reference_tag ) { get_ptr_impl()->T::~T() ; m_initialized = false ; } > > > void destroy_impl ( is_reference_tag ) { m_initialized = false ; } > > > > > pointer_const_type cast_ptr( internal_type const* p, is_not_reference_tag ) const { return p ; } > pointer_type cast_ptr( internal_type * p, is_not_reference_tag ) { return p ; } > pointer_const_type cast_ptr( internal_type const* p, is_reference_tag ) const { return &p->get() ; } > pointer_type cast_ptr( internal_type * p, is_reference_tag ) { return &p->get() ; } > > bool m_initialized ; > storage_type m_storage ; >} ; > >} > >template<class T> >class optional : public optional_detail::optional_base<T> >{ > typedef optional_detail::optional_base<T> base ; > > typedef typename base::unspecified_bool_type unspecified_bool_type ; > > public : > > typedef optional<T> this_type ; > > typedef typename base::value_type value_type ; > typedef typename base::reference_type reference_type ; > typedef typename base::reference_const_type reference_const_type ; > typedef typename base::pointer_type pointer_type ; > typedef typename base::pointer_const_type pointer_const_type ; > typedef typename base::argument_type argument_type ; > > > > optional() : base() {} > > > > optional( none_t none_ ) : base(none_) {} > > > > optional ( argument_type val ) : base(val) {} > > > > optional ( bool cond, argument_type val ) : base(cond,val) {} > > > > > > > > template<class U> > explicit optional ( optional<U> const& rhs ) > : > base() > { > if ( rhs.is_initialized() ) > this->construct(rhs.get()); > } ># 558 "/usr/include/boost/optional/optional.hpp" 3 4 > template<class Expr> > explicit optional ( Expr const& expr ) : base(expr,boost::addressof(expr)) {} > > > > > optional ( optional const& rhs ) : base( static_cast<base const&>(rhs) ) {} > > > ~optional() {} > > > > > template<class Expr> > optional& operator= ( Expr const& expr ) > { > this->assign_expr(expr,boost::addressof(expr)); > return *this ; > } > > > > > > > > template<class U> > optional& operator= ( optional<U> const& rhs ) > { > this->assign(rhs); > return *this ; > } > > > > > > optional& operator= ( optional const& rhs ) > { > this->assign( static_cast<base const&>(rhs) ) ; > return *this ; > } > > > > optional& operator= ( argument_type val ) > { > this->assign( val ) ; > return *this ; > } > > > > > optional& operator= ( none_t none_ ) > { > this->assign( none_ ) ; > return *this ; > } > > void swap( optional & arg ) > { > > using boost::swap; > swap(*this, arg); > } > > > > > > reference_const_type get() const { (static_cast<void> (0)) ; return this->get_impl(); } > reference_type get() { (static_cast<void> (0)) ; return this->get_impl(); } > > > reference_const_type get_value_or ( reference_const_type v ) const { return this->is_initialized() ? get() : v ; } > reference_type get_value_or ( reference_type v ) { return this->is_initialized() ? get() : v ; } > > > > > pointer_const_type operator->() const { (static_cast<void> (0)) ; return this->get_ptr_impl() ; } > pointer_type operator->() { (static_cast<void> (0)) ; return this->get_ptr_impl() ; } > > > > > reference_const_type operator *() const { return this->get() ; } > reference_type operator *() { return this->get() ; } > > > > operator unspecified_bool_type() const { return this->safe_bool() ; } > > > > bool operator!() const { return !this->is_initialized() ; } >} ; > > >template<class T> >inline >optional<T> make_optional ( T const& v ) >{ > return optional<T>(v); >} > > >template<class T> >inline >optional<T> make_optional ( bool cond, T const& v ) >{ > return optional<T>(cond,v); >} > > > >template<class T> >inline >typename optional<T>::reference_const_type >get ( optional<T> const& opt ) >{ > return opt.get() ; >} > >template<class T> >inline >typename optional<T>::reference_type >get ( optional<T>& opt ) >{ > return opt.get() ; >} > > > >template<class T> >inline >typename optional<T>::pointer_const_type >get ( optional<T> const* opt ) >{ > return opt->get_ptr() ; >} > >template<class T> >inline >typename optional<T>::pointer_type >get ( optional<T>* opt ) >{ > return opt->get_ptr() ; >} > > > >template<class T> >inline >typename optional<T>::reference_const_type >get_optional_value_or ( optional<T> const& opt, typename optional<T>::reference_const_type v ) >{ > return opt.get_value_or(v) ; >} > >template<class T> >inline >typename optional<T>::reference_type >get_optional_value_or ( optional<T>& opt, typename optional<T>::reference_type v ) >{ > return opt.get_value_or(v) ; >} > > > >template<class T> >inline >typename optional<T>::pointer_const_type >get_pointer ( optional<T> const& opt ) >{ > return opt.get_ptr() ; >} > >template<class T> >inline >typename optional<T>::pointer_type >get_pointer ( optional<T>& opt ) >{ > return opt.get_ptr() ; >} ># 754 "/usr/include/boost/optional/optional.hpp" 3 4 >template<class T> >inline >bool operator == ( optional<T> const& x, optional<T> const& y ) >{ return equal_pointees(x,y); } > >template<class T> >inline >bool operator < ( optional<T> const& x, optional<T> const& y ) >{ return less_pointees(x,y); } > >template<class T> >inline >bool operator != ( optional<T> const& x, optional<T> const& y ) >{ return !( x == y ) ; } > >template<class T> >inline >bool operator > ( optional<T> const& x, optional<T> const& y ) >{ return y < x ; } > >template<class T> >inline >bool operator <= ( optional<T> const& x, optional<T> const& y ) >{ return !( y < x ) ; } > >template<class T> >inline >bool operator >= ( optional<T> const& x, optional<T> const& y ) >{ return !( x < y ) ; } > > > > > >template<class T> >inline >bool operator == ( optional<T> const& x, T const& y ) >{ return equal_pointees(x, optional<T>(y)); } > >template<class T> >inline >bool operator < ( optional<T> const& x, T const& y ) >{ return less_pointees(x, optional<T>(y)); } > >template<class T> >inline >bool operator != ( optional<T> const& x, T const& y ) >{ return !( x == y ) ; } > >template<class T> >inline >bool operator > ( optional<T> const& x, T const& y ) >{ return y < x ; } > >template<class T> >inline >bool operator <= ( optional<T> const& x, T const& y ) >{ return !( y < x ) ; } > >template<class T> >inline >bool operator >= ( optional<T> const& x, T const& y ) >{ return !( x < y ) ; } > > > > > >template<class T> >inline >bool operator == ( T const& x, optional<T> const& y ) >{ return equal_pointees( optional<T>(x), y ); } > >template<class T> >inline >bool operator < ( T const& x, optional<T> const& y ) >{ return less_pointees( optional<T>(x), y ); } > >template<class T> >inline >bool operator != ( T const& x, optional<T> const& y ) >{ return !( x == y ) ; } > >template<class T> >inline >bool operator > ( T const& x, optional<T> const& y ) >{ return y < x ; } > >template<class T> >inline >bool operator <= ( T const& x, optional<T> const& y ) >{ return !( y < x ) ; } > >template<class T> >inline >bool operator >= ( T const& x, optional<T> const& y ) >{ return !( x < y ) ; } > > > > > > >template<class T> >inline >bool operator == ( optional<T> const& x, none_t ) >{ return equal_pointees(x, optional<T>() ); } > >template<class T> >inline >bool operator < ( optional<T> const& x, none_t ) >{ return less_pointees(x,optional<T>() ); } > >template<class T> >inline >bool operator != ( optional<T> const& x, none_t y ) >{ return !( x == y ) ; } > >template<class T> >inline >bool operator > ( optional<T> const& x, none_t y ) >{ return y < x ; } > >template<class T> >inline >bool operator <= ( optional<T> const& x, none_t y ) >{ return !( y < x ) ; } > >template<class T> >inline >bool operator >= ( optional<T> const& x, none_t y ) >{ return !( x < y ) ; } > > > > > >template<class T> >inline >bool operator == ( none_t , optional<T> const& y ) >{ return equal_pointees(optional<T>() ,y); } > >template<class T> >inline >bool operator < ( none_t , optional<T> const& y ) >{ return less_pointees(optional<T>() ,y); } > >template<class T> >inline >bool operator != ( none_t x, optional<T> const& y ) >{ return !( x == y ) ; } > >template<class T> >inline >bool operator > ( none_t x, optional<T> const& y ) >{ return y < x ; } > >template<class T> >inline >bool operator <= ( none_t x, optional<T> const& y ) >{ return !( y < x ) ; } > >template<class T> >inline >bool operator >= ( none_t x, optional<T> const& y ) >{ return !( x < y ) ; } > >namespace optional_detail { > >template<bool use_default_constructor> struct swap_selector; > >template<> >struct swap_selector<true> >{ > template<class T> > static void optional_swap ( optional<T>& x, optional<T>& y ) > { > const bool hasX = !!x; > const bool hasY = !!y; > > if ( !hasX && !hasY ) > return; > > if( !hasX ) > x = boost::in_place(); > else if ( !hasY ) > y = boost::in_place(); > > > boost::swap(x.get(),y.get()); > > if( !hasX ) > y = boost::none ; > else if( !hasY ) > x = boost::none ; > } >}; > >template<> >struct swap_selector<false> >{ > template<class T> > static void optional_swap ( optional<T>& x, optional<T>& y ) > { > const bool hasX = !!x; > const bool hasY = !!y; > > if ( !hasX && hasY ) > { > x = y.get(); > y = boost::none ; > } > else if ( hasX && !hasY ) > { > y = x.get(); > x = boost::none ; > } > else if ( hasX && hasY ) > { > > boost::swap(x.get(),y.get()); > } > } >}; > >} > >template<class T> >struct optional_swap_should_use_default_constructor : has_nothrow_default_constructor<T> {} ; > >template<class T> inline void swap ( optional<T>& x, optional<T>& y ) >{ > optional_detail::swap_selector<optional_swap_should_use_default_constructor<T>::value>::optional_swap(x, y); >} > >} ># 16 "/usr/include/boost/optional.hpp" 2 3 4 ># 19 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 20 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 ># 35 "/usr/include/boost/thread/pthread/thread_data.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 36 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 > >namespace boost >{ > class thread_attributes { > public: > thread_attributes() noexcept { > int res = pthread_attr_init(&val_); > ((void)(!res && "pthread_attr_init failed")); > } > ~thread_attributes() { > int res = pthread_attr_destroy(&val_); > ((void)(!res && "pthread_attr_destroy failed")); > } > > void set_stack_size(std::size_t size) noexcept { > if (size==0) return; > std::size_t page_size = getpagesize(); > > if (size<16384) size=16384; > > size = ((size+page_size-1)/page_size)*page_size; > int res = pthread_attr_setstacksize(&val_, size); > ((void)(!res && "pthread_attr_setstacksize failed")); > } > > std::size_t get_stack_size() const noexcept { > std::size_t size; > int res = pthread_attr_getstacksize(&val_, &size); > ((void)(!res && "pthread_attr_getstacksize failed")); > return size; > } > > > typedef pthread_attr_t native_handle_type; > native_handle_type* native_handle() noexcept { > return &val_; > } > const native_handle_type* native_handle() const noexcept { > return &val_; > } > > private: > pthread_attr_t val_; > }; > > class thread; > > namespace detail > { > struct shared_state_base; > struct tss_cleanup_function; > struct thread_exit_callback_node; > struct tss_data_node > { > boost::shared_ptr<boost::detail::tss_cleanup_function> func; > void* value; > > tss_data_node(boost::shared_ptr<boost::detail::tss_cleanup_function> func_, > void* value_): > func(func_),value(value_) > {} > }; > > struct thread_data_base; > typedef boost::shared_ptr<thread_data_base> thread_data_ptr; > > struct __attribute__((__visibility__("default"))) thread_data_base: > enable_shared_from_this<thread_data_base> > { > thread_data_ptr self; > pthread_t thread_handle; > boost::mutex data_mutex; > boost::condition_variable done_condition; > boost::mutex sleep_mutex; > boost::condition_variable sleep_condition; > bool done; > bool join_started; > bool joined; > boost::detail::thread_exit_callback_node* thread_exit_callbacks; > std::map<void const*,boost::detail::tss_data_node> tss_data; > > pthread_mutex_t* cond_mutex; > pthread_cond_t* current_cond; > typedef std::vector<std::pair<condition_variable*, mutex*> > > > notify_list_t; > notify_list_t notify; > > typedef std::vector<shared_ptr<shared_state_base> > async_states_t; > async_states_t async_states_; > > > > > > bool interrupt_enabled; > bool interrupt_requested; > > thread_data_base(): > thread_handle(0), > done(false),join_started(false),joined(false), > thread_exit_callbacks(0), > cond_mutex(0), > current_cond(0), > notify(), > async_states_() > > , interrupt_enabled(true) > , interrupt_requested(false) > > {} > virtual ~thread_data_base(); > > typedef pthread_t native_handle_type; > > virtual void run()=0; > virtual void notify_all_at_thread_exit(condition_variable* cv, mutex* m) > { > notify.push_back(std::pair<condition_variable*, mutex*>(cv, m)); > } > > void make_ready_at_thread_exit(shared_ptr<shared_state_base> as) > { > async_states_.push_back(as); > } > > }; > > __attribute__((__visibility__("default"))) thread_data_base* get_current_thread_data(); > > > class interruption_checker > { > thread_data_base* const thread_info; > pthread_mutex_t* m; > bool set; > > void check_for_interruption() > { > > if(thread_info->interrupt_requested) > { > thread_info->interrupt_requested=false; > throw thread_interrupted(); > } > > } > > void operator=(interruption_checker&); > public: > explicit interruption_checker(pthread_mutex_t* cond_mutex,pthread_cond_t* cond): > thread_info(detail::get_current_thread_data()),m(cond_mutex), > set(thread_info && thread_info->interrupt_enabled) > { > if(set) > { > lock_guard<mutex> guard(thread_info->data_mutex); > check_for_interruption(); > thread_info->cond_mutex=cond_mutex; > thread_info->current_cond=cond; > ((void)(!pthread_mutex_lock(m))); > } > else > { > ((void)(!pthread_mutex_lock(m))); > } > } > ~interruption_checker() > { > if(set) > { > ((void)(!pthread_mutex_unlock(m))); > lock_guard<mutex> guard(thread_info->data_mutex); > thread_info->cond_mutex=__null; > thread_info->current_cond=__null; > } > else > { > ((void)(!pthread_mutex_unlock(m))); > } > } > }; > > } > > namespace this_thread > { > namespace hiden > { > void __attribute__((__visibility__("default"))) sleep_for(const timespec& ts); > void __attribute__((__visibility__("default"))) sleep_until(const timespec& ts); > } > > > > > inline > void __attribute__((__visibility__("default"))) sleep_for(const chrono::nanoseconds& ns) > { > return boost::this_thread::hiden::sleep_for(boost::detail::to_timespec(ns)); > } > > > > void __attribute__((__visibility__("default"))) yield() noexcept; > > > > > > > inline void sleep(system_time const& abs_time) > { > return boost::this_thread::hiden::sleep_until(boost::detail::to_timespec(abs_time)); > } > > template<typename TimeDuration> > inline __attribute__((__visibility__("default"))) void sleep(TimeDuration const& rel_time) > { > this_thread::sleep(get_system_time()+rel_time); > } > > } >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 262 "/usr/include/boost/thread/pthread/thread_data.hpp" 2 3 4 ># 18 "/usr/include/boost/thread/thread_only.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/thread/detail/thread.hpp" 1 3 4 ># 20 "/usr/include/boost/thread/detail/thread.hpp" 3 4 ># 1 "/usr/include/boost/thread/detail/thread_heap_alloc.hpp" 1 3 4 ># 17 "/usr/include/boost/thread/detail/thread_heap_alloc.hpp" 3 4 ># 1 "/usr/include/boost/thread/pthread/thread_heap_alloc.hpp" 1 3 4 > > > > > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 9 "/usr/include/boost/thread/pthread/thread_heap_alloc.hpp" 2 3 4 > >namespace boost >{ > namespace detail > { > template<typename T> > inline T* heap_new() > { > return new T(); > } > > > template<typename T,typename A1> > inline T* heap_new(A1&& a1) > { > return new T(static_cast<A1&&>(a1)); > } > template<typename T,typename A1,typename A2> > inline T* heap_new(A1&& a1,A2&& a2) > { > return new T(static_cast<A1&&>(a1),static_cast<A2&&>(a2)); > } > template<typename T,typename A1,typename A2,typename A3> > inline T* heap_new(A1&& a1,A2&& a2,A3&& a3) > { > return new T(static_cast<A1&&>(a1),static_cast<A2&&>(a2), > static_cast<A3&&>(a3)); > } > template<typename T,typename A1,typename A2,typename A3,typename A4> > inline T* heap_new(A1&& a1,A2&& a2,A3&& a3,A4&& a4) > { > return new T(static_cast<A1&&>(a1),static_cast<A2&&>(a2), > static_cast<A3&&>(a3),static_cast<A4&&>(a4)); > } ># 223 "/usr/include/boost/thread/pthread/thread_heap_alloc.hpp" 3 4 > template<typename T> > inline void heap_delete(T* data) > { > delete data; > } > > template<typename T> > struct do_heap_delete > { > void operator()(T* data) const > { > detail::heap_delete(data); > } > }; > } >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 241 "/usr/include/boost/thread/pthread/thread_heap_alloc.hpp" 2 3 4 ># 18 "/usr/include/boost/thread/detail/thread_heap_alloc.hpp" 2 3 4 ># 21 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/detail/make_tuple_indices.hpp" 1 3 4 ># 27 "/usr/include/boost/thread/detail/make_tuple_indices.hpp" 3 4 >namespace boost >{ > namespace detail > { > > > > > template <std::size_t...> struct tuple_indices > {}; > > template <std::size_t Sp, class IntTuple, std::size_t Ep> > struct make_indices_imp; > > template <std::size_t Sp, std::size_t ...Indices, std::size_t Ep> > struct make_indices_imp<Sp, tuple_indices<Indices...>, Ep> > { > typedef typename make_indices_imp<Sp+1, tuple_indices<Indices..., Sp>, Ep>::type type; > }; > > template <std::size_t Ep, std::size_t ...Indices> > struct make_indices_imp<Ep, tuple_indices<Indices...>, Ep> > { > typedef tuple_indices<Indices...> type; > }; > > template <std::size_t Ep, std::size_t Sp = 0> > struct make_tuple_indices > { > static_assert(Sp <= Ep, "make_tuple_indices input error"); > typedef typename make_indices_imp<Sp, tuple_indices<>, Ep>::type type; > }; ># 221 "/usr/include/boost/thread/detail/make_tuple_indices.hpp" 3 4 > } >} ># 22 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/detail/invoke.hpp" 1 3 4 ># 37 "/usr/include/boost/thread/detail/invoke.hpp" 3 4 >namespace boost >{ > namespace detail > { ># 54 "/usr/include/boost/thread/detail/invoke.hpp" 3 4 > template <class Fp, class A0, class ...Args> > inline auto > invoke(Fp && f, A0 && a0, Args && ...args) > -> decltype((boost::forward<A0>(a0).*f)(boost::forward<Args>(args)...)) > { > return (boost::forward<A0>(a0).*f)(boost::forward<Args>(args)...); > } > > template <class Fp, class A0, class ...Args> > inline auto > invoke(Fp && f, A0 && a0, Args && ...args) > -> decltype(((*boost::forward<A0>(a0)).*f)(boost::forward<Args>(args)...)) > { > return ((*boost::forward<A0>(a0)).*f)(boost::forward<Args>(args)...); > } > > > > template <class Fp, class A0> > inline auto > invoke(Fp && f, A0 && a0) > -> decltype(boost::forward<A0>(a0).*f) > { > return boost::forward<A0>(a0).*f; > } > > template <class Fp, class A0> > inline auto > invoke(Fp && f, A0 && a0) > -> decltype((*boost::forward<A0>(a0)).*f) > { > return (*boost::forward<A0>(a0)).*f; > } > > > > template <class Fp, class ...Args> > inline auto invoke(Fp && f, Args && ...args) > -> decltype(boost::forward<Fp>(f)(boost::forward<Args>(args)...)) > { > return boost::forward<Fp>(f)(boost::forward<Args>(args)...); > } ># 1348 "/usr/include/boost/thread/detail/invoke.hpp" 3 4 > } > } ># 23 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/detail/is_convertible.hpp" 1 3 4 ># 18 "/usr/include/boost/thread/detail/is_convertible.hpp" 3 4 >namespace boost >{ > namespace thread_detail > { > template <typename T1, typename T2> > struct is_convertible : boost::is_convertible<T1,T2> {}; ># 44 "/usr/include/boost/thread/detail/is_convertible.hpp" 3 4 > } > >} ># 24 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 25 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 > > ># 1 "/usr/include/boost/ref.hpp" 1 3 4 ># 29 "/usr/include/boost/ref.hpp" 3 4 >namespace boost >{ > >template<class T> class reference_wrapper >{ >public: > typedef T type; > > > > > > > > explicit reference_wrapper(T& t): t_(boost::addressof(t)) {} > > > > operator T& () const { return *t_; } > > T& get() const { return *t_; } > > T* get_pointer() const { return t_; } > >private: > > T* t_; >}; > > > > > > > >template<class T> inline reference_wrapper<T> const ref(T & t) >{ > return reference_wrapper<T>(t); >} > >template<class T> inline reference_wrapper<T const> const cref(T const & t) >{ > return reference_wrapper<T const>(t); >} > > > > > >template<typename T> >class is_reference_wrapper > : public mpl::false_ >{ >}; > >template<typename T> >class unwrap_reference >{ > public: > typedef T type; >}; ># 106 "/usr/include/boost/ref.hpp" 3 4 >template<typename T> class is_reference_wrapper< reference_wrapper<T> > : public mpl::true_ { }; template<typename T> class unwrap_reference< reference_wrapper<T> > { public: typedef T type; }; > >template<typename T> class is_reference_wrapper< reference_wrapper<T> const > : public mpl::true_ { }; template<typename T> class unwrap_reference< reference_wrapper<T> const > { public: typedef T type; }; >template<typename T> class is_reference_wrapper< reference_wrapper<T> volatile > : public mpl::true_ { }; template<typename T> class unwrap_reference< reference_wrapper<T> volatile > { public: typedef T type; }; >template<typename T> class is_reference_wrapper< reference_wrapper<T> const volatile > : public mpl::true_ { }; template<typename T> class unwrap_reference< reference_wrapper<T> const volatile > { public: typedef T type; }; ># 176 "/usr/include/boost/ref.hpp" 3 4 >template <class T> inline typename unwrap_reference<T>::type& >unwrap_ref(T& t) >{ > return t; >} > >template<class T> inline T* get_pointer( reference_wrapper<T> const & r ) >{ > return r.get_pointer(); >} > >} ># 28 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 29 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/bind.hpp" 1 3 4 ># 22 "/usr/include/boost/bind.hpp" 3 4 ># 1 "/usr/include/boost/bind/bind.hpp" 1 3 4 ># 26 "/usr/include/boost/bind/bind.hpp" 3 4 ># 1 "/usr/include/boost/mem_fn.hpp" 1 3 4 ># 22 "/usr/include/boost/mem_fn.hpp" 3 4 ># 1 "/usr/include/boost/bind/mem_fn.hpp" 1 3 4 ># 25 "/usr/include/boost/bind/mem_fn.hpp" 3 4 ># 1 "/usr/include/boost/get_pointer.hpp" 1 3 4 ># 16 "/usr/include/boost/get_pointer.hpp" 3 4 >namespace boost { > > > >template<class T> T * get_pointer(T * p) >{ > return p; >} > > > >template<class T> T * get_pointer(std::auto_ptr<T> const& p) >{ > return p.get(); >} > > > >template<class T> T * get_pointer( std::unique_ptr<T> const& p ) >{ > return p.get(); >} > >template<class T> T * get_pointer( std::shared_ptr<T> const& p ) >{ > return p.get(); >} > > > >} ># 26 "/usr/include/boost/bind/mem_fn.hpp" 2 3 4 > > >namespace boost >{ ># 207 "/usr/include/boost/bind/mem_fn.hpp" 3 4 >namespace _mfi >{ > > > > > > ># 1 "/usr/include/boost/bind/mem_fn_template.hpp" 1 3 4 ># 21 "/usr/include/boost/bind/mem_fn_template.hpp" 3 4 >template<class R, class T > class mf0 >{ >public: > > typedef R result_type; > typedef T * argument_type; > >private: > > typedef R ( T::*F) (); > F f_; > > template<class U> R call(U & u, T const *) const > { > return (u.*f_)(); > } > > template<class U> R call(U & u, void const *) const > { > return (get_pointer(u)->*f_)(); > } > >public: > > explicit mf0(F f): f_(f) {} > > R operator()(T * p) const > { > return (p->*f_)(); > } > > template<class U> R operator()(U & u) const > { > U const * p = 0; > return call(u, p); > } > > > > template<class U> R operator()(U const & u) const > { > U const * p = 0; > return call(u, p); > } > > > > R operator()(T & t) const > { > return (t.*f_)(); > } > > bool operator==(mf0 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(mf0 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T > class cmf0 >{ >public: > > typedef R result_type; > typedef T const * argument_type; > >private: > > typedef R ( T::*F) () const; > F f_; > > template<class U> R call(U & u, T const *) const > { > return (u.*f_)(); > } > > template<class U> R call(U & u, void const *) const > { > return (get_pointer(u)->*f_)(); > } > >public: > > explicit cmf0(F f): f_(f) {} > > template<class U> R operator()(U const & u) const > { > U const * p = 0; > return call(u, p); > } > > R operator()(T const & t) const > { > return (t.*f_)(); > } > > bool operator==(cmf0 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(cmf0 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1 > class mf1 >{ >public: > > typedef R result_type; > typedef T * first_argument_type; > typedef A1 second_argument_type; > >private: > > typedef R ( T::*F) (A1); > F f_; > > template<class U, class B1> R call(U & u, T const *, B1 & b1) const > { > return (u.*f_)(b1); > } > > template<class U, class B1> R call(U & u, void const *, B1 & b1) const > { > return (get_pointer(u)->*f_)(b1); > } > >public: > > explicit mf1(F f): f_(f) {} > > R operator()(T * p, A1 a1) const > { > return (p->*f_)(a1); > } > > template<class U> R operator()(U & u, A1 a1) const > { > U const * p = 0; > return call(u, p, a1); > } > > > > template<class U> R operator()(U const & u, A1 a1) const > { > U const * p = 0; > return call(u, p, a1); > } > > > > R operator()(T & t, A1 a1) const > { > return (t.*f_)(a1); > } > > bool operator==(mf1 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(mf1 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1 > class cmf1 >{ >public: > > typedef R result_type; > typedef T const * first_argument_type; > typedef A1 second_argument_type; > >private: > > typedef R ( T::*F) (A1) const; > F f_; > > template<class U, class B1> R call(U & u, T const *, B1 & b1) const > { > return (u.*f_)(b1); > } > > template<class U, class B1> R call(U & u, void const *, B1 & b1) const > { > return (get_pointer(u)->*f_)(b1); > } > >public: > > explicit cmf1(F f): f_(f) {} > > template<class U> R operator()(U const & u, A1 a1) const > { > U const * p = 0; > return call(u, p, a1); > } > > R operator()(T const & t, A1 a1) const > { > return (t.*f_)(a1); > } > > bool operator==(cmf1 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(cmf1 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2 > class mf2 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2); > F f_; > > template<class U, class B1, class B2> R call(U & u, T const *, B1 & b1, B2 & b2) const > { > return (u.*f_)(b1, b2); > } > > template<class U, class B1, class B2> R call(U & u, void const *, B1 & b1, B2 & b2) const > { > return (get_pointer(u)->*f_)(b1, b2); > } > >public: > > explicit mf2(F f): f_(f) {} > > R operator()(T * p, A1 a1, A2 a2) const > { > return (p->*f_)(a1, a2); > } > > template<class U> R operator()(U & u, A1 a1, A2 a2) const > { > U const * p = 0; > return call(u, p, a1, a2); > } > > > > template<class U> R operator()(U const & u, A1 a1, A2 a2) const > { > U const * p = 0; > return call(u, p, a1, a2); > } > > > > R operator()(T & t, A1 a1, A2 a2) const > { > return (t.*f_)(a1, a2); > } > > bool operator==(mf2 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(mf2 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2 > class cmf2 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2) const; > F f_; > > template<class U, class B1, class B2> R call(U & u, T const *, B1 & b1, B2 & b2) const > { > return (u.*f_)(b1, b2); > } > > template<class U, class B1, class B2> R call(U & u, void const *, B1 & b1, B2 & b2) const > { > return (get_pointer(u)->*f_)(b1, b2); > } > >public: > > explicit cmf2(F f): f_(f) {} > > template<class U> R operator()(U const & u, A1 a1, A2 a2) const > { > U const * p = 0; > return call(u, p, a1, a2); > } > > R operator()(T const & t, A1 a1, A2 a2) const > { > return (t.*f_)(a1, a2); > } > > bool operator==(cmf2 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(cmf2 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3 > class mf3 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3); > F f_; > > template<class U, class B1, class B2, class B3> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3) const > { > return (u.*f_)(b1, b2, b3); > } > > template<class U, class B1, class B2, class B3> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3) const > { > return (get_pointer(u)->*f_)(b1, b2, b3); > } > >public: > > explicit mf3(F f): f_(f) {} > > R operator()(T * p, A1 a1, A2 a2, A3 a3) const > { > return (p->*f_)(a1, a2, a3); > } > > template<class U> R operator()(U & u, A1 a1, A2 a2, A3 a3) const > { > U const * p = 0; > return call(u, p, a1, a2, a3); > } > > > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3) const > { > U const * p = 0; > return call(u, p, a1, a2, a3); > } > > > > R operator()(T & t, A1 a1, A2 a2, A3 a3) const > { > return (t.*f_)(a1, a2, a3); > } > > bool operator==(mf3 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(mf3 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3 > class cmf3 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3) const; > F f_; > > template<class U, class B1, class B2, class B3> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3) const > { > return (u.*f_)(b1, b2, b3); > } > > template<class U, class B1, class B2, class B3> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3) const > { > return (get_pointer(u)->*f_)(b1, b2, b3); > } > >public: > > explicit cmf3(F f): f_(f) {} > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3) const > { > U const * p = 0; > return call(u, p, a1, a2, a3); > } > > R operator()(T const & t, A1 a1, A2 a2, A3 a3) const > { > return (t.*f_)(a1, a2, a3); > } > > bool operator==(cmf3 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(cmf3 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4 > class mf4 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4); > F f_; > > template<class U, class B1, class B2, class B3, class B4> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4) const > { > return (u.*f_)(b1, b2, b3, b4); > } > > template<class U, class B1, class B2, class B3, class B4> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4); > } > >public: > > explicit mf4(F f): f_(f) {} > > R operator()(T * p, A1 a1, A2 a2, A3 a3, A4 a4) const > { > return (p->*f_)(a1, a2, a3, a4); > } > > template<class U> R operator()(U & u, A1 a1, A2 a2, A3 a3, A4 a4) const > { > U const * p = 0; > return call(u, p, a1, a2, a3, a4); > } > > > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4) const > { > U const * p = 0; > return call(u, p, a1, a2, a3, a4); > } > > > > R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4) const > { > return (t.*f_)(a1, a2, a3, a4); > } > > bool operator==(mf4 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(mf4 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4 > class cmf4 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4) const; > F f_; > > template<class U, class B1, class B2, class B3, class B4> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4) const > { > return (u.*f_)(b1, b2, b3, b4); > } > > template<class U, class B1, class B2, class B3, class B4> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4); > } > >public: > > explicit cmf4(F f): f_(f) {} > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4) const > { > U const * p = 0; > return call(u, p, a1, a2, a3, a4); > } > > R operator()(T const & t, A1 a1, A2 a2, A3 a3, A4 a4) const > { > return (t.*f_)(a1, a2, a3, a4); > } > > bool operator==(cmf4 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(cmf4 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4, class A5 > class mf5 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4, A5); > F f_; > > template<class U, class B1, class B2, class B3, class B4, class B5> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5) const > { > return (u.*f_)(b1, b2, b3, b4, b5); > } > > template<class U, class B1, class B2, class B3, class B4, class B5> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4, b5); > } > >public: > > explicit mf5(F f): f_(f) {} > > R operator()(T * p, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const > { > return (p->*f_)(a1, a2, a3, a4, a5); > } > > template<class U> R operator()(U & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const > { > U const * p = 0; > return call(u, p, a1, a2, a3, a4, a5); > } > > > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const > { > U const * p = 0; > return call(u, p, a1, a2, a3, a4, a5); > } > > > > R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const > { > return (t.*f_)(a1, a2, a3, a4, a5); > } > > bool operator==(mf5 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(mf5 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4, class A5 > class cmf5 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4, A5) const; > F f_; > > template<class U, class B1, class B2, class B3, class B4, class B5> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5) const > { > return (u.*f_)(b1, b2, b3, b4, b5); > } > > template<class U, class B1, class B2, class B3, class B4, class B5> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4, b5); > } > >public: > > explicit cmf5(F f): f_(f) {} > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) const > { > U const * p = 0; > 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 > { > return (t.*f_)(a1, a2, a3, a4, a5); > } > > bool operator==(cmf5 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(cmf5 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6 > class mf6 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4, A5, A6); > F f_; > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6) const > { > return (u.*f_)(b1, b2, b3, b4, b5, b6); > } > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6); > } > >public: > > explicit mf6(F f): f_(f) {} > > R operator()(T * p, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const > { > return (p->*f_)(a1, a2, a3, a4, a5, a6); > } > > template<class U> R operator()(U & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const > { > U const * p = 0; > return call(u, p, a1, a2, a3, a4, a5, a6); > } > > > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const > { > U const * p = 0; > return call(u, p, a1, a2, a3, a4, a5, a6); > } > > > > R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const > { > return (t.*f_)(a1, a2, a3, a4, a5, a6); > } > > bool operator==(mf6 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(mf6 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6 > class cmf6 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4, A5, A6) const; > F f_; > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6) const > { > return (u.*f_)(b1, b2, b3, b4, b5, b6); > } > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6); > } > >public: > > explicit cmf6(F f): f_(f) {} > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) const > { > U const * p = 0; > 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 > { > return (t.*f_)(a1, a2, a3, a4, a5, a6); > } > > bool operator==(cmf6 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(cmf6 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7 > class mf7 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4, A5, A6, A7); > F f_; > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6, class B7> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7) const > { > return (u.*f_)(b1, b2, b3, b4, b5, b6, b7); > } > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6, class B7> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6, b7); > } > >public: > > explicit mf7(F f): f_(f) {} > > R operator()(T * p, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const > { > return (p->*f_)(a1, a2, a3, a4, a5, a6, a7); > } > > template<class U> R operator()(U & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const > { > U const * p = 0; > return call(u, p, a1, a2, a3, a4, a5, a6, a7); > } > > > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const > { > U const * p = 0; > return call(u, p, a1, a2, a3, a4, a5, a6, a7); > } > > > > R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const > { > return (t.*f_)(a1, a2, a3, a4, a5, a6, a7); > } > > bool operator==(mf7 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(mf7 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7 > class cmf7 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4, A5, A6, A7) const; > F f_; > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6, class B7> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7) const > { > return (u.*f_)(b1, b2, b3, b4, b5, b6, b7); > } > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6, class B7> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6, b7); > } > >public: > > explicit cmf7(F f): f_(f) {} > > template<class U> R operator()(U const & u, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) const > { > U const * p = 0; > 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 > { > return (t.*f_)(a1, a2, a3, a4, a5, a6, a7); > } > > bool operator==(cmf7 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(cmf7 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8 > class mf8 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4, A5, A6, A7, A8); > F f_; > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7, B8 & b8) const > { > return (u.*f_)(b1, b2, b3, b4, b5, b6, b7, b8); > } > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7, B8 & b8) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6, b7, b8); > } > >public: > > explicit 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 > { > return (p->*f_)(a1, a2, a3, a4, a5, a6, a7, a8); > } > > template<class U> 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; > return call(u, p, a1, a2, a3, a4, a5, a6, a7, a8); > } > > > > template<class U> 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; > return call(u, p, a1, a2, a3, a4, a5, a6, a7, a8); > } > > > > R operator()(T & t, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) const > { > return (t.*f_)(a1, a2, a3, a4, a5, a6, a7, a8); > } > > bool operator==(mf8 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(mf8 const & rhs) const > { > return f_ != rhs.f_; > } >}; > > > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8 > class cmf8 >{ >public: > > typedef R result_type; > >private: > > typedef R ( T::*F) (A1, A2, A3, A4, A5, A6, A7, A8) const; > F f_; > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8> R call(U & u, T const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7, B8 & b8) const > { > return (u.*f_)(b1, b2, b3, b4, b5, b6, b7, b8); > } > > template<class U, class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8> R call(U & u, void const *, B1 & b1, B2 & b2, B3 & b3, B4 & b4, B5 & b5, B6 & b6, B7 & b7, B8 & b8) const > { > return (get_pointer(u)->*f_)(b1, b2, b3, b4, b5, b6, b7, b8); > } > >public: > > explicit 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 > { > return (p->*f_)(a1, a2, a3, a4, a5, a6, a7, a8); > } > > template<class U> 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; > 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 > { > return (t.*f_)(a1, a2, a3, a4, a5, a6, a7, a8); > } > > bool operator==(cmf8 const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(cmf8 const & rhs) const > { > return f_ != rhs.f_; > } >}; ># 216 "/usr/include/boost/bind/mem_fn.hpp" 2 3 4 ># 258 "/usr/include/boost/bind/mem_fn.hpp" 3 4 >} ># 268 "/usr/include/boost/bind/mem_fn.hpp" 3 4 ># 1 "/usr/include/boost/bind/mem_fn_cc.hpp" 1 3 4 ># 15 "/usr/include/boost/bind/mem_fn_cc.hpp" 3 4 >template<class R, class T> _mfi::mf0<R, T> mem_fn(R ( T::*f) ()) >{ > return _mfi::mf0<R, T>(f); >} > >template<class R, class T> _mfi::cmf0<R, T> mem_fn(R ( T::*f) () const) >{ > return _mfi::cmf0<R, T>(f); >} > >template<class R, class T, class A1> _mfi::mf1<R, T, A1> mem_fn(R ( T::*f) (A1)) >{ > return _mfi::mf1<R, T, A1>(f); >} > >template<class R, class T, class A1> _mfi::cmf1<R, T, A1> mem_fn(R ( T::*f) (A1) const) >{ > return _mfi::cmf1<R, T, A1>(f); >} > >template<class R, class T, class A1, class A2> _mfi::mf2<R, T, A1, A2> mem_fn(R ( T::*f) (A1, A2)) >{ > return _mfi::mf2<R, T, A1, A2>(f); >} > >template<class R, class T, class A1, class A2> _mfi::cmf2<R, T, A1, A2> mem_fn(R ( T::*f) (A1, A2) const) >{ > return _mfi::cmf2<R, T, A1, A2>(f); >} > >template<class R, class T, class A1, class A2, class A3> _mfi::mf3<R, T, A1, A2, A3> mem_fn(R ( T::*f) (A1, A2, A3)) >{ > return _mfi::mf3<R, T, A1, A2, A3>(f); >} > >template<class R, class T, class A1, class A2, class A3> _mfi::cmf3<R, T, A1, A2, A3> mem_fn(R ( T::*f) (A1, A2, A3) const) >{ > return _mfi::cmf3<R, T, A1, A2, A3>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4> _mfi::mf4<R, T, A1, A2, A3, A4> mem_fn(R ( T::*f) (A1, A2, A3, A4)) >{ > return _mfi::mf4<R, T, A1, A2, A3, A4>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4> _mfi::cmf4<R, T, A1, A2, A3, A4> mem_fn(R ( T::*f) (A1, A2, A3, A4) const) >{ > return _mfi::cmf4<R, T, A1, A2, A3, A4>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4, class A5> _mfi::mf5<R, T, A1, A2, A3, A4, A5> mem_fn(R ( T::*f) (A1, A2, A3, A4, A5)) >{ > return _mfi::mf5<R, T, A1, A2, A3, A4, A5>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4, class A5> _mfi::cmf5<R, T, A1, A2, A3, A4, A5> mem_fn(R ( T::*f) (A1, A2, A3, A4, A5) const) >{ > return _mfi::cmf5<R, T, A1, A2, A3, A4, A5>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6> _mfi::mf6<R, T, A1, A2, A3, A4, A5, A6> mem_fn(R ( T::*f) (A1, A2, A3, A4, A5, A6)) >{ > return _mfi::mf6<R, T, A1, A2, A3, A4, A5, A6>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6> _mfi::cmf6<R, T, A1, A2, A3, A4, A5, A6> mem_fn(R ( T::*f) (A1, A2, A3, A4, A5, A6) const) >{ > return _mfi::cmf6<R, T, A1, A2, A3, A4, A5, A6>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7> _mfi::mf7<R, T, A1, A2, A3, A4, A5, A6, A7> mem_fn(R ( T::*f) (A1, A2, A3, A4, A5, A6, A7)) >{ > return _mfi::mf7<R, T, A1, A2, A3, A4, A5, A6, A7>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7> _mfi::cmf7<R, T, A1, A2, A3, A4, A5, A6, A7> mem_fn(R ( T::*f) (A1, A2, A3, A4, A5, A6, A7) const) >{ > return _mfi::cmf7<R, T, A1, A2, A3, A4, A5, A6, A7>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> _mfi::mf8<R, T, A1, A2, A3, A4, A5, A6, A7, A8> mem_fn(R ( T::*f) (A1, A2, A3, A4, A5, A6, A7, A8)) >{ > return _mfi::mf8<R, T, A1, A2, A3, A4, A5, A6, A7, A8>(f); >} > >template<class R, class T, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> _mfi::cmf8<R, T, A1, A2, A3, A4, A5, A6, A7, A8> mem_fn(R ( T::*f) (A1, A2, A3, A4, A5, A6, A7, A8) const) >{ > return _mfi::cmf8<R, T, A1, A2, A3, A4, A5, A6, A7, A8>(f); >} ># 269 "/usr/include/boost/bind/mem_fn.hpp" 2 3 4 ># 311 "/usr/include/boost/bind/mem_fn.hpp" 3 4 >namespace _mfi >{ > >template<class R, class T> class dm >{ >public: > > typedef R const & result_type; > typedef T const * argument_type; > >private: > > typedef R (T::*F); > F f_; > > template<class U> R const & call(U & u, T const *) const > { > return (u.*f_); > } > > template<class U> 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<class U> R const & operator()(U const & u) const > { > return call(u, &u); > } > > > > R & operator()(T & t) const > { > return (t.*f_); > } > > R const & operator()(T const & t) const > { > return (t.*f_); > } > > > > bool operator==(dm const & rhs) const > { > return f_ == rhs.f_; > } > > bool operator!=(dm const & rhs) const > { > return f_ != rhs.f_; > } >}; > >} > >template<class R, class T> _mfi::dm<R, T> mem_fn(R T::*f) >{ > return _mfi::dm<R, T>(f); >} > >} ># 23 "/usr/include/boost/mem_fn.hpp" 2 3 4 ># 27 "/usr/include/boost/bind/bind.hpp" 2 3 4 > ># 1 "/usr/include/boost/is_placeholder.hpp" 1 3 4 ># 21 "/usr/include/boost/is_placeholder.hpp" 3 4 >namespace boost >{ > >template< class T > struct is_placeholder >{ > enum _vt { value = 0 }; >}; > >} ># 29 "/usr/include/boost/bind/bind.hpp" 2 3 4 ># 1 "/usr/include/boost/bind/arg.hpp" 1 3 4 ># 25 "/usr/include/boost/bind/arg.hpp" 3 4 >namespace boost >{ > >template< int I > struct arg >{ > arg() > { > } > > template< class T > arg( T const & ) > { > > typedef char T_must_be_placeholder[ I == is_placeholder<T>::value? 1: -1 ]; > } >}; > >template< int I > bool operator==( arg<I> const &, arg<I> const & ) >{ > return true; >} > > > >template< int I > struct is_placeholder< arg<I> > >{ > enum _vt { value = I }; >}; > >template< int I > struct is_placeholder< arg<I> (*) () > >{ > enum _vt { value = I }; >}; > > > >} ># 30 "/usr/include/boost/bind/bind.hpp" 2 3 4 > ># 1 "/usr/include/boost/visit_each.hpp" 1 3 4 ># 15 "/usr/include/boost/visit_each.hpp" 3 4 >namespace boost { > template<typename Visitor, typename T> > inline void visit_each(Visitor& visitor, const T& t, long) > { > visitor(t); > } > > template<typename Visitor, typename T> > inline void visit_each(Visitor& visitor, const T& t) > { > visit_each(visitor, t, 0); > } >} ># 32 "/usr/include/boost/bind/bind.hpp" 2 3 4 ># 41 "/usr/include/boost/bind/bind.hpp" 3 4 ># 1 "/usr/include/boost/bind/storage.hpp" 1 3 4 ># 32 "/usr/include/boost/bind/storage.hpp" 3 4 >namespace boost >{ > >namespace _bi >{ > > > >template<class A1> struct storage1 >{ > explicit storage1( A1 a1 ): a1_( a1 ) {} > > template<class V> void accept(V & v) const > { > visit_each(v, a1_, 0); > } > > A1 a1_; >}; > > > >template<int I> struct storage1< boost::arg<I> > >{ > explicit storage1( boost::arg<I> ) {} > > template<class V> void accept(V &) const { } > > static boost::arg<I> a1_() { return boost::arg<I>(); } >}; > >template<int I> struct storage1< boost::arg<I> (*) () > >{ > explicit storage1( boost::arg<I> (*) () ) {} > > template<class V> void accept(V &) const { } > > static boost::arg<I> a1_() { return boost::arg<I>(); } >}; > > > > > >template<class A1, class A2> struct storage2: public storage1<A1> >{ > typedef storage1<A1> inherited; > > storage2( A1 a1, A2 a2 ): storage1<A1>( a1 ), a2_( a2 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > visit_each(v, a2_, 0); > } > > A2 a2_; >}; > > > >template<class A1, int I> struct storage2< A1, boost::arg<I> >: public storage1<A1> >{ > typedef storage1<A1> inherited; > > storage2( A1 a1, boost::arg<I> ): storage1<A1>( a1 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a2_() { return boost::arg<I>(); } >}; > >template<class A1, int I> struct storage2< A1, boost::arg<I> (*) () >: public storage1<A1> >{ > typedef storage1<A1> inherited; > > storage2( A1 a1, boost::arg<I> (*) () ): storage1<A1>( a1 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a2_() { return boost::arg<I>(); } >}; > > > > > >template<class A1, class A2, class A3> struct storage3: public storage2< A1, A2 > >{ > typedef storage2<A1, A2> inherited; > > storage3( A1 a1, A2 a2, A3 a3 ): storage2<A1, A2>( a1, a2 ), a3_( a3 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > visit_each(v, a3_, 0); > } > > A3 a3_; >}; > > > >template<class A1, class A2, int I> struct storage3< A1, A2, boost::arg<I> >: public storage2< A1, A2 > >{ > typedef storage2<A1, A2> inherited; > > storage3( A1 a1, A2 a2, boost::arg<I> ): storage2<A1, A2>( a1, a2 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a3_() { return boost::arg<I>(); } >}; > >template<class A1, class A2, int I> struct storage3< A1, A2, boost::arg<I> (*) () >: public storage2< A1, A2 > >{ > typedef storage2<A1, A2> inherited; > > storage3( A1 a1, A2 a2, boost::arg<I> (*) () ): storage2<A1, A2>( a1, a2 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a3_() { return boost::arg<I>(); } >}; > > > > > >template<class A1, class A2, class A3, class A4> struct storage4: public storage3< A1, A2, A3 > >{ > typedef storage3<A1, A2, A3> inherited; > > storage4( A1 a1, A2 a2, A3 a3, A4 a4 ): storage3<A1, A2, A3>( a1, a2, a3 ), a4_( a4 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > visit_each(v, a4_, 0); > } > > A4 a4_; >}; > > > >template<class A1, class A2, class A3, int I> struct storage4< A1, A2, A3, boost::arg<I> >: public storage3< A1, A2, A3 > >{ > typedef storage3<A1, A2, A3> inherited; > > storage4( A1 a1, A2 a2, A3 a3, boost::arg<I> ): storage3<A1, A2, A3>( a1, a2, a3 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a4_() { return boost::arg<I>(); } >}; > >template<class A1, class A2, class A3, int I> struct storage4< A1, A2, A3, boost::arg<I> (*) () >: public storage3< A1, A2, A3 > >{ > typedef storage3<A1, A2, A3> inherited; > > storage4( A1 a1, A2 a2, A3 a3, boost::arg<I> (*) () ): storage3<A1, A2, A3>( a1, a2, a3 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a4_() { return boost::arg<I>(); } >}; > > > > > >template<class A1, class A2, class A3, class A4, class A5> struct storage5: public storage4< A1, A2, A3, A4 > >{ > typedef storage4<A1, A2, A3, A4> inherited; > > storage5( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5 ): storage4<A1, A2, A3, A4>( a1, a2, a3, a4 ), a5_( a5 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > visit_each(v, a5_, 0); > } > > A5 a5_; >}; > > > >template<class A1, class A2, class A3, class A4, int I> struct storage5< A1, A2, A3, A4, boost::arg<I> >: public storage4< A1, A2, A3, A4 > >{ > typedef storage4<A1, A2, A3, A4> inherited; > > storage5( A1 a1, A2 a2, A3 a3, A4 a4, boost::arg<I> ): storage4<A1, A2, A3, A4>( a1, a2, a3, a4 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a5_() { return boost::arg<I>(); } >}; > >template<class A1, class A2, class A3, class A4, int I> struct storage5< A1, A2, A3, A4, boost::arg<I> (*) () >: public storage4< A1, A2, A3, A4 > >{ > typedef storage4<A1, A2, A3, A4> inherited; > > storage5( A1 a1, A2 a2, A3 a3, A4 a4, boost::arg<I> (*) () ): storage4<A1, A2, A3, A4>( a1, a2, a3, a4 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a5_() { return boost::arg<I>(); } >}; > > > > > >template<class A1, class A2, class A3, class A4, class A5, class A6> struct storage6: public storage5< A1, A2, A3, A4, A5 > >{ > typedef storage5<A1, A2, A3, A4, A5> inherited; > > storage6( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6 ): storage5<A1, A2, A3, A4, A5>( a1, a2, a3, a4, a5 ), a6_( a6 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > visit_each(v, a6_, 0); > } > > A6 a6_; >}; > > > >template<class A1, class A2, class A3, class A4, class A5, int I> struct storage6< A1, A2, A3, A4, A5, boost::arg<I> >: public storage5< A1, A2, A3, A4, A5 > >{ > typedef storage5<A1, A2, A3, A4, A5> inherited; > > storage6( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, boost::arg<I> ): storage5<A1, A2, A3, A4, A5>( a1, a2, a3, a4, a5 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a6_() { return boost::arg<I>(); } >}; > >template<class A1, class A2, class A3, class A4, class A5, int I> struct storage6< A1, A2, A3, A4, A5, boost::arg<I> (*) () >: public storage5< A1, A2, A3, A4, A5 > >{ > typedef storage5<A1, A2, A3, A4, A5> inherited; > > storage6( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, boost::arg<I> (*) () ): storage5<A1, A2, A3, A4, A5>( a1, a2, a3, a4, a5 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a6_() { return boost::arg<I>(); } >}; > > > > > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> struct storage7: public storage6< A1, A2, A3, A4, A5, A6 > >{ > typedef storage6<A1, A2, A3, A4, A5, A6> inherited; > > storage7( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7 ): storage6<A1, A2, A3, A4, A5, A6>( a1, a2, a3, a4, a5, a6 ), a7_( a7 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > visit_each(v, a7_, 0); > } > > A7 a7_; >}; > > > >template<class A1, class A2, class A3, class A4, class A5, class A6, int I> struct storage7< A1, A2, A3, A4, A5, A6, boost::arg<I> >: public storage6< A1, A2, A3, A4, A5, A6 > >{ > typedef storage6<A1, A2, A3, A4, A5, A6> inherited; > > storage7( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, boost::arg<I> ): storage6<A1, A2, A3, A4, A5, A6>( a1, a2, a3, a4, a5, a6 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a7_() { return boost::arg<I>(); } >}; > >template<class A1, class A2, class A3, class A4, class A5, class A6, int I> struct storage7< A1, A2, A3, A4, A5, A6, boost::arg<I> (*) () >: public storage6< A1, A2, A3, A4, A5, A6 > >{ > typedef storage6<A1, A2, A3, A4, A5, A6> inherited; > > storage7( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, boost::arg<I> (*) () ): storage6<A1, A2, A3, A4, A5, A6>( a1, a2, a3, a4, a5, a6 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a7_() { return boost::arg<I>(); } >}; > > > > > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> struct storage8: public storage7< A1, A2, A3, A4, A5, A6, A7 > >{ > typedef storage7<A1, A2, A3, A4, A5, A6, A7> 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>( a1, a2, a3, a4, a5, a6, a7 ), a8_( a8 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > visit_each(v, a8_, 0); > } > > A8 a8_; >}; > > > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, int I> struct storage8< A1, A2, A3, A4, A5, A6, A7, boost::arg<I> >: public storage7< A1, A2, A3, A4, A5, A6, A7 > >{ > typedef storage7<A1, A2, A3, A4, A5, A6, A7> inherited; > > storage8( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, boost::arg<I> ): storage7<A1, A2, A3, A4, A5, A6, A7>( a1, a2, a3, a4, a5, a6, a7 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a8_() { return boost::arg<I>(); } >}; > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, int I> struct storage8< A1, A2, A3, A4, A5, A6, A7, boost::arg<I> (*) () >: public storage7< A1, A2, A3, A4, A5, A6, A7 > >{ > typedef storage7<A1, A2, A3, A4, A5, A6, A7> inherited; > > storage8( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, boost::arg<I> (*) () ): storage7<A1, A2, A3, A4, A5, A6, A7>( a1, a2, a3, a4, a5, a6, a7 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a8_() { return boost::arg<I>(); } >}; > > > > > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> struct storage9: public storage8< A1, A2, A3, A4, A5, A6, A7, A8 > >{ > typedef storage8<A1, A2, A3, A4, A5, A6, A7, A8> 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>( a1, a2, a3, a4, a5, a6, a7, a8 ), a9_( a9 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > visit_each(v, a9_, 0); > } > > A9 a9_; >}; > > > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, int I> struct storage9< A1, A2, A3, A4, A5, A6, A7, A8, boost::arg<I> >: public storage8< A1, A2, A3, A4, A5, A6, A7, A8 > >{ > typedef storage8<A1, A2, A3, A4, A5, A6, A7, A8> inherited; > > storage9( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, boost::arg<I> ): storage8<A1, A2, A3, A4, A5, A6, A7, A8>( a1, a2, a3, a4, a5, a6, a7, a8 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a9_() { return boost::arg<I>(); } >}; > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, int I> struct storage9< A1, A2, A3, A4, A5, A6, A7, A8, boost::arg<I> (*) () >: public storage8< A1, A2, A3, A4, A5, A6, A7, A8 > >{ > typedef storage8<A1, A2, A3, A4, A5, A6, A7, A8> inherited; > > storage9( A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, boost::arg<I> (*) () ): storage8<A1, A2, A3, A4, A5, A6, A7, A8>( a1, a2, a3, a4, a5, a6, a7, a8 ) {} > > template<class V> void accept(V & v) const > { > inherited::accept(v); > } > > static boost::arg<I> a9_() { return boost::arg<I>(); } >}; > > > >} > >} ># 42 "/usr/include/boost/bind/bind.hpp" 2 3 4 > > > > > > >namespace boost >{ > >template<class T> class weak_ptr; > >namespace _bi >{ > > > >template<class R, class F> struct result_traits >{ > typedef R type; >}; > > > >struct unspecified {}; > >template<class F> struct result_traits<unspecified, F> >{ > typedef typename F::result_type type; >}; > >template<class F> struct result_traits< unspecified, reference_wrapper<F> > >{ > typedef typename F::result_type type; >}; > > > > > >template<class T> bool ref_compare( T const & a, T const & b, long ) >{ > return a == b; >} > >template<int I> bool ref_compare( arg<I> const &, arg<I> const &, int ) >{ > return true; >} > >template<int I> bool ref_compare( arg<I> (*) (), arg<I> (*) (), int ) >{ > return true; >} > >template<class T> bool ref_compare( reference_wrapper<T> const & a, reference_wrapper<T> const & b, int ) >{ > return a.get_pointer() == b.get_pointer(); >} > > > >template<class R, class F, class L> class bind_t; > >template<class R, class F, class L> bool ref_compare( bind_t<R, F, L> const & a, bind_t<R, F, L> const & b, int ) >{ > return a.compare( b ); >} > > > >template<class T> 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_; >}; > > > >template<class T> bool ref_compare( value< weak_ptr<T> > const & a, value< weak_ptr<T> > const & b, int ) >{ > return !(a.get() < b.get()) && !(b.get() < a.get()); >} > > > >template<class T> class type {}; > > > >template<class F> struct unwrapper >{ > static inline F & unwrap( F & f, long ) > { > return f; > } > > template<class F2> static inline F2 & unwrap( reference_wrapper<F2> rf, int ) > { > return rf.get(); > } > > template<class R, class T> static inline _mfi::dm<R, T> unwrap( R T::* pm, int ) > { > return _mfi::dm<R, T>( pm ); > } >}; > > > >class list0 >{ >public: > > list0() {} > > template<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } > > template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A &, long) > { > return unwrapper<F>::unwrap(f, 0)(); > } > > template<class R, class F, class A> R operator()(type<R>, F const & f, A &, long) const > { > return unwrapper<F const>::unwrap(f, 0)(); > } > > template<class F, class A> void operator()(type<void>, F & f, A &, int) > { > unwrapper<F>::unwrap(f, 0)(); > } > > template<class F, class A> void operator()(type<void>, F const & f, A &, int) const > { > unwrapper<F const>::unwrap(f, 0)(); > } > > template<class V> void accept(V &) const > { > } > > bool operator==(list0 const &) const > { > return true; > } >}; ># 217 "/usr/include/boost/bind/bind.hpp" 3 4 >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<class T> T & operator[] ( _bi::value<T> & v ) const { return v.get(); } > > template<class T> T const & operator[] ( _bi::value<T> const & v ) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) > { > return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_]); > } > > template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const > { > return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_]); > } > > template<class F, class A> void operator()(type<void>, F & f, A & a, int) > { > unwrapper<F>::unwrap(f, 0)(a[base_type::a1_]); > } > > template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const > { > unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_]); > } > > template<class V> 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<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } > > template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) > { > return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); > } > > template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const > { > return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); > } > > template<class F, class A> void operator()(type<void>, F & f, A & a, int) > { > unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); > } > > template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const > { > unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_]); > } > > template<class A> bool operator()( type<bool>, logical_and & , A & a, int ) > { > return a[ base_type::a1_ ] && a[ base_type::a2_ ]; > } > > template<class A> bool operator()( type<bool>, logical_and const & , A & a, int ) const > { > return a[ base_type::a1_ ] && a[ base_type::a2_ ]; > } > > template<class A> bool operator()( type<bool>, logical_or & , A & a, int ) > { > return a[ base_type::a1_ ] || a[ base_type::a2_ ]; > } > > template<class A> bool operator()( type<bool>, logical_or const & , A & a, int ) const > { > return a[ base_type::a1_ ] || a[ base_type::a2_ ]; > } > > template<class V> 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<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } > > template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) > { > return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); > } > > template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const > { > return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); > } > > template<class F, class A> void operator()(type<void>, F & f, A & a, int) > { > unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); > } > > template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const > { > unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_]); > } > > template<class V> 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<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } > > template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) > { > return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); > } > > template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const > { > return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); > } > > template<class F, class A> void operator()(type<void>, F & f, A & a, int) > { > unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); > } > > template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const > { > unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_]); > } > > template<class V> 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<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } > > template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) > { > return unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); > } > > template<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const > { > return unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); > } > > template<class F, class A> void operator()(type<void>, F & f, A & a, int) > { > unwrapper<F>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); > } > > template<class F, class A> void operator()(type<void>, F const & f, A & a, int) const > { > unwrapper<F const>::unwrap(f, 0)(a[base_type::a1_], a[base_type::a2_], a[base_type::a3_], a[base_type::a4_], a[base_type::a5_]); > } > > template<class V> 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 A1, class A2, class A3, class A4, class A5, class A6> 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<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } > > template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) > { > return unwrapper<F>::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<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const > { > return unwrapper<F const>::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<class F, class A> void operator()(type<void>, F & f, A & a, int) > { > unwrapper<F>::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<class F, class A> void operator()(type<void>, F const & f, A & a, int) const > { > unwrapper<F const>::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<class V> 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 A1, class A2, class A3, class A4, class A5, class A6, class A7> 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<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } > > template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) > { > return unwrapper<F>::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<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const > { > return unwrapper<F const>::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<class F, class A> void operator()(type<void>, F & f, A & a, int) > { > unwrapper<F>::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<class F, class A> void operator()(type<void>, F const & f, A & a, int) const > { > unwrapper<F const>::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<class V> 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<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } > > template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) > { > return unwrapper<F>::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<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const > { > return unwrapper<F const>::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<class F, class A> void operator()(type<void>, F & f, A & a, int) > { > unwrapper<F>::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<class F, class A> void operator()(type<void>, F const & f, A & a, int) const > { > unwrapper<F const>::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<class V> 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 A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> 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<class T> T & operator[] (_bi::value<T> & v) const { return v.get(); } > > template<class T> T const & operator[] (_bi::value<T> const & v) const { return v.get(); } > > template<class T> T & operator[] (reference_wrapper<T> const & v) const { return v.get(); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> & b) const { return b.eval(*this); } > > template<class R, class F, class L> typename result_traits<R, F>::type operator[] (bind_t<R, F, L> const & b) const { return b.eval(*this); } > > template<class R, class F, class A> R operator()(type<R>, F & f, A & a, long) > { > return unwrapper<F>::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<class R, class F, class A> R operator()(type<R>, F const & f, A & a, long) const > { > return unwrapper<F const>::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<class F, class A> void operator()(type<void>, F & f, A & a, int) > { > unwrapper<F>::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<class F, class A> void operator()(type<void>, F const & f, A & a, int) const > { > unwrapper<F const>::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<class V> 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 ); > } >}; ># 864 "/usr/include/boost/bind/bind.hpp" 3 4 >template<class R, class F, class L> class bind_t >{ >public: > > typedef bind_t this_type; > > bind_t(F f, L const & l): f_(f), l_(l) {} > > ># 1 "/usr/include/boost/bind/bind_template.hpp" 1 3 4 ># 15 "/usr/include/boost/bind/bind_template.hpp" 3 4 > typedef typename result_traits<R, F>::type result_type; > > result_type operator()() > { > list0 a; > return l_(type<result_type>(), f_, a, 0); > } > > result_type operator()() const > { > list0 a; > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1> result_type operator()(A1 & a1) > { > list1<A1 &> a(a1); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1> result_type operator()(A1 & a1) const > { > list1<A1 &> a(a1); > return l_(type<result_type>(), f_, a, 0); > } > > > > > template<class A1> result_type operator()(A1 const & a1) > { > list1<A1 const &> a(a1); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1> result_type operator()(A1 const & a1) const > { > list1<A1 const &> a(a1); > return l_(type<result_type>(), f_, a, 0); > } > > > > template<class A1, class A2> result_type operator()(A1 & a1, A2 & a2) > { > list2<A1 &, A2 &> a(a1, a2); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2> result_type operator()(A1 & a1, A2 & a2) const > { > list2<A1 &, A2 &> a(a1, a2); > return l_(type<result_type>(), f_, a, 0); > } > > > > > template<class A1, class A2> result_type operator()(A1 const & a1, A2 & a2) > { > list2<A1 const &, A2 &> a(a1, a2); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2> result_type operator()(A1 const & a1, A2 & a2) const > { > list2<A1 const &, A2 &> a(a1, a2); > return l_(type<result_type>(), f_, a, 0); > } > > > template<class A1, class A2> result_type operator()(A1 & a1, A2 const & a2) > { > list2<A1 &, A2 const &> a(a1, a2); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2> result_type operator()(A1 & a1, A2 const & a2) const > { > list2<A1 &, A2 const &> a(a1, a2); > return l_(type<result_type>(), f_, a, 0); > } > > > template<class A1, class A2> result_type operator()(A1 const & a1, A2 const & a2) > { > list2<A1 const &, A2 const &> a(a1, a2); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2> result_type operator()(A1 const & a1, A2 const & a2) const > { > list2<A1 const &, A2 const &> a(a1, a2); > return l_(type<result_type>(), f_, a, 0); > } > > > > template<class A1, class A2, class A3> result_type operator()(A1 & a1, A2 & a2, A3 & a3) > { > list3<A1 &, A2 &, A3 &> a(a1, a2, a3); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3> result_type operator()(A1 & a1, A2 & a2, A3 & a3) const > { > list3<A1 &, A2 &, A3 &> a(a1, a2, a3); > return l_(type<result_type>(), f_, a, 0); > } > > > > > template<class A1, class A2, class A3> result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3) > { > list3<A1 const &, A2 const &, A3 const &> a(a1, a2, a3); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3> result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3) const > { > list3<A1 const &, A2 const &, A3 const &> a(a1, a2, a3); > return l_(type<result_type>(), f_, a, 0); > } > > > > template<class A1, class A2, class A3, class A4> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4) > { > list4<A1 &, A2 &, A3 &, A4 &> a(a1, a2, a3, a4); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4) const > { > list4<A1 &, A2 &, A3 &, A4 &> a(a1, a2, a3, a4); > return l_(type<result_type>(), f_, a, 0); > } > > > > > template<class A1, class A2, class A3, class A4> result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4) > { > list4<A1 const &, A2 const &, A3 const &, A4 const &> a(a1, a2, a3, a4); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4> result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4) const > { > list4<A1 const &, A2 const &, A3 const &, A4 const &> a(a1, a2, a3, a4); > return l_(type<result_type>(), f_, a, 0); > } > > > > template<class A1, class A2, class A3, class A4, class A5> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5) > { > list5<A1 &, A2 &, A3 &, A4 &, A5 &> a(a1, a2, a3, a4, a5); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5) const > { > list5<A1 &, A2 &, A3 &, A4 &, A5 &> a(a1, a2, a3, a4, a5); > return l_(type<result_type>(), f_, a, 0); > } > > > > > template<class A1, class A2, class A3, class A4, class A5> result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5) > { > list5<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &> a(a1, a2, a3, a4, a5); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5> result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5) const > { > list5<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &> a(a1, a2, a3, a4, a5); > return l_(type<result_type>(), f_, a, 0); > } > > > > template<class A1, class A2, class A3, class A4, class A5, class A6> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6) > { > list6<A1 &, A2 &, A3 &, A4 &, A5 &, A6 &> a(a1, a2, a3, a4, a5, a6); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6) const > { > list6<A1 &, A2 &, A3 &, A4 &, A5 &, A6 &> a(a1, a2, a3, a4, a5, a6); > return l_(type<result_type>(), f_, a, 0); > } > > > > > template<class A1, class A2, class A3, class A4, class A5, class A6> result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6) > { > list6<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &, A6 const &> a(a1, a2, a3, a4, a5, a6); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6> result_type operator()(A1 const & a1, A2 const & a2, A3 const & a3, A4 const & a4, A5 const & a5, A6 const & a6) const > { > list6<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &, A6 const &> a(a1, a2, a3, a4, a5, a6); > return l_(type<result_type>(), f_, a, 0); > } > > > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7) > { > list7<A1 &, A2 &, A3 &, A4 &, A5 &, A6 &, A7 &> a(a1, a2, a3, a4, a5, a6, a7); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7) const > { > list7<A1 &, A2 &, A3 &, A4 &, A5 &, A6 &, A7 &> a(a1, a2, a3, a4, a5, a6, a7); > return l_(type<result_type>(), f_, a, 0); > } > > > > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> 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<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &, A6 const &, A7 const &> a(a1, a2, a3, a4, a5, a6, a7); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> 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<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &, A6 const &, A7 const &> a(a1, a2, a3, a4, a5, a6, a7); > return l_(type<result_type>(), f_, a, 0); > } > > > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8) > { > list8<A1 &, A2 &, A3 &, A4 &, A5 &, A6 &, A7 &, A8 &> a(a1, a2, a3, a4, a5, a6, a7, a8); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8) const > { > list8<A1 &, A2 &, A3 &, A4 &, A5 &, A6 &, A7 &, A8 &> a(a1, a2, a3, a4, a5, a6, a7, a8); > return l_(type<result_type>(), f_, a, 0); > } > > > > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> 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<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &, A6 const &, A7 const &, A8 const &> a(a1, a2, a3, a4, a5, a6, a7, a8); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> 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<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &, A6 const &, A7 const &, A8 const &> a(a1, a2, a3, a4, a5, a6, a7, a8); > return l_(type<result_type>(), f_, a, 0); > } > > > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8, A9 & a9) > { > list9<A1 &, A2 &, A3 &, A4 &, A5 &, A6 &, A7 &, A8 &, A9 &> a(a1, a2, a3, a4, a5, a6, a7, a8, a9); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> result_type operator()(A1 & a1, A2 & a2, A3 & a3, A4 & a4, A5 & a5, A6 & a6, A7 & a7, A8 & a8, A9 & a9) const > { > list9<A1 &, A2 &, A3 &, A4 &, A5 &, A6 &, A7 &, A8 &, A9 &> a(a1, a2, a3, a4, a5, a6, a7, a8, a9); > return l_(type<result_type>(), f_, a, 0); > } > > > > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> 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<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &, A6 const &, A7 const &, A8 const &, A9 const &> a(a1, a2, a3, a4, a5, a6, a7, a8, a9); > return l_(type<result_type>(), f_, a, 0); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> 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<A1 const &, A2 const &, A3 const &, A4 const &, A5 const &, A6 const &, A7 const &, A8 const &, A9 const &> a(a1, a2, a3, a4, a5, a6, a7, a8, a9); > return l_(type<result_type>(), f_, a, 0); > } > > > > template<class A> result_type eval(A & a) > { > return l_(type<result_type>(), f_, a, 0); > } > > template<class A> result_type eval(A & a) const > { > return l_(type<result_type>(), f_, a, 0); > } > > template<class V> void accept(V & v) const > { > > > using boost::visit_each; > > > 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_; ># 874 "/usr/include/boost/bind/bind.hpp" 2 3 4 > > >}; ># 940 "/usr/include/boost/bind/bind.hpp" 3 4 >template<class R, class F, class L> bool function_equal( bind_t<R, F, L> const & a, bind_t<R, F, L> const & b ) >{ > return a.compare(b); >} ># 994 "/usr/include/boost/bind/bind.hpp" 3 4 >template< class T, int I > struct add_value_2 >{ > typedef boost::arg<I> type; >}; > >template< class T > struct add_value_2< T, 0 > >{ > typedef _bi::value< T > type; >}; > >template<class T> struct add_value >{ > typedef typename add_value_2< T, boost::is_placeholder< T >::value >::type type; >}; > > > >template<class T> struct add_value< value<T> > >{ > typedef _bi::value<T> type; >}; > >template<class T> struct add_value< reference_wrapper<T> > >{ > typedef reference_wrapper<T> type; >}; > >template<int I> struct add_value< arg<I> > >{ > typedef boost::arg<I> type; >}; > >template<int I> struct add_value< arg<I> (*) () > >{ > typedef boost::arg<I> (*type) (); >}; > >template<class R, class F, class L> struct add_value< bind_t<R, F, L> > >{ > typedef bind_t<R, F, L> type; >}; ># 1077 "/usr/include/boost/bind/bind.hpp" 3 4 >template<class A1> struct list_av_1 >{ > typedef typename add_value<A1>::type B1; > typedef list1<B1> type; >}; > >template<class A1, class A2> struct list_av_2 >{ > typedef typename add_value<A1>::type B1; > typedef typename add_value<A2>::type B2; > typedef list2<B1, B2> type; >}; > >template<class A1, class A2, class A3> struct list_av_3 >{ > typedef typename add_value<A1>::type B1; > typedef typename add_value<A2>::type B2; > typedef typename add_value<A3>::type B3; > typedef list3<B1, B2, B3> type; >}; > >template<class A1, class A2, class A3, class A4> struct list_av_4 >{ > typedef typename add_value<A1>::type B1; > typedef typename add_value<A2>::type B2; > typedef typename add_value<A3>::type B3; > typedef typename add_value<A4>::type B4; > typedef list4<B1, B2, B3, B4> type; >}; > >template<class A1, class A2, class A3, class A4, class A5> struct list_av_5 >{ > typedef typename add_value<A1>::type B1; > typedef typename add_value<A2>::type B2; > typedef typename add_value<A3>::type B3; > typedef typename add_value<A4>::type B4; > typedef typename add_value<A5>::type B5; > typedef list5<B1, B2, B3, B4, B5> type; >}; > >template<class A1, class A2, class A3, class A4, class A5, class A6> struct list_av_6 >{ > typedef typename add_value<A1>::type B1; > typedef typename add_value<A2>::type B2; > typedef typename add_value<A3>::type B3; > typedef typename add_value<A4>::type B4; > typedef typename add_value<A5>::type B5; > typedef typename add_value<A6>::type B6; > typedef list6<B1, B2, B3, B4, B5, B6> type; >}; > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7> struct list_av_7 >{ > typedef typename add_value<A1>::type B1; > typedef typename add_value<A2>::type B2; > typedef typename add_value<A3>::type B3; > typedef typename add_value<A4>::type B4; > typedef typename add_value<A5>::type B5; > typedef typename add_value<A6>::type B6; > typedef typename add_value<A7>::type B7; > typedef list7<B1, B2, B3, B4, B5, B6, B7> type; >}; > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> struct list_av_8 >{ > typedef typename add_value<A1>::type B1; > typedef typename add_value<A2>::type B2; > typedef typename add_value<A3>::type B3; > typedef typename add_value<A4>::type B4; > typedef typename add_value<A5>::type B5; > typedef typename add_value<A6>::type B6; > typedef typename add_value<A7>::type B7; > typedef typename add_value<A8>::type B8; > typedef list8<B1, B2, B3, B4, B5, B6, B7, B8> type; >}; > >template<class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> struct list_av_9 >{ > typedef typename add_value<A1>::type B1; > typedef typename add_value<A2>::type B2; > typedef typename add_value<A3>::type B3; > typedef typename add_value<A4>::type B4; > typedef typename add_value<A5>::type B5; > typedef typename add_value<A6>::type B6; > typedef typename add_value<A7>::type B7; > typedef typename add_value<A8>::type B8; > typedef typename add_value<A9>::type B9; > typedef list9<B1, B2, B3, B4, B5, B6, B7, B8, B9> type; >}; > > > >struct logical_not >{ > template<class V> bool operator()(V const & v) const { return !v; } >}; > >template<class R, class F, class L> > bind_t< bool, logical_not, list1< bind_t<R, F, L> > > > operator! (bind_t<R, F, L> const & f) >{ > typedef list1< bind_t<R, F, L> > list_type; > return bind_t<bool, logical_not, list_type> ( logical_not(), list_type(f) ); >} ># 1200 "/usr/include/boost/bind/bind.hpp" 3 4 >struct equal { template<class V, class W> bool operator()(V const & v, W const & w) const { return v == w; } }; template<class R, class F, class L, class A2> bind_t< bool, equal, list2< bind_t<R, F, L>, typename add_value<A2>::type > > operator == (bind_t<R, F, L> const & f, A2 a2) { typedef typename add_value<A2>::type B2; typedef list2< bind_t<R, F, L>, B2> list_type; return bind_t<bool, equal, list_type> ( equal(), list_type(f, a2) ); } >struct not_equal { template<class V, class W> bool operator()(V const & v, W const & w) const { return v != w; } }; template<class R, class F, class L, class A2> bind_t< bool, not_equal, list2< bind_t<R, F, L>, typename add_value<A2>::type > > operator != (bind_t<R, F, L> const & f, A2 a2) { typedef typename add_value<A2>::type B2; typedef list2< bind_t<R, F, L>, B2> list_type; return bind_t<bool, not_equal, list_type> ( not_equal(), list_type(f, a2) ); } > >struct less { template<class V, class W> bool operator()(V const & v, W const & w) const { return v < w; } }; template<class R, class F, class L, class A2> bind_t< bool, less, list2< bind_t<R, F, L>, typename add_value<A2>::type > > operator < (bind_t<R, F, L> const & f, A2 a2) { typedef typename add_value<A2>::type B2; typedef list2< bind_t<R, F, L>, B2> list_type; return bind_t<bool, less, list_type> ( less(), list_type(f, a2) ); } >struct less_equal { template<class V, class W> bool operator()(V const & v, W const & w) const { return v <= w; } }; template<class R, class F, class L, class A2> bind_t< bool, less_equal, list2< bind_t<R, F, L>, typename add_value<A2>::type > > operator <= (bind_t<R, F, L> const & f, A2 a2) { typedef typename add_value<A2>::type B2; typedef list2< bind_t<R, F, L>, B2> list_type; return bind_t<bool, less_equal, list_type> ( less_equal(), list_type(f, a2) ); } > >struct greater { template<class V, class W> bool operator()(V const & v, W const & w) const { return v > w; } }; template<class R, class F, class L, class A2> bind_t< bool, greater, list2< bind_t<R, F, L>, typename add_value<A2>::type > > operator > (bind_t<R, F, L> const & f, A2 a2) { typedef typename add_value<A2>::type B2; typedef list2< bind_t<R, F, L>, B2> list_type; return bind_t<bool, greater, list_type> ( greater(), list_type(f, a2) ); } >struct greater_equal { template<class V, class W> bool operator()(V const & v, W const & w) const { return v >= w; } }; template<class R, class F, class L, class A2> bind_t< bool, greater_equal, list2< bind_t<R, F, L>, typename add_value<A2>::type > > operator >= (bind_t<R, F, L> const & f, A2 a2) { typedef typename add_value<A2>::type B2; typedef list2< bind_t<R, F, L>, B2> list_type; return bind_t<bool, greater_equal, list_type> ( greater_equal(), list_type(f, a2) ); } > >struct logical_and { template<class V, class W> bool operator()(V const & v, W const & w) const { return v && w; } }; template<class R, class F, class L, class A2> bind_t< bool, logical_and, list2< bind_t<R, F, L>, typename add_value<A2>::type > > operator && (bind_t<R, F, L> const & f, A2 a2) { typedef typename add_value<A2>::type B2; typedef list2< bind_t<R, F, L>, B2> list_type; return bind_t<bool, logical_and, list_type> ( logical_and(), list_type(f, a2) ); } >struct logical_or { template<class V, class W> bool operator()(V const & v, W const & w) const { return v || w; } }; template<class R, class F, class L, class A2> bind_t< bool, logical_or, list2< bind_t<R, F, L>, typename add_value<A2>::type > > operator || (bind_t<R, F, L> const & f, A2 a2) { typedef typename add_value<A2>::type B2; typedef list2< bind_t<R, F, L>, B2> list_type; return bind_t<bool, logical_or, list_type> ( logical_or(), list_type(f, a2) ); } ># 1240 "/usr/include/boost/bind/bind.hpp" 3 4 >template<class V, class T> void visit_each( V & v, value<T> const & t, int ) >{ > using boost::visit_each; > visit_each( v, t.get(), 0 ); >} > >template<class V, class R, class F, class L> void visit_each( V & v, bind_t<R, F, L> const & t, int ) >{ > t.accept( v ); >} > > > >} ># 1274 "/usr/include/boost/bind/bind.hpp" 3 4 >template< class T > struct is_bind_expression >{ > enum _vt { value = 0 }; >}; > > > >template< class R, class F, class L > struct is_bind_expression< _bi::bind_t< R, F, L > > >{ > enum _vt { value = 1 }; >}; ># 1296 "/usr/include/boost/bind/bind.hpp" 3 4 >template<class R, class F> > _bi::bind_t<R, F, _bi::list0> > bind(F f) >{ > typedef _bi::list0 list_type; > return _bi::bind_t<R, F, list_type> (f, list_type()); >} > >template<class R, class F, class A1> > _bi::bind_t<R, F, typename _bi::list_av_1<A1>::type> > bind(F f, A1 a1) >{ > typedef typename _bi::list_av_1<A1>::type list_type; > return _bi::bind_t<R, F, list_type> (f, list_type(a1)); >} > >template<class R, class F, class A1, class A2> > _bi::bind_t<R, F, typename _bi::list_av_2<A1, A2>::type> > bind(F f, A1 a1, A2 a2) >{ > typedef typename _bi::list_av_2<A1, A2>::type list_type; > return _bi::bind_t<R, F, list_type> (f, list_type(a1, a2)); >} > >template<class R, class F, class A1, class A2, class A3> > _bi::bind_t<R, F, typename _bi::list_av_3<A1, A2, A3>::type> > bind(F f, A1 a1, A2 a2, A3 a3) >{ > typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3)); >} > >template<class R, class F, class A1, class A2, class A3, class A4> > _bi::bind_t<R, F, typename _bi::list_av_4<A1, A2, A3, A4>::type> > bind(F f, A1 a1, A2 a2, A3 a3, A4 a4) >{ > typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5> > _bi::bind_t<R, F, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> > bind(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) >{ > typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6> > _bi::bind_t<R, F, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> > bind(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) >{ > typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7> > _bi::bind_t<R, F, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> > bind(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) >{ > typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > _bi::bind_t<R, F, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> > 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<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > _bi::bind_t<R, F, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> > 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<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); >} > > > >template<class R, class F> > _bi::bind_t<R, F, _bi::list0> > bind(boost::type<R>, F f) >{ > typedef _bi::list0 list_type; > return _bi::bind_t<R, F, list_type> (f, list_type()); >} > >template<class R, class F, class A1> > _bi::bind_t<R, F, typename _bi::list_av_1<A1>::type> > bind(boost::type<R>, F f, A1 a1) >{ > typedef typename _bi::list_av_1<A1>::type list_type; > return _bi::bind_t<R, F, list_type> (f, list_type(a1)); >} > >template<class R, class F, class A1, class A2> > _bi::bind_t<R, F, typename _bi::list_av_2<A1, A2>::type> > bind(boost::type<R>, F f, A1 a1, A2 a2) >{ > typedef typename _bi::list_av_2<A1, A2>::type list_type; > return _bi::bind_t<R, F, list_type> (f, list_type(a1, a2)); >} > >template<class R, class F, class A1, class A2, class A3> > _bi::bind_t<R, F, typename _bi::list_av_3<A1, A2, A3>::type> > bind(boost::type<R>, F f, A1 a1, A2 a2, A3 a3) >{ > typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3)); >} > >template<class R, class F, class A1, class A2, class A3, class A4> > _bi::bind_t<R, F, typename _bi::list_av_4<A1, A2, A3, A4>::type> > bind(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4) >{ > typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5> > _bi::bind_t<R, F, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> > bind(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) >{ > typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6> > _bi::bind_t<R, F, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> > bind(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) >{ > typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7> > _bi::bind_t<R, F, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> > bind(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) >{ > typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > _bi::bind_t<R, F, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> > bind(boost::type<R>, F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8) >{ > typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); >} > >template<class R, class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > _bi::bind_t<R, F, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> > bind(boost::type<R>, 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<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); >} > > > > > >template<class F> > _bi::bind_t<_bi::unspecified, F, _bi::list0> > bind(F f) >{ > typedef _bi::list0 list_type; > return _bi::bind_t<_bi::unspecified, F, list_type> (f, list_type()); >} > >template<class F, class A1> > _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_1<A1>::type> > bind(F f, A1 a1) >{ > typedef typename _bi::list_av_1<A1>::type list_type; > return _bi::bind_t<_bi::unspecified, F, list_type> (f, list_type(a1)); >} > >template<class F, class A1, class A2> > _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_2<A1, A2>::type> > bind(F f, A1 a1, A2 a2) >{ > typedef typename _bi::list_av_2<A1, A2>::type list_type; > return _bi::bind_t<_bi::unspecified, F, list_type> (f, list_type(a1, a2)); >} > >template<class F, class A1, class A2, class A3> > _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_3<A1, A2, A3>::type> > bind(F f, A1 a1, A2 a2, A3 a3) >{ > typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; > return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3)); >} > >template<class F, class A1, class A2, class A3, class A4> > _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_4<A1, A2, A3, A4>::type> > bind(F f, A1 a1, A2 a2, A3 a3, A4 a4) >{ > typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; > return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4)); >} > >template<class F, class A1, class A2, class A3, class A4, class A5> > _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> > bind(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) >{ > typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; > return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5)); >} > >template<class F, class A1, class A2, class A3, class A4, class A5, class A6> > _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> > bind(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) >{ > typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; > return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6)); >} > >template<class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7> > _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> > bind(F f, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) >{ > typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; > return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7)); >} > >template<class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> > 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<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; > return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); >} > >template<class F, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > _bi::bind_t<_bi::unspecified, F, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> > 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<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; > return _bi::bind_t<_bi::unspecified, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); >} ># 1549 "/usr/include/boost/bind/bind.hpp" 3 4 ># 1 "/usr/include/boost/bind/bind_cc.hpp" 1 3 4 ># 15 "/usr/include/boost/bind/bind_cc.hpp" 3 4 >template<class R> > _bi::bind_t<R, R ( *) (), _bi::list0> > bind( R ( *f) ()) >{ > typedef R ( *F) (); > typedef _bi::list0 list_type; > return _bi::bind_t<R, F, list_type> (f, list_type()); >} > >template<class R, class B1, class A1> > _bi::bind_t<R, R ( *) (B1), typename _bi::list_av_1<A1>::type> > bind( R ( *f) (B1), A1 a1) >{ > typedef R ( *F) (B1); > typedef typename _bi::list_av_1<A1>::type list_type; > return _bi::bind_t<R, F, list_type> (f, list_type(a1)); >} > >template<class R, class B1, class B2, class A1, class A2> > _bi::bind_t<R, R ( *) (B1, B2), typename _bi::list_av_2<A1, A2>::type> > bind( R ( *f) (B1, B2), A1 a1, A2 a2) >{ > typedef R ( *F) (B1, B2); > typedef typename _bi::list_av_2<A1, A2>::type list_type; > return _bi::bind_t<R, F, list_type> (f, list_type(a1, a2)); >} > >template<class R, > class B1, class B2, class B3, > class A1, class A2, class A3> > _bi::bind_t<R, R ( *) (B1, B2, B3), typename _bi::list_av_3<A1, A2, A3>::type> > bind( R ( *f) (B1, B2, B3), A1 a1, A2 a2, A3 a3) >{ > typedef R ( *F) (B1, B2, B3); > typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3)); >} > >template<class R, > class B1, class B2, class B3, class B4, > class A1, class A2, class A3, class A4> > _bi::bind_t<R, R ( *) (B1, B2, B3, B4), typename _bi::list_av_4<A1, A2, A3, A4>::type> > bind( R ( *f) (B1, B2, B3, B4), A1 a1, A2 a2, A3 a3, A4 a4) >{ > typedef R ( *F) (B1, B2, B3, B4); > typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4)); >} > >template<class R, > class B1, class B2, class B3, class B4, class B5, > class A1, class A2, class A3, class A4, class A5> > _bi::bind_t<R, R ( *) (B1, B2, B3, B4, B5), typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> > bind( R ( *f) (B1, B2, B3, B4, B5), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) >{ > typedef R ( *F) (B1, B2, B3, B4, B5); > typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5)); >} > >template<class R, > class B1, class B2, class B3, class B4, class B5, class B6, > class A1, class A2, class A3, class A4, class A5, class A6> > _bi::bind_t<R, R ( *) (B1, B2, B3, B4, B5, B6), typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> > bind( R ( *f) (B1, B2, B3, B4, B5, B6), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) >{ > typedef R ( *F) (B1, B2, B3, B4, B5, B6); > typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6)); >} > >template<class R, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, > class A1, class A2, class A3, class A4, class A5, class A6, class A7> > _bi::bind_t<R, R ( *) (B1, B2, B3, B4, B5, B6, B7), typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> > bind( R ( *f) (B1, B2, B3, B4, B5, B6, B7), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) >{ > typedef R ( *F) (B1, B2, B3, B4, B5, B6, B7); > typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7)); >} > >template<class R, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > _bi::bind_t<R, R ( *) (B1, B2, B3, B4, B5, B6, B7, B8), typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> > bind( R ( *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 R ( *F) (B1, B2, B3, B4, B5, B6, B7, B8); > typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8)); >} > >template<class R, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8, class B9, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > _bi::bind_t<R, R ( *) (B1, B2, B3, B4, B5, B6, B7, B8, B9), typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> > bind( R ( *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 R ( *F) (B1, B2, B3, B4, B5, B6, B7, B8, B9); > typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; > return _bi::bind_t<R, F, list_type>(f, list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); >} ># 1550 "/usr/include/boost/bind/bind.hpp" 2 3 4 ># 1595 "/usr/include/boost/bind/bind.hpp" 3 4 ># 1 "/usr/include/boost/bind/bind_mf_cc.hpp" 1 3 4 ># 17 "/usr/include/boost/bind/bind_mf_cc.hpp" 3 4 >template<class R, class T, > class A1> > _bi::bind_t<R, _mfi::mf0<R, T>, typename _bi::list_av_1<A1>::type> > bind(R ( T::*f) (), A1 a1) >{ > typedef _mfi::mf0<R, T> F; > typedef typename _bi::list_av_1<A1>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1)); >} > >template<class R, class T, > class A1> > _bi::bind_t<R, _mfi::cmf0<R, T>, typename _bi::list_av_1<A1>::type> > bind(R ( T::*f) () const, A1 a1) >{ > typedef _mfi::cmf0<R, T> F; > typedef typename _bi::list_av_1<A1>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1)); >} > > > >template<class R, class T, > class B1, > class A1, class A2> > _bi::bind_t<R, _mfi::mf1<R, T, B1>, typename _bi::list_av_2<A1, A2>::type> > bind(R ( T::*f) (B1), A1 a1, A2 a2) >{ > typedef _mfi::mf1<R, T, B1> F; > typedef typename _bi::list_av_2<A1, A2>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2)); >} > >template<class R, class T, > class B1, > class A1, class A2> > _bi::bind_t<R, _mfi::cmf1<R, T, B1>, typename _bi::list_av_2<A1, A2>::type> > bind(R ( T::*f) (B1) const, A1 a1, A2 a2) >{ > typedef _mfi::cmf1<R, T, B1> F; > typedef typename _bi::list_av_2<A1, A2>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2)); >} > > > >template<class R, class T, > class B1, class B2, > class A1, class A2, class A3> > _bi::bind_t<R, _mfi::mf2<R, T, B1, B2>, typename _bi::list_av_3<A1, A2, A3>::type> > bind(R ( T::*f) (B1, B2), A1 a1, A2 a2, A3 a3) >{ > typedef _mfi::mf2<R, T, B1, B2> F; > typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3)); >} > >template<class R, class T, > class B1, class B2, > class A1, class A2, class A3> > _bi::bind_t<R, _mfi::cmf2<R, T, B1, B2>, typename _bi::list_av_3<A1, A2, A3>::type> > bind(R ( T::*f) (B1, B2) const, A1 a1, A2 a2, A3 a3) >{ > typedef _mfi::cmf2<R, T, B1, B2> F; > typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3)); >} > > > >template<class R, class T, > class B1, class B2, class B3, > class A1, class A2, class A3, class A4> > _bi::bind_t<R, _mfi::mf3<R, T, B1, B2, B3>, typename _bi::list_av_4<A1, A2, A3, A4>::type> > bind(R ( T::*f) (B1, B2, B3), A1 a1, A2 a2, A3 a3, A4 a4) >{ > typedef _mfi::mf3<R, T, B1, B2, B3> F; > typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4)); >} > >template<class R, class T, > class B1, class B2, class B3, > class A1, class A2, class A3, class A4> > _bi::bind_t<R, _mfi::cmf3<R, T, B1, B2, B3>, typename _bi::list_av_4<A1, A2, A3, A4>::type> > bind(R ( T::*f) (B1, B2, B3) const, A1 a1, A2 a2, A3 a3, A4 a4) >{ > typedef _mfi::cmf3<R, T, B1, B2, B3> F; > typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4)); >} > > > >template<class R, class T, > class B1, class B2, class B3, class B4, > class A1, class A2, class A3, class A4, class A5> > _bi::bind_t<R, _mfi::mf4<R, T, B1, B2, B3, B4>, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> > bind(R ( T::*f) (B1, B2, B3, B4), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) >{ > typedef _mfi::mf4<R, T, B1, B2, B3, B4> F; > typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5)); >} > >template<class R, class T, > class B1, class B2, class B3, class B4, > class A1, class A2, class A3, class A4, class A5> > _bi::bind_t<R, _mfi::cmf4<R, T, B1, B2, B3, B4>, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> > bind(R ( T::*f) (B1, B2, B3, B4) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) >{ > typedef _mfi::cmf4<R, T, B1, B2, B3, B4> F; > typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5)); >} > > > >template<class R, class T, > class B1, class B2, class B3, class B4, class B5, > class A1, class A2, class A3, class A4, class A5, class A6> > _bi::bind_t<R, _mfi::mf5<R, T, B1, B2, B3, B4, B5>, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> > bind(R ( T::*f) (B1, B2, B3, B4, B5), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) >{ > typedef _mfi::mf5<R, T, B1, B2, B3, B4, B5> F; > typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6)); >} > >template<class R, class T, > class B1, class B2, class B3, class B4, class B5, > class A1, class A2, class A3, class A4, class A5, class A6> > _bi::bind_t<R, _mfi::cmf5<R, T, B1, B2, B3, B4, B5>, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> > bind(R ( T::*f) (B1, B2, B3, B4, B5) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) >{ > typedef _mfi::cmf5<R, T, B1, B2, B3, B4, B5> F; > typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6)); >} > > > >template<class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, > class A1, class A2, class A3, class A4, class A5, class A6, class A7> > _bi::bind_t<R, _mfi::mf6<R, T, B1, B2, B3, B4, B5, B6>, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> > bind(R ( T::*f) (B1, B2, B3, B4, B5, B6), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) >{ > typedef _mfi::mf6<R, T, B1, B2, B3, B4, B5, B6> F; > typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7)); >} > >template<class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, > class A1, class A2, class A3, class A4, class A5, class A6, class A7> > _bi::bind_t<R, _mfi::cmf6<R, T, B1, B2, B3, B4, B5, B6>, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> > bind(R ( 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::cmf6<R, T, B1, B2, B3, B4, B5, B6> F; > typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7)); >} > > > >template<class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > _bi::bind_t<R, _mfi::mf7<R, T, B1, B2, B3, B4, B5, B6, B7>, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> > bind(R ( 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::mf7<R, T, B1, B2, B3, B4, B5, B6, B7> F; > typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8)); >} > >template<class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > _bi::bind_t<R, _mfi::cmf7<R, T, B1, B2, B3, B4, B5, B6, B7>, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> > bind(R ( 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::cmf7<R, T, B1, B2, B3, B4, B5, B6, B7> F; > typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8)); >} > > > >template<class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > _bi::bind_t<R, _mfi::mf8<R, T, B1, B2, B3, B4, B5, B6, B7, B8>, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> > bind(R ( 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::mf8<R, T, B1, B2, B3, B4, B5, B6, B7, B8> F; > typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); >} > >template<class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > _bi::bind_t<R, _mfi::cmf8<R, T, B1, B2, B3, B4, B5, B6, B7, B8>, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> > bind(R ( 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::cmf8<R, T, B1, B2, B3, B4, B5, B6, B7, B8> F; > typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; > return _bi::bind_t<R, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); >} ># 1596 "/usr/include/boost/bind/bind.hpp" 2 3 4 ># 1 "/usr/include/boost/bind/bind_mf2_cc.hpp" 1 3 4 ># 18 "/usr/include/boost/bind/bind_mf2_cc.hpp" 3 4 >template<class Rt2, class R, class T, > class A1> > _bi::bind_t<Rt2, _mfi::mf0<R, T>, typename _bi::list_av_1<A1>::type> > bind(boost::type<Rt2>, R ( T::*f) (), A1 a1) >{ > typedef _mfi::mf0<R, T> F; > typedef typename _bi::list_av_1<A1>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1)); >} > >template<class Rt2, class R, class T, > class A1> > _bi::bind_t<Rt2, _mfi::cmf0<R, T>, typename _bi::list_av_1<A1>::type> > bind(boost::type<Rt2>, R ( T::*f) () const, A1 a1) >{ > typedef _mfi::cmf0<R, T> F; > typedef typename _bi::list_av_1<A1>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1)); >} > > > >template<class Rt2, class R, class T, > class B1, > class A1, class A2> > _bi::bind_t<Rt2, _mfi::mf1<R, T, B1>, typename _bi::list_av_2<A1, A2>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1), A1 a1, A2 a2) >{ > typedef _mfi::mf1<R, T, B1> F; > typedef typename _bi::list_av_2<A1, A2>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2)); >} > >template<class Rt2, class R, class T, > class B1, > class A1, class A2> > _bi::bind_t<Rt2, _mfi::cmf1<R, T, B1>, typename _bi::list_av_2<A1, A2>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1) const, A1 a1, A2 a2) >{ > typedef _mfi::cmf1<R, T, B1> F; > typedef typename _bi::list_av_2<A1, A2>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2)); >} > > > >template<class Rt2, class R, class T, > class B1, class B2, > class A1, class A2, class A3> > _bi::bind_t<Rt2, _mfi::mf2<R, T, B1, B2>, typename _bi::list_av_3<A1, A2, A3>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1, B2), A1 a1, A2 a2, A3 a3) >{ > typedef _mfi::mf2<R, T, B1, B2> F; > typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3)); >} > >template<class Rt2, class R, class T, > class B1, class B2, > class A1, class A2, class A3> > _bi::bind_t<Rt2, _mfi::cmf2<R, T, B1, B2>, typename _bi::list_av_3<A1, A2, A3>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1, B2) const, A1 a1, A2 a2, A3 a3) >{ > typedef _mfi::cmf2<R, T, B1, B2> F; > typedef typename _bi::list_av_3<A1, A2, A3>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3)); >} > > > >template<class Rt2, class R, class T, > class B1, class B2, class B3, > class A1, class A2, class A3, class A4> > _bi::bind_t<Rt2, _mfi::mf3<R, T, B1, B2, B3>, typename _bi::list_av_4<A1, A2, A3, A4>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1, B2, B3), A1 a1, A2 a2, A3 a3, A4 a4) >{ > typedef _mfi::mf3<R, T, B1, B2, B3> F; > typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4)); >} > >template<class Rt2, class R, class T, > class B1, class B2, class B3, > class A1, class A2, class A3, class A4> > _bi::bind_t<Rt2, _mfi::cmf3<R, T, B1, B2, B3>, typename _bi::list_av_4<A1, A2, A3, A4>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1, B2, B3) const, A1 a1, A2 a2, A3 a3, A4 a4) >{ > typedef _mfi::cmf3<R, T, B1, B2, B3> F; > typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4)); >} > > > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, > class A1, class A2, class A3, class A4, class A5> > _bi::bind_t<Rt2, _mfi::mf4<R, T, B1, B2, B3, B4>, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1, B2, B3, B4), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) >{ > typedef _mfi::mf4<R, T, B1, B2, B3, B4> F; > typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5)); >} > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, > class A1, class A2, class A3, class A4, class A5> > _bi::bind_t<Rt2, _mfi::cmf4<R, T, B1, B2, B3, B4>, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1, B2, B3, B4) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5) >{ > typedef _mfi::cmf4<R, T, B1, B2, B3, B4> F; > typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5)); >} > > > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, class B5, > class A1, class A2, class A3, class A4, class A5, class A6> > _bi::bind_t<Rt2, _mfi::mf5<R, T, B1, B2, B3, B4, B5>, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1, B2, B3, B4, B5), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) >{ > typedef _mfi::mf5<R, T, B1, B2, B3, B4, B5> F; > typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6)); >} > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, class B5, > class A1, class A2, class A3, class A4, class A5, class A6> > _bi::bind_t<Rt2, _mfi::cmf5<R, T, B1, B2, B3, B4, B5>, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1, B2, B3, B4, B5) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6) >{ > typedef _mfi::cmf5<R, T, B1, B2, B3, B4, B5> F; > typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6)); >} > > > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, > class A1, class A2, class A3, class A4, class A5, class A6, class A7> > _bi::bind_t<Rt2, _mfi::mf6<R, T, B1, B2, B3, B4, B5, B6>, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> > bind(boost::type<Rt2>, R ( T::*f) (B1, B2, B3, B4, B5, B6), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7) >{ > typedef _mfi::mf6<R, T, B1, B2, B3, B4, B5, B6> F; > typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7)); >} > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, > class A1, class A2, class A3, class A4, class A5, class A6, class A7> > _bi::bind_t<Rt2, _mfi::cmf6<R, T, B1, B2, B3, B4, B5, B6>, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type> > bind(boost::type<Rt2>, R ( 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::cmf6<R, T, B1, B2, B3, B4, B5, B6> F; > typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7)); >} > > > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > _bi::bind_t<Rt2, _mfi::mf7<R, T, B1, B2, B3, B4, B5, B6, B7>, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> > bind(boost::type<Rt2>, R ( 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::mf7<R, T, B1, B2, B3, B4, B5, B6, B7> F; > typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8)); >} > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > _bi::bind_t<Rt2, _mfi::cmf7<R, T, B1, B2, B3, B4, B5, B6, B7>, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type> > bind(boost::type<Rt2>, R ( 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::cmf7<R, T, B1, B2, B3, B4, B5, B6, B7> F; > typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8)); >} > > > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > _bi::bind_t<Rt2, _mfi::mf8<R, T, B1, B2, B3, B4, B5, B6, B7, B8>, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> > bind(boost::type<Rt2>, R ( 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::mf8<R, T, B1, B2, B3, B4, B5, B6, B7, B8> F; > typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); >} > >template<class Rt2, class R, class T, > class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8, > class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > _bi::bind_t<Rt2, _mfi::cmf8<R, T, B1, B2, B3, B4, B5, B6, B7, B8>, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type> > bind(boost::type<Rt2>, R ( 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::cmf8<R, T, B1, B2, B3, B4, B5, B6, B7, B8> F; > typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type; > return _bi::bind_t<Rt2, F, list_type>(F(f), list_type(a1, a2, a3, a4, a5, a6, a7, a8, a9)); >} ># 1597 "/usr/include/boost/bind/bind.hpp" 2 3 4 ># 1656 "/usr/include/boost/bind/bind.hpp" 3 4 >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 > >{ > > > > > typedef M const & type; > > > >}; > >template< class R, class T > struct add_cref< R (T::*) (), 1 > >{ > typedef void type; >}; > > > >template< class R, class T > struct add_cref< R (T::*) () const, 1 > >{ > typedef void type; >}; > > > >template<class R> struct isref >{ > enum value_type { value = 0 }; >}; > >template<class R> struct isref< R& > >{ > enum value_type { value = 1 }; >}; > >template<class R> struct isref< R* > >{ > enum value_type { value = 1 }; >}; > >template<class Pm, class A1> struct dm_result >{ > typedef typename add_cref< Pm, 1 >::type type; >}; > >template<class Pm, class R, class F, class L> struct dm_result< Pm, bind_t<R, F, L> > >{ > typedef typename bind_t<R, F, L>::result_type result_type; > typedef typename add_cref< Pm, isref< result_type >::value >::type type; >}; > >} > >template< class A1, class M, class T > > >_bi::bind_t< > typename _bi::dm_result< M T::*, A1 >::type, > _mfi::dm<M, T>, > typename _bi::list_av_1<A1>::type >> > >bind( M T::*f, A1 a1 ) >{ > typedef typename _bi::dm_result< M T::*, A1 >::type result_type; > typedef _mfi::dm<M, T> F; > typedef typename _bi::list_av_1<A1>::type list_type; > return _bi::bind_t< result_type, F, list_type >( F( f ), list_type( a1 ) ); >} > > > >} > > > ># 1 "/usr/include/boost/bind/placeholders.hpp" 1 3 4 ># 25 "/usr/include/boost/bind/placeholders.hpp" 3 4 >namespace >{ ># 55 "/usr/include/boost/bind/placeholders.hpp" 3 4 >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; > > > >} ># 1743 "/usr/include/boost/bind/bind.hpp" 2 3 4 ># 23 "/usr/include/boost/bind.hpp" 2 3 4 ># 30 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/io/ios_state.hpp" 1 3 4 ># 12 "/usr/include/boost/io/ios_state.hpp" 3 4 ># 1 "/usr/include/boost/io_fwd.hpp" 1 3 4 ># 15 "/usr/include/boost/io_fwd.hpp" 3 4 >namespace boost >{ >namespace io >{ > > > > >class ios_flags_saver; >class ios_precision_saver; >class ios_width_saver; >class ios_base_all_saver; > >template < typename Ch, class Tr = ::std::char_traits<Ch> > > class basic_ios_iostate_saver; >template < typename Ch, class Tr = ::std::char_traits<Ch> > > class basic_ios_exception_saver; >template < typename Ch, class Tr = ::std::char_traits<Ch> > > class basic_ios_tie_saver; >template < typename Ch, class Tr = ::std::char_traits<Ch> > > class basic_ios_rdbuf_saver; >template < typename Ch, class Tr = ::std::char_traits<Ch> > > class basic_ios_fill_saver; >template < typename Ch, class Tr = ::std::char_traits<Ch> > > class basic_ios_locale_saver; >template < typename Ch, class Tr = ::std::char_traits<Ch> > > class basic_ios_all_saver; > >typedef basic_ios_iostate_saver<char> ios_iostate_saver; >typedef basic_ios_iostate_saver<wchar_t> wios_iostate_saver; >typedef basic_ios_exception_saver<char> ios_exception_saver; >typedef basic_ios_exception_saver<wchar_t> wios_exception_saver; >typedef basic_ios_tie_saver<char> ios_tie_saver; >typedef basic_ios_tie_saver<wchar_t> wios_tie_saver; >typedef basic_ios_rdbuf_saver<char> ios_rdbuf_saver; >typedef basic_ios_rdbuf_saver<wchar_t> wios_rdbuf_saver; >typedef basic_ios_fill_saver<char> ios_fill_saver; >typedef basic_ios_fill_saver<wchar_t> wios_fill_saver; >typedef basic_ios_locale_saver<char> ios_locale_saver; >typedef basic_ios_locale_saver<wchar_t> wios_locale_saver; >typedef basic_ios_all_saver<char> ios_all_saver; >typedef basic_ios_all_saver<wchar_t> wios_all_saver; > >class ios_iword_saver; >class ios_pword_saver; >class ios_all_word_saver; > > >} >} ># 13 "/usr/include/boost/io/ios_state.hpp" 2 3 4 ># 24 "/usr/include/boost/io/ios_state.hpp" 3 4 >namespace boost >{ >namespace io >{ > > > > >class ios_flags_saver >{ >public: > typedef ::std::ios_base state_type; > typedef ::std::ios_base::fmtflags aspect_type; > > explicit ios_flags_saver( state_type &s ) > : s_save_( s ), a_save_( s.flags() ) > {} > ios_flags_saver( state_type &s, aspect_type const &a ) > : s_save_( s ), a_save_( s.flags(a) ) > {} > ~ios_flags_saver() > { this->restore(); } > > void restore() > { s_save_.flags( a_save_ ); } > >private: > state_type & s_save_; > aspect_type const a_save_; > > ios_flags_saver& operator=(const ios_flags_saver&); >}; > >class ios_precision_saver >{ >public: > typedef ::std::ios_base state_type; > typedef ::std::streamsize aspect_type; > > explicit ios_precision_saver( state_type &s ) > : s_save_( s ), a_save_( s.precision() ) > {} > ios_precision_saver( state_type &s, aspect_type const &a ) > : s_save_( s ), a_save_( s.precision(a) ) > {} > ~ios_precision_saver() > { this->restore(); } > > void restore() > { s_save_.precision( a_save_ ); } > >private: > state_type & s_save_; > aspect_type const a_save_; > > ios_precision_saver& operator=(const ios_precision_saver&); >}; > >class ios_width_saver >{ >public: > typedef ::std::ios_base state_type; > typedef ::std::streamsize aspect_type; > > explicit ios_width_saver( state_type &s ) > : s_save_( s ), a_save_( s.width() ) > {} > ios_width_saver( state_type &s, aspect_type const &a ) > : s_save_( s ), a_save_( s.width(a) ) > {} > ~ios_width_saver() > { this->restore(); } > > void restore() > { s_save_.width( a_save_ ); } > >private: > state_type & s_save_; > aspect_type const a_save_; > ios_width_saver& operator=(const ios_width_saver&); >}; > > > > >template < typename Ch, class Tr > >class basic_ios_iostate_saver >{ >public: > typedef ::std::basic_ios<Ch, Tr> state_type; > typedef ::std::ios_base::iostate aspect_type; > > explicit basic_ios_iostate_saver( state_type &s ) > : s_save_( s ), a_save_( s.rdstate() ) > {} > basic_ios_iostate_saver( state_type &s, aspect_type const &a ) > : s_save_( s ), a_save_( s.rdstate() ) > { s.clear(a); } > ~basic_ios_iostate_saver() > { this->restore(); } > > void restore() > { s_save_.clear( a_save_ ); } > >private: > state_type & s_save_; > aspect_type const a_save_; > basic_ios_iostate_saver& operator=(const basic_ios_iostate_saver&); >}; > >template < typename Ch, class Tr > >class basic_ios_exception_saver >{ >public: > typedef ::std::basic_ios<Ch, Tr> state_type; > typedef ::std::ios_base::iostate aspect_type; > > explicit basic_ios_exception_saver( state_type &s ) > : s_save_( s ), a_save_( s.exceptions() ) > {} > > > > basic_ios_exception_saver( state_type &s, aspect_type const &a ) > > : s_save_( s ), a_save_( s.exceptions() ) > { s.exceptions(a); } > ~basic_ios_exception_saver() > { this->restore(); } > > void restore() > { s_save_.exceptions( a_save_ ); } > >private: > state_type & s_save_; > aspect_type const a_save_; > basic_ios_exception_saver& operator=(const basic_ios_exception_saver&); >}; > >template < typename Ch, class Tr > >class basic_ios_tie_saver >{ >public: > typedef ::std::basic_ios<Ch, Tr> state_type; > typedef ::std::basic_ostream<Ch, Tr> * aspect_type; > > explicit basic_ios_tie_saver( state_type &s ) > : s_save_( s ), a_save_( s.tie() ) > {} > basic_ios_tie_saver( state_type &s, aspect_type const &a ) > : s_save_( s ), a_save_( s.tie(a) ) > {} > ~basic_ios_tie_saver() > { this->restore(); } > > void restore() > { s_save_.tie( a_save_ ); } > >private: > state_type & s_save_; > aspect_type const a_save_; > basic_ios_tie_saver& operator=(const basic_ios_tie_saver&); >}; > >template < typename Ch, class Tr > >class basic_ios_rdbuf_saver >{ >public: > typedef ::std::basic_ios<Ch, Tr> state_type; > typedef ::std::basic_streambuf<Ch, Tr> * aspect_type; > > explicit basic_ios_rdbuf_saver( state_type &s ) > : s_save_( s ), a_save_( s.rdbuf() ) > {} > basic_ios_rdbuf_saver( state_type &s, aspect_type const &a ) > : s_save_( s ), a_save_( s.rdbuf(a) ) > {} > ~basic_ios_rdbuf_saver() > { this->restore(); } > > void restore() > { s_save_.rdbuf( a_save_ ); } > >private: > state_type & s_save_; > aspect_type const a_save_; > basic_ios_rdbuf_saver& operator=(const basic_ios_rdbuf_saver&); >}; > >template < typename Ch, class Tr > >class basic_ios_fill_saver >{ >public: > typedef ::std::basic_ios<Ch, Tr> state_type; > typedef typename state_type::char_type aspect_type; > > explicit basic_ios_fill_saver( state_type &s ) > : s_save_( s ), a_save_( s.fill() ) > {} > basic_ios_fill_saver( state_type &s, aspect_type const &a ) > : s_save_( s ), a_save_( s.fill(a) ) > {} > ~basic_ios_fill_saver() > { this->restore(); } > > void restore() > { s_save_.fill( a_save_ ); } > >private: > state_type & s_save_; > aspect_type const a_save_; > basic_ios_fill_saver& operator=(const basic_ios_fill_saver&); >}; > > >template < typename Ch, class Tr > >class basic_ios_locale_saver >{ >public: > typedef ::std::basic_ios<Ch, Tr> state_type; > typedef ::std::locale aspect_type; > > explicit basic_ios_locale_saver( state_type &s ) > : s_save_( s ), a_save_( s.getloc() ) > {} > basic_ios_locale_saver( state_type &s, aspect_type const &a ) > : s_save_( s ), a_save_( s.imbue(a) ) > {} > ~basic_ios_locale_saver() > { this->restore(); } > > void restore() > { s_save_.imbue( a_save_ ); } > >private: > state_type & s_save_; > aspect_type const a_save_; > basic_ios_locale_saver& operator=(const basic_ios_locale_saver&); >}; > > > > > >class ios_iword_saver >{ >public: > typedef ::std::ios_base state_type; > typedef int index_type; > typedef long aspect_type; > > explicit ios_iword_saver( state_type &s, index_type i ) > : s_save_( s ), a_save_( s.iword(i) ), i_save_( i ) > {} > ios_iword_saver( state_type &s, index_type i, aspect_type const &a ) > : s_save_( s ), a_save_( s.iword(i) ), i_save_( i ) > { s.iword(i) = a; } > ~ios_iword_saver() > { this->restore(); } > > void restore() > { s_save_.iword( i_save_ ) = a_save_; } > >private: > state_type & s_save_; > aspect_type const a_save_; > index_type const i_save_; > > ios_iword_saver& operator=(const ios_iword_saver&); >}; > >class ios_pword_saver >{ >public: > typedef ::std::ios_base state_type; > typedef int index_type; > typedef void * aspect_type; > > explicit ios_pword_saver( state_type &s, index_type i ) > : s_save_( s ), a_save_( s.pword(i) ), i_save_( i ) > {} > ios_pword_saver( state_type &s, index_type i, aspect_type const &a ) > : s_save_( s ), a_save_( s.pword(i) ), i_save_( i ) > { s.pword(i) = a; } > ~ios_pword_saver() > { this->restore(); } > > void restore() > { s_save_.pword( i_save_ ) = a_save_; } > >private: > state_type & s_save_; > aspect_type const a_save_; > index_type const i_save_; > > ios_pword_saver operator=(const ios_pword_saver&); >}; > > > > >class ios_base_all_saver >{ >public: > typedef ::std::ios_base state_type; > > explicit ios_base_all_saver( state_type &s ) > : s_save_( s ), a1_save_( s.flags() ), a2_save_( s.precision() ) > , a3_save_( s.width() ) > {} > > ~ios_base_all_saver() > { this->restore(); } > > void restore() > { > s_save_.width( a3_save_ ); > s_save_.precision( a2_save_ ); > s_save_.flags( a1_save_ ); > } > >private: > state_type & s_save_; > state_type::fmtflags const a1_save_; > ::std::streamsize const a2_save_; > ::std::streamsize const a3_save_; > > ios_base_all_saver& operator=(const ios_base_all_saver&); >}; > >template < typename Ch, class Tr > >class basic_ios_all_saver >{ >public: > typedef ::std::basic_ios<Ch, Tr> state_type; > > explicit basic_ios_all_saver( state_type &s ) > : s_save_( s ), a1_save_( s.flags() ), a2_save_( s.precision() ) > , a3_save_( s.width() ), a4_save_( s.rdstate() ) > , a5_save_( s.exceptions() ), a6_save_( s.tie() ) > , a7_save_( s.rdbuf() ), a8_save_( s.fill() ) > > , a9_save_( s.getloc() ) > > {} > > ~basic_ios_all_saver() > { this->restore(); } > > void restore() > { > > s_save_.imbue( a9_save_ ); > > s_save_.fill( a8_save_ ); > s_save_.rdbuf( a7_save_ ); > s_save_.tie( a6_save_ ); > s_save_.exceptions( a5_save_ ); > s_save_.clear( a4_save_ ); > s_save_.width( a3_save_ ); > s_save_.precision( a2_save_ ); > s_save_.flags( a1_save_ ); > } > >private: > state_type & s_save_; > typename state_type::fmtflags const a1_save_; > ::std::streamsize const a2_save_; > ::std::streamsize const a3_save_; > typename state_type::iostate const a4_save_; > typename state_type::iostate const a5_save_; > ::std::basic_ostream<Ch, Tr> * const a6_save_; > ::std::basic_streambuf<Ch, Tr> * const a7_save_; > typename state_type::char_type const a8_save_; > > ::std::locale const a9_save_; > > > basic_ios_all_saver& operator=(const basic_ios_all_saver&); >}; > >class ios_all_word_saver >{ >public: > typedef ::std::ios_base state_type; > typedef int index_type; > > ios_all_word_saver( state_type &s, index_type i ) > : s_save_( s ), i_save_( i ), a1_save_( s.iword(i) ) > , a2_save_( s.pword(i) ) > {} > > ~ios_all_word_saver() > { this->restore(); } > > void restore() > { > s_save_.pword( i_save_ ) = a2_save_; > s_save_.iword( i_save_ ) = a1_save_; > } > >private: > state_type & s_save_; > index_type const i_save_; > long const a1_save_; > void * const a2_save_; > > ios_all_word_saver& operator=(const ios_all_word_saver&); >}; > > >} >} ># 35 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 > > ># 1 "/usr/include/boost/functional/hash.hpp" 1 3 4 > > > > > ># 1 "/usr/include/boost/functional/hash/hash.hpp" 1 3 4 ># 13 "/usr/include/boost/functional/hash/hash.hpp" 3 4 ># 1 "/usr/include/boost/functional/hash/hash_fwd.hpp" 1 3 4 ># 21 "/usr/include/boost/functional/hash/hash_fwd.hpp" 3 4 >namespace boost >{ > template <class T> struct hash; > > > > > template <class T> void hash_combine(std::size_t& seed, T const& v); > > > template <class It> std::size_t hash_range(It, It); > template <class It> void hash_range(std::size_t&, It, It); > > > > > >} ># 14 "/usr/include/boost/functional/hash/hash.hpp" 2 3 4 > ># 1 "/usr/include/boost/functional/hash/detail/hash_float.hpp" 1 3 4 ># 14 "/usr/include/boost/functional/hash/detail/hash_float.hpp" 3 4 ># 1 "/usr/include/boost/functional/hash/detail/float_functions.hpp" 1 3 4 ># 76 "/usr/include/boost/functional/hash/detail/float_functions.hpp" 3 4 >namespace boost { > namespace hash_detail { > template <typename Float> > struct call_ldexp { > typedef Float float_type; > inline Float operator()(Float x, int y) const { > return std::ldexp(x, y); > } > }; > > template <typename Float> > struct call_frexp { > typedef Float float_type; > inline Float operator()(Float x, int* y) const { > return std::frexp(x, y); > } > }; > > template <typename Float> > struct select_hash_type > { > typedef Float type; > }; > } >} ># 15 "/usr/include/boost/functional/hash/detail/hash_float.hpp" 2 3 4 ># 1 "/usr/include/boost/functional/hash/detail/limits.hpp" 1 3 4 ># 26 "/usr/include/boost/functional/hash/detail/limits.hpp" 3 4 >namespace boost >{ > namespace hash_detail > { > template <class T> > struct limits : std::numeric_limits<T> {}; ># 58 "/usr/include/boost/functional/hash/detail/limits.hpp" 3 4 > } >} ># 16 "/usr/include/boost/functional/hash/detail/hash_float.hpp" 2 3 4 > ># 1 "/usr/include/boost/integer/static_log2.hpp" 1 3 4 ># 19 "/usr/include/boost/integer/static_log2.hpp" 3 4 ># 1 "/usr/include/boost/integer_fwd.hpp" 1 3 4 ># 12 "/usr/include/boost/integer_fwd.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 13 "/usr/include/boost/integer_fwd.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 18 "/usr/include/boost/integer_fwd.hpp" 2 3 4 > > >namespace boost >{ > > > > > > > > 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; ># 42 "/usr/include/boost/integer_fwd.hpp" 3 4 >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 >; > > >template < > > class integer_traits< wchar_t >; > > >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 >; > > >template < > >class integer_traits< ::boost::long_long_type>; > >template < > >class integer_traits< ::boost::ulong_long_type >; ># 97 "/usr/include/boost/integer_fwd.hpp" 3 4 >template < typename LeastInt > > struct int_fast_t; > >template< int Bits > > struct int_t; > >template< int Bits > > struct uint_t; > > > template< boost::long_long_type MaxValue > > > > > struct int_max_value_t; > > > template< boost::long_long_type MinValue > > > > > struct int_min_value_t; > > > template< boost::ulong_long_type MaxValue > > > > > struct uint_value_t; > > > > >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<unsigned char>::digits >; > > > >template <static_log2_argument_type Value > > struct static_log2; > >template <> struct static_log2<0u>; > > > > >template <static_min_max_signed_type Value1, static_min_max_signed_type Value2> > struct static_signed_min; > >template <static_min_max_signed_type Value1, static_min_max_signed_type Value2> > struct static_signed_max; > >template <static_min_max_unsigned_type Value1, static_min_max_unsigned_type Value2> > struct static_unsigned_min; > >template <static_min_max_unsigned_type Value1, static_min_max_unsigned_type Value2> > struct static_unsigned_max; > >} ># 20 "/usr/include/boost/integer/static_log2.hpp" 2 3 4 > >namespace boost { > > namespace detail { > > namespace static_log2_impl { ># 44 "/usr/include/boost/integer/static_log2.hpp" 3 4 > typedef boost::static_log2_argument_type argument_type; > typedef boost::static_log2_result_type result_type; > > template <result_type n> > struct choose_initial_n { > > static const bool c = (argument_type(1) << n << n) != 0; > static const result_type value = !c*n + choose_initial_n<2*c*n>::value > > > ; > > }; > > template <> > struct choose_initial_n<0> { > static const result_type value = 0; > }; > > > > > const result_type n_zero = 16; > const result_type initial_n = choose_initial_n<n_zero>::value; ># 84 "/usr/include/boost/integer/static_log2.hpp" 3 4 > template <argument_type x, result_type n = initial_n> > struct static_log2_impl { > > static const bool c = (x >> n) > 0; > static const result_type value = c*n + (static_log2_impl< (x>>c*n), n/2 >::value) > > > ; > > }; > > template <> > struct static_log2_impl<1, 0> { > static const result_type value = 0; > }; > > } > } > > > > > > > > template <static_log2_argument_type x> > struct static_log2 { > > static const static_log2_result_type value = detail::static_log2_impl::static_log2_impl<x>::value > > > ; > > }; > > > template <> > struct static_log2<0> { }; > >} ># 18 "/usr/include/boost/functional/hash/detail/hash_float.hpp" 2 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 19 "/usr/include/boost/functional/hash/detail/hash_float.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 20 "/usr/include/boost/functional/hash/detail/hash_float.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 22 "/usr/include/boost/functional/hash/detail/hash_float.hpp" 2 3 4 ># 51 "/usr/include/boost/functional/hash/detail/hash_float.hpp" 3 4 >namespace boost >{ > namespace hash_detail > { > inline void hash_float_combine(std::size_t& seed, std::size_t value) > { > seed ^= value + (seed<<6) + (seed>>2); > } > > > > > > > > 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 <typename Float, unsigned digits, unsigned max_exponent> > struct enable_binary_hash > { > static const bool value = std::numeric_limits<Float>::is_iec559 && std::numeric_limits<Float>::digits == digits && std::numeric_limits<Float>::radix == 2 && std::numeric_limits<Float>::max_exponent == max_exponent > > > > ; > }; > > template <typename Float> > inline std::size_t float_hash_impl(Float v, > typename boost::enable_if_c< > enable_binary_hash<Float, 24, 128>::value, > std::size_t>::type) > { > return hash_binary((char*) &v, 4); > } > > > template <typename Float> > inline std::size_t float_hash_impl(Float v, > typename boost::enable_if_c< > enable_binary_hash<Float, 53, 1024>::value, > std::size_t>::type) > { > return hash_binary((char*) &v, 8); > } > > template <typename Float> > inline std::size_t float_hash_impl(Float v, > typename boost::enable_if_c< > enable_binary_hash<Float, 64, 16384>::value, > std::size_t>::type) > { > return hash_binary((char*) &v, 10); > } > > template <typename Float> > inline std::size_t float_hash_impl(Float v, > typename boost::enable_if_c< > enable_binary_hash<Float, 113, 16384>::value, > std::size_t>::type) > { > return hash_binary((char*) &v, 16); > } > > > > > > > template <class T> > inline std::size_t float_hash_impl2(T v) > { > boost::hash_detail::call_frexp<T> frexp; > boost::hash_detail::call_ldexp<T> ldexp; > > int exp = 0; > > v = frexp(v, &exp); > > > > if(v < 0) { > v = -v; > exp += limits<T>::max_exponent - > limits<T>::min_exponent; > } > > v = ldexp(v, limits<std::size_t>::digits); > std::size_t seed = static_cast<std::size_t>(v); > v -= static_cast<T>(seed); > > > std::size_t const length > = (limits<T>::digits * > boost::static_log2<limits<T>::radix>::value > + limits<std::size_t>::digits - 1) > / limits<std::size_t>::digits; > > for(std::size_t i = 0; i != length; ++i) > { > v = ldexp(v, limits<std::size_t>::digits); > std::size_t part = static_cast<std::size_t>(v); > v -= static_cast<T>(part); > hash_float_combine(seed, part); > } > > hash_float_combine(seed, exp); > > return seed; > } > > > template <class T> > inline std::size_t float_hash_impl(T v, ...) > { > typedef typename select_hash_type<T>::type type; > return float_hash_impl2(static_cast<type>(v)); > } > > } >} > > > > > >namespace boost >{ > namespace hash_detail > { > template <class T> > inline std::size_t float_hash_value(T v) > { > > > > switch (std::fpclassify(v)) > > > > > { > case 2: > return 0; > case 1: > return (std::size_t)(v > 0 ? -1 : -2); > case 0: > return (std::size_t)(-3); > case 4: > case 3: > return float_hash_impl(v, 0); > default: > (static_cast<void> (0)); > return 0; > } > } > } >} ># 16 "/usr/include/boost/functional/hash/hash.hpp" 2 3 4 ># 27 "/usr/include/boost/functional/hash/hash.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/typeindex" 1 3 4 ># 32 "/usr/include/c++/4.9.0/typeindex" 3 4 ># 33 "/usr/include/c++/4.9.0/typeindex" 3 > > > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 52 "/usr/include/c++/4.9.0/typeindex" 3 > struct type_index > { > type_index(const type_info& __rhs) noexcept > : _M_target(&__rhs) { } > > bool > operator==(const type_index& __rhs) const noexcept > { return *_M_target == *__rhs._M_target; } > > bool > operator!=(const type_index& __rhs) const noexcept > { return *_M_target != *__rhs._M_target; } > > bool > operator<(const type_index& __rhs) const noexcept > { return _M_target->before(*__rhs._M_target); } > > bool > operator<=(const type_index& __rhs) const noexcept > { return !__rhs._M_target->before(*_M_target); } > > bool > operator>(const type_index& __rhs) const noexcept > { return __rhs._M_target->before(*_M_target); } > > bool > operator>=(const type_index& __rhs) const noexcept > { return !_M_target->before(*__rhs._M_target); } > > size_t > hash_code() const noexcept > { return _M_target->hash_code(); } > > const char* > name() const noexcept > { return _M_target->name(); } > > private: > const type_info* _M_target; > }; > > template<typename _Tp> struct hash; > > > template<> > struct hash<type_index> > { > typedef size_t result_type; > typedef type_index argument_type; > > size_t > operator()(const type_index& __ti) const noexcept > { return __ti.hash_code(); } > }; > > >} ># 28 "/usr/include/boost/functional/hash/hash.hpp" 2 3 4 ># 44 "/usr/include/boost/functional/hash/hash.hpp" 3 4 >namespace boost >{ > namespace hash_detail > { > struct enable_hash_value { typedef std::size_t type; }; > > template <typename T> struct basic_numbers {}; > template <typename T> struct long_numbers; > template <typename T> struct ulong_numbers; > template <typename T> struct float_numbers {}; > > template <> struct basic_numbers<bool> : > boost::hash_detail::enable_hash_value {}; > template <> struct basic_numbers<char> : > boost::hash_detail::enable_hash_value {}; > template <> struct basic_numbers<unsigned char> : > boost::hash_detail::enable_hash_value {}; > template <> struct basic_numbers<signed char> : > boost::hash_detail::enable_hash_value {}; > template <> struct basic_numbers<short> : > boost::hash_detail::enable_hash_value {}; > template <> struct basic_numbers<unsigned short> : > boost::hash_detail::enable_hash_value {}; > template <> struct basic_numbers<int> : > boost::hash_detail::enable_hash_value {}; > template <> struct basic_numbers<unsigned int> : > boost::hash_detail::enable_hash_value {}; > template <> struct basic_numbers<long> : > boost::hash_detail::enable_hash_value {}; > template <> struct basic_numbers<unsigned long> : > boost::hash_detail::enable_hash_value {}; > > > template <> struct basic_numbers<wchar_t> : > boost::hash_detail::enable_hash_value {}; > > > > > > template <typename T> struct long_numbers2 {}; > template <typename T> struct ulong_numbers2 {}; > template <typename T> struct long_numbers : long_numbers2<T> {}; > template <typename T> struct ulong_numbers : ulong_numbers2<T> {}; > > > template <> struct long_numbers<boost::long_long_type> : > boost::hash_detail::enable_hash_value {}; > template <> struct ulong_numbers<boost::ulong_long_type> : > boost::hash_detail::enable_hash_value {}; > > > > template <> struct long_numbers2<boost::int128_type> : > boost::hash_detail::enable_hash_value {}; > template <> struct ulong_numbers2<boost::uint128_type> : > boost::hash_detail::enable_hash_value {}; > > > template <> struct float_numbers<float> : > boost::hash_detail::enable_hash_value {}; > template <> struct float_numbers<double> : > boost::hash_detail::enable_hash_value {}; > template <> struct float_numbers<long double> : > boost::hash_detail::enable_hash_value {}; > } > > template <typename T> > typename boost::hash_detail::basic_numbers<T>::type hash_value(T); > template <typename T> > typename boost::hash_detail::long_numbers<T>::type hash_value(T); > template <typename T> > typename boost::hash_detail::ulong_numbers<T>::type hash_value(T); > > template <typename T> > typename boost::enable_if<boost::is_enum<T>, std::size_t>::type > hash_value(T); > > > template <class T> std::size_t hash_value(T* const&); > > > > > > 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]); > > > template <class Ch, class A> > std::size_t hash_value( > std::basic_string<Ch, std::char_traits<Ch>, A> const&); > > template <typename T> > typename boost::hash_detail::float_numbers<T>::type hash_value(T); > > > std::size_t hash_value(std::type_index); > > > > > namespace hash_detail > { > template <class T> > inline std::size_t hash_value_signed(T val) > { > const int size_t_bits = std::numeric_limits<std::size_t>::digits; > > const int length = (std::numeric_limits<T>::digits - 1) > / size_t_bits; > > std::size_t seed = 0; > T positive = val < 0 ? -1 - val : val; > > > 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 <class T> > inline std::size_t hash_value_unsigned(T val) > { > const int size_t_bits = std::numeric_limits<std::size_t>::digits; > > const int length = (std::numeric_limits<T>::digits - 1) > / size_t_bits; > > std::size_t seed = 0; > > > 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 T> > typename boost::hash_detail::basic_numbers<T>::type hash_value(T v) > { > return static_cast<std::size_t>(v); > } > > template <typename T> > typename boost::hash_detail::long_numbers<T>::type hash_value(T v) > { > return hash_detail::hash_value_signed(v); > } > > template <typename T> > typename boost::hash_detail::ulong_numbers<T>::type hash_value(T v) > { > return hash_detail::hash_value_unsigned(v); > } > > template <typename T> > typename boost::enable_if<boost::is_enum<T>, std::size_t>::type > hash_value(T v) > { > return static_cast<std::size_t>(v); > } > > > > template <class T> std::size_t hash_value(T* const& v) > > > > { > > > > > > > std::size_t x = static_cast<std::size_t>( > reinterpret_cast<std::ptrdiff_t>(v)); > > return x + (x >> 3); > } ># 251 "/usr/include/boost/functional/hash/hash.hpp" 3 4 > template <class T> > inline void hash_combine(std::size_t& seed, T const& v) > > { > boost::hash<T> hasher; > seed ^= hasher(v) + 0x9e3779b9 + (seed<<6) + (seed>>2); > } > > > > > > template <class It> > 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 <class It> > inline void hash_range(std::size_t& seed, It first, It last) > { > for(; first != last; ++first) > { > hash_combine(seed, *first); > } > } ># 312 "/usr/include/boost/functional/hash/hash.hpp" 3 4 > 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); > } > > > template <class Ch, class A> > inline std::size_t hash_value( > std::basic_string<Ch, std::char_traits<Ch>, A> const& v) > { > return hash_range(v.begin(), v.end()); > } > > template <typename T> > typename boost::hash_detail::float_numbers<T>::type hash_value(T v) > { > return boost::hash_detail::float_hash_value(v); > } > > > inline std::size_t hash_value(std::type_index v) > { > return v.hash_code(); > } ># 421 "/usr/include/boost/functional/hash/hash.hpp" 3 4 > template <> struct hash<bool> : public std::unary_function<bool, std::size_t> { std::size_t operator()(bool v) const { return boost::hash_value(v); } }; > template <> struct hash<char> : public std::unary_function<char, std::size_t> { std::size_t operator()(char v) const { return boost::hash_value(v); } }; > template <> struct hash<signed char> : public std::unary_function<signed char, std::size_t> { std::size_t operator()(signed char v) const { return boost::hash_value(v); } }; > template <> struct hash<unsigned char> : public std::unary_function<unsigned char, std::size_t> { std::size_t operator()(unsigned char v) const { return boost::hash_value(v); } }; > > template <> struct hash<wchar_t> : public std::unary_function<wchar_t, std::size_t> { std::size_t operator()(wchar_t v) const { return boost::hash_value(v); } }; > > template <> struct hash<short> : public std::unary_function<short, std::size_t> { std::size_t operator()(short v) const { return boost::hash_value(v); } }; > template <> struct hash<unsigned short> : public std::unary_function<unsigned short, std::size_t> { std::size_t operator()(unsigned short v) const { return boost::hash_value(v); } }; > template <> struct hash<int> : public std::unary_function<int, std::size_t> { std::size_t operator()(int v) const { return boost::hash_value(v); } }; > template <> struct hash<unsigned int> : public std::unary_function<unsigned int, std::size_t> { std::size_t operator()(unsigned int v) const { return boost::hash_value(v); } }; > template <> struct hash<long> : public std::unary_function<long, std::size_t> { std::size_t operator()(long v) const { return boost::hash_value(v); } }; > template <> struct hash<unsigned long> : public std::unary_function<unsigned long, std::size_t> { std::size_t operator()(unsigned long v) const { return boost::hash_value(v); } }; > > template <> struct hash<float> : public std::unary_function<float, std::size_t> { std::size_t operator()(float v) const { return boost::hash_value(v); } }; > template <> struct hash<double> : public std::unary_function<double, std::size_t> { std::size_t operator()(double v) const { return boost::hash_value(v); } }; > template <> struct hash<long double> : public std::unary_function<long double, std::size_t> { std::size_t operator()(long double v) const { return boost::hash_value(v); } }; > > template <> struct hash<std::string> : public std::unary_function<std::string, std::size_t> { std::size_t operator()(std::string const& v) const { return boost::hash_value(v); } }; > > template <> struct hash<std::wstring> : public std::unary_function<std::wstring, std::size_t> { std::size_t operator()(std::wstring const& v) const { return boost::hash_value(v); } }; > > > > template <> struct hash<boost::long_long_type> : public std::unary_function<boost::long_long_type, std::size_t> { std::size_t operator()(boost::long_long_type v) const { return boost::hash_value(v); } }; > template <> struct hash<boost::ulong_long_type> : public std::unary_function<boost::ulong_long_type, std::size_t> { std::size_t operator()(boost::ulong_long_type v) const { return boost::hash_value(v); } }; > > > > template <> struct hash<boost::int128_type> : public std::unary_function<boost::int128_type, std::size_t> { std::size_t operator()(boost::int128_type v) const { return boost::hash_value(v); } }; > template <> struct hash<boost::uint128_type> : public std::unary_function<boost::uint128_type, std::size_t> { std::size_t operator()(boost::uint128_type v) const { return boost::hash_value(v); } }; > > > > template <> struct hash<std::type_index> : public std::unary_function<std::type_index, std::size_t> { std::size_t operator()(std::type_index v) const { return boost::hash_value(v); } }; ># 465 "/usr/include/boost/functional/hash/hash.hpp" 3 4 > template <class T> > struct hash<T*> > : public std::unary_function<T*, std::size_t> > { > std::size_t operator()(T* v) const > { > > return boost::hash_value(v); > > > > > > > } > }; ># 524 "/usr/include/boost/functional/hash/hash.hpp" 3 4 >} ># 540 "/usr/include/boost/functional/hash/hash.hpp" 3 4 ># 1 "/usr/include/boost/functional/hash/extensions.hpp" 1 3 4 ># 16 "/usr/include/boost/functional/hash/extensions.hpp" 3 4 ># 1 "/usr/include/boost/functional/hash/hash.hpp" 1 3 4 ># 17 "/usr/include/boost/functional/hash/extensions.hpp" 2 3 4 ># 1 "/usr/include/boost/detail/container_fwd.hpp" 1 3 4 ># 91 "/usr/include/boost/detail/container_fwd.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/deque" 1 3 4 ># 58 "/usr/include/c++/4.9.0/deque" 3 4 ># 59 "/usr/include/c++/4.9.0/deque" 3 > > > > > ># 1 "/usr/include/c++/4.9.0/bits/stl_deque.h" 1 3 ># 66 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 88 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > inline size_t > __deque_buf_size(size_t __size) > { return (__size < 512 > ? size_t(512 / __size) : size_t(1)); } ># 105 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _Tp, typename _Ref, typename _Ptr> > struct _Deque_iterator > { > typedef _Deque_iterator<_Tp, _Tp&, _Tp*> iterator; > typedef _Deque_iterator<_Tp, const _Tp&, const _Tp*> const_iterator; > > static size_t _S_buffer_size() noexcept > { return __deque_buf_size(sizeof(_Tp)); } > > typedef std::random_access_iterator_tag iterator_category; > typedef _Tp value_type; > typedef _Ptr pointer; > typedef _Ref reference; > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef _Tp** _Map_pointer; > typedef _Deque_iterator _Self; > > _Tp* _M_cur; > _Tp* _M_first; > _Tp* _M_last; > _Map_pointer _M_node; > > _Deque_iterator(_Tp* __x, _Map_pointer __y) noexcept > : _M_cur(__x), _M_first(*__y), > _M_last(*__y + _S_buffer_size()), _M_node(__y) { } > > _Deque_iterator() noexcept > : _M_cur(0), _M_first(0), _M_last(0), _M_node(0) { } > > _Deque_iterator(const iterator& __x) noexcept > : _M_cur(__x._M_cur), _M_first(__x._M_first), > _M_last(__x._M_last), _M_node(__x._M_node) { } > > iterator > _M_const_cast() const noexcept > { return iterator(_M_cur, _M_node); } > > reference > operator*() const noexcept > { return *_M_cur; } > > pointer > operator->() const noexcept > { return _M_cur; } > > _Self& > operator++() noexcept > { > ++_M_cur; > if (_M_cur == _M_last) > { > _M_set_node(_M_node + 1); > _M_cur = _M_first; > } > return *this; > } > > _Self > operator++(int) noexcept > { > _Self __tmp = *this; > ++*this; > return __tmp; > } > > _Self& > operator--() noexcept > { > if (_M_cur == _M_first) > { > _M_set_node(_M_node - 1); > _M_cur = _M_last; > } > --_M_cur; > return *this; > } > > _Self > operator--(int) noexcept > { > _Self __tmp = *this; > --*this; > return __tmp; > } > > _Self& > operator+=(difference_type __n) noexcept > { > const difference_type __offset = __n + (_M_cur - _M_first); > if (__offset >= 0 && __offset < difference_type(_S_buffer_size())) > _M_cur += __n; > else > { > const difference_type __node_offset = > __offset > 0 ? __offset / difference_type(_S_buffer_size()) > : -difference_type((-__offset - 1) > / _S_buffer_size()) - 1; > _M_set_node(_M_node + __node_offset); > _M_cur = _M_first + (__offset - __node_offset > * difference_type(_S_buffer_size())); > } > return *this; > } > > _Self > operator+(difference_type __n) const noexcept > { > _Self __tmp = *this; > return __tmp += __n; > } > > _Self& > operator-=(difference_type __n) noexcept > { return *this += -__n; } > > _Self > operator-(difference_type __n) const noexcept > { > _Self __tmp = *this; > return __tmp -= __n; > } > > reference > operator[](difference_type __n) const noexcept > { return *(*this + __n); } > > > > > > > void > _M_set_node(_Map_pointer __new_node) noexcept > { > _M_node = __new_node; > _M_first = *__new_node; > _M_last = _M_first + difference_type(_S_buffer_size()); > } > }; > > > > > template<typename _Tp, typename _Ref, typename _Ptr> > inline bool > operator==(const _Deque_iterator<_Tp, _Ref, _Ptr>& __x, > const _Deque_iterator<_Tp, _Ref, _Ptr>& __y) noexcept > { return __x._M_cur == __y._M_cur; } > > template<typename _Tp, typename _RefL, typename _PtrL, > typename _RefR, typename _PtrR> > inline bool > operator==(const _Deque_iterator<_Tp, _RefL, _PtrL>& __x, > const _Deque_iterator<_Tp, _RefR, _PtrR>& __y) noexcept > { return __x._M_cur == __y._M_cur; } > > template<typename _Tp, typename _Ref, typename _Ptr> > inline bool > operator!=(const _Deque_iterator<_Tp, _Ref, _Ptr>& __x, > const _Deque_iterator<_Tp, _Ref, _Ptr>& __y) noexcept > { return !(__x == __y); } > > template<typename _Tp, typename _RefL, typename _PtrL, > typename _RefR, typename _PtrR> > inline bool > operator!=(const _Deque_iterator<_Tp, _RefL, _PtrL>& __x, > const _Deque_iterator<_Tp, _RefR, _PtrR>& __y) noexcept > { return !(__x == __y); } > > template<typename _Tp, typename _Ref, typename _Ptr> > inline bool > operator<(const _Deque_iterator<_Tp, _Ref, _Ptr>& __x, > const _Deque_iterator<_Tp, _Ref, _Ptr>& __y) noexcept > { return (__x._M_node == __y._M_node) ? (__x._M_cur < __y._M_cur) > : (__x._M_node < __y._M_node); } > > template<typename _Tp, typename _RefL, typename _PtrL, > typename _RefR, typename _PtrR> > inline bool > operator<(const _Deque_iterator<_Tp, _RefL, _PtrL>& __x, > const _Deque_iterator<_Tp, _RefR, _PtrR>& __y) noexcept > { return (__x._M_node == __y._M_node) ? (__x._M_cur < __y._M_cur) > : (__x._M_node < __y._M_node); } > > template<typename _Tp, typename _Ref, typename _Ptr> > inline bool > operator>(const _Deque_iterator<_Tp, _Ref, _Ptr>& __x, > const _Deque_iterator<_Tp, _Ref, _Ptr>& __y) noexcept > { return __y < __x; } > > template<typename _Tp, typename _RefL, typename _PtrL, > typename _RefR, typename _PtrR> > inline bool > operator>(const _Deque_iterator<_Tp, _RefL, _PtrL>& __x, > const _Deque_iterator<_Tp, _RefR, _PtrR>& __y) noexcept > { return __y < __x; } > > template<typename _Tp, typename _Ref, typename _Ptr> > inline bool > operator<=(const _Deque_iterator<_Tp, _Ref, _Ptr>& __x, > const _Deque_iterator<_Tp, _Ref, _Ptr>& __y) noexcept > { return !(__y < __x); } > > template<typename _Tp, typename _RefL, typename _PtrL, > typename _RefR, typename _PtrR> > inline bool > operator<=(const _Deque_iterator<_Tp, _RefL, _PtrL>& __x, > const _Deque_iterator<_Tp, _RefR, _PtrR>& __y) noexcept > { return !(__y < __x); } > > template<typename _Tp, typename _Ref, typename _Ptr> > inline bool > operator>=(const _Deque_iterator<_Tp, _Ref, _Ptr>& __x, > const _Deque_iterator<_Tp, _Ref, _Ptr>& __y) noexcept > { return !(__x < __y); } > > template<typename _Tp, typename _RefL, typename _PtrL, > typename _RefR, typename _PtrR> > inline bool > operator>=(const _Deque_iterator<_Tp, _RefL, _PtrL>& __x, > const _Deque_iterator<_Tp, _RefR, _PtrR>& __y) noexcept > { return !(__x < __y); } > > > > > > template<typename _Tp, typename _Ref, typename _Ptr> > inline typename _Deque_iterator<_Tp, _Ref, _Ptr>::difference_type > operator-(const _Deque_iterator<_Tp, _Ref, _Ptr>& __x, > const _Deque_iterator<_Tp, _Ref, _Ptr>& __y) noexcept > { > return typename _Deque_iterator<_Tp, _Ref, _Ptr>::difference_type > (_Deque_iterator<_Tp, _Ref, _Ptr>::_S_buffer_size()) > * (__x._M_node - __y._M_node - 1) + (__x._M_cur - __x._M_first) > + (__y._M_last - __y._M_cur); > } > > template<typename _Tp, typename _RefL, typename _PtrL, > typename _RefR, typename _PtrR> > inline typename _Deque_iterator<_Tp, _RefL, _PtrL>::difference_type > operator-(const _Deque_iterator<_Tp, _RefL, _PtrL>& __x, > const _Deque_iterator<_Tp, _RefR, _PtrR>& __y) noexcept > { > return typename _Deque_iterator<_Tp, _RefL, _PtrL>::difference_type > (_Deque_iterator<_Tp, _RefL, _PtrL>::_S_buffer_size()) > * (__x._M_node - __y._M_node - 1) + (__x._M_cur - __x._M_first) > + (__y._M_last - __y._M_cur); > } > > template<typename _Tp, typename _Ref, typename _Ptr> > inline _Deque_iterator<_Tp, _Ref, _Ptr> > operator+(ptrdiff_t __n, const _Deque_iterator<_Tp, _Ref, _Ptr>& __x) > noexcept > { return __x + __n; } > > template<typename _Tp> > void > fill(const _Deque_iterator<_Tp, _Tp&, _Tp*>&, > const _Deque_iterator<_Tp, _Tp&, _Tp*>&, const _Tp&); > > template<typename _Tp> > _Deque_iterator<_Tp, _Tp&, _Tp*> > copy(_Deque_iterator<_Tp, const _Tp&, const _Tp*>, > _Deque_iterator<_Tp, const _Tp&, const _Tp*>, > _Deque_iterator<_Tp, _Tp&, _Tp*>); > > template<typename _Tp> > inline _Deque_iterator<_Tp, _Tp&, _Tp*> > copy(_Deque_iterator<_Tp, _Tp&, _Tp*> __first, > _Deque_iterator<_Tp, _Tp&, _Tp*> __last, > _Deque_iterator<_Tp, _Tp&, _Tp*> __result) > { return std::copy(_Deque_iterator<_Tp, const _Tp&, const _Tp*>(__first), > _Deque_iterator<_Tp, const _Tp&, const _Tp*>(__last), > __result); } > > template<typename _Tp> > _Deque_iterator<_Tp, _Tp&, _Tp*> > copy_backward(_Deque_iterator<_Tp, const _Tp&, const _Tp*>, > _Deque_iterator<_Tp, const _Tp&, const _Tp*>, > _Deque_iterator<_Tp, _Tp&, _Tp*>); > > template<typename _Tp> > inline _Deque_iterator<_Tp, _Tp&, _Tp*> > copy_backward(_Deque_iterator<_Tp, _Tp&, _Tp*> __first, > _Deque_iterator<_Tp, _Tp&, _Tp*> __last, > _Deque_iterator<_Tp, _Tp&, _Tp*> __result) > { return std::copy_backward(_Deque_iterator<_Tp, > const _Tp&, const _Tp*>(__first), > _Deque_iterator<_Tp, > const _Tp&, const _Tp*>(__last), > __result); } > > > template<typename _Tp> > _Deque_iterator<_Tp, _Tp&, _Tp*> > move(_Deque_iterator<_Tp, const _Tp&, const _Tp*>, > _Deque_iterator<_Tp, const _Tp&, const _Tp*>, > _Deque_iterator<_Tp, _Tp&, _Tp*>); > > template<typename _Tp> > inline _Deque_iterator<_Tp, _Tp&, _Tp*> > move(_Deque_iterator<_Tp, _Tp&, _Tp*> __first, > _Deque_iterator<_Tp, _Tp&, _Tp*> __last, > _Deque_iterator<_Tp, _Tp&, _Tp*> __result) > { return std::move(_Deque_iterator<_Tp, const _Tp&, const _Tp*>(__first), > _Deque_iterator<_Tp, const _Tp&, const _Tp*>(__last), > __result); } > > template<typename _Tp> > _Deque_iterator<_Tp, _Tp&, _Tp*> > move_backward(_Deque_iterator<_Tp, const _Tp&, const _Tp*>, > _Deque_iterator<_Tp, const _Tp&, const _Tp*>, > _Deque_iterator<_Tp, _Tp&, _Tp*>); > > template<typename _Tp> > inline _Deque_iterator<_Tp, _Tp&, _Tp*> > move_backward(_Deque_iterator<_Tp, _Tp&, _Tp*> __first, > _Deque_iterator<_Tp, _Tp&, _Tp*> __last, > _Deque_iterator<_Tp, _Tp&, _Tp*> __result) > { return std::move_backward(_Deque_iterator<_Tp, > const _Tp&, const _Tp*>(__first), > _Deque_iterator<_Tp, > const _Tp&, const _Tp*>(__last), > __result); } ># 443 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _Tp, typename _Alloc> > class _Deque_base > { > public: > typedef _Alloc allocator_type; > > allocator_type > get_allocator() const noexcept > { return allocator_type(_M_get_Tp_allocator()); } > > typedef _Deque_iterator<_Tp, _Tp&, _Tp*> iterator; > typedef _Deque_iterator<_Tp, const _Tp&, const _Tp*> const_iterator; > > _Deque_base() > : _M_impl() > { _M_initialize_map(0); } > > _Deque_base(size_t __num_elements) > : _M_impl() > { _M_initialize_map(__num_elements); } > > _Deque_base(const allocator_type& __a, size_t __num_elements) > : _M_impl(__a) > { _M_initialize_map(__num_elements); } > > _Deque_base(const allocator_type& __a) > : _M_impl(__a) > { } > > > _Deque_base(_Deque_base&& __x) > : _M_impl(std::move(__x._M_get_Tp_allocator())) > { > _M_initialize_map(0); > if (__x._M_impl._M_map) > { > std::swap(this->_M_impl._M_start, __x._M_impl._M_start); > std::swap(this->_M_impl._M_finish, __x._M_impl._M_finish); > std::swap(this->_M_impl._M_map, __x._M_impl._M_map); > std::swap(this->_M_impl._M_map_size, __x._M_impl._M_map_size); > } > } > > > ~_Deque_base() noexcept; > > protected: > typedef typename _Alloc::template rebind<_Tp*>::other _Map_alloc_type; > > typedef typename _Alloc::template rebind<_Tp>::other _Tp_alloc_type; > > > > > struct _Deque_impl > : public _Tp_alloc_type > { > _Tp** _M_map; > size_t _M_map_size; > iterator _M_start; > iterator _M_finish; > > _Deque_impl() > : _Tp_alloc_type(), _M_map(0), _M_map_size(0), > _M_start(), _M_finish() > { } > > _Deque_impl(const _Tp_alloc_type& __a) noexcept > : _Tp_alloc_type(__a), _M_map(0), _M_map_size(0), > _M_start(), _M_finish() > { } > > > _Deque_impl(_Tp_alloc_type&& __a) noexcept > : _Tp_alloc_type(std::move(__a)), _M_map(0), _M_map_size(0), > _M_start(), _M_finish() > { } > > }; > > _Tp_alloc_type& > _M_get_Tp_allocator() noexcept > { return *static_cast<_Tp_alloc_type*>(&this->_M_impl); } > > const _Tp_alloc_type& > _M_get_Tp_allocator() const noexcept > { return *static_cast<const _Tp_alloc_type*>(&this->_M_impl); } > > _Map_alloc_type > _M_get_map_allocator() const noexcept > { return _Map_alloc_type(_M_get_Tp_allocator()); } > > _Tp* > _M_allocate_node() > { > return _M_impl._Tp_alloc_type::allocate(__deque_buf_size(sizeof(_Tp))); > } > > void > _M_deallocate_node(_Tp* __p) noexcept > { > _M_impl._Tp_alloc_type::deallocate(__p, __deque_buf_size(sizeof(_Tp))); > } > > _Tp** > _M_allocate_map(size_t __n) > { return _M_get_map_allocator().allocate(__n); } > > void > _M_deallocate_map(_Tp** __p, size_t __n) noexcept > { _M_get_map_allocator().deallocate(__p, __n); } > > protected: > void _M_initialize_map(size_t); > void _M_create_nodes(_Tp** __nstart, _Tp** __nfinish); > void _M_destroy_nodes(_Tp** __nstart, _Tp** __nfinish) noexcept; > enum { _S_initial_map_size = 8 }; > > _Deque_impl _M_impl; > }; > > template<typename _Tp, typename _Alloc> > _Deque_base<_Tp, _Alloc>:: > ~_Deque_base() noexcept > { > if (this->_M_impl._M_map) > { > _M_destroy_nodes(this->_M_impl._M_start._M_node, > this->_M_impl._M_finish._M_node + 1); > _M_deallocate_map(this->_M_impl._M_map, this->_M_impl._M_map_size); > } > } ># 584 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _Tp, typename _Alloc> > void > _Deque_base<_Tp, _Alloc>:: > _M_initialize_map(size_t __num_elements) > { > const size_t __num_nodes = (__num_elements/ __deque_buf_size(sizeof(_Tp)) > + 1); > > this->_M_impl._M_map_size = std::max((size_t) _S_initial_map_size, > size_t(__num_nodes + 2)); > this->_M_impl._M_map = _M_allocate_map(this->_M_impl._M_map_size); > > > > > > > _Tp** __nstart = (this->_M_impl._M_map > + (this->_M_impl._M_map_size - __num_nodes) / 2); > _Tp** __nfinish = __nstart + __num_nodes; > > try > { _M_create_nodes(__nstart, __nfinish); } > catch(...) > { > _M_deallocate_map(this->_M_impl._M_map, this->_M_impl._M_map_size); > this->_M_impl._M_map = 0; > this->_M_impl._M_map_size = 0; > throw; > } > > this->_M_impl._M_start._M_set_node(__nstart); > this->_M_impl._M_finish._M_set_node(__nfinish - 1); > this->_M_impl._M_start._M_cur = _M_impl._M_start._M_first; > this->_M_impl._M_finish._M_cur = (this->_M_impl._M_finish._M_first > + __num_elements > % __deque_buf_size(sizeof(_Tp))); > } > > template<typename _Tp, typename _Alloc> > void > _Deque_base<_Tp, _Alloc>:: > _M_create_nodes(_Tp** __nstart, _Tp** __nfinish) > { > _Tp** __cur; > try > { > for (__cur = __nstart; __cur < __nfinish; ++__cur) > *__cur = this->_M_allocate_node(); > } > catch(...) > { > _M_destroy_nodes(__nstart, __cur); > throw; > } > } > > template<typename _Tp, typename _Alloc> > void > _Deque_base<_Tp, _Alloc>:: > _M_destroy_nodes(_Tp** __nstart, _Tp** __nfinish) noexcept > { > for (_Tp** __n = __nstart; __n < __nfinish; ++__n) > _M_deallocate_node(*__n); > } ># 734 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _Tp, typename _Alloc = std::allocator<_Tp> > > class deque : protected _Deque_base<_Tp, _Alloc> > { > > typedef typename _Alloc::value_type _Alloc_value_type; > > > > typedef _Deque_base<_Tp, _Alloc> _Base; > typedef typename _Base::_Tp_alloc_type _Tp_alloc_type; > > public: > typedef _Tp value_type; > typedef typename _Tp_alloc_type::pointer pointer; > typedef typename _Tp_alloc_type::const_pointer const_pointer; > typedef typename _Tp_alloc_type::reference reference; > typedef typename _Tp_alloc_type::const_reference const_reference; > typedef typename _Base::iterator iterator; > typedef typename _Base::const_iterator const_iterator; > typedef std::reverse_iterator<const_iterator> const_reverse_iterator; > typedef std::reverse_iterator<iterator> reverse_iterator; > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef _Alloc allocator_type; > > protected: > typedef pointer* _Map_pointer; > > static size_t _S_buffer_size() noexcept > { return __deque_buf_size(sizeof(_Tp)); } > > > using _Base::_M_initialize_map; > using _Base::_M_create_nodes; > using _Base::_M_destroy_nodes; > using _Base::_M_allocate_node; > using _Base::_M_deallocate_node; > using _Base::_M_allocate_map; > using _Base::_M_deallocate_map; > using _Base::_M_get_Tp_allocator; > > > > > > using _Base::_M_impl; > > public: > > > > > > > deque() : _Base() { } > > > > > > explicit > deque(const allocator_type& __a) > : _Base(__a, 0) { } ># 806 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > explicit > deque(size_type __n) > : _Base(__n) > { _M_default_initialize(); } ># 819 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > deque(size_type __n, const value_type& __value, > const allocator_type& __a = allocator_type()) > : _Base(__a, __n) > { _M_fill_initialize(__value); } ># 846 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > deque(const deque& __x) > : _Base(__x._M_get_Tp_allocator(), __x.size()) > { std::__uninitialized_copy_a(__x.begin(), __x.end(), > this->_M_impl._M_start, > _M_get_Tp_allocator()); } ># 860 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > deque(deque&& __x) > : _Base(std::move(__x)) { } ># 874 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > deque(initializer_list<value_type> __l, > const allocator_type& __a = allocator_type()) > : _Base(__a) > { > _M_range_initialize(__l.begin(), __l.end(), > random_access_iterator_tag()); > } ># 899 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > deque(_InputIterator __first, _InputIterator __last, > const allocator_type& __a = allocator_type()) > : _Base(__a) > { _M_initialize_dispatch(__first, __last, __false_type()); } ># 922 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > ~deque() noexcept > { _M_destroy_data(begin(), end(), _M_get_Tp_allocator()); } ># 932 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > deque& > operator=(const deque& __x); ># 943 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > deque& > operator=(deque&& __x) noexcept > { > > > this->clear(); > this->swap(__x); > return *this; > } ># 964 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > deque& > operator=(initializer_list<value_type> __l) > { > this->assign(__l.begin(), __l.end()); > return *this; > } ># 982 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > assign(size_type __n, const value_type& __val) > { _M_fill_assign(__n, __val); } ># 999 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > void > assign(_InputIterator __first, _InputIterator __last) > { _M_assign_dispatch(__first, __last, __false_type()); } ># 1026 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > assign(initializer_list<value_type> __l) > { this->assign(__l.begin(), __l.end()); } > > > > allocator_type > get_allocator() const noexcept > { return _Base::get_allocator(); } > > > > > > > iterator > begin() noexcept > { return this->_M_impl._M_start; } > > > > > > const_iterator > begin() const noexcept > { return this->_M_impl._M_start; } > > > > > > > iterator > end() noexcept > { return this->_M_impl._M_finish; } > > > > > > > const_iterator > end() const noexcept > { return this->_M_impl._M_finish; } > > > > > > > reverse_iterator > rbegin() noexcept > { return reverse_iterator(this->_M_impl._M_finish); } > > > > > > > const_reverse_iterator > rbegin() const noexcept > { return const_reverse_iterator(this->_M_impl._M_finish); } > > > > > > > reverse_iterator > rend() noexcept > { return reverse_iterator(this->_M_impl._M_start); } > > > > > > > const_reverse_iterator > rend() const noexcept > { return const_reverse_iterator(this->_M_impl._M_start); } > > > > > > > const_iterator > cbegin() const noexcept > { return this->_M_impl._M_start; } > > > > > > > const_iterator > cend() const noexcept > { return this->_M_impl._M_finish; } > > > > > > > const_reverse_iterator > crbegin() const noexcept > { return const_reverse_iterator(this->_M_impl._M_finish); } > > > > > > > const_reverse_iterator > crend() const noexcept > { return const_reverse_iterator(this->_M_impl._M_start); } > > > > > size_type > size() const noexcept > { return this->_M_impl._M_finish - this->_M_impl._M_start; } > > > size_type > max_size() const noexcept > { return _M_get_Tp_allocator().max_size(); } ># 1165 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > resize(size_type __new_size) > { > const size_type __len = size(); > if (__new_size > __len) > _M_default_append(__new_size - __len); > else if (__new_size < __len) > _M_erase_at_end(this->_M_impl._M_start > + difference_type(__new_size)); > } ># 1187 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > resize(size_type __new_size, const value_type& __x) > { > const size_type __len = size(); > if (__new_size > __len) > insert(this->_M_impl._M_finish, __new_size - __len, __x); > else if (__new_size < __len) > _M_erase_at_end(this->_M_impl._M_start > + difference_type(__new_size)); > } ># 1223 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > shrink_to_fit() noexcept > { _M_shrink_to_fit(); } > > > > > > > bool > empty() const noexcept > { return this->_M_impl._M_finish == this->_M_impl._M_start; } ># 1248 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > reference > operator[](size_type __n) noexcept > { return this->_M_impl._M_start[difference_type(__n)]; } ># 1263 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > const_reference > operator[](size_type __n) const noexcept > { return this->_M_impl._M_start[difference_type(__n)]; } > > protected: > > void > _M_range_check(size_type __n) const > { > if (__n >= this->size()) > __throw_out_of_range_fmt(("deque::_M_range_check: __n " "(which is %zu)>= this->size() " "(which is %zu)") > > , > __n, this->size()); > } > > public: ># 1291 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > reference > at(size_type __n) > { > _M_range_check(__n); > return (*this)[__n]; > } ># 1309 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > const_reference > at(size_type __n) const > { > _M_range_check(__n); > return (*this)[__n]; > } > > > > > > reference > front() noexcept > { return *begin(); } > > > > > > const_reference > front() const noexcept > { return *begin(); } > > > > > > reference > back() noexcept > { > iterator __tmp = end(); > --__tmp; > return *__tmp; > } > > > > > > const_reference > back() const noexcept > { > const_iterator __tmp = end(); > --__tmp; > return *__tmp; > } ># 1366 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > push_front(const value_type& __x) > { > if (this->_M_impl._M_start._M_cur != this->_M_impl._M_start._M_first) > { > this->_M_impl.construct(this->_M_impl._M_start._M_cur - 1, __x); > --this->_M_impl._M_start._M_cur; > } > else > _M_push_front_aux(__x); > } > > > void > push_front(value_type&& __x) > { emplace_front(std::move(__x)); } > > template<typename... _Args> > void > emplace_front(_Args&&... __args); ># 1397 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > push_back(const value_type& __x) > { > if (this->_M_impl._M_finish._M_cur > != this->_M_impl._M_finish._M_last - 1) > { > this->_M_impl.construct(this->_M_impl._M_finish._M_cur, __x); > ++this->_M_impl._M_finish._M_cur; > } > else > _M_push_back_aux(__x); > } > > > void > push_back(value_type&& __x) > { emplace_back(std::move(__x)); } > > template<typename... _Args> > void > emplace_back(_Args&&... __args); ># 1428 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > pop_front() noexcept > { > if (this->_M_impl._M_start._M_cur > != this->_M_impl._M_start._M_last - 1) > { > this->_M_impl.destroy(this->_M_impl._M_start._M_cur); > ++this->_M_impl._M_start._M_cur; > } > else > _M_pop_front_aux(); > } ># 1449 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > pop_back() noexcept > { > if (this->_M_impl._M_finish._M_cur > != this->_M_impl._M_finish._M_first) > { > --this->_M_impl._M_finish._M_cur; > this->_M_impl.destroy(this->_M_impl._M_finish._M_cur); > } > else > _M_pop_back_aux(); > } ># 1472 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename... _Args> > iterator > emplace(const_iterator __position, _Args&&... __args); ># 1485 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > iterator > insert(const_iterator __position, const value_type& __x); ># 1511 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > iterator > insert(const_iterator __position, value_type&& __x) > { return emplace(__position, std::move(__x)); } ># 1524 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > iterator > insert(const_iterator __p, initializer_list<value_type> __l) > { return this->insert(__p, __l.begin(), __l.end()); } ># 1540 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > iterator > insert(const_iterator __position, size_type __n, const value_type& __x) > { > difference_type __offset = __position - cbegin(); > _M_fill_insert(__position._M_const_cast(), __n, __x); > return begin() + __offset; > } ># 1574 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _InputIterator, > typename = std::_RequireInputIter<_InputIterator>> > iterator > insert(const_iterator __position, _InputIterator __first, > _InputIterator __last) > { > difference_type __offset = __position - cbegin(); > _M_insert_dispatch(__position._M_const_cast(), > __first, __last, __false_type()); > return begin() + __offset; > } ># 1620 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > iterator > > erase(const_iterator __position) > > > > { return _M_erase(__position._M_const_cast()); } ># 1644 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > iterator > > erase(const_iterator __first, const_iterator __last) > > > > { return _M_erase(__first._M_const_cast(), __last._M_const_cast()); } ># 1661 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > swap(deque& __x) noexcept > { > std::swap(this->_M_impl._M_start, __x._M_impl._M_start); > std::swap(this->_M_impl._M_finish, __x._M_impl._M_finish); > std::swap(this->_M_impl._M_map, __x._M_impl._M_map); > std::swap(this->_M_impl._M_map_size, __x._M_impl._M_map_size); > > > > std::__alloc_swap<_Tp_alloc_type>::_S_do_it(_M_get_Tp_allocator(), > __x._M_get_Tp_allocator()); > } > > > > > > > > void > clear() noexcept > { _M_erase_at_end(begin()); } > > protected: > > > > > > > template<typename _Integer> > void > _M_initialize_dispatch(_Integer __n, _Integer __x, __true_type) > { > _M_initialize_map(static_cast<size_type>(__n)); > _M_fill_initialize(__x); > } > > > template<typename _InputIterator> > void > _M_initialize_dispatch(_InputIterator __first, _InputIterator __last, > __false_type) > { > typedef typename std::iterator_traits<_InputIterator>:: > iterator_category _IterCategory; > _M_range_initialize(__first, __last, _IterCategory()); > } ># 1723 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _InputIterator> > void > _M_range_initialize(_InputIterator __first, _InputIterator __last, > std::input_iterator_tag); > > > template<typename _ForwardIterator> > void > _M_range_initialize(_ForwardIterator __first, _ForwardIterator __last, > std::forward_iterator_tag); ># 1745 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > _M_fill_initialize(const value_type& __value); > > > > void > _M_default_initialize(); ># 1761 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _Integer> > void > _M_assign_dispatch(_Integer __n, _Integer __val, __true_type) > { _M_fill_assign(__n, __val); } > > > template<typename _InputIterator> > void > _M_assign_dispatch(_InputIterator __first, _InputIterator __last, > __false_type) > { > typedef typename std::iterator_traits<_InputIterator>:: > iterator_category _IterCategory; > _M_assign_aux(__first, __last, _IterCategory()); > } > > > template<typename _InputIterator> > void > _M_assign_aux(_InputIterator __first, _InputIterator __last, > std::input_iterator_tag); > > > template<typename _ForwardIterator> > void > _M_assign_aux(_ForwardIterator __first, _ForwardIterator __last, > std::forward_iterator_tag) > { > const size_type __len = std::distance(__first, __last); > if (__len > size()) > { > _ForwardIterator __mid = __first; > std::advance(__mid, size()); > std::copy(__first, __mid, begin()); > insert(end(), __mid, __last); > } > else > _M_erase_at_end(std::copy(__first, __last, begin())); > } > > > > void > _M_fill_assign(size_type __n, const value_type& __val) > { > if (__n > size()) > { > std::fill(begin(), end(), __val); > insert(end(), __n - size(), __val); > } > else > { > _M_erase_at_end(begin() + difference_type(__n)); > std::fill(begin(), end(), __val); > } > } ># 1825 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename... _Args> > void _M_push_back_aux(_Args&&... __args); > > template<typename... _Args> > void _M_push_front_aux(_Args&&... __args); > > > void _M_pop_back_aux(); > > void _M_pop_front_aux(); ># 1844 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _Integer> > void > _M_insert_dispatch(iterator __pos, > _Integer __n, _Integer __x, __true_type) > { _M_fill_insert(__pos, __n, __x); } > > > template<typename _InputIterator> > void > _M_insert_dispatch(iterator __pos, > _InputIterator __first, _InputIterator __last, > __false_type) > { > typedef typename std::iterator_traits<_InputIterator>:: > iterator_category _IterCategory; > _M_range_insert_aux(__pos, __first, __last, _IterCategory()); > } > > > template<typename _InputIterator> > void > _M_range_insert_aux(iterator __pos, _InputIterator __first, > _InputIterator __last, std::input_iterator_tag); > > > template<typename _ForwardIterator> > void > _M_range_insert_aux(iterator __pos, _ForwardIterator __first, > _ForwardIterator __last, std::forward_iterator_tag); > > > > > void > _M_fill_insert(iterator __pos, size_type __n, const value_type& __x); > > > > > > > template<typename... _Args> > iterator > _M_insert_aux(iterator __pos, _Args&&... __args); > > > > void > _M_insert_aux(iterator __pos, size_type __n, const value_type& __x); > > > template<typename _ForwardIterator> > void > _M_insert_aux(iterator __pos, > _ForwardIterator __first, _ForwardIterator __last, > size_type __n); > > > > > void > _M_destroy_data_aux(iterator __first, iterator __last); > > > > template<typename _Alloc1> > void > _M_destroy_data(iterator __first, iterator __last, const _Alloc1&) > { _M_destroy_data_aux(__first, __last); } > > void > _M_destroy_data(iterator __first, iterator __last, > const std::allocator<_Tp>&) > { > if (!__has_trivial_destructor(value_type)) > _M_destroy_data_aux(__first, __last); > } > > > void > _M_erase_at_begin(iterator __pos) > { > _M_destroy_data(begin(), __pos, _M_get_Tp_allocator()); > _M_destroy_nodes(this->_M_impl._M_start._M_node, __pos._M_node); > this->_M_impl._M_start = __pos; > } > > > > void > _M_erase_at_end(iterator __pos) > { > _M_destroy_data(__pos, end(), _M_get_Tp_allocator()); > _M_destroy_nodes(__pos._M_node + 1, > this->_M_impl._M_finish._M_node + 1); > this->_M_impl._M_finish = __pos; > } > > iterator > _M_erase(iterator __pos); > > iterator > _M_erase(iterator __first, iterator __last); > > > > void > _M_default_append(size_type __n); > > bool > _M_shrink_to_fit(); > > > > > iterator > _M_reserve_elements_at_front(size_type __n) > { > const size_type __vacancies = this->_M_impl._M_start._M_cur > - this->_M_impl._M_start._M_first; > if (__n > __vacancies) > _M_new_elements_at_front(__n - __vacancies); > return this->_M_impl._M_start - difference_type(__n); > } > > iterator > _M_reserve_elements_at_back(size_type __n) > { > const size_type __vacancies = (this->_M_impl._M_finish._M_last > - this->_M_impl._M_finish._M_cur) - 1; > if (__n > __vacancies) > _M_new_elements_at_back(__n - __vacancies); > return this->_M_impl._M_finish + difference_type(__n); > } > > void > _M_new_elements_at_front(size_type __new_elements); > > void > _M_new_elements_at_back(size_type __new_elements); ># 1995 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > void > _M_reserve_map_at_back(size_type __nodes_to_add = 1) > { > if (__nodes_to_add + 1 > this->_M_impl._M_map_size > - (this->_M_impl._M_finish._M_node - this->_M_impl._M_map)) > _M_reallocate_map(__nodes_to_add, false); > } > > void > _M_reserve_map_at_front(size_type __nodes_to_add = 1) > { > if (__nodes_to_add > size_type(this->_M_impl._M_start._M_node > - this->_M_impl._M_map)) > _M_reallocate_map(__nodes_to_add, true); > } > > void > _M_reallocate_map(size_type __nodes_to_add, bool __add_at_front); > > }; ># 2027 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _Tp, typename _Alloc> > inline bool > operator==(const deque<_Tp, _Alloc>& __x, > const deque<_Tp, _Alloc>& __y) > { return __x.size() == __y.size() > && std::equal(__x.begin(), __x.end(), __y.begin()); } ># 2045 "/usr/include/c++/4.9.0/bits/stl_deque.h" 3 > template<typename _Tp, typename _Alloc> > inline bool > operator<(const deque<_Tp, _Alloc>& __x, > const deque<_Tp, _Alloc>& __y) > { return std::lexicographical_compare(__x.begin(), __x.end(), > __y.begin(), __y.end()); } > > > template<typename _Tp, typename _Alloc> > inline bool > operator!=(const deque<_Tp, _Alloc>& __x, > const deque<_Tp, _Alloc>& __y) > { return !(__x == __y); } > > > template<typename _Tp, typename _Alloc> > inline bool > operator>(const deque<_Tp, _Alloc>& __x, > const deque<_Tp, _Alloc>& __y) > { return __y < __x; } > > > template<typename _Tp, typename _Alloc> > inline bool > operator<=(const deque<_Tp, _Alloc>& __x, > const deque<_Tp, _Alloc>& __y) > { return !(__y < __x); } > > > template<typename _Tp, typename _Alloc> > inline bool > operator>=(const deque<_Tp, _Alloc>& __x, > const deque<_Tp, _Alloc>& __y) > { return !(__x < __y); } > > > template<typename _Tp, typename _Alloc> > inline void > swap(deque<_Tp,_Alloc>& __x, deque<_Tp,_Alloc>& __y) > { __x.swap(__y); } > > > > >} ># 65 "/usr/include/c++/4.9.0/deque" 2 3 > ># 1 "/usr/include/c++/4.9.0/bits/deque.tcc" 1 3 ># 59 "/usr/include/c++/4.9.0/bits/deque.tcc" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template <typename _Tp, typename _Alloc> > void > deque<_Tp, _Alloc>:: > _M_default_initialize() > { > _Map_pointer __cur; > try > { > for (__cur = this->_M_impl._M_start._M_node; > __cur < this->_M_impl._M_finish._M_node; > ++__cur) > std::__uninitialized_default_a(*__cur, *__cur + _S_buffer_size(), > _M_get_Tp_allocator()); > std::__uninitialized_default_a(this->_M_impl._M_finish._M_first, > this->_M_impl._M_finish._M_cur, > _M_get_Tp_allocator()); > } > catch(...) > { > std::_Destroy(this->_M_impl._M_start, iterator(*__cur, __cur), > _M_get_Tp_allocator()); > throw; > } > } > > > template <typename _Tp, typename _Alloc> > deque<_Tp, _Alloc>& > deque<_Tp, _Alloc>:: > operator=(const deque& __x) > { > const size_type __len = size(); > if (&__x != this) > { > if (__len >= __x.size()) > _M_erase_at_end(std::copy(__x.begin(), __x.end(), > this->_M_impl._M_start)); > else > { > const_iterator __mid = __x.begin() + difference_type(__len); > std::copy(__x.begin(), __mid, this->_M_impl._M_start); > insert(this->_M_impl._M_finish, __mid, __x.end()); > } > } > return *this; > } > > > template<typename _Tp, typename _Alloc> > template<typename... _Args> > void > deque<_Tp, _Alloc>:: > emplace_front(_Args&&... __args) > { > if (this->_M_impl._M_start._M_cur != this->_M_impl._M_start._M_first) > { > this->_M_impl.construct(this->_M_impl._M_start._M_cur - 1, > std::forward<_Args>(__args)...); > --this->_M_impl._M_start._M_cur; > } > else > _M_push_front_aux(std::forward<_Args>(__args)...); > } > > template<typename _Tp, typename _Alloc> > template<typename... _Args> > void > deque<_Tp, _Alloc>:: > emplace_back(_Args&&... __args) > { > if (this->_M_impl._M_finish._M_cur > != this->_M_impl._M_finish._M_last - 1) > { > this->_M_impl.construct(this->_M_impl._M_finish._M_cur, > std::forward<_Args>(__args)...); > ++this->_M_impl._M_finish._M_cur; > } > else > _M_push_back_aux(std::forward<_Args>(__args)...); > } > > > > template<typename _Tp, typename _Alloc> > template<typename... _Args> > typename deque<_Tp, _Alloc>::iterator > deque<_Tp, _Alloc>:: > emplace(const_iterator __position, _Args&&... __args) > { > if (__position._M_cur == this->_M_impl._M_start._M_cur) > { > emplace_front(std::forward<_Args>(__args)...); > return this->_M_impl._M_start; > } > else if (__position._M_cur == this->_M_impl._M_finish._M_cur) > { > emplace_back(std::forward<_Args>(__args)...); > iterator __tmp = this->_M_impl._M_finish; > --__tmp; > return __tmp; > } > else > return _M_insert_aux(__position._M_const_cast(), > std::forward<_Args>(__args)...); > } > > > template <typename _Tp, typename _Alloc> > typename deque<_Tp, _Alloc>::iterator > deque<_Tp, _Alloc>:: > > insert(const_iterator __position, const value_type& __x) > > > > { > if (__position._M_cur == this->_M_impl._M_start._M_cur) > { > push_front(__x); > return this->_M_impl._M_start; > } > else if (__position._M_cur == this->_M_impl._M_finish._M_cur) > { > push_back(__x); > iterator __tmp = this->_M_impl._M_finish; > --__tmp; > return __tmp; > } > else > return _M_insert_aux(__position._M_const_cast(), __x); > } > > template <typename _Tp, typename _Alloc> > typename deque<_Tp, _Alloc>::iterator > deque<_Tp, _Alloc>:: > _M_erase(iterator __position) > { > iterator __next = __position; > ++__next; > const difference_type __index = __position - begin(); > if (static_cast<size_type>(__index) < (size() >> 1)) > { > if (__position != begin()) > std::move_backward(begin(), __position, __next); > pop_front(); > } > else > { > if (__next != end()) > std::move(__next, end(), __position); > pop_back(); > } > return begin() + __index; > } > > template <typename _Tp, typename _Alloc> > typename deque<_Tp, _Alloc>::iterator > deque<_Tp, _Alloc>:: > _M_erase(iterator __first, iterator __last) > { > if (__first == __last) > return __first; > else if (__first == begin() && __last == end()) > { > clear(); > return end(); > } > else > { > const difference_type __n = __last - __first; > const difference_type __elems_before = __first - begin(); > if (static_cast<size_type>(__elems_before) <= (size() - __n) / 2) > { > if (__first != begin()) > std::move_backward(begin(), __first, __last); > _M_erase_at_begin(begin() + __n); > } > else > { > if (__last != end()) > std::move(__last, end(), __first); > _M_erase_at_end(end() - __n); > } > return begin() + __elems_before; > } > } > > template <typename _Tp, class _Alloc> > template <typename _InputIterator> > void > deque<_Tp, _Alloc>:: > _M_assign_aux(_InputIterator __first, _InputIterator __last, > std::input_iterator_tag) > { > iterator __cur = begin(); > for (; __first != __last && __cur != end(); ++__cur, ++__first) > *__cur = *__first; > if (__first == __last) > _M_erase_at_end(__cur); > else > insert(end(), __first, __last); > } > > template <typename _Tp, typename _Alloc> > void > deque<_Tp, _Alloc>:: > _M_fill_insert(iterator __pos, size_type __n, const value_type& __x) > { > if (__pos._M_cur == this->_M_impl._M_start._M_cur) > { > iterator __new_start = _M_reserve_elements_at_front(__n); > try > { > std::__uninitialized_fill_a(__new_start, this->_M_impl._M_start, > __x, _M_get_Tp_allocator()); > this->_M_impl._M_start = __new_start; > } > catch(...) > { > _M_destroy_nodes(__new_start._M_node, > this->_M_impl._M_start._M_node); > throw; > } > } > else if (__pos._M_cur == this->_M_impl._M_finish._M_cur) > { > iterator __new_finish = _M_reserve_elements_at_back(__n); > try > { > std::__uninitialized_fill_a(this->_M_impl._M_finish, > __new_finish, __x, > _M_get_Tp_allocator()); > this->_M_impl._M_finish = __new_finish; > } > catch(...) > { > _M_destroy_nodes(this->_M_impl._M_finish._M_node + 1, > __new_finish._M_node + 1); > throw; > } > } > else > _M_insert_aux(__pos, __n, __x); > } > > > template <typename _Tp, typename _Alloc> > void > deque<_Tp, _Alloc>:: > _M_default_append(size_type __n) > { > if (__n) > { > iterator __new_finish = _M_reserve_elements_at_back(__n); > try > { > std::__uninitialized_default_a(this->_M_impl._M_finish, > __new_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish = __new_finish; > } > catch(...) > { > _M_destroy_nodes(this->_M_impl._M_finish._M_node + 1, > __new_finish._M_node + 1); > throw; > } > } > } > > template <typename _Tp, typename _Alloc> > bool > deque<_Tp, _Alloc>:: > _M_shrink_to_fit() > { > const difference_type __front_capacity > = (this->_M_impl._M_start._M_cur - this->_M_impl._M_start._M_first); > if (__front_capacity == 0) > return false; > > const difference_type __back_capacity > = (this->_M_impl._M_finish._M_last - this->_M_impl._M_finish._M_cur); > if (__front_capacity + __back_capacity < _S_buffer_size()) > return false; > > return std::__shrink_to_fit_aux<deque>::_S_do_it(*this); > } > > > template <typename _Tp, typename _Alloc> > void > deque<_Tp, _Alloc>:: > _M_fill_initialize(const value_type& __value) > { > _Map_pointer __cur; > try > { > for (__cur = this->_M_impl._M_start._M_node; > __cur < this->_M_impl._M_finish._M_node; > ++__cur) > std::__uninitialized_fill_a(*__cur, *__cur + _S_buffer_size(), > __value, _M_get_Tp_allocator()); > std::__uninitialized_fill_a(this->_M_impl._M_finish._M_first, > this->_M_impl._M_finish._M_cur, > __value, _M_get_Tp_allocator()); > } > catch(...) > { > std::_Destroy(this->_M_impl._M_start, iterator(*__cur, __cur), > _M_get_Tp_allocator()); > throw; > } > } > > template <typename _Tp, typename _Alloc> > template <typename _InputIterator> > void > deque<_Tp, _Alloc>:: > _M_range_initialize(_InputIterator __first, _InputIterator __last, > std::input_iterator_tag) > { > this->_M_initialize_map(0); > try > { > for (; __first != __last; ++__first) > > emplace_back(*__first); > > > > } > catch(...) > { > clear(); > throw; > } > } > > template <typename _Tp, typename _Alloc> > template <typename _ForwardIterator> > void > deque<_Tp, _Alloc>:: > _M_range_initialize(_ForwardIterator __first, _ForwardIterator __last, > std::forward_iterator_tag) > { > const size_type __n = std::distance(__first, __last); > this->_M_initialize_map(__n); > > _Map_pointer __cur_node; > try > { > for (__cur_node = this->_M_impl._M_start._M_node; > __cur_node < this->_M_impl._M_finish._M_node; > ++__cur_node) > { > _ForwardIterator __mid = __first; > std::advance(__mid, _S_buffer_size()); > std::__uninitialized_copy_a(__first, __mid, *__cur_node, > _M_get_Tp_allocator()); > __first = __mid; > } > std::__uninitialized_copy_a(__first, __last, > this->_M_impl._M_finish._M_first, > _M_get_Tp_allocator()); > } > catch(...) > { > std::_Destroy(this->_M_impl._M_start, > iterator(*__cur_node, __cur_node), > _M_get_Tp_allocator()); > throw; > } > } > > > template<typename _Tp, typename _Alloc> > > template<typename... _Args> > void > deque<_Tp, _Alloc>:: > _M_push_back_aux(_Args&&... __args) > > > > > > { > _M_reserve_map_at_back(); > *(this->_M_impl._M_finish._M_node + 1) = this->_M_allocate_node(); > try > { > > this->_M_impl.construct(this->_M_impl._M_finish._M_cur, > std::forward<_Args>(__args)...); > > > > this->_M_impl._M_finish._M_set_node(this->_M_impl._M_finish._M_node > + 1); > this->_M_impl._M_finish._M_cur = this->_M_impl._M_finish._M_first; > } > catch(...) > { > _M_deallocate_node(*(this->_M_impl._M_finish._M_node + 1)); > throw; > } > } > > > template<typename _Tp, typename _Alloc> > > template<typename... _Args> > void > deque<_Tp, _Alloc>:: > _M_push_front_aux(_Args&&... __args) > > > > > > { > _M_reserve_map_at_front(); > *(this->_M_impl._M_start._M_node - 1) = this->_M_allocate_node(); > try > { > this->_M_impl._M_start._M_set_node(this->_M_impl._M_start._M_node > - 1); > this->_M_impl._M_start._M_cur = this->_M_impl._M_start._M_last - 1; > > this->_M_impl.construct(this->_M_impl._M_start._M_cur, > std::forward<_Args>(__args)...); > > > > } > catch(...) > { > ++this->_M_impl._M_start; > _M_deallocate_node(*(this->_M_impl._M_start._M_node - 1)); > throw; > } > } > > > template <typename _Tp, typename _Alloc> > void deque<_Tp, _Alloc>:: > _M_pop_back_aux() > { > _M_deallocate_node(this->_M_impl._M_finish._M_first); > this->_M_impl._M_finish._M_set_node(this->_M_impl._M_finish._M_node - 1); > this->_M_impl._M_finish._M_cur = this->_M_impl._M_finish._M_last - 1; > this->_M_impl.destroy(this->_M_impl._M_finish._M_cur); > } > > > > > > > template <typename _Tp, typename _Alloc> > void deque<_Tp, _Alloc>:: > _M_pop_front_aux() > { > this->_M_impl.destroy(this->_M_impl._M_start._M_cur); > _M_deallocate_node(this->_M_impl._M_start._M_first); > this->_M_impl._M_start._M_set_node(this->_M_impl._M_start._M_node + 1); > this->_M_impl._M_start._M_cur = this->_M_impl._M_start._M_first; > } > > template <typename _Tp, typename _Alloc> > template <typename _InputIterator> > void > deque<_Tp, _Alloc>:: > _M_range_insert_aux(iterator __pos, > _InputIterator __first, _InputIterator __last, > std::input_iterator_tag) > { std::copy(__first, __last, std::inserter(*this, __pos)); } > > template <typename _Tp, typename _Alloc> > template <typename _ForwardIterator> > void > deque<_Tp, _Alloc>:: > _M_range_insert_aux(iterator __pos, > _ForwardIterator __first, _ForwardIterator __last, > std::forward_iterator_tag) > { > const size_type __n = std::distance(__first, __last); > if (__pos._M_cur == this->_M_impl._M_start._M_cur) > { > iterator __new_start = _M_reserve_elements_at_front(__n); > try > { > std::__uninitialized_copy_a(__first, __last, __new_start, > _M_get_Tp_allocator()); > this->_M_impl._M_start = __new_start; > } > catch(...) > { > _M_destroy_nodes(__new_start._M_node, > this->_M_impl._M_start._M_node); > throw; > } > } > else if (__pos._M_cur == this->_M_impl._M_finish._M_cur) > { > iterator __new_finish = _M_reserve_elements_at_back(__n); > try > { > std::__uninitialized_copy_a(__first, __last, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish = __new_finish; > } > catch(...) > { > _M_destroy_nodes(this->_M_impl._M_finish._M_node + 1, > __new_finish._M_node + 1); > throw; > } > } > else > _M_insert_aux(__pos, __first, __last, __n); > } > > template<typename _Tp, typename _Alloc> > > template<typename... _Args> > typename deque<_Tp, _Alloc>::iterator > deque<_Tp, _Alloc>:: > _M_insert_aux(iterator __pos, _Args&&... __args) > { > value_type __x_copy(std::forward<_Args>(__args)...); > > > > > > > > difference_type __index = __pos - this->_M_impl._M_start; > if (static_cast<size_type>(__index) < size() / 2) > { > push_front(std::move(front())); > iterator __front1 = this->_M_impl._M_start; > ++__front1; > iterator __front2 = __front1; > ++__front2; > __pos = this->_M_impl._M_start + __index; > iterator __pos1 = __pos; > ++__pos1; > std::move(__front2, __pos1, __front1); > } > else > { > push_back(std::move(back())); > iterator __back1 = this->_M_impl._M_finish; > --__back1; > iterator __back2 = __back1; > --__back2; > __pos = this->_M_impl._M_start + __index; > std::move_backward(__pos, __back2, __back1); > } > *__pos = std::move(__x_copy); > return __pos; > } > > template <typename _Tp, typename _Alloc> > void > deque<_Tp, _Alloc>:: > _M_insert_aux(iterator __pos, size_type __n, const value_type& __x) > { > const difference_type __elems_before = __pos - this->_M_impl._M_start; > const size_type __length = this->size(); > value_type __x_copy = __x; > if (__elems_before < difference_type(__length / 2)) > { > iterator __new_start = _M_reserve_elements_at_front(__n); > iterator __old_start = this->_M_impl._M_start; > __pos = this->_M_impl._M_start + __elems_before; > try > { > if (__elems_before >= difference_type(__n)) > { > iterator __start_n = (this->_M_impl._M_start > + difference_type(__n)); > std::__uninitialized_move_a(this->_M_impl._M_start, > __start_n, __new_start, > _M_get_Tp_allocator()); > this->_M_impl._M_start = __new_start; > std::move(__start_n, __pos, __old_start); > std::fill(__pos - difference_type(__n), __pos, __x_copy); > } > else > { > std::__uninitialized_move_fill(this->_M_impl._M_start, > __pos, __new_start, > this->_M_impl._M_start, > __x_copy, > _M_get_Tp_allocator()); > this->_M_impl._M_start = __new_start; > std::fill(__old_start, __pos, __x_copy); > } > } > catch(...) > { > _M_destroy_nodes(__new_start._M_node, > this->_M_impl._M_start._M_node); > throw; > } > } > else > { > iterator __new_finish = _M_reserve_elements_at_back(__n); > iterator __old_finish = this->_M_impl._M_finish; > const difference_type __elems_after = > difference_type(__length) - __elems_before; > __pos = this->_M_impl._M_finish - __elems_after; > try > { > if (__elems_after > difference_type(__n)) > { > iterator __finish_n = (this->_M_impl._M_finish > - difference_type(__n)); > std::__uninitialized_move_a(__finish_n, > this->_M_impl._M_finish, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish = __new_finish; > std::move_backward(__pos, __finish_n, __old_finish); > std::fill(__pos, __pos + difference_type(__n), __x_copy); > } > else > { > std::__uninitialized_fill_move(this->_M_impl._M_finish, > __pos + difference_type(__n), > __x_copy, __pos, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish = __new_finish; > std::fill(__pos, __old_finish, __x_copy); > } > } > catch(...) > { > _M_destroy_nodes(this->_M_impl._M_finish._M_node + 1, > __new_finish._M_node + 1); > throw; > } > } > } > > template <typename _Tp, typename _Alloc> > template <typename _ForwardIterator> > void > deque<_Tp, _Alloc>:: > _M_insert_aux(iterator __pos, > _ForwardIterator __first, _ForwardIterator __last, > size_type __n) > { > const difference_type __elemsbefore = __pos - this->_M_impl._M_start; > const size_type __length = size(); > if (static_cast<size_type>(__elemsbefore) < __length / 2) > { > iterator __new_start = _M_reserve_elements_at_front(__n); > iterator __old_start = this->_M_impl._M_start; > __pos = this->_M_impl._M_start + __elemsbefore; > try > { > if (__elemsbefore >= difference_type(__n)) > { > iterator __start_n = (this->_M_impl._M_start > + difference_type(__n)); > std::__uninitialized_move_a(this->_M_impl._M_start, > __start_n, __new_start, > _M_get_Tp_allocator()); > this->_M_impl._M_start = __new_start; > std::move(__start_n, __pos, __old_start); > std::copy(__first, __last, __pos - difference_type(__n)); > } > else > { > _ForwardIterator __mid = __first; > std::advance(__mid, difference_type(__n) - __elemsbefore); > std::__uninitialized_move_copy(this->_M_impl._M_start, > __pos, __first, __mid, > __new_start, > _M_get_Tp_allocator()); > this->_M_impl._M_start = __new_start; > std::copy(__mid, __last, __old_start); > } > } > catch(...) > { > _M_destroy_nodes(__new_start._M_node, > this->_M_impl._M_start._M_node); > throw; > } > } > else > { > iterator __new_finish = _M_reserve_elements_at_back(__n); > iterator __old_finish = this->_M_impl._M_finish; > const difference_type __elemsafter = > difference_type(__length) - __elemsbefore; > __pos = this->_M_impl._M_finish - __elemsafter; > try > { > if (__elemsafter > difference_type(__n)) > { > iterator __finish_n = (this->_M_impl._M_finish > - difference_type(__n)); > std::__uninitialized_move_a(__finish_n, > this->_M_impl._M_finish, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish = __new_finish; > std::move_backward(__pos, __finish_n, __old_finish); > std::copy(__first, __last, __pos); > } > else > { > _ForwardIterator __mid = __first; > std::advance(__mid, __elemsafter); > std::__uninitialized_copy_move(__mid, __last, __pos, > this->_M_impl._M_finish, > this->_M_impl._M_finish, > _M_get_Tp_allocator()); > this->_M_impl._M_finish = __new_finish; > std::copy(__first, __mid, __pos); > } > } > catch(...) > { > _M_destroy_nodes(this->_M_impl._M_finish._M_node + 1, > __new_finish._M_node + 1); > throw; > } > } > } > > template<typename _Tp, typename _Alloc> > void > deque<_Tp, _Alloc>:: > _M_destroy_data_aux(iterator __first, iterator __last) > { > for (_Map_pointer __node = __first._M_node + 1; > __node < __last._M_node; ++__node) > std::_Destroy(*__node, *__node + _S_buffer_size(), > _M_get_Tp_allocator()); > > if (__first._M_node != __last._M_node) > { > std::_Destroy(__first._M_cur, __first._M_last, > _M_get_Tp_allocator()); > std::_Destroy(__last._M_first, __last._M_cur, > _M_get_Tp_allocator()); > } > else > std::_Destroy(__first._M_cur, __last._M_cur, > _M_get_Tp_allocator()); > } > > template <typename _Tp, typename _Alloc> > void > deque<_Tp, _Alloc>:: > _M_new_elements_at_front(size_type __new_elems) > { > if (this->max_size() - this->size() < __new_elems) > __throw_length_error(("deque::_M_new_elements_at_front")); > > const size_type __new_nodes = ((__new_elems + _S_buffer_size() - 1) > / _S_buffer_size()); > _M_reserve_map_at_front(__new_nodes); > size_type __i; > try > { > for (__i = 1; __i <= __new_nodes; ++__i) > *(this->_M_impl._M_start._M_node - __i) = this->_M_allocate_node(); > } > catch(...) > { > for (size_type __j = 1; __j < __i; ++__j) > _M_deallocate_node(*(this->_M_impl._M_start._M_node - __j)); > throw; > } > } > > template <typename _Tp, typename _Alloc> > void > deque<_Tp, _Alloc>:: > _M_new_elements_at_back(size_type __new_elems) > { > if (this->max_size() - this->size() < __new_elems) > __throw_length_error(("deque::_M_new_elements_at_back")); > > const size_type __new_nodes = ((__new_elems + _S_buffer_size() - 1) > / _S_buffer_size()); > _M_reserve_map_at_back(__new_nodes); > size_type __i; > try > { > for (__i = 1; __i <= __new_nodes; ++__i) > *(this->_M_impl._M_finish._M_node + __i) = this->_M_allocate_node(); > } > catch(...) > { > for (size_type __j = 1; __j < __i; ++__j) > _M_deallocate_node(*(this->_M_impl._M_finish._M_node + __j)); > throw; > } > } > > template <typename _Tp, typename _Alloc> > void > deque<_Tp, _Alloc>:: > _M_reallocate_map(size_type __nodes_to_add, bool __add_at_front) > { > const size_type __old_num_nodes > = this->_M_impl._M_finish._M_node - this->_M_impl._M_start._M_node + 1; > const size_type __new_num_nodes = __old_num_nodes + __nodes_to_add; > > _Map_pointer __new_nstart; > if (this->_M_impl._M_map_size > 2 * __new_num_nodes) > { > __new_nstart = this->_M_impl._M_map + (this->_M_impl._M_map_size > - __new_num_nodes) / 2 > + (__add_at_front ? __nodes_to_add : 0); > if (__new_nstart < this->_M_impl._M_start._M_node) > std::copy(this->_M_impl._M_start._M_node, > this->_M_impl._M_finish._M_node + 1, > __new_nstart); > else > std::copy_backward(this->_M_impl._M_start._M_node, > this->_M_impl._M_finish._M_node + 1, > __new_nstart + __old_num_nodes); > } > else > { > size_type __new_map_size = this->_M_impl._M_map_size > + std::max(this->_M_impl._M_map_size, > __nodes_to_add) + 2; > > _Map_pointer __new_map = this->_M_allocate_map(__new_map_size); > __new_nstart = __new_map + (__new_map_size - __new_num_nodes) / 2 > + (__add_at_front ? __nodes_to_add : 0); > std::copy(this->_M_impl._M_start._M_node, > this->_M_impl._M_finish._M_node + 1, > __new_nstart); > _M_deallocate_map(this->_M_impl._M_map, this->_M_impl._M_map_size); > > this->_M_impl._M_map = __new_map; > this->_M_impl._M_map_size = __new_map_size; > } > > this->_M_impl._M_start._M_set_node(__new_nstart); > this->_M_impl._M_finish._M_set_node(__new_nstart + __old_num_nodes - 1); > } > > > > template<typename _Tp> > void > fill(const _Deque_iterator<_Tp, _Tp&, _Tp*>& __first, > const _Deque_iterator<_Tp, _Tp&, _Tp*>& __last, const _Tp& __value) > { > typedef typename _Deque_iterator<_Tp, _Tp&, _Tp*>::_Self _Self; > > for (typename _Self::_Map_pointer __node = __first._M_node + 1; > __node < __last._M_node; ++__node) > std::fill(*__node, *__node + _Self::_S_buffer_size(), __value); > > if (__first._M_node != __last._M_node) > { > std::fill(__first._M_cur, __first._M_last, __value); > std::fill(__last._M_first, __last._M_cur, __value); > } > else > std::fill(__first._M_cur, __last._M_cur, __value); > } > > template<typename _Tp> > _Deque_iterator<_Tp, _Tp&, _Tp*> > copy(_Deque_iterator<_Tp, const _Tp&, const _Tp*> __first, > _Deque_iterator<_Tp, const _Tp&, const _Tp*> __last, > _Deque_iterator<_Tp, _Tp&, _Tp*> __result) > { > typedef typename _Deque_iterator<_Tp, _Tp&, _Tp*>::_Self _Self; > typedef typename _Self::difference_type difference_type; > > difference_type __len = __last - __first; > while (__len > 0) > { > const difference_type __clen > = std::min(__len, std::min(__first._M_last - __first._M_cur, > __result._M_last - __result._M_cur)); > std::copy(__first._M_cur, __first._M_cur + __clen, __result._M_cur); > __first += __clen; > __result += __clen; > __len -= __clen; > } > return __result; > } > > template<typename _Tp> > _Deque_iterator<_Tp, _Tp&, _Tp*> > copy_backward(_Deque_iterator<_Tp, const _Tp&, const _Tp*> __first, > _Deque_iterator<_Tp, const _Tp&, const _Tp*> __last, > _Deque_iterator<_Tp, _Tp&, _Tp*> __result) > { > typedef typename _Deque_iterator<_Tp, _Tp&, _Tp*>::_Self _Self; > typedef typename _Self::difference_type difference_type; > > difference_type __len = __last - __first; > while (__len > 0) > { > difference_type __llen = __last._M_cur - __last._M_first; > _Tp* __lend = __last._M_cur; > > difference_type __rlen = __result._M_cur - __result._M_first; > _Tp* __rend = __result._M_cur; > > if (!__llen) > { > __llen = _Self::_S_buffer_size(); > __lend = *(__last._M_node - 1) + __llen; > } > if (!__rlen) > { > __rlen = _Self::_S_buffer_size(); > __rend = *(__result._M_node - 1) + __rlen; > } > > const difference_type __clen = std::min(__len, > std::min(__llen, __rlen)); > std::copy_backward(__lend - __clen, __lend, __rend); > __last -= __clen; > __result -= __clen; > __len -= __clen; > } > return __result; > } > > > template<typename _Tp> > _Deque_iterator<_Tp, _Tp&, _Tp*> > move(_Deque_iterator<_Tp, const _Tp&, const _Tp*> __first, > _Deque_iterator<_Tp, const _Tp&, const _Tp*> __last, > _Deque_iterator<_Tp, _Tp&, _Tp*> __result) > { > typedef typename _Deque_iterator<_Tp, _Tp&, _Tp*>::_Self _Self; > typedef typename _Self::difference_type difference_type; > > difference_type __len = __last - __first; > while (__len > 0) > { > const difference_type __clen > = std::min(__len, std::min(__first._M_last - __first._M_cur, > __result._M_last - __result._M_cur)); > std::move(__first._M_cur, __first._M_cur + __clen, __result._M_cur); > __first += __clen; > __result += __clen; > __len -= __clen; > } > return __result; > } > > template<typename _Tp> > _Deque_iterator<_Tp, _Tp&, _Tp*> > move_backward(_Deque_iterator<_Tp, const _Tp&, const _Tp*> __first, > _Deque_iterator<_Tp, const _Tp&, const _Tp*> __last, > _Deque_iterator<_Tp, _Tp&, _Tp*> __result) > { > typedef typename _Deque_iterator<_Tp, _Tp&, _Tp*>::_Self _Self; > typedef typename _Self::difference_type difference_type; > > difference_type __len = __last - __first; > while (__len > 0) > { > difference_type __llen = __last._M_cur - __last._M_first; > _Tp* __lend = __last._M_cur; > > difference_type __rlen = __result._M_cur - __result._M_first; > _Tp* __rend = __result._M_cur; > > if (!__llen) > { > __llen = _Self::_S_buffer_size(); > __lend = *(__last._M_node - 1) + __llen; > } > if (!__rlen) > { > __rlen = _Self::_S_buffer_size(); > __rend = *(__result._M_node - 1) + __rlen; > } > > const difference_type __clen = std::min(__len, > std::min(__llen, __rlen)); > std::move_backward(__lend - __clen, __lend, __rend); > __last -= __clen; > __result -= __clen; > __len -= __clen; > } > return __result; > } > > > >} ># 67 "/usr/include/c++/4.9.0/deque" 2 3 ># 92 "/usr/include/boost/detail/container_fwd.hpp" 2 3 4 > > > ># 1 "/usr/include/c++/4.9.0/set" 1 3 4 ># 58 "/usr/include/c++/4.9.0/set" 3 4 ># 59 "/usr/include/c++/4.9.0/set" 3 > > ># 1 "/usr/include/c++/4.9.0/bits/stl_set.h" 1 3 ># 64 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 88 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > template<typename _Key, typename _Compare = std::less<_Key>, > typename _Alloc = std::allocator<_Key> > > class set > { > > typedef typename _Alloc::value_type _Alloc_value_type; > > > > > > public: > > > > typedef _Key key_type; > typedef _Key value_type; > typedef _Compare key_compare; > typedef _Compare value_compare; > typedef _Alloc allocator_type; > > > private: > typedef typename __gnu_cxx::__alloc_traits<_Alloc>::template > rebind<_Key>::other _Key_alloc_type; > > typedef _Rb_tree<key_type, value_type, _Identity<value_type>, > key_compare, _Key_alloc_type> _Rep_type; > _Rep_type _M_t; > > typedef __gnu_cxx::__alloc_traits<_Key_alloc_type> _Alloc_traits; > > public: > > > typedef typename _Alloc_traits::pointer pointer; > typedef typename _Alloc_traits::const_pointer const_pointer; > typedef typename _Alloc_traits::reference reference; > typedef typename _Alloc_traits::const_reference const_reference; > > > > typedef typename _Rep_type::const_iterator iterator; > typedef typename _Rep_type::const_iterator const_iterator; > typedef typename _Rep_type::const_reverse_iterator reverse_iterator; > typedef typename _Rep_type::const_reverse_iterator const_reverse_iterator; > typedef typename _Rep_type::size_type size_type; > typedef typename _Rep_type::difference_type difference_type; > > > > > > > set() > : _M_t() { } > > > > > > > explicit > set(const _Compare& __comp, > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Key_alloc_type(__a)) { } ># 165 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > template<typename _InputIterator> > set(_InputIterator __first, _InputIterator __last) > : _M_t() > { _M_t._M_insert_unique(__first, __last); } ># 182 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > template<typename _InputIterator> > set(_InputIterator __first, _InputIterator __last, > const _Compare& __comp, > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Key_alloc_type(__a)) > { _M_t._M_insert_unique(__first, __last); } ># 196 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > set(const set& __x) > : _M_t(__x._M_t) { } ># 207 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > set(set&& __x) > noexcept(is_nothrow_copy_constructible<_Compare>::value) > : _M_t(std::move(__x._M_t)) { } ># 221 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > set(initializer_list<value_type> __l, > const _Compare& __comp = _Compare(), > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Key_alloc_type(__a)) > { _M_t._M_insert_unique(__l.begin(), __l.end()); } > > > explicit > set(const allocator_type& __a) > : _M_t(_Compare(), _Key_alloc_type(__a)) { } > > > set(const set& __x, const allocator_type& __a) > : _M_t(__x._M_t, _Key_alloc_type(__a)) { } > > > set(set&& __x, const allocator_type& __a) > noexcept(is_nothrow_copy_constructible<_Compare>::value > && _Alloc_traits::_S_always_equal()) > : _M_t(std::move(__x._M_t), _Key_alloc_type(__a)) { } > > > set(initializer_list<value_type> __l, const allocator_type& __a) > : _M_t(_Compare(), _Key_alloc_type(__a)) > { _M_t._M_insert_unique(__l.begin(), __l.end()); } > > > template<typename _InputIterator> > set(_InputIterator __first, _InputIterator __last, > const allocator_type& __a) > : _M_t(_Compare(), _Key_alloc_type(__a)) > { _M_t._M_insert_unique(__first, __last); } ># 262 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > set& > operator=(const set& __x) > { > _M_t = __x._M_t; > return *this; > } ># 278 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > set& > operator=(set&& __x) noexcept(_Alloc_traits::_S_nothrow_move()) > { > if (!_M_t._M_move_assign(__x._M_t)) > { > > > clear(); > insert(std::__make_move_if_noexcept_iterator(__x._M_t.begin()), > std::__make_move_if_noexcept_iterator(__x._M_t.end())); > __x.clear(); > } > return *this; > } ># 304 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > set& > operator=(initializer_list<value_type> __l) > { > this->clear(); > this->insert(__l.begin(), __l.end()); > return *this; > } > > > > > > key_compare > key_comp() const > { return _M_t.key_comp(); } > > value_compare > value_comp() const > { return _M_t.key_comp(); } > > allocator_type > get_allocator() const noexcept > { return allocator_type(_M_t.get_allocator()); } > > > > > > > iterator > begin() const noexcept > { return _M_t.begin(); } > > > > > > > iterator > end() const noexcept > { return _M_t.end(); } > > > > > > > reverse_iterator > rbegin() const noexcept > { return _M_t.rbegin(); } > > > > > > > reverse_iterator > rend() const noexcept > { return _M_t.rend(); } > > > > > > > > iterator > cbegin() const noexcept > { return _M_t.begin(); } > > > > > > > iterator > cend() const noexcept > { return _M_t.end(); } > > > > > > > reverse_iterator > crbegin() const noexcept > { return _M_t.rbegin(); } > > > > > > > reverse_iterator > crend() const noexcept > { return _M_t.rend(); } > > > > bool > empty() const noexcept > { return _M_t.empty(); } > > > size_type > size() const noexcept > { return _M_t.size(); } > > > size_type > max_size() const noexcept > { return _M_t.max_size(); } ># 428 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > void > swap(set& __x) > > noexcept(_Alloc_traits::_S_nothrow_swap()) > > { _M_t.swap(__x._M_t); } ># 450 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > template<typename... _Args> > std::pair<iterator, bool> > emplace(_Args&&... __args) > { return _M_t._M_emplace_unique(std::forward<_Args>(__args)...); } ># 476 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > template<typename... _Args> > iterator > emplace_hint(const_iterator __pos, _Args&&... __args) > { > return _M_t._M_emplace_hint_unique(__pos, > std::forward<_Args>(__args)...); > } ># 498 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > std::pair<iterator, bool> > insert(const value_type& __x) > { > std::pair<typename _Rep_type::iterator, bool> __p = > _M_t._M_insert_unique(__x); > return std::pair<iterator, bool>(__p.first, __p.second); > } > > > std::pair<iterator, bool> > insert(value_type&& __x) > { > std::pair<typename _Rep_type::iterator, bool> __p = > _M_t._M_insert_unique(std::move(__x)); > return std::pair<iterator, bool>(__p.first, __p.second); > } ># 535 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > iterator > insert(const_iterator __position, const value_type& __x) > { return _M_t._M_insert_unique_(__position, __x); } > > > iterator > insert(const_iterator __position, value_type&& __x) > { return _M_t._M_insert_unique_(__position, std::move(__x)); } ># 554 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > template<typename _InputIterator> > void > insert(_InputIterator __first, _InputIterator __last) > { _M_t._M_insert_unique(__first, __last); } ># 567 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > void > insert(initializer_list<value_type> __l) > { this->insert(__l.begin(), __l.end()); } ># 588 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > __attribute ((__abi_tag__ ("cxx11"))) > iterator > erase(const_iterator __position) > { return _M_t.erase(__position); } ># 619 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > size_type > erase(const key_type& __x) > { return _M_t.erase(__x); } ># 640 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > __attribute ((__abi_tag__ ("cxx11"))) > iterator > erase(const_iterator __first, const_iterator __last) > { return _M_t.erase(__first, __last); } ># 668 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > void > clear() noexcept > { _M_t.clear(); } ># 682 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > size_type > count(const key_type& __x) const > { return _M_t.find(__x) == _M_t.end() ? 0 : 1; } ># 700 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > iterator > find(const key_type& __x) > { return _M_t.find(__x); } > > const_iterator > find(const key_type& __x) const > { return _M_t.find(__x); } ># 721 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > iterator > lower_bound(const key_type& __x) > { return _M_t.lower_bound(__x); } > > const_iterator > lower_bound(const key_type& __x) const > { return _M_t.lower_bound(__x); } ># 737 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > iterator > upper_bound(const key_type& __x) > { return _M_t.upper_bound(__x); } > > const_iterator > upper_bound(const key_type& __x) const > { return _M_t.upper_bound(__x); } ># 762 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > std::pair<iterator, iterator> > equal_range(const key_type& __x) > { return _M_t.equal_range(__x); } > > std::pair<const_iterator, const_iterator> > equal_range(const key_type& __x) const > { return _M_t.equal_range(__x); } > > > template<typename _K1, typename _C1, typename _A1> > friend bool > operator==(const set<_K1, _C1, _A1>&, const set<_K1, _C1, _A1>&); > > template<typename _K1, typename _C1, typename _A1> > friend bool > operator<(const set<_K1, _C1, _A1>&, const set<_K1, _C1, _A1>&); > }; ># 791 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator==(const set<_Key, _Compare, _Alloc>& __x, > const set<_Key, _Compare, _Alloc>& __y) > { return __x._M_t == __y._M_t; } ># 808 "/usr/include/c++/4.9.0/bits/stl_set.h" 3 > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator<(const set<_Key, _Compare, _Alloc>& __x, > const set<_Key, _Compare, _Alloc>& __y) > { return __x._M_t < __y._M_t; } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator!=(const set<_Key, _Compare, _Alloc>& __x, > const set<_Key, _Compare, _Alloc>& __y) > { return !(__x == __y); } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator>(const set<_Key, _Compare, _Alloc>& __x, > const set<_Key, _Compare, _Alloc>& __y) > { return __y < __x; } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator<=(const set<_Key, _Compare, _Alloc>& __x, > const set<_Key, _Compare, _Alloc>& __y) > { return !(__y < __x); } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator>=(const set<_Key, _Compare, _Alloc>& __x, > const set<_Key, _Compare, _Alloc>& __y) > { return !(__x < __y); } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline void > swap(set<_Key, _Compare, _Alloc>& __x, set<_Key, _Compare, _Alloc>& __y) > { __x.swap(__y); } > > >} ># 62 "/usr/include/c++/4.9.0/set" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 1 3 ># 64 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 90 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > template <typename _Key, typename _Compare = std::less<_Key>, > typename _Alloc = std::allocator<_Key> > > class multiset > { > > typedef typename _Alloc::value_type _Alloc_value_type; > > > > > > public: > > typedef _Key key_type; > typedef _Key value_type; > typedef _Compare key_compare; > typedef _Compare value_compare; > typedef _Alloc allocator_type; > > private: > > typedef typename __gnu_cxx::__alloc_traits<_Alloc>::template > rebind<_Key>::other _Key_alloc_type; > > typedef _Rb_tree<key_type, value_type, _Identity<value_type>, > key_compare, _Key_alloc_type> _Rep_type; > > _Rep_type _M_t; > > typedef __gnu_cxx::__alloc_traits<_Key_alloc_type> _Alloc_traits; > > public: > typedef typename _Alloc_traits::pointer pointer; > typedef typename _Alloc_traits::const_pointer const_pointer; > typedef typename _Alloc_traits::reference reference; > typedef typename _Alloc_traits::const_reference const_reference; > > > > typedef typename _Rep_type::const_iterator iterator; > typedef typename _Rep_type::const_iterator const_iterator; > typedef typename _Rep_type::const_reverse_iterator reverse_iterator; > typedef typename _Rep_type::const_reverse_iterator const_reverse_iterator; > typedef typename _Rep_type::size_type size_type; > typedef typename _Rep_type::difference_type difference_type; > > > > > > multiset() > : _M_t() { } > > > > > > > explicit > multiset(const _Compare& __comp, > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Key_alloc_type(__a)) { } ># 162 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > template<typename _InputIterator> > multiset(_InputIterator __first, _InputIterator __last) > : _M_t() > { _M_t._M_insert_equal(__first, __last); } ># 178 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > template<typename _InputIterator> > multiset(_InputIterator __first, _InputIterator __last, > const _Compare& __comp, > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Key_alloc_type(__a)) > { _M_t._M_insert_equal(__first, __last); } ># 192 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > multiset(const multiset& __x) > : _M_t(__x._M_t) { } ># 203 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > multiset(multiset&& __x) > noexcept(is_nothrow_copy_constructible<_Compare>::value) > : _M_t(std::move(__x._M_t)) { } ># 217 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > multiset(initializer_list<value_type> __l, > const _Compare& __comp = _Compare(), > const allocator_type& __a = allocator_type()) > : _M_t(__comp, _Key_alloc_type(__a)) > { _M_t._M_insert_equal(__l.begin(), __l.end()); } > > > explicit > multiset(const allocator_type& __a) > : _M_t(_Compare(), _Key_alloc_type(__a)) { } > > > multiset(const multiset& __m, const allocator_type& __a) > : _M_t(__m._M_t, _Key_alloc_type(__a)) { } > > > multiset(multiset&& __m, const allocator_type& __a) > noexcept(is_nothrow_copy_constructible<_Compare>::value > && _Alloc_traits::_S_always_equal()) > : _M_t(std::move(__m._M_t), _Key_alloc_type(__a)) { } > > > multiset(initializer_list<value_type> __l, const allocator_type& __a) > : _M_t(_Compare(), _Key_alloc_type(__a)) > { _M_t._M_insert_equal(__l.begin(), __l.end()); } > > > template<typename _InputIterator> > multiset(_InputIterator __first, _InputIterator __last, > const allocator_type& __a) > : _M_t(_Compare(), _Key_alloc_type(__a)) > { _M_t._M_insert_equal(__first, __last); } ># 258 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > multiset& > operator=(const multiset& __x) > { > _M_t = __x._M_t; > return *this; > } ># 274 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > multiset& > operator=(multiset&& __x) noexcept(_Alloc_traits::_S_nothrow_move()) > { > if (!_M_t._M_move_assign(__x._M_t)) > { > > > clear(); > insert(std::__make_move_if_noexcept_iterator(__x._M_t.begin()), > std::__make_move_if_noexcept_iterator(__x._M_t.end())); > __x.clear(); > } > return *this; > } ># 300 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > multiset& > operator=(initializer_list<value_type> __l) > { > this->clear(); > this->insert(__l.begin(), __l.end()); > return *this; > } > > > > > > key_compare > key_comp() const > { return _M_t.key_comp(); } > > value_compare > value_comp() const > { return _M_t.key_comp(); } > > allocator_type > get_allocator() const noexcept > { return allocator_type(_M_t.get_allocator()); } > > > > > > > iterator > begin() const noexcept > { return _M_t.begin(); } > > > > > > > iterator > end() const noexcept > { return _M_t.end(); } > > > > > > > reverse_iterator > rbegin() const noexcept > { return _M_t.rbegin(); } > > > > > > > reverse_iterator > rend() const noexcept > { return _M_t.rend(); } > > > > > > > > iterator > cbegin() const noexcept > { return _M_t.begin(); } > > > > > > > iterator > cend() const noexcept > { return _M_t.end(); } > > > > > > > reverse_iterator > crbegin() const noexcept > { return _M_t.rbegin(); } > > > > > > > reverse_iterator > crend() const noexcept > { return _M_t.rend(); } > > > > bool > empty() const noexcept > { return _M_t.empty(); } > > > size_type > size() const noexcept > { return _M_t.size(); } > > > size_type > max_size() const noexcept > { return _M_t.max_size(); } ># 424 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > void > swap(multiset& __x) > > noexcept(_Alloc_traits::_S_nothrow_swap()) > > { _M_t.swap(__x._M_t); } ># 445 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > template<typename... _Args> > iterator > emplace(_Args&&... __args) > { return _M_t._M_emplace_equal(std::forward<_Args>(__args)...); } ># 471 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > template<typename... _Args> > iterator > emplace_hint(const_iterator __pos, _Args&&... __args) > { > return _M_t._M_emplace_hint_equal(__pos, > std::forward<_Args>(__args)...); > } ># 491 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > iterator > insert(const value_type& __x) > { return _M_t._M_insert_equal(__x); } > > > iterator > insert(value_type&& __x) > { return _M_t._M_insert_equal(std::move(__x)); } ># 521 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > iterator > insert(const_iterator __position, const value_type& __x) > { return _M_t._M_insert_equal_(__position, __x); } > > > iterator > insert(const_iterator __position, value_type&& __x) > { return _M_t._M_insert_equal_(__position, std::move(__x)); } ># 539 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > template<typename _InputIterator> > void > insert(_InputIterator __first, _InputIterator __last) > { _M_t._M_insert_equal(__first, __last); } ># 552 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > void > insert(initializer_list<value_type> __l) > { this->insert(__l.begin(), __l.end()); } ># 573 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > __attribute ((__abi_tag__ ("cxx11"))) > iterator > erase(const_iterator __position) > { return _M_t.erase(__position); } ># 604 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > size_type > erase(const key_type& __x) > { return _M_t.erase(__x); } ># 625 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > __attribute ((__abi_tag__ ("cxx11"))) > iterator > erase(const_iterator __first, const_iterator __last) > { return _M_t.erase(__first, __last); } ># 653 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > void > clear() noexcept > { _M_t.clear(); } ># 664 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > size_type > count(const key_type& __x) const > { return _M_t.count(__x); } ># 682 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > iterator > find(const key_type& __x) > { return _M_t.find(__x); } > > const_iterator > find(const key_type& __x) const > { return _M_t.find(__x); } ># 703 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > iterator > lower_bound(const key_type& __x) > { return _M_t.lower_bound(__x); } > > const_iterator > lower_bound(const key_type& __x) const > { return _M_t.lower_bound(__x); } ># 719 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > iterator > upper_bound(const key_type& __x) > { return _M_t.upper_bound(__x); } > > const_iterator > upper_bound(const key_type& __x) const > { return _M_t.upper_bound(__x); } ># 744 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > std::pair<iterator, iterator> > equal_range(const key_type& __x) > { return _M_t.equal_range(__x); } > > std::pair<const_iterator, const_iterator> > equal_range(const key_type& __x) const > { return _M_t.equal_range(__x); } > > > template<typename _K1, typename _C1, typename _A1> > friend bool > operator==(const multiset<_K1, _C1, _A1>&, > const multiset<_K1, _C1, _A1>&); > > template<typename _K1, typename _C1, typename _A1> > friend bool > operator< (const multiset<_K1, _C1, _A1>&, > const multiset<_K1, _C1, _A1>&); > }; ># 775 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator==(const multiset<_Key, _Compare, _Alloc>& __x, > const multiset<_Key, _Compare, _Alloc>& __y) > { return __x._M_t == __y._M_t; } ># 792 "/usr/include/c++/4.9.0/bits/stl_multiset.h" 3 > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator<(const multiset<_Key, _Compare, _Alloc>& __x, > const multiset<_Key, _Compare, _Alloc>& __y) > { return __x._M_t < __y._M_t; } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator!=(const multiset<_Key, _Compare, _Alloc>& __x, > const multiset<_Key, _Compare, _Alloc>& __y) > { return !(__x == __y); } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator>(const multiset<_Key,_Compare,_Alloc>& __x, > const multiset<_Key,_Compare,_Alloc>& __y) > { return __y < __x; } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator<=(const multiset<_Key, _Compare, _Alloc>& __x, > const multiset<_Key, _Compare, _Alloc>& __y) > { return !(__y < __x); } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline bool > operator>=(const multiset<_Key, _Compare, _Alloc>& __x, > const multiset<_Key, _Compare, _Alloc>& __y) > { return !(__x < __y); } > > > template<typename _Key, typename _Compare, typename _Alloc> > inline void > swap(multiset<_Key, _Compare, _Alloc>& __x, > multiset<_Key, _Compare, _Alloc>& __y) > { __x.swap(__y); } > > >} ># 63 "/usr/include/c++/4.9.0/set" 2 3 ># 96 "/usr/include/boost/detail/container_fwd.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/bitset" 1 3 4 ># 45 "/usr/include/c++/4.9.0/bitset" 3 4 ># 46 "/usr/include/c++/4.9.0/bitset" 3 ># 60 "/usr/include/c++/4.9.0/bitset" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 70 "/usr/include/c++/4.9.0/bitset" 3 > template<size_t _Nw> > struct _Base_bitset > { > typedef unsigned long _WordT; > > > _WordT _M_w[_Nw]; > > constexpr _Base_bitset() noexcept > : _M_w() { } > > > constexpr _Base_bitset(unsigned long long __val) noexcept > : _M_w{ _WordT(__val) > > > > } { } > > > > > > > static constexpr size_t > _S_whichword(size_t __pos) noexcept > { return __pos / (8 * 8); } > > static constexpr size_t > _S_whichbyte(size_t __pos) noexcept > { return (__pos % (8 * 8)) / 8; } > > static constexpr size_t > _S_whichbit(size_t __pos) noexcept > { return __pos % (8 * 8); } > > static constexpr _WordT > _S_maskbit(size_t __pos) noexcept > { return (static_cast<_WordT>(1)) << _S_whichbit(__pos); } > > _WordT& > _M_getword(size_t __pos) noexcept > { return _M_w[_S_whichword(__pos)]; } > > constexpr _WordT > _M_getword(size_t __pos) const noexcept > { return _M_w[_S_whichword(__pos)]; } > > > const _WordT* > _M_getdata() const noexcept > { return _M_w; } > > > _WordT& > _M_hiword() noexcept > { return _M_w[_Nw - 1]; } > > constexpr _WordT > _M_hiword() const noexcept > { return _M_w[_Nw - 1]; } > > void > _M_do_and(const _Base_bitset<_Nw>& __x) noexcept > { > for (size_t __i = 0; __i < _Nw; __i++) > _M_w[__i] &= __x._M_w[__i]; > } > > void > _M_do_or(const _Base_bitset<_Nw>& __x) noexcept > { > for (size_t __i = 0; __i < _Nw; __i++) > _M_w[__i] |= __x._M_w[__i]; > } > > void > _M_do_xor(const _Base_bitset<_Nw>& __x) noexcept > { > for (size_t __i = 0; __i < _Nw; __i++) > _M_w[__i] ^= __x._M_w[__i]; > } > > void > _M_do_left_shift(size_t __shift) noexcept; > > void > _M_do_right_shift(size_t __shift) noexcept; > > void > _M_do_flip() noexcept > { > for (size_t __i = 0; __i < _Nw; __i++) > _M_w[__i] = ~_M_w[__i]; > } > > void > _M_do_set() noexcept > { > for (size_t __i = 0; __i < _Nw; __i++) > _M_w[__i] = ~static_cast<_WordT>(0); > } > > void > _M_do_reset() noexcept > { __builtin_memset(_M_w, 0, _Nw * sizeof(_WordT)); } > > bool > _M_is_equal(const _Base_bitset<_Nw>& __x) const noexcept > { > for (size_t __i = 0; __i < _Nw; ++__i) > if (_M_w[__i] != __x._M_w[__i]) > return false; > return true; > } > > template<size_t _Nb> > bool > _M_are_all() const noexcept > { > for (size_t __i = 0; __i < _Nw - 1; __i++) > if (_M_w[__i] != ~static_cast<_WordT>(0)) > return false; > return _M_hiword() == (~static_cast<_WordT>(0) > >> (_Nw * (8 * 8) > - _Nb)); > } > > bool > _M_is_any() const noexcept > { > for (size_t __i = 0; __i < _Nw; __i++) > if (_M_w[__i] != static_cast<_WordT>(0)) > return true; > return false; > } > > size_t > _M_do_count() const noexcept > { > size_t __result = 0; > for (size_t __i = 0; __i < _Nw; __i++) > __result += __builtin_popcountl(_M_w[__i]); > return __result; > } > > unsigned long > _M_do_to_ulong() const; > > > unsigned long long > _M_do_to_ullong() const; > > > > size_t > _M_do_find_first(size_t) const noexcept; > > > size_t > _M_do_find_next(size_t, size_t) const noexcept; > }; > > > template<size_t _Nw> > void > _Base_bitset<_Nw>::_M_do_left_shift(size_t __shift) noexcept > { > if (__builtin_expect(__shift != 0, 1)) > { > const size_t __wshift = __shift / (8 * 8); > const size_t __offset = __shift % (8 * 8); > > if (__offset == 0) > for (size_t __n = _Nw - 1; __n >= __wshift; --__n) > _M_w[__n] = _M_w[__n - __wshift]; > else > { > const size_t __sub_offset = ((8 * 8) > - __offset); > for (size_t __n = _Nw - 1; __n > __wshift; --__n) > _M_w[__n] = ((_M_w[__n - __wshift] << __offset) > | (_M_w[__n - __wshift - 1] >> __sub_offset)); > _M_w[__wshift] = _M_w[0] << __offset; > } > > std::fill(_M_w + 0, _M_w + __wshift, static_cast<_WordT>(0)); > } > } > > template<size_t _Nw> > void > _Base_bitset<_Nw>::_M_do_right_shift(size_t __shift) noexcept > { > if (__builtin_expect(__shift != 0, 1)) > { > const size_t __wshift = __shift / (8 * 8); > const size_t __offset = __shift % (8 * 8); > const size_t __limit = _Nw - __wshift - 1; > > if (__offset == 0) > for (size_t __n = 0; __n <= __limit; ++__n) > _M_w[__n] = _M_w[__n + __wshift]; > else > { > const size_t __sub_offset = ((8 * 8) > - __offset); > for (size_t __n = 0; __n < __limit; ++__n) > _M_w[__n] = ((_M_w[__n + __wshift] >> __offset) > | (_M_w[__n + __wshift + 1] << __sub_offset)); > _M_w[__limit] = _M_w[_Nw-1] >> __offset; > } > > std::fill(_M_w + __limit + 1, _M_w + _Nw, static_cast<_WordT>(0)); > } > } > > template<size_t _Nw> > unsigned long > _Base_bitset<_Nw>::_M_do_to_ulong() const > { > for (size_t __i = 1; __i < _Nw; ++__i) > if (_M_w[__i]) > __throw_overflow_error(("_Base_bitset::_M_do_to_ulong")); > return _M_w[0]; > } > > > template<size_t _Nw> > unsigned long long > _Base_bitset<_Nw>::_M_do_to_ullong() const > { > const bool __dw = sizeof(unsigned long long) > sizeof(unsigned long); > for (size_t __i = 1 + __dw; __i < _Nw; ++__i) > if (_M_w[__i]) > __throw_overflow_error(("_Base_bitset::_M_do_to_ullong")); > > if (__dw) > return _M_w[0] + (static_cast<unsigned long long>(_M_w[1]) > << (8 * 8)); > return _M_w[0]; > } > > > template<size_t _Nw> > size_t > _Base_bitset<_Nw>:: > _M_do_find_first(size_t __not_found) const noexcept > { > for (size_t __i = 0; __i < _Nw; __i++) > { > _WordT __thisword = _M_w[__i]; > if (__thisword != static_cast<_WordT>(0)) > return (__i * (8 * 8) > + __builtin_ctzl(__thisword)); > } > > return __not_found; > } > > template<size_t _Nw> > size_t > _Base_bitset<_Nw>:: > _M_do_find_next(size_t __prev, size_t __not_found) const noexcept > { > > ++__prev; > > > if (__prev >= _Nw * (8 * 8)) > return __not_found; > > > size_t __i = _S_whichword(__prev); > _WordT __thisword = _M_w[__i]; > > > __thisword &= (~static_cast<_WordT>(0)) << _S_whichbit(__prev); > > if (__thisword != static_cast<_WordT>(0)) > return (__i * (8 * 8) > + __builtin_ctzl(__thisword)); > > > __i++; > for (; __i < _Nw; __i++) > { > __thisword = _M_w[__i]; > if (__thisword != static_cast<_WordT>(0)) > return (__i * (8 * 8) > + __builtin_ctzl(__thisword)); > } > > return __not_found; > } > > > > > > > template<> > struct _Base_bitset<1> > { > typedef unsigned long _WordT; > _WordT _M_w; > > constexpr _Base_bitset() noexcept > : _M_w(0) > { } > > > constexpr _Base_bitset(unsigned long long __val) noexcept > > > > : _M_w(__val) > { } > > static constexpr size_t > _S_whichword(size_t __pos) noexcept > { return __pos / (8 * 8); } > > static constexpr size_t > _S_whichbyte(size_t __pos) noexcept > { return (__pos % (8 * 8)) / 8; } > > static constexpr size_t > _S_whichbit(size_t __pos) noexcept > { return __pos % (8 * 8); } > > static constexpr _WordT > _S_maskbit(size_t __pos) noexcept > { return (static_cast<_WordT>(1)) << _S_whichbit(__pos); } > > _WordT& > _M_getword(size_t) noexcept > { return _M_w; } > > constexpr _WordT > _M_getword(size_t) const noexcept > { return _M_w; } > > > const _WordT* > _M_getdata() const noexcept > { return &_M_w; } > > > _WordT& > _M_hiword() noexcept > { return _M_w; } > > constexpr _WordT > _M_hiword() const noexcept > { return _M_w; } > > void > _M_do_and(const _Base_bitset<1>& __x) noexcept > { _M_w &= __x._M_w; } > > void > _M_do_or(const _Base_bitset<1>& __x) noexcept > { _M_w |= __x._M_w; } > > void > _M_do_xor(const _Base_bitset<1>& __x) noexcept > { _M_w ^= __x._M_w; } > > void > _M_do_left_shift(size_t __shift) noexcept > { _M_w <<= __shift; } > > void > _M_do_right_shift(size_t __shift) noexcept > { _M_w >>= __shift; } > > void > _M_do_flip() noexcept > { _M_w = ~_M_w; } > > void > _M_do_set() noexcept > { _M_w = ~static_cast<_WordT>(0); } > > void > _M_do_reset() noexcept > { _M_w = 0; } > > bool > _M_is_equal(const _Base_bitset<1>& __x) const noexcept > { return _M_w == __x._M_w; } > > template<size_t _Nb> > bool > _M_are_all() const noexcept > { return _M_w == (~static_cast<_WordT>(0) > >> ((8 * 8) - _Nb)); } > > bool > _M_is_any() const noexcept > { return _M_w != 0; } > > size_t > _M_do_count() const noexcept > { return __builtin_popcountl(_M_w); } > > unsigned long > _M_do_to_ulong() const noexcept > { return _M_w; } > > > unsigned long long > _M_do_to_ullong() const noexcept > { return _M_w; } > > > size_t > _M_do_find_first(size_t __not_found) const noexcept > { > if (_M_w != 0) > return __builtin_ctzl(_M_w); > else > return __not_found; > } > > > size_t > _M_do_find_next(size_t __prev, size_t __not_found) const > noexcept > { > ++__prev; > if (__prev >= ((size_t) (8 * 8))) > return __not_found; > > _WordT __x = _M_w >> __prev; > if (__x != 0) > return __builtin_ctzl(__x) + __prev; > else > return __not_found; > } > }; > > > > > > > template<> > struct _Base_bitset<0> > { > typedef unsigned long _WordT; > > constexpr _Base_bitset() noexcept > { } > > > constexpr _Base_bitset(unsigned long long) noexcept > > > > { } > > static constexpr size_t > _S_whichword(size_t __pos) noexcept > { return __pos / (8 * 8); } > > static constexpr size_t > _S_whichbyte(size_t __pos) noexcept > { return (__pos % (8 * 8)) / 8; } > > static constexpr size_t > _S_whichbit(size_t __pos) noexcept > { return __pos % (8 * 8); } > > static constexpr _WordT > _S_maskbit(size_t __pos) noexcept > { return (static_cast<_WordT>(1)) << _S_whichbit(__pos); } ># 556 "/usr/include/c++/4.9.0/bitset" 3 > _WordT& > _M_getword(size_t) noexcept > { > __throw_out_of_range(("_Base_bitset::_M_getword")); > return *new _WordT; > } > > constexpr _WordT > _M_getword(size_t __pos) const noexcept > { return 0; } > > constexpr _WordT > _M_hiword() const noexcept > { return 0; } > > void > _M_do_and(const _Base_bitset<0>&) noexcept > { } > > void > _M_do_or(const _Base_bitset<0>&) noexcept > { } > > void > _M_do_xor(const _Base_bitset<0>&) noexcept > { } > > void > _M_do_left_shift(size_t) noexcept > { } > > void > _M_do_right_shift(size_t) noexcept > { } > > void > _M_do_flip() noexcept > { } > > void > _M_do_set() noexcept > { } > > void > _M_do_reset() noexcept > { } > > > > > bool > _M_is_equal(const _Base_bitset<0>&) const noexcept > { return true; } > > template<size_t _Nb> > bool > _M_are_all() const noexcept > { return true; } > > bool > _M_is_any() const noexcept > { return false; } > > size_t > _M_do_count() const noexcept > { return 0; } > > unsigned long > _M_do_to_ulong() const noexcept > { return 0; } > > > unsigned long long > _M_do_to_ullong() const noexcept > { return 0; } > > > > > size_t > _M_do_find_first(size_t) const noexcept > { return 0; } > > size_t > _M_do_find_next(size_t, size_t) const noexcept > { return 0; } > }; > > > > template<size_t _Extrabits> > struct _Sanitize > { > typedef unsigned long _WordT; > > static void > _S_do_sanitize(_WordT& __val) noexcept > { __val &= ~((~static_cast<_WordT>(0)) << _Extrabits); } > }; > > template<> > struct _Sanitize<0> > { > typedef unsigned long _WordT; > > static void > _S_do_sanitize(_WordT) noexcept { } > }; > > > template<size_t _Nb, bool = _Nb < (8 * 8)> > struct _Sanitize_val > { > static constexpr unsigned long long > _S_do_sanitize_val(unsigned long long __val) > { return __val; } > }; > > template<size_t _Nb> > struct _Sanitize_val<_Nb, true> > { > static constexpr unsigned long long > _S_do_sanitize_val(unsigned long long __val) > { return __val & ~((~static_cast<unsigned long long>(0)) << _Nb); } > }; ># 747 "/usr/include/c++/4.9.0/bitset" 3 > template<size_t _Nb> > class bitset > : private _Base_bitset<((_Nb) / (8 * 8) + ((_Nb) % (8 * 8) == 0 ? 0 : 1))> > { > private: > typedef _Base_bitset<((_Nb) / (8 * 8) + ((_Nb) % (8 * 8) == 0 ? 0 : 1))> _Base; > typedef unsigned long _WordT; > > template<class _CharT, class _Traits, class _Alloc> > void > _M_check_initial_position(const std::basic_string<_CharT, _Traits, _Alloc>& __s, > size_t __position) const > { > if (__position > __s.size()) > __throw_out_of_range_fmt(("bitset::bitset: __position " "(which is %zu) > __s.size() " "(which is %zu)") > > , > __position, __s.size()); > } > > void _M_check(size_t __position, const char *__s) const > { > if (__position >= _Nb) > __throw_out_of_range_fmt(("%s: __position (which is %zu) " ">= _Nb (which is %zu)") > , > __s, __position, _Nb); > } > > void > _M_do_sanitize() noexcept > { > typedef _Sanitize<_Nb % (8 * 8)> __sanitize_type; > __sanitize_type::_S_do_sanitize(this->_M_hiword()); > } > > > template<typename> friend struct hash; > > > public: ># 799 "/usr/include/c++/4.9.0/bitset" 3 > class reference > { > friend class bitset; > > _WordT* _M_wp; > size_t _M_bpos; > > > reference(); > > public: > reference(bitset& __b, size_t __pos) noexcept > { > _M_wp = &__b._M_getword(__pos); > _M_bpos = _Base::_S_whichbit(__pos); > } > > ~reference() noexcept > { } > > > reference& > operator=(bool __x) noexcept > { > if (__x) > *_M_wp |= _Base::_S_maskbit(_M_bpos); > else > *_M_wp &= ~_Base::_S_maskbit(_M_bpos); > return *this; > } > > > reference& > operator=(const reference& __j) noexcept > { > if ((*(__j._M_wp) & _Base::_S_maskbit(__j._M_bpos))) > *_M_wp |= _Base::_S_maskbit(_M_bpos); > else > *_M_wp &= ~_Base::_S_maskbit(_M_bpos); > return *this; > } > > > bool > operator~() const noexcept > { return (*(_M_wp) & _Base::_S_maskbit(_M_bpos)) == 0; } > > > operator bool() const noexcept > { return (*(_M_wp) & _Base::_S_maskbit(_M_bpos)) != 0; } > > > reference& > flip() noexcept > { > *_M_wp ^= _Base::_S_maskbit(_M_bpos); > return *this; > } > }; > friend class reference; > > > > constexpr bitset() noexcept > { } > > > > constexpr bitset(unsigned long long __val) noexcept > : _Base(_Sanitize_val<_Nb>::_S_do_sanitize_val(__val)) { } ># 884 "/usr/include/c++/4.9.0/bitset" 3 > template<class _CharT, class _Traits, class _Alloc> > explicit > bitset(const std::basic_string<_CharT, _Traits, _Alloc>& __s, > size_t __position = 0) > : _Base() > { > _M_check_initial_position(__s, __position); > _M_copy_from_string(__s, __position, > std::basic_string<_CharT, _Traits, _Alloc>::npos, > _CharT('0'), _CharT('1')); > } ># 906 "/usr/include/c++/4.9.0/bitset" 3 > template<class _CharT, class _Traits, class _Alloc> > bitset(const std::basic_string<_CharT, _Traits, _Alloc>& __s, > size_t __position, size_t __n) > : _Base() > { > _M_check_initial_position(__s, __position); > _M_copy_from_string(__s, __position, __n, _CharT('0'), _CharT('1')); > } > > > > template<class _CharT, class _Traits, class _Alloc> > bitset(const std::basic_string<_CharT, _Traits, _Alloc>& __s, > size_t __position, size_t __n, > _CharT __zero, _CharT __one = _CharT('1')) > : _Base() > { > _M_check_initial_position(__s, __position); > _M_copy_from_string(__s, __position, __n, __zero, __one); > } ># 937 "/usr/include/c++/4.9.0/bitset" 3 > template<typename _CharT> > explicit > bitset(const _CharT* __str, > typename std::basic_string<_CharT>::size_type __n > = std::basic_string<_CharT>::npos, > _CharT __zero = _CharT('0'), _CharT __one = _CharT('1')) > : _Base() > { > if (!__str) > __throw_logic_error(("bitset::bitset(const _CharT*, ...)")); > > if (__n == std::basic_string<_CharT>::npos) > __n = std::char_traits<_CharT>::length(__str); > _M_copy_from_ptr<_CharT, std::char_traits<_CharT>>(__str, __n, 0, > __n, __zero, > __one); > } ># 964 "/usr/include/c++/4.9.0/bitset" 3 > bitset<_Nb>& > operator&=(const bitset<_Nb>& __rhs) noexcept > { > this->_M_do_and(__rhs); > return *this; > } > > bitset<_Nb>& > operator|=(const bitset<_Nb>& __rhs) noexcept > { > this->_M_do_or(__rhs); > return *this; > } > > bitset<_Nb>& > operator^=(const bitset<_Nb>& __rhs) noexcept > { > this->_M_do_xor(__rhs); > return *this; > } ># 993 "/usr/include/c++/4.9.0/bitset" 3 > bitset<_Nb>& > operator<<=(size_t __position) noexcept > { > if (__builtin_expect(__position < _Nb, 1)) > { > this->_M_do_left_shift(__position); > this->_M_do_sanitize(); > } > else > this->_M_do_reset(); > return *this; > } > > bitset<_Nb>& > operator>>=(size_t __position) noexcept > { > if (__builtin_expect(__position < _Nb, 1)) > { > this->_M_do_right_shift(__position); > this->_M_do_sanitize(); > } > else > this->_M_do_reset(); > return *this; > } ># 1026 "/usr/include/c++/4.9.0/bitset" 3 > bitset<_Nb>& > _Unchecked_set(size_t __pos) noexcept > { > this->_M_getword(__pos) |= _Base::_S_maskbit(__pos); > return *this; > } > > bitset<_Nb>& > _Unchecked_set(size_t __pos, int __val) noexcept > { > if (__val) > this->_M_getword(__pos) |= _Base::_S_maskbit(__pos); > else > this->_M_getword(__pos) &= ~_Base::_S_maskbit(__pos); > return *this; > } > > bitset<_Nb>& > _Unchecked_reset(size_t __pos) noexcept > { > this->_M_getword(__pos) &= ~_Base::_S_maskbit(__pos); > return *this; > } > > bitset<_Nb>& > _Unchecked_flip(size_t __pos) noexcept > { > this->_M_getword(__pos) ^= _Base::_S_maskbit(__pos); > return *this; > } > > constexpr bool > _Unchecked_test(size_t __pos) const noexcept > { return ((this->_M_getword(__pos) & _Base::_S_maskbit(__pos)) > != static_cast<_WordT>(0)); } > > > > > > > bitset<_Nb>& > set() noexcept > { > this->_M_do_set(); > this->_M_do_sanitize(); > return *this; > } > > > > > > > > bitset<_Nb>& > set(size_t __position, bool __val = true) > { > this->_M_check(__position, ("bitset::set")); > return _Unchecked_set(__position, __val); > } > > > > > bitset<_Nb>& > reset() noexcept > { > this->_M_do_reset(); > return *this; > } ># 1105 "/usr/include/c++/4.9.0/bitset" 3 > bitset<_Nb>& > reset(size_t __position) > { > this->_M_check(__position, ("bitset::reset")); > return _Unchecked_reset(__position); > } > > > > > bitset<_Nb>& > flip() noexcept > { > this->_M_do_flip(); > this->_M_do_sanitize(); > return *this; > } > > > > > > > bitset<_Nb>& > flip(size_t __position) > { > this->_M_check(__position, ("bitset::flip")); > return _Unchecked_flip(__position); > } > > > bitset<_Nb> > operator~() const noexcept > { return bitset<_Nb>(*this).flip(); } ># 1155 "/usr/include/c++/4.9.0/bitset" 3 > reference > operator[](size_t __position) > { return reference(*this, __position); } > > constexpr bool > operator[](size_t __position) const > { return _Unchecked_test(__position); } ># 1170 "/usr/include/c++/4.9.0/bitset" 3 > unsigned long > to_ulong() const > { return this->_M_do_to_ulong(); } > > > unsigned long long > to_ullong() const > { return this->_M_do_to_ullong(); } ># 1188 "/usr/include/c++/4.9.0/bitset" 3 > template<class _CharT, class _Traits, class _Alloc> > std::basic_string<_CharT, _Traits, _Alloc> > to_string() const > { > std::basic_string<_CharT, _Traits, _Alloc> __result; > _M_copy_to_string(__result, _CharT('0'), _CharT('1')); > return __result; > } > > > > template<class _CharT, class _Traits, class _Alloc> > std::basic_string<_CharT, _Traits, _Alloc> > to_string(_CharT __zero, _CharT __one = _CharT('1')) const > { > std::basic_string<_CharT, _Traits, _Alloc> __result; > _M_copy_to_string(__result, __zero, __one); > return __result; > } > > > > template<class _CharT, class _Traits> > std::basic_string<_CharT, _Traits, std::allocator<_CharT> > > to_string() const > { return to_string<_CharT, _Traits, std::allocator<_CharT> >(); } > > > > template<class _CharT, class _Traits> > std::basic_string<_CharT, _Traits, std::allocator<_CharT> > > to_string(_CharT __zero, _CharT __one = _CharT('1')) const > { return to_string<_CharT, _Traits, > std::allocator<_CharT> >(__zero, __one); } > > template<class _CharT> > std::basic_string<_CharT, std::char_traits<_CharT>, > std::allocator<_CharT> > > to_string() const > { > return to_string<_CharT, std::char_traits<_CharT>, > std::allocator<_CharT> >(); > } > > template<class _CharT> > std::basic_string<_CharT, std::char_traits<_CharT>, > std::allocator<_CharT> > > to_string(_CharT __zero, _CharT __one = _CharT('1')) const > { > return to_string<_CharT, std::char_traits<_CharT>, > std::allocator<_CharT> >(__zero, __one); > } > > std::basic_string<char, std::char_traits<char>, std::allocator<char> > > to_string() const > { > return to_string<char, std::char_traits<char>, > std::allocator<char> >(); > } > > std::basic_string<char, std::char_traits<char>, std::allocator<char> > > to_string(char __zero, char __one = '1') const > { > return to_string<char, std::char_traits<char>, > std::allocator<char> >(__zero, __one); > } > > > template<class _CharT, class _Traits> > void > _M_copy_from_ptr(const _CharT*, size_t, size_t, size_t, > _CharT, _CharT); > > template<class _CharT, class _Traits, class _Alloc> > void > _M_copy_from_string(const std::basic_string<_CharT, > _Traits, _Alloc>& __s, size_t __pos, size_t __n, > _CharT __zero, _CharT __one) > { _M_copy_from_ptr<_CharT, _Traits>(__s.data(), __s.size(), __pos, __n, > __zero, __one); } > > template<class _CharT, class _Traits, class _Alloc> > void > _M_copy_to_string(std::basic_string<_CharT, _Traits, _Alloc>&, > _CharT, _CharT) const; > > > template<class _CharT, class _Traits, class _Alloc> > void > _M_copy_from_string(const std::basic_string<_CharT, > _Traits, _Alloc>& __s, size_t __pos, size_t __n) > { _M_copy_from_string(__s, __pos, __n, _CharT('0'), _CharT('1')); } > > template<class _CharT, class _Traits, class _Alloc> > void > _M_copy_to_string(std::basic_string<_CharT, _Traits,_Alloc>& __s) const > { _M_copy_to_string(__s, _CharT('0'), _CharT('1')); } > > > size_t > count() const noexcept > { return this->_M_do_count(); } > > > constexpr size_t > size() const noexcept > { return _Nb; } > > > > bool > operator==(const bitset<_Nb>& __rhs) const noexcept > { return this->_M_is_equal(__rhs); } > > bool > operator!=(const bitset<_Nb>& __rhs) const noexcept > { return !this->_M_is_equal(__rhs); } ># 1313 "/usr/include/c++/4.9.0/bitset" 3 > bool > test(size_t __position) const > { > this->_M_check(__position, ("bitset::test")); > return _Unchecked_test(__position); > } > > > > > > > > bool > all() const noexcept > { return this->template _M_are_all<_Nb>(); } > > > > > > bool > any() const noexcept > { return this->_M_is_any(); } > > > > > > bool > none() const noexcept > { return !this->_M_is_any(); } > > > > bitset<_Nb> > operator<<(size_t __position) const noexcept > { return bitset<_Nb>(*this) <<= __position; } > > bitset<_Nb> > operator>>(size_t __position) const noexcept > { return bitset<_Nb>(*this) >>= __position; } ># 1363 "/usr/include/c++/4.9.0/bitset" 3 > size_t > _Find_first() const noexcept > { return this->_M_do_find_first(_Nb); } ># 1374 "/usr/include/c++/4.9.0/bitset" 3 > size_t > _Find_next(size_t __prev) const noexcept > { return this->_M_do_find_next(__prev, _Nb); } > }; > > > template<size_t _Nb> > template<class _CharT, class _Traits> > void > bitset<_Nb>:: > _M_copy_from_ptr(const _CharT* __s, size_t __len, > size_t __pos, size_t __n, _CharT __zero, _CharT __one) > { > reset(); > const size_t __nbits = std::min(_Nb, std::min(__n, size_t(__len - __pos))); > for (size_t __i = __nbits; __i > 0; --__i) > { > const _CharT __c = __s[__pos + __nbits - __i]; > if (_Traits::eq(__c, __zero)) > ; > else if (_Traits::eq(__c, __one)) > _Unchecked_set(__i - 1); > else > __throw_invalid_argument(("bitset::_M_copy_from_ptr")); > } > } > > template<size_t _Nb> > template<class _CharT, class _Traits, class _Alloc> > void > bitset<_Nb>:: > _M_copy_to_string(std::basic_string<_CharT, _Traits, _Alloc>& __s, > _CharT __zero, _CharT __one) const > { > __s.assign(_Nb, __zero); > for (size_t __i = _Nb; __i > 0; --__i) > if (_Unchecked_test(__i - 1)) > _Traits::assign(__s[_Nb - __i], __one); > } ># 1424 "/usr/include/c++/4.9.0/bitset" 3 > template<size_t _Nb> > inline bitset<_Nb> > operator&(const bitset<_Nb>& __x, const bitset<_Nb>& __y) noexcept > { > bitset<_Nb> __result(__x); > __result &= __y; > return __result; > } > > template<size_t _Nb> > inline bitset<_Nb> > operator|(const bitset<_Nb>& __x, const bitset<_Nb>& __y) noexcept > { > bitset<_Nb> __result(__x); > __result |= __y; > return __result; > } > > template <size_t _Nb> > inline bitset<_Nb> > operator^(const bitset<_Nb>& __x, const bitset<_Nb>& __y) noexcept > { > bitset<_Nb> __result(__x); > __result ^= __y; > return __result; > } ># 1461 "/usr/include/c++/4.9.0/bitset" 3 > template<class _CharT, class _Traits, size_t _Nb> > std::basic_istream<_CharT, _Traits>& > operator>>(std::basic_istream<_CharT, _Traits>& __is, bitset<_Nb>& __x) > { > typedef typename _Traits::char_type char_type; > typedef std::basic_istream<_CharT, _Traits> __istream_type; > typedef typename __istream_type::ios_base __ios_base; > > std::basic_string<_CharT, _Traits> __tmp; > __tmp.reserve(_Nb); > > > > const char_type __zero = __is.widen('0'); > const char_type __one = __is.widen('1'); > > typename __ios_base::iostate __state = __ios_base::goodbit; > typename __istream_type::sentry __sentry(__is); > if (__sentry) > { > try > { > for (size_t __i = _Nb; __i > 0; --__i) > { > static typename _Traits::int_type __eof = _Traits::eof(); > > typename _Traits::int_type __c1 = __is.rdbuf()->sbumpc(); > if (_Traits::eq_int_type(__c1, __eof)) > { > __state |= __ios_base::eofbit; > break; > } > else > { > const char_type __c2 = _Traits::to_char_type(__c1); > if (_Traits::eq(__c2, __zero)) > __tmp.push_back(__zero); > else if (_Traits::eq(__c2, __one)) > __tmp.push_back(__one); > else if (_Traits:: > eq_int_type(__is.rdbuf()->sputbackc(__c2), > __eof)) > { > __state |= __ios_base::failbit; > break; > } > } > } > } > catch(__cxxabiv1::__forced_unwind&) > { > __is._M_setstate(__ios_base::badbit); > throw; > } > catch(...) > { __is._M_setstate(__ios_base::badbit); } > } > > if (__tmp.empty() && _Nb) > __state |= __ios_base::failbit; > else > __x._M_copy_from_string(__tmp, static_cast<size_t>(0), _Nb, > __zero, __one); > if (__state) > __is.setstate(__state); > return __is; > } > > template <class _CharT, class _Traits, size_t _Nb> > std::basic_ostream<_CharT, _Traits>& > operator<<(std::basic_ostream<_CharT, _Traits>& __os, > const bitset<_Nb>& __x) > { > std::basic_string<_CharT, _Traits> __tmp; > > > > const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__os.getloc()); > __x._M_copy_to_string(__tmp, __ct.widen('0'), __ct.widen('1')); > return __os << __tmp; > } > > > >} ># 1555 "/usr/include/c++/4.9.0/bitset" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > template<size_t _Nb> > struct hash<std::bitset<_Nb>> > : public __hash_base<size_t, std::bitset<_Nb>> > { > size_t > operator()(const std::bitset<_Nb>& __b) const noexcept > { > const size_t __clength = (_Nb + 8 - 1) / 8; > return std::_Hash_impl::hash(__b._M_getdata(), __clength); > } > }; > > template<> > struct hash<std::bitset<0>> > : public __hash_base<size_t, std::bitset<0>> > { > size_t > operator()(const std::bitset<0>&) const noexcept > { return 0; } > }; > > >} ># 97 "/usr/include/boost/detail/container_fwd.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/complex" 1 3 4 ># 39 "/usr/include/c++/4.9.0/complex" 3 4 ># 40 "/usr/include/c++/4.9.0/complex" 3 > > > > ># 1 "/usr/include/c++/4.9.0/cmath" 1 3 ># 39 "/usr/include/c++/4.9.0/cmath" 3 ># 40 "/usr/include/c++/4.9.0/cmath" 3 ># 45 "/usr/include/c++/4.9.0/complex" 2 3 > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 63 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> class complex; > template<> class complex<float>; > template<> class complex<double>; > template<> class complex<long double>; > > > template<typename _Tp> _Tp abs(const complex<_Tp>&); > > template<typename _Tp> _Tp arg(const complex<_Tp>&); > > template<typename _Tp> _Tp norm(const complex<_Tp>&); > > > template<typename _Tp> complex<_Tp> conj(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> polar(const _Tp&, const _Tp& = 0); > > > > template<typename _Tp> complex<_Tp> cos(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> cosh(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> exp(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> log(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> log10(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> pow(const complex<_Tp>&, int); > > template<typename _Tp> complex<_Tp> pow(const complex<_Tp>&, const _Tp&); > > template<typename _Tp> complex<_Tp> pow(const complex<_Tp>&, > const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> pow(const _Tp&, const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> sin(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> sinh(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> sqrt(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> tan(const complex<_Tp>&); > > template<typename _Tp> complex<_Tp> tanh(const complex<_Tp>&); ># 121 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > struct complex > { > > typedef _Tp value_type; > > > > constexpr complex(const _Tp& __r = _Tp(), const _Tp& __i = _Tp()) > : _M_real(__r), _M_imag(__i) { } > > > > > template<typename _Up> > constexpr complex(const complex<_Up>& __z) > : _M_real(__z.real()), _M_imag(__z.imag()) { } > > > > > __attribute ((__abi_tag__ ("cxx11"))) > constexpr _Tp > real() { return _M_real; } > > __attribute ((__abi_tag__ ("cxx11"))) > constexpr _Tp > imag() { return _M_imag; } ># 169 "/usr/include/c++/4.9.0/complex" 3 > void > real(_Tp __val) { _M_real = __val; } > > void > imag(_Tp __val) { _M_imag = __val; } > > > complex<_Tp>& operator=(const _Tp&); > > > > complex<_Tp>& > operator+=(const _Tp& __t) > { > _M_real += __t; > return *this; > } > > > > complex<_Tp>& > operator-=(const _Tp& __t) > { > _M_real -= __t; > return *this; > } > > > complex<_Tp>& operator*=(const _Tp&); > > complex<_Tp>& operator/=(const _Tp&); > > > > > > template<typename _Up> > complex<_Tp>& operator=(const complex<_Up>&); > > template<typename _Up> > complex<_Tp>& operator+=(const complex<_Up>&); > > template<typename _Up> > complex<_Tp>& operator-=(const complex<_Up>&); > > template<typename _Up> > complex<_Tp>& operator*=(const complex<_Up>&); > > template<typename _Up> > complex<_Tp>& operator/=(const complex<_Up>&); > > constexpr complex __rep() const > { return *this; } > > private: > _Tp _M_real; > _Tp _M_imag; > }; > > template<typename _Tp> > complex<_Tp>& > complex<_Tp>::operator=(const _Tp& __t) > { > _M_real = __t; > _M_imag = _Tp(); > return *this; > } > > > template<typename _Tp> > complex<_Tp>& > complex<_Tp>::operator*=(const _Tp& __t) > { > _M_real *= __t; > _M_imag *= __t; > return *this; > } > > > template<typename _Tp> > complex<_Tp>& > complex<_Tp>::operator/=(const _Tp& __t) > { > _M_real /= __t; > _M_imag /= __t; > return *this; > } > > template<typename _Tp> > template<typename _Up> > complex<_Tp>& > complex<_Tp>::operator=(const complex<_Up>& __z) > { > _M_real = __z.real(); > _M_imag = __z.imag(); > return *this; > } > > > template<typename _Tp> > template<typename _Up> > complex<_Tp>& > complex<_Tp>::operator+=(const complex<_Up>& __z) > { > _M_real += __z.real(); > _M_imag += __z.imag(); > return *this; > } > > > template<typename _Tp> > template<typename _Up> > complex<_Tp>& > complex<_Tp>::operator-=(const complex<_Up>& __z) > { > _M_real -= __z.real(); > _M_imag -= __z.imag(); > return *this; > } > > > > template<typename _Tp> > template<typename _Up> > complex<_Tp>& > complex<_Tp>::operator*=(const complex<_Up>& __z) > { > const _Tp __r = _M_real * __z.real() - _M_imag * __z.imag(); > _M_imag = _M_real * __z.imag() + _M_imag * __z.real(); > _M_real = __r; > return *this; > } > > > > template<typename _Tp> > template<typename _Up> > complex<_Tp>& > complex<_Tp>::operator/=(const complex<_Up>& __z) > { > const _Tp __r = _M_real * __z.real() + _M_imag * __z.imag(); > const _Tp __n = std::norm(__z); > _M_imag = (_M_imag * __z.real() - _M_real * __z.imag()) / __n; > _M_real = __r / __n; > return *this; > } > > > > > template<typename _Tp> > inline complex<_Tp> > operator+(const complex<_Tp>& __x, const complex<_Tp>& __y) > { > complex<_Tp> __r = __x; > __r += __y; > return __r; > } > > template<typename _Tp> > inline complex<_Tp> > operator+(const complex<_Tp>& __x, const _Tp& __y) > { > complex<_Tp> __r = __x; > __r += __y; > return __r; > } > > template<typename _Tp> > inline complex<_Tp> > operator+(const _Tp& __x, const complex<_Tp>& __y) > { > complex<_Tp> __r = __y; > __r += __x; > return __r; > } > > > > > template<typename _Tp> > inline complex<_Tp> > operator-(const complex<_Tp>& __x, const complex<_Tp>& __y) > { > complex<_Tp> __r = __x; > __r -= __y; > return __r; > } > > template<typename _Tp> > inline complex<_Tp> > operator-(const complex<_Tp>& __x, const _Tp& __y) > { > complex<_Tp> __r = __x; > __r -= __y; > return __r; > } > > template<typename _Tp> > inline complex<_Tp> > operator-(const _Tp& __x, const complex<_Tp>& __y) > { > complex<_Tp> __r(__x, -__y.imag()); > __r -= __y.real(); > return __r; > } > > > > > template<typename _Tp> > inline complex<_Tp> > operator*(const complex<_Tp>& __x, const complex<_Tp>& __y) > { > complex<_Tp> __r = __x; > __r *= __y; > return __r; > } > > template<typename _Tp> > inline complex<_Tp> > operator*(const complex<_Tp>& __x, const _Tp& __y) > { > complex<_Tp> __r = __x; > __r *= __y; > return __r; > } > > template<typename _Tp> > inline complex<_Tp> > operator*(const _Tp& __x, const complex<_Tp>& __y) > { > complex<_Tp> __r = __y; > __r *= __x; > return __r; > } > > > > > template<typename _Tp> > inline complex<_Tp> > operator/(const complex<_Tp>& __x, const complex<_Tp>& __y) > { > complex<_Tp> __r = __x; > __r /= __y; > return __r; > } > > template<typename _Tp> > inline complex<_Tp> > operator/(const complex<_Tp>& __x, const _Tp& __y) > { > complex<_Tp> __r = __x; > __r /= __y; > return __r; > } > > template<typename _Tp> > inline complex<_Tp> > operator/(const _Tp& __x, const complex<_Tp>& __y) > { > complex<_Tp> __r = __x; > __r /= __y; > return __r; > } > > > > template<typename _Tp> > inline complex<_Tp> > operator+(const complex<_Tp>& __x) > { return __x; } > > > template<typename _Tp> > inline complex<_Tp> > operator-(const complex<_Tp>& __x) > { return complex<_Tp>(-__x.real(), -__x.imag()); } > > > > template<typename _Tp> > inline constexpr bool > operator==(const complex<_Tp>& __x, const complex<_Tp>& __y) > { return __x.real() == __y.real() && __x.imag() == __y.imag(); } > > template<typename _Tp> > inline constexpr bool > operator==(const complex<_Tp>& __x, const _Tp& __y) > { return __x.real() == __y && __x.imag() == _Tp(); } > > template<typename _Tp> > inline constexpr bool > operator==(const _Tp& __x, const complex<_Tp>& __y) > { return __x == __y.real() && _Tp() == __y.imag(); } > > > > > template<typename _Tp> > inline constexpr bool > operator!=(const complex<_Tp>& __x, const complex<_Tp>& __y) > { return __x.real() != __y.real() || __x.imag() != __y.imag(); } > > template<typename _Tp> > inline constexpr bool > operator!=(const complex<_Tp>& __x, const _Tp& __y) > { return __x.real() != __y || __x.imag() != _Tp(); } > > template<typename _Tp> > inline constexpr bool > operator!=(const _Tp& __x, const complex<_Tp>& __y) > { return __x != __y.real() || _Tp() != __y.imag(); } > > > > template<typename _Tp, typename _CharT, class _Traits> > basic_istream<_CharT, _Traits>& > operator>>(basic_istream<_CharT, _Traits>& __is, complex<_Tp>& __x) > { > _Tp __re_x, __im_x; > _CharT __ch; > __is >> __ch; > if (__ch == '(') > { > __is >> __re_x >> __ch; > if (__ch == ',') > { > __is >> __im_x >> __ch; > if (__ch == ')') > __x = complex<_Tp>(__re_x, __im_x); > else > __is.setstate(ios_base::failbit); > } > else if (__ch == ')') > __x = __re_x; > else > __is.setstate(ios_base::failbit); > } > else > { > __is.putback(__ch); > __is >> __re_x; > __x = __re_x; > } > return __is; > } > > > template<typename _Tp, typename _CharT, class _Traits> > basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, const complex<_Tp>& __x) > { > basic_ostringstream<_CharT, _Traits> __s; > __s.flags(__os.flags()); > __s.imbue(__os.getloc()); > __s.precision(__os.precision()); > __s << '(' << __x.real() << ',' << __x.imag() << ')'; > return __os << __s.str(); > } > > > > template<typename _Tp> > constexpr _Tp > real(const complex<_Tp>& __z) > { return __z.real(); } > > template<typename _Tp> > constexpr _Tp > imag(const complex<_Tp>& __z) > { return __z.imag(); } ># 565 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > inline _Tp > __complex_abs(const complex<_Tp>& __z) > { > _Tp __x = __z.real(); > _Tp __y = __z.imag(); > const _Tp __s = std::max(abs(__x), abs(__y)); > if (__s == _Tp()) > return __s; > __x /= __s; > __y /= __s; > return __s * sqrt(__x * __x + __y * __y); > } > > > inline float > __complex_abs(__complex__ float __z) { return __builtin_cabsf(__z); } > > inline double > __complex_abs(__complex__ double __z) { return __builtin_cabs(__z); } > > inline long double > __complex_abs(const __complex__ long double& __z) > { return __builtin_cabsl(__z); } > > template<typename _Tp> > inline _Tp > abs(const complex<_Tp>& __z) { return __complex_abs(__z.__rep()); } ># 601 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > inline _Tp > __complex_arg(const complex<_Tp>& __z) > { return atan2(__z.imag(), __z.real()); } > > > inline float > __complex_arg(__complex__ float __z) { return __builtin_cargf(__z); } > > inline double > __complex_arg(__complex__ double __z) { return __builtin_carg(__z); } > > inline long double > __complex_arg(const __complex__ long double& __z) > { return __builtin_cargl(__z); } > > template<typename _Tp> > inline _Tp > arg(const complex<_Tp>& __z) { return __complex_arg(__z.__rep()); } ># 631 "/usr/include/c++/4.9.0/complex" 3 > template<bool> > struct _Norm_helper > { > template<typename _Tp> > static inline _Tp _S_do_it(const complex<_Tp>& __z) > { > const _Tp __x = __z.real(); > const _Tp __y = __z.imag(); > return __x * __x + __y * __y; > } > }; > > template<> > struct _Norm_helper<true> > { > template<typename _Tp> > static inline _Tp _S_do_it(const complex<_Tp>& __z) > { > _Tp __res = std::abs(__z); > return __res * __res; > } > }; > > template<typename _Tp> > inline _Tp > norm(const complex<_Tp>& __z) > { > return _Norm_helper<__is_floating<_Tp>::__value > && !0>::_S_do_it(__z); > } > > template<typename _Tp> > inline complex<_Tp> > polar(const _Tp& __rho, const _Tp& __theta) > { return complex<_Tp>(__rho * cos(__theta), __rho * sin(__theta)); } > > template<typename _Tp> > inline complex<_Tp> > conj(const complex<_Tp>& __z) > { return complex<_Tp>(__z.real(), -__z.imag()); } > > > > > template<typename _Tp> > inline complex<_Tp> > __complex_cos(const complex<_Tp>& __z) > { > const _Tp __x = __z.real(); > const _Tp __y = __z.imag(); > return complex<_Tp>(cos(__x) * cosh(__y), -sin(__x) * sinh(__y)); > } > > > inline __complex__ float > __complex_cos(__complex__ float __z) { return __builtin_ccosf(__z); } > > inline __complex__ double > __complex_cos(__complex__ double __z) { return __builtin_ccos(__z); } > > inline __complex__ long double > __complex_cos(const __complex__ long double& __z) > { return __builtin_ccosl(__z); } > > template<typename _Tp> > inline complex<_Tp> > cos(const complex<_Tp>& __z) { return __complex_cos(__z.__rep()); } > > > > > > > > template<typename _Tp> > inline complex<_Tp> > __complex_cosh(const complex<_Tp>& __z) > { > const _Tp __x = __z.real(); > const _Tp __y = __z.imag(); > return complex<_Tp>(cosh(__x) * cos(__y), sinh(__x) * sin(__y)); > } > > > inline __complex__ float > __complex_cosh(__complex__ float __z) { return __builtin_ccoshf(__z); } > > inline __complex__ double > __complex_cosh(__complex__ double __z) { return __builtin_ccosh(__z); } > > inline __complex__ long double > __complex_cosh(const __complex__ long double& __z) > { return __builtin_ccoshl(__z); } > > template<typename _Tp> > inline complex<_Tp> > cosh(const complex<_Tp>& __z) { return __complex_cosh(__z.__rep()); } > > > > > > > > template<typename _Tp> > inline complex<_Tp> > __complex_exp(const complex<_Tp>& __z) > { return std::polar(exp(__z.real()), __z.imag()); } > > > inline __complex__ float > __complex_exp(__complex__ float __z) { return __builtin_cexpf(__z); } > > inline __complex__ double > __complex_exp(__complex__ double __z) { return __builtin_cexp(__z); } > > inline __complex__ long double > __complex_exp(const __complex__ long double& __z) > { return __builtin_cexpl(__z); } > > template<typename _Tp> > inline complex<_Tp> > exp(const complex<_Tp>& __z) { return __complex_exp(__z.__rep()); } ># 762 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > inline complex<_Tp> > __complex_log(const complex<_Tp>& __z) > { return complex<_Tp>(log(std::abs(__z)), std::arg(__z)); } > > > inline __complex__ float > __complex_log(__complex__ float __z) { return __builtin_clogf(__z); } > > inline __complex__ double > __complex_log(__complex__ double __z) { return __builtin_clog(__z); } > > inline __complex__ long double > __complex_log(const __complex__ long double& __z) > { return __builtin_clogl(__z); } > > template<typename _Tp> > inline complex<_Tp> > log(const complex<_Tp>& __z) { return __complex_log(__z.__rep()); } > > > > > > > template<typename _Tp> > inline complex<_Tp> > log10(const complex<_Tp>& __z) > { return std::log(__z) / log(_Tp(10.0)); } > > > template<typename _Tp> > inline complex<_Tp> > __complex_sin(const complex<_Tp>& __z) > { > const _Tp __x = __z.real(); > const _Tp __y = __z.imag(); > return complex<_Tp>(sin(__x) * cosh(__y), cos(__x) * sinh(__y)); > } > > > inline __complex__ float > __complex_sin(__complex__ float __z) { return __builtin_csinf(__z); } > > inline __complex__ double > __complex_sin(__complex__ double __z) { return __builtin_csin(__z); } > > inline __complex__ long double > __complex_sin(const __complex__ long double& __z) > { return __builtin_csinl(__z); } > > template<typename _Tp> > inline complex<_Tp> > sin(const complex<_Tp>& __z) { return __complex_sin(__z.__rep()); } > > > > > > > > template<typename _Tp> > inline complex<_Tp> > __complex_sinh(const complex<_Tp>& __z) > { > const _Tp __x = __z.real(); > const _Tp __y = __z.imag(); > return complex<_Tp>(sinh(__x) * cos(__y), cosh(__x) * sin(__y)); > } > > > inline __complex__ float > __complex_sinh(__complex__ float __z) { return __builtin_csinhf(__z); } > > inline __complex__ double > __complex_sinh(__complex__ double __z) { return __builtin_csinh(__z); } > > inline __complex__ long double > __complex_sinh(const __complex__ long double& __z) > { return __builtin_csinhl(__z); } > > template<typename _Tp> > inline complex<_Tp> > sinh(const complex<_Tp>& __z) { return __complex_sinh(__z.__rep()); } ># 854 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > complex<_Tp> > __complex_sqrt(const complex<_Tp>& __z) > { > _Tp __x = __z.real(); > _Tp __y = __z.imag(); > > if (__x == _Tp()) > { > _Tp __t = sqrt(abs(__y) / 2); > return complex<_Tp>(__t, __y < _Tp() ? -__t : __t); > } > else > { > _Tp __t = sqrt(2 * (std::abs(__z) + abs(__x))); > _Tp __u = __t / 2; > return __x > _Tp() > ? complex<_Tp>(__u, __y / __t) > : complex<_Tp>(abs(__y) / __t, __y < _Tp() ? -__u : __u); > } > } > > > inline __complex__ float > __complex_sqrt(__complex__ float __z) { return __builtin_csqrtf(__z); } > > inline __complex__ double > __complex_sqrt(__complex__ double __z) { return __builtin_csqrt(__z); } > > inline __complex__ long double > __complex_sqrt(const __complex__ long double& __z) > { return __builtin_csqrtl(__z); } > > template<typename _Tp> > inline complex<_Tp> > sqrt(const complex<_Tp>& __z) { return __complex_sqrt(__z.__rep()); } ># 898 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > inline complex<_Tp> > __complex_tan(const complex<_Tp>& __z) > { return std::sin(__z) / std::cos(__z); } > > > inline __complex__ float > __complex_tan(__complex__ float __z) { return __builtin_ctanf(__z); } > > inline __complex__ double > __complex_tan(__complex__ double __z) { return __builtin_ctan(__z); } > > inline __complex__ long double > __complex_tan(const __complex__ long double& __z) > { return __builtin_ctanl(__z); } > > template<typename _Tp> > inline complex<_Tp> > tan(const complex<_Tp>& __z) { return __complex_tan(__z.__rep()); } ># 926 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > inline complex<_Tp> > __complex_tanh(const complex<_Tp>& __z) > { return std::sinh(__z) / std::cosh(__z); } > > > inline __complex__ float > __complex_tanh(__complex__ float __z) { return __builtin_ctanhf(__z); } > > inline __complex__ double > __complex_tanh(__complex__ double __z) { return __builtin_ctanh(__z); } > > inline __complex__ long double > __complex_tanh(const __complex__ long double& __z) > { return __builtin_ctanhl(__z); } > > template<typename _Tp> > inline complex<_Tp> > tanh(const complex<_Tp>& __z) { return __complex_tanh(__z.__rep()); } ># 955 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > complex<_Tp> > __complex_pow_unsigned(complex<_Tp> __x, unsigned __n) > { > complex<_Tp> __y = __n % 2 ? __x : complex<_Tp>(1); > > while (__n >>= 1) > { > __x *= __x; > if (__n % 2) > __y *= __x; > } > > return __y; > } > > > > > > > > template<typename _Tp> > inline complex<_Tp> > pow(const complex<_Tp>& __z, int __n) > { > return __n < 0 > ? complex<_Tp>(1) / std::__complex_pow_unsigned(__z, -(unsigned)__n) > : std::__complex_pow_unsigned(__z, __n); > } > > template<typename _Tp> > complex<_Tp> > pow(const complex<_Tp>& __x, const _Tp& __y) > { > > > > > if (__x.imag() == _Tp() && __x.real() > _Tp()) > return pow(__x.real(), __y); > > complex<_Tp> __t = std::log(__x); > return std::polar(exp(__y * __t.real()), __y * __t.imag()); > } > > template<typename _Tp> > inline complex<_Tp> > __complex_pow(const complex<_Tp>& __x, const complex<_Tp>& __y) > { return __x == _Tp() ? _Tp() : std::exp(__y * std::log(__x)); } > > > inline __complex__ float > __complex_pow(__complex__ float __x, __complex__ float __y) > { return __builtin_cpowf(__x, __y); } > > inline __complex__ double > __complex_pow(__complex__ double __x, __complex__ double __y) > { return __builtin_cpow(__x, __y); } > > inline __complex__ long double > __complex_pow(const __complex__ long double& __x, > const __complex__ long double& __y) > { return __builtin_cpowl(__x, __y); } > > template<typename _Tp> > inline complex<_Tp> > pow(const complex<_Tp>& __x, const complex<_Tp>& __y) > { return __complex_pow(__x.__rep(), __y.__rep()); } > > > > > > > > template<typename _Tp> > inline complex<_Tp> > pow(const _Tp& __x, const complex<_Tp>& __y) > { > return __x > _Tp() ? std::polar(pow(__x, __y.real()), > __y.imag() * log(__x)) > : std::pow(complex<_Tp>(__x), __y); > } > > > > template<> > struct complex<float> > { > typedef float value_type; > typedef __complex__ float _ComplexT; > > constexpr complex(_ComplexT __z) : _M_value(__z) { } > > constexpr complex(float __r = 0.0f, float __i = 0.0f) > > : _M_value{ __r, __i } { } > > > > > > > > explicit constexpr complex(const complex<double>&); > explicit constexpr complex(const complex<long double>&); > > > > > __attribute ((__abi_tag__ ("cxx11"))) > constexpr float > real() const { return __real__ _M_value; } > > __attribute ((__abi_tag__ ("cxx11"))) > constexpr float > imag() const { return __imag__ _M_value; } ># 1089 "/usr/include/c++/4.9.0/complex" 3 > void > real(float __val) { __real__ _M_value = __val; } > > void > imag(float __val) { __imag__ _M_value = __val; } > > complex& > operator=(float __f) > { > _M_value = __f; > return *this; > } > > complex& > operator+=(float __f) > { > _M_value += __f; > return *this; > } > > complex& > operator-=(float __f) > { > _M_value -= __f; > return *this; > } > > complex& > operator*=(float __f) > { > _M_value *= __f; > return *this; > } > > complex& > operator/=(float __f) > { > _M_value /= __f; > return *this; > } > > > > > > template<typename _Tp> > complex& > operator=(const complex<_Tp>& __z) > { > __real__ _M_value = __z.real(); > __imag__ _M_value = __z.imag(); > return *this; > } > > template<typename _Tp> > complex& > operator+=(const complex<_Tp>& __z) > { > __real__ _M_value += __z.real(); > __imag__ _M_value += __z.imag(); > return *this; > } > > template<class _Tp> > complex& > operator-=(const complex<_Tp>& __z) > { > __real__ _M_value -= __z.real(); > __imag__ _M_value -= __z.imag(); > return *this; > } > > template<class _Tp> > complex& > operator*=(const complex<_Tp>& __z) > { > _ComplexT __t; > __real__ __t = __z.real(); > __imag__ __t = __z.imag(); > _M_value *= __t; > return *this; > } > > template<class _Tp> > complex& > operator/=(const complex<_Tp>& __z) > { > _ComplexT __t; > __real__ __t = __z.real(); > __imag__ __t = __z.imag(); > _M_value /= __t; > return *this; > } > > constexpr _ComplexT __rep() const { return _M_value; } > > private: > _ComplexT _M_value; > }; > > > > template<> > struct complex<double> > { > typedef double value_type; > typedef __complex__ double _ComplexT; > > constexpr complex(_ComplexT __z) : _M_value(__z) { } > > constexpr complex(double __r = 0.0, double __i = 0.0) > > : _M_value{ __r, __i } { } > > > > > > > > constexpr complex(const complex<float>& __z) > : _M_value(__z.__rep()) { } > > explicit constexpr complex(const complex<long double>&); > > > > > __attribute ((__abi_tag__ ("cxx11"))) > constexpr double > real() const { return __real__ _M_value; } > > __attribute ((__abi_tag__ ("cxx11"))) > constexpr double > imag() const { return __imag__ _M_value; } ># 1240 "/usr/include/c++/4.9.0/complex" 3 > void > real(double __val) { __real__ _M_value = __val; } > > void > imag(double __val) { __imag__ _M_value = __val; } > > complex& > operator=(double __d) > { > _M_value = __d; > return *this; > } > > complex& > operator+=(double __d) > { > _M_value += __d; > return *this; > } > > complex& > operator-=(double __d) > { > _M_value -= __d; > return *this; > } > > complex& > operator*=(double __d) > { > _M_value *= __d; > return *this; > } > > complex& > operator/=(double __d) > { > _M_value /= __d; > return *this; > } > > > > > template<typename _Tp> > complex& > operator=(const complex<_Tp>& __z) > { > __real__ _M_value = __z.real(); > __imag__ _M_value = __z.imag(); > return *this; > } > > template<typename _Tp> > complex& > operator+=(const complex<_Tp>& __z) > { > __real__ _M_value += __z.real(); > __imag__ _M_value += __z.imag(); > return *this; > } > > template<typename _Tp> > complex& > operator-=(const complex<_Tp>& __z) > { > __real__ _M_value -= __z.real(); > __imag__ _M_value -= __z.imag(); > return *this; > } > > template<typename _Tp> > complex& > operator*=(const complex<_Tp>& __z) > { > _ComplexT __t; > __real__ __t = __z.real(); > __imag__ __t = __z.imag(); > _M_value *= __t; > return *this; > } > > template<typename _Tp> > complex& > operator/=(const complex<_Tp>& __z) > { > _ComplexT __t; > __real__ __t = __z.real(); > __imag__ __t = __z.imag(); > _M_value /= __t; > return *this; > } > > constexpr _ComplexT __rep() const { return _M_value; } > > private: > _ComplexT _M_value; > }; > > > > template<> > struct complex<long double> > { > typedef long double value_type; > typedef __complex__ long double _ComplexT; > > constexpr complex(_ComplexT __z) : _M_value(__z) { } > > constexpr complex(long double __r = 0.0L, > long double __i = 0.0L) > > : _M_value{ __r, __i } { } > > > > > > > > constexpr complex(const complex<float>& __z) > : _M_value(__z.__rep()) { } > > constexpr complex(const complex<double>& __z) > : _M_value(__z.__rep()) { } > > > > > __attribute ((__abi_tag__ ("cxx11"))) > constexpr long double > real() const { return __real__ _M_value; } > > __attribute ((__abi_tag__ ("cxx11"))) > constexpr long double > imag() const { return __imag__ _M_value; } ># 1392 "/usr/include/c++/4.9.0/complex" 3 > void > real(long double __val) { __real__ _M_value = __val; } > > void > imag(long double __val) { __imag__ _M_value = __val; } > > complex& > operator=(long double __r) > { > _M_value = __r; > return *this; > } > > complex& > operator+=(long double __r) > { > _M_value += __r; > return *this; > } > > complex& > operator-=(long double __r) > { > _M_value -= __r; > return *this; > } > > complex& > operator*=(long double __r) > { > _M_value *= __r; > return *this; > } > > complex& > operator/=(long double __r) > { > _M_value /= __r; > return *this; > } > > > > > template<typename _Tp> > complex& > operator=(const complex<_Tp>& __z) > { > __real__ _M_value = __z.real(); > __imag__ _M_value = __z.imag(); > return *this; > } > > template<typename _Tp> > complex& > operator+=(const complex<_Tp>& __z) > { > __real__ _M_value += __z.real(); > __imag__ _M_value += __z.imag(); > return *this; > } > > template<typename _Tp> > complex& > operator-=(const complex<_Tp>& __z) > { > __real__ _M_value -= __z.real(); > __imag__ _M_value -= __z.imag(); > return *this; > } > > template<typename _Tp> > complex& > operator*=(const complex<_Tp>& __z) > { > _ComplexT __t; > __real__ __t = __z.real(); > __imag__ __t = __z.imag(); > _M_value *= __t; > return *this; > } > > template<typename _Tp> > complex& > operator/=(const complex<_Tp>& __z) > { > _ComplexT __t; > __real__ __t = __z.real(); > __imag__ __t = __z.imag(); > _M_value /= __t; > return *this; > } > > constexpr _ComplexT __rep() const { return _M_value; } > > private: > _ComplexT _M_value; > }; > > > > inline constexpr > complex<float>::complex(const complex<double>& __z) > : _M_value(__z.__rep()) { } > > inline constexpr > complex<float>::complex(const complex<long double>& __z) > : _M_value(__z.__rep()) { } > > inline constexpr > complex<double>::complex(const complex<long double>& __z) > : _M_value(__z.__rep()) { } > > > > > > extern template istream& operator>>(istream&, complex<float>&); > extern template ostream& operator<<(ostream&, const complex<float>&); > extern template istream& operator>>(istream&, complex<double>&); > extern template ostream& operator<<(ostream&, const complex<double>&); > extern template istream& operator>>(istream&, complex<long double>&); > extern template ostream& operator<<(ostream&, const complex<long double>&); > > > extern template wistream& operator>>(wistream&, complex<float>&); > extern template wostream& operator<<(wostream&, const complex<float>&); > extern template wistream& operator>>(wistream&, complex<double>&); > extern template wostream& operator<<(wostream&, const complex<double>&); > extern template wistream& operator>>(wistream&, complex<long double>&); > extern template wostream& operator<<(wostream&, const complex<long double>&); > > > > > > >} > >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > > template<typename _Tp, typename _Up> > struct __promote_2<std::complex<_Tp>, _Up> > { > public: > typedef std::complex<typename __promote_2<_Tp, _Up>::__type> __type; > }; > > template<typename _Tp, typename _Up> > struct __promote_2<_Tp, std::complex<_Up> > > { > public: > typedef std::complex<typename __promote_2<_Tp, _Up>::__type> __type; > }; > > template<typename _Tp, typename _Up> > struct __promote_2<std::complex<_Tp>, std::complex<_Up> > > { > public: > typedef std::complex<typename __promote_2<_Tp, _Up>::__type> __type; > }; > > >} > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template<typename _Tp> std::complex<_Tp> acos(const std::complex<_Tp>&); > template<typename _Tp> std::complex<_Tp> asin(const std::complex<_Tp>&); > template<typename _Tp> std::complex<_Tp> atan(const std::complex<_Tp>&); > > template<typename _Tp> std::complex<_Tp> acosh(const std::complex<_Tp>&); > template<typename _Tp> std::complex<_Tp> asinh(const std::complex<_Tp>&); > template<typename _Tp> std::complex<_Tp> atanh(const std::complex<_Tp>&); > > template<typename _Tp> _Tp fabs(const std::complex<_Tp>&); > > template<typename _Tp> > inline std::complex<_Tp> > __complex_acos(const std::complex<_Tp>& __z) > { > const std::complex<_Tp> __t = std::asin(__z); > const _Tp __pi_2 = 1.5707963267948966192313216916397514L; > return std::complex<_Tp>(__pi_2 - __t.real(), -__t.imag()); > } > > > inline __complex__ float > __complex_acos(__complex__ float __z) > { return __builtin_cacosf(__z); } > > inline __complex__ double > __complex_acos(__complex__ double __z) > { return __builtin_cacos(__z); } > > inline __complex__ long double > __complex_acos(const __complex__ long double& __z) > { return __builtin_cacosl(__z); } > > template<typename _Tp> > inline std::complex<_Tp> > acos(const std::complex<_Tp>& __z) > { return __complex_acos(__z.__rep()); } ># 1613 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > inline std::complex<_Tp> > __complex_asin(const std::complex<_Tp>& __z) > { > std::complex<_Tp> __t(-__z.imag(), __z.real()); > __t = std::asinh(__t); > return std::complex<_Tp>(__t.imag(), -__t.real()); > } > > > inline __complex__ float > __complex_asin(__complex__ float __z) > { return __builtin_casinf(__z); } > > inline __complex__ double > __complex_asin(__complex__ double __z) > { return __builtin_casin(__z); } > > inline __complex__ long double > __complex_asin(const __complex__ long double& __z) > { return __builtin_casinl(__z); } > > template<typename _Tp> > inline std::complex<_Tp> > asin(const std::complex<_Tp>& __z) > { return __complex_asin(__z.__rep()); } ># 1649 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > std::complex<_Tp> > __complex_atan(const std::complex<_Tp>& __z) > { > const _Tp __r2 = __z.real() * __z.real(); > const _Tp __x = _Tp(1.0) - __r2 - __z.imag() * __z.imag(); > > _Tp __num = __z.imag() + _Tp(1.0); > _Tp __den = __z.imag() - _Tp(1.0); > > __num = __r2 + __num * __num; > __den = __r2 + __den * __den; > > return std::complex<_Tp>(_Tp(0.5) * atan2(_Tp(2.0) * __z.real(), __x), > _Tp(0.25) * log(__num / __den)); > } > > > inline __complex__ float > __complex_atan(__complex__ float __z) > { return __builtin_catanf(__z); } > > inline __complex__ double > __complex_atan(__complex__ double __z) > { return __builtin_catan(__z); } > > inline __complex__ long double > __complex_atan(const __complex__ long double& __z) > { return __builtin_catanl(__z); } > > template<typename _Tp> > inline std::complex<_Tp> > atan(const std::complex<_Tp>& __z) > { return __complex_atan(__z.__rep()); } ># 1693 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > std::complex<_Tp> > __complex_acosh(const std::complex<_Tp>& __z) > { > > return _Tp(2.0) * std::log(std::sqrt(_Tp(0.5) * (__z + _Tp(1.0))) > + std::sqrt(_Tp(0.5) * (__z - _Tp(1.0)))); > } > > > inline __complex__ float > __complex_acosh(__complex__ float __z) > { return __builtin_cacoshf(__z); } > > inline __complex__ double > __complex_acosh(__complex__ double __z) > { return __builtin_cacosh(__z); } > > inline __complex__ long double > __complex_acosh(const __complex__ long double& __z) > { return __builtin_cacoshl(__z); } > > template<typename _Tp> > inline std::complex<_Tp> > acosh(const std::complex<_Tp>& __z) > { return __complex_acosh(__z.__rep()); } ># 1729 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > std::complex<_Tp> > __complex_asinh(const std::complex<_Tp>& __z) > { > std::complex<_Tp> __t((__z.real() - __z.imag()) > * (__z.real() + __z.imag()) + _Tp(1.0), > _Tp(2.0) * __z.real() * __z.imag()); > __t = std::sqrt(__t); > > return std::log(__t + __z); > } > > > inline __complex__ float > __complex_asinh(__complex__ float __z) > { return __builtin_casinhf(__z); } > > inline __complex__ double > __complex_asinh(__complex__ double __z) > { return __builtin_casinh(__z); } > > inline __complex__ long double > __complex_asinh(const __complex__ long double& __z) > { return __builtin_casinhl(__z); } > > template<typename _Tp> > inline std::complex<_Tp> > asinh(const std::complex<_Tp>& __z) > { return __complex_asinh(__z.__rep()); } ># 1768 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > std::complex<_Tp> > __complex_atanh(const std::complex<_Tp>& __z) > { > const _Tp __i2 = __z.imag() * __z.imag(); > const _Tp __x = _Tp(1.0) - __i2 - __z.real() * __z.real(); > > _Tp __num = _Tp(1.0) + __z.real(); > _Tp __den = _Tp(1.0) - __z.real(); > > __num = __i2 + __num * __num; > __den = __i2 + __den * __den; > > return std::complex<_Tp>(_Tp(0.25) * (log(__num) - log(__den)), > _Tp(0.5) * atan2(_Tp(2.0) * __z.imag(), __x)); > } > > > inline __complex__ float > __complex_atanh(__complex__ float __z) > { return __builtin_catanhf(__z); } > > inline __complex__ double > __complex_atanh(__complex__ double __z) > { return __builtin_catanh(__z); } > > inline __complex__ long double > __complex_atanh(const __complex__ long double& __z) > { return __builtin_catanhl(__z); } > > template<typename _Tp> > inline std::complex<_Tp> > atanh(const std::complex<_Tp>& __z) > { return __complex_atanh(__z.__rep()); } ># 1812 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > inline _Tp > > > > fabs(const std::complex<_Tp>& __z) > { return std::abs(__z); } > > > template<typename _Tp> > inline typename __gnu_cxx::__promote<_Tp>::__type > arg(_Tp __x) > { > typedef typename __gnu_cxx::__promote<_Tp>::__type __type; > > return std::signbit(__x) ? __type(3.1415926535897932384626433832795029L) > : __type(); > > > > } > > template<typename _Tp> > inline typename __gnu_cxx::__promote<_Tp>::__type > imag(_Tp) > { return _Tp(); } > > template<typename _Tp> > inline typename __gnu_cxx::__promote<_Tp>::__type > norm(_Tp __x) > { > typedef typename __gnu_cxx::__promote<_Tp>::__type __type; > return __type(__x) * __type(__x); > } > > template<typename _Tp> > inline typename __gnu_cxx::__promote<_Tp>::__type > real(_Tp __x) > { return __x; } > > template<typename _Tp, typename _Up> > inline std::complex<typename __gnu_cxx::__promote_2<_Tp, _Up>::__type> > pow(const std::complex<_Tp>& __x, const _Up& __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return std::pow(std::complex<__type>(__x), __type(__y)); > } > > template<typename _Tp, typename _Up> > inline std::complex<typename __gnu_cxx::__promote_2<_Tp, _Up>::__type> > pow(const _Tp& __x, const std::complex<_Up>& __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return std::pow(__type(__x), std::complex<__type>(__y)); > } > > template<typename _Tp, typename _Up> > inline std::complex<typename __gnu_cxx::__promote_2<_Tp, _Up>::__type> > pow(const std::complex<_Tp>& __x, const std::complex<_Up>& __y) > { > typedef typename __gnu_cxx::__promote_2<_Tp, _Up>::__type __type; > return std::pow(std::complex<__type>(__x), > std::complex<__type>(__y)); > } > > > > template<typename _Tp> std::complex<_Tp> proj(const std::complex<_Tp>&); > > template<typename _Tp> > std::complex<_Tp> > __complex_proj(const std::complex<_Tp>& __z) > { > const _Tp __den = (__z.real() * __z.real() > + __z.imag() * __z.imag() + _Tp(1.0)); > > return std::complex<_Tp>((_Tp(2.0) * __z.real()) / __den, > (_Tp(2.0) * __z.imag()) / __den); > } > > > inline __complex__ float > __complex_proj(__complex__ float __z) > { return __builtin_cprojf(__z); } > > inline __complex__ double > __complex_proj(__complex__ double __z) > { return __builtin_cproj(__z); } > > inline __complex__ long double > __complex_proj(const __complex__ long double& __z) > { return __builtin_cprojl(__z); } > > template<typename _Tp> > inline std::complex<_Tp> > proj(const std::complex<_Tp>& __z) > { return __complex_proj(__z.__rep()); } ># 1917 "/usr/include/c++/4.9.0/complex" 3 > template<typename _Tp> > inline typename __gnu_cxx::__promote<_Tp>::__type > proj(_Tp __x) > { return __x; } > > template<typename _Tp> > inline typename __gnu_cxx::__promote<_Tp>::__type > conj(_Tp __x) > { return __x; } ># 1961 "/usr/include/c++/4.9.0/complex" 3 > >} ># 99 "/usr/include/boost/detail/container_fwd.hpp" 2 3 4 ># 18 "/usr/include/boost/functional/hash/extensions.hpp" 2 3 4 > > ># 1 "/usr/include/boost/preprocessor/repetition/repeat_from_to.hpp" 1 3 4 ># 23 "/usr/include/boost/preprocessor/repetition/repeat_from_to.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/repetition/repeat_from_to.hpp" 2 3 4 ># 21 "/usr/include/boost/functional/hash/extensions.hpp" 2 3 4 ># 47 "/usr/include/boost/functional/hash/extensions.hpp" 3 4 >namespace boost >{ > template <class A, class B> > std::size_t hash_value(std::pair<A, B> const&); > template <class T, class A> > std::size_t hash_value(std::vector<T, A> const&); > template <class T, class A> > std::size_t hash_value(std::list<T, A> const& v); > template <class T, class A> > std::size_t hash_value(std::deque<T, A> const& v); > template <class K, class C, class A> > std::size_t hash_value(std::set<K, C, A> const& v); > template <class K, class C, class A> > std::size_t hash_value(std::multiset<K, C, A> const& v); > template <class K, class T, class C, class A> > std::size_t hash_value(std::map<K, T, C, A> const& v); > template <class K, class T, class C, class A> > std::size_t hash_value(std::multimap<K, T, C, A> const& v); > > template <class T> > std::size_t hash_value(std::complex<T> const&); > > template <class A, class B> > std::size_t hash_value(std::pair<A, B> const& v) > { > std::size_t seed = 0; > boost::hash_combine(seed, v.first); > boost::hash_combine(seed, v.second); > return seed; > } > > template <class T, class A> > std::size_t hash_value(std::vector<T, A> const& v) > { > return boost::hash_range(v.begin(), v.end()); > } > > template <class T, class A> > std::size_t hash_value(std::list<T, A> const& v) > { > return boost::hash_range(v.begin(), v.end()); > } > > template <class T, class A> > std::size_t hash_value(std::deque<T, A> const& v) > { > return boost::hash_range(v.begin(), v.end()); > } > > template <class K, class C, class A> > std::size_t hash_value(std::set<K, C, A> const& v) > { > return boost::hash_range(v.begin(), v.end()); > } > > template <class K, class C, class A> > std::size_t hash_value(std::multiset<K, C, A> const& v) > { > return boost::hash_range(v.begin(), v.end()); > } > > template <class K, class T, class C, class A> > std::size_t hash_value(std::map<K, T, C, A> const& v) > { > return boost::hash_range(v.begin(), v.end()); > } > > template <class K, class T, class C, class A> > std::size_t hash_value(std::multimap<K, T, C, A> const& v) > { > return boost::hash_range(v.begin(), v.end()); > } > > template <class T> > std::size_t hash_value(std::complex<T> const& v) > { > boost::hash<T> hasher; > std::size_t seed = hasher(v.imag()); > seed ^= hasher(v.real()) + (seed<<6) + (seed>>2); > return seed; > } > > > template <class T, std::size_t N> > std::size_t hash_value(std::array<T, N> const& v) > { > return boost::hash_range(v.begin(), v.end()); > } > > > > namespace hash_detail { > template <std::size_t I, typename T> > inline typename boost::enable_if_c<(I == std::tuple_size<T>::value), > void>::type > hash_combine_tuple(std::size_t&, T const&) > { > } > > template <std::size_t I, typename T> > inline typename boost::enable_if_c<(I < std::tuple_size<T>::value), > void>::type > hash_combine_tuple(std::size_t& seed, T const& v) > { > boost::hash_combine(seed, std::get<I>(v)); > boost::hash_detail::hash_combine_tuple<I + 1>(seed, v); > } > > template <typename T> > 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; > } > } > > > template <typename... T> > inline std::size_t hash_value(std::tuple<T...> const& v) > { > return boost::hash_detail::hash_tuple(v); > } ># 195 "/usr/include/boost/functional/hash/extensions.hpp" 3 4 > template <typename T> > inline std::size_t hash_value(std::shared_ptr<T> const& x) { > return boost::hash_value(x.get()); > } > > template <typename T, typename Deleter> > inline std::size_t hash_value(std::unique_ptr<T, Deleter> const& x) { > return boost::hash_value(x.get()); > } ># 263 "/usr/include/boost/functional/hash/extensions.hpp" 3 4 > template <class T> struct hash > : std::unary_function<T, std::size_t> > { > > std::size_t operator()(T const& val) const > { > return hash_value(val); > } > > > > > > > }; ># 377 "/usr/include/boost/functional/hash/extensions.hpp" 3 4 >} ># 541 "/usr/include/boost/functional/hash/hash.hpp" 2 3 4 ># 7 "/usr/include/boost/functional/hash.hpp" 2 3 4 ># 38 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 ># 46 "/usr/include/boost/thread/detail/thread.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 47 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 > > > > > > >namespace boost >{ > > namespace detail > { ># 90 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > template<typename F> > class thread_data: > public detail::thread_data_base > { > public: > thread_data(thread_data const&) = delete; thread_data& operator=(thread_data const&) = delete; > > thread_data(F && f_): > f(boost::forward<F>(f_)) > {} ># 115 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > void run() > { > f(); > } > > private: > F f; > }; > > template<typename F> > class thread_data<boost::reference_wrapper<F> >: > public detail::thread_data_base > { > private: > F& f; > public: > thread_data(thread_data const&) = delete; thread_data& operator=(thread_data const&) = delete; > thread_data(boost::reference_wrapper<F> f_): > f(f_) > {} > void run() > { > f(); > } > }; > > template<typename F> > class thread_data<const boost::reference_wrapper<F> >: > public detail::thread_data_base > { > private: > F& f; > public: > thread_data(thread_data const&) = delete; thread_data& operator=(thread_data const&) = delete; > thread_data(const boost::reference_wrapper<F> f_): > f(f_) > {} > void run() > { > f(); > } > }; > > } > > class __attribute__((__visibility__("default"))) thread > { > public: > typedef thread_attributes attributes; > > thread(thread const&) = delete; thread& operator=(thread const&) = delete; > private: > > struct dummy; > > void release_handle(); > > detail::thread_data_ptr thread_info; > > private: > bool start_thread_noexcept(); > bool start_thread_noexcept(const attributes& attr); > public: > void start_thread() > { > if (!start_thread_noexcept()) > { > boost::throw_exception(thread_resource_error()); > } > } > void start_thread(const attributes& attr) > { > if (!start_thread_noexcept(attr)) > { > boost::throw_exception(thread_resource_error()); > } > } > > explicit thread(detail::thread_data_ptr data); > > detail::thread_data_ptr get_thread_info () const; ># 210 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > template<typename F> > static inline detail::thread_data_ptr make_thread_info(F && f) > { > return detail::thread_data_ptr(detail::heap_new<detail::thread_data<typename boost::remove_reference<F>::type> >( > boost::forward<F>(f))); > } > > static inline detail::thread_data_ptr make_thread_info(void (*f)()) > { > return detail::thread_data_ptr(detail::heap_new<detail::thread_data<void(*)()> >( > boost::forward<void(*)()>(f))); > } ># 240 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > public: > > > > > > thread() noexcept; > ~thread() > { > > > > > > > detach(); > > } > > template < > class F > > > explicit thread(F && f > > ): > thread_info(make_thread_info(thread_detail::decay_copy(boost::forward<F>(f)))) > { > start_thread(); > } > template < > class F > > > thread(attributes const& attrs, F && f): > thread_info(make_thread_info(thread_detail::decay_copy(boost::forward<F>(f)))) > { > start_thread(attrs); > } ># 337 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > thread(thread && x) > { > thread_info=x.thread_info; > x.thread_info.reset(); > } ># 352 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > thread& operator=(thread && other) noexcept > { > > > > > thread_info=other.thread_info; > other.thread_info.reset(); > return *this; > } ># 387 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > template <class F,class A1> > thread(F f,A1 a1,typename disable_if<boost::thread_detail::is_convertible<F&,thread_attributes >, dummy* >::type=0): > thread_info(make_thread_info(boost::bind(boost::type<void>(),f,a1))) > { > start_thread(); > } > template <class F,class A1,class A2> > thread(F f,A1 a1,A2 a2): > thread_info(make_thread_info(boost::bind(boost::type<void>(),f,a1,a2))) > { > start_thread(); > } > > template <class F,class A1,class A2,class A3> > thread(F f,A1 a1,A2 a2,A3 a3): > thread_info(make_thread_info(boost::bind(boost::type<void>(),f,a1,a2,a3))) > { > start_thread(); > } > > template <class F,class A1,class A2,class A3,class A4> > thread(F f,A1 a1,A2 a2,A3 a3,A4 a4): > thread_info(make_thread_info(boost::bind(boost::type<void>(),f,a1,a2,a3,a4))) > { > start_thread(); > } > > template <class F,class A1,class A2,class A3,class A4,class A5> > thread(F f,A1 a1,A2 a2,A3 a3,A4 a4,A5 a5): > thread_info(make_thread_info(boost::bind(boost::type<void>(),f,a1,a2,a3,a4,a5))) > { > start_thread(); > } > > template <class F,class A1,class A2,class A3,class A4,class A5,class A6> > thread(F f,A1 a1,A2 a2,A3 a3,A4 a4,A5 a5,A6 a6): > thread_info(make_thread_info(boost::bind(boost::type<void>(),f,a1,a2,a3,a4,a5,a6))) > { > start_thread(); > } > > template <class F,class A1,class A2,class A3,class A4,class A5,class A6,class A7> > thread(F f,A1 a1,A2 a2,A3 a3,A4 a4,A5 a5,A6 a6,A7 a7): > thread_info(make_thread_info(boost::bind(boost::type<void>(),f,a1,a2,a3,a4,a5,a6,a7))) > { > start_thread(); > } > > template <class F,class A1,class A2,class A3,class A4,class A5,class A6,class A7,class A8> > thread(F f,A1 a1,A2 a2,A3 a3,A4 a4,A5 a5,A6 a6,A7 a7,A8 a8): > thread_info(make_thread_info(boost::bind(boost::type<void>(),f,a1,a2,a3,a4,a5,a6,a7,a8))) > { > start_thread(); > } > > template <class F,class A1,class A2,class A3,class A4,class A5,class A6,class A7,class A8,class A9> > thread(F f,A1 a1,A2 a2,A3 a3,A4 a4,A5 a5,A6 a6,A7 a7,A8 a8,A9 a9): > thread_info(make_thread_info(boost::bind(boost::type<void>(),f,a1,a2,a3,a4,a5,a6,a7,a8,a9))) > { > start_thread(); > } > > void swap(thread& x) noexcept > { > thread_info.swap(x.thread_info); > } > > class id; > > inline id get_id() const noexcept; > > > > > > bool joinable() const noexcept; > private: > bool join_noexcept(); > public: > inline void join(); > > > template <class Rep, class Period> > bool try_join_for(const chrono::duration<Rep, Period>& rel_time) > { > return try_join_until(chrono::steady_clock::now() + rel_time); > } > template <class Clock, class Duration> > bool try_join_until(const chrono::time_point<Clock, Duration>& t) > { > using namespace chrono; > system_clock::time_point s_now = system_clock::now(); > bool joined= false; > do { > typename Clock::duration d = ceil<nanoseconds>(t-Clock::now()); > if (d <= Clock::duration::zero()) return false; > joined = try_join_until(s_now + d); > } while (! joined); > return true; > } > template <class Duration> > bool try_join_until(const chrono::time_point<chrono::system_clock, Duration>& t) > { > using namespace chrono; > typedef time_point<system_clock, nanoseconds> nano_sys_tmpt; > return try_join_until(nano_sys_tmpt(ceil<nanoseconds>(t.time_since_epoch()))); > } ># 515 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > private: > bool do_try_join_until_noexcept(struct timespec const &timeout, bool& res); > inline bool do_try_join_until(struct timespec const &timeout); > public: > > bool timed_join(const system_time& abs_time) > { > struct timespec const ts=detail::to_timespec(abs_time); > return do_try_join_until(ts); > } > > > bool try_join_until(const chrono::time_point<chrono::system_clock, chrono::nanoseconds>& tp) > { > using namespace chrono; > nanoseconds d = tp.time_since_epoch(); > timespec ts = boost::detail::to_timespec(d); > return do_try_join_until(ts); > } > > > > public: > > > template<typename TimeDuration> > inline bool timed_join(TimeDuration const& rel_time) > { > return timed_join(get_system_time()+rel_time); > } > > void detach(); > > static unsigned hardware_concurrency() noexcept; > > > typedef detail::thread_data_base::native_handle_type native_handle_type; > native_handle_type native_handle(); > > > > > bool operator==(const thread& other) const; > bool operator!=(const thread& other) const; > > > static inline void yield() noexcept > { > this_thread::yield(); > } > > static inline void sleep(const system_time& xt) > { > this_thread::sleep(xt); > } > > > > > void interrupt(); > bool interruption_requested() const noexcept; > > }; > > inline void swap(thread& lhs,thread& rhs) noexcept > { > return lhs.swap(rhs); > } > > > inline thread&& move(thread& t) noexcept > { > return static_cast<thread&&>(t); > } > > > > > namespace this_thread > { > > inline thread::id get_id() noexcept; > > > > > > void __attribute__((__visibility__("default"))) interruption_point(); > bool __attribute__((__visibility__("default"))) interruption_enabled() noexcept; > bool __attribute__((__visibility__("default"))) interruption_requested() noexcept; > > > > inline __attribute__((__visibility__("default"))) void sleep(xtime const& abs_time) > { > sleep(system_time(abs_time)); > } > > } > > class __attribute__((__visibility__("default"))) thread::id > { > private: > friend inline > std::size_t > hash_value(const thread::id &v) > { > > return hash_value(v.thread_data); > > > > } > > > > > > typedef thread::native_handle_type data; > > > > > data thread_data; > > id(data thread_data_): > thread_data(thread_data_) > {} > friend class thread; > friend id __attribute__((__visibility__("default"))) this_thread::get_id() noexcept; > public: > id() noexcept: > > thread_data(0) > > > > {} > > id(const id& other) noexcept : > thread_data(other.thread_data) > {} > > bool operator==(const id& y) const noexcept > { > return thread_data==y.thread_data; > } > > bool operator!=(const id& y) const noexcept > { > return thread_data!=y.thread_data; > } > > bool operator<(const id& y) const noexcept > { > return thread_data<y.thread_data; > } > > bool operator>(const id& y) const noexcept > { > return y.thread_data<thread_data; > } > > bool operator<=(const id& y) const noexcept > { > return !(y.thread_data<thread_data); > } > > bool operator>=(const id& y) const noexcept > { > return !(thread_data<y.thread_data); > } > > > > template<class charT, class traits> > friend __attribute__((__visibility__("default"))) > std::basic_ostream<charT, traits>& > operator<<(std::basic_ostream<charT, traits>& os, const id& x) > { > if(x.thread_data) > { > io::ios_flags_saver ifs( os ); > return os<< std::hex << x.thread_data; > } > else > { > return os<<"{Not-any-thread}"; > } > } ># 724 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > }; > > > thread::id thread::get_id() const noexcept > { > > return const_cast<thread*>(this)->native_handle(); > > > > > } > > namespace this_thread > { > inline thread::id get_id() noexcept > { > > return pthread_self(); > > > > > } > } > > void thread::join() { > if (this_thread::get_id() == get_id()) > boost::throw_exception(thread_resource_error(system::errc::resource_deadlock_would_occur, "boost thread: trying joining itself")); > > (void)(join_noexcept()) > > ; > } > > > bool thread::do_try_join_until(struct timespec const &timeout) > > > > { > if (this_thread::get_id() == get_id()) > boost::throw_exception(thread_resource_error(system::errc::resource_deadlock_would_occur, "boost thread: trying joining itself")); > bool res; > if (do_try_join_until_noexcept(timeout, res)) > { > return res; > } > else > { > return (false) > > > ; > } > } ># 792 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > inline bool thread::operator==(const thread& other) const > { > return get_id()==other.get_id(); > } > > inline bool thread::operator!=(const thread& other) const > { > return get_id()!=other.get_id(); > } > > > namespace detail > { > struct thread_exit_function_base > { > virtual ~thread_exit_function_base() > {} > virtual void operator()()=0; > }; > > template<typename F> > struct thread_exit_function: > thread_exit_function_base > { > F f; > > thread_exit_function(F f_): > f(f_) > {} > > void operator()() > { > f(); > } > }; > > void __attribute__((__visibility__("default"))) add_thread_exit_function(thread_exit_function_base*); > struct shared_state_base; ># 840 "/usr/include/boost/thread/detail/thread.hpp" 3 4 > void __attribute__((__visibility__("default"))) make_ready_at_thread_exit(shared_ptr<shared_state_base> as); > > } > > namespace this_thread > { > template<typename F> > void at_thread_exit(F f) > { > detail::thread_exit_function_base* const thread_exit_func=detail::heap_new<detail::thread_exit_function<F> >(f); > detail::add_thread_exit_function(thread_exit_func); > } > } >} > > > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 860 "/usr/include/boost/thread/detail/thread.hpp" 2 3 4 ># 23 "/usr/include/boost/thread/thread_only.hpp" 2 3 4 > ># 1 "/usr/include/boost/thread/detail/thread_interruption.hpp" 1 3 4 ># 14 "/usr/include/boost/thread/detail/thread_interruption.hpp" 3 4 >namespace boost >{ > namespace this_thread > { > class __attribute__((__visibility__("default"))) disable_interruption > { > bool interruption_was_enabled; > friend class restore_interruption; > public: > disable_interruption(disable_interruption const&) = delete; disable_interruption& operator=(disable_interruption const&) = delete; > disable_interruption() noexcept; > ~disable_interruption() noexcept; > }; > > class __attribute__((__visibility__("default"))) restore_interruption > { > public: > restore_interruption(restore_interruption const&) = delete; restore_interruption& operator=(restore_interruption const&) = delete; > explicit restore_interruption(disable_interruption& d) noexcept; > ~restore_interruption() noexcept; > }; > } >} ># 25 "/usr/include/boost/thread/thread_only.hpp" 2 3 4 > ># 1 "/usr/include/boost/thread/v2/thread.hpp" 1 3 4 ># 14 "/usr/include/boost/thread/v2/thread.hpp" 3 4 ># 1 "/usr/include/boost/thread/condition_variable.hpp" 1 3 4 ># 16 "/usr/include/boost/thread/condition_variable.hpp" 3 4 ># 1 "/usr/include/boost/thread/pthread/condition_variable.hpp" 1 3 4 ># 21 "/usr/include/boost/thread/pthread/condition_variable.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 22 "/usr/include/boost/thread/pthread/condition_variable.hpp" 2 3 4 > >namespace boost >{ > > namespace this_thread > { > void __attribute__((__visibility__("default"))) interruption_point(); > } > > > namespace thread_cv_detail > { > template<typename MutexType> > struct lock_on_exit > { > MutexType* m; > > lock_on_exit(): > m(0) > {} > > void activate(MutexType& m_) > { > m_.unlock(); > m=&m_; > } > ~lock_on_exit() > { > if(m) > { > m->lock(); > } > } > }; > } > > inline void condition_variable::wait(unique_lock<mutex>& m) > { > > > > > > > int res=0; > { > > thread_cv_detail::lock_on_exit<unique_lock<mutex> > guard; > detail::interruption_checker check_for_interruption(&internal_mutex,&cond); > guard.activate(m); > do { > res = pthread_cond_wait(&cond,&internal_mutex); > } while (res == 4); > > > > > > > > } > > this_thread::interruption_point(); > > if(res) > { > boost::throw_exception(condition_error(res, "boost::condition_variable::wait failed in pthread_cond_wait")); > } > } > > inline bool condition_variable::do_wait_until( > unique_lock<mutex>& m, > struct timespec const &timeout) > { > > > > > > > thread_cv_detail::lock_on_exit<unique_lock<mutex> > guard; > int cond_res; > { > > detail::interruption_checker check_for_interruption(&internal_mutex,&cond); > guard.activate(m); > cond_res=pthread_cond_timedwait(&cond,&internal_mutex,&timeout); > > > > > > } > > this_thread::interruption_point(); > > if(cond_res==110) > { > return false; > } > if(cond_res) > { > boost::throw_exception(condition_error(cond_res, "boost::condition_variable::do_wait_until failed in pthread_cond_timedwait")); > } > return true; > } > > inline void condition_variable::notify_one() noexcept > { > > boost::pthread::pthread_mutex_scoped_lock internal_lock(&internal_mutex); > > ((void)(!pthread_cond_signal(&cond))); > } > > inline void condition_variable::notify_all() noexcept > { > > boost::pthread::pthread_mutex_scoped_lock internal_lock(&internal_mutex); > > ((void)(!pthread_cond_broadcast(&cond))); > } > > class condition_variable_any > { > pthread_mutex_t internal_mutex; > pthread_cond_t cond; > > public: > condition_variable_any(condition_variable_any const&) = delete; condition_variable_any& operator=(condition_variable_any const&) = delete; > condition_variable_any() > { > int const res=pthread_mutex_init(&internal_mutex,__null); > if(res) > { > boost::throw_exception(thread_resource_error(res, "boost::condition_variable_any::condition_variable_any() failed in pthread_mutex_init")); > } > int const res2=pthread_cond_init(&cond,__null); > if(res2) > { > ((void)(!pthread_mutex_destroy(&internal_mutex))); > boost::throw_exception(thread_resource_error(res, "boost::condition_variable_any::condition_variable_any() failed in pthread_cond_init")); > } > } > ~condition_variable_any() > { > ((void)(!pthread_mutex_destroy(&internal_mutex))); > ((void)(!pthread_cond_destroy(&cond))); > } > > template<typename lock_type> > void wait(lock_type& m) > { > int res=0; > { > thread_cv_detail::lock_on_exit<lock_type> guard; > > detail::interruption_checker check_for_interruption(&internal_mutex,&cond); > > > > guard.activate(m); > res=pthread_cond_wait(&cond,&internal_mutex); > } > > this_thread::interruption_point(); > > if(res) > { > boost::throw_exception(condition_error(res, "boost::condition_variable_any::wait() failed in pthread_cond_wait")); > } > } > > template<typename lock_type,typename predicate_type> > void wait(lock_type& m,predicate_type pred) > { > while(!pred()) wait(m); > } > > > template<typename lock_type> > bool timed_wait(lock_type& m,boost::system_time const& abs_time) > { > struct timespec const timeout=detail::to_timespec(abs_time); > return do_wait_until(m, timeout); > } > template<typename lock_type> > bool timed_wait(lock_type& m,xtime const& abs_time) > { > return timed_wait(m,system_time(abs_time)); > } > > template<typename lock_type,typename duration_type> > bool timed_wait(lock_type& m,duration_type const& wait_duration) > { > return timed_wait(m,get_system_time()+wait_duration); > } > > template<typename lock_type,typename predicate_type> > bool timed_wait(lock_type& m,boost::system_time const& abs_time, predicate_type pred) > { > while (!pred()) > { > if(!timed_wait(m, abs_time)) > return pred(); > } > return true; > } > > template<typename lock_type,typename predicate_type> > bool timed_wait(lock_type& m,xtime const& abs_time, predicate_type pred) > { > return timed_wait(m,system_time(abs_time),pred); > } > > template<typename lock_type,typename duration_type,typename predicate_type> > bool timed_wait(lock_type& m,duration_type const& wait_duration,predicate_type pred) > { > return timed_wait(m,get_system_time()+wait_duration,pred); > } > > > template <class lock_type,class Duration> > cv_status > wait_until( > lock_type& lock, > const chrono::time_point<chrono::system_clock, Duration>& t) > { > using namespace chrono; > typedef time_point<system_clock, nanoseconds> nano_sys_tmpt; > wait_until(lock, > nano_sys_tmpt(ceil<nanoseconds>(t.time_since_epoch()))); > return system_clock::now() < t ? cv_status::no_timeout : > cv_status::timeout; > } > > template <class lock_type, class Clock, class Duration> > cv_status > wait_until( > lock_type& lock, > const chrono::time_point<Clock, Duration>& t) > { > using namespace chrono; > system_clock::time_point s_now = system_clock::now(); > typename Clock::time_point c_now = Clock::now(); > wait_until(lock, s_now + ceil<nanoseconds>(t - c_now)); > return Clock::now() < t ? cv_status::no_timeout : cv_status::timeout; > } > > template <class lock_type, class Clock, class Duration, class Predicate> > bool > wait_until( > lock_type& lock, > const chrono::time_point<Clock, Duration>& t, > Predicate pred) > { > while (!pred()) > { > if (wait_until(lock, t) == cv_status::timeout) > return pred(); > } > return true; > } > > > template <class lock_type, class Rep, class Period> > cv_status > wait_for( > lock_type& lock, > const chrono::duration<Rep, Period>& d) > { > using namespace chrono; > system_clock::time_point s_now = system_clock::now(); > steady_clock::time_point c_now = steady_clock::now(); > wait_until(lock, s_now + ceil<nanoseconds>(d)); > return steady_clock::now() - c_now < d ? cv_status::no_timeout : > cv_status::timeout; > > } > > > template <class lock_type, class Rep, class Period, class Predicate> > bool > wait_for( > lock_type& lock, > const chrono::duration<Rep, Period>& d, > Predicate pred) > { > return wait_until(lock, chrono::steady_clock::now() + d, boost::move(pred)); > > > > > > > > } > > template <class lock_type> > cv_status wait_until( > lock_type& lk, > chrono::time_point<chrono::system_clock, chrono::nanoseconds> tp) > { > using namespace chrono; > nanoseconds d = tp.time_since_epoch(); > timespec ts = boost::detail::to_timespec(d); > if (do_wait_until(lk, ts)) return cv_status::no_timeout; > else return cv_status::timeout; > } > > > void notify_one() noexcept > { > boost::pthread::pthread_mutex_scoped_lock internal_lock(&internal_mutex); > ((void)(!pthread_cond_signal(&cond))); > } > > void notify_all() noexcept > { > boost::pthread::pthread_mutex_scoped_lock internal_lock(&internal_mutex); > ((void)(!pthread_cond_broadcast(&cond))); > } > private: > > template <class lock_type> > inline bool do_wait_until( > lock_type& m, > struct timespec const &timeout) > { > int res=0; > { > thread_cv_detail::lock_on_exit<lock_type> guard; > > detail::interruption_checker check_for_interruption(&internal_mutex,&cond); > > > > guard.activate(m); > res=pthread_cond_timedwait(&cond,&internal_mutex,&timeout); > } > > this_thread::interruption_point(); > > if(res==110) > { > return false; > } > if(res) > { > boost::throw_exception(condition_error(res, "boost::condition_variable_any::do_wait_until() failed in pthread_cond_timedwait")); > } > return true; > } > > > }; > >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 382 "/usr/include/boost/thread/pthread/condition_variable.hpp" 2 3 4 ># 17 "/usr/include/boost/thread/condition_variable.hpp" 2 3 4 ># 15 "/usr/include/boost/thread/v2/thread.hpp" 2 3 4 > > >namespace boost >{ > namespace this_thread > { > > > > template <class Clock, class Duration> > void sleep_until(const chrono::time_point<Clock, Duration>& t) > { > using namespace chrono; > mutex mut; > condition_variable cv; > unique_lock<mutex> lk(mut); > while (Clock::now() < t) > cv.wait_until(lk, t); > } > > > > template <class Rep, class Period> > void sleep_for(const chrono::duration<Rep, Period>& d) > { > using namespace chrono; > if (d > duration<Rep, Period>::zero()) > { > duration<long double> Max = nanoseconds::max (); > nanoseconds ns; > if (d < Max) > { > ns = duration_cast<nanoseconds>(d); > if (ns < d) > ++ns; > } > else > ns = nanoseconds:: max (); > sleep_for(ns); > } > } > > template <class Duration> > inline __attribute__((__visibility__("default"))) > void sleep_until(const chrono::time_point<chrono::steady_clock, Duration>& t) > { > using namespace chrono; > sleep_for(t - steady_clock::now()); > } ># 79 "/usr/include/boost/thread/v2/thread.hpp" 3 4 > } >} ># 27 "/usr/include/boost/thread/thread_only.hpp" 2 3 4 ># 13 "/usr/include/boost/thread/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/detail/thread_group.hpp" 1 3 4 ># 9 "/usr/include/boost/thread/detail/thread_group.hpp" 3 4 ># 1 "/usr/include/boost/thread/shared_mutex.hpp" 1 3 4 ># 22 "/usr/include/boost/thread/shared_mutex.hpp" 3 4 ># 1 "/usr/include/boost/thread/pthread/shared_mutex.hpp" 1 3 4 ># 11 "/usr/include/boost/thread/pthread/shared_mutex.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 12 "/usr/include/boost/thread/pthread/shared_mutex.hpp" 2 3 4 ># 23 "/usr/include/boost/thread/pthread/shared_mutex.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 24 "/usr/include/boost/thread/pthread/shared_mutex.hpp" 2 3 4 > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 26 "/usr/include/boost/thread/pthread/shared_mutex.hpp" 2 3 4 > >namespace boost >{ > class shared_mutex > { > private: > class state_data > { > public: > state_data () : > shared_count(0), > exclusive(false), > upgrade(false), > exclusive_waiting_blocked(false) > {} > > void assert_free() const > { > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > } > > void assert_locked() const > { > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > } > > void assert_lock_shared () const > { > (static_cast<void> (0)); > (static_cast<void> (0)); > > > > } > > void assert_lock_upgraded () const > { > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > } > > void assert_lock_not_upgraded () const > { > (static_cast<void> (0)); > } > > bool can_lock () const > { > return ! (shared_count || exclusive); > } > > void exclusive_blocked (bool blocked) > { > exclusive_waiting_blocked = blocked; > } > > void lock () > { > exclusive = true; > } > > void unlock () > { > exclusive = false; > exclusive_waiting_blocked = false; > } > > bool can_lock_shared () const > { > return ! (exclusive || exclusive_waiting_blocked); > } > > bool more_shared () const > { > return shared_count > 0 ; > } > unsigned get_shared_count () const > { > return shared_count ; > } > unsigned lock_shared () > { > return ++shared_count; > } > > > void unlock_shared () > { > --shared_count; > } > > bool unlock_shared_downgrades() > { > if (upgrade) { > upgrade=false; > exclusive=true; > return true; > } else { > exclusive_waiting_blocked=false; > return false; > } > } > > void lock_upgrade () > { > ++shared_count; > upgrade=true; > } > bool can_lock_upgrade () const > { > return ! (exclusive || exclusive_waiting_blocked || upgrade); > } > > void unlock_upgrade () > { > upgrade=false; > --shared_count; > } > > > unsigned shared_count; > bool exclusive; > bool upgrade; > bool exclusive_waiting_blocked; > }; > > > > state_data state; > boost::mutex state_change; > boost::condition_variable shared_cond; > boost::condition_variable exclusive_cond; > boost::condition_variable upgrade_cond; > > void release_waiters() > { > exclusive_cond.notify_one(); > shared_cond.notify_all(); > } > > public: > > shared_mutex(shared_mutex const&) = delete; shared_mutex& operator=(shared_mutex const&) = delete; > > shared_mutex() > { > } > > ~shared_mutex() > { > } > > void lock_shared() > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > while(!state.can_lock_shared()) > { > shared_cond.wait(lk); > } > state.lock_shared(); > } > > bool try_lock_shared() > { > boost::unique_lock<boost::mutex> lk(state_change); > > if(!state.can_lock_shared()) > { > return false; > } > state.lock_shared(); > return true; > } > > > bool timed_lock_shared(system_time const& timeout) > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > > while(!state.can_lock_shared()) > { > if(!shared_cond.timed_wait(lk,timeout)) > { > return false; > } > } > state.lock_shared(); > return true; > } > > template<typename TimeDuration> > bool timed_lock_shared(TimeDuration const & relative_time) > { > return timed_lock_shared(get_system_time()+relative_time); > } > > > template <class Rep, class Period> > bool try_lock_shared_for(const chrono::duration<Rep, Period>& rel_time) > { > return try_lock_shared_until(chrono::steady_clock::now() + rel_time); > } > template <class Clock, class Duration> > bool try_lock_shared_until(const chrono::time_point<Clock, Duration>& abs_time) > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > > while(!state.can_lock_shared()) > > { > if(cv_status::timeout==shared_cond.wait_until(lk,abs_time)) > { > return false; > } > } > state.lock_shared(); > return true; > } > > void unlock_shared() > { > boost::unique_lock<boost::mutex> lk(state_change); > state.assert_lock_shared(); > state.unlock_shared(); > if (! state.more_shared()) > { > if (state.upgrade) > { > > > state.upgrade=false; > state.exclusive=true; > lk.unlock(); > upgrade_cond.notify_one(); > } > else > { > state.exclusive_waiting_blocked=false; > lk.unlock(); > } > release_waiters(); > } > } > > void lock() > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > > while (state.shared_count || state.exclusive) > { > state.exclusive_waiting_blocked=true; > exclusive_cond.wait(lk); > } > state.exclusive=true; > } > > > bool timed_lock(system_time const& timeout) > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > > while(state.shared_count || state.exclusive) > { > state.exclusive_waiting_blocked=true; > if(!exclusive_cond.timed_wait(lk,timeout)) > { > if(state.shared_count || state.exclusive) > { > state.exclusive_waiting_blocked=false; > release_waiters(); > return false; > } > break; > } > } > state.exclusive=true; > return true; > } > > template<typename TimeDuration> > bool timed_lock(TimeDuration const & relative_time) > { > return timed_lock(get_system_time()+relative_time); > } > > > template <class Rep, class Period> > bool try_lock_for(const chrono::duration<Rep, Period>& rel_time) > { > return try_lock_until(chrono::steady_clock::now() + rel_time); > } > template <class Clock, class Duration> > bool try_lock_until(const chrono::time_point<Clock, Duration>& abs_time) > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > > while(state.shared_count || state.exclusive) > { > state.exclusive_waiting_blocked=true; > if(cv_status::timeout == exclusive_cond.wait_until(lk,abs_time)) > { > if(state.shared_count || state.exclusive) > { > state.exclusive_waiting_blocked=false; > release_waiters(); > return false; > } > break; > } > } > state.exclusive=true; > return true; > } > > > bool try_lock() > { > boost::unique_lock<boost::mutex> lk(state_change); > > if(state.shared_count || state.exclusive) > { > return false; > } > else > { > state.exclusive=true; > return true; > } > > } > > void unlock() > { > boost::unique_lock<boost::mutex> lk(state_change); > state.assert_locked(); > state.exclusive=false; > state.exclusive_waiting_blocked=false; > state.assert_free(); > release_waiters(); > } > > void lock_upgrade() > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > while(state.exclusive || state.exclusive_waiting_blocked || state.upgrade) > { > shared_cond.wait(lk); > } > state.lock_shared(); > state.upgrade=true; > } > > > bool timed_lock_upgrade(system_time const& timeout) > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > while(state.exclusive || state.exclusive_waiting_blocked || state.upgrade) > { > if(!shared_cond.timed_wait(lk,timeout)) > { > if(state.exclusive || state.exclusive_waiting_blocked || state.upgrade) > { > return false; > } > break; > } > } > state.lock_shared(); > state.upgrade=true; > return true; > } > > template<typename TimeDuration> > bool timed_lock_upgrade(TimeDuration const & relative_time) > { > return timed_lock_upgrade(get_system_time()+relative_time); > } > > > template <class Rep, class Period> > bool try_lock_upgrade_for(const chrono::duration<Rep, Period>& rel_time) > { > return try_lock_upgrade_until(chrono::steady_clock::now() + rel_time); > } > template <class Clock, class Duration> > bool try_lock_upgrade_until(const chrono::time_point<Clock, Duration>& abs_time) > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > while(state.exclusive || state.exclusive_waiting_blocked || state.upgrade) > { > if(cv_status::timeout == shared_cond.wait_until(lk,abs_time)) > { > if(state.exclusive || state.exclusive_waiting_blocked || state.upgrade) > { > return false; > } > break; > } > } > state.lock_shared(); > state.upgrade=true; > return true; > } > > bool try_lock_upgrade() > { > boost::unique_lock<boost::mutex> lk(state_change); > if(state.exclusive || state.exclusive_waiting_blocked || state.upgrade) > { > return false; > } > else > { > state.lock_shared(); > state.upgrade=true; > state.assert_lock_upgraded(); > return true; > } > } > > void unlock_upgrade() > { > boost::unique_lock<boost::mutex> lk(state_change); > > state.unlock_upgrade(); > if(! state.more_shared() ) > { > state.exclusive_waiting_blocked=false; > release_waiters(); > } else { > shared_cond.notify_all(); > } > } > > > void unlock_upgrade_and_lock() > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > state.assert_lock_upgraded(); > state.unlock_shared(); > while (state.more_shared()) > { > upgrade_cond.wait(lk); > } > state.upgrade=false; > state.exclusive=true; > state.assert_locked(); > } > > void unlock_and_lock_upgrade() > { > boost::unique_lock<boost::mutex> lk(state_change); > state.assert_locked(); > state.exclusive=false; > state.upgrade=true; > state.lock_shared(); > state.exclusive_waiting_blocked=false; > state.assert_lock_upgraded(); > release_waiters(); > } > > bool try_unlock_upgrade_and_lock() > { > boost::unique_lock<boost::mutex> lk(state_change); > state.assert_lock_upgraded(); > if( !state.exclusive > && !state.exclusive_waiting_blocked > && state.upgrade > && state.shared_count==1) > { > state.shared_count=0; > state.exclusive=true; > state.upgrade=false; > state.assert_locked(); > return true; > } > return false; > } > > template <class Rep, class Period> > bool > try_unlock_upgrade_and_lock_for( > const chrono::duration<Rep, Period>& rel_time) > { > return try_unlock_upgrade_and_lock_until( > chrono::steady_clock::now() + rel_time); > } > template <class Clock, class Duration> > bool > try_unlock_upgrade_and_lock_until( > const chrono::time_point<Clock, Duration>& abs_time) > { > > boost::this_thread::disable_interruption do_not_disturb; > > boost::unique_lock<boost::mutex> lk(state_change); > state.assert_lock_upgraded(); > if (state.shared_count != 1) > { > for (;;) > { > cv_status status = shared_cond.wait_until(lk,abs_time); > if (state.shared_count == 1) > break; > if(status == cv_status::timeout) > return false; > } > } > state.upgrade=false; > state.exclusive=true; > state.exclusive_waiting_blocked=false; > state.shared_count=0; > return true; > } > > > > void unlock_and_lock_shared() > { > boost::unique_lock<boost::mutex> lk(state_change); > state.assert_locked(); > state.exclusive=false; > state.lock_shared(); > state.exclusive_waiting_blocked=false; > release_waiters(); > } ># 644 "/usr/include/boost/thread/pthread/shared_mutex.hpp" 3 4 > void unlock_upgrade_and_lock_shared() > { > boost::unique_lock<boost::mutex> lk(state_change); > state.assert_lock_upgraded(); > state.upgrade=false; > state.exclusive_waiting_blocked=false; > release_waiters(); > } ># 709 "/usr/include/boost/thread/pthread/shared_mutex.hpp" 3 4 > }; > > typedef shared_mutex upgrade_mutex; >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 715 "/usr/include/boost/thread/pthread/shared_mutex.hpp" 2 3 4 ># 23 "/usr/include/boost/thread/shared_mutex.hpp" 2 3 4 > > > > > > >namespace boost >{ > namespace sync > { ># 46 "/usr/include/boost/thread/shared_mutex.hpp" 3 4 > } >} ># 10 "/usr/include/boost/thread/detail/thread_group.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 14 "/usr/include/boost/thread/detail/thread_group.hpp" 2 3 4 > > > > > > >namespace boost >{ > class thread_group > { > private: > thread_group(thread_group const&); > thread_group& operator=(thread_group const&); > public: > thread_group() {} > ~thread_group() > { > for(std::list<thread*>::iterator it=threads.begin(),end=threads.end(); > it!=end; > ++it) > { > delete *it; > } > } > > bool is_this_thread_in() > { > thread::id id = this_thread::get_id(); > boost::shared_lock<shared_mutex> guard(m); > for(std::list<thread*>::iterator it=threads.begin(),end=threads.end(); > it!=end; > ++it) > { > if ((*it)->get_id() == id) > return true; > } > return false; > } > > bool is_thread_in(thread* thrd) > { > if(thrd) > { > thread::id id = thrd->get_id(); > boost::shared_lock<shared_mutex> guard(m); > for(std::list<thread*>::iterator it=threads.begin(),end=threads.end(); > it!=end; > ++it) > { > if ((*it)->get_id() == id) > return true; > } > return false; > } > else > { > return false; > } > } > > template<typename F> > thread* create_thread(F threadfunc) > { > boost::lock_guard<shared_mutex> guard(m); > std::auto_ptr<thread> new_thread(new thread(threadfunc)); > threads.push_back(new_thread.get()); > return new_thread.release(); > } > > void add_thread(thread* thrd) > { > if(thrd) > { > > > ; > > boost::lock_guard<shared_mutex> guard(m); > threads.push_back(thrd); > } > } > > void remove_thread(thread* thrd) > { > boost::lock_guard<shared_mutex> guard(m); > std::list<thread*>::iterator const it=std::find(threads.begin(),threads.end(),thrd); > if(it!=threads.end()) > { > threads.erase(it); > } > } > > void join_all() > { > > > ; > boost::shared_lock<shared_mutex> guard(m); > > for(std::list<thread*>::iterator it=threads.begin(),end=threads.end(); > it!=end; > ++it) > { > if ((*it)->joinable()) > (*it)->join(); > } > } > > > void interrupt_all() > { > boost::shared_lock<shared_mutex> guard(m); > > for(std::list<thread*>::iterator it=threads.begin(),end=threads.end(); > it!=end; > ++it) > { > (*it)->interrupt(); > } > } > > > size_t size() const > { > boost::shared_lock<shared_mutex> guard(m); > return threads.size(); > } > > private: > std::list<thread*> threads; > mutable shared_mutex m; > }; >} > > > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 153 "/usr/include/boost/thread/detail/thread_group.hpp" 2 3 4 ># 14 "/usr/include/boost/thread/thread.hpp" 2 3 4 ># 14 "/usr/include/boost/thread.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/thread/once.hpp" 1 3 4 ># 20 "/usr/include/boost/thread/once.hpp" 3 4 ># 1 "/usr/include/boost/thread/pthread/once_atomic.hpp" 1 3 4 ># 15 "/usr/include/boost/thread/pthread/once_atomic.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 16 "/usr/include/boost/thread/pthread/once_atomic.hpp" 2 3 4 > > ># 1 "/usr/include/boost/detail/no_exceptions_support.hpp" 1 3 4 ># 19 "/usr/include/boost/thread/pthread/once_atomic.hpp" 2 3 4 > ># 1 "/usr/include/boost/atomic.hpp" 1 3 4 ># 12 "/usr/include/boost/atomic.hpp" 3 4 ># 1 "/usr/include/boost/atomic/atomic.hpp" 1 3 4 ># 12 "/usr/include/boost/atomic/atomic.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 13 "/usr/include/boost/atomic/atomic.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/atomic/detail/config.hpp" 1 3 4 ># 13 "/usr/include/boost/atomic/detail/config.hpp" 3 4 ># 17 "/usr/include/boost/atomic/atomic.hpp" 2 3 4 ># 1 "/usr/include/boost/atomic/detail/platform.hpp" 1 3 4 ># 15 "/usr/include/boost/atomic/detail/platform.hpp" 3 4 > > > > > > > ># 1 "/usr/include/boost/atomic/detail/gcc-atomic.hpp" 1 3 4 ># 12 "/usr/include/boost/atomic/detail/gcc-atomic.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 13 "/usr/include/boost/atomic/detail/gcc-atomic.hpp" 2 3 4 > > > > > > >namespace boost { >namespace atomics { >namespace detail { ># 35 "/usr/include/boost/atomic/detail/gcc-atomic.hpp" 3 4 >inline __attribute__ ((__always_inline__)) constexpr int convert_memory_order_to_gcc(memory_order order) noexcept >{ > return (order == memory_order_relaxed ? 0 : (order == memory_order_consume ? 1 : > (order == memory_order_acquire ? 2 : (order == memory_order_release ? 3 : > (order == memory_order_acq_rel ? 4 : 5))))); >} > >} >} > > > >class atomic_flag >{ >private: > atomic_flag(const atomic_flag &) ; > atomic_flag & operator=(const atomic_flag &) ; > bool v_; > >public: > constexpr atomic_flag(void) noexcept : v_(false) {} > > bool test_and_set(memory_order order = memory_order_seq_cst) volatile 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 noexcept > { > __atomic_clear((bool*)&v_, atomics::detail::convert_memory_order_to_gcc(order)); > } >}; > > > > > >} > ># 1 "/usr/include/boost/atomic/detail/base.hpp" 1 3 4 ># 18 "/usr/include/boost/atomic/detail/base.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 19 "/usr/include/boost/atomic/detail/base.hpp" 2 3 4 > ># 1 "/usr/include/boost/atomic/detail/lockpool.hpp" 1 3 4 ># 11 "/usr/include/boost/atomic/detail/lockpool.hpp" 3 4 ># 1 "/usr/include/boost/atomic/detail/link.hpp" 1 3 4 ># 13 "/usr/include/boost/atomic/detail/link.hpp" 3 4 ># 46 "/usr/include/boost/atomic/detail/link.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 47 "/usr/include/boost/atomic/detail/link.hpp" 2 3 4 ># 12 "/usr/include/boost/atomic/detail/lockpool.hpp" 2 3 4 ># 20 "/usr/include/boost/atomic/detail/lockpool.hpp" 3 4 >namespace boost { >namespace atomics { >namespace detail { ># 50 "/usr/include/boost/atomic/detail/lockpool.hpp" 3 4 >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);) > { > > __asm__ __volatile__ ("pause\n"); > > } > } > > ~scoped_lock(void) > { > flag_.clear(memory_order_release); > } > > scoped_lock(const scoped_lock &) = delete; > scoped_lock& operator=(const scoped_lock &) = delete; > }; > >private: > static lock_type& get_lock_for(const volatile void * addr); >}; > > > >} >} >} ># 21 "/usr/include/boost/atomic/detail/base.hpp" 2 3 4 ># 151 "/usr/include/boost/atomic/detail/base.hpp" 3 4 >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<typename T, typename C, unsigned int Size, bool Sign> >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: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type const& v) noexcept : v_(v) > {} > > void > store(value_type const& v, memory_order = memory_order_seq_cst) volatile noexcept > { > char * storage = storage_ptr(); > guard_type guard(storage); > > memcpy(storage, &v, sizeof(value_type)); > } > > value_type > load(memory_order = memory_order_seq_cst) volatile const 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 , > memory_order ) volatile 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 noexcept > { > return compare_exchange_strong(expected, desired, success_order, failure_order); > } > > value_type > exchange(value_type const& v, memory_order =memory_order_seq_cst) volatile 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 noexcept > { > return false; > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > char * storage_ptr() volatile const noexcept > { > return const_cast<char *>(&reinterpret_cast<char const volatile &>(v_)); > } > > T v_; >}; > >template<typename T, unsigned int Size, bool Sign> >class base_atomic<T, int, Size, Sign> >{ >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: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void > store(value_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > v_ = v; > } > > value_type > load(memory_order = memory_order_seq_cst) const volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type v = const_cast<const volatile value_type &>(v_); > return v; > } > > value_type > exchange(value_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ = v; > return old; > } > > bool > compare_exchange_strong(value_type & expected, value_type desired, > memory_order , > memory_order ) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&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 noexcept > { > return compare_exchange_strong(expected, desired, success_order, failure_order); > } > > value_type > fetch_add(difference_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ += v; > return old; > } > > value_type > fetch_sub(difference_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ -= v; > return old; > } > > value_type > fetch_and(value_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ &= v; > return old; > } > > value_type > fetch_or(value_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ |= v; > return old; > } > > value_type > fetch_xor(value_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ ^= v; > return old; > } > > bool > is_lock_free(void) const volatile noexcept > { > return false; > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return fetch_sub(v) - v; } value_type operator&=(difference_type v) volatile noexcept { return fetch_and(v) & v; } value_type operator|=(difference_type v) volatile noexcept { return fetch_or(v) | v; } value_type operator^=(difference_type v) volatile noexcept { return fetch_xor(v) ^ v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > >template<typename T, unsigned int Size, bool Sign> >class base_atomic<T *, void *, Size, Sign> >{ >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: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void > store(value_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > v_ = v; > } > > value_type > load(memory_order = memory_order_seq_cst) const volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type v = const_cast<const volatile value_type &>(v_); > return v; > } > > value_type > exchange(value_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ = v; > return old; > } > > bool > compare_exchange_strong(value_type & expected, value_type desired, > memory_order , > memory_order ) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&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 noexcept > { > return compare_exchange_strong(expected, desired, success_order, failure_order); > } > > value_type fetch_add(difference_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ += v; > return old; > } > > value_type fetch_sub(difference_type v, memory_order = memory_order_seq_cst) volatile > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ -= v; > return old; > } > > bool > is_lock_free(void) const volatile noexcept > { > return false; > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return fetch_sub(v) - v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > >template<unsigned int Size, bool Sign> >class base_atomic<void *, void *, Size, Sign> >{ >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: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void > store(value_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > v_ = v; > } > > value_type > load(memory_order = memory_order_seq_cst) const volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type v = const_cast<const volatile value_type &>(v_); > return v; > } > > value_type > exchange(value_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > v_ = v; > return old; > } > > bool > compare_exchange_strong(value_type & expected, value_type desired, > memory_order , > memory_order ) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&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 noexcept > { > return compare_exchange_strong(expected, desired, success_order, failure_order); > } > > bool > is_lock_free(void) const volatile noexcept > { > return false; > } > > value_type fetch_add(difference_type v, memory_order = memory_order_seq_cst) volatile noexcept > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > char * cv = reinterpret_cast<char*>(old); > cv += v; > v_ = cv; > return old; > } > > value_type fetch_sub(difference_type v, memory_order = memory_order_seq_cst) volatile > { > guard_type guard(const_cast<value_type *>(&v_)); > > value_type old = v_; > char * cv = reinterpret_cast<char*>(old); > cv -= v; > v_ = cv; > return old; > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return (char*)fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return (char*)fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return (char*)fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return (char*)fetch_sub(v) - v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > >} >} >} ># 75 "/usr/include/boost/atomic/detail/gcc-atomic.hpp" 2 3 4 ># 112 "/usr/include/boost/atomic/detail/gcc-atomic.hpp" 3 4 >namespace boost { > > >inline __attribute__ ((__always_inline__)) void atomic_thread_fence(memory_order order) >{ > __atomic_thread_fence(atomics::detail::convert_memory_order_to_gcc(order)); >} > > >inline __attribute__ ((__always_inline__)) void atomic_signal_fence(memory_order order) >{ > __atomic_signal_fence(atomics::detail::convert_memory_order_to_gcc(order)); >} > >namespace atomics { >namespace detail { > > > >template<typename T, bool Sign> >class base_atomic<T, int, 1, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef T difference_type; > >protected: > typedef value_type value_arg_type; > >public: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void store(value_type v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 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 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 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 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 noexcept > { > return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); > } > > bool is_lock_free(void) const volatile noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return fetch_sub(v) - v; } value_type operator&=(difference_type v) volatile noexcept { return fetch_and(v) & v; } value_type operator|=(difference_type v) volatile noexcept { return fetch_or(v) | v; } value_type operator^=(difference_type v) volatile noexcept { return fetch_xor(v) ^ v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > >template<typename T, bool Sign> >class base_atomic<T, void, 1, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef uint8_t storage_type; > >protected: > typedef value_type const& value_arg_type; > >public: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type const& v) noexcept : > v_(reinterpret_cast<storage_type const&>(v)) > { > } > > void store(value_type const& v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > storage_type v_; >}; > > > > > >template<typename T, bool Sign> >class base_atomic<T, int, 2, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef T difference_type; > >protected: > typedef value_type value_arg_type; > >public: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void store(value_type v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 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 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 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 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 noexcept > { > return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); > } > > bool is_lock_free(void) const volatile noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return fetch_sub(v) - v; } value_type operator&=(difference_type v) volatile noexcept { return fetch_and(v) & v; } value_type operator|=(difference_type v) volatile noexcept { return fetch_or(v) | v; } value_type operator^=(difference_type v) volatile noexcept { return fetch_xor(v) ^ v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > >template<typename T, bool Sign> >class base_atomic<T, void, 2, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef uint16_t storage_type; > >protected: > typedef value_type const& value_arg_type; > >public: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type const& v) noexcept : > v_(reinterpret_cast<storage_type const&>(v)) > { > } > > void store(value_type const& v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > storage_type v_; >}; > > > > > >template<typename T, bool Sign> >class base_atomic<T, int, 4, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef T difference_type; > >protected: > typedef value_type value_arg_type; > >public: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void store(value_type v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 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 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 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 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 noexcept > { > return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); > } > > bool is_lock_free(void) const volatile noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return fetch_sub(v) - v; } value_type operator&=(difference_type v) volatile noexcept { return fetch_and(v) & v; } value_type operator|=(difference_type v) volatile noexcept { return fetch_or(v) | v; } value_type operator^=(difference_type v) volatile noexcept { return fetch_xor(v) ^ v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > >template<typename T, bool Sign> >class base_atomic<T, void, 4, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef uint32_t storage_type; > >protected: > typedef value_type const& value_arg_type; > >public: > base_atomic(void) = default; > explicit base_atomic(value_type const& v) noexcept : v_(0) > { > memcpy(&v_, &v, sizeof(value_type)); > } > > void store(value_type const& v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > storage_type v_; >}; > > > > > >template<typename T, bool Sign> >class base_atomic<T, int, 8, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef T difference_type; > >protected: > typedef value_type value_arg_type; > >public: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void store(value_type v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 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 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 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 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 noexcept > { > return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); > } > > bool is_lock_free(void) const volatile noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return fetch_sub(v) - v; } value_type operator&=(difference_type v) volatile noexcept { return fetch_and(v) & v; } value_type operator|=(difference_type v) volatile noexcept { return fetch_or(v) | v; } value_type operator^=(difference_type v) volatile noexcept { return fetch_xor(v) ^ v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > >template<typename T, bool Sign> >class base_atomic<T, void, 8, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef uint64_t storage_type; > >protected: > typedef value_type const& value_arg_type; > >public: > base_atomic(void) = default; > explicit base_atomic(value_type const& v) noexcept : v_(0) > { > memcpy(&v_, &v, sizeof(value_type)); > } > > void store(value_type const& v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > storage_type v_; >}; > > > > > >template<typename T, bool Sign> >class base_atomic<T, int, 16, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef T difference_type; > >protected: > typedef value_type value_arg_type; > >public: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void store(value_type v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 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 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 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 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 noexcept > { > return __atomic_fetch_xor(&v_, v, atomics::detail::convert_memory_order_to_gcc(order)); > } > > bool is_lock_free(void) const volatile noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return fetch_sub(v) - v; } value_type operator&=(difference_type v) volatile noexcept { return fetch_and(v) & v; } value_type operator|=(difference_type v) volatile noexcept { return fetch_or(v) | v; } value_type operator^=(difference_type v) volatile noexcept { return fetch_xor(v) ^ v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > > > >typedef boost::uint128_type storage128_type; ># 948 "/usr/include/boost/atomic/detail/gcc-atomic.hpp" 3 4 >template<typename T, bool Sign> >class base_atomic<T, void, 16, Sign> >{ >private: > typedef base_atomic this_type; > typedef T value_type; > typedef storage128_type storage_type; > >protected: > typedef value_type const& value_arg_type; > >public: > base_atomic(void) = default; > explicit base_atomic(value_type const& v) 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 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 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 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 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 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 noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > storage_type v_; >}; ># 1051 "/usr/include/boost/atomic/detail/gcc-atomic.hpp" 3 4 >template<typename T, bool Sign> >class base_atomic<T*, void*, sizeof(void*), Sign> >{ >private: > typedef base_atomic this_type; > typedef T* value_type; > typedef std::ptrdiff_t difference_type; > >protected: > typedef value_type value_arg_type; > >public: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void store(value_type v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 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 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 noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return fetch_sub(v) - v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > >template<bool Sign> >class base_atomic<void*, void*, sizeof(void*), Sign> >{ >private: > typedef base_atomic this_type; > typedef void* value_type; > typedef std::ptrdiff_t difference_type; > >protected: > typedef value_type value_arg_type; > >public: > base_atomic(void) = default; > constexpr explicit base_atomic(value_type v) noexcept : v_(v) {} > > void store(value_type v, memory_order order = memory_order_seq_cst) volatile 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 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 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 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 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 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 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 noexcept > { > return __atomic_is_lock_free(sizeof(v_), &v_); > } > > bool compare_exchange_strong( value_type & expected, value_type desired, memory_order order = memory_order_seq_cst) volatile 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 noexcept { return compare_exchange_weak(expected, desired, order, calculate_failure_order(order)); } value_type operator++(int) volatile noexcept { return fetch_add(1); } value_type operator++(void) volatile noexcept { return (char*)fetch_add(1) + 1; } value_type operator--(int) volatile noexcept { return fetch_sub(1); } value_type operator--(void) volatile noexcept { return (char*)fetch_sub(1) - 1; } value_type operator+=(difference_type v) volatile noexcept { return (char*)fetch_add(v) + v; } value_type operator-=(difference_type v) volatile noexcept { return (char*)fetch_sub(v) - v; } > > base_atomic(base_atomic const&) = delete; > base_atomic& operator=(base_atomic const&) = delete; > >private: > value_type v_; >}; > > > >} >} >} ># 23 "/usr/include/boost/atomic/detail/platform.hpp" 2 3 4 ># 18 "/usr/include/boost/atomic/atomic.hpp" 2 3 4 ># 1 "/usr/include/boost/atomic/detail/type-classification.hpp" 1 3 4 ># 14 "/usr/include/boost/atomic/detail/type-classification.hpp" 3 4 > > > >namespace boost { >namespace atomics { >namespace detail { > >template<typename T, bool IsInt = boost::is_integral<T>::value> >struct classify >{ > typedef void type; >}; > >template<typename T> >struct classify<T, true> {typedef int type;}; > >template<typename T> >struct classify<T*, false> {typedef void* type;}; > >template<typename T> >struct storage_size_of >{ > enum _ > { > size = sizeof(T), > value = (size == 3 ? 4 : (size >= 5 && size <= 7 ? 8 : (size >= 9 && size <= 15 ? 16 : size))) > }; >}; > >}}} ># 19 "/usr/include/boost/atomic/atomic.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_signed.hpp" 1 3 4 ># 19 "/usr/include/boost/type_traits/is_signed.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 20 "/usr/include/boost/type_traits/is_signed.hpp" 2 3 4 > >namespace boost { > > > >namespace detail{ > > > >template <class T> >struct is_signed_values >{ > > > > > > typedef typename remove_cv<T>::type no_cv_t; > static const no_cv_t minus_one = (static_cast<no_cv_t>(-1)); > static const no_cv_t zero = (static_cast<no_cv_t>(0)); >}; > >template <class T> >struct is_signed_helper >{ > typedef typename remove_cv<T>::type no_cv_t; > static const bool value = (!(::boost::detail::is_signed_values<T>::minus_one > boost::detail::is_signed_values<T>::zero)); >}; > >template <bool integral_type> >struct is_signed_select_helper >{ > template <class T> > struct rebind > { > typedef is_signed_helper<T> type; > }; >}; > >template <> >struct is_signed_select_helper<false> >{ > template <class T> > struct rebind > { > typedef false_type type; > }; >}; > >template <class T> >struct is_signed_imp >{ > typedef is_signed_select_helper< > ::boost::type_traits::ice_or< > ::boost::is_integral<T>::value, > ::boost::is_enum<T>::value>::value > > selector; > typedef typename selector::template rebind<T> binder; > typedef typename binder::type type; > > > > static const bool value = type::value; > >}; ># 126 "/usr/include/boost/type_traits/is_signed.hpp" 3 4 >} > > > > > > >template< typename T > struct is_signed : public ::boost::integral_constant<bool,::boost::detail::is_signed_imp<T>::value> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 139 "/usr/include/boost/type_traits/is_signed.hpp" 2 3 4 ># 20 "/usr/include/boost/atomic/atomic.hpp" 2 3 4 ># 29 "/usr/include/boost/atomic/atomic.hpp" 3 4 >namespace boost { ># 92 "/usr/include/boost/atomic/atomic.hpp" 3 4 >template<typename T> >class atomic : > public atomics::detail::base_atomic< > T, > typename atomics::detail::classify<T>::type, > atomics::detail::storage_size_of<T>::value, > > boost::is_signed<T>::value > > > > > > >{ >private: > typedef T value_type; > typedef atomics::detail::base_atomic< > T, > typename atomics::detail::classify<T>::type, > atomics::detail::storage_size_of<T>::value, > > boost::is_signed<T>::value > > > > > > super; > typedef typename super::value_arg_type value_arg_type; > >public: > atomic(void) = default; > > > > > > explicit constexpr atomic(value_arg_type v) noexcept : super(v) {} > > value_type operator=(value_arg_type v) volatile noexcept > { > this->store(v); > return v; > } > > operator value_type(void) volatile const noexcept > { > return this->load(); > } > > atomic(atomic const&) = delete; > atomic& operator=(atomic const&) volatile = delete; >}; > >typedef atomic<char> atomic_char; >typedef atomic<unsigned char> atomic_uchar; >typedef atomic<signed char> atomic_schar; >typedef atomic<uint8_t> atomic_uint8_t; >typedef atomic<int8_t> atomic_int8_t; >typedef atomic<unsigned short> atomic_ushort; >typedef atomic<short> atomic_short; >typedef atomic<uint16_t> atomic_uint16_t; >typedef atomic<int16_t> atomic_int16_t; >typedef atomic<unsigned int> atomic_uint; >typedef atomic<int> atomic_int; >typedef atomic<uint32_t> atomic_uint32_t; >typedef atomic<int32_t> atomic_int32_t; >typedef atomic<unsigned long> atomic_ulong; >typedef atomic<long> atomic_long; >typedef atomic<uint64_t> atomic_uint64_t; >typedef atomic<int64_t> atomic_int64_t; > >typedef atomic<boost::ulong_long_type> atomic_ullong; >typedef atomic<boost::long_long_type> atomic_llong; > >typedef atomic<void*> atomic_address; >typedef atomic<bool> atomic_bool; >typedef atomic<wchar_t> atomic_wchar_t; > >typedef atomic<char16_t> atomic_char16_t; > > >typedef atomic<char32_t> atomic_char32_t; > > >typedef atomic<int_least8_t> atomic_int_least8_t; >typedef atomic<uint_least8_t> atomic_uint_least8_t; >typedef atomic<int_least16_t> atomic_int_least16_t; >typedef atomic<uint_least16_t> atomic_uint_least16_t; >typedef atomic<int_least32_t> atomic_int_least32_t; >typedef atomic<uint_least32_t> atomic_uint_least32_t; >typedef atomic<int_least64_t> atomic_int_least64_t; >typedef atomic<uint_least64_t> atomic_uint_least64_t; >typedef atomic<int_fast8_t> atomic_int_fast8_t; >typedef atomic<uint_fast8_t> atomic_uint_fast8_t; >typedef atomic<int_fast16_t> atomic_int_fast16_t; >typedef atomic<uint_fast16_t> atomic_uint_fast16_t; >typedef atomic<int_fast32_t> atomic_int_fast32_t; >typedef atomic<uint_fast32_t> atomic_uint_fast32_t; >typedef atomic<int_fast64_t> atomic_int_fast64_t; >typedef atomic<uint_fast64_t> atomic_uint_fast64_t; >typedef atomic<intmax_t> atomic_intmax_t; >typedef atomic<uintmax_t> atomic_uintmax_t; > >typedef atomic<std::size_t> atomic_size_t; >typedef atomic<std::ptrdiff_t> atomic_ptrdiff_t; > > >typedef atomic<intptr_t> atomic_intptr_t; >typedef atomic<uintptr_t> atomic_uintptr_t; ># 230 "/usr/include/boost/atomic/atomic.hpp" 3 4 >} ># 13 "/usr/include/boost/atomic.hpp" 2 3 4 ># 21 "/usr/include/boost/thread/pthread/once_atomic.hpp" 2 3 4 > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 23 "/usr/include/boost/thread/pthread/once_atomic.hpp" 2 3 4 > >namespace boost >{ > > struct once_flag; > > namespace thread_detail > { > > > typedef unsigned int atomic_int_type; ># 47 "/usr/include/boost/thread/pthread/once_atomic.hpp" 3 4 > typedef boost::atomic<atomic_int_type> atomic_type; > > __attribute__((__visibility__("default"))) bool enter_once_region(once_flag& flag) noexcept; > __attribute__((__visibility__("default"))) void commit_once_region(once_flag& flag) noexcept; > __attribute__((__visibility__("default"))) void rollback_once_region(once_flag& flag) noexcept; > inline atomic_type& get_atomic_storage(once_flag& flag) noexcept; > } ># 85 "/usr/include/boost/thread/pthread/once_atomic.hpp" 3 4 > struct once_flag > { > > > > __attribute__((__may_alias__)) thread_detail::atomic_int_type storage; > }; > > > > namespace thread_detail > { > inline atomic_type& get_atomic_storage(once_flag& flag) noexcept > { > return reinterpret_cast< atomic_type& >(flag.storage); > } > > } ># 120 "/usr/include/boost/thread/pthread/once_atomic.hpp" 3 4 > template<typename Function, class ...ArgTypes> > inline void call_once(once_flag& flag, Function && f, ArgTypes &&... args) > { > if (thread_detail::enter_once_region(flag)) > { > { try > { > detail::invoke( > thread_detail::decay_copy(boost::forward<Function>(f)), > thread_detail::decay_copy(boost::forward<ArgTypes>(args))... > ) ; > } > catch(...) > { > thread_detail::rollback_once_region(flag); > throw; > } > } > thread_detail::commit_once_region(flag); > } > } ># 308 "/usr/include/boost/thread/pthread/once_atomic.hpp" 3 4 >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 311 "/usr/include/boost/thread/pthread/once_atomic.hpp" 2 3 4 ># 21 "/usr/include/boost/thread/once.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 29 "/usr/include/boost/thread/once.hpp" 2 3 4 > >namespace boost >{ > > >template<typename Function> >inline void call_once(Function func,once_flag& flag) > > { > call_once(flag,func); > } >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 43 "/usr/include/boost/thread/once.hpp" 2 3 4 ># 18 "/usr/include/boost/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/recursive_mutex.hpp" 1 3 4 ># 16 "/usr/include/boost/thread/recursive_mutex.hpp" 3 4 ># 1 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 1 3 4 ># 16 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 17 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 2 3 4 > > > > ># 1 "/usr/include/errno.h" 1 3 4 ># 22 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 2 3 4 ># 43 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 44 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 2 3 4 > >namespace boost >{ > class recursive_mutex > { > private: > pthread_mutex_t m; > > > > > > > public: > recursive_mutex(recursive_mutex const&) = delete; recursive_mutex& operator=(recursive_mutex const&) = delete; > recursive_mutex() > { > > pthread_mutexattr_t attr; > > int const init_attr_res=pthread_mutexattr_init(&attr); > if(init_attr_res) > { > boost::throw_exception(thread_resource_error(init_attr_res, "boost:: recursive_mutex constructor failed in pthread_mutexattr_init")); > } > int const set_attr_res=pthread_mutexattr_settype(&attr,PTHREAD_MUTEX_RECURSIVE); > if(set_attr_res) > { > ((void)(!pthread_mutexattr_destroy(&attr))); > boost::throw_exception(thread_resource_error(set_attr_res, "boost:: recursive_mutex constructor failed in pthread_mutexattr_settype")); > } > > int const res=pthread_mutex_init(&m,&attr); > if(res) > { > ((void)(!pthread_mutexattr_destroy(&attr))); > boost::throw_exception(thread_resource_error(res, "boost:: recursive_mutex constructor failed in pthread_mutex_init")); > } > ((void)(!pthread_mutexattr_destroy(&attr))); ># 98 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 3 4 > } > ~recursive_mutex() > { > ((void)(!pthread_mutex_destroy(&m))); > > > > } > > > void lock() > { > ((void)(!pthread_mutex_lock(&m))); > } > > void unlock() > { > ((void)(!pthread_mutex_unlock(&m))); > } > > bool try_lock() noexcept > { > int const res=pthread_mutex_trylock(&m); > (static_cast<void> (0)); > return !res; > } > > typedef pthread_mutex_t* native_handle_type; > native_handle_type native_handle() > { > return &m; > } ># 176 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 3 4 > typedef unique_lock<recursive_mutex> scoped_lock; > typedef detail::try_lock_wrapper<recursive_mutex> scoped_try_lock; > > }; > > typedef recursive_mutex recursive_try_mutex; > > class recursive_timed_mutex > { > private: > pthread_mutex_t m; > > > > > > > public: > recursive_timed_mutex(recursive_timed_mutex const&) = delete; recursive_timed_mutex& operator=(recursive_timed_mutex const&) = delete; > recursive_timed_mutex() > { > > pthread_mutexattr_t attr; > > int const init_attr_res=pthread_mutexattr_init(&attr); > if(init_attr_res) > { > boost::throw_exception(thread_resource_error(init_attr_res, "boost:: recursive_timed_mutex constructor failed in pthread_mutexattr_init")); > } > int const set_attr_res=pthread_mutexattr_settype(&attr,PTHREAD_MUTEX_RECURSIVE); > if(set_attr_res) > { > boost::throw_exception(thread_resource_error(set_attr_res, "boost:: recursive_timed_mutex constructor failed in pthread_mutexattr_settype")); > } > > int const res=pthread_mutex_init(&m,&attr); > if(res) > { > ((void)(!pthread_mutexattr_destroy(&attr))); > boost::throw_exception(thread_resource_error(res, "boost:: recursive_timed_mutex constructor failed in pthread_mutex_init")); > } > ((void)(!pthread_mutexattr_destroy(&attr))); ># 233 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 3 4 > } > ~recursive_timed_mutex() > { > ((void)(!pthread_mutex_destroy(&m))); > > > > } > > > template<typename TimeDuration> > bool timed_lock(TimeDuration const & relative_time) > { > return timed_lock(get_system_time()+relative_time); > } > > > > void lock() > { > ((void)(!pthread_mutex_lock(&m))); > } > > void unlock() > { > ((void)(!pthread_mutex_unlock(&m))); > } > > bool try_lock() > { > int const res=pthread_mutex_trylock(&m); > (static_cast<void> (0)); > return !res; > } > private: > bool do_try_lock_until(struct timespec const &timeout) > { > int const res=pthread_mutex_timedlock(&m,&timeout); > (static_cast<void> (0)); > return !res; > } > > public: ># 347 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 3 4 > bool timed_lock(system_time const & abs_time) > { > struct timespec const ts=detail::to_timespec(abs_time); > return do_try_lock_until(ts); > } > > > template <class Rep, class Period> > bool try_lock_for(const chrono::duration<Rep, Period>& rel_time) > { > return try_lock_until(chrono::steady_clock::now() + rel_time); > } > template <class Clock, class Duration> > bool try_lock_until(const chrono::time_point<Clock, Duration>& t) > { > using namespace chrono; > system_clock::time_point s_now = system_clock::now(); > typename Clock::time_point c_now = Clock::now(); > return try_lock_until(s_now + ceil<nanoseconds>(t - c_now)); > } > template <class Duration> > bool try_lock_until(const chrono::time_point<chrono::system_clock, Duration>& t) > { > using namespace chrono; > typedef time_point<system_clock, nanoseconds> nano_sys_tmpt; > return try_lock_until(nano_sys_tmpt(ceil<nanoseconds>(t.time_since_epoch()))); > } > bool try_lock_until(const chrono::time_point<chrono::system_clock, chrono::nanoseconds>& tp) > { > > chrono::nanoseconds d = tp.time_since_epoch(); > timespec ts = boost::detail::to_timespec(d); > return do_try_lock_until(ts); > } > > > > typedef pthread_mutex_t* native_handle_type; > native_handle_type native_handle() > { > return &m; > } > > > typedef unique_lock<recursive_timed_mutex> scoped_timed_lock; > typedef detail::try_lock_wrapper<recursive_timed_mutex> scoped_try_lock; > typedef scoped_timed_lock scoped_lock; > > }; > >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 400 "/usr/include/boost/thread/pthread/recursive_mutex.hpp" 2 3 4 ># 17 "/usr/include/boost/thread/recursive_mutex.hpp" 2 3 4 > > > > > > >namespace boost >{ > namespace sync > { ># 51 "/usr/include/boost/thread/recursive_mutex.hpp" 3 4 > template<> > struct is_recursive_mutex_sur_parolle<recursive_mutex> > { > static const bool value = true; > }; > template<> > struct is_recursive_mutex_sur_parolle<recursive_timed_mutex> > { > static const bool value = true; > }; > > } >} ># 19 "/usr/include/boost/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/tss.hpp" 1 3 4 ># 12 "/usr/include/boost/thread/tss.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 13 "/usr/include/boost/thread/tss.hpp" 2 3 4 > >namespace boost >{ > namespace detail > { > struct tss_cleanup_function > { > virtual ~tss_cleanup_function() > {} > > virtual void operator()(void* data)=0; > }; > > __attribute__((__visibility__("default"))) void set_tss_data(void const* key,boost::shared_ptr<tss_cleanup_function> func,void* tss_data,bool cleanup_existing); > __attribute__((__visibility__("default"))) void* get_tss_data(void const* key); > } > > template <typename T> > class thread_specific_ptr > { > private: > thread_specific_ptr(thread_specific_ptr&); > thread_specific_ptr& operator=(thread_specific_ptr&); > > struct delete_data: > detail::tss_cleanup_function > { > void operator()(void* data) > { > delete static_cast<T*>(data); > } > }; > > struct run_custom_cleanup_function: > detail::tss_cleanup_function > { > void (*cleanup_function)(T*); > > explicit run_custom_cleanup_function(void (*cleanup_function_)(T*)): > cleanup_function(cleanup_function_) > {} > > void operator()(void* data) > { > cleanup_function(static_cast<T*>(data)); > } > }; > > > boost::shared_ptr<detail::tss_cleanup_function> cleanup; > > public: > typedef T element_type; > > thread_specific_ptr(): > cleanup(detail::heap_new<delete_data>(),detail::do_heap_delete<delete_data>()) > {} > explicit thread_specific_ptr(void (*func_)(T*)) > { > if(func_) > { > cleanup.reset(detail::heap_new<run_custom_cleanup_function>(func_),detail::do_heap_delete<run_custom_cleanup_function>()); > } > } > ~thread_specific_ptr() > { > detail::set_tss_data(this,boost::shared_ptr<detail::tss_cleanup_function>(),0,true); > } > > T* get() const > { > return static_cast<T*>(detail::get_tss_data(this)); > } > T* operator->() const > { > return get(); > } > T& operator*() const > { > return *get(); > } > T* release() > { > T* const temp=get(); > detail::set_tss_data(this,boost::shared_ptr<detail::tss_cleanup_function>(),0,false); > return temp; > } > void reset(T* new_value=0) > { > T* const current_value=get(); > if(current_value!=new_value) > { > detail::set_tss_data(this,cleanup,new_value,true); > } > } > }; >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 112 "/usr/include/boost/thread/tss.hpp" 2 3 4 ># 20 "/usr/include/boost/thread.hpp" 2 3 4 > ># 1 "/usr/include/boost/thread/locks.hpp" 1 3 4 ># 10 "/usr/include/boost/thread/locks.hpp" 3 4 ># 1 "/usr/include/boost/thread/lock_algorithms.hpp" 1 3 4 ># 17 "/usr/include/boost/thread/lock_algorithms.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 18 "/usr/include/boost/thread/lock_algorithms.hpp" 2 3 4 > >namespace boost >{ > namespace detail > { > template <typename MutexType1, typename MutexType2> > unsigned try_lock_internal(MutexType1& m1, MutexType2& m2) > { > boost::unique_lock<MutexType1> l1(m1, boost::try_to_lock); > if (!l1) > { > return 1; > } > if (!m2.try_lock()) > { > return 2; > } > l1.release(); > return 0; > } > > template <typename MutexType1, typename MutexType2, typename MutexType3> > unsigned try_lock_internal(MutexType1& m1, MutexType2& m2, MutexType3& m3) > { > boost::unique_lock<MutexType1> l1(m1, boost::try_to_lock); > if (!l1) > { > return 1; > } > if (unsigned const failed_lock=try_lock_internal(m2,m3)) > { > return failed_lock + 1; > } > l1.release(); > return 0; > } > > template <typename MutexType1, typename MutexType2, typename MutexType3, typename MutexType4> > unsigned try_lock_internal(MutexType1& m1, MutexType2& m2, MutexType3& m3, MutexType4& m4) > { > boost::unique_lock<MutexType1> l1(m1, boost::try_to_lock); > if (!l1) > { > return 1; > } > if (unsigned const failed_lock=try_lock_internal(m2,m3,m4)) > { > return failed_lock + 1; > } > l1.release(); > return 0; > } > > template <typename MutexType1, typename MutexType2, typename MutexType3, typename MutexType4, typename MutexType5> > unsigned try_lock_internal(MutexType1& m1, MutexType2& m2, MutexType3& m3, MutexType4& m4, MutexType5& m5) > { > boost::unique_lock<MutexType1> l1(m1, boost::try_to_lock); > if (!l1) > { > return 1; > } > if (unsigned const failed_lock=try_lock_internal(m2,m3,m4,m5)) > { > return failed_lock + 1; > } > l1.release(); > return 0; > } > > template <typename MutexType1, typename MutexType2> > unsigned lock_helper(MutexType1& m1, MutexType2& m2) > { > boost::unique_lock<MutexType1> l1(m1); > if (!m2.try_lock()) > { > return 1; > } > l1.release(); > return 0; > } > > template <typename MutexType1, typename MutexType2, typename MutexType3> > unsigned lock_helper(MutexType1& m1, MutexType2& m2, MutexType3& m3) > { > boost::unique_lock<MutexType1> l1(m1); > if (unsigned const failed_lock=try_lock_internal(m2,m3)) > { > return failed_lock; > } > l1.release(); > return 0; > } > > template <typename MutexType1, typename MutexType2, typename MutexType3, typename MutexType4> > unsigned lock_helper(MutexType1& m1, MutexType2& m2, MutexType3& m3, MutexType4& m4) > { > boost::unique_lock<MutexType1> l1(m1); > if (unsigned const failed_lock=try_lock_internal(m2,m3,m4)) > { > return failed_lock; > } > l1.release(); > return 0; > } > > template <typename MutexType1, typename MutexType2, typename MutexType3, typename MutexType4, typename MutexType5> > unsigned lock_helper(MutexType1& m1, MutexType2& m2, MutexType3& m3, MutexType4& m4, MutexType5& m5) > { > boost::unique_lock<MutexType1> l1(m1); > if (unsigned const failed_lock=try_lock_internal(m2,m3,m4,m5)) > { > return failed_lock; > } > l1.release(); > return 0; > } > } > > namespace detail > { > template <bool x> > struct is_mutex_type_wrapper > { > }; > > template <typename MutexType1, typename MutexType2> > void lock_impl(MutexType1& m1, MutexType2& m2, is_mutex_type_wrapper<true> ) > { > unsigned const lock_count = 2; > unsigned lock_first = 0; > for (;;) > { > switch (lock_first) > { > case 0: > lock_first = detail::lock_helper(m1, m2); > if (!lock_first) return; > break; > case 1: > lock_first = detail::lock_helper(m2, m1); > if (!lock_first) return; > lock_first = (lock_first + 1) % lock_count; > break; > } > } > } > > template <typename Iterator> > void lock_impl(Iterator begin, Iterator end, is_mutex_type_wrapper<false> ); > } > > template <typename MutexType1, typename MutexType2> > void lock(MutexType1& m1, MutexType2& m2) > { > detail::lock_impl(m1, m2, detail::is_mutex_type_wrapper<is_mutex_type<MutexType1>::value>()); > } > > template <typename MutexType1, typename MutexType2> > void lock(const MutexType1& m1, MutexType2& m2) > { > detail::lock_impl(m1, m2, detail::is_mutex_type_wrapper<is_mutex_type<MutexType1>::value>()); > } > > template <typename MutexType1, typename MutexType2> > void lock(MutexType1& m1, const MutexType2& m2) > { > detail::lock_impl(m1, m2, detail::is_mutex_type_wrapper<is_mutex_type<MutexType1>::value>()); > } > > template <typename MutexType1, typename MutexType2> > void lock(const MutexType1& m1, const MutexType2& m2) > { > detail::lock_impl(m1, m2, detail::is_mutex_type_wrapper<is_mutex_type<MutexType1>::value>()); > } > > template <typename MutexType1, typename MutexType2, typename MutexType3> > void lock(MutexType1& m1, MutexType2& m2, MutexType3& m3) > { > unsigned const lock_count = 3; > unsigned lock_first = 0; > for (;;) > { > switch (lock_first) > { > case 0: > lock_first = detail::lock_helper(m1, m2, m3); > if (!lock_first) return; > break; > case 1: > lock_first = detail::lock_helper(m2, m3, m1); > if (!lock_first) return; > lock_first = (lock_first + 1) % lock_count; > break; > case 2: > lock_first = detail::lock_helper(m3, m1, m2); > if (!lock_first) return; > lock_first = (lock_first + 2) % lock_count; > break; > } > } > } > > template <typename MutexType1, typename MutexType2, typename MutexType3, typename MutexType4> > void lock(MutexType1& m1, MutexType2& m2, MutexType3& m3, MutexType4& m4) > { > unsigned const lock_count = 4; > unsigned lock_first = 0; > for (;;) > { > switch (lock_first) > { > case 0: > lock_first = detail::lock_helper(m1, m2, m3, m4); > if (!lock_first) return; > break; > case 1: > lock_first = detail::lock_helper(m2, m3, m4, m1); > if (!lock_first) return; > lock_first = (lock_first + 1) % lock_count; > break; > case 2: > lock_first = detail::lock_helper(m3, m4, m1, m2); > if (!lock_first) return; > lock_first = (lock_first + 2) % lock_count; > break; > case 3: > lock_first = detail::lock_helper(m4, m1, m2, m3); > if (!lock_first) return; > lock_first = (lock_first + 3) % lock_count; > break; > } > } > } > > template <typename MutexType1, typename MutexType2, typename MutexType3, typename MutexType4, typename MutexType5> > void lock(MutexType1& m1, MutexType2& m2, MutexType3& m3, MutexType4& m4, MutexType5& m5) > { > unsigned const lock_count = 5; > unsigned lock_first = 0; > for (;;) > { > switch (lock_first) > { > case 0: > lock_first = detail::lock_helper(m1, m2, m3, m4, m5); > if (!lock_first) return; > break; > case 1: > lock_first = detail::lock_helper(m2, m3, m4, m5, m1); > if (!lock_first) return; > lock_first = (lock_first + 1) % lock_count; > break; > case 2: > lock_first = detail::lock_helper(m3, m4, m5, m1, m2); > if (!lock_first) return; > lock_first = (lock_first + 2) % lock_count; > break; > case 3: > lock_first = detail::lock_helper(m4, m5, m1, m2, m3); > if (!lock_first) return; > lock_first = (lock_first + 3) % lock_count; > break; > case 4: > lock_first = detail::lock_helper(m5, m1, m2, m3, m4); > if (!lock_first) return; > lock_first = (lock_first + 4) % lock_count; > break; > } > } > } > > namespace detail > { > template <typename Mutex, bool x = is_mutex_type<Mutex>::value> > struct try_lock_impl_return > { > typedef int type; > }; > > template <typename Iterator> > struct try_lock_impl_return<Iterator, false> > { > typedef Iterator type; > }; > > template <typename MutexType1, typename MutexType2> > int try_lock_impl(MutexType1& m1, MutexType2& m2, is_mutex_type_wrapper<true> ) > { > return ((int) detail::try_lock_internal(m1, m2)) - 1; > } > > template <typename Iterator> > Iterator try_lock_impl(Iterator begin, Iterator end, is_mutex_type_wrapper<false> ); > } > > template <typename MutexType1, typename MutexType2> > typename detail::try_lock_impl_return<MutexType1>::type try_lock(MutexType1& m1, MutexType2& m2) > { > return detail::try_lock_impl(m1, m2, detail::is_mutex_type_wrapper<is_mutex_type<MutexType1>::value>()); > } > > template <typename MutexType1, typename MutexType2> > typename detail::try_lock_impl_return<MutexType1>::type try_lock(const MutexType1& m1, MutexType2& m2) > { > return detail::try_lock_impl(m1, m2, detail::is_mutex_type_wrapper<is_mutex_type<MutexType1>::value>()); > } > > template <typename MutexType1, typename MutexType2> > typename detail::try_lock_impl_return<MutexType1>::type try_lock(MutexType1& m1, const MutexType2& m2) > { > return detail::try_lock_impl(m1, m2, detail::is_mutex_type_wrapper<is_mutex_type<MutexType1>::value>()); > } > > template <typename MutexType1, typename MutexType2> > typename detail::try_lock_impl_return<MutexType1>::type try_lock(const MutexType1& m1, const MutexType2& m2) > { > return detail::try_lock_impl(m1, m2, detail::is_mutex_type_wrapper<is_mutex_type<MutexType1>::value>()); > } > > template <typename MutexType1, typename MutexType2, typename MutexType3> > int try_lock(MutexType1& m1, MutexType2& m2, MutexType3& m3) > { > return ((int) detail::try_lock_internal(m1, m2, m3)) - 1; > } > > template <typename MutexType1, typename MutexType2, typename MutexType3, typename MutexType4> > int try_lock(MutexType1& m1, MutexType2& m2, MutexType3& m3, MutexType4& m4) > { > return ((int) detail::try_lock_internal(m1, m2, m3, m4)) - 1; > } > > template <typename MutexType1, typename MutexType2, typename MutexType3, typename MutexType4, typename MutexType5> > int try_lock(MutexType1& m1, MutexType2& m2, MutexType3& m3, MutexType4& m4, MutexType5& m5) > { > return ((int) detail::try_lock_internal(m1, m2, m3, m4, m5)) - 1; > } > > namespace detail > { > template <typename Iterator> > struct range_lock_guard > { > Iterator begin; > Iterator end; > > range_lock_guard(Iterator begin_, Iterator end_) : > begin(begin_), end(end_) > { > boost::lock(begin, end); > } > > void release() > { > begin = end; > } > > ~range_lock_guard() > { > for (; begin != end; ++begin) > { > begin->unlock(); > } > } > }; > > template <typename Iterator> > Iterator try_lock_impl(Iterator begin, Iterator end, is_mutex_type_wrapper<false> ) > > { > if (begin == end) > { > return end; > } > typedef typename std::iterator_traits<Iterator>::value_type lock_type; > unique_lock<lock_type> guard(*begin, try_to_lock); > > if (!guard.owns_lock()) > { > return begin; > } > Iterator const failed = boost::try_lock(++begin, end); > if (failed == end) > { > guard.release(); > } > > return failed; > } > } > > namespace detail > { > template <typename Iterator> > void lock_impl(Iterator begin, Iterator end, is_mutex_type_wrapper<false> ) > { > typedef typename std::iterator_traits<Iterator>::value_type lock_type; > > if (begin == end) > { > return; > } > bool start_with_begin = true; > Iterator second = begin; > ++second; > Iterator next = second; > > for (;;) > { > unique_lock<lock_type> begin_lock(*begin, defer_lock); > if (start_with_begin) > { > begin_lock.lock(); > Iterator const failed_lock = boost::try_lock(next, end); > if (failed_lock == end) > { > begin_lock.release(); > return; > } > start_with_begin = false; > next = failed_lock; > } > else > { > detail::range_lock_guard<Iterator> guard(next, end); > if (begin_lock.try_lock()) > { > Iterator const failed_lock = boost::try_lock(second, next); > if (failed_lock == next) > { > begin_lock.release(); > guard.release(); > return; > } > start_with_begin = false; > next = failed_lock; > } > else > { > start_with_begin = true; > next = second; > } > } > } > } > > } > >} ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 467 "/usr/include/boost/thread/lock_algorithms.hpp" 2 3 4 ># 11 "/usr/include/boost/thread/locks.hpp" 2 3 4 ># 22 "/usr/include/boost/thread.hpp" 2 3 4 > ># 1 "/usr/include/boost/thread/barrier.hpp" 1 3 4 ># 28 "/usr/include/boost/thread/barrier.hpp" 3 4 ># 1 "/usr/include/boost/utility/result_of.hpp" 1 3 4 ># 18 "/usr/include/boost/utility/result_of.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/repetition/enum_shifted_params.hpp" 1 3 4 ># 19 "/usr/include/boost/utility/result_of.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/facilities/intercept.hpp" 1 3 4 ># 20 "/usr/include/boost/utility/result_of.hpp" 2 3 4 ># 66 "/usr/include/boost/utility/result_of.hpp" 3 4 >namespace boost { > >template<typename F> struct result_of; >template<typename F> struct tr1_result_of; > > >namespace detail { > >template< typename T, typename fallback_ = boost::mpl::bool_<false> > struct has_result_type { struct gcc_3_2_wknd { template< typename U > static boost::mpl::aux::yes_tag test( boost::mpl::aux::type_wrapper<U> const volatile* , boost::mpl::aux::type_wrapper<typename U::result_type>* = 0 ); static boost::mpl::aux::no_tag test(...); }; typedef boost::mpl::aux::type_wrapper<T> t_; static const bool value = sizeof(gcc_3_2_wknd::test(static_cast<t_*>(0))) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_<value> type; }; > >template< typename T , typename fallback_ = boost::mpl::bool_< false > > class has_result { template< typename U > struct has_result_introspect { template< template< typename V0 > class V > struct has_result_substitute0 { }; template< template< typename V0 , typename V1 > class V > struct has_result_substitute1 { }; template< template< typename V0 , typename V1 , typename V2 > class V > struct has_result_substitute2 { }; template< template< typename V0 , typename V1 , typename V2 , typename V3 > class V > struct has_result_substitute3 { }; template< template< typename V0 , typename V1 , typename V2 , typename V3 , typename V4 > class V > struct has_result_substitute4 { }; template< typename V > static boost::mpl::aux::no_tag has_result_test(...); template< typename V > static boost::mpl::aux::yes_tag has_result_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_result_substitute0 < V::template result >* = 0 ); template< typename V > static boost::mpl::aux::yes_tag has_result_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_result_substitute1 < V::template result >* = 0 ); template< typename V > static boost::mpl::aux::yes_tag has_result_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_result_substitute2 < V::template result >* = 0 ); template< typename V > static boost::mpl::aux::yes_tag has_result_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_result_substitute3 < V::template result >* = 0 ); template< typename V > static boost::mpl::aux::yes_tag has_result_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_result_substitute4 < V::template result >* = 0 ); static const bool value = sizeof(has_result_test< U >(0)) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_< value > type; }; public: static const bool value = has_result_introspect< T >::value; typedef typename has_result_introspect< T >::type type; }; > >template<typename F, typename FArgs, bool HasResultType> struct tr1_result_of_impl; > >template<typename F> struct cpp0x_result_of; ># 140 "/usr/include/boost/utility/result_of.hpp" 3 4 >template<typename T> >struct result_of_always_void >{ > typedef void type; >}; > >template<typename F, typename Enable = void> struct cpp0x_result_of_impl {}; > > > >template<typename F> >struct result_of_void_impl >{ > typedef void type; >}; > >template<typename R> >struct result_of_void_impl<R (*)(void)> >{ > typedef R type; >}; > >template<typename R> >struct result_of_void_impl<R (&)(void)> >{ > typedef R type; >}; > > >template<typename F, typename FArgs> >struct result_of_pointer > : tr1_result_of_impl<typename remove_cv<F>::type, FArgs, false> { }; > >template<typename F, typename FArgs> >struct tr1_result_of_impl<F, FArgs, true> >{ > typedef typename F::result_type type; >}; > >template<typename FArgs> >struct is_function_with_no_args : mpl::false_ {}; > >template<typename F> >struct is_function_with_no_args<F(void)> : mpl::true_ {}; > >template<typename F, typename FArgs> >struct result_of_nested_result : F::template result<FArgs> >{}; > >template<typename F, typename FArgs> >struct tr1_result_of_impl<F, FArgs, false> > : mpl::if_<is_function_with_no_args<FArgs>, > result_of_void_impl<F>, > result_of_nested_result<F, FArgs> >::type >{}; > >} > > ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 25 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 27 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F > >struct tr1_result_of<F()> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type(), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F(), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F > >struct result_of<F()> > : detail::cpp0x_result_of<F()> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F > >struct cpp0x_result_of<F()> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type(), false > > > , detail::cpp0x_result_of_impl< > F() > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F > >struct cpp0x_result_of_impl<F(), > typename result_of_always_void<decltype( > boost::declval<F>()( > > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > > ) > ) type; >}; > > > >} ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0> >struct tr1_result_of<F( T0)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0> >struct result_of<F( T0)> > : detail::cpp0x_result_of<F( T0)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0> >struct cpp0x_result_of<F( T0)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0), false > > > , detail::cpp0x_result_of_impl< > F( T0) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0> >struct cpp0x_result_of_impl<F( T0), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0> >struct tr1_result_of_impl<R (*)( T0), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0> >struct tr1_result_of_impl<R (&)( T0), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0> >struct tr1_result_of_impl<R (T0::*) > (), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0> >struct tr1_result_of_impl<R (T0::*) > () > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0> >struct tr1_result_of_impl<R (T0::*) > () > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0> >struct tr1_result_of_impl<R (T0::*) > () > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1> >struct tr1_result_of<F( T0 , T1)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1> >struct result_of<F( T0 , T1)> > : detail::cpp0x_result_of<F( T0 , T1)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1> >struct cpp0x_result_of<F( T0 , T1)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1> >struct cpp0x_result_of_impl<F( T0 , T1), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1> >struct tr1_result_of_impl<R (*)( T0 , T1), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1> >struct tr1_result_of_impl<R (&)( T0 , T1), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1> >struct tr1_result_of_impl<R (T0::*) > ( T1), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1> >struct tr1_result_of_impl<R (T0::*) > ( T1) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1> >struct tr1_result_of_impl<R (T0::*) > ( T1) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1> >struct tr1_result_of_impl<R (T0::*) > ( T1) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 58 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2> >struct tr1_result_of<F( T0 , T1 , T2)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2> >struct result_of<F( T0 , T1 , T2)> > : detail::cpp0x_result_of<F( T0 , T1 , T2)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2> >struct cpp0x_result_of<F( T0 , T1 , T2)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2> >struct cpp0x_result_of_impl<F( T0 , T1 , T2), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 63 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3> >struct tr1_result_of<F( T0 , T1 , T2 , T3)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3> >struct result_of<F( T0 , T1 , T2 , T3)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 68 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct result_of<F( T0 , T1 , T2 , T3 , T4)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 73 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 78 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 83 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 88 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 93 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 98 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 103 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 108 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() , boost::declval<T12 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() , boost::declval<T12 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 113 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() , boost::declval<T12 >() , boost::declval<T13 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() , boost::declval<T12 >() , boost::declval<T13 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 118 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() , boost::declval<T12 >() , boost::declval<T13 >() , boost::declval<T14 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() , boost::declval<T12 >() , boost::declval<T13 >() , boost::declval<T14 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 123 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct tr1_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15)> > : mpl::if_< > mpl::or_< is_pointer<F>, is_member_function_pointer<F> > > , boost::detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15), > (boost::detail::has_result_type<F>::value)> > , boost::detail::tr1_result_of_impl< > F, > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15), > (boost::detail::has_result_type<F>::value)> >::type { }; > > > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15)> > : detail::cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15)> { }; ># 56 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct cpp0x_result_of<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15)> > : mpl::if_< > is_member_function_pointer<F> > , detail::tr1_result_of_impl< > typename remove_cv<F>::type, > typename remove_cv<F>::type( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15), false > > > , detail::cpp0x_result_of_impl< > F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15) > > > >::type >{}; ># 137 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >template<typename F , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct cpp0x_result_of_impl<F( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15), > typename result_of_always_void<decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() , boost::declval<T12 >() , boost::declval<T13 >() , boost::declval<T14 >() , boost::declval<T15 >() > ) > )>::type> { > typedef decltype( > boost::declval<F>()( > boost::declval<T0 >() , boost::declval<T1 >() , boost::declval<T2 >() , boost::declval<T3 >() , boost::declval<T4 >() , boost::declval<T5 >() , boost::declval<T6 >() , boost::declval<T7 >() , boost::declval<T8 >() , boost::declval<T9 >() , boost::declval<T10 >() , boost::declval<T11 >() , boost::declval<T12 >() , boost::declval<T13 >() , boost::declval<T14 >() , boost::declval<T15 >() > ) > ) type; >}; > > > >} ># 169 "/usr/include/boost/utility/detail/result_of_iterate.hpp" 3 4 >namespace detail { > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct tr1_result_of_impl<R (*)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15), FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct tr1_result_of_impl<R (&)( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15), FArgs, false> >{ > typedef R type; >}; > > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15), > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15) > const, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15) > volatile, > FArgs, false> >{ > typedef R type; >}; > >template<typename R, typename FArgs , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15> >struct tr1_result_of_impl<R (T0::*) > ( T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15) > const volatile, > FArgs, false> >{ > typedef R type; >}; > > >} ># 128 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 200 "/usr/include/boost/utility/result_of.hpp" 2 3 4 > > > > > >} ># 29 "/usr/include/boost/thread/barrier.hpp" 2 3 4 > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 31 "/usr/include/boost/thread/barrier.hpp" 2 3 4 > >namespace boost >{ > namespace thread_detail > { > > > > > typedef std::function<void()> void_completion_function; > typedef std::function<size_t()> size_completion_function; > > > struct default_barrier_reseter > { > unsigned int size_; > default_barrier_reseter(unsigned int size) : > size_(size) > { > } > unsigned int operator()() > { > return size_; > } > }; > > struct void_functor_barrier_reseter > { > unsigned int size_; > void_completion_function fct_; > template <typename F> > > void_functor_barrier_reseter(unsigned int size, F && funct) > : size_(size), fct_(boost::move(funct)) > {} > > > > > > unsigned int operator()() > { > fct_(); > return size_; > } > }; > struct void_fct_ptr_barrier_reseter > { > unsigned int size_; > void(*fct_)(); > void_fct_ptr_barrier_reseter(unsigned int size, void(*funct)()) : > size_(size), fct_(funct) > { > } > unsigned int operator()() > { > fct_(); > return size_; > } > }; > } > class barrier > { > static inline unsigned int check_counter(unsigned int count) > { > if (count == 0) boost::throw_exception( > thread_exception(system::errc::invalid_argument, "barrier constructor: count cannot be zero.")); > return count; > } > struct dummy > { > }; > > public: > barrier(barrier const&) = delete; barrier& operator=(barrier const&) = delete; > > explicit barrier(unsigned int count) : > m_count(check_counter(count)), m_generation(0), fct_(thread_detail::default_barrier_reseter(count)) > { > } > > template <typename F> > barrier( > unsigned int count, > > F && funct, > > > > typename enable_if< > typename is_void<typename result_of<F>::type>::type, dummy* > >::type=0 > ) > : m_count(check_counter(count)), > m_generation(0), > fct_(thread_detail::void_functor_barrier_reseter(count, > > boost::move(funct) > > > > ) > ) > { > } > > template <typename F> > barrier( > unsigned int count, > > F && funct, > > > > typename enable_if< > typename is_same<typename result_of<F>::type, unsigned int>::type, dummy* > >::type=0 > ) > : m_count(check_counter(count)), > m_generation(0), > fct_( > > boost::move(funct) > > > > ) > { > } > > barrier(unsigned int count, void(*funct)()) : > m_count(check_counter(count)), m_generation(0), > fct_(funct > ? thread_detail::size_completion_function(thread_detail::void_fct_ptr_barrier_reseter(count, funct)) > : thread_detail::size_completion_function(thread_detail::default_barrier_reseter(count)) > ) > { > } > barrier(unsigned int count, unsigned int(*funct)()) : > m_count(check_counter(count)), m_generation(0), > fct_(funct > ? thread_detail::size_completion_function(funct) > : thread_detail::size_completion_function(thread_detail::default_barrier_reseter(count)) > ) > { > } > > bool wait() > { > boost::unique_lock < boost::mutex > lock(m_mutex); > unsigned int gen = m_generation; > > if (--m_count == 0) > { > m_generation++; > m_count = static_cast<unsigned int>(fct_()); > (static_cast<void> (0)); > m_cond.notify_all(); > return true; > } > > while (gen == m_generation) > m_cond.wait(lock); > return false; > } > > void count_down_and_wait() > { > wait(); > } > > private: > mutex m_mutex; > condition_variable m_cond; > unsigned int m_count; > unsigned int m_generation; > thread_detail::size_completion_function fct_; > }; > >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 213 "/usr/include/boost/thread/barrier.hpp" 2 3 4 ># 24 "/usr/include/boost/thread.hpp" 2 3 4 ># 1 "/usr/include/boost/thread/future.hpp" 1 3 4 ># 22 "/usr/include/boost/thread/future.hpp" 3 4 ># 1 "/usr/include/boost/thread/detail/async_func.hpp" 1 3 4 ># 40 "/usr/include/boost/thread/detail/async_func.hpp" 3 4 >namespace boost >{ > namespace detail > { > > > > > template <class Fp, class ... Args> > class async_func > { > std::tuple<Fp, Args...> f_; > > public: > async_func(async_func const&) = delete; async_func& operator=(async_func const&) = delete; > > typedef typename result_of<Fp(Args...)>::type result_type; > > __attribute__((__visibility__("default"))) > explicit async_func(Fp && f, Args &&... args) > : f_(boost::move(f), boost::move(args)...) > {} > > __attribute__((__visibility__("default"))) > async_func(async_func && f) : f_(boost::move(f.f_)) > {} > > result_type operator()() > { > typedef typename make_tuple_indices<1+sizeof...(Args), 1>::type Index; > return execute(Index()); > } > private: > template <size_t ...Indices> > result_type > execute(tuple_indices<Indices...>) > { > return invoke(boost::move(std::get<0>(f_)), boost::move(std::get<Indices>(f_))...); > } > }; ># 568 "/usr/include/boost/thread/detail/async_func.hpp" 3 4 > } >} ># 23 "/usr/include/boost/thread/future.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/exception_ptr.hpp" 1 3 4 ># 9 "/usr/include/boost/exception_ptr.hpp" 3 4 ># 1 "/usr/include/boost/exception/detail/exception_ptr.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/detail/exception_ptr.hpp" 3 4 ># 10 "/usr/include/boost/exception/detail/exception_ptr.hpp" 3 ># 20 "/usr/include/boost/exception/detail/exception_ptr.hpp" 3 ># 1 "/usr/include/boost/exception/info.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/info.hpp" 3 4 ># 10 "/usr/include/boost/exception/info.hpp" 3 > > > > > > ># 1 "/usr/include/boost/exception/to_string_stub.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/to_string_stub.hpp" 3 4 ># 10 "/usr/include/boost/exception/to_string_stub.hpp" 3 > > > > > ># 1 "/usr/include/boost/exception/to_string.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/to_string.hpp" 3 4 ># 10 "/usr/include/boost/exception/to_string.hpp" 3 > > > > > > ># 1 "/usr/include/boost/exception/detail/is_output_streamable.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/detail/is_output_streamable.hpp" 3 4 ># 10 "/usr/include/boost/exception/detail/is_output_streamable.hpp" 3 > > > > > > > >namespace >boost > { > namespace > to_string_detail > { > struct > partial_ordering_helper1 > { > template <class CharT,class Traits> > partial_ordering_helper1( std::basic_ostream<CharT,Traits> & ); > }; > > struct > partial_ordering_helper2 > { > template <class T> > partial_ordering_helper2( T const & ); > }; > > char operator<<( partial_ordering_helper1, partial_ordering_helper2 ); > > template <class T,class CharT,class Traits> > struct > is_output_streamable_impl > { > static std::basic_ostream<CharT,Traits> & f(); > static T const & g(); > enum e { value=1!=(sizeof(f()<<g())) }; > }; > } > > template <class T, class CharT=char, class Traits=std::char_traits<CharT> > > struct > is_output_streamable > { > enum e { value=to_string_detail::is_output_streamable_impl<T,CharT,Traits>::value }; > }; > } ># 17 "/usr/include/boost/exception/to_string.hpp" 2 3 > > >namespace >boost > { > template <class T,class U> > std::string to_string( std::pair<T,U> const & ); > std::string to_string( std::exception const & ); > > namespace > to_string_detail > { > template <class T> > typename disable_if<is_output_streamable<T>,char>::type to_string( T const & ); > using boost::to_string; > > template <class,bool IsOutputStreamable> > struct has_to_string_impl; > > template <class T> > struct > has_to_string_impl<T,true> > { > enum e { value=1 }; > }; > > template <class T> > struct > has_to_string_impl<T,false> > { > static T const & f(); > enum e { value=1!=sizeof(to_string(f())) }; > }; > } > > template <class T> > inline > typename enable_if<is_output_streamable<T>,std::string>::type > to_string( T const & x ) > { > std::ostringstream out; > out << x; > return out.str(); > } > > template <class T> > struct > has_to_string > { > enum e { value=to_string_detail::has_to_string_impl<T,is_output_streamable<T>::value>::value }; > }; > > template <class T,class U> > inline > std::string > to_string( std::pair<T,U> 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(); > } > } ># 16 "/usr/include/boost/exception/to_string_stub.hpp" 2 3 ># 1 "/usr/include/boost/exception/detail/object_hex_dump.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/detail/object_hex_dump.hpp" 3 4 ># 10 "/usr/include/boost/exception/detail/object_hex_dump.hpp" 3 > > > > > ># 1 "/usr/include/boost/exception/detail/type_info.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/detail/type_info.hpp" 3 4 ># 10 "/usr/include/boost/exception/detail/type_info.hpp" 3 ># 23 "/usr/include/boost/exception/detail/type_info.hpp" 3 >namespace >boost > { > template <class T> > inline > std::string > tag_type_name() > { > > > > return (typeid(T*).name()); > > } > > template <class T> > inline > std::string > type_name() > { > > > > return (typeid(T).name()); > > } > > 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_)); > } > }; > } > } ># 16 "/usr/include/boost/exception/detail/object_hex_dump.hpp" 2 3 > > > > ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 21 "/usr/include/boost/exception/detail/object_hex_dump.hpp" 2 3 > >namespace >boost > { > namespace > exception_detail > { > template <class T> > inline > std::string > object_hex_dump( T const & x, std::size_t max_size=16 ) > { > std::ostringstream s; > s << "type: " << type_name<T>() << ", 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<unsigned char const *>(&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(); > } > } > } ># 17 "/usr/include/boost/exception/to_string_stub.hpp" 2 3 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 18 "/usr/include/boost/exception/to_string_stub.hpp" 2 3 > >namespace >boost > { > namespace > exception_detail > { > template <bool ToStringAvailable> > struct > to_string_dispatcher > { > template <class T,class Stub> > static > std::string > convert( T const & x, Stub ) > { > return to_string(x); > } > }; > > template <> > struct > to_string_dispatcher<false> > { > template <class T,class Stub> > static > std::string > convert( T const & x, Stub s ) > { > return s(x); > } > > template <class T> > static > std::string > convert( T const & x, std::string s ) > { > return s; > } > > template <class T> > static > std::string > convert( T const & x, char const * s ) > { > (static_cast<void> (0)); > return s; > } > }; > > namespace > to_string_dispatch > { > template <class T,class Stub> > inline > std::string > dispatch( T const & x, Stub s ) > { > return to_string_dispatcher<has_to_string<T>::value>::convert(x,s); > } > } > > template <class T> > inline > std::string > string_stub_dump( T const & x ) > { > return "[ " + exception_detail::object_hex_dump(x) + " ]"; > } > } > > template <class T> > inline > std::string > to_string_stub( T const & x ) > { > return exception_detail::to_string_dispatch::dispatch(x,&exception_detail::string_stub_dump<T>); > } > > template <class T,class Stub> > inline > std::string > to_string_stub( T const & x, Stub s ) > { > return exception_detail::to_string_dispatch::dispatch(x,s); > } > > template <class T,class U,class Stub> > inline > std::string > to_string_stub( std::pair<T,U> const & x, Stub s ) > { > return std::string("(") + to_string_stub(x.first,s) + ',' + to_string_stub(x.second,s) + ')'; > } > } ># 17 "/usr/include/boost/exception/info.hpp" 2 3 ># 1 "/usr/include/boost/exception/detail/error_info_impl.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/detail/error_info_impl.hpp" 3 4 ># 10 "/usr/include/boost/exception/detail/error_info_impl.hpp" 3 > > > > > > > >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 Tag,class T> > 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_; > }; > } ># 18 "/usr/include/boost/exception/info.hpp" 2 3 > > > > >namespace >boost > { > template <class Tag,class T> > inline > std::string > error_info_name( error_info<Tag,T> const & x ) > { > return tag_type_name<Tag>(); > } > > template <class Tag,class T> > inline > std::string > to_string( error_info<Tag,T> const & x ) > { > return '[' + error_info_name(x) + "] = " + to_string_stub(x.value()) + '\n'; > } > > template <class Tag,class T> > inline > error_info<Tag,T>:: > error_info( value_type const & value ): > value_(value) > { > } > > template <class Tag,class T> > inline > error_info<Tag,T>:: > ~error_info() throw() > { > } > > template <class Tag,class T> > inline > std::string > error_info<Tag,T>:: > 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<error_info_base> const & x, type_info_ const & typeid_ ) > { > (static_cast<void> (0)); > info_[typeid_] = x; > diagnostic_info_str_.clear(); > } > > shared_ptr<error_info_base> > get( type_info_ const & ti ) const > { > error_info_map::const_iterator i=info_.find(ti); > if( info_.end()!=i ) > { > shared_ptr<error_info_base> const & p = i->second; > > (static_cast<void> (0)); > > return p; > } > return shared_ptr<error_info_base>(); > } > > 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_base> > 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<error_info_container> > clone() const > { > refcount_ptr<error_info_container> p; > error_info_container_impl * c=new error_info_container_impl; > p.adopt(c); > c->info_ = info_; > return p; > } > }; > > template <class E,class Tag,class T> > inline > E const & > set_info( E const & x, error_info<Tag,T> const & v ) > { > typedef error_info<Tag,T> error_info_tag_t; > shared_ptr<error_info_tag_t> 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_detail::type_info_(typeid(error_info_tag_t))); > return x; > } > > template <class T> > struct > derives_boost_exception > { > enum e { value = (sizeof(dispatch_boost_exception((T*)0))==sizeof(large_size)) }; > }; > } > > template <class E,class Tag,class T> > inline > typename enable_if<exception_detail::derives_boost_exception<E>,E const &>::type > operator<<( E const & x, error_info<Tag,T> const & v ) > { > return exception_detail::set_info(x,v); > } > } ># 21 "/usr/include/boost/exception/detail/exception_ptr.hpp" 2 3 ># 1 "/usr/include/boost/exception/diagnostic_information.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/diagnostic_information.hpp" 3 4 ># 10 "/usr/include/boost/exception/diagnostic_information.hpp" 3 > > > > > > ># 1 "/usr/include/boost/exception/get_error_info.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/get_error_info.hpp" 3 4 ># 10 "/usr/include/boost/exception/get_error_info.hpp" 3 ># 20 "/usr/include/boost/exception/get_error_info.hpp" 3 >namespace >boost > { > namespace > exception_detail > { > template <class ErrorInfo> > 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<exception_detail::error_info_base> eib = c->get(::boost::exception_detail::type_info_(typeid(ErrorInfo))) ) > { > > (static_cast<void> (0)); > > ErrorInfo * w = static_cast<ErrorInfo *>(eib.get()); > return &w->value(); > } > return 0; > } > }; > > template <> > struct > get_info<throw_function> > { > static > char const * * > get( exception const & x ) > { > return x.throw_function_ ? &x.throw_function_ : 0; > } > }; > > template <> > struct > get_info<throw_file> > { > static > char const * * > get( exception const & x ) > { > return x.throw_file_ ? &x.throw_file_ : 0; > } > }; > > template <> > struct > get_info<throw_line> > { > static > int * > get( exception const & x ) > { > return x.throw_line_!=-1 ? &x.throw_line_ : 0; > } > }; > > template <class T,class R> > struct > get_error_info_return_type > { > typedef R * type; > }; > > template <class T,class R> > struct > get_error_info_return_type<T const,R> > { > typedef R const * type; > }; > } ># 114 "/usr/include/boost/exception/get_error_info.hpp" 3 > template <class ErrorInfo,class E> > inline > typename exception_detail::get_error_info_return_type<E,typename ErrorInfo::value_type>::type > get_error_info( E & some_exception ) > { > if( exception const * x = dynamic_cast<exception const *>(&some_exception) ) > return exception_detail::get_info<ErrorInfo>::get(*x); > else > return 0; > } > > } ># 17 "/usr/include/boost/exception/diagnostic_information.hpp" 2 3 ># 27 "/usr/include/boost/exception/diagnostic_information.hpp" 3 ># 1 "/usr/include/boost/exception/current_exception_cast.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/current_exception_cast.hpp" 3 4 ># 10 "/usr/include/boost/exception/current_exception_cast.hpp" 3 > > > > > >namespace >boost > { > template <class E> > inline > E * > current_exception_cast() > { > try > { > throw; > } > catch( > E & e ) > { > return &e; > } > catch( > ...) > { > return 0; > } > } > } ># 28 "/usr/include/boost/exception/diagnostic_information.hpp" 2 3 >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<boost::exception const>(); > std::exception const * se=current_exception_cast<std::exception const>(); > if( be || se ) > return exception_detail::diagnostic_information_impl(be,se,true,verbose); > else > return "No diagnostic information available."; > } > } > > >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 ) > { > > try > { > > 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); > (static_cast<void> (0)); > return di; > > } > catch(...) > { > return 0; > } > > } > > 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."; > > if( !be ) > be=dynamic_cast<boost::exception const *>(se); > if( !se ) > se=dynamic_cast<std::exception const *>(be); > > 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<throw_file>(*be); > int const * l=get_error_info<throw_line>(*be); > char const * const * fn=get_error_info<throw_function>(*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<throw_line>(*be) ) > tmp << '(' << *l << "): "; > } > tmp << "Throw in function "; > if( char const * const * fn=get_error_info<throw_function>(*be) ) > tmp << *fn; > else > tmp << "(unknown)"; > tmp << '\n'; > } > } > > if ( verbose ) > tmp << std::string("Dynamic exception type: ") << > ((be?(::boost::exception_detail::type_info_(typeid(*be))):(::boost::exception_detail::type_info_(typeid(*se)))).type_->name()) << '\n'; > > 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 <class T> > 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; > > try > { > > (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()"; > > } > catch( > ... ) > { > } > > return w; > } > } ># 22 "/usr/include/boost/exception/detail/exception_ptr.hpp" 2 3 > ># 1 "/usr/include/boost/exception/detail/clone_current_exception.hpp" 1 3 4 ># 9 "/usr/include/boost/exception/detail/clone_current_exception.hpp" 3 4 ># 10 "/usr/include/boost/exception/detail/clone_current_exception.hpp" 3 ># 19 "/usr/include/boost/exception/detail/clone_current_exception.hpp" 3 >namespace >boost > { > namespace > exception_detail > { > class clone_base; > > > > > > 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 ) > { > > > > return clone_current_exception_result::not_supported; > > } > } > } ># 24 "/usr/include/boost/exception/detail/exception_ptr.hpp" 2 3 ># 33 "/usr/include/boost/exception/detail/exception_ptr.hpp" 3 >namespace >boost > { > class exception_ptr; > __attribute__((__noreturn__)) void rethrow_exception( exception_ptr const & ); > exception_ptr current_exception(); > > class > exception_ptr > { > typedef boost::shared_ptr<exception_detail::clone_base const> 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 <class T> > inline > exception_ptr > copy_exception( T const & e ) > { > try > { > throw enable_current_exception(e); > } > catch( > ... ) > { > return current_exception(); > } > } > > > typedef error_info<struct tag_original_exception_type,std::type_info const *> original_exception_type; > > inline > std::string > to_string( original_exception_type const & x ) > { > return (x.value()->name()); > } > > > 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 <class Exception> > exception_ptr > get_static_exception_object() > { > Exception ba; > exception_detail::clone_impl<Exception> c(ba); > > c << > throw_function(__PRETTY_FUNCTION__) << > throw_file("/usr/include/boost/exception/detail/exception_ptr.hpp") << > throw_line(128); > > static exception_ptr ep(shared_ptr<exception_detail::clone_base const>(new exception_detail::clone_impl<Exception>(c))); > return ep; > } > > template <class Exception> > struct > exception_ptr_static_exception_object > { > static exception_ptr const e; > }; > > template <class Exception> > exception_ptr const > exception_ptr_static_exception_object<Exception>:: > e = get_static_exception_object<Exception>(); > } > > > >#pragma GCC visibility push (default) > > > 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 <class E> > void > add_original_type( E const & e ) > { > > (*this) << original_exception_type(&typeid(e)); > > } > }; > > >#pragma GCC visibility pop > > > > namespace > exception_detail > { > template <class T> > 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 <class E> > void > add_original_type( E const & e ) > { > > (*this) << original_exception_type(&typeid(e)); > > } > }; ># 258 "/usr/include/boost/exception/detail/exception_ptr.hpp" 3 > template <class T> > boost::exception const * > get_boost_exception( T const * x ) > { > return dynamic_cast<boost::exception const *>(x); > } > > > template <class T> > 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<T>(e1,*e2)); > else > return boost::copy_exception(current_exception_std_exception_wrapper<T>(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: > { > (static_cast<void> (0)); > return exception_ptr(shared_ptr<exception_detail::clone_base const>(e)); > } > case exception_detail::clone_current_exception_result:: > bad_alloc: > { > (static_cast<void> (0)); > return exception_detail::exception_ptr_static_exception_object<bad_alloc_>::e; > } > case exception_detail::clone_current_exception_result:: > bad_exception: > { > (static_cast<void> (0)); > return exception_detail::exception_ptr_static_exception_object<bad_exception_>::e; > } > default: > (static_cast<void> (0)); > case exception_detail::clone_current_exception_result:: > not_supported: > { > (static_cast<void> (0)); > try > { > throw; > } > catch( > exception_detail::clone_base & e ) > { > return exception_ptr(shared_ptr<exception_detail::clone_base const>(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); > } > > 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); > } > > 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<exception_detail::bad_alloc_>::e; > } > catch( > ... ) > { > ret=exception_detail::exception_ptr_static_exception_object<exception_detail::bad_exception_>::e; > } > (static_cast<void> (0)); > return ret; > } > > __attribute__((__noreturn__)) > inline > void > rethrow_exception( exception_ptr const & p ) > { > (static_cast<void> (0)); > p.ptr_->rethrow(); > (static_cast<void> (0)); > > > > > abort(); > > } > > 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 "<empty>"; > } > > 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; > } > } ># 10 "/usr/include/boost/exception_ptr.hpp" 2 3 4 ># 29 "/usr/include/boost/thread/future.hpp" 2 3 4 > ># 1 "/usr/include/boost/scoped_ptr.hpp" 1 3 4 ># 14 "/usr/include/boost/scoped_ptr.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/scoped_ptr.hpp" 1 3 4 ># 15 "/usr/include/boost/smart_ptr/scoped_ptr.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 16 "/usr/include/boost/smart_ptr/scoped_ptr.hpp" 2 3 4 ># 24 "/usr/include/boost/smart_ptr/scoped_ptr.hpp" 3 4 >namespace boost >{ ># 41 "/usr/include/boost/smart_ptr/scoped_ptr.hpp" 3 4 >template<class T> class scoped_ptr >{ >private: > > T * px; > > scoped_ptr(scoped_ptr const &); > scoped_ptr & operator=(scoped_ptr const &); > > typedef scoped_ptr<T> this_type; > > void operator==( scoped_ptr const& ) const; > void operator!=( scoped_ptr const& ) const; > >public: > > typedef T element_type; > > explicit scoped_ptr( T * p = 0 ): px( p ) > { > > > > } > > > > explicit scoped_ptr( std::auto_ptr<T> p ) noexcept : px( p.release() ) > { > > > > } > > > > ~scoped_ptr() > { > > > > boost::checked_delete( px ); > } > > void reset(T * p = 0) > { > (static_cast<void> (0)); > this_type(p).swap(*this); > } > > T & operator*() const > { > (static_cast<void> (0)); > return *px; > } > > T * operator->() const > { > (static_cast<void> (0)); > return px; > } > > T * get() const noexcept > { > return px; > } > > ># 1 "/usr/include/boost/smart_ptr/detail/operator_bool.hpp" 1 3 4 ># 11 "/usr/include/boost/smart_ptr/detail/operator_bool.hpp" 3 4 > explicit operator bool () const noexcept > { > return px != 0; > } ># 60 "/usr/include/boost/smart_ptr/detail/operator_bool.hpp" 3 4 > bool operator! () const noexcept > { > return px == 0; > } ># 110 "/usr/include/boost/smart_ptr/scoped_ptr.hpp" 2 3 4 > > void swap(scoped_ptr & b) noexcept > { > T * tmp = b.px; > b.px = px; > px = tmp; > } >}; > > > >template<class T> inline bool operator==( scoped_ptr<T> const & p, boost::detail::sp_nullptr_t ) noexcept >{ > return p.get() == 0; >} > >template<class T> inline bool operator==( boost::detail::sp_nullptr_t, scoped_ptr<T> const & p ) noexcept >{ > return p.get() == 0; >} > >template<class T> inline bool operator!=( scoped_ptr<T> const & p, boost::detail::sp_nullptr_t ) noexcept >{ > return p.get() != 0; >} > >template<class T> inline bool operator!=( boost::detail::sp_nullptr_t, scoped_ptr<T> const & p ) noexcept >{ > return p.get() != 0; >} > > > >template<class T> inline void swap(scoped_ptr<T> & a, scoped_ptr<T> & b) noexcept >{ > a.swap(b); >} > > > >template<class T> inline T * get_pointer(scoped_ptr<T> const & p) noexcept >{ > return p.get(); >} > >} ># 15 "/usr/include/boost/scoped_ptr.hpp" 2 3 4 ># 31 "/usr/include/boost/thread/future.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_fundamental.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/is_fundamental.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/is_fundamental.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct is_fundamental_impl > : public ::boost::type_traits::ice_or< > ::boost::is_arithmetic<T>::value > , ::boost::is_void<T>::value > > >{ >}; > >} > > > > > >template< typename T > struct is_fundamental : public ::boost::integral_constant<bool,::boost::detail::is_fundamental_impl<T>::value> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 44 "/usr/include/boost/type_traits/is_fundamental.hpp" 2 3 4 ># 32 "/usr/include/boost/thread/future.hpp" 2 3 4 ># 40 "/usr/include/boost/thread/future.hpp" 3 4 ># 1 "/usr/include/boost/function.hpp" 1 3 4 ># 15 "/usr/include/boost/function.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iterate.hpp" 1 3 4 ># 16 "/usr/include/boost/function.hpp" 2 3 4 ># 24 "/usr/include/boost/function.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/prologue.hpp" 1 3 4 ># 12 "/usr/include/boost/function/detail/prologue.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cassert" 1 3 4 ># 41 "/usr/include/c++/4.9.0/cassert" 3 4 ># 42 "/usr/include/c++/4.9.0/cassert" 3 > ># 1 "/usr/include/assert.h" 1 3 4 ># 43 "/usr/include/c++/4.9.0/cassert" 2 3 ># 13 "/usr/include/boost/function/detail/prologue.hpp" 2 3 4 > ># 1 "/usr/include/boost/config/no_tr1/functional.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/prologue.hpp" 2 3 4 > > ># 1 "/usr/include/boost/function/function_base.hpp" 1 3 4 ># 20 "/usr/include/boost/function/function_base.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 21 "/usr/include/boost/function/function_base.hpp" 2 3 4 ># 1 "/usr/include/boost/integer.hpp" 1 3 4 ># 22 "/usr/include/boost/integer.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 23 "/usr/include/boost/integer.hpp" 2 3 4 ># 34 "/usr/include/boost/integer.hpp" 3 4 ># 35 "/usr/include/boost/integer.hpp" 3 > > >namespace boost >{ > > > > > > template< typename LeastInt > > struct int_fast_t > { > typedef LeastInt fast; > typedef fast type; > }; > > namespace detail{ > > > template< int Category > struct int_least_helper {}; > template< int Category > struct uint_least_helper {}; > > > > > > template<> struct int_least_helper<1> { typedef boost::long_long_type least; }; > > > > 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; }; > > template<> struct uint_least_helper<1> { typedef boost::ulong_long_type least; }; > > > > 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 <int Bits> > struct exact_signed_base_helper{}; > template <int Bits> > struct exact_unsigned_base_helper{}; > > template <> struct exact_signed_base_helper<sizeof(signed char)* 8> { typedef signed char exact; }; > template <> struct exact_unsigned_base_helper<sizeof(unsigned char)* 8> { typedef unsigned char exact; }; > > template <> struct exact_signed_base_helper<sizeof(short)* 8> { typedef short exact; }; > template <> struct exact_unsigned_base_helper<sizeof(unsigned short)* 8> { typedef unsigned short exact; }; > > > template <> struct exact_signed_base_helper<sizeof(int)* 8> { typedef int exact; }; > template <> struct exact_unsigned_base_helper<sizeof(unsigned int)* 8> { typedef unsigned int exact; }; > > > template <> struct exact_signed_base_helper<sizeof(long)* 8> { typedef long exact; }; > template <> struct exact_unsigned_base_helper<sizeof(unsigned long)* 8> { typedef unsigned long exact; }; ># 108 "/usr/include/boost/integer.hpp" 3 > } > > > > > template< int Bits > > struct int_t : public detail::exact_signed_base_helper<Bits> > { > static_assert(Bits <= (int)(sizeof(boost::intmax_t) * 8), "No suitable signed integer type with the requested number of bits is available.") > ; > typedef typename detail::int_least_helper > < > > (Bits <= (int)(sizeof(boost::long_long_type) * 8)) + > > > > (Bits-1 <= ::std::numeric_limits<long>::digits) + > (Bits-1 <= ::std::numeric_limits<int>::digits) + > (Bits-1 <= ::std::numeric_limits<short>::digits) + > (Bits-1 <= ::std::numeric_limits<signed char>::digits) > >::least least; > typedef typename int_fast_t<least>::type fast; > }; > > > template< int Bits > > struct uint_t : public detail::exact_unsigned_base_helper<Bits> > { > static_assert(Bits <= (int)(sizeof(boost::uintmax_t) * 8), "No suitable unsigned integer type with the requested number of bits is available.") > ; ># 149 "/usr/include/boost/integer.hpp" 3 > typedef typename detail::uint_least_helper > < > > (Bits <= (int)(sizeof(boost::long_long_type) * 8)) + > > > > (Bits <= ::std::numeric_limits<unsigned long>::digits) + > (Bits <= ::std::numeric_limits<unsigned int>::digits) + > (Bits <= ::std::numeric_limits<unsigned short>::digits) + > (Bits <= ::std::numeric_limits<unsigned char>::digits) > >::least least; > > typedef typename int_fast_t<least>::type fast; > > }; > > > > > > template< boost::long_long_type MaxValue > > > > > struct int_max_value_t > { > typedef typename detail::int_least_helper > < > > (MaxValue <= ::boost::integer_traits<boost::long_long_type>::const_max) + > > > > (MaxValue <= ::boost::integer_traits<long>::const_max) + > (MaxValue <= ::boost::integer_traits<int>::const_max) + > (MaxValue <= ::boost::integer_traits<short>::const_max) + > (MaxValue <= ::boost::integer_traits<signed char>::const_max) > >::least least; > typedef typename int_fast_t<least>::type fast; > }; > > > template< boost::long_long_type MinValue > > > > > struct int_min_value_t > { > typedef typename detail::int_least_helper > < > > (MinValue >= ::boost::integer_traits<boost::long_long_type>::const_min) + > > > > (MinValue >= ::boost::integer_traits<long>::const_min) + > (MinValue >= ::boost::integer_traits<int>::const_min) + > (MinValue >= ::boost::integer_traits<short>::const_min) + > (MinValue >= ::boost::integer_traits<signed char>::const_min) > >::least least; > typedef typename int_fast_t<least>::type fast; > }; > > > > template< boost::ulong_long_type MaxValue > > > > > struct uint_value_t > { ># 242 "/usr/include/boost/integer.hpp" 3 > typedef typename detail::uint_least_helper > < > > (MaxValue <= ::boost::integer_traits<boost::ulong_long_type>::const_max) + > > > > (MaxValue <= ::boost::integer_traits<unsigned long>::const_max) + > (MaxValue <= ::boost::integer_traits<unsigned int>::const_max) + > (MaxValue <= ::boost::integer_traits<unsigned short>::const_max) + > (MaxValue <= ::boost::integer_traits<unsigned char>::const_max) > >::least least; > > typedef typename int_fast_t<least>::type fast; > }; > > >} ># 22 "/usr/include/boost/function/function_base.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/type_traits/composite_traits.hpp" 1 3 4 ># 22 "/usr/include/boost/type_traits/composite_traits.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_union.hpp" 1 3 4 ># 19 "/usr/include/boost/type_traits/is_union.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 20 "/usr/include/boost/type_traits/is_union.hpp" 2 3 4 > >namespace boost { > >namespace detail { ># 40 "/usr/include/boost/type_traits/is_union.hpp" 3 4 >template <typename T> struct is_union_impl >{ > > static const bool value = __is_union(T); > > > >}; > >} > >template< typename T > struct is_union : public ::boost::integral_constant<bool,::boost::detail::is_union_impl<T>::value> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 56 "/usr/include/boost/type_traits/is_union.hpp" 2 3 4 ># 23 "/usr/include/boost/type_traits/composite_traits.hpp" 2 3 4 ># 28 "/usr/include/boost/function/function_base.hpp" 2 3 4 ># 38 "/usr/include/boost/function/function_base.hpp" 3 4 ># 1 "/usr/include/boost/function_equal.hpp" 1 3 4 ># 13 "/usr/include/boost/function_equal.hpp" 3 4 >namespace boost { > >template<typename F, typename G> > bool function_equal_impl(const F& f, const G& g, long) > { return f == g; } > > > > >template<typename F, typename G> > bool function_equal(const F& f, const G& g) > { return function_equal_impl(f, g, 0); } > >} ># 39 "/usr/include/boost/function/function_base.hpp" 2 3 4 ># 1 "/usr/include/boost/function/function_fwd.hpp" 1 3 4 ># 28 "/usr/include/boost/function/function_fwd.hpp" 3 4 >namespace boost { > class bad_function_call; > > > > template<typename Signature> class function; > > template<typename Signature> > inline void swap(function<Signature>& f1, function<Signature>& f2) > { > f1.swap(f2); > } > > > > template<typename R> class function0; > template<typename R, typename T1> class function1; > template<typename R, typename T1, typename T2> class function2; > template<typename R, typename T1, typename T2, typename T3> class function3; > template<typename R, typename T1, typename T2, typename T3, typename T4> > class function4; > template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5> > class function5; > template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6> > class function6; > template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6, typename T7> > class function7; > template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6, typename T7, typename T8> > class function8; > template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6, typename T7, typename T8, typename T9> > class function9; > template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6, typename T7, typename T8, typename T9, > typename T10> > class function10; >} ># 40 "/usr/include/boost/function/function_base.hpp" 2 3 4 ># 62 "/usr/include/boost/function/function_base.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 63 "/usr/include/boost/function/function_base.hpp" 2 3 4 ># 89 "/usr/include/boost/function/function_base.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > class X; > > > > > > > > union function_buffer > { > > mutable void* obj_ptr; > > > struct type_t { > > const detail::sp_typeinfo* type; > > > bool const_qualified; > > bool volatile_qualified; > } type; > > > mutable void (*func_ptr)(); > > > struct bound_memfunc_ptr_t { > void (X::*memfunc_ptr)(int); > void* obj_ptr; > } bound_memfunc_ptr; > > > > struct obj_ref_t { > mutable void* obj_ptr; > bool is_const_qualified; > bool is_volatile_qualified; > } obj_ref; > > > mutable char data; > }; > > > > > > > > struct unusable > { > unusable() {} > template<typename T> unusable(const T&) {} > }; > > > > > > template<typename T> struct function_return_type { typedef T type; }; > > template<> > struct function_return_type<void> > { > typedef unusable type; > }; > > > enum functor_manager_operation_type { > clone_functor_tag, > move_functor_tag, > destroy_functor_tag, > check_functor_type_tag, > get_functor_type_tag > }; > > > struct function_ptr_tag {}; > struct function_obj_tag {}; > struct member_ptr_tag {}; > struct function_obj_ref_tag {}; > > template<typename F> > class get_function_tag > { > typedef typename mpl::if_c<(is_pointer<F>::value), > function_ptr_tag, > function_obj_tag>::type ptr_or_obj_tag; > > typedef typename mpl::if_c<(is_member_pointer<F>::value), > member_ptr_tag, > ptr_or_obj_tag>::type ptr_or_obj_or_mem_tag; > > typedef typename mpl::if_c<(is_reference_wrapper<F>::value), > function_obj_ref_tag, > ptr_or_obj_or_mem_tag>::type or_ref_tag; > > public: > typedef or_ref_tag type; > }; > > > > template<typename F> > 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; > > > > if ((std::strcmp((check_type).name(),(typeid(F)).name()) == 0) > && (!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 = &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; > } > } > }; > > > > > > template<typename F> > struct function_allows_small_object_optimization > { > static const bool value = ((sizeof(F) <= sizeof(function_buffer) && (alignment_of<function_buffer>::value % alignment_of<F>::value == 0))) > > > > ; > }; > > template <typename F,typename A> > 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<const F&>(f)), > A(static_cast<const A&>(f)) > { > } > }; > > > > > > template<typename Functor> > struct functor_manager_common > { > typedef Functor functor_type; > > > 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 ((std::strcmp((check_type).name(),(typeid(Functor)).name()) == 0)) > out_buffer.obj_ptr = &in_buffer.func_ptr; > else > out_buffer.obj_ptr = 0; > } else { > out_buffer.type.type = &typeid(Functor); > out_buffer.type.const_qualified = false; > out_buffer.type.volatile_qualified = false; > } > } > > > 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<const functor_type*>(&in_buffer.data); > new (reinterpret_cast<void*>(&out_buffer.data)) functor_type(*in_functor); > > if (op == move_functor_tag) { > functor_type* f = reinterpret_cast<functor_type*>(&in_buffer.data); > (void)f; > f->~Functor(); > } > } else if (op == destroy_functor_tag) { > > functor_type* f = reinterpret_cast<functor_type*>(&out_buffer.data); > (void)f; > f->~Functor(); > } else if (op == check_functor_type_tag) { > const detail::sp_typeinfo& check_type > = *out_buffer.type.type; > if ((std::strcmp((check_type).name(),(typeid(Functor)).name()) == 0)) > out_buffer.obj_ptr = &in_buffer.data; > else > out_buffer.obj_ptr = 0; > } else { > out_buffer.type.type = &typeid(Functor); > out_buffer.type.const_qualified = false; > out_buffer.type.volatile_qualified = false; > } > } > }; > > template<typename Functor> > struct functor_manager > { > private: > typedef Functor functor_type; > > > static inline void > manager(const function_buffer& in_buffer, function_buffer& out_buffer, > functor_manager_operation_type op, function_ptr_tag) > { > functor_manager_common<Functor>::manage_ptr(in_buffer,out_buffer,op); > } > > > static inline void > manager(const function_buffer& in_buffer, function_buffer& out_buffer, > functor_manager_operation_type op, mpl::true_) > { > functor_manager_common<Functor>::manage_small(in_buffer,out_buffer,op); > } > > > 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) { > > > > > > const functor_type* f = > static_cast<const functor_type*>(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) { > > functor_type* f = > static_cast<functor_type*>(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 ((std::strcmp((check_type).name(),(typeid(Functor)).name()) == 0)) > out_buffer.obj_ptr = in_buffer.obj_ptr; > else > out_buffer.obj_ptr = 0; > } else { > out_buffer.type.type = &typeid(Functor); > out_buffer.type.const_qualified = false; > out_buffer.type.volatile_qualified = false; > } > } > > > > > 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<functor_type>::value)>()); > } > > > 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: > > > static inline void > manage(const function_buffer& in_buffer, function_buffer& out_buffer, > functor_manager_operation_type op) > { > typedef typename get_function_tag<functor_type>::type tag_type; > switch (op) { > case get_functor_type_tag: > out_buffer.type.type = &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<typename Functor, typename Allocator> > struct functor_manager_a > { > private: > typedef Functor functor_type; > > > static inline void > manager(const function_buffer& in_buffer, function_buffer& out_buffer, > functor_manager_operation_type op, function_ptr_tag) > { > functor_manager_common<Functor>::manage_ptr(in_buffer,out_buffer,op); > } > > > static inline void > manager(const function_buffer& in_buffer, function_buffer& out_buffer, > functor_manager_operation_type op, mpl::true_) > { > functor_manager_common<Functor>::manage_small(in_buffer,out_buffer,op); > } > > > static inline void > manager(const function_buffer& in_buffer, function_buffer& out_buffer, > functor_manager_operation_type op, mpl::false_) > { > typedef functor_wrapper<Functor,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::other > wrapper_allocator_type; > typedef typename wrapper_allocator_type::pointer wrapper_allocator_pointer_type; > > if (op == clone_functor_tag) { > > > > const functor_wrapper_type* f = > static_cast<const functor_wrapper_type*>(in_buffer.obj_ptr); > wrapper_allocator_type wrapper_allocator(static_cast<Allocator const &>(*f)); > wrapper_allocator_pointer_type copy = wrapper_allocator.allocate(1); > wrapper_allocator.construct(copy, *f); > > > functor_wrapper_type* new_f = static_cast<functor_wrapper_type*>(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) { > > functor_wrapper_type* victim = > static_cast<functor_wrapper_type*>(in_buffer.obj_ptr); > wrapper_allocator_type wrapper_allocator(static_cast<Allocator const &>(*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 ((std::strcmp((check_type).name(),(typeid(Functor)).name()) == 0)) > out_buffer.obj_ptr = in_buffer.obj_ptr; > else > out_buffer.obj_ptr = 0; > } else { > out_buffer.type.type = &typeid(Functor); > out_buffer.type.const_qualified = false; > out_buffer.type.volatile_qualified = false; > } > } > > > > > 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<functor_type>::value)>()); > } > > public: > > > static inline void > manage(const function_buffer& in_buffer, function_buffer& out_buffer, > functor_manager_operation_type op) > { > typedef typename get_function_tag<functor_type>::type tag_type; > switch (op) { > case get_functor_type_tag: > out_buffer.type.type = &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; > } > } > }; > > > struct useless_clear_type {}; ># 615 "/usr/include/boost/function/function_base.hpp" 3 4 > struct vtable_base > { > void (*manager)(const function_buffer& in_buffer, > function_buffer& out_buffer, > functor_manager_operation_type op); > }; > } > } > > > > > > > >class function_base >{ >public: > function_base() : vtable(0) { } > > > bool empty() const { return !vtable; } > > > > const detail::sp_typeinfo& target_type() const > { > if (!vtable) return typeid(void); > > detail::function::function_buffer type; > get_vtable()->manager(functor, type, detail::function::get_functor_type_tag); > return *type.type.type; > } > > template<typename Functor> > Functor* target() > { > if (!vtable) return 0; > > detail::function::function_buffer type_result; > type_result.type.type = &typeid(Functor); > type_result.type.const_qualified = is_const<Functor>::value; > type_result.type.volatile_qualified = is_volatile<Functor>::value; > get_vtable()->manager(functor, type_result, > detail::function::check_functor_type_tag); > return static_cast<Functor*>(type_result.obj_ptr); > } > > template<typename Functor> > > > > const Functor* target() const > > { > if (!vtable) return 0; > > detail::function::function_buffer type_result; > type_result.type.type = &typeid(Functor); > type_result.type.const_qualified = true; > type_result.type.volatile_qualified = is_volatile<Functor>::value; > get_vtable()->manager(functor, type_result, > detail::function::check_functor_type_tag); > > > return static_cast<const Functor*>(type_result.obj_ptr); > } > > template<typename F> > bool contains(const F& f) const > { > > > > if (const F* fp = this->template target<F>()) > > { > return function_equal(*fp, f); > } else { > return false; > } > } ># 721 "/usr/include/boost/function/function_base.hpp" 3 4 >public: > detail::function::vtable_base* get_vtable() const { > return reinterpret_cast<detail::function::vtable_base*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > bool has_trivial_copy_and_destroy() const { > return reinterpret_cast<std::size_t>(vtable) & 0x01; > } > > detail::function::vtable_base* vtable; > mutable detail::function::function_buffer functor; >}; > > > > > >class bad_function_call : public std::runtime_error >{ >public: > bad_function_call() : std::runtime_error("call to empty boost::function") {} >}; > > >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(); >} ># 806 "/usr/include/boost/function/function_base.hpp" 3 4 >template<typename Functor> > typename ::boost::enable_if_c<(::boost::type_traits::ice_not< (::boost::is_integral<Functor>::value)>::value), bool>::type > operator==(const function_base& f, Functor g) > { > if (const Functor* fp = f.template target<Functor>()) > return function_equal(*fp, g); > else return false; > } > >template<typename Functor> > typename ::boost::enable_if_c<(::boost::type_traits::ice_not< (::boost::is_integral<Functor>::value)>::value), bool>::type > operator==(Functor g, const function_base& f) > { > if (const Functor* fp = f.template target<Functor>()) > return function_equal(g, *fp); > else return false; > } > >template<typename Functor> > typename ::boost::enable_if_c<(::boost::type_traits::ice_not< (::boost::is_integral<Functor>::value)>::value), bool>::type > operator!=(const function_base& f, Functor g) > { > if (const Functor* fp = f.template target<Functor>()) > return !function_equal(*fp, g); > else return true; > } > >template<typename Functor> > typename ::boost::enable_if_c<(::boost::type_traits::ice_not< (::boost::is_integral<Functor>::value)>::value), bool>::type > operator!=(Functor g, const function_base& f) > { > if (const Functor* fp = f.template target<Functor>()) > return !function_equal(g, *fp); > else return true; > } > > >template<typename Functor> > typename ::boost::enable_if_c<(::boost::type_traits::ice_not< (::boost::is_integral<Functor>::value)>::value), bool>::type > operator==(const function_base& f, reference_wrapper<Functor> g) > { > if (const Functor* fp = f.template target<Functor>()) > return fp == g.get_pointer(); > else return false; > } > >template<typename Functor> > typename ::boost::enable_if_c<(::boost::type_traits::ice_not< (::boost::is_integral<Functor>::value)>::value), bool>::type > operator==(reference_wrapper<Functor> g, const function_base& f) > { > if (const Functor* fp = f.template target<Functor>()) > return g.get_pointer() == fp; > else return false; > } > >template<typename Functor> > typename ::boost::enable_if_c<(::boost::type_traits::ice_not< (::boost::is_integral<Functor>::value)>::value), bool>::type > operator!=(const function_base& f, reference_wrapper<Functor> g) > { > if (const Functor* fp = f.template target<Functor>()) > return fp != g.get_pointer(); > else return true; > } > >template<typename Functor> > typename ::boost::enable_if_c<(::boost::type_traits::ice_not< (::boost::is_integral<Functor>::value)>::value), bool>::type > operator!=(reference_wrapper<Functor> g, const function_base& f) > { > if (const Functor* fp = f.template target<Functor>()) > return g.get_pointer() != fp; > else return true; > } > > > >namespace detail { > namespace function { > inline bool has_empty_target(const function_base* f) > { > return f->empty(); > } > > > > > > > > inline bool has_empty_target(...) > { > return false; > } > > } >} >} ># 18 "/usr/include/boost/function/detail/prologue.hpp" 2 3 4 > > ># 1 "/usr/include/boost/preprocessor/enum.hpp" 1 3 4 ># 21 "/usr/include/boost/function/detail/prologue.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/enum_params.hpp" 1 3 4 ># 22 "/usr/include/boost/function/detail/prologue.hpp" 2 3 4 ># 25 "/usr/include/boost/function.hpp" 2 3 4 ># 64 "/usr/include/boost/function.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 25 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 27 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 13 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R > > > > struct function_invoker0 > { > static R invoke(function_buffer& function_ptr > ) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f(); > } > }; > > template< > typename FunctionPtr, > typename R > > > > struct void_function_invoker0 > { > static void > invoke(function_buffer& function_ptr > ) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f(); > } > }; > > template< > typename FunctionObj, > typename R > > > > struct function_obj_invoker0 > { > static R invoke(function_buffer& function_obj_ptr > ) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)(); > } > }; > > template< > typename FunctionObj, > typename R > > > > struct void_function_obj_invoker0 > { > static void > invoke(function_buffer& function_obj_ptr > ) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)(); > } > }; > > template< > typename FunctionObj, > typename R > > > > struct function_ref_invoker0 > { > static R invoke(function_buffer& function_obj_ptr > ) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)(); > } > }; > > template< > typename FunctionObj, > typename R > > > > struct void_function_ref_invoker0 > { > static void > invoke(function_buffer& function_obj_ptr > ) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)(); > } > }; ># 230 "/usr/include/boost/function/function_template.hpp" 3 4 > template< > typename FunctionPtr, > typename R > > > > struct get_function_invoker0 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker0< > FunctionPtr, > R > > >, > function_invoker0< > FunctionPtr, > R > > > > >::type type; > }; > > template< > typename FunctionObj, > typename R > > > > struct get_function_obj_invoker0 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker0< > FunctionObj, > R > > >, > function_obj_invoker0< > FunctionObj, > R > > > > >::type type; > }; > > template< > typename FunctionObj, > typename R > > > > struct get_function_ref_invoker0 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker0< > FunctionObj, > R > > >, > function_ref_invoker0< > FunctionObj, > R > > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker0 { }; > > > template<> > struct get_invoker0<function_ptr_tag> > { > template<typename FunctionPtr, > typename R > > struct apply > { > typedef typename get_function_invoker0< > FunctionPtr, > R > > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker0< > FunctionPtr, > R > > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; ># 400 "/usr/include/boost/function/function_template.hpp" 3 4 > template<> > struct get_invoker0<function_obj_tag> > { > template<typename FunctionObj, > typename R > > struct apply > { > typedef typename get_function_obj_invoker0< > FunctionObj, > R > > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker0< > FunctionObj, > R > > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker0<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R > > struct apply > { > typedef typename get_function_ref_invoker0< > typename RefWrapper::type, > R > > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker0< > typename RefWrapper::type, > R > > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R > > struct basic_vtable0 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > > ); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } ># 562 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R > > > > class function0 : public function_base ># 664 "/usr/include/boost/function/function_template.hpp" 3 4 > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable0< > R > > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 0; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; ># 702 "/usr/include/boost/function/function_template.hpp" 3 4 > static const int arity = 0; > > > typedef function0 self_type; > > function0() : function_base() { } > > > > template<typename Functor> > function0(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function0(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function0(clear_type*) : function_base() { } > > > > > > > > function0(const function0& f) : function_base() > { > this->assign_to_own(f); > } > > > function0(function0&& f) : function_base() > { > this->move_assign(f); > } > > > ~function0() { clear(); } > > result_type operator()() const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor ); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function0&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function0& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function0& operator=(const function0& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function0& operator=(function0&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function0& other) > { > if (&other == this) > return; > > function0 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function0& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker0<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R > > > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker0<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R > , > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function0& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R > > inline void swap(function0< > R > > >& f1, > function0< > R > > >& f2) > { > f1.swap(f2); > } > > >template<typename R > > void operator==(const function0< > R > >&, > const function0< > R > >&); >template<typename R > > void operator!=(const function0< > R > >&, > const function0< > R > >& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R > > >class function<R (void)> > : public function0<R > >{ > typedef function0<R > base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 14 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 18 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 > > > struct function_invoker1 > { > static R invoke(function_buffer& function_ptr , > T0 a0) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 > > > struct void_function_invoker1 > { > static void > invoke(function_buffer& function_ptr , > T0 a0) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 > > > struct function_obj_invoker1 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 > > > struct void_function_obj_invoker1 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 > > > struct function_ref_invoker1 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 > > > struct void_function_ref_invoker1 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 > > > struct function_mem_invoker1 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 > > > struct function_void_mem_invoker1 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 > > > struct get_function_invoker1 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker1< > FunctionPtr, > R , > T0 > >, > function_invoker1< > FunctionPtr, > R , > T0 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 > > > struct get_function_obj_invoker1 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker1< > FunctionObj, > R , > T0 > >, > function_obj_invoker1< > FunctionObj, > R , > T0 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 > > > struct get_function_ref_invoker1 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker1< > FunctionObj, > R , > T0 > >, > function_ref_invoker1< > FunctionObj, > R , > T0 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 > > > struct get_member_invoker1 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker1< > MemberPtr, > R , > T0 > >, > function_mem_invoker1< > MemberPtr, > R , > T0 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker1 { }; > > > template<> > struct get_invoker1<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0> > struct apply > { > typedef typename get_function_invoker1< > FunctionPtr, > R , > T0 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker1< > FunctionPtr, > R , > T0 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker1<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0> > struct apply > { > typedef typename get_member_invoker1< > MemberPtr, > R , > T0 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker1< > MemberPtr, > R , > T0 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker1<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0> > struct apply > { > typedef typename get_function_obj_invoker1< > FunctionObj, > R , > T0 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker1< > FunctionObj, > R , > T0 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker1<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0> > struct apply > { > typedef typename get_function_ref_invoker1< > typename RefWrapper::type, > R , > T0 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker1< > typename RefWrapper::type, > R , > T0 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0> > struct basic_vtable1 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 > > > class function1 : public function_base > > > > , public std::unary_function<T0,R> > > > > > > > > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable1< > R , T0> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 1; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; > > > typedef T0 argument_type; > > > > > > static const int arity = 1; > typedef T0 arg1_type; > > typedef function1 self_type; > > function1() : function_base() { } > > > > template<typename Functor> > function1(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function1(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function1(clear_type*) : function_base() { } > > > > > > > > function1(const function1& f) : function_base() > { > this->assign_to_own(f); > } > > > function1(function1&& f) : function_base() > { > this->move_assign(f); > } > > > ~function1() { clear(); } > > result_type operator()( T0 a0) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function1&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function1& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function1& operator=(const function1& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function1& operator=(function1&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function1& other) > { > if (&other == this) > return; > > function1 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function1& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker1<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker1<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function1& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0> > inline void swap(function1< > R , > T0 > >& f1, > function1< > R , > T0 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0> > void operator==(const function1< > R , > T0>&, > const function1< > R , > T0>&); >template<typename R , typename T0> > void operator!=(const function1< > R , > T0>&, > const function1< > R , > T0>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0> >class function<R ( T0)> > : public function1<R , T0> >{ > typedef function1<R , T0> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 19 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 23 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 > > > struct function_invoker2 > { > static R invoke(function_buffer& function_ptr , > T0 a0 , T1 a1) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0 , a1); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 > > > struct void_function_invoker2 > { > static void > invoke(function_buffer& function_ptr , > T0 a0 , T1 a1) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0 , a1); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 > > > struct function_obj_invoker2 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 > > > struct void_function_obj_invoker2 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 > > > struct function_ref_invoker2 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 > > > struct void_function_ref_invoker2 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 > > > struct function_mem_invoker2 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0 , a1); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 > > > struct function_void_mem_invoker2 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0 , a1); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 > > > struct get_function_invoker2 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker2< > FunctionPtr, > R , > T0 , T1 > >, > function_invoker2< > FunctionPtr, > R , > T0 , T1 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 > > > struct get_function_obj_invoker2 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker2< > FunctionObj, > R , > T0 , T1 > >, > function_obj_invoker2< > FunctionObj, > R , > T0 , T1 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 > > > struct get_function_ref_invoker2 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker2< > FunctionObj, > R , > T0 , T1 > >, > function_ref_invoker2< > FunctionObj, > R , > T0 , T1 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 > > > struct get_member_invoker2 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker2< > MemberPtr, > R , > T0 , T1 > >, > function_mem_invoker2< > MemberPtr, > R , > T0 , T1 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker2 { }; > > > template<> > struct get_invoker2<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0 , typename T1> > struct apply > { > typedef typename get_function_invoker2< > FunctionPtr, > R , > T0 , T1 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0 , typename T1, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker2< > FunctionPtr, > R , > T0 , T1 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker2<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0 , typename T1> > struct apply > { > typedef typename get_member_invoker2< > MemberPtr, > R , > T0 , T1 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0 , typename T1, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker2< > MemberPtr, > R , > T0 , T1 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker2<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0 , typename T1> > struct apply > { > typedef typename get_function_obj_invoker2< > FunctionObj, > R , > T0 , T1 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0 , typename T1, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker2< > FunctionObj, > R , > T0 , T1 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker2<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0 , typename T1> > struct apply > { > typedef typename get_function_ref_invoker2< > typename RefWrapper::type, > R , > T0 , T1 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0 , typename T1, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker2< > typename RefWrapper::type, > R , > T0 , T1 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0 , typename T1> > struct basic_vtable2 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0 , T1); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 , typename T1 > > > class function2 : public function_base > > > > > > > > , public std::binary_function<T0,T1,R> > > > > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable2< > R , T0 , T1> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 2; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; > > > > > typedef T0 first_argument_type; > typedef T1 second_argument_type; > > > static const int arity = 2; > typedef T0 arg1_type; typedef T1 arg2_type; > > typedef function2 self_type; > > function2() : function_base() { } > > > > template<typename Functor> > function2(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function2(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function2(clear_type*) : function_base() { } > > > > > > > > function2(const function2& f) : function_base() > { > this->assign_to_own(f); > } > > > function2(function2&& f) : function_base() > { > this->move_assign(f); > } > > > ~function2() { clear(); } > > result_type operator()( T0 a0 , T1 a1) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0 , a1); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function2&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function2& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function2& operator=(const function2& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function2& operator=(function2&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function2& other) > { > if (&other == this) > return; > > function2 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function2& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker2<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0 , T1> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker2<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0 , T1, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function2& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0 , typename T1> > inline void swap(function2< > R , > T0 , T1 > >& f1, > function2< > R , > T0 , T1 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0 , typename T1> > void operator==(const function2< > R , > T0 , T1>&, > const function2< > R , > T0 , T1>&); >template<typename R , typename T0 , typename T1> > void operator!=(const function2< > R , > T0 , T1>&, > const function2< > R , > T0 , T1>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0 , typename T1> >class function<R ( T0 , T1)> > : public function2<R , T0 , T1> >{ > typedef function2<R , T0 , T1> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 24 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 58 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 28 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 > > > struct function_invoker3 > { > static R invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0 , a1 , a2); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 > > > struct void_function_invoker3 > { > static void > invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0 , a1 , a2); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 > > > struct function_obj_invoker3 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 > > > struct void_function_obj_invoker3 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 > > > struct function_ref_invoker3 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 > > > struct void_function_ref_invoker3 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 > > > struct function_mem_invoker3 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0 , a1 , a2); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 > > > struct function_void_mem_invoker3 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0 , a1 , a2); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 > > > struct get_function_invoker3 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker3< > FunctionPtr, > R , > T0 , T1 , T2 > >, > function_invoker3< > FunctionPtr, > R , > T0 , T1 , T2 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 > > > struct get_function_obj_invoker3 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker3< > FunctionObj, > R , > T0 , T1 , T2 > >, > function_obj_invoker3< > FunctionObj, > R , > T0 , T1 , T2 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 > > > struct get_function_ref_invoker3 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker3< > FunctionObj, > R , > T0 , T1 , T2 > >, > function_ref_invoker3< > FunctionObj, > R , > T0 , T1 , T2 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 > > > struct get_member_invoker3 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker3< > MemberPtr, > R , > T0 , T1 , T2 > >, > function_mem_invoker3< > MemberPtr, > R , > T0 , T1 , T2 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker3 { }; > > > template<> > struct get_invoker3<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2> > struct apply > { > typedef typename get_function_invoker3< > FunctionPtr, > R , > T0 , T1 , T2 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker3< > FunctionPtr, > R , > T0 , T1 , T2 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker3<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2> > struct apply > { > typedef typename get_member_invoker3< > MemberPtr, > R , > T0 , T1 , T2 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker3< > MemberPtr, > R , > T0 , T1 , T2 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker3<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2> > struct apply > { > typedef typename get_function_obj_invoker3< > FunctionObj, > R , > T0 , T1 , T2 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker3< > FunctionObj, > R , > T0 , T1 , T2 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker3<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2> > struct apply > { > typedef typename get_function_ref_invoker3< > typename RefWrapper::type, > R , > T0 , T1 , T2 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker3< > typename RefWrapper::type, > R , > T0 , T1 , T2 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0 , typename T1 , typename T2> > struct basic_vtable3 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0 , T1 , T2); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 , typename T1 , typename T2 > > > class function3 : public function_base ># 664 "/usr/include/boost/function/function_template.hpp" 3 4 > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable3< > R , T0 , T1 , T2> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 3; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; ># 702 "/usr/include/boost/function/function_template.hpp" 3 4 > static const int arity = 3; > typedef T0 arg1_type; typedef T1 arg2_type; typedef T2 arg3_type; > > typedef function3 self_type; > > function3() : function_base() { } > > > > template<typename Functor> > function3(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function3(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function3(clear_type*) : function_base() { } > > > > > > > > function3(const function3& f) : function_base() > { > this->assign_to_own(f); > } > > > function3(function3&& f) : function_base() > { > this->move_assign(f); > } > > > ~function3() { clear(); } > > result_type operator()( T0 a0 , T1 a1 , T2 a2) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0 , a1 , a2); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function3&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function3& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function3& operator=(const function3& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function3& operator=(function3&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function3& other) > { > if (&other == this) > return; > > function3 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function3& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker3<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0 , T1 , T2> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker3<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0 , T1 , T2, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function3& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0 , typename T1 , typename T2> > inline void swap(function3< > R , > T0 , T1 , T2 > >& f1, > function3< > R , > T0 , T1 , T2 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0 , typename T1 , typename T2> > void operator==(const function3< > R , > T0 , T1 , T2>&, > const function3< > R , > T0 , T1 , T2>&); >template<typename R , typename T0 , typename T1 , typename T2> > void operator!=(const function3< > R , > T0 , T1 , T2>&, > const function3< > R , > T0 , T1 , T2>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0 , typename T1 , typename T2> >class function<R ( T0 , T1 , T2)> > : public function3<R , T0 , T1 , T2> >{ > typedef function3<R , T0 , T1 , T2> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 29 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 63 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 33 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct function_invoker4 > { > static R invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0 , a1 , a2 , a3); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct void_function_invoker4 > { > static void > invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0 , a1 , a2 , a3); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct function_obj_invoker4 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct void_function_obj_invoker4 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct function_ref_invoker4 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct void_function_ref_invoker4 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct function_mem_invoker4 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0 , a1 , a2 , a3); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct function_void_mem_invoker4 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0 , a1 , a2 , a3); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct get_function_invoker4 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker4< > FunctionPtr, > R , > T0 , T1 , T2 , T3 > >, > function_invoker4< > FunctionPtr, > R , > T0 , T1 , T2 , T3 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct get_function_obj_invoker4 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker4< > FunctionObj, > R , > T0 , T1 , T2 , T3 > >, > function_obj_invoker4< > FunctionObj, > R , > T0 , T1 , T2 , T3 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct get_function_ref_invoker4 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker4< > FunctionObj, > R , > T0 , T1 , T2 , T3 > >, > function_ref_invoker4< > FunctionObj, > R , > T0 , T1 , T2 , T3 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > struct get_member_invoker4 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker4< > MemberPtr, > R , > T0 , T1 , T2 , T3 > >, > function_mem_invoker4< > MemberPtr, > R , > T0 , T1 , T2 , T3 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker4 { }; > > > template<> > struct get_invoker4<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3> > struct apply > { > typedef typename get_function_invoker4< > FunctionPtr, > R , > T0 , T1 , T2 , T3 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker4< > FunctionPtr, > R , > T0 , T1 , T2 , T3 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker4<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3> > struct apply > { > typedef typename get_member_invoker4< > MemberPtr, > R , > T0 , T1 , T2 , T3 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker4< > MemberPtr, > R , > T0 , T1 , T2 , T3 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker4<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3> > struct apply > { > typedef typename get_function_obj_invoker4< > FunctionObj, > R , > T0 , T1 , T2 , T3 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker4< > FunctionObj, > R , > T0 , T1 , T2 , T3 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker4<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3> > struct apply > { > typedef typename get_function_ref_invoker4< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker4< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0 , typename T1 , typename T2 , typename T3> > struct basic_vtable4 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0 , T1 , T2 , T3); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 , typename T1 , typename T2 , typename T3 > > > class function4 : public function_base ># 664 "/usr/include/boost/function/function_template.hpp" 3 4 > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable4< > R , T0 , T1 , T2 , T3> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 4; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; ># 702 "/usr/include/boost/function/function_template.hpp" 3 4 > static const int arity = 4; > typedef T0 arg1_type; typedef T1 arg2_type; typedef T2 arg3_type; typedef T3 arg4_type; > > typedef function4 self_type; > > function4() : function_base() { } > > > > template<typename Functor> > function4(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function4(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function4(clear_type*) : function_base() { } > > > > > > > > function4(const function4& f) : function_base() > { > this->assign_to_own(f); > } > > > function4(function4&& f) : function_base() > { > this->move_assign(f); > } > > > ~function4() { clear(); } > > result_type operator()( T0 a0 , T1 a1 , T2 a2 , T3 a3) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0 , a1 , a2 , a3); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function4&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function4& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function4& operator=(const function4& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function4& operator=(function4&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function4& other) > { > if (&other == this) > return; > > function4 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function4& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker4<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0 , T1 , T2 , T3> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker4<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0 , T1 , T2 , T3, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function4& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0 , typename T1 , typename T2 , typename T3> > inline void swap(function4< > R , > T0 , T1 , T2 , T3 > >& f1, > function4< > R , > T0 , T1 , T2 , T3 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0 , typename T1 , typename T2 , typename T3> > void operator==(const function4< > R , > T0 , T1 , T2 , T3>&, > const function4< > R , > T0 , T1 , T2 , T3>&); >template<typename R , typename T0 , typename T1 , typename T2 , typename T3> > void operator!=(const function4< > R , > T0 , T1 , T2 , T3>&, > const function4< > R , > T0 , T1 , T2 , T3>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0 , typename T1 , typename T2 , typename T3> >class function<R ( T0 , T1 , T2 , T3)> > : public function4<R , T0 , T1 , T2 , T3> >{ > typedef function4<R , T0 , T1 , T2 , T3> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 34 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 68 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 38 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct function_invoker5 > { > static R invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0 , a1 , a2 , a3 , a4); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct void_function_invoker5 > { > static void > invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0 , a1 , a2 , a3 , a4); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct function_obj_invoker5 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct void_function_obj_invoker5 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct function_ref_invoker5 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct void_function_ref_invoker5 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct function_mem_invoker5 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct function_void_mem_invoker5 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct get_function_invoker5 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker5< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 > >, > function_invoker5< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct get_function_obj_invoker5 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker5< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 > >, > function_obj_invoker5< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct get_function_ref_invoker5 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker5< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 > >, > function_ref_invoker5< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > struct get_member_invoker5 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker5< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 > >, > function_mem_invoker5< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker5 { }; > > > template<> > struct get_invoker5<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> > struct apply > { > typedef typename get_function_invoker5< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker5< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker5<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> > struct apply > { > typedef typename get_member_invoker5< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker5< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker5<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> > struct apply > { > typedef typename get_function_obj_invoker5< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker5< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker5<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> > struct apply > { > typedef typename get_function_ref_invoker5< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker5< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> > struct basic_vtable5 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0 , T1 , T2 , T3 , T4); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 > > > class function5 : public function_base ># 664 "/usr/include/boost/function/function_template.hpp" 3 4 > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable5< > R , T0 , T1 , T2 , T3 , T4> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 5; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; ># 702 "/usr/include/boost/function/function_template.hpp" 3 4 > static const int arity = 5; > typedef T0 arg1_type; typedef T1 arg2_type; typedef T2 arg3_type; typedef T3 arg4_type; typedef T4 arg5_type; > > typedef function5 self_type; > > function5() : function_base() { } > > > > template<typename Functor> > function5(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function5(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function5(clear_type*) : function_base() { } > > > > > > > > function5(const function5& f) : function_base() > { > this->assign_to_own(f); > } > > > function5(function5&& f) : function_base() > { > this->move_assign(f); > } > > > ~function5() { clear(); } > > result_type operator()( T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0 , a1 , a2 , a3 , a4); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function5&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function5& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function5& operator=(const function5& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function5& operator=(function5&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function5& other) > { > if (&other == this) > return; > > function5 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function5& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker5<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0 , T1 , T2 , T3 , T4> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker5<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0 , T1 , T2 , T3 , T4, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function5& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> > inline void swap(function5< > R , > T0 , T1 , T2 , T3 , T4 > >& f1, > function5< > R , > T0 , T1 , T2 , T3 , T4 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> > void operator==(const function5< > R , > T0 , T1 , T2 , T3 , T4>&, > const function5< > R , > T0 , T1 , T2 , T3 , T4>&); >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4> > void operator!=(const function5< > R , > T0 , T1 , T2 , T3 , T4>&, > const function5< > R , > T0 , T1 , T2 , T3 , T4>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4> >class function<R ( T0 , T1 , T2 , T3 , T4)> > : public function5<R , T0 , T1 , T2 , T3 , T4> >{ > typedef function5<R , T0 , T1 , T2 , T3 , T4> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 39 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 73 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 43 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct function_invoker6 > { > static R invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0 , a1 , a2 , a3 , a4 , a5); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct void_function_invoker6 > { > static void > invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0 , a1 , a2 , a3 , a4 , a5); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct function_obj_invoker6 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct void_function_obj_invoker6 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct function_ref_invoker6 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct void_function_ref_invoker6 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct function_mem_invoker6 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct function_void_mem_invoker6 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct get_function_invoker6 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker6< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >, > function_invoker6< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct get_function_obj_invoker6 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker6< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >, > function_obj_invoker6< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct get_function_ref_invoker6 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker6< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >, > function_ref_invoker6< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > struct get_member_invoker6 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker6< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >, > function_mem_invoker6< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker6 { }; > > > template<> > struct get_invoker6<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> > struct apply > { > typedef typename get_function_invoker6< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker6< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker6<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> > struct apply > { > typedef typename get_member_invoker6< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker6< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker6<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> > struct apply > { > typedef typename get_function_obj_invoker6< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker6< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker6<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> > struct apply > { > typedef typename get_function_ref_invoker6< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker6< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> > struct basic_vtable6 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0 , T1 , T2 , T3 , T4 , T5); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > > > class function6 : public function_base ># 664 "/usr/include/boost/function/function_template.hpp" 3 4 > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable6< > R , T0 , T1 , T2 , T3 , T4 , T5> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 6; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; ># 702 "/usr/include/boost/function/function_template.hpp" 3 4 > static const int arity = 6; > typedef T0 arg1_type; typedef T1 arg2_type; typedef T2 arg3_type; typedef T3 arg4_type; typedef T4 arg5_type; typedef T5 arg6_type; > > typedef function6 self_type; > > function6() : function_base() { } > > > > template<typename Functor> > function6(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function6(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function6(clear_type*) : function_base() { } > > > > > > > > function6(const function6& f) : function_base() > { > this->assign_to_own(f); > } > > > function6(function6&& f) : function_base() > { > this->move_assign(f); > } > > > ~function6() { clear(); } > > result_type operator()( T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0 , a1 , a2 , a3 , a4 , a5); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function6&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function6& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function6& operator=(const function6& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function6& operator=(function6&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function6& other) > { > if (&other == this) > return; > > function6 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function6& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker6<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker6<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function6& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> > inline void swap(function6< > R , > T0 , T1 , T2 , T3 , T4 , T5 > >& f1, > function6< > R , > T0 , T1 , T2 , T3 , T4 , T5 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> > void operator==(const function6< > R , > T0 , T1 , T2 , T3 , T4 , T5>&, > const function6< > R , > T0 , T1 , T2 , T3 , T4 , T5>&); >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> > void operator!=(const function6< > R , > T0 , T1 , T2 , T3 , T4 , T5>&, > const function6< > R , > T0 , T1 , T2 , T3 , T4 , T5>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5> >class function<R ( T0 , T1 , T2 , T3 , T4 , T5)> > : public function6<R , T0 , T1 , T2 , T3 , T4 , T5> >{ > typedef function6<R , T0 , T1 , T2 , T3 , T4 , T5> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 44 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 78 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 48 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct function_invoker7 > { > static R invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0 , a1 , a2 , a3 , a4 , a5 , a6); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct void_function_invoker7 > { > static void > invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0 , a1 , a2 , a3 , a4 , a5 , a6); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct function_obj_invoker7 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct void_function_obj_invoker7 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct function_ref_invoker7 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct void_function_ref_invoker7 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct function_mem_invoker7 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct function_void_mem_invoker7 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct get_function_invoker7 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker7< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >, > function_invoker7< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct get_function_obj_invoker7 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker7< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >, > function_obj_invoker7< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct get_function_ref_invoker7 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker7< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >, > function_ref_invoker7< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > struct get_member_invoker7 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker7< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >, > function_mem_invoker7< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker7 { }; > > > template<> > struct get_invoker7<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> > struct apply > { > typedef typename get_function_invoker7< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker7< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker7<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> > struct apply > { > typedef typename get_member_invoker7< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker7< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker7<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> > struct apply > { > typedef typename get_function_obj_invoker7< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker7< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker7<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> > struct apply > { > typedef typename get_function_ref_invoker7< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker7< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> > struct basic_vtable7 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0 , T1 , T2 , T3 , T4 , T5 , T6); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > > > class function7 : public function_base ># 664 "/usr/include/boost/function/function_template.hpp" 3 4 > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable7< > R , T0 , T1 , T2 , T3 , T4 , T5 , T6> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 7; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; ># 702 "/usr/include/boost/function/function_template.hpp" 3 4 > static const int arity = 7; > typedef T0 arg1_type; typedef T1 arg2_type; typedef T2 arg3_type; typedef T3 arg4_type; typedef T4 arg5_type; typedef T5 arg6_type; typedef T6 arg7_type; > > typedef function7 self_type; > > function7() : function_base() { } > > > > template<typename Functor> > function7(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function7(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function7(clear_type*) : function_base() { } > > > > > > > > function7(const function7& f) : function_base() > { > this->assign_to_own(f); > } > > > function7(function7&& f) : function_base() > { > this->move_assign(f); > } > > > ~function7() { clear(); } > > result_type operator()( T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0 , a1 , a2 , a3 , a4 , a5 , a6); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function7&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function7& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function7& operator=(const function7& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function7& operator=(function7&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function7& other) > { > if (&other == this) > return; > > function7 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function7& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker7<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5 , T6> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker7<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5 , T6, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function7& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> > inline void swap(function7< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >& f1, > function7< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> > void operator==(const function7< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6>&, > const function7< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6>&); >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> > void operator!=(const function7< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6>&, > const function7< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6> >class function<R ( T0 , T1 , T2 , T3 , T4 , T5 , T6)> > : public function7<R , T0 , T1 , T2 , T3 , T4 , T5 , T6> >{ > typedef function7<R , T0 , T1 , T2 , T3 , T4 , T5 , T6> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 49 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 83 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 53 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct function_invoker8 > { > static R invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct void_function_invoker8 > { > static void > invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct function_obj_invoker8 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct void_function_obj_invoker8 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct function_ref_invoker8 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct void_function_ref_invoker8 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct function_mem_invoker8 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct function_void_mem_invoker8 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct get_function_invoker8 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker8< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >, > function_invoker8< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct get_function_obj_invoker8 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker8< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >, > function_obj_invoker8< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct get_function_ref_invoker8 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker8< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >, > function_ref_invoker8< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > struct get_member_invoker8 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker8< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >, > function_mem_invoker8< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker8 { }; > > > template<> > struct get_invoker8<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> > struct apply > { > typedef typename get_function_invoker8< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker8< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker8<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> > struct apply > { > typedef typename get_member_invoker8< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker8< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker8<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> > struct apply > { > typedef typename get_function_obj_invoker8< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker8< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker8<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> > struct apply > { > typedef typename get_function_ref_invoker8< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker8< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> > struct basic_vtable8 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 > > > class function8 : public function_base ># 664 "/usr/include/boost/function/function_template.hpp" 3 4 > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable8< > R , T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 8; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; ># 702 "/usr/include/boost/function/function_template.hpp" 3 4 > static const int arity = 8; > typedef T0 arg1_type; typedef T1 arg2_type; typedef T2 arg3_type; typedef T3 arg4_type; typedef T4 arg5_type; typedef T5 arg6_type; typedef T6 arg7_type; typedef T7 arg8_type; > > typedef function8 self_type; > > function8() : function_base() { } > > > > template<typename Functor> > function8(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function8(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function8(clear_type*) : function_base() { } > > > > > > > > function8(const function8& f) : function_base() > { > this->assign_to_own(f); > } > > > function8(function8&& f) : function_base() > { > this->move_assign(f); > } > > > ~function8() { clear(); } > > result_type operator()( T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function8&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function8& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function8& operator=(const function8& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function8& operator=(function8&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function8& other) > { > if (&other == this) > return; > > function8 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function8& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker8<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker8<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function8& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> > inline void swap(function8< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >& f1, > function8< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> > void operator==(const function8< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7>&, > const function8< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7>&); >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> > void operator!=(const function8< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7>&, > const function8< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7> >class function<R ( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7)> > : public function8<R , T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7> >{ > typedef function8<R , T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 54 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 88 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 58 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct function_invoker9 > { > static R invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct void_function_invoker9 > { > static void > invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct function_obj_invoker9 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct void_function_obj_invoker9 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct function_ref_invoker9 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct void_function_ref_invoker9 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct function_mem_invoker9 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct function_void_mem_invoker9 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct get_function_invoker9 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker9< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >, > function_invoker9< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct get_function_obj_invoker9 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker9< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >, > function_obj_invoker9< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct get_function_ref_invoker9 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker9< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >, > function_ref_invoker9< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > struct get_member_invoker9 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker9< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >, > function_mem_invoker9< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker9 { }; > > > template<> > struct get_invoker9<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> > struct apply > { > typedef typename get_function_invoker9< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker9< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker9<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> > struct apply > { > typedef typename get_member_invoker9< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker9< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker9<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> > struct apply > { > typedef typename get_function_obj_invoker9< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker9< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker9<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> > struct apply > { > typedef typename get_function_ref_invoker9< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker9< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> > struct basic_vtable9 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 > > > class function9 : public function_base ># 664 "/usr/include/boost/function/function_template.hpp" 3 4 > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable9< > R , T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 9; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; ># 702 "/usr/include/boost/function/function_template.hpp" 3 4 > static const int arity = 9; > typedef T0 arg1_type; typedef T1 arg2_type; typedef T2 arg3_type; typedef T3 arg4_type; typedef T4 arg5_type; typedef T5 arg6_type; typedef T6 arg7_type; typedef T7 arg8_type; typedef T8 arg9_type; > > typedef function9 self_type; > > function9() : function_base() { } > > > > template<typename Functor> > function9(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function9(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function9(clear_type*) : function_base() { } > > > > > > > > function9(const function9& f) : function_base() > { > this->assign_to_own(f); > } > > > function9(function9&& f) : function_base() > { > this->move_assign(f); > } > > > ~function9() { clear(); } > > result_type operator()( T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function9&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function9& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function9& operator=(const function9& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function9& operator=(function9&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function9& other) > { > if (&other == this) > return; > > function9 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function9& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker9<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker9<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function9& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> > inline void swap(function9< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >& f1, > function9< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> > void operator==(const function9< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8>&, > const function9< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8>&); >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> > void operator!=(const function9< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8>&, > const function9< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8> >class function<R ( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8)> > : public function9<R , T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8> >{ > typedef function9<R , T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 59 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 93 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 63 "/usr/include/boost/function/detail/maybe_include.hpp" 3 4 ># 1 "/usr/include/boost/function/function_template.hpp" 1 3 4 ># 81 "/usr/include/boost/function/function_template.hpp" 3 4 >namespace boost { > namespace detail { > namespace function { > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct function_invoker10 > { > static R invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8 , T9 a9) > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > return f( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9); > } > }; > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct void_function_invoker10 > { > static void > invoke(function_buffer& function_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8 , T9 a9) > > { > FunctionPtr f = reinterpret_cast<FunctionPtr>(function_ptr.func_ptr); > f( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct function_obj_invoker10 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8 , T9 a9) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct void_function_obj_invoker10 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8 , T9 a9) > > { > FunctionObj* f; > if (function_allows_small_object_optimization<FunctionObj>::value) > f = reinterpret_cast<FunctionObj*>(&function_obj_ptr.data); > else > f = reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct function_ref_invoker10 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8 , T9 a9) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > return (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9); > } > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct void_function_ref_invoker10 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8 , T9 a9) > > { > FunctionObj* f = > reinterpret_cast<FunctionObj*>(function_obj_ptr.obj_ptr); > (*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9); > } > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct function_mem_invoker10 > { > static R invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8 , T9 a9) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > return boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9); > } > }; > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct function_void_mem_invoker10 > { > static void > invoke(function_buffer& function_obj_ptr , > T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8 , T9 a9) > > { > MemberPtr* f = > reinterpret_cast<MemberPtr*>(&function_obj_ptr.data); > boost::mem_fn(*f)( a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9); > } > }; > > > template< > typename FunctionPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct get_function_invoker10 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_invoker10< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >, > function_invoker10< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct get_function_obj_invoker10 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_obj_invoker10< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >, > function_obj_invoker10< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > > > >::type type; > }; > > template< > typename FunctionObj, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct get_function_ref_invoker10 > { > typedef typename mpl::if_c<(is_void<R>::value), > void_function_ref_invoker10< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >, > function_ref_invoker10< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > > > >::type type; > }; > > > > template< > typename MemberPtr, > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > struct get_member_invoker10 > { > typedef typename mpl::if_c<(is_void<R>::value), > function_void_mem_invoker10< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >, > function_mem_invoker10< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > > > >::type type; > }; ># 326 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename Tag> > struct get_invoker10 { }; > > > template<> > struct get_invoker10<function_ptr_tag> > { > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> > struct apply > { > typedef typename get_function_invoker10< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > > template<typename FunctionPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9, > typename Allocator> > struct apply_a > { > typedef typename get_function_invoker10< > FunctionPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >::type > invoker_type; > > typedef functor_manager<FunctionPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker10<member_ptr_tag> > { > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> > struct apply > { > typedef typename get_member_invoker10< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > > template<typename MemberPtr, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9, > typename Allocator> > struct apply_a > { > typedef typename get_member_invoker10< > MemberPtr, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >::type > invoker_type; > > typedef functor_manager<MemberPtr> manager_type; > }; > }; > > > > template<> > struct get_invoker10<function_obj_tag> > { > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> > struct apply > { > typedef typename get_function_obj_invoker10< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >::type > invoker_type; > > typedef functor_manager<FunctionObj> manager_type; > }; > > template<typename FunctionObj, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9, > typename Allocator> > struct apply_a > { > typedef typename get_function_obj_invoker10< > FunctionObj, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >::type > invoker_type; > > typedef functor_manager_a<FunctionObj, Allocator> manager_type; > }; > }; > > > template<> > struct get_invoker10<function_obj_ref_tag> > { > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> > struct apply > { > typedef typename get_function_ref_invoker10< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > > template<typename RefWrapper, > typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9, > typename Allocator> > struct apply_a > { > typedef typename get_function_ref_invoker10< > typename RefWrapper::type, > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >::type > invoker_type; > > typedef reference_manager<typename RefWrapper::type> manager_type; > }; > }; ># 475 "/usr/include/boost/function/function_template.hpp" 3 4 > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> > struct basic_vtable10 > { > > typedef R result_type; > > > > > typedef result_type (*invoker_type)(function_buffer& > , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9); > > template<typename F> > bool assign_to(F f, function_buffer& functor) const > { > typedef typename get_function_tag<F>::type tag; > return assign_to(f, functor, tag()); > } > template<typename F,typename Allocator> > bool assign_to_a(F f, function_buffer& functor, Allocator a) const > { > typedef typename get_function_tag<F>::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: > > template<typename FunctionPtr> > bool > assign_to(FunctionPtr f, function_buffer& functor, function_ptr_tag) const > { > this->clear(functor); > if (f) { > > > functor.func_ptr = reinterpret_cast<void (*)()>(f); > return true; > } else { > return false; > } > } > template<typename FunctionPtr,typename Allocator> > bool > assign_to_a(FunctionPtr f, function_buffer& functor, Allocator, function_ptr_tag) const > { > return assign_to(f,functor,function_ptr_tag()); > } > > > > template<typename MemberPtr> > bool assign_to(MemberPtr f, function_buffer& functor, member_ptr_tag) const > { > > > > if (f) { > this->assign_to(boost::mem_fn(f), functor); > return true; > } else { > return false; > } > } > template<typename MemberPtr,typename Allocator> > bool assign_to_a(MemberPtr f, function_buffer& functor, Allocator a, member_ptr_tag) const > { > > > > if (f) { > this->assign_to_a(boost::mem_fn(f), functor, a); > return true; > } else { > return false; > } > } > > > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::true_) const > { > new (reinterpret_cast<void*>(&functor.data)) FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator, mpl::true_) const > { > assign_functor(f,functor,mpl::true_()); > } > > > template<typename FunctionObj> > void > assign_functor(FunctionObj f, function_buffer& functor, mpl::false_) const > { > functor.obj_ptr = new FunctionObj(f); > } > template<typename FunctionObj,typename Allocator> > void > assign_functor_a(FunctionObj f, function_buffer& functor, Allocator a, mpl::false_) const > { > typedef functor_wrapper<FunctionObj,Allocator> functor_wrapper_type; > typedef typename Allocator::template rebind<functor_wrapper_type>::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<functor_wrapper_type*>(copy); > functor.obj_ptr = new_f; > } > > template<typename FunctionObj> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > template<typename FunctionObj,typename Allocator> > 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<FunctionObj>::value)>()); > return true; > } else { > return false; > } > } > > > template<typename FunctionObj> > bool > assign_to(const reference_wrapper<FunctionObj>& 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<FunctionObj>::value; > functor.obj_ref.is_volatile_qualified = is_volatile<FunctionObj>::value; > return true; > } > template<typename FunctionObj,typename Allocator> > bool > assign_to_a(const reference_wrapper<FunctionObj>& 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; > }; > } > } > > template< > typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 > > > class function10 : public function_base ># 664 "/usr/include/boost/function/function_template.hpp" 3 4 > { > public: > > typedef R result_type; > > > > > > private: > typedef boost::detail::function::basic_vtable10< > R , T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9> > vtable_type; > > vtable_type* get_vtable() const { > return reinterpret_cast<vtable_type*>( > reinterpret_cast<std::size_t>(vtable) & ~static_cast<std::size_t>(0x01)); > } > > struct clear_type {}; > > public: > static const int args = 10; > > > template<typename Args> > struct sig > { > typedef result_type type; > }; ># 702 "/usr/include/boost/function/function_template.hpp" 3 4 > static const int arity = 10; > typedef T0 arg1_type; typedef T1 arg2_type; typedef T2 arg3_type; typedef T3 arg4_type; typedef T4 arg5_type; typedef T5 arg6_type; typedef T6 arg7_type; typedef T7 arg8_type; typedef T8 arg9_type; typedef T9 arg10_type; > > typedef function10 self_type; > > function10() : function_base() { } > > > > template<typename Functor> > function10(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to(f); > } > template<typename Functor,typename Allocator> > function10(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > function_base() > { > this->assign_to_a(f,a); > } > > > function10(clear_type*) : function_base() { } > > > > > > > > function10(const function10& f) : function_base() > { > this->assign_to_own(f); > } > > > function10(function10&& f) : function_base() > { > this->move_assign(f); > } > > > ~function10() { clear(); } > > result_type operator()( T0 a0 , T1 a1 , T2 a2 , T3 a3 , T4 a4 , T5 a5 , T6 a6 , T7 a7 , T8 a8 , T9 a9) const > { > if (this->empty()) > boost::throw_exception(bad_function_call()); > > return get_vtable()->invoker > (this->functor , a0 , a1 , a2 , a3 , a4 , a5 , a6 , a7 , a8 , a9); > } > > > > > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > function10&>::type > > > > operator=(Functor f) > { > this->clear(); > { try { > this->assign_to(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > template<typename Functor,typename Allocator> > void assign(Functor f, Allocator a) > { > this->clear(); > { try{ > this->assign_to_a(f,a); > } catch(...) { > vtable = 0; > throw;; > } > } > } > > > function10& operator=(clear_type*) > { > this->clear(); > return *this; > } ># 825 "/usr/include/boost/function/function_template.hpp" 3 4 > function10& operator=(const function10& f) > { > if (&f == this) > return *this; > > this->clear(); > { try { > this->assign_to_own(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > > function10& operator=(function10&& f) > { > > if (&f == this) > return *this; > > this->clear(); > { try { > this->move_assign(f); > } catch(...) { > vtable = 0; > throw;; > } > } > return *this; > } > > > void swap(function10& other) > { > if (&other == this) > return; > > function10 tmp; > tmp.move_assign(*this); > this->move_assign(other); > other.move_assign(tmp); > } > > > void clear() > { > if (vtable) { > if (!this->has_trivial_copy_and_destroy()) > get_vtable()->clear(this->functor); > vtable = 0; > } > } > > > > > > 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(); } > > > private: > void assign_to_own(const function10& 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<typename Functor> > void assign_to(Functor f) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker10<tag> get_invoker; > typedef typename get_invoker:: > template apply<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > template<typename Functor,typename Allocator> > void assign_to_a(Functor f,Allocator a) > { > using detail::function::vtable_base; > > typedef typename detail::function::get_function_tag<Functor>::type tag; > typedef detail::function::get_invoker10<tag> get_invoker; > typedef typename get_invoker:: > template apply_a<Functor, R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9, > Allocator> > handler_type; > > typedef typename handler_type::invoker_type invoker_type; > typedef typename handler_type::manager_type manager_type; > > > > > > 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<std::size_t>(&stored_vtable.base); > if (boost::has_trivial_copy_constructor<Functor>::value && > boost::has_trivial_destructor<Functor>::value && > detail::function::function_allows_small_object_optimization<Functor>::value) > value |= static_cast<std::size_t>(0x01); > vtable = reinterpret_cast<detail::function::vtable_base *>(value); > } else > vtable = 0; > } > > > > > void move_assign(function10& f) > { > if (&f == this) > return; > > { 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(); > } > } catch(...) { > vtable = 0; > throw;; > } > } > } > }; > > template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> > inline void swap(function10< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >& f1, > function10< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 > >& f2) > { > f1.swap(f2); > } > > >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> > void operator==(const function10< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9>&, > const function10< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9>&); >template<typename R , typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> > void operator!=(const function10< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9>&, > const function10< > R , > T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9>& ); ># 1046 "/usr/include/boost/function/function_template.hpp" 3 4 >template<typename R , > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9> >class function<R ( T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9)> > : public function10<R , T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9> >{ > typedef function10<R , T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9> base_type; > typedef function self_type; > > struct clear_type {}; > >public: > > function() : base_type() {} > > template<typename Functor> > function(Functor f > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f) > { > } > template<typename Functor,typename Allocator> > function(Functor f, Allocator a > > ,typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > int>::type = 0 > > ) : > base_type(f,a) > { > } > > > function(clear_type*) : base_type() {} > > > function(const self_type& f) : base_type(static_cast<const base_type&>(f)){} > > function(const base_type& f) : base_type(static_cast<const base_type&>(f)){} > > > > function(self_type&& f): base_type(static_cast<base_type&&>(f)){} > function(base_type&& f): base_type(static_cast<base_type&&>(f)){} > > > self_type& operator=(const self_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(self_type&& f) > { > self_type(static_cast<self_type&&>(f)).swap(*this); > return *this; > } > > > template<typename Functor> > > typename enable_if_c< > (boost::type_traits::ice_not< > (is_integral<Functor>::value)>::value), > self_type&>::type > > > > operator=(Functor f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(clear_type*) > { > this->clear(); > return *this; > } > > > self_type& operator=(const base_type& f) > { > self_type(f).swap(*this); > return *this; > } > > > self_type& operator=(base_type&& f) > { > self_type(static_cast<base_type&&>(f)).swap(*this); > return *this; > } > >}; > > > > >} ># 64 "/usr/include/boost/function/detail/maybe_include.hpp" 2 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 98 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 65 "/usr/include/boost/function.hpp" 2 3 4 ># 41 "/usr/include/boost/thread/future.hpp" 2 3 4 > > ># 1 "/usr/include/boost/scoped_array.hpp" 1 3 4 ># 14 "/usr/include/boost/scoped_array.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/scoped_array.hpp" 1 3 4 ># 15 "/usr/include/boost/smart_ptr/scoped_array.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 16 "/usr/include/boost/smart_ptr/scoped_array.hpp" 2 3 4 > > > > > > > >namespace boost >{ ># 39 "/usr/include/boost/smart_ptr/scoped_array.hpp" 3 4 >template<class T> class scoped_array >{ >private: > > T * px; > > scoped_array(scoped_array const &); > scoped_array & operator=(scoped_array const &); > > typedef scoped_array<T> this_type; > > void operator==( scoped_array const& ) const; > void operator!=( scoped_array const& ) const; > >public: > > typedef T element_type; > > explicit scoped_array( T * p = 0 ) noexcept : px( p ) > { > > > > } > > ~scoped_array() > { > > > > boost::checked_array_delete( px ); > } > > void reset(T * p = 0) > { > (static_cast<void> (0)); > this_type(p).swap(*this); > } > > T & operator[](std::ptrdiff_t i) const > { > (static_cast<void> (0)); > (static_cast<void> (0)); > return px[i]; > } > > T * get() const noexcept > { > return px; > } > > ># 1 "/usr/include/boost/smart_ptr/detail/operator_bool.hpp" 1 3 4 ># 11 "/usr/include/boost/smart_ptr/detail/operator_bool.hpp" 3 4 > explicit operator bool () const noexcept > { > return px != 0; > } ># 60 "/usr/include/boost/smart_ptr/detail/operator_bool.hpp" 3 4 > bool operator! () const noexcept > { > return px == 0; > } ># 92 "/usr/include/boost/smart_ptr/scoped_array.hpp" 2 3 4 > > void swap(scoped_array & b) noexcept > { > T * tmp = b.px; > b.px = px; > px = tmp; > } >}; > > > >template<class T> inline bool operator==( scoped_array<T> const & p, boost::detail::sp_nullptr_t ) noexcept >{ > return p.get() == 0; >} > >template<class T> inline bool operator==( boost::detail::sp_nullptr_t, scoped_array<T> const & p ) noexcept >{ > return p.get() == 0; >} > >template<class T> inline bool operator!=( scoped_array<T> const & p, boost::detail::sp_nullptr_t ) noexcept >{ > return p.get() != 0; >} > >template<class T> inline bool operator!=( boost::detail::sp_nullptr_t, scoped_array<T> const & p ) noexcept >{ > return p.get() != 0; >} > > > >template<class T> inline void swap(scoped_array<T> & a, scoped_array<T> & b) noexcept >{ > a.swap(b); >} > >} ># 15 "/usr/include/boost/scoped_array.hpp" 2 3 4 ># 44 "/usr/include/boost/thread/future.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/thread/future_error_code.hpp" 1 3 4 ># 16 "/usr/include/boost/thread/future_error_code.hpp" 3 4 >namespace boost >{ > > > enum class future_errc > { > broken_promise = 1, > future_already_retrieved, > promise_already_satisfied, > no_state > } > ; > > namespace system > { > template <> > struct __attribute__((__visibility__("default"))) is_error_code_enum<future_errc> : public true_type {}; > > > > > > } > > __attribute__((__visibility__("default"))) > const system::error_category& future_category() noexcept; > > namespace system > { > inline > error_code > make_error_code(future_errc e) noexcept > { > return error_code(underlying_cast<int>(e), boost::future_category()); > } > > inline > error_condition > make_error_condition(future_errc e) noexcept > { > return error_condition(underlying_cast<int>(e), future_category()); > } > } >} ># 51 "/usr/include/boost/thread/future.hpp" 2 3 4 ># 68 "/usr/include/boost/thread/future.hpp" 3 4 >namespace boost >{ > > > enum class launch > { > none = 0, > async = 1, > deferred = 2, > any = async | deferred > } > ; > > > enum class future_status > { > ready, > timeout, > deferred > } > ; > > class __attribute__((__visibility__("default"))) future_error > : public std::logic_error > { > system::error_code ec_; > public: > future_error(system::error_code ec) > : logic_error(ec.message()), > ec_(ec) > { > } > > const system::error_code& code() const noexcept > { > return ec_; > } > }; > > class __attribute__((__visibility__("default"))) future_uninitialized: > public future_error > { > public: > future_uninitialized() : > future_error(system::make_error_code(future_errc::no_state)) > {} > }; > class __attribute__((__visibility__("default"))) broken_promise: > public future_error > { > public: > broken_promise(): > future_error(system::make_error_code(future_errc::broken_promise)) > {} > }; > class __attribute__((__visibility__("default"))) future_already_retrieved: > public future_error > { > public: > future_already_retrieved(): > future_error(system::make_error_code(future_errc::future_already_retrieved)) > {} > }; > class __attribute__((__visibility__("default"))) promise_already_satisfied: > public future_error > { > public: > promise_already_satisfied(): > future_error(system::make_error_code(future_errc::promise_already_satisfied)) > {} > }; > > class __attribute__((__visibility__("default"))) task_already_started: > public future_error > { > public: > task_already_started(): > future_error(system::make_error_code(future_errc::promise_already_satisfied)) > {} > }; > > class __attribute__((__visibility__("default"))) task_moved: > public future_error > { > public: > task_moved(): > future_error(system::make_error_code(future_errc::no_state)) > {} > }; > > class promise_moved: > public future_error > { > public: > promise_moved(): > future_error(system::make_error_code(future_errc::no_state)) > {} > }; > > namespace future_state > { > enum state { uninitialized, waiting, ready, moved, deferred }; > } > > namespace detail > { > struct relocker > { > boost::unique_lock<boost::mutex>& lock_; > bool unlocked_; > > relocker(boost::unique_lock<boost::mutex>& lk): > lock_(lk) > { > lock_.unlock(); > unlocked_=true; > } > ~relocker() > { > if (unlocked_) { > lock_.lock(); > } > } > void lock() { > if (unlocked_) { > lock_.lock(); > unlocked_=false; > } > } > private: > relocker& operator=(relocker const&); > }; > > struct shared_state_base : enable_shared_from_this<shared_state_base> > { > typedef std::list<boost::condition_variable_any*> waiter_list; > > typedef shared_ptr<shared_state_base> continuation_ptr_type; > > boost::exception_ptr exception; > bool done; > bool is_deferred_; > launch policy_; > bool is_constructed; > mutable boost::mutex mutex; > boost::condition_variable waiters; > waiter_list external_waiters; > boost::function<void()> callback; > > bool thread_was_interrupted; > > continuation_ptr_type continuation_ptr; > > > virtual void launch_continuation(boost::unique_lock<boost::mutex>&) > { > } > > shared_state_base(): > done(false), > is_deferred_(false), > policy_(launch::none), > is_constructed(false), > thread_was_interrupted(false), > continuation_ptr() > {} > virtual ~shared_state_base() > {} > > void set_deferred() > { > is_deferred_ = true; > policy_ = launch::deferred; > } > void set_async() > { > is_deferred_ = false; > policy_ = launch::async; > } > > waiter_list::iterator register_external_waiter(boost::condition_variable_any& cv) > { > boost::unique_lock<boost::mutex> lock(mutex); > do_callback(lock); > return external_waiters.insert(external_waiters.end(),&cv); > } > > void remove_external_waiter(waiter_list::iterator it) > { > boost::lock_guard<boost::mutex> lock(mutex); > external_waiters.erase(it); > } ># 272 "/usr/include/boost/thread/future.hpp" 3 4 > void do_continuation(boost::unique_lock<boost::mutex>&) > { > } ># 285 "/usr/include/boost/thread/future.hpp" 3 4 > void mark_finished_internal(boost::unique_lock<boost::mutex>& lock) > { > done=true; > waiters.notify_all(); > for(waiter_list::const_iterator it=external_waiters.begin(), > end=external_waiters.end();it!=end;++it) > { > (*it)->notify_all(); > } > do_continuation(lock); > } > void make_ready() > { > boost::unique_lock<boost::mutex> lock(mutex); > mark_finished_internal(lock); > } > > void do_callback(boost::unique_lock<boost::mutex>& lock) > { > if(callback && !done) > { > boost::function<void()> local_callback=callback; > relocker relock(lock); > local_callback(); > } > } > > void wait_internal(boost::unique_lock<boost::mutex> &lk, bool rethrow=true) > { > do_callback(lk); > > { > if (is_deferred_) > { > is_deferred_=false; > execute(lk); > > } > else > { > while(!done) > { > waiters.wait(lk); > } > > if(rethrow && thread_was_interrupted) > { > throw boost::thread_interrupted(); > } > > if(rethrow && exception) > { > boost::rethrow_exception(exception); > } > } > } > } > > virtual void wait(bool rethrow=true) > { > boost::unique_lock<boost::mutex> lock(mutex); > wait_internal(lock, rethrow); > } > > > bool timed_wait_until(boost::system_time const& target_time) > { > boost::unique_lock<boost::mutex> lock(mutex); > if (is_deferred_) > return false; > > do_callback(lock); > while(!done) > { > bool const success=waiters.timed_wait(lock,target_time); > if(!success && !done) > { > return false; > } > } > return true; > } > > > > template <class Clock, class Duration> > future_status > wait_until(const chrono::time_point<Clock, Duration>& abs_time) > { > boost::unique_lock<boost::mutex> lock(mutex); > if (is_deferred_) > return future_status::deferred; > do_callback(lock); > while(!done) > { > cv_status const st=waiters.wait_until(lock,abs_time); > if(st==cv_status::timeout && !done) > { > return future_status::timeout; > } > } > return future_status::ready; > } > > void mark_exceptional_finish_internal(boost::exception_ptr const& e, boost::unique_lock<boost::mutex>& lock) > { > exception=e; > mark_finished_internal(lock); > } > > void mark_exceptional_finish() > { > boost::unique_lock<boost::mutex> lock(mutex); > mark_exceptional_finish_internal(boost::current_exception(), lock); > } > > > void mark_interrupted_finish() > { > boost::unique_lock<boost::mutex> lock(mutex); > thread_was_interrupted=true; > mark_finished_internal(lock); > } > > void set_interrupted_at_thread_exit() > { > unique_lock<boost::mutex> lk(mutex); > thread_was_interrupted=true; > if (has_value(lk)) > { > throw_exception(promise_already_satisfied()); > } > detail::make_ready_at_thread_exit(shared_from_this()); > } > > > void set_exception_at_thread_exit(exception_ptr e) > { > unique_lock<boost::mutex> lk(mutex); > if (has_value(lk)) > { > throw_exception(promise_already_satisfied()); > } > exception=e; > this->is_constructed = true; > detail::make_ready_at_thread_exit(shared_from_this()); > > } > > bool has_value() const > { > boost::lock_guard<boost::mutex> lock(mutex); > return done && !(exception > > || thread_was_interrupted > > ); > } > > bool has_value(unique_lock<boost::mutex>& ) const > { > return done && !(exception > > || thread_was_interrupted > > ); > } > > bool has_exception() const > { > boost::lock_guard<boost::mutex> lock(mutex); > return done && (exception > > || thread_was_interrupted > > ); > } > > bool has_exception(unique_lock<boost::mutex>&) const > { > return done && (exception > > || thread_was_interrupted > > ); > } > > bool is_deferred(boost::lock_guard<boost::mutex>&) const { > return is_deferred_; > } > > launch launch_policy(boost::unique_lock<boost::mutex>&) const > { > return policy_; > } > > future_state::state get_state() const > { > boost::lock_guard<boost::mutex> guard(mutex); > if(!done) > { > return future_state::waiting; > } > else > { > return future_state::ready; > } > } > > exception_ptr get_exception_ptr() > { > boost::unique_lock<boost::mutex> lock(mutex); > return get_exception_ptr(lock); > } > exception_ptr get_exception_ptr(boost::unique_lock<boost::mutex>& lock) > { > wait_internal(lock, false); > > if(thread_was_interrupted) > { > return copy_exception(boost::thread_interrupted()); > } > > return exception; > } > > template<typename F,typename U> > void set_wait_callback(F f,U* u) > { > boost::lock_guard<boost::mutex> lock(mutex); > callback=boost::bind(f,boost::ref(*u)); > } > > virtual void execute(boost::unique_lock<boost::mutex>&) {} > > private: > shared_state_base(shared_state_base const&); > shared_state_base& operator=(shared_state_base const&); > }; > > template<typename T> > struct future_traits > { > typedef boost::scoped_ptr<T> storage_type; > struct dummy; > > typedef T const& source_reference_type; > > typedef T && rvalue_source_type; > > typedef T move_dest_type; ># 549 "/usr/include/boost/thread/future.hpp" 3 4 > typedef const T& shared_future_get_result_type; > > static void init(storage_type& storage,source_reference_type t) > { > storage.reset(new T(t)); > } > > static void init(storage_type& storage,rvalue_source_type t) > { > > storage.reset(new T(boost::forward<T>(t))); > > > > } > > static void cleanup(storage_type& storage) > { > storage.reset(); > } > }; > > template<typename T> > struct future_traits<T&> > { > typedef T* storage_type; > typedef T& source_reference_type; > > > typedef T& move_dest_type; > typedef T& shared_future_get_result_type; > > static void init(storage_type& storage,T& t) > { > storage=&t; > } > > static void cleanup(storage_type& storage) > { > storage=0; > } > }; > > template<> > struct future_traits<void> > { > typedef bool storage_type; > typedef void move_dest_type; > typedef void shared_future_get_result_type; > > static void init(storage_type& storage) > { > storage=true; > } > > static void cleanup(storage_type& storage) > { > storage=false; > } > > }; > > > template<typename T> > struct shared_state: > detail::shared_state_base > { > typedef typename future_traits<T>::storage_type storage_type; > typedef typename future_traits<T>::source_reference_type source_reference_type; > typedef typename future_traits<T>::rvalue_source_type rvalue_source_type; > typedef typename future_traits<T>::move_dest_type move_dest_type; > typedef typename future_traits<T>::shared_future_get_result_type shared_future_get_result_type; > > storage_type result; > > shared_state(): > result(0) > {} > > ~shared_state() > {} > > void mark_finished_with_result_internal(source_reference_type result_, boost::unique_lock<boost::mutex>& lock) > { > future_traits<T>::init(result,result_); > this->mark_finished_internal(lock); > } > > void mark_finished_with_result_internal(rvalue_source_type result_, boost::unique_lock<boost::mutex>& lock) > { > > future_traits<T>::init(result,boost::forward<T>(result_)); > > > > this->mark_finished_internal(lock); > } > > void mark_finished_with_result(source_reference_type result_) > { > boost::unique_lock<boost::mutex> lock(mutex); > this->mark_finished_with_result_internal(result_, lock); > } > > void mark_finished_with_result(rvalue_source_type result_) > { > boost::unique_lock<boost::mutex> lock(mutex); > > > mark_finished_with_result_internal(boost::forward<T>(result_), lock); > > > > } > > virtual move_dest_type get() > { > wait(); > return boost::move(*result); > } > > virtual shared_future_get_result_type get_sh() > { > wait(); > return *result; > } > > > void set_value_at_thread_exit(source_reference_type result_) > { > unique_lock<boost::mutex> lk(this->mutex); > if (this->has_value(lk)) > { > throw_exception(promise_already_satisfied()); > } > > result.reset(new T(result_)); > > this->is_constructed = true; > detail::make_ready_at_thread_exit(shared_from_this()); > } > > void set_value_at_thread_exit(rvalue_source_type result_) > { > unique_lock<boost::mutex> lk(this->mutex); > if (this->has_value(lk)) > throw_exception(promise_already_satisfied()); > result.reset(new T(boost::move(result_))); > > this->is_constructed = true; > detail::make_ready_at_thread_exit(shared_from_this()); > } > > > private: > shared_state(shared_state const&); > shared_state& operator=(shared_state const&); > }; > > template<typename T> > struct shared_state<T&>: > detail::shared_state_base > { > typedef typename future_traits<T&>::storage_type storage_type; > typedef typename future_traits<T&>::source_reference_type source_reference_type; > typedef typename future_traits<T&>::move_dest_type move_dest_type; > typedef typename future_traits<T&>::shared_future_get_result_type shared_future_get_result_type; > > T* result; > > shared_state(): > result(0) > {} > > ~shared_state() > { > } > > void mark_finished_with_result_internal(source_reference_type result_, boost::unique_lock<boost::mutex>& lock) > { > > result= &result_; > mark_finished_internal(lock); > } > > void mark_finished_with_result(source_reference_type result_) > { > boost::unique_lock<boost::mutex> lock(mutex); > mark_finished_with_result_internal(result_, lock); > } > > virtual T& get() > { > wait(); > return *result; > } > > virtual T& get_sh() > { > wait(); > return *result; > } > > void set_value_at_thread_exit(T& result_) > { > unique_lock<boost::mutex> lk(this->mutex); > if (this->has_value(lk)) > throw_exception(promise_already_satisfied()); > > result= &result_; > this->is_constructed = true; > detail::make_ready_at_thread_exit(shared_from_this()); > } > > private: > shared_state(shared_state const&); > shared_state& operator=(shared_state const&); > }; > > template<> > struct shared_state<void>: > detail::shared_state_base > { > typedef void shared_future_get_result_type; > > shared_state() > {} > > void mark_finished_with_result_internal(boost::unique_lock<boost::mutex>& lock) > { > mark_finished_internal(lock); > } > > void mark_finished_with_result() > { > boost::unique_lock<boost::mutex> lock(mutex); > mark_finished_with_result_internal(lock); > } > > virtual void get() > { > this->wait(); > } > > virtual void get_sh() > { > wait(); > } > > void set_value_at_thread_exit() > { > unique_lock<boost::mutex> lk(this->mutex); > if (this->has_value(lk)) > { > throw_exception(promise_already_satisfied()); > } > this->is_constructed = true; > detail::make_ready_at_thread_exit(shared_from_this()); > } > private: > shared_state(shared_state const&); > shared_state& operator=(shared_state const&); > }; > > > > > template<typename Rp> > struct future_async_shared_state_base: shared_state<Rp> > { > typedef shared_state<Rp> base_type; > protected: > boost::thread thr_; > void join() > { > if (thr_.joinable()) thr_.join(); > } > public: > future_async_shared_state_base() > { > this->set_async(); > } > explicit future_async_shared_state_base(boost::thread && th) : > thr_(boost::move(th)) > { > this->set_async(); > } > > ~future_async_shared_state_base() > { > join(); > } > > virtual void wait(bool rethrow) > { > join(); > this->base_type::wait(rethrow); > } > }; > > > > > template<typename Rp, typename Fp> > struct future_async_shared_state: future_async_shared_state_base<Rp> > { > typedef future_async_shared_state_base<Rp> base_type; > > public: > explicit future_async_shared_state(Fp && f) : > base_type(thread(&future_async_shared_state::run, this, boost::forward<Fp>(f))) > { > } > > static void run(future_async_shared_state* that, Fp && f) > { > try > { > that->mark_finished_with_result(f()); > } > > catch(thread_interrupted& ) > { > that->mark_interrupted_finish(); > } > > catch(...) > { > that->mark_exceptional_finish(); > } > } > }; > > template<typename Fp> > struct future_async_shared_state<void, Fp>: public future_async_shared_state_base<void> > { > typedef future_async_shared_state_base<void> base_type; > > public: > explicit future_async_shared_state(Fp && f) : > base_type(thread(&future_async_shared_state::run, this, boost::forward<Fp>(f))) > { > } > > static void run(future_async_shared_state* that, Fp && f) > { > try > { > f(); > that->mark_finished_with_result(); > } > > catch(thread_interrupted& ) > { > that->mark_interrupted_finish(); > } > > catch(...) > { > that->mark_exceptional_finish(); > } > } > }; > > template<typename Rp, typename Fp> > struct future_async_shared_state<Rp&, Fp>: future_async_shared_state_base<Rp&> > { > typedef future_async_shared_state_base<Rp&> base_type; > > public: > explicit future_async_shared_state(Fp && f) : > base_type(thread(&future_async_shared_state::run, this, boost::forward<Fp>(f))) > { > } > > static void run(future_async_shared_state* that, Fp && f) > { > try > { > that->mark_finished_with_result(f()); > } > > catch(thread_interrupted& ) > { > that->mark_interrupted_finish(); > } > > catch(...) > { > that->mark_exceptional_finish(); > } > } > }; > > > > > template<typename Rp, typename Fp> > struct future_deferred_shared_state: shared_state<Rp> > { > typedef shared_state<Rp> base_type; > Fp func_; > > public: > explicit future_deferred_shared_state(Fp && f) > : func_(boost::forward<Fp>(f)) > { > this->set_deferred(); > } > > virtual void execute(boost::unique_lock<boost::mutex>& lck) { > try > { > Fp local_fuct=boost::move(func_); > relocker relock(lck); > Rp res = local_fuct(); > relock.lock(); > this->mark_finished_with_result_internal(boost::move(res), lck); > } > catch (...) > { > this->mark_exceptional_finish_internal(current_exception(), lck); > } > } > }; > template<typename Rp, typename Fp> > struct future_deferred_shared_state<Rp&,Fp>: shared_state<Rp&> > { > typedef shared_state<Rp&> base_type; > Fp func_; > > public: > explicit future_deferred_shared_state(Fp && f) > : func_(boost::forward<Fp>(f)) > { > this->set_deferred(); > } > > virtual void execute(boost::unique_lock<boost::mutex>& lck) { > try > { > this->mark_finished_with_result_internal(func_(), lck); > } > catch (...) > { > this->mark_exceptional_finish_internal(current_exception(), lck); > } > } > }; > > template<typename Fp> > struct future_deferred_shared_state<void,Fp>: shared_state<void> > { > typedef shared_state<void> base_type; > Fp func_; > > public: > explicit future_deferred_shared_state(Fp && f) > : func_(boost::forward<Fp>(f)) > { > this->set_deferred(); > } > > virtual void execute(boost::unique_lock<boost::mutex>& lck) { > try > { > Fp local_fuct=boost::move(func_); > relocker relock(lck); > local_fuct(); > relock.lock(); > this->mark_finished_with_result_internal(lck); > } > catch (...) > { > this->mark_exceptional_finish_internal(current_exception(), lck); > } > } > }; ># 1039 "/usr/include/boost/thread/future.hpp" 3 4 > class future_waiter > { > struct registered_waiter; > typedef std::vector<int>::size_type count_type; > > struct registered_waiter > { > boost::shared_ptr<detail::shared_state_base> future_; > detail::shared_state_base::waiter_list::iterator wait_iterator; > count_type index; > > registered_waiter(boost::shared_ptr<detail::shared_state_base> const& a_future, > detail::shared_state_base::waiter_list::iterator wait_iterator_, > count_type index_): > future_(a_future),wait_iterator(wait_iterator_),index(index_) > {} > }; > > struct all_futures_lock > { > > > > typedef count_type count_type_portable; > > count_type_portable count; > boost::scoped_array<boost::unique_lock<boost::mutex> > locks; > > all_futures_lock(std::vector<registered_waiter>& futures): > count(futures.size()),locks(new boost::unique_lock<boost::mutex>[count]) > { > for(count_type_portable i=0;i<count;++i) > { > > > > locks[i]=boost::unique_lock<boost::mutex>(futures[i].future_->mutex); > > } > } > > void lock() > { > boost::lock(locks.get(),locks.get()+count); > } > > void unlock() > { > for(count_type_portable i=0;i<count;++i) > { > locks[i].unlock(); > } > } > }; > > boost::condition_variable_any cv; > std::vector<registered_waiter> futures; > count_type future_count; > > public: > future_waiter(): > future_count(0) > {} > > template<typename F> > void add(F& f) > { > if(f.future_) > { > futures.push_back(registered_waiter(f.future_,f.future_->register_external_waiter(cv),future_count)); > } > ++future_count; > } > > count_type wait() > { > all_futures_lock lk(futures); > for(;;) > { > for(count_type i=0;i<futures.size();++i) > { > if(futures[i].future_->done) > { > return futures[i].index; > } > } > cv.wait(lk); > } > } > > ~future_waiter() > { > for(count_type i=0;i<futures.size();++i) > { > futures[i].future_->remove_external_waiter(futures[i].wait_iterator); > } > } > > }; > > } > > template <typename R> > class unique_future; > > template <typename R> > class shared_future; > > template<typename T> > struct is_future_type > { > static const bool value=false; > typedef void type; > }; > > template<typename T> > struct is_future_type<unique_future<T> > > { > static const bool value=true; > typedef T type; > }; > > template<typename T> > struct is_future_type<shared_future<T> > > { > static const bool value=true; > typedef T type; > }; > > template<typename Iterator> > typename boost::disable_if<is_future_type<Iterator>,void>::type wait_for_all(Iterator begin,Iterator end) > { > for(Iterator current=begin;current!=end;++current) > { > current->wait(); > } > } > > template<typename F1,typename F2> > typename boost::enable_if<is_future_type<F1>,void>::type wait_for_all(F1& f1,F2& f2) > { > f1.wait(); > f2.wait(); > } > > template<typename F1,typename F2,typename F3> > void wait_for_all(F1& f1,F2& f2,F3& f3) > { > f1.wait(); > f2.wait(); > f3.wait(); > } > > template<typename F1,typename F2,typename F3,typename F4> > void wait_for_all(F1& f1,F2& f2,F3& f3,F4& f4) > { > f1.wait(); > f2.wait(); > f3.wait(); > f4.wait(); > } > > template<typename F1,typename F2,typename F3,typename F4,typename F5> > void wait_for_all(F1& f1,F2& f2,F3& f3,F4& f4,F5& f5) > { > f1.wait(); > f2.wait(); > f3.wait(); > f4.wait(); > f5.wait(); > } > > template<typename Iterator> > typename boost::disable_if<is_future_type<Iterator>,Iterator>::type wait_for_any(Iterator begin,Iterator end) > { > if(begin==end) > return end; > > detail::future_waiter waiter; > for(Iterator current=begin;current!=end;++current) > { > waiter.add(*current); > } > return boost::next(begin,waiter.wait()); > } > > template<typename F1,typename F2> > typename boost::enable_if<is_future_type<F1>,unsigned>::type wait_for_any(F1& f1,F2& f2) > { > detail::future_waiter waiter; > waiter.add(f1); > waiter.add(f2); > return waiter.wait(); > } > > template<typename F1,typename F2,typename F3> > unsigned wait_for_any(F1& f1,F2& f2,F3& f3) > { > detail::future_waiter waiter; > waiter.add(f1); > waiter.add(f2); > waiter.add(f3); > return waiter.wait(); > } > > template<typename F1,typename F2,typename F3,typename F4> > unsigned wait_for_any(F1& f1,F2& f2,F3& f3,F4& f4) > { > detail::future_waiter waiter; > waiter.add(f1); > waiter.add(f2); > waiter.add(f3); > waiter.add(f4); > return waiter.wait(); > } > > template<typename F1,typename F2,typename F3,typename F4,typename F5> > unsigned wait_for_any(F1& f1,F2& f2,F3& f3,F4& f4,F5& f5) > { > detail::future_waiter waiter; > waiter.add(f1); > waiter.add(f2); > waiter.add(f3); > waiter.add(f4); > waiter.add(f5); > return waiter.wait(); > } > > template <typename R> > class promise; > > template <typename R> > class packaged_task; > > namespace detail > { > > class base_future > { > > > }; > > template <typename R> > class basic_future : public base_future > { > protected: > public: > > typedef boost::shared_ptr<detail::shared_state<R> > future_ptr; > > future_ptr future_; > > basic_future(future_ptr a_future): > future_(a_future) > { > } > > explicit basic_future(const shared_future<R>&) noexcept; > > public: > typedef future_state::state state; > > > basic_future(): future_() {} > ~basic_future() {} > > basic_future(basic_future && other) noexcept: > future_(other.future_) > { > other.future_.reset(); > } > basic_future& operator=(basic_future && other) noexcept > { > future_=other.future_; > other.future_.reset(); > return *this; > } > void swap(basic_future& that) noexcept > { > future_.swap(that.future_); > } > > state get_state() const > { > if(!future_) > { > return future_state::uninitialized; > } > return future_->get_state(); > } > > bool is_ready() const > { > return get_state()==future_state::ready; > } > > bool has_exception() const > { > return future_ && future_->has_exception(); > } > > bool has_value() const > { > return future_ && future_->has_value(); > } > > launch launch_policy(boost::unique_lock<boost::mutex>& lk) const > { > if ( future_ ) return future_->launch_policy(lk); > else return launch(launch::none); > } > > exception_ptr get_exception_ptr() > { > return future_ > ? future_->get_exception_ptr() > : exception_ptr(); > } > > bool valid() const noexcept > { > return future_ != 0; > } > > > void wait() const > { > if(!future_) > { > boost::throw_exception(future_uninitialized()); > } > future_->wait(false); > } > > > template<typename Duration> > bool timed_wait(Duration const& rel_time) const > { > return timed_wait_until(boost::get_system_time()+rel_time); > } > > bool timed_wait_until(boost::system_time const& abs_time) const > { > if(!future_) > { > boost::throw_exception(future_uninitialized()); > } > return future_->timed_wait_until(abs_time); > } > > > template <class Rep, class Period> > future_status > wait_for(const chrono::duration<Rep, Period>& rel_time) const > { > return wait_until(chrono::steady_clock::now() + rel_time); > > } > template <class Clock, class Duration> > future_status > wait_until(const chrono::time_point<Clock, Duration>& abs_time) const > { > if(!future_) > { > boost::throw_exception(future_uninitialized()); > } > return future_->wait_until(abs_time); > } > > > }; > > } > namespace detail { template <typename R> struct enable_move_utility_emulation_dummy_specialization< detail::basic_future<R> > : integral_constant<bool, false> {}; } > > namespace detail > { > > template <class Rp, class Fp> > unique_future<Rp> > make_future_async_shared_state(Fp && f); > > template <class Rp, class Fp> > unique_future<Rp> > make_future_deferred_shared_state(Fp && f); ># 1447 "/usr/include/boost/thread/future.hpp" 3 4 > } > > template <typename R> > class unique_future : public detail::basic_future<R> > { > private: > typedef detail::basic_future<R> base_type; > typedef typename base_type::future_ptr future_ptr; > > friend class shared_future<R>; > friend class promise<R>; ># 1482 "/usr/include/boost/thread/future.hpp" 3 4 > friend class packaged_task<R>; > > friend class detail::future_waiter; > > template <class Rp, class Fp> > friend unique_future<Rp> > detail::make_future_async_shared_state(Fp && f); > > template <class Rp, class Fp> > friend unique_future<Rp> > detail::make_future_deferred_shared_state(Fp && f); > > > typedef typename detail::future_traits<R>::move_dest_type move_dest_type; > > unique_future(future_ptr a_future): > base_type(a_future) > { > } > > public: > unique_future(unique_future const&) = delete; unique_future& operator=(unique_future const&) = delete; > typedef future_state::state state; > typedef R value_type; > > constexpr unique_future() {} > > ~unique_future() {} > > unique_future(unique_future && other) noexcept: > base_type(boost::move(static_cast<base_type&>(other))) > { > } > inline unique_future(unique_future<unique_future<R> > && other); > > unique_future& operator=(unique_future && other) noexcept > { > this->base_type::operator=(boost::move(static_cast<base_type&>(other))); > return *this; > } > > shared_future<R> share() > { > return shared_future<R>(::boost::move(*this)); > } > > void swap(unique_future& other) > { > static_cast<base_type*>(this)->swap(other); > } > > > void set_async() > { > this->future_->set_async(); > } > > void set_deferred() > { > this->future_->set_deferred(); > } > > > move_dest_type get() > { > if(!this->future_) > { > boost::throw_exception(future_uninitialized()); > } > future_ptr fut_=this->future_; > > > > return fut_->get(); > } > > template <typename R2> > typename boost::disable_if< is_void<R2>, move_dest_type>::type > get_or(R2 && v) > { > if(!this->future_) > { > boost::throw_exception(future_uninitialized()); > } > this->future_->wait(false); > future_ptr fut_=this->future_; > > > > if (fut_->has_value()) { > return fut_->get(); > } > else { > return boost::move(v); > } > } > > template <typename R2> > typename boost::disable_if< is_void<R2>, move_dest_type>::type > get_or(R2 const& v) > { > if(!this->future_) > { > boost::throw_exception(future_uninitialized()); > } > this->future_->wait(false); > future_ptr fut_=this->future_; > > > > if (fut_->has_value()) { > return fut_->get(); > } > else { > return v; > } > } ># 1638 "/usr/include/boost/thread/future.hpp" 3 4 > }; > > namespace detail { template <typename T> struct enable_move_utility_emulation_dummy_specialization< unique_future<T> > : integral_constant<bool, false> {}; } > > template <typename R2> > class unique_future<unique_future<R2> > : public detail::basic_future<unique_future<R2> > > { > typedef unique_future<R2> R; > > private: > typedef detail::basic_future<R> base_type; > typedef typename base_type::future_ptr future_ptr; > > friend class shared_future<R>; > friend class promise<R>; ># 1677 "/usr/include/boost/thread/future.hpp" 3 4 > friend class packaged_task<R>; > > friend class detail::future_waiter; > > template <class Rp, class Fp> > friend unique_future<Rp> > detail::make_future_async_shared_state(Fp && f); > > template <class Rp, class Fp> > friend unique_future<Rp> > detail::make_future_deferred_shared_state(Fp && f); > > > typedef typename detail::future_traits<R>::move_dest_type move_dest_type; > > unique_future(future_ptr a_future): > base_type(a_future) > { > } > > public: > unique_future(unique_future const&) = delete; unique_future& operator=(unique_future const&) = delete; > typedef future_state::state state; > typedef R value_type; > > constexpr unique_future() {} > > ~unique_future() {} > > unique_future(unique_future && other) noexcept: > base_type(boost::move(static_cast<base_type&>(other))) > { > } > > unique_future& operator=(unique_future && other) noexcept > { > this->base_type::operator=(boost::move(static_cast<base_type&>(other))); > return *this; > } > > shared_future<R> share() > { > return shared_future<R>(::boost::move(*this)); > } > > void swap(unique_future& other) > { > static_cast<base_type*>(this)->swap(other); > } > > > void set_async() > { > this->future_->set_async(); > } > > void set_deferred() > { > this->future_->set_deferred(); > } > > > move_dest_type get() > { > if(!this->future_) > { > boost::throw_exception(future_uninitialized()); > } > future_ptr fut_=this->future_; > > > > return fut_->get(); > } > move_dest_type get_or(R && v) > { > if(!this->future_) > { > boost::throw_exception(future_uninitialized()); > } > this->future_->wait(false); > future_ptr fut_=this->future_; > > > > if (fut_->has_value()) return fut_->get(); > else return boost::move(v); > } > > move_dest_type get_or(R const& v) > { > if(!this->future_) > { > boost::throw_exception(future_uninitialized()); > } > this->future_->wait(false); > future_ptr fut_=this->future_; > > > > if (fut_->has_value()) return fut_->get(); > else return v; > } ># 1807 "/usr/include/boost/thread/future.hpp" 3 4 > }; > > template <typename R> > class shared_future : public detail::basic_future<R> > { > > typedef detail::basic_future<R> base_type; > typedef typename base_type::future_ptr future_ptr; > > friend class detail::future_waiter; > friend class promise<R>; ># 1836 "/usr/include/boost/thread/future.hpp" 3 4 > friend class packaged_task<R>; > > shared_future(future_ptr a_future): > base_type(a_future) > {} > > public: > > typedef R value_type; > > shared_future(shared_future const& other): > base_type(other) > {} > > typedef future_state::state state; > > constexpr shared_future() > {} > > ~shared_future() > {} > > shared_future& operator=(shared_future const& other) > { > shared_future(other).swap(*this); > return *this; > } > shared_future(shared_future && other) noexcept : > base_type(boost::move(static_cast<base_type&>(other))) > { > other.future_.reset(); > } > shared_future(unique_future<R> && other) noexcept : > base_type(boost::move(static_cast<base_type&>(other))) > { > } > > shared_future& operator=(shared_future && other) noexcept > { > base_type::operator=(boost::move(static_cast<base_type&>(other))); > return *this; > } > shared_future& operator=(unique_future<R> && other) noexcept > { > base_type::operator=(boost::move(static_cast<base_type&>(other))); > return *this; > } > > void swap(shared_future& other) noexcept > { > static_cast<base_type*>(this)->swap(other); > } > > > typename detail::shared_state<R>::shared_future_get_result_type get() > { > if(!this->future_) > { > boost::throw_exception(future_uninitialized()); > } > > return this->future_->get_sh(); > } > > template <typename R2> > typename boost::disable_if< is_void<R2>, typename detail::shared_state<R>::shared_future_get_result_type>::type > get_or(R2 && v) > { > if(!this->future_) > { > boost::throw_exception(future_uninitialized()); > } > future_ptr fut_=this->future_; > fut_->wait(); > if (fut_->has_value()) return fut_->get_sh(); > else return boost::move(v); > } ># 1943 "/usr/include/boost/thread/future.hpp" 3 4 > }; > > namespace detail { template <typename T> struct enable_move_utility_emulation_dummy_specialization< shared_future<T> > : integral_constant<bool, false> {}; } > > namespace detail > { > > template <typename R> > inline basic_future<R>::basic_future(const shared_future<R>& other) noexcept > : future_(other.future_) > { > } > } > > template <typename R> > class promise > { > typedef boost::shared_ptr<detail::shared_state<R> > future_ptr; > > future_ptr future_; > bool future_obtained; > > void lazy_init() > { > ># 1 "/usr/include/boost/detail/atomic_undef_macros.hpp" 1 3 4 ># 1969 "/usr/include/boost/thread/future.hpp" 2 3 4 > if(!atomic_load(&future_)) > { > future_ptr blank; > atomic_compare_exchange(&future_,&blank,future_ptr(new detail::shared_state<R>)); > } ># 1 "/usr/include/boost/detail/atomic_redef_macros.hpp" 1 3 4 ># 1975 "/usr/include/boost/thread/future.hpp" 2 3 4 > > } > > public: > promise(promise const&) = delete; promise& operator=(promise const&) = delete; ># 1992 "/usr/include/boost/thread/future.hpp" 3 4 > promise(): > > future_(), > > > > future_obtained(false) > {} > > ~promise() > { > if(future_) > { > boost::unique_lock<boost::mutex> lock(future_->mutex); > > if(!future_->done && !future_->is_constructed) > { > future_->mark_exceptional_finish_internal(boost::copy_exception(broken_promise()), lock); > } > } > } > > > promise(promise && rhs) noexcept : > future_(rhs.future_),future_obtained(rhs.future_obtained) > { > rhs.future_.reset(); > rhs.future_obtained=false; > } > promise & operator=(promise && rhs) noexcept > { > future_=rhs.future_; > future_obtained=rhs.future_obtained; > rhs.future_.reset(); > rhs.future_obtained=false; > return *this; > } > > void swap(promise& other) > { > future_.swap(other.future_); > std::swap(future_obtained,other.future_obtained); > } > > > unique_future<R> get_future() > { > lazy_init(); > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > if (future_obtained) > { > boost::throw_exception(future_already_retrieved()); > } > future_obtained=true; > return unique_future<R>(future_); > } > > void set_value(typename detail::future_traits<R>::source_reference_type r) > { > lazy_init(); > boost::unique_lock<boost::mutex> lock(future_->mutex); > if(future_->done) > { > boost::throw_exception(promise_already_satisfied()); > } > future_->mark_finished_with_result_internal(r, lock); > } > > > void set_value(typename detail::future_traits<R>::rvalue_source_type r) > { > lazy_init(); > boost::unique_lock<boost::mutex> lock(future_->mutex); > if(future_->done) > { > boost::throw_exception(promise_already_satisfied()); > } > > future_->mark_finished_with_result_internal(boost::forward<R>(r), lock); > > > > } > > void set_exception(boost::exception_ptr p) > { > lazy_init(); > boost::unique_lock<boost::mutex> lock(future_->mutex); > if(future_->done) > { > boost::throw_exception(promise_already_satisfied()); > } > future_->mark_exceptional_finish_internal(p, lock); > } > template <typename E> > void set_exception(E ex) > { > set_exception(copy_exception(ex)); > } > > void set_value_at_thread_exit(const R& r) > { > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > future_->set_value_at_thread_exit(r); > } > > void set_value_at_thread_exit(R && r) > { > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > future_->set_value_at_thread_exit(boost::move(r)); > } > void set_exception_at_thread_exit(exception_ptr e) > { > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > future_->set_exception_at_thread_exit(e); > } > template <typename E> > void set_exception_at_thread_exit(E ex) > { > set_exception_at_thread_exit(copy_exception(ex)); > } > > template<typename F> > void set_wait_callback(F f) > { > lazy_init(); > future_->set_wait_callback(f,this); > } > > }; > > template <typename R> > class promise<R&> > { > typedef boost::shared_ptr<detail::shared_state<R&> > future_ptr; > > future_ptr future_; > bool future_obtained; > > void lazy_init() > { > ># 1 "/usr/include/boost/detail/atomic_undef_macros.hpp" 1 3 4 ># 2147 "/usr/include/boost/thread/future.hpp" 2 3 4 > if(!atomic_load(&future_)) > { > future_ptr blank; > atomic_compare_exchange(&future_,&blank,future_ptr(new detail::shared_state<R&>)); > } ># 1 "/usr/include/boost/detail/atomic_redef_macros.hpp" 1 3 4 ># 2153 "/usr/include/boost/thread/future.hpp" 2 3 4 > > } > > public: > promise(promise const&) = delete; promise& operator=(promise const&) = delete; ># 2170 "/usr/include/boost/thread/future.hpp" 3 4 > promise(): > > future_(), > > > > future_obtained(false) > {} > > ~promise() > { > if(future_) > { > boost::unique_lock<boost::mutex> lock(future_->mutex); > > if(!future_->done && !future_->is_constructed) > { > future_->mark_exceptional_finish_internal(boost::copy_exception(broken_promise()), lock); > } > } > } > > > promise(promise && rhs) noexcept : > future_(rhs.future_),future_obtained(rhs.future_obtained) > { > rhs.future_.reset(); > rhs.future_obtained=false; > } > promise & operator=(promise && rhs) noexcept > { > future_=rhs.future_; > future_obtained=rhs.future_obtained; > rhs.future_.reset(); > rhs.future_obtained=false; > return *this; > } > > void swap(promise& other) > { > future_.swap(other.future_); > std::swap(future_obtained,other.future_obtained); > } > > > unique_future<R&> get_future() > { > lazy_init(); > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > if (future_obtained) > { > boost::throw_exception(future_already_retrieved()); > } > future_obtained=true; > return unique_future<R&>(future_); > } > > void set_value(R& r) > { > lazy_init(); > boost::unique_lock<boost::mutex> lock(future_->mutex); > if(future_->done) > { > boost::throw_exception(promise_already_satisfied()); > } > future_->mark_finished_with_result_internal(r, lock); > } > > void set_exception(boost::exception_ptr p) > { > lazy_init(); > boost::unique_lock<boost::mutex> lock(future_->mutex); > if(future_->done) > { > boost::throw_exception(promise_already_satisfied()); > } > future_->mark_exceptional_finish_internal(p, lock); > } > template <typename E> > void set_exception(E ex) > { > set_exception(copy_exception(ex)); > } > > > void set_value_at_thread_exit(R& r) > { > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > future_->set_value_at_thread_exit(r); > } > > void set_exception_at_thread_exit(exception_ptr e) > { > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > future_->set_exception_at_thread_exit(e); > } > template <typename E> > void set_exception_at_thread_exit(E ex) > { > set_exception_at_thread_exit(copy_exception(ex)); > } > > template<typename F> > void set_wait_callback(F f) > { > lazy_init(); > future_->set_wait_callback(f,this); > } > > }; > template <> > class promise<void> > { > typedef boost::shared_ptr<detail::shared_state<void> > future_ptr; > > future_ptr future_; > bool future_obtained; > > void lazy_init() > { > > if(!atomic_load(&future_)) > { > future_ptr blank; > atomic_compare_exchange(&future_,&blank,future_ptr(new detail::shared_state<void>)); > } > > } > public: > promise(promise const&) = delete; promise& operator=(promise const&) = delete; ># 2322 "/usr/include/boost/thread/future.hpp" 3 4 > promise(): > > future_(), > > > > future_obtained(false) > {} > > ~promise() > { > if(future_) > { > boost::unique_lock<boost::mutex> lock(future_->mutex); > > if(!future_->done && !future_->is_constructed) > { > future_->mark_exceptional_finish_internal(boost::copy_exception(broken_promise()), lock); > } > } > } > > > promise(promise && rhs) noexcept : > future_(rhs.future_),future_obtained(rhs.future_obtained) > { > > rhs.future_.reset(); > rhs.future_obtained=false; > } > > promise & operator=(promise && rhs) noexcept > { > future_=rhs.future_; > future_obtained=rhs.future_obtained; > rhs.future_.reset(); > rhs.future_obtained=false; > return *this; > } > > void swap(promise& other) > { > future_.swap(other.future_); > std::swap(future_obtained,other.future_obtained); > } > > > unique_future<void> get_future() > { > lazy_init(); > > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > if(future_obtained) > { > boost::throw_exception(future_already_retrieved()); > } > future_obtained=true; > return unique_future<void>(future_); > } > > void set_value() > { > lazy_init(); > boost::unique_lock<boost::mutex> lock(future_->mutex); > if(future_->done) > { > boost::throw_exception(promise_already_satisfied()); > } > future_->mark_finished_with_result_internal(lock); > } > > void set_exception(boost::exception_ptr p) > { > lazy_init(); > boost::unique_lock<boost::mutex> lock(future_->mutex); > if(future_->done) > { > boost::throw_exception(promise_already_satisfied()); > } > future_->mark_exceptional_finish_internal(p,lock); > } > template <typename E> > void set_exception(E ex) > { > set_exception(copy_exception(ex)); > } > > > void set_value_at_thread_exit() > { > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > future_->set_value_at_thread_exit(); > } > > void set_exception_at_thread_exit(exception_ptr e) > { > if (future_.get()==0) > { > boost::throw_exception(promise_moved()); > } > future_->set_exception_at_thread_exit(e); > } > template <typename E> > void set_exception_at_thread_exit(E ex) > { > set_exception_at_thread_exit(copy_exception(ex)); > } > > template<typename F> > void set_wait_callback(F f) > { > lazy_init(); > future_->set_wait_callback(f,this); > } > > }; ># 2455 "/usr/include/boost/thread/future.hpp" 3 4 > namespace detail { template <typename T> struct enable_move_utility_emulation_dummy_specialization< promise<T> > : integral_constant<bool, false> {}; } > > namespace detail > { ># 2470 "/usr/include/boost/thread/future.hpp" 3 4 > template<typename R> > struct task_base_shared_state: > > detail::shared_state<R> > { > bool started; > > task_base_shared_state(): > started(false) > {} > > void reset() > { > started=false; > } > > > > > virtual void do_run()=0; > void run() > > { > { > boost::lock_guard<boost::mutex> lk(this->mutex); > if(started) > { > boost::throw_exception(task_already_started()); > } > started=true; > } > > > > do_run(); > > } > > > > > > virtual void do_apply()=0; > void apply() > > { > { > boost::lock_guard<boost::mutex> lk(this->mutex); > if(started) > { > boost::throw_exception(task_already_started()); > } > started=true; > } > > > > do_apply(); > > } > > void owner_destroyed() > { > boost::unique_lock<boost::mutex> lk(this->mutex); > if(!started) > { > started=true; > this->mark_exceptional_finish_internal(boost::copy_exception(boost::broken_promise()), lk); > } > } > > }; ># 2556 "/usr/include/boost/thread/future.hpp" 3 4 > template<typename F, typename R> > struct task_shared_state: > task_base_shared_state<R> > > { > private: > task_shared_state(task_shared_state&); > public: > F f; > task_shared_state(F const& f_): > f(f_) > {} > task_shared_state(F && f_): > f(boost::move(f_)) > {} ># 2580 "/usr/include/boost/thread/future.hpp" 3 4 > void do_apply() > { > try > { > this->set_value_at_thread_exit(f()); > } > > > catch(thread_interrupted& ) > { > this->set_interrupted_at_thread_exit(); > } > > catch(...) > { > this->set_exception_at_thread_exit(current_exception()); > } > } ># 2607 "/usr/include/boost/thread/future.hpp" 3 4 > void do_run() > { > try > { > > R res((f())); > this->mark_finished_with_result(boost::move(res)); > > > > } > > > catch(thread_interrupted& ) > { > this->mark_interrupted_finish(); > } > > catch(...) > { > this->mark_exceptional_finish(); > } > } > }; ># 2643 "/usr/include/boost/thread/future.hpp" 3 4 > template<typename F, typename R> > struct task_shared_state<F,R&>: > task_base_shared_state<R&> > > { > private: > task_shared_state(task_shared_state&); > public: > F f; > task_shared_state(F const& f_): > f(f_) > {} > task_shared_state(F && f_): > f(boost::move(f_)) > {} ># 2667 "/usr/include/boost/thread/future.hpp" 3 4 > void do_apply() > { > try > { > this->set_value_at_thread_exit(f()); > } > > > catch(thread_interrupted& ) > { > this->set_interrupted_at_thread_exit(); > } > > catch(...) > { > this->set_exception_at_thread_exit(current_exception()); > } > } ># 2694 "/usr/include/boost/thread/future.hpp" 3 4 > void do_run() > { > try > { > R& res((f())); > this->mark_finished_with_result(res); > } > > > catch(thread_interrupted& ) > { > this->mark_interrupted_finish(); > } > > catch(...) > { > this->mark_exceptional_finish(); > } > } > }; ># 2728 "/usr/include/boost/thread/future.hpp" 3 4 > template<typename R> > struct task_shared_state<R (*)(), R> : > task_base_shared_state<R> > > { > private: > task_shared_state(task_shared_state&); > public: > R (*f)(); > task_shared_state(R (*f_)()): > f(f_) > {} ># 2750 "/usr/include/boost/thread/future.hpp" 3 4 > void do_apply() > { > try > { > R r((f())); > this->set_value_at_thread_exit(boost::move(r)); > } > > > catch(thread_interrupted& ) > { > this->set_interrupted_at_thread_exit(); > } > > catch(...) > { > this->set_exception_at_thread_exit(current_exception()); > } > } ># 2779 "/usr/include/boost/thread/future.hpp" 3 4 > void do_run() > { > try > { > R res((f())); > this->mark_finished_with_result(boost::move(res)); > } > > > catch(thread_interrupted& ) > { > this->mark_interrupted_finish(); > } > > catch(...) > { > this->mark_exceptional_finish(); > } > } > }; ># 2810 "/usr/include/boost/thread/future.hpp" 3 4 > template<typename R> > struct task_shared_state<R& (*)(), R&> : > task_base_shared_state<R&> > > { > private: > task_shared_state(task_shared_state&); > public: > R& (*f)(); > task_shared_state(R& (*f_)()): > f(f_) > {} ># 2832 "/usr/include/boost/thread/future.hpp" 3 4 > void do_apply() > { > try > { > this->set_value_at_thread_exit(f()); > } > > > catch(thread_interrupted& ) > { > this->set_interrupted_at_thread_exit(); > } > > catch(...) > { > this->set_exception_at_thread_exit(current_exception()); > } > } ># 2860 "/usr/include/boost/thread/future.hpp" 3 4 > void do_run() > { > try > { > this->mark_finished_with_result(f()); > } > > > catch(thread_interrupted& ) > { > this->mark_interrupted_finish(); > } > > catch(...) > { > this->mark_exceptional_finish(); > } > } > }; ># 2891 "/usr/include/boost/thread/future.hpp" 3 4 > template<typename F> > struct task_shared_state<F,void>: > task_base_shared_state<void> > > { > private: > task_shared_state(task_shared_state&); > public: > F f; > task_shared_state(F const& f_): > f(f_) > {} > task_shared_state(F && f_): > f(boost::move(f_)) > {} ># 2914 "/usr/include/boost/thread/future.hpp" 3 4 > void do_apply() > { > try > { > f(); > > this->set_value_at_thread_exit(); > } > > catch(thread_interrupted& ) > { > this->set_interrupted_at_thread_exit(); > } > > catch(...) > { > this->set_exception_at_thread_exit(current_exception()); > } > } ># 2941 "/usr/include/boost/thread/future.hpp" 3 4 > void do_run() > { > try > { > f(); > > this->mark_finished_with_result(); > } > > catch(thread_interrupted& ) > { > this->mark_interrupted_finish(); > } > > catch(...) > { > this->mark_exceptional_finish(); > } > } > }; ># 2973 "/usr/include/boost/thread/future.hpp" 3 4 > template<> > struct task_shared_state<void (*)(),void>: > task_base_shared_state<void> > > { > private: > task_shared_state(task_shared_state&); > public: > void (*f)(); > task_shared_state(void (*f_)()): > f(f_) > {} ># 2993 "/usr/include/boost/thread/future.hpp" 3 4 > void do_apply() > { > try > { > f(); > > this->set_value_at_thread_exit(); > } > > catch(thread_interrupted& ) > { > this->set_interrupted_at_thread_exit(); > } > > catch(...) > { > this->set_exception_at_thread_exit(current_exception()); > } > } ># 3020 "/usr/include/boost/thread/future.hpp" 3 4 > void do_run() > { > try > { > f(); > > this->mark_finished_with_result(); > } > > catch(thread_interrupted& ) > { > this->mark_interrupted_finish(); > } > > catch(...) > { > this->mark_exceptional_finish(); > } > } > }; > } ># 3057 "/usr/include/boost/thread/future.hpp" 3 4 > template<typename R> > class packaged_task > { > typedef boost::shared_ptr<detail::task_base_shared_state<R> > task_ptr; > boost::shared_ptr<detail::task_base_shared_state<R> > task; > > bool future_obtained; > struct dummy; > > public: > typedef R result_type; > packaged_task(packaged_task const&) = delete; packaged_task& operator=(packaged_task const&) = delete; > > packaged_task(): > future_obtained(false) > {} ># 3096 "/usr/include/boost/thread/future.hpp" 3 4 > explicit packaged_task(R(*f)()) > { > typedef R(*FR)(); > typedef detail::task_shared_state<FR,R> task_shared_state_type; > task= task_ptr(new task_shared_state_type(f)); > future_obtained=false; > } > > > > template <class F> > explicit packaged_task(F && f > , typename boost::disable_if<is_same<typename decay<F>::type, packaged_task>, dummy* >::type=0 > ) > { > typedef typename remove_cv<typename remove_reference<F>::type>::type FR; > > > > > > > > typedef detail::task_shared_state<FR,R> task_shared_state_type; > > task = task_ptr(new task_shared_state_type(boost::forward<F>(f))); > future_obtained = false; > > } ># 3256 "/usr/include/boost/thread/future.hpp" 3 4 > ~packaged_task() > { > if(task) > { > task->owner_destroyed(); > } > } > > > packaged_task(packaged_task && other) noexcept : > future_obtained(other.future_obtained) > { > task.swap(other.task); > other.future_obtained=false; > } > packaged_task& operator=(packaged_task && other) noexcept > { > > > > packaged_task temp(boost::move(other)); > > > > swap(temp); > return *this; > } > > void reset() > { > if (!valid()) > throw future_error(system::make_error_code(future_errc::no_state)); > task->reset(); > future_obtained=false; > } > > void swap(packaged_task& other) noexcept > { > task.swap(other.task); > std::swap(future_obtained,other.future_obtained); > } > bool valid() const noexcept > { > return task.get()!=0; > } > > > unique_future<R> get_future() > { > if(!task) > { > boost::throw_exception(task_moved()); > } > else if(!future_obtained) > { > future_obtained=true; > return unique_future<R>(task); > } > else > { > boost::throw_exception(future_already_retrieved()); > } > > } ># 3344 "/usr/include/boost/thread/future.hpp" 3 4 > void operator()() > { > if(!task) > { > boost::throw_exception(task_moved()); > } > task->run(); > } > void make_ready_at_thread_exit() > { > if(!task) > { > boost::throw_exception(task_moved()); > } > if (task->has_value()) > boost::throw_exception(promise_already_satisfied()); > task->apply(); > } > > template<typename F> > void set_wait_callback(F f) > { > task->set_wait_callback(f,this); > } > }; ># 3379 "/usr/include/boost/thread/future.hpp" 3 4 > namespace detail { template <typename T> struct enable_move_utility_emulation_dummy_specialization< packaged_task<T> > : integral_constant<bool, false> {}; } > > namespace detail > { > > > > template <class Rp, class Fp> > unique_future<Rp> > make_future_deferred_shared_state(Fp && f) > { > shared_ptr<future_deferred_shared_state<Rp, Fp> > > h(new future_deferred_shared_state<Rp, Fp>(boost::forward<Fp>(f))); > return unique_future<Rp>(h); > } > > > > > template <class Rp, class Fp> > unique_future<Rp> > make_future_async_shared_state(Fp && f) > { > shared_ptr<future_async_shared_state<Rp, Fp> > > h(new future_async_shared_state<Rp, Fp>(boost::forward<Fp>(f))); > return unique_future<Rp>(h); > } > > } ># 3433 "/usr/include/boost/thread/future.hpp" 3 4 > template <class R> > unique_future<R> > async(launch policy, R(*f)()) > { > typedef packaged_task<R> packaged_task_type; > > if (int(policy) & int(launch::async)) > { ># 3449 "/usr/include/boost/thread/future.hpp" 3 4 > packaged_task_type pt( f ); > > unique_future<R> ret = pt.get_future(); > ret.set_async(); > boost::thread( boost::move(pt) ).detach(); > return ::boost::move(ret); > > } > else if (int(policy) & int(launch::deferred)) > { ># 3467 "/usr/include/boost/thread/future.hpp" 3 4 > std::terminate(); > unique_future<R> ret; > return ::boost::move(ret); > > > } else { > std::terminate(); > unique_future<R> ret; > return ::boost::move(ret); > } > } ># 3508 "/usr/include/boost/thread/future.hpp" 3 4 > template <class F> > unique_future<typename boost::result_of<typename decay<F>::type()>::type> > async(launch policy, F && f) > { > typedef typename boost::result_of<typename decay<F>::type()>::type R; > typedef packaged_task<R> packaged_task_type; > > > > if (int(policy) & int(launch::async)) > { ># 3527 "/usr/include/boost/thread/future.hpp" 3 4 > packaged_task_type pt( boost::forward<F>(f) ); > > unique_future<R> ret = pt.get_future(); > ret.set_async(); > boost::thread( boost::move(pt) ).detach(); > return ::boost::move(ret); > > } > else if (int(policy) & int(launch::deferred)) > { ># 3545 "/usr/include/boost/thread/future.hpp" 3 4 > std::terminate(); > unique_future<R> ret; > return ::boost::move(ret); > > > > > > > > } else { > std::terminate(); > unique_future<R> ret; > return ::boost::move(ret); > } > } ># 3577 "/usr/include/boost/thread/future.hpp" 3 4 > template <class R> > unique_future<R> > async(R(*f)()) > { > return async(launch(launch::any), f); > } ># 3596 "/usr/include/boost/thread/future.hpp" 3 4 > template <class F> > unique_future<typename boost::result_of<F()>::type> > async(F && f) > { > return async(launch(launch::any), boost::forward<F>(f)); > } > > > > > > > template <typename T> > unique_future<typename decay<T>::type> make_future(T && value) > { > typedef typename decay<T>::type future_value_type; > promise<future_value_type> p; > p.set_value(boost::forward<future_value_type>(value)); > return p.get_future(); > } ># 3629 "/usr/include/boost/thread/future.hpp" 3 4 > template <typename T> > unique_future<typename decay<T>::type> make_ready_future(T && value) > { > typedef typename decay<T>::type future_value_type; > promise<future_value_type> p; > p.set_value(boost::forward<future_value_type>(value)); > return p.get_future(); > } ># 3647 "/usr/include/boost/thread/future.hpp" 3 4 > template <typename T> > unique_future<T> make_ready_future(exception_ptr ex) > { > promise<T> p; > p.set_exception(ex); > return p.get_future(); > } > template <typename T, typename E> > unique_future<T> make_ready_future(E ex) > { > promise<T> p; > p.set_exception(boost::copy_exception(ex)); > return p.get_future(); > } ># 3682 "/usr/include/boost/thread/future.hpp" 3 4 > template <typename T> > shared_future<typename decay<T>::type> make_shared_future(T && value) > { > typedef typename decay<T>::type future_type; > promise<future_type> p; > p.set_value(boost::forward<T>(value)); > return p.get_future().share(); > } > > > inline shared_future<void> make_shared_future() > { > promise<void> p; > return p.get_future().share(); > > } ># 4238 "/usr/include/boost/thread/future.hpp" 3 4 >} ># 25 "/usr/include/boost/thread.hpp" 2 3 4 ># 44 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/usr/include/boost/filesystem.hpp" 1 3 4 ># 15 "/usr/include/boost/filesystem.hpp" 3 4 ># 1 "/usr/include/boost/filesystem/config.hpp" 1 3 4 ># 106 "/usr/include/boost/filesystem/config.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 107 "/usr/include/boost/filesystem/config.hpp" 2 3 4 ># 16 "/usr/include/boost/filesystem.hpp" 2 3 4 ># 1 "/usr/include/boost/filesystem/path.hpp" 1 3 4 ># 25 "/usr/include/boost/filesystem/path.hpp" 3 4 ># 1 "/usr/include/boost/filesystem/path_traits.hpp" 1 3 4 ># 24 "/usr/include/boost/filesystem/path_traits.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cwchar" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cwchar" 3 4 ># 40 "/usr/include/c++/4.9.0/cwchar" 3 > > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 45 "/usr/include/c++/4.9.0/cwchar" 2 3 ># 25 "/usr/include/boost/filesystem/path_traits.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 31 "/usr/include/boost/filesystem/path_traits.hpp" 2 3 4 > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 34 "/usr/include/boost/filesystem/path_traits.hpp" 2 3 4 > >namespace boost { namespace filesystem { > > const system::error_category& codecvt_error_category(); ># 48 "/usr/include/boost/filesystem/path_traits.hpp" 3 4 > class directory_entry; > >namespace path_traits { > > typedef std::codecvt<wchar_t, char, std::mbstate_t> codecvt_type; > > > > template <class T> > struct is_pathable { static const bool value = false; }; > > template<> struct is_pathable<char*> { static const bool value = true; }; > template<> struct is_pathable<const char*> { static const bool value = true; }; > template<> struct is_pathable<wchar_t*> { static const bool value = true; }; > template<> struct is_pathable<const wchar_t*> { static const bool value = true; }; > template<> struct is_pathable<std::string> { static const bool value = true; }; > template<> struct is_pathable<std::wstring> { static const bool value = true; }; > template<> struct is_pathable<std::vector<char> > { static const bool value = true; }; > template<> struct is_pathable<std::vector<wchar_t> > { static const bool value = true; }; > template<> struct is_pathable<std::list<char> > { static const bool value = true; }; > template<> struct is_pathable<std::list<wchar_t> > { static const bool value = true; }; > template<> struct is_pathable<directory_entry> { static const bool value = true; }; > > > > template <class Container> inline > > > typename boost::disable_if<boost::is_array<Container>, bool>::type > empty(const Container & c) > { return c.begin() == c.end(); } > > template <class T> inline > bool empty(T * const & c_str) > { > (static_cast<void> (0)); > return !*c_str; > } > > template <typename T, size_t N> inline > bool empty(T (&x)[N]) > { return !x[0]; } > > > > > > > void convert(const char* from, > const char* from_end, > std::wstring & to, > const codecvt_type& cvt); > > > void convert(const wchar_t* from, > const wchar_t* from_end, > std::string & to, > const codecvt_type& cvt); > > inline > void convert(const char* from, > std::wstring & to, > const codecvt_type& cvt) > { > (static_cast<void> (0)); > convert(from, 0, to, cvt); > } > > inline > void convert(const wchar_t* from, > std::string & to, > const codecvt_type& cvt) > { > (static_cast<void> (0)); > convert(from, 0, to, cvt); > } > > > > > > inline > void convert(const char* from, const char* from_end, std::string & to, > const codecvt_type&) > { > (static_cast<void> (0)); > (static_cast<void> (0)); > to.append(from, from_end); > } > > inline > void convert(const char* from, > std::string & to, > const codecvt_type&) > { > (static_cast<void> (0)); > to += from; > } > > > > inline > void convert(const wchar_t* from, const wchar_t* from_end, std::wstring & to, > const codecvt_type&) > { > (static_cast<void> (0)); > (static_cast<void> (0)); > to.append(from, from_end); > } > > inline > void convert(const wchar_t* from, > std::wstring & to, > const codecvt_type&) > { > (static_cast<void> (0)); > to += from; > } > > > > > template <class U> 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 <class U> 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 <class U> inline > void dispatch(const std::vector<char>& c, U& to, const codecvt_type& cvt) > { > if (c.size()) > convert(&*c.begin(), &*c.begin() + c.size(), to, cvt); > } > template <class U> inline > void dispatch(const std::vector<wchar_t>& c, U& to, const codecvt_type& cvt) > { > if (c.size()) > convert(&*c.begin(), &*c.begin() + c.size(), to, cvt); > } > > > template <class Container, class U> inline > > > typename boost::disable_if<boost::is_array<Container>, void>::type > dispatch(const Container & c, U& to, const codecvt_type& cvt) > { > if (c.size()) > { > std::basic_string<typename Container::value_type> s(c.begin(), c.end()); > convert(s.c_str(), s.c_str()+s.size(), to, cvt); > } > } > > > template <class T, class U> inline > void dispatch(T * const & c_str, U& to, const codecvt_type& cvt) > { > > (static_cast<void> (0)); > convert(c_str, to, cvt); > } > > > > > > void dispatch(const directory_entry & de, > > > > std::string & to, > > const codecvt_type&); > > >}}} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 234 "/usr/include/boost/filesystem/path_traits.hpp" 2 3 4 ># 26 "/usr/include/boost/filesystem/path.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/io/detail/quoted_manip.hpp" 1 3 4 ># 21 "/usr/include/boost/io/detail/quoted_manip.hpp" 3 4 >namespace boost >{ > namespace io > { > namespace detail { template <class String, class Char> struct quoted_proxy; } > > > > > template <class Char, class Traits, class Alloc> > detail::quoted_proxy<std::basic_string<Char, Traits, Alloc> const &, Char> > quoted(const std::basic_string<Char, Traits, Alloc>& s, > Char escape='\\', Char delim='\"'); > > > template <class Char, class Traits, class Alloc> > detail::quoted_proxy<std::basic_string<Char, Traits, Alloc> &, Char> > quoted(std::basic_string<Char, Traits, Alloc>& s, > Char escape='\\', Char delim='\"'); > > > template <class Char> > detail::quoted_proxy<const Char*, Char> > quoted(const Char* s, Char escape='\\', Char delim='\"'); > > > > namespace detail > { > > template <class String, class Char> > struct quoted_proxy > { > String string; > Char escape; > Char delim; > > quoted_proxy(String s_, Char escape_, Char delim_) > : string(s_), escape(escape_), delim(delim_) {} > private: > > quoted_proxy& operator=(const quoted_proxy&); > }; > > > template <class Char, class Traits, class Alloc> > std::basic_ostream<Char, Traits>& > basic_string_inserter_imp(std::basic_ostream<Char, Traits>& os, > std::basic_string<Char, Traits, Alloc> const & string, Char escape, Char delim) > { > os << delim; > typename std::basic_string<Char, Traits, Alloc>::const_iterator > end_it = string.end(); > for (typename std::basic_string<Char, Traits, Alloc>::const_iterator > it = string.begin(); > it != end_it; > ++it ) > { > if (*it == delim || *it == escape) > os << escape; > os << *it; > } > os << delim; > return os; > } > > > template <class Char, class Traits, class Alloc> > inline > std::basic_ostream<Char, Traits>& operator<<(std::basic_ostream<Char, Traits>& os, > const quoted_proxy<std::basic_string<Char, Traits, Alloc> const &, Char>& proxy) > { > return basic_string_inserter_imp(os, proxy.string, proxy.escape, proxy.delim); > } > > > template <class Char, class Traits, class Alloc> > inline > std::basic_ostream<Char, Traits>& operator<<(std::basic_ostream<Char, Traits>& os, > const quoted_proxy<std::basic_string<Char, Traits, Alloc>&, Char>& proxy) > { > return basic_string_inserter_imp(os, proxy.string, proxy.escape, proxy.delim); > } > > > template <class Char, class Traits> > std::basic_ostream<Char, Traits>& operator<<(std::basic_ostream<Char, Traits>& os, > const quoted_proxy<const Char*, Char>& proxy) > { > os << proxy.delim; > for (const Char* it = proxy.string; > *it; > ++it ) > { > if (*it == proxy.delim || *it == proxy.escape) > os << proxy.escape; > os << *it; > } > os << proxy.delim; > return os; > } > > > template <class Char, class Traits, class Alloc> > std::basic_istream<Char, Traits>& operator>>(std::basic_istream<Char, Traits>& is, > const quoted_proxy<std::basic_string<Char, Traits, Alloc>&, Char>& proxy) > { > proxy.string.clear(); > Char c; > is >> c; > if (c != proxy.delim) > { > is.unget(); > is >> proxy.string; > return is; > } > { > boost::io::ios_flags_saver ifs(is); > is >> std::noskipws; > for (;;) > { > is >> c; > if (!is.good()) > break; > if (c == proxy.escape) > { > is >> c; > if (!is.good()) > break; > } > else if (c == proxy.delim) > break; > proxy.string += c; > } > } > return is; > } > > } > > > template <class Char, class Traits, class Alloc> > inline detail::quoted_proxy<std::basic_string<Char, Traits, Alloc> const &, Char> > quoted(const std::basic_string<Char, Traits, Alloc>& s, Char escape, Char delim) > { > return detail::quoted_proxy<std::basic_string<Char, Traits, Alloc> const &, Char> > (s, escape, delim); > } > > > template <class Char, class Traits, class Alloc> > inline detail::quoted_proxy<std::basic_string<Char, Traits, Alloc> &, Char> > quoted(std::basic_string<Char, Traits, Alloc>& s, Char escape, Char delim) > { > return detail::quoted_proxy<std::basic_string<Char, Traits, Alloc>&, Char> > (s, escape, delim); > } > > > template <class Char> > inline detail::quoted_proxy<const Char*, Char> > quoted(const Char* s, Char escape, Char delim) > { > return detail::quoted_proxy<const Char*, Char> (s, escape, delim); > } > > } >} ># 31 "/usr/include/boost/filesystem/path.hpp" 2 3 4 > ># 1 "/usr/include/boost/functional/hash_fwd.hpp" 1 3 4 ># 33 "/usr/include/boost/filesystem/path.hpp" 2 3 4 > > > ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 37 "/usr/include/boost/filesystem/path.hpp" 2 3 4 > > ># 1 "/usr/include/c++/4.9.0/cassert" 1 3 4 ># 41 "/usr/include/c++/4.9.0/cassert" 3 4 ># 42 "/usr/include/c++/4.9.0/cassert" 3 > ># 1 "/usr/include/assert.h" 1 3 4 ># 43 "/usr/include/c++/4.9.0/cassert" 2 3 ># 40 "/usr/include/boost/filesystem/path.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 44 "/usr/include/boost/filesystem/path.hpp" 2 3 4 > >namespace boost >{ >namespace filesystem >{ > > > > > > > class path > { > public: ># 66 "/usr/include/boost/filesystem/path.hpp" 3 4 > typedef char value_type; > static constexpr value_type preferred_separator = '/'; > > typedef std::basic_string<value_type> string_type; > typedef std::codecvt<wchar_t, char, > std::mbstate_t> codecvt_type; ># 130 "/usr/include/boost/filesystem/path.hpp" 3 4 > path(){} > > path(const path& p) : m_pathname(p.m_pathname) {} > > template <class Source> > path(Source const& source, > typename boost::enable_if<path_traits::is_pathable< > typename boost::decay<Source>::type> >::type* =0) > { > path_traits::dispatch(source, m_pathname, codecvt()); > } ># 150 "/usr/include/boost/filesystem/path.hpp" 3 4 > path(const value_type* s) : m_pathname(s) {} > path(const std::basic_string<value_type>& s) : m_pathname(s) {} > > template <class Source> > path(Source const& source, const codecvt_type& cvt) > > { > path_traits::dispatch(source, m_pathname, cvt); > } > > template <class InputIterator> > path(InputIterator begin, InputIterator end) > { > if (begin != end) > { > std::basic_string<typename std::iterator_traits<InputIterator>::value_type> > s(begin, end); > path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, codecvt()); > } > } > > template <class InputIterator> > path(InputIterator begin, InputIterator end, const codecvt_type& cvt) > { > if (begin != end) > { > std::basic_string<typename std::iterator_traits<InputIterator>::value_type> > s(begin, end); > path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); > } > } > > > > path& operator=(const path& p) > { > m_pathname = p.m_pathname; > return *this; > } > > path& operator=(const value_type* ptr) > { > m_pathname = ptr; > return *this; > } > > template <class Source> > typename boost::enable_if<path_traits::is_pathable< > typename boost::decay<Source>::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&) > { > m_pathname = ptr; > return *this; > } > > template <class Source> > path& assign(Source const& source, const codecvt_type& cvt) > { > m_pathname.clear(); > path_traits::dispatch(source, m_pathname, cvt); > return *this; > } > > template <class InputIterator> > path& assign(InputIterator begin, InputIterator end) > { > return assign(begin, end, codecvt()); > } > > template <class InputIterator> > path& assign(InputIterator begin, InputIterator end, const codecvt_type& cvt) > { > m_pathname.clear(); > if (begin != end) > { > std::basic_string<typename std::iterator_traits<InputIterator>::value_type> > s(begin, end); > path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); > } > return *this; > } > > > > 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 <class Source> > typename boost::enable_if<path_traits::is_pathable< > typename boost::decay<Source>::type>, path&>::type > operator+=(Source const& source) > { > return concat(source, codecvt()); > } > > template <class CharT> > typename boost::enable_if<is_integral<CharT>, path&>::type > operator+=(CharT c) > { > CharT tmp[2]; > tmp[0] = c; > tmp[1] = 0; > return concat(tmp, codecvt()); > } > > template <class Source> > path& concat(Source const& source, const codecvt_type& cvt) > { > path_traits::dispatch(source, m_pathname, cvt); > return *this; > } > > template <class InputIterator> > path& concat(InputIterator begin, InputIterator end) > { > return concat(begin, end, codecvt()); > } > > template <class InputIterator> > path& concat(InputIterator begin, InputIterator end, const codecvt_type& cvt) > { > if (begin == end) > return *this; > std::basic_string<typename std::iterator_traits<InputIterator>::value_type> > s(begin, end); > path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); > return *this; > } > > > > > > > path& operator/=(const path& p); > > path& operator/=(const value_type* ptr); > > template <class Source> > typename boost::enable_if<path_traits::is_pathable< > typename boost::decay<Source>::type>, path&>::type > operator/=(Source const& source) > { > return append(source, codecvt()); > } > > path& append(const value_type* ptr, const codecvt_type&) > { > this->operator/=(ptr); > return *this; > } > > template <class Source> > path& append(Source const& source, const codecvt_type& cvt); > > template <class InputIterator> > path& append(InputIterator begin, InputIterator end) > { > return append(begin, end, codecvt()); > } > > template <class InputIterator> > path& append(InputIterator begin, InputIterator end, const codecvt_type& cvt); > > > > void clear() { m_pathname.clear(); } > path& make_preferred() > > { return *this; } > > > > path& remove_filename(); > path& replace_extension(const path& new_extension = path()); > void swap(path& rhs) { m_pathname.swap(rhs.m_pathname); } ># 357 "/usr/include/boost/filesystem/path.hpp" 3 4 > const string_type& native() const { return m_pathname; } > const value_type* c_str() const { return m_pathname.c_str(); } > > template <class String> > String string() const; > > template <class String> > String string(const codecvt_type& cvt) const; ># 383 "/usr/include/boost/filesystem/path.hpp" 3 4 > 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; > } > > > > > > template <class String> > String generic_string() const; > > template <class String> > String generic_string(const codecvt_type& cvt) const; ># 414 "/usr/include/boost/filesystem/path.hpp" 3 4 > 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); } > > > > > > int compare(const path& p) const noexcept; > int compare(const std::string& s) const { return compare(path(s)); } > int compare(const value_type* s) const { return compare(path(s)); } > > > > path root_path() const; > path root_name() const; > > path root_directory() const; > path relative_path() const; > path parent_path() const; > path filename() const; > path stem() const; > path extension() const; > > > > bool empty() const { return m_pathname.empty(); } > 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 > { > > > > return has_root_directory(); > > } > bool is_relative() const { return !is_absolute(); } > > > > class iterator; > typedef iterator const_iterator; > > iterator begin() const; > iterator end() const; > > > > static std::locale imbue(const std::locale& loc); > static const codecvt_type& codecvt(); ># 481 "/usr/include/boost/filesystem/path.hpp" 3 4 > 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(); } ># 515 "/usr/include/boost/filesystem/path.hpp" 3 4 > private: ># 528 "/usr/include/boost/filesystem/path.hpp" 3 4 > string_type m_pathname; > > > > > > string_type::size_type m_append_separator_if_needed(); > > > > void m_erase_redundant_separator(string_type::size_type sep_pos); > string_type::size_type m_parent_path_end() const; > > path& m_normalize(); > > > > friend class iterator; > friend bool operator<(const path& lhs, const path& rhs); > > > static void m_path_iterator_increment(path::iterator & it); > static void m_path_iterator_decrement(path::iterator & it); > > }; > > namespace detail > { > > int lex_compare(path::iterator first1, path::iterator last1, > path::iterator first2, path::iterator last2); > } > > > typedef path wpath; > > > > > > > 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; > } > > > > void increment() { m_path_iterator_increment(*this); } > void decrement() { m_path_iterator_decrement(*this); } > > path m_element; > const path* m_path_ptr; > string_type::size_type m_pos; > > > > > > }; ># 611 "/usr/include/boost/filesystem/path.hpp" 3 4 > 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;} > > > > 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) > { > > > > > > > return hash_range(x.native().begin(), x.native().end()); > > } > > inline void swap(path& lhs, path& rhs) { lhs.swap(rhs); } > > inline path operator/(const path& lhs, const path& rhs) { return path(lhs) /= rhs; } > > > > > > template <class Char, class Traits> > inline std::basic_ostream<Char, Traits>& > operator<<(std::basic_ostream<Char, Traits>& os, const path& p) > { > return os > << boost::io::quoted(p.template string<std::basic_string<Char> >(), static_cast<Char>('&')); > } > > template <class Char, class Traits> > inline std::basic_istream<Char, Traits>& > operator>>(std::basic_istream<Char, Traits>& is, path& p) > { > std::basic_string<Char> str; > is >> boost::io::quoted(str, static_cast<Char>('&')); > p = str; > return is; > } > > > > > > > bool portable_posix_name(const std::string & name); > bool windows_name(const std::string & name); > bool portable_name(const std::string & name); > bool portable_directory_name(const std::string & name); > bool portable_file_name(const std::string & name); > bool native(const std::string & name); > > > > > > template <class InputIterator> > 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<typename std::iterator_traits<InputIterator>::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 <class Source> > 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; > } > > > > > > template <> inline > std::string path::string<std::string>() const > { return string(); } > > template <> inline > std::wstring path::string<std::wstring>() const > { return wstring(); } > > template <> inline > std::string path::string<std::string>(const codecvt_type& cvt) const > { return string(cvt); } > > template <> inline > std::wstring path::string<std::wstring>(const codecvt_type& cvt) const > { return wstring(cvt); } > > template <> inline > std::string path::generic_string<std::string>() const > { return generic_string(); } > > template <> inline > std::wstring path::generic_string<std::wstring>() const > { return generic_wstring(); } > > template <> inline > std::string path::generic_string<std::string>(const codecvt_type& cvt) const > { return generic_string(cvt); } > > template <> inline > std::wstring path::generic_string<std::wstring>(const codecvt_type& cvt) const > { return generic_wstring(cvt); } > > >} >} > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 757 "/usr/include/boost/filesystem/path.hpp" 2 3 4 ># 17 "/usr/include/boost/filesystem.hpp" 2 3 4 ># 1 "/usr/include/boost/filesystem/operations.hpp" 1 3 4 ># 28 "/usr/include/boost/filesystem/operations.hpp" 3 4 ># 1 "/usr/include/boost/detail/bitmask.hpp" 1 3 4 ># 18 "/usr/include/boost/detail/bitmask.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 19 "/usr/include/boost/detail/bitmask.hpp" 2 3 4 ># 29 "/usr/include/boost/filesystem/operations.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 36 "/usr/include/boost/filesystem/operations.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 37 "/usr/include/boost/filesystem/operations.hpp" 2 3 4 > > > ># 1 "/usr/include/c++/4.9.0/ctime" 1 3 4 ># 39 "/usr/include/c++/4.9.0/ctime" 3 4 ># 40 "/usr/include/c++/4.9.0/ctime" 3 ># 41 "/usr/include/boost/filesystem/operations.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/stack" 1 3 4 ># 58 "/usr/include/c++/4.9.0/stack" 3 4 ># 59 "/usr/include/c++/4.9.0/stack" 3 > > ># 1 "/usr/include/c++/4.9.0/bits/stl_stack.h" 1 3 ># 62 "/usr/include/c++/4.9.0/bits/stl_stack.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 95 "/usr/include/c++/4.9.0/bits/stl_stack.h" 3 > template<typename _Tp, typename _Sequence = deque<_Tp> > > class stack > { > > typedef typename _Sequence::value_type _Sequence_value_type; > > > > > template<typename _Tp1, typename _Seq1> > friend bool > operator==(const stack<_Tp1, _Seq1>&, const stack<_Tp1, _Seq1>&); > > template<typename _Tp1, typename _Seq1> > friend bool > operator<(const stack<_Tp1, _Seq1>&, const stack<_Tp1, _Seq1>&); > > public: > typedef typename _Sequence::value_type value_type; > typedef typename _Sequence::reference reference; > typedef typename _Sequence::const_reference const_reference; > typedef typename _Sequence::size_type size_type; > typedef _Sequence container_type; > > protected: > > _Sequence c; > > public: ># 133 "/usr/include/c++/4.9.0/bits/stl_stack.h" 3 > explicit > stack(const _Sequence& __c) > : c(__c) { } > > explicit > stack(_Sequence&& __c = _Sequence()) > : c(std::move(__c)) { } > > > > > > bool > empty() const > { return c.empty(); } > > > size_type > size() const > { return c.size(); } > > > > > > reference > top() > { > ; > return c.back(); > } > > > > > > const_reference > top() const > { > ; > return c.back(); > } ># 185 "/usr/include/c++/4.9.0/bits/stl_stack.h" 3 > void > push(const value_type& __x) > { c.push_back(__x); } > > > void > push(value_type&& __x) > { c.push_back(std::move(__x)); } > > template<typename... _Args> > void > emplace(_Args&&... __args) > { c.emplace_back(std::forward<_Args>(__args)...); } ># 211 "/usr/include/c++/4.9.0/bits/stl_stack.h" 3 > void > pop() > { > ; > c.pop_back(); > } > > > void > swap(stack& __s) > noexcept(noexcept(swap(c, __s.c))) > { > using std::swap; > swap(c, __s.c); > } > > }; ># 241 "/usr/include/c++/4.9.0/bits/stl_stack.h" 3 > template<typename _Tp, typename _Seq> > inline bool > operator==(const stack<_Tp, _Seq>& __x, const stack<_Tp, _Seq>& __y) > { return __x.c == __y.c; } ># 259 "/usr/include/c++/4.9.0/bits/stl_stack.h" 3 > template<typename _Tp, typename _Seq> > inline bool > operator<(const stack<_Tp, _Seq>& __x, const stack<_Tp, _Seq>& __y) > { return __x.c < __y.c; } > > > template<typename _Tp, typename _Seq> > inline bool > operator!=(const stack<_Tp, _Seq>& __x, const stack<_Tp, _Seq>& __y) > { return !(__x == __y); } > > > template<typename _Tp, typename _Seq> > inline bool > operator>(const stack<_Tp, _Seq>& __x, const stack<_Tp, _Seq>& __y) > { return __y < __x; } > > > template<typename _Tp, typename _Seq> > inline bool > operator<=(const stack<_Tp, _Seq>& __x, const stack<_Tp, _Seq>& __y) > { return !(__y < __x); } > > > template<typename _Tp, typename _Seq> > inline bool > operator>=(const stack<_Tp, _Seq>& __x, const stack<_Tp, _Seq>& __y) > { return !(__x < __y); } > > > template<typename _Tp, typename _Seq> > inline void > swap(stack<_Tp, _Seq>& __x, stack<_Tp, _Seq>& __y) > noexcept(noexcept(__x.swap(__y))) > { __x.swap(__y); } > > template<typename _Tp, typename _Seq, typename _Alloc> > struct uses_allocator<stack<_Tp, _Seq>, _Alloc> > : public uses_allocator<_Seq, _Alloc>::type { }; > > > >} ># 62 "/usr/include/c++/4.9.0/stack" 2 3 ># 43 "/usr/include/boost/filesystem/operations.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 49 "/usr/include/boost/filesystem/operations.hpp" 2 3 4 > > > >namespace boost >{ > namespace filesystem > { > > > > > > enum file_type > { > status_error, > > status_unknown = status_error, > > file_not_found, > regular_file, > directory_file, > > symlink_file, > block_file, > character_file, > fifo_file, > socket_file, > reparse_file, > type_unknown, > > > _detail_directory_symlink > }; > > > > > > enum perms > { > no_perms = 0, > > > > > > > owner_read = 0400, > owner_write = 0200, > owner_exe = 0100, > owner_all = 0700, > > group_read = 040, > group_write = 020, > group_exe = 010, > group_all = 070, > > others_read = 04, > others_write = 02, > others_exe = 01, > others_all = 07, > > all_all = owner_all|group_all|others_all, > > > > set_uid_on_exe = 04000, > set_gid_on_exe = 02000, > sticky_bit = 01000, > > > > > > > perms_mask = all_all|set_uid_on_exe|set_gid_on_exe|sticky_bit, > > perms_not_known = 0xFFFF, > > > > add_perms = 0x1000, > remove_perms = 0x2000, > > > > > symlink_perms = 0x4000 > }; > > inline perms operator| (perms x , perms y ) { return static_cast<perms>( static_cast<boost::int_least32_t>(x) | static_cast<boost::int_least32_t>(y)); } inline perms operator& (perms x , perms y ) { return static_cast<perms>( static_cast<boost::int_least32_t>(x) & static_cast<boost::int_least32_t>(y)); } inline perms operator^ (perms x , perms y ) { return static_cast<perms>( static_cast<boost::int_least32_t>(x) ^ static_cast<boost::int_least32_t>(y)); } inline perms operator~ (perms x ) { return static_cast<perms>(~static_cast<boost::int_least32_t>(x)); } inline perms & operator&=(perms & x , perms y) { x = x & y ; return x ; } inline perms & operator|=(perms & x , perms y) { x = x | y ; return x ; } inline perms & operator^=(perms & x , perms y) { x = x ^ y ; return x ; } > > > > > > class 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) {} > > > file_type type() const { return m_value; } > perms permissions() const { return m_perms; } > > > 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); } > > > inline bool is_regular(file_status f) { return f.type() == regular_file; } > > > struct space_info > { > > boost::uintmax_t capacity; > boost::uintmax_t free; > boost::uintmax_t available; > }; > > enum class copy_option > {none, fail_if_exists = none, overwrite_if_exists}; > > > > > > > namespace detail > { > > file_status status(const path&p, system::error_code* ec=0); > > file_status symlink_status(const path& p, system::error_code* ec=0); > > bool is_empty(const path& p, system::error_code* ec=0); > > path initial_path(system::error_code* ec=0); > > path canonical(const path& p, const path& base, system::error_code* ec=0); > > void copy(const path& from, const path& to, system::error_code* ec=0); > > void copy_directory(const path& from, const path& to, system::error_code* ec=0); > > void copy_file(const path& from, const path& to, > copy_option option, > system::error_code* ec=0); > > void copy_symlink(const path& existing_symlink, const path& new_symlink, system::error_code* ec=0); > > bool create_directories(const path& p, system::error_code* ec=0); > > bool create_directory(const path& p, system::error_code* ec=0); > > void create_directory_symlink(const path& to, const path& from, > system::error_code* ec=0); > > void create_hard_link(const path& to, const path& from, system::error_code* ec=0); > > void create_symlink(const path& to, const path& from, system::error_code* ec=0); > > path current_path(system::error_code* ec=0); > > void current_path(const path& p, system::error_code* ec=0); > > bool equivalent(const path& p1, const path& p2, system::error_code* ec=0); > > boost::uintmax_t file_size(const path& p, system::error_code* ec=0); > > boost::uintmax_t hard_link_count(const path& p, system::error_code* ec=0); > > std::time_t last_write_time(const path& p, system::error_code* ec=0); > > void last_write_time(const path& p, const std::time_t new_time, > system::error_code* ec=0); > > void permissions(const path& p, perms prms, system::error_code* ec=0); > > path read_symlink(const path& p, system::error_code* ec=0); > > > bool remove(const path& p, system::error_code* ec=0); > > boost::uintmax_t remove_all(const path& p, system::error_code* ec=0); > > void rename(const path& old_p, const path& new_p, system::error_code* ec=0); > > void resize_file(const path& p, uintmax_t size, system::error_code* ec=0); > > space_info space(const path& p, system::error_code* ec=0); > > path system_complete(const path& p, system::error_code* ec=0); > > path temp_directory_path(system::error_code* ec=0); > > path unique_path(const path& p, system::error_code* ec=0); > } > > > > > > > > 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));} > > 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));} > > > 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);} ># 335 "/usr/include/boost/filesystem/operations.hpp" 3 4 > path current_path(); > path initial_path(); > > > path absolute(const path& p, const path& base=current_path()); > > > 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);} > > > inline > path complete(const path& p) > { > return absolute(p, initial_path()); > } > > inline > path complete(const path& p, const path& base) > { > return absolute(p, base); > } > > > 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, > 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, > 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 <class Path> > path initial_path() {return initial_path();} > template <class Path> > 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 > > 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 > 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);} > > > inline bool symbolic_link_exists(const path& p) > { return is_symlink(symlink_status(p)); } > > > 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); } ># 559 "/usr/include/boost/filesystem/operations.hpp" 3 4 >class directory_entry >{ >public: > > > > 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; > } > > > void replace_leaf(const boost::filesystem::path& p, > file_status st, file_status symlink_st) > { replace_filename(p, st, symlink_st); } > > > 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; > mutable file_status m_symlink_status; > > file_status m_get_status(system::error_code* ec=0) const; > file_status m_get_symlink_status(system::error_code* ec=0) const; >}; > > > > > > > >class directory_iterator; > >namespace detail >{ > > system::error_code dir_itr_close( > void *& handle > > , void *& buffer > > ); > > struct dir_itr_imp > { > directory_entry dir_entry; > void* handle; > > > void* buffer; > > > dir_itr_imp() : handle(0) > > , buffer(0) > > {} > > ~dir_itr_imp() > { > dir_itr_close(handle > > , buffer > > ); > } > }; > > > void directory_iterator_construct(directory_iterator& it, > const path& p, system::error_code* ec); > void directory_iterator_increment(directory_iterator& it, > system::error_code* ec); > >} > > > > > > > > class directory_iterator > : public boost::iterator_facade< directory_iterator, > directory_entry, > boost::single_pass_traversal_tag > > { > public: > > directory_iterator(){} > > > > 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() {} > > directory_iterator& increment(system::error_code& ec) > { > detail::directory_iterator_increment(*this, &ec); > return *this; > } > > private: > friend struct detail::dir_itr_imp; > friend void detail::directory_iterator_construct(directory_iterator& it, > const path& p, system::error_code* ec); > friend void detail::directory_iterator_increment(directory_iterator& it, > system::error_code* ec); > > > > 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 > { > ((void)0); > 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; } > }; > > > > > > > > enum class symlink_option > { > none, > no_recurse = none, > recurse, > _detail_no_push = recurse << 1 > }; > > > inline symlink_option operator| (symlink_option x , symlink_option y ) { return static_cast<symlink_option>( static_cast<boost::int_least32_t>(x) | static_cast<boost::int_least32_t>(y)); } inline symlink_option operator& (symlink_option x , symlink_option y ) { return static_cast<symlink_option>( static_cast<boost::int_least32_t>(x) & static_cast<boost::int_least32_t>(y)); } inline symlink_option operator^ (symlink_option x , symlink_option y ) { return static_cast<symlink_option>( static_cast<boost::int_least32_t>(x) ^ static_cast<boost::int_least32_t>(y)); } inline symlink_option operator~ (symlink_option x ) { return static_cast<symlink_option>(~static_cast<boost::int_least32_t>(x)); } inline symlink_option & operator&=(symlink_option & x , symlink_option y) { x = x & y ; return x ; } inline symlink_option & operator|=(symlink_option & x , symlink_option y) { x = x | y ; return x ; } inline symlink_option & operator^=(symlink_option & x , symlink_option y) { x = x ^ y ; return x ; } > > 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; > symlink_option m_options; > > recur_dir_itr_imp() : m_level(0), m_options(symlink_option::none) {} > > void increment(system::error_code* ec); > > void pop(); > > }; > > > > > > inline > void recur_dir_itr_imp::increment(system::error_code* ec) > > { > if ((m_options & symlink_option::_detail_no_push) == symlink_option::_detail_no_push) > m_options &= ~symlink_option::_detail_no_push; > > else > { > > > > > > > > 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() > { > ((void)0) > ; > > do > { > m_stack.pop(); > --m_level; > } > while (!m_stack.empty() && ++m_stack.top() == directory_iterator()); > } > } > > > > > > > > class recursive_directory_iterator > : public boost::iterator_facade< > recursive_directory_iterator, > directory_entry, > boost::single_pass_traversal_tag > > { > public: > > recursive_directory_iterator(){} > > explicit recursive_directory_iterator(const path& dir_path, > 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, > 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) > { > ((void)0) > ; > m_imp->increment(&ec); > if (m_imp->m_stack.empty()) > m_imp.reset(); > return *this; > } > > int level() const > { > ((void)0) > ; > return m_imp->m_level; > } > > bool no_push_pending() const > { > ((void)0) > ; > return (m_imp->m_options & symlink_option::_detail_no_push) > == symlink_option::_detail_no_push; > } > > > bool no_push_request() const { return no_push_pending(); } > > > void pop() > { > ((void)0) > ; > m_imp->pop(); > if (m_imp->m_stack.empty()) m_imp.reset(); > } > > void no_push(bool value=true) > { > ((void)0) > ; > 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 > { > ((void)0) > ; > return m_imp->m_stack.top()->status(); > } > > file_status symlink_status() const > { > ((void)0) > ; > return m_imp->m_stack.top()->symlink_status(); > } > > private: > > > > 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 > { > ((void)0) > ; > return *m_imp->m_stack.top(); > } > > void increment() > { > ((void)0) > ; > m_imp->increment(0); > if (m_imp->m_stack.empty()) > m_imp.reset(); > } > > bool equal(const recursive_directory_iterator& rhs) const > { return m_imp == rhs.m_imp; } > > }; > > > typedef recursive_directory_iterator wrecursive_directory_iterator; ># 980 "/usr/include/boost/filesystem/operations.hpp" 3 4 > class __attribute__((__visibility__("default"))) filesystem_error : public system::system_error > { > > > > > public: > > > 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; > path m_path2; > std::string m_what; > }; > boost::shared_ptr<m_imp> m_imp_ptr; > }; > > > > > > > > namespace detail > { > bool possible_large_file_size_support(); > } > > } >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 1096 "/usr/include/boost/filesystem/operations.hpp" 2 3 4 ># 18 "/usr/include/boost/filesystem.hpp" 2 3 4 ># 1 "/usr/include/boost/filesystem/convenience.hpp" 1 3 4 ># 25 "/usr/include/boost/filesystem/convenience.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 26 "/usr/include/boost/filesystem/convenience.hpp" 2 3 4 > >namespace boost >{ > namespace filesystem > { > > > > 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; > } > > > > > } >} > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 58 "/usr/include/boost/filesystem/convenience.hpp" 2 3 4 ># 19 "/usr/include/boost/filesystem.hpp" 2 3 4 ># 45 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/usr/include/boost/algorithm/string.hpp" 1 3 4 ># 18 "/usr/include/boost/algorithm/string.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/std_containers_traits.hpp" 1 3 4 ># 19 "/usr/include/boost/algorithm/string/std_containers_traits.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/std/string_traits.hpp" 1 3 4 ># 14 "/usr/include/boost/algorithm/string/std/string_traits.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/yes_no_type.hpp" 1 3 4 ># 14 "/usr/include/boost/algorithm/string/yes_no_type.hpp" 3 4 >namespace boost { > namespace algorithm { > > > > > > template<int I> struct size_descriptor > { > typedef char (& type)[I]; > }; > > typedef size_descriptor<1>::type yes_type; > typedef size_descriptor<2>::type no_type; > > } >} ># 15 "/usr/include/boost/algorithm/string/std/string_traits.hpp" 2 3 4 > ># 1 "/usr/include/boost/algorithm/string/sequence_traits.hpp" 1 3 4 ># 34 "/usr/include/boost/algorithm/string/sequence_traits.hpp" 3 4 >namespace boost { > namespace algorithm { ># 85 "/usr/include/boost/algorithm/string/sequence_traits.hpp" 3 4 > template< typename T > > class has_native_replace > { ># 96 "/usr/include/boost/algorithm/string/sequence_traits.hpp" 3 4 > public: > > > > static const bool value=false; > > > > > typedef mpl::bool_<has_native_replace<T>::value> type; > }; > > > > > > > > template< typename T > > class has_stable_iterators > { > > > > > > > > public: > > > > static const bool value=false; > > > > typedef mpl::bool_<has_stable_iterators<T>::value> type; > }; > > > > > > > > template< typename T > > class has_const_time_insert > { > > > > > > > > public: > > > > static const bool value=false; > > > > typedef mpl::bool_<has_const_time_insert<T>::value> type; > }; > > > > > > > > template< typename T > > class has_const_time_erase > { > > > > > > > > public: > > > > static const bool value=false; > > > > typedef mpl::bool_<has_const_time_erase<T>::value> type; > }; > > } >} ># 17 "/usr/include/boost/algorithm/string/std/string_traits.hpp" 2 3 4 > >namespace boost { > namespace algorithm { ># 32 "/usr/include/boost/algorithm/string/std/string_traits.hpp" 3 4 > template<typename T, typename TraitsT, typename AllocT> > class has_native_replace< std::basic_string<T, TraitsT, AllocT> > > { > public: > > > > static const bool value=true; > > > typedef mpl::bool_<has_native_replace<T>::value> type; > }; > > > > > } >} ># 20 "/usr/include/boost/algorithm/string/std_containers_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/std/list_traits.hpp" 1 3 4 ># 18 "/usr/include/boost/algorithm/string/std/list_traits.hpp" 3 4 >namespace boost { > namespace algorithm { ># 41 "/usr/include/boost/algorithm/string/std/list_traits.hpp" 3 4 > template<typename T, typename AllocT> > class has_stable_iterators< ::std::list<T,AllocT> > > { > public: > > > > static const bool value=true; > > typedef mpl::bool_<has_stable_iterators<T>::value> type; > }; > > > template<typename T, typename AllocT> > class has_const_time_insert< ::std::list<T,AllocT> > > { > public: > > > > static const bool value=true; > > typedef mpl::bool_<has_const_time_insert<T>::value> type; > }; > > > template<typename T, typename AllocT> > class has_const_time_erase< ::std::list<T,AllocT> > > { > public: > > > > static const bool value=true; > > typedef mpl::bool_<has_const_time_erase<T>::value> type; > }; > > > > } >} ># 21 "/usr/include/boost/algorithm/string/std_containers_traits.hpp" 2 3 4 > > ># 1 "/usr/include/boost/algorithm/string/std/slist_traits.hpp" 1 3 4 ># 14 "/usr/include/boost/algorithm/string/std/slist_traits.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/config.hpp" 1 3 4 ># 15 "/usr/include/boost/algorithm/string/std/slist_traits.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/ext/slist" 1 3 4 ># 53 "/usr/include/c++/4.9.0/ext/slist" 3 4 >namespace __gnu_cxx __attribute__ ((__visibility__ ("default"))) >{ > > > using std::size_t; > using std::ptrdiff_t; > using std::_Construct; > using std::_Destroy; > using std::allocator; > using std::__true_type; > using std::__false_type; > > struct _Slist_node_base > { > _Slist_node_base* _M_next; > }; > > inline _Slist_node_base* > __slist_make_link(_Slist_node_base* __prev_node, > _Slist_node_base* __new_node) > { > __new_node->_M_next = __prev_node->_M_next; > __prev_node->_M_next = __new_node; > return __new_node; > } > > inline _Slist_node_base* > __slist_previous(_Slist_node_base* __head, > const _Slist_node_base* __node) > { > while (__head && __head->_M_next != __node) > __head = __head->_M_next; > return __head; > } > > inline const _Slist_node_base* > __slist_previous(const _Slist_node_base* __head, > const _Slist_node_base* __node) > { > while (__head && __head->_M_next != __node) > __head = __head->_M_next; > return __head; > } > > inline void > __slist_splice_after(_Slist_node_base* __pos, > _Slist_node_base* __before_first, > _Slist_node_base* __before_last) > { > if (__pos != __before_first && __pos != __before_last) > { > _Slist_node_base* __first = __before_first->_M_next; > _Slist_node_base* __after = __pos->_M_next; > __before_first->_M_next = __before_last->_M_next; > __pos->_M_next = __first; > __before_last->_M_next = __after; > } > } > > inline void > __slist_splice_after(_Slist_node_base* __pos, _Slist_node_base* __head) > { > _Slist_node_base* __before_last = __slist_previous(__head, 0); > if (__before_last != __head) > { > _Slist_node_base* __after = __pos->_M_next; > __pos->_M_next = __head->_M_next; > __head->_M_next = 0; > __before_last->_M_next = __after; > } > } > > inline _Slist_node_base* > __slist_reverse(_Slist_node_base* __node) > { > _Slist_node_base* __result = __node; > __node = __node->_M_next; > __result->_M_next = 0; > while(__node) > { > _Slist_node_base* __next = __node->_M_next; > __node->_M_next = __result; > __result = __node; > __node = __next; > } > return __result; > } > > inline size_t > __slist_size(_Slist_node_base* __node) > { > size_t __result = 0; > for (; __node != 0; __node = __node->_M_next) > ++__result; > return __result; > } > > template <class _Tp> > struct _Slist_node : public _Slist_node_base > { > _Tp _M_data; > }; > > struct _Slist_iterator_base > { > typedef size_t size_type; > typedef ptrdiff_t difference_type; > typedef std::forward_iterator_tag iterator_category; > > _Slist_node_base* _M_node; > > _Slist_iterator_base(_Slist_node_base* __x) > : _M_node(__x) {} > > void > _M_incr() > { _M_node = _M_node->_M_next; } > > bool > operator==(const _Slist_iterator_base& __x) const > { return _M_node == __x._M_node; } > > bool > operator!=(const _Slist_iterator_base& __x) const > { return _M_node != __x._M_node; } > }; > > template <class _Tp, class _Ref, class _Ptr> > struct _Slist_iterator : public _Slist_iterator_base > { > typedef _Slist_iterator<_Tp, _Tp&, _Tp*> iterator; > typedef _Slist_iterator<_Tp, const _Tp&, const _Tp*> const_iterator; > typedef _Slist_iterator<_Tp, _Ref, _Ptr> _Self; > > typedef _Tp value_type; > typedef _Ptr pointer; > typedef _Ref reference; > typedef _Slist_node<_Tp> _Node; > > explicit > _Slist_iterator(_Node* __x) > : _Slist_iterator_base(__x) {} > > _Slist_iterator() > : _Slist_iterator_base(0) {} > > _Slist_iterator(const iterator& __x) > : _Slist_iterator_base(__x._M_node) {} > > reference > operator*() const > { return ((_Node*) _M_node)->_M_data; } > > pointer > operator->() const > { return &(operator*()); } > > _Self& > operator++() > { > _M_incr(); > return *this; > } > > _Self > operator++(int) > { > _Self __tmp = *this; > _M_incr(); > return __tmp; > } > }; > > template <class _Tp, class _Alloc> > struct _Slist_base > : public _Alloc::template rebind<_Slist_node<_Tp> >::other > { > typedef typename _Alloc::template rebind<_Slist_node<_Tp> >::other > _Node_alloc; > typedef _Alloc allocator_type; > > allocator_type > get_allocator() const > { return *static_cast<const _Node_alloc*>(this); } > > _Slist_base(const allocator_type& __a) > : _Node_alloc(__a) > { this->_M_head._M_next = 0; } > > ~_Slist_base() > { _M_erase_after(&this->_M_head, 0); } > > protected: > _Slist_node_base _M_head; > > _Slist_node<_Tp>* > _M_get_node() > { return _Node_alloc::allocate(1); } > > void > _M_put_node(_Slist_node<_Tp>* __p) > { _Node_alloc::deallocate(__p, 1); } > > protected: > _Slist_node_base* _M_erase_after(_Slist_node_base* __pos) > { > _Slist_node<_Tp>* __next = (_Slist_node<_Tp>*) (__pos->_M_next); > _Slist_node_base* __next_next = __next->_M_next; > __pos->_M_next = __next_next; > get_allocator().destroy(&__next->_M_data); > _M_put_node(__next); > return __next_next; > } > _Slist_node_base* _M_erase_after(_Slist_node_base*, _Slist_node_base*); > }; > > template <class _Tp, class _Alloc> > _Slist_node_base* > _Slist_base<_Tp,_Alloc>::_M_erase_after(_Slist_node_base* __before_first, > _Slist_node_base* __last_node) > { > _Slist_node<_Tp>* __cur = (_Slist_node<_Tp>*) (__before_first->_M_next); > while (__cur != __last_node) > { > _Slist_node<_Tp>* __tmp = __cur; > __cur = (_Slist_node<_Tp>*) __cur->_M_next; > get_allocator().destroy(&__tmp->_M_data); > _M_put_node(__tmp); > } > __before_first->_M_next = __last_node; > return __last_node; > } > > > > > > > template <class _Tp, class _Alloc = allocator<_Tp> > > class slist : private _Slist_base<_Tp,_Alloc> > { > > > > private: > typedef _Slist_base<_Tp,_Alloc> _Base; > > public: > typedef _Tp value_type; > typedef value_type* pointer; > typedef const value_type* const_pointer; > typedef value_type& reference; > typedef const value_type& const_reference; > typedef size_t size_type; > typedef ptrdiff_t difference_type; > > typedef _Slist_iterator<_Tp, _Tp&, _Tp*> iterator; > typedef _Slist_iterator<_Tp, const _Tp&, const _Tp*> const_iterator; > > typedef typename _Base::allocator_type allocator_type; > > allocator_type > get_allocator() const > { return _Base::get_allocator(); } > > private: > typedef _Slist_node<_Tp> _Node; > typedef _Slist_node_base _Node_base; > typedef _Slist_iterator_base _Iterator_base; > > _Node* > _M_create_node(const value_type& __x) > { > _Node* __node = this->_M_get_node(); > try > { > get_allocator().construct(&__node->_M_data, __x); > __node->_M_next = 0; > } > catch(...) > { > this->_M_put_node(__node); > throw; > } > return __node; > } > > _Node* > _M_create_node() > { > _Node* __node = this->_M_get_node(); > try > { > get_allocator().construct(&__node->_M_data, value_type()); > __node->_M_next = 0; > } > catch(...) > { > this->_M_put_node(__node); > throw; > } > return __node; > } > > public: > explicit > slist(const allocator_type& __a = allocator_type()) > : _Base(__a) {} > > slist(size_type __n, const value_type& __x, > const allocator_type& __a = allocator_type()) > : _Base(__a) > { _M_insert_after_fill(&this->_M_head, __n, __x); } > > explicit > slist(size_type __n) > : _Base(allocator_type()) > { _M_insert_after_fill(&this->_M_head, __n, value_type()); } > > > > template <class _InputIterator> > slist(_InputIterator __first, _InputIterator __last, > const allocator_type& __a = allocator_type()) > : _Base(__a) > { _M_insert_after_range(&this->_M_head, __first, __last); } > > slist(const slist& __x) > : _Base(__x.get_allocator()) > { _M_insert_after_range(&this->_M_head, __x.begin(), __x.end()); } > > slist& > operator= (const slist& __x); > > ~slist() {} > > public: > > > > > > void > assign(size_type __n, const _Tp& __val) > { _M_fill_assign(__n, __val); } > > void > _M_fill_assign(size_type __n, const _Tp& __val); > > template <class _InputIterator> > void > assign(_InputIterator __first, _InputIterator __last) > { > typedef typename std::__is_integer<_InputIterator>::__type _Integral; > _M_assign_dispatch(__first, __last, _Integral()); > } > > template <class _Integer> > void > _M_assign_dispatch(_Integer __n, _Integer __val, __true_type) > { _M_fill_assign((size_type) __n, (_Tp) __val); } > > template <class _InputIterator> > void > _M_assign_dispatch(_InputIterator __first, _InputIterator __last, > __false_type); > > public: > > iterator > begin() > { return iterator((_Node*)this->_M_head._M_next); } > > const_iterator > begin() const > { return const_iterator((_Node*)this->_M_head._M_next);} > > iterator > end() > { return iterator(0); } > > const_iterator > end() const > { return const_iterator(0); } ># 445 "/usr/include/c++/4.9.0/ext/slist" 3 4 > iterator > before_begin() > { return iterator((_Node*) &this->_M_head); } > > const_iterator > before_begin() const > { return const_iterator((_Node*) &this->_M_head); } > > size_type > size() const > { return __slist_size(this->_M_head._M_next); } > > size_type > max_size() const > { return size_type(-1); } > > bool > empty() const > { return this->_M_head._M_next == 0; } > > void > swap(slist& __x) > { std::swap(this->_M_head._M_next, __x._M_head._M_next); } > > public: > > reference > front() > { return ((_Node*) this->_M_head._M_next)->_M_data; } > > const_reference > front() const > { return ((_Node*) this->_M_head._M_next)->_M_data; } > > void > push_front(const value_type& __x) > { __slist_make_link(&this->_M_head, _M_create_node(__x)); } > > void > push_front() > { __slist_make_link(&this->_M_head, _M_create_node()); } > > void > pop_front() > { > _Node* __node = (_Node*) this->_M_head._M_next; > this->_M_head._M_next = __node->_M_next; > get_allocator().destroy(&__node->_M_data); > this->_M_put_node(__node); > } > > iterator > previous(const_iterator __pos) > { return iterator((_Node*) __slist_previous(&this->_M_head, > __pos._M_node)); } > > const_iterator > previous(const_iterator __pos) const > { return const_iterator((_Node*) __slist_previous(&this->_M_head, > __pos._M_node)); } > > private: > _Node* > _M_insert_after(_Node_base* __pos, const value_type& __x) > { return (_Node*) (__slist_make_link(__pos, _M_create_node(__x))); } > > _Node* > _M_insert_after(_Node_base* __pos) > { return (_Node*) (__slist_make_link(__pos, _M_create_node())); } > > void > _M_insert_after_fill(_Node_base* __pos, > size_type __n, const value_type& __x) > { > for (size_type __i = 0; __i < __n; ++__i) > __pos = __slist_make_link(__pos, _M_create_node(__x)); > } > > > template <class _InIterator> > void > _M_insert_after_range(_Node_base* __pos, > _InIterator __first, _InIterator __last) > { > typedef typename std::__is_integer<_InIterator>::__type _Integral; > _M_insert_after_range(__pos, __first, __last, _Integral()); > } > > template <class _Integer> > void > _M_insert_after_range(_Node_base* __pos, _Integer __n, _Integer __x, > __true_type) > { _M_insert_after_fill(__pos, __n, __x); } > > template <class _InIterator> > void > _M_insert_after_range(_Node_base* __pos, > _InIterator __first, _InIterator __last, > __false_type) > { > while (__first != __last) > { > __pos = __slist_make_link(__pos, _M_create_node(*__first)); > ++__first; > } > } > > public: > iterator > insert_after(iterator __pos, const value_type& __x) > { return iterator(_M_insert_after(__pos._M_node, __x)); } > > iterator > insert_after(iterator __pos) > { return insert_after(__pos, value_type()); } > > void > insert_after(iterator __pos, size_type __n, const value_type& __x) > { _M_insert_after_fill(__pos._M_node, __n, __x); } > > > > template <class _InIterator> > void > insert_after(iterator __pos, _InIterator __first, _InIterator __last) > { _M_insert_after_range(__pos._M_node, __first, __last); } > > iterator > insert(iterator __pos, const value_type& __x) > { return iterator(_M_insert_after(__slist_previous(&this->_M_head, > __pos._M_node), > __x)); } > > iterator > insert(iterator __pos) > { return iterator(_M_insert_after(__slist_previous(&this->_M_head, > __pos._M_node), > value_type())); } > > void > insert(iterator __pos, size_type __n, const value_type& __x) > { _M_insert_after_fill(__slist_previous(&this->_M_head, __pos._M_node), > __n, __x); } > > > > template <class _InIterator> > void > insert(iterator __pos, _InIterator __first, _InIterator __last) > { _M_insert_after_range(__slist_previous(&this->_M_head, __pos._M_node), > __first, __last); } > > public: > iterator > erase_after(iterator __pos) > { return iterator((_Node*) this->_M_erase_after(__pos._M_node)); } > > iterator > erase_after(iterator __before_first, iterator __last) > { > return iterator((_Node*) this->_M_erase_after(__before_first._M_node, > __last._M_node)); > } > > iterator > erase(iterator __pos) > { > return iterator((_Node*) this->_M_erase_after > (__slist_previous(&this->_M_head, __pos._M_node))); > } > > iterator > erase(iterator __first, iterator __last) > { > return iterator((_Node*) this->_M_erase_after > (__slist_previous(&this->_M_head, __first._M_node), > __last._M_node)); > } > > void > resize(size_type new_size, const _Tp& __x); > > void > resize(size_type new_size) > { resize(new_size, _Tp()); } > > void > clear() > { this->_M_erase_after(&this->_M_head, 0); } > > public: > > > void > splice_after(iterator __pos, > iterator __before_first, iterator __before_last) > { > if (__before_first != __before_last) > __slist_splice_after(__pos._M_node, __before_first._M_node, > __before_last._M_node); > } > > > > void > splice_after(iterator __pos, iterator __prev) > { __slist_splice_after(__pos._M_node, > __prev._M_node, __prev._M_node->_M_next); } > > > > > void > splice_after(iterator __pos, slist& __x) > { __slist_splice_after(__pos._M_node, &__x._M_head); } > > > void > splice(iterator __pos, slist& __x) > { > if (__x._M_head._M_next) > __slist_splice_after(__slist_previous(&this->_M_head, __pos._M_node), > &__x._M_head, > __slist_previous(&__x._M_head, 0)); } > > > void > splice(iterator __pos, slist& __x, iterator __i) > { __slist_splice_after(__slist_previous(&this->_M_head, __pos._M_node), > __slist_previous(&__x._M_head, __i._M_node), > __i._M_node); } > > > > void > splice(iterator __pos, slist& __x, iterator __first, iterator __last) > { > if (__first != __last) > __slist_splice_after(__slist_previous(&this->_M_head, __pos._M_node), > __slist_previous(&__x._M_head, __first._M_node), > __slist_previous(__first._M_node, > __last._M_node)); > } > > public: > void > reverse() > { > if (this->_M_head._M_next) > this->_M_head._M_next = __slist_reverse(this->_M_head._M_next); > } > > void > remove(const _Tp& __val); > > void > unique(); > > void > merge(slist& __x); > > void > sort(); > > template <class _Predicate> > void > remove_if(_Predicate __pred); > > template <class _BinaryPredicate> > void > unique(_BinaryPredicate __pred); > > template <class _StrictWeakOrdering> > void > merge(slist&, _StrictWeakOrdering); > > template <class _StrictWeakOrdering> > void > sort(_StrictWeakOrdering __comp); > }; > > template <class _Tp, class _Alloc> > slist<_Tp, _Alloc>& > slist<_Tp, _Alloc>::operator=(const slist<_Tp, _Alloc>& __x) > { > if (&__x != this) > { > _Node_base* __p1 = &this->_M_head; > _Node* __n1 = (_Node*) this->_M_head._M_next; > const _Node* __n2 = (const _Node*) __x._M_head._M_next; > while (__n1 && __n2) > { > __n1->_M_data = __n2->_M_data; > __p1 = __n1; > __n1 = (_Node*) __n1->_M_next; > __n2 = (const _Node*) __n2->_M_next; > } > if (__n2 == 0) > this->_M_erase_after(__p1, 0); > else > _M_insert_after_range(__p1, const_iterator((_Node*)__n2), > const_iterator(0)); > } > return *this; > } > > template <class _Tp, class _Alloc> > void > slist<_Tp, _Alloc>::_M_fill_assign(size_type __n, const _Tp& __val) > { > _Node_base* __prev = &this->_M_head; > _Node* __node = (_Node*) this->_M_head._M_next; > for (; __node != 0 && __n > 0; --__n) > { > __node->_M_data = __val; > __prev = __node; > __node = (_Node*) __node->_M_next; > } > if (__n > 0) > _M_insert_after_fill(__prev, __n, __val); > else > this->_M_erase_after(__prev, 0); > } > > template <class _Tp, class _Alloc> > template <class _InputIterator> > void > slist<_Tp, _Alloc>::_M_assign_dispatch(_InputIterator __first, > _InputIterator __last, > __false_type) > { > _Node_base* __prev = &this->_M_head; > _Node* __node = (_Node*) this->_M_head._M_next; > while (__node != 0 && __first != __last) > { > __node->_M_data = *__first; > __prev = __node; > __node = (_Node*) __node->_M_next; > ++__first; > } > if (__first != __last) > _M_insert_after_range(__prev, __first, __last); > else > this->_M_erase_after(__prev, 0); > } > > template <class _Tp, class _Alloc> > inline bool > operator==(const slist<_Tp, _Alloc>& _SL1, const slist<_Tp, _Alloc>& _SL2) > { > typedef typename slist<_Tp,_Alloc>::const_iterator const_iterator; > const_iterator __end1 = _SL1.end(); > const_iterator __end2 = _SL2.end(); > > const_iterator __i1 = _SL1.begin(); > const_iterator __i2 = _SL2.begin(); > while (__i1 != __end1 && __i2 != __end2 && *__i1 == *__i2) > { > ++__i1; > ++__i2; > } > return __i1 == __end1 && __i2 == __end2; > } > > > template <class _Tp, class _Alloc> > inline bool > operator<(const slist<_Tp, _Alloc>& _SL1, const slist<_Tp, _Alloc>& _SL2) > { return std::lexicographical_compare(_SL1.begin(), _SL1.end(), > _SL2.begin(), _SL2.end()); } > > template <class _Tp, class _Alloc> > inline bool > operator!=(const slist<_Tp, _Alloc>& _SL1, const slist<_Tp, _Alloc>& _SL2) > { return !(_SL1 == _SL2); } > > template <class _Tp, class _Alloc> > inline bool > operator>(const slist<_Tp, _Alloc>& _SL1, const slist<_Tp, _Alloc>& _SL2) > { return _SL2 < _SL1; } > > template <class _Tp, class _Alloc> > inline bool > operator<=(const slist<_Tp, _Alloc>& _SL1, const slist<_Tp, _Alloc>& _SL2) > { return !(_SL2 < _SL1); } > > template <class _Tp, class _Alloc> > inline bool > operator>=(const slist<_Tp, _Alloc>& _SL1, const slist<_Tp, _Alloc>& _SL2) > { return !(_SL1 < _SL2); } > > template <class _Tp, class _Alloc> > inline void > swap(slist<_Tp, _Alloc>& __x, slist<_Tp, _Alloc>& __y) > { __x.swap(__y); } > > template <class _Tp, class _Alloc> > void > slist<_Tp, _Alloc>::resize(size_type __len, const _Tp& __x) > { > _Node_base* __cur = &this->_M_head; > while (__cur->_M_next != 0 && __len > 0) > { > --__len; > __cur = __cur->_M_next; > } > if (__cur->_M_next) > this->_M_erase_after(__cur, 0); > else > _M_insert_after_fill(__cur, __len, __x); > } > > template <class _Tp, class _Alloc> > void > slist<_Tp, _Alloc>::remove(const _Tp& __val) > { > _Node_base* __cur = &this->_M_head; > while (__cur && __cur->_M_next) > { > if (((_Node*) __cur->_M_next)->_M_data == __val) > this->_M_erase_after(__cur); > else > __cur = __cur->_M_next; > } > } > > template <class _Tp, class _Alloc> > void > slist<_Tp, _Alloc>::unique() > { > _Node_base* __cur = this->_M_head._M_next; > if (__cur) > { > while (__cur->_M_next) > { > if (((_Node*)__cur)->_M_data > == ((_Node*)(__cur->_M_next))->_M_data) > this->_M_erase_after(__cur); > else > __cur = __cur->_M_next; > } > } > } > > template <class _Tp, class _Alloc> > void > slist<_Tp, _Alloc>::merge(slist<_Tp, _Alloc>& __x) > { > _Node_base* __n1 = &this->_M_head; > while (__n1->_M_next && __x._M_head._M_next) > { > if (((_Node*) __x._M_head._M_next)->_M_data > < ((_Node*) __n1->_M_next)->_M_data) > __slist_splice_after(__n1, &__x._M_head, __x._M_head._M_next); > __n1 = __n1->_M_next; > } > if (__x._M_head._M_next) > { > __n1->_M_next = __x._M_head._M_next; > __x._M_head._M_next = 0; > } > } > > template <class _Tp, class _Alloc> > void > slist<_Tp, _Alloc>::sort() > { > if (this->_M_head._M_next && this->_M_head._M_next->_M_next) > { > slist __carry; > slist __counter[64]; > int __fill = 0; > while (!empty()) > { > __slist_splice_after(&__carry._M_head, > &this->_M_head, this->_M_head._M_next); > int __i = 0; > while (__i < __fill && !__counter[__i].empty()) > { > __counter[__i].merge(__carry); > __carry.swap(__counter[__i]); > ++__i; > } > __carry.swap(__counter[__i]); > if (__i == __fill) > ++__fill; > } > > for (int __i = 1; __i < __fill; ++__i) > __counter[__i].merge(__counter[__i-1]); > this->swap(__counter[__fill-1]); > } > } > > template <class _Tp, class _Alloc> > template <class _Predicate> > void slist<_Tp, _Alloc>::remove_if(_Predicate __pred) > { > _Node_base* __cur = &this->_M_head; > while (__cur->_M_next) > { > if (__pred(((_Node*) __cur->_M_next)->_M_data)) > this->_M_erase_after(__cur); > else > __cur = __cur->_M_next; > } > } > > template <class _Tp, class _Alloc> > template <class _BinaryPredicate> > void > slist<_Tp, _Alloc>::unique(_BinaryPredicate __pred) > { > _Node* __cur = (_Node*) this->_M_head._M_next; > if (__cur) > { > while (__cur->_M_next) > { > if (__pred(((_Node*)__cur)->_M_data, > ((_Node*)(__cur->_M_next))->_M_data)) > this->_M_erase_after(__cur); > else > __cur = (_Node*) __cur->_M_next; > } > } > } > > template <class _Tp, class _Alloc> > template <class _StrictWeakOrdering> > void > slist<_Tp, _Alloc>::merge(slist<_Tp, _Alloc>& __x, > _StrictWeakOrdering __comp) > { > _Node_base* __n1 = &this->_M_head; > while (__n1->_M_next && __x._M_head._M_next) > { > if (__comp(((_Node*) __x._M_head._M_next)->_M_data, > ((_Node*) __n1->_M_next)->_M_data)) > __slist_splice_after(__n1, &__x._M_head, __x._M_head._M_next); > __n1 = __n1->_M_next; > } > if (__x._M_head._M_next) > { > __n1->_M_next = __x._M_head._M_next; > __x._M_head._M_next = 0; > } > } > > template <class _Tp, class _Alloc> > template <class _StrictWeakOrdering> > void > slist<_Tp, _Alloc>::sort(_StrictWeakOrdering __comp) > { > if (this->_M_head._M_next && this->_M_head._M_next->_M_next) > { > slist __carry; > slist __counter[64]; > int __fill = 0; > while (!empty()) > { > __slist_splice_after(&__carry._M_head, > &this->_M_head, this->_M_head._M_next); > int __i = 0; > while (__i < __fill && !__counter[__i].empty()) > { > __counter[__i].merge(__carry, __comp); > __carry.swap(__counter[__i]); > ++__i; > } > __carry.swap(__counter[__i]); > if (__i == __fill) > ++__fill; > } > > for (int __i = 1; __i < __fill; ++__i) > __counter[__i].merge(__counter[__i-1], __comp); > this->swap(__counter[__fill-1]); > } > } > > >} > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > template <class _Tp, class _Alloc> > class insert_iterator<__gnu_cxx::slist<_Tp, _Alloc> > > { > protected: > typedef __gnu_cxx::slist<_Tp, _Alloc> _Container; > _Container* container; > typename _Container::iterator iter; > > public: > typedef _Container container_type; > typedef output_iterator_tag iterator_category; > typedef void value_type; > typedef void difference_type; > typedef void pointer; > typedef void reference; > > insert_iterator(_Container& __x, typename _Container::iterator __i) > : container(&__x) > { > if (__i == __x.begin()) > iter = __x.before_begin(); > else > iter = __x.previous(__i); > } > > insert_iterator<_Container>& > operator=(const typename _Container::value_type& __value) > { > iter = container->insert_after(iter, __value); > return *this; > } > > insert_iterator<_Container>& > operator*() > { return *this; } > > insert_iterator<_Container>& > operator++() > { return *this; } > > insert_iterator<_Container>& > operator++(int) > { return *this; } > }; > > >} ># 17 "/usr/include/boost/algorithm/string/std/slist_traits.hpp" 2 3 4 > > >namespace boost { > namespace algorithm { ># 41 "/usr/include/boost/algorithm/string/std/slist_traits.hpp" 3 4 > template<typename T, typename AllocT> > class has_stable_iterators< __gnu_cxx::slist<T,AllocT> > > { > public: > > > > static const bool value=true; > > typedef mpl::bool_<has_stable_iterators<T>::value> type; > }; > > > template<typename T, typename AllocT> > class has_const_time_insert< __gnu_cxx::slist<T,AllocT> > > { > public: > > > > static const bool value=true; > > typedef mpl::bool_<has_const_time_insert<T>::value> type; > }; > > > template<typename T, typename AllocT> > class has_const_time_erase< __gnu_cxx::slist<T,AllocT> > > { > public: > > > > static const bool value=true; > > typedef mpl::bool_<has_const_time_erase<T>::value> type; > }; > > > > } >} ># 24 "/usr/include/boost/algorithm/string/std_containers_traits.hpp" 2 3 4 ># 19 "/usr/include/boost/algorithm/string.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/trim.hpp" 1 3 4 ># 19 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 ># 1 "/usr/include/boost/range/as_literal.hpp" 1 3 4 ># 22 "/usr/include/boost/range/as_literal.hpp" 3 4 ># 1 "/usr/include/boost/range/iterator_range.hpp" 1 3 4 ># 13 "/usr/include/boost/range/iterator_range.hpp" 3 4 ># 1 "/usr/include/boost/range/iterator_range_core.hpp" 1 3 4 ># 21 "/usr/include/boost/range/iterator_range_core.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 22 "/usr/include/boost/range/iterator_range_core.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/range/functions.hpp" 1 3 4 ># 20 "/usr/include/boost/range/functions.hpp" 3 4 ># 1 "/usr/include/boost/range/size.hpp" 1 3 4 ># 21 "/usr/include/boost/range/size.hpp" 3 4 ># 1 "/usr/include/boost/range/size_type.hpp" 1 3 4 ># 19 "/usr/include/boost/range/size_type.hpp" 3 4 ># 1 "/usr/include/boost/range/difference_type.hpp" 1 3 4 ># 22 "/usr/include/boost/range/difference_type.hpp" 3 4 >namespace boost >{ > template< class T > > struct range_difference : iterator_difference< typename range_iterator<T>::type > > { }; >} ># 20 "/usr/include/boost/range/size_type.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/type_traits/make_unsigned.hpp" 1 3 4 ># 22 "/usr/include/boost/type_traits/make_unsigned.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/add_volatile.hpp" 1 3 4 ># 16 "/usr/include/boost/type_traits/add_volatile.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 17 "/usr/include/boost/type_traits/add_volatile.hpp" 2 3 4 > >namespace boost { ># 33 "/usr/include/boost/type_traits/add_volatile.hpp" 3 4 >template< typename T > struct add_volatile { public: typedef T volatile type; }; > > > > > > >template< typename T > struct add_volatile<T&> { public: typedef T& type; }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 46 "/usr/include/boost/type_traits/add_volatile.hpp" 2 3 4 ># 23 "/usr/include/boost/type_traits/make_unsigned.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 30 "/usr/include/boost/type_traits/make_unsigned.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <class T> >struct make_unsigned_imp >{ > static_assert((::boost::type_traits::ice_or< ::boost::is_integral<T>::value, ::boost::is_enum<T>::value>::value), "(::boost::type_traits::ice_or< ::boost::is_integral<T>::value, ::boost::is_enum<T>::value>::value)") > ; > > static_assert((::boost::type_traits::ice_not< ::boost::is_same< typename remove_cv<T>::type, bool>::value>::value), "(::boost::type_traits::ice_not< ::boost::is_same< typename remove_cv<T>::type, bool>::value>::value)") > > ; > > > typedef typename remove_cv<T>::type t_no_cv; > typedef typename mpl::if_c< > (::boost::type_traits::ice_and< > ::boost::is_unsigned<T>::value, > ::boost::is_integral<T>::value, > ::boost::type_traits::ice_not< ::boost::is_same<t_no_cv, char>::value>::value, > ::boost::type_traits::ice_not< ::boost::is_same<t_no_cv, wchar_t>::value>::value, > ::boost::type_traits::ice_not< ::boost::is_same<t_no_cv, bool>::value>::value >::value), > T, > typename mpl::if_c< > (::boost::type_traits::ice_and< > ::boost::is_integral<T>::value, > ::boost::type_traits::ice_not< ::boost::is_same<t_no_cv, char>::value>::value, > ::boost::type_traits::ice_not< ::boost::is_same<t_no_cv, wchar_t>::value>::value, > ::boost::type_traits::ice_not< ::boost::is_same<t_no_cv, bool>::value>::value> > ::value), > typename mpl::if_< > is_same<t_no_cv, signed char>, > unsigned char, > typename mpl::if_< > is_same<t_no_cv, short>, > unsigned short, > typename mpl::if_< > is_same<t_no_cv, int>, > unsigned int, > typename mpl::if_< > is_same<t_no_cv, long>, > unsigned long, > > > typename mpl::if_c< > sizeof(t_no_cv) == sizeof(boost::ulong_long_type), > boost::ulong_long_type, > boost::uint128_type > >::type ># 89 "/usr/include/boost/type_traits/make_unsigned.hpp" 3 4 > >::type > >::type > >::type > >::type, > > typename mpl::if_c< > sizeof(t_no_cv) == sizeof(unsigned char), > unsigned char, > typename mpl::if_c< > sizeof(t_no_cv) == sizeof(unsigned short), > unsigned short, > typename mpl::if_c< > sizeof(t_no_cv) == sizeof(unsigned int), > unsigned int, > typename mpl::if_c< > sizeof(t_no_cv) == sizeof(unsigned long), > unsigned long, > > > typename mpl::if_c< > sizeof(t_no_cv) == sizeof(boost::ulong_long_type), > boost::ulong_long_type, > boost::uint128_type > >::type ># 121 "/usr/include/boost/type_traits/make_unsigned.hpp" 3 4 > >::type > >::type > >::type > >::type > >::type > >::type base_integer_type; > > > typedef typename mpl::if_< > is_const<T>, > typename add_const<base_integer_type>::type, > base_integer_type > >::type const_base_integer_type; > > > typedef typename mpl::if_< > is_volatile<T>, > typename add_volatile<const_base_integer_type>::type, > const_base_integer_type > >::type type; >}; > > >} > >template< typename T > struct make_unsigned { public: typedef typename boost::detail::make_unsigned_imp<T>::type type; }; > >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 151 "/usr/include/boost/type_traits/make_unsigned.hpp" 2 3 4 ># 26 "/usr/include/boost/range/size_type.hpp" 2 3 4 > > > > >namespace boost >{ > namespace detail > { > > > > > > template<typename T> > class has_size_type > { > typedef char no_type; > struct yes_type { char dummy[2]; }; > > template<typename C> > static yes_type test(typename C::size_type x); > > template<typename C, typename Arg> > static no_type test(Arg x); > > public: > static const bool value = sizeof(test<T>(0)) == sizeof(yes_type); > }; > > template<typename C, typename Enabler=void> > struct range_size > { > typedef typename make_unsigned< > typename range_difference<C>::type > >::type type; > }; > > template<typename C> > struct range_size< > C, > typename enable_if<has_size_type<C>, void>::type > > > { > typedef typename C::size_type type; > }; > > } > > template< class T > > struct range_size : > detail::range_size<T> > { }; > > template< class T > > struct range_size<const T > > : detail::range_size<T> > { }; > >} ># 22 "/usr/include/boost/range/size.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 23 "/usr/include/boost/range/size.hpp" 2 3 4 > >namespace boost >{ > namespace range_detail > { > template<class SinglePassRange> > inline typename range_size<const SinglePassRange>::type > range_calculate_size(const SinglePassRange& rng) > { > (static_cast<void> (0)) > ; > return boost::end(rng) - boost::begin(rng); > } > } > > template<class SinglePassRange> > inline typename range_size<const SinglePassRange>::type > size(const SinglePassRange& rng) > { > > > > using namespace range_detail; > > return range_calculate_size(rng); > } > >} ># 21 "/usr/include/boost/range/functions.hpp" 2 3 4 ># 1 "/usr/include/boost/range/distance.hpp" 1 3 4 ># 22 "/usr/include/boost/range/distance.hpp" 3 4 >namespace boost >{ > > template< class T > > inline typename range_difference<T>::type > distance( const T& r ) > { > return std::distance( boost::begin( r ), boost::end( r ) ); > } > >} ># 22 "/usr/include/boost/range/functions.hpp" 2 3 4 ># 1 "/usr/include/boost/range/empty.hpp" 1 3 4 ># 22 "/usr/include/boost/range/empty.hpp" 3 4 >namespace boost >{ > > template< class T > > inline bool empty( const T& r ) > { > return boost::begin( r ) == boost::end( r ); > } > >} ># 23 "/usr/include/boost/range/functions.hpp" 2 3 4 ># 29 "/usr/include/boost/range/iterator_range_core.hpp" 2 3 4 > > ># 1 "/usr/include/boost/range/algorithm/equal.hpp" 1 3 4 ># 14 "/usr/include/boost/range/algorithm/equal.hpp" 3 4 ># 1 "/usr/include/boost/range/concepts.hpp" 1 3 4 ># 19 "/usr/include/boost/range/concepts.hpp" 3 4 ># 1 "/usr/include/boost/concept_check.hpp" 1 3 4 ># 20 "/usr/include/boost/concept_check.hpp" 3 4 ># 1 "/usr/include/boost/concept/assert.hpp" 1 3 4 ># 36 "/usr/include/boost/concept/assert.hpp" 3 4 ># 1 "/usr/include/boost/concept/detail/general.hpp" 1 3 4 > > > > > > > ># 1 "/usr/include/boost/concept/detail/backward_compatibility.hpp" 1 3 4 > > > > > > >namespace boost >{ > namespace concepts {} > > > > >} ># 9 "/usr/include/boost/concept/detail/general.hpp" 2 3 4 > > ># 1 "/usr/include/boost/concept/detail/has_constraints.hpp" 1 3 4 ># 11 "/usr/include/boost/concept/detail/has_constraints.hpp" 3 4 >namespace boost { namespace concepts { > >namespace detail >{ > > > > typedef char yes; > typedef char (&no)[2]; > > template <class Model, void (Model::*)()> > struct wrap_constraints {}; ># 31 "/usr/include/boost/concept/detail/has_constraints.hpp" 3 4 > template <class Model> > inline yes has_constraints_(Model*, wrap_constraints<Model,&Model::constraints>* = 0); > inline no has_constraints_(...); > >} > > > >template <class Model> >struct not_satisfied >{ > static const bool value = sizeof( detail::has_constraints_((Model*)0) ) == sizeof(detail::yes) > > ; > typedef mpl::bool_<value> type; >}; > >}} ># 12 "/usr/include/boost/concept/detail/general.hpp" 2 3 4 > > > > > >namespace boost { namespace concepts { > >template <class ModelFn> >struct requirement_; > >namespace detail >{ > template <void(*)()> struct instantiate {}; >} > >template <class Model> >struct requirement >{ > static void failed() { ((Model*)0)->~Model(); } >}; > >struct failed {}; > >template <class Model> >struct requirement<failed ************ Model::************> >{ > static void failed() { ((Model*)0)->~Model(); } >}; > > > >template <class Model> >struct constraint >{ > static void failed() { ((Model*)0)->constraints(); } >}; > >template <class Model> >struct requirement_<void(*)(Model)> > : mpl::if_< > concepts::not_satisfied<Model> > , constraint<Model> > , requirement<failed ************ Model::************> > >::type >{}; ># 73 "/usr/include/boost/concept/detail/general.hpp" 3 4 >}} ># 37 "/usr/include/boost/concept/assert.hpp" 2 3 4 ># 21 "/usr/include/boost/concept_check.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/conversion_traits.hpp" 1 3 4 ># 24 "/usr/include/boost/concept_check.hpp" 2 3 4 ># 32 "/usr/include/boost/concept_check.hpp" 3 4 ># 1 "/usr/include/boost/concept/usage.hpp" 1 3 4 ># 11 "/usr/include/boost/concept/usage.hpp" 3 4 >namespace boost { namespace concepts { > > > > > > > >template <class Model> >struct usage_requirements >{ > ~usage_requirements() { ((Model*)0)->~Model(); } >}; ># 42 "/usr/include/boost/concept/usage.hpp" 3 4 >}} ># 33 "/usr/include/boost/concept_check.hpp" 2 3 4 ># 1 "/usr/include/boost/concept/detail/concept_def.hpp" 1 3 4 > > > > > ># 1 "/usr/include/boost/preprocessor/seq/for_each_i.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/seq/for_each_i.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/seq/seq.hpp" 1 3 4 ># 16 "/usr/include/boost/preprocessor/seq/seq.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/seq/elem.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/seq/seq.hpp" 2 3 4 ># 20 "/usr/include/boost/preprocessor/seq/for_each_i.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/seq/size.hpp" 1 3 4 ># 21 "/usr/include/boost/preprocessor/seq/for_each_i.hpp" 2 3 4 ># 7 "/usr/include/boost/concept/detail/concept_def.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/seq/enum.hpp" 1 3 4 ># 8 "/usr/include/boost/concept/detail/concept_def.hpp" 2 3 4 ># 34 "/usr/include/boost/concept_check.hpp" 2 3 4 > >namespace boost >{ > > > > > > template <class Model> > inline void function_requires(Model* = 0) > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Model)>::failed> boost_concept_check45; > } > template <class T> inline void ignore_unused_variable_warning(T const&) {} ># 65 "/usr/include/boost/concept_check.hpp" 3 4 > template < typename T > struct Integer; template < typename T > struct IntegerConcept : Integer< T > { }; template < typename T > struct Integer > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Integer>)>::failed> boost_concept_check67; ~Integer() > { > x.error_type_must_be_an_integer_type(); > } > private: > T x; > }; > > template <> struct Integer<char> {}; > template <> struct Integer<signed char> {}; > template <> struct Integer<unsigned char> {}; > template <> struct Integer<short> {}; > template <> struct Integer<unsigned short> {}; > template <> struct Integer<int> {}; > template <> struct Integer<unsigned int> {}; > template <> struct Integer<long> {}; > template <> struct Integer<unsigned long> {}; > > template <> struct Integer< ::boost::long_long_type> {}; > template <> struct Integer< ::boost::ulong_long_type> {}; > > > > > > template < typename T > struct SignedInteger; template < typename T > struct SignedIntegerConcept : SignedInteger< T > { }; template < typename T > struct SignedInteger { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<SignedInteger>)>::failed> boost_concept_check93; ~SignedInteger() { > x.error_type_must_be_a_signed_integer_type(); > } > private: > T x; > }; > template <> struct SignedInteger<signed char> { }; > template <> struct SignedInteger<short> {}; > template <> struct SignedInteger<int> {}; > template <> struct SignedInteger<long> {}; > > template <> struct SignedInteger< ::boost::long_long_type> {}; > > > > > template < typename T > struct UnsignedInteger; template < typename T > struct UnsignedIntegerConcept : UnsignedInteger< T > { }; template < typename T > struct UnsignedInteger { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<UnsignedInteger>)>::failed> boost_concept_check110; ~UnsignedInteger() { > x.error_type_must_be_an_unsigned_integer_type(); > } > private: > T x; > }; > > template <> struct UnsignedInteger<unsigned char> {}; > template <> struct UnsignedInteger<unsigned short> {}; > template <> struct UnsignedInteger<unsigned int> {}; > template <> struct UnsignedInteger<unsigned long> {}; > > template <> struct UnsignedInteger< ::boost::ulong_long_type> {}; > > > > > > > > template < typename TT > struct DefaultConstructible; template < typename TT > struct DefaultConstructibleConcept : DefaultConstructible< TT > { }; template < typename TT > struct DefaultConstructible > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<DefaultConstructible>)>::failed> boost_concept_check132; ~DefaultConstructible() { > TT a; > ignore_unused_variable_warning(a); > } > }; > > template < typename TT > struct Assignable; template < typename TT > struct AssignableConcept : Assignable< TT > { }; template < typename TT > struct Assignable > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Assignable>)>::failed> boost_concept_check140; ~Assignable() { > > a = b; > > const_constraints(b); > } > private: > void const_constraints(const TT& x) { > > a = x; > > > > } > private: > TT a; > TT b; > }; > > > template < typename TT > struct CopyConstructible; template < typename TT > struct CopyConstructibleConcept : CopyConstructible< TT > { }; template < typename TT > struct CopyConstructible > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<CopyConstructible>)>::failed> boost_concept_check162; ~CopyConstructible() { > TT a(b); > TT* ptr = &a; > const_constraints(a); > ignore_unused_variable_warning(ptr); > } > private: > void const_constraints(const TT& a) { > TT c(a); > const TT* ptr = &a; > ignore_unused_variable_warning(c); > ignore_unused_variable_warning(ptr); > } > TT b; > }; > > > > > > > > template < typename TT > struct SGIAssignable; template < typename TT > struct SGIAssignableConcept : SGIAssignable< TT > { }; template < typename TT > struct SGIAssignable > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<SGIAssignable>)>::failed> boost_concept_check186; ~SGIAssignable() { > TT c(a); > > a = b; > > const_constraints(b); > ignore_unused_variable_warning(c); > } > private: > void const_constraints(const TT& x) { > TT c(x); > > a = x; > > ignore_unused_variable_warning(c); > } > TT a; > TT b; > }; > > > > > template < typename X , typename Y > struct Convertible; template < typename X , typename Y > struct ConvertibleConcept : Convertible< X, Y > { }; template < typename X , typename Y > struct Convertible > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Convertible>)>::failed> boost_concept_check211; ~Convertible() { > Y y = x; > ignore_unused_variable_warning(y); > } > private: > X x; > }; ># 228 "/usr/include/boost/concept_check.hpp" 3 4 > template <class TT> > void require_boolean_expr(const TT& t) { > bool x = t; > ignore_unused_variable_warning(x); > } > > template < typename TT > struct EqualityComparable; template < typename TT > struct EqualityComparableConcept : EqualityComparable< TT > { }; template < typename TT > struct EqualityComparable > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<EqualityComparable>)>::failed> boost_concept_check236; ~EqualityComparable() { > require_boolean_expr(a == b); > require_boolean_expr(a != b); > } > private: > TT a, b; > }; > > template < typename TT > struct LessThanComparable; template < typename TT > struct LessThanComparableConcept : LessThanComparable< TT > { }; template < typename TT > struct LessThanComparable > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<LessThanComparable>)>::failed> boost_concept_check246; ~LessThanComparable() { > require_boolean_expr(a < b); > } > private: > TT a, b; > }; > > > template < typename TT > struct Comparable; template < typename TT > struct ComparableConcept : Comparable< TT > { }; template < typename TT > struct Comparable > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Comparable>)>::failed> boost_concept_check256; ~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; > }; ># 286 "/usr/include/boost/concept_check.hpp" 3 4 > template < typename First , typename Second > struct EqualOp; template < typename First , typename Second > struct EqualOpConcept : EqualOp< First, Second > { }; template < typename First , typename Second > struct EqualOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<EqualOp>)>::failed> boost_concept_check286; ~EqualOp() { (void)constraints_(); } private: bool constraints_() { return a == b; } First a; Second b; }; > template < typename First , typename Second > struct NotEqualOp; template < typename First , typename Second > struct NotEqualOpConcept : NotEqualOp< First, Second > { }; template < typename First , typename Second > struct NotEqualOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<NotEqualOp>)>::failed> boost_concept_check287; ~NotEqualOp() { (void)constraints_(); } private: bool constraints_() { return a != b; } First a; Second b; }; > template < typename First , typename Second > struct LessThanOp; template < typename First , typename Second > struct LessThanOpConcept : LessThanOp< First, Second > { }; template < typename First , typename Second > struct LessThanOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<LessThanOp>)>::failed> boost_concept_check288; ~LessThanOp() { (void)constraints_(); } private: bool constraints_() { return a < b; } First a; Second b; }; > template < typename First , typename Second > struct LessEqualOp; template < typename First , typename Second > struct LessEqualOpConcept : LessEqualOp< First, Second > { }; template < typename First , typename Second > struct LessEqualOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<LessEqualOp>)>::failed> boost_concept_check289; ~LessEqualOp() { (void)constraints_(); } private: bool constraints_() { return a <= b; } First a; Second b; }; > template < typename First , typename Second > struct GreaterThanOp; template < typename First , typename Second > struct GreaterThanOpConcept : GreaterThanOp< First, Second > { }; template < typename First , typename Second > struct GreaterThanOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<GreaterThanOp>)>::failed> boost_concept_check290; ~GreaterThanOp() { (void)constraints_(); } private: bool constraints_() { return a > b; } First a; Second b; }; > template < typename First , typename Second > struct GreaterEqualOp; template < typename First , typename Second > struct GreaterEqualOpConcept : GreaterEqualOp< First, Second > { }; template < typename First , typename Second > struct GreaterEqualOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<GreaterEqualOp>)>::failed> boost_concept_check291; ~GreaterEqualOp() { (void)constraints_(); } private: bool constraints_() { return a >= b; } First a; Second b; }; > > template < typename Ret , typename First , typename Second > struct PlusOp; template < typename Ret , typename First , typename Second > struct PlusOpConcept : PlusOp< Ret, First, Second > { }; template < typename Ret , typename First , typename Second > struct PlusOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<PlusOp>)>::failed> boost_concept_check293; ~PlusOp() { (void)constraints_(); } private: Ret constraints_() { return a + b; } First a; Second b; }; > template < typename Ret , typename First , typename Second > struct TimesOp; template < typename Ret , typename First , typename Second > struct TimesOpConcept : TimesOp< Ret, First, Second > { }; template < typename Ret , typename First , typename Second > struct TimesOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<TimesOp>)>::failed> boost_concept_check294; ~TimesOp() { (void)constraints_(); } private: Ret constraints_() { return a * b; } First a; Second b; }; > template < typename Ret , typename First , typename Second > struct DivideOp; template < typename Ret , typename First , typename Second > struct DivideOpConcept : DivideOp< Ret, First, Second > { }; template < typename Ret , typename First , typename Second > struct DivideOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<DivideOp>)>::failed> boost_concept_check295; ~DivideOp() { (void)constraints_(); } private: Ret constraints_() { return a / b; } First a; Second b; }; > template < typename Ret , typename First , typename Second > struct SubtractOp; template < typename Ret , typename First , typename Second > struct SubtractOpConcept : SubtractOp< Ret, First, Second > { }; template < typename Ret , typename First , typename Second > struct SubtractOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<SubtractOp>)>::failed> boost_concept_check296; ~SubtractOp() { (void)constraints_(); } private: Ret constraints_() { return a - b; } First a; Second b; }; > template < typename Ret , typename First , typename Second > struct ModOp; template < typename Ret , typename First , typename Second > struct ModOpConcept : ModOp< Ret, First, Second > { }; template < typename Ret , typename First , typename Second > struct ModOp { typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<ModOp>)>::failed> boost_concept_check297; ~ModOp() { (void)constraints_(); } private: Ret constraints_() { return a % b; } First a; Second b; }; > > > > > template < typename Func , typename Return > struct Generator; template < typename Func , typename Return > struct GeneratorConcept : Generator< Func, Return > { }; template < typename Func , typename Return > struct Generator > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Generator>)>::failed> boost_concept_check304; ~Generator() { test(is_void<Return>()); } > > private: > void test(boost::mpl::false_) > { > > const Return& r = f(); > ignore_unused_variable_warning(r); > } > > void test(boost::mpl::true_) > { > f(); > } > > Func f; > }; > > template < typename Func , typename Return , typename Arg > struct UnaryFunction; template < typename Func , typename Return , typename Arg > struct UnaryFunctionConcept : UnaryFunction< Func, Return, Arg > { }; template < typename Func , typename Return , typename Arg > struct UnaryFunction > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<UnaryFunction>)>::failed> boost_concept_check324; ~UnaryFunction() { test(is_void<Return>()); } > > private: > void test(boost::mpl::false_) > { > f(arg); > Return r = f(arg); > ignore_unused_variable_warning(r); > } > > void test(boost::mpl::true_) > { > f(arg); > } > > > > > > > > UnaryFunction(); > > > Func f; > Arg arg; > }; > > template < typename Func , typename Return , typename First , typename Second > struct BinaryFunction; template < typename Func , typename Return , typename First , typename Second > struct BinaryFunctionConcept : BinaryFunction< Func, Return, First, Second > { }; template < typename Func , typename Return , typename First , typename Second > struct BinaryFunction > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<BinaryFunction>)>::failed> boost_concept_check354; ~BinaryFunction() { test(is_void<Return>()); } > private: > void test(boost::mpl::false_) > { > f(first,second); > Return r = f(first, second); > (void)r; > } > > void test(boost::mpl::true_) > { > f(first,second); > } > > > > > > > > BinaryFunction(); > > > Func f; > First first; > Second second; > }; > > template < typename Func , typename Arg > struct UnaryPredicate; template < typename Func , typename Arg > struct UnaryPredicateConcept : UnaryPredicate< Func, Arg > { }; template < typename Func , typename Arg > struct UnaryPredicate > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<UnaryPredicate>)>::failed> boost_concept_check384; ~UnaryPredicate() { > require_boolean_expr(f(arg)); > } > private: > > > > > > > UnaryPredicate(); > > > Func f; > Arg arg; > }; > > template < typename Func , typename First , typename Second > struct BinaryPredicate; template < typename Func , typename First , typename Second > struct BinaryPredicateConcept : BinaryPredicate< Func, First, Second > { }; template < typename Func , typename First , typename Second > struct BinaryPredicate > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<BinaryPredicate>)>::failed> boost_concept_check403; ~BinaryPredicate() { > require_boolean_expr(f(a, b)); > } > private: > > > > > > > BinaryPredicate(); > > Func f; > First a; > Second b; > }; > > > template < typename Func , typename First , typename Second > struct Const_BinaryPredicate; template < typename Func , typename First , typename Second > struct Const_BinaryPredicateConcept : Const_BinaryPredicate< Func, First, Second > { }; template < typename Func , typename First , typename Second > struct Const_BinaryPredicate > : BinaryPredicate<Func, First, Second> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Const_BinaryPredicate>)>::failed> boost_concept_check424; ~Const_BinaryPredicate() { > const_constraints(f); > } > private: > void const_constraints(const Func& fun) { > > require_boolean_expr(fun(a, b)); > } > > > > > > > Const_BinaryPredicate(); > > > Func f; > First a; > Second b; > }; > > template < typename Func , typename Return > struct AdaptableGenerator; template < typename Func , typename Return > struct AdaptableGeneratorConcept : AdaptableGenerator< Func, Return > { }; template < typename Func , typename Return > struct AdaptableGenerator > : Generator<Func, typename Func::result_type> > { > typedef typename Func::result_type result_type; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<AdaptableGenerator>)>::failed> boost_concept_check451; ~AdaptableGenerator() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible<result_type, Return>)>::failed> boost_concept_check453; > } > }; > > template < typename Func , typename Return , typename Arg > struct AdaptableUnaryFunction; template < typename Func , typename Return , typename Arg > struct AdaptableUnaryFunctionConcept : AdaptableUnaryFunction< Func, Return, Arg > { }; template < typename Func , typename Return , typename Arg > struct AdaptableUnaryFunction > : UnaryFunction<Func, typename Func::result_type, typename Func::argument_type> > { > typedef typename Func::argument_type argument_type; > typedef typename Func::result_type result_type; > > ~AdaptableUnaryFunction() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible<result_type, Return>)>::failed> boost_concept_check465; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible<Arg, argument_type>)>::failed> boost_concept_check466; > } > }; > > template < typename Func , typename Return , typename First , typename Second > struct AdaptableBinaryFunction; template < typename Func , typename Return , typename First , typename Second > struct AdaptableBinaryFunctionConcept : AdaptableBinaryFunction< Func, Return, First, Second > { }; template < typename Func , typename Return , typename First , typename Second > struct AdaptableBinaryFunction > : 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() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible<result_type, Return>)>::failed> boost_concept_check484; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible<First, first_argument_type>)>::failed> boost_concept_check485; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible<Second, second_argument_type>)>::failed> boost_concept_check486; > } > }; > > template < typename Func , typename Arg > struct AdaptablePredicate; template < typename Func , typename Arg > struct AdaptablePredicateConcept : AdaptablePredicate< Func, Arg > { }; template < typename Func , typename Arg > struct AdaptablePredicate > : UnaryPredicate<Func, Arg> > , AdaptableUnaryFunction<Func, bool, Arg> > { > }; > > template < typename Func , typename First , typename Second > struct AdaptableBinaryPredicate; template < typename Func , typename First , typename Second > struct AdaptableBinaryPredicateConcept : AdaptableBinaryPredicate< Func, First, Second > { }; template < typename Func , typename First , typename Second > struct AdaptableBinaryPredicate > : BinaryPredicate<Func, First, Second> > , AdaptableBinaryFunction<Func, bool, First, Second> > { > }; > > > > > template < typename TT > struct InputIterator; template < typename TT > struct InputIteratorConcept : InputIterator< TT > { }; template < typename TT > struct InputIterator > : Assignable<TT> > , EqualityComparable<TT> > { > typedef typename boost::detail::iterator_traits<TT>::value_type value_type; > typedef typename boost::detail::iterator_traits<TT>::difference_type difference_type; > typedef typename boost::detail::iterator_traits<TT>::reference reference; > typedef typename boost::detail::iterator_traits<TT>::pointer pointer; > typedef typename boost::detail::iterator_traits<TT>::iterator_category iterator_category; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<InputIterator>)>::failed> boost_concept_check515; ~InputIterator() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(SignedInteger<difference_type>)>::failed> boost_concept_check517; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible<iterator_category, std::input_iterator_tag>)>::failed> boost_concept_check518; > > TT j(i); > (void)*i; > ++j; > i++; > } > private: > TT i; > }; > > template < typename TT , typename ValueT > struct OutputIterator; template < typename TT , typename ValueT > struct OutputIteratorConcept : OutputIterator< TT, ValueT > { }; template < typename TT , typename ValueT > struct OutputIterator > : Assignable<TT> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<OutputIterator>)>::failed> boost_concept_check532; ~OutputIterator() { > > ++i; > i++; > *i++ = t; > } > private: > TT i, j; > ValueT t; > }; > > template < typename TT > struct ForwardIterator; template < typename TT > struct ForwardIteratorConcept : ForwardIterator< TT > { }; template < typename TT > struct ForwardIterator > : InputIterator<TT> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<ForwardIterator>)>::failed> boost_concept_check546; ~ForwardIterator() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible< typename ForwardIterator::iterator_category , std::forward_iterator_tag >)>::failed> boost_concept_check551 > > > ; > > typename InputIterator<TT>::reference r = *i; > ignore_unused_variable_warning(r); > } > > private: > TT i; > }; > > template < typename TT > struct Mutable_ForwardIterator; template < typename TT > struct Mutable_ForwardIteratorConcept : Mutable_ForwardIterator< TT > { }; template < typename TT > struct Mutable_ForwardIterator > : ForwardIterator<TT> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Mutable_ForwardIterator>)>::failed> boost_concept_check564; ~Mutable_ForwardIterator() { > *i++ = *i; > } > private: > TT i; > }; > > template < typename TT > struct BidirectionalIterator; template < typename TT > struct BidirectionalIteratorConcept : BidirectionalIterator< TT > { }; template < typename TT > struct BidirectionalIterator > : ForwardIterator<TT> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<BidirectionalIterator>)>::failed> boost_concept_check574; ~BidirectionalIterator() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible< typename BidirectionalIterator::iterator_category , std::bidirectional_iterator_tag >)>::failed> boost_concept_check579 > > > ; > > --i; > i--; > } > private: > TT i; > }; > > template < typename TT > struct Mutable_BidirectionalIterator; template < typename TT > struct Mutable_BidirectionalIteratorConcept : Mutable_BidirectionalIterator< TT > { }; template < typename TT > struct Mutable_BidirectionalIterator > : BidirectionalIterator<TT> > , Mutable_ForwardIterator<TT> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Mutable_BidirectionalIterator>)>::failed> boost_concept_check592; ~Mutable_BidirectionalIterator() > { > *i-- = *i; > } > private: > TT i; > }; > > template < typename TT > struct RandomAccessIterator; template < typename TT > struct RandomAccessIteratorConcept : RandomAccessIterator< TT > { }; template < typename TT > struct RandomAccessIterator > : BidirectionalIterator<TT> > , Comparable<TT> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<RandomAccessIterator>)>::failed> boost_concept_check604; ~RandomAccessIterator() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Convertible< typename BidirectionalIterator<TT>::iterator_category , std::random_access_iterator_tag >)>::failed> boost_concept_check609 > > > ; > > i += n; > i = i + n; i = n + i; > i -= n; > i = i - n; > n = i - j; > (void)i[n]; > } > > private: > TT a, b; > TT i, j; > typename boost::detail::iterator_traits<TT>::difference_type n; > }; > > template < typename TT > struct Mutable_RandomAccessIterator; template < typename TT > struct Mutable_RandomAccessIteratorConcept : Mutable_RandomAccessIterator< TT > { }; template < typename TT > struct Mutable_RandomAccessIterator > : RandomAccessIterator<TT> > , Mutable_BidirectionalIterator<TT> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Mutable_RandomAccessIterator>)>::failed> boost_concept_check629; ~Mutable_RandomAccessIterator() > { > i[n] = *i; > } > private: > TT i; > typename boost::detail::iterator_traits<TT>::difference_type n; > }; > > > > > template < typename C > struct Container; template < typename C > struct ContainerConcept : Container< C > { }; template < typename C > struct Container > : Assignable<C> > { > 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; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Container>)>::failed> boost_concept_check651; ~Container() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(InputIterator<const_iterator>)>::failed> boost_concept_check653; > 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; > }; > > template < typename C > struct Mutable_Container; template < typename C > struct Mutable_ContainerConcept : Mutable_Container< C > { }; template < typename C > struct Mutable_Container > : Container<C> > { > typedef typename C::reference reference; > typedef typename C::iterator iterator; > typedef typename C::pointer pointer; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Mutable_Container>)>::failed> boost_concept_check678; ~Mutable_Container() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( Assignable<typename Mutable_Container::value_type>)>::failed> boost_concept_check681 > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(InputIterator<iterator>)>::failed> boost_concept_check683; > > i = c.begin(); > i = c.end(); > c.swap(c2); > } > > private: > iterator i; > C c, c2; > }; > > template < typename C > struct ForwardContainer; template < typename C > struct ForwardContainerConcept : ForwardContainer< C > { }; template < typename C > struct ForwardContainer > : Container<C> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<ForwardContainer>)>::failed> boost_concept_check698; ~ForwardContainer() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( ForwardIterator< typename ForwardContainer::const_iterator >)>::failed> boost_concept_check703 > > > ; > } > }; > > template < typename C > struct Mutable_ForwardContainer; template < typename C > struct Mutable_ForwardContainerConcept : Mutable_ForwardContainer< C > { }; template < typename C > struct Mutable_ForwardContainer > : ForwardContainer<C> > , Mutable_Container<C> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Mutable_ForwardContainer>)>::failed> boost_concept_check711; ~Mutable_ForwardContainer() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( Mutable_ForwardIterator< typename Mutable_ForwardContainer::iterator >)>::failed> boost_concept_check716 > > > ; > } > }; > > template < typename C > struct ReversibleContainer; template < typename C > struct ReversibleContainerConcept : ReversibleContainer< C > { }; template < typename C > struct ReversibleContainer > : ForwardContainer<C> > { > typedef typename > C::const_reverse_iterator > const_reverse_iterator; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<ReversibleContainer>)>::failed> boost_concept_check727; ~ReversibleContainer() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( BidirectionalIterator< typename ReversibleContainer::const_iterator>)>::failed> boost_concept_check731 > > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(BidirectionalIterator<const_reverse_iterator>)>::failed> boost_concept_check733; > > const_constraints(c); > } > private: > void const_constraints(const C& cc) > { > const_reverse_iterator i = cc.rbegin(); > i = cc.rend(); > } > C c; > }; > > template < typename C > struct Mutable_ReversibleContainer; template < typename C > struct Mutable_ReversibleContainerConcept : Mutable_ReversibleContainer< C > { }; template < typename C > struct Mutable_ReversibleContainer > : Mutable_ForwardContainer<C> > , ReversibleContainer<C> > { > typedef typename C::reverse_iterator reverse_iterator; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Mutable_ReversibleContainer>)>::failed> boost_concept_check752; ~Mutable_ReversibleContainer() > { > typedef typename Mutable_ForwardContainer<C>::iterator iterator; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Mutable_BidirectionalIterator<iterator>)>::failed> boost_concept_check755; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Mutable_BidirectionalIterator<reverse_iterator>)>::failed> boost_concept_check756; > > reverse_iterator i = c.rbegin(); > i = c.rend(); > } > private: > C c; > }; > > template < typename C > struct RandomAccessContainer; template < typename C > struct RandomAccessContainerConcept : RandomAccessContainer< C > { }; template < typename C > struct RandomAccessContainer > : ReversibleContainer<C> > { > typedef typename C::size_type size_type; > typedef typename C::const_reference const_reference; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<RandomAccessContainer>)>::failed> boost_concept_check771; ~RandomAccessContainer() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( RandomAccessIterator< typename RandomAccessContainer::const_iterator >)>::failed> boost_concept_check776 > > > ; > > 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; > }; > > template < typename C > struct Mutable_RandomAccessContainer; template < typename C > struct Mutable_RandomAccessContainerConcept : Mutable_RandomAccessContainer< C > { }; template < typename C > struct Mutable_RandomAccessContainer > : Mutable_ReversibleContainer<C> > , RandomAccessContainer<C> > { > private: > typedef Mutable_RandomAccessContainer self; > public: > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Mutable_RandomAccessContainer>)>::failed> boost_concept_check798; ~Mutable_RandomAccessContainer() > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Mutable_RandomAccessIterator<typename self::iterator>)>::failed> boost_concept_check800; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(Mutable_RandomAccessIterator<typename self::reverse_iterator>)>::failed> boost_concept_check801; > > typename self::reference r = c[i]; > ignore_unused_variable_warning(r); > } > > private: > typename Mutable_ReversibleContainer<C>::size_type i; > C c; > }; > > > template < typename S > struct Sequence; template < typename S > struct SequenceConcept : Sequence< S > { }; template < typename S > struct Sequence > : Mutable_ForwardContainer<S> > > > > , DefaultConstructible<S> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Sequence>)>::failed> boost_concept_check820; ~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; > }; > > template < typename S > struct FrontInsertionSequence; template < typename S > struct FrontInsertionSequenceConcept : FrontInsertionSequence< S > { }; template < typename S > struct FrontInsertionSequence > : Sequence<S> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<FrontInsertionSequence>)>::failed> boost_concept_check857; ~FrontInsertionSequence() > { > c.push_front(t); > c.pop_front(); > } > private: > S c; > typename S::value_type t; > }; > > template < typename S > struct BackInsertionSequence; template < typename S > struct BackInsertionSequenceConcept : BackInsertionSequence< S > { }; template < typename S > struct BackInsertionSequence > : Sequence<S> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<BackInsertionSequence>)>::failed> boost_concept_check870; ~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; > }; > > template < typename C > struct AssociativeContainer; template < typename C > struct AssociativeContainerConcept : AssociativeContainer< C > { }; template < typename C > struct AssociativeContainer > : ForwardContainer<C> > , DefaultConstructible<C> > { > 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; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<AssociativeContainer>)>::failed> boost_concept_check897; ~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); > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(BinaryPredicate<key_compare,key_type,key_type>)>::failed> boost_concept_check905; > > typedef typename AssociativeContainer::value_type value_type_; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(BinaryPredicate<value_compare,value_type_,value_type_>)>::failed> boost_concept_check908; > } > > > 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<iterator,iterator> r; > const_iterator ci; > std::pair<const_iterator,const_iterator> cr; > typename C::key_type k; > typename C::size_type n; > }; > > template < typename C > struct UniqueAssociativeContainer; template < typename C > struct UniqueAssociativeContainerConcept : UniqueAssociativeContainer< C > { }; template < typename C > struct UniqueAssociativeContainer > : AssociativeContainer<C> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<UniqueAssociativeContainer>)>::failed> boost_concept_check933; ~UniqueAssociativeContainer() > { > C c(first, last); > > pos_flag = c.insert(t); > c.insert(first, last); > > ignore_unused_variable_warning(c); > } > private: > std::pair<typename C::iterator, bool> pos_flag; > typename C::value_type t; > typename C::value_type* first, *last; > }; > > template < typename C > struct MultipleAssociativeContainer; template < typename C > struct MultipleAssociativeContainerConcept : MultipleAssociativeContainer< C > { }; template < typename C > struct MultipleAssociativeContainer > : AssociativeContainer<C> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<MultipleAssociativeContainer>)>::failed> boost_concept_check951; ~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; > }; > > template < typename C > struct SimpleAssociativeContainer; template < typename C > struct SimpleAssociativeContainerConcept : SimpleAssociativeContainer< C > { }; template < typename C > struct SimpleAssociativeContainer > : AssociativeContainer<C> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<SimpleAssociativeContainer>)>::failed> boost_concept_check970; ~SimpleAssociativeContainer() > { > typedef typename C::key_type key_type; > typedef typename C::value_type value_type; > enum { mpl_assertion_in_line_974 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) (boost::is_same<key_type,value_type>))0, 1 ) ) ) }; > } > }; > > template < typename C > struct PairAssociativeContainer; template < typename C > struct PairAssociativeContainerConcept : PairAssociativeContainer< C > { }; template < typename C > struct PairAssociativeContainer > : AssociativeContainer<C> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<PairAssociativeContainer>)>::failed> boost_concept_check981; ~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<const key_type, mapped_type> required_value_type; > enum { mpl_assertion_in_line_987 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) (boost::is_same<value_type,required_value_type>))0, 1 ) ) ) }; > } > }; > > template < typename C > struct SortedAssociativeContainer; template < typename C > struct SortedAssociativeContainerConcept : SortedAssociativeContainer< C > { }; template < typename C > struct SortedAssociativeContainer > : AssociativeContainer<C> > , ReversibleContainer<C> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<SortedAssociativeContainer>)>::failed> boost_concept_check995; ~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<typename self::iterator,typename self::iterator> r; > std::pair<typename self::const_iterator,typename self::const_iterator> cr; > typename C::value_type* first, *last; > }; > > > > template < typename C > struct Collection; template < typename C > struct CollectionConcept : Collection< C > { }; template < typename C > struct Collection > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<Collection>)>::failed> boost_concept_check1044; ~Collection() > { > boost::function_requires<boost::InputIteratorConcept<iterator> >(); > boost::function_requires<boost::InputIteratorConcept<const_iterator> >(); > boost::function_requires<boost::CopyConstructibleConcept<value_type> >(); > 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::difference_type difference_type; > typedef typename C::size_type size_type; > > C c; > bool b; > iterator i; > const_iterator ci; > size_type n; > }; >} > ># 1 "/usr/include/boost/concept/detail/concept_undef.hpp" 1 3 4 ># 1081 "/usr/include/boost/concept_check.hpp" 2 3 4 ># 20 "/usr/include/boost/range/concepts.hpp" 2 3 4 ># 1 "/usr/include/boost/iterator/iterator_concepts.hpp" 1 3 4 ># 31 "/usr/include/boost/iterator/iterator_concepts.hpp" 3 4 ># 1 "/usr/include/boost/concept/detail/concept_def.hpp" 1 3 4 ># 32 "/usr/include/boost/iterator/iterator_concepts.hpp" 2 3 4 > >namespace boost_concepts >{ > > > > > > > > template < typename Iterator > struct ReadableIterator; template < typename Iterator > struct ReadableIteratorConcept : ReadableIterator< Iterator > { }; template < typename Iterator > struct ReadableIterator > : boost::Assignable<Iterator> > , boost::CopyConstructible<Iterator> > > { > typedef typename boost::detail::iterator_traits<Iterator>::value_type value_type; > typedef typename boost::detail::iterator_traits<Iterator>::reference reference; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<ReadableIterator>)>::failed> boost_concept_check50; ~ReadableIterator() > { > > value_type v = *i; > boost::ignore_unused_variable_warning(v); > } > private: > Iterator i; > }; > > template < > typename Iterator > , typename ValueType = typename boost::detail::iterator_traits<Iterator>::value_type > > > struct WritableIterator > : boost::CopyConstructible<Iterator> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<WritableIterator>)>::failed> boost_concept_check67; ~WritableIterator() > { > *i = v; > } > private: > ValueType v; > Iterator i; > }; > > template < > typename Iterator > , typename ValueType = typename boost::detail::iterator_traits<Iterator>::value_type > > > struct WritableIteratorConcept : WritableIterator<Iterator,ValueType> {}; > > template < typename Iterator > struct SwappableIterator; template < typename Iterator > struct SwappableIteratorConcept : SwappableIterator< Iterator > { }; template < typename Iterator > struct SwappableIterator > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<SwappableIterator>)>::failed> boost_concept_check84; ~SwappableIterator() > { > std::iter_swap(i1, i2); > } > private: > Iterator i1; > Iterator i2; > }; > > template < typename Iterator > struct LvalueIterator; template < typename Iterator > struct LvalueIteratorConcept : LvalueIterator< Iterator > { }; template < typename Iterator > struct LvalueIterator > { > typedef typename boost::detail::iterator_traits<Iterator>::value_type value_type; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<LvalueIterator>)>::failed> boost_concept_check97; ~LvalueIterator() > { > value_type& r = const_cast<value_type&>(*i); > boost::ignore_unused_variable_warning(r); > } > private: > Iterator i; > }; > > > > > > template < typename Iterator > struct IncrementableIterator; template < typename Iterator > struct IncrementableIteratorConcept : IncrementableIterator< Iterator > { }; template < typename Iterator > struct IncrementableIterator > : boost::Assignable<Iterator> > , boost::CopyConstructible<Iterator> > { > typedef typename boost::iterator_traversal<Iterator>::type traversal_category; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( boost::Convertible< traversal_category , boost::incrementable_traversal_tag >)>::failed> boost_concept_check120 > > > > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<IncrementableIterator>)>::failed> boost_concept_check122; ~IncrementableIterator() > { > ++i; > (void)i++; > } > private: > Iterator i; > }; > > template < typename Iterator > struct SinglePassIterator; template < typename Iterator > struct SinglePassIteratorConcept : SinglePassIterator< Iterator > { }; template < typename Iterator > struct SinglePassIterator > : IncrementableIterator<Iterator> > , boost::EqualityComparable<Iterator> > > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( boost::Convertible< typename SinglePassIterator::traversal_category , boost::single_pass_traversal_tag > )>::failed> boost_concept_check140 > > > > ; > }; > > template < typename Iterator > struct ForwardTraversal; template < typename Iterator > struct ForwardTraversalConcept : ForwardTraversal< Iterator > { }; template < typename Iterator > struct ForwardTraversal > : SinglePassIterator<Iterator> > , boost::DefaultConstructible<Iterator> > { > typedef typename boost::detail::iterator_traits<Iterator>::difference_type difference_type; > > enum { mpl_assertion_in_line_149 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) (boost::is_integral<difference_type>))0, 1 ) ) ) }; > enum { mpl_assert_rel_value150 = (std::numeric_limits<difference_type>::is_signed == true) }; enum { mpl_assertion_in_line_150 = sizeof( boost::mpl::assertion_failed<mpl_assert_rel_value150>( (boost::mpl::failed ************ ( boost::mpl::assert_relation< boost::mpl::assert_::relations( sizeof( boost::mpl::assert_::arg == boost::mpl::assert_::arg ) ) , std::numeric_limits<difference_type>::is_signed , true >::************)) 0 ) ) }; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( boost::Convertible< typename ForwardTraversal::traversal_category , boost::forward_traversal_tag > )>::failed> boost_concept_check156 > > > > ; > }; > > template < typename Iterator > struct BidirectionalTraversal; template < typename Iterator > struct BidirectionalTraversalConcept : BidirectionalTraversal< Iterator > { }; template < typename Iterator > struct BidirectionalTraversal > : ForwardTraversal<Iterator> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( boost::Convertible< typename BidirectionalTraversal::traversal_category , boost::bidirectional_traversal_tag > )>::failed> boost_concept_check166 > > > > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<BidirectionalTraversal>)>::failed> boost_concept_check168; ~BidirectionalTraversal() > { > --i; > (void)i--; > } > private: > Iterator i; > }; > > template < typename Iterator > struct RandomAccessTraversal; template < typename Iterator > struct RandomAccessTraversalConcept : RandomAccessTraversal< Iterator > { }; template < typename Iterator > struct RandomAccessTraversal > : BidirectionalTraversal<Iterator> > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( boost::Convertible< typename RandomAccessTraversal::traversal_category , boost::random_access_traversal_tag > )>::failed> boost_concept_check184 > > > > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<RandomAccessTraversal>)>::failed> boost_concept_check186; ~RandomAccessTraversal() > { > i += n; > i = i + n; > i = n + i; > i -= n; > i = i - n; > n = i - j; > } > > private: > typename BidirectionalTraversal<Iterator>::difference_type n; > Iterator i, j; > }; > > > > > namespace detail > { > template <typename Iterator1, typename Iterator2> > void interop_single_pass_constraints(Iterator1 const& i1, Iterator2 const& i2) > { > bool b; > b = i1 == i2; > b = i1 != i2; > > b = i2 == i1; > b = i2 != i1; > boost::ignore_unused_variable_warning(b); > } > > template <typename Iterator1, typename Iterator2> > void interop_rand_access_constraints( > Iterator1 const& i1, Iterator2 const& i2, > boost::random_access_traversal_tag, boost::random_access_traversal_tag) > { > bool b; > typename boost::detail::iterator_traits<Iterator2>::difference_type n; > b = i1 < i2; > b = i1 <= i2; > b = i1 > i2; > b = i1 >= i2; > n = i1 - i2; > > b = i2 < i1; > b = i2 <= i1; > b = i2 > i1; > b = i2 >= i1; > n = i2 - i1; > boost::ignore_unused_variable_warning(b); > boost::ignore_unused_variable_warning(n); > } > > template <typename Iterator1, typename Iterator2> > void interop_rand_access_constraints( > Iterator1 const&, Iterator2 const&, > boost::single_pass_traversal_tag, boost::single_pass_traversal_tag) > { } > > } > > template < typename Iterator , typename ConstIterator > struct InteroperableIterator; template < typename Iterator , typename ConstIterator > struct InteroperableIteratorConcept : InteroperableIterator< Iterator, ConstIterator > { }; template < typename Iterator , typename ConstIterator > struct InteroperableIterator > { > private: > typedef typename boost::detail::pure_traversal_tag< > typename boost::iterator_traversal< > Iterator > >::type > >::type traversal_category; > > typedef typename boost::detail::pure_traversal_tag< > typename boost::iterator_traversal< > ConstIterator > >::type > >::type const_traversal_category; > > public: > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(SinglePassIterator<Iterator>)>::failed> boost_concept_check264; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(SinglePassIterator<ConstIterator>)>::failed> boost_concept_check265; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<InteroperableIterator>)>::failed> boost_concept_check267; ~InteroperableIterator() > { > detail::interop_single_pass_constraints(i, ci); > detail::interop_rand_access_constraints(i, ci, traversal_category(), const_traversal_category()); > > ci = i; > } > > private: > Iterator i; > ConstIterator ci; > }; > >} > ># 1 "/usr/include/boost/concept/detail/concept_undef.hpp" 1 3 4 ># 283 "/usr/include/boost/iterator/iterator_concepts.hpp" 2 3 4 ># 21 "/usr/include/boost/range/concepts.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/range/value_type.hpp" 1 3 4 ># 27 "/usr/include/boost/range/value_type.hpp" 3 4 >namespace boost >{ > template< class T > > struct range_value : iterator_value< typename range_iterator<T>::type > > { }; >} ># 25 "/usr/include/boost/range/concepts.hpp" 2 3 4 ># 1 "/usr/include/boost/range/detail/misc_concept.hpp" 1 3 4 ># 13 "/usr/include/boost/range/detail/misc_concept.hpp" 3 4 >namespace boost >{ > namespace range_detail > { > template<typename T1, typename T2> > class SameTypeConcept > { > public: > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<SameTypeConcept>)>::failed> boost_concept_check21; ~SameTypeConcept() > { > same_type(a,b); > } > private: > template<typename T> void same_type(T,T) {} > T1 a; > T2 b; > }; > } >} ># 26 "/usr/include/boost/range/concepts.hpp" 2 3 4 ># 59 "/usr/include/boost/range/concepts.hpp" 3 4 >namespace boost { > > namespace range_detail { ># 112 "/usr/include/boost/range/concepts.hpp" 3 4 > template<class Iterator> > struct IncrementableIteratorConcept : CopyConstructible<Iterator> > { > > typedef typename iterator_traversal<Iterator>::type traversal_category; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( Convertible< traversal_category, incrementable_traversal_tag >)>::failed> boost_concept_check122 > > > > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<IncrementableIteratorConcept>)>::failed> boost_concept_check124; ~IncrementableIteratorConcept() > { > ++i; > (void)i++; > } > private: > Iterator i; > > }; > > template<class Iterator> > struct SinglePassIteratorConcept > : IncrementableIteratorConcept<Iterator> > , EqualityComparable<Iterator> > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( Convertible< typename SinglePassIteratorConcept::traversal_category, single_pass_traversal_tag >)>::failed> boost_concept_check144 > > > > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<SinglePassIteratorConcept>)>::failed> boost_concept_check146; ~SinglePassIteratorConcept() > { > Iterator i2(++i); > boost::ignore_unused_variable_warning(i2); > > > > > > (void)(i++); > > typename boost::detail::iterator_traits<Iterator>::reference r1(*i); > boost::ignore_unused_variable_warning(r1); > > typename boost::detail::iterator_traits<Iterator>::reference r2(*(++i)); > boost::ignore_unused_variable_warning(r2); > } > private: > Iterator i; > > }; > > template<class Iterator> > struct ForwardIteratorConcept > : SinglePassIteratorConcept<Iterator> > , DefaultConstructible<Iterator> > { > > typedef typename boost::detail::iterator_traits<Iterator>::difference_type difference_type; > > enum { mpl_assertion_in_line_176 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) (is_integral<difference_type>))0, 1 ) ) ) }; > enum { mpl_assert_rel_value177 = (std::numeric_limits<difference_type>::is_signed == true) }; enum { mpl_assertion_in_line_177 = sizeof( boost::mpl::assertion_failed<mpl_assert_rel_value177>( (boost::mpl::failed ************ ( boost::mpl::assert_relation< boost::mpl::assert_::relations( sizeof( boost::mpl::assert_::arg == boost::mpl::assert_::arg ) ) , std::numeric_limits<difference_type>::is_signed , true >::************)) 0 ) ) }; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( Convertible< typename ForwardIteratorConcept::traversal_category, forward_traversal_tag >)>::failed> boost_concept_check183 > > > > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<ForwardIteratorConcept>)>::failed> boost_concept_check185; ~ForwardIteratorConcept() > { > > > > > Iterator i2(i++); > boost::ignore_unused_variable_warning(i2); > typename boost::detail::iterator_traits<Iterator>::reference r(*(i++)); > boost::ignore_unused_variable_warning(r); > } > private: > Iterator i; > > }; > > template<class Iterator> > struct BidirectionalIteratorConcept > : ForwardIteratorConcept<Iterator> > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( Convertible< typename BidirectionalIteratorConcept::traversal_category, bidirectional_traversal_tag >)>::failed> boost_concept_check210 > > > > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<BidirectionalIteratorConcept>)>::failed> boost_concept_check212; ~BidirectionalIteratorConcept() > { > --i; > (void)i--; > } > private: > Iterator i; > > }; > > template<class Iterator> > struct RandomAccessIteratorConcept > : BidirectionalIteratorConcept<Iterator> > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( Convertible< typename RandomAccessIteratorConcept::traversal_category, random_access_traversal_tag >)>::failed> boost_concept_check231 > > > > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<RandomAccessIteratorConcept>)>::failed> boost_concept_check233; ~RandomAccessIteratorConcept() > { > i += n; > i = i + n; > i = n + i; > i -= n; > i = i - n; > n = i - j; > } > private: > typename RandomAccessIteratorConcept::difference_type n; > Iterator i; > Iterator j; > > }; > > } > > > template<class T> > struct SinglePassRangeConcept > { > > typedef typename range_iterator<T const>::type const_iterator; > typedef typename range_iterator<T>::type iterator; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(range_detail::SinglePassIteratorConcept<iterator>)>::failed> boost_concept_check259; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(range_detail::SinglePassIteratorConcept<const_iterator>)>::failed> boost_concept_check260; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<SinglePassRangeConcept>)>::failed> boost_concept_check262; ~SinglePassRangeConcept() > { > > > > iterator i1 = boost::begin(*m_range); > iterator i2 = boost::end(*m_range); > > ignore_unused_variable_warning(i1); > ignore_unused_variable_warning(i2); > > const_constraints(*m_range); > } > > private: > void const_constraints(const T& const_range) > { > const_iterator ci1 = boost::begin(const_range); > const_iterator ci2 = boost::end(const_range); > > ignore_unused_variable_warning(ci1); > ignore_unused_variable_warning(ci2); > } > > > > > > T* m_range; > > }; > > > template<class T> > struct ForwardRangeConcept : SinglePassRangeConcept<T> > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(range_detail::ForwardIteratorConcept<typename ForwardRangeConcept::iterator>)>::failed> boost_concept_check299; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(range_detail::ForwardIteratorConcept<typename ForwardRangeConcept::const_iterator>)>::failed> boost_concept_check300; > > }; > > template<class Range> > struct WriteableRangeConcept > { > > typedef typename range_iterator<Range>::type iterator; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::concepts::usage_requirements<WriteableRangeConcept>)>::failed> boost_concept_check310; ~WriteableRangeConcept() > { > *i = v; > } > private: > iterator i; > typename range_value<Range>::type v; > > }; > > > template<class T> > struct WriteableForwardRangeConcept > : ForwardRangeConcept<T> > , WriteableRangeConcept<T> > { > }; > > > template<class T> > struct BidirectionalRangeConcept : ForwardRangeConcept<T> > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(range_detail::BidirectionalIteratorConcept<typename BidirectionalRangeConcept::iterator>)>::failed> boost_concept_check333; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(range_detail::BidirectionalIteratorConcept<typename BidirectionalRangeConcept::const_iterator>)>::failed> boost_concept_check334; > > }; > > > template<class T> > struct WriteableBidirectionalRangeConcept > : BidirectionalRangeConcept<T> > , WriteableRangeConcept<T> > { > }; > > > template<class T> > struct RandomAccessRangeConcept : BidirectionalRangeConcept<T> > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(range_detail::RandomAccessIteratorConcept<typename RandomAccessRangeConcept::iterator>)>::failed> boost_concept_check351; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(range_detail::RandomAccessIteratorConcept<typename RandomAccessRangeConcept::const_iterator>)>::failed> boost_concept_check352; > > }; > > > template<class T> > struct WriteableRandomAccessRangeConcept > : RandomAccessRangeConcept<T> > , WriteableRangeConcept<T> > { > }; > >} ># 15 "/usr/include/boost/range/algorithm/equal.hpp" 2 3 4 > > >namespace boost >{ > namespace range_detail > { > > > template< class SinglePassTraversalReadableIterator1, > class SinglePassTraversalReadableIterator2, > class IteratorCategoryTag1, > class IteratorCategoryTag2 > > inline bool equal_impl( SinglePassTraversalReadableIterator1 first1, > SinglePassTraversalReadableIterator1 last1, > SinglePassTraversalReadableIterator2 first2, > SinglePassTraversalReadableIterator2 last2, > IteratorCategoryTag1, > IteratorCategoryTag2 ) > { > while (true) > { > > > > if (first1 == last1) > return first2 == last2; > > > > > if (first2 == last2) > return false; > > > if (*first1 != *first2) > break; > > ++first1; > ++first2; > } > > > > return false; > } > > template< class SinglePassTraversalReadableIterator1, > class SinglePassTraversalReadableIterator2, > class IteratorCategoryTag1, > class IteratorCategoryTag2, > class BinaryPredicate > > inline bool equal_impl( SinglePassTraversalReadableIterator1 first1, > SinglePassTraversalReadableIterator1 last1, > SinglePassTraversalReadableIterator2 first2, > SinglePassTraversalReadableIterator2 last2, > BinaryPredicate pred, > IteratorCategoryTag1, > IteratorCategoryTag2 ) > { > while (true) > { > > > > if (first1 == last1) > return first2 == last2; > > > > > if (first2 == last2) > return false; > > > if (!pred(*first1, *first2)) > break; > > ++first1; > ++first2; > } > > > > return false; > } > > > > template< class RandomAccessTraversalReadableIterator1, > class RandomAccessTraversalReadableIterator2 > > inline bool equal_impl( RandomAccessTraversalReadableIterator1 first1, > RandomAccessTraversalReadableIterator1 last1, > RandomAccessTraversalReadableIterator2 first2, > RandomAccessTraversalReadableIterator2 last2, > std::random_access_iterator_tag, > std::random_access_iterator_tag ) > { > return ((last1 - first1) == (last2 - first2)) > && std::equal(first1, last1, first2); > } > > template< class RandomAccessTraversalReadableIterator1, > class RandomAccessTraversalReadableIterator2, > class BinaryPredicate > > inline bool equal_impl( RandomAccessTraversalReadableIterator1 first1, > RandomAccessTraversalReadableIterator1 last1, > RandomAccessTraversalReadableIterator2 first2, > RandomAccessTraversalReadableIterator2 last2, > BinaryPredicate pred ) > { > return ((last1 - first1) == (last2 - first2)) > && std::equal(first1, last1, first2, pred); > } > > template< class SinglePassTraversalReadableIterator1, > class SinglePassTraversalReadableIterator2 > > inline bool equal( SinglePassTraversalReadableIterator1 first1, > SinglePassTraversalReadableIterator1 last1, > SinglePassTraversalReadableIterator2 first2, > SinglePassTraversalReadableIterator2 last2 ) > { > typename std::iterator_traits< SinglePassTraversalReadableIterator1 >::iterator_category tag1; > typename std::iterator_traits< SinglePassTraversalReadableIterator2 >::iterator_category tag2; > > return equal_impl(first1, last1, first2, last2, tag1, tag2); > } > > template< class SinglePassTraversalReadableIterator1, > class SinglePassTraversalReadableIterator2, > class BinaryPredicate > > inline bool equal( SinglePassTraversalReadableIterator1 first1, > SinglePassTraversalReadableIterator1 last1, > SinglePassTraversalReadableIterator2 first2, > SinglePassTraversalReadableIterator2 last2, > BinaryPredicate pred ) > { > typename std::iterator_traits< SinglePassTraversalReadableIterator1 >::iterator_category tag1; > typename std::iterator_traits< SinglePassTraversalReadableIterator2 >::iterator_category tag2; > > return equal_impl(first1, last1, first2, last2, pred, tag1, tag2); > } > > } > > namespace range > { ># 169 "/usr/include/boost/range/algorithm/equal.hpp" 3 4 > template< class SinglePassRange1, class SinglePassRange2 > > inline bool equal( const SinglePassRange1& rng1, const SinglePassRange2& rng2 ) > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( SinglePassRangeConcept<const SinglePassRange1> )>::failed> boost_concept_check172; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( SinglePassRangeConcept<const SinglePassRange2> )>::failed> boost_concept_check173; > > return ::boost::range_detail::equal( > ::boost::begin(rng1), ::boost::end(rng1), > ::boost::begin(rng2), ::boost::end(rng2) ); > } > > > template< class SinglePassRange1, class SinglePassRange2, class BinaryPredicate > > inline bool equal( const SinglePassRange1& rng1, const SinglePassRange2& rng2, > BinaryPredicate pred ) > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( SinglePassRangeConcept<const SinglePassRange1> )>::failed> boost_concept_check185; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( SinglePassRangeConcept<const SinglePassRange2> )>::failed> boost_concept_check186; > > return ::boost::range_detail::equal( > ::boost::begin(rng1), ::boost::end(rng1), > ::boost::begin(rng2), ::boost::end(rng2), > pred); > } > > } > using ::boost::range::equal; >} ># 32 "/usr/include/boost/range/iterator_range_core.hpp" 2 3 4 ># 1 "/usr/include/boost/range/detail/safe_bool.hpp" 1 3 4 ># 16 "/usr/include/boost/range/detail/safe_bool.hpp" 3 4 >namespace boost >{ > namespace range_detail > { > >template<class DataMemberPtr> >class safe_bool >{ >public: > typedef safe_bool this_type; ># 56 "/usr/include/boost/range/detail/safe_bool.hpp" 3 4 > typedef DataMemberPtr unspecified_bool_type; > static unspecified_bool_type to_unspecified_bool(const bool x, DataMemberPtr p) > { > return x ? p : 0; > } > >private: > safe_bool(); > safe_bool(const safe_bool&); > void operator=(const safe_bool&); > ~safe_bool(); >}; > > } >} ># 33 "/usr/include/boost/range/iterator_range_core.hpp" 2 3 4 ># 45 "/usr/include/boost/range/iterator_range_core.hpp" 3 4 >namespace boost >{ > namespace iterator_range_detail > { > > > > > template<class IteratorT> > struct iterator_range_impl { > template< class ForwardRange > > static IteratorT adl_begin( ForwardRange& r ) > { > return static_cast<IteratorT>( boost::begin( r ) ); > } > > template< class ForwardRange > > static IteratorT adl_end( ForwardRange& r ) > { > return static_cast<IteratorT>( boost::end( r ) ); > } > }; > > template< class Left, class Right > > inline bool less_than( const Left& l, const Right& r ) > { > return std::lexicographical_compare( boost::begin(l), > boost::end(l), > boost::begin(r), > boost::end(r) ); > } > > template< class Left, class Right > > inline bool greater_than( const Left& l, const Right& r ) > { > return less_than(r,l); > } > > template< class Left, class Right > > inline bool less_or_equal_than( const Left& l, const Right& r ) > { > return !iterator_range_detail::less_than(r,l); > } > > template< class Left, class Right > > inline bool greater_or_equal_than( const Left& l, const Right& r ) > { > return !iterator_range_detail::less_than(l,r); > } > > > > template< class Left, class Right > > inline bool equal(const Left& l, const Right& r) > { > return boost::equal(l, r); > } > > struct range_tag { }; > struct const_range_tag { }; > } ># 126 "/usr/include/boost/range/iterator_range_core.hpp" 3 4 > template<class IteratorT> > class iterator_range > { > typedef range_detail::safe_bool< IteratorT iterator_range<IteratorT>::* > safe_bool_t; > protected: > > typedef iterator_range_detail::iterator_range_impl<IteratorT> impl; > public: > > typedef iterator_range<IteratorT> type; > typedef typename safe_bool_t::unspecified_bool_type unspecified_bool_type; > > > > typedef typename > iterator_value<IteratorT>::type value_type; > > > typedef typename > iterator_difference<IteratorT>::type difference_type; > > > typedef std::size_t size_type; > > > typedef iterator_range<IteratorT> this_type; > > > > > > > typedef typename > iterator_reference<IteratorT>::type reference; > > > > > > > typedef IteratorT const_iterator; > > typedef IteratorT iterator; > > private: > typedef typename > boost::mpl::if_< boost::mpl::or_< boost::is_abstract< value_type >, > boost::is_array< value_type > >, > reference, value_type >::type abstract_value_type; > > public: > iterator_range() : m_Begin( iterator() ), m_End( iterator() ) > { } > > > template< class Iterator > > iterator_range( Iterator Begin, Iterator End ) : > m_Begin(Begin), m_End(End) > {} > > > template< class Range > > iterator_range( const Range& r ) : > m_Begin( impl::adl_begin( r ) ), m_End( impl::adl_end( r ) ) > {} > > > template< class Range > > iterator_range( Range& r ) : > m_Begin( impl::adl_begin( r ) ), m_End( impl::adl_end( r ) ) > {} > > > template< class Range > > iterator_range( const Range& r, iterator_range_detail::const_range_tag ) : > m_Begin( impl::adl_begin( r ) ), m_End( impl::adl_end( r ) ) > {} > > > template< class Range > > iterator_range( Range& r, iterator_range_detail::range_tag ) : > m_Begin( impl::adl_begin( r ) ), m_End( impl::adl_end( r ) ) > {} > > > this_type& operator=( const this_type& r ) > { > m_Begin = r.begin(); > m_End = r.end(); > return *this; > } > > > template< class Iterator > > iterator_range& operator=( const iterator_range<Iterator>& r ) > { > m_Begin = r.begin(); > m_End = r.end(); > return *this; > } > > template< class ForwardRange > > iterator_range& operator=( ForwardRange& r ) > { > m_Begin = impl::adl_begin( r ); > m_End = impl::adl_end( r ); > return *this; > } > > template< class ForwardRange > > iterator_range& operator=( const ForwardRange& r ) > { > m_Begin = impl::adl_begin( r ); > m_End = impl::adl_end( r ); > return *this; > } > > IteratorT begin() const > { > return m_Begin; > } > > IteratorT end() const > { > return m_End; > } > > difference_type size() const > { > return m_End - m_Begin; > } > > bool empty() const > { > return m_Begin == m_End; > } > > operator unspecified_bool_type() const > { > return safe_bool_t::to_unspecified_bool(m_Begin != m_End, &iterator_range::m_Begin); > } > > bool operator!() const > { > return empty(); > } > > bool equal( const iterator_range& r ) const > { > return m_Begin == r.m_Begin && m_End == r.m_End; > } ># 313 "/usr/include/boost/range/iterator_range_core.hpp" 3 4 > public: > reference front() const > { > (static_cast<void> (0)); > return *m_Begin; > } > > reference back() const > { > (static_cast<void> (0)); > IteratorT last( m_End ); > return *--last; > } > > > void pop_front() > { > (static_cast<void> (0)); > ++m_Begin; > } > > > void pop_back() > { > (static_cast<void> (0)); > --m_End; > } > > reference operator[]( difference_type at ) const > { > (static_cast<void> (0)); > return m_Begin[at]; > } > > > > > > > abstract_value_type operator()( difference_type at ) const > { > (static_cast<void> (0)); > return m_Begin[at]; > } > > iterator_range& advance_begin( difference_type n ) > { > std::advance( m_Begin, n ); > return *this; > } > > iterator_range& advance_end( difference_type n ) > { > std::advance( m_End, n ); > return *this; > } > > private: > > IteratorT m_Begin; > IteratorT m_End; > > protected: > > > > > typedef iterator_range iterator_range_; > }; > > > > > > > > template< class IteratorT, class ForwardRange > > inline bool operator==( const ForwardRange& l, > const iterator_range<IteratorT>& r ) > { > return boost::equal( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator!=( const ForwardRange& l, > const iterator_range<IteratorT>& r ) > { > return !boost::equal( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator<( const ForwardRange& l, > const iterator_range<IteratorT>& r ) > { > return iterator_range_detail::less_than( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator<=( const ForwardRange& l, > const iterator_range<IteratorT>& r ) > { > return iterator_range_detail::less_or_equal_than( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator>( const ForwardRange& l, > const iterator_range<IteratorT>& r ) > { > return iterator_range_detail::greater_than( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator>=( const ForwardRange& l, > const iterator_range<IteratorT>& r ) > { > return iterator_range_detail::greater_or_equal_than( l, r ); > } > > > > template< class Iterator1T, class Iterator2T > > inline bool operator==( const iterator_range<Iterator1T>& l, > const iterator_range<Iterator2T>& r ) > { > return boost::equal( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator==( const iterator_range<IteratorT>& l, > const ForwardRange& r ) > { > return boost::equal( l, r ); > } > > > template< class Iterator1T, class Iterator2T > > inline bool operator!=( const iterator_range<Iterator1T>& l, > const iterator_range<Iterator2T>& r ) > { > return !boost::equal( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator!=( const iterator_range<IteratorT>& l, > const ForwardRange& r ) > { > return !boost::equal( l, r ); > } > > > template< class Iterator1T, class Iterator2T > > inline bool operator<( const iterator_range<Iterator1T>& l, > const iterator_range<Iterator2T>& r ) > { > return iterator_range_detail::less_than( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator<( const iterator_range<IteratorT>& l, > const ForwardRange& r ) > { > return iterator_range_detail::less_than( l, r ); > } > > template< class Iterator1T, class Iterator2T > > inline bool operator<=( const iterator_range<Iterator1T>& l, > const iterator_range<Iterator2T>& r ) > { > return iterator_range_detail::less_or_equal_than( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator<=( const iterator_range<IteratorT>& l, > const ForwardRange& r ) > { > return iterator_range_detail::less_or_equal_than( l, r ); > } > > template< class Iterator1T, class Iterator2T > > inline bool operator>( const iterator_range<Iterator1T>& l, > const iterator_range<Iterator2T>& r ) > { > return iterator_range_detail::greater_than( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator>( const iterator_range<IteratorT>& l, > const ForwardRange& r ) > { > return iterator_range_detail::greater_than( l, r ); > } > > template< class Iterator1T, class Iterator2T > > inline bool operator>=( const iterator_range<Iterator1T>& l, > const iterator_range<Iterator2T>& r ) > { > return iterator_range_detail::greater_or_equal_than( l, r ); > } > > template< class IteratorT, class ForwardRange > > inline bool operator>=( const iterator_range<IteratorT>& l, > const ForwardRange& r ) > { > return iterator_range_detail::greater_or_equal_than( l, r ); > } ># 531 "/usr/include/boost/range/iterator_range_core.hpp" 3 4 > template< typename IteratorT > > inline iterator_range< IteratorT > > make_iterator_range( IteratorT Begin, IteratorT End ) > { > return iterator_range<IteratorT>( Begin, End ); > } ># 554 "/usr/include/boost/range/iterator_range_core.hpp" 3 4 > template< class ForwardRange > > inline iterator_range< typename range_iterator<ForwardRange>::type > > make_iterator_range( ForwardRange& r ) > { > return iterator_range< typename range_iterator<ForwardRange>::type > > ( r, iterator_range_detail::range_tag() ); > } > > template< class ForwardRange > > inline iterator_range< typename range_iterator<const ForwardRange>::type > > make_iterator_range( const ForwardRange& r ) > { > return iterator_range< typename range_iterator<const ForwardRange>::type > > ( r, iterator_range_detail::const_range_tag() ); > } > > > > namespace iterator_range_detail > { > template< class Range > > inline iterator_range< typename range_iterator<Range>::type > > make_range_impl( Range& r, > typename range_difference<Range>::type advance_begin, > typename range_difference<Range>::type advance_end ) > { > > > > > > > > typename range_iterator<Range>::type > new_begin = boost::begin( r ), > new_end = boost::end( r ); > std::advance( new_begin, advance_begin ); > std::advance( new_end, advance_end ); > return make_iterator_range( new_begin, new_end ); > } > } ># 610 "/usr/include/boost/range/iterator_range_core.hpp" 3 4 > template< class Range > > inline iterator_range< typename range_iterator<Range>::type > > make_iterator_range( Range& r, > typename range_difference<Range>::type advance_begin, > typename range_difference<Range>::type advance_end ) > { > > return iterator_range_detail::make_range_impl( r, advance_begin, advance_end ); > } > > template< class Range > > inline iterator_range< typename range_iterator<const Range>::type > > make_iterator_range( const Range& r, > typename range_difference<Range>::type advance_begin, > typename range_difference<Range>::type advance_end ) > { > > return iterator_range_detail::make_range_impl( r, advance_begin, advance_end ); > } ># 640 "/usr/include/boost/range/iterator_range_core.hpp" 3 4 > template< typename SeqT, typename Range > > inline SeqT copy_range( const Range& r ) > { > return SeqT( boost::begin( r ), boost::end( r ) ); > } > >} ># 14 "/usr/include/boost/range/iterator_range.hpp" 2 3 4 ># 1 "/usr/include/boost/range/iterator_range_io.hpp" 1 3 4 ># 43 "/usr/include/boost/range/iterator_range_io.hpp" 3 4 >namespace boost >{ ># 54 "/usr/include/boost/range/iterator_range_io.hpp" 3 4 > template< typename IteratorT, typename Elem, typename Traits > > inline std::basic_ostream<Elem,Traits>& operator<<( > std::basic_ostream<Elem, Traits>& Os, > const iterator_range<IteratorT>& r ) > { > std::copy( r.begin(), r.end(), > std::ostream_iterator< typename > iterator_value<IteratorT>::type, > Elem, Traits>(Os) ); > return Os; > } ># 85 "/usr/include/boost/range/iterator_range_io.hpp" 3 4 >} ># 15 "/usr/include/boost/range/iterator_range.hpp" 2 3 4 ># 23 "/usr/include/boost/range/as_literal.hpp" 2 3 4 ># 1 "/usr/include/boost/range/detail/str_types.hpp" 1 3 4 ># 17 "/usr/include/boost/range/detail/str_types.hpp" 3 4 >namespace boost >{ > template< class T > > struct range_mutable_iterator<T*> > { > typedef T* type; > }; > > template< class T > > struct range_const_iterator<T*> > { > typedef const T* type; > }; > > template< class T > > struct range_size<T*> > { > typedef std::size_t type; > }; >} ># 24 "/usr/include/boost/range/as_literal.hpp" 2 3 4 > > > ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 28 "/usr/include/boost/range/as_literal.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/cwchar" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cwchar" 3 4 ># 40 "/usr/include/c++/4.9.0/cwchar" 3 > > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 45 "/usr/include/c++/4.9.0/cwchar" 2 3 ># 30 "/usr/include/boost/range/as_literal.hpp" 2 3 4 > > >namespace boost >{ > namespace range_detail > { > inline std::size_t length( const char* s ) > { > return strlen( s ); > } > > > inline std::size_t length( const wchar_t* s ) > { > return wcslen( s ); > } ># 54 "/usr/include/boost/range/as_literal.hpp" 3 4 > inline bool is_char_ptr( char* ) > { > return true; > } > > inline bool is_char_ptr( const char* ) > { > return true; > } > > > inline bool is_char_ptr( wchar_t* ) > { > return true; > } > > inline bool is_char_ptr( const wchar_t* ) > { > return true; > } > > > template< class T > > inline long is_char_ptr( const T& ) > { > return 0L; > } > > template< class T > > inline iterator_range<T*> > make_range( T* const r, bool ) > { > return iterator_range<T*>( r, r + length(r) ); > } > > template< class T > > inline iterator_range<typename range_iterator<T>::type> > make_range( T& r, long ) > { > return boost::make_iterator_range( r ); > } > > } > > template< class Range > > inline iterator_range<typename range_iterator<Range>::type> > as_literal( Range& r ) > { > return range_detail::make_range( r, range_detail::is_char_ptr(r) ); > } > > template< class Range > > inline iterator_range<typename range_iterator<const Range>::type> > as_literal( const Range& r ) > { > return range_detail::make_range( r, range_detail::is_char_ptr(r) ); > } > > template< class Char, std::size_t sz > > inline iterator_range<Char*> as_literal( Char (&arr)[sz] ) > { > return range_detail::make_range( arr, range_detail::is_char_ptr(arr) ); > } > > template< class Char, std::size_t sz > > inline iterator_range<const Char*> as_literal( const Char (&arr)[sz] ) > { > return range_detail::make_range( arr, range_detail::is_char_ptr(arr) ); > } >} ># 20 "/usr/include/boost/algorithm/string/trim.hpp" 2 3 4 > > ># 1 "/usr/include/boost/algorithm/string/detail/trim.hpp" 1 3 4 ># 17 "/usr/include/boost/algorithm/string/detail/trim.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { > > > > 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; > } > > 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; > } > > > template< typename ForwardIteratorT, typename PredicateT > > inline ForwardIteratorT trim_end( > ForwardIteratorT InBegin, > ForwardIteratorT InEnd, > PredicateT IsSpace ) > { > typedef typename boost::detail:: > iterator_traits<ForwardIteratorT>::iterator_category category; > > return ::boost::algorithm::detail::trim_end_iter_select( InBegin, InEnd, IsSpace, category() ); > } > > > } > } >} ># 23 "/usr/include/boost/algorithm/string/trim.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/classification.hpp" 1 3 4 ># 18 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/classification.hpp" 1 3 4 ># 22 "/usr/include/boost/algorithm/string/detail/classification.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/predicate_facade.hpp" 1 3 4 ># 23 "/usr/include/boost/algorithm/string/predicate_facade.hpp" 3 4 >namespace boost { > namespace algorithm { ># 35 "/usr/include/boost/algorithm/string/predicate_facade.hpp" 3 4 > template<typename Derived> > struct predicate_facade {}; > > } >} ># 23 "/usr/include/boost/algorithm/string/detail/classification.hpp" 2 3 4 > > >namespace boost { > namespace algorithm { > namespace detail { > > > > > struct is_classifiedF : > public predicate_facade<is_classifiedF> > { > > typedef bool result_type; > > > is_classifiedF(std::ctype_base::mask Type, std::locale const & Loc = std::locale()) : > m_Type(Type), m_Locale(Loc) {} > > template<typename CharT> > bool operator()( CharT Ch ) const > { > return std::use_facet< std::ctype<CharT> >(m_Locale).is( m_Type, Ch ); > } ># 56 "/usr/include/boost/algorithm/string/detail/classification.hpp" 3 4 > private: > std::ctype_base::mask m_Type; > std::locale m_Locale; > }; > > > > > > > template<typename CharT> > struct is_any_ofF : > public predicate_facade<is_any_ofF<CharT> > > { > private: > > typedef typename ::boost::remove_const<CharT>::type set_value_type; > > public: > > typedef bool result_type; > > > template<typename RangeT> > is_any_ofF( const RangeT& Range ) : m_Size(0) > { > > 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)) > { > > Storage=&m_Storage.m_fixSet[0]; > } > else > { > > m_Storage.m_dynSet=new set_value_type[m_Size]; > Storage=m_Storage.m_dynSet; > } > > > ::std::copy(::boost::begin(Range), ::boost::end(Range), Storage); > ::std::sort(Storage, Storage+m_Size); > } > > > is_any_ofF(const is_any_ofF& Other) : m_Size(Other.m_Size) > { > > m_Storage.m_dynSet=0; > const set_value_type* SrcStorage=0; > set_value_type* DestStorage=0; > > if(use_fixed_storage(m_Size)) > { > > DestStorage=&m_Storage.m_fixSet[0]; > SrcStorage=&Other.m_Storage.m_fixSet[0]; > } > else > { > > m_Storage.m_dynSet=new set_value_type[m_Size]; > DestStorage=m_Storage.m_dynSet; > SrcStorage=Other.m_Storage.m_dynSet; > } > > > ::std::memcpy(DestStorage, SrcStorage, sizeof(set_value_type)*m_Size); > } > > > ~is_any_ofF() > { > if(!use_fixed_storage(m_Size) && m_Storage.m_dynSet!=0) > { > delete [] m_Storage.m_dynSet; > } > } > > > is_any_ofF& operator=(const is_any_ofF& Other) > { > > if(this==&Other) return *this; > > > const set_value_type* SrcStorage; > set_value_type* DestStorage; > > if(use_fixed_storage(Other.m_Size)) > { > > DestStorage=&m_Storage.m_fixSet[0]; > SrcStorage=&Other.m_Storage.m_fixSet[0]; > > > if(!use_fixed_storage(m_Size) && m_Storage.m_dynSet!=0) > { > delete [] m_Storage.m_dynSet; > } > > > m_Size=Other.m_Size; > } > else > { > > SrcStorage=Other.m_Storage.m_dynSet; > > > if(use_fixed_storage(m_Size)) > { > > set_value_type* pTemp=new set_value_type[Other.m_Size]; > DestStorage=pTemp; > m_Storage.m_dynSet=pTemp; > m_Size=Other.m_Size; > } > else > { > > if(m_Storage.m_dynSet!=0 && m_Size>=Other.m_Size && m_Size<Other.m_Size*2) > { > > DestStorage=m_Storage.m_dynSet; > m_Size=Other.m_Size; > } > else > { > > set_value_type* pTemp=new set_value_type[Other.m_Size]; > DestStorage=pTemp; > > > if(m_Storage.m_dynSet!=0) > { > delete [] m_Storage.m_dynSet; > } > > m_Storage.m_dynSet=pTemp; > > m_Size=Other.m_Size; > } > } > } > > > ::std::memcpy(DestStorage, SrcStorage, sizeof(set_value_type)*m_Size); > > return *this; > } > > > template<typename Char2T> > 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: > > static bool use_fixed_storage(std::size_t size) > { > return size<=sizeof(set_value_type*)*2; > } > > > private: > > > union > { > set_value_type* m_dynSet; > set_value_type m_fixSet[sizeof(set_value_type*)*2]; > } > m_Storage; > > > ::std::size_t m_Size; > }; > > > > > > > template<typename CharT> > struct is_from_rangeF : > public predicate_facade< is_from_rangeF<CharT> > > { > > typedef bool result_type; > > > is_from_rangeF( CharT From, CharT To ) : m_From(From), m_To(To) {} > > > template<typename Char2T> > bool operator()( Char2T Ch ) const > { > return ( m_From <= Ch ) && ( Ch <= m_To ); > } > > private: > CharT m_From; > CharT m_To; > }; > > > template<typename Pred1T, typename Pred2T> > struct pred_andF : > public predicate_facade< pred_andF<Pred1T,Pred2T> > > { > public: > > > typedef bool result_type; > > > pred_andF( Pred1T Pred1, Pred2T Pred2 ) : > m_Pred1(Pred1), m_Pred2(Pred2) {} > > > template<typename CharT> > bool operator()( CharT Ch ) const > { > return m_Pred1(Ch) && m_Pred2(Ch); > } > > private: > Pred1T m_Pred1; > Pred2T m_Pred2; > }; > > > template<typename Pred1T, typename Pred2T> > struct pred_orF : > public predicate_facade< pred_orF<Pred1T,Pred2T> > > { > public: > > typedef bool result_type; > > > pred_orF( Pred1T Pred1, Pred2T Pred2 ) : > m_Pred1(Pred1), m_Pred2(Pred2) {} > > > template<typename CharT> > bool operator()( CharT Ch ) const > { > return m_Pred1(Ch) || m_Pred2(Ch); > } > > private: > Pred1T m_Pred1; > Pred2T m_Pred2; > }; > > > template< typename PredT > > struct pred_notF : > public predicate_facade< pred_notF<PredT> > > { > public: > > typedef bool result_type; > > > pred_notF( PredT Pred ) : m_Pred(Pred) {} > > > template<typename CharT> > bool operator()( CharT Ch ) const > { > return !m_Pred(Ch); > } > > private: > PredT m_Pred; > }; > > } > } >} ># 19 "/usr/include/boost/algorithm/string/classification.hpp" 2 3 4 ># 29 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 >namespace boost { > namespace algorithm { ># 43 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_classified(std::ctype_base::mask Type, const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(Type, Loc); > } ># 56 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_space(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::space, Loc); > } ># 69 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_alnum(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::alnum, Loc); > } ># 82 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_alpha(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::alpha, Loc); > } ># 95 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_cntrl(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::cntrl, Loc); > } ># 108 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_digit(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::digit, Loc); > } ># 121 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_graph(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::graph, Loc); > } ># 134 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_lower(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::lower, Loc); > } ># 147 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_print(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::print, Loc); > } ># 160 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_punct(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::punct, Loc); > } ># 173 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_upper(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::upper, Loc); > } ># 186 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > inline detail::is_classifiedF > is_xdigit(const std::locale& Loc=std::locale()) > { > return detail::is_classifiedF(std::ctype_base::xdigit, Loc); > } ># 200 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > template<typename RangeT> > inline detail::is_any_ofF< > typename range_value<RangeT>::type> > is_any_of( const RangeT& Set ) > { > iterator_range<typename range_const_iterator<RangeT>::type> lit_set(boost::as_literal(Set)); > return detail::is_any_ofF<typename range_value<RangeT>::type>(lit_set); > } ># 218 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > template<typename CharT> > inline detail::is_from_rangeF<CharT> is_from_range(CharT From, CharT To) > { > return detail::is_from_rangeF<CharT>(From,To); > } ># 236 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > template<typename Pred1T, typename Pred2T> > inline detail::pred_andF<Pred1T, Pred2T> > operator&&( > const predicate_facade<Pred1T>& Pred1, > const predicate_facade<Pred2T>& Pred2 ) > { > > > > return detail::pred_andF<Pred1T,Pred2T>( > *static_cast<const Pred1T*>(&Pred1), > *static_cast<const Pred2T*>(&Pred2) ); > } ># 260 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > template<typename Pred1T, typename Pred2T> > inline detail::pred_orF<Pred1T, Pred2T> > operator||( > const predicate_facade<Pred1T>& Pred1, > const predicate_facade<Pred2T>& Pred2 ) > { > > > > return detail::pred_orF<Pred1T,Pred2T>( > *static_cast<const Pred1T*>(&Pred1), > *static_cast<const Pred2T*>(&Pred2)); > } ># 282 "/usr/include/boost/algorithm/string/classification.hpp" 3 4 > template<typename PredT> > inline detail::pred_notF<PredT> > operator!( const predicate_facade<PredT>& Pred ) > { > > > > return detail::pred_notF<PredT>(*static_cast<const PredT*>(&Pred)); > } > > } > > > 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; > >} ># 24 "/usr/include/boost/algorithm/string/trim.hpp" 2 3 4 ># 38 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 >namespace boost { > namespace algorithm { ># 60 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename OutputIteratorT, typename RangeT, typename PredicateT> > inline OutputIteratorT trim_left_copy_if( > OutputIteratorT Output, > const RangeT& Input, > PredicateT IsSpace) > { > iterator_range<typename range_const_iterator<RangeT>::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; > } > > > > > > template<typename SequenceT, typename PredicateT> > 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)); > } ># 105 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename SequenceT> > 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)); > } ># 123 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename SequenceT, typename PredicateT> > 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)); > } ># 142 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename SequenceT> > inline void trim_left(SequenceT& Input, const std::locale& Loc=std::locale()) > { > ::boost::algorithm::trim_left_if( > Input, > is_space(Loc)); > } ># 168 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename OutputIteratorT, typename RangeT, typename PredicateT> > inline OutputIteratorT trim_right_copy_if( > OutputIteratorT Output, > const RangeT& Input, > PredicateT IsSpace ) > { > iterator_range<typename range_const_iterator<RangeT>::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; > } > > > > > > template<typename SequenceT, typename PredicateT> > 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) > ); > } ># 214 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename SequenceT> > 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)); > } ># 233 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename SequenceT, typename PredicateT> > 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) > ); > } ># 254 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename SequenceT> > inline void trim_right(SequenceT& Input, const std::locale& Loc=std::locale()) > { > ::boost::algorithm::trim_right_if( > Input, > is_space(Loc) ); > } ># 280 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename OutputIteratorT, typename RangeT, typename PredicateT> > inline OutputIteratorT trim_copy_if( > OutputIteratorT Output, > const RangeT& Input, > PredicateT IsSpace) > { > iterator_range<typename range_const_iterator<RangeT>::type> lit_range(::boost::as_literal(Input)); > > typename > range_const_iterator<RangeT>::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; > } > > > > > > template<typename SequenceT, typename PredicateT> > inline SequenceT trim_copy_if(const SequenceT& Input, PredicateT IsSpace) > { > typename > range_const_iterator<SequenceT>::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 > ); > } ># 339 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename SequenceT> > inline SequenceT trim_copy( const SequenceT& Input, const std::locale& Loc=std::locale() ) > { > return > ::boost::algorithm::trim_copy_if( > Input, > is_space(Loc) ); > } ># 357 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename SequenceT, typename PredicateT> > inline void trim_if(SequenceT& Input, PredicateT IsSpace) > { > ::boost::algorithm::trim_right_if( Input, IsSpace ); > ::boost::algorithm::trim_left_if( Input, IsSpace ); > } ># 372 "/usr/include/boost/algorithm/string/trim.hpp" 3 4 > template<typename SequenceT> > inline void trim(SequenceT& Input, const std::locale& Loc=std::locale()) > { > ::boost::algorithm::trim_if( > Input, > is_space( Loc ) ); > } > > } > > > 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; > >} ># 20 "/usr/include/boost/algorithm/string.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/case_conv.hpp" 1 3 4 ># 17 "/usr/include/boost/algorithm/string/case_conv.hpp" 3 4 ># 1 "/usr/include/boost/iterator/transform_iterator.hpp" 1 3 4 ># 16 "/usr/include/boost/iterator/transform_iterator.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/function_traits.hpp" 1 3 4 ># 16 "/usr/include/boost/type_traits/function_traits.hpp" 3 4 >namespace boost { > > >namespace detail { > >template<typename Function> struct function_traits_helper; > >template<typename R> >struct function_traits_helper<R (*)(void)> >{ > static const unsigned arity = 0; > typedef R result_type; >}; > >template<typename R, typename T1> >struct function_traits_helper<R (*)(T1)> >{ > static const unsigned arity = 1; > typedef R result_type; > typedef T1 arg1_type; > typedef T1 argument_type; >}; > >template<typename R, typename T1, typename T2> >struct function_traits_helper<R (*)(T1, T2)> >{ > static const unsigned arity = 2; > typedef R result_type; > typedef T1 arg1_type; > typedef T2 arg2_type; > typedef T1 first_argument_type; > typedef T2 second_argument_type; >}; > >template<typename R, typename T1, typename T2, typename T3> >struct function_traits_helper<R (*)(T1, T2, T3)> >{ > static const unsigned arity = 3; > typedef R result_type; > typedef T1 arg1_type; > typedef T2 arg2_type; > typedef T3 arg3_type; >}; > >template<typename R, typename T1, typename T2, typename T3, typename T4> >struct function_traits_helper<R (*)(T1, T2, T3, T4)> >{ > static const unsigned arity = 4; > typedef R result_type; > typedef T1 arg1_type; > typedef T2 arg2_type; > typedef T3 arg3_type; > typedef T4 arg4_type; >}; > >template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5> >struct function_traits_helper<R (*)(T1, T2, T3, T4, T5)> >{ > static const unsigned arity = 5; > typedef R result_type; > typedef T1 arg1_type; > typedef T2 arg2_type; > typedef T3 arg3_type; > typedef T4 arg4_type; > typedef T5 arg5_type; >}; > >template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6> >struct function_traits_helper<R (*)(T1, T2, T3, T4, T5, T6)> >{ > static const unsigned arity = 6; > typedef R result_type; > typedef T1 arg1_type; > typedef T2 arg2_type; > typedef T3 arg3_type; > typedef T4 arg4_type; > typedef T5 arg5_type; > typedef T6 arg6_type; >}; > >template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6, typename T7> >struct function_traits_helper<R (*)(T1, T2, T3, T4, T5, T6, T7)> >{ > static const unsigned arity = 7; > typedef R result_type; > typedef T1 arg1_type; > typedef T2 arg2_type; > typedef T3 arg3_type; > typedef T4 arg4_type; > typedef T5 arg5_type; > typedef T6 arg6_type; > typedef T7 arg7_type; >}; > >template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6, typename T7, typename T8> >struct function_traits_helper<R (*)(T1, T2, T3, T4, T5, T6, T7, T8)> >{ > static const unsigned arity = 8; > typedef R result_type; > typedef T1 arg1_type; > typedef T2 arg2_type; > typedef T3 arg3_type; > typedef T4 arg4_type; > typedef T5 arg5_type; > typedef T6 arg6_type; > typedef T7 arg7_type; > typedef T8 arg8_type; >}; > >template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6, typename T7, typename T8, typename T9> >struct function_traits_helper<R (*)(T1, T2, T3, T4, T5, T6, T7, T8, T9)> >{ > static const unsigned arity = 9; > typedef R result_type; > typedef T1 arg1_type; > typedef T2 arg2_type; > typedef T3 arg3_type; > typedef T4 arg4_type; > typedef T5 arg5_type; > typedef T6 arg6_type; > typedef T7 arg7_type; > typedef T8 arg8_type; > typedef T9 arg9_type; >}; > >template<typename R, typename T1, typename T2, typename T3, typename T4, > typename T5, typename T6, typename T7, typename T8, typename T9, > typename T10> >struct function_traits_helper<R (*)(T1, T2, T3, T4, T5, T6, T7, T8, T9, T10)> >{ > static const unsigned arity = 10; > typedef R result_type; > typedef T1 arg1_type; > typedef T2 arg2_type; > typedef T3 arg3_type; > typedef T4 arg4_type; > typedef T5 arg5_type; > typedef T6 arg6_type; > typedef T7 arg7_type; > typedef T8 arg8_type; > typedef T9 arg9_type; > typedef T10 arg10_type; >}; > >} > >template<typename Function> >struct function_traits : > public boost::detail::function_traits_helper<typename boost::add_pointer<Function>::type> >{ >}; ># 234 "/usr/include/boost/type_traits/function_traits.hpp" 3 4 >} ># 17 "/usr/include/boost/iterator/transform_iterator.hpp" 2 3 4 ># 30 "/usr/include/boost/iterator/transform_iterator.hpp" 3 4 ># 1 "/usr/include/boost/iterator/detail/config_def.hpp" 1 3 4 ># 31 "/usr/include/boost/iterator/transform_iterator.hpp" 2 3 4 > > >namespace boost >{ > template <class UnaryFunction, class Iterator, class Reference = use_default, class Value = use_default> > class transform_iterator; > > namespace detail > { > > template <class UnaryFunc, class Iterator, class Reference, class Value> > struct transform_iterator_base > { > private: > > > typedef typename ia_dflt_help< > Reference > , result_of<const UnaryFunc(typename std::iterator_traits<Iterator>::reference)> > >::type reference; > > > > > > > typedef typename ia_dflt_help< > Value > , remove_reference<reference> > >::type cv_value_type; > > public: > typedef iterator_adaptor< > transform_iterator<UnaryFunc, Iterator, Reference, Value> > , Iterator > , cv_value_type > , use_default > , reference > > type; > }; > } > > template <class UnaryFunc, class Iterator, class Reference, class Value> > class transform_iterator > : public boost::detail::transform_iterator_base<UnaryFunc, Iterator, Reference, Value>::type > { > typedef typename > boost::detail::transform_iterator_base<UnaryFunc, Iterator, Reference, Value>::type > super_t; > > friend class iterator_core_access; > > public: > transform_iterator() { } > > transform_iterator(Iterator const& x, UnaryFunc f) > : super_t(x), m_f(f) { } > > explicit transform_iterator(Iterator const& x) > : super_t(x) > { > > > > > > static_assert(is_class<UnaryFunc>::value, "is_class<UnaryFunc>::value"); > > } > > template < > class OtherUnaryFunction > , class OtherIterator > , class OtherReference > , class OtherValue> > transform_iterator( > transform_iterator<OtherUnaryFunction, OtherIterator, OtherReference, OtherValue> const& t > , typename enable_if_convertible<OtherIterator, Iterator>::type* = 0 > > , typename enable_if_convertible<OtherUnaryFunction, UnaryFunc>::type* = 0 > > ) > : super_t(t.base()), m_f(t.functor()) > {} > > UnaryFunc functor() const > { return m_f; } > > private: > typename super_t::reference dereference() const > { return m_f(*this->base()); } > > > > UnaryFunc m_f; > }; > > template <class UnaryFunc, class Iterator> > transform_iterator<UnaryFunc, Iterator> > make_transform_iterator(Iterator it, UnaryFunc fun) > { > return transform_iterator<UnaryFunc, Iterator>(it, fun); > } ># 142 "/usr/include/boost/iterator/transform_iterator.hpp" 3 4 > template <class UnaryFunc, class Iterator> > > > > typename iterators::enable_if< > > is_class<UnaryFunc> > , transform_iterator<UnaryFunc, Iterator> > > > > >::type > make_transform_iterator(Iterator it) > { > return transform_iterator<UnaryFunc, Iterator>(it, UnaryFunc()); > } ># 168 "/usr/include/boost/iterator/transform_iterator.hpp" 3 4 >} > ># 1 "/usr/include/boost/iterator/detail/config_undef.hpp" 1 3 4 ># 171 "/usr/include/boost/iterator/transform_iterator.hpp" 2 3 4 ># 18 "/usr/include/boost/algorithm/string/case_conv.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/algorithm/string/detail/case_conv.hpp" 1 3 4 ># 20 "/usr/include/boost/algorithm/string/detail/case_conv.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { ># 32 "/usr/include/boost/algorithm/string/detail/case_conv.hpp" 3 4 > template<typename CharT> > struct to_lowerF : public std::unary_function<CharT, CharT> > { > > to_lowerF( const std::locale& Loc ) : m_Loc( &Loc ) {} > > > CharT operator ()( CharT Ch ) const > { > > > > return std::tolower<CharT>( Ch, *m_Loc ); > > } > private: > const std::locale* m_Loc; > }; > > > template<typename CharT> > struct to_upperF : public std::unary_function<CharT, CharT> > { > > to_upperF( const std::locale& Loc ) : m_Loc( &Loc ) {} > > > CharT operator ()( CharT Ch ) const > { > > > > return std::toupper<CharT>( Ch, *m_Loc ); > > } > private: > const std::locale* m_Loc; > }; ># 78 "/usr/include/boost/algorithm/string/detail/case_conv.hpp" 3 4 > template<typename OutputIteratorT, typename RangeT, typename FunctorT> > OutputIteratorT transform_range_copy( > OutputIteratorT Output, > const RangeT& Input, > FunctorT Functor) > { > return std::transform( > ::boost::begin(Input), > ::boost::end(Input), > Output, > Functor); > } > > > template<typename RangeT, typename FunctorT> > void transform_range( > const RangeT& Input, > FunctorT Functor) > { > std::transform( > ::boost::begin(Input), > ::boost::end(Input), > ::boost::begin(Input), > Functor); > } > > template<typename SequenceT, typename RangeT, typename FunctorT> > 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)); > } > > } > } >} ># 25 "/usr/include/boost/algorithm/string/case_conv.hpp" 2 3 4 > > > > > > > >namespace boost { > namespace algorithm { ># 53 "/usr/include/boost/algorithm/string/case_conv.hpp" 3 4 > template<typename OutputIteratorT, typename RangeT> > 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<RangeT>::type >(Loc)); > } > > > > > > template<typename SequenceT> > inline SequenceT to_lower_copy( > const SequenceT& Input, > const std::locale& Loc=std::locale()) > { > return ::boost::algorithm::detail::transform_range_copy<SequenceT>( > Input, > ::boost::algorithm::detail::to_lowerF< > typename range_value<SequenceT>::type >(Loc)); > } ># 90 "/usr/include/boost/algorithm/string/case_conv.hpp" 3 4 > template<typename WritableRangeT> > 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<WritableRangeT>::type >(Loc)); > } ># 118 "/usr/include/boost/algorithm/string/case_conv.hpp" 3 4 > template<typename OutputIteratorT, typename RangeT> > 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<RangeT>::type >(Loc)); > } > > > > > > template<typename SequenceT> > inline SequenceT to_upper_copy( > const SequenceT& Input, > const std::locale& Loc=std::locale()) > { > return ::boost::algorithm::detail::transform_range_copy<SequenceT>( > Input, > ::boost::algorithm::detail::to_upperF< > typename range_value<SequenceT>::type >(Loc)); > } ># 155 "/usr/include/boost/algorithm/string/case_conv.hpp" 3 4 > template<typename WritableRangeT> > 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<WritableRangeT>::type >(Loc)); > } > > } > > > using algorithm::to_lower; > using algorithm::to_lower_copy; > using algorithm::to_upper; > using algorithm::to_upper_copy; > >} ># 21 "/usr/include/boost/algorithm/string.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/predicate.hpp" 1 3 4 ># 22 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/compare.hpp" 1 3 4 ># 24 "/usr/include/boost/algorithm/string/compare.hpp" 3 4 >namespace boost { > namespace algorithm { ># 34 "/usr/include/boost/algorithm/string/compare.hpp" 3 4 > struct is_equal > { > > > > > template< typename T1, typename T2 > > bool operator()( const T1& Arg1, const T2& Arg2 ) const > { > return Arg1==Arg2; > } > }; > > > > > > > struct is_iequal > { > > > > > is_iequal( const std::locale& Loc=std::locale() ) : > m_Loc( Loc ) {} > > > > > > template< typename T1, typename T2 > > bool operator()( const T1& Arg1, const T2& Arg2 ) const > { > > > > return std::toupper<T1>(Arg1,m_Loc)==std::toupper<T2>(Arg2,m_Loc); > > } > > private: > std::locale m_Loc; > }; ># 86 "/usr/include/boost/algorithm/string/compare.hpp" 3 4 > struct is_less > { > > > > > template< typename T1, typename T2 > > bool operator()( const T1& Arg1, const T2& Arg2 ) const > { > return Arg1<Arg2; > } > }; > > > > > > > > struct is_iless > { > > > > > is_iless( const std::locale& Loc=std::locale() ) : > m_Loc( Loc ) {} > > > > > > template< typename T1, typename T2 > > bool operator()( const T1& Arg1, const T2& Arg2 ) const > { > > > > return std::toupper<T1>(Arg1,m_Loc)<std::toupper<T2>(Arg2,m_Loc); > > } > > private: > std::locale m_Loc; > }; ># 139 "/usr/include/boost/algorithm/string/compare.hpp" 3 4 > struct is_not_greater > { > > > > > template< typename T1, typename T2 > > bool operator()( const T1& Arg1, const T2& Arg2 ) const > { > return Arg1<=Arg2; > } > }; > > > > > > > > struct is_not_igreater > { > > > > > is_not_igreater( const std::locale& Loc=std::locale() ) : > m_Loc( Loc ) {} > > > > > > template< typename T1, typename T2 > > bool operator()( const T1& Arg1, const T2& Arg2 ) const > { > > > > return std::toupper<T1>(Arg1,m_Loc)<=std::toupper<T2>(Arg2,m_Loc); > > } > > private: > std::locale m_Loc; > }; > > > } > > > 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; > >} ># 23 "/usr/include/boost/algorithm/string/predicate.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/find.hpp" 1 3 4 ># 22 "/usr/include/boost/algorithm/string/find.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/finder.hpp" 1 3 4 ># 22 "/usr/include/boost/algorithm/string/finder.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/constants.hpp" 1 3 4 ># 14 "/usr/include/boost/algorithm/string/constants.hpp" 3 4 >namespace boost { > namespace algorithm { > > > > > > enum token_compress_mode_type > { > token_compress_on, > token_compress_off > }; > > } > > > using algorithm::token_compress_on; > using algorithm::token_compress_off; > >} ># 23 "/usr/include/boost/algorithm/string/finder.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/finder.hpp" 1 3 4 ># 24 "/usr/include/boost/algorithm/string/detail/finder.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { ># 36 "/usr/include/boost/algorithm/string/detail/finder.hpp" 3 4 > template<typename SearchIteratorT,typename PredicateT> > struct first_finderF > { > typedef SearchIteratorT search_iterator_type; > > > 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) {} > > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > operator()( > ForwardIteratorT Begin, > ForwardIteratorT End ) const > { > typedef iterator_range<ForwardIteratorT> result_type; > typedef ForwardIteratorT input_iterator_type; > > > for(input_iterator_type OuterIt=Begin; > OuterIt!=End; > ++OuterIt) > { > > 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; > } > > > if ( SubstrIt==m_Search.end() ) > return result_type( OuterIt, InnerIt ); > } > > return result_type( End, End ); > } > > private: > iterator_range<search_iterator_type> m_Search; > PredicateT m_Comp; > }; ># 100 "/usr/include/boost/algorithm/string/detail/finder.hpp" 3 4 > template<typename SearchIteratorT, typename PredicateT> > struct last_finderF > { > typedef SearchIteratorT search_iterator_type; > typedef first_finderF< > search_iterator_type, > PredicateT> first_finder_type; > > > 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) {} > > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > operator()( > ForwardIteratorT Begin, > ForwardIteratorT End ) const > { > typedef iterator_range<ForwardIteratorT> result_type; > > if( boost::empty(m_Search) ) > return result_type( End, End ); > > typedef typename boost::detail:: > iterator_traits<ForwardIteratorT>::iterator_category category; > > return findit( Begin, End, category() ); > } > > private: > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > findit( > ForwardIteratorT Begin, > ForwardIteratorT End, > std::forward_iterator_tag ) const > { > typedef iterator_range<ForwardIteratorT> 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; > } > > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > findit( > ForwardIteratorT Begin, > ForwardIteratorT End, > std::bidirectional_iterator_tag ) const > { > typedef iterator_range<ForwardIteratorT> result_type; > typedef ForwardIteratorT input_iterator_type; > > > 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; > } > > > if( SubstrIt==m_Search.end() ) > return result_type( OuterIt2, InnerIt ); > } > > return result_type( End, End ); > } > > private: > iterator_range<search_iterator_type> m_Search; > PredicateT m_Comp; > }; ># 209 "/usr/include/boost/algorithm/string/detail/finder.hpp" 3 4 > template<typename SearchIteratorT, typename PredicateT> > 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; > > > 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) {} > > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > 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: > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > find_forward( > ForwardIteratorT Begin, > ForwardIteratorT End, > unsigned int N) const > { > typedef iterator_range<ForwardIteratorT> result_type; > > > if( boost::empty(m_Search) ) > return result_type( End, End ); > > > 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 ) > { > > M=first_finder( ::boost::end(M), End ); > > if ( !M ) > { > > return M; > } > } > > return M; > } > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > find_backward( > ForwardIteratorT Begin, > ForwardIteratorT End, > unsigned int N) const > { > typedef iterator_range<ForwardIteratorT> result_type; > > > if( boost::empty(m_Search) ) > return result_type( End, End ); > > > 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 ) > { > > M=last_finder( Begin, ::boost::begin(M) ); > > if ( !M ) > { > > return M; > } > } > > return M; > } > > > private: > iterator_range<search_iterator_type> m_Search; > int m_Nth; > PredicateT m_Comp; > }; > > > > template<typename ForwardIteratorT> > iterator_range<ForwardIteratorT> > find_head_impl( > ForwardIteratorT Begin, > ForwardIteratorT End, > unsigned int N, > std::forward_iterator_tag ) > { > typedef ForwardIteratorT input_iterator_type; > typedef iterator_range<ForwardIteratorT> result_type; > > input_iterator_type It=Begin; > for( > unsigned int Index=0; > Index<N && It!=End; ++Index,++It ) {}; > > return result_type( Begin, It ); > } > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > find_head_impl( > ForwardIteratorT Begin, > ForwardIteratorT End, > unsigned int N, > std::random_access_iterator_tag ) > { > typedef iterator_range<ForwardIteratorT> result_type; > > if ( (End<=Begin) || ( static_cast<unsigned int>(End-Begin) < N ) ) > return result_type( Begin, End ); > > return result_type(Begin,Begin+N); > } > > > template<typename ForwardIteratorT> > iterator_range<ForwardIteratorT> > find_head_impl( > ForwardIteratorT Begin, > ForwardIteratorT End, > unsigned int N ) > { > typedef typename boost::detail:: > iterator_traits<ForwardIteratorT>::iterator_category category; > > return ::boost::algorithm::detail::find_head_impl( Begin, End, N, category() ); > } > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > find_tail_impl( > ForwardIteratorT Begin, > ForwardIteratorT End, > unsigned int N, > std::forward_iterator_tag ) > { > typedef ForwardIteratorT input_iterator_type; > typedef iterator_range<ForwardIteratorT> result_type; > > unsigned int Index=0; > input_iterator_type It=Begin; > input_iterator_type It2=Begin; > > > for( Index=0; Index<N && It2!=End; ++Index,++It2 ) {}; > > > for(; It2!=End; ++It,++It2 ) {}; > > return result_type( It, It2 ); > } > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > find_tail_impl( > ForwardIteratorT Begin, > ForwardIteratorT End, > unsigned int N, > std::bidirectional_iterator_tag ) > { > typedef ForwardIteratorT input_iterator_type; > typedef iterator_range<ForwardIteratorT> result_type; > > input_iterator_type It=End; > for( > unsigned int Index=0; > Index<N && It!=Begin; ++Index,--It ) {}; > > return result_type( It, End ); > } > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > find_tail_impl( > ForwardIteratorT Begin, > ForwardIteratorT End, > unsigned int N, > std::random_access_iterator_tag ) > { > typedef iterator_range<ForwardIteratorT> result_type; > > if ( (End<=Begin) || ( static_cast<unsigned int>(End-Begin) < N ) ) > return result_type( Begin, End ); > > return result_type( End-N, End ); > } > > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > find_tail_impl( > ForwardIteratorT Begin, > ForwardIteratorT End, > unsigned int N ) > { > typedef typename boost::detail:: > iterator_traits<ForwardIteratorT>::iterator_category category; > > return ::boost::algorithm::detail::find_tail_impl( Begin, End, N, category() ); > } ># 468 "/usr/include/boost/algorithm/string/detail/finder.hpp" 3 4 > struct head_finderF > { > > head_finderF( int N ) : m_N(N) {} > > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > operator()( > ForwardIteratorT Begin, > ForwardIteratorT End ) const > { > if(m_N>=0) > { > return ::boost::algorithm::detail::find_head_impl( Begin, End, m_N ); > } > else > { > iterator_range<ForwardIteratorT> Res= > ::boost::algorithm::detail::find_tail_impl( Begin, End, -m_N ); > > return ::boost::make_iterator_range(Begin, Res.begin()); > } > } > > private: > int m_N; > }; ># 506 "/usr/include/boost/algorithm/string/detail/finder.hpp" 3 4 > struct tail_finderF > { > > tail_finderF( int N ) : m_N(N) {} > > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > operator()( > ForwardIteratorT Begin, > ForwardIteratorT End ) const > { > if(m_N>=0) > { > return ::boost::algorithm::detail::find_tail_impl( Begin, End, m_N ); > } > else > { > iterator_range<ForwardIteratorT> Res= > ::boost::algorithm::detail::find_head_impl( Begin, End, -m_N ); > > return ::boost::make_iterator_range(Res.end(), End); > } > } > > private: > int m_N; > }; ># 547 "/usr/include/boost/algorithm/string/detail/finder.hpp" 3 4 > template< typename PredicateT > > struct token_finderF > { > > token_finderF( > PredicateT Pred, > token_compress_mode_type eCompress=token_compress_off ) : > m_Pred(Pred), m_eCompress(eCompress) {} > > > template< typename ForwardIteratorT > > iterator_range<ForwardIteratorT> > operator()( > ForwardIteratorT Begin, > ForwardIteratorT End ) const > { > typedef iterator_range<ForwardIteratorT> 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 ) > { > > while( It2!=End && m_Pred(*It2) ) ++It2; > } > else > { > > ++It2; > } > > return result_type( It, It2 ); > } > } > > private: > PredicateT m_Pred; > token_compress_mode_type m_eCompress; > }; ># 602 "/usr/include/boost/algorithm/string/detail/finder.hpp" 3 4 > template<typename ForwardIterator1T> > struct range_finderF > { > typedef ForwardIterator1T input_iterator_type; > typedef iterator_range<input_iterator_type> result_type; > > > range_finderF( > input_iterator_type Begin, > input_iterator_type End ) : m_Range(Begin, End) {} > > range_finderF(const iterator_range<input_iterator_type>& Range) : > m_Range(Range) {} > > > template< typename ForwardIterator2T > > iterator_range<ForwardIterator2T> > operator()( > ForwardIterator2T, > ForwardIterator2T ) const > { > > > > > > return m_Range; > > } > > private: > iterator_range<input_iterator_type> m_Range; > }; > > > } > } >} ># 24 "/usr/include/boost/algorithm/string/finder.hpp" 2 3 4 ># 34 "/usr/include/boost/algorithm/string/finder.hpp" 3 4 >namespace boost { > namespace algorithm { ># 49 "/usr/include/boost/algorithm/string/finder.hpp" 3 4 > template<typename RangeT> > inline detail::first_finderF< > typename range_const_iterator<RangeT>::type, > is_equal> > first_finder( const RangeT& Search ) > { > return > detail::first_finderF< > typename > range_const_iterator<RangeT>::type, > is_equal>( ::boost::as_literal(Search), is_equal() ) ; > } > > > > > > template<typename RangeT,typename PredicateT> > inline detail::first_finderF< > typename range_const_iterator<RangeT>::type, > PredicateT> > first_finder( > const RangeT& Search, PredicateT Comp ) > { > return > detail::first_finderF< > typename > range_const_iterator<RangeT>::type, > PredicateT>( ::boost::as_literal(Search), Comp ); > } ># 90 "/usr/include/boost/algorithm/string/finder.hpp" 3 4 > template<typename RangeT> > inline detail::last_finderF< > typename range_const_iterator<RangeT>::type, > is_equal> > last_finder( const RangeT& Search ) > { > return > detail::last_finderF< > typename > range_const_iterator<RangeT>::type, > is_equal>( ::boost::as_literal(Search), is_equal() ); > } > > > > > template<typename RangeT, typename PredicateT> > inline detail::last_finderF< > typename range_const_iterator<RangeT>::type, > PredicateT> > last_finder( const RangeT& Search, PredicateT Comp ) > { > return > detail::last_finderF< > typename > range_const_iterator<RangeT>::type, > PredicateT>( ::boost::as_literal(Search), Comp ) ; > } ># 130 "/usr/include/boost/algorithm/string/finder.hpp" 3 4 > template<typename RangeT> > inline detail::nth_finderF< > typename range_const_iterator<RangeT>::type, > is_equal> > nth_finder( > const RangeT& Search, > int Nth) > { > return > detail::nth_finderF< > typename > range_const_iterator<RangeT>::type, > is_equal>( ::boost::as_literal(Search), Nth, is_equal() ) ; > } > > > > > template<typename RangeT, typename PredicateT> > inline detail::nth_finderF< > typename range_const_iterator<RangeT>::type, > PredicateT> > nth_finder( > const RangeT& Search, > int Nth, > PredicateT Comp ) > { > return > detail::nth_finderF< > typename > range_const_iterator<RangeT>::type, > PredicateT>( ::boost::as_literal(Search), Nth, Comp ); > } ># 175 "/usr/include/boost/algorithm/string/finder.hpp" 3 4 > inline detail::head_finderF > head_finder( int N ) > { > return detail::head_finderF(N); > } ># 192 "/usr/include/boost/algorithm/string/finder.hpp" 3 4 > inline detail::tail_finderF > tail_finder( int N ) > { > return detail::tail_finderF(N); > } ># 216 "/usr/include/boost/algorithm/string/finder.hpp" 3 4 > template< typename PredicateT > > inline detail::token_finderF<PredicateT> > token_finder( > PredicateT Pred, > token_compress_mode_type eCompress=token_compress_off ) > { > return detail::token_finderF<PredicateT>( Pred, eCompress ); > } ># 236 "/usr/include/boost/algorithm/string/finder.hpp" 3 4 > template< typename ForwardIteratorT > > inline detail::range_finderF<ForwardIteratorT> > range_finder( > ForwardIteratorT Begin, > ForwardIteratorT End ) > { > return detail::range_finderF<ForwardIteratorT>( Begin, End ); > } > > > > > > template< typename ForwardIteratorT > > inline detail::range_finderF<ForwardIteratorT> > range_finder( iterator_range<ForwardIteratorT> Range ) > { > return detail::range_finderF<ForwardIteratorT>( Range ); > } > > } > > > 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; > >} ># 23 "/usr/include/boost/algorithm/string/find.hpp" 2 3 4 ># 32 "/usr/include/boost/algorithm/string/find.hpp" 3 4 >namespace boost { > namespace algorithm { ># 49 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename RangeT, typename FinderT> > inline iterator_range< > typename range_iterator<RangeT>::type> > find( > RangeT& Input, > const FinderT& Finder) > { > iterator_range<typename range_iterator<RangeT>::type> lit_input(::boost::as_literal(Input)); > > return Finder(::boost::begin(lit_input),::boost::end(lit_input)); > } ># 77 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename Range1T, typename Range2T> > inline iterator_range< > typename range_iterator<Range1T>::type> > find_first( > Range1T& Input, > const Range2T& Search) > { > return ::boost::algorithm::find(Input, ::boost::algorithm::first_finder(Search)); > } ># 103 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename Range1T, typename Range2T> > inline iterator_range< > typename range_iterator<Range1T>::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))); > } ># 130 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename Range1T, typename Range2T> > inline iterator_range< > typename range_iterator<Range1T>::type> > find_last( > Range1T& Input, > const Range2T& Search) > { > return ::boost::algorithm::find(Input, ::boost::algorithm::last_finder(Search)); > } ># 156 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename Range1T, typename Range2T> > inline iterator_range< > typename range_iterator<Range1T>::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))); > } ># 184 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename Range1T, typename Range2T> > inline iterator_range< > typename range_iterator<Range1T>::type> > find_nth( > Range1T& Input, > const Range2T& Search, > int Nth) > { > return ::boost::algorithm::find(Input, ::boost::algorithm::nth_finder(Search,Nth)); > } ># 214 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename Range1T, typename Range2T> > inline iterator_range< > typename range_iterator<Range1T>::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))); > } ># 246 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename RangeT> > inline iterator_range< > typename range_iterator<RangeT>::type> > find_head( > RangeT& Input, > int N) > { > return ::boost::algorithm::find(Input, ::boost::algorithm::head_finder(N)); > } ># 277 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename RangeT> > inline iterator_range< > typename range_iterator<RangeT>::type> > find_tail( > RangeT& Input, > int N) > { > return ::boost::algorithm::find(Input, ::boost::algorithm::tail_finder(N)); > } ># 306 "/usr/include/boost/algorithm/string/find.hpp" 3 4 > template<typename RangeT, typename PredicateT> > inline iterator_range< > typename range_iterator<RangeT>::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)); > } > > } > > > 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; > >} ># 24 "/usr/include/boost/algorithm/string/predicate.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/predicate.hpp" 1 3 4 ># 17 "/usr/include/boost/algorithm/string/detail/predicate.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { > > > > 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 ) > { > > return true; > } > > iterator_range<ForwardIterator1T> Result > =last_finder( > ::boost::make_iterator_range(SubBegin, SubEnd), > Comp)(Begin, End); > > return !Result.empty() && Result.end()==End; > } > > } > } >} ># 25 "/usr/include/boost/algorithm/string/predicate.hpp" 2 3 4 ># 37 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 >namespace boost { > namespace algorithm { ># 56 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T, typename PredicateT> > inline bool starts_with( > const Range1T& Input, > const Range2T& Test, > PredicateT Comp) > { > iterator_range<typename range_const_iterator<Range1T>::type> lit_input(::boost::as_literal(Input)); > iterator_range<typename range_const_iterator<Range2T>::type> lit_test(::boost::as_literal(Test)); > > typedef typename > range_const_iterator<Range1T>::type Iterator1T; > typedef typename > range_const_iterator<Range2T>::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; > } > > > > > > template<typename Range1T, typename Range2T> > inline bool starts_with( > const Range1T& Input, > const Range2T& Test) > { > return ::boost::algorithm::starts_with(Input, Test, is_equal()); > } ># 111 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T> > 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)); > } ># 138 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T, typename PredicateT> > inline bool ends_with( > const Range1T& Input, > const Range2T& Test, > PredicateT Comp) > { > iterator_range<typename range_const_iterator<Range1T>::type> lit_input(::boost::as_literal(Input)); > iterator_range<typename range_const_iterator<Range2T>::type> lit_test(::boost::as_literal(Test)); > > typedef typename > range_const_iterator<Range1T>::type Iterator1T; > typedef typename boost::detail:: > iterator_traits<Iterator1T>::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()); > } > > > > > > > template<typename Range1T, typename Range2T> > inline bool ends_with( > const Range1T& Input, > const Range2T& Test) > { > return ::boost::algorithm::ends_with(Input, Test, is_equal()); > } ># 188 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T> > 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)); > } ># 212 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T, typename PredicateT> > inline bool contains( > const Range1T& Input, > const Range2T& Test, > PredicateT Comp) > { > iterator_range<typename range_const_iterator<Range1T>::type> lit_input(::boost::as_literal(Input)); > iterator_range<typename range_const_iterator<Range2T>::type> lit_test(::boost::as_literal(Test)); > > if (::boost::empty(lit_test)) > { > > return true; > } > > > bool bResult=(::boost::algorithm::first_finder(lit_test,Comp)(::boost::begin(lit_input), ::boost::end(lit_input))); > return bResult; > } > > > > > > template<typename Range1T, typename Range2T> > inline bool contains( > const Range1T& Input, > const Range2T& Test) > { > return ::boost::algorithm::contains(Input, Test, is_equal()); > } ># 256 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T> > inline bool icontains( > const Range1T& Input, > const Range2T& Test, > const std::locale& Loc=std::locale()) > { > return ::boost::algorithm::contains(Input, Test, is_iequal(Loc)); > } ># 283 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T, typename PredicateT> > inline bool equals( > const Range1T& Input, > const Range2T& Test, > PredicateT Comp) > { > iterator_range<typename range_const_iterator<Range1T>::type> lit_input(::boost::as_literal(Input)); > iterator_range<typename range_const_iterator<Range2T>::type> lit_test(::boost::as_literal(Test)); > > typedef typename > range_const_iterator<Range1T>::type Iterator1T; > typedef typename > range_const_iterator<Range2T>::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); > } > > > > > > template<typename Range1T, typename Range2T> > inline bool equals( > const Range1T& Input, > const Range2T& Test) > { > return ::boost::algorithm::equals(Input, Test, is_equal()); > } ># 340 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T> > inline bool iequals( > const Range1T& Input, > const Range2T& Test, > const std::locale& Loc=std::locale()) > { > return ::boost::algorithm::equals(Input, Test, is_iequal(Loc)); > } ># 369 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T, typename PredicateT> > inline bool lexicographical_compare( > const Range1T& Arg1, > const Range2T& Arg2, > PredicateT Pred) > { > iterator_range<typename range_const_iterator<Range1T>::type> lit_arg1(::boost::as_literal(Arg1)); > iterator_range<typename range_const_iterator<Range2T>::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); > } > > > > > > template<typename Range1T, typename Range2T> > inline bool lexicographical_compare( > const Range1T& Arg1, > const Range2T& Arg2) > { > return ::boost::algorithm::lexicographical_compare(Arg1, Arg2, is_less()); > } ># 414 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename Range1T, typename Range2T> > 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)); > } ># 437 "/usr/include/boost/algorithm/string/predicate.hpp" 3 4 > template<typename RangeT, typename PredicateT> > inline bool all( > const RangeT& Input, > PredicateT Pred) > { > iterator_range<typename range_const_iterator<RangeT>::type> lit_input(::boost::as_literal(Input)); > > typedef typename > range_const_iterator<RangeT>::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; > } > > } > > > 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; > >} ># 22 "/usr/include/boost/algorithm/string.hpp" 2 3 4 > ># 1 "/usr/include/boost/algorithm/string/split.hpp" 1 3 4 ># 16 "/usr/include/boost/algorithm/string/split.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/iter_find.hpp" 1 3 4 ># 26 "/usr/include/boost/algorithm/string/iter_find.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/concept.hpp" 1 3 4 ># 23 "/usr/include/boost/algorithm/string/concept.hpp" 3 4 >namespace boost { > namespace algorithm { ># 34 "/usr/include/boost/algorithm/string/concept.hpp" 3 4 > template<typename FinderT, typename IteratorT> > struct FinderConcept > { > private: > typedef iterator_range<IteratorT> range; > public: > void constraints() > { > > r=(*pF)(i,i); > } > private: > range r; > IteratorT i; > FinderT* pF; > }; ># 61 "/usr/include/boost/algorithm/string/concept.hpp" 3 4 > template<typename FormatterT, typename FinderT, typename IteratorT> > struct FormatterConcept > { > public: > void constraints() > { > > ::boost::begin((*pFo)( (*pF)(i,i) )); > ::boost::end((*pFo)( (*pF)(i,i) )); > } > private: > IteratorT i; > FinderT* pF; > FormatterT *pFo; > }; > > } >} ># 27 "/usr/include/boost/algorithm/string/iter_find.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/find_iterator.hpp" 1 3 4 ># 24 "/usr/include/boost/algorithm/string/find_iterator.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/find_iterator.hpp" 1 3 4 ># 18 "/usr/include/boost/algorithm/string/detail/find_iterator.hpp" 3 4 ># 1 "/usr/include/boost/function.hpp" 1 3 4 ># 64 "/usr/include/boost/function.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 25 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 27 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 58 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 63 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 68 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 73 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 78 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 83 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 88 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 93 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 98 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 65 "/usr/include/boost/function.hpp" 2 3 4 ># 19 "/usr/include/boost/algorithm/string/detail/find_iterator.hpp" 2 3 4 > >namespace boost { > namespace algorithm { > namespace detail { > > > > > template<typename IteratorT> > class find_iterator_base > { > protected: > > typedef IteratorT input_iterator_type; > typedef iterator_range<IteratorT> match_type; > typedef function2< > match_type, > input_iterator_type, > input_iterator_type> finder_type; > > protected: > > > > find_iterator_base() {}; > > find_iterator_base( const find_iterator_base& Other ) : > m_Finder(Other.m_Finder) {} > > > template<typename FinderT> > find_iterator_base( FinderT Finder, int ) : > m_Finder(Finder) {} > > > ~find_iterator_base() {} > > > 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); > } > } > > > bool is_null() const > { > return m_Finder.empty(); > } > > private: > > finder_type m_Finder; > }; > > } > } >} ># 25 "/usr/include/boost/algorithm/string/find_iterator.hpp" 2 3 4 ># 33 "/usr/include/boost/algorithm/string/find_iterator.hpp" 3 4 >namespace boost { > namespace algorithm { ># 49 "/usr/include/boost/algorithm/string/find_iterator.hpp" 3 4 > template<typename IteratorT> > class find_iterator : > public iterator_facade< > find_iterator<IteratorT>, > const iterator_range<IteratorT>, > forward_traversal_tag >, > private detail::find_iterator_base<IteratorT> > { > private: > > friend class ::boost::iterator_core_access; > > private: > > > typedef detail::find_iterator_base<IteratorT> base_type; > typedef typename > base_type::input_iterator_type input_iterator_type; > typedef typename > base_type::match_type match_type; > > public: > > > > > > > find_iterator() {} > > > > > > find_iterator( const find_iterator& Other ) : > base_type(Other), > m_Match(Other.m_Match), > m_End(Other.m_End) {} > > > > > > > template<typename FinderT> > find_iterator( > IteratorT Begin, > IteratorT End, > FinderT Finder ) : > detail::find_iterator_base<IteratorT>(Finder,0), > m_Match(Begin,Begin), > m_End(End) > { > increment(); > } > > > > > > > template<typename FinderT, typename RangeT> > find_iterator( > RangeT& Col, > FinderT Finder ) : > detail::find_iterator_base<IteratorT>(Finder,0) > { > iterator_range<typename range_iterator<RangeT>::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: > > > > const match_type& dereference() const > { > return m_Match; > } > > > void increment() > { > m_Match=this->do_find(m_Match.end(),m_End); > } > > > 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: ># 160 "/usr/include/boost/algorithm/string/find_iterator.hpp" 3 4 > bool eof() const > { > return > this->is_null() || > ( > m_Match.begin() == m_End && > m_Match.end() == m_End > ); > } > > private: > > match_type m_Match; > input_iterator_type m_End; > }; > > > > > > template<typename RangeT, typename FinderT> > inline find_iterator< > typename range_iterator<RangeT>::type> > make_find_iterator( > RangeT& Collection, > FinderT Finder) > { > return find_iterator<typename range_iterator<RangeT>::type>( > Collection, Finder); > } ># 205 "/usr/include/boost/algorithm/string/find_iterator.hpp" 3 4 > template<typename IteratorT> > class split_iterator : > public iterator_facade< > split_iterator<IteratorT>, > const iterator_range<IteratorT>, > forward_traversal_tag >, > private detail::find_iterator_base<IteratorT> > { > private: > > friend class ::boost::iterator_core_access; > > private: > > > typedef detail::find_iterator_base<IteratorT> base_type; > typedef typename > base_type::input_iterator_type input_iterator_type; > typedef typename > base_type::match_type match_type; > > public: > > > > > > > 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) > {} > > > > > > > template<typename FinderT> > split_iterator( > IteratorT Begin, > IteratorT End, > FinderT Finder ) : > detail::find_iterator_base<IteratorT>(Finder,0), > m_Match(Begin,Begin), > m_Next(Begin), > m_End(End), > m_bEof(false) > { > > if(Begin!=End) > { > increment(); > } > } > > > > > > template<typename FinderT, typename RangeT> > split_iterator( > RangeT& Col, > FinderT Finder ) : > detail::find_iterator_base<IteratorT>(Finder,0), > m_bEof(false) > { > iterator_range<typename range_iterator<RangeT>::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); > > > if(m_Next!=m_End) > { > increment(); > } > } > > > private: > > > > const match_type& dereference() const > { > return m_Match; > } > > > 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) > { > > m_bEof=true; > } > } > > m_Match=match_type( m_Next, FindMatch.begin() ); > m_Next=FindMatch.end(); > } > > > 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: ># 343 "/usr/include/boost/algorithm/string/find_iterator.hpp" 3 4 > bool eof() const > { > return this->is_null() || m_bEof; > } > > private: > > match_type m_Match; > input_iterator_type m_Next; > input_iterator_type m_End; > bool m_bEof; > }; > > > > > > template<typename RangeT, typename FinderT> > inline split_iterator< > typename range_iterator<RangeT>::type> > make_split_iterator( > RangeT& Collection, > FinderT Finder) > { > return split_iterator<typename range_iterator<RangeT>::type>( > Collection, Finder); > } > > > } > > > using algorithm::find_iterator; > using algorithm::make_find_iterator; > using algorithm::split_iterator; > using algorithm::make_split_iterator; > >} ># 28 "/usr/include/boost/algorithm/string/iter_find.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/util.hpp" 1 3 4 ># 18 "/usr/include/boost/algorithm/string/detail/util.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { ># 31 "/usr/include/boost/algorithm/string/detail/util.hpp" 3 4 > template< typename CharT > > struct empty_container > { > typedef empty_container<CharT> 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; > > > > const_iterator begin() const > { > return reinterpret_cast<const_iterator>(0); > } > > const_iterator end() const > { > return reinterpret_cast<const_iterator>(0); > } > > bool empty() const > { > return false; > } > > size_type size() const > { > return 0; > } > }; > > > > > template<typename InputIteratorT, typename OutputIteratorT> > 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; > } > > > > > template< > typename SeqT, > typename IteratorT=typename SeqT::const_iterator > > struct copy_iterator_rangeF : > public std::unary_function< iterator_range<IteratorT>, SeqT > > { > SeqT operator()( const iterator_range<IteratorT>& Range ) const > { > return copy_range<SeqT>(Range); > } > }; > > } > } >} ># 29 "/usr/include/boost/algorithm/string/iter_find.hpp" 2 3 4 ># 41 "/usr/include/boost/algorithm/string/iter_find.hpp" 3 4 >namespace boost { > namespace algorithm { ># 67 "/usr/include/boost/algorithm/string/iter_find.hpp" 3 4 > template< > typename SequenceSequenceT, > typename RangeT, > typename FinderT > > inline SequenceSequenceT& > iter_find( > SequenceSequenceT& Result, > RangeT& Input, > FinderT Finder ) > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FinderConcept< FinderT, typename range_iterator<RangeT>::type> )>::failed> boost_concept_check81 > > > > ; > > iterator_range<typename range_iterator<RangeT>::type> lit_input(::boost::as_literal(Input)); > > typedef typename > range_iterator<RangeT>::type input_iterator_type; > typedef find_iterator<input_iterator_type> find_iterator_type; > typedef detail::copy_iterator_rangeF< > typename > range_value<SequenceSequenceT>::type, > input_iterator_type> copy_range_type; > > input_iterator_type InputEnd=::boost::end(lit_input); > > typedef transform_iterator<copy_range_type, find_iterator_type> > 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; > } ># 138 "/usr/include/boost/algorithm/string/iter_find.hpp" 3 4 > template< > typename SequenceSequenceT, > typename RangeT, > typename FinderT > > inline SequenceSequenceT& > iter_split( > SequenceSequenceT& Result, > RangeT& Input, > FinderT Finder ) > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FinderConcept<FinderT, typename range_iterator<RangeT>::type> )>::failed> boost_concept_check151 > > > ; > > iterator_range<typename range_iterator<RangeT>::type> lit_input(::boost::as_literal(Input)); > > typedef typename > range_iterator<RangeT>::type input_iterator_type; > typedef split_iterator<input_iterator_type> find_iterator_type; > typedef detail::copy_iterator_rangeF< > typename > range_value<SequenceSequenceT>::type, > input_iterator_type> copy_range_type; > > input_iterator_type InputEnd=::boost::end(lit_input); > > typedef transform_iterator<copy_range_type, find_iterator_type> > 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; > } > > } > > > using algorithm::iter_find; > using algorithm::iter_split; > >} ># 17 "/usr/include/boost/algorithm/string/split.hpp" 2 3 4 ># 34 "/usr/include/boost/algorithm/string/split.hpp" 3 4 >namespace boost { > namespace algorithm { ># 61 "/usr/include/boost/algorithm/string/split.hpp" 3 4 > 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) ); > } ># 96 "/usr/include/boost/algorithm/string/split.hpp" 3 4 > 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) ) ); > } ># 139 "/usr/include/boost/algorithm/string/split.hpp" 3 4 > 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 ) ); > } > > } > > > using algorithm::find_all; > using algorithm::ifind_all; > using algorithm::split; > >} ># 24 "/usr/include/boost/algorithm/string.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/join.hpp" 1 3 4 ># 15 "/usr/include/boost/algorithm/string/join.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/sequence.hpp" 1 3 4 ># 22 "/usr/include/boost/algorithm/string/detail/sequence.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { > > > > template< typename InputT, typename ForwardIteratorT > > inline void insert( > InputT& Input, > typename InputT::iterator At, > ForwardIteratorT Begin, > ForwardIteratorT End ) > { > Input.insert( At, Begin, End ); > } > > template< typename InputT, typename InsertT > > inline void insert( > InputT& Input, > typename InputT::iterator At, > const InsertT& Insert ) > { > ::boost::algorithm::detail::insert( Input, At, ::boost::begin(Insert), ::boost::end(Insert) ); > } > > > > > > > > template< typename InputT > > inline typename InputT::iterator erase( > InputT& Input, > typename InputT::iterator From, > typename InputT::iterator To ) > { > return Input.erase( From, To ); > } > > > > > > template< bool HasConstTimeOperations > > struct replace_const_time_helper > { > template< typename InputT, typename ForwardIteratorT > > void operator()( > InputT& Input, > typename InputT::iterator From, > typename InputT::iterator To, > ForwardIteratorT Begin, > ForwardIteratorT End ) > { > > ForwardIteratorT InsertIt=Begin; > typename InputT::iterator InputIt=From; > for(; InsertIt!=End && InputIt!=To; InsertIt++, InputIt++ ) > { > *InputIt=*InsertIt; > } > > if ( InsertIt!=End ) > { > > Input.insert( InputIt, InsertIt, End ); > } > else > { > if ( InputIt!=To ) > { > > Input.erase( InputIt, To ); > } > } > } > }; > > template<> > struct replace_const_time_helper< true > > { > > template< typename InputT, typename ForwardIteratorT > > void operator()( > InputT& Input, > typename InputT::iterator From, > typename InputT::iterator To, > ForwardIteratorT Begin, > ForwardIteratorT End ) > { > 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 ); > } > } > } > }; > > > template< bool HasNative > > struct replace_native_helper > { > template< typename InputT, typename ForwardIteratorT > > void operator()( > InputT& Input, > typename InputT::iterator From, > typename InputT::iterator To, > ForwardIteratorT Begin, > ForwardIteratorT End ) > { > replace_const_time_helper< > boost::mpl::and_< > has_const_time_insert<InputT>, > has_const_time_erase<InputT> >::value >()( > Input, From, To, Begin, End ); > } > }; > > > template<> > struct replace_native_helper< true > > { > template< typename InputT, typename ForwardIteratorT > > void operator()( > InputT& Input, > typename InputT::iterator From, > typename InputT::iterator To, > ForwardIteratorT Begin, > ForwardIteratorT End ) > { > Input.replace( From, To, Begin, End ); > } > }; > > > > template< typename InputT, typename ForwardIteratorT > > inline void replace( > InputT& Input, > typename InputT::iterator From, > typename InputT::iterator To, > ForwardIteratorT Begin, > ForwardIteratorT End ) > { > replace_native_helper< has_native_replace<InputT>::value >()( > Input, From, To, Begin, End ); > } > > template< typename InputT, typename InsertT > > inline void replace( > InputT& Input, > typename InputT::iterator From, > 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) ); > } > } > > } > } >} ># 16 "/usr/include/boost/algorithm/string/join.hpp" 2 3 4 ># 28 "/usr/include/boost/algorithm/string/join.hpp" 3 4 >namespace boost { > namespace algorithm { ># 44 "/usr/include/boost/algorithm/string/join.hpp" 3 4 > template< typename SequenceSequenceT, typename Range1T> > inline typename range_value<SequenceSequenceT>::type > join( > const SequenceSequenceT& Input, > const Range1T& Separator) > { > > typedef typename range_value<SequenceSequenceT>::type ResultT; > typedef typename range_const_iterator<SequenceSequenceT>::type InputIteratorT; > > > InputIteratorT itBegin=::boost::begin(Input); > InputIteratorT itEnd=::boost::end(Input); > > > ResultT Result; > > > if(itBegin!=itEnd) > { > detail::insert(Result, ::boost::end(Result), *itBegin); > ++itBegin; > } > > for(;itBegin!=itEnd; ++itBegin) > { > > detail::insert(Result, ::boost::end(Result), ::boost::as_literal(Separator)); > > detail::insert(Result, ::boost::end(Result), *itBegin); > } > > return Result; > } ># 94 "/usr/include/boost/algorithm/string/join.hpp" 3 4 > template< typename SequenceSequenceT, typename Range1T, typename PredicateT> > inline typename range_value<SequenceSequenceT>::type > join_if( > const SequenceSequenceT& Input, > const Range1T& Separator, > PredicateT Pred) > { > > typedef typename range_value<SequenceSequenceT>::type ResultT; > typedef typename range_const_iterator<SequenceSequenceT>::type InputIteratorT; > > > InputIteratorT itBegin=::boost::begin(Input); > InputIteratorT itEnd=::boost::end(Input); > > > ResultT Result; > > > while(itBegin!=itEnd && !Pred(*itBegin)) ++itBegin; > > if(itBegin!=itEnd) > { > detail::insert(Result, ::boost::end(Result), *itBegin); > ++itBegin; > } > > for(;itBegin!=itEnd; ++itBegin) > { > if(Pred(*itBegin)) > { > > detail::insert(Result, ::boost::end(Result), ::boost::as_literal(Separator)); > > detail::insert(Result, ::boost::end(Result), *itBegin); > } > } > > return Result; > } > > } > > > using algorithm::join; > using algorithm::join_if; > >} ># 25 "/usr/include/boost/algorithm/string.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/replace.hpp" 1 3 4 ># 22 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/find_format.hpp" 1 3 4 ># 23 "/usr/include/boost/algorithm/string/find_format.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/find_format.hpp" 1 3 4 ># 18 "/usr/include/boost/algorithm/string/detail/find_format.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/find_format_store.hpp" 1 3 4 ># 17 "/usr/include/boost/algorithm/string/detail/find_format_store.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { > > > > > > > > template< > typename ForwardIteratorT, > typename FormatterT, > typename FormatResultT > > class find_format_store : > public iterator_range<ForwardIteratorT> > { > public: > > typedef iterator_range<ForwardIteratorT> base_type; > typedef FormatterT formatter_type; > typedef FormatResultT format_result_type; > > public: > > 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) {} > > > template< typename FindResultT > > find_format_store& operator=( FindResultT FindResult ) > { > iterator_range<ForwardIteratorT>::operator=(FindResult); > if( !this->empty() ) { > m_FormatResult=m_Formatter(FindResult); > } > > return *this; > } > > > const format_result_type& format_result() > { > return m_FormatResult; > } > > private: > format_result_type m_FormatResult; > const formatter_type& m_Formatter; > }; > > template<typename InputT, typename FindResultT> > bool check_find_result(InputT&, FindResultT& FindResult) > { > typedef typename > range_const_iterator<InputT>::type input_iterator_type; > iterator_range<input_iterator_type> ResultRange(FindResult); > return !ResultRange.empty(); > } > > > > > } > } >} ># 19 "/usr/include/boost/algorithm/string/detail/find_format.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/replace_storage.hpp" 1 3 4 ># 20 "/usr/include/boost/algorithm/string/detail/replace_storage.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { > > > > 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) ); > } > > > > > template< bool HasStableIterators > > struct process_segment_helper > { > > template< > typename StorageT, > typename InputT, > typename ForwardIteratorT > > ForwardIteratorT operator()( > StorageT& Storage, > InputT& , > ForwardIteratorT InsertIt, > ForwardIteratorT SegmentBegin, > ForwardIteratorT SegmentEnd ) > { > > ForwardIteratorT It=::boost::algorithm::detail::move_from_storage( Storage, InsertIt, SegmentBegin ); > > > > > > > if( Storage.empty() ) > { > if( It==SegmentBegin ) > { > > return SegmentEnd; > } > else > { > > return std::copy( SegmentBegin, SegmentEnd, It ); > } > } > else > { > > while( It!=SegmentEnd ) > { > > Storage.push_back( *It ); > > *It=Storage.front(); > Storage.pop_front(); > > > ++It; > } > > return It; > } > } > }; > > template<> > struct process_segment_helper< true > > { > > template< > typename StorageT, > typename InputT, > typename ForwardIteratorT > > ForwardIteratorT operator()( > StorageT& Storage, > InputT& Input, > ForwardIteratorT InsertIt, > ForwardIteratorT SegmentBegin, > ForwardIteratorT SegmentEnd ) > > { > > ::boost::algorithm::detail::replace( Input, InsertIt, SegmentBegin, Storage ); > > Storage.clear(); > > return SegmentEnd; > } > }; > > > 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<InputT>::value>()( > Storage, Input, InsertIt, SegmentBegin, SegmentEnd ); > } > > > } > } >} ># 20 "/usr/include/boost/algorithm/string/detail/find_format.hpp" 2 3 4 > >namespace boost { > namespace algorithm { > namespace detail { > > > > 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< > typename > range_const_iterator<InputT>::type, > FormatterT, > FormatResultT > store_type; > > > store_type M( FindResult, FormatResult, Formatter ); > > if ( !M ) > { > > Output = std::copy( ::boost::begin(Input), ::boost::end(Input), Output ); > return Output; > } > > > Output = std::copy( ::boost::begin(Input), ::boost::begin(M), Output ); > > > Output = std::copy( ::boost::begin(M.format_result()), ::boost::end(M.format_result()), Output ); > > 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 ); > } > } > > > > > 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< > typename > range_const_iterator<InputT>::type, > FormatterT, > FormatResultT > store_type; > > > store_type M( FindResult, FormatResult, Formatter ); > > if ( !M ) > { > > return InputT( Input ); > } > > InputT Output; > > boost::algorithm::detail::insert( Output, ::boost::end(Output), ::boost::begin(Input), M.begin() ); > > boost::algorithm::detail::insert( Output, ::boost::end(Output), M.format_result() ); > > 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; > } > } > > > > 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< > typename > range_iterator<InputT>::type, > FormatterT, > FormatResultT > store_type; > > > store_type M( FindResult, FormatResult, Formatter ); > > if ( !M ) > { > > return; > } > > > ::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) ); > } > } > > } > } >} ># 24 "/usr/include/boost/algorithm/string/find_format.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/find_format_all.hpp" 1 3 4 ># 21 "/usr/include/boost/algorithm/string/detail/find_format_all.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { > > > > 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 typename > range_const_iterator<InputT>::type input_iterator_type; > > typedef find_format_store< > input_iterator_type, > FormatterT, > FormatResultT > store_type; > > > store_type M( FindResult, FormatResult, Formatter ); > > > input_iterator_type LastMatch=::boost::begin(Input); > > > while( M ) > { > > Output = std::copy( LastMatch, M.begin(), Output ); > > Output = std::copy( ::boost::begin(M.format_result()), ::boost::end(M.format_result()), Output ); > > > LastMatch=M.end(); > M=Finder( LastMatch, ::boost::end(Input) ); > } > > > 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 ); > } > } > > > > 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 typename > range_const_iterator<InputT>::type input_iterator_type; > > typedef find_format_store< > input_iterator_type, > FormatterT, > FormatResultT > store_type; > > > store_type M( FindResult, FormatResult, Formatter ); > > > input_iterator_type LastMatch=::boost::begin(Input); > > > InputT Output; > > > while( M ) > { > > boost::algorithm::detail::insert( Output, ::boost::end(Output), LastMatch, M.begin() ); > > boost::algorithm::detail::insert( Output, ::boost::end(Output), M.format_result() ); > > > LastMatch=M.end(); > M=Finder( LastMatch, ::boost::end(Input) ); > } > > > ::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; > } > } > > > > 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 typename > range_iterator<InputT>::type input_iterator_type; > typedef find_format_store< > input_iterator_type, > FormatterT, > FormatResultT > store_type; > > > store_type M( FindResult, FormatResult, Formatter ); > > > std::deque< > typename range_value<InputT>::type> Storage; > > > input_iterator_type InsertIt=::boost::begin(Input); > input_iterator_type SearchIt=::boost::begin(Input); > > while( M ) > { > > InsertIt=process_segment( > Storage, > Input, > InsertIt, > SearchIt, > M.begin() ); > > > SearchIt=M.end(); > > > ::boost::algorithm::detail::copy_to_storage( Storage, M.format_result() ); > > > M=Finder( SearchIt, ::boost::end(Input) ); > } > > > InsertIt=::boost::algorithm::detail::process_segment( > Storage, > Input, > InsertIt, > SearchIt, > ::boost::end(Input) ); > > if ( Storage.empty() ) > { > > ::boost::algorithm::detail::erase( Input, InsertIt, ::boost::end(Input) ); > } > else > { > > ::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) ); > } > } > > } > } >} ># 25 "/usr/include/boost/algorithm/string/find_format.hpp" 2 3 4 > > > > > > > >namespace boost { > namespace algorithm { ># 53 "/usr/include/boost/algorithm/string/find_format.hpp" 3 4 > template< > typename OutputIteratorT, > typename RangeT, > typename FinderT, > typename FormatterT> > inline OutputIteratorT find_format_copy( > OutputIteratorT Output, > const RangeT& Input, > FinderT Finder, > FormatterT Formatter ) > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FinderConcept< FinderT, typename range_const_iterator<RangeT>::type> )>::failed> boost_concept_check69 > > > > ; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FormatterConcept< FormatterT, FinderT,typename range_const_iterator<RangeT>::type> )>::failed> boost_concept_check74 > > > > ; > > iterator_range<typename range_const_iterator<RangeT>::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) ) ); > } > > > > > > template< > typename SequenceT, > typename FinderT, > typename FormatterT> > inline SequenceT find_format_copy( > const SequenceT& Input, > FinderT Finder, > FormatterT Formatter ) > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FinderConcept< FinderT, typename range_const_iterator<SequenceT>::type> )>::failed> boost_concept_check103 > > > > ; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FormatterConcept< FormatterT, FinderT,typename range_const_iterator<SequenceT>::type> )>::failed> boost_concept_check108 > > > > ; > > return detail::find_format_copy_impl( > Input, > Formatter, > Finder(::boost::begin(Input), ::boost::end(Input))); > } ># 125 "/usr/include/boost/algorithm/string/find_format.hpp" 3 4 > template< > typename SequenceT, > typename FinderT, > typename FormatterT> > inline void find_format( > SequenceT& Input, > FinderT Finder, > FormatterT Formatter) > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FinderConcept< FinderT, typename range_const_iterator<SequenceT>::type> )>::failed> boost_concept_check139 > > > > ; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FormatterConcept< FormatterT, FinderT,typename range_const_iterator<SequenceT>::type> )>::failed> boost_concept_check144 > > > > ; > > detail::find_format_impl( > Input, > Formatter, > Finder(::boost::begin(Input), ::boost::end(Input))); > } ># 172 "/usr/include/boost/algorithm/string/find_format.hpp" 3 4 > template< > typename OutputIteratorT, > typename RangeT, > typename FinderT, > typename FormatterT> > inline OutputIteratorT find_format_all_copy( > OutputIteratorT Output, > const RangeT& Input, > FinderT Finder, > FormatterT Formatter) > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FinderConcept< FinderT, typename range_const_iterator<RangeT>::type> )>::failed> boost_concept_check188 > > > > ; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FormatterConcept< FormatterT, FinderT,typename range_const_iterator<RangeT>::type> )>::failed> boost_concept_check193 > > > > ; > > iterator_range<typename range_const_iterator<RangeT>::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))); > } > > > > > > template< > typename SequenceT, > typename FinderT, > typename FormatterT > > inline SequenceT find_format_all_copy( > const SequenceT& Input, > FinderT Finder, > FormatterT Formatter ) > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FinderConcept< FinderT, typename range_const_iterator<SequenceT>::type> )>::failed> boost_concept_check223 > > > > ; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FormatterConcept< FormatterT, FinderT,typename range_const_iterator<SequenceT>::type> )>::failed> boost_concept_check228 > > > > ; > > return detail::find_format_all_copy_impl( > Input, > Finder, > Formatter, > Finder( ::boost::begin(Input), ::boost::end(Input) ) ); > } ># 247 "/usr/include/boost/algorithm/string/find_format.hpp" 3 4 > template< > typename SequenceT, > typename FinderT, > typename FormatterT > > inline void find_format_all( > SequenceT& Input, > FinderT Finder, > FormatterT Formatter ) > { > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FinderConcept< FinderT, typename range_const_iterator<SequenceT>::type> )>::failed> boost_concept_check261 > > > > ; > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)( FormatterConcept< FormatterT, FinderT,typename range_const_iterator<SequenceT>::type> )>::failed> boost_concept_check266 > > > > ; > > detail::find_format_all_impl( > Input, > Finder, > Formatter, > Finder(::boost::begin(Input), ::boost::end(Input))); > > } > > } > > > using algorithm::find_format_copy; > using algorithm::find_format; > using algorithm::find_format_all_copy; > using algorithm::find_format_all; > >} ># 23 "/usr/include/boost/algorithm/string/replace.hpp" 2 3 4 > ># 1 "/usr/include/boost/algorithm/string/formatter.hpp" 1 3 4 ># 19 "/usr/include/boost/algorithm/string/formatter.hpp" 3 4 ># 1 "/usr/include/boost/algorithm/string/detail/formatter.hpp" 1 3 4 ># 24 "/usr/include/boost/algorithm/string/detail/formatter.hpp" 3 4 >namespace boost { > namespace algorithm { > namespace detail { > > > > > template<typename RangeT> > struct const_formatF > { > private: > typedef typename > range_const_iterator<RangeT>::type format_iterator; > typedef iterator_range<format_iterator> result_type; > > public: > > const_formatF(const RangeT& Format) : > m_Format(::boost::begin(Format), ::boost::end(Format)) {} ># 53 "/usr/include/boost/algorithm/string/detail/formatter.hpp" 3 4 > template<typename Range2T> > const result_type& operator()(const Range2T&) const > { > return m_Format; > } > > private: > result_type m_Format; > }; > > > > > template<typename RangeT> > struct identity_formatF > { > > template< typename Range2T > > const RangeT& operator()(const Range2T& Replace) const > { > return RangeT(::boost::begin(Replace), ::boost::end(Replace)); > } > }; > > > > > template< typename CharT > > struct empty_formatF > { > template< typename ReplaceT > > empty_container<CharT> operator()(const ReplaceT&) const > { > return empty_container<CharT>(); > } > }; > > > > > template<typename FinderT> > struct dissect_formatF > { > public: > > dissect_formatF(FinderT Finder) : > m_Finder(Finder) {} > > > template<typename RangeT> > inline iterator_range< > typename range_const_iterator<RangeT>::type> > operator()(const RangeT& Replace) const > { > return m_Finder(::boost::begin(Replace), ::boost::end(Replace)); > } > > private: > FinderT m_Finder; > }; > > > } > } >} ># 20 "/usr/include/boost/algorithm/string/formatter.hpp" 2 3 4 ># 32 "/usr/include/boost/algorithm/string/formatter.hpp" 3 4 >namespace boost { > namespace algorithm { ># 45 "/usr/include/boost/algorithm/string/formatter.hpp" 3 4 > template<typename RangeT> > inline detail::const_formatF< > iterator_range< > typename range_const_iterator<RangeT>::type> > > const_formatter(const RangeT& Format) > { > return detail::const_formatF< > iterator_range< > typename range_const_iterator<RangeT>::type> >(::boost::as_literal(Format)); > } ># 63 "/usr/include/boost/algorithm/string/formatter.hpp" 3 4 > template<typename RangeT> > inline detail::identity_formatF< > iterator_range< > typename range_const_iterator<RangeT>::type> > > identity_formatter() > { > return detail::identity_formatF< > iterator_range< > typename range_const_iterator<RangeT>::type> >(); > } ># 83 "/usr/include/boost/algorithm/string/formatter.hpp" 3 4 > template<typename RangeT> > inline detail::empty_formatF< > typename range_value<RangeT>::type> > empty_formatter(const RangeT&) > { > return detail::empty_formatF< > typename range_value<RangeT>::type>(); > } ># 101 "/usr/include/boost/algorithm/string/formatter.hpp" 3 4 > template<typename FinderT> > inline detail::dissect_formatF< FinderT > > dissect_formatter(const FinderT& Finder) > { > return detail::dissect_formatF<FinderT>(Finder); > } > > > } > > > using algorithm::const_formatter; > using algorithm::identity_formatter; > using algorithm::empty_formatter; > using algorithm::dissect_formatter; > >} ># 25 "/usr/include/boost/algorithm/string/replace.hpp" 2 3 4 > > > > > > > >namespace boost { > namespace algorithm { ># 52 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template< > typename OutputIteratorT, > typename Range1T, > typename Range2T> > inline OutputIteratorT replace_range_copy( > OutputIteratorT Output, > const Range1T& Input, > const iterator_range< > typename > range_const_iterator<Range1T>::type>& SearchRange, > const Range2T& Format) > { > return ::boost::algorithm::find_format_copy( > Output, > Input, > ::boost::algorithm::range_finder(SearchRange), > ::boost::algorithm::const_formatter(Format)); > } > > > > > > template<typename SequenceT, typename RangeT> > inline SequenceT replace_range_copy( > const SequenceT& Input, > const iterator_range< > typename > range_const_iterator<SequenceT>::type>& SearchRange, > const RangeT& Format) > { > return ::boost::algorithm::find_format_copy( > Input, > ::boost::algorithm::range_finder(SearchRange), > ::boost::algorithm::const_formatter(Format)); > } ># 98 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename RangeT> > inline void replace_range( > SequenceT& Input, > const iterator_range< > typename > range_iterator<SequenceT>::type>& SearchRange, > const RangeT& Format) > { > ::boost::algorithm::find_format( > Input, > ::boost::algorithm::range_finder(SearchRange), > ::boost::algorithm::const_formatter(Format)); > } ># 130 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 173 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 205 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename Range2T, typename Range1T> > 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) ); > } ># 252 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 283 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 326 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 358 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 406 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 439 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 486 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 521 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 572 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 604 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 648 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 680 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 727 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename Range1T, typename Range2T> > 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) ); > } ># 762 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 808 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename RangeT> > 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) ); > } ># 842 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 888 "/usr/include/boost/algorithm/string/replace.hpp" 3 4 > template<typename SequenceT, typename RangeT> > 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) ); > } > > } > > > 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; > >} ># 26 "/usr/include/boost/algorithm/string.hpp" 2 3 4 ># 1 "/usr/include/boost/algorithm/string/erase.hpp" 1 3 4 ># 31 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 >namespace boost { > namespace algorithm { ># 49 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename OutputIteratorT, typename RangeT> > inline OutputIteratorT erase_range_copy( > OutputIteratorT Output, > const RangeT& Input, > const iterator_range< > typename > range_const_iterator<RangeT>::type>& SearchRange ) > { > return ::boost::algorithm::find_format_copy( > Output, > Input, > ::boost::algorithm::range_finder(SearchRange), > ::boost::algorithm::empty_formatter(Input) ); > } > > > > > > template<typename SequenceT> > inline SequenceT erase_range_copy( > const SequenceT& Input, > const iterator_range< > typename > range_const_iterator<SequenceT>::type>& SearchRange ) > { > return ::boost::algorithm::find_format_copy( > Input, > ::boost::algorithm::range_finder(SearchRange), > ::boost::algorithm::empty_formatter(Input) ); > } ># 89 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT> > inline void erase_range( > SequenceT& Input, > const iterator_range< > typename > range_iterator<SequenceT>::type>& SearchRange ) > { > ::boost::algorithm::find_format( > Input, > ::boost::algorithm::range_finder(SearchRange), > ::boost::algorithm::empty_formatter(Input) ); > } ># 118 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 157 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT, typename RangeT> > inline void erase_first( > SequenceT& Input, > const RangeT& Search ) > { > ::boost::algorithm::find_format( > Input, > ::boost::algorithm::first_finder(Search), > ::boost::algorithm::empty_formatter(Input) ); > } ># 186 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 228 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT, typename RangeT> > 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) ); > } ># 256 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 295 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT, typename RangeT> > inline void erase_last( > SequenceT& Input, > const RangeT& Search ) > { > ::boost::algorithm::find_format( > Input, > ::boost::algorithm::last_finder(Search), > ::boost::algorithm::empty_formatter(Input) ); > } ># 324 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 366 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT, typename RangeT> > 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) ); > } ># 397 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 440 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT, typename RangeT> > 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) ); > } ># 472 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 518 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT, typename RangeT> > 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) ); > } ># 549 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 588 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT, typename RangeT> > 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) ); > } ># 617 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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) ); > } > > > > > > template<typename SequenceT, typename RangeT> > 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) ); > } ># 659 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT, typename RangeT> > 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) ); > } ># 691 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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 ) ); > } > > > > > > template<typename SequenceT> > 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 ) ); > } ># 732 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT> > inline void erase_head( > SequenceT& Input, > int N ) > { > ::boost::algorithm::find_format( > Input, > ::boost::algorithm::head_finder(N), > ::boost::algorithm::empty_formatter( Input ) ); > } ># 763 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > 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 ) ); > } > > > > > > template<typename SequenceT> > 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 ) ); > } ># 804 "/usr/include/boost/algorithm/string/erase.hpp" 3 4 > template<typename SequenceT> > inline void erase_tail( > SequenceT& Input, > int N ) > { > ::boost::algorithm::find_format( > Input, > ::boost::algorithm::tail_finder(N), > ::boost::algorithm::empty_formatter( Input ) ); > } > > } > > > 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; > >} ># 27 "/usr/include/boost/algorithm/string.hpp" 2 3 4 ># 46 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 > > > > > > > ># 1 "/c/honeypenny/contrib/epee/include/static_initializer.h" 1 ># 33 "/c/honeypenny/contrib/epee/include/static_initializer.h" >namespace epee >{ > > > > > > > >template<class to_initialize> >class initializer >{ >public: > initializer() > { > to_initialize::init(); > > } > ~initializer() > { > to_initialize::un_init(); > > } ># 81 "/c/honeypenny/contrib/epee/include/static_initializer.h" >}; > >} ># 54 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/string_tools.h" 1 ># 34 "/c/honeypenny/contrib/epee/include/string_tools.h" ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 35 "/c/honeypenny/contrib/epee/include/string_tools.h" 2 > ># 1 "/usr/include/boost/uuid/uuid.hpp" 1 3 4 ># 36 "/usr/include/boost/uuid/uuid.hpp" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 37 "/usr/include/boost/uuid/uuid.hpp" 2 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 38 "/usr/include/boost/uuid/uuid.hpp" 2 3 4 ># 57 "/usr/include/boost/uuid/uuid.hpp" 3 4 >namespace boost { >namespace uuids { > >struct uuid >{ >public: > typedef uint8_t value_type; > typedef uint8_t& reference; > typedef uint8_t const& const_reference; > typedef uint8_t* iterator; > typedef uint8_t const* const_iterator; > typedef std::size_t size_type; > typedef std::ptrdiff_t difference_type; > > > > > > static size_type static_size() { return 16; } > >public: > iterator begin() { return data; } > const_iterator begin() const { return data; } > iterator end() { return data+size(); } > const_iterator end() const { return data+size(); } > > size_type size() const { return static_size(); } > > bool is_nil() const > { > for(size_t i=0; i<static_size(); i++) { > if (data[i] != 0U) { > return false; > } > } > return true; > } > > enum variant_type > { > variant_ncs, > variant_rfc_4122, > variant_microsoft, > variant_future > }; > variant_type variant() const > { > > > unsigned char octet7 = data[8]; > if ( (octet7 & 0x80) == 0x00 ) { > return variant_ncs; > } else if ( (octet7 & 0xC0) == 0x80 ) { > return variant_rfc_4122; > } else if ( (octet7 & 0xE0) == 0xC0 ) { > return variant_microsoft; > } else { > > return variant_future; > } > } > > enum version_type > { > version_unknown = -1, > version_time_based = 1, > version_dce_security = 2, > version_name_based_md5 = 3, > version_random_number_based = 4, > version_name_based_sha1 = 5 > }; > version_type version() const > { > > > unsigned char octet9 = data[6]; > if ( (octet9 & 0xF0) == 0x10 ) { > return version_time_based; > } else if ( (octet9 & 0xF0) == 0x20 ) { > return version_dce_security; > } else if ( (octet9 & 0xF0) == 0x30 ) { > return version_name_based_md5; > } else if ( (octet9 & 0xF0) == 0x40 ) { > return version_random_number_based; > } else if ( (octet9 & 0xF0) == 0x50 ) { > return version_name_based_sha1; > } else { > return version_unknown; > } > } > > > void swap(uuid& rhs) > { > std::swap_ranges(begin(), end(), rhs.begin()); > } > >public: > > uint8_t data[16]; >}; > >inline bool operator==(uuid const& lhs, uuid const& rhs) >{ > return std::equal(lhs.begin(), lhs.end(), rhs.begin()); >} > >inline bool operator!=(uuid const& lhs, uuid const& rhs) >{ > return !(lhs == rhs); >} > >inline bool operator<(uuid const& lhs, uuid const& rhs) >{ > return std::lexicographical_compare(lhs.begin(), lhs.end(), rhs.begin(), rhs.end()); >} > >inline bool operator>(uuid const& lhs, uuid const& rhs) >{ > return rhs < lhs; >} >inline bool operator<=(uuid const& lhs, uuid const& rhs) >{ > return !(rhs < lhs); >} > >inline bool operator>=(uuid const& lhs, uuid const& rhs) >{ > return !(lhs < rhs); >} > >inline void swap(uuid& lhs, uuid& rhs) >{ > lhs.swap(rhs); >} > > >inline std::size_t hash_value(uuid const& u) >{ > std::size_t seed = 0; > for(uuid::const_iterator i=u.begin(); i != u.end(); ++i) > { > seed ^= static_cast<std::size_t>(*i) + 0x9e3779b9 + (seed << 6) + (seed >> 2); > } > > return seed; >} > >}} > > > >namespace boost { > >template <> >struct is_pod<uuids::uuid> : true_type {}; > >} ># 37 "/c/honeypenny/contrib/epee/include/string_tools.h" 2 ># 1 "/usr/include/boost/uuid/uuid_io.hpp" 1 3 4 ># 28 "/usr/include/boost/uuid/uuid_io.hpp" 3 4 >namespace boost { >namespace uuids { > >template <typename ch, typename char_traits> > std::basic_ostream<ch, char_traits>& operator<<(std::basic_ostream<ch, char_traits> &os, uuid const& u) >{ > io::ios_flags_saver flags_saver(os); > io::basic_ios_fill_saver<ch, char_traits> fill_saver(os); > > const typename std::basic_ostream<ch, char_traits>::sentry ok(os); > if (ok) { > const std::streamsize width = os.width(0); > const std::streamsize uuid_width = 36; > const std::ios_base::fmtflags flags = os.flags(); > const typename std::basic_ios<ch, char_traits>::char_type fill = os.fill(); > if (flags & (std::ios_base::right | std::ios_base::internal)) { > for (std::streamsize i=uuid_width; i<width; i++) { > os << fill; > } > } > > os << std::hex; > os.fill(os.widen('0')); > > std::size_t i=0; > for (uuid::const_iterator i_data = u.begin(); i_data!=u.end(); ++i_data, ++i) { > os.width(2); > os << static_cast<unsigned int>(*i_data); > if (i == 3 || i == 5 || i == 7 || i == 9) { > os << os.widen('-'); > } > } > > if (flags & std::ios_base::left) { > for (std::streamsize i=uuid_width; i<width; i++) { > os << fill; > } > } > > os.width(0); > } > return os; >} > >template <typename ch, typename char_traits> > std::basic_istream<ch, char_traits>& operator>>(std::basic_istream<ch, char_traits> &is, uuid &u) >{ > const typename std::basic_istream<ch, char_traits>::sentry ok(is); > if (ok) { > unsigned char data[16]; > > typedef std::ctype<ch> ctype_t; > ctype_t const& ctype = std::use_facet<ctype_t>(is.getloc()); > > ch xdigits[16]; > { > char szdigits[] = "0123456789ABCDEF"; > ctype.widen(szdigits, szdigits+16, xdigits); > } > ch*const xdigits_end = xdigits+16; > > ch c; > for (std::size_t i=0; i<u.size() && is; ++i) { > is >> c; > c = ctype.toupper(c); > > ch* f = std::find(xdigits, xdigits_end, c); > if (f == xdigits_end) { > is.setstate(std::ios_base::failbit); > break; > } > > unsigned char byte = static_cast<unsigned char>(std::distance(&xdigits[0], f)); > > is >> c; > c = ctype.toupper(c); > f = std::find(xdigits, xdigits_end, c); > if (f == xdigits_end) { > is.setstate(std::ios_base::failbit); > break; > } > > byte <<= 4; > byte |= static_cast<unsigned char>(std::distance(&xdigits[0], f)); > > data[i] = byte; > > if (is) { > if (i == 3 || i == 5 || i == 7 || i == 9) { > is >> c; > if (c != is.widen('-')) is.setstate(std::ios_base::failbit); > } > } > } > > if (is) { > std::copy(data, data+16, u.begin()); > } > } > return is; >} > >namespace detail { >inline char to_char(size_t i) { > if (i <= 9) { > return static_cast<char>('0' + i); > } else { > return static_cast<char>('a' + (i-10)); > } >} > >inline wchar_t to_wchar(size_t i) { > if (i <= 9) { > return static_cast<wchar_t>(L'0' + i); > } else { > return static_cast<wchar_t>(L'a' + (i-10)); > } >} > >} > >inline std::string to_string(uuid const& u) >{ > std::string result; > result.reserve(36); > > std::size_t i=0; > for (uuid::const_iterator it_data = u.begin(); it_data!=u.end(); ++it_data, ++i) { > const size_t hi = ((*it_data) >> 4) & 0x0F; > result += detail::to_char(hi); > > const size_t lo = (*it_data) & 0x0F; > result += detail::to_char(lo); > > if (i == 3 || i == 5 || i == 7 || i == 9) { > result += '-'; > } > } > return result; >} > > >inline std::wstring to_wstring(uuid const& u) >{ > std::wstring result; > result.reserve(36); > > std::size_t i=0; > for (uuid::const_iterator it_data = u.begin(); it_data!=u.end(); ++it_data, ++i) { > const size_t hi = ((*it_data) >> 4) & 0x0F; > result += detail::to_wchar(hi); > > const size_t lo = (*it_data) & 0x0F; > result += detail::to_wchar(lo); > > if (i == 3 || i == 5 || i == 7 || i == 9) { > result += L'-'; > } > } > return result; >} > > > >}} ># 38 "/c/honeypenny/contrib/epee/include/string_tools.h" 2 ># 1 "/usr/include/boost/lexical_cast.hpp" 1 3 4 ># 29 "/usr/include/boost/lexical_cast.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 30 "/usr/include/boost/lexical_cast.hpp" 2 3 4 > > ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 33 "/usr/include/boost/lexical_cast.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cstdio" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdio" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdio" 3 ># 34 "/usr/include/boost/lexical_cast.hpp" 2 3 4 ># 42 "/usr/include/boost/lexical_cast.hpp" 3 4 ># 1 "/usr/include/boost/detail/lcast_precision.hpp" 1 3 4 ># 11 "/usr/include/boost/detail/lcast_precision.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 12 "/usr/include/boost/detail/lcast_precision.hpp" 2 3 4 ># 36 "/usr/include/boost/detail/lcast_precision.hpp" 3 4 >namespace boost { namespace detail { > >class lcast_abstract_stub {}; > > > > > >template<class T> >struct lcast_precision >{ > > > > typedef typename boost::mpl::if_< > boost::is_abstract<T> > , std::numeric_limits<lcast_abstract_stub> > , std::numeric_limits<T> > >::type limits; > > > static const bool use_default_precision = !limits::is_specialized || limits::is_exact > > ; > > static const bool is_specialized_bin = !use_default_precision && limits::radix == 2 && limits::digits > 0 > > > ; > > static const bool is_specialized_dec = !use_default_precision && limits::radix == 10 && limits::digits10 > 0 > > > ; > > static const std::streamsize streamsize_max = boost::integer_traits<std::streamsize>::const_max > > ; > > static const unsigned int precision_dec = limits::digits10 + 1U; > > static_assert(!is_specialized_dec || precision_dec <= streamsize_max + 0UL, "!is_specialized_dec || precision_dec <= streamsize_max + 0UL") > > ; > > static const unsigned long precision_bin = 2UL + limits::digits * 30103UL / 100000UL > > ; > > static_assert(!is_specialized_bin || (limits::digits + 0UL < (9223372036854775807L * 2UL + 1UL) / 30103UL && precision_bin > limits::digits10 + 0UL && precision_bin <= streamsize_max + 0UL), "!is_specialized_bin || (limits::digits + 0UL < ULONG_MAX / 30103UL && precision_bin > limits::digits10 + 0UL && precision_bin <= streamsize_max + 0UL)") > > > > ; > > static const std::streamsize value = is_specialized_bin ? precision_bin : is_specialized_dec ? precision_dec : 6 > > > ; >}; > > >template<class T> >inline std::streamsize lcast_get_precision(T* = 0) >{ > > return lcast_precision<T>::value; ># 165 "/usr/include/boost/detail/lcast_precision.hpp" 3 4 >} > >template<class T> >inline void lcast_set_precision(std::ios_base& stream, T*) >{ > stream.precision(lcast_get_precision<T>()); >} > >template<class Source, class Target> >inline void lcast_set_precision(std::ios_base& stream, Source*, Target*) >{ > std::streamsize const s = lcast_get_precision(static_cast<Source*>(0)); > std::streamsize const t = lcast_get_precision(static_cast<Target*>(0)); > stream.precision(s > t ? s : t); >} > >}} ># 43 "/usr/include/boost/lexical_cast.hpp" 2 3 4 ># 72 "/usr/include/boost/lexical_cast.hpp" 3 4 >namespace boost >{ > > class __attribute__((__visibility__("default"))) bad_lexical_cast : > > > > > public std::bad_cast > > > > > > > > { > public: > bad_lexical_cast() noexcept : > > source(&typeid(void)), target(&typeid(void)) > > > > { > } > > bad_lexical_cast( > const std::type_info &source_type_arg, > const std::type_info &target_type_arg) noexcept : > source(&source_type_arg), target(&target_type_arg) > { > } > > const std::type_info &source_type() const > { > return *source; > } > const std::type_info &target_type() const > { > return *target; > } > > > virtual const char *what() const noexcept > > > > { > return "bad lexical cast: " > "source type value could not be interpreted as target"; > } > > > virtual ~bad_lexical_cast() noexcept > > > > {} > private: > const std::type_info *source; > const std::type_info *target; > }; > > namespace detail > { > template <typename TargetChar, typename SourceChar> > struct widest_char > { > typedef typename boost::mpl::if_c< > (sizeof(TargetChar) > sizeof(SourceChar)) > , TargetChar > , SourceChar >::type type; > }; > } >} > > > ># 1 "/usr/include/c++/4.9.0/cmath" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cmath" 3 4 ># 40 "/usr/include/c++/4.9.0/cmath" 3 ># 152 "/usr/include/boost/lexical_cast.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/array.hpp" 1 3 4 ># 44 "/usr/include/boost/array.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 45 "/usr/include/boost/array.hpp" 2 3 4 ># 1 "/usr/include/boost/swap.hpp" 1 3 4 ># 46 "/usr/include/boost/array.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/functional/hash_fwd.hpp" 1 3 4 ># 51 "/usr/include/boost/array.hpp" 2 3 4 > > > > > > >namespace boost { > > template<class T, std::size_t N> > class array { > public: > T elems[N]; > > public: > > 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 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; } > > > > typedef std::reverse_iterator<iterator> reverse_iterator; > typedef std::reverse_iterator<const_iterator> const_reverse_iterator; ># 104 "/usr/include/boost/array.hpp" 3 4 > 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()); > } > > > reference operator[](size_type i) > { > ((void)0); > return elems[i]; > } > > const_reference operator[](size_type i) const > { > ((void)0); > return elems[i]; > } > > > reference at(size_type i) { rangecheck(i); return elems[i]; } > const_reference at(size_type i) const { rangecheck(i); return elems[i]; } > > > 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]; > } > > > static size_type size() { return N; } > static bool empty() { return false; } > static size_type max_size() { return N; } > enum { static_size = N }; > > > void swap (array<T,N>& y) { > for (size_type i = 0; i < N; ++i) > boost::swap(elems[i],y.elems[i]); > } > > > const T* data() const { return elems; } > T* data() { return elems; } > > > T* c_array() { return elems; } > > > template <typename T2> > array<T,N>& operator= (const array<T2,N>& rhs) { > std::copy(rhs.begin(),rhs.end(), begin()); > return *this; > } > > > void assign (const T& value) { fill ( value ); } > void fill (const T& value) > { > std::fill_n(begin(),size(),value); > } > > > static void rangecheck (size_type i) { > if (i >= size()) { > std::out_of_range e("array<>: index out of range"); > boost::throw_exception(e); > } > } > > }; > > > template< class T > > class array< T, 0 > { > > public: > > 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 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(); } > > > > typedef std::reverse_iterator<iterator> reverse_iterator; > typedef std::reverse_iterator<const_iterator> const_reverse_iterator; ># 245 "/usr/include/boost/array.hpp" 3 4 > 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()); > } > > > reference operator[](size_type ) > { > return failed_rangecheck(); > } > > const_reference operator[](size_type ) const > { > return failed_rangecheck(); > } > > > reference at(size_type ) { return failed_rangecheck(); } > const_reference at(size_type ) const { return failed_rangecheck(); } > > > reference front() > { > return failed_rangecheck(); > } > > const_reference front() const > { > return failed_rangecheck(); > } > > reference back() > { > return failed_rangecheck(); > } > > const_reference back() const > { > return failed_rangecheck(); > } > > > 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<T,0>& ) { > } > > > const T* data() const { return 0; } > T* data() { return 0; } > > > T* c_array() { return 0; } > > > template <typename T2> > array<T,0>& operator= (const array<T2,0>& ) { > return *this; > } > > > void assign (const T& value) { fill ( value ); } > void fill (const T& ) {} > > > static reference failed_rangecheck () { > std::out_of_range e("attempt to access element of an empty array"); > boost::throw_exception(e); > > > > > > > static T placeholder; > return placeholder; > > } > }; > > > > template<class T, std::size_t N> > bool operator== (const array<T,N>& x, const array<T,N>& y) { > return std::equal(x.begin(), x.end(), y.begin()); > } > template<class T, std::size_t N> > bool operator< (const array<T,N>& x, const array<T,N>& y) { > return std::lexicographical_compare(x.begin(),x.end(),y.begin(),y.end()); > } > template<class T, std::size_t N> > bool operator!= (const array<T,N>& x, const array<T,N>& y) { > return !(x==y); > } > template<class T, std::size_t N> > bool operator> (const array<T,N>& x, const array<T,N>& y) { > return y<x; > } > template<class T, std::size_t N> > bool operator<= (const array<T,N>& x, const array<T,N>& y) { > return !(y<x); > } > template<class T, std::size_t N> > bool operator>= (const array<T,N>& x, const array<T,N>& y) { > return !(x<y); > } > > > template<class T, std::size_t N> > inline void swap (array<T,N>& x, array<T,N>& y) { > x.swap(y); > } ># 400 "/usr/include/boost/array.hpp" 3 4 > template <typename T, std::size_t N> > T(&get_c_array(boost::array<T,N>& arg))[N] > { > return arg.elems; > } > > > template <typename T, std::size_t N> > const T(&get_c_array(const boost::array<T,N>& arg))[N] > { > return arg.elems; > } ># 433 "/usr/include/boost/array.hpp" 3 4 > template<class T, std::size_t N> > std::size_t hash_value(const array<T,N>& arr) > { > return boost::hash_range(arr.begin(), arr.end()); > } > >} ># 159 "/usr/include/boost/lexical_cast.hpp" 2 3 4 ># 1 "/usr/include/boost/numeric/conversion/cast.hpp" 1 3 4 ># 33 "/usr/include/boost/numeric/conversion/cast.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/converter.hpp" 1 3 4 ># 13 "/usr/include/boost/numeric/conversion/converter.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/conversion_traits.hpp" 1 3 4 ># 13 "/usr/include/boost/numeric/conversion/conversion_traits.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/detail/conversion_traits.hpp" 1 3 4 ># 17 "/usr/include/boost/numeric/conversion/detail/conversion_traits.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/detail/meta.hpp" 1 3 4 ># 17 "/usr/include/boost/numeric/conversion/detail/meta.hpp" 3 4 ># 1 "/usr/include/boost/mpl/equal_to.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/equal_to.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/numeric_cast.hpp" 1 3 4 ># 30 "/usr/include/boost/mpl/numeric_cast.hpp" 3 4 >namespace boost { namespace mpl { > > > >template< typename SourceTag, typename TargetTag > struct numeric_cast >{ > template< typename N > struct apply; >}; > >}} ># 22 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/tag.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/tag.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/has_tag.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/has_tag.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { >template< typename T, typename fallback_ = boost::mpl::bool_<false> > struct has_tag { struct gcc_3_2_wknd { template< typename U > static boost::mpl::aux::yes_tag test( boost::mpl::aux::type_wrapper<U> const volatile* , boost::mpl::aux::type_wrapper<typename U::tag>* = 0 ); static boost::mpl::aux::no_tag test(...); }; typedef boost::mpl::aux::type_wrapper<T> t_; static const bool value = sizeof(gcc_3_2_wknd::test(static_cast<t_*>(0))) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_<value> type; }; >}}} ># 20 "/usr/include/boost/mpl/tag.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >namespace aux { >template< typename T > struct tag_impl >{ > typedef typename T::tag type; >}; >} > >template< typename T, typename Default = void_ > struct tag > > : if_< > aux::has_tag<T> > , aux::tag_impl<T> > , Default > >::type >{ ># 48 "/usr/include/boost/mpl/tag.hpp" 3 4 >}; > >}} ># 25 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_cast_utils.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/numeric_cast_utils.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/numeric_cast_utils.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/forwarding.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/numeric_cast_utils.hpp" 2 3 4 > >namespace boost { namespace mpl { namespace aux { > >template< > typename F > , typename Tag1 > , typename Tag2 > > >struct cast1st_impl >{ > template< typename N1, typename N2 > struct apply > > : apply_wrap2< > F > , typename apply_wrap1< numeric_cast<Tag1,Tag2>,N1 >::type > , N2 > > > { ># 46 "/usr/include/boost/mpl/aux_/numeric_cast_utils.hpp" 3 4 > }; >}; > >template< > typename F > , typename Tag1 > , typename Tag2 > > >struct cast2nd_impl >{ > template< typename N1, typename N2 > struct apply > > : apply_wrap2< > F > , N1 > , typename apply_wrap1< numeric_cast<Tag2,Tag1>,N2 >::type > > > { ># 72 "/usr/include/boost/mpl/aux_/numeric_cast_utils.hpp" 3 4 > }; >}; > >}}} ># 26 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/aux_/msvc_eti_base.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/msvc_eti_base.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/is_msvc_eti_arg.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/aux_/is_msvc_eti_arg.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { ># 62 "/usr/include/boost/mpl/aux_/is_msvc_eti_arg.hpp" 3 4 >}}} ># 18 "/usr/include/boost/mpl/aux_/msvc_eti_base.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { namespace aux { ># 55 "/usr/include/boost/mpl/aux_/msvc_eti_base.hpp" 3 4 >template< typename T > struct msvc_eti_base > : T >{ > > msvc_eti_base(); > > typedef T type; >}; > > > >template<> struct msvc_eti_base<int> >{ > typedef msvc_eti_base type; > typedef msvc_eti_base first; > typedef msvc_eti_base second; > typedef msvc_eti_base tag; > enum { value = 0 }; >}; > >}}} ># 30 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/equal_to.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/equal_to.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Tag1 > , typename Tag2 > > >struct equal_to_impl > : if_c< > ( Tag1::value > > Tag2::value > ) > > , aux::cast2nd_impl< equal_to_impl< Tag1,Tag1 >,Tag1, Tag2 > > , aux::cast1st_impl< equal_to_impl< Tag2,Tag2 >,Tag1, Tag2 > > >::type >{ >}; > > >template<> struct equal_to_impl< na,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct equal_to_impl< na,Tag > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct equal_to_impl< Tag,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename T > struct equal_to_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > > >struct equal_to > > : equal_to_impl< > typename equal_to_tag<N1>::type > , typename equal_to_tag<N2>::type > >::template apply< N1,N2 >::type >{ > > >}; > >template<> struct equal_to< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : equal_to< T1 , T2 > { }; }; template< typename Tag > struct lambda< equal_to< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef equal_to< na , na > result_; typedef equal_to< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< equal_to< T1 , T2 > > : int_<2> { }; template<> struct template_arity< equal_to< na , na > > : int_<-1> { }; } > >}} > >namespace boost { namespace mpl { > >template<> >struct equal_to_impl< integral_c_tag,integral_c_tag > >{ > template< typename N1, typename N2 > struct apply > > : bool_< ( N1::value == N2::value ) > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/equal_to.hpp" 2 3 4 ># 18 "/usr/include/boost/numeric/conversion/detail/meta.hpp" 2 3 4 > > > > > >namespace boost { namespace numeric { namespace convdetail >{ > template< class T1, class T2> > struct equal_to > { > > > enum { x = ( T1::value == T2::value ) }; > > static const bool value = x; > > typedef mpl::bool_<value> type; ># 48 "/usr/include/boost/numeric/conversion/detail/meta.hpp" 3 4 > }; ># 59 "/usr/include/boost/numeric/conversion/detail/meta.hpp" 3 4 > template<class Value, > class Case0Val, > class Case1Val, > class Case2Val, > class Case0Type, > class Case1Type, > class Case2Type, > class DefaultType > > > struct ct_switch4 > { > typedef mpl::identity<Case0Type> Case0TypeQ ; > typedef mpl::identity<Case1Type> Case1TypeQ ; > > typedef equal_to<Value,Case0Val> is_case0 ; > typedef equal_to<Value,Case1Val> is_case1 ; > typedef equal_to<Value,Case2Val> is_case2 ; > > typedef mpl::if_<is_case2,Case2Type,DefaultType> choose_2_3Q ; > typedef mpl::eval_if<is_case1,Case1TypeQ,choose_2_3Q> choose_1_2_3Q ; > > typedef typename > mpl::eval_if<is_case0,Case0TypeQ,choose_1_2_3Q>::type > type ; > } ; ># 97 "/usr/include/boost/numeric/conversion/detail/meta.hpp" 3 4 > template<class expr0, class expr1, class TT, class TF, class FT, class FF> > struct for_both > { > typedef mpl::identity<TF> TF_Q ; > typedef mpl::identity<TT> TT_Q ; > > typedef typename mpl::not_<expr0>::type not_expr0 ; > typedef typename mpl::not_<expr1>::type not_expr1 ; > > typedef typename mpl::and_<expr0,expr1>::type caseTT ; > typedef typename mpl::and_<expr0,not_expr1>::type caseTF ; > typedef typename mpl::and_<not_expr0,expr1>::type caseFT ; > > typedef mpl::if_<caseFT,FT,FF> choose_FT_FF_Q ; > typedef mpl::eval_if<caseTF,TF_Q,choose_FT_FF_Q> choose_TF_FT_FF_Q ; > > typedef typename mpl::eval_if<caseTT,TT_Q,choose_TF_FT_FF_Q>::type type ; > } ; > >} } } ># 18 "/usr/include/boost/numeric/conversion/detail/conversion_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/numeric/conversion/detail/int_float_mixture.hpp" 1 3 4 ># 16 "/usr/include/boost/numeric/conversion/detail/int_float_mixture.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/int_float_mixture_enum.hpp" 1 3 4 ># 13 "/usr/include/boost/numeric/conversion/int_float_mixture_enum.hpp" 3 4 >namespace boost { namespace numeric >{ > enum int_float_mixture_enum > { > integral_to_integral > ,integral_to_float > ,float_to_integral > ,float_to_float > } ; > >} } ># 17 "/usr/include/boost/numeric/conversion/detail/int_float_mixture.hpp" 2 3 4 > > > > >namespace boost { namespace numeric { namespace convdetail >{ > > typedef mpl::integral_c<int_float_mixture_enum, integral_to_integral> int2int_c ; > typedef mpl::integral_c<int_float_mixture_enum, integral_to_float> int2float_c ; > typedef mpl::integral_c<int_float_mixture_enum, float_to_integral> float2int_c ; > typedef mpl::integral_c<int_float_mixture_enum, float_to_float> float2float_c ; > > > > > > > > template<class T,class S> > struct get_int_float_mixture > { > typedef mpl::bool_< ::std::numeric_limits<S>::is_integer > S_int ; > typedef mpl::bool_< ::std::numeric_limits<T>::is_integer > T_int ; > > typedef typename > for_both<S_int, T_int, int2int_c, int2float_c, float2int_c, float2float_c>::type > type ; > } ; ># 55 "/usr/include/boost/numeric/conversion/detail/int_float_mixture.hpp" 3 4 > template<class IntFloatMixture, class Int2Int, class Int2Float, class Float2Int, class Float2Float> > struct for_int_float_mixture > { > typedef typename > ct_switch4<IntFloatMixture > ,int2int_c, int2float_c, float2int_c > ,Int2Int , Int2Float , Float2Int , Float2Float > >::type > type ; > } ; > >} } } ># 19 "/usr/include/boost/numeric/conversion/detail/conversion_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/numeric/conversion/detail/sign_mixture.hpp" 1 3 4 ># 16 "/usr/include/boost/numeric/conversion/detail/sign_mixture.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/sign_mixture_enum.hpp" 1 3 4 ># 13 "/usr/include/boost/numeric/conversion/sign_mixture_enum.hpp" 3 4 >namespace boost { namespace numeric >{ > enum sign_mixture_enum > { > unsigned_to_unsigned > ,signed_to_signed > ,signed_to_unsigned > ,unsigned_to_signed > } ; > >} } ># 17 "/usr/include/boost/numeric/conversion/detail/sign_mixture.hpp" 2 3 4 > > > > >namespace boost { namespace numeric { namespace convdetail >{ > > typedef mpl::integral_c<sign_mixture_enum, unsigned_to_unsigned> unsig2unsig_c ; > typedef mpl::integral_c<sign_mixture_enum, signed_to_signed> sig2sig_c ; > typedef mpl::integral_c<sign_mixture_enum, signed_to_unsigned> sig2unsig_c ; > typedef mpl::integral_c<sign_mixture_enum, unsigned_to_signed> unsig2sig_c ; > > > > > > > > template<class T,class S> > struct get_sign_mixture > { > typedef mpl::bool_< ::std::numeric_limits<S>::is_signed > S_signed ; > typedef mpl::bool_< ::std::numeric_limits<T>::is_signed > T_signed ; > > typedef typename > for_both<S_signed, T_signed, sig2sig_c, sig2unsig_c, unsig2sig_c, unsig2unsig_c>::type > type ; > } ; ># 55 "/usr/include/boost/numeric/conversion/detail/sign_mixture.hpp" 3 4 > template<class SignMixture, class Sig2Sig, class Sig2Unsig, class Unsig2Sig, class Unsig2Unsig> > struct for_sign_mixture > { > typedef typename > ct_switch4<SignMixture > , sig2sig_c, sig2unsig_c, unsig2sig_c > , Sig2Sig , Sig2Unsig , Unsig2Sig , Unsig2Unsig > >::type > type ; > } ; > >} } } ># 20 "/usr/include/boost/numeric/conversion/detail/conversion_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/numeric/conversion/detail/udt_builtin_mixture.hpp" 1 3 4 ># 15 "/usr/include/boost/numeric/conversion/detail/udt_builtin_mixture.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/udt_builtin_mixture_enum.hpp" 1 3 4 ># 13 "/usr/include/boost/numeric/conversion/udt_builtin_mixture_enum.hpp" 3 4 >namespace boost { namespace numeric >{ > enum udt_builtin_mixture_enum > { > builtin_to_builtin > ,builtin_to_udt > ,udt_to_builtin > ,udt_to_udt > } ; > >} } ># 16 "/usr/include/boost/numeric/conversion/detail/udt_builtin_mixture.hpp" 2 3 4 > > > > >namespace boost { namespace numeric { namespace convdetail >{ > > typedef mpl::integral_c<udt_builtin_mixture_enum, builtin_to_builtin> builtin2builtin_c ; > typedef mpl::integral_c<udt_builtin_mixture_enum, builtin_to_udt> builtin2udt_c ; > typedef mpl::integral_c<udt_builtin_mixture_enum, udt_to_builtin> udt2builtin_c ; > typedef mpl::integral_c<udt_builtin_mixture_enum, udt_to_udt> udt2udt_c ; ># 37 "/usr/include/boost/numeric/conversion/detail/udt_builtin_mixture.hpp" 3 4 > template<class UdtMixture, class BuiltIn2BuiltIn, class BuiltIn2Udt, class Udt2BuiltIn, class Udt2Udt> > struct for_udt_builtin_mixture > { > typedef typename > ct_switch4<UdtMixture > , builtin2builtin_c, builtin2udt_c, udt2builtin_c > , BuiltIn2BuiltIn , BuiltIn2Udt , Udt2BuiltIn , Udt2Udt > >::type > type ; > } ; > > > > > > > > template<class T,class S> > struct get_udt_builtin_mixture > { > typedef is_arithmetic<S> S_builtin ; > typedef is_arithmetic<T> T_builtin ; > > typedef typename > for_both<S_builtin, T_builtin, builtin2builtin_c, builtin2udt_c, udt2builtin_c, udt2udt_c>::type > type ; > } ; > >} } } ># 21 "/usr/include/boost/numeric/conversion/detail/conversion_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/numeric/conversion/detail/is_subranged.hpp" 1 3 4 ># 17 "/usr/include/boost/numeric/conversion/detail/is_subranged.hpp" 3 4 ># 1 "/usr/include/boost/mpl/multiplies.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/multiplies.hpp" 3 4 ># 1 "/usr/include/boost/mpl/times.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/times.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 27 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/times.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/times.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Tag1 > , typename Tag2 > > >struct times_impl > : if_c< > ( Tag1::value > > Tag2::value > ) > > , aux::cast2nd_impl< times_impl< Tag1,Tag1 >,Tag1, Tag2 > > , aux::cast1st_impl< times_impl< Tag2,Tag2 >,Tag1, Tag2 > > >::type >{ >}; > > >template<> struct times_impl< na,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct times_impl< na,Tag > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct times_impl< Tag,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename T > struct times_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > , typename N3 = na, typename N4 = na, typename N5 = na > > >struct times > : times< times< times< times< N1,N2 >, N3>, N4>, N5> >{ > > > > > >}; > >template< > typename N1, typename N2, typename N3, typename N4 > > >struct times< N1,N2,N3,N4,na > > > : times< times< times< N1,N2 >, N3>, N4> >{ > > > > > >}; > >template< > typename N1, typename N2, typename N3 > > >struct times< N1,N2,N3,na,na > > > : times< times< N1,N2 >, N3> >{ > > > > > >}; > >template< > typename N1, typename N2 > > >struct times< N1,N2,na,na,na > > : times_impl< > typename times_tag<N1>::type > , typename times_tag<N2>::type > >::template apply< N1,N2 >::type >{ > > > > > > >}; > >template<> struct times< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : times< T1 , T2 > { }; }; template< typename Tag > struct lambda< times< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef times< na , na > result_; typedef times< na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct template_arity< times< T1 , T2 , T3 , T4 , T5 > > : int_<5> { }; template<> struct template_arity< times< na , na > > : int_<-1> { }; } > >}} > >namespace boost { namespace mpl { >template<> >struct times_impl< integral_c_tag,integral_c_tag > >{ > template< typename N1, typename N2 > struct apply > > : integral_c< > typename aux::largest_int< > typename N1::value_type > , typename N2::value_type > >::type > , ( N1::value > * N2::value > ) > > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 35 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/times.hpp" 2 3 4 ># 18 "/usr/include/boost/mpl/multiplies.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/aux_/preprocessor/default_params.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/multiplies.hpp" 2 3 4 > > > > > >namespace boost { namespace mpl { > > > > > > > >template< > typename N1 = na , typename N2 = na , typename N3 = na , typename N4 = na , typename N5 = na > > >struct multiplies > : times< N1 , N2 , N3 , N4 , N5 > >{ > > > > > >}; > >template<> struct multiplies< na , na , na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct apply : multiplies< T1 , T2 , T3 , T4 , T5 > { }; }; template< typename Tag > struct lambda< multiplies< na , na , na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef multiplies< na , na , na , na , na > result_; typedef multiplies< na , na , na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct template_arity< multiplies< T1 , T2 , T3 , T4 , T5 > > : int_<5> { }; template<> struct template_arity< multiplies< na , na , na , na , na > > : int_<-1> { }; } > > > >}} ># 18 "/usr/include/boost/numeric/conversion/detail/is_subranged.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/less.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/less.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/less.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/less.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Tag1 > , typename Tag2 > > >struct less_impl > : if_c< > ( Tag1::value > > Tag2::value > ) > > , aux::cast2nd_impl< less_impl< Tag1,Tag1 >,Tag1, Tag2 > > , aux::cast1st_impl< less_impl< Tag2,Tag2 >,Tag1, Tag2 > > >::type >{ >}; > > >template<> struct less_impl< na,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct less_impl< na,Tag > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct less_impl< Tag,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename T > struct less_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > > >struct less > > : less_impl< > typename less_tag<N1>::type > , typename less_tag<N2>::type > >::template apply< N1,N2 >::type >{ > > >}; > >template<> struct less< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : less< T1 , T2 > { }; }; template< typename Tag > struct lambda< less< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef less< na , na > result_; typedef less< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< less< T1 , T2 > > : int_<2> { }; template<> struct template_arity< less< na , na > > : int_<-1> { }; } > >}} > >namespace boost { namespace mpl { > >template<> >struct less_impl< integral_c_tag,integral_c_tag > >{ > template< typename N1, typename N2 > struct apply > > : bool_< ( N2::value > N1::value ) > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/less.hpp" 2 3 4 ># 19 "/usr/include/boost/numeric/conversion/detail/is_subranged.hpp" 2 3 4 ># 28 "/usr/include/boost/numeric/conversion/detail/is_subranged.hpp" 3 4 >namespace boost { namespace numeric { namespace convdetail >{ > > > > > > template<class T,class S> > struct subranged_Sig2Unsig > { > > > typedef mpl::true_ type ; > } ; > > > template<class T,class S> > struct subranged_Unsig2Sig > { ># 62 "/usr/include/boost/numeric/conversion/detail/is_subranged.hpp" 3 4 > typedef mpl::int_< ::std::numeric_limits<S>::digits > S_digits ; > typedef mpl::int_< ::std::numeric_limits<T>::digits > T_digits ; > > > typedef typename T_digits::next u_T_digits ; > > typedef mpl::int_<2> Two ; > > typedef typename mpl::multiplies<S_digits,Two>::type S_digits_times_2 ; > > typedef typename mpl::less<u_T_digits,S_digits_times_2>::type type ; > } ; > > > template<class T,class S> > struct subranged_SameSign > { > > > typedef mpl::int_< ::std::numeric_limits<S>::digits > S_digits ; > typedef mpl::int_< ::std::numeric_limits<T>::digits > T_digits ; > > typedef typename mpl::less<T_digits,S_digits>::type type ; > } ; > > > template<class T,class S> > struct subranged_Int2Float > { > typedef mpl::false_ type ; > } ; > > > template<class T,class S> > struct subranged_Float2Int > { > typedef mpl::true_ type ; > } ; > > > template<class T,class S> > struct subranged_Float2Float > { > > > > typedef mpl::int_< ::std::numeric_limits<S>::digits > S_mantisa ; > typedef mpl::int_< ::std::numeric_limits<T>::digits > T_mantisa ; > > typedef mpl::int_< ::std::numeric_limits<S>::max_exponent > S_exponent ; > typedef mpl::int_< ::std::numeric_limits<T>::max_exponent > T_exponent ; > > typedef typename mpl::less<T_exponent,S_exponent>::type T_smaller_exponent ; > > typedef typename mpl::equal_to<T_exponent,S_exponent>::type equal_exponents ; > > typedef mpl::less<T_mantisa,S_mantisa> T_smaller_mantisa ; > > typedef mpl::eval_if<equal_exponents,T_smaller_mantisa,mpl::false_> not_bigger_exponent_case ; > > typedef typename > mpl::eval_if<T_smaller_exponent,mpl::true_,not_bigger_exponent_case>::type > type ; > } ; > > > template<class T,class S> > struct subranged_Udt2BuiltIn > { > typedef mpl::true_ type ; > } ; > > > template<class T,class S> > struct subranged_BuiltIn2Udt > { > typedef mpl::false_ type ; > } ; > > > template<class T,class S> > struct subranged_Udt2Udt > { > typedef mpl::false_ type ; > } ; > > > > > > template<class T,class S> > struct get_subranged_Int2Int > { > typedef subranged_SameSign<T,S> Sig2Sig ; > typedef subranged_Sig2Unsig<T,S> Sig2Unsig ; > typedef subranged_Unsig2Sig<T,S> Unsig2Sig ; > typedef Sig2Sig Unsig2Unsig ; > > typedef typename get_sign_mixture<T,S>::type sign_mixture ; > > typedef typename > for_sign_mixture<sign_mixture, Sig2Sig, Sig2Unsig, Unsig2Sig, Unsig2Unsig>::type > type ; > } ; > > template<class T,class S> > struct get_subranged_BuiltIn2BuiltIn > { > typedef get_subranged_Int2Int<T,S> Int2IntQ ; > > typedef subranged_Int2Float <T,S> Int2Float ; > typedef subranged_Float2Int <T,S> Float2Int ; > typedef subranged_Float2Float<T,S> Float2Float ; > > typedef mpl::identity<Int2Float > Int2FloatQ ; > typedef mpl::identity<Float2Int > Float2IntQ ; > typedef mpl::identity<Float2Float> Float2FloatQ ; > > typedef typename get_int_float_mixture<T,S>::type int_float_mixture ; > > typedef for_int_float_mixture<int_float_mixture, Int2IntQ, Int2FloatQ, Float2IntQ, Float2FloatQ> for_ ; > > typedef typename for_::type selected ; > > typedef typename selected::type type ; > } ; > > template<class T,class S> > struct get_subranged > { > typedef get_subranged_BuiltIn2BuiltIn<T,S> BuiltIn2BuiltInQ ; > > typedef subranged_BuiltIn2Udt<T,S> BuiltIn2Udt ; > typedef subranged_Udt2BuiltIn<T,S> Udt2BuiltIn ; > typedef subranged_Udt2Udt<T,S> Udt2Udt ; > > typedef mpl::identity<BuiltIn2Udt> BuiltIn2UdtQ ; > typedef mpl::identity<Udt2BuiltIn> Udt2BuiltInQ ; > typedef mpl::identity<Udt2Udt > Udt2UdtQ ; > > typedef typename get_udt_builtin_mixture<T,S>::type udt_builtin_mixture ; > > typedef typename > for_udt_builtin_mixture<udt_builtin_mixture, BuiltIn2BuiltInQ, BuiltIn2UdtQ, Udt2BuiltInQ, Udt2UdtQ>::type > selected ; > > typedef typename selected::type selected2 ; > > typedef typename selected2::type type ; > } ; > > > > > > template<class T, class S> > struct get_is_subranged > { > typedef get_subranged<T,S> non_trivial_case ; > typedef mpl::identity<mpl::false_> trivial_case ; > > typedef is_same<T,S> is_trivial ; > > typedef typename mpl::if_<is_trivial,trivial_case,non_trivial_case>::type selected ; > > typedef typename selected::type type ; > } ; > >} } } ># 22 "/usr/include/boost/numeric/conversion/detail/conversion_traits.hpp" 2 3 4 > >namespace boost { namespace numeric { namespace convdetail >{ > > > > > > template<class T,class S> > struct non_trivial_traits_impl > { > typedef typename get_int_float_mixture <T,S>::type int_float_mixture ; > typedef typename get_sign_mixture <T,S>::type sign_mixture ; > typedef typename get_udt_builtin_mixture <T,S>::type udt_builtin_mixture ; > > typedef typename get_is_subranged<T,S>::type subranged ; > > typedef mpl::false_ trivial ; > > typedef T target_type ; > typedef S source_type ; > typedef T result_type ; > > typedef typename mpl::if_< is_arithmetic<S>, S, S const&>::type argument_type ; > > typedef typename mpl::if_<subranged,S,T>::type supertype ; > typedef typename mpl::if_<subranged,T,S>::type subtype ; > } ; > > > > > > > template<class N> > struct trivial_traits_impl > { > typedef typename get_int_float_mixture <N,N>::type int_float_mixture ; > typedef typename get_sign_mixture <N,N>::type sign_mixture ; > typedef typename get_udt_builtin_mixture<N,N>::type udt_builtin_mixture ; > > typedef mpl::false_ subranged ; > typedef mpl::true_ trivial ; > > typedef N target_type ; > typedef N source_type ; > typedef N const& result_type ; > typedef N const& argument_type ; > > typedef N supertype ; > typedef N subtype ; > > } ; > > > > > template<class T, class S> > struct get_conversion_traits > { > typedef typename remove_cv<T>::type target_type ; > typedef typename remove_cv<S>::type source_type ; > > typedef typename is_same<target_type,source_type>::type is_trivial ; > > typedef trivial_traits_impl <target_type> trivial_imp ; > typedef non_trivial_traits_impl<target_type,source_type> non_trivial_imp ; > > typedef typename mpl::if_<is_trivial,trivial_imp,non_trivial_imp>::type type ; > } ; > >} } } ># 14 "/usr/include/boost/numeric/conversion/conversion_traits.hpp" 2 3 4 > > > >namespace boost { namespace numeric >{ > >template<class T, class S> >struct conversion_traits > : convdetail::get_conversion_traits<T,S>::type >{ > > > > > > > >} ; > >} } ># 14 "/usr/include/boost/numeric/conversion/converter.hpp" 2 3 4 ># 1 "/usr/include/boost/numeric/conversion/converter_policies.hpp" 1 3 4 ># 25 "/usr/include/boost/numeric/conversion/converter_policies.hpp" 3 4 >namespace boost { namespace numeric >{ > >template<class S> >struct Trunc >{ > typedef S source_type ; > > typedef typename mpl::if_< is_arithmetic<S>,S,S const&>::type argument_type ; > > static source_type nearbyint ( argument_type s ) > { > > using std::floor ; > using std::ceil ; > > > return s < static_cast<S>(0) ? ceil(s) : floor(s) ; > } > > typedef mpl::integral_c< std::float_round_style, std::round_toward_zero> round_style ; >} ; > > > >template<class S> >struct Floor >{ > typedef S source_type ; > > typedef typename mpl::if_< is_arithmetic<S>,S,S const&>::type argument_type ; > > static source_type nearbyint ( argument_type s ) > { > > using std::floor ; > > > return floor(s) ; > } > > typedef mpl::integral_c< std::float_round_style, std::round_toward_neg_infinity> round_style ; >} ; > >template<class S> >struct Ceil >{ > typedef S source_type ; > > typedef typename mpl::if_< is_arithmetic<S>,S,S const&>::type argument_type ; > > static source_type nearbyint ( argument_type s ) > { > > using std::ceil ; > > > return ceil(s) ; > } > > typedef mpl::integral_c< std::float_round_style, std::round_toward_infinity> round_style ; >} ; > >template<class S> >struct RoundEven >{ > typedef S source_type ; > > typedef typename mpl::if_< is_arithmetic<S>,S,S const&>::type argument_type ; > > static source_type nearbyint ( argument_type s ) > { > > > > using std::floor ; > using std::ceil ; > > > > S prev = floor(s); > S next = ceil(s); > > S rt = (s - prev) - (next - s); > > S const zero(0.0); > S const two(2.0); > > if ( rt < zero ) > return prev; > else if ( rt > zero ) > return next; > else > { > bool is_prev_even = two * floor(prev / two) == prev ; > return ( is_prev_even ? prev : next ) ; > } > } > > typedef mpl::integral_c< std::float_round_style, std::round_to_nearest> round_style ; >} ; > > >enum range_check_result >{ > cInRange = 0 , > cNegOverflow = 1 , > cPosOverflow = 2 >} ; > >class bad_numeric_cast : public std::bad_cast >{ > public: > > virtual const char * what() const throw() > { return "bad numeric conversion: overflow"; } >}; > >class negative_overflow : public bad_numeric_cast >{ > public: > > virtual const char * what() const throw() > { return "bad numeric conversion: negative overflow"; } >}; >class positive_overflow : public bad_numeric_cast >{ > public: > > virtual const char * what() const throw() > { return "bad numeric conversion: positive overflow"; } >}; > >struct def_overflow_handler >{ > void operator() ( range_check_result r ) > { > > if ( r == cNegOverflow ) > throw negative_overflow() ; > else if ( r == cPosOverflow ) > throw positive_overflow() ; > > > > > > > } >} ; > >struct silent_overflow_handler >{ > void operator() ( range_check_result ) {} >} ; > >template<class Traits> >struct raw_converter >{ > typedef typename Traits::result_type result_type ; > typedef typename Traits::argument_type argument_type ; > > static result_type low_level_convert ( argument_type s ) { return static_cast<result_type>(s) ; } >} ; > >struct UseInternalRangeChecker {} ; > >} } ># 15 "/usr/include/boost/numeric/conversion/converter.hpp" 2 3 4 > ># 1 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 1 3 4 ># 17 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/bounds.hpp" 1 3 4 ># 13 "/usr/include/boost/numeric/conversion/bounds.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/detail/bounds.hpp" 1 3 4 ># 17 "/usr/include/boost/numeric/conversion/detail/bounds.hpp" 3 4 >namespace boost { namespace numeric { namespace boundsdetail >{ > template<class N> > class Integral > { > typedef std::numeric_limits<N> limits ; > > public : > > static N lowest () { return limits::min (); } > static N highest () { return limits::max (); } > static N smallest() { return static_cast<N>(1); } > } ; > > template<class N> > class Float > { > typedef std::numeric_limits<N> limits ; > > public : > > static N lowest () { return static_cast<N>(-limits::max ()) ; } > static N highest () { return limits::max (); } > static N smallest() { return limits::min (); } > } ; > > template<class N> > struct get_impl > { > typedef mpl::bool_< ::std::numeric_limits<N>::is_integer > is_int ; > > typedef Integral<N> impl_int ; > typedef Float <N> impl_float ; > > typedef typename mpl::if_<is_int,impl_int,impl_float>::type type ; > } ; > >} } } ># 14 "/usr/include/boost/numeric/conversion/bounds.hpp" 2 3 4 > >namespace boost { namespace numeric >{ > >template<class N> >struct bounds : boundsdetail::get_impl<N>::type >{} ; > >} } ># 18 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 2 3 4 > > > > > >namespace boost { namespace numeric { namespace convdetail >{ > > typedef mpl::integral_c<std::float_round_style, std::round_toward_zero> round2zero_c ; > typedef mpl::integral_c<std::float_round_style, std::round_to_nearest> round2nearest_c ; > typedef mpl::integral_c<std::float_round_style, std::round_toward_infinity> round2inf_c ; > typedef mpl::integral_c<std::float_round_style, std::round_toward_neg_infinity> round2neg_inf_c ; ># 40 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > template<class RoundStyle,class RoundToZero,class RoundToNearest,class RoundToInf,class RoundToNegInf> > struct for_round_style > { > typedef ct_switch4<RoundStyle > , round2zero_c, round2nearest_c, round2inf_c > , RoundToZero , RoundToNearest , RoundToInf , RoundToNegInf > > selector ; > > typedef typename selector::type type ; > } ; ># 81 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > struct non_applicable { typedef mpl::false_ do_apply ; } ; > struct applicable { typedef mpl::true_ do_apply ; } ; ># 96 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > template<class Traits> > struct LT_LoT : applicable > { > typedef typename Traits::target_type T ; > typedef typename Traits::source_type S ; > typedef typename Traits::argument_type argument_type ; > > static range_check_result apply ( argument_type s ) > { > return s < static_cast<S>(bounds<T>::lowest()) ? cNegOverflow : cInRange ; > } > } ; > > > > template<class Traits> > struct LT_Zero : applicable > { > typedef typename Traits::source_type S ; > typedef typename Traits::argument_type argument_type ; > > static range_check_result apply ( argument_type s ) > { > return s < static_cast<S>(0) ? cNegOverflow : cInRange ; > } > } ; > > > > template<class Traits> > struct LE_PrevLoT : applicable > { > typedef typename Traits::target_type T ; > typedef typename Traits::source_type S ; > typedef typename Traits::argument_type argument_type ; > > static range_check_result apply ( argument_type s ) > { > return s <= static_cast<S>(bounds<T>::lowest()) - static_cast<S>(1.0) > ? cNegOverflow : cInRange ; > } > } ; > > > > template<class Traits> > struct LT_HalfPrevLoT : applicable > { > typedef typename Traits::target_type T ; > typedef typename Traits::source_type S ; > typedef typename Traits::argument_type argument_type ; > > static range_check_result apply ( argument_type s ) > { > return s < static_cast<S>(bounds<T>::lowest()) - static_cast<S>(0.5) > ? cNegOverflow : cInRange ; > } > } ; > > > > template<class Traits> > struct GT_HiT : applicable > { > typedef typename Traits::target_type T ; > typedef typename Traits::source_type S ; > typedef typename Traits::argument_type argument_type ; > > static range_check_result apply ( argument_type s ) > { > return s > static_cast<S>(bounds<T>::highest()) > ? cPosOverflow : cInRange ; > } > } ; > > > > template<class Traits> > struct GE_SuccHiT : applicable > { > typedef typename Traits::target_type T ; > typedef typename Traits::source_type S ; > typedef typename Traits::argument_type argument_type ; > > static range_check_result apply ( argument_type s ) > { > return s >= static_cast<S>(bounds<T>::highest()) + static_cast<S>(1.0) > ? cPosOverflow : cInRange ; > } > } ; > > > > template<class Traits> > struct GT_HalfSuccHiT : applicable > { > typedef typename Traits::target_type T ; > typedef typename Traits::source_type S ; > typedef typename Traits::argument_type argument_type ; > > static range_check_result apply ( argument_type s ) > { > return s >= static_cast<S>(bounds<T>::highest()) + static_cast<S>(0.5) > ? cPosOverflow : cInRange ; > } > } ; ># 215 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > template<class PredA, class PredB> > struct applyBoth > { > typedef typename PredA::argument_type argument_type ; > > static range_check_result apply ( argument_type s ) > { > range_check_result r = PredA::apply(s) ; > if ( r == cInRange ) > r = PredB::apply(s); > return r ; > } > } ; > > template<class PredA, class PredB> > struct combine > { > typedef applyBoth<PredA,PredB> Both ; > typedef void NNone ; > > typedef typename PredA::do_apply do_applyA ; > typedef typename PredB::do_apply do_applyB ; > > typedef typename for_both<do_applyA, do_applyB, Both, PredA, PredB, NNone>::type type ; > } ; ># 262 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > template<class Traits> > struct dummy_range_checker > { > typedef typename Traits::argument_type argument_type ; > > static range_check_result out_of_range ( argument_type ) { return cInRange ; } > static void validate_range ( argument_type ) {} > } ; ># 279 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > template<class Traits, class IsNegOverflow, class IsPosOverflow, class OverflowHandler> > struct generic_range_checker > { > typedef OverflowHandler overflow_handler ; > > typedef typename Traits::argument_type argument_type ; > > static range_check_result out_of_range ( argument_type s ) > { > typedef typename combine<IsNegOverflow,IsPosOverflow>::type Predicate ; > > return Predicate::apply(s); > } > > static void validate_range ( argument_type s ) > { OverflowHandler()( out_of_range(s) ) ; } > } ; ># 305 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > template<class Traits,class OverflowHandler> > struct GetRC_Sig2Sig_or_Unsig2Unsig > { > typedef dummy_range_checker<Traits> Dummy ; > > typedef LT_LoT<Traits> Pred1 ; > typedef GT_HiT<Traits> Pred2 ; > > typedef generic_range_checker<Traits,Pred1,Pred2,OverflowHandler> Normal ; > > typedef typename Traits::subranged subranged ; > > typedef typename mpl::if_<subranged,Normal,Dummy>::type type ; > } ; > > template<class Traits, class OverflowHandler> > struct GetRC_Sig2Unsig > { > typedef LT_Zero<Traits> Pred1 ; > typedef GT_HiT <Traits> Pred2 ; > > typedef generic_range_checker<Traits,Pred1,Pred2,OverflowHandler> ChoiceA ; > > typedef generic_range_checker<Traits,Pred1,non_applicable,OverflowHandler> ChoiceB ; > > typedef typename Traits::target_type T ; > typedef typename Traits::source_type S ; > > typedef typename subranged_Unsig2Sig<S,T>::type oposite_subranged ; > > typedef typename mpl::not_<oposite_subranged>::type positively_subranged ; > > typedef typename mpl::if_<positively_subranged,ChoiceA,ChoiceB>::type type ; > } ; > > template<class Traits, class OverflowHandler> > struct GetRC_Unsig2Sig > { > typedef GT_HiT<Traits> Pred1 ; > > typedef generic_range_checker<Traits,non_applicable,Pred1,OverflowHandler> type ; > } ; > > template<class Traits,class OverflowHandler> > struct GetRC_Int2Int > { > typedef GetRC_Sig2Sig_or_Unsig2Unsig<Traits,OverflowHandler> Sig2SigQ ; > typedef GetRC_Sig2Unsig <Traits,OverflowHandler> Sig2UnsigQ ; > typedef GetRC_Unsig2Sig <Traits,OverflowHandler> Unsig2SigQ ; > typedef Sig2SigQ Unsig2UnsigQ ; > > typedef typename Traits::sign_mixture sign_mixture ; > > typedef typename > for_sign_mixture<sign_mixture,Sig2SigQ,Sig2UnsigQ,Unsig2SigQ,Unsig2UnsigQ>::type > selector ; > > typedef typename selector::type type ; > } ; > > template<class Traits> > struct GetRC_Int2Float > { > typedef dummy_range_checker<Traits> type ; > } ; > > template<class Traits, class OverflowHandler, class Float2IntRounder> > struct GetRC_Float2Int > { > typedef LE_PrevLoT <Traits> Pred1 ; > typedef GE_SuccHiT <Traits> Pred2 ; > typedef LT_HalfPrevLoT<Traits> Pred3 ; > typedef GT_HalfSuccHiT<Traits> Pred4 ; > typedef GT_HiT <Traits> Pred5 ; > typedef LT_LoT <Traits> Pred6 ; > > typedef generic_range_checker<Traits,Pred1,Pred2,OverflowHandler> ToZero ; > typedef generic_range_checker<Traits,Pred3,Pred4,OverflowHandler> ToNearest ; > typedef generic_range_checker<Traits,Pred1,Pred5,OverflowHandler> ToInf ; > typedef generic_range_checker<Traits,Pred6,Pred2,OverflowHandler> ToNegInf ; > > typedef typename Float2IntRounder::round_style round_style ; > > typedef typename for_round_style<round_style,ToZero,ToNearest,ToInf,ToNegInf>::type type ; > } ; > > template<class Traits, class OverflowHandler> > struct GetRC_Float2Float > { > typedef dummy_range_checker<Traits> Dummy ; > > typedef LT_LoT<Traits> Pred1 ; > typedef GT_HiT<Traits> Pred2 ; > > typedef generic_range_checker<Traits,Pred1,Pred2,OverflowHandler> Normal ; > > typedef typename Traits::subranged subranged ; > > typedef typename mpl::if_<subranged,Normal,Dummy>::type type ; > } ; > > template<class Traits, class OverflowHandler, class Float2IntRounder> > struct GetRC_BuiltIn2BuiltIn > { > typedef GetRC_Int2Int<Traits,OverflowHandler> Int2IntQ ; > typedef GetRC_Int2Float<Traits> Int2FloatQ ; > typedef GetRC_Float2Int<Traits,OverflowHandler,Float2IntRounder> Float2IntQ ; > typedef GetRC_Float2Float<Traits,OverflowHandler> Float2FloatQ ; > > typedef typename Traits::int_float_mixture int_float_mixture ; > > typedef typename for_int_float_mixture<int_float_mixture, Int2IntQ, Int2FloatQ, Float2IntQ, Float2FloatQ>::type selector ; > > typedef typename selector::type type ; > } ; > > template<class Traits, class OverflowHandler, class Float2IntRounder> > struct GetRC > { > typedef GetRC_BuiltIn2BuiltIn<Traits,OverflowHandler,Float2IntRounder> BuiltIn2BuiltInQ ; > > typedef dummy_range_checker<Traits> Dummy ; > > typedef mpl::identity<Dummy> DummyQ ; > > typedef typename Traits::udt_builtin_mixture udt_builtin_mixture ; > > typedef typename for_udt_builtin_mixture<udt_builtin_mixture,BuiltIn2BuiltInQ,DummyQ,DummyQ,DummyQ>::type selector ; > > typedef typename selector::type type ; > } ; ># 452 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > template<class Traits> > struct trivial_converter_impl : public std::unary_function< typename Traits::argument_type > ,typename Traits::result_type > > > ,public dummy_range_checker<Traits> > { > typedef Traits traits ; > > typedef typename Traits::source_type source_type ; > typedef typename Traits::argument_type argument_type ; > typedef typename Traits::result_type result_type ; > > static result_type low_level_convert ( argument_type s ) { return s ; } > static source_type nearbyint ( argument_type s ) { return s ; } > static result_type convert ( argument_type s ) { return s ; } > } ; > > > > > > template<class Traits,class RangeChecker,class RawConverter,class Float2IntRounder> > struct rounding_converter : public std::unary_function< typename Traits::argument_type > ,typename Traits::result_type > > > ,public RangeChecker > ,public Float2IntRounder > ,public RawConverter > { > typedef RangeChecker RangeCheckerBase ; > typedef Float2IntRounder Float2IntRounderBase ; > typedef RawConverter RawConverterBase ; > > typedef Traits traits ; > > typedef typename Traits::source_type source_type ; > typedef typename Traits::argument_type argument_type ; > typedef typename Traits::result_type result_type ; > > static result_type convert ( argument_type s ) > { > RangeCheckerBase::validate_range(s); > source_type s1 = Float2IntRounderBase::nearbyint(s); > return RawConverterBase::low_level_convert(s1); > } > } ; > > > > > > template<class Traits,class RangeChecker,class RawConverter> > struct non_rounding_converter : public std::unary_function< typename Traits::argument_type > ,typename Traits::result_type > > > ,public RangeChecker > ,public RawConverter > { > typedef RangeChecker RangeCheckerBase ; > typedef RawConverter RawConverterBase ; > > typedef Traits traits ; > > typedef typename Traits::source_type source_type ; > typedef typename Traits::argument_type argument_type ; > typedef typename Traits::result_type result_type ; > > static source_type nearbyint ( argument_type s ) { return s ; } > > static result_type convert ( argument_type s ) > { > RangeCheckerBase::validate_range(s); > return RawConverterBase::low_level_convert(s); > } > } ; ># 537 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > template<class Traits,class OverflowHandler,class Float2IntRounder,class RawConverter, class UserRangeChecker> > struct get_non_trivial_converter > { > typedef GetRC<Traits,OverflowHandler,Float2IntRounder> InternalRangeCheckerQ ; > > typedef is_same<UserRangeChecker,UseInternalRangeChecker> use_internal_RC ; > > typedef mpl::identity<UserRangeChecker> UserRangeCheckerQ ; > > typedef typename > mpl::eval_if<use_internal_RC,InternalRangeCheckerQ,UserRangeCheckerQ>::type > RangeChecker ; > > typedef non_rounding_converter<Traits,RangeChecker,RawConverter> NonRounding ; > typedef rounding_converter<Traits,RangeChecker,RawConverter,Float2IntRounder> Rounding ; > > typedef mpl::identity<NonRounding> NonRoundingQ ; > typedef mpl::identity<Rounding> RoundingQ ; > > typedef typename Traits::int_float_mixture int_float_mixture ; > > typedef typename > for_int_float_mixture<int_float_mixture, NonRoundingQ, NonRoundingQ, RoundingQ, NonRoundingQ>::type > selector ; > > typedef typename selector::type type ; > } ; > > template< class Traits > ,class OverflowHandler > ,class Float2IntRounder > ,class RawConverter > ,class UserRangeChecker > > > struct get_converter_impl > { ># 583 "/usr/include/boost/numeric/conversion/detail/converter.hpp" 3 4 > typedef trivial_converter_impl<Traits> Trivial ; > typedef mpl::identity <Trivial> TrivialQ ; > > typedef get_non_trivial_converter< Traits > ,OverflowHandler > ,Float2IntRounder > ,RawConverter > ,UserRangeChecker > > NonTrivialQ ; > > typedef typename Traits::trivial trivial ; > > typedef typename mpl::eval_if<trivial,TrivialQ,NonTrivialQ>::type type ; > } ; > >} } } ># 17 "/usr/include/boost/numeric/conversion/converter.hpp" 2 3 4 > >namespace boost { namespace numeric >{ > >template<class T, > class S, > class Traits = conversion_traits<T,S>, > class OverflowHandler = def_overflow_handler, > class Float2IntRounder = Trunc< typename Traits::source_type> , > class RawConverter = raw_converter<Traits>, > class UserRangeChecker = UseInternalRangeChecker > > >struct converter : convdetail::get_converter_impl<Traits, > OverflowHandler, > Float2IntRounder, > RawConverter, > UserRangeChecker > >::type >{ > typedef Traits traits ; > > typedef typename Traits::argument_type argument_type ; > typedef typename Traits::result_type result_type ; > > result_type operator() ( argument_type s ) const { return this->convert(s) ; } >} ; > > > >template<class S, > class OverflowHandler = def_overflow_handler, > class Float2IntRounder = Trunc<S> , > class UserRangeChecker = UseInternalRangeChecker > > >struct make_converter_from >{ > template<class T, > class Traits = conversion_traits<T,S>, > class RawConverter = raw_converter<Traits> > > > struct to > { > typedef converter<T,S,Traits,OverflowHandler,Float2IntRounder,RawConverter,UserRangeChecker> type ; > } ; > >} ; > >} } ># 34 "/usr/include/boost/numeric/conversion/cast.hpp" 2 3 4 ># 1 "/usr/include/boost/numeric/conversion/numeric_cast_traits.hpp" 1 3 4 ># 14 "/usr/include/boost/numeric/conversion/numeric_cast_traits.hpp" 3 4 >namespace boost { namespace numeric { > > template <typename Target, typename Source, typename EnableIf = void> > struct numeric_cast_traits > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<Source> rounding_policy; > }; > >}} > > ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 28 "/usr/include/boost/numeric/conversion/numeric_cast_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/numeric/conversion/detail/numeric_cast_traits.hpp" 1 3 4 ># 12 "/usr/include/boost/numeric/conversion/detail/numeric_cast_traits.hpp" 3 4 ># 1 "/usr/include/boost/numeric/conversion/detail/preprocessed/numeric_cast_traits_common.hpp" 1 3 4 ># 12 "/usr/include/boost/numeric/conversion/detail/preprocessed/numeric_cast_traits_common.hpp" 3 4 >namespace boost { namespace numeric { > > template <> > struct numeric_cast_traits > < > char > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , signed char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<signed char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , unsigned char > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned char> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , unsigned short > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned short> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , unsigned int > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned int> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , unsigned long > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<unsigned long> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , float > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<float> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<double> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , long double > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<long double> rounding_policy; > }; >}} ># 13 "/usr/include/boost/numeric/conversion/detail/numeric_cast_traits.hpp" 2 3 4 > > ># 1 "/usr/include/boost/numeric/conversion/detail/preprocessed/numeric_cast_traits_long_long.hpp" 1 3 4 ># 9 "/usr/include/boost/numeric/conversion/detail/preprocessed/numeric_cast_traits_long_long.hpp" 3 4 >namespace boost { namespace numeric { > > > template <> > struct numeric_cast_traits > < > char > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > char > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > signed char > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned char > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > short > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned short > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > int > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned int > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > unsigned long > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > float > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > double > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > long double > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > boost::long_long_type > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > boost::long_long_type > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > boost::ulong_long_type > , boost::long_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::long_long_type> rounding_policy; > }; > > template <> > struct numeric_cast_traits > < > boost::ulong_long_type > , boost::ulong_long_type > > > { > typedef def_overflow_handler overflow_policy; > typedef UseInternalRangeChecker range_checking_policy; > typedef Trunc<boost::ulong_long_type> rounding_policy; > }; >}} ># 16 "/usr/include/boost/numeric/conversion/detail/numeric_cast_traits.hpp" 2 3 4 ># 29 "/usr/include/boost/numeric/conversion/numeric_cast_traits.hpp" 2 3 4 ># 35 "/usr/include/boost/numeric/conversion/cast.hpp" 2 3 4 > >namespace boost >{ > template <typename Target, typename Source> > inline Target numeric_cast( Source arg ) > { > typedef numeric::conversion_traits<Target, Source> conv_traits; > typedef numeric::numeric_cast_traits<Target, Source> cast_traits; > typedef boost::numeric::converter > < > Target, > Source, > conv_traits, > typename cast_traits::overflow_policy, > typename cast_traits::rounding_policy, > boost::numeric::raw_converter< conv_traits >, > typename cast_traits::range_checking_policy > > converter; > return converter::convert(arg); > } > > using numeric::bad_numeric_cast; >} ># 160 "/usr/include/boost/lexical_cast.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/type_traits/has_left_shift.hpp" 1 3 4 ># 43 "/usr/include/boost/type_traits/has_left_shift.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 1 3 4 ># 25 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 26 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 2 3 4 ># 40 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 4 ># 41 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 > > > > > >namespace boost { >namespace detail { > > >namespace has_left_shift_impl { > > > >template <typename T> T &make(); > > > > > > > >struct no_operator { }; > > > > >struct any { template <class T> any(T const&); }; > > >no_operator operator << (const any&, const any&); ># 82 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 >struct returns_void_t { }; >template <typename T> int operator,(const T&, returns_void_t); >template <typename T> int operator,(const volatile T&, returns_void_t); > > > > >template < typename Lhs, typename Rhs > >struct operator_returns_void { > > > static ::boost::type_traits::yes_type returns_void(returns_void_t); > static ::boost::type_traits::no_type returns_void(int); > static const bool value = (sizeof(::boost::type_traits::yes_type)==sizeof(returns_void((make<Lhs>() << make<Rhs>(),returns_void_t())))); >}; > > > > > >struct dont_care { }; > >template < typename Lhs, typename Rhs, typename Ret, bool Returns_void > >struct operator_returns_Ret; > >template < typename Lhs, typename Rhs > >struct operator_returns_Ret < Lhs, Rhs, dont_care, true > { > static const bool value = true; >}; > >template < typename Lhs, typename Rhs > >struct operator_returns_Ret < Lhs, Rhs, dont_care, false > { > static const bool value = true; >}; > >template < typename Lhs, typename Rhs > >struct operator_returns_Ret < Lhs, Rhs, void, true > { > static const bool value = true; >}; > >template < typename Lhs, typename Rhs > >struct operator_returns_Ret < Lhs, Rhs, void, false > { > static const bool value = false; >}; > >template < typename Lhs, typename Rhs, typename Ret > >struct operator_returns_Ret < Lhs, Rhs, Ret, true > { > static const bool value = false; >}; > > > > >template < typename Lhs, typename Rhs, typename Ret > >struct operator_returns_Ret < Lhs, Rhs, Ret, false > { > static ::boost::type_traits::yes_type is_convertible_to_Ret(Ret); > static ::boost::type_traits::no_type is_convertible_to_Ret(...); > > static const bool value = (sizeof(is_convertible_to_Ret(make<Lhs>() << make<Rhs>()))==sizeof(::boost::type_traits::yes_type)); >}; ># 150 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 >struct has_operator { }; >no_operator operator,(no_operator, has_operator); > >template < typename Lhs, typename Rhs > >struct operator_exists { > static ::boost::type_traits::yes_type check(has_operator); > static ::boost::type_traits::no_type check(no_operator); > > static const bool value = (sizeof(check(((make<Lhs>() << make<Rhs>()),make<has_operator>())))==sizeof(::boost::type_traits::yes_type)); >}; ># 169 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 >template < typename Lhs, typename Rhs, typename Ret, bool Forbidden_if > >struct trait_impl1; > >template < typename Lhs, typename Rhs, typename Ret > >struct trait_impl1 < Lhs, Rhs, Ret, true > { > static const bool value = false; >}; > >template < typename Lhs, typename Rhs, typename Ret > >struct trait_impl1 < Lhs, Rhs, Ret, false > { > static const bool value = ( ::boost::type_traits::ice_and< operator_exists < Lhs, Rhs >::value, operator_returns_Ret < Lhs, Rhs, Ret, operator_returns_void < Lhs, Rhs >::value >::value >::value ) > > > > > > > ; >}; > > >template < typename Rhs, typename Ret > >struct trait_impl1 < void, Rhs, Ret, false > { > static const bool value = false; >}; > >template < typename Lhs, typename Ret > >struct trait_impl1 < Lhs, void, Ret, false > { > static const bool value = false; >}; > >template < typename Ret > >struct trait_impl1 < void, void, Ret, false > { > static const bool value = false; >}; > > >template < typename Lhs, typename Rhs, typename Ret > >struct trait_impl { > typedef typename ::boost::remove_reference<Lhs>::type Lhs_noref; > typedef typename ::boost::remove_reference<Rhs>::type Rhs_noref; > typedef typename ::boost::remove_cv<Lhs_noref>::type Lhs_nocv; > typedef typename ::boost::remove_cv<Rhs_noref>::type Rhs_nocv; > typedef typename ::boost::remove_cv< typename ::boost::remove_reference< typename ::boost::remove_pointer<Lhs_noref>::type >::type >::type Lhs_noptr; > typedef typename ::boost::remove_cv< typename ::boost::remove_reference< typename ::boost::remove_pointer<Rhs_noref>::type >::type >::type Rhs_noptr; > static const bool value = (trait_impl1 < Lhs_noref, Rhs_noref, Ret, ::boost::type_traits::ice_or< ::boost::type_traits::ice_and< ::boost::is_fundamental< Lhs_nocv >::value, ::boost::is_fundamental< Rhs_nocv >::value, ::boost::type_traits::ice_or< ::boost::type_traits::ice_not< ::boost::is_integral< Lhs_noref >::value >::value, ::boost::type_traits::ice_not< ::boost::is_integral< Rhs_noref >::value >::value >::value >::value, ::boost::type_traits::ice_and< ::boost::is_fundamental< Lhs_nocv >::value, ::boost::is_pointer< Rhs_noref >::value >::value, ::boost::type_traits::ice_and< ::boost::is_fundamental< Rhs_nocv >::value, ::boost::is_pointer< Lhs_noref >::value >::value, ::boost::type_traits::ice_and< ::boost::is_pointer< Lhs_noref >::value, ::boost::is_pointer< Rhs_noref >::value >::value >::value >::value); >}; > >} >} > > >template< typename Lhs, typename Rhs=Lhs, typename Ret=::boost::detail::has_left_shift_impl::dont_care > struct has_left_shift : public ::boost::integral_constant<bool,(::boost::detail::has_left_shift_impl::trait_impl < Lhs, Rhs, Ret >::value)> { public: }; > >} > > > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 229 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 2 3 ># 44 "/usr/include/boost/type_traits/has_left_shift.hpp" 2 3 4 ># 166 "/usr/include/boost/lexical_cast.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/has_right_shift.hpp" 1 3 4 ># 43 "/usr/include/boost/type_traits/has_right_shift.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 1 3 4 ># 25 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 26 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 2 3 4 ># 40 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 4 ># 41 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 > > > > > >namespace boost { >namespace detail { > > >namespace has_right_shift_impl { > > > >template <typename T> T &make(); > > > > > > > >struct no_operator { }; > > > > >struct any { template <class T> any(T const&); }; > > >no_operator operator >> (const any&, const any&); ># 82 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 >struct returns_void_t { }; >template <typename T> int operator,(const T&, returns_void_t); >template <typename T> int operator,(const volatile T&, returns_void_t); > > > > >template < typename Lhs, typename Rhs > >struct operator_returns_void { > > > static ::boost::type_traits::yes_type returns_void(returns_void_t); > static ::boost::type_traits::no_type returns_void(int); > static const bool value = (sizeof(::boost::type_traits::yes_type)==sizeof(returns_void((make<Lhs>() >> make<Rhs>(),returns_void_t())))); >}; > > > > > >struct dont_care { }; > >template < typename Lhs, typename Rhs, typename Ret, bool Returns_void > >struct operator_returns_Ret; > >template < typename Lhs, typename Rhs > >struct operator_returns_Ret < Lhs, Rhs, dont_care, true > { > static const bool value = true; >}; > >template < typename Lhs, typename Rhs > >struct operator_returns_Ret < Lhs, Rhs, dont_care, false > { > static const bool value = true; >}; > >template < typename Lhs, typename Rhs > >struct operator_returns_Ret < Lhs, Rhs, void, true > { > static const bool value = true; >}; > >template < typename Lhs, typename Rhs > >struct operator_returns_Ret < Lhs, Rhs, void, false > { > static const bool value = false; >}; > >template < typename Lhs, typename Rhs, typename Ret > >struct operator_returns_Ret < Lhs, Rhs, Ret, true > { > static const bool value = false; >}; > > > > >template < typename Lhs, typename Rhs, typename Ret > >struct operator_returns_Ret < Lhs, Rhs, Ret, false > { > static ::boost::type_traits::yes_type is_convertible_to_Ret(Ret); > static ::boost::type_traits::no_type is_convertible_to_Ret(...); > > static const bool value = (sizeof(is_convertible_to_Ret(make<Lhs>() >> make<Rhs>()))==sizeof(::boost::type_traits::yes_type)); >}; ># 150 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 >struct has_operator { }; >no_operator operator,(no_operator, has_operator); > >template < typename Lhs, typename Rhs > >struct operator_exists { > static ::boost::type_traits::yes_type check(has_operator); > static ::boost::type_traits::no_type check(no_operator); > > static const bool value = (sizeof(check(((make<Lhs>() >> make<Rhs>()),make<has_operator>())))==sizeof(::boost::type_traits::yes_type)); >}; ># 169 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 3 >template < typename Lhs, typename Rhs, typename Ret, bool Forbidden_if > >struct trait_impl1; > >template < typename Lhs, typename Rhs, typename Ret > >struct trait_impl1 < Lhs, Rhs, Ret, true > { > static const bool value = false; >}; > >template < typename Lhs, typename Rhs, typename Ret > >struct trait_impl1 < Lhs, Rhs, Ret, false > { > static const bool value = ( ::boost::type_traits::ice_and< operator_exists < Lhs, Rhs >::value, operator_returns_Ret < Lhs, Rhs, Ret, operator_returns_void < Lhs, Rhs >::value >::value >::value ) > > > > > > > ; >}; > > >template < typename Rhs, typename Ret > >struct trait_impl1 < void, Rhs, Ret, false > { > static const bool value = false; >}; > >template < typename Lhs, typename Ret > >struct trait_impl1 < Lhs, void, Ret, false > { > static const bool value = false; >}; > >template < typename Ret > >struct trait_impl1 < void, void, Ret, false > { > static const bool value = false; >}; > > >template < typename Lhs, typename Rhs, typename Ret > >struct trait_impl { > typedef typename ::boost::remove_reference<Lhs>::type Lhs_noref; > typedef typename ::boost::remove_reference<Rhs>::type Rhs_noref; > typedef typename ::boost::remove_cv<Lhs_noref>::type Lhs_nocv; > typedef typename ::boost::remove_cv<Rhs_noref>::type Rhs_nocv; > typedef typename ::boost::remove_cv< typename ::boost::remove_reference< typename ::boost::remove_pointer<Lhs_noref>::type >::type >::type Lhs_noptr; > typedef typename ::boost::remove_cv< typename ::boost::remove_reference< typename ::boost::remove_pointer<Rhs_noref>::type >::type >::type Rhs_noptr; > static const bool value = (trait_impl1 < Lhs_noref, Rhs_noref, Ret, ::boost::type_traits::ice_or< ::boost::type_traits::ice_and< ::boost::is_fundamental< Lhs_nocv >::value, ::boost::is_fundamental< Rhs_nocv >::value, ::boost::type_traits::ice_or< ::boost::type_traits::ice_not< ::boost::is_integral< Lhs_noref >::value >::value, ::boost::type_traits::ice_not< ::boost::is_integral< Rhs_noref >::value >::value >::value >::value, ::boost::type_traits::ice_and< ::boost::is_fundamental< Lhs_nocv >::value, ::boost::is_pointer< Rhs_noref >::value >::value, ::boost::type_traits::ice_and< ::boost::is_fundamental< Rhs_nocv >::value, ::boost::is_pointer< Lhs_noref >::value >::value, ::boost::type_traits::ice_and< ::boost::is_pointer< Lhs_noref >::value, ::boost::is_pointer< Rhs_noref >::value >::value >::value >::value); >}; > >} >} > > >template< typename Lhs, typename Rhs=Lhs, typename Ret=::boost::detail::has_right_shift_impl::dont_care > struct has_right_shift : public ::boost::integral_constant<bool,(::boost::detail::has_right_shift_impl::trait_impl < Lhs, Rhs, Ret >::value)> { public: }; > >} > > > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 229 "/usr/include/boost/type_traits/detail/has_binary_operator.hpp" 2 3 ># 44 "/usr/include/boost/type_traits/has_right_shift.hpp" 2 3 4 ># 167 "/usr/include/boost/lexical_cast.hpp" 2 3 4 ># 1 "/usr/include/boost/math/special_functions/sign.hpp" 1 3 4 ># 16 "/usr/include/boost/math/special_functions/sign.hpp" 3 4 ># 1 "/usr/include/boost/math/tools/config.hpp" 1 3 4 ># 14 "/usr/include/boost/math/tools/config.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 15 "/usr/include/boost/math/tools/config.hpp" 2 3 4 > > > ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 19 "/usr/include/boost/math/tools/config.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cfloat" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cfloat" 3 4 ># 40 "/usr/include/c++/4.9.0/cfloat" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/float.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/cfloat" 2 3 ># 20 "/usr/include/boost/math/tools/config.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/math/tools/user.hpp" 1 3 4 ># 25 "/usr/include/boost/math/tools/config.hpp" 2 3 4 ># 263 "/usr/include/boost/math/tools/config.hpp" 3 4 >namespace boost{ namespace math{ >namespace tools >{ > >template <class T> >inline T max (T a, T b, T c) >{ > return (std::max)((std::max)(a, b), c); >} > >template <class T> >inline T max (T a, T b, T c, T d) >{ > return (std::max)((std::max)(a, b), (std::max)(c, d)); >} > >} > >template <class T> >void suppress_unused_variable_warning(const T&) >{ >} > >}} > > > ># 1 "/usr/include/boost/detail/fenv.hpp" 1 3 4 ># 69 "/usr/include/boost/detail/fenv.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/fenv.h" 1 3 4 ># 32 "/usr/include/c++/4.9.0/fenv.h" 3 4 ># 33 "/usr/include/c++/4.9.0/fenv.h" 3 > > > ># 1 "/usr/include/fenv.h" 1 3 4 ># 57 "/usr/include/fenv.h" 3 4 ># 1 "/usr/include/bits/fenv.h" 1 3 4 ># 24 "/usr/include/bits/fenv.h" 3 4 >enum > { > FE_INVALID = > > 0x01, > __FE_DENORM = 0x02, > FE_DIVBYZERO = > > 0x04, > FE_OVERFLOW = > > 0x08, > FE_UNDERFLOW = > > 0x10, > FE_INEXACT = > > 0x20 > }; > > > > > > > >enum > { > FE_TONEAREST = > > 0, > FE_DOWNWARD = > > 0x400, > FE_UPWARD = > > 0x800, > FE_TOWARDZERO = > > 0xc00 > }; > > > >typedef unsigned short int fexcept_t; > > > > > > >typedef struct > { > unsigned short int __control_word; > unsigned short int __unused1; > unsigned short int __status_word; > unsigned short int __unused2; > unsigned short int __tags; > unsigned short int __unused3; > unsigned int __eip; > unsigned short int __cs_selector; > unsigned int __opcode:11; > unsigned int __unused4:5; > unsigned int __data_offset; > unsigned short int __data_selector; > unsigned short int __unused5; > > unsigned int __mxcsr; > > } >fenv_t; ># 106 "/usr/include/bits/fenv.h" 3 4 >extern "C" { > > >extern int __feraiseexcept_renamed (int) throw () __asm__ ("" "feraiseexcept"); >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) feraiseexcept (int __excepts) throw () >{ > if (__builtin_constant_p (__excepts) > && (__excepts & ~(0x01 | 0x04)) == 0) > { > if ((0x01 & __excepts) != 0) > { > > float __f = 0.0; > > > __asm__ __volatile__ ("divss %0, %0 " : : "x" (__f)); > > > > > (void) &__f; > } > if ((0x04 & __excepts) != 0) > { > float __f = 1.0; > float __g = 0.0; > > > __asm__ __volatile__ ("divss %1, %0" : : "x" (__f), "x" (__g)); > > > > > (void) &__f; > } > > return 0; > } > > return __feraiseexcept_renamed (__excepts); >} > >} ># 58 "/usr/include/fenv.h" 2 3 4 > >extern "C" { > > > > >extern int feclearexcept (int __excepts) throw (); > > > >extern int fegetexceptflag (fexcept_t *__flagp, int __excepts) throw (); > > >extern int feraiseexcept (int __excepts) throw (); > > > >extern int fesetexceptflag (const fexcept_t *__flagp, int __excepts) throw (); > > > >extern int fetestexcept (int __excepts) throw (); > > > > > >extern int fegetround (void) throw (); > > >extern int fesetround (int __rounding_direction) throw (); > > > > > > >extern int fegetenv (fenv_t *__envp) throw (); > > > > >extern int feholdexcept (fenv_t *__envp) throw (); > > > >extern int fesetenv (const fenv_t *__envp) throw (); > > > > >extern int feupdateenv (const fenv_t *__envp) throw (); > > > > ># 1 "/usr/include/bits/fenvinline.h" 1 3 4 ># 115 "/usr/include/fenv.h" 2 3 4 > > > > > > > >extern int feenableexcept (int __excepts) throw (); > > > > >extern int fedisableexcept (int __excepts) throw (); > > >extern int fegetexcept (void) throw (); > > >} ># 37 "/usr/include/c++/4.9.0/fenv.h" 2 3 ># 55 "/usr/include/c++/4.9.0/fenv.h" 3 >namespace std >{ > > using ::fenv_t; > using ::fexcept_t; > > > using ::feclearexcept; > using ::fegetexceptflag; > using ::feraiseexcept; > using ::fesetexceptflag; > using ::fetestexcept; > > using ::fegetround; > using ::fesetround; > > using ::fegetenv; > using ::feholdexcept; > using ::fesetenv; > using ::feupdateenv; >} ># 70 "/usr/include/boost/detail/fenv.hpp" 2 3 4 ># 291 "/usr/include/boost/math/tools/config.hpp" 2 3 4 > > > >namespace boost{ namespace math{ > namespace detail > { > struct fpu_guard > { > fpu_guard() > { > fegetexceptflag(&m_flags, (0x20 | 0x04 | 0x10 | 0x08 | 0x01)); > feclearexcept((0x20 | 0x04 | 0x10 | 0x08 | 0x01)); > } > ~fpu_guard() > { > fesetexceptflag(&m_flags, (0x20 | 0x04 | 0x10 | 0x08 | 0x01)); > } > private: > fexcept_t m_flags; > }; > > } > }} ># 17 "/usr/include/boost/math/special_functions/sign.hpp" 2 3 4 ># 1 "/usr/include/boost/math/special_functions/math_fwd.hpp" 1 3 4 ># 26 "/usr/include/boost/math/special_functions/math_fwd.hpp" 3 4 ># 1 "/usr/include/boost/math/special_functions/detail/round_fwd.hpp" 1 3 4 ># 12 "/usr/include/boost/math/special_functions/detail/round_fwd.hpp" 3 4 ># 1 "/usr/include/boost/math/tools/promotion.hpp" 1 3 4 ># 42 "/usr/include/boost/math/tools/promotion.hpp" 3 4 >namespace boost >{ > namespace math > { > namespace tools > { ># 68 "/usr/include/boost/math/tools/promotion.hpp" 3 4 > template <class T> > struct promote_arg > { > typedef typename mpl::if_<is_integral<T>, double, T>::type type; > }; > > > template <> struct promote_arg<float> { typedef float type; }; > template <> struct promote_arg<double>{ typedef double type; }; > template <> struct promote_arg<long double> { typedef long double type; }; > template <> struct promote_arg<int> { typedef double type; }; > > template <class T1, class T2> > struct promote_args_2 > { > > typedef typename promote_arg<T1>::type T1P; > typedef typename promote_arg<T2>::type T2P; > > typedef typename mpl::if_< > typename mpl::and_<is_floating_point<T1P>, is_floating_point<T2P> >::type, > typename mpl::if_< typename mpl::or_<is_same<long double, T1P>, is_same<long double, T2P> >::type, > long double, > typename mpl::if_< typename mpl::or_<is_same<double, T1P>, is_same<double, T2P> >::type, > double, > float > >::type > >::type, > > typename mpl::if_< typename mpl::and_<mpl::not_<is_floating_point<T2P> >, ::boost::is_convertible<T1P, T2P> >, T2P, T1P>::type>::type type; > }; > > > template <> struct promote_args_2<float, float> { typedef float type; }; > template <> struct promote_args_2<double, double>{ typedef double type; }; > template <> struct promote_args_2<long double, long double> { typedef long double type; }; > template <> struct promote_args_2<int, int> { typedef double type; }; > template <> struct promote_args_2<int, float> { typedef double type; }; > template <> struct promote_args_2<float, int> { typedef double type; }; > template <> struct promote_args_2<int, double> { typedef double type; }; > template <> struct promote_args_2<double, int> { typedef double type; }; > template <> struct promote_args_2<int, long double> { typedef long double type; }; > template <> struct promote_args_2<long double, int> { typedef long double type; }; > template <> struct promote_args_2<float, double> { typedef double type; }; > template <> struct promote_args_2<double, float> { typedef double type; }; > template <> struct promote_args_2<float, long double> { typedef long double type; }; > template <> struct promote_args_2<long double, float> { typedef long double type; }; > template <> struct promote_args_2<double, long double> { typedef long double type; }; > template <> struct promote_args_2<long double, double> { typedef long double type; }; > > template <class T1, class T2=float, class T3=float, class T4=float, class T5=float, class T6=float> > struct promote_args > { > typedef typename promote_args_2< > typename remove_cv<T1>::type, > typename promote_args_2< > typename remove_cv<T2>::type, > typename promote_args_2< > typename remove_cv<T3>::type, > typename promote_args_2< > typename remove_cv<T4>::type, > typename promote_args_2< > typename remove_cv<T5>::type, typename remove_cv<T6>::type > >::type > >::type > >::type > >::type > >::type type; > > > > > > > > }; > > > > > > > template <class T1, class T2=float, class T3=float, class T4=float, class T5=float, class T6=float> > struct promote_args_permissive > { > typedef typename promote_args_2< > typename remove_cv<T1>::type, > typename promote_args_2< > typename remove_cv<T2>::type, > typename promote_args_2< > typename remove_cv<T3>::type, > typename promote_args_2< > typename remove_cv<T4>::type, > typename promote_args_2< > typename remove_cv<T5>::type, typename remove_cv<T6>::type > >::type > >::type > >::type > >::type > >::type type; > }; > > } > } >} ># 13 "/usr/include/boost/math/special_functions/detail/round_fwd.hpp" 2 3 4 > > > > > >namespace boost >{ > namespace math > { > > template <class T, class Policy> > typename tools::promote_args<T>::type trunc(const T& v, const Policy& pol); > template <class T> > typename tools::promote_args<T>::type trunc(const T& v); > template <class T, class Policy> > int itrunc(const T& v, const Policy& pol); > template <class T> > int itrunc(const T& v); > template <class T, class Policy> > long ltrunc(const T& v, const Policy& pol); > template <class T> > long ltrunc(const T& v); > > template <class T, class Policy> > boost::long_long_type lltrunc(const T& v, const Policy& pol); > template <class T> > boost::long_long_type lltrunc(const T& v); > > template <class T, class Policy> > typename tools::promote_args<T>::type round(const T& v, const Policy& pol); > template <class T> > typename tools::promote_args<T>::type round(const T& v); > template <class T, class Policy> > int iround(const T& v, const Policy& pol); > template <class T> > int iround(const T& v); > template <class T, class Policy> > long lround(const T& v, const Policy& pol); > template <class T> > long lround(const T& v); > > template <class T, class Policy> > boost::long_long_type llround(const T& v, const Policy& pol); > template <class T> > boost::long_long_type llround(const T& v); > > template <class T, class Policy> > T modf(const T& v, T* ipart, const Policy& pol); > template <class T> > T modf(const T& v, T* ipart); > template <class T, class Policy> > T modf(const T& v, int* ipart, const Policy& pol); > template <class T> > T modf(const T& v, int* ipart); > template <class T, class Policy> > T modf(const T& v, long* ipart, const Policy& pol); > template <class T> > T modf(const T& v, long* ipart); > > template <class T, class Policy> > T modf(const T& v, boost::long_long_type* ipart, const Policy& pol); > template <class T> > T modf(const T& v, boost::long_long_type* ipart); > > > } >} ># 27 "/usr/include/boost/math/special_functions/math_fwd.hpp" 2 3 4 > ># 1 "/usr/include/boost/math/policies/policy.hpp" 1 3 4 ># 9 "/usr/include/boost/math/policies/policy.hpp" 3 4 ># 1 "/usr/include/boost/mpl/list.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/list.hpp" 3 4 ># 1 "/usr/include/boost/mpl/limits/list.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/list.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/list.hpp" 3 4 ># 1 "/usr/include/boost/mpl/list/list20.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/list/list20.hpp" 3 4 ># 1 "/usr/include/boost/mpl/list/list10.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/list/list10.hpp" 3 4 ># 1 "/usr/include/boost/mpl/list/list0.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/list0.hpp" 3 4 ># 1 "/usr/include/boost/mpl/long.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/long.hpp" 3 4 ># 1 "/usr/include/boost/mpl/long_fwd.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/long_fwd.hpp" 3 4 >namespace mpl_ { > >template< long N > struct long_; > >} >namespace boost { namespace mpl { using ::mpl_::long_; } } ># 18 "/usr/include/boost/mpl/long.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 1 3 4 ># 40 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 3 4 >namespace mpl_ { > >template< long N > >struct long_ >{ > static const long value = N; > > > > > > typedef long_ type; > > typedef long value_type; > typedef integral_c_tag tag; ># 72 "/usr/include/boost/mpl/aux_/integral_wrapper.hpp" 3 4 > typedef mpl_::long_< static_cast<long>((value + 1)) > next; > typedef mpl_::long_< static_cast<long>((value - 1)) > prior; > > > > > > > operator long() const { return static_cast<long>(this->value); } >}; > > >template< long N > >long const mpl_::long_< N >::value; > > >} ># 21 "/usr/include/boost/mpl/long.hpp" 2 3 4 ># 18 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/list/aux_/push_front.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/push_front.hpp" 3 4 ># 1 "/usr/include/boost/mpl/push_front_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/push_front_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct push_front_impl; >template< typename Sequence, typename T > struct push_front; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/push_front.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/list/aux_/item.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/list/aux_/item.hpp" 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/tag.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/tag.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >struct list_tag; >struct l_iter_tag; > >}}} ># 19 "/usr/include/boost/mpl/list/aux_/item.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< > typename Size > , typename T > , typename Next > > >struct l_item >{ > > > > > typedef aux::list_tag tag; > typedef l_item type; > > typedef Size size; > typedef T item; > typedef Next next; >}; > >struct l_end >{ > > > > typedef aux::list_tag tag; > typedef l_end type; > typedef long_<0> size; >}; > >}} ># 20 "/usr/include/boost/mpl/list/aux_/push_front.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template<> >struct push_front_impl< aux::list_tag > >{ > template< typename List, typename T > struct apply > { > typedef l_item< > typename next<typename List::size>::type > , T > , typename List::type > > type; > }; >}; > >}} ># 20 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/pop_front.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/pop_front.hpp" 3 4 ># 1 "/usr/include/boost/mpl/pop_front_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/pop_front_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct pop_front_impl; >template< typename Sequence > struct pop_front; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/pop_front.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template<> >struct pop_front_impl< aux::list_tag > >{ > template< typename List > struct apply > { > typedef typename mpl::next<List>::type type; > }; >}; > >}} ># 21 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/push_back.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/push_back.hpp" 3 4 ># 1 "/usr/include/boost/mpl/push_back_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/push_back_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct push_back_impl; >template< typename Sequence, typename T > struct push_back; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/push_back.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< typename Tag > struct has_push_back_impl; > >template<> >struct has_push_back_impl< aux::list_tag > >{ > template< typename Seq > struct apply > : false_ > { > }; >}; > >}} ># 22 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/front.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/front.hpp" 3 4 ># 1 "/usr/include/boost/mpl/front_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/front_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct front_impl; >template< typename Sequence > struct front; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/front.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template<> >struct front_impl< aux::list_tag > >{ > template< typename List > struct apply > { > typedef typename List::item type; > }; >}; > >}} ># 23 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/clear.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/clear.hpp" 3 4 ># 1 "/usr/include/boost/mpl/clear_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/clear_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct clear_impl; >template< typename Sequence > struct clear; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/clear.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template<> >struct clear_impl< aux::list_tag > >{ > template< typename List > struct apply > { > typedef l_end type; > }; >}; > >}} ># 24 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/O1_size.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/O1_size.hpp" 3 4 ># 1 "/usr/include/boost/mpl/O1_size_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/O1_size_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct O1_size_impl; >template< typename Sequence > struct O1_size; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/O1_size.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template<> >struct O1_size_impl< aux::list_tag > >{ > template< typename List > struct apply > : List::size > { > }; >}; > >}} ># 25 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/size.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/size.hpp" 3 4 ># 1 "/usr/include/boost/mpl/size_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/size_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct size_impl; >template< typename Sequence > struct size; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/size.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template<> >struct size_impl< aux::list_tag > >{ > template< typename List > struct apply > : List::size > { > }; >}; > >}} ># 26 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/empty.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/empty.hpp" 3 4 ># 1 "/usr/include/boost/mpl/empty_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/empty_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct empty_impl; >template< typename Sequence > struct empty; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/empty.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template<> >struct empty_impl< aux::list_tag > >{ > template< typename List > struct apply > : not_<typename List::size> > { > }; >}; > >}} ># 27 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/begin_end.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/begin_end.hpp" 3 4 ># 1 "/usr/include/boost/mpl/begin_end_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/begin_end_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct begin_impl; >template< typename Tag > struct end_impl; > >template< typename Sequence > struct begin; >template< typename Sequence > struct end; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/begin_end.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/iterator.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/list/aux_/iterator.hpp" 3 4 ># 1 "/usr/include/boost/mpl/iterator_tags.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/iterator_tags.hpp" 3 4 >namespace boost { namespace mpl { > >struct forward_iterator_tag : int_<0> { typedef forward_iterator_tag type; }; >struct bidirectional_iterator_tag : int_<1> { typedef bidirectional_iterator_tag type; }; >struct random_access_iterator_tag : int_<2> { typedef random_access_iterator_tag type; }; > >}} ># 18 "/usr/include/boost/mpl/list/aux_/iterator.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/deref.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/deref.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/msvc_type.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/msvc_type.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { ># 48 "/usr/include/boost/mpl/aux_/msvc_type.hpp" 3 4 >template< typename T > struct msvc_type >{ > typedef typename T::type type; >}; > >template<> struct msvc_type<int> >{ > typedef int type; >}; > > > >}}} ># 18 "/usr/include/boost/mpl/deref.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > >template< > typename Iterator = na > > >struct deref >{ > > typedef typename Iterator::type type; > > > > >}; > >template<> struct deref< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : deref< T1 > { }; }; template< typename Tag > struct lambda< deref< na > , Tag , int_<-1> > { typedef false_ is_le; typedef deref< na > result_; typedef deref< na > type; }; namespace aux { template< typename T1 > struct template_arity< deref< T1 > > : int_<1> { }; template<> struct template_arity< deref< na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/list/aux_/iterator.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/aux_/lambda_spec.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/list/aux_/iterator.hpp" 2 3 4 > > >namespace boost { namespace mpl { > > > >template< typename Node > >struct l_iter >{ > typedef aux::l_iter_tag tag; > typedef forward_iterator_tag category; >}; > >template< typename Node > >struct deref< l_iter<Node> > >{ > typedef typename Node::item type; >}; > >template< typename Node > >struct next< l_iter<Node> > >{ > typedef l_iter< typename Node::next > type; >}; ># 62 "/usr/include/boost/mpl/list/aux_/iterator.hpp" 3 4 >template<> struct l_iter<l_end> >{ > typedef aux::l_iter_tag tag; > typedef forward_iterator_tag category; > > > > >}; > >template< typename T1 , typename Tag > struct lambda< l_iter< T1 > , Tag , int_<1> > { typedef false_ is_le; typedef l_iter< T1 > result_; typedef result_ type; }; > >}} ># 19 "/usr/include/boost/mpl/list/aux_/begin_end.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template<> >struct begin_impl< aux::list_tag > >{ > template< typename List > struct apply > { > typedef l_iter<typename List::type> type; > }; >}; > >template<> >struct end_impl< aux::list_tag > >{ > template< typename > struct apply > { > typedef l_iter<l_end> type; > }; >}; > >}} ># 28 "/usr/include/boost/mpl/list/list0.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template< typename Dummy = na > struct list0; > >template<> struct list0<na> > : l_end >{ > typedef l_end type; >}; > >}} ># 19 "/usr/include/boost/mpl/list/list10.hpp" 2 3 4 ># 27 "/usr/include/boost/mpl/list/list10.hpp" 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/include_preprocessed.hpp" 1 3 4 ># 30 "/usr/include/boost/mpl/list/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/preprocessed/plain/list10.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/list/aux_/preprocessed/plain/list10.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T0 > > >struct list1 > : l_item< > long_<1> > , T0 > , l_end > > >{ > typedef list1 type; >}; > >template< > typename T0, typename T1 > > >struct list2 > : l_item< > long_<2> > , T0 > , list1<T1> > > >{ > typedef list2 type; >}; > >template< > typename T0, typename T1, typename T2 > > >struct list3 > : l_item< > long_<3> > , T0 > , list2< T1,T2 > > > >{ > typedef list3 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3 > > >struct list4 > : l_item< > long_<4> > , T0 > , list3< T1,T2,T3 > > > >{ > typedef list4 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > > >struct list5 > : l_item< > long_<5> > , T0 > , list4< T1,T2,T3,T4 > > > >{ > typedef list5 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct list6 > : l_item< > long_<6> > , T0 > , list5< T1,T2,T3,T4,T5 > > > >{ > typedef list6 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6 > > >struct list7 > : l_item< > long_<7> > , T0 > , list6< T1,T2,T3,T4,T5,T6 > > > >{ > typedef list7 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7 > > >struct list8 > : l_item< > long_<8> > , T0 > , list7< T1,T2,T3,T4,T5,T6,T7 > > > >{ > typedef list8 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8 > > >struct list9 > : l_item< > long_<9> > , T0 > , list8< T1,T2,T3,T4,T5,T6,T7,T8 > > > >{ > typedef list9 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > > >struct list10 > : l_item< > long_<10> > , T0 > , list9< T1,T2,T3,T4,T5,T6,T7,T8,T9 > > > >{ > typedef list10 type; >}; > >}} ># 31 "/usr/include/boost/mpl/list/aux_/include_preprocessed.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/list/list10.hpp" 2 3 4 ># 19 "/usr/include/boost/mpl/list/list20.hpp" 2 3 4 ># 27 "/usr/include/boost/mpl/list/list20.hpp" 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/include_preprocessed.hpp" 1 3 4 ># 30 "/usr/include/boost/mpl/list/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/list/aux_/preprocessed/plain/list20.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/list/aux_/preprocessed/plain/list20.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10 > > >struct list11 > : l_item< > long_<11> > , T0 > , list10< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10 > > > >{ > typedef list11 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11 > > >struct list12 > : l_item< > long_<12> > , T0 > , list11< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11 > > > >{ > typedef list12 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12 > > >struct list13 > : l_item< > long_<13> > , T0 > , list12< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12 > > > >{ > typedef list13 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13 > > >struct list14 > : l_item< > long_<14> > , T0 > , list13< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13 > > > >{ > typedef list14 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > > >struct list15 > : l_item< > long_<15> > , T0 > , list14< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14 > > > >{ > typedef list15 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15 > > >struct list16 > : l_item< > long_<16> > , T0 > , list15< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15 > > > >{ > typedef list16 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16 > > >struct list17 > : l_item< > long_<17> > , T0 > , list16< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16 > > > >{ > typedef list17 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17 > > >struct list18 > : l_item< > long_<18> > , T0 > , list17< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17 > > > >{ > typedef list18 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17, typename T18 > > >struct list19 > : l_item< > long_<19> > , T0 > , list18< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18 > > > >{ > typedef list19 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17, typename T18, typename T19 > > >struct list20 > : l_item< > long_<20> > , T0 > , list19< T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19 > > > >{ > typedef list20 type; >}; > >}} ># 31 "/usr/include/boost/mpl/list/aux_/include_preprocessed.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/list/list20.hpp" 2 3 4 ># 37 "/usr/include/boost/mpl/list.hpp" 2 3 4 ># 46 "/usr/include/boost/mpl/list.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/list.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/list.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T0 = na, typename T1 = na, typename T2 = na, typename T3 = na > , typename T4 = na, typename T5 = na, typename T6 = na, typename T7 = na > , typename T8 = na, typename T9 = na, typename T10 = na, typename T11 = na > , typename T12 = na, typename T13 = na, typename T14 = na > , typename T15 = na, typename T16 = na, typename T17 = na > , typename T18 = na, typename T19 = na > > >struct list; > >template< > > > >struct list< > na, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : list0< > >{ > typedef list0< >::type type; >}; > >template< > typename T0 > > >struct list< > T0, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : list1<T0> >{ > typedef typename list1<T0>::type type; >}; > >template< > typename T0, typename T1 > > >struct list< > T0, T1, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : list2< T0,T1 > >{ > typedef typename list2< T0,T1 >::type type; >}; > >template< > typename T0, typename T1, typename T2 > > >struct list< > T0, T1, T2, na, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : list3< T0,T1,T2 > >{ > typedef typename list3< T0,T1,T2 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3 > > >struct list< > T0, T1, T2, T3, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : list4< T0,T1,T2,T3 > >{ > typedef typename list4< T0,T1,T2,T3 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > > >struct list< > T0, T1, T2, T3, T4, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : list5< T0,T1,T2,T3,T4 > >{ > typedef typename list5< T0,T1,T2,T3,T4 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct list< > T0, T1, T2, T3, T4, T5, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : list6< T0,T1,T2,T3,T4,T5 > >{ > typedef typename list6< T0,T1,T2,T3,T4,T5 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : list7< T0,T1,T2,T3,T4,T5,T6 > >{ > typedef typename list7< T0,T1,T2,T3,T4,T5,T6 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, na, na, na, na, na, na, na, na, na > , na, na, na > > > : list8< T0,T1,T2,T3,T4,T5,T6,T7 > >{ > typedef typename list8< T0,T1,T2,T3,T4,T5,T6,T7 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, na, na, na, na, na, na, na, na > , na, na, na > > > : list9< T0,T1,T2,T3,T4,T5,T6,T7,T8 > >{ > typedef typename list9< T0,T1,T2,T3,T4,T5,T6,T7,T8 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, na, na, na, na, na, na, na > , na, na, na > > > : list10< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9 > >{ > typedef typename list10< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, na, na, na, na, na, na > , na, na, na > > > : list11< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10 > >{ > typedef typename list11< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, na, na, na, na > , na, na, na, na > > > : list12< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11 > >{ > typedef typename list12< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, na, na, na > , na, na, na, na > > > : list13< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12 > >{ > typedef typename list13< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, na, na > , na, na, na, na > > > : list14< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13 > >{ > typedef typename list14< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, na > , na, na, na, na > > > : list15< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > > >{ > typedef typename list15< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, na, na, na, na > > > : list16< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15 > > >{ > typedef typename list16< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, na, na, na > > > : list17< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16 > > >{ > typedef typename list17< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17, na, na > > > : list18< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17 > > >{ > typedef typename list18< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17, typename T18 > > >struct list< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17, T18, na > > > : list19< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17, T18 > > >{ > typedef typename list19< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18 >::type type; >}; > > > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17, typename T18, typename T19 > > >struct list > : list20< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17, T18, T19 > > >{ > typedef typename list20< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19 >::type type; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 47 "/usr/include/boost/mpl/list.hpp" 2 3 4 ># 10 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/contains.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/contains.hpp" 3 4 ># 1 "/usr/include/boost/mpl/contains_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/contains_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct contains_impl; >template< typename Sequence, typename T > struct contains; > >}} ># 19 "/usr/include/boost/mpl/contains.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/sequence_tag.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/sequence_tag.hpp" 3 4 ># 1 "/usr/include/boost/mpl/sequence_tag_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/sequence_tag_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >struct nested_begin_end_tag; >struct non_sequence_tag; > >template< typename Sequence > struct sequence_tag; > >}} ># 18 "/usr/include/boost/mpl/sequence_tag.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/aux_/has_begin.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/has_begin.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { >template< typename T, typename fallback_ = boost::mpl::bool_<true> > struct has_begin { struct gcc_3_2_wknd { template< typename U > static boost::mpl::aux::yes_tag test( boost::mpl::aux::type_wrapper<U> const volatile* , boost::mpl::aux::type_wrapper<typename U::begin>* = 0 ); static boost::mpl::aux::no_tag test(...); }; typedef boost::mpl::aux::type_wrapper<T> t_; static const bool value = sizeof(gcc_3_2_wknd::test(static_cast<t_*>(0))) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_<value> type; }; >}}} ># 20 "/usr/include/boost/mpl/sequence_tag.hpp" 2 3 4 > > > > > > >namespace boost { namespace mpl { ># 78 "/usr/include/boost/mpl/sequence_tag.hpp" 3 4 >namespace aux { > >template< bool has_tag_, bool has_begin_ > >struct sequence_tag_impl >{ > > > template< typename Sequence > struct result2_; >}; ># 98 "/usr/include/boost/mpl/sequence_tag.hpp" 3 4 >template<> struct sequence_tag_impl<true,true> { template< typename Sequence > struct result2_ { typedef typename Sequence::tag type; }; }; >template<> struct sequence_tag_impl<true,false> { template< typename Sequence > struct result2_ { typedef typename Sequence::tag type; }; }; >template<> struct sequence_tag_impl<false,true> { template< typename Sequence > struct result2_ { typedef nested_begin_end_tag type; }; }; >template<> struct sequence_tag_impl<false,false> { template< typename Sequence > struct result2_ { typedef non_sequence_tag type; }; }; > > > >} > >template< > typename Sequence = na > > >struct sequence_tag > : aux::sequence_tag_impl< > ::boost::mpl::aux::has_tag<Sequence>::value > , ::boost::mpl::aux::has_begin<Sequence>::value > >::template result2_<Sequence> >{ >}; > > > >template<> struct sequence_tag< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : sequence_tag< T1 > { }; }; template< typename Tag > struct lambda< sequence_tag< na > , Tag , int_<-1> > { typedef false_ is_le; typedef sequence_tag< na > result_; typedef sequence_tag< na > type; }; namespace aux { template< typename T1 > struct template_arity< sequence_tag< T1 > > : int_<1> { }; template<> struct template_arity< sequence_tag< na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/contains.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/contains_impl.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/contains_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/begin_end.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/begin_end.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/begin_end_impl.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/begin_end_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/traits_lambda_spec.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/aux_/begin_end_impl.hpp" 2 3 4 > > >namespace boost { namespace mpl { > > >namespace aux { > >template< typename Sequence > >struct begin_type >{ > typedef typename Sequence::begin type; >}; >template< typename Sequence > >struct end_type >{ > typedef typename Sequence::end type; >}; > >} > > > > > >template< typename Tag > >struct begin_impl >{ > template< typename Sequence > struct apply > { > typedef typename eval_if<aux::has_begin<Sequence, true_>, > aux::begin_type<Sequence>, void_>::type type; > }; >}; > >template< typename Tag > >struct end_impl >{ > template< typename Sequence > struct apply > { > typedef typename eval_if<aux::has_begin<Sequence, true_>, > aux::end_type<Sequence>, void_>::type type; > }; >}; ># 82 "/usr/include/boost/mpl/aux_/begin_end_impl.hpp" 3 4 >template<> struct begin_impl<nested_begin_end_tag> { template< typename Sequence > struct apply { typedef typename Sequence::begin type; }; }; >template<> struct end_impl<nested_begin_end_tag> { template< typename Sequence > struct apply { typedef typename Sequence::end type; }; }; > > > > >template<> struct begin_impl<non_sequence_tag> { template< typename Sequence > struct apply { typedef void_ type; }; }; >template<> struct end_impl<non_sequence_tag> { template< typename Sequence > struct apply { typedef void_ type; }; }; >template<> struct begin_impl<na> { template< typename Sequence > struct apply { typedef void_ type; }; }; >template<> struct end_impl<na> { template< typename Sequence > struct apply { typedef void_ type; }; }; > > > > > > > >}} ># 19 "/usr/include/boost/mpl/begin_end.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > > > > >template< > typename Sequence = na > > >struct begin >{ > typedef typename sequence_tag<Sequence>::type tag_; > typedef typename begin_impl< tag_ > > ::template apply< Sequence >::type type; > > >}; > >template< > typename Sequence = na > > >struct end >{ > typedef typename sequence_tag<Sequence>::type tag_; > typedef typename end_impl< tag_ > > ::template apply< Sequence >::type type; > > >}; > >template<> struct begin< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : begin< T1 > { }; }; template< typename Tag > struct lambda< begin< na > , Tag , int_<-1> > { typedef false_ is_le; typedef begin< na > result_; typedef begin< na > type; }; namespace aux { template< typename T1 > struct template_arity< begin< T1 > > : int_<1> { }; template<> struct template_arity< begin< na > > : int_<-1> { }; } >template<> struct end< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : end< T1 > { }; }; template< typename Tag > struct lambda< end< na > , Tag , int_<-1> > { typedef false_ is_le; typedef end< na > result_; typedef end< na > type; }; namespace aux { template< typename T1 > struct template_arity< end< T1 > > : int_<1> { }; template<> struct template_arity< end< na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/aux_/contains_impl.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/find.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/find.hpp" 3 4 ># 1 "/usr/include/boost/mpl/find_if.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/find_if.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/find_if_pred.hpp" 1 3 4 ># 14 "/usr/include/boost/mpl/aux_/find_if_pred.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/iter_apply.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/iter_apply.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/iter_apply.hpp" 2 3 4 > > >namespace boost { namespace mpl { namespace aux { > >template< > typename F > , typename Iterator > > >struct iter_apply1 > : apply1< F,typename deref<Iterator>::type > >{ >}; > >template< > typename F > , typename Iterator1 > , typename Iterator2 > > >struct iter_apply2 > : apply2< > F > , typename deref<Iterator1>::type > , typename deref<Iterator2>::type > > >{ >}; > >}}} ># 15 "/usr/include/boost/mpl/aux_/find_if_pred.hpp" 2 3 4 > > >namespace boost { namespace mpl { namespace aux { > >template< typename Predicate > >struct find_if_pred >{ > template< typename Iterator > > struct apply > { > typedef not_< aux::iter_apply1<Predicate,Iterator> > type; > }; >}; > >}}} ># 18 "/usr/include/boost/mpl/find_if.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/arg.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/find_if.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/iter_fold_if.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/iter_fold_if.hpp" 3 4 ># 1 "/usr/include/boost/mpl/pair.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/pair.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T1 = na > , typename T2 = na > > >struct pair >{ > typedef pair type; > typedef T1 first; > typedef T2 second; > > >}; > >template< > typename P = na > > >struct first >{ > > typedef typename P::first type; > > > > >}; > >template< > typename P = na > > >struct second >{ > > typedef typename P::second type; > > > > >}; > > >template<> struct pair< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : pair< T1 , T2 > { }; }; template< typename Tag > struct lambda< pair< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef pair< na , na > result_; typedef pair< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< pair< T1 , T2 > > : int_<2> { }; template<> struct template_arity< pair< na , na > > : int_<-1> { }; } >template<> struct first< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : first< T1 > { }; }; template< typename Tag > struct lambda< first< na > , Tag , int_<-1> > { typedef false_ is_le; typedef first< na > result_; typedef first< na > type; }; namespace aux { template< typename T1 > struct template_arity< first< T1 > > : int_<1> { }; template<> struct template_arity< first< na > > : int_<-1> { }; } >template<> struct second< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : second< T1 > { }; }; template< typename Tag > struct lambda< second< na > , Tag , int_<-1> > { typedef false_ is_le; typedef second< na > result_; typedef second< na > type; }; namespace aux { template< typename T1 > struct template_arity< second< T1 > > : int_<1> { }; template<> struct template_arity< second< na > > : int_<-1> { }; } > >}} ># 24 "/usr/include/boost/mpl/iter_fold_if.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/iter_fold_if.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/iter_fold_if_impl.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/iter_fold_if_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/iter_fold_if_impl.hpp" 2 3 4 ># 32 "/usr/include/boost/mpl/aux_/iter_fold_if_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/iter_fold_if_impl.hpp" 1 3 4 ># 13 "/usr/include/boost/mpl/aux_/preprocessed/gcc/iter_fold_if_impl.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >template< typename Iterator, typename State > >struct iter_fold_if_null_step >{ > typedef State state; > typedef Iterator iterator; >}; > >template< bool > >struct iter_fold_if_step_impl >{ > template< > typename Iterator > , typename State > , typename StateOp > , typename IteratorOp > > > struct result_ > { > typedef typename apply2< StateOp,State,Iterator >::type state; > typedef typename IteratorOp::type iterator; > }; >}; > >template<> >struct iter_fold_if_step_impl<false> >{ > template< > typename Iterator > , typename State > , typename StateOp > , typename IteratorOp > > > struct result_ > { > typedef State state; > typedef Iterator iterator; > }; >}; > >template< > typename Iterator > , typename State > , typename ForwardOp > , typename Predicate > > >struct iter_fold_if_forward_step >{ > typedef typename apply2< Predicate,State,Iterator >::type not_last; > typedef typename iter_fold_if_step_impl< > not_last::value > >::template result_< Iterator,State,ForwardOp, mpl::next<Iterator> > impl_; > > typedef typename impl_::state state; > typedef typename impl_::iterator iterator; >}; > >template< > typename Iterator > , typename State > , typename BackwardOp > , typename Predicate > > >struct iter_fold_if_backward_step >{ > typedef typename apply2< Predicate,State,Iterator >::type not_last; > typedef typename iter_fold_if_step_impl< > not_last::value > >::template result_< Iterator,State,BackwardOp, identity<Iterator> > impl_; > > typedef typename impl_::state state; > typedef typename impl_::iterator iterator; >}; > >template< > typename Iterator > , typename State > , typename ForwardOp > , typename ForwardPredicate > , typename BackwardOp > , typename BackwardPredicate > > >struct iter_fold_if_impl >{ > private: > typedef iter_fold_if_null_step< Iterator,State > forward_step0; > typedef iter_fold_if_forward_step< typename forward_step0::iterator, typename forward_step0::state, ForwardOp, ForwardPredicate > forward_step1; > typedef iter_fold_if_forward_step< typename forward_step1::iterator, typename forward_step1::state, ForwardOp, ForwardPredicate > forward_step2; > typedef iter_fold_if_forward_step< typename forward_step2::iterator, typename forward_step2::state, ForwardOp, ForwardPredicate > forward_step3; > typedef iter_fold_if_forward_step< typename forward_step3::iterator, typename forward_step3::state, ForwardOp, ForwardPredicate > forward_step4; > > > typedef typename if_< > typename forward_step4::not_last > , iter_fold_if_impl< > typename forward_step4::iterator > , typename forward_step4::state > , ForwardOp > , ForwardPredicate > , BackwardOp > , BackwardPredicate > > > , iter_fold_if_null_step< > typename forward_step4::iterator > , typename forward_step4::state > > > >::type backward_step4; > > typedef iter_fold_if_backward_step< typename forward_step3::iterator, typename backward_step4::state, BackwardOp, BackwardPredicate > backward_step3; > typedef iter_fold_if_backward_step< typename forward_step2::iterator, typename backward_step3::state, BackwardOp, BackwardPredicate > backward_step2; > typedef iter_fold_if_backward_step< typename forward_step1::iterator, typename backward_step2::state, BackwardOp, BackwardPredicate > backward_step1; > typedef iter_fold_if_backward_step< typename forward_step0::iterator, typename backward_step1::state, BackwardOp, BackwardPredicate > backward_step0; > > > public: > typedef typename backward_step0::state state; > typedef typename backward_step4::iterator iterator; >}; > >}}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 33 "/usr/include/boost/mpl/aux_/iter_fold_if_impl.hpp" 2 3 4 ># 26 "/usr/include/boost/mpl/iter_fold_if.hpp" 2 3 4 > > > > > > > >namespace boost { namespace mpl { > >namespace aux { > >template< typename Predicate, typename LastIterator > >struct iter_fold_if_pred >{ > template< typename State, typename Iterator > struct apply > > : and_< > not_< is_same<Iterator,LastIterator> > > , apply1<Predicate,Iterator> > > > { > > > > > > > > }; >}; > >} > >template< > typename Sequence = na > , typename State = na > , typename ForwardOp = na > , typename ForwardPredicate = na > , typename BackwardOp = na > , typename BackwardPredicate = na > > >struct iter_fold_if >{ > > typedef typename begin<Sequence>::type first_; > typedef typename end<Sequence>::type last_; > > typedef typename eval_if< > is_na<BackwardPredicate> > , if_< is_na<BackwardOp>, always<false_>, always<true_> > > , identity<BackwardPredicate> > >::type backward_pred_; > > > > struct result_ : > > > > aux::iter_fold_if_impl< > first_ > , State > , ForwardOp > , protect< aux::iter_fold_if_pred< ForwardPredicate,last_ > > > , BackwardOp > , backward_pred_ > > > > { }; > > > > >public: > > typedef pair< > typename result_::state > , typename result_::iterator > > type; > > > > > > >}; > >template<> struct iter_fold_if< na , na , na , na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > struct apply : iter_fold_if< T1 , T2 , T3 , T4 , T5 , T6 > { }; }; template< typename Tag > struct lambda< iter_fold_if< na , na , na , na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef iter_fold_if< na , na , na , na , na , na > result_; typedef iter_fold_if< na , na , na , na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 > struct template_arity< iter_fold_if< T1 , T2 , T3 , T4 , T5 , T6 > > : int_<6> { }; template<> struct template_arity< iter_fold_if< na , na , na , na , na , na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/find_if.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > > > >template< > typename Sequence = na > , typename Predicate = na > > >struct find_if >{ > typedef typename iter_fold_if< > Sequence > , void > , mpl::arg<1> > , protect< aux::find_if_pred<Predicate> > > >::type result_; > > typedef typename second<result_>::type type; > > >}; > >template<> struct find_if< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : find_if< T1 , T2 > { }; }; template< typename Tag > struct lambda< find_if< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef find_if< na , na > result_; typedef find_if< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< find_if< T1 , T2 > > : int_<2> { }; template<> struct template_arity< find_if< na , na > > : int_<-1> { }; } > >}} ># 18 "/usr/include/boost/mpl/find.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/same_as.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/same_as.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename T1 > >struct same_as >{ > template< typename T2 > struct apply > > : is_same<T1,T2> > { > > > > > }; >}; > >template< typename T1 > >struct not_same_as >{ > template< typename T2 > struct apply > > : not_< is_same<T1,T2> > > { > > > > > }; >}; > >}} ># 19 "/usr/include/boost/mpl/find.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > , typename T = na > > >struct find > : find_if< Sequence,same_as<T> > >{ > >}; > >template<> struct find< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : find< T1 , T2 > { }; }; template< typename Tag > struct lambda< find< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef find< na , na > result_; typedef find< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< find< T1 , T2 > > : int_<2> { }; template<> struct template_arity< find< na , na > > : int_<-1> { }; } > >}} ># 21 "/usr/include/boost/mpl/aux_/contains_impl.hpp" 2 3 4 > > > > > > > >namespace boost { namespace mpl { > >template< typename Tag > >struct contains_impl >{ > template< typename Sequence, typename T > struct apply > > : not_< is_same< > typename find<Sequence,T>::type > , typename end<Sequence>::type > > > > { ># 54 "/usr/include/boost/mpl/aux_/contains_impl.hpp" 3 4 > }; >}; > > template<> struct contains_impl<non_sequence_tag> {}; > >}} ># 21 "/usr/include/boost/mpl/contains.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > , typename T = na > > >struct contains > : contains_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence,T > >{ > >}; > >template<> struct contains< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : contains< T1 , T2 > { }; }; template< typename Tag > struct lambda< contains< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef contains< na , na > result_; typedef contains< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< contains< T1 , T2 > > : int_<2> { }; template<> struct template_arity< contains< na , na > > : int_<-1> { }; } > >}} ># 11 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/remove_if.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/remove_if.hpp" 3 4 ># 1 "/usr/include/boost/mpl/fold.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/fold.hpp" 3 4 ># 1 "/usr/include/boost/mpl/O1_size.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/O1_size.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/O1_size_impl.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/O1_size_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/has_size.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/has_size.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { >template< typename T, typename fallback_ = boost::mpl::bool_<false> > struct has_size { struct gcc_3_2_wknd { template< typename U > static boost::mpl::aux::yes_tag test( boost::mpl::aux::type_wrapper<U> const volatile* , boost::mpl::aux::type_wrapper<typename U::size>* = 0 ); static boost::mpl::aux::no_tag test(...); }; typedef boost::mpl::aux::type_wrapper<T> t_; static const bool value = sizeof(gcc_3_2_wknd::test(static_cast<t_*>(0))) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_<value> type; }; >}}} ># 21 "/usr/include/boost/mpl/aux_/O1_size_impl.hpp" 2 3 4 > > > > > >namespace boost { namespace mpl { ># 35 "/usr/include/boost/mpl/aux_/O1_size_impl.hpp" 3 4 >namespace aux { >template< typename Sequence > struct O1_size_impl > : Sequence::size >{ >}; >} > >template< typename Tag > >struct O1_size_impl >{ > template< typename Sequence > struct apply > > : if_< > aux::has_size<Sequence> > , aux::O1_size_impl<Sequence> > , long_<-1> > >::type > { ># 69 "/usr/include/boost/mpl/aux_/O1_size_impl.hpp" 3 4 > }; >}; ># 85 "/usr/include/boost/mpl/aux_/O1_size_impl.hpp" 3 4 >}} ># 20 "/usr/include/boost/mpl/O1_size.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > > >template< > typename Sequence = na > > >struct O1_size > : O1_size_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence > >{ > >}; > >template<> struct O1_size< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : O1_size< T1 > { }; }; template< typename Tag > struct lambda< O1_size< na > , Tag , int_<-1> > { typedef false_ is_le; typedef O1_size< na > result_; typedef O1_size< na > type; }; namespace aux { template< typename T1 > struct template_arity< O1_size< T1 > > : int_<1> { }; template<> struct template_arity< O1_size< na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/fold.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/fold_impl.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/fold_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/fold_impl.hpp" 2 3 4 ># 34 "/usr/include/boost/mpl/aux_/fold_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/fold_impl.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/fold_impl.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > > > >template< > int N > , typename First > , typename Last > , typename State > , typename ForwardOp > > >struct fold_impl; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct fold_impl< 0,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef state0 state; > typedef iter0 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct fold_impl< 1,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef typename apply2< ForwardOp, state0, typename deref<iter0>::type >::type state1; > typedef typename mpl::next<iter0>::type iter1; > > > typedef state1 state; > typedef iter1 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct fold_impl< 2,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef typename apply2< ForwardOp, state0, typename deref<iter0>::type >::type state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp, state1, typename deref<iter1>::type >::type state2; > typedef typename mpl::next<iter1>::type iter2; > > > typedef state2 state; > typedef iter2 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct fold_impl< 3,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef typename apply2< ForwardOp, state0, typename deref<iter0>::type >::type state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp, state1, typename deref<iter1>::type >::type state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp, state2, typename deref<iter2>::type >::type state3; > typedef typename mpl::next<iter2>::type iter3; > > > typedef state3 state; > typedef iter3 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct fold_impl< 4,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef typename apply2< ForwardOp, state0, typename deref<iter0>::type >::type state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp, state1, typename deref<iter1>::type >::type state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp, state2, typename deref<iter2>::type >::type state3; > typedef typename mpl::next<iter2>::type iter3; > typedef typename apply2< ForwardOp, state3, typename deref<iter3>::type >::type state4; > typedef typename mpl::next<iter3>::type iter4; > > > typedef state4 state; > typedef iter4 iterator; >}; > >template< > int N > , typename First > , typename Last > , typename State > , typename ForwardOp > > >struct fold_impl >{ > typedef fold_impl< > 4 > , First > , Last > , State > , ForwardOp > > chunk_; > > typedef fold_impl< > ( (N - 4) < 0 ? 0 : N - 4 ) > , typename chunk_::iterator > , Last > , typename chunk_::state > , ForwardOp > > res_; > > typedef typename res_::state state; > typedef typename res_::iterator iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct fold_impl< -1,First,Last,State,ForwardOp > > : fold_impl< > -1 > , typename mpl::next<First>::type > , Last > , typename apply2<ForwardOp,State, typename deref<First>::type>::type > , ForwardOp > > >{ >}; > >template< > typename Last > , typename State > , typename ForwardOp > > >struct fold_impl< -1,Last,Last,State,ForwardOp > >{ > typedef State state; > typedef Last iterator; >}; > >}}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 35 "/usr/include/boost/mpl/aux_/fold_impl.hpp" 2 3 4 ># 21 "/usr/include/boost/mpl/fold.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > , typename State = na > , typename ForwardOp = na > > >struct fold >{ > typedef typename aux::fold_impl< > ::boost::mpl::O1_size<Sequence>::value > , typename begin<Sequence>::type > , typename end<Sequence>::type > , State > , ForwardOp > >::state type; > > >}; > >template<> struct fold< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : fold< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< fold< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef fold< na , na , na > result_; typedef fold< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< fold< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< fold< na , na , na > > : int_<-1> { }; } > >}} ># 19 "/usr/include/boost/mpl/remove_if.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/reverse_fold.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/reverse_fold.hpp" 3 4 ># 1 "/usr/include/boost/mpl/arg.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/reverse_fold.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/reverse_fold_impl.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/reverse_fold_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/aux_/reverse_fold_impl.hpp" 2 3 4 ># 35 "/usr/include/boost/mpl/aux_/reverse_fold_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/reverse_fold_impl.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/reverse_fold_impl.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > > > >template< > long N > , typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_fold_impl; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_fold_impl< 0,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef fwd_state0 bkwd_state0; > typedef bkwd_state0 state; > typedef iter0 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_fold_impl< 1,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp, fwd_state0, typename deref<iter0>::type >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > > > typedef fwd_state1 bkwd_state1; > typedef typename apply2< BackwardOp, bkwd_state1, typename deref<iter0>::type >::type bkwd_state0; > typedef bkwd_state0 state; > typedef iter1 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_fold_impl< 2,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp, fwd_state0, typename deref<iter0>::type >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp, fwd_state1, typename deref<iter1>::type >::type fwd_state2; > typedef typename mpl::next<iter1>::type iter2; > > > typedef fwd_state2 bkwd_state2; > typedef typename apply2< BackwardOp, bkwd_state2, typename deref<iter1>::type >::type bkwd_state1; > typedef typename apply2< BackwardOp, bkwd_state1, typename deref<iter0>::type >::type bkwd_state0; > > > typedef bkwd_state0 state; > typedef iter2 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_fold_impl< 3,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp, fwd_state0, typename deref<iter0>::type >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp, fwd_state1, typename deref<iter1>::type >::type fwd_state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp, fwd_state2, typename deref<iter2>::type >::type fwd_state3; > typedef typename mpl::next<iter2>::type iter3; > > > typedef fwd_state3 bkwd_state3; > typedef typename apply2< BackwardOp, bkwd_state3, typename deref<iter2>::type >::type bkwd_state2; > typedef typename apply2< BackwardOp, bkwd_state2, typename deref<iter1>::type >::type bkwd_state1; > typedef typename apply2< BackwardOp, bkwd_state1, typename deref<iter0>::type >::type bkwd_state0; > > > typedef bkwd_state0 state; > typedef iter3 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_fold_impl< 4,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp, fwd_state0, typename deref<iter0>::type >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp, fwd_state1, typename deref<iter1>::type >::type fwd_state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp, fwd_state2, typename deref<iter2>::type >::type fwd_state3; > typedef typename mpl::next<iter2>::type iter3; > typedef typename apply2< ForwardOp, fwd_state3, typename deref<iter3>::type >::type fwd_state4; > typedef typename mpl::next<iter3>::type iter4; > > > typedef fwd_state4 bkwd_state4; > typedef typename apply2< BackwardOp, bkwd_state4, typename deref<iter3>::type >::type bkwd_state3; > typedef typename apply2< BackwardOp, bkwd_state3, typename deref<iter2>::type >::type bkwd_state2; > typedef typename apply2< BackwardOp, bkwd_state2, typename deref<iter1>::type >::type bkwd_state1; > typedef typename apply2< BackwardOp, bkwd_state1, typename deref<iter0>::type >::type bkwd_state0; > > > typedef bkwd_state0 state; > typedef iter4 iterator; >}; > >template< > long N > , typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_fold_impl >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp, fwd_state0, typename deref<iter0>::type >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp, fwd_state1, typename deref<iter1>::type >::type fwd_state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp, fwd_state2, typename deref<iter2>::type >::type fwd_state3; > typedef typename mpl::next<iter2>::type iter3; > typedef typename apply2< ForwardOp, fwd_state3, typename deref<iter3>::type >::type fwd_state4; > typedef typename mpl::next<iter3>::type iter4; > > > typedef reverse_fold_impl< > ( (N - 4) < 0 ? 0 : N - 4 ) > , iter4 > , Last > , fwd_state4 > , BackwardOp > , ForwardOp > > nested_chunk; > > typedef typename nested_chunk::state bkwd_state4; > typedef typename apply2< BackwardOp, bkwd_state4, typename deref<iter3>::type >::type bkwd_state3; > typedef typename apply2< BackwardOp, bkwd_state3, typename deref<iter2>::type >::type bkwd_state2; > typedef typename apply2< BackwardOp, bkwd_state2, typename deref<iter1>::type >::type bkwd_state1; > typedef typename apply2< BackwardOp, bkwd_state1, typename deref<iter0>::type >::type bkwd_state0; > > > typedef bkwd_state0 state; > typedef typename nested_chunk::iterator iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_fold_impl< -1,First,Last,State,BackwardOp,ForwardOp > >{ > typedef reverse_fold_impl< > -1 > , typename mpl::next<First>::type > , Last > , typename apply2<ForwardOp,State, typename deref<First>::type>::type > , BackwardOp > , ForwardOp > > nested_step; > > typedef typename apply2< > BackwardOp > , typename nested_step::state > , typename deref<First>::type > >::type state; > > typedef typename nested_step::iterator iterator; >}; > >template< > typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_fold_impl< -1,Last,Last,State,BackwardOp,ForwardOp > >{ > typedef State state; > typedef Last iterator; >}; > >}}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/aux_/reverse_fold_impl.hpp" 2 3 4 ># 22 "/usr/include/boost/mpl/reverse_fold.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > , typename State = na > , typename BackwardOp = na > , typename ForwardOp = arg<1> > > >struct reverse_fold >{ > typedef typename aux::reverse_fold_impl< > ::boost::mpl::O1_size<Sequence>::value > , typename begin<Sequence>::type > , typename end<Sequence>::type > , State > , BackwardOp > , ForwardOp > >::state type; > > >}; > >template<> struct reverse_fold< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : reverse_fold< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< reverse_fold< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef reverse_fold< na , na , na > result_; typedef reverse_fold< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< reverse_fold< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< reverse_fold< na , na , na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/remove_if.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/remove_if.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/inserter_algorithm.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/inserter_algorithm.hpp" 3 4 ># 1 "/usr/include/boost/mpl/back_inserter.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/back_inserter.hpp" 3 4 ># 1 "/usr/include/boost/mpl/push_back.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/push_back.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/push_back_impl.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/aux_/push_back_impl.hpp" 3 4 >namespace boost { namespace mpl { > >struct has_push_back_arg {}; > > > >template< typename Tag > >struct push_back_impl >{ > template< typename Sequence, typename T > struct apply > { > > > > struct REQUESTED_PUSH_BACK_SPECIALIZATION_FOR_SEQUENCE_DOES_NOT_EXIST; typedef struct REQUESTED_PUSH_BACK_SPECIALIZATION_FOR_SEQUENCE_DOES_NOT_EXIST44 : boost::mpl::assert_ { static boost::mpl::failed ************ (REQUESTED_PUSH_BACK_SPECIALIZATION_FOR_SEQUENCE_DOES_NOT_EXIST::************ assert_arg()) ( Sequence ) { return 0; } } mpl_assert_arg44; enum { mpl_assertion_in_line_44 = sizeof( boost::mpl::assertion_failed<(( boost::is_same< T, has_push_back_arg >::value ))>( mpl_assert_arg44::assert_arg() ) ) } > > > > ; > }; >}; > >template< typename Tag > >struct has_push_back_impl >{ > template< typename Seq > struct apply > > : aux::has_type< push_back< Seq, has_push_back_arg > > > { > > > > > > > > }; >}; > > template<> struct push_back_impl<non_sequence_tag> {}; > template<> struct has_push_back_impl<non_sequence_tag> {}; > >}} ># 19 "/usr/include/boost/mpl/push_back.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > , typename T = na > > >struct push_back > : push_back_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence,T > >{ > >}; > > >template< > typename Sequence = na > > >struct has_push_back > : has_push_back_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence > >{ > >}; > > >template<> struct push_back< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : push_back< T1 , T2 > { }; }; template< typename Tag > struct lambda< push_back< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef push_back< na , na > result_; typedef push_back< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< push_back< T1 , T2 > > : int_<2> { }; template<> struct template_arity< push_back< na , na > > : int_<-1> { }; } >template<> struct has_push_back< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : has_push_back< T1 > { }; }; template< typename Tag > struct lambda< has_push_back< na > , Tag , int_<-1> > { typedef false_ is_le; typedef has_push_back< na > result_; typedef has_push_back< na > type; }; namespace aux { template< typename T1 > struct template_arity< has_push_back< T1 > > : int_<1> { }; template<> struct template_arity< has_push_back< na > > : int_<-1> { }; } > >}} ># 19 "/usr/include/boost/mpl/back_inserter.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/inserter.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/inserter.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Sequence > , typename Operation > > >struct inserter >{ > typedef Sequence state; > typedef Operation operation; >}; > >}} ># 20 "/usr/include/boost/mpl/back_inserter.hpp" 2 3 4 > >namespace boost { >namespace mpl { > >template< > typename Sequence > > >struct back_inserter > : inserter< Sequence,push_back<> > >{ >}; > >}} ># 19 "/usr/include/boost/mpl/aux_/inserter_algorithm.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/front_inserter.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/front_inserter.hpp" 3 4 ># 1 "/usr/include/boost/mpl/push_front.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/push_front.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/push_front_impl.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/aux_/push_front_impl.hpp" 3 4 >namespace boost { namespace mpl { > >struct has_push_front_arg {}; > > > > >template< typename Tag > >struct push_front_impl >{ > template< typename Sequence, typename T > struct apply > { > > > > struct REQUESTED_PUSH_FRONT_SPECIALIZATION_FOR_SEQUENCE_DOES_NOT_EXIST; typedef struct REQUESTED_PUSH_FRONT_SPECIALIZATION_FOR_SEQUENCE_DOES_NOT_EXIST45 : boost::mpl::assert_ { static boost::mpl::failed ************ (REQUESTED_PUSH_FRONT_SPECIALIZATION_FOR_SEQUENCE_DOES_NOT_EXIST::************ assert_arg()) ( Sequence ) { return 0; } } mpl_assert_arg45; enum { mpl_assertion_in_line_45 = sizeof( boost::mpl::assertion_failed<(( boost::is_same< T, has_push_front_arg >::value ))>( mpl_assert_arg45::assert_arg() ) ) } > > > > ; > }; >}; > >template< typename Tag > >struct has_push_front_impl >{ > template< typename Seq > struct apply > > : aux::has_type< push_front< Seq, has_push_front_arg > > > { > > > > > > > > }; >}; > > template<> struct push_front_impl<non_sequence_tag> {}; > template<> struct has_push_front_impl<non_sequence_tag> {}; > >}} ># 19 "/usr/include/boost/mpl/push_front.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > , typename T = na > > >struct push_front > : push_front_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence,T > >{ > >}; > > >template< > typename Sequence = na > > >struct has_push_front > : has_push_front_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence > >{ > >}; > >template<> struct push_front< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : push_front< T1 , T2 > { }; }; template< typename Tag > struct lambda< push_front< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef push_front< na , na > result_; typedef push_front< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< push_front< T1 , T2 > > : int_<2> { }; template<> struct template_arity< push_front< na , na > > : int_<-1> { }; } >template<> struct has_push_front< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : has_push_front< T1 > { }; }; template< typename Tag > struct lambda< has_push_front< na > , Tag , int_<-1> > { typedef false_ is_le; typedef has_push_front< na > result_; typedef has_push_front< na > type; }; namespace aux { template< typename T1 > struct template_arity< has_push_front< T1 > > : int_<1> { }; template<> struct template_arity< has_push_front< na > > : int_<-1> { }; } > >}} ># 19 "/usr/include/boost/mpl/front_inserter.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template< > typename Sequence > > >struct front_inserter > : inserter< Sequence,push_front<> > >{ >}; > >}} ># 20 "/usr/include/boost/mpl/aux_/inserter_algorithm.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/mpl/clear.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/clear.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/clear_impl.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/aux_/clear_impl.hpp" 3 4 >namespace boost { namespace mpl { > > > >template< typename Tag > >struct clear_impl >{ > template< typename Sequence > struct apply; >}; > > template<> struct clear_impl<non_sequence_tag> {}; > >}} ># 19 "/usr/include/boost/mpl/clear.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > > >struct clear > : clear_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence > >{ > >}; > >template<> struct clear< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : clear< T1 > { }; }; template< typename Tag > struct lambda< clear< na > , Tag , int_<-1> > { typedef false_ is_le; typedef clear< na > result_; typedef clear< na > type; }; namespace aux { template< typename T1 > struct template_arity< clear< T1 > > : int_<1> { }; template<> struct template_arity< clear< na > > : int_<-1> { }; } > >}} ># 25 "/usr/include/boost/mpl/aux_/inserter_algorithm.hpp" 2 3 4 ># 26 "/usr/include/boost/mpl/remove_if.hpp" 2 3 4 > >namespace boost { namespace mpl { > >namespace aux { > >template< typename Pred, typename InsertOp > struct remove_if_helper >{ > template< typename Sequence, typename U > struct apply > { > typedef typename eval_if< > typename apply1<Pred,U>::type > , identity<Sequence> > , apply2<InsertOp,Sequence,U> > >::type type; > }; >}; > >template< > typename Sequence > , typename Predicate > , typename Inserter > > >struct remove_if_impl > : fold< > Sequence > , typename Inserter::state > , protect< aux::remove_if_helper< > typename lambda<Predicate>::type > , typename Inserter::operation > > > > > >{ >}; > >template< > typename Sequence > , typename Predicate > , typename Inserter > > >struct reverse_remove_if_impl > : reverse_fold< > Sequence > , typename Inserter::state > , protect< aux::remove_if_helper< > typename lambda<Predicate>::type > , typename Inserter::operation > > > > > >{ >}; > >} > > template< typename P1 = na , typename P2 = na , typename P3 = na > struct remove_if : aux::remove_if_impl< P1 , P2 , P3> { }; template< typename P1 , typename P2 > struct remove_if< P1 , P2,na > : if_< has_push_back< typename clear<P1>::type> , aux::remove_if_impl< P1 , P2 , back_inserter< typename clear<P1>::type > > , aux::reverse_remove_if_impl< P1 , P2 , front_inserter< typename clear<P1>::type > > >::type { }; template< typename P1 = na , typename P2 = na , typename P3 = na > struct reverse_remove_if : aux::reverse_remove_if_impl< P1 , P2 , P3> { }; template< typename P1 , typename P2 > struct reverse_remove_if< P1 , P2,na > : if_< has_push_back<P1> , aux::reverse_remove_if_impl< P1 , P2 , back_inserter< typename clear<P1>::type > > , aux::remove_if_impl< P1 , P2 , front_inserter< typename clear<P1>::type > > >::type { }; template<> struct remove_if< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : remove_if< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< remove_if< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef remove_if< na , na , na > result_; typedef remove_if< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< remove_if< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< remove_if< na , na , na > > : int_<-1> { }; } template<> struct reverse_remove_if< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : reverse_remove_if< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< reverse_remove_if< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef reverse_remove_if< na , na , na > result_; typedef reverse_remove_if< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< reverse_remove_if< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< reverse_remove_if< na , na , na > > : int_<-1> { }; } > >}} ># 14 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/vector.hpp" 3 4 ># 1 "/usr/include/boost/mpl/limits/vector.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/vector.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/vector.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/vector20.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/vector/vector20.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/vector10.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/vector/vector10.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/vector0.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/vector/vector0.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/at.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/vector/aux_/at.hpp" 3 4 ># 1 "/usr/include/boost/mpl/at_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/at_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct at_impl; >template< typename Sequence, typename N > struct at; > >}} ># 18 "/usr/include/boost/mpl/vector/aux_/at.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/tag.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/vector/aux_/tag.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/typeof.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/vector/aux_/tag.hpp" 2 3 4 > > >namespace boost { namespace mpl { namespace aux { > >struct v_iter_tag; > > >struct vector_tag; > > > > >}}} ># 19 "/usr/include/boost/mpl/vector/aux_/at.hpp" 2 3 4 ># 27 "/usr/include/boost/mpl/vector/aux_/at.hpp" 3 4 >namespace boost { namespace mpl { > > > >template< typename Vector, long n_ > >struct v_at_impl >{ > typedef long_< (Vector::lower_bound_::value + n_) > index_; > typedef __typeof__( Vector::item_(index_()) ) type; >}; > > >template< typename Vector, long n_ > >struct v_at > : aux::wrapped_type< typename v_at_impl<Vector,n_>::type > >{ >}; > >template<> >struct at_impl< aux::vector_tag > >{ > template< typename Vector, typename N > struct apply > : v_at< > Vector > , N::value > > > { > }; >}; ># 114 "/usr/include/boost/mpl/vector/aux_/at.hpp" 3 4 >}} ># 18 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/front.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/vector/aux_/front.hpp" 3 4 >namespace boost { namespace mpl { > > > >template<> >struct front_impl< aux::vector_tag > >{ > template< typename Vector > struct apply > : v_at<Vector,0> > { > }; >}; ># 54 "/usr/include/boost/mpl/vector/aux_/front.hpp" 3 4 >}} ># 19 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/push_front.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/vector/aux_/push_front.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/item.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/vector/aux_/item.hpp" 3 4 >namespace boost { namespace mpl { > > > >template< > typename T > , typename Base > , int at_front = 0 > > >struct v_item > : Base >{ > typedef typename Base::upper_bound_ index_; > typedef typename next<index_>::type upper_bound_; > typedef typename next<typename Base::size>::type size; > typedef Base base; > typedef v_item type; > > > > static aux::type_wrapper<T> item_(index_); > using Base::item_; >}; > >template< > typename T > , typename Base > > >struct v_item<T,Base,1> > : Base >{ > typedef typename prior<typename Base::lower_bound_>::type index_; > typedef index_ lower_bound_; > typedef typename next<typename Base::size>::type size; > typedef Base base; > typedef v_item type; > > static aux::type_wrapper<T> item_(index_); > using Base::item_; >}; > > >template< > typename Base > , int at_front > > >struct v_mask > : Base >{ > typedef typename prior<typename Base::upper_bound_>::type index_; > typedef index_ upper_bound_; > typedef typename prior<typename Base::size>::type size; > typedef Base base; > typedef v_mask type; > > static aux::type_wrapper<void_> item_(index_); > using Base::item_; >}; > >template< > typename Base > > >struct v_mask<Base,1> > : Base >{ > typedef typename Base::lower_bound_ index_; > typedef typename next<index_>::type lower_bound_; > typedef typename prior<typename Base::size>::type size; > typedef Base base; > typedef v_mask type; > > static aux::type_wrapper<void_> item_(index_); > using Base::item_; >}; > > > >}} ># 23 "/usr/include/boost/mpl/vector/aux_/push_front.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template<> >struct push_front_impl< aux::vector_tag > >{ > template< typename Vector, typename T > struct apply > { > typedef v_item<T,Vector,1> type; > }; >}; > >}} ># 20 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/pop_front.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/vector/aux_/pop_front.hpp" 3 4 >namespace boost { namespace mpl { > >template<> >struct pop_front_impl< aux::vector_tag > >{ > template< typename Vector > struct apply > { > typedef v_mask<Vector,1> type; > }; >}; > >}} ># 21 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/push_back.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/vector/aux_/push_back.hpp" 3 4 >namespace boost { namespace mpl { > >template<> >struct push_back_impl< aux::vector_tag > >{ > template< typename Vector, typename T > struct apply > { > typedef v_item<T,Vector,0> type; > }; >}; > >}} ># 22 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/pop_back.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/vector/aux_/pop_back.hpp" 3 4 ># 1 "/usr/include/boost/mpl/pop_back_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/pop_back_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct pop_back_impl; >template< typename Sequence > struct pop_back; > >}} ># 18 "/usr/include/boost/mpl/vector/aux_/pop_back.hpp" 2 3 4 > > > > > > > >namespace boost { namespace mpl { > >template<> >struct pop_back_impl< aux::vector_tag > >{ > template< typename Vector > struct apply > { > typedef v_mask<Vector,0> type; > }; >}; > >}} ># 23 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/back.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/vector/aux_/back.hpp" 3 4 ># 1 "/usr/include/boost/mpl/back_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/back_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct back_impl; >template< typename Sequence > struct back; > >}} ># 18 "/usr/include/boost/mpl/vector/aux_/back.hpp" 2 3 4 > > > > > > >namespace boost { namespace mpl { > > > >template<> >struct back_impl< aux::vector_tag > >{ > template< typename Vector > struct apply > : v_at< > Vector > , prior<typename Vector::size>::type::value > > > { > }; >}; ># 57 "/usr/include/boost/mpl/vector/aux_/back.hpp" 3 4 >}} ># 24 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/clear.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/vector/aux_/clear.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/vector0.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/vector/aux_/vector0.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/iterator.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/vector/aux_/iterator.hpp" 3 4 ># 1 "/usr/include/boost/mpl/plus.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/plus.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 27 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/plus.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/plus.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Tag1 > , typename Tag2 > > >struct plus_impl > : if_c< > ( Tag1::value > > Tag2::value > ) > > , aux::cast2nd_impl< plus_impl< Tag1,Tag1 >,Tag1, Tag2 > > , aux::cast1st_impl< plus_impl< Tag2,Tag2 >,Tag1, Tag2 > > >::type >{ >}; > > >template<> struct plus_impl< na,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct plus_impl< na,Tag > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct plus_impl< Tag,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename T > struct plus_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > , typename N3 = na, typename N4 = na, typename N5 = na > > >struct plus > : plus< plus< plus< plus< N1,N2 >, N3>, N4>, N5> >{ > > > > > >}; > >template< > typename N1, typename N2, typename N3, typename N4 > > >struct plus< N1,N2,N3,N4,na > > > : plus< plus< plus< N1,N2 >, N3>, N4> >{ > > > > > >}; > >template< > typename N1, typename N2, typename N3 > > >struct plus< N1,N2,N3,na,na > > > : plus< plus< N1,N2 >, N3> >{ > > > > > >}; > >template< > typename N1, typename N2 > > >struct plus< N1,N2,na,na,na > > : plus_impl< > typename plus_tag<N1>::type > , typename plus_tag<N2>::type > >::template apply< N1,N2 >::type >{ > > > > > > >}; > >template<> struct plus< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : plus< T1 , T2 > { }; }; template< typename Tag > struct lambda< plus< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef plus< na , na > result_; typedef plus< na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct template_arity< plus< T1 , T2 , T3 , T4 , T5 > > : int_<5> { }; template<> struct template_arity< plus< na , na > > : int_<-1> { }; } > >}} > >namespace boost { namespace mpl { >template<> >struct plus_impl< integral_c_tag,integral_c_tag > >{ > template< typename N1, typename N2 > struct apply > > : integral_c< > typename aux::largest_int< > typename N1::value_type > , typename N2::value_type > >::type > , ( N1::value > + N2::value > ) > > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 35 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/plus.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/vector/aux_/iterator.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/minus.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/minus.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 27 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/minus.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/minus.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Tag1 > , typename Tag2 > > >struct minus_impl > : if_c< > ( Tag1::value > > Tag2::value > ) > > , aux::cast2nd_impl< minus_impl< Tag1,Tag1 >,Tag1, Tag2 > > , aux::cast1st_impl< minus_impl< Tag2,Tag2 >,Tag1, Tag2 > > >::type >{ >}; > > >template<> struct minus_impl< na,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct minus_impl< na,Tag > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct minus_impl< Tag,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename T > struct minus_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > , typename N3 = na, typename N4 = na, typename N5 = na > > >struct minus > : minus< minus< minus< minus< N1,N2 >, N3>, N4>, N5> >{ > > > > > >}; > >template< > typename N1, typename N2, typename N3, typename N4 > > >struct minus< N1,N2,N3,N4,na > > > : minus< minus< minus< N1,N2 >, N3>, N4> >{ > > > > > >}; > >template< > typename N1, typename N2, typename N3 > > >struct minus< N1,N2,N3,na,na > > > : minus< minus< N1,N2 >, N3> >{ > > > > > >}; > >template< > typename N1, typename N2 > > >struct minus< N1,N2,na,na,na > > : minus_impl< > typename minus_tag<N1>::type > , typename minus_tag<N2>::type > >::template apply< N1,N2 >::type >{ > > > > > > >}; > >template<> struct minus< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : minus< T1 , T2 > { }; }; template< typename Tag > struct lambda< minus< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef minus< na , na > result_; typedef minus< na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct template_arity< minus< T1 , T2 , T3 , T4 , T5 > > : int_<5> { }; template<> struct template_arity< minus< na , na > > : int_<-1> { }; } > >}} > >namespace boost { namespace mpl { >template<> >struct minus_impl< integral_c_tag,integral_c_tag > >{ > template< typename N1, typename N2 > struct apply > > : integral_c< > typename aux::largest_int< > typename N1::value_type > , typename N2::value_type > >::type > , ( N1::value > - N2::value > ) > > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 35 "/usr/include/boost/mpl/aux_/arithmetic_op.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/minus.hpp" 2 3 4 ># 21 "/usr/include/boost/mpl/vector/aux_/iterator.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/advance_fwd.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/advance_fwd.hpp" 3 4 >namespace boost { namespace mpl { > > > >template< typename Tag > struct advance_impl; >template< typename Iterator, typename N > struct advance; > >}} ># 22 "/usr/include/boost/mpl/vector/aux_/iterator.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/distance_fwd.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/distance_fwd.hpp" 3 4 >namespace boost { namespace mpl { > > > >template< typename Tag > struct distance_impl; >template< typename First, typename Last > struct distance; > >}} ># 23 "/usr/include/boost/mpl/vector/aux_/iterator.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/prior.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/vector/aux_/iterator.hpp" 2 3 4 > > > > > >namespace boost { namespace mpl { > >template< > typename Vector > , long n_ > > >struct v_iter >{ > typedef aux::v_iter_tag tag; > typedef random_access_iterator_tag category; > typedef typename v_at<Vector,n_>::type type; > > typedef Vector vector_; > typedef mpl::long_<n_> pos; ># 56 "/usr/include/boost/mpl/vector/aux_/iterator.hpp" 3 4 >}; > > > > >template< > typename Vector > , long n_ > > >struct next< v_iter<Vector,n_> > >{ > typedef v_iter<Vector,(n_ + 1)> type; >}; > >template< > typename Vector > , long n_ > > >struct prior< v_iter<Vector,n_> > >{ > typedef v_iter<Vector,(n_ - 1)> type; >}; > >template< > typename Vector > , long n_ > , typename Distance > > >struct advance< v_iter<Vector,n_>,Distance> >{ > typedef v_iter< > Vector > , (n_ + Distance::value) > > type; >}; > >template< > typename Vector > , long n_ > , long m_ > > >struct distance< v_iter<Vector,n_>, v_iter<Vector,m_> > > : mpl::long_<(m_ - n_)> >{ >}; ># 128 "/usr/include/boost/mpl/vector/aux_/iterator.hpp" 3 4 >}} ># 23 "/usr/include/boost/mpl/vector/aux_/vector0.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< typename Dummy = na > struct vector0; > >template<> struct vector0<na> >{ > > typedef aux::vector_tag tag; > typedef vector0 type; > typedef long_<32768> lower_bound_; > typedef lower_bound_ upper_bound_; > typedef long_<0> size; > > static aux::type_wrapper<void_> item_(...); ># 48 "/usr/include/boost/mpl/vector/aux_/vector0.hpp" 3 4 >}; > >}} ># 19 "/usr/include/boost/mpl/vector/aux_/clear.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > > > >template<> >struct clear_impl< aux::vector_tag > >{ > template< typename Vector > struct apply > { > typedef vector0<> type; > }; >}; ># 53 "/usr/include/boost/mpl/vector/aux_/clear.hpp" 3 4 >}} ># 25 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/O1_size.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/vector/aux_/O1_size.hpp" 3 4 >namespace boost { namespace mpl { > > > >template<> >struct O1_size_impl< aux::vector_tag > >{ > template< typename Vector > struct apply > : Vector::size > { > }; >}; ># 54 "/usr/include/boost/mpl/vector/aux_/O1_size.hpp" 3 4 >}} ># 26 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/size.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/vector/aux_/size.hpp" 3 4 >namespace boost { namespace mpl { > > > >template<> >struct size_impl< aux::vector_tag > > : O1_size_impl< aux::vector_tag > >{ >}; ># 47 "/usr/include/boost/mpl/vector/aux_/size.hpp" 3 4 >}} ># 27 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/empty.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/vector/aux_/empty.hpp" 3 4 >namespace boost { namespace mpl { > > > >template<> >struct empty_impl< aux::vector_tag > >{ > template< typename Vector > struct apply > : is_same< > typename Vector::lower_bound_ > , typename Vector::upper_bound_ > > > { > }; >}; ># 66 "/usr/include/boost/mpl/vector/aux_/empty.hpp" 3 4 >}} ># 28 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/vector/aux_/begin_end.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/vector/aux_/begin_end.hpp" 3 4 >namespace boost { namespace mpl { > >template<> >struct begin_impl< aux::vector_tag > >{ > template< typename Vector > struct apply > { > typedef v_iter<Vector,0> type; > }; >}; > >template<> >struct end_impl< aux::vector_tag > >{ > template< typename Vector > struct apply > { > typedef v_iter<Vector,Vector::size::value> type; > }; >}; > >}} ># 32 "/usr/include/boost/mpl/vector/vector0.hpp" 2 3 4 ># 19 "/usr/include/boost/mpl/vector/vector10.hpp" 2 3 4 ># 27 "/usr/include/boost/mpl/vector/vector10.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/include_preprocessed.hpp" 1 3 4 ># 49 "/usr/include/boost/mpl/vector/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/preprocessed/typeof_based/vector10.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/vector/aux_/preprocessed/typeof_based/vector10.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T0 > > >struct vector1 > : v_item< > T0 > , vector0< > > > >{ > typedef vector1 type; >}; > >template< > typename T0, typename T1 > > >struct vector2 > : v_item< > T1 > , vector1<T0> > > >{ > typedef vector2 type; >}; > >template< > typename T0, typename T1, typename T2 > > >struct vector3 > : v_item< > T2 > , vector2< T0,T1 > > > >{ > typedef vector3 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3 > > >struct vector4 > : v_item< > T3 > , vector3< T0,T1,T2 > > > >{ > typedef vector4 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > > >struct vector5 > : v_item< > T4 > , vector4< T0,T1,T2,T3 > > > >{ > typedef vector5 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct vector6 > : v_item< > T5 > , vector5< T0,T1,T2,T3,T4 > > > >{ > typedef vector6 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6 > > >struct vector7 > : v_item< > T6 > , vector6< T0,T1,T2,T3,T4,T5 > > > >{ > typedef vector7 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7 > > >struct vector8 > : v_item< > T7 > , vector7< T0,T1,T2,T3,T4,T5,T6 > > > >{ > typedef vector8 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8 > > >struct vector9 > : v_item< > T8 > , vector8< T0,T1,T2,T3,T4,T5,T6,T7 > > > >{ > typedef vector9 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > > >struct vector10 > : v_item< > T9 > , vector9< T0,T1,T2,T3,T4,T5,T6,T7,T8 > > > >{ > typedef vector10 type; >}; > >}} ># 50 "/usr/include/boost/mpl/vector/aux_/include_preprocessed.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/vector/vector10.hpp" 2 3 4 ># 19 "/usr/include/boost/mpl/vector/vector20.hpp" 2 3 4 ># 27 "/usr/include/boost/mpl/vector/vector20.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/include_preprocessed.hpp" 1 3 4 ># 49 "/usr/include/boost/mpl/vector/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/vector/aux_/preprocessed/typeof_based/vector20.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/vector/aux_/preprocessed/typeof_based/vector20.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10 > > >struct vector11 > : v_item< > T10 > , vector10< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9 > > > >{ > typedef vector11 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11 > > >struct vector12 > : v_item< > T11 > , vector11< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10 > > > >{ > typedef vector12 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12 > > >struct vector13 > : v_item< > T12 > , vector12< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11 > > > >{ > typedef vector13 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13 > > >struct vector14 > : v_item< > T13 > , vector13< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12 > > > >{ > typedef vector14 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > > >struct vector15 > : v_item< > T14 > , vector14< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13 > > > >{ > typedef vector15 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15 > > >struct vector16 > : v_item< > T15 > , vector15< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14 > > > >{ > typedef vector16 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16 > > >struct vector17 > : v_item< > T16 > , vector16< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15 > > > >{ > typedef vector17 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17 > > >struct vector18 > : v_item< > T17 > , vector17< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16 > > > >{ > typedef vector18 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17, typename T18 > > >struct vector19 > : v_item< > T18 > , vector18< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17 > > > >{ > typedef vector19 type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17, typename T18, typename T19 > > >struct vector20 > : v_item< > T19 > , vector19< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18 > > > >{ > typedef vector20 type; >}; > >}} ># 50 "/usr/include/boost/mpl/vector/aux_/include_preprocessed.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/vector/vector20.hpp" 2 3 4 ># 37 "/usr/include/boost/mpl/vector.hpp" 2 3 4 ># 46 "/usr/include/boost/mpl/vector.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/vector.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/vector.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T0 = na, typename T1 = na, typename T2 = na, typename T3 = na > , typename T4 = na, typename T5 = na, typename T6 = na, typename T7 = na > , typename T8 = na, typename T9 = na, typename T10 = na, typename T11 = na > , typename T12 = na, typename T13 = na, typename T14 = na > , typename T15 = na, typename T16 = na, typename T17 = na > , typename T18 = na, typename T19 = na > > >struct vector; > >template< > > > >struct vector< > na, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : vector0< > >{ > typedef vector0< >::type type; >}; > >template< > typename T0 > > >struct vector< > T0, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : vector1<T0> >{ > typedef typename vector1<T0>::type type; >}; > >template< > typename T0, typename T1 > > >struct vector< > T0, T1, na, na, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : vector2< T0,T1 > >{ > typedef typename vector2< T0,T1 >::type type; >}; > >template< > typename T0, typename T1, typename T2 > > >struct vector< > T0, T1, T2, na, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : vector3< T0,T1,T2 > >{ > typedef typename vector3< T0,T1,T2 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3 > > >struct vector< > T0, T1, T2, T3, na, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : vector4< T0,T1,T2,T3 > >{ > typedef typename vector4< T0,T1,T2,T3 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > > >struct vector< > T0, T1, T2, T3, T4, na, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : vector5< T0,T1,T2,T3,T4 > >{ > typedef typename vector5< T0,T1,T2,T3,T4 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5 > > >struct vector< > T0, T1, T2, T3, T4, T5, na, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : vector6< T0,T1,T2,T3,T4,T5 > >{ > typedef typename vector6< T0,T1,T2,T3,T4,T5 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, na, na, na, na, na, na, na, na, na, na > , na, na, na > > > : vector7< T0,T1,T2,T3,T4,T5,T6 > >{ > typedef typename vector7< T0,T1,T2,T3,T4,T5,T6 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, na, na, na, na, na, na, na, na, na > , na, na, na > > > : vector8< T0,T1,T2,T3,T4,T5,T6,T7 > >{ > typedef typename vector8< T0,T1,T2,T3,T4,T5,T6,T7 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, na, na, na, na, na, na, na, na > , na, na, na > > > : vector9< T0,T1,T2,T3,T4,T5,T6,T7,T8 > >{ > typedef typename vector9< T0,T1,T2,T3,T4,T5,T6,T7,T8 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, na, na, na, na, na, na, na > , na, na, na > > > : vector10< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9 > >{ > typedef typename vector10< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, na, na, na, na, na, na > , na, na, na > > > : vector11< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10 > >{ > typedef typename vector11< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, na, na, na, na > , na, na, na, na > > > : vector12< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11 > >{ > typedef typename vector12< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, na, na, na > , na, na, na, na > > > : vector13< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12 > >{ > typedef typename vector13< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, na, na > , na, na, na, na > > > : vector14< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13 > >{ > typedef typename vector14< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, na > , na, na, na, na > > > : vector15< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > > >{ > typedef typename vector15< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, na, na, na, na > > > : vector16< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15 > > >{ > typedef typename vector16< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, na, na, na > > > : vector17< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16 > > >{ > typedef typename vector17< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17, na, na > > > : vector18< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17 > > >{ > typedef typename vector18< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17 >::type type; >}; > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17, typename T18 > > >struct vector< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17, T18, na > > > : vector19< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17, T18 > > >{ > typedef typename vector19< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18 >::type type; >}; > > > >template< > typename T0, typename T1, typename T2, typename T3, typename T4 > , typename T5, typename T6, typename T7, typename T8, typename T9 > , typename T10, typename T11, typename T12, typename T13, typename T14 > , typename T15, typename T16, typename T17, typename T18, typename T19 > > >struct vector > : vector20< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > , T15, T16, T17, T18, T19 > > >{ > typedef typename vector20< T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19 >::type type; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 47 "/usr/include/boost/mpl/vector.hpp" 2 3 4 ># 15 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/at.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/at.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/at_impl.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/aux_/at_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/advance.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/advance.hpp" 3 4 ># 1 "/usr/include/boost/mpl/negate.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/negate.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct negate_impl; > >template< typename T > struct negate_tag >{ > typedef typename T::tag type; >}; > >template< > typename N = na > > >struct negate > > : negate_impl< > typename negate_tag<N>::type > >::template apply<N>::type > > > > > > >{ > >}; > >template<> struct negate< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : negate< T1 > { }; }; template< typename Tag > struct lambda< negate< na > , Tag , int_<-1> > { typedef false_ is_le; typedef negate< na > result_; typedef negate< na > type; }; namespace aux { template< typename T1 > struct template_arity< negate< T1 > > : int_<1> { }; template<> struct template_arity< negate< na > > : int_<-1> { }; } ># 65 "/usr/include/boost/mpl/negate.hpp" 3 4 >template<> >struct negate_impl<integral_c_tag> >{ > > > > > template< typename N > struct apply > : integral_c< typename N::value_type, (-N::value) > > > { > }; >}; > >}} ># 20 "/usr/include/boost/mpl/advance.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/advance.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/advance_forward.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/advance_forward.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/aux_/advance_forward.hpp" 2 3 4 ># 32 "/usr/include/boost/mpl/aux_/advance_forward.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/advance_forward.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/advance_forward.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >template< long N > struct advance_forward; >template<> >struct advance_forward<0> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef iter0 type; > }; >}; > >template<> >struct advance_forward<1> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef typename next<iter0>::type iter1; > typedef iter1 type; > }; >}; > >template<> >struct advance_forward<2> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef typename next<iter0>::type iter1; > typedef typename next<iter1>::type iter2; > typedef iter2 type; > }; >}; > >template<> >struct advance_forward<3> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef typename next<iter0>::type iter1; > typedef typename next<iter1>::type iter2; > typedef typename next<iter2>::type iter3; > typedef iter3 type; > }; >}; > >template<> >struct advance_forward<4> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef typename next<iter0>::type iter1; > typedef typename next<iter1>::type iter2; > typedef typename next<iter2>::type iter3; > typedef typename next<iter3>::type iter4; > typedef iter4 type; > }; >}; > >template< long N > >struct advance_forward >{ > template< typename Iterator > struct apply > { > typedef typename apply_wrap1< > advance_forward<4> > , Iterator > >::type chunk_result_; > > typedef typename apply_wrap1< > advance_forward<( > (N - 4) < 0 > ? 0 > : N - 4 > )> > , chunk_result_ > >::type type; > }; >}; > >}}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 33 "/usr/include/boost/mpl/aux_/advance_forward.hpp" 2 3 4 ># 25 "/usr/include/boost/mpl/advance.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/advance_backward.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/advance_backward.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/aux_/advance_backward.hpp" 2 3 4 ># 32 "/usr/include/boost/mpl/aux_/advance_backward.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/advance_backward.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/advance_backward.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >template< long N > struct advance_backward; >template<> >struct advance_backward<0> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef iter0 type; > }; >}; > >template<> >struct advance_backward<1> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef typename prior<iter0>::type iter1; > typedef iter1 type; > }; >}; > >template<> >struct advance_backward<2> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef typename prior<iter0>::type iter1; > typedef typename prior<iter1>::type iter2; > typedef iter2 type; > }; >}; > >template<> >struct advance_backward<3> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef typename prior<iter0>::type iter1; > typedef typename prior<iter1>::type iter2; > typedef typename prior<iter2>::type iter3; > typedef iter3 type; > }; >}; > >template<> >struct advance_backward<4> >{ > template< typename Iterator > struct apply > { > typedef Iterator iter0; > typedef typename prior<iter0>::type iter1; > typedef typename prior<iter1>::type iter2; > typedef typename prior<iter2>::type iter3; > typedef typename prior<iter3>::type iter4; > typedef iter4 type; > }; >}; > >template< long N > >struct advance_backward >{ > template< typename Iterator > struct apply > { > typedef typename apply_wrap1< > advance_backward<4> > , Iterator > >::type chunk_result_; > > typedef typename apply_wrap1< > advance_backward<( > (N - 4) < 0 > ? 0 > : N - 4 > )> > , chunk_result_ > >::type type; > }; >}; > >}}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 33 "/usr/include/boost/mpl/aux_/advance_backward.hpp" 2 3 4 ># 26 "/usr/include/boost/mpl/advance.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > > >template< typename Tag > >struct advance_impl >{ > template< typename Iterator, typename N > struct apply > { > typedef typename less< N,long_<0> >::type backward_; > typedef typename if_< backward_, negate<N>, N >::type offset_; > > typedef typename if_< > backward_ > , aux::advance_backward< offset_::value > > , aux::advance_forward< offset_::value > > >::type f_; > > typedef typename apply_wrap1<f_,Iterator>::type type; > }; >}; > > >template< > typename Iterator = na > , typename N = na > > >struct advance > : advance_impl< typename tag<Iterator>::type > > ::template apply<Iterator,N> >{ >}; > >template< > typename Iterator > , long N > > >struct advance_c > : advance_impl< typename tag<Iterator>::type > > ::template apply<Iterator,long_<N> > >{ >}; > >template<> struct advance< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : advance< T1 , T2 > { }; }; template< typename Tag > struct lambda< advance< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef advance< na , na > result_; typedef advance< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< advance< T1 , T2 > > : int_<2> { }; template<> struct template_arity< advance< na , na > > : int_<-1> { }; } > >}} ># 19 "/usr/include/boost/mpl/aux_/at_impl.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > > > > >template< typename Tag > >struct at_impl >{ > template< typename Sequence, typename N > struct apply > { > typedef typename advance< > typename begin<Sequence>::type > , N > >::type iter_; > > typedef typename deref<iter_>::type type; > }; >}; > > template<> struct at_impl<non_sequence_tag> {}; > >}} ># 19 "/usr/include/boost/mpl/at.hpp" 2 3 4 > > > > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > , typename N = na > > >struct at > : at_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence,N > >{ > >}; > >template< > typename Sequence > , long N > > >struct at_c > : at_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence,mpl::long_<N> > >{ >}; > >template<> struct at< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : at< T1 , T2 > { }; }; template< typename Tag > struct lambda< at< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef at< na , na > result_; typedef at< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< at< T1 , T2 > > : int_<2> { }; template<> struct template_arity< at< na , na > > : int_<-1> { }; } > >}} ># 17 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/size.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/size.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/size_impl.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/size_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/distance.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/distance.hpp" 3 4 ># 1 "/usr/include/boost/mpl/iter_fold.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/iter_fold.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/iter_fold_impl.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/iter_fold_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/iter_fold_impl.hpp" 2 3 4 ># 33 "/usr/include/boost/mpl/aux_/iter_fold_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/iter_fold_impl.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/iter_fold_impl.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > > > >template< > int N > , typename First > , typename Last > , typename State > , typename ForwardOp > > >struct iter_fold_impl; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct iter_fold_impl< 0,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef state0 state; > typedef iter0 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct iter_fold_impl< 1,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef typename apply2< ForwardOp,state0,iter0 >::type state1; > typedef typename mpl::next<iter0>::type iter1; > > > typedef state1 state; > typedef iter1 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct iter_fold_impl< 2,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef typename apply2< ForwardOp,state0,iter0 >::type state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp,state1,iter1 >::type state2; > typedef typename mpl::next<iter1>::type iter2; > > > typedef state2 state; > typedef iter2 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct iter_fold_impl< 3,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef typename apply2< ForwardOp,state0,iter0 >::type state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp,state1,iter1 >::type state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp,state2,iter2 >::type state3; > typedef typename mpl::next<iter2>::type iter3; > > > typedef state3 state; > typedef iter3 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct iter_fold_impl< 4,First,Last,State,ForwardOp > >{ > typedef First iter0; > typedef State state0; > typedef typename apply2< ForwardOp,state0,iter0 >::type state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp,state1,iter1 >::type state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp,state2,iter2 >::type state3; > typedef typename mpl::next<iter2>::type iter3; > typedef typename apply2< ForwardOp,state3,iter3 >::type state4; > typedef typename mpl::next<iter3>::type iter4; > > > typedef state4 state; > typedef iter4 iterator; >}; > >template< > int N > , typename First > , typename Last > , typename State > , typename ForwardOp > > >struct iter_fold_impl >{ > typedef iter_fold_impl< > 4 > , First > , Last > , State > , ForwardOp > > chunk_; > > typedef iter_fold_impl< > ( (N - 4) < 0 ? 0 : N - 4 ) > , typename chunk_::iterator > , Last > , typename chunk_::state > , ForwardOp > > res_; > > typedef typename res_::state state; > typedef typename res_::iterator iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename ForwardOp > > >struct iter_fold_impl< -1,First,Last,State,ForwardOp > > : iter_fold_impl< > -1 > , typename mpl::next<First>::type > , Last > , typename apply2< ForwardOp,State,First >::type > , ForwardOp > > >{ >}; > >template< > typename Last > , typename State > , typename ForwardOp > > >struct iter_fold_impl< -1,Last,Last,State,ForwardOp > >{ > typedef State state; > typedef Last iterator; >}; > >}}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 34 "/usr/include/boost/mpl/aux_/iter_fold_impl.hpp" 2 3 4 ># 22 "/usr/include/boost/mpl/iter_fold.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > , typename State = na > , typename ForwardOp = na > > >struct iter_fold >{ > typedef typename aux::iter_fold_impl< > ::boost::mpl::O1_size<Sequence>::value > , typename begin<Sequence>::type > , typename end<Sequence>::type > , State > , typename lambda<ForwardOp>::type > >::state type; > > >}; > >template<> struct iter_fold< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : iter_fold< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< iter_fold< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef iter_fold< na , na , na > result_; typedef iter_fold< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< iter_fold< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< iter_fold< na , na , na > > : int_<-1> { }; } > >}} ># 19 "/usr/include/boost/mpl/distance.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/iterator_range.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/iterator_range.hpp" 3 4 >namespace boost { namespace mpl { > >struct iterator_range_tag; > >template< > typename First = na > , typename Last = na > > >struct iterator_range >{ > typedef iterator_range_tag tag; > typedef iterator_range type; > typedef First begin; > typedef Last end; > > >}; > >template<> struct iterator_range< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : iterator_range< T1 , T2 > { }; }; template< typename Tag > struct lambda< iterator_range< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef iterator_range< na , na > result_; typedef iterator_range< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< iterator_range< T1 , T2 > > : int_<2> { }; template<> struct template_arity< iterator_range< na , na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/distance.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/distance.hpp" 2 3 4 > > > > > > > >namespace boost { namespace mpl { > > >template< typename Tag > struct distance_impl >{ > template< typename First, typename Last > struct apply > > : aux::msvc_eti_base< typename iter_fold< > iterator_range<First,Last> > , mpl::long_<0> > , next<> > >::type > > { ># 60 "/usr/include/boost/mpl/distance.hpp" 3 4 > }; >}; > >template< > typename First = na > , typename Last = na > > >struct distance > : distance_impl< typename tag<First>::type > > ::template apply<First, Last> >{ > >}; > >template<> struct distance< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : distance< T1 , T2 > { }; }; template< typename Tag > struct lambda< distance< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef distance< na , na > result_; typedef distance< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< distance< T1 , T2 > > : int_<2> { }; template<> struct template_arity< distance< na , na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/aux_/size_impl.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > > > > >template< typename Tag > >struct size_impl >{ > template< typename Sequence > struct apply > > : distance< > typename begin<Sequence>::type > , typename end<Sequence>::type > > > { > > > > > > > > }; >}; > > template<> struct size_impl<non_sequence_tag> {}; > >}} ># 20 "/usr/include/boost/mpl/size.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > > >struct size > : aux::msvc_eti_base< > typename size_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence >::type > >::type >{ > >}; > >template<> struct size< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : size< T1 > { }; }; template< typename Tag > struct lambda< size< na > , Tag , int_<-1> > { typedef false_ is_le; typedef size< na > result_; typedef size< na > type; }; namespace aux { template< typename T1 > struct template_arity< size< T1 > > : int_<1> { }; template<> struct template_arity< size< na > > : int_<-1> { }; } > >}} ># 18 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/comparison.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/comparison.hpp" 3 4 ># 1 "/usr/include/boost/mpl/not_equal_to.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/not_equal_to.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/not_equal_to.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/not_equal_to.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Tag1 > , typename Tag2 > > >struct not_equal_to_impl > : if_c< > ( Tag1::value > > Tag2::value > ) > > , aux::cast2nd_impl< not_equal_to_impl< Tag1,Tag1 >,Tag1, Tag2 > > , aux::cast1st_impl< not_equal_to_impl< Tag2,Tag2 >,Tag1, Tag2 > > >::type >{ >}; > > >template<> struct not_equal_to_impl< na,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct not_equal_to_impl< na,Tag > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct not_equal_to_impl< Tag,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename T > struct not_equal_to_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > > >struct not_equal_to > > : not_equal_to_impl< > typename not_equal_to_tag<N1>::type > , typename not_equal_to_tag<N2>::type > >::template apply< N1,N2 >::type >{ > > >}; > >template<> struct not_equal_to< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : not_equal_to< T1 , T2 > { }; }; template< typename Tag > struct lambda< not_equal_to< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef not_equal_to< na , na > result_; typedef not_equal_to< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< not_equal_to< T1 , T2 > > : int_<2> { }; template<> struct template_arity< not_equal_to< na , na > > : int_<-1> { }; } > >}} > >namespace boost { namespace mpl { > >template<> >struct not_equal_to_impl< integral_c_tag,integral_c_tag > >{ > template< typename N1, typename N2 > struct apply > > : bool_< ( N1::value != N2::value ) > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/not_equal_to.hpp" 2 3 4 ># 19 "/usr/include/boost/mpl/comparison.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/greater.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/greater.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/greater.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/greater.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Tag1 > , typename Tag2 > > >struct greater_impl > : if_c< > ( Tag1::value > > Tag2::value > ) > > , aux::cast2nd_impl< greater_impl< Tag1,Tag1 >,Tag1, Tag2 > > , aux::cast1st_impl< greater_impl< Tag2,Tag2 >,Tag1, Tag2 > > >::type >{ >}; > > >template<> struct greater_impl< na,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct greater_impl< na,Tag > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct greater_impl< Tag,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename T > struct greater_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > > >struct greater > > : greater_impl< > typename greater_tag<N1>::type > , typename greater_tag<N2>::type > >::template apply< N1,N2 >::type >{ > > >}; > >template<> struct greater< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : greater< T1 , T2 > { }; }; template< typename Tag > struct lambda< greater< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef greater< na , na > result_; typedef greater< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< greater< T1 , T2 > > : int_<2> { }; template<> struct template_arity< greater< na , na > > : int_<-1> { }; } > >}} > >namespace boost { namespace mpl { > >template<> >struct greater_impl< integral_c_tag,integral_c_tag > >{ > template< typename N1, typename N2 > struct apply > > : bool_< ( N1::value > N2::value ) > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/greater.hpp" 2 3 4 ># 21 "/usr/include/boost/mpl/comparison.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/less_equal.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/less_equal.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/less_equal.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/less_equal.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Tag1 > , typename Tag2 > > >struct less_equal_impl > : if_c< > ( Tag1::value > > Tag2::value > ) > > , aux::cast2nd_impl< less_equal_impl< Tag1,Tag1 >,Tag1, Tag2 > > , aux::cast1st_impl< less_equal_impl< Tag2,Tag2 >,Tag1, Tag2 > > >::type >{ >}; > > >template<> struct less_equal_impl< na,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct less_equal_impl< na,Tag > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct less_equal_impl< Tag,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename T > struct less_equal_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > > >struct less_equal > > : less_equal_impl< > typename less_equal_tag<N1>::type > , typename less_equal_tag<N2>::type > >::template apply< N1,N2 >::type >{ > > >}; > >template<> struct less_equal< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : less_equal< T1 , T2 > { }; }; template< typename Tag > struct lambda< less_equal< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef less_equal< na , na > result_; typedef less_equal< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< less_equal< T1 , T2 > > : int_<2> { }; template<> struct template_arity< less_equal< na , na > > : int_<-1> { }; } > >}} > >namespace boost { namespace mpl { > >template<> >struct less_equal_impl< integral_c_tag,integral_c_tag > >{ > template< typename N1, typename N2 > struct apply > > : bool_< ( N1::value <= N2::value ) > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/less_equal.hpp" 2 3 4 ># 22 "/usr/include/boost/mpl/comparison.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/greater_equal.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/greater_equal.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply_wrap.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/aux_/numeric_op.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/greater_equal.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/greater_equal.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Tag1 > , typename Tag2 > > >struct greater_equal_impl > : if_c< > ( Tag1::value > > Tag2::value > ) > > , aux::cast2nd_impl< greater_equal_impl< Tag1,Tag1 >,Tag1, Tag2 > > , aux::cast1st_impl< greater_equal_impl< Tag2,Tag2 >,Tag1, Tag2 > > >::type >{ >}; > > >template<> struct greater_equal_impl< na,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct greater_equal_impl< na,Tag > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename Tag > struct greater_equal_impl< Tag,na > >{ > template< typename U1, typename U2 > struct apply > { > typedef apply type; > static const int value = 0; > }; >}; > >template< typename T > struct greater_equal_tag >{ > typedef typename T::tag type; >}; > >template< > typename N1 = na > , typename N2 = na > > >struct greater_equal > > : greater_equal_impl< > typename greater_equal_tag<N1>::type > , typename greater_equal_tag<N2>::type > >::template apply< N1,N2 >::type >{ > > >}; > >template<> struct greater_equal< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : greater_equal< T1 , T2 > { }; }; template< typename Tag > struct lambda< greater_equal< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef greater_equal< na , na > result_; typedef greater_equal< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< greater_equal< T1 , T2 > > : int_<2> { }; template<> struct template_arity< greater_equal< na , na > > : int_<-1> { }; } > >}} > >namespace boost { namespace mpl { > >template<> >struct greater_equal_impl< integral_c_tag,integral_c_tag > >{ > template< typename N1, typename N2 > struct apply > > : bool_< ( N1::value >= N2::value ) > > { > }; >}; > >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 36 "/usr/include/boost/mpl/aux_/comparison_op.hpp" 2 3 4 ># 20 "/usr/include/boost/mpl/greater_equal.hpp" 2 3 4 ># 23 "/usr/include/boost/mpl/comparison.hpp" 2 3 4 ># 19 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 > > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 22 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 27 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 29 "/usr/include/boost/math/policies/policy.hpp" 2 3 4 > > >namespace boost{ namespace math{ > >namespace tools{ > >template <class T> >int digits(); >template <class T> >T epsilon(); > >} > >namespace policies{ ># 176 "/usr/include/boost/math/policies/policy.hpp" 3 4 >enum error_policy_type >{ > throw_on_error = 0, > errno_on_error = 1, > ignore_error = 2, > user_error = 3 >}; > >template <error_policy_type N = throw_on_error> struct domain_error : public boost::mpl::int_<N>{}; namespace detail{ template <error_policy_type N> char test_is_valid_arg(const domain_error<N>*); char test_is_default_arg(const domain_error<throw_on_error>*); template <class T> struct is_domain_error_imp { template <error_policy_type N> static char test(const domain_error<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_domain_error : public boost::mpl::bool_< ::boost::math::policies::detail::is_domain_error_imp<T>::value>{}; >template <error_policy_type N = throw_on_error> struct pole_error : public boost::mpl::int_<N>{}; namespace detail{ template <error_policy_type N> char test_is_valid_arg(const pole_error<N>*); char test_is_default_arg(const pole_error<throw_on_error>*); template <class T> struct is_pole_error_imp { template <error_policy_type N> static char test(const pole_error<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_pole_error : public boost::mpl::bool_< ::boost::math::policies::detail::is_pole_error_imp<T>::value>{}; >template <error_policy_type N = throw_on_error> struct overflow_error : public boost::mpl::int_<N>{}; namespace detail{ template <error_policy_type N> char test_is_valid_arg(const overflow_error<N>*); char test_is_default_arg(const overflow_error<throw_on_error>*); template <class T> struct is_overflow_error_imp { template <error_policy_type N> static char test(const overflow_error<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_overflow_error : public boost::mpl::bool_< ::boost::math::policies::detail::is_overflow_error_imp<T>::value>{}; >template <error_policy_type N = ignore_error> struct underflow_error : public boost::mpl::int_<N>{}; namespace detail{ template <error_policy_type N> char test_is_valid_arg(const underflow_error<N>*); char test_is_default_arg(const underflow_error<ignore_error>*); template <class T> struct is_underflow_error_imp { template <error_policy_type N> static char test(const underflow_error<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_underflow_error : public boost::mpl::bool_< ::boost::math::policies::detail::is_underflow_error_imp<T>::value>{}; >template <error_policy_type N = ignore_error> struct denorm_error : public boost::mpl::int_<N>{}; namespace detail{ template <error_policy_type N> char test_is_valid_arg(const denorm_error<N>*); char test_is_default_arg(const denorm_error<ignore_error>*); template <class T> struct is_denorm_error_imp { template <error_policy_type N> static char test(const denorm_error<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_denorm_error : public boost::mpl::bool_< ::boost::math::policies::detail::is_denorm_error_imp<T>::value>{}; >template <error_policy_type N = throw_on_error> struct evaluation_error : public boost::mpl::int_<N>{}; namespace detail{ template <error_policy_type N> char test_is_valid_arg(const evaluation_error<N>*); char test_is_default_arg(const evaluation_error<throw_on_error>*); template <class T> struct is_evaluation_error_imp { template <error_policy_type N> static char test(const evaluation_error<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_evaluation_error : public boost::mpl::bool_< ::boost::math::policies::detail::is_evaluation_error_imp<T>::value>{}; >template <error_policy_type N = throw_on_error> struct rounding_error : public boost::mpl::int_<N>{}; namespace detail{ template <error_policy_type N> char test_is_valid_arg(const rounding_error<N>*); char test_is_default_arg(const rounding_error<throw_on_error>*); template <class T> struct is_rounding_error_imp { template <error_policy_type N> static char test(const rounding_error<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_rounding_error : public boost::mpl::bool_< ::boost::math::policies::detail::is_rounding_error_imp<T>::value>{}; >template <error_policy_type N = ignore_error> struct indeterminate_result_error : public boost::mpl::int_<N>{}; namespace detail{ template <error_policy_type N> char test_is_valid_arg(const indeterminate_result_error<N>*); char test_is_default_arg(const indeterminate_result_error<ignore_error>*); template <class T> struct is_indeterminate_result_error_imp { template <error_policy_type N> static char test(const indeterminate_result_error<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_indeterminate_result_error : public boost::mpl::bool_< ::boost::math::policies::detail::is_indeterminate_result_error_imp<T>::value>{}; > > > > >template <bool N = true> struct promote_float : public boost::mpl::bool_<N>{}; namespace detail{ template <bool N> char test_is_valid_arg(const promote_float<N>*); char test_is_default_arg(const promote_float<true>*); template <class T> struct is_promote_float_imp { template <bool N> static char test(const promote_float<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_promote_float : public boost::mpl::bool_< ::boost::math::policies::detail::is_promote_float_imp<T>::value>{}; >template <bool N = true> struct promote_double : public boost::mpl::bool_<N>{}; namespace detail{ template <bool N> char test_is_valid_arg(const promote_double<N>*); char test_is_default_arg(const promote_double<true>*); template <class T> struct is_promote_double_imp { template <bool N> static char test(const promote_double<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_promote_double : public boost::mpl::bool_< ::boost::math::policies::detail::is_promote_double_imp<T>::value>{}; >template <bool N = true> struct assert_undefined : public boost::mpl::bool_<N>{}; namespace detail{ template <bool N> char test_is_valid_arg(const assert_undefined<N>*); char test_is_default_arg(const assert_undefined<true>*); template <class T> struct is_assert_undefined_imp { template <bool N> static char test(const assert_undefined<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_assert_undefined : public boost::mpl::bool_< ::boost::math::policies::detail::is_assert_undefined_imp<T>::value>{}; > > > >enum discrete_quantile_policy_type >{ > real, > integer_round_outwards, > integer_round_inwards, > integer_round_down, > integer_round_up, > integer_round_nearest >}; > >template <discrete_quantile_policy_type N = integer_round_outwards> struct discrete_quantile : public boost::mpl::int_<N>{}; namespace detail{ template <discrete_quantile_policy_type N> char test_is_valid_arg(const discrete_quantile<N>*); char test_is_default_arg(const discrete_quantile<integer_round_outwards>*); template <class T> struct is_discrete_quantile_imp { template <discrete_quantile_policy_type N> static char test(const discrete_quantile<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_discrete_quantile : public boost::mpl::bool_< ::boost::math::policies::detail::is_discrete_quantile_imp<T>::value>{}; > > > >template <int N = 0> struct digits10 : public boost::mpl::int_<N>{}; namespace detail{ template <int N> char test_is_valid_arg(const digits10<N>*); char test_is_default_arg(const digits10<0>*); template <class T> struct is_digits10_imp { template <int N> static char test(const digits10<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_digits10 : public boost::mpl::bool_< ::boost::math::policies::detail::is_digits10_imp<T>::value>{}; >template <int N = 0> struct digits2 : public boost::mpl::int_<N>{}; namespace detail{ template <int N> char test_is_valid_arg(const digits2<N>*); char test_is_default_arg(const digits2<0>*); template <class T> struct is_digits2_imp { template <int N> static char test(const digits2<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_digits2 : public boost::mpl::bool_< ::boost::math::policies::detail::is_digits2_imp<T>::value>{}; > > > >template <unsigned long N = 1000000> struct max_series_iterations : public boost::mpl::int_<N>{}; namespace detail{ template <unsigned long N> char test_is_valid_arg(const max_series_iterations<N>*); char test_is_default_arg(const max_series_iterations<1000000>*); template <class T> struct is_max_series_iterations_imp { template <unsigned long N> static char test(const max_series_iterations<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_max_series_iterations : public boost::mpl::bool_< ::boost::math::policies::detail::is_max_series_iterations_imp<T>::value>{}; >template <unsigned long N = 200> struct max_root_iterations : public boost::mpl::int_<N>{}; namespace detail{ template <unsigned long N> char test_is_valid_arg(const max_root_iterations<N>*); char test_is_default_arg(const max_root_iterations<200>*); template <class T> struct is_max_root_iterations_imp { template <unsigned long N> static char test(const max_root_iterations<N>*); static double test(...); static const bool value = sizeof(test(static_cast<T*>(0))) == 1; }; } template <class T> struct is_max_root_iterations : public boost::mpl::bool_< ::boost::math::policies::detail::is_max_root_iterations_imp<T>::value>{}; > > > > > > > >struct default_policy{}; > >namespace detail{ > > > >template <class Digits10, class Digits2> >struct precision >{ > > > > typedef typename mpl::if_c< > (Digits10::value == 0), > digits2<0>, > digits2<((Digits10::value + 1) * 1000L) / 301L> > >::type digits2_type; >public: > > > > > > typedef typename mpl::if_c< > (Digits2::value > digits2_type::value), > Digits2, digits2_type>::type type; > >}; > >template <class A, class B, bool b> >struct select_result >{ > typedef A type; >}; >template <class A, class B> >struct select_result<A, B, false> >{ > typedef typename mpl::deref<B>::type type; >}; > >template <class Seq, class Pred, class DefaultType> >struct find_arg >{ >private: > typedef typename mpl::find_if<Seq, Pred>::type iter; > typedef typename mpl::end<Seq>::type end_type; >public: > typedef typename select_result< > DefaultType, iter, > ::boost::is_same<iter, end_type>::value>::type type; >}; > >double test_is_valid_arg(...); >double test_is_default_arg(...); >char test_is_valid_arg(const default_policy*); >char test_is_default_arg(const default_policy*); > >template <class T> >struct is_valid_policy_imp >{ > static const bool value = sizeof(::boost::math::policies::detail::test_is_valid_arg(static_cast<T*>(0))) == 1; >}; > >template <class T> >struct is_default_policy_imp >{ > static const bool value = sizeof(::boost::math::policies::detail::test_is_default_arg(static_cast<T*>(0))) == 1; >}; > >template <class T> struct is_valid_policy >: public mpl::bool_< > ::boost::math::policies::detail::is_valid_policy_imp<T>::value> >{}; > >template <class T> struct is_default_policy >: public mpl::bool_< > ::boost::math::policies::detail::is_default_policy_imp<T>::value> >{ > template <class U> > struct apply > { > typedef is_default_policy<U> type; > }; >}; > >template <class Seq, class T, int N> >struct append_N >{ > typedef typename mpl::push_back<Seq, T>::type new_seq; > typedef typename append_N<new_seq, T, N-1>::type type; >}; > >template <class Seq, class T> >struct append_N<Seq, T, 0> >{ > typedef Seq type; >}; > > > > > >template <bool f, bool d> >struct default_args >{ > typedef promote_float<false> arg1; > typedef promote_double<false> arg2; >}; > >template <> >struct default_args<false, false> >{ > typedef default_policy arg1; > typedef default_policy arg2; >}; > >template <> >struct default_args<true, false> >{ > typedef promote_float<false> arg1; > typedef default_policy arg2; >}; > >template <> >struct default_args<false, true> >{ > typedef promote_double<false> arg1; > typedef default_policy arg2; >}; > >typedef default_args<true, true>::arg1 forwarding_arg1; >typedef default_args<true, true>::arg2 forwarding_arg2; > >} > > > > >template <class A1 = default_policy, > class A2 = default_policy, > class A3 = default_policy, > class A4 = default_policy, > class A5 = default_policy, > class A6 = default_policy, > class A7 = default_policy, > class A8 = default_policy, > class A9 = default_policy, > class A10 = default_policy, > class A11 = default_policy, > class A12 = default_policy, > class A13 = default_policy> >struct policy >{ >private: > > > > static_assert(::boost::math::policies::detail::is_valid_policy<A1>::value, "::boost::math::policies::detail::is_valid_policy<A1>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A2>::value, "::boost::math::policies::detail::is_valid_policy<A2>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A3>::value, "::boost::math::policies::detail::is_valid_policy<A3>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A4>::value, "::boost::math::policies::detail::is_valid_policy<A4>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A5>::value, "::boost::math::policies::detail::is_valid_policy<A5>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A6>::value, "::boost::math::policies::detail::is_valid_policy<A6>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A7>::value, "::boost::math::policies::detail::is_valid_policy<A7>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A8>::value, "::boost::math::policies::detail::is_valid_policy<A8>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A9>::value, "::boost::math::policies::detail::is_valid_policy<A9>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A10>::value, "::boost::math::policies::detail::is_valid_policy<A10>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A11>::value, "::boost::math::policies::detail::is_valid_policy<A11>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A12>::value, "::boost::math::policies::detail::is_valid_policy<A12>::value"); > static_assert(::boost::math::policies::detail::is_valid_policy<A13>::value, "::boost::math::policies::detail::is_valid_policy<A13>::value"); > > > > typedef mpl::list<A1,A2,A3,A4,A5,A6,A7,A8,A9,A10,A11,A12,A13> arg_list; > >public: > typedef typename detail::find_arg<arg_list, is_domain_error<mpl::_1>, domain_error<> >::type domain_error_type; > typedef typename detail::find_arg<arg_list, is_pole_error<mpl::_1>, pole_error<> >::type pole_error_type; > typedef typename detail::find_arg<arg_list, is_overflow_error<mpl::_1>, overflow_error<> >::type overflow_error_type; > typedef typename detail::find_arg<arg_list, is_underflow_error<mpl::_1>, underflow_error<> >::type underflow_error_type; > typedef typename detail::find_arg<arg_list, is_denorm_error<mpl::_1>, denorm_error<> >::type denorm_error_type; > typedef typename detail::find_arg<arg_list, is_evaluation_error<mpl::_1>, evaluation_error<> >::type evaluation_error_type; > typedef typename detail::find_arg<arg_list, is_rounding_error<mpl::_1>, rounding_error<> >::type rounding_error_type; > typedef typename detail::find_arg<arg_list, is_indeterminate_result_error<mpl::_1>, indeterminate_result_error<> >::type indeterminate_result_error_type; >private: > > > > typedef typename detail::find_arg<arg_list, is_digits10<mpl::_1>, digits10<> >::type digits10_type; > typedef typename detail::find_arg<arg_list, is_digits2<mpl::_1>, digits2<> >::type bits_precision_type; >public: > typedef typename detail::precision<digits10_type, bits_precision_type>::type precision_type; > > > > typedef typename detail::find_arg<arg_list, is_promote_float<mpl::_1>, promote_float<> >::type promote_float_type; > typedef typename detail::find_arg<arg_list, is_promote_double<mpl::_1>, promote_double<> >::type promote_double_type; > > > > typedef typename detail::find_arg<arg_list, is_discrete_quantile<mpl::_1>, discrete_quantile<> >::type discrete_quantile_type; > > > > typedef typename detail::find_arg<arg_list, is_assert_undefined<mpl::_1>, assert_undefined<> >::type assert_undefined_type; > > > > typedef typename detail::find_arg<arg_list, is_max_series_iterations<mpl::_1>, max_series_iterations<> >::type max_series_iterations_type; > typedef typename detail::find_arg<arg_list, is_max_root_iterations<mpl::_1>, max_root_iterations<> >::type max_root_iterations_type; >}; > > > > > >template <> >struct policy<default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy> >{ >public: > typedef domain_error<> domain_error_type; > typedef pole_error<> pole_error_type; > typedef overflow_error<> overflow_error_type; > typedef underflow_error<> underflow_error_type; > typedef denorm_error<> denorm_error_type; > typedef evaluation_error<> evaluation_error_type; > typedef rounding_error<> rounding_error_type; > typedef indeterminate_result_error<> indeterminate_result_error_type; > > typedef digits2<> precision_type; > > > > typedef promote_float<> promote_float_type; > typedef promote_double<> promote_double_type; > typedef discrete_quantile<> discrete_quantile_type; > typedef assert_undefined<> assert_undefined_type; > typedef max_series_iterations<> max_series_iterations_type; > typedef max_root_iterations<> max_root_iterations_type; >}; > >template <> >struct policy<detail::forwarding_arg1, detail::forwarding_arg2, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy, default_policy> >{ >public: > typedef domain_error<> domain_error_type; > typedef pole_error<> pole_error_type; > typedef overflow_error<> overflow_error_type; > typedef underflow_error<> underflow_error_type; > typedef denorm_error<> denorm_error_type; > typedef evaluation_error<> evaluation_error_type; > typedef rounding_error<> rounding_error_type; > typedef indeterminate_result_error<> indeterminate_result_error_type; > > typedef digits2<> precision_type; > > > > typedef promote_float<false> promote_float_type; > typedef promote_double<false> promote_double_type; > typedef discrete_quantile<> discrete_quantile_type; > typedef assert_undefined<> assert_undefined_type; > typedef max_series_iterations<> max_series_iterations_type; > typedef max_root_iterations<> max_root_iterations_type; >}; > >template <class Policy, > class A1 = default_policy, > class A2 = default_policy, > class A3 = default_policy, > class A4 = default_policy, > class A5 = default_policy, > class A6 = default_policy, > class A7 = default_policy, > class A8 = default_policy, > class A9 = default_policy, > class A10 = default_policy, > class A11 = default_policy, > class A12 = default_policy, > class A13 = default_policy> >struct normalise >{ >private: > typedef mpl::list<A1,A2,A3,A4,A5,A6,A7,A8,A9,A10,A11,A12,A13> arg_list; > typedef typename detail::find_arg<arg_list, is_domain_error<mpl::_1>, typename Policy::domain_error_type >::type domain_error_type; > typedef typename detail::find_arg<arg_list, is_pole_error<mpl::_1>, typename Policy::pole_error_type >::type pole_error_type; > typedef typename detail::find_arg<arg_list, is_overflow_error<mpl::_1>, typename Policy::overflow_error_type >::type overflow_error_type; > typedef typename detail::find_arg<arg_list, is_underflow_error<mpl::_1>, typename Policy::underflow_error_type >::type underflow_error_type; > typedef typename detail::find_arg<arg_list, is_denorm_error<mpl::_1>, typename Policy::denorm_error_type >::type denorm_error_type; > typedef typename detail::find_arg<arg_list, is_evaluation_error<mpl::_1>, typename Policy::evaluation_error_type >::type evaluation_error_type; > typedef typename detail::find_arg<arg_list, is_rounding_error<mpl::_1>, typename Policy::rounding_error_type >::type rounding_error_type; > typedef typename detail::find_arg<arg_list, is_indeterminate_result_error<mpl::_1>, typename Policy::indeterminate_result_error_type >::type indeterminate_result_error_type; > > > > typedef typename detail::find_arg<arg_list, is_digits10<mpl::_1>, digits10<> >::type digits10_type; > typedef typename detail::find_arg<arg_list, is_digits2<mpl::_1>, typename Policy::precision_type >::type bits_precision_type; > typedef typename detail::precision<digits10_type, bits_precision_type>::type precision_type; > > > > typedef typename detail::find_arg<arg_list, is_promote_float<mpl::_1>, typename Policy::promote_float_type >::type promote_float_type; > typedef typename detail::find_arg<arg_list, is_promote_double<mpl::_1>, typename Policy::promote_double_type >::type promote_double_type; > > > > typedef typename detail::find_arg<arg_list, is_discrete_quantile<mpl::_1>, typename Policy::discrete_quantile_type >::type discrete_quantile_type; > > > > typedef typename detail::find_arg<arg_list, is_assert_undefined<mpl::_1>, typename Policy::assert_undefined_type >::type assert_undefined_type; > > > > typedef typename detail::find_arg<arg_list, is_max_series_iterations<mpl::_1>, typename Policy::max_series_iterations_type>::type max_series_iterations_type; > typedef typename detail::find_arg<arg_list, is_max_root_iterations<mpl::_1>, typename Policy::max_root_iterations_type>::type max_root_iterations_type; > > > > typedef mpl::vector< > domain_error_type, > pole_error_type, > overflow_error_type, > underflow_error_type, > denorm_error_type, > evaluation_error_type, > rounding_error_type, > indeterminate_result_error_type, > precision_type, > promote_float_type, > promote_double_type, > discrete_quantile_type, > assert_undefined_type, > max_series_iterations_type, > max_root_iterations_type> result_list; > > > > typedef typename mpl::remove_if<result_list, detail::is_default_policy<mpl::_> >::type reduced_list; > > > > typedef typename detail::append_N<reduced_list, default_policy, (14 - ::boost::mpl::size<reduced_list>::value)>::type result_type; >public: > typedef policy< > typename mpl::at<result_type, mpl::int_<0> >::type, > typename mpl::at<result_type, mpl::int_<1> >::type, > typename mpl::at<result_type, mpl::int_<2> >::type, > typename mpl::at<result_type, mpl::int_<3> >::type, > typename mpl::at<result_type, mpl::int_<4> >::type, > typename mpl::at<result_type, mpl::int_<5> >::type, > typename mpl::at<result_type, mpl::int_<6> >::type, > typename mpl::at<result_type, mpl::int_<7> >::type, > typename mpl::at<result_type, mpl::int_<8> >::type, > typename mpl::at<result_type, mpl::int_<9> >::type, > typename mpl::at<result_type, mpl::int_<10> >::type, > typename mpl::at<result_type, mpl::int_<11> >::type, > typename mpl::at<result_type, mpl::int_<12> >::type > type; >}; > > > >template <> >struct normalise<policy<>, > promote_float<false>, > promote_double<false>, > discrete_quantile<>, > assert_undefined<>, > default_policy, > default_policy, > default_policy, > default_policy, > default_policy, > default_policy, > default_policy> >{ > typedef policy<detail::forwarding_arg1, detail::forwarding_arg2> type; >}; > >template <> >struct normalise<policy<detail::forwarding_arg1, detail::forwarding_arg2>, > promote_float<false>, > promote_double<false>, > discrete_quantile<>, > assert_undefined<>, > default_policy, > default_policy, > default_policy, > default_policy, > default_policy, > default_policy, > default_policy> >{ > typedef policy<detail::forwarding_arg1, detail::forwarding_arg2> type; >}; > >inline policy<> make_policy() >{ return policy<>(); } > >template <class A1> >inline typename normalise<policy<>, A1>::type make_policy(const A1&) >{ > typedef typename normalise<policy<>, A1>::type result_type; > return result_type(); >} > >template <class A1, class A2> >inline typename normalise<policy<>, A1, A2>::type make_policy(const A1&, const A2&) >{ > typedef typename normalise<policy<>, A1, A2>::type result_type; > return result_type(); >} > >template <class A1, class A2, class A3> >inline typename normalise<policy<>, A1, A2, A3>::type make_policy(const A1&, const A2&, const A3&) >{ > typedef typename normalise<policy<>, A1, A2, A3>::type result_type; > return result_type(); >} > >template <class A1, class A2, class A3, class A4> >inline typename normalise<policy<>, A1, A2, A3, A4>::type make_policy(const A1&, const A2&, const A3&, const A4&) >{ > typedef typename normalise<policy<>, A1, A2, A3, A4>::type result_type; > return result_type(); >} > >template <class A1, class A2, class A3, class A4, class A5> >inline typename normalise<policy<>, A1, A2, A3, A4, A5>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&) >{ > typedef typename normalise<policy<>, A1, A2, A3, A4, A5>::type result_type; > return result_type(); >} > >template <class A1, class A2, class A3, class A4, class A5, class A6> >inline typename normalise<policy<>, A1, A2, A3, A4, A5, A6>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&) >{ > typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6>::type result_type; > return result_type(); >} > >template <class A1, class A2, class A3, class A4, class A5, class A6, class A7> >inline typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&) >{ > typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7>::type result_type; > return result_type(); >} > >template <class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> >inline typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&) >{ > typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8>::type result_type; > return result_type(); >} > >template <class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> >inline typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&, const A9&) >{ > typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9>::type result_type; > return result_type(); >} > >template <class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9, class A10> >inline typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&, const A9&, const A10&) >{ > typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10>::type result_type; > return result_type(); >} > >template <class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9, class A10, class A11> >inline typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10, A11>::type make_policy(const A1&, const A2&, const A3&, const A4&, const A5&, const A6&, const A7&, const A8&, const A9&, const A10&, const A11&) >{ > typedef typename normalise<policy<>, A1, A2, A3, A4, A5, A6, A7, A8, A9, A10, A11>::type result_type; > return result_type(); >} > > > > >template <class Real, class Policy> >struct evaluation >{ > typedef Real type; >}; > >template <class Policy> >struct evaluation<float, Policy> >{ > typedef typename mpl::if_<typename Policy::promote_float_type, double, float>::type type; >}; > >template <class Policy> >struct evaluation<double, Policy> >{ > typedef typename mpl::if_<typename Policy::promote_double_type, long double, double>::type type; >}; ># 776 "/usr/include/boost/math/policies/policy.hpp" 3 4 >template <class Real, class Policy> >struct precision >{ > static_assert((::std::numeric_limits<Real>::radix == 2) || ((::std::numeric_limits<Real>::is_specialized == 0) || (::std::numeric_limits<Real>::digits == 0)), "(::std::numeric_limits<Real>::radix == 2) || ((::std::numeric_limits<Real>::is_specialized == 0) || (::std::numeric_limits<Real>::digits == 0))"); > > typedef typename Policy::precision_type precision_type; > typedef typename mpl::if_c< > ((::std::numeric_limits<Real>::is_specialized == 0) || (::std::numeric_limits<Real>::digits == 0)), > > precision_type, > typename mpl::if_c< > ((::std::numeric_limits<Real>::digits <= precision_type::value) > || (Policy::precision_type::value <= 0)), > > digits2< ::std::numeric_limits<Real>::digits>, > > precision_type > >::type > >::type type; ># 812 "/usr/include/boost/math/policies/policy.hpp" 3 4 >}; > > > > > >template <class Policy> >struct precision<__float128, Policy> >{ > typedef mpl::int_<113> type; >}; > > > >namespace detail{ > >template <class T, class Policy> >inline int digits_imp(mpl::true_ const&) >{ > > static_assert(::std::numeric_limits<T>::is_specialized, "::std::numeric_limits<T>::is_specialized"); > > > > typedef typename boost::math::policies::precision<T, Policy>::type p_t; > return p_t::value; >} > >template <class T, class Policy> >inline int digits_imp(mpl::false_ const&) >{ > return tools::digits<T>(); >} > >} > >template <class T, class Policy> >inline int digits() >{ > typedef mpl::bool_< std::numeric_limits<T>::is_specialized > tag_type; > return detail::digits_imp<T, Policy>(tag_type()); >} > >template <class Policy> >inline unsigned long get_max_series_iterations() >{ > typedef typename Policy::max_series_iterations_type iter_type; > return iter_type::value; >} > >template <class Policy> >inline unsigned long get_max_root_iterations() >{ > typedef typename Policy::max_root_iterations_type iter_type; > return iter_type::value; >} > >namespace detail{ > >template <class T, class Digits, class Small, class Default> >struct series_factor_calc >{ > static T get() > { > return ldexp(T(1.0), 1 - Digits::value); > } >}; > >template <class T, class Digits> >struct series_factor_calc<T, Digits, mpl::true_, mpl::true_> >{ > static T get() > { > return boost::math::tools::epsilon<T>(); > } >}; >template <class T, class Digits> >struct series_factor_calc<T, Digits, mpl::true_, mpl::false_> >{ > static T get() > { > static const boost::uintmax_t v = static_cast<boost::uintmax_t>(1u) << (Digits::value - 1); > return 1 / static_cast<T>(v); > } >}; >template <class T, class Digits> >struct series_factor_calc<T, Digits, mpl::false_, mpl::true_> >{ > static T get() > { > return boost::math::tools::epsilon<T>(); > } >}; > >template <class T, class Policy> >inline T get_epsilon_imp(mpl::true_ const&) >{ > > static_assert(::std::numeric_limits<T>::is_specialized, "::std::numeric_limits<T>::is_specialized"); > static_assert(::std::numeric_limits<T>::radix == 2, "::std::numeric_limits<T>::radix == 2"); > > > > > typedef typename boost::math::policies::precision<T, Policy>::type p_t; > typedef mpl::bool_<p_t::value <= std::numeric_limits<boost::uintmax_t>::digits> is_small_int; > typedef mpl::bool_<p_t::value >= std::numeric_limits<T>::digits> is_default_value; > return series_factor_calc<T, p_t, is_small_int, is_default_value>::get(); >} > >template <class T, class Policy> >inline T get_epsilon_imp(mpl::false_ const&) >{ > return tools::epsilon<T>(); >} > >} > >template <class T, class Policy> >inline T get_epsilon() >{ > typedef mpl::bool_< (std::numeric_limits<T>::is_specialized && (std::numeric_limits<T>::radix == 2)) > tag_type; > return detail::get_epsilon_imp<T, Policy>(tag_type()); >} > >namespace detail{ > >template <class A1, > class A2, > class A3, > class A4, > class A5, > class A6, > class A7, > class A8, > class A9, > class A10, > class A11> >char test_is_policy(const policy<A1,A2,A3,A4,A5,A6,A7,A8,A9,A10,A11>*); >double test_is_policy(...); > >template <class P> >struct is_policy_imp >{ > static const bool value = (sizeof(::boost::math::policies::detail::test_is_policy(static_cast<P*>(0))) == 1); >}; > >} > >template <class P> >struct is_policy : public mpl::bool_< ::boost::math::policies::detail::is_policy_imp<P>::value> {}; > > > > >template <class Policy> >struct constructor_error_check >{ > typedef typename Policy::domain_error_type domain_error_type; > typedef typename mpl::if_c< > (domain_error_type::value == throw_on_error) || (domain_error_type::value == user_error), > mpl::true_, > mpl::false_>::type type; >}; > >template <class Policy> >struct method_error_check >{ > typedef typename Policy::domain_error_type domain_error_type; > typedef typename mpl::if_c< > (domain_error_type::value == throw_on_error) && (domain_error_type::value != user_error), > mpl::false_, > mpl::true_>::type type; >}; > >}}} ># 29 "/usr/include/boost/math/special_functions/math_fwd.hpp" 2 3 4 > ># 1 "/usr/include/boost/config/no_tr1/complex.hpp" 1 3 4 ># 31 "/usr/include/boost/math/special_functions/math_fwd.hpp" 2 3 4 > > > >namespace boost >{ > namespace math > { > > > template <class RT1, class RT2> > typename tools::promote_args<RT1, RT2>::type > beta(RT1 a, RT2 b); > > template <class RT1, class RT2, class A> > typename tools::promote_args<RT1, RT2, A>::type > beta(RT1 a, RT2 b, A x); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > beta(RT1 a, RT2 b, RT3 x, const Policy& pol); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > betac(RT1 a, RT2 b, RT3 x); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > betac(RT1 a, RT2 b, RT3 x, const Policy& pol); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta(RT1 a, RT2 b, RT3 x); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta(RT1 a, RT2 b, RT3 x, const Policy& pol); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > ibetac(RT1 a, RT2 b, RT3 x); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > ibetac(RT1 a, RT2 b, RT3 x, const Policy& pol); > > template <class T1, class T2, class T3, class T4> > typename tools::promote_args<T1, T2, T3, T4>::type > ibeta_inv(T1 a, T2 b, T3 p, T4* py); > > template <class T1, class T2, class T3, class T4, class Policy> > typename tools::promote_args<T1, T2, T3, T4>::type > ibeta_inv(T1 a, T2 b, T3 p, T4* py, const Policy& pol); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta_inv(RT1 a, RT2 b, RT3 p); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta_inv(RT1 a, RT2 b, RT3 p, const Policy&); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta_inva(RT1 a, RT2 b, RT3 p); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta_inva(RT1 a, RT2 b, RT3 p, const Policy&); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta_invb(RT1 a, RT2 b, RT3 p); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta_invb(RT1 a, RT2 b, RT3 p, const Policy&); > > template <class T1, class T2, class T3, class T4> > typename tools::promote_args<T1, T2, T3, T4>::type > ibetac_inv(T1 a, T2 b, T3 q, T4* py); > > template <class T1, class T2, class T3, class T4, class Policy> > typename tools::promote_args<T1, T2, T3, T4>::type > ibetac_inv(T1 a, T2 b, T3 q, T4* py, const Policy& pol); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > ibetac_inv(RT1 a, RT2 b, RT3 q); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > ibetac_inv(RT1 a, RT2 b, RT3 q, const Policy&); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > ibetac_inva(RT1 a, RT2 b, RT3 q); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > ibetac_inva(RT1 a, RT2 b, RT3 q, const Policy&); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > ibetac_invb(RT1 a, RT2 b, RT3 q); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > ibetac_invb(RT1 a, RT2 b, RT3 q, const Policy&); > > template <class RT1, class RT2, class RT3> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta_derivative(RT1 a, RT2 b, RT3 x); > > template <class RT1, class RT2, class RT3, class Policy> > typename tools::promote_args<RT1, RT2, RT3>::type > ibeta_derivative(RT1 a, RT2 b, RT3 x, const Policy& pol); > > > template <class RT> > typename tools::promote_args<RT>::type erf(RT z); > template <class RT, class Policy> > typename tools::promote_args<RT>::type erf(RT z, const Policy&); > > template <class RT> > typename tools::promote_args<RT>::type erfc(RT z); > template <class RT, class Policy> > typename tools::promote_args<RT>::type erfc(RT z, const Policy&); > > template <class RT> > typename tools::promote_args<RT>::type erf_inv(RT z); > template <class RT, class Policy> > typename tools::promote_args<RT>::type erf_inv(RT z, const Policy& pol); > > template <class RT> > typename tools::promote_args<RT>::type erfc_inv(RT z); > template <class RT, class Policy> > typename tools::promote_args<RT>::type erfc_inv(RT z, const Policy& pol); > > > template <class T1, class T2, class T3> > typename tools::promote_args<T1, T2, T3>::type > legendre_next(unsigned l, T1 x, T2 Pl, T3 Plm1); > > template <class T> > typename tools::promote_args<T>::type > legendre_p(int l, T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type > legendre_p(int l, T x, const Policy& pol); > > template <class T> > typename tools::promote_args<T>::type > legendre_q(unsigned l, T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type > legendre_q(unsigned l, T x, const Policy& pol); > > template <class T1, class T2, class T3> > typename tools::promote_args<T1, T2, T3>::type > legendre_next(unsigned l, unsigned m, T1 x, T2 Pl, T3 Plm1); > > template <class T> > typename tools::promote_args<T>::type > legendre_p(int l, int m, T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type > legendre_p(int l, int m, T x, const Policy& pol); > > template <class T1, class T2, class T3> > typename tools::promote_args<T1, T2, T3>::type > laguerre_next(unsigned n, T1 x, T2 Ln, T3 Lnm1); > > template <class T1, class T2, class T3> > typename tools::promote_args<T1, T2, T3>::type > laguerre_next(unsigned n, unsigned l, T1 x, T2 Pl, T3 Plm1); > > template <class T> > typename tools::promote_args<T>::type > laguerre(unsigned n, T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type > laguerre(unsigned n, unsigned m, T x, const Policy& pol); > > template <class T1, class T2> > struct laguerre_result > { > typedef typename mpl::if_< > policies::is_policy<T2>, > typename tools::promote_args<T1>::type, > typename tools::promote_args<T2>::type > >::type type; > }; > > template <class T1, class T2> > typename laguerre_result<T1, T2>::type > laguerre(unsigned n, T1 m, T2 x); > > template <class T> > typename tools::promote_args<T>::type > hermite(unsigned n, T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type > hermite(unsigned n, T x, const Policy& pol); > > template <class T1, class T2, class T3> > typename tools::promote_args<T1, T2, T3>::type > hermite_next(unsigned n, T1 x, T2 Hn, T3 Hnm1); > > template <class T1, class T2> > std::complex<typename tools::promote_args<T1, T2>::type> > spherical_harmonic(unsigned n, int m, T1 theta, T2 phi); > > template <class T1, class T2, class Policy> > std::complex<typename tools::promote_args<T1, T2>::type> > spherical_harmonic(unsigned n, int m, T1 theta, T2 phi, const Policy& pol); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type > spherical_harmonic_r(unsigned n, int m, T1 theta, T2 phi); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type > spherical_harmonic_r(unsigned n, int m, T1 theta, T2 phi, const Policy& pol); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type > spherical_harmonic_i(unsigned n, int m, T1 theta, T2 phi); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type > spherical_harmonic_i(unsigned n, int m, T1 theta, T2 phi, const Policy& pol); > > > template <class T1, class T2, class T3> > typename tools::promote_args<T1, T2, T3>::type > ellint_rf(T1 x, T2 y, T3 z); > > template <class T1, class T2, class T3, class Policy> > typename tools::promote_args<T1, T2, T3>::type > ellint_rf(T1 x, T2 y, T3 z, const Policy& pol); > > template <class T1, class T2, class T3> > typename tools::promote_args<T1, T2, T3>::type > ellint_rd(T1 x, T2 y, T3 z); > > template <class T1, class T2, class T3, class Policy> > typename tools::promote_args<T1, T2, T3>::type > ellint_rd(T1 x, T2 y, T3 z, const Policy& pol); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type > ellint_rc(T1 x, T2 y); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type > ellint_rc(T1 x, T2 y, const Policy& pol); > > template <class T1, class T2, class T3, class T4> > typename tools::promote_args<T1, T2, T3, T4>::type > ellint_rj(T1 x, T2 y, T3 z, T4 p); > > template <class T1, class T2, class T3, class T4, class Policy> > typename tools::promote_args<T1, T2, T3, T4>::type > ellint_rj(T1 x, T2 y, T3 z, T4 p, const Policy& pol); > > template <typename T> > typename tools::promote_args<T>::type ellint_2(T k); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type ellint_2(T1 k, T2 phi); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type ellint_2(T1 k, T2 phi, const Policy& pol); > > template <typename T> > typename tools::promote_args<T>::type ellint_1(T k); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type ellint_1(T1 k, T2 phi); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type ellint_1(T1 k, T2 phi, const Policy& pol); > > namespace detail{ > > template <class T, class U, class V> > struct ellint_3_result > { > typedef typename mpl::if_< > policies::is_policy<V>, > typename tools::promote_args<T, U>::type, > typename tools::promote_args<T, U, V>::type > >::type type; > }; > > } > > > template <class T1, class T2, class T3> > typename detail::ellint_3_result<T1, T2, T3>::type ellint_3(T1 k, T2 v, T3 phi); > > template <class T1, class T2, class T3, class Policy> > typename tools::promote_args<T1, T2, T3>::type ellint_3(T1 k, T2 v, T3 phi, const Policy& pol); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type ellint_3(T1 k, T2 v); > > > > template <class RT> > struct max_factorial; > template <class RT> > RT factorial(unsigned int); > template <class RT, class Policy> > RT factorial(unsigned int, const Policy& pol); > template <class RT> > RT unchecked_factorial(unsigned int ); > template <class RT> > RT double_factorial(unsigned i); > template <class RT, class Policy> > RT double_factorial(unsigned i, const Policy& pol); > > template <class RT> > typename tools::promote_args<RT>::type falling_factorial(RT x, unsigned n); > > template <class RT, class Policy> > typename tools::promote_args<RT>::type falling_factorial(RT x, unsigned n, const Policy& pol); > > template <class RT> > typename tools::promote_args<RT>::type rising_factorial(RT x, int n); > > template <class RT, class Policy> > typename tools::promote_args<RT>::type rising_factorial(RT x, int n, const Policy& pol); > > > template <class RT> > typename tools::promote_args<RT>::type tgamma(RT z); > > template <class RT> > typename tools::promote_args<RT>::type tgamma1pm1(RT z); > > template <class RT, class Policy> > typename tools::promote_args<RT>::type tgamma1pm1(RT z, const Policy& pol); > > template <class RT1, class RT2> > typename tools::promote_args<RT1, RT2>::type tgamma(RT1 a, RT2 z); > > template <class RT1, class RT2, class Policy> > typename tools::promote_args<RT1, RT2>::type tgamma(RT1 a, RT2 z, const Policy& pol); > > template <class RT> > typename tools::promote_args<RT>::type lgamma(RT z, int* sign); > > template <class RT, class Policy> > typename tools::promote_args<RT>::type lgamma(RT z, int* sign, const Policy& pol); > > template <class RT> > typename tools::promote_args<RT>::type lgamma(RT x); > > template <class RT, class Policy> > typename tools::promote_args<RT>::type lgamma(RT x, const Policy& pol); > > template <class RT1, class RT2> > typename tools::promote_args<RT1, RT2>::type tgamma_lower(RT1 a, RT2 z); > > template <class RT1, class RT2, class Policy> > typename tools::promote_args<RT1, RT2>::type tgamma_lower(RT1 a, RT2 z, const Policy&); > > template <class RT1, class RT2> > typename tools::promote_args<RT1, RT2>::type gamma_q(RT1 a, RT2 z); > > template <class RT1, class RT2, class Policy> > typename tools::promote_args<RT1, RT2>::type gamma_q(RT1 a, RT2 z, const Policy&); > > template <class RT1, class RT2> > typename tools::promote_args<RT1, RT2>::type gamma_p(RT1 a, RT2 z); > > template <class RT1, class RT2, class Policy> > typename tools::promote_args<RT1, RT2>::type gamma_p(RT1 a, RT2 z, const Policy&); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type tgamma_delta_ratio(T1 z, T2 delta); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type tgamma_delta_ratio(T1 z, T2 delta, const Policy&); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type tgamma_ratio(T1 a, T2 b); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type tgamma_ratio(T1 a, T2 b, const Policy&); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type gamma_p_derivative(T1 a, T2 x); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type gamma_p_derivative(T1 a, T2 x, const Policy&); > > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type gamma_p_inv(T1 a, T2 p); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type gamma_p_inva(T1 a, T2 p, const Policy&); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type gamma_p_inva(T1 a, T2 p); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type gamma_p_inv(T1 a, T2 p, const Policy&); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type gamma_q_inv(T1 a, T2 q); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type gamma_q_inv(T1 a, T2 q, const Policy&); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type gamma_q_inva(T1 a, T2 q); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type gamma_q_inva(T1 a, T2 q, const Policy&); > > > template <class T> > typename tools::promote_args<T>::type digamma(T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type digamma(T x, const Policy&); > > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type > hypot(T1 x, T2 y); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type > hypot(T1 x, T2 y, const Policy&); > > > template <class RT> > typename tools::promote_args<RT>::type cbrt(RT z); > > template <class RT, class Policy> > typename tools::promote_args<RT>::type cbrt(RT z, const Policy&); > > > template <class T> > typename tools::promote_args<T>::type log1p(T); > > template <class T, class Policy> > typename tools::promote_args<T>::type log1p(T, const Policy&); > > > template <class T> > typename tools::promote_args<T>::type log1pmx(T); > > template <class T, class Policy> > typename tools::promote_args<T>::type log1pmx(T, const Policy&); > > > template <class T> > typename tools::promote_args<T>::type expm1(T); > > template <class T, class Policy> > typename tools::promote_args<T>::type expm1(T, const Policy&); > > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type > powm1(const T1 a, const T2 z); > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type > powm1(const T1 a, const T2 z, const Policy&); > > > template <class T> > typename tools::promote_args<T>::type sqrt1pm1(const T& val); > > template <class T, class Policy> > typename tools::promote_args<T>::type sqrt1pm1(const T& val, const Policy&); > > > template <class T> > typename tools::promote_args<T>::type sinc_pi(T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type sinc_pi(T x, const Policy&); > > template <class T> > typename tools::promote_args<T>::type sinhc_pi(T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type sinhc_pi(T x, const Policy&); > > > template<typename T> > typename tools::promote_args<T>::type asinh(T x); > > template<typename T, class Policy> > typename tools::promote_args<T>::type asinh(T x, const Policy&); > > template<typename T> > typename tools::promote_args<T>::type acosh(T x); > > template<typename T, class Policy> > typename tools::promote_args<T>::type acosh(T x, const Policy&); > > template<typename T> > typename tools::promote_args<T>::type atanh(T x); > > template<typename T, class Policy> > typename tools::promote_args<T>::type atanh(T x, const Policy&); > > namespace detail{ > > typedef mpl::int_<0> bessel_no_int_tag; > typedef mpl::int_<1> bessel_maybe_int_tag; > typedef mpl::int_<2> bessel_int_tag; > > template <class T1, class T2, class Policy> > struct bessel_traits > { > typedef typename tools::promote_args< > T1, T2 > >::type result_type; > > typedef typename policies::precision<result_type, Policy>::type precision_type; > > typedef typename mpl::if_< > mpl::or_< > mpl::less_equal<precision_type, mpl::int_<0> >, > mpl::greater<precision_type, mpl::int_<64> > >, > bessel_no_int_tag, > typename mpl::if_< > is_integral<T1>, > bessel_int_tag, > bessel_maybe_int_tag > >::type > >::type optimisation_tag; > }; > } > > > template <class T1, class T2, class Policy> > typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_bessel_j(T1 v, T2 x, const Policy& pol); > > template <class T1, class T2> > typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_bessel_j(T1 v, T2 x); > > template <class T, class Policy> > typename detail::bessel_traits<T, T, Policy>::result_type sph_bessel(unsigned v, T x, const Policy& pol); > > template <class T> > typename detail::bessel_traits<T, T, policies::policy<> >::result_type sph_bessel(unsigned v, T x); > > template <class T1, class T2, class Policy> > typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_bessel_i(T1 v, T2 x, const Policy& pol); > > template <class T1, class T2> > typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_bessel_i(T1 v, T2 x); > > template <class T1, class T2, class Policy> > typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_bessel_k(T1 v, T2 x, const Policy& pol); > > template <class T1, class T2> > typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_bessel_k(T1 v, T2 x); > > template <class T1, class T2, class Policy> > typename detail::bessel_traits<T1, T2, Policy>::result_type cyl_neumann(T1 v, T2 x, const Policy& pol); > > template <class T1, class T2> > typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type cyl_neumann(T1 v, T2 x); > > template <class T, class Policy> > typename detail::bessel_traits<T, T, Policy>::result_type sph_neumann(unsigned v, T x, const Policy& pol); > > template <class T> > typename detail::bessel_traits<T, T, policies::policy<> >::result_type sph_neumann(unsigned v, T x); > > template <class T, class Policy> > typename detail::bessel_traits<T, T, Policy>::result_type cyl_bessel_j_zero(T v, int m, const Policy& pol); > > template <class T> > typename detail::bessel_traits<T, T, policies::policy<> >::result_type cyl_bessel_j_zero(T v, int m); > > template <class T, class OutputIterator> > OutputIterator cyl_bessel_j_zero(T v, > int start_index, > unsigned number_of_zeros, > OutputIterator out_it); > > template <class T, class OutputIterator, class Policy> > OutputIterator cyl_bessel_j_zero(T v, > int start_index, > unsigned number_of_zeros, > OutputIterator out_it, > const Policy&); > > template <class T, class Policy> > typename detail::bessel_traits<T, T, Policy>::result_type cyl_neumann_zero(T v, int m, const Policy& pol); > > template <class T> > typename detail::bessel_traits<T, T, policies::policy<> >::result_type cyl_neumann_zero(T v, int m); > > template <class T, class OutputIterator> > OutputIterator cyl_neumann_zero(T v, > int start_index, > unsigned number_of_zeros, > OutputIterator out_it); > > template <class T, class OutputIterator, class Policy> > OutputIterator cyl_neumann_zero(T v, > int start_index, > unsigned number_of_zeros, > OutputIterator out_it, > const Policy&); > > template <class T1, class T2> > std::complex<typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type> cyl_hankel_1(T1 v, T2 x); > > template <class T1, class T2, class Policy> > std::complex<typename detail::bessel_traits<T1, T2, Policy>::result_type> cyl_hankel_1(T1 v, T2 x, const Policy& pol); > > template <class T1, class T2, class Policy> > std::complex<typename detail::bessel_traits<T1, T2, Policy>::result_type> cyl_hankel_2(T1 v, T2 x, const Policy& pol); > > template <class T1, class T2> > std::complex<typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type> cyl_hankel_2(T1 v, T2 x); > > template <class T1, class T2, class Policy> > std::complex<typename detail::bessel_traits<T1, T2, Policy>::result_type> sph_hankel_1(T1 v, T2 x, const Policy& pol); > > template <class T1, class T2> > std::complex<typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type> sph_hankel_1(T1 v, T2 x); > > template <class T1, class T2, class Policy> > std::complex<typename detail::bessel_traits<T1, T2, Policy>::result_type> sph_hankel_2(T1 v, T2 x, const Policy& pol); > > template <class T1, class T2> > std::complex<typename detail::bessel_traits<T1, T2, policies::policy<> >::result_type> sph_hankel_2(T1 v, T2 x); > > template <class T, class Policy> > typename tools::promote_args<T>::type airy_ai(T x, const Policy&); > > template <class T> > typename tools::promote_args<T>::type airy_ai(T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type airy_bi(T x, const Policy&); > > template <class T> > typename tools::promote_args<T>::type airy_bi(T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type airy_ai_prime(T x, const Policy&); > > template <class T> > typename tools::promote_args<T>::type airy_ai_prime(T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type airy_bi_prime(T x, const Policy&); > > template <class T> > typename tools::promote_args<T>::type airy_bi_prime(T x); > > template <class T> > T airy_ai_zero(unsigned m); > template <class T, class Policy> > T airy_ai_zero(unsigned m, const Policy&); > > template <class OutputIterator> > OutputIterator airy_ai_zero( > unsigned start_index, > unsigned number_of_zeros, > OutputIterator out_it); > template <class OutputIterator, class Policy> > OutputIterator airy_ai_zero( > unsigned start_index, > unsigned number_of_zeros, > OutputIterator out_it, > const Policy&); > > template <class T> > T airy_bi_zero(unsigned m); > template <class T, class Policy> > T airy_bi_zero(unsigned m, const Policy&); > > template <class OutputIterator> > OutputIterator airy_bi_zero( > unsigned start_index, > unsigned number_of_zeros, > OutputIterator out_it); > template <class OutputIterator, class Policy> > OutputIterator airy_bi_zero( > unsigned start_index, > unsigned number_of_zeros, > OutputIterator out_it, > const Policy&); > > template <class T, class Policy> > typename tools::promote_args<T>::type sin_pi(T x, const Policy&); > > template <class T> > typename tools::promote_args<T>::type sin_pi(T x); > > template <class T, class Policy> > typename tools::promote_args<T>::type cos_pi(T x, const Policy&); > > template <class T> > typename tools::promote_args<T>::type cos_pi(T x); > > template <class T> > int fpclassify (T t); > > template <class T> > bool isfinite (T z); > > template <class T> > bool isinf (T t); > > template <class T> > bool isnan (T t); > > template <class T> > bool isnormal (T t); > > template<class T> > int signbit (T x); > > template <class T> > int sign (const T& z); > > template <class T, class U> > typename tools::promote_args_permissive<T, U>::type copysign (const T& x, const U& y); > > template <class T> > typename tools::promote_args_permissive<T>::type changesign (const T& z); > > > namespace detail{ > > template <class T, class U> > struct expint_result > { > typedef typename mpl::if_< > policies::is_policy<U>, > typename tools::promote_args<T>::type, > typename tools::promote_args<U>::type > >::type type; > }; > > } > > template <class T, class Policy> > typename tools::promote_args<T>::type expint(unsigned n, T z, const Policy&); > > template <class T, class U> > typename detail::expint_result<T, U>::type expint(T const z, U const u); > > template <class T> > typename tools::promote_args<T>::type expint(T z); > > > template <class T, class Policy> > typename tools::promote_args<T>::type zeta(T s, const Policy&); > > > template <class T1, class T2, class Policy> > typename tools::promote_args<T1, T2>::type owens_t(T1 h, T2 a, const Policy& pol); > > template <class T1, class T2> > typename tools::promote_args<T1, T2>::type owens_t(T1 h, T2 a); > > > template <class T, class U, class V, class Policy> > typename tools::promote_args<T, U, V>::type jacobi_elliptic(T k, U theta, V* pcn, V* pdn, const Policy&); > > template <class T, class U, class V> > typename tools::promote_args<T, U, V>::type jacobi_elliptic(T k, U theta, V* pcn = 0, V* pdn = 0); > > template <class U, class T, class Policy> > typename tools::promote_args<T, U>::type jacobi_sn(U k, T theta, const Policy& pol); > > template <class U, class T> > typename tools::promote_args<T, U>::type jacobi_sn(U k, T theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_cn(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_cn(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_dn(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_dn(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_cd(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_cd(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_dc(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_dc(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_ns(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_ns(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_sd(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_sd(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_ds(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_ds(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_nc(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_nc(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_nd(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_nd(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_sc(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_sc(T k, U theta); > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type jacobi_cs(T k, U theta, const Policy& pol); > > template <class T, class U> > typename tools::promote_args<T, U>::type jacobi_cs(T k, U theta); > > > template <class T> > typename tools::promote_args<T>::type zeta(T s); > > > template <int N, typename T, class Policy> > typename tools::promote_args<T>::type pow(T base, const Policy& policy); > > template <int N, typename T> > typename tools::promote_args<T>::type pow(T base); > > > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type nextafter(const T&, const U&, const Policy&); > template <class T, class U> > typename tools::promote_args<T, U>::type nextafter(const T&, const U&); > template <class T, class Policy> > typename tools::promote_args<T>::type float_next(const T&, const Policy&); > template <class T> > typename tools::promote_args<T>::type float_next(const T&); > template <class T, class Policy> > typename tools::promote_args<T>::type float_prior(const T&, const Policy&); > template <class T> > typename tools::promote_args<T>::type float_prior(const T&); > template <class T, class U, class Policy> > typename tools::promote_args<T, U>::type float_distance(const T&, const U&, const Policy&); > template <class T, class U> > typename tools::promote_args<T, U>::type float_distance(const T&, const U&); > template <class T, class Policy> > typename tools::promote_args<T>::type float_advance(T val, int distance, const Policy& pol); > template <class T> > typename tools::promote_args<T>::type float_advance(const T& val, int distance); > > } >} ># 18 "/usr/include/boost/math/special_functions/sign.hpp" 2 3 4 ># 1 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 1 3 4 ># 23 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 24 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 2 3 4 > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 26 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 27 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/detail/endian.hpp" 1 3 4 ># 9 "/usr/include/boost/detail/endian.hpp" 3 4 ># 1 "/usr/include/boost/predef/detail/endian_compat.h" 1 3 4 ># 11 "/usr/include/boost/predef/detail/endian_compat.h" 3 4 ># 1 "/usr/include/boost/predef/other/endian.h" 1 3 4 ># 11 "/usr/include/boost/predef/other/endian.h" 3 4 ># 1 "/usr/include/boost/predef/version_number.h" 1 3 4 ># 12 "/usr/include/boost/predef/other/endian.h" 2 3 4 ># 1 "/usr/include/boost/predef/make.h" 1 3 4 > > > > > > ># 1 "/usr/include/boost/predef/detail/test.h" 1 3 4 ># 8 "/usr/include/boost/predef/make.h" 2 3 4 ># 13 "/usr/include/boost/predef/other/endian.h" 2 3 4 ># 1 "/usr/include/boost/predef/library/c/gnu.h" 1 3 4 ># 12 "/usr/include/boost/predef/library/c/gnu.h" 3 4 ># 1 "/usr/include/boost/predef/make.h" 1 3 4 ># 13 "/usr/include/boost/predef/library/c/gnu.h" 2 3 4 > ># 1 "/usr/include/boost/predef/library/c/_prefix.h" 1 3 4 ># 11 "/usr/include/boost/predef/library/c/_prefix.h" 3 4 ># 1 "/usr/include/boost/predef/detail/_cassert.h" 1 3 4 ># 14 "/usr/include/boost/predef/detail/_cassert.h" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 15 "/usr/include/boost/predef/detail/_cassert.h" 2 3 4 ># 12 "/usr/include/boost/predef/library/c/_prefix.h" 2 3 4 ># 15 "/usr/include/boost/predef/library/c/gnu.h" 2 3 4 > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 18 "/usr/include/boost/predef/library/c/gnu.h" 2 3 4 ># 59 "/usr/include/boost/predef/library/c/gnu.h" 3 4 ># 14 "/usr/include/boost/predef/other/endian.h" 2 3 4 ># 1 "/usr/include/boost/predef/os/macos.h" 1 3 4 ># 12 "/usr/include/boost/predef/os/macos.h" 3 4 ># 1 "/usr/include/boost/predef/make.h" 1 3 4 ># 13 "/usr/include/boost/predef/os/macos.h" 2 3 4 ># 55 "/usr/include/boost/predef/os/macos.h" 3 4 ># 15 "/usr/include/boost/predef/other/endian.h" 2 3 4 ># 1 "/usr/include/boost/predef/os/bsd.h" 1 3 4 ># 19 "/usr/include/boost/predef/os/bsd.h" 3 4 ># 1 "/usr/include/boost/predef/make.h" 1 3 4 ># 20 "/usr/include/boost/predef/os/bsd.h" 2 3 4 ># 52 "/usr/include/boost/predef/os/bsd.h" 3 4 ># 1 "/usr/include/boost/predef/os/bsd/bsdi.h" 1 3 4 ># 11 "/usr/include/boost/predef/os/bsd/bsdi.h" 3 4 ># 1 "/usr/include/boost/predef/os/bsd.h" 1 3 4 ># 12 "/usr/include/boost/predef/os/bsd/bsdi.h" 2 3 4 ># 46 "/usr/include/boost/predef/os/bsd/bsdi.h" 3 4 ># 53 "/usr/include/boost/predef/os/bsd.h" 2 3 4 ># 1 "/usr/include/boost/predef/os/bsd/dragonfly.h" 1 3 4 ># 48 "/usr/include/boost/predef/os/bsd/dragonfly.h" 3 4 ># 54 "/usr/include/boost/predef/os/bsd.h" 2 3 4 ># 1 "/usr/include/boost/predef/os/bsd/free.h" 1 3 4 ># 58 "/usr/include/boost/predef/os/bsd/free.h" 3 4 ># 55 "/usr/include/boost/predef/os/bsd.h" 2 3 4 ># 1 "/usr/include/boost/predef/os/bsd/open.h" 1 3 4 ># 169 "/usr/include/boost/predef/os/bsd/open.h" 3 4 ># 56 "/usr/include/boost/predef/os/bsd.h" 2 3 4 ># 1 "/usr/include/boost/predef/os/bsd/net.h" 1 3 4 ># 82 "/usr/include/boost/predef/os/bsd/net.h" 3 4 ># 57 "/usr/include/boost/predef/os/bsd.h" 2 3 4 ># 93 "/usr/include/boost/predef/os/bsd.h" 3 4 ># 16 "/usr/include/boost/predef/other/endian.h" 2 3 4 ># 193 "/usr/include/boost/predef/other/endian.h" 3 4 ># 12 "/usr/include/boost/predef/detail/endian_compat.h" 2 3 4 ># 10 "/usr/include/boost/detail/endian.hpp" 2 3 4 ># 28 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 2 3 4 ># 81 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 >namespace boost { >namespace math { >namespace detail { ># 92 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 >struct native_tag {}; >template <bool has_limits> >struct generic_tag {}; >struct ieee_tag {}; >struct ieee_copy_all_bits_tag : public ieee_tag {}; >struct ieee_copy_leading_bits_tag : public ieee_tag {}; ># 125 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 >struct unknown_precision{}; >struct single_precision {}; >struct double_precision {}; >struct extended_double_precision {}; > > > >template<class T> struct fp_traits_native >{ > typedef native_tag method; >}; > > > >template<class T, class U> struct fp_traits_non_native >{ > > typedef generic_tag<std::numeric_limits<T>::is_specialized> method; > > > >}; ># 177 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 >template<> struct fp_traits_non_native<float, single_precision> >{ > typedef ieee_copy_all_bits_tag method; > > static const uint32_t sign = 0x80000000u; > static const uint32_t exponent = 0x7f800000; > static const uint32_t flag = 0x00000000; > static const uint32_t significand = 0x007fffff; > > typedef uint32_t bits; > static void get_bits(float x, uint32_t& a) { std::memcpy(&a, &x, 4); } > static void set_bits(float& x, uint32_t a) { std::memcpy(&x, &a, 4); } >}; ># 232 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 >template<> struct fp_traits_non_native<double, double_precision> >{ > typedef ieee_copy_all_bits_tag method; > > static const uint64_t sign = ((uint64_t)0x80000000u) << 32; > static const uint64_t exponent = ((uint64_t)0x7ff00000) << 32; > static const uint64_t flag = 0; > static const uint64_t significand > = (((uint64_t)0x000fffff) << 32) + ((uint64_t)0xffffffffu); > > typedef uint64_t bits; > static void get_bits(double x, uint64_t& a) { std::memcpy(&a, &x, 8); } > static void set_bits(double& x, uint64_t a) { std::memcpy(&x, &a, 8); } >}; ># 292 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 >template<> struct fp_traits_non_native<long double, double_precision> >{ > typedef ieee_copy_all_bits_tag method; > > static const uint64_t sign = (uint64_t)0x80000000u << 32; > static const uint64_t exponent = (uint64_t)0x7ff00000 << 32; > static const uint64_t flag = 0; > static const uint64_t significand > = ((uint64_t)0x000fffff << 32) + (uint64_t)0xffffffffu; > > typedef uint64_t bits; > static void get_bits(long double x, uint64_t& a) { std::memcpy(&a, &x, 8); } > static void set_bits(long double& x, uint64_t a) { std::memcpy(&x, &a, 8); } >}; ># 318 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 >template<> >struct fp_traits_non_native<long double, extended_double_precision> >{ > typedef ieee_copy_leading_bits_tag method; > > static const uint32_t sign = 0x80000000u; > static const uint32_t exponent = 0x7fff0000; > static const uint32_t flag = 0x00008000; > static const uint32_t significand = 0x00007fff; > > typedef uint32_t bits; > > static void get_bits(long double x, uint32_t& a) > { > std::memcpy(&a, reinterpret_cast<const unsigned char*>(&x) + 6, 4); > } > > static void set_bits(long double& x, uint32_t a) > { > std::memcpy(reinterpret_cast<unsigned char*>(&x) + 6, &a, 4); > } >}; ># 483 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 >template<int n, bool fp> struct size_to_precision >{ > typedef unknown_precision type; >}; > >template<> struct size_to_precision<4, true> >{ > typedef single_precision type; >}; > >template<> struct size_to_precision<8, true> >{ > typedef double_precision type; >}; > >template<> struct size_to_precision<10, true> >{ > typedef extended_double_precision type; >}; > >template<> struct size_to_precision<12, true> >{ > typedef extended_double_precision type; >}; > >template<> struct size_to_precision<16, true> >{ > typedef extended_double_precision type; >}; > > > > > > >template <class T> >struct select_native >{ > typedef typename size_to_precision<sizeof(T), ::boost::is_floating_point<T>::value>::type precision; > typedef fp_traits_non_native<T, precision> type; >}; >template<> >struct select_native<float> >{ > typedef fp_traits_native<float> type; >}; >template<> >struct select_native<double> >{ > typedef fp_traits_native<double> type; >}; >template<> >struct select_native<long double> >{ > typedef fp_traits_native<long double> type; >}; ># 553 "/usr/include/boost/math/special_functions/detail/fp_traits.hpp" 3 4 >template<class T> struct fp_traits >{ > typedef typename size_to_precision<sizeof(T), ::boost::is_floating_point<T>::value>::type precision; > > typedef typename select_native<T>::type type; > > > > typedef fp_traits_non_native<T, precision> sign_change_type; >}; > > > >} >} >} ># 19 "/usr/include/boost/math/special_functions/sign.hpp" 2 3 4 > >namespace boost{ namespace math{ > >namespace detail { > > > > > template<class T> > inline int signbit_impl(T x, native_tag const&) > { > return (std::signbit)(x); > } > > > template<class T> > inline int signbit_impl(T x, generic_tag<true> const&) > { > return x < 0; > } > > template<class T> > inline int signbit_impl(T x, generic_tag<false> const&) > { > return x < 0; > } > > template<class T> > inline int signbit_impl(T x, ieee_copy_all_bits_tag const&) > { > typedef typename fp_traits<T>::type traits; > > typename traits::bits a; > traits::get_bits(x,a); > return a & traits::sign ? 1 : 0; > } > > template<class T> > inline int signbit_impl(T x, ieee_copy_leading_bits_tag const&) > { > typedef typename fp_traits<T>::type traits; > > typename traits::bits a; > traits::get_bits(x,a); > > return a & traits::sign ? 1 : 0; > } > > > > template<class T> > inline T (changesign_impl)(T x, generic_tag<true> const&) > { > return -x; > } > > template<class T> > inline T (changesign_impl)(T x, generic_tag<false> const&) > { > return -x; > } > > > template<class T> > inline T changesign_impl(T x, ieee_copy_all_bits_tag const&) > { > typedef typename fp_traits<T>::sign_change_type traits; > > typename traits::bits a; > traits::get_bits(x,a); > a ^= traits::sign; > traits::set_bits(x,a); > return x; > } > > template<class T> > inline T (changesign_impl)(T x, ieee_copy_leading_bits_tag const&) > { > typedef typename fp_traits<T>::sign_change_type traits; > > typename traits::bits a; > traits::get_bits(x,a); > a ^= traits::sign; > traits::set_bits(x,a); > return x; > } > > >} > >template<class T> int (signbit)(T x) >{ > typedef typename detail::fp_traits<T>::type traits; > typedef typename traits::method method; > > typedef typename tools::promote_args_permissive<T>::type result_type; > return detail::signbit_impl(static_cast<result_type>(x), method()); >} > >template <class T> >inline int sign (const T& z) >{ > return (z == 0) ? 0 : (boost::math::signbit)(z) ? -1 : 1; >} > >template <class T> typename tools::promote_args_permissive<T>::type (changesign)(const T& x) >{ > typedef typename detail::fp_traits<T>::sign_change_type traits; > typedef typename traits::method method; > > typedef typename tools::promote_args_permissive<T>::type result_type; > > return detail::changesign_impl(static_cast<result_type>(x), method()); >} > >template <class T, class U> >inline typename tools::promote_args_permissive<T, U>::type > copysign (const T& x, const U& y) >{ > using std::abs; using std::acos; using std::cos; using std::fmod; using std::modf; using std::tan; using std::asin; using std::cosh; using std::frexp; using std::pow; using std::tanh; using std::atan; using std::exp; using std::ldexp; using std::sin; using std::atan2; using std::fabs; using std::log; using std::sinh; using std::ceil; using std::floor; using std::log10; using std::sqrt; using boost::math::round; using boost::math::iround; using boost::math::lround; using boost::math::trunc; using boost::math::itrunc; using boost::math::ltrunc; using boost::math::modf; > typedef typename tools::promote_args_permissive<T, U>::type result_type; > return (boost::math::signbit)(static_cast<result_type>(x)) != (boost::math::signbit)(static_cast<result_type>(y)) > ? (boost::math::changesign)(static_cast<result_type>(x)) : static_cast<result_type>(x); >} > >} >} ># 168 "/usr/include/boost/lexical_cast.hpp" 2 3 4 ># 1 "/usr/include/boost/math/special_functions/fpclassify.hpp" 1 3 4 ># 17 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 ># 1 "/usr/include/boost/math/tools/real_cast.hpp" 1 3 4 ># 13 "/usr/include/boost/math/tools/real_cast.hpp" 3 4 >namespace boost{ namespace math >{ > namespace tools > { > template <class To, class T> > inline To real_cast(T t) > { > return static_cast<To>(t); > } > } >} >} ># 18 "/usr/include/boost/math/special_functions/fpclassify.hpp" 2 3 4 ># 88 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >namespace boost{ > > > > > > >namespace math_detail{ > > > > > > >template <class T> >inline bool is_nan_helper(T t, const boost::true_type&) >{ > > > > > > > return (::std:: fpclassify(t) == (int)0); > >} > > > > > >template <class T> >inline bool is_nan_helper(T, const boost::false_type&) >{ > return false; >} > >} > >namespace math{ > >namespace detail{ > > >template <class T> >inline int fpclassify_imp (T t, const native_tag&) >{ > return (std::fpclassify)(t); >} > > >template <class T> >inline int fpclassify_imp (T t, const generic_tag<true>&) >{ > ; > > > > if(::boost::math_detail::is_nan_helper(t, ::boost::is_floating_point<T>())) > return 0; ># 156 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 > T at = (t < T(0)) ? -t : t; > > > > > > > > if(at <= (std::numeric_limits<T>::max)()) > { > if(at >= (std::numeric_limits<T>::min)()) > return 4; > return (at != 0) ? 3 : 2; > } > else if(at > (std::numeric_limits<T>::max)()) > return 1; > return 0; >} > >template <class T> >inline int fpclassify_imp (T t, const generic_tag<false>&) >{ ># 186 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 > ; > > return t == 0 ? 2 : 4; >} > >template<class T> >int fpclassify_imp (T x, ieee_copy_all_bits_tag) >{ > typedef typename fp_traits<T>::type traits; > > ; > > typename traits::bits a; > traits::get_bits(x,a); > ; > a &= traits::exponent | traits::flag | traits::significand; > ; > ; > > if(a <= traits::significand) { > if(a == 0) > return 2; > else > return 3; > } > > if(a < traits::exponent) return 4; > > a &= traits::significand; > if(a == 0) return 1; > > return 0; >} > >template<class T> >int fpclassify_imp (T x, ieee_copy_leading_bits_tag) >{ > typedef typename fp_traits<T>::type traits; > > ; > > typename traits::bits a; > traits::get_bits(x,a); > a &= traits::exponent | traits::flag | traits::significand; > > if(a <= traits::significand) { > if(x == 0) > return 2; > else > return 3; > } > > if(a < traits::exponent) return 4; > > a &= traits::significand; > traits::set_bits(x,a); > if(x == 0) return 1; > > return 0; >} ># 254 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >} > >template <class T> >inline int fpclassify (T t) >{ > typedef typename detail::fp_traits<T>::type traits; > typedef typename traits::method method; > typedef typename tools::promote_args_permissive<T>::type value_type; > > > > > > return detail::fpclassify_imp(static_cast<value_type>(t), method()); > >} ># 288 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >namespace detail { > > > template<class T> > inline bool isfinite_impl(T x, native_tag const&) > { > return (std::isfinite)(x); > } > > > template<class T> > inline bool isfinite_impl(T x, generic_tag<true> const&) > { > return x >= -(std::numeric_limits<T>::max)() > && x <= (std::numeric_limits<T>::max)(); > } > > template<class T> > inline bool isfinite_impl(T x, generic_tag<false> const&) > { > > > > > (void)x; > return true; > } > > template<class T> > inline bool isfinite_impl(T x, ieee_tag const&) > { > typedef typename detail::fp_traits<T>::type traits; > typename traits::bits a; > traits::get_bits(x,a); > a &= traits::exponent; > return a != traits::exponent; > } ># 333 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >} > >template<class T> >inline bool (isfinite)(T x) >{ > typedef typename detail::fp_traits<T>::type traits; > typedef typename traits::method method; > > typedef typename tools::promote_args_permissive<T>::type value_type; > return detail::isfinite_impl(static_cast<value_type>(x), method()); >} ># 359 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >namespace detail { > > > template<class T> > inline bool isnormal_impl(T x, native_tag const&) > { > return (std::isnormal)(x); > } > > > template<class T> > inline bool isnormal_impl(T x, generic_tag<true> const&) > { > if(x < 0) x = -x; > return x >= (std::numeric_limits<T>::min)() > && x <= (std::numeric_limits<T>::max)(); > } > > template<class T> > inline bool isnormal_impl(T x, generic_tag<false> const&) > { > > > > > return !(x == 0); > } > > template<class T> > inline bool isnormal_impl(T x, ieee_tag const&) > { > typedef typename detail::fp_traits<T>::type traits; > typename traits::bits a; > traits::get_bits(x,a); > a &= traits::exponent | traits::flag; > return (a != 0) && (a < traits::exponent); > } ># 404 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >} > >template<class T> >inline bool (isnormal)(T x) >{ > typedef typename detail::fp_traits<T>::type traits; > typedef typename traits::method method; > > typedef typename tools::promote_args_permissive<T>::type value_type; > return detail::isnormal_impl(static_cast<value_type>(x), method()); >} ># 430 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >namespace detail { > > > template<class T> > inline bool isinf_impl(T x, native_tag const&) > { > return (std::isinf)(x); > } > > > template<class T> > inline bool isinf_impl(T x, generic_tag<true> const&) > { > (void)x; > return std::numeric_limits<T>::has_infinity > && ( x == std::numeric_limits<T>::infinity() > || x == -std::numeric_limits<T>::infinity()); > } > > template<class T> > inline bool isinf_impl(T x, generic_tag<false> const&) > { > > > > > (void)x; > return false; > } > > template<class T> > inline bool isinf_impl(T x, ieee_copy_all_bits_tag const&) > { > typedef typename fp_traits<T>::type traits; > > typename traits::bits a; > traits::get_bits(x,a); > a &= traits::exponent | traits::significand; > return a == traits::exponent; > } > > template<class T> > inline bool isinf_impl(T x, ieee_copy_leading_bits_tag const&) > { > typedef typename fp_traits<T>::type traits; > > typename traits::bits a; > traits::get_bits(x,a); > a &= traits::exponent | traits::significand; > if(a != traits::exponent) > return false; > > traits::set_bits(x,0); > return x == 0; > } ># 493 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >} > >template<class T> >inline bool (isinf)(T x) >{ > typedef typename detail::fp_traits<T>::type traits; > typedef typename traits::method method; > > typedef typename tools::promote_args_permissive<T>::type value_type; > return detail::isinf_impl(static_cast<value_type>(x), method()); >} ># 519 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >namespace detail { > > > template<class T> > inline bool isnan_impl(T x, native_tag const&) > { > return (std::isnan)(x); > } > > > template<class T> > inline bool isnan_impl(T x, generic_tag<true> const&) > { > return std::numeric_limits<T>::has_infinity > ? !(x <= std::numeric_limits<T>::infinity()) > : x != x; > } > > template<class T> > inline bool isnan_impl(T x, generic_tag<false> const&) > { > > > > > (void)x; > return false; > } > > template<class T> > inline bool isnan_impl(T x, ieee_copy_all_bits_tag const&) > { > typedef typename fp_traits<T>::type traits; > > typename traits::bits a; > traits::get_bits(x,a); > a &= traits::exponent | traits::significand; > return a > traits::exponent; > } > > template<class T> > inline bool isnan_impl(T x, ieee_copy_leading_bits_tag const&) > { > typedef typename fp_traits<T>::type traits; > > typename traits::bits a; > traits::get_bits(x,a); > > a &= traits::exponent | traits::significand; > if(a < traits::exponent) > return false; > > a &= traits::significand; > traits::set_bits(x,a); > return x != 0; > } > >} > >template<class T> >inline bool (isnan)(T x) >{ > typedef typename detail::fp_traits<T>::type traits; > typedef typename traits::method method; > > return detail::isnan_impl(x, method()); >} ># 602 "/usr/include/boost/math/special_functions/fpclassify.hpp" 3 4 >} >} ># 169 "/usr/include/boost/lexical_cast.hpp" 2 3 4 > ># 1 "/usr/include/boost/container/container_fwd.hpp" 1 3 4 ># 24 "/usr/include/boost/container/container_fwd.hpp" 3 4 >namespace boost{ >namespace intrusive{ > >}} > >namespace boost{ namespace container{ namespace container_detail{ > >namespace bi = boost::intrusive; > >}}} ># 47 "/usr/include/boost/container/container_fwd.hpp" 3 4 >namespace boost { >namespace container { > > >template <class T > ,class Allocator = std::allocator<T> > >class vector; > > >template <class T > ,class Allocator = std::allocator<T> > >class stable_vector; > > >template <class T > ,class Allocator = std::allocator<T> > >class deque; > > >template <class T > ,class Allocator = std::allocator<T> > >class list; > > >template <class T > ,class Allocator = std::allocator<T> > >class slist; > > >template <class Key > ,class Compare = std::less<Key> > ,class Allocator = std::allocator<Key> > >class set; > > >template <class Key > ,class Compare = std::less<Key> > ,class Allocator = std::allocator<Key> > >class multiset; > > >template <class Key > ,class T > ,class Compare = std::less<Key> > ,class Allocator = std::allocator<std::pair<const Key, T> > > >class map; > > >template <class Key > ,class T > ,class Compare = std::less<Key> > ,class Allocator = std::allocator<std::pair<const Key, T> > > >class multimap; > > >template <class Key > ,class Compare = std::less<Key> > ,class Allocator = std::allocator<Key> > >class flat_set; > > >template <class Key > ,class Compare = std::less<Key> > ,class Allocator = std::allocator<Key> > >class flat_multiset; > > >template <class Key > ,class T > ,class Compare = std::less<Key> > ,class Allocator = std::allocator<std::pair<Key, T> > > >class flat_map; > > >template <class Key > ,class T > ,class Compare = std::less<Key> > ,class Allocator = std::allocator<std::pair<Key, T> > > >class flat_multimap; > > >template <class CharT > ,class Traits = std::char_traits<CharT> > ,class Allocator = std::allocator<CharT> > >class basic_string; > > > >struct ordered_range_t >{}; > > > >static const ordered_range_t ordered_range = ordered_range_t(); > > > >struct ordered_unique_range_t > : public ordered_range_t >{}; > > > >static const ordered_unique_range_t ordered_unique_range = ordered_unique_range_t(); > > > >struct default_init_t >{}; > > > >static const default_init_t default_init = default_init_t(); > > >namespace detail_really_deep_namespace { > > > >struct dummy >{ > dummy() > { > (void)ordered_range; > (void)ordered_unique_range; > (void)default_init; > } >}; > >} > > > >}} ># 171 "/usr/include/boost/lexical_cast.hpp" 2 3 4 > > ># 1 "/usr/include/c++/4.9.0/cwchar" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cwchar" 3 4 ># 40 "/usr/include/c++/4.9.0/cwchar" 3 > > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 45 "/usr/include/c++/4.9.0/cwchar" 2 3 ># 174 "/usr/include/boost/lexical_cast.hpp" 2 3 4 > > >namespace boost { > > namespace detail > { > > template < typename T > > struct is_char_or_wchar > { > typedef boost::type_traits::ice_or< > boost::is_same< T, char >::value, > > boost::is_same< T, wchar_t >::value, > > > boost::is_same< T, char16_t >::value, > > > boost::is_same< T, char32_t >::value, > > boost::is_same< T, unsigned char >::value, > boost::is_same< T, signed char >::value > > result_type; > > static const bool value = (result_type::value); > }; > } > > namespace detail > { > > template < class Char > > struct normalize_single_byte_char > { > typedef Char type; > }; > > template <> > struct normalize_single_byte_char< signed char > > { > typedef char type; > }; > > template <> > struct normalize_single_byte_char< unsigned char > > { > typedef char type; > }; > } > > namespace detail > { > > > template < class T > struct deduce_character_type_later {}; > } > > namespace detail > { > > > > template < typename Type > > struct stream_char_common: public boost::mpl::if_c< > boost::detail::is_char_or_wchar< Type >::value, > Type, > boost::detail::deduce_character_type_later< Type > > > {}; > > template < typename Char > > struct stream_char_common< Char* >: public boost::mpl::if_c< > boost::detail::is_char_or_wchar< Char >::value, > Char, > boost::detail::deduce_character_type_later< Char* > > > {}; > > template < typename Char > > struct stream_char_common< const Char* >: public boost::mpl::if_c< > boost::detail::is_char_or_wchar< Char >::value, > Char, > boost::detail::deduce_character_type_later< const Char* > > > {}; > > template < typename Char > > struct stream_char_common< boost::iterator_range< Char* > >: public boost::mpl::if_c< > boost::detail::is_char_or_wchar< Char >::value, > Char, > boost::detail::deduce_character_type_later< boost::iterator_range< Char* > > > > {}; > > template < typename Char > > struct stream_char_common< boost::iterator_range< const Char* > >: public boost::mpl::if_c< > boost::detail::is_char_or_wchar< Char >::value, > Char, > boost::detail::deduce_character_type_later< boost::iterator_range< const Char* > > > > {}; > > template < class Char, class Traits, class Alloc > > struct stream_char_common< std::basic_string< Char, Traits, Alloc > > > { > typedef Char type; > }; > > template < class Char, class Traits, class Alloc > > struct stream_char_common< boost::container::basic_string< Char, Traits, Alloc > > > { > typedef Char type; > }; > > template < typename Char, std::size_t N > > struct stream_char_common< boost::array< Char, N > >: public boost::mpl::if_c< > boost::detail::is_char_or_wchar< Char >::value, > Char, > boost::detail::deduce_character_type_later< boost::array< Char, N > > > > {}; > > template < typename Char, std::size_t N > > struct stream_char_common< boost::array< const Char, N > >: public boost::mpl::if_c< > boost::detail::is_char_or_wchar< Char >::value, > Char, > boost::detail::deduce_character_type_later< boost::array< const Char, N > > > > {}; > > > template < typename Char, std::size_t N > > struct stream_char_common< std::array<Char, N > >: public boost::mpl::if_c< > boost::detail::is_char_or_wchar< Char >::value, > Char, > boost::detail::deduce_character_type_later< std::array< Char, N > > > > {}; > > template < typename Char, std::size_t N > > struct stream_char_common< std::array< const Char, N > >: public boost::mpl::if_c< > boost::detail::is_char_or_wchar< Char >::value, > Char, > boost::detail::deduce_character_type_later< std::array< const Char, N > > > > {}; > > > > template <> struct stream_char_common< boost::int128_type >: public boost::mpl::identity< char > {}; > template <> struct stream_char_common< boost::uint128_type >: public boost::mpl::identity< char > {}; ># 326 "/usr/include/boost/lexical_cast.hpp" 3 4 > } > > namespace detail > { > > > > > > template < class Char > > struct deduce_source_char_impl > { > typedef typename boost::detail::normalize_single_byte_char< Char >::type type; > }; > > template < class T > > struct deduce_source_char_impl< deduce_character_type_later< T > > > { > typedef boost::has_left_shift< std::basic_ostream< char >, T > result_t; > > > > > > > typedef typename boost::mpl::if_c< > result_t::value, char, wchar_t > >::type type; > > static_assert((result_t::value || boost::has_left_shift< std::basic_ostream< type >, T >::value), "Source type is neither std::ostream`able nor std::wostream`able") > ; > > }; > } > > namespace detail > { > > > > > > template < class Char > > struct deduce_target_char_impl > { > typedef typename normalize_single_byte_char< Char >::type type; > }; > > template < class T > > struct deduce_target_char_impl< deduce_character_type_later<T> > > { > typedef boost::has_right_shift<std::basic_istream<char>, T > result_t; > > > > > > > typedef typename boost::mpl::if_c< > result_t::value, char, wchar_t > >::type type; > > static_assert((result_t::value || boost::has_right_shift<std::basic_istream<wchar_t>, T >::value), "Target type is neither std::istream`able nor std::wistream`able") > ; > > }; > } > > namespace detail > { ># 411 "/usr/include/boost/lexical_cast.hpp" 3 4 > template < class T > > struct deduce_target_char > { > typedef typename stream_char_common< T >::type stage1_type; > typedef typename deduce_target_char_impl< stage1_type >::type stage2_type; > > typedef stage2_type type; > }; > > template < class T > > struct deduce_source_char > { > typedef typename stream_char_common< T >::type stage1_type; > typedef typename deduce_source_char_impl< stage1_type >::type stage2_type; > > typedef stage2_type type; > }; > } > > namespace detail > { > > > template < class Char, class Target, class Source > > struct deduce_char_traits > { > typedef std::char_traits< Char > type; > }; > > template < class Char, class Traits, class Alloc, class Source > > struct deduce_char_traits< Char > , std::basic_string< Char, Traits, Alloc > > , Source > > > { > typedef Traits type; > }; > > template < class Char, class Target, class Traits, class Alloc > > struct deduce_char_traits< Char > , Target > , std::basic_string< Char, Traits, Alloc > > > > { > typedef Traits type; > }; > > template < class Char, class Traits, class Alloc, class Source > > struct deduce_char_traits< Char > , boost::container::basic_string< Char, Traits, Alloc > > , Source > > > { > typedef Traits type; > }; > > template < class Char, class Target, class Traits, class Alloc > > struct deduce_char_traits< Char > , Target > , boost::container::basic_string< Char, Traits, Alloc > > > > { > typedef Traits type; > }; > > template < class Char, class Traits, class Alloc1, class Alloc2 > > struct deduce_char_traits< Char > , std::basic_string< Char, Traits, Alloc1 > > , std::basic_string< Char, Traits, Alloc2 > > > > { > typedef Traits type; > }; > > template<class Char, class Traits, class Alloc1, class Alloc2> > struct deduce_char_traits< Char > , boost::container::basic_string< Char, Traits, Alloc1 > > , boost::container::basic_string< Char, Traits, Alloc2 > > > > { > typedef Traits type; > }; > > template < class Char, class Traits, class Alloc1, class Alloc2 > > struct deduce_char_traits< Char > , boost::container::basic_string< Char, Traits, Alloc1 > > , std::basic_string< Char, Traits, Alloc2 > > > > { > typedef Traits type; > }; > > template < class Char, class Traits, class Alloc1, class Alloc2 > > struct deduce_char_traits< Char > , std::basic_string< Char, Traits, Alloc1 > > , boost::container::basic_string< Char, Traits, Alloc2 > > > > { > typedef Traits type; > }; > } > > namespace detail > { > template<class T> > struct array_to_pointer_decay > { > typedef T type; > }; > > template<class T, std::size_t N> > struct array_to_pointer_decay<T[N]> > { > typedef const T * type; > }; > } > > namespace detail > { > > > > template <typename Float, typename Char> > struct is_this_float_conversion_optimized > { > typedef boost::type_traits::ice_and< > boost::is_float<Float>::value, > > boost::type_traits::ice_or< > boost::type_traits::ice_eq<sizeof(Char), sizeof(char) >::value, > boost::is_same<Char, wchar_t>::value > >::value > > > > > result_type; > > static const bool value = (result_type::value); > }; > } > > namespace detail > { > > template< class Source > > > struct lcast_src_length > { > static const std::size_t value = 1; > > > static void check_coverage() {} > }; ># 578 "/usr/include/boost/lexical_cast.hpp" 3 4 > template<class Source> > struct lcast_src_length_integral > { > > static const std::size_t value = std::numeric_limits<Source>::is_signed + std::numeric_limits<Source>::is_specialized + std::numeric_limits<Source>::digits10 * 2 > > > > ; > > > > > }; > > > > > > > template<> struct lcast_src_length<short> : lcast_src_length_integral<short> { static void check_coverage() {} }; > template<> struct lcast_src_length<unsigned short> : lcast_src_length_integral<unsigned short> { static void check_coverage() {} }; > template<> struct lcast_src_length<int> : lcast_src_length_integral<int> { static void check_coverage() {} }; > template<> struct lcast_src_length<unsigned int> : lcast_src_length_integral<unsigned int> { static void check_coverage() {} }; > template<> struct lcast_src_length<long> : lcast_src_length_integral<long> { static void check_coverage() {} }; > template<> struct lcast_src_length<unsigned long> : lcast_src_length_integral<unsigned long> { static void check_coverage() {} }; > > template<> struct lcast_src_length<boost::ulong_long_type> : lcast_src_length_integral<boost::ulong_long_type> { static void check_coverage() {} }; > template<> struct lcast_src_length<boost::long_long_type> : lcast_src_length_integral<boost::long_long_type> { static void check_coverage() {} }; > > > > > > template<> struct lcast_src_length<boost::int128_type> : lcast_src_length_integral<boost::int128_type> { static void check_coverage() {} }; > template<> struct lcast_src_length<boost::uint128_type> : lcast_src_length_integral<boost::uint128_type> { static void check_coverage() {} }; ># 629 "/usr/include/boost/lexical_cast.hpp" 3 4 > template<class Source> > struct lcast_src_length_floating > { > static_assert(std::numeric_limits<Source>::max_exponent10 <= 999999L && std::numeric_limits<Source>::min_exponent10 >= -999999L, "std::numeric_limits<Source>::max_exponent10 <= 999999L && std::numeric_limits<Source>::min_exponent10 >= -999999L") > > > ; > static const std::size_t value = 5 + lcast_precision<Source>::value + 6 > > ; > }; > > template<> > struct lcast_src_length<float> > : lcast_src_length_floating<float> > { > static void check_coverage() {} > }; > > template<> > struct lcast_src_length<double> > : lcast_src_length_floating<double> > { > static void check_coverage() {} > }; > > template<> > struct lcast_src_length<long double> > : lcast_src_length_floating<long double> > { > static void check_coverage() {} > }; > > > } > > namespace detail > { > template <class Source, class Target> > struct lexical_cast_stream_traits { > typedef typename boost::detail::array_to_pointer_decay<Source>::type src; > typedef typename boost::remove_cv<src>::type no_cv_src; > > typedef boost::detail::deduce_source_char<no_cv_src> deduce_src_char_metafunc; > typedef typename deduce_src_char_metafunc::type src_char_t; > typedef typename boost::detail::deduce_target_char<Target>::type target_char_t; > > typedef typename boost::detail::widest_char< > target_char_t, src_char_t > >::type char_type; ># 691 "/usr/include/boost/lexical_cast.hpp" 3 4 > typedef typename boost::detail::deduce_char_traits< > char_type, Target, no_cv_src > >::type traits; > > typedef boost::type_traits::ice_and< > boost::is_same<char, src_char_t>::value, > boost::type_traits::ice_ne<sizeof(char), sizeof(target_char_t) >::value, > boost::type_traits::ice_not< > boost::detail::is_char_or_wchar<no_cv_src>::value > >::value > > is_string_widening_required_t; > > typedef boost::type_traits::ice_not< boost::type_traits::ice_or< > boost::is_integral<no_cv_src>::value, > boost::detail::is_this_float_conversion_optimized<no_cv_src, char_type >::value, > boost::detail::is_char_or_wchar< > typename deduce_src_char_metafunc::stage1_type > >::value > >::value > is_source_input_not_optimized_t; > > > > static const bool requires_stringbuf = (boost::type_traits::ice_or< is_string_widening_required_t::value, is_source_input_not_optimized_t::value >::value) > > > > ; > > typedef boost::detail::lcast_src_length<no_cv_src> len_t; > }; > } > > namespace detail > { > template < typename Char > struct lcast_char_constants; > > template<> > struct lcast_char_constants<char> > { > static const char zero = '0'; > static const char minus = '-'; > static const char plus = '+'; > static const char lowercase_e = 'e'; > static const char capital_e = 'E'; > static const char c_decimal_separator = '.'; > }; > > > template<> > struct lcast_char_constants<wchar_t> > { > static const wchar_t zero = L'0'; > static const wchar_t minus = L'-'; > static const wchar_t plus = L'+'; > static const wchar_t lowercase_e = L'e'; > static const wchar_t capital_e = L'E'; > static const wchar_t c_decimal_separator = L'.'; > }; > > > > template<> > struct lcast_char_constants<char16_t> > { > static const char16_t zero = u'0'; > static const char16_t minus = u'-'; > static const char16_t plus = u'+'; > static const char16_t lowercase_e = u'e'; > static const char16_t capital_e = u'E'; > static const char16_t c_decimal_separator = u'.'; > }; > > > > template<> > struct lcast_char_constants<char32_t> > { > static const char32_t zero = U'0'; > static const char32_t minus = U'-'; > static const char32_t plus = U'+'; > static const char32_t lowercase_e = U'e'; > static const char32_t capital_e = U'E'; > static const char32_t c_decimal_separator = U'.'; > }; > > } > > namespace detail > { > template<class T> > inline > typename make_unsigned<T>::type lcast_to_unsigned(T value) noexcept > { > typedef typename boost::make_unsigned<T>::type result_type; > return static_cast<result_type>( > value < 0 ? 0u - static_cast<result_type>(value) : value > ); > } > } > > namespace detail > { > template<class Traits, class T, class CharT> > CharT* lcast_put_unsigned(const T n_param, CharT* finish) > { > > static_assert(!std::numeric_limits<T>::is_signed, "!std::numeric_limits<T>::is_signed"); > > > typedef typename Traits::int_type int_type; > CharT const czero = lcast_char_constants<CharT>::zero; > int_type const zero = Traits::to_int_type(czero); > typename boost::mpl::if_c< > (sizeof(int_type) > sizeof(T)) > , int_type > , T > >::type n = n_param; > > > std::locale loc; > if (loc != std::locale::classic()) { > typedef std::numpunct<CharT> numpunct; > numpunct const& np = std::use_facet< numpunct >(loc); > std::string const grouping = np.grouping(); > std::string::size_type const grouping_size = grouping.size(); > > if ( grouping_size && grouping[0] > 0 ) > { > > > > static_assert(std::numeric_limits<T>::digits10 < 127, "std::numeric_limits<T>::digits10 < CHAR_MAX"); > > CharT thousands_sep = np.thousands_sep(); > std::string::size_type group = 0; > char last_grp_size = grouping[0]; > char left = last_grp_size; > > do > { > if(left == 0) > { > ++group; > if(group < grouping_size) > { > char const grp_size = grouping[group]; > last_grp_size = grp_size <= 0 ? static_cast<char>(127) : grp_size; > } > > left = last_grp_size; > --finish; > Traits::assign(*finish, thousands_sep); > } > > --left; > > --finish; > int_type const digit = static_cast<int_type>(n % 10U); > Traits::assign(*finish, Traits::to_char_type(zero + digit)); > n /= 10; > } while(n); > return finish; > } > } > > { > do > { > --finish; > int_type const digit = static_cast<int_type>(n % 10U); > Traits::assign(*finish, Traits::to_char_type(zero + digit)); > n /= 10; > } while(n); > } > > return finish; > } > } > > namespace detail > { > template<class Traits, class T, class CharT> > inline bool lcast_ret_unsigned(T& value, const CharT* const begin, const CharT* end) > { > > static_assert(!std::numeric_limits<T>::is_signed, "!std::numeric_limits<T>::is_signed"); > > > > > > > static_assert(std::numeric_limits<T>::is_specialized, "std::numeric_limits are not specialized for integral type passed to boost::lexical_cast") > > ; > > CharT const czero = lcast_char_constants<CharT>::zero; > --end; > value = 0; > > if (begin > end || *end < czero || *end >= czero + 10) > return false; > value = static_cast<T>(*end - czero); > --end; > T multiplier = 1; > bool multiplier_overflowed = false; > > > std::locale loc; > if (loc != std::locale::classic()) { > typedef std::numpunct<CharT> numpunct; > numpunct const& np = std::use_facet< numpunct >(loc); > std::string const& grouping = np.grouping(); > std::string::size_type const grouping_size = grouping.size(); > > > > > if (grouping_size && grouping[0] > 0) > { > unsigned char current_grouping = 0; > CharT const thousands_sep = np.thousands_sep(); > char remained = static_cast<char>(grouping[current_grouping] - 1); > bool shall_we_return = true; > > for(;end>=begin; --end) > { > if (remained) { > T const multiplier_10 = static_cast<T>(multiplier * 10); > if (multiplier_10 / 10 != multiplier) multiplier_overflowed = true; > > T const dig_value = static_cast<T>(*end - czero); > T const new_sub_value = static_cast<T>(multiplier_10 * dig_value); > > if (*end < czero || *end >= czero + 10 > > || (dig_value && new_sub_value / dig_value != multiplier_10) > || static_cast<T>((std::numeric_limits<T>::max)()-new_sub_value) < value > || (multiplier_overflowed && dig_value) > ) > return false; > > value = static_cast<T>(value + new_sub_value); > multiplier = static_cast<T>(multiplier * 10); > --remained; > } else { > if ( !Traits::eq(*end, thousands_sep) ) > { ># 950 "/usr/include/boost/lexical_cast.hpp" 3 4 > shall_we_return = false; > break; > } else { > if ( begin == end ) return false; > if (current_grouping < grouping_size-1 ) ++current_grouping; > remained = grouping[current_grouping]; > } > } > } > > if (shall_we_return) return true; > } > } > > { > while ( begin <= end ) > { > T const multiplier_10 = static_cast<T>(multiplier * 10); > if (multiplier_10 / 10 != multiplier) multiplier_overflowed = true; > > T const dig_value = static_cast<T>(*end - czero); > T const new_sub_value = static_cast<T>(multiplier_10 * dig_value); > > if (*end < czero || *end >= czero + 10 > > || (dig_value && new_sub_value / dig_value != multiplier_10) > || static_cast<T>((std::numeric_limits<T>::max)()-new_sub_value) < value > || (multiplier_overflowed && dig_value) > ) > return false; > > value = static_cast<T>(value + new_sub_value); > multiplier = static_cast<T>(multiplier * 10); > --end; > } > } > return true; > } > } > > namespace detail > { > template <class CharT> > bool lc_iequal(const CharT* val, const CharT* lcase, const CharT* ucase, unsigned int len) noexcept { > for( unsigned int i=0; i < len; ++i ) { > if ( val[i] != lcase[i] && val[i] != ucase[i] ) return false; > } > > return true; > } > > > template <class CharT, class T> > inline bool parse_inf_nan_impl(const CharT* begin, const CharT* end, T& value > , const CharT* lc_NAN, const CharT* lc_nan > , const CharT* lc_INFINITY, const CharT* lc_infinity > , const CharT opening_brace, const CharT closing_brace) noexcept > { > using namespace std; > if (begin == end) return false; > const CharT minus = lcast_char_constants<CharT>::minus; > const CharT plus = lcast_char_constants<CharT>::plus; > const int inifinity_size = 8; > > bool has_minus = false; > > if( *begin == minus) > { > ++ begin; > has_minus = true; > } > else if( *begin == plus ) ++begin; > > if( end-begin < 3 ) return false; > if( lc_iequal(begin, lc_nan, lc_NAN, 3) ) > { > begin += 3; > if (end != begin) > { > if(end-begin<2) return false; > -- end; > if( *begin != opening_brace || *end != closing_brace) return false; > } > > if( !has_minus ) value = std::numeric_limits<T>::quiet_NaN(); > else value = (boost::math::changesign) (std::numeric_limits<T>::quiet_NaN()); > return true; > } else > if (( > end-begin==3 > && > lc_iequal(begin, lc_infinity, lc_INFINITY, 3) > ) > || > ( > end-begin==inifinity_size > && > lc_iequal(begin, lc_infinity, lc_INFINITY, inifinity_size) > ) > ) > { > if( !has_minus ) value = std::numeric_limits<T>::infinity(); > else value = (boost::math::changesign) (std::numeric_limits<T>::infinity()); > return true; > } > > return false; > } > > template <class CharT, class T> > bool put_inf_nan_impl(CharT* begin, CharT*& end, const T& value > , const CharT* lc_nan > , const CharT* lc_infinity) noexcept > { > using namespace std; > const CharT minus = lcast_char_constants<CharT>::minus; > if ( (boost::math::isnan)(value) ) > { > if ( (boost::math::signbit)(value) ) > { > *begin = minus; > ++ begin; > } > > memcpy(begin, lc_nan, 3 * sizeof(CharT)); > end = begin + 3; > return true; > } else if ( (boost::math::isinf)(value) ) > { > if ( (boost::math::signbit)(value) ) > { > *begin = minus; > ++ begin; > } > > memcpy(begin, lc_infinity, 3 * sizeof(CharT)); > end = begin + 3; > return true; > } > > return false; > } > > > > template <class T> > bool parse_inf_nan(const wchar_t* begin, const wchar_t* end, T& value) noexcept > { > return parse_inf_nan_impl(begin, end, value > , L"NAN", L"nan" > , L"INFINITY", L"infinity" > , L'(', L')'); > } > > template <class T> > bool put_inf_nan(wchar_t* begin, wchar_t*& end, const T& value) noexcept > { > return put_inf_nan_impl(begin, end, value, L"nan", L"infinity"); > } > > > > template <class T> > bool parse_inf_nan(const char16_t* begin, const char16_t* end, T& value) noexcept > { > return parse_inf_nan_impl(begin, end, value > , u"NAN", u"nan" > , u"INFINITY", u"infinity" > , u'(', u')'); > } > > template <class T> > bool put_inf_nan(char16_t* begin, char16_t*& end, const T& value) noexcept > { > return put_inf_nan_impl(begin, end, value, u"nan", u"infinity"); > } > > > template <class T> > bool parse_inf_nan(const char32_t* begin, const char32_t* end, T& value) noexcept > { > return parse_inf_nan_impl(begin, end, value > , U"NAN", U"nan" > , U"INFINITY", U"infinity" > , U'(', U')'); > } > > template <class T> > bool put_inf_nan(char32_t* begin, char32_t*& end, const T& value) noexcept > { > return put_inf_nan_impl(begin, end, value, U"nan", U"infinity"); > } > > > template <class CharT, class T> > bool parse_inf_nan(const CharT* begin, const CharT* end, T& value) noexcept > { > return parse_inf_nan_impl(begin, end, value > , "NAN", "nan" > , "INFINITY", "infinity" > , '(', ')'); > } > > template <class CharT, class T> > bool put_inf_nan(CharT* begin, CharT*& end, const T& value) noexcept > { > return put_inf_nan_impl(begin, end, value, "nan", "infinity"); > } > } > > > namespace detail > { > > > > > > > template <class T> > struct mantissa_holder_type > { > > }; > > template <> > struct mantissa_holder_type<float> > { > typedef unsigned int type; > typedef double wide_result_t; > }; > > template <> > struct mantissa_holder_type<double> > { > > typedef long double wide_result_t; > > typedef boost::ulong_long_type type; > > > > > }; > > template<class Traits, class T, class CharT> > inline bool lcast_ret_float(T& value, const CharT* begin, const CharT* end) > { > > > std::locale loc; > typedef std::numpunct<CharT> numpunct; > numpunct const& np = std::use_facet< numpunct >(loc); > std::string const grouping( > (loc == std::locale::classic()) > ? std::string() > : np.grouping() > ); > std::string::size_type const grouping_size = grouping.size(); > CharT const thousands_sep = static_cast<CharT>(grouping_size ? np.thousands_sep() : 0); > CharT const decimal_point = np.decimal_point(); > bool found_grouping = false; > std::string::size_type last_grouping_pos = grouping_size - 1; > > > > > CharT const czero = lcast_char_constants<CharT>::zero; > CharT const minus = lcast_char_constants<CharT>::minus; > CharT const plus = lcast_char_constants<CharT>::plus; > CharT const capital_e = lcast_char_constants<CharT>::capital_e; > CharT const lowercase_e = lcast_char_constants<CharT>::lowercase_e; > > value = static_cast<T>(0); > > if (parse_inf_nan(begin, end, value)) return true; > > typedef typename Traits::int_type int_type; > typedef typename mantissa_holder_type<T>::type mantissa_type; > typedef typename mantissa_holder_type<T>::wide_result_t wide_result_t; > int_type const zero = Traits::to_int_type(czero); > if (begin == end) return false; > > > bool has_minus = false; > if (Traits::eq(*begin, minus) ) { > ++ begin; > has_minus = true; > if (begin == end) return false; > } else if (Traits::eq(*begin, plus) ) { > ++begin; > if (begin == end) return false; > } > > bool found_decimal = false; > bool found_number_before_exp = false; > int pow_of_10 = 0; > mantissa_type mantissa=0; > bool is_mantissa_full = false; > > char length_since_last_delim = 0; > > while ( begin != end ) > { > if (found_decimal) { > > > mantissa_type tmp_mantissa = mantissa * 10u; > if (Traits::eq(*begin, lowercase_e) || Traits::eq(*begin, capital_e)) break; > if ( *begin < czero || *begin >= czero + 10 ) return false; > if ( is_mantissa_full > || tmp_mantissa / 10u != mantissa > || (std::numeric_limits<mantissa_type>::max)()-(*begin - zero) < tmp_mantissa > ) { > is_mantissa_full = true; > ++ begin; > continue; > } > > -- pow_of_10; > mantissa = tmp_mantissa; > mantissa += *begin - zero; > > found_number_before_exp = true; > } else { > > if (*begin >= czero && *begin < czero + 10) { > > > > > mantissa_type tmp_mantissa = mantissa * 10u; > if( !is_mantissa_full > && tmp_mantissa / 10u == mantissa > && (std::numeric_limits<mantissa_type>::max)()-(*begin - zero) >= tmp_mantissa > ) > { > mantissa = tmp_mantissa; > mantissa += *begin - zero; > } else > { > is_mantissa_full = true; > ++ pow_of_10; > } > > found_number_before_exp = true; > ++ length_since_last_delim; > } else if (Traits::eq(*begin, decimal_point) || Traits::eq(*begin, lowercase_e) || Traits::eq(*begin, capital_e)) { ># 1306 "/usr/include/boost/lexical_cast.hpp" 3 4 > if( grouping_size && found_grouping > && ( > length_since_last_delim != grouping[0] > || last_grouping_pos>1 > || (last_grouping_pos==0 && grouping_size>1) > ) > ) return false; > > > if(Traits::eq(*begin, decimal_point)) { > ++ begin; > found_decimal = true; > if (!found_number_before_exp && begin==end) return false; > continue; > }else { > if (!found_number_before_exp) return false; > break; > } > } > > else if (grouping_size && Traits::eq(*begin, thousands_sep)){ > if(found_grouping) > { > > > > > if (length_since_last_delim != grouping[last_grouping_pos] ) > { > if (!last_grouping_pos) return false; > else > { > -- last_grouping_pos; > if (length_since_last_delim != grouping[last_grouping_pos]) return false; > } > } else > > if (grouping_size>1u && last_grouping_pos+1<grouping_size) return false; > > } else { > > if (!length_since_last_delim) return false; > > found_grouping = true; > if (length_since_last_delim > grouping[last_grouping_pos] ) return false; > } > > length_since_last_delim = 0; > ++ begin; > > > if (begin == end) return false; > continue; > } > > else return false; > } > > ++begin; > } > > > if ( begin != end && (Traits::eq(*begin, lowercase_e) || Traits::eq(*begin, capital_e)) ) { > ++ begin; > if ( begin == end ) return false; > > bool exp_has_minus = false; > if(Traits::eq(*begin, minus)) { > exp_has_minus = true; > ++ begin; > if ( begin == end ) return false; > } else if (Traits::eq(*begin, plus)) { > ++ begin; > if ( begin == end ) return false; > } > > int exp_pow_of_10 = 0; > while ( begin != end ) > { > if ( *begin < czero > || *begin >= czero + 10 > || exp_pow_of_10 * 10 < exp_pow_of_10) > return false; > > exp_pow_of_10 *= 10; > exp_pow_of_10 += *begin - zero; > ++ begin; > }; > > if ( exp_pow_of_10 ) { > > if ( exp_has_minus ) { > pow_of_10 -= exp_pow_of_10; > } else { > pow_of_10 += exp_pow_of_10; > } > } > } > > > > > const wide_result_t result = std::pow(static_cast<wide_result_t>(10.0), pow_of_10) * mantissa; > value = static_cast<T>( has_minus ? (boost::math::changesign)(result) : result); > > if ( (boost::math::isinf)(value) || (boost::math::isnan)(value) ) return false; > > return true; > } > > > > > } > > namespace detail > { ># 1431 "/usr/include/boost/lexical_cast.hpp" 3 4 > template <class BufferType, class charT> > class parser_buf : public BufferType { > typedef BufferType base_type; > typedef typename base_type::int_type int_type; > typedef typename base_type::char_type char_type; > typedef typename base_type::pos_type pos_type; > typedef ::std::streamsize streamsize; > typedef typename base_type::off_type off_type; > > public: > parser_buf() : base_type() { setbuf(0, 0); } > const charT* getnext() { return this->gptr(); } > > using base_type::pptr; > using base_type::pbase; > > > > > base_type* setbuf(char_type* s, streamsize n) { > this->setg(s, s, s + n); > return this; > } > > pos_type seekpos(pos_type sp, ::std::ios_base::openmode which) { > if(which & ::std::ios_base::out) > return pos_type(off_type(-1)); > off_type size = static_cast<off_type>(this->egptr() - this->eback()); > charT* g = this->eback(); > if(off_type(sp) <= size) > { > this->setg(g, g + off_type(sp), g + size); > } > return pos_type(off_type(-1)); > } > > pos_type seekoff(off_type off, ::std::ios_base::seekdir way, ::std::ios_base::openmode which) { > typedef typename boost::int_t<sizeof(way) * 8>::least cast_type; > > if(which & ::std::ios_base::out) > return pos_type(off_type(-1)); > std::ptrdiff_t size = this->egptr() - this->eback(); > std::ptrdiff_t pos = this->gptr() - this->eback(); > charT* g = this->eback(); > switch(static_cast<cast_type>(way)) > { > case ::std::ios_base::beg: > if((off < 0) || (off > size)) > return pos_type(off_type(-1)); > else > this->setg(g, g + off, g + size); > break; > case ::std::ios_base::end: > if((off < 0) || (off > size)) > return pos_type(off_type(-1)); > else > this->setg(g, g + size - off, g + size); > break; > case ::std::ios_base::cur: > { > std::ptrdiff_t newpos = static_cast<std::ptrdiff_t>(pos + off); > if((newpos < 0) || (newpos > size)) > return pos_type(off_type(-1)); > else > this->setg(g, g + newpos, g + size); > break; > } > default: ; > } > > > > > return static_cast<pos_type>(this->gptr() - this->eback()); > > > > } > private: > parser_buf& operator=(const parser_buf&); > parser_buf(const parser_buf&); > }; > } > > namespace detail > { > struct do_not_construct_out_stream_t{}; > } > > namespace detail > { > > template< class CharT > , class Traits > , bool RequiresStringbuffer > > > class lexical_stream_limited_src > { > > > > > > > > typedef std::basic_ostringstream<CharT, Traits> out_stream_t; > typedef parser_buf<std::basic_streambuf<CharT, Traits>, CharT> buffer_t; > > typedef typename boost::mpl::if_c< > RequiresStringbuffer, > out_stream_t, > do_not_construct_out_stream_t > >::type deduced_out_stream_t; > > > CharT* start; > CharT* finish; > deduced_out_stream_t out_stream; > > public: > lexical_stream_limited_src(CharT* sta, CharT* fin) noexcept > : start(sta) > , finish(fin) > {} > > private: > > lexical_stream_limited_src(lexical_stream_limited_src const&); > void operator=(lexical_stream_limited_src const&); > > > bool shl_char(CharT ch) noexcept > { > Traits::assign(*start, ch); > finish = start + 1; > return true; > } > > > template <class T> > bool shl_char(T ch) > { > static_assert(( sizeof(T) <= sizeof(CharT)) , "boost::lexical_cast does not support narrowing of char types." "Use boost::locale instead") > > ; > > std::locale loc; > CharT const w = std::use_facet< std::ctype<CharT> >(loc).widen(ch); > > > > Traits::assign(*start, w); > finish = start + 1; > return true; > } > > > bool shl_char_array(CharT const* str) noexcept > { > start = const_cast<CharT*>(str); > finish = start + Traits::length(str); > return true; > } > > template <class T> > bool shl_char_array(T const* str) > { > static_assert(( sizeof(T) <= sizeof(CharT)), "boost::lexical_cast does not support narrowing of char types." "Use boost::locale instead") > > ; > return shl_input_streamable(str); > } > > bool shl_char_array_limited(CharT const* str, std::size_t max_size) noexcept > { > start = const_cast<CharT*>(str); > finish = std::find(start, start + max_size, Traits::to_char_type(0)); > return true; > } > > template<typename InputStreamable> > bool shl_input_streamable(InputStreamable& input) > { > > > > > > > > out_stream.exceptions(std::ios::badbit); > try { > > bool const result = !(out_stream << input).fail(); > const buffer_t* const p = static_cast<buffer_t*>( > static_cast<std::basic_streambuf<CharT, Traits>*>(out_stream.rdbuf()) > ); > start = p->pbase(); > finish = p->pptr(); > return result; > > } catch (const ::std::ios_base::failure& ) { > return false; > } > > } > > template <class T> > inline bool shl_signed(T n) > { > start = lcast_put_unsigned<Traits>(lcast_to_unsigned(n), finish); > if(n < 0) > { > --start; > CharT const minus = lcast_char_constants<CharT>::minus; > Traits::assign(*start, minus); > } > return true; > } > > template <class T, class SomeCharT> > bool shl_real_type(const T& val, SomeCharT* begin, SomeCharT*& end) > { > if (put_inf_nan(begin, end, val)) return true; > lcast_set_precision(out_stream, &val); > return shl_input_streamable(val); > } > > static bool shl_real_type(float val, char* begin, char*& end) > { using namespace std; > if (put_inf_nan(begin, end, val)) return true; > const double val_as_double = val; > end = begin + > > > > sprintf(begin, > > "%.*g", static_cast<int>(boost::detail::lcast_get_precision<float>()), val_as_double); > return end > begin; > } > > static bool shl_real_type(double val, char* begin, char*& end) > { using namespace std; > if (put_inf_nan(begin, end, val)) return true; > end = begin + > > > > sprintf(begin, > > "%.*g", static_cast<int>(boost::detail::lcast_get_precision<double>()), val); > return end > begin; > } > > > static bool shl_real_type(long double val, char* begin, char*& end) > { using namespace std; > if (put_inf_nan(begin, end, val)) return true; > end = begin + > > > > sprintf(begin, > > "%.*Lg", static_cast<int>(boost::detail::lcast_get_precision<long double>()), val ); > return end > begin; > } > > > > > static bool shl_real_type(float val, wchar_t* begin, wchar_t*& end) > { using namespace std; > if (put_inf_nan(begin, end, val)) return true; > const double val_as_double = val; > end = begin + swprintf(begin, end-begin, > L"%.*g", > static_cast<int>(boost::detail::lcast_get_precision<float >()), > val_as_double ); > return end > begin; > } > > static bool shl_real_type(double val, wchar_t* begin, wchar_t*& end) > { using namespace std; > if (put_inf_nan(begin, end, val)) return true; > end = begin + swprintf(begin, end-begin, > L"%.*g", static_cast<int>(boost::detail::lcast_get_precision<double >()), val ); > return end > begin; > } > > static bool shl_real_type(long double val, wchar_t* begin, wchar_t*& end) > { using namespace std; > if (put_inf_nan(begin, end, val)) return true; > end = begin + swprintf(begin, end-begin, > L"%.*Lg", static_cast<int>(boost::detail::lcast_get_precision<long double >()), val ); > return end > begin; > } > > > > public: > template<class Alloc> > bool operator<<(std::basic_string<CharT,Traits,Alloc> const& str) noexcept > { > start = const_cast<CharT*>(str.data()); > finish = start + str.length(); > return true; > } > > template<class Alloc> > bool operator<<(boost::container::basic_string<CharT,Traits,Alloc> const& str) noexcept > { > start = const_cast<CharT*>(str.data()); > finish = start + str.length(); > return true; > } > > bool operator<<(bool value) noexcept > { > CharT const czero = lcast_char_constants<CharT>::zero; > Traits::assign(*start, Traits::to_char_type(czero + value)); > finish = start + 1; > return true; > } > > bool operator<<(const iterator_range<CharT*>& rng) noexcept > { > start = rng.begin(); > finish = rng.end(); > return true; > } > > bool operator<<(const iterator_range<const CharT*>& rng) noexcept > { > start = const_cast<CharT*>(rng.begin()); > finish = const_cast<CharT*>(rng.end()); > return true; > } > > bool operator<<(const iterator_range<const signed char*>& rng) noexcept > { > return (*this) << iterator_range<char*>( > const_cast<char*>(reinterpret_cast<const char*>(rng.begin())), > const_cast<char*>(reinterpret_cast<const char*>(rng.end())) > ); > } > > bool operator<<(const iterator_range<const unsigned char*>& rng) noexcept > { > return (*this) << iterator_range<char*>( > const_cast<char*>(reinterpret_cast<const char*>(rng.begin())), > const_cast<char*>(reinterpret_cast<const char*>(rng.end())) > ); > } > > bool operator<<(const iterator_range<signed char*>& rng) noexcept > { > return (*this) << iterator_range<char*>( > reinterpret_cast<char*>(rng.begin()), > reinterpret_cast<char*>(rng.end()) > ); > } > > bool operator<<(const iterator_range<unsigned char*>& rng) noexcept > { > return (*this) << iterator_range<char*>( > reinterpret_cast<char*>(rng.begin()), > reinterpret_cast<char*>(rng.end()) > ); > } > > bool operator<<(char ch) { return shl_char(ch); } > bool operator<<(unsigned char ch) { return ((*this) << static_cast<char>(ch)); } > bool operator<<(signed char ch) { return ((*this) << static_cast<char>(ch)); } > > bool operator<<(wchar_t const* str) { return shl_char_array(str); } > bool operator<<(wchar_t * str) { return shl_char_array(str); } > > bool operator<<(wchar_t ch) { return shl_char(ch); } > > > > bool operator<<(char16_t ch) { return shl_char(ch); } > bool operator<<(char16_t * str) { return shl_char_array(str); } > bool operator<<(char16_t const * str) { return shl_char_array(str); } > > > bool operator<<(char32_t ch) { return shl_char(ch); } > bool operator<<(char32_t * str) { return shl_char_array(str); } > bool operator<<(char32_t const * str) { return shl_char_array(str); } > > bool operator<<(unsigned char const* ch) { return ((*this) << reinterpret_cast<char const*>(ch)); } > bool operator<<(unsigned char * ch) { return ((*this) << reinterpret_cast<char *>(ch)); } > bool operator<<(signed char const* ch) { return ((*this) << reinterpret_cast<char const*>(ch)); } > bool operator<<(signed char * ch) { return ((*this) << reinterpret_cast<char *>(ch)); } > bool operator<<(char const* str) { return shl_char_array(str); } > bool operator<<(char* str) { return shl_char_array(str); } > bool operator<<(short n) { return shl_signed(n); } > bool operator<<(int n) { return shl_signed(n); } > bool operator<<(long n) { return shl_signed(n); } > bool operator<<(unsigned short n) { start = lcast_put_unsigned<Traits>(n, finish); return true; } > bool operator<<(unsigned int n) { start = lcast_put_unsigned<Traits>(n, finish); return true; } > bool operator<<(unsigned long n) { start = lcast_put_unsigned<Traits>(n, finish); return true; } > > > bool operator<<(boost::ulong_long_type n) { start = lcast_put_unsigned<Traits>(n, finish); return true; } > bool operator<<(boost::long_long_type n) { return shl_signed(n); } > > > > > > > bool operator<<(const boost::uint128_type& n) { start = lcast_put_unsigned<Traits>(n, finish); return true; } > bool operator<<(const boost::int128_type& n) { return shl_signed(n); } > > > bool operator<<(float val) { return shl_real_type(val, start, finish); } > bool operator<<(double val) { return shl_real_type(val, start, finish); } > bool operator<<(long double val) { > > return shl_real_type(val, start, finish); > > > > } > > template <std::size_t N> > bool operator<<(boost::array<CharT, N> const& input) noexcept > { return shl_char_array_limited(input.begin(), N); } > > template <std::size_t N> > bool operator<<(boost::array<unsigned char, N> const& input) noexcept > { return ((*this) << reinterpret_cast<boost::array<char, N> const& >(input)); } > > template <std::size_t N> > bool operator<<(boost::array<signed char, N> const& input) noexcept > { return ((*this) << reinterpret_cast<boost::array<char, N> const& >(input)); } > > template <std::size_t N> > bool operator<<(boost::array<const CharT, N> const& input) noexcept > { return shl_char_array_limited(input.begin(), N); } > > template <std::size_t N> > bool operator<<(boost::array<const unsigned char, N> const& input) noexcept > { return ((*this) << reinterpret_cast<boost::array<const char, N> const& >(input)); } > > template <std::size_t N> > bool operator<<(boost::array<const signed char, N> const& input) noexcept > { return ((*this) << reinterpret_cast<boost::array<const char, N> const& >(input)); } > > > template <std::size_t N> > bool operator<<(std::array<CharT, N> const& input) noexcept > { > if (input.size()) return shl_char_array_limited(&input[0], N); > else return true; > } > > template <std::size_t N> > bool operator<<(std::array<unsigned char, N> const& input) noexcept > { return ((*this) << reinterpret_cast<boost::array<char, N> const& >(input)); } > > template <std::size_t N> > bool operator<<(std::array<signed char, N> const& input) noexcept > { return ((*this) << reinterpret_cast<boost::array<char, N> const& >(input)); } > > template <std::size_t N> > bool operator<<(std::array<const CharT, N> const& input) noexcept > { > if (input.size()) return shl_char_array_limited(&input[0], N); > else return true; > } > > template <std::size_t N> > bool operator<<(std::array<const unsigned char, N> const& input) noexcept > { return ((*this) << reinterpret_cast<boost::array<const char, N> const& >(input)); } > > template <std::size_t N> > bool operator<<(std::array<const signed char, N> const& input) noexcept > { return ((*this) << reinterpret_cast<boost::array<const char, N> const& >(input)); } > > > template <class InStreamable> > bool operator<<(const InStreamable& input) { return shl_input_streamable(input); } > > > private: > > template <typename Type> > bool shr_unsigned(Type& output) > { > if (start == finish) return false; > CharT const minus = lcast_char_constants<CharT>::minus; > CharT const plus = lcast_char_constants<CharT>::plus; > bool has_minus = false; > > > if ( Traits::eq(minus,*start) ) > { > ++start; > has_minus = true; > } else if ( Traits::eq( plus, *start ) ) > { > ++start; > } > > bool const succeed = lcast_ret_unsigned<Traits>(output, start, finish); > > if (has_minus) { > output = static_cast<Type>(0u - output); > } > > return succeed; > } > > template <typename Type> > bool shr_signed(Type& output) > { > if (start == finish) return false; > CharT const minus = lcast_char_constants<CharT>::minus; > CharT const plus = lcast_char_constants<CharT>::plus; > typedef typename make_unsigned<Type>::type utype; > utype out_tmp =0; > bool has_minus = false; > > > if ( Traits::eq(minus,*start) ) > { > ++start; > has_minus = true; > } else if ( Traits::eq(plus, *start) ) > { > ++start; > } > > bool succeed = lcast_ret_unsigned<Traits>(out_tmp, start, finish); > if (has_minus) { > utype const comp_val = (static_cast<utype>(1) << std::numeric_limits<Type>::digits); > succeed = succeed && out_tmp<=comp_val; > output = static_cast<Type>(0u - out_tmp); > } else { > utype const comp_val = static_cast<utype>((std::numeric_limits<Type>::max)()); > succeed = succeed && out_tmp<=comp_val; > output = out_tmp; > } > return succeed; > } > > template<typename InputStreamable> > bool shr_using_base_class(InputStreamable& output) > { > static_assert((!boost::is_pointer<InputStreamable>::value), "boost::lexical_cast can not convert to pointers") > > > ; ># 2000 "/usr/include/boost/lexical_cast.hpp" 3 4 > buffer_t buf; > buf.setbuf(start, finish - start); > > > > std::basic_istream<CharT, Traits> stream(&buf); > > > > > stream.exceptions(std::ios::badbit); > try { > > stream.unsetf(std::ios::skipws); > lcast_set_precision(stream, static_cast<InputStreamable*>(0)); > > return stream >> output && > stream.get() == > > > > > > > > Traits::eof(); > > > > } catch (const ::std::ios_base::failure& ) { > return false; > } > > } > > template<class T> > inline bool shr_xchar(T& output) > { > static_assert(( sizeof(CharT) == sizeof(T) ), "boost::lexical_cast does not support narrowing of character types." "Use boost::locale instead") > > ; > bool const ok = (finish - start == 1); > if (ok) { > CharT out; > Traits::assign(out, *start); > output = static_cast<T>(out); > } > return ok; > } > > > public: > bool operator>>(unsigned short& output) { return shr_unsigned(output); } > bool operator>>(unsigned int& output) { return shr_unsigned(output); } > bool operator>>(unsigned long int& output) { return shr_unsigned(output); } > bool operator>>(short& output) { return shr_signed(output); } > bool operator>>(int& output) { return shr_signed(output); } > bool operator>>(long int& output) { return shr_signed(output); } > > bool operator>>(boost::ulong_long_type& output) { return shr_unsigned(output); } > bool operator>>(boost::long_long_type& output) { return shr_signed(output); } > > > > > > > bool operator>>(boost::uint128_type& output) { return shr_unsigned(output); } > bool operator>>(boost::int128_type& output) { return shr_signed(output); } > > > bool operator>>(char& output) { return shr_xchar(output); } > bool operator>>(unsigned char& output) { return shr_xchar(output); } > bool operator>>(signed char& output) { return shr_xchar(output); } > > bool operator>>(wchar_t& output) { return shr_xchar(output); } > > > bool operator>>(char16_t& output) { return shr_xchar(output); } > > > bool operator>>(char32_t& output) { return shr_xchar(output); } > > template<class Alloc> > bool operator>>(std::basic_string<CharT,Traits,Alloc>& str) { str.assign(start, finish); return true; } > > template<class Alloc> > bool operator>>(boost::container::basic_string<CharT,Traits,Alloc>& str) { str.assign(start, finish); return true; } > > > private: > template <std::size_t N, class ArrayT> > bool shr_std_array(ArrayT& output) noexcept > { > using namespace std; > const std::size_t size = finish - start; > if (size > N - 1) { > return false; > } > > memcpy(&output[0], start, size * sizeof(CharT)); > output[size] = Traits::to_char_type(0); > return true; > } > > public: > > template <std::size_t N> > bool operator>>(boost::array<CharT, N>& output) noexcept > { > return shr_std_array<N>(output); > } > > template <std::size_t N> > bool operator>>(boost::array<unsigned char, N>& output) > { > return ((*this) >> reinterpret_cast<boost::array<char, N>& >(output)); > } > > template <std::size_t N> > bool operator>>(boost::array<signed char, N>& output) > { > return ((*this) >> reinterpret_cast<boost::array<char, N>& >(output)); > } > > > template <std::size_t N> > bool operator>>(std::array<CharT, N>& output) noexcept > { > return shr_std_array<N>(output); > } > > template <std::size_t N> > bool operator>>(std::array<unsigned char, N>& output) > { > return ((*this) >> reinterpret_cast<std::array<char, N>& >(output)); > } > > template <std::size_t N> > bool operator>>(std::array<signed char, N>& output) > { > return ((*this) >> reinterpret_cast<std::array<char, N>& >(output)); > } ># 2151 "/usr/include/boost/lexical_cast.hpp" 3 4 > bool operator>>(bool& output) noexcept > { > CharT const zero = lcast_char_constants<CharT>::zero; > CharT const plus = lcast_char_constants<CharT>::plus; > CharT const minus = lcast_char_constants<CharT>::minus; > > switch(finish-start) > { > case 1: > output = Traits::eq(start[0], zero+1); > return output || Traits::eq(start[0], zero ); > case 2: > if ( Traits::eq( plus, *start) ) > { > ++start; > output = Traits::eq(start[0], zero +1); > return output || Traits::eq(start[0], zero ); > } else > { > output = false; > return Traits::eq( minus, *start) > && Traits::eq( zero, start[1]); > } > default: > output = false; > return false; > } > } > > bool operator>>(float& output) { return lcast_ret_float<Traits>(output,start,finish); } > > private: > > template <class T> > bool float_types_converter_internal(T& output, int ) { > if (parse_inf_nan(start, finish, output)) return true; > bool return_value = shr_using_base_class(output); > > > > > > > > CharT const minus = lcast_char_constants<CharT>::minus; > CharT const plus = lcast_char_constants<CharT>::plus; > CharT const capital_e = lcast_char_constants<CharT>::capital_e; > CharT const lowercase_e = lcast_char_constants<CharT>::lowercase_e; > if ( return_value && > ( > Traits::eq(*(finish-1), lowercase_e) > || Traits::eq(*(finish-1), capital_e) > || Traits::eq(*(finish-1), minus) > || Traits::eq(*(finish-1), plus) > ) > ) return false; > > return return_value; > } > > > bool float_types_converter_internal(double& output,char ) { > return lcast_ret_float<Traits>(output,start,finish); > } > public: > > bool operator>>(double& output) > { > > > > > > > boost::mpl::if_c< > > boost::type_traits::ice_eq< sizeof(double), sizeof(long double) >::value, > > > > int, > char > >::type tag = 0; > > return float_types_converter_internal(output, tag); > } > > bool operator>>(long double& output) > { > int tag = 0; > return float_types_converter_internal(output, tag); > } > > > > template<typename InputStreamable> > bool operator>>(InputStreamable& output) { return shr_using_base_class(output); } > }; > } > > namespace detail > { > template<typename T> > struct is_stdstring > { > static const bool value = false; > }; > > template<typename CharT, typename Traits, typename Alloc> > struct is_stdstring< std::basic_string<CharT, Traits, Alloc> > > { > static const bool value = true; > }; > > template<typename CharT, typename Traits, typename Alloc> > struct is_stdstring< boost::container::basic_string<CharT, Traits, Alloc> > > { > static const bool value = true; > }; > > template<typename Target, typename Source> > struct is_arithmetic_and_not_xchars > { > static const bool value = ( boost::type_traits::ice_and< boost::is_arithmetic<Source>::value, boost::is_arithmetic<Target>::value, boost::type_traits::ice_not< detail::is_char_or_wchar<Target>::value >::value, boost::type_traits::ice_not< detail::is_char_or_wchar<Source>::value >::value >::value ) ># 2287 "/usr/include/boost/lexical_cast.hpp" 3 4 > ; > }; > > > > > > > template<typename Target, typename Source> > struct is_xchar_to_xchar > { > static const bool value = ( boost::type_traits::ice_or< boost::type_traits::ice_and< is_same<Source,Target>::value, is_char_or_wchar<Target>::value >::value, boost::type_traits::ice_and< boost::type_traits::ice_eq< sizeof(char),sizeof(Target)>::value, boost::type_traits::ice_eq< sizeof(char),sizeof(Source)>::value, is_char_or_wchar<Target>::value, is_char_or_wchar<Source>::value >::value >::value ) ># 2313 "/usr/include/boost/lexical_cast.hpp" 3 4 > ; > }; > > template<typename Target, typename Source> > struct is_char_array_to_stdstring > { > static const bool value = false; > }; > > template<typename CharT, typename Traits, typename Alloc> > struct is_char_array_to_stdstring< std::basic_string<CharT, Traits, Alloc>, CharT* > > { > static const bool value = true; > }; > > template<typename CharT, typename Traits, typename Alloc> > struct is_char_array_to_stdstring< std::basic_string<CharT, Traits, Alloc>, const CharT* > > { > static const bool value = true; > }; > > template<typename CharT, typename Traits, typename Alloc> > struct is_char_array_to_stdstring< boost::container::basic_string<CharT, Traits, Alloc>, CharT* > > { > static const bool value = true; > }; > > template<typename CharT, typename Traits, typename Alloc> > struct is_char_array_to_stdstring< boost::container::basic_string<CharT, Traits, Alloc>, const CharT* > > { > static const bool value = true; > }; > > > > > > > > template<typename Target, typename Source> > struct lexical_cast_do_cast > { > static inline Target lexical_cast_impl(const Source& arg) > { > typedef lexical_cast_stream_traits<Source, Target> stream_trait; > > typedef detail::lexical_stream_limited_src< > typename stream_trait::char_type, > typename stream_trait::traits, > stream_trait::requires_stringbuf > > interpreter_type; > > > Target result; > > typename stream_trait::char_type buf[stream_trait::len_t::value + 1]; > stream_trait::len_t::check_coverage(); > > interpreter_type interpreter(buf, buf + stream_trait::len_t::value + 1); > > > if(!(interpreter.operator <<(arg) && interpreter.operator >>(result))) > throw_exception(bad_lexical_cast(typeid(Source), typeid(Target))); > > return result; > } > }; > > > > > template <typename Source> > struct lexical_cast_copy > { > static inline const Source& lexical_cast_impl(const Source &arg) noexcept > { > return arg; > } > }; > > template <class Source, class Target > > struct detect_precision_loss > { > typedef boost::numeric::Trunc<Source> Rounder; > typedef Source source_type ; > > typedef typename mpl::if_< > boost::is_arithmetic<Source>, Source, Source const& > >::type argument_type ; > > static source_type nearbyint ( argument_type s ) > { > const source_type near_int = Rounder::nearbyint(s); > if (near_int) { > const source_type orig_div_round = s / near_int; > const source_type eps = std::numeric_limits<source_type>::epsilon(); > > if ((orig_div_round > 1 ? orig_div_round - 1 : 1 - orig_div_round) > eps) > throw_exception(bad_lexical_cast(typeid(Source), typeid(Target))); > } > > return s ; > } > > typedef typename Rounder::round_style round_style; > } ; > > template <class Source, class Target > > struct nothrow_overflow_handler > { > void operator() ( boost::numeric::range_check_result r ) > { > if (r != boost::numeric::cInRange) > throw_exception(bad_lexical_cast(typeid(Source), typeid(Target))); > } > } ; > > template <typename Target, typename Source> > struct lexical_cast_dynamic_num_not_ignoring_minus > { > static inline Target lexical_cast_impl(const Source &arg) > { > return boost::numeric::converter< > Target, > Source, > boost::numeric::conversion_traits<Target,Source>, > nothrow_overflow_handler<Source, Target>, > detect_precision_loss<Source, Target> > >::convert(arg); > } > }; > > template <typename Target, typename Source> > struct lexical_cast_dynamic_num_ignoring_minus > { > static inline Target lexical_cast_impl(const Source &arg) > { > typedef typename boost::mpl::eval_if_c< > boost::is_float<Source>::value, > boost::mpl::identity<Source>, > boost::make_unsigned<Source> > >::type usource_t; > > typedef boost::numeric::converter< > Target, > usource_t, > boost::numeric::conversion_traits<Target,usource_t>, > nothrow_overflow_handler<usource_t, Target>, > detect_precision_loss<usource_t, Target> > > converter_t; > > return ( > arg < 0 ? static_cast<Target>(0u - converter_t::convert(0u - arg)) : converter_t::convert(arg) > ); > } > }; ># 2488 "/usr/include/boost/lexical_cast.hpp" 3 4 > template <typename Target, typename Source> > struct lexical_cast_dynamic_num > { > static inline Target lexical_cast_impl(const Source &arg) > { > typedef typename boost::mpl::if_c< > boost::type_traits::ice_and< > boost::type_traits::ice_or< > boost::is_signed<Source>::value, > boost::is_float<Source>::value > >::value, > boost::type_traits::ice_not< > boost::is_same<Source, bool>::value > >::value, > boost::type_traits::ice_not< > boost::is_same<Target, bool>::value > >::value, > boost::is_unsigned<Target>::value > >::value, > lexical_cast_dynamic_num_ignoring_minus<Target, Source>, > lexical_cast_dynamic_num_not_ignoring_minus<Target, Source> > >::type caster_type; > > return caster_type::lexical_cast_impl(arg); > } > }; > } > > template <typename Target, typename Source> > inline Target lexical_cast(const Source &arg) > { > typedef typename boost::detail::array_to_pointer_decay<Source>::type src; > > typedef typename boost::type_traits::ice_or< > boost::detail::is_xchar_to_xchar<Target, src >::value, > boost::detail::is_char_array_to_stdstring<Target, src >::value, > boost::type_traits::ice_and< > boost::is_same<Target, src >::value, > boost::detail::is_stdstring<Target >::value > >::value > > shall_we_copy_t; > > typedef typename > boost::detail::is_arithmetic_and_not_xchars<Target, src > shall_we_copy_with_dynamic_check_t; > > typedef typename boost::mpl::if_c< > shall_we_copy_t::value, > boost::detail::lexical_cast_copy<src >, > typename boost::mpl::if_c< > shall_we_copy_with_dynamic_check_t::value, > boost::detail::lexical_cast_dynamic_num<Target, src >, > boost::detail::lexical_cast_do_cast<Target, src > > >::type > >::type caster_type; > > return caster_type::lexical_cast_impl(arg); > } > > template <typename Target> > inline Target lexical_cast(const char* chars, std::size_t count) > { > return ::boost::lexical_cast<Target>( > ::boost::iterator_range<const char*>(chars, chars + count) > ); > } > > > template <typename Target> > inline Target lexical_cast(const unsigned char* chars, std::size_t count) > { > return ::boost::lexical_cast<Target>( > ::boost::iterator_range<const unsigned char*>(chars, chars + count) > ); > } > > template <typename Target> > inline Target lexical_cast(const signed char* chars, std::size_t count) > { > return ::boost::lexical_cast<Target>( > ::boost::iterator_range<const signed char*>(chars, chars + count) > ); > } > > > template <typename Target> > inline Target lexical_cast(const wchar_t* chars, std::size_t count) > { > return ::boost::lexical_cast<Target>( > ::boost::iterator_range<const wchar_t*>(chars, chars + count) > ); > } > > > template <typename Target> > inline Target lexical_cast(const char16_t* chars, std::size_t count) > { > return ::boost::lexical_cast<Target>( > ::boost::iterator_range<const char16_t*>(chars, chars + count) > ); > } > > > template <typename Target> > inline Target lexical_cast(const char32_t* chars, std::size_t count) > { > return ::boost::lexical_cast<Target>( > ::boost::iterator_range<const char32_t*>(chars, chars + count) > ); > } > > >} ># 39 "/c/honeypenny/contrib/epee/include/string_tools.h" 2 ># 1 "/usr/include/boost/asio.hpp" 1 3 4 ># 20 "/usr/include/boost/asio.hpp" 3 4 ># 1 "/usr/include/boost/asio/async_result.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/async_result.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/config.hpp" 1 3 4 ># 550 "/usr/include/boost/asio/detail/config.hpp" 3 4 ># 1 "/usr/include/linux/version.h" 1 3 4 ># 551 "/usr/include/boost/asio/detail/config.hpp" 2 3 4 ># 19 "/usr/include/boost/asio/async_result.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/handler_type.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/handler_type.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/handler_type.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 34 "/usr/include/boost/asio/handler_type.hpp" 3 4 >template <typename Handler, typename Signature> >struct handler_type >{ > > typedef Handler type; >}; > > > >template <typename Handler, typename Signature> >struct handler_type<const Handler, Signature> > : handler_type<Handler, Signature> {}; > >template <typename Handler, typename Signature> >struct handler_type<volatile Handler, Signature> > : handler_type<Handler, Signature> {}; > >template <typename Handler, typename Signature> >struct handler_type<const volatile Handler, Signature> > : handler_type<Handler, Signature> {}; > >template <typename Handler, typename Signature> >struct handler_type<const Handler&, Signature> > : handler_type<Handler, Signature> {}; > >template <typename Handler, typename Signature> >struct handler_type<volatile Handler&, Signature> > : handler_type<Handler, Signature> {}; > >template <typename Handler, typename Signature> >struct handler_type<const volatile Handler&, Signature> > : handler_type<Handler, Signature> {}; > >template <typename Handler, typename Signature> >struct handler_type<Handler&, Signature> > : handler_type<Handler, Signature> {}; > > >template <typename Handler, typename Signature> >struct handler_type<Handler&&, Signature> > : handler_type<Handler, Signature> {}; > > >template <typename ReturnType, typename Signature> >struct handler_type<ReturnType(), Signature> > : handler_type<ReturnType(*)(), Signature> {}; > >template <typename ReturnType, typename Arg1, typename Signature> >struct handler_type<ReturnType(Arg1), Signature> > : handler_type<ReturnType(*)(Arg1), Signature> {}; > >template <typename ReturnType, typename Arg1, typename Arg2, typename Signature> >struct handler_type<ReturnType(Arg1, Arg2), Signature> > : handler_type<ReturnType(*)(Arg1, Arg2), Signature> {}; > >template <typename ReturnType, typename Arg1, typename Arg2, typename Arg3, > typename Signature> >struct handler_type<ReturnType(Arg1, Arg2, Arg3), Signature> > : handler_type<ReturnType(*)(Arg1, Arg2, Arg3), Signature> {}; > >template <typename ReturnType, typename Arg1, typename Arg2, typename Arg3, > typename Arg4, typename Signature> >struct handler_type<ReturnType(Arg1, Arg2, Arg3, Arg4), Signature> > : handler_type<ReturnType(*)(Arg1, Arg2, Arg3, Arg4), Signature> {}; > >template <typename ReturnType, typename Arg1, typename Arg2, typename Arg3, > typename Arg4, typename Arg5, typename Signature> >struct handler_type<ReturnType(Arg1, Arg2, Arg3, Arg4, Arg5), Signature> > : handler_type<ReturnType(*)(Arg1, Arg2, Arg3, Arg4, Arg5), Signature> {}; > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 110 "/usr/include/boost/asio/handler_type.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/async_result.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/async_result.hpp" 2 3 4 > >namespace boost { >namespace asio { > > > > > >template <typename Handler> >class async_result >{ >public: > > typedef void type; > > > > > > > > explicit async_result(Handler&) > { > } > > > type get() > { > } >}; > >namespace detail { > > > >template <typename Handler, typename Signature> >struct async_result_init >{ > explicit async_result_init(Handler&& orig_handler) > : handler(static_cast<Handler&&>(orig_handler)), > result(handler) > { > } > > typename handler_type<Handler, Signature>::type handler; > async_result<typename handler_type<Handler, Signature>::type> result; >}; > >template <typename Handler, typename Signature> >struct async_result_type_helper >{ > typedef typename async_result< > typename handler_type<Handler, Signature>::type > >::type type; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 83 "/usr/include/boost/asio/async_result.hpp" 2 3 4 ># 21 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/basic_datagram_socket.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 ># 1 "/usr/include/boost/asio/basic_socket.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/basic_socket.hpp" 3 4 ># 1 "/usr/include/boost/asio/basic_io_object.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/basic_io_object.hpp" 3 4 ># 1 "/usr/include/boost/asio/io_service.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/io_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/noncopyable.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/noncopyable.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/noncopyable.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class noncopyable >{ >protected: > noncopyable() {} > ~noncopyable() {} >private: > noncopyable(const noncopyable&); > const noncopyable& operator=(const noncopyable&); >}; > >} > >using boost::asio::detail::noncopyable; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 44 "/usr/include/boost/asio/detail/noncopyable.hpp" 2 3 4 ># 24 "/usr/include/boost/asio/io_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/wrapped_handler.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/detail/wrapped_handler.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/bind_handler.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/bind_handler.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/handler_alloc_helpers.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/handler_alloc_helpers.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/addressof.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/addressof.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > >using std::addressof; > > > > >} >} >} ># 20 "/usr/include/boost/asio/detail/handler_alloc_helpers.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/handler_alloc_hook.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/handler_alloc_hook.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/handler_alloc_hook.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 58 "/usr/include/boost/asio/handler_alloc_hook.hpp" 3 4 >inline void* asio_handler_allocate( > std::size_t size, ...); ># 71 "/usr/include/boost/asio/handler_alloc_hook.hpp" 3 4 >inline void asio_handler_deallocate( > void* pointer, std::size_t size, ...); > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 78 "/usr/include/boost/asio/handler_alloc_hook.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/impl/handler_alloc_hook.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/impl/handler_alloc_hook.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/call_stack.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/call_stack.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/tss_ptr.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/tss_ptr.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/keyword_tss_ptr.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/keyword_tss_ptr.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/keyword_tss_ptr.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename T> >class keyword_tss_ptr > : private noncopyable >{ >public: > > keyword_tss_ptr() > { > } > > > ~keyword_tss_ptr() > { > } > > > operator T*() const > { > return value_; > } > > > void operator=(T* value) > { > value_ = value; > } > >private: > static __thread T* value_; >}; > >template <typename T> >__thread T* keyword_tss_ptr<T>::value_; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 69 "/usr/include/boost/asio/detail/keyword_tss_ptr.hpp" 2 3 4 ># 24 "/usr/include/boost/asio/detail/tss_ptr.hpp" 2 3 4 ># 32 "/usr/include/boost/asio/detail/tss_ptr.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/detail/tss_ptr.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename T> >class tss_ptr > > > > : public keyword_tss_ptr<T> > > > > > >{ >public: > void operator=(T* value) > { > > > > keyword_tss_ptr<T>::operator=(value); > > > > > > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 70 "/usr/include/boost/asio/detail/tss_ptr.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/detail/call_stack.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/call_stack.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > > >template <typename Key, typename Value = unsigned char> >class call_stack >{ >public: > > class context > : private noncopyable > { > public: > > explicit context(Key* k) > : key_(k), > next_(call_stack<Key, Value>::top_) > { > value_ = reinterpret_cast<unsigned char*>(this); > call_stack<Key, Value>::top_ = this; > } > > > context(Key* k, Value& v) > : key_(k), > value_(&v), > next_(call_stack<Key, Value>::top_) > { > call_stack<Key, Value>::top_ = this; > } > > > ~context() > { > call_stack<Key, Value>::top_ = next_; > } > > > Value* next_by_key() const > { > context* elem = next_; > while (elem) > { > if (elem->key_ == key_) > return elem->value_; > elem = elem->next_; > } > return 0; > } > > private: > friend class call_stack<Key, Value>; > > > Key* key_; > > > Value* value_; > > > context* next_; > }; > > friend class context; > > > > static Value* contains(Key* k) > { > context* elem = top_; > while (elem) > { > if (elem->key_ == k) > return elem->value_; > elem = elem->next_; > } > return 0; > } > > > static Value* top() > { > context* elem = top_; > return elem ? elem->value_ : 0; > } > >private: > > static tss_ptr<context> top_; >}; > >template <typename Key, typename Value> >tss_ptr<typename call_stack<Key, Value>::context> >call_stack<Key, Value>::top_; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 126 "/usr/include/boost/asio/detail/call_stack.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/impl/handler_alloc_hook.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/handler_alloc_hook.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/impl/handler_alloc_hook.ipp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/task_io_service_thread_info.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/detail/task_io_service_thread_info.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/event.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/event.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/posix_event.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/posix_event.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/assert.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/assert.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/detail/assert.hpp" 2 3 4 ># 24 "/usr/include/boost/asio/detail/posix_event.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/posix_event.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class posix_event > : private noncopyable >{ >public: > > inline posix_event(); > > > ~posix_event() > { > ::pthread_cond_destroy(&cond_); > } > > > template <typename Lock> > void signal(Lock& lock) > { > (static_cast<void> (0)); > (void)lock; > signalled_ = true; > ::pthread_cond_signal(&cond_); > } > > > template <typename Lock> > void signal_and_unlock(Lock& lock) > { > (static_cast<void> (0)); > signalled_ = true; > lock.unlock(); > ::pthread_cond_signal(&cond_); > } > > > template <typename Lock> > void clear(Lock& lock) > { > (static_cast<void> (0)); > (void)lock; > signalled_ = false; > } > > > template <typename Lock> > void wait(Lock& lock) > { > (static_cast<void> (0)); > while (!signalled_) > ::pthread_cond_wait(&cond_, &lock.mutex().mutex_); > } > >private: > ::pthread_cond_t cond_; > bool signalled_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 93 "/usr/include/boost/asio/detail/posix_event.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/posix_event.ipp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/impl/posix_event.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/posix_event.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/impl/posix_event.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/throw_error.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/throw_error.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/throw_error.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >inline void do_throw_error(const boost::system::error_code& err); > >inline void do_throw_error(const boost::system::error_code& err, > const char* location); > >inline void throw_error(const boost::system::error_code& err) >{ > if (err) > do_throw_error(err); >} > >inline void throw_error(const boost::system::error_code& err, > const char* location) >{ > if (err) > do_throw_error(err, location); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 50 "/usr/include/boost/asio/detail/throw_error.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/throw_error.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/impl/throw_error.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/throw_error.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/impl/throw_error.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/throw_exception.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/throw_exception.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > >using boost::throw_exception; ># 49 "/usr/include/boost/asio/detail/throw_exception.hpp" 3 4 >} >} >} ># 21 "/usr/include/boost/asio/detail/impl/throw_error.ipp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/impl/throw_error.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >void do_throw_error(const boost::system::error_code& err) >{ > boost::system::system_error e(err); > boost::asio::detail::throw_exception(e); >} > >void do_throw_error(const boost::system::error_code& err, const char* location) >{ > boost::system::system_error e(err, location); > boost::asio::detail::throw_exception(e); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 46 "/usr/include/boost/asio/detail/impl/throw_error.ipp" 2 3 4 ># 53 "/usr/include/boost/asio/detail/throw_error.hpp" 2 3 4 ># 24 "/usr/include/boost/asio/detail/impl/posix_event.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/error.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/error.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cerrno" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cerrno" 3 4 ># 40 "/usr/include/c++/4.9.0/cerrno" 3 > ># 1 "/usr/include/errno.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/cerrno" 2 3 ># 27 "/usr/include/boost/asio/error.hpp" 2 3 4 ># 1 "/usr/include/netdb.h" 1 3 4 ># 27 "/usr/include/netdb.h" 3 4 ># 1 "/usr/include/netinet/in.h" 1 3 4 ># 23 "/usr/include/netinet/in.h" 3 4 ># 1 "/usr/include/sys/socket.h" 1 3 4 ># 24 "/usr/include/sys/socket.h" 3 4 >extern "C" { > ># 1 "/usr/include/sys/uio.h" 1 3 4 ># 25 "/usr/include/sys/uio.h" 3 4 >extern "C" { > > ># 1 "/usr/include/bits/uio.h" 1 3 4 ># 43 "/usr/include/bits/uio.h" 3 4 >struct iovec > { > void *iov_base; > size_t iov_len; > }; ># 56 "/usr/include/bits/uio.h" 3 4 >extern "C" { > > >extern ssize_t process_vm_readv (pid_t __pid, const struct iovec *__lvec, > unsigned long int __liovcnt, > const struct iovec *__rvec, > unsigned long int __riovcnt, > unsigned long int __flags) > throw (); > > >extern ssize_t process_vm_writev (pid_t __pid, const struct iovec *__lvec, > unsigned long int __liovcnt, > const struct iovec *__rvec, > unsigned long int __riovcnt, > unsigned long int __flags) > throw (); > >} ># 29 "/usr/include/sys/uio.h" 2 3 4 ># 39 "/usr/include/sys/uio.h" 3 4 >extern ssize_t readv (int __fd, const struct iovec *__iovec, int __count) > ; ># 50 "/usr/include/sys/uio.h" 3 4 >extern ssize_t writev (int __fd, const struct iovec *__iovec, int __count) > ; ># 65 "/usr/include/sys/uio.h" 3 4 >extern ssize_t preadv (int __fd, const struct iovec *__iovec, int __count, > __off_t __offset) ; ># 77 "/usr/include/sys/uio.h" 3 4 >extern ssize_t pwritev (int __fd, const struct iovec *__iovec, int __count, > __off_t __offset) ; ># 103 "/usr/include/sys/uio.h" 3 4 >extern ssize_t preadv64 (int __fd, const struct iovec *__iovec, int __count, > __off64_t __offset) ; ># 115 "/usr/include/sys/uio.h" 3 4 >extern ssize_t pwritev64 (int __fd, const struct iovec *__iovec, int __count, > __off64_t __offset) ; > > > >} ># 27 "/usr/include/sys/socket.h" 2 3 4 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 29 "/usr/include/sys/socket.h" 2 3 4 > > ># 1 "/usr/include/bits/sigset.h" 1 3 4 ># 32 "/usr/include/sys/socket.h" 2 3 4 > > > > > > ># 1 "/usr/include/bits/socket.h" 1 3 4 ># 27 "/usr/include/bits/socket.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 28 "/usr/include/bits/socket.h" 2 3 4 ># 38 "/usr/include/bits/socket.h" 3 4 ># 1 "/usr/include/bits/socket_type.h" 1 3 4 ># 24 "/usr/include/bits/socket_type.h" 3 4 >enum __socket_type >{ > SOCK_STREAM = 1, > > > SOCK_DGRAM = 2, > > > SOCK_RAW = 3, > > SOCK_RDM = 4, > > SOCK_SEQPACKET = 5, > > > SOCK_DCCP = 6, > > SOCK_PACKET = 10, > > > > > > > > SOCK_CLOEXEC = 02000000, > > > SOCK_NONBLOCK = 00004000 > > >}; ># 39 "/usr/include/bits/socket.h" 2 3 4 ># 146 "/usr/include/bits/socket.h" 3 4 ># 1 "/usr/include/bits/sockaddr.h" 1 3 4 ># 28 "/usr/include/bits/sockaddr.h" 3 4 >typedef unsigned short int sa_family_t; ># 147 "/usr/include/bits/socket.h" 2 3 4 > > >struct sockaddr > { > sa_family_t sa_family; > char sa_data[14]; > }; ># 162 "/usr/include/bits/socket.h" 3 4 >struct sockaddr_storage > { > sa_family_t ss_family; > unsigned long int __ss_align; > char __ss_padding[(128 - (2 * sizeof (unsigned long int)))]; > }; > > > >enum > { > MSG_OOB = 0x01, > > MSG_PEEK = 0x02, > > MSG_DONTROUTE = 0x04, > > > > MSG_TRYHARD = MSG_DONTROUTE, > > > MSG_CTRUNC = 0x08, > > MSG_PROXY = 0x10, > > MSG_TRUNC = 0x20, > > MSG_DONTWAIT = 0x40, > > MSG_EOR = 0x80, > > MSG_WAITALL = 0x100, > > MSG_FIN = 0x200, > > MSG_SYN = 0x400, > > MSG_CONFIRM = 0x800, > > MSG_RST = 0x1000, > > MSG_ERRQUEUE = 0x2000, > > MSG_NOSIGNAL = 0x4000, > > MSG_MORE = 0x8000, > > MSG_WAITFORONE = 0x10000, > > MSG_FASTOPEN = 0x20000000, > > > MSG_CMSG_CLOEXEC = 0x40000000 > > > > }; > > > > >struct msghdr > { > void *msg_name; > socklen_t msg_namelen; > > struct iovec *msg_iov; > size_t msg_iovlen; > > void *msg_control; > size_t msg_controllen; > > > > > int msg_flags; > }; > > >struct cmsghdr > { > size_t cmsg_len; > > > > > int cmsg_level; > int cmsg_type; > > __extension__ unsigned char __cmsg_data []; > > }; ># 272 "/usr/include/bits/socket.h" 3 4 >extern struct cmsghdr *__cmsg_nxthdr (struct msghdr *__mhdr, > struct cmsghdr *__cmsg) throw (); > > > > >extern __inline __attribute__ ((__gnu_inline__)) struct cmsghdr * >__attribute__ ((__leaf__)) __cmsg_nxthdr (struct msghdr *__mhdr, struct cmsghdr *__cmsg) throw () >{ > if ((size_t) __cmsg->cmsg_len < sizeof (struct cmsghdr)) > > return (struct cmsghdr *) 0; > > __cmsg = (struct cmsghdr *) ((unsigned char *) __cmsg > + (((__cmsg->cmsg_len) + sizeof (size_t) - 1) & (size_t) ~(sizeof (size_t) - 1))); > if ((unsigned char *) (__cmsg + 1) > ((unsigned char *) __mhdr->msg_control > + __mhdr->msg_controllen) > || ((unsigned char *) __cmsg + (((__cmsg->cmsg_len) + sizeof (size_t) - 1) & (size_t) ~(sizeof (size_t) - 1)) > > ((unsigned char *) __mhdr->msg_control + __mhdr->msg_controllen))) > > return (struct cmsghdr *) 0; > return __cmsg; >} > > > > >enum > { > SCM_RIGHTS = 0x01 > > > , SCM_CREDENTIALS = 0x02 > > > }; > > > >struct ucred >{ > pid_t pid; > uid_t uid; > gid_t gid; >}; ># 345 "/usr/include/bits/socket.h" 3 4 ># 1 "/usr/include/asm/socket.h" 1 3 4 ># 1 "/usr/include/asm-generic/socket.h" 1 3 4 > > > ># 1 "/usr/include/asm/sockios.h" 1 3 4 ># 1 "/usr/include/asm-generic/sockios.h" 1 3 4 ># 1 "/usr/include/asm/sockios.h" 2 3 4 ># 5 "/usr/include/asm-generic/socket.h" 2 3 4 ># 1 "/usr/include/asm/socket.h" 2 3 4 ># 346 "/usr/include/bits/socket.h" 2 3 4 ># 379 "/usr/include/bits/socket.h" 3 4 >struct linger > { > int l_onoff; > int l_linger; > }; ># 39 "/usr/include/sys/socket.h" 2 3 4 > > > > >struct osockaddr > { > unsigned short int sa_family; > unsigned char sa_data[14]; > }; > > > > >enum >{ > SHUT_RD = 0, > > SHUT_WR, > > SHUT_RDWR > >}; ># 101 "/usr/include/sys/socket.h" 3 4 >struct mmsghdr > { > struct msghdr msg_hdr; > unsigned int msg_len; > > }; > > > > > > >extern int socket (int __domain, int __type, int __protocol) throw (); > > > > > >extern int socketpair (int __domain, int __type, int __protocol, > int __fds[2]) throw (); > > >extern int bind (int __fd, const struct sockaddr * __addr, socklen_t __len) > throw (); > > >extern int getsockname (int __fd, struct sockaddr *__restrict __addr, > socklen_t *__restrict __len) throw (); ># 137 "/usr/include/sys/socket.h" 3 4 >extern int connect (int __fd, const struct sockaddr * __addr, socklen_t __len); > > > >extern int getpeername (int __fd, struct sockaddr *__restrict __addr, > socklen_t *__restrict __len) throw (); > > > > > > >extern ssize_t send (int __fd, const void *__buf, size_t __n, int __flags); > > > > > > >extern ssize_t recv (int __fd, void *__buf, size_t __n, int __flags); > > > > > > >extern ssize_t sendto (int __fd, const void *__buf, size_t __n, > int __flags, const struct sockaddr * __addr, > socklen_t __addr_len); ># 174 "/usr/include/sys/socket.h" 3 4 >extern ssize_t recvfrom (int __fd, void *__restrict __buf, size_t __n, > int __flags, struct sockaddr *__restrict __addr, > socklen_t *__restrict __addr_len); > > > > > > > >extern ssize_t sendmsg (int __fd, const struct msghdr *__message, > int __flags); > > > > > > > >extern int sendmmsg (int __fd, struct mmsghdr *__vmessages, > unsigned int __vlen, int __flags); > > > > > > > >extern ssize_t recvmsg (int __fd, struct msghdr *__message, int __flags); > > > > > > > >extern int recvmmsg (int __fd, struct mmsghdr *__vmessages, > unsigned int __vlen, int __flags, > const struct timespec *__tmo); > > > > > > >extern int getsockopt (int __fd, int __level, int __optname, > void *__restrict __optval, > socklen_t *__restrict __optlen) throw (); > > > > >extern int setsockopt (int __fd, int __level, int __optname, > const void *__optval, socklen_t __optlen) throw (); > > > > > >extern int listen (int __fd, int __n) throw (); ># 243 "/usr/include/sys/socket.h" 3 4 >extern int accept (int __fd, struct sockaddr *__restrict __addr, > socklen_t *__restrict __addr_len); > > > > > > >extern int accept4 (int __fd, struct sockaddr *__restrict __addr, > socklen_t *__restrict __addr_len, int __flags); ># 261 "/usr/include/sys/socket.h" 3 4 >extern int shutdown (int __fd, int __how) throw (); > > > > >extern int sockatmark (int __fd) throw (); > > > > > > > >extern int isfdtype (int __fd, int __fdtype) throw (); ># 283 "/usr/include/sys/socket.h" 3 4 >} ># 24 "/usr/include/netinet/in.h" 2 3 4 > > > >extern "C" { > > >enum > { > IPPROTO_IP = 0, > > IPPROTO_HOPOPTS = 0, > > IPPROTO_ICMP = 1, > > IPPROTO_IGMP = 2, > > IPPROTO_IPIP = 4, > > IPPROTO_TCP = 6, > > IPPROTO_EGP = 8, > > IPPROTO_PUP = 12, > > IPPROTO_UDP = 17, > > IPPROTO_IDP = 22, > > IPPROTO_TP = 29, > > IPPROTO_DCCP = 33, > > IPPROTO_IPV6 = 41, > > IPPROTO_ROUTING = 43, > > IPPROTO_FRAGMENT = 44, > > IPPROTO_RSVP = 46, > > IPPROTO_GRE = 47, > > IPPROTO_ESP = 50, > > IPPROTO_AH = 51, > > IPPROTO_ICMPV6 = 58, > > IPPROTO_NONE = 59, > > IPPROTO_DSTOPTS = 60, > > IPPROTO_MTP = 92, > > IPPROTO_ENCAP = 98, > > IPPROTO_PIM = 103, > > IPPROTO_COMP = 108, > > IPPROTO_SCTP = 132, > > IPPROTO_UDPLITE = 136, > > IPPROTO_RAW = 255, > > IPPROTO_MAX > }; > > > >typedef uint16_t in_port_t; > > >enum > { > IPPORT_ECHO = 7, > IPPORT_DISCARD = 9, > IPPORT_SYSTAT = 11, > IPPORT_DAYTIME = 13, > IPPORT_NETSTAT = 15, > IPPORT_FTP = 21, > IPPORT_TELNET = 23, > IPPORT_SMTP = 25, > IPPORT_TIMESERVER = 37, > IPPORT_NAMESERVER = 42, > IPPORT_WHOIS = 43, > IPPORT_MTP = 57, > > IPPORT_TFTP = 69, > IPPORT_RJE = 77, > IPPORT_FINGER = 79, > IPPORT_TTYLINK = 87, > IPPORT_SUPDUP = 95, > > > IPPORT_EXECSERVER = 512, > IPPORT_LOGINSERVER = 513, > IPPORT_CMDSERVER = 514, > IPPORT_EFSSERVER = 520, > > > IPPORT_BIFFUDP = 512, > IPPORT_WHOSERVER = 513, > IPPORT_ROUTESERVER = 520, > > > IPPORT_RESERVED = 1024, > > > IPPORT_USERRESERVED = 5000 > }; > > > >typedef uint32_t in_addr_t; >struct in_addr > { > in_addr_t s_addr; > }; ># 196 "/usr/include/netinet/in.h" 3 4 >struct in6_addr > { > union > { > uint8_t __u6_addr8[16]; > > uint16_t __u6_addr16[8]; > uint32_t __u6_addr32[4]; > > } __in6_u; > > > > > > }; > >extern const struct in6_addr in6addr_any; >extern const struct in6_addr in6addr_loopback; ># 223 "/usr/include/netinet/in.h" 3 4 >struct sockaddr_in > { > sa_family_t sin_family; > in_port_t sin_port; > struct in_addr sin_addr; > > > unsigned char sin_zero[sizeof (struct sockaddr) - > (sizeof (unsigned short int)) - > sizeof (in_port_t) - > sizeof (struct in_addr)]; > }; > > >struct sockaddr_in6 > { > sa_family_t sin6_family; > in_port_t sin6_port; > uint32_t sin6_flowinfo; > struct in6_addr sin6_addr; > uint32_t sin6_scope_id; > }; > > > > >struct ip_mreq > { > > struct in_addr imr_multiaddr; > > > struct in_addr imr_interface; > }; > >struct ip_mreq_source > { > > struct in_addr imr_multiaddr; > > > struct in_addr imr_interface; > > > struct in_addr imr_sourceaddr; > }; > > > > >struct ipv6_mreq > { > > struct in6_addr ipv6mr_multiaddr; > > > unsigned int ipv6mr_interface; > }; > > > > >struct group_req > { > > uint32_t gr_interface; > > > struct sockaddr_storage gr_group; > }; > >struct group_source_req > { > > uint32_t gsr_interface; > > > struct sockaddr_storage gsr_group; > > > struct sockaddr_storage gsr_source; > }; > > > >struct ip_msfilter > { > > struct in_addr imsf_multiaddr; > > > struct in_addr imsf_interface; > > > uint32_t imsf_fmode; > > > uint32_t imsf_numsrc; > > struct in_addr imsf_slist[1]; > }; > > > > > >struct group_filter > { > > uint32_t gf_interface; > > > struct sockaddr_storage gf_group; > > > uint32_t gf_fmode; > > > uint32_t gf_numsrc; > > struct sockaddr_storage gf_slist[1]; >}; ># 354 "/usr/include/netinet/in.h" 3 4 ># 1 "/usr/include/bits/in.h" 1 3 4 ># 100 "/usr/include/bits/in.h" 3 4 >struct ip_opts > { > struct in_addr ip_dst; > char ip_opts[40]; > }; > > >struct ip_mreqn > { > struct in_addr imr_multiaddr; > struct in_addr imr_address; > int imr_ifindex; > }; > > >struct in_pktinfo > { > int ipi_ifindex; > struct in_addr ipi_spec_dst; > struct in_addr ipi_addr; > }; ># 355 "/usr/include/netinet/in.h" 2 3 4 ># 363 "/usr/include/netinet/in.h" 3 4 >extern uint32_t ntohl (uint32_t __netlong) throw () __attribute__ ((__const__)); >extern uint16_t ntohs (uint16_t __netshort) > throw () __attribute__ ((__const__)); >extern uint32_t htonl (uint32_t __hostlong) > throw () __attribute__ ((__const__)); >extern uint16_t htons (uint16_t __hostshort) > throw () __attribute__ ((__const__)); > > > > ># 1 "/usr/include/bits/byteswap.h" 1 3 4 ># 375 "/usr/include/netinet/in.h" 2 3 4 ># 490 "/usr/include/netinet/in.h" 3 4 >extern int bindresvport (int __sockfd, struct sockaddr_in *__sock_in) throw (); > > >extern int bindresvport6 (int __sockfd, struct sockaddr_in6 *__sock_in) > throw (); ># 520 "/usr/include/netinet/in.h" 3 4 >struct cmsghdr; > > >struct in6_pktinfo > { > struct in6_addr ipi6_addr; > unsigned int ipi6_ifindex; > }; > > >struct ip6_mtuinfo > { > struct sockaddr_in6 ip6m_addr; > uint32_t ip6m_mtu; > }; > > > >extern int inet6_option_space (int __nbytes) > throw () __attribute__ ((__deprecated__)); >extern int inet6_option_init (void *__bp, struct cmsghdr **__cmsgp, > int __type) throw () __attribute__ ((__deprecated__)); >extern int inet6_option_append (struct cmsghdr *__cmsg, > const uint8_t *__typep, int __multx, > int __plusy) throw () __attribute__ ((__deprecated__)); >extern uint8_t *inet6_option_alloc (struct cmsghdr *__cmsg, int __datalen, > int __multx, int __plusy) > throw () __attribute__ ((__deprecated__)); >extern int inet6_option_next (const struct cmsghdr *__cmsg, > uint8_t **__tptrp) > throw () __attribute__ ((__deprecated__)); >extern int inet6_option_find (const struct cmsghdr *__cmsg, > uint8_t **__tptrp, int __type) > throw () __attribute__ ((__deprecated__)); > > > >extern int inet6_opt_init (void *__extbuf, socklen_t __extlen) throw (); >extern int inet6_opt_append (void *__extbuf, socklen_t __extlen, int __offset, > uint8_t __type, socklen_t __len, uint8_t __align, > void **__databufp) throw (); >extern int inet6_opt_finish (void *__extbuf, socklen_t __extlen, int __offset) > throw (); >extern int inet6_opt_set_val (void *__databuf, int __offset, void *__val, > socklen_t __vallen) throw (); >extern int inet6_opt_next (void *__extbuf, socklen_t __extlen, int __offset, > uint8_t *__typep, socklen_t *__lenp, > void **__databufp) throw (); >extern int inet6_opt_find (void *__extbuf, socklen_t __extlen, int __offset, > uint8_t __type, socklen_t *__lenp, > void **__databufp) throw (); >extern int inet6_opt_get_val (void *__databuf, int __offset, void *__val, > socklen_t __vallen) throw (); > > > >extern socklen_t inet6_rth_space (int __type, int __segments) throw (); >extern void *inet6_rth_init (void *__bp, socklen_t __bp_len, int __type, > int __segments) throw (); >extern int inet6_rth_add (void *__bp, const struct in6_addr *__addr) throw (); >extern int inet6_rth_reverse (const void *__in, void *__out) throw (); >extern int inet6_rth_segments (const void *__bp) throw (); >extern struct in6_addr *inet6_rth_getaddr (const void *__bp, int __index) > throw (); > > > > > >extern int getipv4sourcefilter (int __s, struct in_addr __interface_addr, > struct in_addr __group, uint32_t *__fmode, > uint32_t *__numsrc, struct in_addr *__slist) > throw (); > > >extern int setipv4sourcefilter (int __s, struct in_addr __interface_addr, > struct in_addr __group, uint32_t __fmode, > uint32_t __numsrc, > const struct in_addr *__slist) > throw (); > > > >extern int getsourcefilter (int __s, uint32_t __interface_addr, > const struct sockaddr *__group, > socklen_t __grouplen, uint32_t *__fmode, > uint32_t *__numsrc, > struct sockaddr_storage *__slist) throw (); > > >extern int setsourcefilter (int __s, uint32_t __interface_addr, > const struct sockaddr *__group, > socklen_t __grouplen, uint32_t __fmode, > uint32_t __numsrc, > const struct sockaddr_storage *__slist) throw (); > > >} ># 28 "/usr/include/netdb.h" 2 3 4 > > > > ># 1 "/usr/include/rpc/netdb.h" 1 3 4 ># 42 "/usr/include/rpc/netdb.h" 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 43 "/usr/include/rpc/netdb.h" 2 3 4 > >extern "C" { > >struct rpcent >{ > char *r_name; > char **r_aliases; > int r_number; >}; > >extern void setrpcent (int __stayopen) throw (); >extern void endrpcent (void) throw (); >extern struct rpcent *getrpcbyname (const char *__name) throw (); >extern struct rpcent *getrpcbynumber (int __number) throw (); >extern struct rpcent *getrpcent (void) throw (); > > >extern int getrpcbyname_r (const char *__name, struct rpcent *__result_buf, > char *__buffer, size_t __buflen, > struct rpcent **__result) throw (); > >extern int getrpcbynumber_r (int __number, struct rpcent *__result_buf, > char *__buffer, size_t __buflen, > struct rpcent **__result) throw (); > >extern int getrpcent_r (struct rpcent *__result_buf, char *__buffer, > size_t __buflen, struct rpcent **__result) throw (); > > >} ># 33 "/usr/include/netdb.h" 2 3 4 > > > > ># 1 "/usr/include/bits/siginfo.h" 1 3 4 ># 24 "/usr/include/bits/siginfo.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 25 "/usr/include/bits/siginfo.h" 2 3 4 > > > > > > > >typedef union sigval > { > int sival_int; > void *sival_ptr; > } sigval_t; ># 307 "/usr/include/bits/siginfo.h" 3 4 >typedef struct sigevent > { > sigval_t sigev_value; > int sigev_signo; > int sigev_notify; > > union > { > int _pad[((64 / sizeof (int)) - 4)]; > > > > __pid_t _tid; > > struct > { > void (*_function) (sigval_t); > pthread_attr_t *_attribute; > } _sigev_thread; > } _sigev_un; > } sigevent_t; > > > > > > >enum >{ > SIGEV_SIGNAL = 0, > > SIGEV_NONE, > > SIGEV_THREAD, > > > SIGEV_THREAD_ID = 4 > >}; ># 38 "/usr/include/netdb.h" 2 3 4 > > > > ># 1 "/usr/include/bits/netdb.h" 1 3 4 ># 26 "/usr/include/bits/netdb.h" 3 4 >struct netent >{ > char *n_name; > char **n_aliases; > int n_addrtype; > uint32_t n_net; >}; ># 43 "/usr/include/netdb.h" 2 3 4 ># 53 "/usr/include/netdb.h" 3 4 >extern "C" { > > > > > > > >extern int *__h_errno_location (void) throw () __attribute__ ((__const__)); ># 92 "/usr/include/netdb.h" 3 4 >extern void herror (const char *__str) throw (); > > >extern const char *hstrerror (int __err_num) throw (); > > > > >struct hostent >{ > char *h_name; > char **h_aliases; > int h_addrtype; > int h_length; > char **h_addr_list; > > > >}; > > > > > > >extern void sethostent (int __stay_open); > > > > > >extern void endhostent (void); > > > > > > >extern struct hostent *gethostent (void); > > > > > > >extern struct hostent *gethostbyaddr (const void *__addr, __socklen_t __len, > int __type); > > > > > >extern struct hostent *gethostbyname (const char *__name); ># 155 "/usr/include/netdb.h" 3 4 >extern struct hostent *gethostbyname2 (const char *__name, int __af); ># 167 "/usr/include/netdb.h" 3 4 >extern int gethostent_r (struct hostent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct hostent **__restrict __result, > int *__restrict __h_errnop); > >extern int gethostbyaddr_r (const void *__restrict __addr, __socklen_t __len, > int __type, > struct hostent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct hostent **__restrict __result, > int *__restrict __h_errnop); > >extern int gethostbyname_r (const char *__restrict __name, > struct hostent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct hostent **__restrict __result, > int *__restrict __h_errnop); > >extern int gethostbyname2_r (const char *__restrict __name, int __af, > struct hostent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct hostent **__restrict __result, > int *__restrict __h_errnop); ># 198 "/usr/include/netdb.h" 3 4 >extern void setnetent (int __stay_open); > > > > > >extern void endnetent (void); > > > > > > >extern struct netent *getnetent (void); > > > > > > >extern struct netent *getnetbyaddr (uint32_t __net, int __type); > > > > > >extern struct netent *getnetbyname (const char *__name); ># 237 "/usr/include/netdb.h" 3 4 >extern int getnetent_r (struct netent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct netent **__restrict __result, > int *__restrict __h_errnop); > >extern int getnetbyaddr_r (uint32_t __net, int __type, > struct netent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct netent **__restrict __result, > int *__restrict __h_errnop); > >extern int getnetbyname_r (const char *__restrict __name, > struct netent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct netent **__restrict __result, > int *__restrict __h_errnop); > > > > >struct servent >{ > char *s_name; > char **s_aliases; > int s_port; > char *s_proto; >}; > > > > > > >extern void setservent (int __stay_open); > > > > > >extern void endservent (void); > > > > > > >extern struct servent *getservent (void); > > > > > > >extern struct servent *getservbyname (const char *__name, const char *__proto); > > > > > > >extern struct servent *getservbyport (int __port, const char *__proto); ># 308 "/usr/include/netdb.h" 3 4 >extern int getservent_r (struct servent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct servent **__restrict __result); > >extern int getservbyname_r (const char *__restrict __name, > const char *__restrict __proto, > struct servent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct servent **__restrict __result); > >extern int getservbyport_r (int __port, const char *__restrict __proto, > struct servent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct servent **__restrict __result); > > > > >struct protoent >{ > char *p_name; > char **p_aliases; > int p_proto; >}; > > > > > > >extern void setprotoent (int __stay_open); > > > > > >extern void endprotoent (void); > > > > > > >extern struct protoent *getprotoent (void); > > > > > >extern struct protoent *getprotobyname (const char *__name); > > > > > >extern struct protoent *getprotobynumber (int __proto); ># 374 "/usr/include/netdb.h" 3 4 >extern int getprotoent_r (struct protoent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct protoent **__restrict __result); > >extern int getprotobyname_r (const char *__restrict __name, > struct protoent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct protoent **__restrict __result); > >extern int getprotobynumber_r (int __proto, > struct protoent *__restrict __result_buf, > char *__restrict __buf, size_t __buflen, > struct protoent **__restrict __result); ># 395 "/usr/include/netdb.h" 3 4 >extern int setnetgrent (const char *__netgroup); > > > > > > > >extern void endnetgrent (void); ># 412 "/usr/include/netdb.h" 3 4 >extern int getnetgrent (char **__restrict __hostp, > char **__restrict __userp, > char **__restrict __domainp); ># 423 "/usr/include/netdb.h" 3 4 >extern int innetgr (const char *__netgroup, const char *__host, > const char *__user, const char *__domain); > > > > > > > >extern int getnetgrent_r (char **__restrict __hostp, > char **__restrict __userp, > char **__restrict __domainp, > char *__restrict __buffer, size_t __buflen); ># 451 "/usr/include/netdb.h" 3 4 >extern int rcmd (char **__restrict __ahost, unsigned short int __rport, > const char *__restrict __locuser, > const char *__restrict __remuser, > const char *__restrict __cmd, int *__restrict __fd2p); ># 463 "/usr/include/netdb.h" 3 4 >extern int rcmd_af (char **__restrict __ahost, unsigned short int __rport, > const char *__restrict __locuser, > const char *__restrict __remuser, > const char *__restrict __cmd, int *__restrict __fd2p, > sa_family_t __af); ># 479 "/usr/include/netdb.h" 3 4 >extern int rexec (char **__restrict __ahost, int __rport, > const char *__restrict __name, > const char *__restrict __pass, > const char *__restrict __cmd, int *__restrict __fd2p); ># 491 "/usr/include/netdb.h" 3 4 >extern int rexec_af (char **__restrict __ahost, int __rport, > const char *__restrict __name, > const char *__restrict __pass, > const char *__restrict __cmd, int *__restrict __fd2p, > sa_family_t __af); ># 505 "/usr/include/netdb.h" 3 4 >extern int ruserok (const char *__rhost, int __suser, > const char *__remuser, const char *__locuser); ># 515 "/usr/include/netdb.h" 3 4 >extern int ruserok_af (const char *__rhost, int __suser, > const char *__remuser, const char *__locuser, > sa_family_t __af); ># 528 "/usr/include/netdb.h" 3 4 >extern int iruserok (uint32_t __raddr, int __suser, > const char *__remuser, const char *__locuser); ># 539 "/usr/include/netdb.h" 3 4 >extern int iruserok_af (const void *__raddr, int __suser, > const char *__remuser, const char *__locuser, > sa_family_t __af); ># 551 "/usr/include/netdb.h" 3 4 >extern int rresvport (int *__alport); ># 560 "/usr/include/netdb.h" 3 4 >extern int rresvport_af (int *__alport, sa_family_t __af); > > > > > > >struct addrinfo >{ > int ai_flags; > int ai_family; > int ai_socktype; > int ai_protocol; > socklen_t ai_addrlen; > struct sockaddr *ai_addr; > char *ai_canonname; > struct addrinfo *ai_next; >}; > > > >struct gaicb >{ > const char *ar_name; > const char *ar_service; > const struct addrinfo *ar_request; > struct addrinfo *ar_result; > > int __return; > int __unused[5]; >}; ># 662 "/usr/include/netdb.h" 3 4 >extern int getaddrinfo (const char *__restrict __name, > const char *__restrict __service, > const struct addrinfo *__restrict __req, > struct addrinfo **__restrict __pai); > > >extern void freeaddrinfo (struct addrinfo *__ai) throw (); > > >extern const char *gai_strerror (int __ecode) throw (); > > > > > >extern int getnameinfo (const struct sockaddr *__restrict __sa, > socklen_t __salen, char *__restrict __host, > socklen_t __hostlen, char *__restrict __serv, > socklen_t __servlen, int __flags); ># 692 "/usr/include/netdb.h" 3 4 >extern int getaddrinfo_a (int __mode, struct gaicb *__list[], > int __ent, struct sigevent *__restrict __sig); ># 703 "/usr/include/netdb.h" 3 4 >extern int gai_suspend (const struct gaicb *const __list[], int __ent, > const struct timespec *__timeout); > > >extern int gai_error (struct gaicb *__req) throw (); > > >extern int gai_cancel (struct gaicb *__gaicbp) throw (); > > >} ># 28 "/usr/include/boost/asio/error.hpp" 2 3 4 ># 61 "/usr/include/boost/asio/error.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 62 "/usr/include/boost/asio/error.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace error { > >enum basic_errors >{ > > access_denied = 13, > > > address_family_not_supported = 97, > > > address_in_use = 98, > > > already_connected = 106, > > > already_started = 114, > > > broken_pipe = 32 > > , > > > connection_aborted = 103, > > > connection_refused = 111, > > > connection_reset = 104, > > > bad_descriptor = 9, > > > fault = 14, > > > host_unreachable = 113, > > > in_progress = 115, > > > interrupted = 4, > > > invalid_argument = 22, > > > message_size = 90, > > > name_too_long = 36, > > > network_down = 100, > > > network_reset = 102, > > > network_unreachable = 101, > > > no_descriptors = 24, > > > no_buffer_space = 105, > > > no_memory = 12 > > , > > > no_permission = 1 > > , > > > no_protocol_option = 92, > > > not_connected = 107, > > > not_socket = 88, > > > operation_aborted = 125 > > , > > > operation_not_supported = 95, > > > shut_down = 108, > > > timed_out = 110, > > > try_again = 11 > > , > > > would_block = 11 >}; > >enum netdb_errors >{ > > host_not_found = 1, > > > host_not_found_try_again = 2, > > > no_data = 4, > > > no_recovery = 3 >}; > >enum addrinfo_errors >{ > > service_not_found = -8 > > , > > > socket_type_not_supported = -7 > > >}; > >enum misc_errors >{ > > already_open = 1, > > > eof, > > > not_found, > > > fd_set_failure >}; > >inline const boost::system::error_category& get_system_category() >{ > return boost::system::system_category(); >} > > > >extern inline >const boost::system::error_category& get_netdb_category(); > >extern inline >const boost::system::error_category& get_addrinfo_category(); ># 249 "/usr/include/boost/asio/error.hpp" 3 4 >extern inline >const boost::system::error_category& get_misc_category(); > >static const boost::system::error_category& system_category > = boost::asio::error::get_system_category(); >static const boost::system::error_category& netdb_category > = boost::asio::error::get_netdb_category(); >static const boost::system::error_category& addrinfo_category > = boost::asio::error::get_addrinfo_category(); >static const boost::system::error_category& misc_category > = boost::asio::error::get_misc_category(); > >} >} >} > >namespace boost { >namespace system { > >template<> struct is_error_code_enum<boost::asio::error::basic_errors> >{ > static const bool value = true; >}; > >template<> struct is_error_code_enum<boost::asio::error::netdb_errors> >{ > static const bool value = true; >}; > >template<> struct is_error_code_enum<boost::asio::error::addrinfo_errors> >{ > static const bool value = true; >}; > >template<> struct is_error_code_enum<boost::asio::error::misc_errors> >{ > static const bool value = true; >}; > >} >} > >namespace boost { >namespace asio { >namespace error { > >inline boost::system::error_code make_error_code(basic_errors e) >{ > return boost::system::error_code( > static_cast<int>(e), get_system_category()); >} > >inline boost::system::error_code make_error_code(netdb_errors e) >{ > return boost::system::error_code( > static_cast<int>(e), get_netdb_category()); >} > >inline boost::system::error_code make_error_code(addrinfo_errors e) >{ > return boost::system::error_code( > static_cast<int>(e), get_addrinfo_category()); >} > >inline boost::system::error_code make_error_code(misc_errors e) >{ > return boost::system::error_code( > static_cast<int>(e), get_misc_category()); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 324 "/usr/include/boost/asio/error.hpp" 2 3 4 ># 332 "/usr/include/boost/asio/error.hpp" 3 4 ># 1 "/usr/include/boost/asio/impl/error.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/impl/error.ipp" 3 4 ># 1 "/usr/include/boost/asio/error.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/impl/error.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/impl/error.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace error { > > > >namespace detail { > >class netdb_category : public boost::system::error_category >{ >public: > const char* name() const noexcept > { > return "asio.netdb"; > } > > std::string message(int value) const > { > if (value == error::host_not_found) > return "Host not found (authoritative)"; > if (value == error::host_not_found_try_again) > return "Host not found (non-authoritative), try again later"; > if (value == error::no_data) > return "The query is valid, but it does not have associated data"; > if (value == error::no_recovery) > return "A non-recoverable error occurred during database lookup"; > return "asio.netdb error"; > } >}; > >} > >const boost::system::error_category& get_netdb_category() >{ > static detail::netdb_category instance; > return instance; >} > >namespace detail { > >class addrinfo_category : public boost::system::error_category >{ >public: > const char* name() const noexcept > { > return "asio.addrinfo"; > } > > std::string message(int value) const > { > if (value == error::service_not_found) > return "Service not found"; > if (value == error::socket_type_not_supported) > return "Socket type not supported"; > return "asio.addrinfo error"; > } >}; > >} > >const boost::system::error_category& get_addrinfo_category() >{ > static detail::addrinfo_category instance; > return instance; >} > > > >namespace detail { > >class misc_category : public boost::system::error_category >{ >public: > const char* name() const noexcept > { > return "asio.misc"; > } > > std::string message(int value) const > { > if (value == error::already_open) > return "Already open"; > if (value == error::eof) > return "End of file"; > if (value == error::not_found) > return "Element not found"; > if (value == error::fd_set_failure) > return "The descriptor does not fit into the select call's fd_set"; > return "asio.misc error"; > } >}; > >} > >const boost::system::error_category& get_misc_category() >{ > static detail::misc_category instance; > return instance; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 128 "/usr/include/boost/asio/impl/error.ipp" 2 3 4 ># 333 "/usr/include/boost/asio/error.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/detail/impl/posix_event.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/impl/posix_event.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >posix_event::posix_event() > : signalled_(false) >{ > int error = ::pthread_cond_init(&cond_, 0); > boost::system::error_code ec(error, > boost::asio::error::get_system_category()); > boost::asio::detail::throw_error(ec, "event"); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 46 "/usr/include/boost/asio/detail/impl/posix_event.ipp" 2 3 4 ># 96 "/usr/include/boost/asio/detail/posix_event.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/detail/event.hpp" 2 3 4 > > > > > > >namespace boost { >namespace asio { >namespace detail { > > > > > > >typedef posix_event event; > > > > >} >} >} ># 19 "/usr/include/boost/asio/detail/task_io_service_thread_info.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/op_queue.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/op_queue.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/op_queue.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Operation> >class op_queue; > >class op_queue_access >{ >public: > template <typename Operation> > static Operation* next(Operation* o) > { > return static_cast<Operation*>(o->next_); > } > > template <typename Operation1, typename Operation2> > static void next(Operation1*& o1, Operation2* o2) > { > o1->next_ = o2; > } > > template <typename Operation> > static void destroy(Operation* o) > { > o->destroy(); > } > > template <typename Operation> > static Operation*& front(op_queue<Operation>& q) > { > return q.front_; > } > > template <typename Operation> > static Operation*& back(op_queue<Operation>& q) > { > return q.back_; > } >}; > >template <typename Operation> >class op_queue > : private noncopyable >{ >public: > > op_queue() > : front_(0), > back_(0) > { > } > > > ~op_queue() > { > while (Operation* op = front_) > { > pop(); > op_queue_access::destroy(op); > } > } > > > Operation* front() > { > return front_; > } > > > void pop() > { > if (front_) > { > Operation* tmp = front_; > front_ = op_queue_access::next(front_); > if (front_ == 0) > back_ = 0; > op_queue_access::next(tmp, static_cast<Operation*>(0)); > } > } > > > void push(Operation* h) > { > op_queue_access::next(h, static_cast<Operation*>(0)); > if (back_) > { > op_queue_access::next(back_, h); > back_ = h; > } > else > { > front_ = back_ = h; > } > } > > > > template <typename OtherOperation> > void push(op_queue<OtherOperation>& q) > { > if (Operation* other_front = op_queue_access::front(q)) > { > if (back_) > op_queue_access::next(back_, other_front); > else > front_ = other_front; > back_ = op_queue_access::back(q); > op_queue_access::front(q) = 0; > op_queue_access::back(q) = 0; > } > } > > > bool empty() const > { > return front_ == 0; > } > >private: > friend class op_queue_access; > > > Operation* front_; > > > Operation* back_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 157 "/usr/include/boost/asio/detail/op_queue.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/detail/task_io_service_thread_info.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/thread_info_base.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/detail/thread_info_base.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 19 "/usr/include/boost/asio/detail/thread_info_base.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/thread_info_base.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class thread_info_base > : private noncopyable >{ >public: > thread_info_base() > : reusable_memory_(0) > { > } > > ~thread_info_base() > { > if (reusable_memory_) > ::operator delete(reusable_memory_); > } > > static void* allocate(thread_info_base* this_thread, std::size_t size) > { > if (this_thread && this_thread->reusable_memory_) > { > void* const pointer = this_thread->reusable_memory_; > this_thread->reusable_memory_ = 0; > > unsigned char* const mem = static_cast<unsigned char*>(pointer); > if (static_cast<std::size_t>(mem[0]) >= size) > { > mem[size] = mem[0]; > return pointer; > } > > ::operator delete(pointer); > } > > void* const pointer = ::operator new(size + 1); > unsigned char* const mem = static_cast<unsigned char*>(pointer); > mem[size] = (size <= (127 * 2 + 1)) ? static_cast<unsigned char>(size) : 0; > return pointer; > } > > static void deallocate(thread_info_base* this_thread, > void* pointer, std::size_t size) > { > if (size <= (127 * 2 + 1)) > { > if (this_thread && this_thread->reusable_memory_ == 0) > { > unsigned char* const mem = static_cast<unsigned char*>(pointer); > mem[0] = mem[size]; > this_thread->reusable_memory_ = pointer; > return; > } > } > > ::operator delete(pointer); > } > >private: > void* reusable_memory_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 92 "/usr/include/boost/asio/detail/thread_info_base.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/detail/task_io_service_thread_info.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/task_io_service_thread_info.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class task_io_service; >class task_io_service_operation; > >struct task_io_service_thread_info : public thread_info_base >{ > event* wakeup_event; > op_queue<task_io_service_operation> private_op_queue; > long private_outstanding_work; > task_io_service_thread_info* next; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 44 "/usr/include/boost/asio/detail/task_io_service_thread_info.hpp" 2 3 4 ># 27 "/usr/include/boost/asio/impl/handler_alloc_hook.ipp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/impl/handler_alloc_hook.ipp" 2 3 4 > >namespace boost { >namespace asio { > > > > > >void* asio_handler_allocate(std::size_t size, ...) >{ > > > > > > typedef detail::task_io_service io_service_impl; > typedef detail::task_io_service_thread_info thread_info; > > typedef detail::call_stack<io_service_impl, thread_info> call_stack; > return thread_info::allocate(call_stack::top(), size); > > > >} > >void asio_handler_deallocate(void* pointer, std::size_t size, ...) >{ > > > > > > typedef detail::task_io_service io_service_impl; > typedef detail::task_io_service_thread_info thread_info; > > typedef detail::call_stack<io_service_impl, thread_info> call_stack; > thread_info::deallocate(call_stack::top(), pointer, size); > > > > >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 78 "/usr/include/boost/asio/impl/handler_alloc_hook.ipp" 2 3 4 ># 81 "/usr/include/boost/asio/handler_alloc_hook.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/detail/handler_alloc_helpers.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/handler_alloc_helpers.hpp" 2 3 4 > > > > >namespace boost_asio_handler_alloc_helpers { > >template <typename Handler> >inline void* allocate(std::size_t s, Handler& h) >{ > > > > using boost::asio::asio_handler_allocate; > return asio_handler_allocate(s, boost::asio::detail::addressof(h)); > >} > >template <typename Handler> >inline void deallocate(void* p, std::size_t s, Handler& h) >{ > > > > using boost::asio::asio_handler_deallocate; > asio_handler_deallocate(p, s, boost::asio::detail::addressof(h)); > >} > >} ># 80 "/usr/include/boost/asio/detail/handler_alloc_helpers.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 81 "/usr/include/boost/asio/detail/handler_alloc_helpers.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/detail/bind_handler.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/handler_cont_helpers.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/handler_cont_helpers.hpp" 3 4 ># 1 "/usr/include/boost/asio/handler_continuation_hook.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/handler_continuation_hook.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/handler_continuation_hook.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 46 "/usr/include/boost/asio/handler_continuation_hook.hpp" 3 4 >inline bool asio_handler_is_continuation(...) >{ > return false; >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 55 "/usr/include/boost/asio/handler_continuation_hook.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/detail/handler_cont_helpers.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/handler_cont_helpers.hpp" 2 3 4 > > > > >namespace boost_asio_handler_cont_helpers { > >template <typename Context> >inline bool is_continuation(Context& context) >{ > > > > using boost::asio::asio_handler_is_continuation; > return asio_handler_is_continuation( > boost::asio::detail::addressof(context)); > >} > >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 44 "/usr/include/boost/asio/detail/handler_cont_helpers.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/detail/bind_handler.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/handler_invoke_helpers.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/handler_invoke_helpers.hpp" 3 4 ># 1 "/usr/include/boost/asio/handler_invoke_hook.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/handler_invoke_hook.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/handler_invoke_hook.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 66 "/usr/include/boost/asio/handler_invoke_hook.hpp" 3 4 >template <typename Function> >inline void asio_handler_invoke(Function& function, ...) >{ > function(); >} > > >template <typename Function> >inline void asio_handler_invoke(const Function& function, ...) >{ > Function tmp(function); > tmp(); >} > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 86 "/usr/include/boost/asio/handler_invoke_hook.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/detail/handler_invoke_helpers.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/handler_invoke_helpers.hpp" 2 3 4 > > > > >namespace boost_asio_handler_invoke_helpers { > >template <typename Function, typename Context> >inline void invoke(Function& function, Context& context) >{ > > > > > using boost::asio::asio_handler_invoke; > asio_handler_invoke(function, boost::asio::detail::addressof(context)); > >} > >template <typename Function, typename Context> >inline void invoke(const Function& function, Context& context) >{ > > > > > using boost::asio::asio_handler_invoke; > asio_handler_invoke(function, boost::asio::detail::addressof(context)); > >} > >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 56 "/usr/include/boost/asio/detail/handler_invoke_helpers.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/detail/bind_handler.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/bind_handler.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Handler, typename Arg1> >class binder1 >{ >public: > binder1(const Handler& handler, const Arg1& arg1) > : handler_(handler), > arg1_(arg1) > { > } > > binder1(Handler& handler, const Arg1& arg1) > : handler_(static_cast<Handler&&>(handler)), > arg1_(arg1) > { > } > > void operator()() > { > handler_(static_cast<const Arg1&>(arg1_)); > } > > void operator()() const > { > handler_(arg1_); > } > > > Handler handler_; > Arg1 arg1_; >}; > >template <typename Handler, typename Arg1> >inline void* asio_handler_allocate(std::size_t size, > binder1<Handler, Arg1>* this_handler) >{ > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); >} > >template <typename Handler, typename Arg1> >inline void asio_handler_deallocate(void* pointer, std::size_t size, > binder1<Handler, Arg1>* this_handler) >{ > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); >} > >template <typename Handler, typename Arg1> >inline bool asio_handler_is_continuation( > binder1<Handler, Arg1>* this_handler) >{ > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1> >inline void asio_handler_invoke(Function& function, > binder1<Handler, Arg1>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1> >inline void asio_handler_invoke(const Function& function, > binder1<Handler, Arg1>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Handler, typename Arg1> >inline binder1<Handler, Arg1> bind_handler(Handler handler, > const Arg1& arg1) >{ > return binder1<Handler, Arg1>(handler, arg1); >} > >template <typename Handler, typename Arg1, typename Arg2> >class binder2 >{ >public: > binder2(const Handler& handler, const Arg1& arg1, const Arg2& arg2) > : handler_(handler), > arg1_(arg1), > arg2_(arg2) > { > } > > binder2(Handler& handler, const Arg1& arg1, const Arg2& arg2) > : handler_(static_cast<Handler&&>(handler)), > arg1_(arg1), > arg2_(arg2) > { > } > > void operator()() > { > handler_(static_cast<const Arg1&>(arg1_), > static_cast<const Arg2&>(arg2_)); > } > > void operator()() const > { > handler_(arg1_, arg2_); > } > > > Handler handler_; > Arg1 arg1_; > Arg2 arg2_; >}; > >template <typename Handler, typename Arg1, typename Arg2> >inline void* asio_handler_allocate(std::size_t size, > binder2<Handler, Arg1, Arg2>* this_handler) >{ > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2> >inline void asio_handler_deallocate(void* pointer, std::size_t size, > binder2<Handler, Arg1, Arg2>* this_handler) >{ > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2> >inline bool asio_handler_is_continuation( > binder2<Handler, Arg1, Arg2>* this_handler) >{ > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1, typename Arg2> >inline void asio_handler_invoke(Function& function, > binder2<Handler, Arg1, Arg2>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1, typename Arg2> >inline void asio_handler_invoke(const Function& function, > binder2<Handler, Arg1, Arg2>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2> >inline binder2<Handler, Arg1, Arg2> bind_handler(Handler handler, > const Arg1& arg1, const Arg2& arg2) >{ > return binder2<Handler, Arg1, Arg2>(handler, arg1, arg2); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3> >class binder3 >{ >public: > binder3(const Handler& handler, const Arg1& arg1, const Arg2& arg2, > const Arg3& arg3) > : handler_(handler), > arg1_(arg1), > arg2_(arg2), > arg3_(arg3) > { > } > > binder3(Handler& handler, const Arg1& arg1, const Arg2& arg2, > const Arg3& arg3) > : handler_(static_cast<Handler&&>(handler)), > arg1_(arg1), > arg2_(arg2), > arg3_(arg3) > { > } > > void operator()() > { > handler_(static_cast<const Arg1&>(arg1_), > static_cast<const Arg2&>(arg2_), > static_cast<const Arg3&>(arg3_)); > } > > void operator()() const > { > handler_(arg1_, arg2_, arg3_); > } > > > Handler handler_; > Arg1 arg1_; > Arg2 arg2_; > Arg3 arg3_; >}; > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3> >inline void* asio_handler_allocate(std::size_t size, > binder3<Handler, Arg1, Arg2, Arg3>* this_handler) >{ > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3> >inline void asio_handler_deallocate(void* pointer, std::size_t size, > binder3<Handler, Arg1, Arg2, Arg3>* this_handler) >{ > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3> >inline bool asio_handler_is_continuation( > binder3<Handler, Arg1, Arg2, Arg3>* this_handler) >{ > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1, typename Arg2, > typename Arg3> >inline void asio_handler_invoke(Function& function, > binder3<Handler, Arg1, Arg2, Arg3>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1, typename Arg2, > typename Arg3> >inline void asio_handler_invoke(const Function& function, > binder3<Handler, Arg1, Arg2, Arg3>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3> >inline binder3<Handler, Arg1, Arg2, Arg3> bind_handler(Handler handler, > const Arg1& arg1, const Arg2& arg2, const Arg3& arg3) >{ > return binder3<Handler, Arg1, Arg2, Arg3>(handler, arg1, arg2, arg3); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4> >class binder4 >{ >public: > binder4(const Handler& handler, const Arg1& arg1, const Arg2& arg2, > const Arg3& arg3, const Arg4& arg4) > : handler_(handler), > arg1_(arg1), > arg2_(arg2), > arg3_(arg3), > arg4_(arg4) > { > } > > binder4(Handler& handler, const Arg1& arg1, const Arg2& arg2, > const Arg3& arg3, const Arg4& arg4) > : handler_(static_cast<Handler&&>(handler)), > arg1_(arg1), > arg2_(arg2), > arg3_(arg3), > arg4_(arg4) > { > } > > void operator()() > { > handler_(static_cast<const Arg1&>(arg1_), > static_cast<const Arg2&>(arg2_), > static_cast<const Arg3&>(arg3_), > static_cast<const Arg4&>(arg4_)); > } > > void operator()() const > { > handler_(arg1_, arg2_, arg3_, arg4_); > } > > > Handler handler_; > Arg1 arg1_; > Arg2 arg2_; > Arg3 arg3_; > Arg4 arg4_; >}; > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4> >inline void* asio_handler_allocate(std::size_t size, > binder4<Handler, Arg1, Arg2, Arg3, Arg4>* this_handler) >{ > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4> >inline void asio_handler_deallocate(void* pointer, std::size_t size, > binder4<Handler, Arg1, Arg2, Arg3, Arg4>* this_handler) >{ > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4> >inline bool asio_handler_is_continuation( > binder4<Handler, Arg1, Arg2, Arg3, Arg4>* this_handler) >{ > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1, typename Arg2, > typename Arg3, typename Arg4> >inline void asio_handler_invoke(Function& function, > binder4<Handler, Arg1, Arg2, Arg3, Arg4>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1, typename Arg2, > typename Arg3, typename Arg4> >inline void asio_handler_invoke(const Function& function, > binder4<Handler, Arg1, Arg2, Arg3, Arg4>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4> >inline binder4<Handler, Arg1, Arg2, Arg3, Arg4> bind_handler( > Handler handler, const Arg1& arg1, const Arg2& arg2, > const Arg3& arg3, const Arg4& arg4) >{ > return binder4<Handler, Arg1, Arg2, Arg3, Arg4>(handler, arg1, arg2, arg3, > arg4); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4, typename Arg5> >class binder5 >{ >public: > binder5(const Handler& handler, const Arg1& arg1, const Arg2& arg2, > const Arg3& arg3, const Arg4& arg4, const Arg5& arg5) > : handler_(handler), > arg1_(arg1), > arg2_(arg2), > arg3_(arg3), > arg4_(arg4), > arg5_(arg5) > { > } > > binder5(Handler& handler, const Arg1& arg1, const Arg2& arg2, > const Arg3& arg3, const Arg4& arg4, const Arg5& arg5) > : handler_(static_cast<Handler&&>(handler)), > arg1_(arg1), > arg2_(arg2), > arg3_(arg3), > arg4_(arg4), > arg5_(arg5) > { > } > > void operator()() > { > handler_(static_cast<const Arg1&>(arg1_), > static_cast<const Arg2&>(arg2_), > static_cast<const Arg3&>(arg3_), > static_cast<const Arg4&>(arg4_), > static_cast<const Arg5&>(arg5_)); > } > > void operator()() const > { > handler_(arg1_, arg2_, arg3_, arg4_, arg5_); > } > > > Handler handler_; > Arg1 arg1_; > Arg2 arg2_; > Arg3 arg3_; > Arg4 arg4_; > Arg5 arg5_; >}; > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4, typename Arg5> >inline void* asio_handler_allocate(std::size_t size, > binder5<Handler, Arg1, Arg2, Arg3, Arg4, Arg5>* this_handler) >{ > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4, typename Arg5> >inline void asio_handler_deallocate(void* pointer, std::size_t size, > binder5<Handler, Arg1, Arg2, Arg3, Arg4, Arg5>* this_handler) >{ > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4, typename Arg5> >inline bool asio_handler_is_continuation( > binder5<Handler, Arg1, Arg2, Arg3, Arg4, Arg5>* this_handler) >{ > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1, typename Arg2, > typename Arg3, typename Arg4, typename Arg5> >inline void asio_handler_invoke(Function& function, > binder5<Handler, Arg1, Arg2, Arg3, Arg4, Arg5>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Function, typename Handler, typename Arg1, typename Arg2, > typename Arg3, typename Arg4, typename Arg5> >inline void asio_handler_invoke(const Function& function, > binder5<Handler, Arg1, Arg2, Arg3, Arg4, Arg5>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); >} > >template <typename Handler, typename Arg1, typename Arg2, typename Arg3, > typename Arg4, typename Arg5> >inline binder5<Handler, Arg1, Arg2, Arg3, Arg4, Arg5> bind_handler( > Handler handler, const Arg1& arg1, const Arg2& arg2, > const Arg3& arg3, const Arg4& arg4, const Arg5& arg5) >{ > return binder5<Handler, Arg1, Arg2, Arg3, Arg4, Arg5>(handler, arg1, arg2, > arg3, arg4, arg5); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 490 "/usr/include/boost/asio/detail/bind_handler.hpp" 2 3 4 ># 19 "/usr/include/boost/asio/detail/wrapped_handler.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/wrapped_handler.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >struct is_continuation_delegated >{ > template <typename Dispatcher, typename Handler> > bool operator()(Dispatcher&, Handler& handler) const > { > return boost_asio_handler_cont_helpers::is_continuation(handler); > } >}; > >struct is_continuation_if_running >{ > template <typename Dispatcher, typename Handler> > bool operator()(Dispatcher& dispatcher, Handler&) const > { > return dispatcher.running_in_this_thread(); > } >}; > >template <typename Dispatcher, typename Handler, > typename IsContinuation = is_continuation_delegated> >class wrapped_handler >{ >public: > typedef void result_type; > > wrapped_handler(Dispatcher dispatcher, Handler& handler) > : dispatcher_(dispatcher), > handler_(static_cast<Handler&&>(handler)) > { > } > > > wrapped_handler(const wrapped_handler& other) > : dispatcher_(other.dispatcher_), > handler_(other.handler_) > { > } > > wrapped_handler(wrapped_handler&& other) > : dispatcher_(other.dispatcher_), > handler_(static_cast<Handler&&>(other.handler_)) > { > } > > > void operator()() > { > dispatcher_.dispatch(static_cast<Handler&&>(handler_)); > } > > void operator()() const > { > dispatcher_.dispatch(handler_); > } > > template <typename Arg1> > void operator()(const Arg1& arg1) > { > dispatcher_.dispatch(detail::bind_handler(handler_, arg1)); > } > > template <typename Arg1> > void operator()(const Arg1& arg1) const > { > dispatcher_.dispatch(detail::bind_handler(handler_, arg1)); > } > > template <typename Arg1, typename Arg2> > void operator()(const Arg1& arg1, const Arg2& arg2) > { > dispatcher_.dispatch(detail::bind_handler(handler_, arg1, arg2)); > } > > template <typename Arg1, typename Arg2> > void operator()(const Arg1& arg1, const Arg2& arg2) const > { > dispatcher_.dispatch(detail::bind_handler(handler_, arg1, arg2)); > } > > template <typename Arg1, typename Arg2, typename Arg3> > void operator()(const Arg1& arg1, const Arg2& arg2, const Arg3& arg3) > { > dispatcher_.dispatch(detail::bind_handler(handler_, arg1, arg2, arg3)); > } > > template <typename Arg1, typename Arg2, typename Arg3> > void operator()(const Arg1& arg1, const Arg2& arg2, const Arg3& arg3) const > { > dispatcher_.dispatch(detail::bind_handler(handler_, arg1, arg2, arg3)); > } > > template <typename Arg1, typename Arg2, typename Arg3, typename Arg4> > void operator()(const Arg1& arg1, const Arg2& arg2, const Arg3& arg3, > const Arg4& arg4) > { > dispatcher_.dispatch( > detail::bind_handler(handler_, arg1, arg2, arg3, arg4)); > } > > template <typename Arg1, typename Arg2, typename Arg3, typename Arg4> > void operator()(const Arg1& arg1, const Arg2& arg2, const Arg3& arg3, > const Arg4& arg4) const > { > dispatcher_.dispatch( > detail::bind_handler(handler_, arg1, arg2, arg3, arg4)); > } > > template <typename Arg1, typename Arg2, typename Arg3, typename Arg4, > typename Arg5> > void operator()(const Arg1& arg1, const Arg2& arg2, const Arg3& arg3, > const Arg4& arg4, const Arg5& arg5) > { > dispatcher_.dispatch( > detail::bind_handler(handler_, arg1, arg2, arg3, arg4, arg5)); > } > > template <typename Arg1, typename Arg2, typename Arg3, typename Arg4, > typename Arg5> > void operator()(const Arg1& arg1, const Arg2& arg2, const Arg3& arg3, > const Arg4& arg4, const Arg5& arg5) const > { > dispatcher_.dispatch( > detail::bind_handler(handler_, arg1, arg2, arg3, arg4, arg5)); > } > > > Dispatcher dispatcher_; > Handler handler_; >}; > >template <typename Handler, typename Context> >class rewrapped_handler >{ >public: > explicit rewrapped_handler(Handler& handler, const Context& context) > : context_(context), > handler_(static_cast<Handler&&>(handler)) > { > } > > explicit rewrapped_handler(const Handler& handler, const Context& context) > : context_(context), > handler_(handler) > { > } > > > rewrapped_handler(const rewrapped_handler& other) > : context_(other.context_), > handler_(other.handler_) > { > } > > rewrapped_handler(rewrapped_handler&& other) > : context_(static_cast<Context&&>(other.context_)), > handler_(static_cast<Handler&&>(other.handler_)) > { > } > > > void operator()() > { > handler_(); > } > > void operator()() const > { > handler_(); > } > > > Context context_; > Handler handler_; >}; > >template <typename Dispatcher, typename Handler, typename IsContinuation> >inline void* asio_handler_allocate(std::size_t size, > wrapped_handler<Dispatcher, Handler, IsContinuation>* this_handler) >{ > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); >} > >template <typename Dispatcher, typename Handler, typename IsContinuation> >inline void asio_handler_deallocate(void* pointer, std::size_t size, > wrapped_handler<Dispatcher, Handler, IsContinuation>* this_handler) >{ > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); >} > >template <typename Dispatcher, typename Handler, typename IsContinuation> >inline bool asio_handler_is_continuation( > wrapped_handler<Dispatcher, Handler, IsContinuation>* this_handler) >{ > return IsContinuation()(this_handler->dispatcher_, this_handler->handler_); >} > >template <typename Function, typename Dispatcher, > typename Handler, typename IsContinuation> >inline void asio_handler_invoke(Function& function, > wrapped_handler<Dispatcher, Handler, IsContinuation>* this_handler) >{ > this_handler->dispatcher_.dispatch( > rewrapped_handler<Function, Handler>( > function, this_handler->handler_)); >} > >template <typename Function, typename Dispatcher, > typename Handler, typename IsContinuation> >inline void asio_handler_invoke(const Function& function, > wrapped_handler<Dispatcher, Handler, IsContinuation>* this_handler) >{ > this_handler->dispatcher_.dispatch( > rewrapped_handler<Function, Handler>( > function, this_handler->handler_)); >} > >template <typename Handler, typename Context> >inline void* asio_handler_allocate(std::size_t size, > rewrapped_handler<Handler, Context>* this_handler) >{ > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->context_); >} > >template <typename Handler, typename Context> >inline void asio_handler_deallocate(void* pointer, std::size_t size, > rewrapped_handler<Handler, Context>* this_handler) >{ > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->context_); >} > >template <typename Dispatcher, typename Context> >inline bool asio_handler_is_continuation( > rewrapped_handler<Dispatcher, Context>* this_handler) >{ > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); >} > >template <typename Function, typename Handler, typename Context> >inline void asio_handler_invoke(Function& function, > rewrapped_handler<Handler, Context>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->context_); >} > >template <typename Function, typename Handler, typename Context> >inline void asio_handler_invoke(const Function& function, > rewrapped_handler<Handler, Context>* this_handler) >{ > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->context_); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 292 "/usr/include/boost/asio/detail/wrapped_handler.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/io_service.hpp" 2 3 4 ># 34 "/usr/include/boost/asio/io_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 35 "/usr/include/boost/asio/io_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > >class io_service; >template <typename Service> Service& use_service(io_service& ios); >template <typename Service> void add_service(io_service& ios, Service* svc); >template <typename Service> bool has_service(io_service& ios); > >namespace detail { > > > > > typedef class task_io_service io_service_impl; > > class service_registry; >} ># 185 "/usr/include/boost/asio/io_service.hpp" 3 4 >class io_service > : private noncopyable >{ >private: > typedef detail::io_service_impl impl_type; > > > > >public: > class work; > friend class work; > > class id; > > class service; > > class strand; > > > inline io_service(); ># 214 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline explicit io_service(std::size_t concurrency_hint); ># 248 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline ~io_service(); ># 276 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline std::size_t run(); ># 304 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline std::size_t run(boost::system::error_code& ec); ># 320 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline std::size_t run_one(); ># 336 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline std::size_t run_one(boost::system::error_code& ec); ># 348 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline std::size_t poll(); ># 360 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline std::size_t poll(boost::system::error_code& ec); ># 372 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline std::size_t poll_one(); ># 384 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline std::size_t poll_one(boost::system::error_code& ec); ># 393 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline void stop(); ># 405 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline bool stopped() const; ># 418 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline void reset(); ># 441 "/usr/include/boost/asio/io_service.hpp" 3 4 > template <typename CompletionHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<CompletionHandler, void ()>::type>::type > dispatch(CompletionHandler&& handler); ># 467 "/usr/include/boost/asio/io_service.hpp" 3 4 > template <typename CompletionHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<CompletionHandler, void ()>::type>::type > post(CompletionHandler&& handler); ># 493 "/usr/include/boost/asio/io_service.hpp" 3 4 > template <typename Handler> > > > > detail::wrapped_handler<io_service&, Handler> > > wrap(Handler handler); > > > enum fork_event > { > > fork_prepare, > > > fork_parent, > > > fork_child > }; ># 554 "/usr/include/boost/asio/io_service.hpp" 3 4 > inline void notify_fork(boost::asio::io_service::fork_event event); ># 567 "/usr/include/boost/asio/io_service.hpp" 3 4 > template <typename Service> > friend Service& use_service(io_service& ios); ># 587 "/usr/include/boost/asio/io_service.hpp" 3 4 > template <typename Service> > friend void add_service(io_service& ios, Service* svc); ># 599 "/usr/include/boost/asio/io_service.hpp" 3 4 > template <typename Service> > friend bool has_service(io_service& ios); > >private: ># 611 "/usr/include/boost/asio/io_service.hpp" 3 4 > boost::asio::detail::service_registry* service_registry_; > > > impl_type& impl_; >}; ># 627 "/usr/include/boost/asio/io_service.hpp" 3 4 >class io_service::work >{ >public: > > > > > > > explicit work(boost::asio::io_service& io_service); > > > > > > > > work(const work& other); > > > > > > > > ~work(); > > > boost::asio::io_service& get_io_service(); > >private: > > void operator=(const work& other); > > > detail::io_service_impl& io_service_impl_; >}; > > >class io_service::id > : private noncopyable >{ >public: > > id() {} >}; > > >class io_service::service > : private noncopyable >{ >public: > > boost::asio::io_service& get_io_service(); > >protected: > > > > > inline service(boost::asio::io_service& owner); > > > inline virtual ~service(); > >private: > > virtual void shutdown_service() = 0; > > > > > > > > inline virtual void fork_service( > boost::asio::io_service::fork_event event); > > friend class boost::asio::detail::service_registry; > struct key > { > key() : type_info_(0), id_(0) {} > const std::type_info* type_info_; > const boost::asio::io_service::id* id_; > } key_; > > boost::asio::io_service& owner_; > service* next_; >}; > > >class service_already_exists > : public std::logic_error >{ >public: > inline service_already_exists(); >}; > > > >class invalid_service_owner > : public std::logic_error >{ >public: > inline invalid_service_owner(); >}; > >namespace detail { > > >template <typename Type> >class service_id > : public boost::asio::io_service::id >{ >}; > > >template <typename Type> >class service_base > : public boost::asio::io_service::service >{ >public: > static boost::asio::detail::service_id<Type> id; > > > service_base(boost::asio::io_service& io_service) > : boost::asio::io_service::service(io_service) > { > } >}; > >template <typename Type> >boost::asio::detail::service_id<Type> service_base<Type>::id; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 766 "/usr/include/boost/asio/io_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/io_service.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/impl/io_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/handler_type_requirements.hpp" 1 3 4 ># 66 "/usr/include/boost/asio/detail/handler_type_requirements.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > > > > >template <typename Handler> >auto zero_arg_handler_test(Handler h, void*) > -> decltype( > sizeof(Handler(static_cast<const Handler&>(h))), > ((h)()), > char(0)); > >template <typename Handler> >char (&zero_arg_handler_test(Handler, ...))[2]; > >template <typename Handler, typename Arg1> >auto one_arg_handler_test(Handler h, Arg1* a1) > -> decltype( > sizeof(Handler(static_cast<const Handler&>(h))), > ((h)(*a1)), > char(0)); > >template <typename Handler> >char (&one_arg_handler_test(Handler h, ...))[2]; > >template <typename Handler, typename Arg1, typename Arg2> >auto two_arg_handler_test(Handler h, Arg1* a1, Arg2* a2) > -> decltype( > sizeof(Handler(static_cast<const Handler&>(h))), > ((h)(*a1, *a2)), > char(0)); > >template <typename Handler> >char (&two_arg_handler_test(Handler, ...))[2]; ># 113 "/usr/include/boost/asio/detail/handler_type_requirements.hpp" 3 4 >template <typename T> T& lvref(); >template <typename T> T& lvref(T); >template <typename T> const T& clvref(); >template <typename T> const T& clvref(T); >template <typename T> char argbyv(T); > >template <int> >struct handler_type_requirements >{ >}; ># 486 "/usr/include/boost/asio/detail/handler_type_requirements.hpp" 3 4 >} >} >} ># 19 "/usr/include/boost/asio/impl/io_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/service_registry.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/service_registry.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/mutex.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/mutex.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/posix_mutex.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/posix_mutex.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/scoped_lock.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/scoped_lock.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/scoped_lock.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > >template <typename Mutex> >class scoped_lock > : private noncopyable >{ >public: > > enum adopt_lock_t { adopt_lock }; > > > scoped_lock(Mutex& m, adopt_lock_t) > : mutex_(m), > locked_(true) > { > } > > > explicit scoped_lock(Mutex& m) > : mutex_(m) > { > mutex_.lock(); > locked_ = true; > } > > > ~scoped_lock() > { > if (locked_) > mutex_.unlock(); > } > > > void lock() > { > if (!locked_) > { > mutex_.lock(); > locked_ = true; > } > } > > > void unlock() > { > if (locked_) > { > mutex_.unlock(); > locked_ = false; > } > } > > > bool locked() const > { > return locked_; > } > > > Mutex& mutex() > { > return mutex_; > } > >private: > > Mutex& mutex_; > > > bool locked_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 102 "/usr/include/boost/asio/detail/scoped_lock.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/detail/posix_mutex.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/posix_mutex.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class posix_event; > >class posix_mutex > : private noncopyable >{ >public: > typedef boost::asio::detail::scoped_lock<posix_mutex> scoped_lock; > > > inline posix_mutex(); > > > ~posix_mutex() > { > ::pthread_mutex_destroy(&mutex_); > } > > > void lock() > { > (void)::pthread_mutex_lock(&mutex_); > } > > > void unlock() > { > (void)::pthread_mutex_unlock(&mutex_); > } > >private: > friend class posix_event; > ::pthread_mutex_t mutex_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 71 "/usr/include/boost/asio/detail/posix_mutex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/posix_mutex.ipp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/impl/posix_mutex.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/posix_mutex.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/impl/posix_mutex.ipp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/impl/posix_mutex.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >posix_mutex::posix_mutex() >{ > int error = ::pthread_mutex_init(&mutex_, 0); > boost::system::error_code ec(error, > boost::asio::error::get_system_category()); > boost::asio::detail::throw_error(ec, "mutex"); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 45 "/usr/include/boost/asio/detail/impl/posix_mutex.ipp" 2 3 4 ># 74 "/usr/include/boost/asio/detail/posix_mutex.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/detail/mutex.hpp" 2 3 4 > > > > > > >namespace boost { >namespace asio { >namespace detail { > > > > > > >typedef posix_mutex mutex; > > > > >} >} >} ># 21 "/usr/include/boost/asio/detail/service_registry.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/io_service.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/service_registry.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/service_registry.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > > >#pragma GCC visibility push (default) > > > >template <typename T> >class typeid_wrapper {}; > > > >#pragma GCC visibility pop > > > >class service_registry > : private noncopyable >{ >public: > > template <typename Service, typename Arg> > service_registry(boost::asio::io_service& o, > Service* initial_service, Arg arg); > > > inline ~service_registry(); > > > inline void notify_fork(boost::asio::io_service::fork_event fork_ev); > > > > template <typename Service> > Service& first_service(); > > > > > template <typename Service> > Service& use_service(); > > > > template <typename Service> > void add_service(Service* new_service); > > > template <typename Service> > bool has_service() const; > >private: > > inline static void init_key( > boost::asio::io_service::service::key& key, > const boost::asio::io_service::id& id); > > > > template <typename Service> > static void init_key(boost::asio::io_service::service::key& key, > const boost::asio::detail::service_id<Service>& ); > > > > inline static bool keys_match( > const boost::asio::io_service::service::key& key1, > const boost::asio::io_service::service::key& key2); > > > typedef boost::asio::io_service::service* > (*factory_type)(boost::asio::io_service&); > > > template <typename Service> > static boost::asio::io_service::service* create( > boost::asio::io_service& owner); > > > inline static void destroy( > boost::asio::io_service::service* service); > > > struct auto_service_ptr; > friend struct auto_service_ptr; > struct auto_service_ptr > { > boost::asio::io_service::service* ptr_; > ~auto_service_ptr() { destroy(ptr_); } > }; > > > > > inline boost::asio::io_service::service* do_use_service( > const boost::asio::io_service::service::key& key, > factory_type factory); > > > > inline void do_add_service( > const boost::asio::io_service::service::key& key, > boost::asio::io_service::service* new_service); > > > inline bool do_has_service( > const boost::asio::io_service::service::key& key) const; > > > mutable boost::asio::detail::mutex mutex_; > > > boost::asio::io_service& owner_; > > > boost::asio::io_service::service* first_service_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 152 "/usr/include/boost/asio/detail/service_registry.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/impl/service_registry.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/detail/impl/service_registry.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/impl/service_registry.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Service, typename Arg> >service_registry::service_registry( > boost::asio::io_service& o, Service*, Arg arg) > : owner_(o), > first_service_(new Service(o, arg)) >{ > boost::asio::io_service::service::key key; > init_key(key, Service::id); > first_service_->key_ = key; > first_service_->next_ = 0; >} > >template <typename Service> >Service& service_registry::first_service() >{ > return *static_cast<Service*>(first_service_); >} > >template <typename Service> >Service& service_registry::use_service() >{ > boost::asio::io_service::service::key key; > init_key(key, Service::id); > factory_type factory = &service_registry::create<Service>; > return *static_cast<Service*>(do_use_service(key, factory)); >} > >template <typename Service> >void service_registry::add_service(Service* new_service) >{ > boost::asio::io_service::service::key key; > init_key(key, Service::id); > return do_add_service(key, new_service); >} > >template <typename Service> >bool service_registry::has_service() const >{ > boost::asio::io_service::service::key key; > init_key(key, Service::id); > return do_has_service(key); >} > > >template <typename Service> >void service_registry::init_key(boost::asio::io_service::service::key& key, > const boost::asio::detail::service_id<Service>& ) >{ > key.type_info_ = &typeid(typeid_wrapper<Service>); > key.id_ = 0; >} > > >template <typename Service> >boost::asio::io_service::service* service_registry::create( > boost::asio::io_service& owner) >{ > return new Service(owner); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 89 "/usr/include/boost/asio/detail/impl/service_registry.hpp" 2 3 4 ># 154 "/usr/include/boost/asio/detail/service_registry.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/impl/service_registry.ipp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/impl/service_registry.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/service_registry.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/impl/service_registry.ipp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/impl/service_registry.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >service_registry::~service_registry() >{ > > > > boost::asio::io_service::service* service = first_service_; > while (service) > { > service->shutdown_service(); > service = service->next_; > } > > > while (first_service_) > { > boost::asio::io_service::service* next_service = first_service_->next_; > destroy(first_service_); > first_service_ = next_service; > } >} > >void service_registry::notify_fork(boost::asio::io_service::fork_event fork_ev) >{ > > > > std::vector<boost::asio::io_service::service*> services; > { > boost::asio::detail::mutex::scoped_lock lock(mutex_); > boost::asio::io_service::service* service = first_service_; > while (service) > { > services.push_back(service); > service = service->next_; > } > } > > > > > > std::size_t num_services = services.size(); > if (fork_ev == boost::asio::io_service::fork_prepare) > for (std::size_t i = 0; i < num_services; ++i) > services[i]->fork_service(fork_ev); > else > for (std::size_t i = num_services; i > 0; --i) > services[i - 1]->fork_service(fork_ev); >} > >void service_registry::init_key(boost::asio::io_service::service::key& key, > const boost::asio::io_service::id& id) >{ > key.type_info_ = 0; > key.id_ = &id; >} > >bool service_registry::keys_match( > const boost::asio::io_service::service::key& key1, > const boost::asio::io_service::service::key& key2) >{ > if (key1.id_ && key2.id_) > if (key1.id_ == key2.id_) > return true; > if (key1.type_info_ && key2.type_info_) > if (*key1.type_info_ == *key2.type_info_) > return true; > return false; >} > >void service_registry::destroy(boost::asio::io_service::service* service) >{ > delete service; >} > >boost::asio::io_service::service* service_registry::do_use_service( > const boost::asio::io_service::service::key& key, > factory_type factory) >{ > boost::asio::detail::mutex::scoped_lock lock(mutex_); > > > boost::asio::io_service::service* service = first_service_; > while (service) > { > if (keys_match(service->key_, key)) > return service; > service = service->next_; > } > > > > > lock.unlock(); > auto_service_ptr new_service = { factory(owner_) }; > new_service.ptr_->key_ = key; > lock.lock(); > > > > service = first_service_; > while (service) > { > if (keys_match(service->key_, key)) > return service; > service = service->next_; > } > > > new_service.ptr_->next_ = first_service_; > first_service_ = new_service.ptr_; > new_service.ptr_ = 0; > return first_service_; >} > >void service_registry::do_add_service( > const boost::asio::io_service::service::key& key, > boost::asio::io_service::service* new_service) >{ > if (&owner_ != &new_service->get_io_service()) > boost::asio::detail::throw_exception(invalid_service_owner()); > > boost::asio::detail::mutex::scoped_lock lock(mutex_); > > > boost::asio::io_service::service* service = first_service_; > while (service) > { > if (keys_match(service->key_, key)) > boost::asio::detail::throw_exception(service_already_exists()); > service = service->next_; > } > > > new_service->key_ = key; > new_service->next_ = first_service_; > first_service_ = new_service; >} > >bool service_registry::do_has_service( > const boost::asio::io_service::service::key& key) const >{ > boost::asio::detail::mutex::scoped_lock lock(mutex_); > > boost::asio::io_service::service* service = first_service_; > while (service) > { > if (keys_match(service->key_, key)) > return true; > service = service->next_; > } > > return false; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 189 "/usr/include/boost/asio/detail/impl/service_registry.ipp" 2 3 4 ># 156 "/usr/include/boost/asio/detail/service_registry.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/impl/io_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/impl/io_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > >template <typename Service> >inline Service& use_service(io_service& ios) >{ > > (void)static_cast<io_service::service*>(static_cast<Service*>(0)); > (void)static_cast<const io_service::id*>(&Service::id); > > return ios.service_registry_->template use_service<Service>(); >} > >template <> >inline detail::io_service_impl& use_service<detail::io_service_impl>( > io_service& ios) >{ > return ios.impl_; >} > >template <typename Service> >inline void add_service(io_service& ios, Service* svc) >{ > > (void)static_cast<io_service::service*>(static_cast<Service*>(0)); > (void)static_cast<const io_service::id*>(&Service::id); > > ios.service_registry_->template add_service<Service>(svc); >} > >template <typename Service> >inline bool has_service(io_service& ios) >{ > > (void)static_cast<io_service::service*>(static_cast<Service*>(0)); > (void)static_cast<const io_service::id*>(&Service::id); > > return ios.service_registry_->template has_service<Service>(); >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 67 "/usr/include/boost/asio/impl/io_service.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/asio/detail/task_io_service.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/task_io_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/atomic_count.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/atomic_count.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > > > > >typedef std::atomic<long> atomic_count; >inline void increment(atomic_count& a, long b) { a += b; } > > > > > >} >} >} ># 25 "/usr/include/boost/asio/detail/task_io_service.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/detail/reactor_fwd.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/reactor_fwd.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > > > > > >typedef class epoll_reactor reactor; ># 38 "/usr/include/boost/asio/detail/reactor_fwd.hpp" 3 4 >} >} >} ># 29 "/usr/include/boost/asio/detail/task_io_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/task_io_service_operation.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/task_io_service_operation.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/handler_tracking.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/handler_tracking.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/handler_tracking.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { ># 151 "/usr/include/boost/asio/detail/handler_tracking.hpp" 3 4 >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 156 "/usr/include/boost/asio/detail/handler_tracking.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/handler_tracking.ipp" 1 3 4 ># 159 "/usr/include/boost/asio/detail/handler_tracking.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/detail/task_io_service_operation.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/task_io_service_operation.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class task_io_service; > > > >class task_io_service_operation >{ >public: > void complete(task_io_service& owner, > const boost::system::error_code& ec, std::size_t bytes_transferred) > { > func_(&owner, this, ec, bytes_transferred); > } > > void destroy() > { > func_(0, this, boost::system::error_code(), 0); > } > >protected: > typedef void (*func_type)(task_io_service*, > task_io_service_operation*, > const boost::system::error_code&, std::size_t); > > task_io_service_operation(func_type func) > : next_(0), > func_(func), > task_result_(0) > { > } > > > ~task_io_service_operation() > { > } > >private: > friend class op_queue_access; > task_io_service_operation* next_; > func_type func_; >protected: > friend class task_io_service; > unsigned int task_result_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 77 "/usr/include/boost/asio/detail/task_io_service_operation.hpp" 2 3 4 ># 30 "/usr/include/boost/asio/detail/task_io_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/detail/task_io_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >struct task_io_service_thread_info; > >class task_io_service > : public boost::asio::detail::service_base<task_io_service> >{ >public: > typedef task_io_service_operation operation; > > > > inline task_io_service(boost::asio::io_service& io_service, > std::size_t concurrency_hint = 0); > > > inline void shutdown_service(); > > > inline void init_task(); > > > inline std::size_t run(boost::system::error_code& ec); > > > inline std::size_t run_one(boost::system::error_code& ec); > > > inline std::size_t poll(boost::system::error_code& ec); > > > inline std::size_t poll_one(boost::system::error_code& ec); > > > inline void stop(); > > > inline bool stopped() const; > > > inline void reset(); > > > void work_started() > { > ++outstanding_work_; > } > > > void work_finished() > { > if (--outstanding_work_ == 0) > stop(); > } > > > bool can_dispatch() > { > return thread_call_stack::contains(this) != 0; > } > > > template <typename Handler> > void dispatch(Handler& handler); > > > template <typename Handler> > void post(Handler& handler); > > > > inline void post_immediate_completion( > operation* op, bool is_continuation); > > > > inline void post_deferred_completion(operation* op); > > > > inline void post_deferred_completions(op_queue<operation>& ops); > > > > inline void abandon_operations(op_queue<operation>& ops); > >private: > > typedef task_io_service_thread_info thread_info; > > > > inline void do_dispatch(operation* op); > > > inline std::size_t do_run_one(mutex::scoped_lock& lock, > thread_info& this_thread, const boost::system::error_code& ec); > > > inline std::size_t do_poll_one(mutex::scoped_lock& lock, > thread_info& this_thread, const boost::system::error_code& ec); > > > inline void stop_all_threads(mutex::scoped_lock& lock); > > > > > inline bool wake_one_idle_thread_and_unlock( > mutex::scoped_lock& lock); > > > inline void wake_one_thread_and_unlock( > mutex::scoped_lock& lock); > > > struct task_cleanup; > friend struct task_cleanup; > > > struct work_cleanup; > friend struct work_cleanup; > > > const bool one_thread_; > > > mutable mutex mutex_; > > > reactor* task_; > > > struct task_operation : operation > { > task_operation() : operation(0) {} > } task_operation_; > > > bool task_interrupted_; > > > atomic_count outstanding_work_; > > > op_queue<operation> op_queue_; > > > bool stopped_; > > > bool shutdown_; > > > typedef call_stack<task_io_service, thread_info> thread_call_stack; > > > thread_info* first_idle_thread_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 200 "/usr/include/boost/asio/detail/task_io_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/impl/task_io_service.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/impl/task_io_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/completion_handler.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/completion_handler.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/fenced_block.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/detail/fenced_block.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/gcc_x86_fenced_block.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/gcc_x86_fenced_block.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/gcc_x86_fenced_block.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class gcc_x86_fenced_block > : private noncopyable >{ >public: > enum half_t { half }; > enum full_t { full }; > > > explicit gcc_x86_fenced_block(half_t) > { > } > > > explicit gcc_x86_fenced_block(full_t) > { > lbarrier(); > } > > > ~gcc_x86_fenced_block() > { > sbarrier(); > } > >private: > static int barrier() > { > int r = 0, m = 1; > __asm__ __volatile__ ( > "xchgl %0, %1" : > "=r"(r), "=m"(m) : > "0"(1), "m"(m) : > "memory", "cc"); > return r; > } > > static void lbarrier() > { > > __asm__ __volatile__ ("lfence" ::: "memory"); > > > > } > > static void sbarrier() > { > > __asm__ __volatile__ ("sfence" ::: "memory"); > > > > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 88 "/usr/include/boost/asio/detail/gcc_x86_fenced_block.hpp" 2 3 4 ># 34 "/usr/include/boost/asio/detail/fenced_block.hpp" 2 3 4 ># 45 "/usr/include/boost/asio/detail/fenced_block.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { ># 62 "/usr/include/boost/asio/detail/fenced_block.hpp" 3 4 >typedef gcc_x86_fenced_block fenced_block; ># 74 "/usr/include/boost/asio/detail/fenced_block.hpp" 3 4 >} >} >} ># 21 "/usr/include/boost/asio/detail/completion_handler.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/operation.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/operation.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > > > >typedef task_io_service_operation operation; > > >} >} >} ># 24 "/usr/include/boost/asio/detail/completion_handler.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/completion_handler.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Handler> >class completion_handler : public operation >{ >public: > struct ptr { Handler* h; void* v; completion_handler* p; ~ptr() { reset(); } void reset() { if (p) { p->~completion_handler(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(completion_handler), *h); v = 0; } } }; > > completion_handler(Handler& h) > : operation(&completion_handler::do_complete), > handler_(static_cast<Handler&&>(h)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > completion_handler* h(static_cast<completion_handler*>(base)); > ptr p = { boost::asio::detail::addressof(h->handler_), h, h }; > > (void)0; > > > > > > > > Handler handler(static_cast<Handler&&>(h->handler_)); > p.h = boost::asio::detail::addressof(handler); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 82 "/usr/include/boost/asio/detail/completion_handler.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/detail/impl/task_io_service.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/impl/task_io_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Handler> >void task_io_service::dispatch(Handler& handler) >{ > if (thread_call_stack::contains(this)) > { > fenced_block b(fenced_block::full); > boost_asio_handler_invoke_helpers::invoke(handler, handler); > } > else > { > > typedef completion_handler<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0; > > do_dispatch(p.p); > p.v = p.p = 0; > } >} > >template <typename Handler> >void task_io_service::post(Handler& handler) >{ > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef completion_handler<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0; > > post_immediate_completion(p.p, is_continuation); > p.v = p.p = 0; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 79 "/usr/include/boost/asio/detail/impl/task_io_service.hpp" 2 3 4 ># 202 "/usr/include/boost/asio/detail/task_io_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/impl/task_io_service.ipp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/impl/task_io_service.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/limits.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/impl/task_io_service.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactor.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/reactor.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/object_pool.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/object_pool.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/object_pool.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Object> >class object_pool; > >class object_pool_access >{ >public: > template <typename Object> > static Object* create() > { > return new Object; > } > > template <typename Object> > static void destroy(Object* o) > { > delete o; > } > > template <typename Object> > static Object*& next(Object* o) > { > return o->next_; > } > > template <typename Object> > static Object*& prev(Object* o) > { > return o->prev_; > } >}; > >template <typename Object> >class object_pool > : private noncopyable >{ >public: > > object_pool() > : live_list_(0), > free_list_(0) > { > } > > > ~object_pool() > { > destroy_list(live_list_); > destroy_list(free_list_); > } > > > Object* first() > { > return live_list_; > } > > > Object* alloc() > { > Object* o = free_list_; > if (o) > free_list_ = object_pool_access::next(free_list_); > else > o = object_pool_access::create<Object>(); > > object_pool_access::next(o) = live_list_; > object_pool_access::prev(o) = 0; > if (live_list_) > object_pool_access::prev(live_list_) = o; > live_list_ = o; > > return o; > } > > > void free(Object* o) > { > if (live_list_ == o) > live_list_ = object_pool_access::next(o); > > if (object_pool_access::prev(o)) > { > object_pool_access::next(object_pool_access::prev(o)) > = object_pool_access::next(o); > } > > if (object_pool_access::next(o)) > { > object_pool_access::prev(object_pool_access::next(o)) > = object_pool_access::prev(o); > } > > object_pool_access::next(o) = free_list_; > object_pool_access::prev(o) = 0; > free_list_ = o; > } > >private: > > void destroy_list(Object* list) > { > while (list) > { > Object* o = list; > list = object_pool_access::next(o); > object_pool_access::destroy(o); > } > } > > > Object* live_list_; > > > Object* free_list_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 147 "/usr/include/boost/asio/detail/object_pool.hpp" 2 3 4 ># 27 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/reactor_op.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/reactor_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/reactor_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class reactor_op > : public operation >{ >public: > > boost::system::error_code ec_; > > > std::size_t bytes_transferred_; > > > bool perform() > { > return perform_func_(this); > } > >protected: > typedef bool (*perform_func_type)(reactor_op*); > > reactor_op(perform_func_type perform_func, func_type complete_func) > : operation(complete_func), > bytes_transferred_(0), > perform_func_(perform_func) > { > } > >private: > perform_func_type perform_func_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 62 "/usr/include/boost/asio/detail/reactor_op.hpp" 2 3 4 ># 29 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/select_interrupter.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/select_interrupter.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/eventfd_select_interrupter.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/eventfd_select_interrupter.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/eventfd_select_interrupter.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class eventfd_select_interrupter >{ >public: > > inline eventfd_select_interrupter(); > > > inline ~eventfd_select_interrupter(); > > > inline void recreate(); > > > inline void interrupt(); > > > inline bool reset(); > > > int read_descriptor() const > { > return read_descriptor_; > } > >private: > > inline void open_descriptors(); > > > inline void close_descriptors(); > > > > > > int read_descriptor_; > > > > > > int write_descriptor_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 78 "/usr/include/boost/asio/detail/eventfd_select_interrupter.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 3 4 ># 1 "/usr/include/sys/stat.h" 1 3 4 ># 103 "/usr/include/sys/stat.h" 3 4 >extern "C" { > ># 1 "/usr/include/bits/stat.h" 1 3 4 ># 46 "/usr/include/bits/stat.h" 3 4 >struct stat > { > __dev_t st_dev; > > > > > __ino_t st_ino; > > > > > > > > __nlink_t st_nlink; > __mode_t st_mode; > > __uid_t st_uid; > __gid_t st_gid; > > int __pad0; > > __dev_t st_rdev; > > > > > __off_t st_size; > > > > __blksize_t st_blksize; > > __blkcnt_t st_blocks; ># 91 "/usr/include/bits/stat.h" 3 4 > struct timespec st_atim; > struct timespec st_mtim; > struct timespec st_ctim; ># 106 "/usr/include/bits/stat.h" 3 4 > __syscall_slong_t __unused[3]; ># 115 "/usr/include/bits/stat.h" 3 4 > }; > > > >struct stat64 > { > __dev_t st_dev; > > __ino64_t st_ino; > __nlink_t st_nlink; > __mode_t st_mode; > > > > > > > __uid_t st_uid; > __gid_t st_gid; > > int __pad0; > __dev_t st_rdev; > __off_t st_size; > > > > > > __blksize_t st_blksize; > __blkcnt64_t st_blocks; > > > > > > > > struct timespec st_atim; > struct timespec st_mtim; > struct timespec st_ctim; ># 164 "/usr/include/bits/stat.h" 3 4 > __syscall_slong_t __unused[3]; > > > > }; ># 106 "/usr/include/sys/stat.h" 2 3 4 ># 209 "/usr/include/sys/stat.h" 3 4 >extern int stat (const char *__restrict __file, > struct stat *__restrict __buf) throw () __attribute__ ((__nonnull__ (1, 2))); > > > >extern int fstat (int __fd, struct stat *__buf) throw () __attribute__ ((__nonnull__ (2))); ># 228 "/usr/include/sys/stat.h" 3 4 >extern int stat64 (const char *__restrict __file, > struct stat64 *__restrict __buf) throw () __attribute__ ((__nonnull__ (1, 2))); >extern int fstat64 (int __fd, struct stat64 *__buf) throw () __attribute__ ((__nonnull__ (2))); > > > > > > > >extern int fstatat (int __fd, const char *__restrict __file, > struct stat *__restrict __buf, int __flag) > throw () __attribute__ ((__nonnull__ (2, 3))); ># 253 "/usr/include/sys/stat.h" 3 4 >extern int fstatat64 (int __fd, const char *__restrict __file, > struct stat64 *__restrict __buf, int __flag) > throw () __attribute__ ((__nonnull__ (2, 3))); > > > > > > > >extern int lstat (const char *__restrict __file, > struct stat *__restrict __buf) throw () __attribute__ ((__nonnull__ (1, 2))); ># 276 "/usr/include/sys/stat.h" 3 4 >extern int lstat64 (const char *__restrict __file, > struct stat64 *__restrict __buf) > throw () __attribute__ ((__nonnull__ (1, 2))); > > > > > >extern int chmod (const char *__file, __mode_t __mode) > throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern int lchmod (const char *__file, __mode_t __mode) > throw () __attribute__ ((__nonnull__ (1))); > > > > >extern int fchmod (int __fd, __mode_t __mode) throw (); > > > > > >extern int fchmodat (int __fd, const char *__file, __mode_t __mode, > int __flag) > throw () __attribute__ ((__nonnull__ (2))) ; > > > > > > >extern __mode_t umask (__mode_t __mask) throw (); > > > > >extern __mode_t getumask (void) throw (); > > > >extern int mkdir (const char *__path, __mode_t __mode) > throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern int mkdirat (int __fd, const char *__path, __mode_t __mode) > throw () __attribute__ ((__nonnull__ (2))); > > > > > > >extern int mknod (const char *__path, __mode_t __mode, __dev_t __dev) > throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern int mknodat (int __fd, const char *__path, __mode_t __mode, > __dev_t __dev) throw () __attribute__ ((__nonnull__ (2))); > > > > > >extern int mkfifo (const char *__path, __mode_t __mode) > throw () __attribute__ ((__nonnull__ (1))); > > > > > >extern int mkfifoat (int __fd, const char *__path, __mode_t __mode) > throw () __attribute__ ((__nonnull__ (2))); > > > > > >extern int utimensat (int __fd, const char *__path, > const struct timespec __times[2], > int __flags) > throw () __attribute__ ((__nonnull__ (2))); > > > > >extern int futimens (int __fd, const struct timespec __times[2]) throw (); ># 399 "/usr/include/sys/stat.h" 3 4 >extern int __fxstat (int __ver, int __fildes, struct stat *__stat_buf) > throw () __attribute__ ((__nonnull__ (3))); >extern int __xstat (int __ver, const char *__filename, > struct stat *__stat_buf) throw () __attribute__ ((__nonnull__ (2, 3))); >extern int __lxstat (int __ver, const char *__filename, > struct stat *__stat_buf) throw () __attribute__ ((__nonnull__ (2, 3))); >extern int __fxstatat (int __ver, int __fildes, const char *__filename, > struct stat *__stat_buf, int __flag) > throw () __attribute__ ((__nonnull__ (3, 4))); ># 432 "/usr/include/sys/stat.h" 3 4 >extern int __fxstat64 (int __ver, int __fildes, struct stat64 *__stat_buf) > throw () __attribute__ ((__nonnull__ (3))); >extern int __xstat64 (int __ver, const char *__filename, > struct stat64 *__stat_buf) throw () __attribute__ ((__nonnull__ (2, 3))); >extern int __lxstat64 (int __ver, const char *__filename, > struct stat64 *__stat_buf) throw () __attribute__ ((__nonnull__ (2, 3))); >extern int __fxstatat64 (int __ver, int __fildes, const char *__filename, > struct stat64 *__stat_buf, int __flag) > throw () __attribute__ ((__nonnull__ (3, 4))); > >extern int __xmknod (int __ver, const char *__path, __mode_t __mode, > __dev_t *__dev) throw () __attribute__ ((__nonnull__ (2, 4))); > >extern int __xmknodat (int __ver, int __fd, const char *__path, > __mode_t __mode, __dev_t *__dev) > throw () __attribute__ ((__nonnull__ (3, 5))); > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) stat (const char *__path, struct stat *__statbuf) throw () >{ > return __xstat (1, __path, __statbuf); >} > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) lstat (const char *__path, struct stat *__statbuf) throw () >{ > return __lxstat (1, __path, __statbuf); >} > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) fstat (int __fd, struct stat *__statbuf) throw () >{ > return __fxstat (1, __fd, __statbuf); >} > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) fstatat (int __fd, const char *__filename, struct stat *__statbuf, int __flag) throw () > >{ > return __fxstatat (1, __fd, __filename, __statbuf, __flag); >} > > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) mknod (const char *__path, __mode_t __mode, __dev_t __dev) throw () >{ > return __xmknod (0, __path, __mode, &__dev); >} > > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) mknodat (int __fd, const char *__path, __mode_t __mode, __dev_t __dev) throw () > >{ > return __xmknodat (0, __fd, __path, __mode, &__dev); >} > > > > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) stat64 (const char *__path, struct stat64 *__statbuf) throw () >{ > return __xstat64 (1, __path, __statbuf); >} > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) lstat64 (const char *__path, struct stat64 *__statbuf) throw () >{ > return __lxstat64 (1, __path, __statbuf); >} > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) fstat64 (int __fd, struct stat64 *__statbuf) throw () >{ > return __fxstat64 (1, __fd, __statbuf); >} > > >extern __inline __attribute__ ((__gnu_inline__)) int >__attribute__ ((__leaf__)) fstatat64 (int __fd, const char *__filename, struct stat64 *__statbuf, int __flag) throw () > >{ > return __fxstatat64 (1, __fd, __filename, __statbuf, __flag); >} > > > > > > >} ># 24 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 2 3 4 > ># 1 "/usr/include/fcntl.h" 1 3 4 ># 28 "/usr/include/fcntl.h" 3 4 >extern "C" { > > > > > > ># 1 "/usr/include/bits/fcntl.h" 1 3 4 ># 35 "/usr/include/bits/fcntl.h" 3 4 >struct flock > { > short int l_type; > short int l_whence; > > __off_t l_start; > __off_t l_len; > > > > > __pid_t l_pid; > }; > > >struct flock64 > { > short int l_type; > short int l_whence; > __off64_t l_start; > __off64_t l_len; > __pid_t l_pid; > }; > > > ># 1 "/usr/include/bits/fcntl-linux.h" 1 3 4 ># 38 "/usr/include/bits/fcntl-linux.h" 3 4 ># 1 "/usr/include/bits/uio.h" 1 3 4 ># 39 "/usr/include/bits/fcntl-linux.h" 2 3 4 ># 237 "/usr/include/bits/fcntl-linux.h" 3 4 >enum __pid_type > { > F_OWNER_TID = 0, > F_OWNER_PID, > F_OWNER_PGRP, > F_OWNER_GID = F_OWNER_PGRP > }; > > >struct f_owner_ex > { > enum __pid_type type; > __pid_t pid; > }; ># 307 "/usr/include/bits/fcntl-linux.h" 3 4 >struct file_handle >{ > unsigned int handle_bytes; > int handle_type; > > unsigned char f_handle[0]; >}; > > > > > >extern "C" { > > > > >extern ssize_t readahead (int __fd, __off64_t __offset, size_t __count) > throw (); > > > > > > >extern int sync_file_range (int __fd, __off64_t __offset, __off64_t __count, > unsigned int __flags); > > > > > > >extern ssize_t vmsplice (int __fdout, const struct iovec *__iov, > size_t __count, unsigned int __flags); > > > > > >extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout, > __off64_t *__offout, size_t __len, > unsigned int __flags); > > > > > >extern ssize_t tee (int __fdin, int __fdout, size_t __len, > unsigned int __flags); > > > > > > >extern int fallocate (int __fd, int __mode, __off_t __offset, __off_t __len); ># 374 "/usr/include/bits/fcntl-linux.h" 3 4 >extern int fallocate64 (int __fd, int __mode, __off64_t __offset, > __off64_t __len); > > > > >extern int name_to_handle_at (int __dfd, const char *__name, > struct file_handle *__handle, int *__mnt_id, > int __flags) throw (); > > > > > >extern int open_by_handle_at (int __mountdirfd, struct file_handle *__handle, > int __flags); > > > >} ># 61 "/usr/include/bits/fcntl.h" 2 3 4 ># 36 "/usr/include/fcntl.h" 2 3 4 ># 68 "/usr/include/fcntl.h" 3 4 ># 1 "/usr/include/bits/stat.h" 1 3 4 ># 69 "/usr/include/fcntl.h" 2 3 4 ># 160 "/usr/include/fcntl.h" 3 4 >extern int fcntl (int __fd, int __cmd, ...); ># 169 "/usr/include/fcntl.h" 3 4 >extern int open (const char *__file, int __oflag, ...) __attribute__ ((__nonnull__ (1))); ># 179 "/usr/include/fcntl.h" 3 4 >extern int open64 (const char *__file, int __oflag, ...) __attribute__ ((__nonnull__ (1))); ># 193 "/usr/include/fcntl.h" 3 4 >extern int openat (int __fd, const char *__file, int __oflag, ...) > __attribute__ ((__nonnull__ (2))); ># 204 "/usr/include/fcntl.h" 3 4 >extern int openat64 (int __fd, const char *__file, int __oflag, ...) > __attribute__ ((__nonnull__ (2))); ># 215 "/usr/include/fcntl.h" 3 4 >extern int creat (const char *__file, mode_t __mode) __attribute__ ((__nonnull__ (1))); ># 225 "/usr/include/fcntl.h" 3 4 >extern int creat64 (const char *__file, mode_t __mode) __attribute__ ((__nonnull__ (1))); ># 261 "/usr/include/fcntl.h" 3 4 >extern int posix_fadvise (int __fd, off_t __offset, off_t __len, > int __advise) throw (); ># 273 "/usr/include/fcntl.h" 3 4 >extern int posix_fadvise64 (int __fd, off64_t __offset, off64_t __len, > int __advise) throw (); ># 283 "/usr/include/fcntl.h" 3 4 >extern int posix_fallocate (int __fd, off_t __offset, off_t __len); ># 294 "/usr/include/fcntl.h" 3 4 >extern int posix_fallocate64 (int __fd, off64_t __offset, off64_t __len); ># 305 "/usr/include/fcntl.h" 3 4 >} ># 26 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 2 3 4 > > > ># 1 "/usr/include/sys/eventfd.h" 1 3 4 ># 24 "/usr/include/sys/eventfd.h" 3 4 ># 1 "/usr/include/bits/eventfd.h" 1 3 4 ># 23 "/usr/include/bits/eventfd.h" 3 4 >enum > { > EFD_SEMAPHORE = 00000001, > > EFD_CLOEXEC = 02000000, > > EFD_NONBLOCK = 00004000 > > }; ># 25 "/usr/include/sys/eventfd.h" 2 3 4 > > >typedef uint64_t eventfd_t; > > >extern "C" { > > > >extern int eventfd (int __count, int __flags) throw (); > > >extern int eventfd_read (int __fd, eventfd_t *__value); > > >extern int eventfd_write (int __fd, eventfd_t __value); > >} ># 30 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/cstdint.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/cstdint.hpp" 3 4 >namespace boost { >namespace asio { > > >using std::int16_t; >using std::uint16_t; >using std::int32_t; >using std::uint32_t; >using std::int64_t; >using std::uint64_t; ># 45 "/usr/include/boost/asio/detail/cstdint.hpp" 3 4 >} >} ># 32 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/eventfd_select_interrupter.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 37 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >eventfd_select_interrupter::eventfd_select_interrupter() >{ > open_descriptors(); >} > >void eventfd_select_interrupter::open_descriptors() >{ ># 58 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 3 4 > write_descriptor_ = read_descriptor_ = > ::eventfd(0, EFD_CLOEXEC | EFD_NONBLOCK); > > > > > if (read_descriptor_ == -1 && (*__errno_location ()) == 22) > { > write_descriptor_ = read_descriptor_ = ::eventfd(0, 0); > if (read_descriptor_ != -1) > { > ::fcntl(read_descriptor_, 4, 04000); > ::fcntl(read_descriptor_, 2, 1); > } > } > > > if (read_descriptor_ == -1) > { > int pipe_fds[2]; > if (pipe(pipe_fds) == 0) > { > read_descriptor_ = pipe_fds[0]; > ::fcntl(read_descriptor_, 4, 04000); > ::fcntl(read_descriptor_, 2, 1); > write_descriptor_ = pipe_fds[1]; > ::fcntl(write_descriptor_, 4, 04000); > ::fcntl(write_descriptor_, 2, 1); > } > else > { > boost::system::error_code ec((*__errno_location ()), > boost::asio::error::get_system_category()); > boost::asio::detail::throw_error(ec, "eventfd_select_interrupter"); > } > } >} > >eventfd_select_interrupter::~eventfd_select_interrupter() >{ > close_descriptors(); >} > >void eventfd_select_interrupter::close_descriptors() >{ > if (write_descriptor_ != -1 && write_descriptor_ != read_descriptor_) > ::close(write_descriptor_); > if (read_descriptor_ != -1) > ::close(read_descriptor_); >} > >void eventfd_select_interrupter::recreate() >{ > close_descriptors(); > > write_descriptor_ = -1; > read_descriptor_ = -1; > > open_descriptors(); >} > >void eventfd_select_interrupter::interrupt() >{ > uint64_t counter(1UL); > int result = ::write(write_descriptor_, &counter, sizeof(uint64_t)); > (void)result; >} > >bool eventfd_select_interrupter::reset() >{ > if (write_descriptor_ == read_descriptor_) > { > for (;;) > { > > uint64_t counter(0); > (*__errno_location ()) = 0; > int bytes_read = ::read(read_descriptor_, &counter, sizeof(uint64_t)); > if (bytes_read < 0 && (*__errno_location ()) == 4) > continue; > bool was_interrupted = (bytes_read > 0); > return was_interrupted; > } > } > else > { > for (;;) > { > > char data[1024]; > int bytes_read = ::read(read_descriptor_, data, sizeof(data)); > if (bytes_read < 0 && (*__errno_location ()) == 4) > continue; > bool was_interrupted = (bytes_read > 0); > while (bytes_read == sizeof(data)) > bytes_read = ::read(read_descriptor_, data, sizeof(data)); > return was_interrupted; > } > } >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 164 "/usr/include/boost/asio/detail/impl/eventfd_select_interrupter.ipp" 2 3 4 ># 81 "/usr/include/boost/asio/detail/eventfd_select_interrupter.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/detail/select_interrupter.hpp" 2 3 4 > > > > >namespace boost { >namespace asio { >namespace detail { > > > > >typedef eventfd_select_interrupter select_interrupter; > > > > >} >} >} ># 30 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/socket_types.hpp" 1 3 4 ># 55 "/usr/include/boost/asio/detail/socket_types.hpp" 3 4 ># 1 "/usr/include/sys/ioctl.h" 1 3 4 ># 23 "/usr/include/sys/ioctl.h" 3 4 >extern "C" { > > ># 1 "/usr/include/bits/ioctls.h" 1 3 4 ># 23 "/usr/include/bits/ioctls.h" 3 4 ># 1 "/usr/include/asm/ioctls.h" 1 3 4 ># 1 "/usr/include/asm-generic/ioctls.h" 1 3 4 > > > ># 1 "/usr/include/linux/ioctl.h" 1 3 4 > > > ># 1 "/usr/include/asm/ioctl.h" 1 3 4 ># 1 "/usr/include/asm-generic/ioctl.h" 1 3 4 ># 1 "/usr/include/asm/ioctl.h" 2 3 4 ># 5 "/usr/include/linux/ioctl.h" 2 3 4 ># 5 "/usr/include/asm-generic/ioctls.h" 2 3 4 ># 1 "/usr/include/asm/ioctls.h" 2 3 4 ># 24 "/usr/include/bits/ioctls.h" 2 3 4 ># 27 "/usr/include/sys/ioctl.h" 2 3 4 > > ># 1 "/usr/include/bits/ioctl-types.h" 1 3 4 ># 24 "/usr/include/bits/ioctl-types.h" 3 4 ># 1 "/usr/include/asm/ioctls.h" 1 3 4 ># 25 "/usr/include/bits/ioctl-types.h" 2 3 4 > > >struct winsize > { > unsigned short int ws_row; > unsigned short int ws_col; > unsigned short int ws_xpixel; > unsigned short int ws_ypixel; > }; > > >struct termio > { > unsigned short int c_iflag; > unsigned short int c_oflag; > unsigned short int c_cflag; > unsigned short int c_lflag; > unsigned char c_line; > unsigned char c_cc[8]; >}; ># 30 "/usr/include/sys/ioctl.h" 2 3 4 > > > > > > ># 1 "/usr/include/sys/ttydefaults.h" 1 3 4 ># 37 "/usr/include/sys/ioctl.h" 2 3 4 > > > > >extern int ioctl (int __fd, unsigned long int __request, ...) throw (); > >} ># 56 "/usr/include/boost/asio/detail/socket_types.hpp" 2 3 4 > ># 1 "/usr/include/sys/poll.h" 1 3 4 ># 25 "/usr/include/sys/poll.h" 3 4 ># 1 "/usr/include/bits/poll.h" 1 3 4 ># 26 "/usr/include/sys/poll.h" 2 3 4 > > ># 1 "/usr/include/bits/sigset.h" 1 3 4 ># 29 "/usr/include/sys/poll.h" 2 3 4 > > > > > > > >typedef unsigned long int nfds_t; > > >struct pollfd > { > int fd; > short int events; > short int revents; > }; > > >extern "C" { ># 57 "/usr/include/sys/poll.h" 3 4 >extern int poll (struct pollfd *__fds, nfds_t __nfds, int __timeout); ># 66 "/usr/include/sys/poll.h" 3 4 >extern int ppoll (struct pollfd *__fds, nfds_t __nfds, > const struct timespec *__timeout, > const __sigset_t *__ss); > > >} ># 58 "/usr/include/boost/asio/detail/socket_types.hpp" 2 3 4 ># 70 "/usr/include/boost/asio/detail/socket_types.hpp" 3 4 ># 1 "/usr/include/sys/un.h" 1 3 4 ># 26 "/usr/include/sys/un.h" 3 4 >extern "C" { > > >struct sockaddr_un > { > sa_family_t sun_family; > char sun_path[108]; > }; ># 44 "/usr/include/sys/un.h" 3 4 >} ># 71 "/usr/include/boost/asio/detail/socket_types.hpp" 2 3 4 > > ># 1 "/usr/include/netinet/tcp.h" 1 3 4 ># 102 "/usr/include/netinet/tcp.h" 3 4 >struct tcphdr > { > u_int16_t source; > u_int16_t dest; > u_int32_t seq; > u_int32_t ack_seq; > > u_int16_t res1:4; > u_int16_t doff:4; > u_int16_t fin:1; > u_int16_t syn:1; > u_int16_t rst:1; > u_int16_t psh:1; > u_int16_t ack:1; > u_int16_t urg:1; > u_int16_t res2:2; ># 131 "/usr/include/netinet/tcp.h" 3 4 > u_int16_t window; > u_int16_t check; > u_int16_t urg_ptr; >}; > > >enum >{ > TCP_ESTABLISHED = 1, > TCP_SYN_SENT, > TCP_SYN_RECV, > TCP_FIN_WAIT1, > TCP_FIN_WAIT2, > TCP_TIME_WAIT, > TCP_CLOSE, > TCP_CLOSE_WAIT, > TCP_LAST_ACK, > TCP_LISTEN, > TCP_CLOSING >}; ># 191 "/usr/include/netinet/tcp.h" 3 4 >enum tcp_ca_state >{ > TCP_CA_Open = 0, > TCP_CA_Disorder = 1, > TCP_CA_CWR = 2, > TCP_CA_Recovery = 3, > TCP_CA_Loss = 4 >}; > >struct tcp_info >{ > u_int8_t tcpi_state; > u_int8_t tcpi_ca_state; > u_int8_t tcpi_retransmits; > u_int8_t tcpi_probes; > u_int8_t tcpi_backoff; > u_int8_t tcpi_options; > u_int8_t tcpi_snd_wscale : 4, tcpi_rcv_wscale : 4; > > u_int32_t tcpi_rto; > u_int32_t tcpi_ato; > u_int32_t tcpi_snd_mss; > u_int32_t tcpi_rcv_mss; > > u_int32_t tcpi_unacked; > u_int32_t tcpi_sacked; > u_int32_t tcpi_lost; > u_int32_t tcpi_retrans; > u_int32_t tcpi_fackets; > > > u_int32_t tcpi_last_data_sent; > u_int32_t tcpi_last_ack_sent; > u_int32_t tcpi_last_data_recv; > u_int32_t tcpi_last_ack_recv; > > > u_int32_t tcpi_pmtu; > u_int32_t tcpi_rcv_ssthresh; > u_int32_t tcpi_rtt; > u_int32_t tcpi_rttvar; > u_int32_t tcpi_snd_ssthresh; > u_int32_t tcpi_snd_cwnd; > u_int32_t tcpi_advmss; > u_int32_t tcpi_reordering; > > u_int32_t tcpi_rcv_rtt; > u_int32_t tcpi_rcv_space; > > u_int32_t tcpi_total_retrans; >}; > > > > > >struct tcp_md5sig >{ > struct sockaddr_storage tcpm_addr; > u_int16_t __tcpm_pad1; > u_int16_t tcpm_keylen; > u_int32_t __tcpm_pad2; > u_int8_t tcpm_key[80]; >}; > > >struct tcp_repair_opt >{ > u_int32_t opt_code; > u_int32_t opt_val; >}; > > >enum >{ > TCP_NO_QUEUE, > TCP_RECV_QUEUE, > TCP_SEND_QUEUE, > TCP_QUEUES_NR, >}; ># 289 "/usr/include/netinet/tcp.h" 3 4 >struct tcp_cookie_transactions >{ > u_int16_t tcpct_flags; > u_int8_t __tcpct_pad1; > u_int8_t tcpct_cookie_desired; > u_int16_t tcpct_s_data_desired; > u_int16_t tcpct_used; > u_int8_t tcpct_value[536U]; >}; ># 74 "/usr/include/boost/asio/detail/socket_types.hpp" 2 3 4 > ># 1 "/usr/include/arpa/inet.h" 1 3 4 ># 30 "/usr/include/arpa/inet.h" 3 4 >extern "C" { > > > >extern in_addr_t inet_addr (const char *__cp) throw (); > > >extern in_addr_t inet_lnaof (struct in_addr __in) throw (); > > > >extern struct in_addr inet_makeaddr (in_addr_t __net, in_addr_t __host) > throw (); > > >extern in_addr_t inet_netof (struct in_addr __in) throw (); > > > >extern in_addr_t inet_network (const char *__cp) throw (); > > > >extern char *inet_ntoa (struct in_addr __in) throw (); > > > > >extern int inet_pton (int __af, const char *__restrict __cp, > void *__restrict __buf) throw (); > > > > >extern const char *inet_ntop (int __af, const void *__restrict __cp, > char *__restrict __buf, socklen_t __len) > throw (); > > > > > > >extern int inet_aton (const char *__cp, struct in_addr *__inp) throw (); > > > >extern char *inet_neta (in_addr_t __net, char *__buf, size_t __len) throw (); > > > > >extern char *inet_net_ntop (int __af, const void *__cp, int __bits, > char *__buf, size_t __len) throw (); > > > > >extern int inet_net_pton (int __af, const char *__cp, > void *__buf, size_t __len) throw (); > > > > >extern unsigned int inet_nsap_addr (const char *__cp, > unsigned char *__buf, int __len) throw (); > > > >extern char *inet_nsap_ntoa (int __len, const unsigned char *__cp, > char *__buf) throw (); > > >} ># 76 "/usr/include/boost/asio/detail/socket_types.hpp" 2 3 4 > ># 1 "/usr/include/net/if.h" 1 3 4 ># 33 "/usr/include/net/if.h" 3 4 >struct if_nameindex > { > unsigned int if_index; > char *if_name; > }; > > > > >enum > { > IFF_UP = 0x1, > > IFF_BROADCAST = 0x2, > > IFF_DEBUG = 0x4, > > IFF_LOOPBACK = 0x8, > > IFF_POINTOPOINT = 0x10, > > IFF_NOTRAILERS = 0x20, > > IFF_RUNNING = 0x40, > > IFF_NOARP = 0x80, > > IFF_PROMISC = 0x100, > > > > IFF_ALLMULTI = 0x200, > > > IFF_MASTER = 0x400, > > IFF_SLAVE = 0x800, > > > IFF_MULTICAST = 0x1000, > > > IFF_PORTSEL = 0x2000, > > IFF_AUTOMEDIA = 0x4000, > > IFF_DYNAMIC = 0x8000 > > }; > > > > > > >struct ifaddr > { > struct sockaddr ifa_addr; > union > { > struct sockaddr ifu_broadaddr; > struct sockaddr ifu_dstaddr; > } ifa_ifu; > struct iface *ifa_ifp; > struct ifaddr *ifa_next; > }; ># 111 "/usr/include/net/if.h" 3 4 >struct ifmap > { > unsigned long int mem_start; > unsigned long int mem_end; > unsigned short int base_addr; > unsigned char irq; > unsigned char dma; > unsigned char port; > > }; > > > > > >struct ifreq > { > > > union > { > char ifrn_name[16]; > } ifr_ifrn; > > union > { > struct sockaddr ifru_addr; > struct sockaddr ifru_dstaddr; > struct sockaddr ifru_broadaddr; > struct sockaddr ifru_netmask; > struct sockaddr ifru_hwaddr; > short int ifru_flags; > int ifru_ivalue; > int ifru_mtu; > struct ifmap ifru_map; > char ifru_slave[16]; > char ifru_newname[16]; > __caddr_t ifru_data; > } ifr_ifru; > }; ># 176 "/usr/include/net/if.h" 3 4 >struct ifconf > { > int ifc_len; > union > { > __caddr_t ifcu_buf; > struct ifreq *ifcu_req; > } ifc_ifcu; > }; > > > > > >extern "C" { > > >extern unsigned int if_nametoindex (const char *__ifname) throw (); >extern char *if_indextoname (unsigned int __ifindex, char *__ifname) throw (); > > >extern struct if_nameindex *if_nameindex (void) throw (); > > >extern void if_freenameindex (struct if_nameindex *__ptr) throw (); > >} ># 78 "/usr/include/boost/asio/detail/socket_types.hpp" 2 3 4 ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 79 "/usr/include/boost/asio/detail/socket_types.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 86 "/usr/include/boost/asio/detail/socket_types.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { ># 278 "/usr/include/boost/asio/detail/socket_types.hpp" 3 4 >typedef int socket_type; >const int invalid_socket = -1; >const int socket_error_retval = -1; >const int max_addr_v4_str_len = 16; > >const int max_addr_v6_str_len = 46 + 1 + 16; > > > >typedef sockaddr socket_addr_type; >typedef in_addr in4_addr_type; ># 297 "/usr/include/boost/asio/detail/socket_types.hpp" 3 4 >typedef ip_mreq in4_mreq_type; > >typedef sockaddr_in sockaddr_in4_type; >typedef in6_addr in6_addr_type; >typedef ipv6_mreq in6_mreq_type; >typedef sockaddr_in6 sockaddr_in6_type; >typedef sockaddr_storage sockaddr_storage_type; >typedef sockaddr_un sockaddr_un_type; >typedef addrinfo addrinfo_type; >typedef ::linger linger_type; >typedef int ioctl_arg_type; >typedef uint32_t u_long_type; >typedef uint16_t u_short_type; > >typedef ssize_t signed_size_type; ># 390 "/usr/include/boost/asio/detail/socket_types.hpp" 3 4 >const int max_iov_len = 1024; > > > > > >const int custom_socket_option_level = 0xA5100000; >const int enable_connection_aborted_option = 1; >const int always_fail_option = 2; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 405 "/usr/include/boost/asio/detail/socket_types.hpp" 2 3 4 ># 31 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/timer_queue_base.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/timer_queue_base.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/timer_queue_base.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class timer_queue_base > : private noncopyable >{ >public: > > timer_queue_base() : next_(0) {} > > > virtual ~timer_queue_base() {} > > > virtual bool empty() const = 0; > > > virtual long wait_duration_msec(long max_duration) const = 0; > > > virtual long wait_duration_usec(long max_duration) const = 0; > > > virtual void get_ready_timers(op_queue<operation>& ops) = 0; > > > virtual void get_all_timers(op_queue<operation>& ops) = 0; > >private: > friend class timer_queue_set; > > > timer_queue_base* next_; >}; > >template <typename Time_Traits> >class timer_queue; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 69 "/usr/include/boost/asio/detail/timer_queue_base.hpp" 2 3 4 ># 32 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/timer_queue_set.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/timer_queue_set.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/timer_queue_set.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class timer_queue_set >{ >public: > > inline timer_queue_set(); > > > inline void insert(timer_queue_base* q); > > > inline void erase(timer_queue_base* q); > > > inline bool all_empty() const; > > > inline long wait_duration_msec(long max_duration) const; > > > inline long wait_duration_usec(long max_duration) const; > > > inline void get_ready_timers(op_queue<operation>& ops); > > > inline void get_all_timers(op_queue<operation>& ops); > >private: > timer_queue_base* first_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 63 "/usr/include/boost/asio/detail/timer_queue_set.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/timer_queue_set.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/impl/timer_queue_set.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/timer_queue_set.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/impl/timer_queue_set.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/impl/timer_queue_set.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >timer_queue_set::timer_queue_set() > : first_(0) >{ >} > >void timer_queue_set::insert(timer_queue_base* q) >{ > q->next_ = first_; > first_ = q; >} > >void timer_queue_set::erase(timer_queue_base* q) >{ > if (first_) > { > if (q == first_) > { > first_ = q->next_; > q->next_ = 0; > return; > } > > for (timer_queue_base* p = first_; p->next_; p = p->next_) > { > if (p->next_ == q) > { > p->next_ = q->next_; > q->next_ = 0; > return; > } > } > } >} > >bool timer_queue_set::all_empty() const >{ > for (timer_queue_base* p = first_; p; p = p->next_) > if (!p->empty()) > return false; > return true; >} > >long timer_queue_set::wait_duration_msec(long max_duration) const >{ > long min_duration = max_duration; > for (timer_queue_base* p = first_; p; p = p->next_) > min_duration = p->wait_duration_msec(min_duration); > return min_duration; >} > >long timer_queue_set::wait_duration_usec(long max_duration) const >{ > long min_duration = max_duration; > for (timer_queue_base* p = first_; p; p = p->next_) > min_duration = p->wait_duration_usec(min_duration); > return min_duration; >} > >void timer_queue_set::get_ready_timers(op_queue<operation>& ops) >{ > for (timer_queue_base* p = first_; p; p = p->next_) > p->get_ready_timers(ops); >} > >void timer_queue_set::get_all_timers(op_queue<operation>& ops) >{ > for (timer_queue_base* p = first_; p; p = p->next_) > p->get_all_timers(ops); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 102 "/usr/include/boost/asio/detail/impl/timer_queue_set.ipp" 2 3 4 ># 66 "/usr/include/boost/asio/detail/timer_queue_set.hpp" 2 3 4 ># 33 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/wait_op.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/wait_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/wait_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class wait_op > : public operation >{ >public: > > boost::system::error_code ec_; > >protected: > wait_op(func_type func) > : operation(func) > { > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 46 "/usr/include/boost/asio/detail/wait_op.hpp" 2 3 4 ># 34 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 36 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class epoll_reactor > : public boost::asio::detail::service_base<epoll_reactor> >{ >public: > enum op_types { read_op = 0, write_op = 1, > connect_op = 1, except_op = 2, max_ops = 3 }; > > > class descriptor_state : operation > { > friend class epoll_reactor; > friend class object_pool_access; > > descriptor_state* next_; > descriptor_state* prev_; > > mutex mutex_; > epoll_reactor* reactor_; > int descriptor_; > uint32_t registered_events_; > op_queue<reactor_op> op_queue_[max_ops]; > bool shutdown_; > > inline descriptor_state(); > void set_ready_events(uint32_t events) { task_result_ = events; } > inline operation* perform_io(uint32_t events); > inline static void do_complete( > io_service_impl* owner, operation* base, > const boost::system::error_code& ec, std::size_t bytes_transferred); > }; > > > typedef descriptor_state* per_descriptor_data; > > > inline epoll_reactor(boost::asio::io_service& io_service); > > > inline ~epoll_reactor(); > > > inline void shutdown_service(); > > > inline void fork_service( > boost::asio::io_service::fork_event fork_ev); > > > inline void init_task(); > > > > inline int register_descriptor(socket_type descriptor, > per_descriptor_data& descriptor_data); > > > > inline int register_internal_descriptor( > int op_type, socket_type descriptor, > per_descriptor_data& descriptor_data, reactor_op* op); > > > inline void move_descriptor(socket_type descriptor, > per_descriptor_data& target_descriptor_data, > per_descriptor_data& source_descriptor_data); > > > void post_immediate_completion(reactor_op* op, bool is_continuation) > { > io_service_.post_immediate_completion(op, is_continuation); > } > > > > inline void start_op(int op_type, socket_type descriptor, > per_descriptor_data& descriptor_data, reactor_op* op, > bool is_continuation, bool allow_speculative); > > > > > inline void cancel_ops(socket_type descriptor, > per_descriptor_data& descriptor_data); > > > > inline void deregister_descriptor(socket_type descriptor, > per_descriptor_data& descriptor_data, bool closing); > > > inline void deregister_internal_descriptor( > socket_type descriptor, per_descriptor_data& descriptor_data); > > > template <typename Time_Traits> > void add_timer_queue(timer_queue<Time_Traits>& timer_queue); > > > template <typename Time_Traits> > void remove_timer_queue(timer_queue<Time_Traits>& timer_queue); > > > > template <typename Time_Traits> > void schedule_timer(timer_queue<Time_Traits>& queue, > const typename Time_Traits::time_type& time, > typename timer_queue<Time_Traits>::per_timer_data& timer, wait_op* op); > > > > template <typename Time_Traits> > std::size_t cancel_timer(timer_queue<Time_Traits>& queue, > typename timer_queue<Time_Traits>::per_timer_data& timer, > std::size_t max_cancelled = (std::numeric_limits<std::size_t>::max)()); > > > inline void run(bool block, op_queue<operation>& ops); > > > inline void interrupt(); > >private: > > enum { epoll_size = 20000 }; > > > > inline static int do_epoll_create(); > > > inline static int do_timerfd_create(); > > > inline descriptor_state* allocate_descriptor_state(); > > > inline void free_descriptor_state(descriptor_state* s); > > > inline void do_add_timer_queue(timer_queue_base& queue); > > > inline void do_remove_timer_queue(timer_queue_base& queue); > > > inline void update_timeout(); > > > > > inline int get_timeout(); > > > > > inline int get_timeout(itimerspec& ts); > > > > io_service_impl& io_service_; > > > mutex mutex_; > > > select_interrupter interrupter_; > > > int epoll_fd_; > > > int timer_fd_; > > > timer_queue_set timer_queues_; > > > bool shutdown_; > > > mutex registered_descriptors_mutex_; > > > object_pool<descriptor_state> registered_descriptors_; > > > struct perform_io_cleanup_on_block_exit; > friend struct perform_io_cleanup_on_block_exit; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 236 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/impl/epoll_reactor.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/impl/epoll_reactor.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/impl/epoll_reactor.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Time_Traits> >void epoll_reactor::add_timer_queue(timer_queue<Time_Traits>& queue) >{ > do_add_timer_queue(queue); >} > >template <typename Time_Traits> >void epoll_reactor::remove_timer_queue(timer_queue<Time_Traits>& queue) >{ > do_remove_timer_queue(queue); >} > >template <typename Time_Traits> >void epoll_reactor::schedule_timer(timer_queue<Time_Traits>& queue, > const typename Time_Traits::time_type& time, > typename timer_queue<Time_Traits>::per_timer_data& timer, wait_op* op) >{ > mutex::scoped_lock lock(mutex_); > > if (shutdown_) > { > io_service_.post_immediate_completion(op, false); > return; > } > > bool earliest = queue.enqueue_timer(time, timer, op); > io_service_.work_started(); > if (earliest) > update_timeout(); >} > >template <typename Time_Traits> >std::size_t epoll_reactor::cancel_timer(timer_queue<Time_Traits>& queue, > typename timer_queue<Time_Traits>::per_timer_data& timer, > std::size_t max_cancelled) >{ > mutex::scoped_lock lock(mutex_); > op_queue<operation> ops; > std::size_t n = queue.cancel_timer(timer, ops, max_cancelled); > lock.unlock(); > io_service_.post_deferred_completions(ops); > return n; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 75 "/usr/include/boost/asio/detail/impl/epoll_reactor.hpp" 2 3 4 ># 238 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/impl/epoll_reactor.ipp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/impl/epoll_reactor.ipp" 3 4 ># 1 "/usr/include/sys/epoll.h" 1 3 4 ># 25 "/usr/include/sys/epoll.h" 3 4 ># 1 "/usr/include/bits/sigset.h" 1 3 4 ># 26 "/usr/include/sys/epoll.h" 2 3 4 > > > > > > > ># 1 "/usr/include/bits/epoll.h" 1 3 4 ># 23 "/usr/include/bits/epoll.h" 3 4 >enum > { > EPOLL_CLOEXEC = 02000000 > > }; ># 34 "/usr/include/sys/epoll.h" 2 3 4 > > > > > > >enum EPOLL_EVENTS > { > EPOLLIN = 0x001, > > EPOLLPRI = 0x002, > > EPOLLOUT = 0x004, > > EPOLLRDNORM = 0x040, > > EPOLLRDBAND = 0x080, > > EPOLLWRNORM = 0x100, > > EPOLLWRBAND = 0x200, > > EPOLLMSG = 0x400, > > EPOLLERR = 0x008, > > EPOLLHUP = 0x010, > > EPOLLRDHUP = 0x2000, > > EPOLLWAKEUP = 1u << 29, > > EPOLLONESHOT = 1u << 30, > > EPOLLET = 1u << 31 > > }; ># 79 "/usr/include/sys/epoll.h" 3 4 >typedef union epoll_data >{ > void *ptr; > int fd; > uint32_t u32; > uint64_t u64; >} epoll_data_t; > >struct epoll_event >{ > uint32_t events; > epoll_data_t data; >} __attribute__ ((__packed__)); > > >extern "C" { > > > > > >extern int epoll_create (int __size) throw (); > > > >extern int epoll_create1 (int __flags) throw (); ># 113 "/usr/include/sys/epoll.h" 3 4 >extern int epoll_ctl (int __epfd, int __op, int __fd, > struct epoll_event *__event) throw (); ># 127 "/usr/include/sys/epoll.h" 3 4 >extern int epoll_wait (int __epfd, struct epoll_event *__events, > int __maxevents, int __timeout); > > > > > > > >extern int epoll_pwait (int __epfd, struct epoll_event *__events, > int __maxevents, int __timeout, > const __sigset_t *__ss); > >} ># 24 "/usr/include/boost/asio/detail/impl/epoll_reactor.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/impl/epoll_reactor.ipp" 2 3 4 > > > > ># 1 "/usr/include/sys/timerfd.h" 1 3 4 ># 24 "/usr/include/sys/timerfd.h" 3 4 ># 1 "/usr/include/bits/timerfd.h" 1 3 4 ># 23 "/usr/include/bits/timerfd.h" 3 4 >enum > { > TFD_CLOEXEC = 02000000, > > TFD_NONBLOCK = 00004000 > > }; ># 25 "/usr/include/sys/timerfd.h" 2 3 4 > > > >enum > { > TFD_TIMER_ABSTIME = 1 << 0 > > }; > > >extern "C" { > > >extern int timerfd_create (clockid_t __clock_id, int __flags) throw (); > > > > >extern int timerfd_settime (int __ufd, int __flags, > const struct itimerspec *__utmr, > struct itimerspec *__otmr) throw (); > > >extern int timerfd_gettime (int __ufd, struct itimerspec *__otmr) throw (); > >} ># 30 "/usr/include/boost/asio/detail/impl/epoll_reactor.ipp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/detail/impl/epoll_reactor.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >epoll_reactor::epoll_reactor(boost::asio::io_service& io_service) > : boost::asio::detail::service_base<epoll_reactor>(io_service), > io_service_(use_service<io_service_impl>(io_service)), > mutex_(), > interrupter_(), > epoll_fd_(do_epoll_create()), > timer_fd_(do_timerfd_create()), > shutdown_(false) >{ > > epoll_event ev = { 0, { 0 } }; > ev.events = EPOLLIN | EPOLLERR | EPOLLET; > ev.data.ptr = &interrupter_; > epoll_ctl(epoll_fd_, 1, interrupter_.read_descriptor(), &ev); > interrupter_.interrupt(); > > > if (timer_fd_ != -1) > { > ev.events = EPOLLIN | EPOLLERR; > ev.data.ptr = &timer_fd_; > epoll_ctl(epoll_fd_, 1, timer_fd_, &ev); > } >} > >epoll_reactor::~epoll_reactor() >{ > if (epoll_fd_ != -1) > close(epoll_fd_); > if (timer_fd_ != -1) > close(timer_fd_); >} > >void epoll_reactor::shutdown_service() >{ > mutex::scoped_lock lock(mutex_); > shutdown_ = true; > lock.unlock(); > > op_queue<operation> ops; > > while (descriptor_state* state = registered_descriptors_.first()) > { > for (int i = 0; i < max_ops; ++i) > ops.push(state->op_queue_[i]); > state->shutdown_ = true; > registered_descriptors_.free(state); > } > > timer_queues_.get_all_timers(ops); > > io_service_.abandon_operations(ops); >} > >void epoll_reactor::fork_service(boost::asio::io_service::fork_event fork_ev) >{ > if (fork_ev == boost::asio::io_service::fork_child) > { > if (epoll_fd_ != -1) > ::close(epoll_fd_); > epoll_fd_ = -1; > epoll_fd_ = do_epoll_create(); > > if (timer_fd_ != -1) > ::close(timer_fd_); > timer_fd_ = -1; > timer_fd_ = do_timerfd_create(); > > interrupter_.recreate(); > > > epoll_event ev = { 0, { 0 } }; > ev.events = EPOLLIN | EPOLLERR | EPOLLET; > ev.data.ptr = &interrupter_; > epoll_ctl(epoll_fd_, 1, interrupter_.read_descriptor(), &ev); > interrupter_.interrupt(); > > > if (timer_fd_ != -1) > { > ev.events = EPOLLIN | EPOLLERR; > ev.data.ptr = &timer_fd_; > epoll_ctl(epoll_fd_, 1, timer_fd_, &ev); > } > > update_timeout(); > > > mutex::scoped_lock descriptors_lock(registered_descriptors_mutex_); > for (descriptor_state* state = registered_descriptors_.first(); > state != 0; state = state->next_) > { > ev.events = state->registered_events_; > ev.data.ptr = state; > int result = epoll_ctl(epoll_fd_, 1, state->descriptor_, &ev); > if (result != 0) > { > boost::system::error_code ec((*__errno_location ()), > boost::asio::error::get_system_category()); > boost::asio::detail::throw_error(ec, "epoll re-registration"); > } > } > } >} > >void epoll_reactor::init_task() >{ > io_service_.init_task(); >} > >int epoll_reactor::register_descriptor(socket_type descriptor, > epoll_reactor::per_descriptor_data& descriptor_data) >{ > descriptor_data = allocate_descriptor_state(); > > { > mutex::scoped_lock descriptor_lock(descriptor_data->mutex_); > > descriptor_data->reactor_ = this; > descriptor_data->descriptor_ = descriptor; > descriptor_data->shutdown_ = false; > } > > epoll_event ev = { 0, { 0 } }; > ev.events = EPOLLIN | EPOLLERR | EPOLLHUP | EPOLLPRI | EPOLLET; > descriptor_data->registered_events_ = ev.events; > ev.data.ptr = descriptor_data; > int result = epoll_ctl(epoll_fd_, 1, descriptor, &ev); > if (result != 0) > return (*__errno_location ()); > > return 0; >} > >int epoll_reactor::register_internal_descriptor( > int op_type, socket_type descriptor, > epoll_reactor::per_descriptor_data& descriptor_data, reactor_op* op) >{ > descriptor_data = allocate_descriptor_state(); > > { > mutex::scoped_lock descriptor_lock(descriptor_data->mutex_); > > descriptor_data->reactor_ = this; > descriptor_data->descriptor_ = descriptor; > descriptor_data->shutdown_ = false; > descriptor_data->op_queue_[op_type].push(op); > } > > epoll_event ev = { 0, { 0 } }; > ev.events = EPOLLIN | EPOLLERR | EPOLLHUP | EPOLLPRI | EPOLLET; > descriptor_data->registered_events_ = ev.events; > ev.data.ptr = descriptor_data; > int result = epoll_ctl(epoll_fd_, 1, descriptor, &ev); > if (result != 0) > return (*__errno_location ()); > > return 0; >} > >void epoll_reactor::move_descriptor(socket_type, > epoll_reactor::per_descriptor_data& target_descriptor_data, > epoll_reactor::per_descriptor_data& source_descriptor_data) >{ > target_descriptor_data = source_descriptor_data; > source_descriptor_data = 0; >} > >void epoll_reactor::start_op(int op_type, socket_type descriptor, > epoll_reactor::per_descriptor_data& descriptor_data, reactor_op* op, > bool is_continuation, bool allow_speculative) >{ > if (!descriptor_data) > { > op->ec_ = boost::asio::error::bad_descriptor; > post_immediate_completion(op, is_continuation); > return; > } > > mutex::scoped_lock descriptor_lock(descriptor_data->mutex_); > > if (descriptor_data->shutdown_) > { > post_immediate_completion(op, is_continuation); > return; > } > > if (descriptor_data->op_queue_[op_type].empty()) > { > if (allow_speculative > && (op_type != read_op > || descriptor_data->op_queue_[except_op].empty())) > { > if (op->perform()) > { > descriptor_lock.unlock(); > io_service_.post_immediate_completion(op, is_continuation); > return; > } > > if (op_type == write_op) > { > if ((descriptor_data->registered_events_ & EPOLLOUT) == 0) > { > epoll_event ev = { 0, { 0 } }; > ev.events = descriptor_data->registered_events_ | EPOLLOUT; > ev.data.ptr = descriptor_data; > if (epoll_ctl(epoll_fd_, 3, descriptor, &ev) == 0) > { > descriptor_data->registered_events_ |= ev.events; > } > else > { > op->ec_ = boost::system::error_code((*__errno_location ()), > boost::asio::error::get_system_category()); > io_service_.post_immediate_completion(op, is_continuation); > return; > } > } > } > } > else > { > if (op_type == write_op) > { > descriptor_data->registered_events_ |= EPOLLOUT; > } > > epoll_event ev = { 0, { 0 } }; > ev.events = descriptor_data->registered_events_; > ev.data.ptr = descriptor_data; > epoll_ctl(epoll_fd_, 3, descriptor, &ev); > } > } > > descriptor_data->op_queue_[op_type].push(op); > io_service_.work_started(); >} > >void epoll_reactor::cancel_ops(socket_type, > epoll_reactor::per_descriptor_data& descriptor_data) >{ > if (!descriptor_data) > return; > > mutex::scoped_lock descriptor_lock(descriptor_data->mutex_); > > op_queue<operation> ops; > for (int i = 0; i < max_ops; ++i) > { > while (reactor_op* op = descriptor_data->op_queue_[i].front()) > { > op->ec_ = boost::asio::error::operation_aborted; > descriptor_data->op_queue_[i].pop(); > ops.push(op); > } > } > > descriptor_lock.unlock(); > > io_service_.post_deferred_completions(ops); >} > >void epoll_reactor::deregister_descriptor(socket_type descriptor, > epoll_reactor::per_descriptor_data& descriptor_data, bool closing) >{ > if (!descriptor_data) > return; > > mutex::scoped_lock descriptor_lock(descriptor_data->mutex_); > > if (!descriptor_data->shutdown_) > { > if (closing) > { > > > } > else > { > epoll_event ev = { 0, { 0 } }; > epoll_ctl(epoll_fd_, 2, descriptor, &ev); > } > > op_queue<operation> ops; > for (int i = 0; i < max_ops; ++i) > { > while (reactor_op* op = descriptor_data->op_queue_[i].front()) > { > op->ec_ = boost::asio::error::operation_aborted; > descriptor_data->op_queue_[i].pop(); > ops.push(op); > } > } > > descriptor_data->descriptor_ = -1; > descriptor_data->shutdown_ = true; > > descriptor_lock.unlock(); > > free_descriptor_state(descriptor_data); > descriptor_data = 0; > > io_service_.post_deferred_completions(ops); > } >} > >void epoll_reactor::deregister_internal_descriptor(socket_type descriptor, > epoll_reactor::per_descriptor_data& descriptor_data) >{ > if (!descriptor_data) > return; > > mutex::scoped_lock descriptor_lock(descriptor_data->mutex_); > > if (!descriptor_data->shutdown_) > { > epoll_event ev = { 0, { 0 } }; > epoll_ctl(epoll_fd_, 2, descriptor, &ev); > > op_queue<operation> ops; > for (int i = 0; i < max_ops; ++i) > ops.push(descriptor_data->op_queue_[i]); > > descriptor_data->descriptor_ = -1; > descriptor_data->shutdown_ = true; > > descriptor_lock.unlock(); > > free_descriptor_state(descriptor_data); > descriptor_data = 0; > } >} > >void epoll_reactor::run(bool block, op_queue<operation>& ops) >{ > > > > > > > > int timeout; > if (timer_fd_ != -1) > timeout = block ? -1 : 0; > else > { > mutex::scoped_lock lock(mutex_); > timeout = block ? get_timeout() : 0; > } > > > epoll_event events[128]; > int num_events = epoll_wait(epoll_fd_, events, 128, timeout); > > > bool check_timers = (timer_fd_ == -1); > > > > > > for (int i = 0; i < num_events; ++i) > { > void* ptr = events[i].data.ptr; > if (ptr == &interrupter_) > { > > > > > > > if (timer_fd_ == -1) > check_timers = true; > > > > } > > else if (ptr == &timer_fd_) > { > check_timers = true; > } > > else > { > > > > descriptor_state* descriptor_data = static_cast<descriptor_state*>(ptr); > descriptor_data->set_ready_events(events[i].events); > ops.push(descriptor_data); > } > } > > if (check_timers) > { > mutex::scoped_lock common_lock(mutex_); > timer_queues_.get_ready_timers(ops); > > > if (timer_fd_ != -1) > { > itimerspec new_timeout; > itimerspec old_timeout; > int flags = get_timeout(new_timeout); > timerfd_settime(timer_fd_, flags, &new_timeout, &old_timeout); > } > > } >} > >void epoll_reactor::interrupt() >{ > epoll_event ev = { 0, { 0 } }; > ev.events = EPOLLIN | EPOLLERR | EPOLLET; > ev.data.ptr = &interrupter_; > epoll_ctl(epoll_fd_, 3, interrupter_.read_descriptor(), &ev); >} > >int epoll_reactor::do_epoll_create() >{ > > int fd = epoll_create1(EPOLL_CLOEXEC); > > > > > > if (fd == -1 && ((*__errno_location ()) == 22 || (*__errno_location ()) == 38)) > { > fd = epoll_create(epoll_size); > if (fd != -1) > ::fcntl(fd, 2, 1); > } > > if (fd == -1) > { > boost::system::error_code ec((*__errno_location ()), > boost::asio::error::get_system_category()); > boost::asio::detail::throw_error(ec, "epoll"); > } > > return fd; >} > >int epoll_reactor::do_timerfd_create() >{ > > > int fd = timerfd_create(1, TFD_CLOEXEC); > > > > > > if (fd == -1 && (*__errno_location ()) == 22) > { > fd = timerfd_create(1, 0); > if (fd != -1) > ::fcntl(fd, 2, 1); > } > > return fd; > > > >} > >epoll_reactor::descriptor_state* epoll_reactor::allocate_descriptor_state() >{ > mutex::scoped_lock descriptors_lock(registered_descriptors_mutex_); > return registered_descriptors_.alloc(); >} > >void epoll_reactor::free_descriptor_state(epoll_reactor::descriptor_state* s) >{ > mutex::scoped_lock descriptors_lock(registered_descriptors_mutex_); > registered_descriptors_.free(s); >} > >void epoll_reactor::do_add_timer_queue(timer_queue_base& queue) >{ > mutex::scoped_lock lock(mutex_); > timer_queues_.insert(&queue); >} > >void epoll_reactor::do_remove_timer_queue(timer_queue_base& queue) >{ > mutex::scoped_lock lock(mutex_); > timer_queues_.erase(&queue); >} > >void epoll_reactor::update_timeout() >{ > > if (timer_fd_ != -1) > { > itimerspec new_timeout; > itimerspec old_timeout; > int flags = get_timeout(new_timeout); > timerfd_settime(timer_fd_, flags, &new_timeout, &old_timeout); > return; > } > > interrupt(); >} > >int epoll_reactor::get_timeout() >{ > > > return timer_queues_.wait_duration_msec(5 * 60 * 1000); >} > > >int epoll_reactor::get_timeout(itimerspec& ts) >{ > ts.it_interval.tv_sec = 0; > ts.it_interval.tv_nsec = 0; > > long usec = timer_queues_.wait_duration_usec(5 * 60 * 1000 * 1000); > ts.it_value.tv_sec = usec / 1000000; > ts.it_value.tv_nsec = usec ? (usec % 1000000) * 1000 : 1; > > return usec ? 0 : TFD_TIMER_ABSTIME; >} > > >struct epoll_reactor::perform_io_cleanup_on_block_exit >{ > explicit perform_io_cleanup_on_block_exit(epoll_reactor* r) > : reactor_(r), first_op_(0) > { > } > > ~perform_io_cleanup_on_block_exit() > { > if (first_op_) > { > > if (!ops_.empty()) > reactor_->io_service_.post_deferred_completions(ops_); > > > > > > } > else > { > > > > reactor_->io_service_.work_started(); > } > } > > epoll_reactor* reactor_; > op_queue<operation> ops_; > operation* first_op_; >}; > >epoll_reactor::descriptor_state::descriptor_state() > : operation(&epoll_reactor::descriptor_state::do_complete) >{ >} > >operation* epoll_reactor::descriptor_state::perform_io(uint32_t events) >{ > mutex_.lock(); > perform_io_cleanup_on_block_exit io_cleanup(reactor_); > mutex::scoped_lock descriptor_lock(mutex_, mutex::scoped_lock::adopt_lock); > > > > static const int flag[max_ops] = { EPOLLIN, EPOLLOUT, EPOLLPRI }; > for (int j = max_ops - 1; j >= 0; --j) > { > if (events & (flag[j] | EPOLLERR | EPOLLHUP)) > { > while (reactor_op* op = op_queue_[j].front()) > { > if (op->perform()) > { > op_queue_[j].pop(); > io_cleanup.ops_.push(op); > } > else > break; > } > } > } > > > > io_cleanup.first_op_ = io_cleanup.ops_.front(); > io_cleanup.ops_.pop(); > return io_cleanup.first_op_; >} > >void epoll_reactor::descriptor_state::do_complete( > io_service_impl* owner, operation* base, > const boost::system::error_code& ec, std::size_t bytes_transferred) >{ > if (owner) > { > descriptor_state* descriptor_data = static_cast<descriptor_state*>(base); > uint32_t events = static_cast<uint32_t>(bytes_transferred); > if (operation* op = descriptor_data->perform_io(events)) > { > op->complete(*owner, ec, 0); > } > } >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 661 "/usr/include/boost/asio/detail/impl/epoll_reactor.ipp" 2 3 4 ># 240 "/usr/include/boost/asio/detail/epoll_reactor.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/detail/reactor.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/detail/impl/task_io_service.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/task_io_service.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/impl/task_io_service.ipp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/detail/impl/task_io_service.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >struct task_io_service::task_cleanup >{ > ~task_cleanup() > { > if (this_thread_->private_outstanding_work > 0) > { > boost::asio::detail::increment( > task_io_service_->outstanding_work_, > this_thread_->private_outstanding_work); > } > this_thread_->private_outstanding_work = 0; > > > > lock_->lock(); > task_io_service_->task_interrupted_ = true; > task_io_service_->op_queue_.push(this_thread_->private_op_queue); > task_io_service_->op_queue_.push(&task_io_service_->task_operation_); > } > > task_io_service* task_io_service_; > mutex::scoped_lock* lock_; > thread_info* this_thread_; >}; > >struct task_io_service::work_cleanup >{ > ~work_cleanup() > { > if (this_thread_->private_outstanding_work > 1) > { > boost::asio::detail::increment( > task_io_service_->outstanding_work_, > this_thread_->private_outstanding_work - 1); > } > else if (this_thread_->private_outstanding_work < 1) > { > task_io_service_->work_finished(); > } > this_thread_->private_outstanding_work = 0; > > > if (!this_thread_->private_op_queue.empty()) > { > lock_->lock(); > task_io_service_->op_queue_.push(this_thread_->private_op_queue); > } > > } > > task_io_service* task_io_service_; > mutex::scoped_lock* lock_; > thread_info* this_thread_; >}; > >task_io_service::task_io_service( > boost::asio::io_service& io_service, std::size_t concurrency_hint) > : boost::asio::detail::service_base<task_io_service>(io_service), > one_thread_(concurrency_hint == 1), > mutex_(), > task_(0), > task_interrupted_(true), > outstanding_work_(0), > stopped_(false), > shutdown_(false), > first_idle_thread_(0) >{ > (void)0; >} > >void task_io_service::shutdown_service() >{ > mutex::scoped_lock lock(mutex_); > shutdown_ = true; > lock.unlock(); > > > while (!op_queue_.empty()) > { > operation* o = op_queue_.front(); > op_queue_.pop(); > if (o != &task_operation_) > o->destroy(); > } > > > task_ = 0; >} > >void task_io_service::init_task() >{ > mutex::scoped_lock lock(mutex_); > if (!shutdown_ && !task_) > { > task_ = &use_service<reactor>(this->get_io_service()); > op_queue_.push(&task_operation_); > wake_one_thread_and_unlock(lock); > } >} > >std::size_t task_io_service::run(boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > if (outstanding_work_ == 0) > { > stop(); > return 0; > } > > thread_info this_thread; > event wakeup_event; > this_thread.wakeup_event = &wakeup_event; > this_thread.private_outstanding_work = 0; > this_thread.next = 0; > thread_call_stack::context ctx(this, this_thread); > > mutex::scoped_lock lock(mutex_); > > std::size_t n = 0; > for (; do_run_one(lock, this_thread, ec); lock.lock()) > if (n != (std::numeric_limits<std::size_t>::max)()) > ++n; > return n; >} > >std::size_t task_io_service::run_one(boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > if (outstanding_work_ == 0) > { > stop(); > return 0; > } > > thread_info this_thread; > event wakeup_event; > this_thread.wakeup_event = &wakeup_event; > this_thread.private_outstanding_work = 0; > this_thread.next = 0; > thread_call_stack::context ctx(this, this_thread); > > mutex::scoped_lock lock(mutex_); > > return do_run_one(lock, this_thread, ec); >} > >std::size_t task_io_service::poll(boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > if (outstanding_work_ == 0) > { > stop(); > return 0; > } > > thread_info this_thread; > this_thread.wakeup_event = 0; > this_thread.private_outstanding_work = 0; > this_thread.next = 0; > thread_call_stack::context ctx(this, this_thread); > > mutex::scoped_lock lock(mutex_); > > > > > > if (one_thread_) > if (thread_info* outer_thread_info = ctx.next_by_key()) > op_queue_.push(outer_thread_info->private_op_queue); > > > std::size_t n = 0; > for (; do_poll_one(lock, this_thread, ec); lock.lock()) > if (n != (std::numeric_limits<std::size_t>::max)()) > ++n; > return n; >} > >std::size_t task_io_service::poll_one(boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > if (outstanding_work_ == 0) > { > stop(); > return 0; > } > > thread_info this_thread; > this_thread.wakeup_event = 0; > this_thread.private_outstanding_work = 0; > this_thread.next = 0; > thread_call_stack::context ctx(this, this_thread); > > mutex::scoped_lock lock(mutex_); > > > > > > if (one_thread_) > if (thread_info* outer_thread_info = ctx.next_by_key()) > op_queue_.push(outer_thread_info->private_op_queue); > > > return do_poll_one(lock, this_thread, ec); >} > >void task_io_service::stop() >{ > mutex::scoped_lock lock(mutex_); > stop_all_threads(lock); >} > >bool task_io_service::stopped() const >{ > mutex::scoped_lock lock(mutex_); > return stopped_; >} > >void task_io_service::reset() >{ > mutex::scoped_lock lock(mutex_); > stopped_ = false; >} > >void task_io_service::post_immediate_completion( > task_io_service::operation* op, bool is_continuation) >{ > > if (one_thread_ || is_continuation) > { > if (thread_info* this_thread = thread_call_stack::contains(this)) > { > ++this_thread->private_outstanding_work; > this_thread->private_op_queue.push(op); > return; > } > } > > > work_started(); > mutex::scoped_lock lock(mutex_); > op_queue_.push(op); > wake_one_thread_and_unlock(lock); >} > >void task_io_service::post_deferred_completion(task_io_service::operation* op) >{ > > if (one_thread_) > { > if (thread_info* this_thread = thread_call_stack::contains(this)) > { > this_thread->private_op_queue.push(op); > return; > } > } > > > mutex::scoped_lock lock(mutex_); > op_queue_.push(op); > wake_one_thread_and_unlock(lock); >} > >void task_io_service::post_deferred_completions( > op_queue<task_io_service::operation>& ops) >{ > if (!ops.empty()) > { > > if (one_thread_) > { > if (thread_info* this_thread = thread_call_stack::contains(this)) > { > this_thread->private_op_queue.push(ops); > return; > } > } > > > mutex::scoped_lock lock(mutex_); > op_queue_.push(ops); > wake_one_thread_and_unlock(lock); > } >} > >void task_io_service::do_dispatch( > task_io_service::operation* op) >{ > work_started(); > mutex::scoped_lock lock(mutex_); > op_queue_.push(op); > wake_one_thread_and_unlock(lock); >} > >void task_io_service::abandon_operations( > op_queue<task_io_service::operation>& ops) >{ > op_queue<task_io_service::operation> ops2; > ops2.push(ops); >} > >std::size_t task_io_service::do_run_one(mutex::scoped_lock& lock, > task_io_service::thread_info& this_thread, > const boost::system::error_code& ec) >{ > while (!stopped_) > { > if (!op_queue_.empty()) > { > > operation* o = op_queue_.front(); > op_queue_.pop(); > bool more_handlers = (!op_queue_.empty()); > > if (o == &task_operation_) > { > task_interrupted_ = more_handlers; > > if (more_handlers && !one_thread_) > { > if (!wake_one_idle_thread_and_unlock(lock)) > lock.unlock(); > } > else > lock.unlock(); > > task_cleanup on_exit = { this, &lock, &this_thread }; > (void)on_exit; > > > > > task_->run(!more_handlers, this_thread.private_op_queue); > } > else > { > std::size_t task_result = o->task_result_; > > if (more_handlers && !one_thread_) > wake_one_thread_and_unlock(lock); > else > lock.unlock(); > > > work_cleanup on_exit = { this, &lock, &this_thread }; > (void)on_exit; > > > o->complete(*this, ec, task_result); > > return 1; > } > } > else > { > > this_thread.next = first_idle_thread_; > first_idle_thread_ = &this_thread; > this_thread.wakeup_event->clear(lock); > this_thread.wakeup_event->wait(lock); > } > } > > return 0; >} > >std::size_t task_io_service::do_poll_one(mutex::scoped_lock& lock, > task_io_service::thread_info& this_thread, > const boost::system::error_code& ec) >{ > if (stopped_) > return 0; > > operation* o = op_queue_.front(); > if (o == &task_operation_) > { > op_queue_.pop(); > lock.unlock(); > > { > task_cleanup c = { this, &lock, &this_thread }; > (void)c; > > > > > task_->run(false, this_thread.private_op_queue); > } > > o = op_queue_.front(); > if (o == &task_operation_) > { > wake_one_idle_thread_and_unlock(lock); > return 0; > } > } > > if (o == 0) > return 0; > > op_queue_.pop(); > bool more_handlers = (!op_queue_.empty()); > > std::size_t task_result = o->task_result_; > > if (more_handlers && !one_thread_) > wake_one_thread_and_unlock(lock); > else > lock.unlock(); > > > work_cleanup on_exit = { this, &lock, &this_thread }; > (void)on_exit; > > > o->complete(*this, ec, task_result); > > return 1; >} > >void task_io_service::stop_all_threads( > mutex::scoped_lock& lock) >{ > stopped_ = true; > > while (first_idle_thread_) > { > thread_info* idle_thread = first_idle_thread_; > first_idle_thread_ = idle_thread->next; > idle_thread->next = 0; > idle_thread->wakeup_event->signal(lock); > } > > if (!task_interrupted_ && task_) > { > task_interrupted_ = true; > task_->interrupt(); > } >} > >bool task_io_service::wake_one_idle_thread_and_unlock( > mutex::scoped_lock& lock) >{ > if (first_idle_thread_) > { > thread_info* idle_thread = first_idle_thread_; > first_idle_thread_ = idle_thread->next; > idle_thread->next = 0; > idle_thread->wakeup_event->signal_and_unlock(lock); > return true; > } > return false; >} > >void task_io_service::wake_one_thread_and_unlock( > mutex::scoped_lock& lock) >{ > if (!wake_one_idle_thread_and_unlock(lock)) > { > if (!task_interrupted_ && task_) > { > task_interrupted_ = true; > task_->interrupt(); > } > lock.unlock(); > } >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 509 "/usr/include/boost/asio/detail/impl/task_io_service.ipp" 2 3 4 ># 204 "/usr/include/boost/asio/detail/task_io_service.hpp" 2 3 4 ># 72 "/usr/include/boost/asio/impl/io_service.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 75 "/usr/include/boost/asio/impl/io_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > >template <typename CompletionHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<CompletionHandler, void ()>::type>::type >io_service::dispatch(CompletionHandler&& handler) >{ > > > typedef typename handler_type<CompletionHandler, void()>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::zero_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), 0)) == 1, "CompletionHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()(), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > CompletionHandler, void ()> init( > static_cast<CompletionHandler&&>(handler)); > > impl_.dispatch(init.handler); > > return init.result.get(); >} > >template <typename CompletionHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<CompletionHandler, void ()>::type>::type >io_service::post(CompletionHandler&& handler) >{ > > > typedef typename handler_type<CompletionHandler, void()>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::zero_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), 0)) == 1, "CompletionHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()(), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > CompletionHandler, void ()> init( > static_cast<CompletionHandler&&>(handler)); > > impl_.post(init.handler); > > return init.result.get(); >} > >template <typename Handler> > > > >inline detail::wrapped_handler<io_service&, Handler> > >io_service::wrap(Handler handler) >{ > return detail::wrapped_handler<io_service&, Handler>(*this, handler); >} > >inline io_service::work::work(boost::asio::io_service& io_service) > : io_service_impl_(io_service.impl_) >{ > io_service_impl_.work_started(); >} > >inline io_service::work::work(const work& other) > : io_service_impl_(other.io_service_impl_) >{ > io_service_impl_.work_started(); >} > >inline io_service::work::~work() >{ > io_service_impl_.work_finished(); >} > >inline boost::asio::io_service& io_service::work::get_io_service() >{ > return io_service_impl_.get_io_service(); >} > >inline boost::asio::io_service& io_service::service::get_io_service() >{ > return owner_; >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 155 "/usr/include/boost/asio/impl/io_service.hpp" 2 3 4 ># 768 "/usr/include/boost/asio/io_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/io_service.ipp" 1 3 4 ># 21 "/usr/include/boost/asio/impl/io_service.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/scoped_ptr.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/scoped_ptr.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/scoped_ptr.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename T> >class scoped_ptr >{ >public: > > explicit scoped_ptr(T* p = 0) > : p_(p) > { > } > > > ~scoped_ptr() > { > delete p_; > } > > > T* get() > { > return p_; > } > > > T* operator->() > { > return p_; > } > > > T& operator*() > { > return *p_; > } > > > void reset(T* p = 0) > { > delete p_; > p_ = p; > } > >private: > > scoped_ptr(const scoped_ptr&); > scoped_ptr& operator=(const scoped_ptr&); > > T* p_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 80 "/usr/include/boost/asio/detail/scoped_ptr.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/impl/io_service.ipp" 2 3 4 ># 31 "/usr/include/boost/asio/impl/io_service.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/impl/io_service.ipp" 2 3 4 > >namespace boost { >namespace asio { > >io_service::io_service() > : service_registry_(new boost::asio::detail::service_registry( > *this, static_cast<impl_type*>(0), > (std::numeric_limits<std::size_t>::max)())), > impl_(service_registry_->first_service<impl_type>()) >{ >} > >io_service::io_service(std::size_t concurrency_hint) > : service_registry_(new boost::asio::detail::service_registry( > *this, static_cast<impl_type*>(0), concurrency_hint)), > impl_(service_registry_->first_service<impl_type>()) >{ >} > >io_service::~io_service() >{ > delete service_registry_; >} > >std::size_t io_service::run() >{ > boost::system::error_code ec; > std::size_t s = impl_.run(ec); > boost::asio::detail::throw_error(ec); > return s; >} > >std::size_t io_service::run(boost::system::error_code& ec) >{ > return impl_.run(ec); >} > >std::size_t io_service::run_one() >{ > boost::system::error_code ec; > std::size_t s = impl_.run_one(ec); > boost::asio::detail::throw_error(ec); > return s; >} > >std::size_t io_service::run_one(boost::system::error_code& ec) >{ > return impl_.run_one(ec); >} > >std::size_t io_service::poll() >{ > boost::system::error_code ec; > std::size_t s = impl_.poll(ec); > boost::asio::detail::throw_error(ec); > return s; >} > >std::size_t io_service::poll(boost::system::error_code& ec) >{ > return impl_.poll(ec); >} > >std::size_t io_service::poll_one() >{ > boost::system::error_code ec; > std::size_t s = impl_.poll_one(ec); > boost::asio::detail::throw_error(ec); > return s; >} > >std::size_t io_service::poll_one(boost::system::error_code& ec) >{ > return impl_.poll_one(ec); >} > >void io_service::stop() >{ > impl_.stop(); >} > >bool io_service::stopped() const >{ > return impl_.stopped(); >} > >void io_service::reset() >{ > impl_.reset(); >} > >void io_service::notify_fork(boost::asio::io_service::fork_event event) >{ > service_registry_->notify_fork(event); >} > >io_service::service::service(boost::asio::io_service& owner) > : owner_(owner), > next_(0) >{ >} > >io_service::service::~service() >{ >} > >void io_service::service::fork_service(boost::asio::io_service::fork_event) >{ >} > >service_already_exists::service_already_exists() > : std::logic_error("Service already exists.") >{ >} > >invalid_service_owner::invalid_service_owner() > : std::logic_error("Invalid service owner.") >{ >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 156 "/usr/include/boost/asio/impl/io_service.ipp" 2 3 4 ># 770 "/usr/include/boost/asio/io_service.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/basic_io_object.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/basic_io_object.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >namespace detail >{ > > template <typename IoObjectService> > class service_has_move > { > private: > typedef IoObjectService service_type; > typedef typename service_type::implementation_type implementation_type; > > template <typename T, typename U> > static auto eval(T* t, U* u) -> decltype(t->move_construct(*u, *u), char()); > static char (&eval(...))[2]; > > public: > static const bool value = > sizeof(service_has_move::eval( > static_cast<service_type*>(0), > static_cast<implementation_type*>(0))) == 1; > }; >} ># 58 "/usr/include/boost/asio/basic_io_object.hpp" 3 4 >template <typename IoObjectService, > bool Movable = detail::service_has_move<IoObjectService>::value> > >class basic_io_object >{ >public: > > typedef IoObjectService service_type; > > > typedef typename service_type::implementation_type implementation_type; ># 78 "/usr/include/boost/asio/basic_io_object.hpp" 3 4 > boost::asio::io_service& get_io_service() > { > return service.get_io_service(); > } > >protected: > > > > > > explicit basic_io_object(boost::asio::io_service& io_service) > : service(boost::asio::use_service<IoObjectService>(io_service)) > { > service.construct(implementation); > } ># 122 "/usr/include/boost/asio/basic_io_object.hpp" 3 4 > ~basic_io_object() > { > service.destroy(implementation); > } > > > service_type& get_service() > { > return service; > } > > > const service_type& get_service() const > { > return service; > } > > > > > > > service_type& service; > > > implementation_type& get_implementation() > { > return implementation; > } > > > const implementation_type& get_implementation() const > { > return implementation; > } > > > > implementation_type implementation; > >private: > basic_io_object(const basic_io_object&); > basic_io_object& operator=(const basic_io_object&); >}; > > > >template <typename IoObjectService> >class basic_io_object<IoObjectService, true> >{ >public: > typedef IoObjectService service_type; > typedef typename service_type::implementation_type implementation_type; > > boost::asio::io_service& get_io_service() > { > return service_->get_io_service(); > } > >protected: > explicit basic_io_object(boost::asio::io_service& io_service) > : service_(&boost::asio::use_service<IoObjectService>(io_service)) > { > service_->construct(implementation); > } > > basic_io_object(basic_io_object&& other) > : service_(&other.get_service()) > { > service_->move_construct(implementation, other.implementation); > } > > ~basic_io_object() > { > service_->destroy(implementation); > } > > basic_io_object& operator=(basic_io_object&& other) > { > service_->move_assign(implementation, > *other.service_, other.implementation); > service_ = other.service_; > return *this; > } > > service_type& get_service() > { > return *service_; > } > > const service_type& get_service() const > { > return *service_; > } > > implementation_type& get_implementation() > { > return implementation; > } > > const implementation_type& get_implementation() const > { > return implementation; > } > > implementation_type implementation; > >private: > basic_io_object(const basic_io_object&); > void operator=(const basic_io_object&); > > IoObjectService* service_; >}; > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 241 "/usr/include/boost/asio/basic_io_object.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/basic_socket.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/type_traits.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/detail/type_traits.hpp" 3 4 >namespace boost { >namespace asio { > > >using std::add_const; >using std::enable_if; >using std::is_const; >using std::is_convertible; >using std::is_function; >using std::is_same; >using std::remove_pointer; >using std::remove_reference; ># 57 "/usr/include/boost/asio/detail/type_traits.hpp" 3 4 >} >} ># 24 "/usr/include/boost/asio/basic_socket.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/socket_base.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/socket_base.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/io_control.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/io_control.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/io_control.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { >namespace io_control { > > >class non_blocking_io >{ >public: > > non_blocking_io() > : value_(0) > { > } > > > non_blocking_io(bool value) > : value_(value ? 1 : 0) > { > } > > > int name() const > { > return static_cast<int>(0x5421); > } > > > void set(bool value) > { > value_ = value ? 1 : 0; > } > > > bool get() const > { > return value_ != 0; > } > > > detail::ioctl_arg_type* data() > { > return &value_; > } > > > const detail::ioctl_arg_type* data() const > { > return &value_; > } > >private: > detail::ioctl_arg_type value_; >}; > > >class bytes_readable >{ >public: > > bytes_readable() > : value_(0) > { > } > > > bytes_readable(std::size_t value) > : value_(static_cast<detail::ioctl_arg_type>(value)) > { > } > > > int name() const > { > return static_cast<int>(0x541B); > } > > > void set(std::size_t value) > { > value_ = static_cast<detail::ioctl_arg_type>(value); > } > > > std::size_t get() const > { > return static_cast<std::size_t>(value_); > } > > > detail::ioctl_arg_type* data() > { > return &value_; > } > > > const detail::ioctl_arg_type* data() const > { > return &value_; > } > >private: > detail::ioctl_arg_type value_; >}; > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 135 "/usr/include/boost/asio/detail/io_control.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/socket_base.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/socket_option.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/socket_option.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/socket_option.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { >namespace socket_option { > > >template <int Level, int Name> >class boolean >{ >public: > > boolean() > : value_(0) > { > } > > > explicit boolean(bool v) > : value_(v ? 1 : 0) > { > } > > > boolean& operator=(bool v) > { > value_ = v ? 1 : 0; > return *this; > } > > > bool value() const > { > return !!value_; > } > > > operator bool() const > { > return !!value_; > } > > > bool operator!() const > { > return !value_; > } > > > template <typename Protocol> > int level(const Protocol&) const > { > return Level; > } > > > template <typename Protocol> > int name(const Protocol&) const > { > return Name; > } > > > template <typename Protocol> > int* data(const Protocol&) > { > return &value_; > } > > > template <typename Protocol> > const int* data(const Protocol&) const > { > return &value_; > } > > > template <typename Protocol> > std::size_t size(const Protocol&) const > { > return sizeof(value_); > } > > > template <typename Protocol> > void resize(const Protocol&, std::size_t s) > { > > > > switch (s) > { > case sizeof(char): > value_ = *reinterpret_cast<char*>(&value_) ? 1 : 0; > break; > case sizeof(value_): > break; > default: > { > std::length_error ex("boolean socket option resize"); > boost::asio::detail::throw_exception(ex); > } > } > } > >private: > int value_; >}; > > >template <int Level, int Name> >class integer >{ >public: > > integer() > : value_(0) > { > } > > > explicit integer(int v) > : value_(v) > { > } > > > integer& operator=(int v) > { > value_ = v; > return *this; > } > > > int value() const > { > return value_; > } > > > template <typename Protocol> > int level(const Protocol&) const > { > return Level; > } > > > template <typename Protocol> > int name(const Protocol&) const > { > return Name; > } > > > template <typename Protocol> > int* data(const Protocol&) > { > return &value_; > } > > > template <typename Protocol> > const int* data(const Protocol&) const > { > return &value_; > } > > > template <typename Protocol> > std::size_t size(const Protocol&) const > { > return sizeof(value_); > } > > > template <typename Protocol> > void resize(const Protocol&, std::size_t s) > { > if (s != sizeof(value_)) > { > std::length_error ex("integer socket option resize"); > boost::asio::detail::throw_exception(ex); > } > } > >private: > int value_; >}; > > >template <int Level, int Name> >class linger >{ >public: > > linger() > { > value_.l_onoff = 0; > value_.l_linger = 0; > } > > > linger(bool e, int t) > { > enabled(e); > timeout (t); > } > > > void enabled(bool value) > { > value_.l_onoff = value ? 1 : 0; > } > > > bool enabled() const > { > return value_.l_onoff != 0; > } > > > void timeout (int value) > { > > > > value_.l_linger = value; > > } > > > int timeout () const > { > return static_cast<int>(value_.l_linger); > } > > > template <typename Protocol> > int level(const Protocol&) const > { > return Level; > } > > > template <typename Protocol> > int name(const Protocol&) const > { > return Name; > } > > > template <typename Protocol> > detail::linger_type* data(const Protocol&) > { > return &value_; > } > > > template <typename Protocol> > const detail::linger_type* data(const Protocol&) const > { > return &value_; > } > > > template <typename Protocol> > std::size_t size(const Protocol&) const > { > return sizeof(value_); > } > > > template <typename Protocol> > void resize(const Protocol&, std::size_t s) > { > if (s != sizeof(value_)) > { > std::length_error ex("linger socket option resize"); > boost::asio::detail::throw_exception(ex); > } > } > >private: > detail::linger_type value_; >}; > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 317 "/usr/include/boost/asio/detail/socket_option.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/socket_base.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/socket_base.hpp" 2 3 4 > >namespace boost { >namespace asio { > > > > >class socket_base >{ >public: > > enum shutdown_type > { ># 47 "/usr/include/boost/asio/socket_base.hpp" 3 4 > shutdown_receive = SHUT_RD, > shutdown_send = SHUT_WR, > shutdown_both = SHUT_RDWR > > }; > > > typedef int message_flags; ># 69 "/usr/include/boost/asio/socket_base.hpp" 3 4 > static const int message_peek = MSG_PEEK > ; > static const int message_out_of_band = MSG_OOB > ; > static const int message_do_not_route = MSG_DONTROUTE > ; > static const int message_end_of_record = MSG_EOR > ; ># 108 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::boolean< > 1, 6> > broadcast; ># 142 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::boolean< > 1, 1> debug; ># 175 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::boolean< > 1, 5> > do_not_route; ># 209 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::boolean< > 1, 9> keep_alive; ># 242 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::integer< > 1, 7> > send_buffer_size; ># 276 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::integer< > 1, 19> > send_low_watermark; ># 310 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::integer< > 1, 8> > receive_buffer_size; ># 344 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::integer< > 1, 18> > receive_low_watermark; ># 379 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::boolean< > 1, 2> > reuse_address; ># 415 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::linger< > 1, 13> > linger; ># 451 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::socket_option::boolean< > boost::asio::detail::custom_socket_option_level, > boost::asio::detail::enable_connection_aborted_option> > enable_connection_aborted; ># 476 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::io_control::non_blocking_io non_blocking_io; ># 499 "/usr/include/boost/asio/socket_base.hpp" 3 4 > typedef boost::asio::detail::io_control::bytes_readable bytes_readable; > > > > > > > static const int max_connections = 128 > ; > > >protected: > > ~socket_base() > { > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 521 "/usr/include/boost/asio/socket_base.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/basic_socket.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/basic_socket.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 41 "/usr/include/boost/asio/basic_socket.hpp" 3 4 >template <typename Protocol, typename SocketService> >class basic_socket > : public basic_io_object<SocketService>, > public socket_base >{ >public: > > > typedef typename SocketService::native_handle_type native_type; > > > typedef typename SocketService::native_handle_type native_handle_type; > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; > > > typedef basic_socket<Protocol, SocketService> lowest_layer_type; ># 70 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > explicit basic_socket(boost::asio::io_service& io_service) > : basic_io_object<SocketService>(io_service) > { > } ># 86 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > basic_socket(boost::asio::io_service& io_service, > const protocol_type& protocol) > : basic_io_object<SocketService>(io_service) > { > boost::system::error_code ec; > this->get_service().open(this->get_implementation(), protocol, ec); > boost::asio::detail::throw_error(ec, "open"); > } ># 110 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > basic_socket(boost::asio::io_service& io_service, > const endpoint_type& endpoint) > : basic_io_object<SocketService>(io_service) > { > boost::system::error_code ec; > const protocol_type protocol = endpoint.protocol(); > this->get_service().open(this->get_implementation(), protocol, ec); > boost::asio::detail::throw_error(ec, "open"); > this->get_service().bind(this->get_implementation(), endpoint, ec); > boost::asio::detail::throw_error(ec, "bind"); > } ># 135 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > basic_socket(boost::asio::io_service& io_service, > const protocol_type& protocol, const native_handle_type& native_socket) > : basic_io_object<SocketService>(io_service) > { > boost::system::error_code ec; > this->get_service().assign(this->get_implementation(), > protocol, native_socket, ec); > boost::asio::detail::throw_error(ec, "assign"); > } ># 156 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > basic_socket(basic_socket&& other) > : basic_io_object<SocketService>( > static_cast<basic_socket&&>(other)) > { > } ># 172 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > basic_socket& operator=(basic_socket&& other) > { > basic_io_object<SocketService>::operator=( > static_cast<basic_socket&&>(other)); > return *this; > } > > > template <typename Protocol1, typename SocketService1> > friend class basic_socket; ># 193 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > template <typename Protocol1, typename SocketService1> > basic_socket(basic_socket<Protocol1, SocketService1>&& other, > typename enable_if<is_convertible<Protocol1, Protocol>::value>::type* = 0) > : basic_io_object<SocketService>(other.get_io_service()) > { > this->get_service().template converting_move_construct<Protocol1>( > this->get_implementation(), other.get_implementation()); > } ># 212 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > template <typename Protocol1, typename SocketService1> > typename enable_if<is_convertible<Protocol1, Protocol>::value, > basic_socket>::type& operator=( > basic_socket<Protocol1, SocketService1>&& other) > { > basic_socket tmp(static_cast<basic_socket< Protocol1, SocketService1>&&> > (other)); > basic_io_object<SocketService>::operator=( > static_cast<basic_socket&&>(tmp)); > return *this; > } ># 234 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > lowest_layer_type& lowest_layer() > { > return *this; > } ># 248 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > const lowest_layer_type& lowest_layer() const > { > return *this; > } ># 267 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > void open(const protocol_type& protocol = protocol_type()) > { > boost::system::error_code ec; > this->get_service().open(this->get_implementation(), protocol, ec); > boost::asio::detail::throw_error(ec, "open"); > } ># 293 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > boost::system::error_code open(const protocol_type& protocol, > boost::system::error_code& ec) > { > return this->get_service().open(this->get_implementation(), protocol, ec); > } ># 309 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > void assign(const protocol_type& protocol, > const native_handle_type& native_socket) > { > boost::system::error_code ec; > this->get_service().assign(this->get_implementation(), > protocol, native_socket, ec); > boost::asio::detail::throw_error(ec, "assign"); > } ># 328 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > boost::system::error_code assign(const protocol_type& protocol, > const native_handle_type& native_socket, boost::system::error_code& ec) > { > return this->get_service().assign(this->get_implementation(), > protocol, native_socket, ec); > } > > > bool is_open() const > { > return this->get_service().is_open(this->get_implementation()); > } ># 353 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > void close() > { > boost::system::error_code ec; > this->get_service().close(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "close"); > } ># 384 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > boost::system::error_code close(boost::system::error_code& ec) > { > return this->get_service().close(this->get_implementation(), ec); > } > > > > > > > > native_type native() > { > return this->get_service().native_handle(this->get_implementation()); > } > > > > > > > > native_handle_type native_handle() > { > return this->get_service().native_handle(this->get_implementation()); > } ># 452 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > void cancel() > { > boost::system::error_code ec; > this->get_service().cancel(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "cancel"); > } ># 500 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > boost::system::error_code cancel(boost::system::error_code& ec) > { > return this->get_service().cancel(this->get_implementation(), ec); > } ># 515 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > bool at_mark() const > { > boost::system::error_code ec; > bool b = this->get_service().at_mark(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "at_mark"); > return b; > } ># 533 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > bool at_mark(boost::system::error_code& ec) const > { > return this->get_service().at_mark(this->get_implementation(), ec); > } ># 548 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > std::size_t available() const > { > boost::system::error_code ec; > std::size_t s = this->get_service().available( > this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "available"); > return s; > } ># 567 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > std::size_t available(boost::system::error_code& ec) const > { > return this->get_service().available(this->get_implementation(), ec); > } ># 590 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > void bind(const endpoint_type& endpoint) > { > boost::system::error_code ec; > this->get_service().bind(this->get_implementation(), endpoint, ec); > boost::asio::detail::throw_error(ec, "bind"); > } ># 620 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > boost::system::error_code bind(const endpoint_type& endpoint, > boost::system::error_code& ec) > { > return this->get_service().bind(this->get_implementation(), endpoint, ec); > } ># 649 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > void connect(const endpoint_type& peer_endpoint) > { > boost::system::error_code ec; > if (!is_open()) > { > this->get_service().open(this->get_implementation(), > peer_endpoint.protocol(), ec); > boost::asio::detail::throw_error(ec, "connect"); > } > this->get_service().connect(this->get_implementation(), peer_endpoint, ec); > boost::asio::detail::throw_error(ec, "connect"); > } ># 690 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > boost::system::error_code connect(const endpoint_type& peer_endpoint, > boost::system::error_code& ec) > { > if (!is_open()) > { > if (this->get_service().open(this->get_implementation(), > peer_endpoint.protocol(), ec)) > { > return ec; > } > } > > return this->get_service().connect( > this->get_implementation(), peer_endpoint, ec); > } ># 747 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > template <typename ConnectHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ConnectHandler, void (boost::system::error_code)>::type>::type > > async_connect(const endpoint_type& peer_endpoint, > ConnectHandler&& handler) > { > > > typedef typename handler_type<ConnectHandler, void(boost::system::error_code)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::one_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0))) == 1, "ConnectHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>()), char(0))> __attribute__((__unused__)) type_check; > > if (!is_open()) > { > boost::system::error_code ec; > const protocol_type protocol = peer_endpoint.protocol(); > if (this->get_service().open(this->get_implementation(), protocol, ec)) > { > detail::async_result_init< > ConnectHandler, void (boost::system::error_code)> init( > static_cast<ConnectHandler&&>(handler)); > > this->get_io_service().post( > boost::asio::detail::bind_handler( > static_cast<typename handler_type<ConnectHandler, void (boost::system::error_code)>::type&&> > ( > init.handler), ec)); > > return init.result.get(); > } > } > > return this->get_service().async_connect(this->get_implementation(), > peer_endpoint, static_cast<ConnectHandler&&>(handler)); > } ># 815 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > template <typename SettableSocketOption> > void set_option(const SettableSocketOption& option) > { > boost::system::error_code ec; > this->get_service().set_option(this->get_implementation(), option, ec); > boost::asio::detail::throw_error(ec, "set_option"); > } ># 862 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > template <typename SettableSocketOption> > boost::system::error_code set_option(const SettableSocketOption& option, > boost::system::error_code& ec) > { > return this->get_service().set_option( > this->get_implementation(), option, ec); > } ># 905 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > template <typename GettableSocketOption> > void get_option(GettableSocketOption& option) const > { > boost::system::error_code ec; > this->get_service().get_option(this->get_implementation(), option, ec); > boost::asio::detail::throw_error(ec, "get_option"); > } ># 953 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > template <typename GettableSocketOption> > boost::system::error_code get_option(GettableSocketOption& option, > boost::system::error_code& ec) const > { > return this->get_service().get_option( > this->get_implementation(), option, ec); > } ># 983 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > template <typename IoControlCommand> > void io_control(IoControlCommand& command) > { > boost::system::error_code ec; > this->get_service().io_control(this->get_implementation(), command, ec); > boost::asio::detail::throw_error(ec, "io_control"); > } ># 1018 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > template <typename IoControlCommand> > boost::system::error_code io_control(IoControlCommand& command, > boost::system::error_code& ec) > { > return this->get_service().io_control( > this->get_implementation(), command, ec); > } ># 1037 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > bool non_blocking() const > { > return this->get_service().non_blocking(this->get_implementation()); > } ># 1055 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > void non_blocking(bool mode) > { > boost::system::error_code ec; > this->get_service().non_blocking(this->get_implementation(), mode, ec); > boost::asio::detail::throw_error(ec, "non_blocking"); > } ># 1075 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > boost::system::error_code non_blocking( > bool mode, boost::system::error_code& ec) > { > return this->get_service().non_blocking( > this->get_implementation(), mode, ec); > } ># 1166 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > bool native_non_blocking() const > { > return this->get_service().native_non_blocking(this->get_implementation()); > } ># 1256 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > void native_non_blocking(bool mode) > { > boost::system::error_code ec; > this->get_service().native_non_blocking( > this->get_implementation(), mode, ec); > boost::asio::detail::throw_error(ec, "native_non_blocking"); > } ># 1349 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > boost::system::error_code native_non_blocking( > bool mode, boost::system::error_code& ec) > { > return this->get_service().native_non_blocking( > this->get_implementation(), mode, ec); > } ># 1371 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > endpoint_type local_endpoint() const > { > boost::system::error_code ec; > endpoint_type ep = this->get_service().local_endpoint( > this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "local_endpoint"); > return ep; > } ># 1401 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > endpoint_type local_endpoint(boost::system::error_code& ec) const > { > return this->get_service().local_endpoint(this->get_implementation(), ec); > } ># 1421 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > endpoint_type remote_endpoint() const > { > boost::system::error_code ec; > endpoint_type ep = this->get_service().remote_endpoint( > this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "remote_endpoint"); > return ep; > } ># 1451 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > endpoint_type remote_endpoint(boost::system::error_code& ec) const > { > return this->get_service().remote_endpoint(this->get_implementation(), ec); > } ># 1473 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > void shutdown(shutdown_type what) > { > boost::system::error_code ec; > this->get_service().shutdown(this->get_implementation(), what, ec); > boost::asio::detail::throw_error(ec, "shutdown"); > } ># 1502 "/usr/include/boost/asio/basic_socket.hpp" 3 4 > boost::system::error_code shutdown(shutdown_type what, > boost::system::error_code& ec) > { > return this->get_service().shutdown(this->get_implementation(), what, ec); > } > >protected: > > ~basic_socket() > { > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 1519 "/usr/include/boost/asio/basic_socket.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/basic_datagram_socket.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/datagram_socket_service.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/datagram_socket_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/buffer.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/buffer.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 21 "/usr/include/boost/asio/buffer.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/array_fwd.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/array_fwd.hpp" 3 4 >namespace boost { > >template<class T, std::size_t N> >class array; > >} ># 24 "/usr/include/boost/asio/buffer.hpp" 2 3 4 ># 58 "/usr/include/boost/asio/buffer.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 59 "/usr/include/boost/asio/buffer.hpp" 2 3 4 > >namespace boost { >namespace asio { > >class mutable_buffer; >class const_buffer; > >namespace detail { >void* buffer_cast_helper(const mutable_buffer&); >const void* buffer_cast_helper(const const_buffer&); >std::size_t buffer_size_helper(const mutable_buffer&); >std::size_t buffer_size_helper(const const_buffer&); >} ># 92 "/usr/include/boost/asio/buffer.hpp" 3 4 >class mutable_buffer >{ >public: > > mutable_buffer() > : data_(0), > size_(0) > { > } > > > mutable_buffer(void* data, std::size_t size) > : data_(data), > size_(size) > { > } ># 124 "/usr/include/boost/asio/buffer.hpp" 3 4 >private: > friend void* boost::asio::detail::buffer_cast_helper( > const mutable_buffer& b); > friend std::size_t boost::asio::detail::buffer_size_helper( > const mutable_buffer& b); > > void* data_; > std::size_t size_; > > > > >}; > >namespace detail { > >inline void* buffer_cast_helper(const mutable_buffer& b) >{ > > > > > return b.data_; >} > >inline std::size_t buffer_size_helper(const mutable_buffer& b) >{ > return b.size_; >} > >} > > > >class mutable_buffers_1 > : public mutable_buffer >{ >public: > > typedef mutable_buffer value_type; > > > typedef const mutable_buffer* const_iterator; > > > mutable_buffers_1(void* data, std::size_t size) > : mutable_buffer(data, size) > { > } > > > explicit mutable_buffers_1(const mutable_buffer& b) > : mutable_buffer(b) > { > } > > > const_iterator begin() const > { > return this; > } > > > const_iterator end() const > { > return begin() + 1; > } >}; ># 212 "/usr/include/boost/asio/buffer.hpp" 3 4 >class const_buffer >{ >public: > > const_buffer() > : data_(0), > size_(0) > { > } > > > const_buffer(const void* data, std::size_t size) > : data_(data), > size_(size) > { > } > > > const_buffer(const mutable_buffer& b) > : data_(boost::asio::detail::buffer_cast_helper(b)), > size_(boost::asio::detail::buffer_size_helper(b)) > > > > { > } ># 254 "/usr/include/boost/asio/buffer.hpp" 3 4 >private: > friend const void* boost::asio::detail::buffer_cast_helper( > const const_buffer& b); > friend std::size_t boost::asio::detail::buffer_size_helper( > const const_buffer& b); > > const void* data_; > std::size_t size_; > > > > >}; > >namespace detail { > >inline const void* buffer_cast_helper(const const_buffer& b) >{ > > > > > return b.data_; >} > >inline std::size_t buffer_size_helper(const const_buffer& b) >{ > return b.size_; >} > >} > > > >class const_buffers_1 > : public const_buffer >{ >public: > > typedef const_buffer value_type; > > > typedef const const_buffer* const_iterator; > > > const_buffers_1(const void* data, std::size_t size) > : const_buffer(data, size) > { > } > > > explicit const_buffers_1(const const_buffer& b) > : const_buffer(b) > { > } > > > const_iterator begin() const > { > return this; > } > > > const_iterator end() const > { > return begin() + 1; > } >}; > > > >class null_buffers >{ >public: > > typedef mutable_buffer value_type; > > > typedef const mutable_buffer* const_iterator; > > > const_iterator begin() const > { > return &buf_; > } > > > const_iterator end() const > { > return &buf_; > } > >private: > mutable_buffer buf_; >}; ># 358 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_size(const mutable_buffer& b) >{ > return detail::buffer_size_helper(b); >} > > >inline std::size_t buffer_size(const mutable_buffers_1& b) >{ > return detail::buffer_size_helper(b); >} > > >inline std::size_t buffer_size(const const_buffer& b) >{ > return detail::buffer_size_helper(b); >} > > >inline std::size_t buffer_size(const const_buffers_1& b) >{ > return detail::buffer_size_helper(b); >} > > > > > > >template <typename BufferSequence> >inline std::size_t buffer_size(const BufferSequence& b) >{ > std::size_t total_buffer_size = 0; > > typename BufferSequence::const_iterator iter = b.begin(); > typename BufferSequence::const_iterator end = b.end(); > for (; iter != end; ++iter) > total_buffer_size += detail::buffer_size_helper(*iter); > > return total_buffer_size; >} ># 424 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PointerToPodType> >inline PointerToPodType buffer_cast(const mutable_buffer& b) >{ > return static_cast<PointerToPodType>(detail::buffer_cast_helper(b)); >} > > >template <typename PointerToPodType> >inline PointerToPodType buffer_cast(const const_buffer& b) >{ > return static_cast<PointerToPodType>(detail::buffer_cast_helper(b)); >} > > > > > > > >inline mutable_buffer operator+(const mutable_buffer& b, std::size_t start) >{ > if (start > buffer_size(b)) > return mutable_buffer(); > char* new_data = buffer_cast<char*>(b) + start; > std::size_t new_size = buffer_size(b) - start; > return mutable_buffer(new_data, new_size > > > > ); >} > > > > > >inline mutable_buffer operator+(std::size_t start, const mutable_buffer& b) >{ > if (start > buffer_size(b)) > return mutable_buffer(); > char* new_data = buffer_cast<char*>(b) + start; > std::size_t new_size = buffer_size(b) - start; > return mutable_buffer(new_data, new_size > > > > ); >} > > > > > >inline const_buffer operator+(const const_buffer& b, std::size_t start) >{ > if (start > buffer_size(b)) > return const_buffer(); > const char* new_data = buffer_cast<const char*>(b) + start; > std::size_t new_size = buffer_size(b) - start; > return const_buffer(new_data, new_size > > > > ); >} > > > > > >inline const_buffer operator+(std::size_t start, const const_buffer& b) >{ > if (start > buffer_size(b)) > return const_buffer(); > const char* new_data = buffer_cast<const char*>(b) + start; > std::size_t new_size = buffer_size(b) - start; > return const_buffer(new_data, new_size > > > > ); >} ># 704 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline mutable_buffers_1 buffer(const mutable_buffer& b) >{ > return mutable_buffers_1(b); >} ># 716 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline mutable_buffers_1 buffer(const mutable_buffer& b, > std::size_t max_size_in_bytes) >{ > return mutable_buffers_1( > mutable_buffer(buffer_cast<void*>(b), > buffer_size(b) < max_size_in_bytes > ? buffer_size(b) : max_size_in_bytes > > > > )); >} > > > > > >inline const_buffers_1 buffer(const const_buffer& b) >{ > return const_buffers_1(b); >} ># 745 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline const_buffers_1 buffer(const const_buffer& b, > std::size_t max_size_in_bytes) >{ > return const_buffers_1( > const_buffer(buffer_cast<const void*>(b), > buffer_size(b) < max_size_in_bytes > ? buffer_size(b) : max_size_in_bytes > > > > )); >} > > > > > >inline mutable_buffers_1 buffer(void* data, std::size_t size_in_bytes) >{ > return mutable_buffers_1(mutable_buffer(data, size_in_bytes)); >} > > > > > >inline const_buffers_1 buffer(const void* data, > std::size_t size_in_bytes) >{ > return const_buffers_1(const_buffer(data, size_in_bytes)); >} ># 784 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline mutable_buffers_1 buffer(PodType (&data)[N]) >{ > return mutable_buffers_1(mutable_buffer(data, N * sizeof(PodType))); >} ># 797 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline mutable_buffers_1 buffer(PodType (&data)[N], > std::size_t max_size_in_bytes) >{ > return mutable_buffers_1( > mutable_buffer(data, > N * sizeof(PodType) < max_size_in_bytes > ? N * sizeof(PodType) : max_size_in_bytes)); >} ># 814 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(const PodType (&data)[N]) >{ > return const_buffers_1(const_buffer(data, N * sizeof(PodType))); >} ># 827 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(const PodType (&data)[N], > std::size_t max_size_in_bytes) >{ > return const_buffers_1( > const_buffer(data, > N * sizeof(PodType) < max_size_in_bytes > ? N * sizeof(PodType) : max_size_in_bytes)); >} ># 913 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline mutable_buffers_1 buffer(boost::array<PodType, N>& data) >{ > return mutable_buffers_1( > mutable_buffer(data.c_array(), data.size() * sizeof(PodType))); >} ># 927 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline mutable_buffers_1 buffer(boost::array<PodType, N>& data, > std::size_t max_size_in_bytes) >{ > return mutable_buffers_1( > mutable_buffer(data.c_array(), > data.size() * sizeof(PodType) < max_size_in_bytes > ? data.size() * sizeof(PodType) : max_size_in_bytes)); >} ># 944 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(boost::array<const PodType, N>& data) >{ > return const_buffers_1( > const_buffer(data.data(), data.size() * sizeof(PodType))); >} ># 958 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(boost::array<const PodType, N>& data, > std::size_t max_size_in_bytes) >{ > return const_buffers_1( > const_buffer(data.data(), > data.size() * sizeof(PodType) < max_size_in_bytes > ? data.size() * sizeof(PodType) : max_size_in_bytes)); >} ># 977 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(const boost::array<PodType, N>& data) >{ > return const_buffers_1( > const_buffer(data.data(), data.size() * sizeof(PodType))); >} ># 991 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(const boost::array<PodType, N>& data, > std::size_t max_size_in_bytes) >{ > return const_buffers_1( > const_buffer(data.data(), > data.size() * sizeof(PodType) < max_size_in_bytes > ? data.size() * sizeof(PodType) : max_size_in_bytes)); >} ># 1010 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline mutable_buffers_1 buffer(std::array<PodType, N>& data) >{ > return mutable_buffers_1( > mutable_buffer(data.data(), data.size() * sizeof(PodType))); >} ># 1024 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline mutable_buffers_1 buffer(std::array<PodType, N>& data, > std::size_t max_size_in_bytes) >{ > return mutable_buffers_1( > mutable_buffer(data.data(), > data.size() * sizeof(PodType) < max_size_in_bytes > ? data.size() * sizeof(PodType) : max_size_in_bytes)); >} ># 1041 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(std::array<const PodType, N>& data) >{ > return const_buffers_1( > const_buffer(data.data(), data.size() * sizeof(PodType))); >} ># 1055 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(std::array<const PodType, N>& data, > std::size_t max_size_in_bytes) >{ > return const_buffers_1( > const_buffer(data.data(), > data.size() * sizeof(PodType) < max_size_in_bytes > ? data.size() * sizeof(PodType) : max_size_in_bytes)); >} ># 1072 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(const std::array<PodType, N>& data) >{ > return const_buffers_1( > const_buffer(data.data(), data.size() * sizeof(PodType))); >} ># 1086 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, std::size_t N> >inline const_buffers_1 buffer(const std::array<PodType, N>& data, > std::size_t max_size_in_bytes) >{ > return const_buffers_1( > const_buffer(data.data(), > data.size() * sizeof(PodType) < max_size_in_bytes > ? data.size() * sizeof(PodType) : max_size_in_bytes)); >} ># 1108 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, typename Allocator> >inline mutable_buffers_1 buffer(std::vector<PodType, Allocator>& data) >{ > return mutable_buffers_1( > mutable_buffer(data.size() ? &data[0] : 0, data.size() * sizeof(PodType) > > > > > > )); >} ># 1131 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, typename Allocator> >inline mutable_buffers_1 buffer(std::vector<PodType, Allocator>& data, > std::size_t max_size_in_bytes) >{ > return mutable_buffers_1( > mutable_buffer(data.size() ? &data[0] : 0, > data.size() * sizeof(PodType) < max_size_in_bytes > ? data.size() * sizeof(PodType) : max_size_in_bytes > > > > > > )); >} ># 1157 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, typename Allocator> >inline const_buffers_1 buffer( > const std::vector<PodType, Allocator>& data) >{ > return const_buffers_1( > const_buffer(data.size() ? &data[0] : 0, data.size() * sizeof(PodType) > > > > > > )); >} ># 1181 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename PodType, typename Allocator> >inline const_buffers_1 buffer( > const std::vector<PodType, Allocator>& data, std::size_t max_size_in_bytes) >{ > return const_buffers_1( > const_buffer(data.size() ? &data[0] : 0, > data.size() * sizeof(PodType) < max_size_in_bytes > ? data.size() * sizeof(PodType) : max_size_in_bytes > > > > > > )); >} ># 1204 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename Elem, typename Traits, typename Allocator> >inline const_buffers_1 buffer( > const std::basic_string<Elem, Traits, Allocator>& data) >{ > return const_buffers_1(const_buffer(data.data(), data.size() * sizeof(Elem) > > > > > > )); >} ># 1227 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename Elem, typename Traits, typename Allocator> >inline const_buffers_1 buffer( > const std::basic_string<Elem, Traits, Allocator>& data, > std::size_t max_size_in_bytes) >{ > return const_buffers_1( > const_buffer(data.data(), > data.size() * sizeof(Elem) < max_size_in_bytes > ? data.size() * sizeof(Elem) : max_size_in_bytes > > > > > > )); >} ># 1287 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffer& target, > const const_buffer& source) >{ > using namespace std; > std::size_t target_size = buffer_size(target); > std::size_t source_size = buffer_size(source); > std::size_t n = target_size < source_size ? target_size : source_size; > memcpy(buffer_cast<void*>(target), buffer_cast<const void*>(source), n); > return n; >} ># 1314 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffer& target, > const const_buffers_1& source) >{ > return buffer_copy(target, static_cast<const const_buffer&>(source)); >} ># 1337 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffer& target, > const mutable_buffer& source) >{ > return buffer_copy(target, const_buffer(source)); >} ># 1360 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffer& target, > const mutable_buffers_1& source) >{ > return buffer_copy(target, const_buffer(source)); >} ># 1382 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename ConstBufferSequence> >std::size_t buffer_copy(const mutable_buffer& target, > const ConstBufferSequence& source) >{ > std::size_t total_bytes_copied = 0; > > typename ConstBufferSequence::const_iterator source_iter = source.begin(); > typename ConstBufferSequence::const_iterator source_end = source.end(); > > for (mutable_buffer target_buffer(target); > buffer_size(target_buffer) && source_iter != source_end; ++source_iter) > { > const_buffer source_buffer(*source_iter); > std::size_t bytes_copied = buffer_copy(target_buffer, source_buffer); > total_bytes_copied += bytes_copied; > target_buffer = target_buffer + bytes_copied; > } > > return total_bytes_copied; >} ># 1419 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const const_buffer& source) >{ > return buffer_copy(static_cast<const mutable_buffer&>(target), source); >} ># 1441 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const const_buffers_1& source) >{ > return buffer_copy(static_cast<const mutable_buffer&>(target), > static_cast<const const_buffer&>(source)); >} ># 1465 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const mutable_buffer& source) >{ > return buffer_copy(static_cast<const mutable_buffer&>(target), > const_buffer(source)); >} ># 1489 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const mutable_buffers_1& source) >{ > return buffer_copy(static_cast<const mutable_buffer&>(target), > const_buffer(source)); >} ># 1512 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename ConstBufferSequence> >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const ConstBufferSequence& source) >{ > return buffer_copy(static_cast<const mutable_buffer&>(target), source); >} ># 1535 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence> >std::size_t buffer_copy(const MutableBufferSequence& target, > const const_buffer& source) >{ > std::size_t total_bytes_copied = 0; > > typename MutableBufferSequence::const_iterator target_iter = target.begin(); > typename MutableBufferSequence::const_iterator target_end = target.end(); > > for (const_buffer source_buffer(source); > buffer_size(source_buffer) && target_iter != target_end; ++target_iter) > { > mutable_buffer target_buffer(*target_iter); > std::size_t bytes_copied = buffer_copy(target_buffer, source_buffer); > total_bytes_copied += bytes_copied; > source_buffer = source_buffer + bytes_copied; > } > > return total_bytes_copied; >} ># 1572 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence> >inline std::size_t buffer_copy(const MutableBufferSequence& target, > const const_buffers_1& source) >{ > return buffer_copy(target, static_cast<const const_buffer&>(source)); >} ># 1596 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence> >inline std::size_t buffer_copy(const MutableBufferSequence& target, > const mutable_buffer& source) >{ > return buffer_copy(target, const_buffer(source)); >} ># 1620 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence> >inline std::size_t buffer_copy(const MutableBufferSequence& target, > const mutable_buffers_1& source) >{ > return buffer_copy(target, const_buffer(source)); >} ># 1643 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence, typename ConstBufferSequence> >std::size_t buffer_copy(const MutableBufferSequence& target, > const ConstBufferSequence& source) >{ > std::size_t total_bytes_copied = 0; > > typename MutableBufferSequence::const_iterator target_iter = target.begin(); > typename MutableBufferSequence::const_iterator target_end = target.end(); > std::size_t target_buffer_offset = 0; > > typename ConstBufferSequence::const_iterator source_iter = source.begin(); > typename ConstBufferSequence::const_iterator source_end = source.end(); > std::size_t source_buffer_offset = 0; > > while (target_iter != target_end && source_iter != source_end) > { > mutable_buffer target_buffer = > mutable_buffer(*target_iter) + target_buffer_offset; > > const_buffer source_buffer = > const_buffer(*source_iter) + source_buffer_offset; > > std::size_t bytes_copied = buffer_copy(target_buffer, source_buffer); > total_bytes_copied += bytes_copied; > > if (bytes_copied == buffer_size(target_buffer)) > { > ++target_iter; > target_buffer_offset = 0; > } > else > target_buffer_offset += bytes_copied; > > if (bytes_copied == buffer_size(source_buffer)) > { > ++source_iter; > source_buffer_offset = 0; > } > else > source_buffer_offset += bytes_copied; > } > > return total_bytes_copied; >} ># 1708 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffer& target, > const const_buffer& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1734 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffer& target, > const const_buffers_1& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1761 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffer& target, > const mutable_buffer& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1788 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffer& target, > const mutable_buffers_1& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1815 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename ConstBufferSequence> >inline std::size_t buffer_copy(const mutable_buffer& target, > const ConstBufferSequence& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1842 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const const_buffer& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1868 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const const_buffers_1& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1895 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const mutable_buffer& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1922 "/usr/include/boost/asio/buffer.hpp" 3 4 >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const mutable_buffers_1& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1949 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename ConstBufferSequence> >inline std::size_t buffer_copy(const mutable_buffers_1& target, > const ConstBufferSequence& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(buffer(target, max_bytes_to_copy), source); >} ># 1977 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence> >inline std::size_t buffer_copy(const MutableBufferSequence& target, > const const_buffer& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(target, buffer(source, max_bytes_to_copy)); >} ># 2005 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence> >inline std::size_t buffer_copy(const MutableBufferSequence& target, > const const_buffers_1& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(target, buffer(source, max_bytes_to_copy)); >} ># 2034 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence> >inline std::size_t buffer_copy(const MutableBufferSequence& target, > const mutable_buffer& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(target, buffer(source, max_bytes_to_copy)); >} ># 2063 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence> >inline std::size_t buffer_copy(const MutableBufferSequence& target, > const mutable_buffers_1& source, std::size_t max_bytes_to_copy) >{ > return buffer_copy(target, buffer(source, max_bytes_to_copy)); >} ># 2091 "/usr/include/boost/asio/buffer.hpp" 3 4 >template <typename MutableBufferSequence, typename ConstBufferSequence> >std::size_t buffer_copy(const MutableBufferSequence& target, > const ConstBufferSequence& source, std::size_t max_bytes_to_copy) >{ > std::size_t total_bytes_copied = 0; > > typename MutableBufferSequence::const_iterator target_iter = target.begin(); > typename MutableBufferSequence::const_iterator target_end = target.end(); > std::size_t target_buffer_offset = 0; > > typename ConstBufferSequence::const_iterator source_iter = source.begin(); > typename ConstBufferSequence::const_iterator source_end = source.end(); > std::size_t source_buffer_offset = 0; > > while (total_bytes_copied != max_bytes_to_copy > && target_iter != target_end && source_iter != source_end) > { > mutable_buffer target_buffer = > mutable_buffer(*target_iter) + target_buffer_offset; > > const_buffer source_buffer = > const_buffer(*source_iter) + source_buffer_offset; > > std::size_t bytes_copied = buffer_copy(target_buffer, > source_buffer, max_bytes_to_copy - total_bytes_copied); > total_bytes_copied += bytes_copied; > > if (bytes_copied == buffer_size(target_buffer)) > { > ++target_iter; > target_buffer_offset = 0; > } > else > target_buffer_offset += bytes_copied; > > if (bytes_copied == buffer_size(source_buffer)) > { > ++source_iter; > source_buffer_offset = 0; > } > else > source_buffer_offset += bytes_copied; > } > > return total_bytes_copied; >} > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 2144 "/usr/include/boost/asio/buffer.hpp" 2 3 4 ># 23 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/asio/detail/buffer_sequence_adapter.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/buffer_sequence_adapter.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/buffer_sequence_adapter.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class buffer_sequence_adapter_base >{ >protected: ># 66 "/usr/include/boost/asio/detail/buffer_sequence_adapter.hpp" 3 4 > enum { max_buffers = 64 < max_iov_len ? 64 : max_iov_len }; > > typedef iovec native_buffer_type; > > static void init_iov_base(void*& base, void* addr) > { > base = addr; > } > > template <typename T> > static void init_iov_base(T& base, void* addr) > { > base = static_cast<T>(addr); > } > > static void init_native_buffer(iovec& iov, > const boost::asio::mutable_buffer& buffer) > { > init_iov_base(iov.iov_base, boost::asio::buffer_cast<void*>(buffer)); > iov.iov_len = boost::asio::buffer_size(buffer); > } > > static void init_native_buffer(iovec& iov, > const boost::asio::const_buffer& buffer) > { > init_iov_base(iov.iov_base, const_cast<void*>( > boost::asio::buffer_cast<const void*>(buffer))); > iov.iov_len = boost::asio::buffer_size(buffer); > } > >}; > > >template <typename Buffer, typename Buffers> >class buffer_sequence_adapter > : buffer_sequence_adapter_base >{ >public: > explicit buffer_sequence_adapter(const Buffers& buffer_sequence) > : count_(0), total_buffer_size_(0) > { > typename Buffers::const_iterator iter = buffer_sequence.begin(); > typename Buffers::const_iterator end = buffer_sequence.end(); > for (; iter != end && count_ < max_buffers; ++iter, ++count_) > { > Buffer buffer(*iter); > init_native_buffer(buffers_[count_], buffer); > total_buffer_size_ += boost::asio::buffer_size(buffer); > } > } > > native_buffer_type* buffers() > { > return buffers_; > } > > std::size_t count() const > { > return count_; > } > > bool all_empty() const > { > return total_buffer_size_ == 0; > } > > static bool all_empty(const Buffers& buffer_sequence) > { > typename Buffers::const_iterator iter = buffer_sequence.begin(); > typename Buffers::const_iterator end = buffer_sequence.end(); > std::size_t i = 0; > for (; iter != end && i < max_buffers; ++iter, ++i) > if (boost::asio::buffer_size(Buffer(*iter)) > 0) > return false; > return true; > } > > static void validate(const Buffers& buffer_sequence) > { > typename Buffers::const_iterator iter = buffer_sequence.begin(); > typename Buffers::const_iterator end = buffer_sequence.end(); > for (; iter != end; ++iter) > { > Buffer buffer(*iter); > boost::asio::buffer_cast<const void*>(buffer); > } > } > > static Buffer first(const Buffers& buffer_sequence) > { > typename Buffers::const_iterator iter = buffer_sequence.begin(); > typename Buffers::const_iterator end = buffer_sequence.end(); > for (; iter != end; ++iter) > { > Buffer buffer(*iter); > if (boost::asio::buffer_size(buffer) != 0) > return buffer; > } > return Buffer(); > } > >private: > native_buffer_type buffers_[max_buffers]; > std::size_t count_; > std::size_t total_buffer_size_; >}; > >template <typename Buffer> >class buffer_sequence_adapter<Buffer, boost::asio::mutable_buffers_1> > : buffer_sequence_adapter_base >{ >public: > explicit buffer_sequence_adapter( > const boost::asio::mutable_buffers_1& buffer_sequence) > { > init_native_buffer(buffer_, Buffer(buffer_sequence)); > total_buffer_size_ = boost::asio::buffer_size(buffer_sequence); > } > > native_buffer_type* buffers() > { > return &buffer_; > } > > std::size_t count() const > { > return 1; > } > > bool all_empty() const > { > return total_buffer_size_ == 0; > } > > static bool all_empty(const boost::asio::mutable_buffers_1& buffer_sequence) > { > return boost::asio::buffer_size(buffer_sequence) == 0; > } > > static void validate(const boost::asio::mutable_buffers_1& buffer_sequence) > { > boost::asio::buffer_cast<const void*>(buffer_sequence); > } > > static Buffer first(const boost::asio::mutable_buffers_1& buffer_sequence) > { > return Buffer(buffer_sequence); > } > >private: > native_buffer_type buffer_; > std::size_t total_buffer_size_; >}; > >template <typename Buffer> >class buffer_sequence_adapter<Buffer, boost::asio::const_buffers_1> > : buffer_sequence_adapter_base >{ >public: > explicit buffer_sequence_adapter( > const boost::asio::const_buffers_1& buffer_sequence) > { > init_native_buffer(buffer_, Buffer(buffer_sequence)); > total_buffer_size_ = boost::asio::buffer_size(buffer_sequence); > } > > native_buffer_type* buffers() > { > return &buffer_; > } > > std::size_t count() const > { > return 1; > } > > bool all_empty() const > { > return total_buffer_size_ == 0; > } > > static bool all_empty(const boost::asio::const_buffers_1& buffer_sequence) > { > return boost::asio::buffer_size(buffer_sequence) == 0; > } > > static void validate(const boost::asio::const_buffers_1& buffer_sequence) > { > boost::asio::buffer_cast<const void*>(buffer_sequence); > } > > static Buffer first(const boost::asio::const_buffers_1& buffer_sequence) > { > return Buffer(buffer_sequence); > } > >private: > native_buffer_type buffer_; > std::size_t total_buffer_size_; >}; > >template <typename Buffer, typename Elem> >class buffer_sequence_adapter<Buffer, boost::array<Elem, 2> > > : buffer_sequence_adapter_base >{ >public: > explicit buffer_sequence_adapter( > const boost::array<Elem, 2>& buffer_sequence) > { > init_native_buffer(buffers_[0], Buffer(buffer_sequence[0])); > init_native_buffer(buffers_[1], Buffer(buffer_sequence[1])); > total_buffer_size_ = boost::asio::buffer_size(buffer_sequence[0]) > + boost::asio::buffer_size(buffer_sequence[1]); > } > > native_buffer_type* buffers() > { > return buffers_; > } > > std::size_t count() const > { > return 2; > } > > bool all_empty() const > { > return total_buffer_size_ == 0; > } > > static bool all_empty(const boost::array<Elem, 2>& buffer_sequence) > { > return boost::asio::buffer_size(buffer_sequence[0]) == 0 > && boost::asio::buffer_size(buffer_sequence[1]) == 0; > } > > static void validate(const boost::array<Elem, 2>& buffer_sequence) > { > boost::asio::buffer_cast<const void*>(buffer_sequence[0]); > boost::asio::buffer_cast<const void*>(buffer_sequence[1]); > } > > static Buffer first(const boost::array<Elem, 2>& buffer_sequence) > { > return Buffer(boost::asio::buffer_size(buffer_sequence[0]) != 0 > ? buffer_sequence[0] : buffer_sequence[1]); > } > >private: > native_buffer_type buffers_[2]; > std::size_t total_buffer_size_; >}; > > > >template <typename Buffer, typename Elem> >class buffer_sequence_adapter<Buffer, std::array<Elem, 2> > > : buffer_sequence_adapter_base >{ >public: > explicit buffer_sequence_adapter( > const std::array<Elem, 2>& buffer_sequence) > { > init_native_buffer(buffers_[0], Buffer(buffer_sequence[0])); > init_native_buffer(buffers_[1], Buffer(buffer_sequence[1])); > total_buffer_size_ = boost::asio::buffer_size(buffer_sequence[0]) > + boost::asio::buffer_size(buffer_sequence[1]); > } > > native_buffer_type* buffers() > { > return buffers_; > } > > std::size_t count() const > { > return 2; > } > > bool all_empty() const > { > return total_buffer_size_ == 0; > } > > static bool all_empty(const std::array<Elem, 2>& buffer_sequence) > { > return boost::asio::buffer_size(buffer_sequence[0]) == 0 > && boost::asio::buffer_size(buffer_sequence[1]) == 0; > } > > static void validate(const std::array<Elem, 2>& buffer_sequence) > { > boost::asio::buffer_cast<const void*>(buffer_sequence[0]); > boost::asio::buffer_cast<const void*>(buffer_sequence[1]); > } > > static Buffer first(const std::array<Elem, 2>& buffer_sequence) > { > return Buffer(boost::asio::buffer_size(buffer_sequence[0]) != 0 > ? buffer_sequence[0] : buffer_sequence[1]); > } > >private: > native_buffer_type buffers_[2]; > std::size_t total_buffer_size_; >}; > > > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 380 "/usr/include/boost/asio/detail/buffer_sequence_adapter.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/buffer_sequence_adapter.ipp" 1 3 4 ># 383 "/usr/include/boost/asio/detail/buffer_sequence_adapter.hpp" 2 3 4 ># 28 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/reactive_null_buffers_op.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/reactive_null_buffers_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/reactive_null_buffers_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Handler> >class reactive_null_buffers_op : public reactor_op >{ >public: > struct ptr { Handler* h; void* v; reactive_null_buffers_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~reactive_null_buffers_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(reactive_null_buffers_op), *h); v = 0; } } }; > > reactive_null_buffers_op(Handler& handler) > : reactor_op(&reactive_null_buffers_op::do_perform, > &reactive_null_buffers_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static bool do_perform(reactor_op*) > { > return true; > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > reactive_null_buffers_op* o(static_cast<reactive_null_buffers_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, std::size_t> > handler(o->handler_, o->ec_, o->bytes_transferred_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 89 "/usr/include/boost/asio/detail/reactive_null_buffers_op.hpp" 2 3 4 ># 30 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_accept_op.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/reactive_socket_accept_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/socket_holder.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/socket_holder.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/socket_ops.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/socket_ops.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/shared_ptr.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/shared_ptr.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > >using std::shared_ptr; > > > > >} >} >} ># 22 "/usr/include/boost/asio/detail/socket_ops.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/weak_ptr.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/weak_ptr.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > >using std::weak_ptr; > > > > >} >} >} ># 24 "/usr/include/boost/asio/detail/socket_ops.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/socket_ops.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { >namespace socket_ops { > > >enum >{ > > user_set_non_blocking = 1, > > > internal_non_blocking = 2, > > > non_blocking = user_set_non_blocking | internal_non_blocking, > > > enable_connection_aborted = 4, > > > user_set_linger = 8, > > > stream_oriented = 16, > > > datagram_oriented = 32, > > > possible_dup = 64 >}; > >typedef unsigned char state_type; > >struct noop_deleter { void operator()(void*) {} }; >typedef shared_ptr<void> shared_cancel_token_type; >typedef weak_ptr<void> weak_cancel_token_type; > > > >inline socket_type accept(socket_type s, socket_addr_type* addr, > std::size_t* addrlen, boost::system::error_code& ec); > >inline socket_type sync_accept(socket_type s, > state_type state, socket_addr_type* addr, > std::size_t* addrlen, boost::system::error_code& ec); ># 84 "/usr/include/boost/asio/detail/socket_ops.hpp" 3 4 >inline bool non_blocking_accept(socket_type s, > state_type state, socket_addr_type* addr, std::size_t* addrlen, > boost::system::error_code& ec, socket_type& new_socket); > > > >inline int bind(socket_type s, const socket_addr_type* addr, > std::size_t addrlen, boost::system::error_code& ec); > >inline int close(socket_type s, state_type& state, > bool destruction, boost::system::error_code& ec); > >inline bool set_user_non_blocking(socket_type s, > state_type& state, bool value, boost::system::error_code& ec); > >inline bool set_internal_non_blocking(socket_type s, > state_type& state, bool value, boost::system::error_code& ec); > >inline int shutdown(socket_type s, > int what, boost::system::error_code& ec); > >inline int connect(socket_type s, const socket_addr_type* addr, > std::size_t addrlen, boost::system::error_code& ec); > >inline void sync_connect(socket_type s, const socket_addr_type* addr, > std::size_t addrlen, boost::system::error_code& ec); > >inline bool non_blocking_connect(socket_type s, > boost::system::error_code& ec); > >inline int socketpair(int af, int type, int protocol, > socket_type sv[2], boost::system::error_code& ec); > >inline bool sockatmark(socket_type s, boost::system::error_code& ec); > >inline size_t available(socket_type s, boost::system::error_code& ec); > >inline int listen(socket_type s, > int backlog, boost::system::error_code& ec); > > > > >typedef iovec buf; > > >inline void init_buf(buf& b, void* data, size_t size); > >inline void init_buf(buf& b, const void* data, size_t size); > >inline signed_size_type recv(socket_type s, buf* bufs, > size_t count, int flags, boost::system::error_code& ec); > >inline size_t sync_recv(socket_type s, state_type state, buf* bufs, > size_t count, int flags, bool all_empty, boost::system::error_code& ec); ># 148 "/usr/include/boost/asio/detail/socket_ops.hpp" 3 4 >inline bool non_blocking_recv(socket_type s, > buf* bufs, size_t count, int flags, bool is_stream, > boost::system::error_code& ec, size_t& bytes_transferred); > > > >inline signed_size_type recvfrom(socket_type s, buf* bufs, > size_t count, int flags, socket_addr_type* addr, > std::size_t* addrlen, boost::system::error_code& ec); > >inline size_t sync_recvfrom(socket_type s, state_type state, > buf* bufs, size_t count, int flags, socket_addr_type* addr, > std::size_t* addrlen, boost::system::error_code& ec); ># 170 "/usr/include/boost/asio/detail/socket_ops.hpp" 3 4 >inline bool non_blocking_recvfrom(socket_type s, > buf* bufs, size_t count, int flags, > socket_addr_type* addr, std::size_t* addrlen, > boost::system::error_code& ec, size_t& bytes_transferred); > > > >inline signed_size_type recvmsg(socket_type s, buf* bufs, > size_t count, int in_flags, int& out_flags, > boost::system::error_code& ec); > >inline size_t sync_recvmsg(socket_type s, state_type state, > buf* bufs, size_t count, int in_flags, int& out_flags, > boost::system::error_code& ec); ># 193 "/usr/include/boost/asio/detail/socket_ops.hpp" 3 4 >inline bool non_blocking_recvmsg(socket_type s, > buf* bufs, size_t count, int in_flags, int& out_flags, > boost::system::error_code& ec, size_t& bytes_transferred); > > > >inline signed_size_type send(socket_type s, const buf* bufs, > size_t count, int flags, boost::system::error_code& ec); > >inline size_t sync_send(socket_type s, state_type state, > const buf* bufs, size_t count, int flags, > bool all_empty, boost::system::error_code& ec); ># 214 "/usr/include/boost/asio/detail/socket_ops.hpp" 3 4 >inline bool non_blocking_send(socket_type s, > const buf* bufs, size_t count, int flags, > boost::system::error_code& ec, size_t& bytes_transferred); > > > >inline signed_size_type sendto(socket_type s, const buf* bufs, > size_t count, int flags, const socket_addr_type* addr, > std::size_t addrlen, boost::system::error_code& ec); > >inline size_t sync_sendto(socket_type s, state_type state, > const buf* bufs, size_t count, int flags, const socket_addr_type* addr, > std::size_t addrlen, boost::system::error_code& ec); > > > >inline bool non_blocking_sendto(socket_type s, > const buf* bufs, size_t count, int flags, > const socket_addr_type* addr, std::size_t addrlen, > boost::system::error_code& ec, size_t& bytes_transferred); > > > >inline socket_type socket(int af, int type, int protocol, > boost::system::error_code& ec); > >inline int setsockopt(socket_type s, state_type& state, > int level, int optname, const void* optval, > std::size_t optlen, boost::system::error_code& ec); > >inline int getsockopt(socket_type s, state_type state, > int level, int optname, void* optval, > size_t* optlen, boost::system::error_code& ec); > >inline int getpeername(socket_type s, socket_addr_type* addr, > std::size_t* addrlen, bool cached, boost::system::error_code& ec); > >inline int getsockname(socket_type s, socket_addr_type* addr, > std::size_t* addrlen, boost::system::error_code& ec); > >inline int ioctl(socket_type s, state_type& state, > int cmd, ioctl_arg_type* arg, boost::system::error_code& ec); > >inline int select(int nfds, fd_set* readfds, fd_set* writefds, > fd_set* exceptfds, timeval* timeout, boost::system::error_code& ec); > >inline int poll_read(socket_type s, > state_type state, boost::system::error_code& ec); > >inline int poll_write(socket_type s, > state_type state, boost::system::error_code& ec); > >inline int poll_connect(socket_type s, boost::system::error_code& ec); > > > >inline const char* inet_ntop(int af, const void* src, char* dest, > size_t length, unsigned long scope_id, boost::system::error_code& ec); > >inline int inet_pton(int af, const char* src, void* dest, > unsigned long* scope_id, boost::system::error_code& ec); > >inline int gethostname(char* name, > int namelen, boost::system::error_code& ec); > > > >inline boost::system::error_code getaddrinfo(const char* host, > const char* service, const addrinfo_type& hints, > addrinfo_type** result, boost::system::error_code& ec); > >inline boost::system::error_code background_getaddrinfo( > const weak_cancel_token_type& cancel_token, const char* host, > const char* service, const addrinfo_type& hints, > addrinfo_type** result, boost::system::error_code& ec); > >inline void freeaddrinfo(addrinfo_type* ai); > >inline boost::system::error_code getnameinfo( > const socket_addr_type* addr, std::size_t addrlen, > char* host, std::size_t hostlen, char* serv, > std::size_t servlen, int flags, boost::system::error_code& ec); > >inline boost::system::error_code sync_getnameinfo( > const socket_addr_type* addr, std::size_t addrlen, > char* host, std::size_t hostlen, char* serv, > std::size_t servlen, int sock_type, boost::system::error_code& ec); > >inline boost::system::error_code background_getnameinfo( > const weak_cancel_token_type& cancel_token, > const socket_addr_type* addr, std::size_t addrlen, > char* host, std::size_t hostlen, char* serv, > std::size_t servlen, int sock_type, boost::system::error_code& ec); > > > >inline u_long_type network_to_host_long(u_long_type value); > >inline u_long_type host_to_network_long(u_long_type value); > >inline u_short_type network_to_host_short(u_short_type value); > >inline u_short_type host_to_network_short(u_short_type value); > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 324 "/usr/include/boost/asio/detail/socket_ops.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 ># 1 "/usr/include/c++/4.9.0/cctype" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cctype" 3 4 ># 40 "/usr/include/c++/4.9.0/cctype" 3 ># 21 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cstdio" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdio" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdio" 3 ># 22 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 23 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 24 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cerrno" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cerrno" 3 4 ># 40 "/usr/include/c++/4.9.0/cerrno" 3 > ># 1 "/usr/include/errno.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/cerrno" 2 3 ># 25 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/socket_ops.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 2 3 4 ># 44 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 45 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { >namespace socket_ops { ># 66 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 >inline void clear_last_error() >{ > > > > (*__errno_location ()) = 0; > >} > > > >template <typename ReturnType> >inline ReturnType error_wrapper(ReturnType return_value, > boost::system::error_code& ec) >{ > > > > > ec = boost::system::error_code((*__errno_location ()), > boost::asio::error::get_system_category()); > > return return_value; >} > >template <typename SockLenType> >inline socket_type call_accept(SockLenType msghdr::*, > socket_type s, socket_addr_type* addr, std::size_t* addrlen) >{ > SockLenType tmp_addrlen = addrlen ? (SockLenType)*addrlen : 0; > socket_type result = ::accept(s, addr, addrlen ? &tmp_addrlen : 0); > if (addrlen) > *addrlen = (std::size_t)tmp_addrlen; > return result; >} > >socket_type accept(socket_type s, socket_addr_type* addr, > std::size_t* addrlen, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return invalid_socket; > } > > clear_last_error(); > > socket_type new_s = error_wrapper(call_accept( > &msghdr::msg_namelen, s, addr, addrlen), ec); > if (new_s == invalid_socket) > return new_s; ># 129 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > ec = boost::system::error_code(); > return new_s; >} > >socket_type sync_accept(socket_type s, state_type state, > socket_addr_type* addr, std::size_t* addrlen, boost::system::error_code& ec) >{ > > for (;;) > { > > socket_type new_socket = socket_ops::accept(s, addr, addrlen, ec); > > > if (new_socket != invalid_socket) > return new_socket; > > > if (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again) > { > if (state & user_set_non_blocking) > return invalid_socket; > > } > else if (ec == boost::asio::error::connection_aborted) > { > if (state & enable_connection_aborted) > return invalid_socket; > > } > > else if (ec.value() == 71) > { > if (state & enable_connection_aborted) > return invalid_socket; > > } > > else > return invalid_socket; > > > if (socket_ops::poll_read(s, 0, ec) < 0) > return invalid_socket; > } >} ># 224 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 >bool non_blocking_accept(socket_type s, > state_type state, socket_addr_type* addr, std::size_t* addrlen, > boost::system::error_code& ec, socket_type& new_socket) >{ > for (;;) > { > > new_socket = socket_ops::accept(s, addr, addrlen, ec); > > > if (new_socket != invalid_socket) > return true; > > > if (ec == boost::asio::error::interrupted) > continue; > > > if (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again) > { > if (state & user_set_non_blocking) > return true; > > } > else if (ec == boost::asio::error::connection_aborted) > { > if (state & enable_connection_aborted) > return true; > > } > > else if (ec.value() == 71) > { > if (state & enable_connection_aborted) > return true; > > } > > else > return true; > > return false; > } >} > > > >template <typename SockLenType> >inline int call_bind(SockLenType msghdr::*, > socket_type s, const socket_addr_type* addr, std::size_t addrlen) >{ > return ::bind(s, addr, (SockLenType)addrlen); >} > >int bind(socket_type s, const socket_addr_type* addr, > std::size_t addrlen, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } > > clear_last_error(); > int result = error_wrapper(call_bind( > &msghdr::msg_namelen, s, addr, addrlen), ec); > if (result == 0) > ec = boost::system::error_code(); > return result; >} > >int close(socket_type s, state_type& state, > bool destruction, boost::system::error_code& ec) >{ > int result = 0; > if (s != invalid_socket) > { > > > > if (destruction && (state & user_set_linger)) > { > ::linger opt; > opt.l_onoff = 0; > opt.l_linger = 0; > boost::system::error_code ignored_ec; > socket_ops::setsockopt(s, state, 1, > 13, &opt, sizeof(opt), ignored_ec); > } > > clear_last_error(); > > > > result = error_wrapper(::close(s), ec); > > > if (result != 0 > && (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again)) > { ># 341 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > ioctl_arg_type arg = 0; > ::ioctl(s, 0x5421, &arg); > > > state &= ~non_blocking; > > clear_last_error(); > > > > result = error_wrapper(::close(s), ec); > > } > } > > if (result == 0) > ec = boost::system::error_code(); > return result; >} > >bool set_user_non_blocking(socket_type s, > state_type& state, bool value, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return false; > } > > clear_last_error(); ># 383 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > ioctl_arg_type arg = (value ? 1 : 0); > int result = error_wrapper(::ioctl(s, 0x5421, &arg), ec); > > > if (result >= 0) > { > ec = boost::system::error_code(); > if (value) > state |= user_set_non_blocking; > else > { > > > > state &= ~(user_set_non_blocking | internal_non_blocking); > } > return true; > } > > return false; >} > >bool set_internal_non_blocking(socket_type s, > state_type& state, bool value, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return false; > } > > if (!value && (state & user_set_non_blocking)) > { > > > > ec = boost::asio::error::invalid_argument; > return false; > } > > clear_last_error(); ># 436 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > ioctl_arg_type arg = (value ? 1 : 0); > int result = error_wrapper(::ioctl(s, 0x5421, &arg), ec); > > > if (result >= 0) > { > ec = boost::system::error_code(); > if (value) > state |= internal_non_blocking; > else > state &= ~internal_non_blocking; > return true; > } > > return false; >} > >int shutdown(socket_type s, int what, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } > > clear_last_error(); > int result = error_wrapper(::shutdown(s, what), ec); > if (result == 0) > ec = boost::system::error_code(); > return result; >} > >template <typename SockLenType> >inline int call_connect(SockLenType msghdr::*, > socket_type s, const socket_addr_type* addr, std::size_t addrlen) >{ > return ::connect(s, addr, (SockLenType)addrlen); >} > >int connect(socket_type s, const socket_addr_type* addr, > std::size_t addrlen, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } > > clear_last_error(); > int result = error_wrapper(call_connect( > &msghdr::msg_namelen, s, addr, addrlen), ec); > if (result == 0) > ec = boost::system::error_code(); > > else if (ec == boost::asio::error::try_again) > ec = boost::asio::error::no_buffer_space; > > return result; >} > >void sync_connect(socket_type s, const socket_addr_type* addr, > std::size_t addrlen, boost::system::error_code& ec) >{ > > socket_ops::connect(s, addr, addrlen, ec); > if (ec != boost::asio::error::in_progress > && ec != boost::asio::error::would_block) > { > > return; > } > > > if (socket_ops::poll_connect(s, ec) < 0) > return; > > > int connect_error = 0; > size_t connect_error_len = sizeof(connect_error); > if (socket_ops::getsockopt(s, 0, 1, 4, > &connect_error, &connect_error_len, ec) == socket_error_retval) > return; > > > ec = boost::system::error_code(connect_error, > boost::asio::error::get_system_category()); >} > >bool non_blocking_connect(socket_type s, boost::system::error_code& ec) >{ ># 544 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > pollfd fds; > fds.fd = s; > fds.events = 0x004; > fds.revents = 0; > int ready = ::poll(&fds, 1, 0); > > > > if (ready == 0) > { > > return false; > } > > > int connect_error = 0; > size_t connect_error_len = sizeof(connect_error); > if (socket_ops::getsockopt(s, 0, 1, 4, > &connect_error, &connect_error_len, ec) == 0) > { > if (connect_error) > { > ec = boost::system::error_code(connect_error, > boost::asio::error::get_system_category()); > } > else > ec = boost::system::error_code(); > } > > return true; >} > >int socketpair(int af, int type, int protocol, > socket_type sv[2], boost::system::error_code& ec) >{ ># 587 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > clear_last_error(); > int result = error_wrapper(::socketpair(af, type, protocol, sv), ec); > if (result == 0) > ec = boost::system::error_code(); > return result; > >} > >bool sockatmark(socket_type s, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return false; > } > > > ioctl_arg_type value = 0; > > > > int result = error_wrapper(::ioctl(s, 0x8905, &value), ec); > > if (result == 0) > ec = boost::system::error_code(); > > if (ec.value() == 25) > ec = boost::asio::error::not_socket; > > > > > > > > return ec ? false : value != 0; >} > >size_t available(socket_type s, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return 0; > } > > ioctl_arg_type value = 0; > > > > int result = error_wrapper(::ioctl(s, 0x541B, &value), ec); > > if (result == 0) > ec = boost::system::error_code(); > > if (ec.value() == 25) > ec = boost::asio::error::not_socket; > > > return ec ? static_cast<size_t>(0) : static_cast<size_t>(value); >} > >int listen(socket_type s, int backlog, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } > > clear_last_error(); > int result = error_wrapper(::listen(s, backlog), ec); > if (result == 0) > ec = boost::system::error_code(); > return result; >} > >inline void init_buf_iov_base(void*& base, void* addr) >{ > base = addr; >} > >template <typename T> >inline void init_buf_iov_base(T& base, void* addr) >{ > base = static_cast<T>(addr); >} > > > > >typedef iovec buf; > > >void init_buf(buf& b, void* data, size_t size) >{ > > > > > init_buf_iov_base(b.iov_base, data); > b.iov_len = size; > >} > >void init_buf(buf& b, const void* data, size_t size) >{ > > > > > init_buf_iov_base(b.iov_base, const_cast<void*>(data)); > b.iov_len = size; > >} > >inline void init_msghdr_msg_name(void*& name, socket_addr_type* addr) >{ > name = addr; >} > >inline void init_msghdr_msg_name(void*& name, const socket_addr_type* addr) >{ > name = const_cast<socket_addr_type*>(addr); >} > >template <typename T> >inline void init_msghdr_msg_name(T& name, socket_addr_type* addr) >{ > name = reinterpret_cast<T>(addr); >} > >template <typename T> >inline void init_msghdr_msg_name(T& name, const socket_addr_type* addr) >{ > name = reinterpret_cast<T>(const_cast<socket_addr_type*>(addr)); >} > >signed_size_type recv(socket_type s, buf* bufs, size_t count, > int flags, boost::system::error_code& ec) >{ > clear_last_error(); ># 745 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > msghdr msg = msghdr(); > msg.msg_iov = bufs; > msg.msg_iovlen = static_cast<int>(count); > signed_size_type result = error_wrapper(::recvmsg(s, &msg, flags), ec); > if (result >= 0) > ec = boost::system::error_code(); > return result; > >} > >size_t sync_recv(socket_type s, state_type state, buf* bufs, > size_t count, int flags, bool all_empty, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return 0; > } > > > if (all_empty && (state & stream_oriented)) > { > ec = boost::system::error_code(); > return 0; > } > > > for (;;) > { > > signed_size_type bytes = socket_ops::recv(s, bufs, count, flags, ec); > > > if (bytes > 0) > return bytes; > > > if ((state & stream_oriented) && bytes == 0) > { > ec = boost::asio::error::eof; > return 0; > } > > > if ((state & user_set_non_blocking) > || (ec != boost::asio::error::would_block > && ec != boost::asio::error::try_again)) > return 0; > > > if (socket_ops::poll_read(s, 0, ec) < 0) > return 0; > } >} ># 830 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 >bool non_blocking_recv(socket_type s, > buf* bufs, size_t count, int flags, bool is_stream, > boost::system::error_code& ec, size_t& bytes_transferred) >{ > for (;;) > { > > signed_size_type bytes = socket_ops::recv(s, bufs, count, flags, ec); > > > if (is_stream && bytes == 0) > { > ec = boost::asio::error::eof; > return true; > } > > > if (ec == boost::asio::error::interrupted) > continue; > > > if (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again) > return false; > > > if (bytes >= 0) > { > ec = boost::system::error_code(); > bytes_transferred = bytes; > } > else > bytes_transferred = 0; > > return true; > } >} > > > >signed_size_type recvfrom(socket_type s, buf* bufs, size_t count, > int flags, socket_addr_type* addr, std::size_t* addrlen, > boost::system::error_code& ec) >{ > clear_last_error(); ># 893 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > msghdr msg = msghdr(); > init_msghdr_msg_name(msg.msg_name, addr); > msg.msg_namelen = static_cast<int>(*addrlen); > msg.msg_iov = bufs; > msg.msg_iovlen = static_cast<int>(count); > signed_size_type result = error_wrapper(::recvmsg(s, &msg, flags), ec); > *addrlen = msg.msg_namelen; > if (result >= 0) > ec = boost::system::error_code(); > return result; > >} > >size_t sync_recvfrom(socket_type s, state_type state, buf* bufs, > size_t count, int flags, socket_addr_type* addr, > std::size_t* addrlen, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return 0; > } > > > for (;;) > { > > signed_size_type bytes = socket_ops::recvfrom( > s, bufs, count, flags, addr, addrlen, ec); > > > if (bytes >= 0) > return bytes; > > > if ((state & user_set_non_blocking) > || (ec != boost::asio::error::would_block > && ec != boost::asio::error::try_again)) > return 0; > > > if (socket_ops::poll_read(s, 0, ec) < 0) > return 0; > } >} ># 961 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 >bool non_blocking_recvfrom(socket_type s, > buf* bufs, size_t count, int flags, > socket_addr_type* addr, std::size_t* addrlen, > boost::system::error_code& ec, size_t& bytes_transferred) >{ > for (;;) > { > > signed_size_type bytes = socket_ops::recvfrom( > s, bufs, count, flags, addr, addrlen, ec); > > > if (ec == boost::asio::error::interrupted) > continue; > > > if (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again) > return false; > > > if (bytes >= 0) > { > ec = boost::system::error_code(); > bytes_transferred = bytes; > } > else > bytes_transferred = 0; > > return true; > } >} > > > >signed_size_type recvmsg(socket_type s, buf* bufs, size_t count, > int in_flags, int& out_flags, boost::system::error_code& ec) >{ > clear_last_error(); > > > > > msghdr msg = msghdr(); > msg.msg_iov = bufs; > msg.msg_iovlen = static_cast<int>(count); > signed_size_type result = error_wrapper(::recvmsg(s, &msg, in_flags), ec); > if (result >= 0) > { > ec = boost::system::error_code(); > out_flags = msg.msg_flags; > } > else > out_flags = 0; > return result; > >} > >size_t sync_recvmsg(socket_type s, state_type state, > buf* bufs, size_t count, int in_flags, int& out_flags, > boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return 0; > } > > > for (;;) > { > > signed_size_type bytes = socket_ops::recvmsg( > s, bufs, count, in_flags, out_flags, ec); > > > if (bytes >= 0) > return bytes; > > > if ((state & user_set_non_blocking) > || (ec != boost::asio::error::would_block > && ec != boost::asio::error::try_again)) > return 0; > > > if (socket_ops::poll_read(s, 0, ec) < 0) > return 0; > } >} ># 1074 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 >bool non_blocking_recvmsg(socket_type s, > buf* bufs, size_t count, int in_flags, int& out_flags, > boost::system::error_code& ec, size_t& bytes_transferred) >{ > for (;;) > { > > signed_size_type bytes = socket_ops::recvmsg( > s, bufs, count, in_flags, out_flags, ec); > > > if (ec == boost::asio::error::interrupted) > continue; > > > if (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again) > return false; > > > if (bytes >= 0) > { > ec = boost::system::error_code(); > bytes_transferred = bytes; > } > else > bytes_transferred = 0; > > return true; > } >} > > > >signed_size_type send(socket_type s, const buf* bufs, size_t count, > int flags, boost::system::error_code& ec) >{ > clear_last_error(); ># 1128 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > msghdr msg = msghdr(); > msg.msg_iov = const_cast<buf*>(bufs); > msg.msg_iovlen = static_cast<int>(count); > > flags |= MSG_NOSIGNAL; > > signed_size_type result = error_wrapper(::sendmsg(s, &msg, flags), ec); > if (result >= 0) > ec = boost::system::error_code(); > return result; > >} > >size_t sync_send(socket_type s, state_type state, const buf* bufs, > size_t count, int flags, bool all_empty, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return 0; > } > > > if (all_empty && (state & stream_oriented)) > { > ec = boost::system::error_code(); > return 0; > } > > > for (;;) > { > > signed_size_type bytes = socket_ops::send(s, bufs, count, flags, ec); > > > if (bytes >= 0) > return bytes; > > > if ((state & user_set_non_blocking) > || (ec != boost::asio::error::would_block > && ec != boost::asio::error::try_again)) > return 0; > > > if (socket_ops::poll_write(s, 0, ec) < 0) > return 0; > } >} ># 1201 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 >bool non_blocking_send(socket_type s, > const buf* bufs, size_t count, int flags, > boost::system::error_code& ec, size_t& bytes_transferred) >{ > for (;;) > { > > signed_size_type bytes = socket_ops::send(s, bufs, count, flags, ec); > > > if (ec == boost::asio::error::interrupted) > continue; > > > if (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again) > return false; > > > if (bytes >= 0) > { > ec = boost::system::error_code(); > bytes_transferred = bytes; > } > else > bytes_transferred = 0; > > return true; > } >} > > > >signed_size_type sendto(socket_type s, const buf* bufs, size_t count, > int flags, const socket_addr_type* addr, std::size_t addrlen, > boost::system::error_code& ec) >{ > clear_last_error(); ># 1255 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > msghdr msg = msghdr(); > init_msghdr_msg_name(msg.msg_name, addr); > msg.msg_namelen = static_cast<int>(addrlen); > msg.msg_iov = const_cast<buf*>(bufs); > msg.msg_iovlen = static_cast<int>(count); > > flags |= MSG_NOSIGNAL; > > signed_size_type result = error_wrapper(::sendmsg(s, &msg, flags), ec); > if (result >= 0) > ec = boost::system::error_code(); > return result; > >} > >size_t sync_sendto(socket_type s, state_type state, const buf* bufs, > size_t count, int flags, const socket_addr_type* addr, > std::size_t addrlen, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return 0; > } > > > for (;;) > { > > signed_size_type bytes = socket_ops::sendto( > s, bufs, count, flags, addr, addrlen, ec); > > > if (bytes >= 0) > return bytes; > > > if ((state & user_set_non_blocking) > || (ec != boost::asio::error::would_block > && ec != boost::asio::error::try_again)) > return 0; > > > if (socket_ops::poll_write(s, 0, ec) < 0) > return 0; > } >} > > > >bool non_blocking_sendto(socket_type s, > const buf* bufs, size_t count, int flags, > const socket_addr_type* addr, std::size_t addrlen, > boost::system::error_code& ec, size_t& bytes_transferred) >{ > for (;;) > { > > signed_size_type bytes = socket_ops::sendto( > s, bufs, count, flags, addr, addrlen, ec); > > > if (ec == boost::asio::error::interrupted) > continue; > > > if (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again) > return false; > > > if (bytes >= 0) > { > ec = boost::system::error_code(); > bytes_transferred = bytes; > } > else > bytes_transferred = 0; > > return true; > } >} > > > >socket_type socket(int af, int type, int protocol, > boost::system::error_code& ec) >{ > clear_last_error(); ># 1379 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > int s = error_wrapper(::socket(af, type, protocol), ec); > if (s >= 0) > ec = boost::system::error_code(); > return s; > >} > >template <typename SockLenType> >inline int call_setsockopt(SockLenType msghdr::*, > socket_type s, int level, int optname, > const void* optval, std::size_t optlen) >{ > return ::setsockopt(s, level, optname, > (const char*)optval, (SockLenType)optlen); >} > >int setsockopt(socket_type s, state_type& state, int level, int optname, > const void* optval, std::size_t optlen, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } > > if (level == custom_socket_option_level && optname == always_fail_option) > { > ec = boost::asio::error::invalid_argument; > return socket_error_retval; > } > > if (level == custom_socket_option_level > && optname == enable_connection_aborted_option) > { > if (optlen != sizeof(int)) > { > ec = boost::asio::error::invalid_argument; > return socket_error_retval; > } > > if (*static_cast<const int*>(optval)) > state |= enable_connection_aborted; > else > state &= ~enable_connection_aborted; > ec = boost::system::error_code(); > return 0; > } > > if (level == 1 && optname == 13) > state |= user_set_linger; ># 1448 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > clear_last_error(); > int result = error_wrapper(call_setsockopt(&msghdr::msg_namelen, > s, level, optname, optval, optlen), ec); > if (result == 0) > { > ec = boost::system::error_code(); ># 1466 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > } > > return result; > >} > >template <typename SockLenType> >inline int call_getsockopt(SockLenType msghdr::*, > socket_type s, int level, int optname, > void* optval, std::size_t* optlen) >{ > SockLenType tmp_optlen = (SockLenType)*optlen; > int result = ::getsockopt(s, level, optname, (char*)optval, &tmp_optlen); > *optlen = (std::size_t)tmp_optlen; > return result; >} > >int getsockopt(socket_type s, state_type state, int level, int optname, > void* optval, size_t* optlen, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } > > if (level == custom_socket_option_level && optname == always_fail_option) > { > ec = boost::asio::error::invalid_argument; > return socket_error_retval; > } > > if (level == custom_socket_option_level > && optname == enable_connection_aborted_option) > { > if (*optlen != sizeof(int)) > { > ec = boost::asio::error::invalid_argument; > return socket_error_retval; > } > > *static_cast<int*>(optval) = (state & enable_connection_aborted) ? 1 : 0; > ec = boost::system::error_code(); > return 0; > } ># 1561 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > clear_last_error(); > int result = error_wrapper(call_getsockopt(&msghdr::msg_namelen, > s, level, optname, optval, optlen), ec); > > if (result == 0 && level == 1 && *optlen == sizeof(int) > && (optname == 7 || optname == 8)) > { > > > > > > *static_cast<int*>(optval) /= 2; > } > > if (result == 0) > ec = boost::system::error_code(); > return result; > >} > >template <typename SockLenType> >inline int call_getpeername(SockLenType msghdr::*, > socket_type s, socket_addr_type* addr, std::size_t* addrlen) >{ > SockLenType tmp_addrlen = (SockLenType)*addrlen; > int result = ::getpeername(s, addr, &tmp_addrlen); > *addrlen = (std::size_t)tmp_addrlen; > return result; >} > >int getpeername(socket_type s, socket_addr_type* addr, > std::size_t* addrlen, bool cached, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } ># 1623 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > (void)cached; > > > clear_last_error(); > int result = error_wrapper(call_getpeername( > &msghdr::msg_namelen, s, addr, addrlen), ec); > if (result == 0) > ec = boost::system::error_code(); > return result; >} > >template <typename SockLenType> >inline int call_getsockname(SockLenType msghdr::*, > socket_type s, socket_addr_type* addr, std::size_t* addrlen) >{ > SockLenType tmp_addrlen = (SockLenType)*addrlen; > int result = ::getsockname(s, addr, &tmp_addrlen); > *addrlen = (std::size_t)tmp_addrlen; > return result; >} > >int getsockname(socket_type s, socket_addr_type* addr, > std::size_t* addrlen, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } > > clear_last_error(); > int result = error_wrapper(call_getsockname( > &msghdr::msg_namelen, s, addr, addrlen), ec); > if (result == 0) > ec = boost::system::error_code(); > return result; >} > >int ioctl(socket_type s, state_type& state, int cmd, > ioctl_arg_type* arg, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } > > clear_last_error(); > > > > > > > > int result = error_wrapper(::ioctl(s, cmd, arg), ec); > > if (result >= 0) > { > ec = boost::system::error_code(); > > > > > > > if (cmd == static_cast<int>(0x5421)) > { > if (*arg) > { > state |= user_set_non_blocking; > } > else > { > > > > state &= ~(user_set_non_blocking | internal_non_blocking); > } > } > } > > return result; >} > >int select(int nfds, fd_set* readfds, fd_set* writefds, > fd_set* exceptfds, timeval* timeout, boost::system::error_code& ec) >{ > clear_last_error(); ># 1741 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > int result = error_wrapper(::select(nfds, readfds, > writefds, exceptfds, timeout), ec); > if (result >= 0) > ec = boost::system::error_code(); > return result; > >} > >int poll_read(socket_type s, state_type state, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } ># 1772 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > pollfd fds; > fds.fd = s; > fds.events = 0x001; > fds.revents = 0; > int timeout = (state & user_set_non_blocking) ? 0 : -1; > clear_last_error(); > int result = error_wrapper(::poll(&fds, 1, timeout), ec); > > > > if (result == 0) > ec = (state & user_set_non_blocking) > ? boost::asio::error::would_block : boost::system::error_code(); > else if (result > 0) > ec = boost::system::error_code(); > return result; >} > >int poll_write(socket_type s, state_type state, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } ># 1813 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > pollfd fds; > fds.fd = s; > fds.events = 0x004; > fds.revents = 0; > int timeout = (state & user_set_non_blocking) ? 0 : -1; > clear_last_error(); > int result = error_wrapper(::poll(&fds, 1, timeout), ec); > > > > if (result == 0) > ec = (state & user_set_non_blocking) > ? boost::asio::error::would_block : boost::system::error_code(); > else if (result > 0) > ec = boost::system::error_code(); > return result; >} > >int poll_connect(socket_type s, boost::system::error_code& ec) >{ > if (s == invalid_socket) > { > ec = boost::asio::error::bad_descriptor; > return socket_error_retval; > } ># 1857 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > pollfd fds; > fds.fd = s; > fds.events = 0x004; > fds.revents = 0; > clear_last_error(); > int result = error_wrapper(::poll(&fds, 1, -1), ec); > if (result >= 0) > ec = boost::system::error_code(); > return result; > > > >} > > > >const char* inet_ntop(int af, const void* src, char* dest, size_t length, > unsigned long scope_id, boost::system::error_code& ec) >{ > clear_last_error(); ># 1967 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > const char* result = error_wrapper(::inet_ntop( > af, src, dest, static_cast<int>(length)), ec); > if (result == 0 && !ec) > ec = boost::asio::error::invalid_argument; > if (result != 0 && af == 10 && scope_id != 0) > { > using namespace std; > char if_name[16 + 1] = "%"; > const in6_addr_type* ipv6_address = static_cast<const in6_addr_type*>(src); > bool is_link_local = ((ipv6_address->__in6_u.__u6_addr8[0] == 0xfe) > && ((ipv6_address->__in6_u.__u6_addr8[1] & 0xc0) == 0x80)); > if (!is_link_local > || if_indextoname(static_cast<unsigned>(scope_id), if_name + 1) == 0) > sprintf(if_name + 1, "%lu", scope_id); > strcat(dest, if_name); > } > return result; > >} > >int inet_pton(int af, const char* src, void* dest, > unsigned long* scope_id, boost::system::error_code& ec) >{ > clear_last_error(); ># 2196 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > int result = error_wrapper(::inet_pton(af, src, dest), ec); > if (result <= 0 && !ec) > ec = boost::asio::error::invalid_argument; > if (result > 0 && af == 10 && scope_id) > { > using namespace std; > *scope_id = 0; > if (const char* if_name = strchr(src, '%')) > { > in6_addr_type* ipv6_address = static_cast<in6_addr_type*>(dest); > bool is_link_local = ((ipv6_address->__in6_u.__u6_addr8[0] == 0xfe) > && ((ipv6_address->__in6_u.__u6_addr8[1] & 0xc0) == 0x80)); > if (is_link_local) > *scope_id = if_nametoindex(if_name + 1); > if (*scope_id == 0) > *scope_id = atoi(if_name + 1); > } > } > return result; > >} > >int gethostname(char* name, int namelen, boost::system::error_code& ec) >{ > clear_last_error(); ># 2251 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > int result = error_wrapper(::gethostname(name, namelen), ec); > > > > > return result; > >} ># 3107 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 >inline boost::system::error_code translate_addrinfo_error(int error) >{ > switch (error) > { > case 0: > return boost::system::error_code(); > case -3: > return boost::asio::error::host_not_found_try_again; > case -1: > return boost::asio::error::invalid_argument; > case -4: > return boost::asio::error::no_recovery; > case -6: > return boost::asio::error::address_family_not_supported; > case -10: > return boost::asio::error::no_memory; > case -2: > > case -9: > > > case -5: > > return boost::asio::error::host_not_found; > case -8: > return boost::asio::error::service_not_found; > case -7: > return boost::asio::error::socket_type_not_supported; > default: > > > > > return boost::system::error_code( > (*__errno_location ()), boost::asio::error::get_system_category()); > > } >} > >boost::system::error_code getaddrinfo(const char* host, > const char* service, const addrinfo_type& hints, > addrinfo_type** result, boost::system::error_code& ec) >{ > host = (host && *host) ? host : 0; > service = (service && *service) ? service : 0; > clear_last_error(); ># 3177 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > int error = ::getaddrinfo(host, service, &hints, result); > return ec = translate_addrinfo_error(error); > >} > >boost::system::error_code background_getaddrinfo( > const weak_cancel_token_type& cancel_token, const char* host, > const char* service, const addrinfo_type& hints, > addrinfo_type** result, boost::system::error_code& ec) >{ > if (cancel_token.expired()) > ec = boost::asio::error::operation_aborted; > else > socket_ops::getaddrinfo(host, service, hints, result, ec); > return ec; >} > >void freeaddrinfo(addrinfo_type* ai) >{ ># 3216 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > ::freeaddrinfo(ai); > >} > >boost::system::error_code getnameinfo(const socket_addr_type* addr, > std::size_t addrlen, char* host, std::size_t hostlen, > char* serv, std::size_t servlen, int flags, boost::system::error_code& ec) >{ ># 3261 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > clear_last_error(); > int error = ::getnameinfo(addr, addrlen, host, hostlen, serv, servlen, flags); > return ec = translate_addrinfo_error(error); > >} > >boost::system::error_code sync_getnameinfo( > const socket_addr_type* addr, std::size_t addrlen, > char* host, std::size_t hostlen, char* serv, > std::size_t servlen, int sock_type, boost::system::error_code& ec) >{ > > > int flags = (sock_type == SOCK_DGRAM) ? 16 : 0; > socket_ops::getnameinfo(addr, addrlen, host, > hostlen, serv, servlen, flags, ec); > if (ec) > { > socket_ops::getnameinfo(addr, addrlen, host, hostlen, > serv, servlen, flags | 2, ec); > } > > return ec; >} > >boost::system::error_code background_getnameinfo( > const weak_cancel_token_type& cancel_token, > const socket_addr_type* addr, std::size_t addrlen, > char* host, std::size_t hostlen, char* serv, > std::size_t servlen, int sock_type, boost::system::error_code& ec) >{ > if (cancel_token.expired()) > { > ec = boost::asio::error::operation_aborted; > } > else > { > > > int flags = (sock_type == SOCK_DGRAM) ? 16 : 0; > socket_ops::getnameinfo(addr, addrlen, host, > hostlen, serv, servlen, flags, ec); > if (ec) > { > socket_ops::getnameinfo(addr, addrlen, host, hostlen, > serv, servlen, flags | 2, ec); > } > } > > return ec; >} > > > >u_long_type network_to_host_long(u_long_type value) >{ ># 3325 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > return __bswap_32 (value); > >} > >u_long_type host_to_network_long(u_long_type value) >{ ># 3340 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 3 4 > return __bswap_32 (value); > >} > >u_short_type network_to_host_short(u_short_type value) >{ > > > > > > > return (__extension__ ({ unsigned short int __v, __x = (unsigned short int) (value); if (__builtin_constant_p (__x)) __v = ((unsigned short int) ((((__x) >> 8) & 0xff) | (((__x) & 0xff) << 8))); else __asm__ ("rorw $8, %w0" : "=r" (__v) : "0" (__x) : "cc"); __v; })); > >} > >u_short_type host_to_network_short(u_short_type value) >{ > > > > > > > > return (__extension__ ({ unsigned short int __v, __x = (unsigned short int) (value); if (__builtin_constant_p (__x)) __v = ((unsigned short int) ((((__x) >> 8) & 0xff) | (((__x) & 0xff) << 8))); else __asm__ ("rorw $8, %w0" : "=r" (__v) : "0" (__x) : "cc"); __v; })); > >} > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 3375 "/usr/include/boost/asio/detail/impl/socket_ops.ipp" 2 3 4 ># 327 "/usr/include/boost/asio/detail/socket_ops.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/detail/socket_holder.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/socket_holder.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > >class socket_holder > : private noncopyable >{ >public: > > socket_holder() > : socket_(invalid_socket) > { > } > > > explicit socket_holder(socket_type s) > : socket_(s) > { > } > > > ~socket_holder() > { > if (socket_ != invalid_socket) > { > boost::system::error_code ec; > socket_ops::state_type state = 0; > socket_ops::close(socket_, state, true, ec); > } > } > > > socket_type get() const > { > return socket_; > } > > > void reset() > { > if (socket_ != invalid_socket) > { > boost::system::error_code ec; > socket_ops::state_type state = 0; > socket_ops::close(socket_, state, true, ec); > socket_ = invalid_socket; > } > } > > > void reset(socket_type s) > { > reset(); > socket_ = s; > } > > > socket_type release() > { > socket_type tmp = socket_; > socket_ = invalid_socket; > return tmp; > } > >private: > > socket_type socket_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 99 "/usr/include/boost/asio/detail/socket_holder.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/detail/reactive_socket_accept_op.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/reactive_socket_accept_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Socket, typename Protocol> >class reactive_socket_accept_op_base : public reactor_op >{ >public: > reactive_socket_accept_op_base(socket_type socket, > socket_ops::state_type state, Socket& peer, const Protocol& protocol, > typename Protocol::endpoint* peer_endpoint, func_type complete_func) > : reactor_op(&reactive_socket_accept_op_base::do_perform, complete_func), > socket_(socket), > state_(state), > peer_(peer), > protocol_(protocol), > peer_endpoint_(peer_endpoint) > { > } > > static bool do_perform(reactor_op* base) > { > reactive_socket_accept_op_base* o( > static_cast<reactive_socket_accept_op_base*>(base)); > > std::size_t addrlen = o->peer_endpoint_ ? o->peer_endpoint_->capacity() : 0; > socket_type new_socket = invalid_socket; > bool result = socket_ops::non_blocking_accept(o->socket_, > o->state_, o->peer_endpoint_ ? o->peer_endpoint_->data() : 0, > o->peer_endpoint_ ? &addrlen : 0, o->ec_, new_socket); > > > if (new_socket != invalid_socket) > { > socket_holder new_socket_holder(new_socket); > if (o->peer_endpoint_) > o->peer_endpoint_->resize(addrlen); > if (!o->peer_.assign(o->protocol_, new_socket, o->ec_)) > new_socket_holder.release(); > } > > return result; > } > >private: > socket_type socket_; > socket_ops::state_type state_; > Socket& peer_; > Protocol protocol_; > typename Protocol::endpoint* peer_endpoint_; >}; > >template <typename Socket, typename Protocol, typename Handler> >class reactive_socket_accept_op : > public reactive_socket_accept_op_base<Socket, Protocol> >{ >public: > struct ptr { Handler* h; void* v; reactive_socket_accept_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~reactive_socket_accept_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(reactive_socket_accept_op), *h); v = 0; } } }; > > reactive_socket_accept_op(socket_type socket, > socket_ops::state_type state, Socket& peer, const Protocol& protocol, > typename Protocol::endpoint* peer_endpoint, Handler& handler) > : reactive_socket_accept_op_base<Socket, Protocol>(socket, state, peer, > protocol, peer_endpoint, &reactive_socket_accept_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > reactive_socket_accept_op* o(static_cast<reactive_socket_accept_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder1<Handler, boost::system::error_code> > handler(o->handler_, o->ec_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 137 "/usr/include/boost/asio/detail/reactive_socket_accept_op.hpp" 2 3 4 ># 31 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_connect_op.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/reactive_socket_connect_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/reactive_socket_connect_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class reactive_socket_connect_op_base : public reactor_op >{ >public: > reactive_socket_connect_op_base(socket_type socket, func_type complete_func) > : reactor_op(&reactive_socket_connect_op_base::do_perform, complete_func), > socket_(socket) > { > } > > static bool do_perform(reactor_op* base) > { > reactive_socket_connect_op_base* o( > static_cast<reactive_socket_connect_op_base*>(base)); > > return socket_ops::non_blocking_connect(o->socket_, o->ec_); > } > >private: > socket_type socket_; >}; > >template <typename Handler> >class reactive_socket_connect_op : public reactive_socket_connect_op_base >{ >public: > struct ptr { Handler* h; void* v; reactive_socket_connect_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~reactive_socket_connect_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(reactive_socket_connect_op), *h); v = 0; } } }; > > reactive_socket_connect_op(socket_type socket, Handler& handler) > : reactive_socket_connect_op_base(socket, > &reactive_socket_connect_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > reactive_socket_connect_op* o > (static_cast<reactive_socket_connect_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder1<Handler, boost::system::error_code> > handler(o->handler_, o->ec_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 107 "/usr/include/boost/asio/detail/reactive_socket_connect_op.hpp" 2 3 4 ># 32 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_recvfrom_op.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/reactive_socket_recvfrom_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/reactive_socket_recvfrom_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename MutableBufferSequence, typename Endpoint> >class reactive_socket_recvfrom_op_base : public reactor_op >{ >public: > reactive_socket_recvfrom_op_base(socket_type socket, int protocol_type, > const MutableBufferSequence& buffers, Endpoint& endpoint, > socket_base::message_flags flags, func_type complete_func) > : reactor_op(&reactive_socket_recvfrom_op_base::do_perform, complete_func), > socket_(socket), > protocol_type_(protocol_type), > buffers_(buffers), > sender_endpoint_(endpoint), > flags_(flags) > { > } > > static bool do_perform(reactor_op* base) > { > reactive_socket_recvfrom_op_base* o( > static_cast<reactive_socket_recvfrom_op_base*>(base)); > > buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence> bufs(o->buffers_); > > std::size_t addr_len = o->sender_endpoint_.capacity(); > bool result = socket_ops::non_blocking_recvfrom(o->socket_, > bufs.buffers(), bufs.count(), o->flags_, > o->sender_endpoint_.data(), &addr_len, > o->ec_, o->bytes_transferred_); > > if (result && !o->ec_) > o->sender_endpoint_.resize(addr_len); > > return result; > } > >private: > socket_type socket_; > int protocol_type_; > MutableBufferSequence buffers_; > Endpoint& sender_endpoint_; > socket_base::message_flags flags_; >}; > >template <typename MutableBufferSequence, typename Endpoint, typename Handler> >class reactive_socket_recvfrom_op : > public reactive_socket_recvfrom_op_base<MutableBufferSequence, Endpoint> >{ >public: > struct ptr { Handler* h; void* v; reactive_socket_recvfrom_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~reactive_socket_recvfrom_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(reactive_socket_recvfrom_op), *h); v = 0; } } }; > > reactive_socket_recvfrom_op(socket_type socket, int protocol_type, > const MutableBufferSequence& buffers, Endpoint& endpoint, > socket_base::message_flags flags, Handler& handler) > : reactive_socket_recvfrom_op_base<MutableBufferSequence, Endpoint>( > socket, protocol_type, buffers, endpoint, flags, > &reactive_socket_recvfrom_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > reactive_socket_recvfrom_op* o( > static_cast<reactive_socket_recvfrom_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, std::size_t> > handler(o->handler_, o->ec_, o->bytes_transferred_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 134 "/usr/include/boost/asio/detail/reactive_socket_recvfrom_op.hpp" 2 3 4 ># 33 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_sendto_op.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/reactive_socket_sendto_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/reactive_socket_sendto_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename ConstBufferSequence, typename Endpoint> >class reactive_socket_sendto_op_base : public reactor_op >{ >public: > reactive_socket_sendto_op_base(socket_type socket, > const ConstBufferSequence& buffers, const Endpoint& endpoint, > socket_base::message_flags flags, func_type complete_func) > : reactor_op(&reactive_socket_sendto_op_base::do_perform, complete_func), > socket_(socket), > buffers_(buffers), > destination_(endpoint), > flags_(flags) > { > } > > static bool do_perform(reactor_op* base) > { > reactive_socket_sendto_op_base* o( > static_cast<reactive_socket_sendto_op_base*>(base)); > > buffer_sequence_adapter<boost::asio::const_buffer, > ConstBufferSequence> bufs(o->buffers_); > > return socket_ops::non_blocking_sendto(o->socket_, > bufs.buffers(), bufs.count(), o->flags_, > o->destination_.data(), o->destination_.size(), > o->ec_, o->bytes_transferred_); > } > >private: > socket_type socket_; > ConstBufferSequence buffers_; > Endpoint destination_; > socket_base::message_flags flags_; >}; > >template <typename ConstBufferSequence, typename Endpoint, typename Handler> >class reactive_socket_sendto_op : > public reactive_socket_sendto_op_base<ConstBufferSequence, Endpoint> >{ >public: > struct ptr { Handler* h; void* v; reactive_socket_sendto_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~reactive_socket_sendto_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(reactive_socket_sendto_op), *h); v = 0; } } }; > > reactive_socket_sendto_op(socket_type socket, > const ConstBufferSequence& buffers, const Endpoint& endpoint, > socket_base::message_flags flags, Handler& handler) > : reactive_socket_sendto_op_base<ConstBufferSequence, Endpoint>(socket, > buffers, endpoint, flags, &reactive_socket_sendto_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > reactive_socket_sendto_op* o(static_cast<reactive_socket_sendto_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, std::size_t> > handler(o->handler_, o->ec_, o->bytes_transferred_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 124 "/usr/include/boost/asio/detail/reactive_socket_sendto_op.hpp" 2 3 4 ># 34 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_service_base.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/detail/reactive_socket_service_base.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_recv_op.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/reactive_socket_recv_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/reactive_socket_recv_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename MutableBufferSequence> >class reactive_socket_recv_op_base : public reactor_op >{ >public: > reactive_socket_recv_op_base(socket_type socket, > socket_ops::state_type state, const MutableBufferSequence& buffers, > socket_base::message_flags flags, func_type complete_func) > : reactor_op(&reactive_socket_recv_op_base::do_perform, complete_func), > socket_(socket), > state_(state), > buffers_(buffers), > flags_(flags) > { > } > > static bool do_perform(reactor_op* base) > { > reactive_socket_recv_op_base* o( > static_cast<reactive_socket_recv_op_base*>(base)); > > buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence> bufs(o->buffers_); > > return socket_ops::non_blocking_recv(o->socket_, > bufs.buffers(), bufs.count(), o->flags_, > (o->state_ & socket_ops::stream_oriented) != 0, > o->ec_, o->bytes_transferred_); > } > >private: > socket_type socket_; > socket_ops::state_type state_; > MutableBufferSequence buffers_; > socket_base::message_flags flags_; >}; > >template <typename MutableBufferSequence, typename Handler> >class reactive_socket_recv_op : > public reactive_socket_recv_op_base<MutableBufferSequence> >{ >public: > struct ptr { Handler* h; void* v; reactive_socket_recv_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~reactive_socket_recv_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(reactive_socket_recv_op), *h); v = 0; } } }; > > reactive_socket_recv_op(socket_type socket, > socket_ops::state_type state, const MutableBufferSequence& buffers, > socket_base::message_flags flags, Handler& handler) > : reactive_socket_recv_op_base<MutableBufferSequence>(socket, state, > buffers, flags, &reactive_socket_recv_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > reactive_socket_recv_op* o(static_cast<reactive_socket_recv_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, std::size_t> > handler(o->handler_, o->ec_, o->bytes_transferred_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 124 "/usr/include/boost/asio/detail/reactive_socket_recv_op.hpp" 2 3 4 ># 31 "/usr/include/boost/asio/detail/reactive_socket_service_base.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_recvmsg_op.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/reactive_socket_recvmsg_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/reactive_socket_recvmsg_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename MutableBufferSequence> >class reactive_socket_recvmsg_op_base : public reactor_op >{ >public: > reactive_socket_recvmsg_op_base(socket_type socket, > const MutableBufferSequence& buffers, socket_base::message_flags in_flags, > socket_base::message_flags& out_flags, func_type complete_func) > : reactor_op(&reactive_socket_recvmsg_op_base::do_perform, complete_func), > socket_(socket), > buffers_(buffers), > in_flags_(in_flags), > out_flags_(out_flags) > { > } > > static bool do_perform(reactor_op* base) > { > reactive_socket_recvmsg_op_base* o( > static_cast<reactive_socket_recvmsg_op_base*>(base)); > > buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence> bufs(o->buffers_); > > return socket_ops::non_blocking_recvmsg(o->socket_, > bufs.buffers(), bufs.count(), > o->in_flags_, o->out_flags_, > o->ec_, o->bytes_transferred_); > } > >private: > socket_type socket_; > MutableBufferSequence buffers_; > socket_base::message_flags in_flags_; > socket_base::message_flags& out_flags_; >}; > >template <typename MutableBufferSequence, typename Handler> >class reactive_socket_recvmsg_op : > public reactive_socket_recvmsg_op_base<MutableBufferSequence> >{ >public: > struct ptr { Handler* h; void* v; reactive_socket_recvmsg_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~reactive_socket_recvmsg_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(reactive_socket_recvmsg_op), *h); v = 0; } } }; > > reactive_socket_recvmsg_op(socket_type socket, > const MutableBufferSequence& buffers, socket_base::message_flags in_flags, > socket_base::message_flags& out_flags, Handler& handler) > : reactive_socket_recvmsg_op_base<MutableBufferSequence>(socket, buffers, > in_flags, out_flags, &reactive_socket_recvmsg_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > reactive_socket_recvmsg_op* o( > static_cast<reactive_socket_recvmsg_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, std::size_t> > handler(o->handler_, o->ec_, o->bytes_transferred_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 126 "/usr/include/boost/asio/detail/reactive_socket_recvmsg_op.hpp" 2 3 4 ># 32 "/usr/include/boost/asio/detail/reactive_socket_service_base.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_send_op.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/reactive_socket_send_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/reactive_socket_send_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename ConstBufferSequence> >class reactive_socket_send_op_base : public reactor_op >{ >public: > reactive_socket_send_op_base(socket_type socket, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, func_type complete_func) > : reactor_op(&reactive_socket_send_op_base::do_perform, complete_func), > socket_(socket), > buffers_(buffers), > flags_(flags) > { > } > > static bool do_perform(reactor_op* base) > { > reactive_socket_send_op_base* o( > static_cast<reactive_socket_send_op_base*>(base)); > > buffer_sequence_adapter<boost::asio::const_buffer, > ConstBufferSequence> bufs(o->buffers_); > > return socket_ops::non_blocking_send(o->socket_, > bufs.buffers(), bufs.count(), o->flags_, > o->ec_, o->bytes_transferred_); > } > >private: > socket_type socket_; > ConstBufferSequence buffers_; > socket_base::message_flags flags_; >}; > >template <typename ConstBufferSequence, typename Handler> >class reactive_socket_send_op : > public reactive_socket_send_op_base<ConstBufferSequence> >{ >public: > struct ptr { Handler* h; void* v; reactive_socket_send_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~reactive_socket_send_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(reactive_socket_send_op), *h); v = 0; } } }; > > reactive_socket_send_op(socket_type socket, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, Handler& handler) > : reactive_socket_send_op_base<ConstBufferSequence>(socket, > buffers, flags, &reactive_socket_send_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > reactive_socket_send_op* o(static_cast<reactive_socket_send_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, std::size_t> > handler(o->handler_, o->ec_, o->bytes_transferred_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 121 "/usr/include/boost/asio/detail/reactive_socket_send_op.hpp" 2 3 4 ># 33 "/usr/include/boost/asio/detail/reactive_socket_service_base.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 40 "/usr/include/boost/asio/detail/reactive_socket_service_base.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class reactive_socket_service_base >{ >public: > > typedef socket_type native_handle_type; > > > struct base_implementation_type > { > > socket_type socket_; > > > socket_ops::state_type state_; > > > reactor::per_descriptor_data reactor_data_; > }; > > > inline reactive_socket_service_base( > boost::asio::io_service& io_service); > > > inline void shutdown_service(); > > > inline void construct(base_implementation_type& impl); > > > inline void base_move_construct(base_implementation_type& impl, > base_implementation_type& other_impl); > > > inline void base_move_assign(base_implementation_type& impl, > reactive_socket_service_base& other_service, > base_implementation_type& other_impl); > > > inline void destroy(base_implementation_type& impl); > > > bool is_open(const base_implementation_type& impl) const > { > return impl.socket_ != invalid_socket; > } > > > inline boost::system::error_code close( > base_implementation_type& impl, boost::system::error_code& ec); > > > native_handle_type native_handle(base_implementation_type& impl) > { > return impl.socket_; > } > > > inline boost::system::error_code cancel( > base_implementation_type& impl, boost::system::error_code& ec); > > > bool at_mark(const base_implementation_type& impl, > boost::system::error_code& ec) const > { > return socket_ops::sockatmark(impl.socket_, ec); > } > > > std::size_t available(const base_implementation_type& impl, > boost::system::error_code& ec) const > { > return socket_ops::available(impl.socket_, ec); > } > > > boost::system::error_code listen(base_implementation_type& impl, > int backlog, boost::system::error_code& ec) > { > socket_ops::listen(impl.socket_, backlog, ec); > return ec; > } > > > template <typename IO_Control_Command> > boost::system::error_code io_control(base_implementation_type& impl, > IO_Control_Command& command, boost::system::error_code& ec) > { > socket_ops::ioctl(impl.socket_, impl.state_, command.name(), > static_cast<ioctl_arg_type*>(command.data()), ec); > return ec; > } > > > bool non_blocking(const base_implementation_type& impl) const > { > return (impl.state_ & socket_ops::user_set_non_blocking) != 0; > } > > > boost::system::error_code non_blocking(base_implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > socket_ops::set_user_non_blocking(impl.socket_, impl.state_, mode, ec); > return ec; > } > > > bool native_non_blocking(const base_implementation_type& impl) const > { > return (impl.state_ & socket_ops::internal_non_blocking) != 0; > } > > > boost::system::error_code native_non_blocking(base_implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > socket_ops::set_internal_non_blocking(impl.socket_, impl.state_, mode, ec); > return ec; > } > > > boost::system::error_code shutdown(base_implementation_type& impl, > socket_base::shutdown_type what, boost::system::error_code& ec) > { > socket_ops::shutdown(impl.socket_, what, ec); > return ec; > } > > > template <typename ConstBufferSequence> > size_t send(base_implementation_type& impl, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > buffer_sequence_adapter<boost::asio::const_buffer, > ConstBufferSequence> bufs(buffers); > > return socket_ops::sync_send(impl.socket_, impl.state_, > bufs.buffers(), bufs.count(), flags, bufs.all_empty(), ec); > } > > > size_t send(base_implementation_type& impl, const null_buffers&, > socket_base::message_flags, boost::system::error_code& ec) > { > > socket_ops::poll_write(impl.socket_, impl.state_, ec); > > return 0; > } > > > > template <typename ConstBufferSequence, typename Handler> > void async_send(base_implementation_type& impl, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_socket_send_op<ConstBufferSequence, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl.socket_, buffers, flags, handler); > > (void)0; > > start_op(impl, reactor::write_op, p.p, is_continuation, true, > ((impl.state_ & socket_ops::stream_oriented) > && buffer_sequence_adapter<boost::asio::const_buffer, > ConstBufferSequence>::all_empty(buffers))); > p.v = p.p = 0; > } > > > template <typename Handler> > void async_send(base_implementation_type& impl, const null_buffers&, > socket_base::message_flags, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_null_buffers_op<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0 > ; > > start_op(impl, reactor::write_op, p.p, is_continuation, false, false); > p.v = p.p = 0; > } > > > template <typename MutableBufferSequence> > size_t receive(base_implementation_type& impl, > const MutableBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence> bufs(buffers); > > return socket_ops::sync_recv(impl.socket_, impl.state_, > bufs.buffers(), bufs.count(), flags, bufs.all_empty(), ec); > } > > > size_t receive(base_implementation_type& impl, const null_buffers&, > socket_base::message_flags, boost::system::error_code& ec) > { > > socket_ops::poll_read(impl.socket_, impl.state_, ec); > > return 0; > } > > > > template <typename MutableBufferSequence, typename Handler> > void async_receive(base_implementation_type& impl, > const MutableBufferSequence& buffers, > socket_base::message_flags flags, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_socket_recv_op<MutableBufferSequence, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl.socket_, impl.state_, buffers, flags, handler); > > (void)0; > > start_op(impl, > (flags & socket_base::message_out_of_band) > ? reactor::except_op : reactor::read_op, > p.p, is_continuation, > (flags & socket_base::message_out_of_band) == 0, > ((impl.state_ & socket_ops::stream_oriented) > && buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence>::all_empty(buffers))); > p.v = p.p = 0; > } > > > template <typename Handler> > void async_receive(base_implementation_type& impl, const null_buffers&, > socket_base::message_flags flags, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_null_buffers_op<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0 > ; > > start_op(impl, > (flags & socket_base::message_out_of_band) > ? reactor::except_op : reactor::read_op, > p.p, is_continuation, false, false); > p.v = p.p = 0; > } > > > > template <typename MutableBufferSequence> > size_t receive_with_flags(base_implementation_type& impl, > const MutableBufferSequence& buffers, > socket_base::message_flags in_flags, > socket_base::message_flags& out_flags, boost::system::error_code& ec) > { > buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence> bufs(buffers); > > return socket_ops::sync_recvmsg(impl.socket_, impl.state_, > bufs.buffers(), bufs.count(), in_flags, out_flags, ec); > } > > > size_t receive_with_flags(base_implementation_type& impl, > const null_buffers&, socket_base::message_flags, > socket_base::message_flags& out_flags, boost::system::error_code& ec) > { > > socket_ops::poll_read(impl.socket_, impl.state_, ec); > > > > out_flags = 0; > > return 0; > } > > > > template <typename MutableBufferSequence, typename Handler> > void async_receive_with_flags(base_implementation_type& impl, > const MutableBufferSequence& buffers, socket_base::message_flags in_flags, > socket_base::message_flags& out_flags, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_socket_recvmsg_op<MutableBufferSequence, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl.socket_, buffers, in_flags, out_flags, handler); > > (void)0 > ; > > start_op(impl, > (in_flags & socket_base::message_out_of_band) > ? reactor::except_op : reactor::read_op, > p.p, is_continuation, > (in_flags & socket_base::message_out_of_band) == 0, false); > p.v = p.p = 0; > } > > > template <typename Handler> > void async_receive_with_flags(base_implementation_type& impl, > const null_buffers&, socket_base::message_flags in_flags, > socket_base::message_flags& out_flags, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_null_buffers_op<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0 > ; > > > > out_flags = 0; > > start_op(impl, > (in_flags & socket_base::message_out_of_band) > ? reactor::except_op : reactor::read_op, > p.p, is_continuation, false, false); > p.v = p.p = 0; > } > >protected: > > inline boost::system::error_code do_open( > base_implementation_type& impl, int af, > int type, int protocol, boost::system::error_code& ec); > > > inline boost::system::error_code do_assign( > base_implementation_type& impl, int type, > const native_handle_type& native_socket, boost::system::error_code& ec); > > > inline void start_op(base_implementation_type& impl, int op_type, > reactor_op* op, bool is_continuation, bool is_non_blocking, bool noop); > > > inline void start_accept_op(base_implementation_type& impl, > reactor_op* op, bool is_continuation, bool peer_is_open); > > > inline void start_connect_op(base_implementation_type& impl, > reactor_op* op, bool is_continuation, > const socket_addr_type* addr, size_t addrlen); > > > reactor& reactor_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 444 "/usr/include/boost/asio/detail/reactive_socket_service_base.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/reactive_socket_service_base.ipp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/impl/reactive_socket_service_base.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_socket_service_base.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/impl/reactive_socket_service_base.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/impl/reactive_socket_service_base.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >reactive_socket_service_base::reactive_socket_service_base( > boost::asio::io_service& io_service) > : reactor_(use_service<reactor>(io_service)) >{ > reactor_.init_task(); >} > >void reactive_socket_service_base::shutdown_service() >{ >} > >void reactive_socket_service_base::construct( > reactive_socket_service_base::base_implementation_type& impl) >{ > impl.socket_ = invalid_socket; > impl.state_ = 0; >} > >void reactive_socket_service_base::base_move_construct( > reactive_socket_service_base::base_implementation_type& impl, > reactive_socket_service_base::base_implementation_type& other_impl) >{ > impl.socket_ = other_impl.socket_; > other_impl.socket_ = invalid_socket; > > impl.state_ = other_impl.state_; > other_impl.state_ = 0; > > reactor_.move_descriptor(impl.socket_, > impl.reactor_data_, other_impl.reactor_data_); >} > >void reactive_socket_service_base::base_move_assign( > reactive_socket_service_base::base_implementation_type& impl, > reactive_socket_service_base& other_service, > reactive_socket_service_base::base_implementation_type& other_impl) >{ > destroy(impl); > > impl.socket_ = other_impl.socket_; > other_impl.socket_ = invalid_socket; > > impl.state_ = other_impl.state_; > other_impl.state_ = 0; > > other_service.reactor_.move_descriptor(impl.socket_, > impl.reactor_data_, other_impl.reactor_data_); >} > >void reactive_socket_service_base::destroy( > reactive_socket_service_base::base_implementation_type& impl) >{ > if (impl.socket_ != invalid_socket) > { > (void)0; > > reactor_.deregister_descriptor(impl.socket_, impl.reactor_data_, > (impl.state_ & socket_ops::possible_dup) == 0); > > boost::system::error_code ignored_ec; > socket_ops::close(impl.socket_, impl.state_, true, ignored_ec); > } >} > >boost::system::error_code reactive_socket_service_base::close( > reactive_socket_service_base::base_implementation_type& impl, > boost::system::error_code& ec) >{ > if (is_open(impl)) > { > (void)0; > > reactor_.deregister_descriptor(impl.socket_, impl.reactor_data_, > (impl.state_ & socket_ops::possible_dup) == 0); > } > > socket_ops::close(impl.socket_, impl.state_, false, ec); ># 117 "/usr/include/boost/asio/detail/impl/reactive_socket_service_base.ipp" 3 4 > construct(impl); > > return ec; >} > >boost::system::error_code reactive_socket_service_base::cancel( > reactive_socket_service_base::base_implementation_type& impl, > boost::system::error_code& ec) >{ > if (!is_open(impl)) > { > ec = boost::asio::error::bad_descriptor; > return ec; > } > > (void)0; > > reactor_.cancel_ops(impl.socket_, impl.reactor_data_); > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code reactive_socket_service_base::do_open( > reactive_socket_service_base::base_implementation_type& impl, > int af, int type, int protocol, boost::system::error_code& ec) >{ > if (is_open(impl)) > { > ec = boost::asio::error::already_open; > return ec; > } > > socket_holder sock(socket_ops::socket(af, type, protocol, ec)); > if (sock.get() == invalid_socket) > return ec; > > if (int err = reactor_.register_descriptor(sock.get(), impl.reactor_data_)) > { > ec = boost::system::error_code(err, > boost::asio::error::get_system_category()); > return ec; > } > > impl.socket_ = sock.release(); > switch (type) > { > case SOCK_STREAM: impl.state_ = socket_ops::stream_oriented; break; > case SOCK_DGRAM: impl.state_ = socket_ops::datagram_oriented; break; > default: impl.state_ = 0; break; > } > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code reactive_socket_service_base::do_assign( > reactive_socket_service_base::base_implementation_type& impl, int type, > const reactive_socket_service_base::native_handle_type& native_socket, > boost::system::error_code& ec) >{ > if (is_open(impl)) > { > ec = boost::asio::error::already_open; > return ec; > } > > if (int err = reactor_.register_descriptor( > native_socket, impl.reactor_data_)) > { > ec = boost::system::error_code(err, > boost::asio::error::get_system_category()); > return ec; > } > > impl.socket_ = native_socket; > switch (type) > { > case SOCK_STREAM: impl.state_ = socket_ops::stream_oriented; break; > case SOCK_DGRAM: impl.state_ = socket_ops::datagram_oriented; break; > default: impl.state_ = 0; break; > } > impl.state_ |= socket_ops::possible_dup; > ec = boost::system::error_code(); > return ec; >} > >void reactive_socket_service_base::start_op( > reactive_socket_service_base::base_implementation_type& impl, > int op_type, reactor_op* op, bool is_continuation, > bool is_non_blocking, bool noop) >{ > if (!noop) > { > if ((impl.state_ & socket_ops::non_blocking) > || socket_ops::set_internal_non_blocking( > impl.socket_, impl.state_, true, op->ec_)) > { > reactor_.start_op(op_type, impl.socket_, > impl.reactor_data_, op, is_continuation, is_non_blocking); > return; > } > } > > reactor_.post_immediate_completion(op, is_continuation); >} > >void reactive_socket_service_base::start_accept_op( > reactive_socket_service_base::base_implementation_type& impl, > reactor_op* op, bool is_continuation, bool peer_is_open) >{ > if (!peer_is_open) > start_op(impl, reactor::read_op, op, true, is_continuation, false); > else > { > op->ec_ = boost::asio::error::already_open; > reactor_.post_immediate_completion(op, is_continuation); > } >} > >void reactive_socket_service_base::start_connect_op( > reactive_socket_service_base::base_implementation_type& impl, > reactor_op* op, bool is_continuation, > const socket_addr_type* addr, size_t addrlen) >{ > if ((impl.state_ & socket_ops::non_blocking) > || socket_ops::set_internal_non_blocking( > impl.socket_, impl.state_, true, op->ec_)) > { > if (socket_ops::connect(impl.socket_, addr, addrlen, op->ec_) != 0) > { > if (op->ec_ == boost::asio::error::in_progress > || op->ec_ == boost::asio::error::would_block) > { > op->ec_ = boost::system::error_code(); > reactor_.start_op(reactor::connect_op, impl.socket_, > impl.reactor_data_, op, is_continuation, false); > return; > } > } > } > > reactor_.post_immediate_completion(op, is_continuation); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 265 "/usr/include/boost/asio/detail/impl/reactive_socket_service_base.ipp" 2 3 4 ># 447 "/usr/include/boost/asio/detail/reactive_socket_service_base.hpp" 2 3 4 ># 35 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 42 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Protocol> >class reactive_socket_service : > public reactive_socket_service_base >{ >public: > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; > > > typedef socket_type native_handle_type; > > > struct implementation_type : > reactive_socket_service_base::base_implementation_type > { > > implementation_type() > : protocol_(endpoint_type().protocol()) > { > } > > > protocol_type protocol_; > }; > > > reactive_socket_service(boost::asio::io_service& io_service) > : reactive_socket_service_base(io_service) > { > } > > > void move_construct(implementation_type& impl, > implementation_type& other_impl) > { > this->base_move_construct(impl, other_impl); > > impl.protocol_ = other_impl.protocol_; > other_impl.protocol_ = endpoint_type().protocol(); > } > > > void move_assign(implementation_type& impl, > reactive_socket_service_base& other_service, > implementation_type& other_impl) > { > this->base_move_assign(impl, other_service, other_impl); > > impl.protocol_ = other_impl.protocol_; > other_impl.protocol_ = endpoint_type().protocol(); > } > > > template <typename Protocol1> > void converting_move_construct(implementation_type& impl, > typename reactive_socket_service< > Protocol1>::implementation_type& other_impl) > { > this->base_move_construct(impl, other_impl); > > impl.protocol_ = protocol_type(other_impl.protocol_); > other_impl.protocol_ = typename Protocol1::endpoint().protocol(); > } > > > boost::system::error_code open(implementation_type& impl, > const protocol_type& protocol, boost::system::error_code& ec) > { > if (!do_open(impl, protocol.family(), > protocol.type(), protocol.protocol(), ec)) > impl.protocol_ = protocol; > return ec; > } > > > boost::system::error_code assign(implementation_type& impl, > const protocol_type& protocol, const native_handle_type& native_socket, > boost::system::error_code& ec) > { > if (!do_assign(impl, protocol.type(), native_socket, ec)) > impl.protocol_ = protocol; > return ec; > } > > > native_handle_type native_handle(implementation_type& impl) > { > return impl.socket_; > } > > > boost::system::error_code bind(implementation_type& impl, > const endpoint_type& endpoint, boost::system::error_code& ec) > { > socket_ops::bind(impl.socket_, endpoint.data(), endpoint.size(), ec); > return ec; > } > > > template <typename Option> > boost::system::error_code set_option(implementation_type& impl, > const Option& option, boost::system::error_code& ec) > { > socket_ops::setsockopt(impl.socket_, impl.state_, > option.level(impl.protocol_), option.name(impl.protocol_), > option.data(impl.protocol_), option.size(impl.protocol_), ec); > return ec; > } > > > template <typename Option> > boost::system::error_code get_option(const implementation_type& impl, > Option& option, boost::system::error_code& ec) const > { > std::size_t size = option.size(impl.protocol_); > socket_ops::getsockopt(impl.socket_, impl.state_, > option.level(impl.protocol_), option.name(impl.protocol_), > option.data(impl.protocol_), &size, ec); > if (!ec) > option.resize(impl.protocol_, size); > return ec; > } > > > endpoint_type local_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > endpoint_type endpoint; > std::size_t addr_len = endpoint.capacity(); > if (socket_ops::getsockname(impl.socket_, endpoint.data(), &addr_len, ec)) > return endpoint_type(); > endpoint.resize(addr_len); > return endpoint; > } > > > endpoint_type remote_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > endpoint_type endpoint; > std::size_t addr_len = endpoint.capacity(); > if (socket_ops::getpeername(impl.socket_, > endpoint.data(), &addr_len, false, ec)) > return endpoint_type(); > endpoint.resize(addr_len); > return endpoint; > } > > > > template <typename ConstBufferSequence> > size_t send_to(implementation_type& impl, const ConstBufferSequence& buffers, > const endpoint_type& destination, socket_base::message_flags flags, > boost::system::error_code& ec) > { > buffer_sequence_adapter<boost::asio::const_buffer, > ConstBufferSequence> bufs(buffers); > > return socket_ops::sync_sendto(impl.socket_, impl.state_, > bufs.buffers(), bufs.count(), flags, > destination.data(), destination.size(), ec); > } > > > size_t send_to(implementation_type& impl, const null_buffers&, > const endpoint_type&, socket_base::message_flags, > boost::system::error_code& ec) > { > > socket_ops::poll_write(impl.socket_, impl.state_, ec); > > return 0; > } > > > > template <typename ConstBufferSequence, typename Handler> > void async_send_to(implementation_type& impl, > const ConstBufferSequence& buffers, > const endpoint_type& destination, socket_base::message_flags flags, > Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_socket_sendto_op<ConstBufferSequence, > endpoint_type, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl.socket_, buffers, destination, flags, handler); > > (void)0; > > start_op(impl, reactor::write_op, p.p, is_continuation, true, false); > p.v = p.p = 0; > } > > > template <typename Handler> > void async_send_to(implementation_type& impl, const null_buffers&, > const endpoint_type&, socket_base::message_flags, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_null_buffers_op<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0 > ; > > start_op(impl, reactor::write_op, p.p, is_continuation, false, false); > p.v = p.p = 0; > } > > > > template <typename MutableBufferSequence> > size_t receive_from(implementation_type& impl, > const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint, socket_base::message_flags flags, > boost::system::error_code& ec) > { > buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence> bufs(buffers); > > std::size_t addr_len = sender_endpoint.capacity(); > std::size_t bytes_recvd = socket_ops::sync_recvfrom( > impl.socket_, impl.state_, bufs.buffers(), bufs.count(), > flags, sender_endpoint.data(), &addr_len, ec); > > if (!ec) > sender_endpoint.resize(addr_len); > > return bytes_recvd; > } > > > size_t receive_from(implementation_type& impl, const null_buffers&, > endpoint_type& sender_endpoint, socket_base::message_flags, > boost::system::error_code& ec) > { > > socket_ops::poll_read(impl.socket_, impl.state_, ec); > > > sender_endpoint = endpoint_type(); > > return 0; > } > > > > > template <typename MutableBufferSequence, typename Handler> > void async_receive_from(implementation_type& impl, > const MutableBufferSequence& buffers, endpoint_type& sender_endpoint, > socket_base::message_flags flags, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_socket_recvfrom_op<MutableBufferSequence, > endpoint_type, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > int protocol = impl.protocol_.type(); > p.p = new (p.v) op(impl.socket_, protocol, > buffers, sender_endpoint, flags, handler); > > (void)0 > ; > > start_op(impl, > (flags & socket_base::message_out_of_band) > ? reactor::except_op : reactor::read_op, > p.p, is_continuation, true, false); > p.v = p.p = 0; > } > > > template <typename Handler> > void async_receive_from(implementation_type& impl, > const null_buffers&, endpoint_type& sender_endpoint, > socket_base::message_flags flags, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_null_buffers_op<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0 > ; > > > sender_endpoint = endpoint_type(); > > start_op(impl, > (flags & socket_base::message_out_of_band) > ? reactor::except_op : reactor::read_op, > p.p, is_continuation, false, false); > p.v = p.p = 0; > } > > > template <typename Socket> > boost::system::error_code accept(implementation_type& impl, > Socket& peer, endpoint_type* peer_endpoint, boost::system::error_code& ec) > { > > if (peer.is_open()) > { > ec = boost::asio::error::already_open; > return ec; > } > > std::size_t addr_len = peer_endpoint ? peer_endpoint->capacity() : 0; > socket_holder new_socket(socket_ops::sync_accept(impl.socket_, > impl.state_, peer_endpoint ? peer_endpoint->data() : 0, > peer_endpoint ? &addr_len : 0, ec)); > > > if (new_socket.get() != invalid_socket) > { > if (peer_endpoint) > peer_endpoint->resize(addr_len); > if (!peer.assign(impl.protocol_, new_socket.get(), ec)) > new_socket.release(); > } > > return ec; > } > > > > template <typename Socket, typename Handler> > void async_accept(implementation_type& impl, Socket& peer, > endpoint_type* peer_endpoint, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_socket_accept_op<Socket, Protocol, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl.socket_, impl.state_, peer, > impl.protocol_, peer_endpoint, handler); > > (void)0; > > start_accept_op(impl, p.p, is_continuation, peer.is_open()); > p.v = p.p = 0; > } > > > boost::system::error_code connect(implementation_type& impl, > const endpoint_type& peer_endpoint, boost::system::error_code& ec) > { > socket_ops::sync_connect(impl.socket_, > peer_endpoint.data(), peer_endpoint.size(), ec); > return ec; > } > > > template <typename Handler> > void async_connect(implementation_type& impl, > const endpoint_type& peer_endpoint, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_socket_connect_op<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl.socket_, handler); > > (void)0; > > start_connect_op(impl, p.p, is_continuation, > peer_endpoint.data(), peer_endpoint.size()); > p.v = p.p = 0; > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 456 "/usr/include/boost/asio/detail/reactive_socket_service.hpp" 2 3 4 ># 31 "/usr/include/boost/asio/datagram_socket_service.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 34 "/usr/include/boost/asio/datagram_socket_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >template <typename Protocol> >class datagram_socket_service > > > > : public boost::asio::detail::service_base<datagram_socket_service<Protocol> > > >{ >public: > > > > > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; > >private: > > > > > > > typedef detail::reactive_socket_service<Protocol> service_impl_type; > > >public: > > > > > typedef typename service_impl_type::implementation_type implementation_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_handle_type; > > > > explicit datagram_socket_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base< > datagram_socket_service<Protocol> >(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > > void move_construct(implementation_type& impl, > implementation_type& other_impl) > { > service_impl_.move_construct(impl, other_impl); > } > > > void move_assign(implementation_type& impl, > datagram_socket_service& other_service, > implementation_type& other_impl) > { > service_impl_.move_assign(impl, other_service.service_impl_, other_impl); > } > > > > template <typename Protocol1> > void converting_move_construct(implementation_type& impl, > typename datagram_socket_service< > Protocol1>::implementation_type& other_impl, > typename enable_if<is_convertible< > Protocol1, Protocol>::value>::type* = 0) > { > service_impl_.template converting_move_construct<Protocol1>( > impl, other_impl); > } > > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > boost::system::error_code open(implementation_type& impl, > const protocol_type& protocol, boost::system::error_code& ec) > { > if (protocol.type() == SOCK_DGRAM) > service_impl_.open(impl, protocol, ec); > else > ec = boost::asio::error::invalid_argument; > return ec; > } > > > boost::system::error_code assign(implementation_type& impl, > const protocol_type& protocol, const native_handle_type& native_socket, > boost::system::error_code& ec) > { > return service_impl_.assign(impl, protocol, native_socket, ec); > } > > > bool is_open(const implementation_type& impl) const > { > return service_impl_.is_open(impl); > } > > > boost::system::error_code close(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.close(impl, ec); > } > > > native_type native(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > native_handle_type native_handle(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > bool at_mark(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.at_mark(impl, ec); > } > > > std::size_t available(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.available(impl, ec); > } > > > boost::system::error_code bind(implementation_type& impl, > const endpoint_type& endpoint, boost::system::error_code& ec) > { > return service_impl_.bind(impl, endpoint, ec); > } > > > boost::system::error_code connect(implementation_type& impl, > const endpoint_type& peer_endpoint, boost::system::error_code& ec) > { > return service_impl_.connect(impl, peer_endpoint, ec); > } > > > template <typename ConnectHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ConnectHandler, void (boost::system::error_code)>::type>::type > > async_connect(implementation_type& impl, > const endpoint_type& peer_endpoint, > ConnectHandler&& handler) > { > detail::async_result_init< > ConnectHandler, void (boost::system::error_code)> init( > static_cast<ConnectHandler&&>(handler)); > > service_impl_.async_connect(impl, peer_endpoint, init.handler); > > return init.result.get(); > } > > > template <typename SettableSocketOption> > boost::system::error_code set_option(implementation_type& impl, > const SettableSocketOption& option, boost::system::error_code& ec) > { > return service_impl_.set_option(impl, option, ec); > } > > > template <typename GettableSocketOption> > boost::system::error_code get_option(const implementation_type& impl, > GettableSocketOption& option, boost::system::error_code& ec) const > { > return service_impl_.get_option(impl, option, ec); > } > > > template <typename IoControlCommand> > boost::system::error_code io_control(implementation_type& impl, > IoControlCommand& command, boost::system::error_code& ec) > { > return service_impl_.io_control(impl, command, ec); > } > > > bool non_blocking(const implementation_type& impl) const > { > return service_impl_.non_blocking(impl); > } > > > boost::system::error_code non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.non_blocking(impl, mode, ec); > } > > > bool native_non_blocking(const implementation_type& impl) const > { > return service_impl_.native_non_blocking(impl); > } > > > boost::system::error_code native_non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.native_non_blocking(impl, mode, ec); > } > > > endpoint_type local_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.local_endpoint(impl, ec); > } > > > endpoint_type remote_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.remote_endpoint(impl, ec); > } > > > boost::system::error_code shutdown(implementation_type& impl, > socket_base::shutdown_type what, boost::system::error_code& ec) > { > return service_impl_.shutdown(impl, what, ec); > } > > > template <typename ConstBufferSequence> > std::size_t send(implementation_type& impl, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.send(impl, buffers, flags, ec); > } > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(implementation_type& impl, const ConstBufferSequence& buffers, > socket_base::message_flags flags, > WriteHandler&& handler) > { > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > service_impl_.async_send(impl, buffers, flags, init.handler); > > return init.result.get(); > } > > > template <typename ConstBufferSequence> > std::size_t send_to(implementation_type& impl, > const ConstBufferSequence& buffers, const endpoint_type& destination, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.send_to(impl, buffers, destination, flags, ec); > } > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send_to(implementation_type& impl, > const ConstBufferSequence& buffers, const endpoint_type& destination, > socket_base::message_flags flags, > WriteHandler&& handler) > { > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > service_impl_.async_send_to(impl, buffers, > destination, flags, init.handler); > > return init.result.get(); > } > > > template <typename MutableBufferSequence> > std::size_t receive(implementation_type& impl, > const MutableBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.receive(impl, buffers, flags, ec); > } > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(implementation_type& impl, > const MutableBufferSequence& buffers, > socket_base::message_flags flags, > ReadHandler&& handler) > { > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > service_impl_.async_receive(impl, buffers, flags, init.handler); > > return init.result.get(); > } > > > template <typename MutableBufferSequence> > std::size_t receive_from(implementation_type& impl, > const MutableBufferSequence& buffers, endpoint_type& sender_endpoint, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.receive_from(impl, buffers, sender_endpoint, flags, > ec); > } > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive_from(implementation_type& impl, > const MutableBufferSequence& buffers, endpoint_type& sender_endpoint, > socket_base::message_flags flags, > ReadHandler&& handler) > { > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > service_impl_.async_receive_from(impl, buffers, > sender_endpoint, flags, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > service_impl_type service_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 433 "/usr/include/boost/asio/datagram_socket_service.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/basic_datagram_socket.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/basic_datagram_socket.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 41 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 >template <typename Protocol, > typename DatagramSocketService = datagram_socket_service<Protocol> > >class basic_datagram_socket > : public basic_socket<Protocol, DatagramSocketService> >{ >public: > > > typedef typename DatagramSocketService::native_handle_type native_type; > > > typedef typename DatagramSocketService::native_handle_type native_handle_type; > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; ># 69 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > explicit basic_datagram_socket(boost::asio::io_service& io_service) > : basic_socket<Protocol, DatagramSocketService>(io_service) > { > } ># 86 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > basic_datagram_socket(boost::asio::io_service& io_service, > const protocol_type& protocol) > : basic_socket<Protocol, DatagramSocketService>(io_service, protocol) > { > } ># 108 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > basic_datagram_socket(boost::asio::io_service& io_service, > const endpoint_type& endpoint) > : basic_socket<Protocol, DatagramSocketService>(io_service, endpoint) > { > } ># 129 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > basic_datagram_socket(boost::asio::io_service& io_service, > const protocol_type& protocol, const native_handle_type& native_socket) > : basic_socket<Protocol, DatagramSocketService>( > io_service, protocol, native_socket) > { > } ># 147 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > basic_datagram_socket(basic_datagram_socket&& other) > : basic_socket<Protocol, DatagramSocketService>( > static_cast<basic_datagram_socket&&>(other)) > { > } ># 164 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > basic_datagram_socket& operator=(basic_datagram_socket&& other) > { > basic_socket<Protocol, DatagramSocketService>::operator=( > static_cast<basic_datagram_socket&&>(other)); > return *this; > } ># 182 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename Protocol1, typename DatagramSocketService1> > basic_datagram_socket( > basic_datagram_socket<Protocol1, DatagramSocketService1>&& other, > typename enable_if<is_convertible<Protocol1, Protocol>::value>::type* = 0) > : basic_socket<Protocol, DatagramSocketService>( > static_cast<basic_datagram_socket< Protocol1, DatagramSocketService1>&&> > (other)) > { > } ># 204 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename Protocol1, typename DatagramSocketService1> > typename enable_if<is_convertible<Protocol1, Protocol>::value, > basic_datagram_socket>::type& operator=( > basic_datagram_socket<Protocol1, DatagramSocketService1>&& other) > { > basic_socket<Protocol, DatagramSocketService>::operator=( > static_cast<basic_datagram_socket< Protocol1, DatagramSocketService1>&&> > (other)); > return *this; > } ># 238 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send( > this->get_implementation(), buffers, 0, ec); > boost::asio::detail::throw_error(ec, "send"); > return s; > } ># 265 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers, > socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send( > this->get_implementation(), buffers, flags, ec); > boost::asio::detail::throw_error(ec, "send"); > return s; > } ># 293 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return this->get_service().send( > this->get_implementation(), buffers, flags, ec); > } ># 337 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send(this->get_implementation(), > buffers, 0, static_cast<WriteHandler&&>(handler)); > } ># 379 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(const ConstBufferSequence& buffers, > socket_base::message_flags flags, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send(this->get_implementation(), > buffers, flags, static_cast<WriteHandler&&>(handler)); > } ># 419 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send_to( > this->get_implementation(), buffers, destination, 0, ec); > boost::asio::detail::throw_error(ec, "send_to"); > return s; > } ># 446 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination, socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send_to( > this->get_implementation(), buffers, destination, flags, ec); > boost::asio::detail::throw_error(ec, "send_to"); > return s; > } ># 473 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination, socket_base::message_flags flags, > boost::system::error_code& ec) > { > return this->get_service().send_to(this->get_implementation(), > buffers, destination, flags, ec); > } ># 519 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send_to( > this->get_implementation(), buffers, destination, 0, > static_cast<WriteHandler&&>(handler)); > } ># 562 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination, socket_base::message_flags flags, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send_to( > this->get_implementation(), buffers, destination, flags, > static_cast<WriteHandler&&>(handler)); > } ># 602 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive( > this->get_implementation(), buffers, 0, ec); > boost::asio::detail::throw_error(ec, "receive"); > return s; > } ># 630 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers, > socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive( > this->get_implementation(), buffers, flags, ec); > boost::asio::detail::throw_error(ec, "receive"); > return s; > } ># 659 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return this->get_service().receive( > this->get_implementation(), buffers, flags, ec); > } ># 703 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive(this->get_implementation(), > buffers, 0, static_cast<ReadHandler&&>(handler)); > } ># 745 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(const MutableBufferSequence& buffers, > socket_base::message_flags flags, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive(this->get_implementation(), > buffers, flags, static_cast<ReadHandler&&>(handler)); > } ># 786 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive_from( > this->get_implementation(), buffers, sender_endpoint, 0, ec); > boost::asio::detail::throw_error(ec, "receive_from"); > return s; > } ># 813 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint, socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive_from( > this->get_implementation(), buffers, sender_endpoint, flags, ec); > boost::asio::detail::throw_error(ec, "receive_from"); > return s; > } ># 840 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint, socket_base::message_flags flags, > boost::system::error_code& ec) > { > return this->get_service().receive_from(this->get_implementation(), > buffers, sender_endpoint, flags, ec); > } ># 885 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive_from( > this->get_implementation(), buffers, sender_endpoint, 0, > static_cast<ReadHandler&&>(handler)); > } ># 930 "/usr/include/boost/asio/basic_datagram_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint, socket_base::message_flags flags, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive_from( > this->get_implementation(), buffers, sender_endpoint, flags, > static_cast<ReadHandler&&>(handler)); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 951 "/usr/include/boost/asio/basic_datagram_socket.hpp" 2 3 4 ># 22 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/basic_deadline_timer.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 ># 1 "/usr/include/boost/asio/deadline_timer_service.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/deadline_timer_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/deadline_timer_service.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/deadline_timer_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/timer_queue.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/timer_queue.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/date_time_fwd.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/date_time_fwd.hpp" 3 4 >namespace boost { >namespace date_time { > >template<class T, class TimeSystem> >class base_time; > >} >namespace posix_time { > >class ptime; > >} >} ># 23 "/usr/include/boost/asio/detail/timer_queue.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/detail/timer_queue.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Time_Traits> >class timer_queue > : public timer_queue_base >{ >public: > > typedef typename Time_Traits::time_type time_type; > > > typedef typename Time_Traits::duration_type duration_type; > > > class per_timer_data > { > public: > per_timer_data() : next_(0), prev_(0) {} > > private: > friend class timer_queue; > > > op_queue<wait_op> op_queue_; > > > std::size_t heap_index_; > > > per_timer_data* next_; > per_timer_data* prev_; > }; > > > timer_queue() > : timers_(), > heap_() > { > } > > > > > bool enqueue_timer(const time_type& time, per_timer_data& timer, wait_op* op) > { > > if (timer.prev_ == 0 && &timer != timers_) > { > if (this->is_positive_infinity(time)) > { > > timer.heap_index_ = (std::numeric_limits<std::size_t>::max)(); > } > else > { > > > timer.heap_index_ = heap_.size(); > heap_entry entry = { time, &timer }; > heap_.push_back(entry); > up_heap(heap_.size() - 1); > } > > > timer.next_ = timers_; > timer.prev_ = 0; > if (timers_) > timers_->prev_ = &timer; > timers_ = &timer; > } > > > timer.op_queue_.push(op); > > > return timer.heap_index_ == 0 && timer.op_queue_.front() == op; > } > > > virtual bool empty() const > { > return timers_ == 0; > } > > > virtual long wait_duration_msec(long max_duration) const > { > if (heap_.empty()) > return max_duration; > > return this->to_msec( > Time_Traits::to_posix_duration( > Time_Traits::subtract(heap_[0].time_, Time_Traits::now())), > max_duration); > } > > > virtual long wait_duration_usec(long max_duration) const > { > if (heap_.empty()) > return max_duration; > > return this->to_usec( > Time_Traits::to_posix_duration( > Time_Traits::subtract(heap_[0].time_, Time_Traits::now())), > max_duration); > } > > > virtual void get_ready_timers(op_queue<operation>& ops) > { > if (!heap_.empty()) > { > const time_type now = Time_Traits::now(); > while (!heap_.empty() && !Time_Traits::less_than(now, heap_[0].time_)) > { > per_timer_data* timer = heap_[0].timer_; > ops.push(timer->op_queue_); > remove_timer(*timer); > } > } > } > > > virtual void get_all_timers(op_queue<operation>& ops) > { > while (timers_) > { > per_timer_data* timer = timers_; > timers_ = timers_->next_; > ops.push(timer->op_queue_); > timer->next_ = 0; > timer->prev_ = 0; > } > > heap_.clear(); > } > > > std::size_t cancel_timer(per_timer_data& timer, op_queue<operation>& ops, > std::size_t max_cancelled = (std::numeric_limits<std::size_t>::max)()) > { > std::size_t num_cancelled = 0; > if (timer.prev_ != 0 || &timer == timers_) > { > while (wait_op* op = (num_cancelled != max_cancelled) > ? timer.op_queue_.front() : 0) > { > op->ec_ = boost::asio::error::operation_aborted; > timer.op_queue_.pop(); > ops.push(op); > ++num_cancelled; > } > if (timer.op_queue_.empty()) > remove_timer(timer); > } > return num_cancelled; > } > >private: > > void up_heap(std::size_t index) > { > std::size_t parent = (index - 1) / 2; > while (index > 0 > && Time_Traits::less_than(heap_[index].time_, heap_[parent].time_)) > { > swap_heap(index, parent); > index = parent; > parent = (index - 1) / 2; > } > } > > > void down_heap(std::size_t index) > { > std::size_t child = index * 2 + 1; > while (child < heap_.size()) > { > std::size_t min_child = (child + 1 == heap_.size() > || Time_Traits::less_than( > heap_[child].time_, heap_[child + 1].time_)) > ? child : child + 1; > if (Time_Traits::less_than(heap_[index].time_, heap_[min_child].time_)) > break; > swap_heap(index, min_child); > index = min_child; > child = index * 2 + 1; > } > } > > > void swap_heap(std::size_t index1, std::size_t index2) > { > heap_entry tmp = heap_[index1]; > heap_[index1] = heap_[index2]; > heap_[index2] = tmp; > heap_[index1].timer_->heap_index_ = index1; > heap_[index2].timer_->heap_index_ = index2; > } > > > void remove_timer(per_timer_data& timer) > { > > std::size_t index = timer.heap_index_; > if (!heap_.empty() && index < heap_.size()) > { > if (index == heap_.size() - 1) > { > heap_.pop_back(); > } > else > { > swap_heap(index, heap_.size() - 1); > heap_.pop_back(); > std::size_t parent = (index - 1) / 2; > if (index > 0 && Time_Traits::less_than( > heap_[index].time_, heap_[parent].time_)) > up_heap(index); > else > down_heap(index); > } > } > > > if (timers_ == &timer) > timers_ = timer.next_; > if (timer.prev_) > timer.prev_->next_ = timer.next_; > if (timer.next_) > timer.next_->prev_= timer.prev_; > timer.next_ = 0; > timer.prev_ = 0; > } > > > template <typename Time_Type> > static bool is_positive_infinity(const Time_Type&) > { > return false; > } > > > template <typename T, typename TimeSystem> > static bool is_positive_infinity( > const boost::date_time::base_time<T, TimeSystem>& time) > { > return time.is_pos_infinity(); > } > > > template <typename Duration> > long to_msec(const Duration& d, long max_duration) const > { > if (d.ticks() <= 0) > return 0; > int64_t msec = d.total_milliseconds(); > if (msec == 0) > return 1; > if (msec > max_duration) > return max_duration; > return static_cast<long>(msec); > } > > > template <typename Duration> > long to_usec(const Duration& d, long max_duration) const > { > if (d.ticks() <= 0) > return 0; > int64_t usec = d.total_microseconds(); > if (usec == 0) > return 1; > if (usec > max_duration) > return max_duration; > return static_cast<long>(usec); > } > > > per_timer_data* timers_; > > struct heap_entry > { > > time_type time_; > > > per_timer_data* timer_; > }; > > > std::vector<heap_entry> heap_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 333 "/usr/include/boost/asio/detail/timer_queue.hpp" 2 3 4 ># 29 "/usr/include/boost/asio/detail/deadline_timer_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/timer_scheduler.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/timer_scheduler.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/timer_scheduler_fwd.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/timer_scheduler_fwd.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > > > > > >typedef class epoll_reactor timer_scheduler; ># 38 "/usr/include/boost/asio/detail/timer_scheduler_fwd.hpp" 3 4 >} >} >} ># 20 "/usr/include/boost/asio/detail/timer_scheduler.hpp" 2 3 4 ># 30 "/usr/include/boost/asio/detail/deadline_timer_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/wait_handler.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/wait_handler.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/wait_handler.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Handler> >class wait_handler : public wait_op >{ >public: > struct ptr { Handler* h; void* v; wait_handler* p; ~ptr() { reset(); } void reset() { if (p) { p->~wait_handler(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(wait_handler), *h); v = 0; } } }; > > wait_handler(Handler& h) > : wait_op(&wait_handler::do_complete), > handler_(static_cast<Handler&&>(h)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > wait_handler* h(static_cast<wait_handler*>(base)); > ptr p = { boost::asio::detail::addressof(h->handler_), h, h }; > > (void)0; > > > > > > > > detail::binder1<Handler, boost::system::error_code> > handler(h->handler_, h->ec_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 84 "/usr/include/boost/asio/detail/wait_handler.hpp" 2 3 4 ># 31 "/usr/include/boost/asio/detail/deadline_timer_service.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 39 "/usr/include/boost/asio/detail/deadline_timer_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Time_Traits> >class deadline_timer_service >{ >public: > > typedef typename Time_Traits::time_type time_type; > > > typedef typename Time_Traits::duration_type duration_type; > > > > struct implementation_type > : private boost::asio::detail::noncopyable > { > time_type expiry; > bool might_have_pending_waits; > typename timer_queue<Time_Traits>::per_timer_data timer_data; > }; > > > deadline_timer_service(boost::asio::io_service& io_service) > : scheduler_(boost::asio::use_service<timer_scheduler>(io_service)) > { > scheduler_.init_task(); > scheduler_.add_timer_queue(timer_queue_); > } > > > ~deadline_timer_service() > { > scheduler_.remove_timer_queue(timer_queue_); > } > > > void shutdown_service() > { > } > > > void construct(implementation_type& impl) > { > impl.expiry = time_type(); > impl.might_have_pending_waits = false; > } > > > void destroy(implementation_type& impl) > { > boost::system::error_code ec; > cancel(impl, ec); > } > > > std::size_t cancel(implementation_type& impl, boost::system::error_code& ec) > { > if (!impl.might_have_pending_waits) > { > ec = boost::system::error_code(); > return 0; > } > > (void)0; > > std::size_t count = scheduler_.cancel_timer(timer_queue_, impl.timer_data); > impl.might_have_pending_waits = false; > ec = boost::system::error_code(); > return count; > } > > > std::size_t cancel_one(implementation_type& impl, > boost::system::error_code& ec) > { > if (!impl.might_have_pending_waits) > { > ec = boost::system::error_code(); > return 0; > } > > (void)0; > > std::size_t count = scheduler_.cancel_timer( > timer_queue_, impl.timer_data, 1); > if (count == 0) > impl.might_have_pending_waits = false; > ec = boost::system::error_code(); > return count; > } > > > time_type expires_at(const implementation_type& impl) const > { > return impl.expiry; > } > > > std::size_t expires_at(implementation_type& impl, > const time_type& expiry_time, boost::system::error_code& ec) > { > std::size_t count = cancel(impl, ec); > impl.expiry = expiry_time; > ec = boost::system::error_code(); > return count; > } > > > duration_type expires_from_now(const implementation_type& impl) const > { > return Time_Traits::subtract(expires_at(impl), Time_Traits::now()); > } > > > std::size_t expires_from_now(implementation_type& impl, > const duration_type& expiry_time, boost::system::error_code& ec) > { > return expires_at(impl, > Time_Traits::add(Time_Traits::now(), expiry_time), ec); > } > > > void wait(implementation_type& impl, boost::system::error_code& ec) > { > time_type now = Time_Traits::now(); > ec = boost::system::error_code(); > while (Time_Traits::less_than(now, impl.expiry) && !ec) > { > this->do_wait(Time_Traits::to_posix_duration( > Time_Traits::subtract(impl.expiry, now)), ec); > now = Time_Traits::now(); > } > } > > > template <typename Handler> > void async_wait(implementation_type& impl, Handler& handler) > { > > typedef wait_handler<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > impl.might_have_pending_waits = true; > > (void)0; > > scheduler_.schedule_timer(timer_queue_, impl.expiry, impl.timer_data, p.p); > p.v = p.p = 0; > } > >private: > > > > template <typename Duration> > void do_wait(const Duration& timeout, boost::system::error_code& ec) > { > > > > > > > ::timeval tv; > tv.tv_sec = timeout.total_seconds(); > tv.tv_usec = timeout.total_microseconds() % 1000000; > socket_ops::select(0, 0, 0, 0, &tv, ec); > > } > > > timer_queue<Time_Traits> timer_queue_; > > > timer_scheduler& scheduler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 228 "/usr/include/boost/asio/detail/deadline_timer_service.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/deadline_timer_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/time_traits.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/time_traits.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/time_traits.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/time_traits.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/time_traits.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >template <typename Time> >struct time_traits; > > >template <> >struct time_traits<boost::posix_time::ptime> >{ > > typedef boost::posix_time::ptime time_type; > > > typedef boost::posix_time::time_duration duration_type; > > > static time_type now() > { > > return boost::posix_time::microsec_clock::universal_time(); > > > > } > > > static time_type add(const time_type& t, const duration_type& d) > { > return t + d; > } > > > static duration_type subtract(const time_type& t1, const time_type& t2) > { > return t1 - t2; > } > > > static bool less_than(const time_type& t1, const time_type& t2) > { > return t1 < t2; > } > > > static boost::posix_time::time_duration to_posix_duration( > const duration_type& d) > { > return d; > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 86 "/usr/include/boost/asio/time_traits.hpp" 2 3 4 ># 28 "/usr/include/boost/asio/deadline_timer_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/timer_queue_ptime.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/timer_queue_ptime.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/timer_queue_ptime.hpp" 2 3 4 > > > >namespace boost { >namespace asio { >namespace detail { > >struct forwarding_posix_time_traits : time_traits<boost::posix_time::ptime> {}; > > >template <> >class timer_queue<time_traits<boost::posix_time::ptime> > > : public timer_queue_base >{ >public: > > typedef boost::posix_time::ptime time_type; > > > typedef boost::posix_time::time_duration duration_type; > > > typedef timer_queue<forwarding_posix_time_traits>::per_timer_data > per_timer_data; > > > inline timer_queue(); > > > inline virtual ~timer_queue(); > > > > > inline bool enqueue_timer(const time_type& time, > per_timer_data& timer, wait_op* op); > > > inline virtual bool empty() const; > > > inline virtual long wait_duration_msec(long max_duration) const; > > > inline virtual long wait_duration_usec(long max_duration) const; > > > inline virtual void get_ready_timers(op_queue<operation>& ops); > > > inline virtual void get_all_timers(op_queue<operation>& ops); > > > inline std::size_t cancel_timer( > per_timer_data& timer, op_queue<operation>& ops, > std::size_t max_cancelled = (std::numeric_limits<std::size_t>::max)()); > >private: > timer_queue<forwarding_posix_time_traits> impl_; >}; > >} >} >} > > > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 90 "/usr/include/boost/asio/detail/timer_queue_ptime.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/timer_queue_ptime.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/impl/timer_queue_ptime.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/timer_queue_ptime.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/impl/timer_queue_ptime.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/impl/timer_queue_ptime.ipp" 2 3 4 > > > >namespace boost { >namespace asio { >namespace detail { > >timer_queue<time_traits<boost::posix_time::ptime> >::timer_queue() >{ >} > >timer_queue<time_traits<boost::posix_time::ptime> >::~timer_queue() >{ >} > >bool timer_queue<time_traits<boost::posix_time::ptime> >::enqueue_timer( > const time_type& time, per_timer_data& timer, wait_op* op) >{ > return impl_.enqueue_timer(time, timer, op); >} > >bool timer_queue<time_traits<boost::posix_time::ptime> >::empty() const >{ > return impl_.empty(); >} > >long timer_queue<time_traits<boost::posix_time::ptime> >::wait_duration_msec( > long max_duration) const >{ > return impl_.wait_duration_msec(max_duration); >} > >long timer_queue<time_traits<boost::posix_time::ptime> >::wait_duration_usec( > long max_duration) const >{ > return impl_.wait_duration_usec(max_duration); >} > >void timer_queue<time_traits<boost::posix_time::ptime> >::get_ready_timers( > op_queue<operation>& ops) >{ > impl_.get_ready_timers(ops); >} > >void timer_queue<time_traits<boost::posix_time::ptime> >::get_all_timers( > op_queue<operation>& ops) >{ > impl_.get_all_timers(ops); >} > >std::size_t timer_queue<time_traits<boost::posix_time::ptime> >::cancel_timer( > per_timer_data& timer, op_queue<operation>& ops, std::size_t max_cancelled) >{ > return impl_.cancel_timer(timer, ops, max_cancelled); >} > >} >} >} > > > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 85 "/usr/include/boost/asio/detail/impl/timer_queue_ptime.ipp" 2 3 4 ># 93 "/usr/include/boost/asio/detail/timer_queue_ptime.hpp" 2 3 4 ># 29 "/usr/include/boost/asio/deadline_timer_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/deadline_timer_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >template <typename TimeType, > typename TimeTraits = boost::asio::time_traits<TimeType> > >class deadline_timer_service > > > > : public boost::asio::detail::service_base< > deadline_timer_service<TimeType, TimeTraits> > > >{ >public: > > > > > > > typedef TimeTraits traits_type; > > > typedef typename traits_type::time_type time_type; > > > typedef typename traits_type::duration_type duration_type; > >private: > > typedef detail::deadline_timer_service<traits_type> service_impl_type; > >public: > > > > > typedef typename service_impl_type::implementation_type implementation_type; > > > > explicit deadline_timer_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base< > deadline_timer_service<TimeType, TimeTraits> >(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > std::size_t cancel(implementation_type& impl, boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > std::size_t cancel_one(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel_one(impl, ec); > } > > > time_type expires_at(const implementation_type& impl) const > { > return service_impl_.expires_at(impl); > } > > > std::size_t expires_at(implementation_type& impl, > const time_type& expiry_time, boost::system::error_code& ec) > { > return service_impl_.expires_at(impl, expiry_time, ec); > } > > > duration_type expires_from_now(const implementation_type& impl) const > { > return service_impl_.expires_from_now(impl); > } > > > std::size_t expires_from_now(implementation_type& impl, > const duration_type& expiry_time, boost::system::error_code& ec) > { > return service_impl_.expires_from_now(impl, expiry_time, ec); > } > > > void wait(implementation_type& impl, boost::system::error_code& ec) > { > service_impl_.wait(impl, ec); > } > > > template <typename WaitHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WaitHandler, void (boost::system::error_code)>::type>::type > > async_wait(implementation_type& impl, > WaitHandler&& handler) > { > detail::async_result_init< > WaitHandler, void (boost::system::error_code)> init( > static_cast<WaitHandler&&>(handler)); > > service_impl_.async_wait(impl, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > service_impl_type service_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 169 "/usr/include/boost/asio/deadline_timer_service.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/basic_deadline_timer.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/basic_deadline_timer.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 123 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 >template <typename Time, > typename TimeTraits = boost::asio::time_traits<Time>, > typename TimerService = deadline_timer_service<Time, TimeTraits> > >class basic_deadline_timer > : public basic_io_object<TimerService> >{ >public: > > typedef TimeTraits traits_type; > > > typedef typename traits_type::time_type time_type; > > > typedef typename traits_type::duration_type duration_type; ># 148 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > explicit basic_deadline_timer(boost::asio::io_service& io_service) > : basic_io_object<TimerService>(io_service) > { > } ># 163 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > basic_deadline_timer(boost::asio::io_service& io_service, > const time_type& expiry_time) > : basic_io_object<TimerService>(io_service) > { > boost::system::error_code ec; > this->service.expires_at(this->implementation, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_at"); > } ># 182 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > basic_deadline_timer(boost::asio::io_service& io_service, > const duration_type& expiry_time) > : basic_io_object<TimerService>(io_service) > { > boost::system::error_code ec; > this->service.expires_from_now(this->implementation, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_from_now"); > } ># 213 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > std::size_t cancel() > { > boost::system::error_code ec; > std::size_t s = this->service.cancel(this->implementation, ec); > boost::asio::detail::throw_error(ec, "cancel"); > return s; > } ># 243 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > std::size_t cancel(boost::system::error_code& ec) > { > return this->service.cancel(this->implementation, ec); > } ># 272 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > std::size_t cancel_one() > { > boost::system::error_code ec; > std::size_t s = this->service.cancel_one(this->implementation, ec); > boost::asio::detail::throw_error(ec, "cancel_one"); > return s; > } ># 304 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > std::size_t cancel_one(boost::system::error_code& ec) > { > return this->service.cancel_one(this->implementation, ec); > } > > > > > > > time_type expires_at() const > { > return this->service.expires_at(this->implementation); > } ># 341 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > std::size_t expires_at(const time_type& expiry_time) > { > boost::system::error_code ec; > std::size_t s = this->service.expires_at( > this->implementation, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_at"); > return s; > } ># 372 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > std::size_t expires_at(const time_type& expiry_time, > boost::system::error_code& ec) > { > return this->service.expires_at(this->implementation, expiry_time, ec); > } > > > > > > > duration_type expires_from_now() const > { > return this->service.expires_from_now(this->implementation); > } ># 410 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > std::size_t expires_from_now(const duration_type& expiry_time) > { > boost::system::error_code ec; > std::size_t s = this->service.expires_from_now( > this->implementation, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_from_now"); > return s; > } ># 441 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > std::size_t expires_from_now(const duration_type& expiry_time, > boost::system::error_code& ec) > { > return this->service.expires_from_now( > this->implementation, expiry_time, ec); > } ># 455 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > void wait() > { > boost::system::error_code ec; > this->service.wait(this->implementation, ec); > boost::asio::detail::throw_error(ec, "wait"); > } ># 469 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > void wait(boost::system::error_code& ec) > { > this->service.wait(this->implementation, ec); > } ># 498 "/usr/include/boost/asio/basic_deadline_timer.hpp" 3 4 > template <typename WaitHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WaitHandler, void (boost::system::error_code)>::type>::type > > async_wait(WaitHandler&& handler) > { > > > typedef typename handler_type<WaitHandler, void(boost::system::error_code)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::one_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0))) == 1, "WaitHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>()), char(0))> __attribute__((__unused__)) type_check; > > return this->service.async_wait(this->implementation, > static_cast<WaitHandler&&>(handler)); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 516 "/usr/include/boost/asio/basic_deadline_timer.hpp" 2 3 4 ># 23 "/usr/include/boost/asio.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/basic_raw_socket.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 ># 1 "/usr/include/boost/asio/raw_socket_service.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/raw_socket_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 34 "/usr/include/boost/asio/raw_socket_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >template <typename Protocol> >class raw_socket_service > > > > : public boost::asio::detail::service_base<raw_socket_service<Protocol> > > >{ >public: > > > > > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; > >private: > > > > > > > typedef detail::reactive_socket_service<Protocol> service_impl_type; > > >public: > > > > > typedef typename service_impl_type::implementation_type implementation_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_handle_type; > > > > explicit raw_socket_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base< > raw_socket_service<Protocol> >(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > > void move_construct(implementation_type& impl, > implementation_type& other_impl) > { > service_impl_.move_construct(impl, other_impl); > } > > > void move_assign(implementation_type& impl, > raw_socket_service& other_service, > implementation_type& other_impl) > { > service_impl_.move_assign(impl, other_service.service_impl_, other_impl); > } > > > > template <typename Protocol1> > void converting_move_construct(implementation_type& impl, > typename raw_socket_service< > Protocol1>::implementation_type& other_impl, > typename enable_if<is_convertible< > Protocol1, Protocol>::value>::type* = 0) > { > service_impl_.template converting_move_construct<Protocol1>( > impl, other_impl); > } > > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > boost::system::error_code open(implementation_type& impl, > const protocol_type& protocol, boost::system::error_code& ec) > { > if (protocol.type() == SOCK_RAW) > service_impl_.open(impl, protocol, ec); > else > ec = boost::asio::error::invalid_argument; > return ec; > } > > > boost::system::error_code assign(implementation_type& impl, > const protocol_type& protocol, const native_handle_type& native_socket, > boost::system::error_code& ec) > { > return service_impl_.assign(impl, protocol, native_socket, ec); > } > > > bool is_open(const implementation_type& impl) const > { > return service_impl_.is_open(impl); > } > > > boost::system::error_code close(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.close(impl, ec); > } > > > native_type native(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > native_handle_type native_handle(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > bool at_mark(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.at_mark(impl, ec); > } > > > std::size_t available(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.available(impl, ec); > } > > > boost::system::error_code bind(implementation_type& impl, > const endpoint_type& endpoint, boost::system::error_code& ec) > { > return service_impl_.bind(impl, endpoint, ec); > } > > > boost::system::error_code connect(implementation_type& impl, > const endpoint_type& peer_endpoint, boost::system::error_code& ec) > { > return service_impl_.connect(impl, peer_endpoint, ec); > } > > > template <typename ConnectHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ConnectHandler, void (boost::system::error_code)>::type>::type > > async_connect(implementation_type& impl, > const endpoint_type& peer_endpoint, > ConnectHandler&& handler) > { > detail::async_result_init< > ConnectHandler, void (boost::system::error_code)> init( > static_cast<ConnectHandler&&>(handler)); > > service_impl_.async_connect(impl, peer_endpoint, init.handler); > > return init.result.get(); > } > > > template <typename SettableSocketOption> > boost::system::error_code set_option(implementation_type& impl, > const SettableSocketOption& option, boost::system::error_code& ec) > { > return service_impl_.set_option(impl, option, ec); > } > > > template <typename GettableSocketOption> > boost::system::error_code get_option(const implementation_type& impl, > GettableSocketOption& option, boost::system::error_code& ec) const > { > return service_impl_.get_option(impl, option, ec); > } > > > template <typename IoControlCommand> > boost::system::error_code io_control(implementation_type& impl, > IoControlCommand& command, boost::system::error_code& ec) > { > return service_impl_.io_control(impl, command, ec); > } > > > bool non_blocking(const implementation_type& impl) const > { > return service_impl_.non_blocking(impl); > } > > > boost::system::error_code non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.non_blocking(impl, mode, ec); > } > > > bool native_non_blocking(const implementation_type& impl) const > { > return service_impl_.native_non_blocking(impl); > } > > > boost::system::error_code native_non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.native_non_blocking(impl, mode, ec); > } > > > endpoint_type local_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.local_endpoint(impl, ec); > } > > > endpoint_type remote_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.remote_endpoint(impl, ec); > } > > > boost::system::error_code shutdown(implementation_type& impl, > socket_base::shutdown_type what, boost::system::error_code& ec) > { > return service_impl_.shutdown(impl, what, ec); > } > > > template <typename ConstBufferSequence> > std::size_t send(implementation_type& impl, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.send(impl, buffers, flags, ec); > } > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(implementation_type& impl, const ConstBufferSequence& buffers, > socket_base::message_flags flags, > WriteHandler&& handler) > { > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > service_impl_.async_send(impl, buffers, flags, init.handler); > > return init.result.get(); > } > > > template <typename ConstBufferSequence> > std::size_t send_to(implementation_type& impl, > const ConstBufferSequence& buffers, const endpoint_type& destination, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.send_to(impl, buffers, destination, flags, ec); > } > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send_to(implementation_type& impl, > const ConstBufferSequence& buffers, const endpoint_type& destination, > socket_base::message_flags flags, > WriteHandler&& handler) > { > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > service_impl_.async_send_to(impl, buffers, > destination, flags, init.handler); > > return init.result.get(); > } > > > template <typename MutableBufferSequence> > std::size_t receive(implementation_type& impl, > const MutableBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.receive(impl, buffers, flags, ec); > } > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(implementation_type& impl, > const MutableBufferSequence& buffers, > socket_base::message_flags flags, > ReadHandler&& handler) > { > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > service_impl_.async_receive(impl, buffers, flags, init.handler); > > return init.result.get(); > } > > > template <typename MutableBufferSequence> > std::size_t receive_from(implementation_type& impl, > const MutableBufferSequence& buffers, endpoint_type& sender_endpoint, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.receive_from(impl, buffers, sender_endpoint, flags, > ec); > } > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive_from(implementation_type& impl, > const MutableBufferSequence& buffers, endpoint_type& sender_endpoint, > socket_base::message_flags flags, > ReadHandler&& handler) > { > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > service_impl_.async_receive_from(impl, buffers, > sender_endpoint, flags, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > service_impl_type service_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 433 "/usr/include/boost/asio/raw_socket_service.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/basic_raw_socket.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/basic_raw_socket.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 41 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 >template <typename Protocol, > typename RawSocketService = raw_socket_service<Protocol> > >class basic_raw_socket > : public basic_socket<Protocol, RawSocketService> >{ >public: > > > typedef typename RawSocketService::native_handle_type native_type; > > > typedef typename RawSocketService::native_handle_type native_handle_type; > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; ># 69 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > explicit basic_raw_socket(boost::asio::io_service& io_service) > : basic_socket<Protocol, RawSocketService>(io_service) > { > } ># 86 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > basic_raw_socket(boost::asio::io_service& io_service, > const protocol_type& protocol) > : basic_socket<Protocol, RawSocketService>(io_service, protocol) > { > } ># 108 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > basic_raw_socket(boost::asio::io_service& io_service, > const endpoint_type& endpoint) > : basic_socket<Protocol, RawSocketService>(io_service, endpoint) > { > } ># 129 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > basic_raw_socket(boost::asio::io_service& io_service, > const protocol_type& protocol, const native_handle_type& native_socket) > : basic_socket<Protocol, RawSocketService>( > io_service, protocol, native_socket) > { > } ># 147 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > basic_raw_socket(basic_raw_socket&& other) > : basic_socket<Protocol, RawSocketService>( > static_cast<basic_raw_socket&&>(other)) > { > } ># 163 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > basic_raw_socket& operator=(basic_raw_socket&& other) > { > basic_socket<Protocol, RawSocketService>::operator=( > static_cast<basic_raw_socket&&>(other)); > return *this; > } ># 180 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename Protocol1, typename RawSocketService1> > basic_raw_socket(basic_raw_socket<Protocol1, RawSocketService1>&& other, > typename enable_if<is_convertible<Protocol1, Protocol>::value>::type* = 0) > : basic_socket<Protocol, RawSocketService>( > static_cast<basic_raw_socket< Protocol1, RawSocketService1>&&> > (other)) > { > } ># 199 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename Protocol1, typename RawSocketService1> > typename enable_if<is_convertible<Protocol1, Protocol>::value, > basic_raw_socket>::type& operator=( > basic_raw_socket<Protocol1, RawSocketService1>&& other) > { > basic_socket<Protocol, RawSocketService>::operator=( > static_cast<basic_raw_socket< Protocol1, RawSocketService1>&&> > (other)); > return *this; > } ># 232 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send( > this->get_implementation(), buffers, 0, ec); > boost::asio::detail::throw_error(ec, "send"); > return s; > } ># 258 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers, > socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send( > this->get_implementation(), buffers, flags, ec); > boost::asio::detail::throw_error(ec, "send"); > return s; > } ># 285 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return this->get_service().send( > this->get_implementation(), buffers, flags, ec); > } ># 328 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send(this->get_implementation(), > buffers, 0, static_cast<WriteHandler&&>(handler)); > } ># 370 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(const ConstBufferSequence& buffers, > socket_base::message_flags flags, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send(this->get_implementation(), > buffers, flags, static_cast<WriteHandler&&>(handler)); > } ># 410 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send_to( > this->get_implementation(), buffers, destination, 0, ec); > boost::asio::detail::throw_error(ec, "send_to"); > return s; > } ># 437 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination, socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send_to( > this->get_implementation(), buffers, destination, flags, ec); > boost::asio::detail::throw_error(ec, "send_to"); > return s; > } ># 464 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination, socket_base::message_flags flags, > boost::system::error_code& ec) > { > return this->get_service().send_to(this->get_implementation(), > buffers, destination, flags, ec); > } ># 510 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send_to(this->get_implementation(), > buffers, destination, 0, static_cast<WriteHandler&&>(handler)); > } ># 552 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send_to(const ConstBufferSequence& buffers, > const endpoint_type& destination, socket_base::message_flags flags, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send_to( > this->get_implementation(), buffers, destination, flags, > static_cast<WriteHandler&&>(handler)); > } ># 592 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive( > this->get_implementation(), buffers, 0, ec); > boost::asio::detail::throw_error(ec, "receive"); > return s; > } ># 620 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers, > socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive( > this->get_implementation(), buffers, flags, ec); > boost::asio::detail::throw_error(ec, "receive"); > return s; > } ># 649 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return this->get_service().receive( > this->get_implementation(), buffers, flags, ec); > } ># 693 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive(this->get_implementation(), > buffers, 0, static_cast<ReadHandler&&>(handler)); > } ># 735 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(const MutableBufferSequence& buffers, > socket_base::message_flags flags, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive(this->get_implementation(), > buffers, flags, static_cast<ReadHandler&&>(handler)); > } ># 776 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive_from( > this->get_implementation(), buffers, sender_endpoint, 0, ec); > boost::asio::detail::throw_error(ec, "receive_from"); > return s; > } ># 803 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint, socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive_from( > this->get_implementation(), buffers, sender_endpoint, flags, ec); > boost::asio::detail::throw_error(ec, "receive_from"); > return s; > } ># 830 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint, socket_base::message_flags flags, > boost::system::error_code& ec) > { > return this->get_service().receive_from(this->get_implementation(), > buffers, sender_endpoint, flags, ec); > } ># 875 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive_from( > this->get_implementation(), buffers, sender_endpoint, 0, > static_cast<ReadHandler&&>(handler)); > } ># 920 "/usr/include/boost/asio/basic_raw_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive_from(const MutableBufferSequence& buffers, > endpoint_type& sender_endpoint, socket_base::message_flags flags, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive_from( > this->get_implementation(), buffers, sender_endpoint, flags, > static_cast<ReadHandler&&>(handler)); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 941 "/usr/include/boost/asio/basic_raw_socket.hpp" 2 3 4 ># 25 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 ># 1 "/usr/include/boost/asio/seq_packet_socket_service.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/seq_packet_socket_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 34 "/usr/include/boost/asio/seq_packet_socket_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >template <typename Protocol> >class seq_packet_socket_service > > > > : public boost::asio::detail::service_base< > seq_packet_socket_service<Protocol> > > >{ >public: > > > > > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; > >private: > > > > > > > typedef detail::reactive_socket_service<Protocol> service_impl_type; > > >public: > > > > > typedef typename service_impl_type::implementation_type implementation_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_handle_type; > > > > > explicit seq_packet_socket_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base< > seq_packet_socket_service<Protocol> >(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > > void move_construct(implementation_type& impl, > implementation_type& other_impl) > { > service_impl_.move_construct(impl, other_impl); > } > > > void move_assign(implementation_type& impl, > seq_packet_socket_service& other_service, > implementation_type& other_impl) > { > service_impl_.move_assign(impl, other_service.service_impl_, other_impl); > } > > > > template <typename Protocol1> > void converting_move_construct(implementation_type& impl, > typename seq_packet_socket_service< > Protocol1>::implementation_type& other_impl, > typename enable_if<is_convertible< > Protocol1, Protocol>::value>::type* = 0) > { > service_impl_.template converting_move_construct<Protocol1>( > impl, other_impl); > } > > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > boost::system::error_code open(implementation_type& impl, > const protocol_type& protocol, boost::system::error_code& ec) > { > if (protocol.type() == SOCK_SEQPACKET) > service_impl_.open(impl, protocol, ec); > else > ec = boost::asio::error::invalid_argument; > return ec; > } > > > boost::system::error_code assign(implementation_type& impl, > const protocol_type& protocol, const native_handle_type& native_socket, > boost::system::error_code& ec) > { > return service_impl_.assign(impl, protocol, native_socket, ec); > } > > > bool is_open(const implementation_type& impl) const > { > return service_impl_.is_open(impl); > } > > > boost::system::error_code close(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.close(impl, ec); > } > > > native_type native(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > native_handle_type native_handle(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > bool at_mark(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.at_mark(impl, ec); > } > > > std::size_t available(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.available(impl, ec); > } > > > boost::system::error_code bind(implementation_type& impl, > const endpoint_type& endpoint, boost::system::error_code& ec) > { > return service_impl_.bind(impl, endpoint, ec); > } > > > boost::system::error_code connect(implementation_type& impl, > const endpoint_type& peer_endpoint, boost::system::error_code& ec) > { > return service_impl_.connect(impl, peer_endpoint, ec); > } > > > template <typename ConnectHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ConnectHandler, void (boost::system::error_code)>::type>::type > > async_connect(implementation_type& impl, > const endpoint_type& peer_endpoint, > ConnectHandler&& handler) > { > detail::async_result_init< > ConnectHandler, void (boost::system::error_code)> init( > static_cast<ConnectHandler&&>(handler)); > > service_impl_.async_connect(impl, peer_endpoint, init.handler); > > return init.result.get(); > } > > > template <typename SettableSocketOption> > boost::system::error_code set_option(implementation_type& impl, > const SettableSocketOption& option, boost::system::error_code& ec) > { > return service_impl_.set_option(impl, option, ec); > } > > > template <typename GettableSocketOption> > boost::system::error_code get_option(const implementation_type& impl, > GettableSocketOption& option, boost::system::error_code& ec) const > { > return service_impl_.get_option(impl, option, ec); > } > > > template <typename IoControlCommand> > boost::system::error_code io_control(implementation_type& impl, > IoControlCommand& command, boost::system::error_code& ec) > { > return service_impl_.io_control(impl, command, ec); > } > > > bool non_blocking(const implementation_type& impl) const > { > return service_impl_.non_blocking(impl); > } > > > boost::system::error_code non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.non_blocking(impl, mode, ec); > } > > > bool native_non_blocking(const implementation_type& impl) const > { > return service_impl_.native_non_blocking(impl); > } > > > boost::system::error_code native_non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.native_non_blocking(impl, mode, ec); > } > > > endpoint_type local_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.local_endpoint(impl, ec); > } > > > endpoint_type remote_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.remote_endpoint(impl, ec); > } > > > boost::system::error_code shutdown(implementation_type& impl, > socket_base::shutdown_type what, boost::system::error_code& ec) > { > return service_impl_.shutdown(impl, what, ec); > } > > > template <typename ConstBufferSequence> > std::size_t send(implementation_type& impl, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.send(impl, buffers, flags, ec); > } > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(implementation_type& impl, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, > WriteHandler&& handler) > { > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > service_impl_.async_send(impl, buffers, flags, init.handler); > > return init.result.get(); > } > > > template <typename MutableBufferSequence> > std::size_t receive(implementation_type& impl, > const MutableBufferSequence& buffers, socket_base::message_flags in_flags, > socket_base::message_flags& out_flags, boost::system::error_code& ec) > { > return service_impl_.receive_with_flags(impl, > buffers, in_flags, out_flags, ec); > } > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(implementation_type& impl, > const MutableBufferSequence& buffers, socket_base::message_flags in_flags, > socket_base::message_flags& out_flags, > ReadHandler&& handler) > { > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > service_impl_.async_receive_with_flags(impl, > buffers, in_flags, out_flags, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > service_impl_type service_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 381 "/usr/include/boost/asio/seq_packet_socket_service.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 40 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 >template <typename Protocol, > typename SeqPacketSocketService = seq_packet_socket_service<Protocol> > >class basic_seq_packet_socket > : public basic_socket<Protocol, SeqPacketSocketService> >{ >public: > > > typedef typename SeqPacketSocketService::native_handle_type native_type; > > > typedef typename SeqPacketSocketService::native_handle_type > native_handle_type; > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; ># 70 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > explicit basic_seq_packet_socket(boost::asio::io_service& io_service) > : basic_socket<Protocol, SeqPacketSocketService>(io_service) > { > } ># 89 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > basic_seq_packet_socket(boost::asio::io_service& io_service, > const protocol_type& protocol) > : basic_socket<Protocol, SeqPacketSocketService>(io_service, protocol) > { > } ># 111 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > basic_seq_packet_socket(boost::asio::io_service& io_service, > const endpoint_type& endpoint) > : basic_socket<Protocol, SeqPacketSocketService>(io_service, endpoint) > { > } ># 132 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > basic_seq_packet_socket(boost::asio::io_service& io_service, > const protocol_type& protocol, const native_handle_type& native_socket) > : basic_socket<Protocol, SeqPacketSocketService>( > io_service, protocol, native_socket) > { > } ># 151 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > basic_seq_packet_socket(basic_seq_packet_socket&& other) > : basic_socket<Protocol, SeqPacketSocketService>( > static_cast<basic_seq_packet_socket&&>(other)) > { > } ># 168 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > basic_seq_packet_socket& operator=(basic_seq_packet_socket&& other) > { > basic_socket<Protocol, SeqPacketSocketService>::operator=( > static_cast<basic_seq_packet_socket&&>(other)); > return *this; > } ># 187 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename Protocol1, typename SeqPacketSocketService1> > basic_seq_packet_socket( > basic_seq_packet_socket<Protocol1, SeqPacketSocketService1>&& other, > typename enable_if<is_convertible<Protocol1, Protocol>::value>::type* = 0) > : basic_socket<Protocol, SeqPacketSocketService>( > static_cast<basic_seq_packet_socket< Protocol1, SeqPacketSocketService1>&&> > (other)) > { > } ># 209 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename Protocol1, typename SeqPacketSocketService1> > typename enable_if<is_convertible<Protocol1, Protocol>::value, > basic_seq_packet_socket>::type& operator=( > basic_seq_packet_socket<Protocol1, SeqPacketSocketService1>&& other) > { > basic_socket<Protocol, SeqPacketSocketService>::operator=( > static_cast<basic_seq_packet_socket< Protocol1, SeqPacketSocketService1>&&> > (other)); > return *this; > } ># 244 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers, > socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send( > this->get_implementation(), buffers, flags, ec); > boost::asio::detail::throw_error(ec, "send"); > return s; > } ># 273 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return this->get_service().send( > this->get_implementation(), buffers, flags, ec); > } ># 314 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(const ConstBufferSequence& buffers, > socket_base::message_flags flags, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send(this->get_implementation(), > buffers, flags, static_cast<WriteHandler&&>(handler)); > } ># 358 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers, > socket_base::message_flags& out_flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive( > this->get_implementation(), buffers, 0, out_flags, ec); > boost::asio::detail::throw_error(ec, "receive"); > return s; > } ># 404 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers, > socket_base::message_flags in_flags, > socket_base::message_flags& out_flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive( > this->get_implementation(), buffers, in_flags, out_flags, ec); > boost::asio::detail::throw_error(ec, "receive"); > return s; > } ># 439 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers, > socket_base::message_flags in_flags, > socket_base::message_flags& out_flags, boost::system::error_code& ec) > { > return this->get_service().receive(this->get_implementation(), > buffers, in_flags, out_flags, ec); > } ># 486 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(const MutableBufferSequence& buffers, > socket_base::message_flags& out_flags, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive( > this->get_implementation(), buffers, 0, out_flags, > static_cast<ReadHandler&&>(handler)); > } ># 544 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(const MutableBufferSequence& buffers, > socket_base::message_flags in_flags, > socket_base::message_flags& out_flags, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive( > this->get_implementation(), buffers, in_flags, out_flags, > static_cast<ReadHandler&&>(handler)); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 566 "/usr/include/boost/asio/basic_seq_packet_socket.hpp" 2 3 4 ># 26 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/basic_serial_port.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 ># 1 "/usr/include/boost/asio/serial_port_base.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/serial_port_base.hpp" 3 4 ># 1 "/usr/include/termios.h" 1 3 4 ># 35 "/usr/include/termios.h" 3 4 >extern "C" { > > > ># 1 "/usr/include/bits/termios.h" 1 3 4 ># 23 "/usr/include/bits/termios.h" 3 4 >typedef unsigned char cc_t; >typedef unsigned int speed_t; >typedef unsigned int tcflag_t; > > >struct termios > { > tcflag_t c_iflag; > tcflag_t c_oflag; > tcflag_t c_cflag; > tcflag_t c_lflag; > cc_t c_line; > cc_t c_cc[32]; > speed_t c_ispeed; > speed_t c_ospeed; > > > }; ># 40 "/usr/include/termios.h" 2 3 4 ># 48 "/usr/include/termios.h" 3 4 >extern speed_t cfgetospeed (const struct termios *__termios_p) throw (); > > >extern speed_t cfgetispeed (const struct termios *__termios_p) throw (); > > >extern int cfsetospeed (struct termios *__termios_p, speed_t __speed) throw (); > > >extern int cfsetispeed (struct termios *__termios_p, speed_t __speed) throw (); > > > >extern int cfsetspeed (struct termios *__termios_p, speed_t __speed) throw (); > > > > >extern int tcgetattr (int __fd, struct termios *__termios_p) throw (); > > > >extern int tcsetattr (int __fd, int __optional_actions, > const struct termios *__termios_p) throw (); > > > > >extern void cfmakeraw (struct termios *__termios_p) throw (); > > > >extern int tcsendbreak (int __fd, int __duration) throw (); > > > > > >extern int tcdrain (int __fd); > > > >extern int tcflush (int __fd, int __queue_selector) throw (); > > > >extern int tcflow (int __fd, int __action) throw (); > > > > >extern __pid_t tcgetsid (int __fd) throw (); > > > > ># 1 "/usr/include/sys/ttydefaults.h" 1 3 4 ># 105 "/usr/include/termios.h" 2 3 4 > > >} ># 26 "/usr/include/boost/asio/serial_port_base.hpp" 2 3 4 ># 39 "/usr/include/boost/asio/serial_port_base.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 40 "/usr/include/boost/asio/serial_port_base.hpp" 2 3 4 > >namespace boost { >namespace asio { > > > >class serial_port_base >{ >public: > > > > > class baud_rate > { > public: > explicit baud_rate(unsigned int rate = 0); > unsigned int value() const; > inline boost::system::error_code store( > termios& storage, > boost::system::error_code& ec) const; > inline boost::system::error_code load( > const termios& storage, > boost::system::error_code& ec); > private: > unsigned int value_; > }; > > > > > > class flow_control > { > public: > enum type { none, software, hardware }; > inline explicit flow_control(type t = none); > type value() const; > inline boost::system::error_code store( > termios& storage, > boost::system::error_code& ec) const; > inline boost::system::error_code load( > const termios& storage, > boost::system::error_code& ec); > private: > type value_; > }; > > > > > > class parity > { > public: > enum type { none, odd, even }; > inline explicit parity(type t = none); > type value() const; > inline boost::system::error_code store( > termios& storage, > boost::system::error_code& ec) const; > inline boost::system::error_code load( > const termios& storage, > boost::system::error_code& ec); > private: > type value_; > }; > > > > > > class stop_bits > { > public: > enum type { one, onepointfive, two }; > inline explicit stop_bits(type t = one); > type value() const; > inline boost::system::error_code store( > termios& storage, > boost::system::error_code& ec) const; > inline boost::system::error_code load( > const termios& storage, > boost::system::error_code& ec); > private: > type value_; > }; > > > > > > class character_size > { > public: > inline explicit character_size(unsigned int t = 8); > unsigned int value() const; > inline boost::system::error_code store( > termios& storage, > boost::system::error_code& ec) const; > inline boost::system::error_code load( > const termios& storage, > boost::system::error_code& ec); > private: > unsigned int value_; > }; > >protected: > > ~serial_port_base() > { > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 158 "/usr/include/boost/asio/serial_port_base.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/impl/serial_port_base.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/impl/serial_port_base.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/impl/serial_port_base.hpp" 2 3 4 > >namespace boost { >namespace asio { > >inline serial_port_base::baud_rate::baud_rate(unsigned int rate) > : value_(rate) >{ >} > >inline unsigned int serial_port_base::baud_rate::value() const >{ > return value_; >} > >inline serial_port_base::flow_control::type >serial_port_base::flow_control::value() const >{ > return value_; >} > >inline serial_port_base::parity::type serial_port_base::parity::value() const >{ > return value_; >} > >inline serial_port_base::stop_bits::type >serial_port_base::stop_bits::value() const >{ > return value_; >} > >inline unsigned int serial_port_base::character_size::value() const >{ > return value_; >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 60 "/usr/include/boost/asio/impl/serial_port_base.hpp" 2 3 4 ># 162 "/usr/include/boost/asio/serial_port_base.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/serial_port_base.ipp" 1 3 4 ># 25 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 ># 1 "/usr/include/boost/asio/serial_port_base.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/impl/serial_port_base.ipp" 2 3 4 ># 36 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 37 "/usr/include/boost/asio/impl/serial_port_base.ipp" 2 3 4 > >namespace boost { >namespace asio { > >boost::system::error_code serial_port_base::baud_rate::store( > termios& storage, boost::system::error_code& ec) const >{ > > > > speed_t baud; > switch (value_) > { > > case 0: baud = 0000000; break; > case 50: baud = 0000001; break; > case 75: baud = 0000002; break; > case 110: baud = 0000003; break; > case 134: baud = 0000004; break; > case 150: baud = 0000005; break; > case 200: baud = 0000006; break; > case 300: baud = 0000007; break; > case 600: baud = 0000010; break; > case 1200: baud = 0000011; break; > case 1800: baud = 0000012; break; > case 2400: baud = 0000013; break; > case 4800: baud = 0000014; break; > case 9600: baud = 0000015; break; > case 19200: baud = 0000016; break; > case 38400: baud = 0000017; break; ># 75 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 > case 57600: baud = 0010001; break; > > > case 115200: baud = 0010002; break; > > > case 230400: baud = 0010003; break; > > > case 460800: baud = 0010004; break; > > > case 500000: baud = 0010005; break; > > > case 576000: baud = 0010006; break; > > > case 921600: baud = 0010007; break; > > > case 1000000: baud = 0010010; break; > > > case 1152000: baud = 0010011; break; > > > case 2000000: baud = 0010013; break; > > > case 3000000: baud = 0010015; break; > > > case 3500000: baud = 0010016; break; > > > case 4000000: baud = 0010017; break; > > default: > ec = boost::asio::error::invalid_argument; > return ec; > } > > ::cfsetspeed(&storage, baud); > > > > > > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code serial_port_base::baud_rate::load( > const termios& storage, boost::system::error_code& ec) >{ > > > > speed_t baud = ::cfgetospeed(&storage); > switch (baud) > { > > case 0000000: value_ = 0; break; > case 0000001: value_ = 50; break; > case 0000002: value_ = 75; break; > case 0000003: value_ = 110; break; > case 0000004: value_ = 134; break; > case 0000005: value_ = 150; break; > case 0000006: value_ = 200; break; > case 0000007: value_ = 300; break; > case 0000010: value_ = 600; break; > case 0000011: value_ = 1200; break; > case 0000012: value_ = 1800; break; > case 0000013: value_ = 2400; break; > case 0000014: value_ = 4800; break; > case 0000015: value_ = 9600; break; > case 0000016: value_ = 19200; break; > case 0000017: value_ = 38400; break; ># 162 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 > case 0010001: value_ = 57600; break; > > > case 0010002: value_ = 115200; break; > > > case 0010003: value_ = 230400; break; > > > case 0010004: value_ = 460800; break; > > > case 0010005: value_ = 500000; break; > > > case 0010006: value_ = 576000; break; > > > case 0010007: value_ = 921600; break; > > > case 0010010: value_ = 1000000; break; > > > case 0010011: value_ = 1152000; break; > > > case 0010013: value_ = 2000000; break; > > > case 0010015: value_ = 3000000; break; > > > case 0010016: value_ = 3500000; break; > > > case 0010017: value_ = 4000000; break; > > default: > value_ = 0; > ec = boost::asio::error::invalid_argument; > return ec; > } > > ec = boost::system::error_code(); > return ec; >} > >serial_port_base::flow_control::flow_control( > serial_port_base::flow_control::type t) > : value_(t) >{ > if (t != none && t != software && t != hardware) > { > std::out_of_range ex("invalid flow_control value"); > boost::asio::detail::throw_exception(ex); > } >} > >boost::system::error_code serial_port_base::flow_control::store( > termios& storage, boost::system::error_code& ec) const >{ ># 249 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 > switch (value_) > { > case none: > storage.c_iflag &= ~(0010000 | 0002000); > > storage.c_cflag &= ~020000000000; > > > > break; > case software: > storage.c_iflag |= 0010000 | 0002000; > > storage.c_cflag &= ~020000000000; > > > > break; > case hardware: > > storage.c_iflag &= ~(0010000 | 0002000); > storage.c_cflag |= 020000000000; > break; ># 280 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 > default: > break; > } > > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code serial_port_base::flow_control::load( > const termios& storage, boost::system::error_code& ec) >{ ># 305 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 > if (storage.c_iflag & (0010000 | 0002000)) > { > value_ = software; > } > > else if (storage.c_cflag & 020000000000) > { > value_ = hardware; > } > > > > > > > else > { > value_ = none; > } > > ec = boost::system::error_code(); > return ec; >} > >serial_port_base::parity::parity(serial_port_base::parity::type t) > : value_(t) >{ > if (t != none && t != odd && t != even) > { > std::out_of_range ex("invalid parity value"); > boost::asio::detail::throw_exception(ex); > } >} > >boost::system::error_code serial_port_base::parity::store( > termios& storage, boost::system::error_code& ec) const >{ ># 361 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 > switch (value_) > { > case none: > storage.c_iflag |= 0000004; > storage.c_cflag &= ~(0000400 | 0001000); > break; > case even: > storage.c_iflag &= ~(0000004 | 0000010); > storage.c_iflag |= 0000020; > storage.c_cflag |= 0000400; > storage.c_cflag &= ~0001000; > break; > case odd: > storage.c_iflag &= ~(0000004 | 0000010); > storage.c_iflag |= 0000020; > storage.c_cflag |= (0000400 | 0001000); > break; > default: > break; > } > > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code serial_port_base::parity::load( > const termios& storage, boost::system::error_code& ec) >{ ># 403 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 > if (storage.c_cflag & 0000400) > { > if (storage.c_cflag & 0001000) > { > value_ = odd; > } > else > { > value_ = even; > } > } > else > { > value_ = none; > } > > ec = boost::system::error_code(); > return ec; >} > >serial_port_base::stop_bits::stop_bits( > serial_port_base::stop_bits::type t) > : value_(t) >{ > if (t != one && t != onepointfive && t != two) > { > std::out_of_range ex("invalid stop_bits value"); > boost::asio::detail::throw_exception(ex); > } >} > >boost::system::error_code serial_port_base::stop_bits::store( > termios& storage, boost::system::error_code& ec) const >{ ># 453 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 > switch (value_) > { > case one: > storage.c_cflag &= ~0000100; > break; > case two: > storage.c_cflag |= 0000100; > break; > default: > ec = boost::asio::error::operation_not_supported; > return ec; > } > > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code serial_port_base::stop_bits::load( > const termios& storage, boost::system::error_code& ec) >{ ># 491 "/usr/include/boost/asio/impl/serial_port_base.ipp" 3 4 > value_ = (storage.c_cflag & 0000100) ? two : one; > > ec = boost::system::error_code(); > return ec; >} > >serial_port_base::character_size::character_size(unsigned int t) > : value_(t) >{ > if (t < 5 || t > 8) > { > std::out_of_range ex("invalid character_size value"); > boost::asio::detail::throw_exception(ex); > } >} > >boost::system::error_code serial_port_base::character_size::store( > termios& storage, boost::system::error_code& ec) const >{ > > > > storage.c_cflag &= ~0000060; > switch (value_) > { > case 5: storage.c_cflag |= 0000000; break; > case 6: storage.c_cflag |= 0000020; break; > case 7: storage.c_cflag |= 0000040; break; > case 8: storage.c_cflag |= 0000060; break; > default: break; > } > > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code serial_port_base::character_size::load( > const termios& storage, boost::system::error_code& ec) >{ > > > > if ((storage.c_cflag & 0000060) == 0000000) { value_ = 5; } > else if ((storage.c_cflag & 0000060) == 0000020) { value_ = 6; } > else if ((storage.c_cflag & 0000060) == 0000040) { value_ = 7; } > else if ((storage.c_cflag & 0000060) == 0000060) { value_ = 8; } > else > { > > value_ = 8; > } > > ec = boost::system::error_code(); > return ec; >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 551 "/usr/include/boost/asio/impl/serial_port_base.ipp" 2 3 4 ># 164 "/usr/include/boost/asio/serial_port_base.hpp" 2 3 4 ># 30 "/usr/include/boost/asio/basic_serial_port.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/serial_port_service.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/serial_port_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_serial_port_service.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/reactive_serial_port_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/descriptor_ops.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/descriptor_ops.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/detail/descriptor_ops.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { >namespace descriptor_ops { > > >enum >{ > > user_set_non_blocking = 1, > > > internal_non_blocking = 2, > > > non_blocking = user_set_non_blocking | internal_non_blocking, > > > possible_dup = 4 >}; > >typedef unsigned char state_type; > >template <typename ReturnType> >inline ReturnType error_wrapper(ReturnType return_value, > boost::system::error_code& ec) >{ > ec = boost::system::error_code((*__errno_location ()), > boost::asio::error::get_system_category()); > return return_value; >} > >inline int open(const char* path, int flags, > boost::system::error_code& ec); > >inline int close(int d, state_type& state, > boost::system::error_code& ec); > >inline bool set_user_non_blocking(int d, > state_type& state, bool value, boost::system::error_code& ec); > >inline bool set_internal_non_blocking(int d, > state_type& state, bool value, boost::system::error_code& ec); > >typedef iovec buf; > >inline std::size_t sync_read(int d, state_type state, buf* bufs, > std::size_t count, bool all_empty, boost::system::error_code& ec); > >inline bool non_blocking_read(int d, buf* bufs, std::size_t count, > boost::system::error_code& ec, std::size_t& bytes_transferred); > >inline std::size_t sync_write(int d, state_type state, > const buf* bufs, std::size_t count, bool all_empty, > boost::system::error_code& ec); > >inline bool non_blocking_write(int d, > const buf* bufs, std::size_t count, > boost::system::error_code& ec, std::size_t& bytes_transferred); > >inline int ioctl(int d, state_type& state, long cmd, > ioctl_arg_type* arg, boost::system::error_code& ec); > >inline int fcntl(int d, int cmd, boost::system::error_code& ec); > >inline int fcntl(int d, int cmd, > long arg, boost::system::error_code& ec); > >inline int poll_read(int d, > state_type state, boost::system::error_code& ec); > >inline int poll_write(int d, > state_type state, boost::system::error_code& ec); > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 110 "/usr/include/boost/asio/detail/descriptor_ops.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/descriptor_ops.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/impl/descriptor_ops.ipp" 3 4 ># 1 "/usr/include/c++/4.9.0/cerrno" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cerrno" 3 4 ># 40 "/usr/include/c++/4.9.0/cerrno" 3 > ># 1 "/usr/include/errno.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/cerrno" 2 3 ># 20 "/usr/include/boost/asio/detail/impl/descriptor_ops.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/descriptor_ops.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/impl/descriptor_ops.ipp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/impl/descriptor_ops.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { >namespace descriptor_ops { > >int open(const char* path, int flags, boost::system::error_code& ec) >{ > (*__errno_location ()) = 0; > int result = error_wrapper(::open(path, flags), ec); > if (result >= 0) > ec = boost::system::error_code(); > return result; >} > >int close(int d, state_type& state, boost::system::error_code& ec) >{ > int result = 0; > if (d != -1) > { > (*__errno_location ()) = 0; > result = error_wrapper(::close(d), ec); > > if (result != 0 > && (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again)) > { ># 66 "/usr/include/boost/asio/detail/impl/descriptor_ops.ipp" 3 4 > ioctl_arg_type arg = 0; > ::ioctl(d, 0x5421, &arg); > > state &= ~non_blocking; > > (*__errno_location ()) = 0; > result = error_wrapper(::close(d), ec); > } > } > > if (result == 0) > ec = boost::system::error_code(); > return result; >} > >bool set_user_non_blocking(int d, state_type& state, > bool value, boost::system::error_code& ec) >{ > if (d == -1) > { > ec = boost::asio::error::bad_descriptor; > return false; > } > > (*__errno_location ()) = 0; ># 100 "/usr/include/boost/asio/detail/impl/descriptor_ops.ipp" 3 4 > ioctl_arg_type arg = (value ? 1 : 0); > int result = error_wrapper(::ioctl(d, 0x5421, &arg), ec); > > > if (result >= 0) > { > ec = boost::system::error_code(); > if (value) > state |= user_set_non_blocking; > else > { > > > > state &= ~(user_set_non_blocking | internal_non_blocking); > } > return true; > } > > return false; >} > >bool set_internal_non_blocking(int d, state_type& state, > bool value, boost::system::error_code& ec) >{ > if (d == -1) > { > ec = boost::asio::error::bad_descriptor; > return false; > } > > if (!value && (state & user_set_non_blocking)) > { > > > > ec = boost::asio::error::invalid_argument; > return false; > } > > (*__errno_location ()) = 0; ># 150 "/usr/include/boost/asio/detail/impl/descriptor_ops.ipp" 3 4 > ioctl_arg_type arg = (value ? 1 : 0); > int result = error_wrapper(::ioctl(d, 0x5421, &arg), ec); > > > if (result >= 0) > { > ec = boost::system::error_code(); > if (value) > state |= internal_non_blocking; > else > state &= ~internal_non_blocking; > return true; > } > > return false; >} > >std::size_t sync_read(int d, state_type state, buf* bufs, > std::size_t count, bool all_empty, boost::system::error_code& ec) >{ > if (d == -1) > { > ec = boost::asio::error::bad_descriptor; > return 0; > } > > > if (all_empty) > { > ec = boost::system::error_code(); > return 0; > } > > > for (;;) > { > > (*__errno_location ()) = 0; > signed_size_type bytes = error_wrapper(::readv( > d, bufs, static_cast<int>(count)), ec); > > > if (bytes > 0) > return bytes; > > > if (bytes == 0) > { > ec = boost::asio::error::eof; > return 0; > } > > > if ((state & user_set_non_blocking) > || (ec != boost::asio::error::would_block > && ec != boost::asio::error::try_again)) > return 0; > > > if (descriptor_ops::poll_read(d, 0, ec) < 0) > return 0; > } >} > >bool non_blocking_read(int d, buf* bufs, std::size_t count, > boost::system::error_code& ec, std::size_t& bytes_transferred) >{ > for (;;) > { > > (*__errno_location ()) = 0; > signed_size_type bytes = error_wrapper(::readv( > d, bufs, static_cast<int>(count)), ec); > > > if (bytes == 0) > { > ec = boost::asio::error::eof; > return true; > } > > > if (ec == boost::asio::error::interrupted) > continue; > > > if (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again) > return false; > > > if (bytes > 0) > { > ec = boost::system::error_code(); > bytes_transferred = bytes; > } > else > bytes_transferred = 0; > > return true; > } >} > >std::size_t sync_write(int d, state_type state, const buf* bufs, > std::size_t count, bool all_empty, boost::system::error_code& ec) >{ > if (d == -1) > { > ec = boost::asio::error::bad_descriptor; > return 0; > } > > > if (all_empty) > { > ec = boost::system::error_code(); > return 0; > } > > > for (;;) > { > > (*__errno_location ()) = 0; > signed_size_type bytes = error_wrapper(::writev( > d, bufs, static_cast<int>(count)), ec); > > > if (bytes > 0) > return bytes; > > > if ((state & user_set_non_blocking) > || (ec != boost::asio::error::would_block > && ec != boost::asio::error::try_again)) > return 0; > > > if (descriptor_ops::poll_write(d, 0, ec) < 0) > return 0; > } >} > >bool non_blocking_write(int d, const buf* bufs, std::size_t count, > boost::system::error_code& ec, std::size_t& bytes_transferred) >{ > for (;;) > { > > (*__errno_location ()) = 0; > signed_size_type bytes = error_wrapper(::writev( > d, bufs, static_cast<int>(count)), ec); > > > if (ec == boost::asio::error::interrupted) > continue; > > > if (ec == boost::asio::error::would_block > || ec == boost::asio::error::try_again) > return false; > > > if (bytes >= 0) > { > ec = boost::system::error_code(); > bytes_transferred = bytes; > } > else > bytes_transferred = 0; > > return true; > } >} > >int ioctl(int d, state_type& state, long cmd, > ioctl_arg_type* arg, boost::system::error_code& ec) >{ > if (d == -1) > { > ec = boost::asio::error::bad_descriptor; > return -1; > } > > (*__errno_location ()) = 0; > int result = error_wrapper(::ioctl(d, cmd, arg), ec); > > if (result >= 0) > { > ec = boost::system::error_code(); > > > > > > > > if (cmd == static_cast<long>(0x5421)) > { > if (*arg) > { > state |= user_set_non_blocking; > } > else > { > > > > state &= ~(user_set_non_blocking | internal_non_blocking); > } > } > } > > return result; >} > >int fcntl(int d, int cmd, boost::system::error_code& ec) >{ > if (d == -1) > { > ec = boost::asio::error::bad_descriptor; > return -1; > } > > (*__errno_location ()) = 0; > int result = error_wrapper(::fcntl(d, cmd), ec); > if (result != -1) > ec = boost::system::error_code(); > return result; >} > >int fcntl(int d, int cmd, long arg, boost::system::error_code& ec) >{ > if (d == -1) > { > ec = boost::asio::error::bad_descriptor; > return -1; > } > > (*__errno_location ()) = 0; > int result = error_wrapper(::fcntl(d, cmd, arg), ec); > if (result != -1) > ec = boost::system::error_code(); > return result; >} > >int poll_read(int d, state_type state, boost::system::error_code& ec) >{ > if (d == -1) > { > ec = boost::asio::error::bad_descriptor; > return -1; > } > > pollfd fds; > fds.fd = d; > fds.events = 0x001; > fds.revents = 0; > int timeout = (state & user_set_non_blocking) ? 0 : -1; > (*__errno_location ()) = 0; > int result = error_wrapper(::poll(&fds, 1, timeout), ec); > if (result == 0) > ec = (state & user_set_non_blocking) > ? boost::asio::error::would_block : boost::system::error_code(); > else if (result > 0) > ec = boost::system::error_code(); > return result; >} > >int poll_write(int d, state_type state, boost::system::error_code& ec) >{ > if (d == -1) > { > ec = boost::asio::error::bad_descriptor; > return -1; > } > > pollfd fds; > fds.fd = d; > fds.events = 0x004; > fds.revents = 0; > int timeout = (state & user_set_non_blocking) ? 0 : -1; > (*__errno_location ()) = 0; > int result = error_wrapper(::poll(&fds, 1, timeout), ec); > if (result == 0) > ec = (state & user_set_non_blocking) > ? boost::asio::error::would_block : boost::system::error_code(); > else if (result > 0) > ec = boost::system::error_code(); > return result; >} > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 448 "/usr/include/boost/asio/detail/impl/descriptor_ops.ipp" 2 3 4 ># 113 "/usr/include/boost/asio/detail/descriptor_ops.hpp" 2 3 4 ># 29 "/usr/include/boost/asio/detail/reactive_serial_port_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_descriptor_service.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/detail/reactive_descriptor_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/descriptor_read_op.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/detail/descriptor_read_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/detail/descriptor_read_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename MutableBufferSequence> >class descriptor_read_op_base : public reactor_op >{ >public: > descriptor_read_op_base(int descriptor, > const MutableBufferSequence& buffers, func_type complete_func) > : reactor_op(&descriptor_read_op_base::do_perform, complete_func), > descriptor_(descriptor), > buffers_(buffers) > { > } > > static bool do_perform(reactor_op* base) > { > descriptor_read_op_base* o(static_cast<descriptor_read_op_base*>(base)); > > buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence> bufs(o->buffers_); > > return descriptor_ops::non_blocking_read(o->descriptor_, > bufs.buffers(), bufs.count(), o->ec_, o->bytes_transferred_); > } > >private: > int descriptor_; > MutableBufferSequence buffers_; >}; > >template <typename MutableBufferSequence, typename Handler> >class descriptor_read_op > : public descriptor_read_op_base<MutableBufferSequence> >{ >public: > struct ptr { Handler* h; void* v; descriptor_read_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~descriptor_read_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(descriptor_read_op), *h); v = 0; } } }; > > descriptor_read_op(int descriptor, > const MutableBufferSequence& buffers, Handler& handler) > : descriptor_read_op_base<MutableBufferSequence>( > descriptor, buffers, &descriptor_read_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > descriptor_read_op* o(static_cast<descriptor_read_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, std::size_t> > handler(o->handler_, o->ec_, o->bytes_transferred_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 118 "/usr/include/boost/asio/detail/descriptor_read_op.hpp" 2 3 4 ># 31 "/usr/include/boost/asio/detail/reactive_descriptor_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/descriptor_write_op.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/detail/descriptor_write_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/detail/descriptor_write_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename ConstBufferSequence> >class descriptor_write_op_base : public reactor_op >{ >public: > descriptor_write_op_base(int descriptor, > const ConstBufferSequence& buffers, func_type complete_func) > : reactor_op(&descriptor_write_op_base::do_perform, complete_func), > descriptor_(descriptor), > buffers_(buffers) > { > } > > static bool do_perform(reactor_op* base) > { > descriptor_write_op_base* o(static_cast<descriptor_write_op_base*>(base)); > > buffer_sequence_adapter<boost::asio::const_buffer, > ConstBufferSequence> bufs(o->buffers_); > > return descriptor_ops::non_blocking_write(o->descriptor_, > bufs.buffers(), bufs.count(), o->ec_, o->bytes_transferred_); > } > >private: > int descriptor_; > ConstBufferSequence buffers_; >}; > >template <typename ConstBufferSequence, typename Handler> >class descriptor_write_op > : public descriptor_write_op_base<ConstBufferSequence> >{ >public: > struct ptr { Handler* h; void* v; descriptor_write_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~descriptor_write_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(descriptor_write_op), *h); v = 0; } } }; > > descriptor_write_op(int descriptor, > const ConstBufferSequence& buffers, Handler& handler) > : descriptor_write_op_base<ConstBufferSequence>( > descriptor, buffers, &descriptor_write_op::do_complete), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > descriptor_write_op* o(static_cast<descriptor_write_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, std::size_t> > handler(o->handler_, o->ec_, o->bytes_transferred_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 118 "/usr/include/boost/asio/detail/descriptor_write_op.hpp" 2 3 4 ># 32 "/usr/include/boost/asio/detail/reactive_descriptor_service.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 38 "/usr/include/boost/asio/detail/reactive_descriptor_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class reactive_descriptor_service >{ >public: > > typedef int native_handle_type; > > > class implementation_type > : private boost::asio::detail::noncopyable > { > public: > > implementation_type() > : descriptor_(-1), > state_(0) > { > } > > private: > > friend class reactive_descriptor_service; > > > int descriptor_; > > > descriptor_ops::state_type state_; > > > reactor::per_descriptor_data reactor_data_; > }; > > > inline reactive_descriptor_service( > boost::asio::io_service& io_service); > > > inline void shutdown_service(); > > > inline void construct(implementation_type& impl); > > > inline void move_construct(implementation_type& impl, > implementation_type& other_impl); > > > inline void move_assign(implementation_type& impl, > reactive_descriptor_service& other_service, > implementation_type& other_impl); > > > inline void destroy(implementation_type& impl); > > > inline boost::system::error_code assign(implementation_type& impl, > const native_handle_type& native_descriptor, > boost::system::error_code& ec); > > > bool is_open(const implementation_type& impl) const > { > return impl.descriptor_ != -1; > } > > > inline boost::system::error_code close(implementation_type& impl, > boost::system::error_code& ec); > > > native_handle_type native_handle(const implementation_type& impl) const > { > return impl.descriptor_; > } > > > inline native_handle_type release(implementation_type& impl); > > > inline boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec); > > > template <typename IO_Control_Command> > boost::system::error_code io_control(implementation_type& impl, > IO_Control_Command& command, boost::system::error_code& ec) > { > descriptor_ops::ioctl(impl.descriptor_, impl.state_, > command.name(), static_cast<ioctl_arg_type*>(command.data()), ec); > return ec; > } > > > bool non_blocking(const implementation_type& impl) const > { > return (impl.state_ & descriptor_ops::user_set_non_blocking) != 0; > } > > > boost::system::error_code non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > descriptor_ops::set_user_non_blocking( > impl.descriptor_, impl.state_, mode, ec); > return ec; > } > > > bool native_non_blocking(const implementation_type& impl) const > { > return (impl.state_ & descriptor_ops::internal_non_blocking) != 0; > } > > > boost::system::error_code native_non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > descriptor_ops::set_internal_non_blocking( > impl.descriptor_, impl.state_, mode, ec); > return ec; > } > > > template <typename ConstBufferSequence> > size_t write_some(implementation_type& impl, > const ConstBufferSequence& buffers, boost::system::error_code& ec) > { > buffer_sequence_adapter<boost::asio::const_buffer, > ConstBufferSequence> bufs(buffers); > > return descriptor_ops::sync_write(impl.descriptor_, impl.state_, > bufs.buffers(), bufs.count(), bufs.all_empty(), ec); > } > > > size_t write_some(implementation_type& impl, > const null_buffers&, boost::system::error_code& ec) > { > > descriptor_ops::poll_write(impl.descriptor_, impl.state_, ec); > > return 0; > } > > > > template <typename ConstBufferSequence, typename Handler> > void async_write_some(implementation_type& impl, > const ConstBufferSequence& buffers, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef descriptor_write_op<ConstBufferSequence, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl.descriptor_, buffers, handler); > > (void)0; > > start_op(impl, reactor::write_op, p.p, is_continuation, true, > buffer_sequence_adapter<boost::asio::const_buffer, > ConstBufferSequence>::all_empty(buffers)); > p.v = p.p = 0; > } > > > template <typename Handler> > void async_write_some(implementation_type& impl, > const null_buffers&, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_null_buffers_op<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0 > ; > > start_op(impl, reactor::write_op, p.p, is_continuation, false, false); > p.v = p.p = 0; > } > > > template <typename MutableBufferSequence> > size_t read_some(implementation_type& impl, > const MutableBufferSequence& buffers, boost::system::error_code& ec) > { > buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence> bufs(buffers); > > return descriptor_ops::sync_read(impl.descriptor_, impl.state_, > bufs.buffers(), bufs.count(), bufs.all_empty(), ec); > } > > > size_t read_some(implementation_type& impl, > const null_buffers&, boost::system::error_code& ec) > { > > descriptor_ops::poll_read(impl.descriptor_, impl.state_, ec); > > return 0; > } > > > > template <typename MutableBufferSequence, typename Handler> > void async_read_some(implementation_type& impl, > const MutableBufferSequence& buffers, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef descriptor_read_op<MutableBufferSequence, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl.descriptor_, buffers, handler); > > (void)0; > > start_op(impl, reactor::read_op, p.p, is_continuation, true, > buffer_sequence_adapter<boost::asio::mutable_buffer, > MutableBufferSequence>::all_empty(buffers)); > p.v = p.p = 0; > } > > > template <typename Handler> > void async_read_some(implementation_type& impl, > const null_buffers&, Handler& handler) > { > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef reactive_null_buffers_op<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0 > ; > > start_op(impl, reactor::read_op, p.p, is_continuation, false, false); > p.v = p.p = 0; > } > >private: > > inline void start_op(implementation_type& impl, int op_type, > reactor_op* op, bool is_continuation, bool is_non_blocking, bool noop); > > > reactor& reactor_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 315 "/usr/include/boost/asio/detail/reactive_descriptor_service.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/reactive_descriptor_service.ipp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/impl/reactive_descriptor_service.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_descriptor_service.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/impl/reactive_descriptor_service.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/impl/reactive_descriptor_service.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >reactive_descriptor_service::reactive_descriptor_service( > boost::asio::io_service& io_service) > : reactor_(boost::asio::use_service<reactor>(io_service)) >{ > reactor_.init_task(); >} > >void reactive_descriptor_service::shutdown_service() >{ >} > >void reactive_descriptor_service::construct( > reactive_descriptor_service::implementation_type& impl) >{ > impl.descriptor_ = -1; > impl.state_ = 0; >} > >void reactive_descriptor_service::move_construct( > reactive_descriptor_service::implementation_type& impl, > reactive_descriptor_service::implementation_type& other_impl) >{ > impl.descriptor_ = other_impl.descriptor_; > other_impl.descriptor_ = -1; > > impl.state_ = other_impl.state_; > other_impl.state_ = 0; > > reactor_.move_descriptor(impl.descriptor_, > impl.reactor_data_, other_impl.reactor_data_); >} > >void reactive_descriptor_service::move_assign( > reactive_descriptor_service::implementation_type& impl, > reactive_descriptor_service& other_service, > reactive_descriptor_service::implementation_type& other_impl) >{ > destroy(impl); > > impl.descriptor_ = other_impl.descriptor_; > other_impl.descriptor_ = -1; > > impl.state_ = other_impl.state_; > other_impl.state_ = 0; > > other_service.reactor_.move_descriptor(impl.descriptor_, > impl.reactor_data_, other_impl.reactor_data_); >} > >void reactive_descriptor_service::destroy( > reactive_descriptor_service::implementation_type& impl) >{ > if (is_open(impl)) > { > (void)0; > > reactor_.deregister_descriptor(impl.descriptor_, impl.reactor_data_, > (impl.state_ & descriptor_ops::possible_dup) == 0); > } > > boost::system::error_code ignored_ec; > descriptor_ops::close(impl.descriptor_, impl.state_, ignored_ec); >} > >boost::system::error_code reactive_descriptor_service::assign( > reactive_descriptor_service::implementation_type& impl, > const native_handle_type& native_descriptor, boost::system::error_code& ec) >{ > if (is_open(impl)) > { > ec = boost::asio::error::already_open; > return ec; > } > > if (int err = reactor_.register_descriptor( > native_descriptor, impl.reactor_data_)) > { > ec = boost::system::error_code(err, > boost::asio::error::get_system_category()); > return ec; > } > > impl.descriptor_ = native_descriptor; > impl.state_ = descriptor_ops::possible_dup; > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code reactive_descriptor_service::close( > reactive_descriptor_service::implementation_type& impl, > boost::system::error_code& ec) >{ > if (is_open(impl)) > { > (void)0; > > reactor_.deregister_descriptor(impl.descriptor_, impl.reactor_data_, > (impl.state_ & descriptor_ops::possible_dup) == 0); > } > > descriptor_ops::close(impl.descriptor_, impl.state_, ec); > > > > > > > > construct(impl); > > return ec; >} > >reactive_descriptor_service::native_handle_type >reactive_descriptor_service::release( > reactive_descriptor_service::implementation_type& impl) >{ > native_handle_type descriptor = impl.descriptor_; > > if (is_open(impl)) > { > (void)0; > > reactor_.deregister_descriptor(impl.descriptor_, impl.reactor_data_, false); > construct(impl); > } > > return descriptor; >} > >boost::system::error_code reactive_descriptor_service::cancel( > reactive_descriptor_service::implementation_type& impl, > boost::system::error_code& ec) >{ > if (!is_open(impl)) > { > ec = boost::asio::error::bad_descriptor; > return ec; > } > > (void)0; > > reactor_.cancel_ops(impl.descriptor_, impl.reactor_data_); > ec = boost::system::error_code(); > return ec; >} > >void reactive_descriptor_service::start_op( > reactive_descriptor_service::implementation_type& impl, > int op_type, reactor_op* op, bool is_continuation, > bool is_non_blocking, bool noop) >{ > if (!noop) > { > if ((impl.state_ & descriptor_ops::non_blocking) || > descriptor_ops::set_internal_non_blocking( > impl.descriptor_, impl.state_, true, op->ec_)) > { > reactor_.start_op(op_type, impl.descriptor_, > impl.reactor_data_, op, is_continuation, is_non_blocking); > return; > } > } > > reactor_.post_immediate_completion(op, is_continuation); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 205 "/usr/include/boost/asio/detail/impl/reactive_descriptor_service.ipp" 2 3 4 ># 318 "/usr/include/boost/asio/detail/reactive_descriptor_service.hpp" 2 3 4 ># 30 "/usr/include/boost/asio/detail/reactive_serial_port_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/detail/reactive_serial_port_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > >class reactive_serial_port_service >{ >public: > > typedef reactive_descriptor_service::native_handle_type native_handle_type; > > > typedef reactive_descriptor_service::implementation_type implementation_type; > > inline reactive_serial_port_service( > boost::asio::io_service& io_service); > > > inline void shutdown_service(); > > > void construct(implementation_type& impl) > { > descriptor_service_.construct(impl); > } > > > void move_construct(implementation_type& impl, > implementation_type& other_impl) > { > descriptor_service_.move_construct(impl, other_impl); > } > > > void move_assign(implementation_type& impl, > reactive_serial_port_service& other_service, > implementation_type& other_impl) > { > descriptor_service_.move_assign(impl, > other_service.descriptor_service_, other_impl); > } > > > void destroy(implementation_type& impl) > { > descriptor_service_.destroy(impl); > } > > > inline boost::system::error_code open(implementation_type& impl, > const std::string& device, boost::system::error_code& ec); > > > boost::system::error_code assign(implementation_type& impl, > const native_handle_type& native_descriptor, > boost::system::error_code& ec) > { > return descriptor_service_.assign(impl, native_descriptor, ec); > } > > > bool is_open(const implementation_type& impl) const > { > return descriptor_service_.is_open(impl); > } > > > boost::system::error_code close(implementation_type& impl, > boost::system::error_code& ec) > { > return descriptor_service_.close(impl, ec); > } > > > native_handle_type native_handle(implementation_type& impl) > { > return descriptor_service_.native_handle(impl); > } > > > boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec) > { > return descriptor_service_.cancel(impl, ec); > } > > > template <typename SettableSerialPortOption> > boost::system::error_code set_option(implementation_type& impl, > const SettableSerialPortOption& option, boost::system::error_code& ec) > { > return do_set_option(impl, > &reactive_serial_port_service::store_option<SettableSerialPortOption>, > &option, ec); > } > > > template <typename GettableSerialPortOption> > boost::system::error_code get_option(const implementation_type& impl, > GettableSerialPortOption& option, boost::system::error_code& ec) const > { > return do_get_option(impl, > &reactive_serial_port_service::load_option<GettableSerialPortOption>, > &option, ec); > } > > > boost::system::error_code send_break(implementation_type& impl, > boost::system::error_code& ec) > { > (*__errno_location ()) = 0; > descriptor_ops::error_wrapper(::tcsendbreak( > descriptor_service_.native_handle(impl), 0), ec); > return ec; > } > > > template <typename ConstBufferSequence> > size_t write_some(implementation_type& impl, > const ConstBufferSequence& buffers, boost::system::error_code& ec) > { > return descriptor_service_.write_some(impl, buffers, ec); > } > > > > template <typename ConstBufferSequence, typename Handler> > void async_write_some(implementation_type& impl, > const ConstBufferSequence& buffers, Handler& handler) > { > descriptor_service_.async_write_some(impl, buffers, handler); > } > > > template <typename MutableBufferSequence> > size_t read_some(implementation_type& impl, > const MutableBufferSequence& buffers, boost::system::error_code& ec) > { > return descriptor_service_.read_some(impl, buffers, ec); > } > > > > template <typename MutableBufferSequence, typename Handler> > void async_read_some(implementation_type& impl, > const MutableBufferSequence& buffers, Handler& handler) > { > descriptor_service_.async_read_some(impl, buffers, handler); > } > >private: > > typedef boost::system::error_code (*store_function_type)( > const void*, termios&, boost::system::error_code&); > > > template <typename SettableSerialPortOption> > static boost::system::error_code store_option(const void* option, > termios& storage, boost::system::error_code& ec) > { > return static_cast<const SettableSerialPortOption*>(option)->store( > storage, ec); > } > > > inline boost::system::error_code do_set_option( > implementation_type& impl, store_function_type store, > const void* option, boost::system::error_code& ec); > > > typedef boost::system::error_code (*load_function_type)( > void*, const termios&, boost::system::error_code&); > > > template <typename GettableSerialPortOption> > static boost::system::error_code load_option(void* option, > const termios& storage, boost::system::error_code& ec) > { > return static_cast<GettableSerialPortOption*>(option)->load(storage, ec); > } > > > inline boost::system::error_code do_get_option( > const implementation_type& impl, load_function_type load, > void* option, boost::system::error_code& ec) const; > > > reactive_descriptor_service descriptor_service_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 228 "/usr/include/boost/asio/detail/reactive_serial_port_service.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/reactive_serial_port_service.ipp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/impl/reactive_serial_port_service.ipp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 25 "/usr/include/boost/asio/detail/impl/reactive_serial_port_service.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/reactive_serial_port_service.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/impl/reactive_serial_port_service.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/impl/reactive_serial_port_service.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >reactive_serial_port_service::reactive_serial_port_service( > boost::asio::io_service& io_service) > : descriptor_service_(io_service) >{ >} > >void reactive_serial_port_service::shutdown_service() >{ > descriptor_service_.shutdown_service(); >} > >boost::system::error_code reactive_serial_port_service::open( > reactive_serial_port_service::implementation_type& impl, > const std::string& device, boost::system::error_code& ec) >{ > if (is_open(impl)) > { > ec = boost::asio::error::already_open; > return ec; > } > > descriptor_ops::state_type state = 0; > int fd = descriptor_ops::open(device.c_str(), > 02 | 04000 | 0400, ec); > if (fd < 0) > return ec; > > int s = descriptor_ops::fcntl(fd, 3, ec); > if (s >= 0) > s = descriptor_ops::fcntl(fd, 4, s | 04000, ec); > if (s < 0) > { > boost::system::error_code ignored_ec; > descriptor_ops::close(fd, state, ignored_ec); > return ec; > } > > > termios ios; > (*__errno_location ()) = 0; > s = descriptor_ops::error_wrapper(::tcgetattr(fd, &ios), ec); > if (s >= 0) > { > > ::cfmakeraw(&ios); ># 86 "/usr/include/boost/asio/detail/impl/reactive_serial_port_service.ipp" 3 4 > ios.c_iflag |= 0000004; > ios.c_cflag |= 0000200 | 0004000; > (*__errno_location ()) = 0; > s = descriptor_ops::error_wrapper(::tcsetattr(fd, 0, &ios), ec); > } > if (s < 0) > { > boost::system::error_code ignored_ec; > descriptor_ops::close(fd, state, ignored_ec); > return ec; > } > > > if (descriptor_service_.assign(impl, fd, ec)) > { > boost::system::error_code ignored_ec; > descriptor_ops::close(fd, state, ignored_ec); > } > > return ec; >} > >boost::system::error_code reactive_serial_port_service::do_set_option( > reactive_serial_port_service::implementation_type& impl, > reactive_serial_port_service::store_function_type store, > const void* option, boost::system::error_code& ec) >{ > termios ios; > (*__errno_location ()) = 0; > descriptor_ops::error_wrapper(::tcgetattr( > descriptor_service_.native_handle(impl), &ios), ec); > if (ec) > return ec; > > if (store(option, ios, ec)) > return ec; > > (*__errno_location ()) = 0; > descriptor_ops::error_wrapper(::tcsetattr( > descriptor_service_.native_handle(impl), 0, &ios), ec); > return ec; >} > >boost::system::error_code reactive_serial_port_service::do_get_option( > const reactive_serial_port_service::implementation_type& impl, > reactive_serial_port_service::load_function_type load, > void* option, boost::system::error_code& ec) const >{ > termios ios; > (*__errno_location ()) = 0; > descriptor_ops::error_wrapper(::tcgetattr( > descriptor_service_.native_handle(impl), &ios), ec); > if (ec) > return ec; > > return load(option, ios, ec); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 149 "/usr/include/boost/asio/detail/impl/reactive_serial_port_service.ipp" 2 3 4 ># 231 "/usr/include/boost/asio/detail/reactive_serial_port_service.hpp" 2 3 4 ># 27 "/usr/include/boost/asio/serial_port_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/win_iocp_serial_port_service.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/serial_port_service.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/serial_port_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >class serial_port_service > > > > : public boost::asio::detail::service_base<serial_port_service> > >{ >public: > > > > > >private: > > > > > typedef detail::reactive_serial_port_service service_impl_type; > > >public: > > > > > typedef service_impl_type::implementation_type implementation_type; > > > > > > > typedef service_impl_type::native_handle_type native_type; > > > > > > > typedef service_impl_type::native_handle_type native_handle_type; > > > > explicit serial_port_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base<serial_port_service>(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > > void move_construct(implementation_type& impl, > implementation_type& other_impl) > { > service_impl_.move_construct(impl, other_impl); > } > > > void move_assign(implementation_type& impl, > serial_port_service& other_service, > implementation_type& other_impl) > { > service_impl_.move_assign(impl, other_service.service_impl_, other_impl); > } > > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > boost::system::error_code open(implementation_type& impl, > const std::string& device, boost::system::error_code& ec) > { > return service_impl_.open(impl, device, ec); > } > > > boost::system::error_code assign(implementation_type& impl, > const native_handle_type& handle, boost::system::error_code& ec) > { > return service_impl_.assign(impl, handle, ec); > } > > > bool is_open(const implementation_type& impl) const > { > return service_impl_.is_open(impl); > } > > > boost::system::error_code close(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.close(impl, ec); > } > > > native_type native(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > native_handle_type native_handle(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > template <typename SettableSerialPortOption> > boost::system::error_code set_option(implementation_type& impl, > const SettableSerialPortOption& option, boost::system::error_code& ec) > { > return service_impl_.set_option(impl, option, ec); > } > > > template <typename GettableSerialPortOption> > boost::system::error_code get_option(const implementation_type& impl, > GettableSerialPortOption& option, boost::system::error_code& ec) const > { > return service_impl_.get_option(impl, option, ec); > } > > > boost::system::error_code send_break(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.send_break(impl, ec); > } > > > template <typename ConstBufferSequence> > std::size_t write_some(implementation_type& impl, > const ConstBufferSequence& buffers, boost::system::error_code& ec) > { > return service_impl_.write_some(impl, buffers, ec); > } > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_write_some(implementation_type& impl, > const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > service_impl_.async_write_some(impl, buffers, init.handler); > > return init.result.get(); > } > > > template <typename MutableBufferSequence> > std::size_t read_some(implementation_type& impl, > const MutableBufferSequence& buffers, boost::system::error_code& ec) > { > return service_impl_.read_some(impl, buffers, ec); > } > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_read_some(implementation_type& impl, > const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > service_impl_.async_read_some(impl, buffers, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > service_impl_type service_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 251 "/usr/include/boost/asio/serial_port_service.hpp" 2 3 4 ># 31 "/usr/include/boost/asio/basic_serial_port.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/basic_serial_port.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 46 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 >template <typename SerialPortService = serial_port_service> >class basic_serial_port > : public basic_io_object<SerialPortService>, > public serial_port_base >{ >public: > > > typedef typename SerialPortService::native_handle_type native_type; > > > typedef typename SerialPortService::native_handle_type native_handle_type; > > > typedef basic_serial_port<SerialPortService> lowest_layer_type; ># 69 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > explicit basic_serial_port(boost::asio::io_service& io_service) > : basic_io_object<SerialPortService>(io_service) > { > } ># 85 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > explicit basic_serial_port(boost::asio::io_service& io_service, > const char* device) > : basic_io_object<SerialPortService>(io_service) > { > boost::system::error_code ec; > this->get_service().open(this->get_implementation(), device, ec); > boost::asio::detail::throw_error(ec, "open"); > } ># 105 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > explicit basic_serial_port(boost::asio::io_service& io_service, > const std::string& device) > : basic_io_object<SerialPortService>(io_service) > { > boost::system::error_code ec; > this->get_service().open(this->get_implementation(), device, ec); > boost::asio::detail::throw_error(ec, "open"); > } ># 126 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > basic_serial_port(boost::asio::io_service& io_service, > const native_handle_type& native_serial_port) > : basic_io_object<SerialPortService>(io_service) > { > boost::system::error_code ec; > this->get_service().assign(this->get_implementation(), > native_serial_port, ec); > boost::asio::detail::throw_error(ec, "assign"); > } ># 147 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > basic_serial_port(basic_serial_port&& other) > : basic_io_object<SerialPortService>( > static_cast<basic_serial_port&&>(other)) > { > } ># 163 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > basic_serial_port& operator=(basic_serial_port&& other) > { > basic_io_object<SerialPortService>::operator=( > static_cast<basic_serial_port&&>(other)); > return *this; > } ># 180 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > lowest_layer_type& lowest_layer() > { > return *this; > } ># 194 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > const lowest_layer_type& lowest_layer() const > { > return *this; > } ># 207 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > void open(const std::string& device) > { > boost::system::error_code ec; > this->get_service().open(this->get_implementation(), device, ec); > boost::asio::detail::throw_error(ec, "open"); > } ># 223 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > boost::system::error_code open(const std::string& device, > boost::system::error_code& ec) > { > return this->get_service().open(this->get_implementation(), device, ec); > } ># 237 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > void assign(const native_handle_type& native_serial_port) > { > boost::system::error_code ec; > this->get_service().assign(this->get_implementation(), > native_serial_port, ec); > boost::asio::detail::throw_error(ec, "assign"); > } ># 253 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > boost::system::error_code assign(const native_handle_type& native_serial_port, > boost::system::error_code& ec) > { > return this->get_service().assign(this->get_implementation(), > native_serial_port, ec); > } > > > bool is_open() const > { > return this->get_service().is_open(this->get_implementation()); > } ># 274 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > void close() > { > boost::system::error_code ec; > this->get_service().close(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "close"); > } ># 289 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > boost::system::error_code close(boost::system::error_code& ec) > { > return this->get_service().close(this->get_implementation(), ec); > } ># 301 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > native_type native() > { > return this->get_service().native_handle(this->get_implementation()); > } > > > > > > > > native_handle_type native_handle() > { > return this->get_service().native_handle(this->get_implementation()); > } ># 325 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > void cancel() > { > boost::system::error_code ec; > this->get_service().cancel(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "cancel"); > } ># 340 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > boost::system::error_code cancel(boost::system::error_code& ec) > { > return this->get_service().cancel(this->get_implementation(), ec); > } ># 352 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > void send_break() > { > boost::system::error_code ec; > this->get_service().send_break(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "send_break"); > } ># 366 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > boost::system::error_code send_break(boost::system::error_code& ec) > { > return this->get_service().send_break(this->get_implementation(), ec); > } ># 386 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename SettableSerialPortOption> > void set_option(const SettableSerialPortOption& option) > { > boost::system::error_code ec; > this->get_service().set_option(this->get_implementation(), option, ec); > boost::asio::detail::throw_error(ec, "set_option"); > } ># 409 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename SettableSerialPortOption> > boost::system::error_code set_option(const SettableSerialPortOption& option, > boost::system::error_code& ec) > { > return this->get_service().set_option( > this->get_implementation(), option, ec); > } ># 433 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename GettableSerialPortOption> > void get_option(GettableSerialPortOption& option) > { > boost::system::error_code ec; > this->get_service().get_option(this->get_implementation(), option, ec); > boost::asio::detail::throw_error(ec, "get_option"); > } ># 457 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename GettableSerialPortOption> > boost::system::error_code get_option(GettableSerialPortOption& option, > boost::system::error_code& ec) > { > return this->get_service().get_option( > this->get_implementation(), option, ec); > } ># 492 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().write_some( > this->get_implementation(), buffers, ec); > boost::asio::detail::throw_error(ec, "write_some"); > return s; > } ># 518 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers, > boost::system::error_code& ec) > { > return this->get_service().write_some( > this->get_implementation(), buffers, ec); > } ># 561 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_write_some(const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_write_some(this->get_implementation(), > buffers, static_cast<WriteHandler&&>(handler)); > } ># 603 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().read_some( > this->get_implementation(), buffers, ec); > boost::asio::detail::throw_error(ec, "read_some"); > return s; > } ># 630 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers, > boost::system::error_code& ec) > { > return this->get_service().read_some( > this->get_implementation(), buffers, ec); > } ># 674 "/usr/include/boost/asio/basic_serial_port.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_read_some(const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_read_some(this->get_implementation(), > buffers, static_cast<ReadHandler&&>(handler)); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 693 "/usr/include/boost/asio/basic_serial_port.hpp" 2 3 4 ># 27 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/basic_signal_set.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 ># 1 "/usr/include/boost/asio/signal_set_service.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/signal_set_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/signal_set_service.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/signal_set_service.hpp" 3 4 ># 1 "/usr/include/signal.h" 1 3 4 ># 30 "/usr/include/signal.h" 3 4 >extern "C" { > ># 1 "/usr/include/bits/sigset.h" 1 3 4 ># 102 "/usr/include/bits/sigset.h" 3 4 >extern int __sigismember (const __sigset_t *, int); >extern int __sigaddset (__sigset_t *, int); >extern int __sigdelset (__sigset_t *, int); ># 116 "/usr/include/bits/sigset.h" 3 4 >extern __inline __attribute__ ((__gnu_inline__)) int __sigismember (const __sigset_t *__set, int __sig) { unsigned long int __mask = (((unsigned long int) 1) << (((__sig) - 1) % (8 * sizeof (unsigned long int)))); unsigned long int __word = (((__sig) - 1) / (8 * sizeof (unsigned long int))); return (__set->__val[__word] & __mask) ? 1 : 0; } >extern __inline __attribute__ ((__gnu_inline__)) int __sigaddset ( __sigset_t *__set, int __sig) { unsigned long int __mask = (((unsigned long int) 1) << (((__sig) - 1) % (8 * sizeof (unsigned long int)))); unsigned long int __word = (((__sig) - 1) / (8 * sizeof (unsigned long int))); return ((__set->__val[__word] |= __mask), 0); } >extern __inline __attribute__ ((__gnu_inline__)) int __sigdelset ( __sigset_t *__set, int __sig) { unsigned long int __mask = (((unsigned long int) 1) << (((__sig) - 1) % (8 * sizeof (unsigned long int)))); unsigned long int __word = (((__sig) - 1) / (8 * sizeof (unsigned long int))); return ((__set->__val[__word] &= ~__mask), 0); } ># 33 "/usr/include/signal.h" 2 3 4 > > > > > > > >typedef __sig_atomic_t sig_atomic_t; ># 57 "/usr/include/signal.h" 3 4 ># 1 "/usr/include/bits/signum.h" 1 3 4 ># 58 "/usr/include/signal.h" 2 3 4 ># 80 "/usr/include/signal.h" 3 4 ># 1 "/usr/include/bits/siginfo.h" 1 3 4 ># 24 "/usr/include/bits/siginfo.h" 3 4 ># 1 "/usr/include/bits/wordsize.h" 1 3 4 ># 25 "/usr/include/bits/siginfo.h" 2 3 4 ># 58 "/usr/include/bits/siginfo.h" 3 4 >typedef __clock_t __sigchld_clock_t; > > > >typedef struct > { > int si_signo; > int si_errno; > > int si_code; > > union > { > int _pad[((128 / sizeof (int)) - 4)]; > > > struct > { > __pid_t si_pid; > __uid_t si_uid; > } _kill; > > > struct > { > int si_tid; > int si_overrun; > sigval_t si_sigval; > } _timer; > > > struct > { > __pid_t si_pid; > __uid_t si_uid; > sigval_t si_sigval; > } _rt; > > > struct > { > __pid_t si_pid; > __uid_t si_uid; > int si_status; > __sigchld_clock_t si_utime; > __sigchld_clock_t si_stime; > } _sigchld; > > > struct > { > void *si_addr; > short int si_addr_lsb; > } _sigfault; > > > struct > { > long int si_band; > int si_fd; > } _sigpoll; > > > struct > { > void *_call_addr; > int _syscall; > unsigned int _arch; > } _sigsys; > } _sifields; > } siginfo_t ; ># 153 "/usr/include/bits/siginfo.h" 3 4 >enum >{ > SI_ASYNCNL = -60, > > SI_TKILL = -6, > > SI_SIGIO, > > SI_ASYNCIO, > > SI_MESGQ, > > SI_TIMER, > > SI_QUEUE, > > SI_USER, > > SI_KERNEL = 0x80 > >}; > > > >enum >{ > ILL_ILLOPC = 1, > > ILL_ILLOPN, > > ILL_ILLADR, > > ILL_ILLTRP, > > ILL_PRVOPC, > > ILL_PRVREG, > > ILL_COPROC, > > ILL_BADSTK > >}; > > >enum >{ > FPE_INTDIV = 1, > > FPE_INTOVF, > > FPE_FLTDIV, > > FPE_FLTOVF, > > FPE_FLTUND, > > FPE_FLTRES, > > FPE_FLTINV, > > FPE_FLTSUB > >}; > > >enum >{ > SEGV_MAPERR = 1, > > SEGV_ACCERR > >}; > > >enum >{ > BUS_ADRALN = 1, > > BUS_ADRERR, > > BUS_OBJERR, > > BUS_MCEERR_AR, > > BUS_MCEERR_AO > >}; > > >enum >{ > TRAP_BRKPT = 1, > > TRAP_TRACE > >}; > > >enum >{ > CLD_EXITED = 1, > > CLD_KILLED, > > CLD_DUMPED, > > CLD_TRAPPED, > > CLD_STOPPED, > > CLD_CONTINUED > >}; > > >enum >{ > POLL_IN = 1, > > POLL_OUT, > > POLL_MSG, > > POLL_ERR, > > POLL_PRI, > > POLL_HUP > >}; ># 81 "/usr/include/signal.h" 2 3 4 > > > > >typedef void (*__sighandler_t) (int); > > > > >extern __sighandler_t __sysv_signal (int __sig, __sighandler_t __handler) > throw (); > >extern __sighandler_t sysv_signal (int __sig, __sighandler_t __handler) > throw (); > > > > > > > >extern __sighandler_t signal (int __sig, __sighandler_t __handler) > throw (); ># 114 "/usr/include/signal.h" 3 4 > > > > > >extern __sighandler_t bsd_signal (int __sig, __sighandler_t __handler) > throw (); > > > > > > >extern int kill (__pid_t __pid, int __sig) throw (); > > > > > > >extern int killpg (__pid_t __pgrp, int __sig) throw (); > > > > >extern int raise (int __sig) throw (); > > > > >extern __sighandler_t ssignal (int __sig, __sighandler_t __handler) > throw (); >extern int gsignal (int __sig) throw (); > > > > >extern void psignal (int __sig, const char *__s); > > > > >extern void psiginfo (const siginfo_t *__pinfo, const char *__s); ># 169 "/usr/include/signal.h" 3 4 >extern int __sigpause (int __sig_or_mask, int __is_sig); ># 178 "/usr/include/signal.h" 3 4 >extern int sigpause (int __sig) __asm__ ("__xpg_sigpause"); ># 197 "/usr/include/signal.h" 3 4 >extern int sigblock (int __mask) throw () __attribute__ ((__deprecated__)); > > >extern int sigsetmask (int __mask) throw () __attribute__ ((__deprecated__)); > > >extern int siggetmask (void) throw () __attribute__ ((__deprecated__)); ># 212 "/usr/include/signal.h" 3 4 >typedef __sighandler_t sighandler_t; > > > > >typedef __sighandler_t sig_t; > > > > > >extern int sigemptyset (sigset_t *__set) throw () __attribute__ ((__nonnull__ (1))); > > >extern int sigfillset (sigset_t *__set) throw () __attribute__ ((__nonnull__ (1))); > > >extern int sigaddset (sigset_t *__set, int __signo) throw () __attribute__ ((__nonnull__ (1))); > > >extern int sigdelset (sigset_t *__set, int __signo) throw () __attribute__ ((__nonnull__ (1))); > > >extern int sigismember (const sigset_t *__set, int __signo) > throw () __attribute__ ((__nonnull__ (1))); > > > >extern int sigisemptyset (const sigset_t *__set) throw () __attribute__ ((__nonnull__ (1))); > > >extern int sigandset (sigset_t *__set, const sigset_t *__left, > const sigset_t *__right) throw () __attribute__ ((__nonnull__ (1, 2, 3))); > > >extern int sigorset (sigset_t *__set, const sigset_t *__left, > const sigset_t *__right) throw () __attribute__ ((__nonnull__ (1, 2, 3))); > > > > ># 1 "/usr/include/bits/sigaction.h" 1 3 4 ># 24 "/usr/include/bits/sigaction.h" 3 4 >struct sigaction > { > > > union > { > > __sighandler_t sa_handler; > > void (*sa_sigaction) (int, siginfo_t *, void *); > } > __sigaction_handler; > > > > > > > > __sigset_t sa_mask; > > > int sa_flags; > > > void (*sa_restorer) (void); > }; ># 254 "/usr/include/signal.h" 2 3 4 > > >extern int sigprocmask (int __how, const sigset_t *__restrict __set, > sigset_t *__restrict __oset) throw (); > > > > > > >extern int sigsuspend (const sigset_t *__set) __attribute__ ((__nonnull__ (1))); > > >extern int sigaction (int __sig, const struct sigaction *__restrict __act, > struct sigaction *__restrict __oact) throw (); > > >extern int sigpending (sigset_t *__set) throw () __attribute__ ((__nonnull__ (1))); > > > > > > >extern int sigwait (const sigset_t *__restrict __set, int *__restrict __sig) > __attribute__ ((__nonnull__ (1, 2))); > > > > > > >extern int sigwaitinfo (const sigset_t *__restrict __set, > siginfo_t *__restrict __info) __attribute__ ((__nonnull__ (1))); > > > > > > >extern int sigtimedwait (const sigset_t *__restrict __set, > siginfo_t *__restrict __info, > const struct timespec *__restrict __timeout) > __attribute__ ((__nonnull__ (1))); > > > >extern int sigqueue (__pid_t __pid, int __sig, const union sigval __val) > throw (); ># 311 "/usr/include/signal.h" 3 4 >extern const char *const _sys_siglist[65]; >extern const char *const sys_siglist[65]; > > >struct sigvec > { > __sighandler_t sv_handler; > int sv_mask; > > int sv_flags; > > }; ># 335 "/usr/include/signal.h" 3 4 >extern int sigvec (int __sig, const struct sigvec *__vec, > struct sigvec *__ovec) throw (); > > > ># 1 "/usr/include/bits/sigcontext.h" 1 3 4 ># 29 "/usr/include/bits/sigcontext.h" 3 4 >struct _fpx_sw_bytes >{ > __uint32_t magic1; > __uint32_t extended_size; > __uint64_t xstate_bv; > __uint32_t xstate_size; > __uint32_t padding[7]; >}; > >struct _fpreg >{ > unsigned short significand[4]; > unsigned short exponent; >}; > >struct _fpxreg >{ > unsigned short significand[4]; > unsigned short exponent; > unsigned short padding[3]; >}; > >struct _xmmreg >{ > __uint32_t element[4]; >}; ># 121 "/usr/include/bits/sigcontext.h" 3 4 >struct _fpstate >{ > > __uint16_t cwd; > __uint16_t swd; > __uint16_t ftw; > __uint16_t fop; > __uint64_t rip; > __uint64_t rdp; > __uint32_t mxcsr; > __uint32_t mxcr_mask; > struct _fpxreg _st[8]; > struct _xmmreg _xmm[16]; > __uint32_t padding[24]; >}; > >struct sigcontext >{ > __uint64_t r8; > __uint64_t r9; > __uint64_t r10; > __uint64_t r11; > __uint64_t r12; > __uint64_t r13; > __uint64_t r14; > __uint64_t r15; > __uint64_t rdi; > __uint64_t rsi; > __uint64_t rbp; > __uint64_t rbx; > __uint64_t rdx; > __uint64_t rax; > __uint64_t rcx; > __uint64_t rsp; > __uint64_t rip; > __uint64_t eflags; > unsigned short cs; > unsigned short gs; > unsigned short fs; > unsigned short __pad0; > __uint64_t err; > __uint64_t trapno; > __uint64_t oldmask; > __uint64_t cr2; > __extension__ union > { > struct _fpstate * fpstate; > __uint64_t __fpstate_word; > }; > __uint64_t __reserved1 [8]; >}; > > > >struct _xsave_hdr >{ > __uint64_t xstate_bv; > __uint64_t reserved1[2]; > __uint64_t reserved2[5]; >}; > >struct _ymmh_state >{ > __uint32_t ymmh_space[64]; >}; > >struct _xstate >{ > struct _fpstate fpstate; > struct _xsave_hdr xstate_hdr; > struct _ymmh_state ymmh; >}; ># 341 "/usr/include/signal.h" 2 3 4 > > >extern int sigreturn (struct sigcontext *__scp) throw (); > > > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 351 "/usr/include/signal.h" 2 3 4 > > > > >extern int siginterrupt (int __sig, int __interrupt) throw (); > ># 1 "/usr/include/bits/sigstack.h" 1 3 4 ># 25 "/usr/include/bits/sigstack.h" 3 4 >struct sigstack > { > void *ss_sp; > int ss_onstack; > }; > > > >enum >{ > SS_ONSTACK = 1, > > SS_DISABLE > >}; ># 49 "/usr/include/bits/sigstack.h" 3 4 >typedef struct sigaltstack > { > void *ss_sp; > int ss_flags; > size_t ss_size; > } stack_t; ># 358 "/usr/include/signal.h" 2 3 4 > > ># 1 "/usr/include/sys/ucontext.h" 1 3 4 ># 22 "/usr/include/sys/ucontext.h" 3 4 ># 1 "/usr/include/signal.h" 1 3 4 ># 23 "/usr/include/sys/ucontext.h" 2 3 4 ># 31 "/usr/include/sys/ucontext.h" 3 4 >__extension__ typedef long long int greg_t; > > > > > >typedef greg_t gregset_t[23]; > > > >enum >{ > REG_R8 = 0, > > REG_R9, > > REG_R10, > > REG_R11, > > REG_R12, > > REG_R13, > > REG_R14, > > REG_R15, > > REG_RDI, > > REG_RSI, > > REG_RBP, > > REG_RBX, > > REG_RDX, > > REG_RAX, > > REG_RCX, > > REG_RSP, > > REG_RIP, > > REG_EFL, > > REG_CSGSFS, > > REG_ERR, > > REG_TRAPNO, > > REG_OLDMASK, > > REG_CR2 > >}; > > >struct _libc_fpxreg >{ > unsigned short int significand[4]; > unsigned short int exponent; > unsigned short int padding[3]; >}; > >struct _libc_xmmreg >{ > __uint32_t element[4]; >}; > >struct _libc_fpstate >{ > > __uint16_t cwd; > __uint16_t swd; > __uint16_t ftw; > __uint16_t fop; > __uint64_t rip; > __uint64_t rdp; > __uint32_t mxcsr; > __uint32_t mxcr_mask; > struct _libc_fpxreg _st[8]; > struct _libc_xmmreg _xmm[16]; > __uint32_t padding[24]; >}; > > >typedef struct _libc_fpstate *fpregset_t; > > >typedef struct > { > gregset_t gregs; > > fpregset_t fpregs; > __extension__ unsigned long long __reserved1 [8]; >} mcontext_t; > > >typedef struct ucontext > { > unsigned long int uc_flags; > struct ucontext *uc_link; > stack_t uc_stack; > mcontext_t uc_mcontext; > __sigset_t uc_sigmask; > struct _libc_fpstate __fpregs_mem; > } ucontext_t; ># 361 "/usr/include/signal.h" 2 3 4 > > > > > >extern int sigstack (struct sigstack *__ss, struct sigstack *__oss) > throw () __attribute__ ((__deprecated__)); > > > >extern int sigaltstack (const struct sigaltstack *__restrict __ss, > struct sigaltstack *__restrict __oss) throw (); > > > > > > > >extern int sighold (int __sig) throw (); > > >extern int sigrelse (int __sig) throw (); > > >extern int sigignore (int __sig) throw (); > > >extern __sighandler_t sigset (int __sig, __sighandler_t __disp) throw (); > > > > > > ># 1 "/usr/include/bits/sigthread.h" 1 3 4 ># 30 "/usr/include/bits/sigthread.h" 3 4 >extern int pthread_sigmask (int __how, > const __sigset_t *__restrict __newmask, > __sigset_t *__restrict __oldmask)throw (); > > >extern int pthread_kill (pthread_t __threadid, int __signo) throw (); > > > >extern int pthread_sigqueue (pthread_t __threadid, int __signo, > const union sigval __value) throw (); ># 397 "/usr/include/signal.h" 2 3 4 > > > > > > >extern int __libc_current_sigrtmin (void) throw (); > >extern int __libc_current_sigrtmax (void) throw (); > > > >} ># 22 "/usr/include/boost/asio/detail/signal_set_service.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/signal_handler.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/signal_handler.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/signal_op.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/signal_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/signal_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class signal_op > : public operation >{ >public: > > boost::system::error_code ec_; > > > int signal_number_; > >protected: > signal_op(func_type func) > : operation(func), > signal_number_(0) > { > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 50 "/usr/include/boost/asio/detail/signal_op.hpp" 2 3 4 ># 24 "/usr/include/boost/asio/detail/signal_handler.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/signal_handler.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Handler> >class signal_handler : public signal_op >{ >public: > struct ptr { Handler* h; void* v; signal_handler* p; ~ptr() { reset(); } void reset() { if (p) { p->~signal_handler(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(signal_handler), *h); v = 0; } } }; > > signal_handler(Handler& h) > : signal_op(&signal_handler::do_complete), > handler_(static_cast<Handler&&>(h)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > signal_handler* h(static_cast<signal_handler*>(base)); > ptr p = { boost::asio::detail::addressof(h->handler_), h, h }; > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, int> > handler(h->handler_, h->ec_, h->signal_number_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > >private: > Handler handler_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 83 "/usr/include/boost/asio/detail/signal_handler.hpp" 2 3 4 ># 28 "/usr/include/boost/asio/detail/signal_set_service.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 36 "/usr/include/boost/asio/detail/signal_set_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > >enum { max_signal_number = 65 }; > > > > >extern inline struct signal_state* get_signal_state(); > >extern "C" inline void boost_asio_signal_handler(int signal_number); > >class signal_set_service >{ >public: > > class registration > { > public: > > registration() > : signal_number_(0), > queue_(0), > undelivered_(0), > next_in_table_(0), > prev_in_table_(0), > next_in_set_(0) > { > } > > private: > > friend class signal_set_service; > > > int signal_number_; > > > op_queue<signal_op>* queue_; > > > std::size_t undelivered_; > > > registration* next_in_table_; > registration* prev_in_table_; > > > registration* next_in_set_; > }; > > > class implementation_type > { > public: > > implementation_type() > : signals_(0) > { > } > > private: > > friend class signal_set_service; > > > op_queue<signal_op> queue_; > > > registration* signals_; > }; > > > inline signal_set_service(boost::asio::io_service& io_service); > > > inline ~signal_set_service(); > > > inline void shutdown_service(); > > > inline void fork_service( > boost::asio::io_service::fork_event fork_ev); > > > inline void construct(implementation_type& impl); > > > inline void destroy(implementation_type& impl); > > > inline boost::system::error_code add(implementation_type& impl, > int signal_number, boost::system::error_code& ec); > > > inline boost::system::error_code remove(implementation_type& impl, > int signal_number, boost::system::error_code& ec); > > > inline boost::system::error_code clear(implementation_type& impl, > boost::system::error_code& ec); > > > inline boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec); > > > template <typename Handler> > void async_wait(implementation_type& impl, Handler& handler) > { > > typedef signal_handler<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0; > > start_wait_op(impl, p.p); > p.v = p.p = 0; > } > > > inline static void deliver_signal(int signal_number); > >private: > > inline static void add_service(signal_set_service* service); > > > inline static void remove_service(signal_set_service* service); > > > inline static void open_descriptors(); > > > inline static void close_descriptors(); > > > inline void start_wait_op(implementation_type& impl, signal_op* op); > > > io_service_impl& io_service_; > > > > > > class pipe_read_op; > > > reactor& reactor_; > > > reactor::per_descriptor_data reactor_data_; > > > > > > registration* registrations_[max_signal_number]; > > > signal_set_service* next_; > signal_set_service* prev_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 213 "/usr/include/boost/asio/detail/signal_set_service.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/signal_set_service.ipp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/impl/signal_set_service.ipp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 21 "/usr/include/boost/asio/detail/impl/signal_set_service.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/signal_blocker.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/signal_blocker.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/posix_signal_blocker.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/posix_signal_blocker.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/csignal" 1 3 4 ># 39 "/usr/include/c++/4.9.0/csignal" 3 4 ># 40 "/usr/include/c++/4.9.0/csignal" 3 ># 50 "/usr/include/c++/4.9.0/csignal" 3 >namespace std >{ > using ::sig_atomic_t; > using ::signal; > using ::raise; >} ># 23 "/usr/include/boost/asio/detail/posix_signal_blocker.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/detail/posix_signal_blocker.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class posix_signal_blocker > : private noncopyable >{ >public: > > posix_signal_blocker() > : blocked_(false) > { > sigset_t new_mask; > sigfillset(&new_mask); > blocked_ = (pthread_sigmask(0, &new_mask, &old_mask_) == 0); > } > > > ~posix_signal_blocker() > { > if (blocked_) > pthread_sigmask(2, &old_mask_, 0); > } > > > void block() > { > if (!blocked_) > { > sigset_t new_mask; > sigfillset(&new_mask); > blocked_ = (pthread_sigmask(0, &new_mask, &old_mask_) == 0); > } > } > > > void unblock() > { > if (blocked_) > blocked_ = (pthread_sigmask(2, &old_mask_, 0) != 0); > } > >private: > > bool blocked_; > > > sigset_t old_mask_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 84 "/usr/include/boost/asio/detail/posix_signal_blocker.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/detail/signal_blocker.hpp" 2 3 4 > > > > >namespace boost { >namespace asio { >namespace detail { > > > > > > >typedef posix_signal_blocker signal_blocker; > > >} >} >} ># 23 "/usr/include/boost/asio/detail/impl/signal_set_service.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/signal_set_service.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/impl/signal_set_service.ipp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/static_mutex.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/static_mutex.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/posix_static_mutex.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/posix_static_mutex.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/posix_static_mutex.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >struct posix_static_mutex >{ > typedef boost::asio::detail::scoped_lock<posix_static_mutex> scoped_lock; > > > void init() > { > > } > > > void lock() > { > (void)::pthread_mutex_lock(&mutex_); > } > > > void unlock() > { > (void)::pthread_mutex_unlock(&mutex_); > } > > ::pthread_mutex_t mutex_; >}; > > > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 63 "/usr/include/boost/asio/detail/posix_static_mutex.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/detail/static_mutex.hpp" 2 3 4 > > > > > > >namespace boost { >namespace asio { >namespace detail { ># 43 "/usr/include/boost/asio/detail/static_mutex.hpp" 3 4 >typedef posix_static_mutex static_mutex; > > > > > > >} >} >} ># 25 "/usr/include/boost/asio/detail/impl/signal_set_service.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/impl/signal_set_service.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >struct signal_state >{ > > static_mutex mutex_; > > > int read_descriptor_; > > > int write_descriptor_; > > > bool fork_prepared_; > > > class signal_set_service* service_list_; > > > std::size_t registration_count_[max_signal_number]; >}; > >signal_state* get_signal_state() >{ > static signal_state state = { > { { { 0, 0, 0, 0, 0, 0, 0, { 0, 0 } } } }, -1, -1, false, 0, { 0 } }; > return &state; >} > >void boost_asio_signal_handler(int signal_number) >{ > > > > > > > > int saved_errno = (*__errno_location ()); > signal_state* state = get_signal_state(); > signed_size_type result = ::write(state->write_descriptor_, > &signal_number, sizeof(signal_number)); > (void)result; > (*__errno_location ()) = saved_errno; > > > > > > > >} > > > > >class signal_set_service::pipe_read_op : public reactor_op >{ >public: > pipe_read_op() > : reactor_op(&pipe_read_op::do_perform, pipe_read_op::do_complete) > { > } > > static bool do_perform(reactor_op*) > { > signal_state* state = get_signal_state(); > > int fd = state->read_descriptor_; > int signal_number = 0; > while (::read(fd, &signal_number, sizeof(int)) == sizeof(int)) > if (signal_number >= 0 && signal_number < max_signal_number) > signal_set_service::deliver_signal(signal_number); > > return false; > } > > static void do_complete(io_service_impl* , operation* base, > const boost::system::error_code& , > std::size_t ) > { > pipe_read_op* o(static_cast<pipe_read_op*>(base)); > delete o; > } >}; > > > > >signal_set_service::signal_set_service( > boost::asio::io_service& io_service) > : io_service_(boost::asio::use_service<io_service_impl>(io_service)), > > > > reactor_(boost::asio::use_service<reactor>(io_service)), > > > > next_(0), > prev_(0) >{ > get_signal_state()->mutex_.init(); > > > > > reactor_.init_task(); > > > > > for (int i = 0; i < max_signal_number; ++i) > registrations_[i] = 0; > > add_service(this); >} > >signal_set_service::~signal_set_service() >{ > remove_service(this); >} > >void signal_set_service::shutdown_service() >{ > remove_service(this); > > op_queue<operation> ops; > > for (int i = 0; i < max_signal_number; ++i) > { > registration* reg = registrations_[i]; > while (reg) > { > ops.push(*reg->queue_); > reg = reg->next_in_table_; > } > } > > io_service_.abandon_operations(ops); >} > >void signal_set_service::fork_service( > boost::asio::io_service::fork_event fork_ev) >{ > > > > signal_state* state = get_signal_state(); > static_mutex::scoped_lock lock(state->mutex_); > > switch (fork_ev) > { > case boost::asio::io_service::fork_prepare: > { > int read_descriptor = state->read_descriptor_; > state->fork_prepared_ = true; > lock.unlock(); > reactor_.deregister_internal_descriptor(read_descriptor, reactor_data_); > } > break; > case boost::asio::io_service::fork_parent: > if (state->fork_prepared_) > { > int read_descriptor = state->read_descriptor_; > state->fork_prepared_ = false; > lock.unlock(); > reactor_.register_internal_descriptor(reactor::read_op, > read_descriptor, reactor_data_, new pipe_read_op); > } > break; > case boost::asio::io_service::fork_child: > if (state->fork_prepared_) > { > boost::asio::detail::signal_blocker blocker; > close_descriptors(); > open_descriptors(); > int read_descriptor = state->read_descriptor_; > state->fork_prepared_ = false; > lock.unlock(); > reactor_.register_internal_descriptor(reactor::read_op, > read_descriptor, reactor_data_, new pipe_read_op); > } > break; > default: > break; > } > > > > > > > >} > >void signal_set_service::construct( > signal_set_service::implementation_type& impl) >{ > impl.signals_ = 0; >} > >void signal_set_service::destroy( > signal_set_service::implementation_type& impl) >{ > boost::system::error_code ignored_ec; > clear(impl, ignored_ec); > cancel(impl, ignored_ec); >} > >boost::system::error_code signal_set_service::add( > signal_set_service::implementation_type& impl, > int signal_number, boost::system::error_code& ec) >{ > > if (signal_number < 0 || signal_number > max_signal_number) > { > ec = boost::asio::error::invalid_argument; > return ec; > } > > signal_state* state = get_signal_state(); > static_mutex::scoped_lock lock(state->mutex_); > > > registration** insertion_point = &impl.signals_; > registration* next = impl.signals_; > while (next && next->signal_number_ < signal_number) > { > insertion_point = &next->next_in_set_; > next = next->next_in_set_; > } > > > if (next == 0 || next->signal_number_ != signal_number) > { > registration* new_registration = new registration; > > > > if (state->registration_count_[signal_number] == 0) > { > > using namespace std; > struct sigaction sa; > memset(&sa, 0, sizeof(sa)); > sa.__sigaction_handler.sa_handler = boost_asio_signal_handler; > sigfillset(&sa.sa_mask); > if (::sigaction(signal_number, &sa, 0) == -1) > > > > { > > > > ec = boost::system::error_code((*__errno_location ()), > boost::asio::error::get_system_category()); > > delete new_registration; > return ec; > } > } > > > > new_registration->signal_number_ = signal_number; > new_registration->queue_ = &impl.queue_; > new_registration->next_in_set_ = next; > *insertion_point = new_registration; > > > new_registration->next_in_table_ = registrations_[signal_number]; > if (registrations_[signal_number]) > registrations_[signal_number]->prev_in_table_ = new_registration; > registrations_[signal_number] = new_registration; > > ++state->registration_count_[signal_number]; > } > > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code signal_set_service::remove( > signal_set_service::implementation_type& impl, > int signal_number, boost::system::error_code& ec) >{ > > if (signal_number < 0 || signal_number > max_signal_number) > { > ec = boost::asio::error::invalid_argument; > return ec; > } > > signal_state* state = get_signal_state(); > static_mutex::scoped_lock lock(state->mutex_); > > > registration** deletion_point = &impl.signals_; > registration* reg = impl.signals_; > while (reg && reg->signal_number_ < signal_number) > { > deletion_point = ®->next_in_set_; > reg = reg->next_in_set_; > } > > if (reg != 0 && reg->signal_number_ == signal_number) > { > > > if (state->registration_count_[signal_number] == 1) > { > > using namespace std; > struct sigaction sa; > memset(&sa, 0, sizeof(sa)); > sa.__sigaction_handler.sa_handler = ((__sighandler_t) 0); > if (::sigaction(signal_number, &sa, 0) == -1) > > > > { > > > > ec = boost::system::error_code((*__errno_location ()), > boost::asio::error::get_system_category()); > > return ec; > } > } > > > > *deletion_point = reg->next_in_set_; > > > if (registrations_[signal_number] == reg) > registrations_[signal_number] = reg->next_in_table_; > if (reg->prev_in_table_) > reg->prev_in_table_->next_in_table_ = reg->next_in_table_; > if (reg->next_in_table_) > reg->next_in_table_->prev_in_table_ = reg->prev_in_table_; > > --state->registration_count_[signal_number]; > > delete reg; > } > > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code signal_set_service::clear( > signal_set_service::implementation_type& impl, > boost::system::error_code& ec) >{ > signal_state* state = get_signal_state(); > static_mutex::scoped_lock lock(state->mutex_); > > while (registration* reg = impl.signals_) > { > > > if (state->registration_count_[reg->signal_number_] == 1) > { > > using namespace std; > struct sigaction sa; > memset(&sa, 0, sizeof(sa)); > sa.__sigaction_handler.sa_handler = ((__sighandler_t) 0); > if (::sigaction(reg->signal_number_, &sa, 0) == -1) > > > > { > > > > ec = boost::system::error_code((*__errno_location ()), > boost::asio::error::get_system_category()); > > return ec; > } > } > > > > if (registrations_[reg->signal_number_] == reg) > registrations_[reg->signal_number_] = reg->next_in_table_; > if (reg->prev_in_table_) > reg->prev_in_table_->next_in_table_ = reg->next_in_table_; > if (reg->next_in_table_) > reg->next_in_table_->prev_in_table_ = reg->prev_in_table_; > > --state->registration_count_[reg->signal_number_]; > > impl.signals_ = reg->next_in_set_; > delete reg; > } > > ec = boost::system::error_code(); > return ec; >} > >boost::system::error_code signal_set_service::cancel( > signal_set_service::implementation_type& impl, > boost::system::error_code& ec) >{ > (void)0; > > op_queue<operation> ops; > { > signal_state* state = get_signal_state(); > static_mutex::scoped_lock lock(state->mutex_); > > while (signal_op* op = impl.queue_.front()) > { > op->ec_ = boost::asio::error::operation_aborted; > impl.queue_.pop(); > ops.push(op); > } > } > > io_service_.post_deferred_completions(ops); > > ec = boost::system::error_code(); > return ec; >} > >void signal_set_service::deliver_signal(int signal_number) >{ > signal_state* state = get_signal_state(); > static_mutex::scoped_lock lock(state->mutex_); > > signal_set_service* service = state->service_list_; > while (service) > { > op_queue<operation> ops; > > registration* reg = service->registrations_[signal_number]; > while (reg) > { > if (reg->queue_->empty()) > { > ++reg->undelivered_; > } > else > { > while (signal_op* op = reg->queue_->front()) > { > op->signal_number_ = signal_number; > reg->queue_->pop(); > ops.push(op); > } > } > > reg = reg->next_in_table_; > } > > service->io_service_.post_deferred_completions(ops); > > service = service->next_; > } >} > >void signal_set_service::add_service(signal_set_service* service) >{ > signal_state* state = get_signal_state(); > static_mutex::scoped_lock lock(state->mutex_); > > > > if (state->service_list_ == 0) > open_descriptors(); > > > > service->next_ = state->service_list_; > service->prev_ = 0; > if (state->service_list_) > state->service_list_->prev_ = service; > state->service_list_ = service; > > > > > > int read_descriptor = state->read_descriptor_; > lock.unlock(); > service->reactor_.register_internal_descriptor(reactor::read_op, > read_descriptor, service->reactor_data_, new pipe_read_op); > > > >} > >void signal_set_service::remove_service(signal_set_service* service) >{ > signal_state* state = get_signal_state(); > static_mutex::scoped_lock lock(state->mutex_); > > if (service->next_ || service->prev_ || state->service_list_ == service) > { > > > > > int read_descriptor = state->read_descriptor_; > lock.unlock(); > service->reactor_.deregister_descriptor( > read_descriptor, service->reactor_data_, false); > lock.lock(); > > > > > > if (state->service_list_ == service) > state->service_list_ = service->next_; > if (service->prev_) > service->prev_->next_ = service->next_; > if (service->next_) > service->next_->prev_= service->prev_; > service->next_ = 0; > service->prev_ = 0; > > > > if (state->service_list_ == 0) > close_descriptors(); > > } >} > >void signal_set_service::open_descriptors() >{ > > > > signal_state* state = get_signal_state(); > > int pipe_fds[2]; > if (::pipe(pipe_fds) == 0) > { > state->read_descriptor_ = pipe_fds[0]; > ::fcntl(state->read_descriptor_, 4, 04000); > > state->write_descriptor_ = pipe_fds[1]; > ::fcntl(state->write_descriptor_, 4, 04000); > > > ::fcntl(state->read_descriptor_, 2, 1); > ::fcntl(state->write_descriptor_, 2, 1); > > } > else > { > boost::system::error_code ec((*__errno_location ()), > boost::asio::error::get_system_category()); > boost::asio::detail::throw_error(ec, "signal_set_service pipe"); > } > > > >} > >void signal_set_service::close_descriptors() >{ > > > > signal_state* state = get_signal_state(); > > if (state->read_descriptor_ != -1) > ::close(state->read_descriptor_); > state->read_descriptor_ = -1; > > if (state->write_descriptor_ != -1) > ::close(state->write_descriptor_); > state->write_descriptor_ = -1; > > > >} > >void signal_set_service::start_wait_op( > signal_set_service::implementation_type& impl, signal_op* op) >{ > io_service_.work_started(); > > signal_state* state = get_signal_state(); > static_mutex::scoped_lock lock(state->mutex_); > > registration* reg = impl.signals_; > while (reg) > { > if (reg->undelivered_ > 0) > { > --reg->undelivered_; > op->signal_number_ = reg->signal_number_; > io_service_.post_deferred_completion(op); > return; > } > > reg = reg->next_in_set_; > } > > impl.queue_.push(op); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 648 "/usr/include/boost/asio/detail/impl/signal_set_service.ipp" 2 3 4 ># 216 "/usr/include/boost/asio/detail/signal_set_service.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/signal_set_service.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/signal_set_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >class signal_set_service > > > > : public boost::asio::detail::service_base<signal_set_service> > >{ >public: > > > > > >public: > > > > > typedef detail::signal_set_service::implementation_type implementation_type; > > > > explicit signal_set_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base<signal_set_service>(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > boost::system::error_code add(implementation_type& impl, > int signal_number, boost::system::error_code& ec) > { > return service_impl_.add(impl, signal_number, ec); > } > > > boost::system::error_code remove(implementation_type& impl, > int signal_number, boost::system::error_code& ec) > { > return service_impl_.remove(impl, signal_number, ec); > } > > > boost::system::error_code clear(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.clear(impl, ec); > } > > > boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > template <typename SignalHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<SignalHandler, void (boost::system::error_code, int)>::type>::type > > async_wait(implementation_type& impl, > SignalHandler&& handler) > { > detail::async_result_init< > SignalHandler, void (boost::system::error_code, int)> init( > static_cast<SignalHandler&&>(handler)); > > service_impl_.async_wait(impl, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > void fork_service(boost::asio::io_service::fork_event event) > { > service_impl_.fork_service(event); > } > > > detail::signal_set_service service_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 135 "/usr/include/boost/asio/signal_set_service.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/basic_signal_set.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/basic_signal_set.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 93 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 >template <typename SignalSetService = signal_set_service> >class basic_signal_set > : public basic_io_object<SignalSetService> >{ >public: > > > > > > > > explicit basic_signal_set(boost::asio::io_service& io_service) > : basic_io_object<SignalSetService>(io_service) > { > } ># 123 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > basic_signal_set(boost::asio::io_service& io_service, int signal_number_1) > : basic_io_object<SignalSetService>(io_service) > { > boost::system::error_code ec; > this->service.add(this->implementation, signal_number_1, ec); > boost::asio::detail::throw_error(ec, "add"); > } ># 147 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > basic_signal_set(boost::asio::io_service& io_service, int signal_number_1, > int signal_number_2) > : basic_io_object<SignalSetService>(io_service) > { > boost::system::error_code ec; > this->service.add(this->implementation, signal_number_1, ec); > boost::asio::detail::throw_error(ec, "add"); > this->service.add(this->implementation, signal_number_2, ec); > boost::asio::detail::throw_error(ec, "add"); > } ># 177 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > basic_signal_set(boost::asio::io_service& io_service, int signal_number_1, > int signal_number_2, int signal_number_3) > : basic_io_object<SignalSetService>(io_service) > { > boost::system::error_code ec; > this->service.add(this->implementation, signal_number_1, ec); > boost::asio::detail::throw_error(ec, "add"); > this->service.add(this->implementation, signal_number_2, ec); > boost::asio::detail::throw_error(ec, "add"); > this->service.add(this->implementation, signal_number_3, ec); > boost::asio::detail::throw_error(ec, "add"); > } ># 199 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > void add(int signal_number) > { > boost::system::error_code ec; > this->service.add(this->implementation, signal_number, ec); > boost::asio::detail::throw_error(ec, "add"); > } ># 215 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > boost::system::error_code add(int signal_number, > boost::system::error_code& ec) > { > return this->service.add(this->implementation, signal_number, ec); > } ># 233 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > void remove(int signal_number) > { > boost::system::error_code ec; > this->service.remove(this->implementation, signal_number, ec); > boost::asio::detail::throw_error(ec, "remove"); > } ># 252 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > boost::system::error_code remove(int signal_number, > boost::system::error_code& ec) > { > return this->service.remove(this->implementation, signal_number, ec); > } ># 267 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > void clear() > { > boost::system::error_code ec; > this->service.clear(this->implementation, ec); > boost::asio::detail::throw_error(ec, "clear"); > } ># 283 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > boost::system::error_code clear(boost::system::error_code& ec) > { > return this->service.clear(this->implementation, ec); > } ># 309 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > void cancel() > { > boost::system::error_code ec; > this->service.cancel(this->implementation, ec); > boost::asio::detail::throw_error(ec, "cancel"); > } ># 337 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > boost::system::error_code cancel(boost::system::error_code& ec) > { > return this->service.cancel(this->implementation, ec); > } ># 367 "/usr/include/boost/asio/basic_signal_set.hpp" 3 4 > template <typename SignalHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<SignalHandler, void (boost::system::error_code, int)>::type>::type > > async_wait(SignalHandler&& handler) > { > > > typedef typename handler_type<SignalHandler, void(boost::system::error_code, int)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const int*>(0))) == 1, "SignalHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const int>()), char(0))> __attribute__((__unused__)) type_check; > > return this->service.async_wait(this->implementation, > static_cast<SignalHandler&&>(handler)); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 385 "/usr/include/boost/asio/basic_signal_set.hpp" 2 3 4 ># 28 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 ># 1 "/usr/include/boost/asio/socket_acceptor_service.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/socket_acceptor_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/socket_acceptor_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >template <typename Protocol> >class socket_acceptor_service > > > > : public boost::asio::detail::service_base<socket_acceptor_service<Protocol> > > >{ >public: > > > > > > > typedef Protocol protocol_type; > > > typedef typename protocol_type::endpoint endpoint_type; > >private: > > > > > > > typedef detail::reactive_socket_service<Protocol> service_impl_type; > > >public: > > > > > typedef typename service_impl_type::implementation_type implementation_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_handle_type; > > > > explicit socket_acceptor_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base< > socket_acceptor_service<Protocol> >(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > > void move_construct(implementation_type& impl, > implementation_type& other_impl) > { > service_impl_.move_construct(impl, other_impl); > } > > > void move_assign(implementation_type& impl, > socket_acceptor_service& other_service, > implementation_type& other_impl) > { > service_impl_.move_assign(impl, other_service.service_impl_, other_impl); > } > > > > template <typename Protocol1> > void converting_move_construct(implementation_type& impl, > typename socket_acceptor_service< > Protocol1>::implementation_type& other_impl, > typename enable_if<is_convertible< > Protocol1, Protocol>::value>::type* = 0) > { > service_impl_.template converting_move_construct<Protocol1>( > impl, other_impl); > } > > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > boost::system::error_code open(implementation_type& impl, > const protocol_type& protocol, boost::system::error_code& ec) > { > return service_impl_.open(impl, protocol, ec); > } > > > boost::system::error_code assign(implementation_type& impl, > const protocol_type& protocol, const native_handle_type& native_acceptor, > boost::system::error_code& ec) > { > return service_impl_.assign(impl, protocol, native_acceptor, ec); > } > > > bool is_open(const implementation_type& impl) const > { > return service_impl_.is_open(impl); > } > > > boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > boost::system::error_code bind(implementation_type& impl, > const endpoint_type& endpoint, boost::system::error_code& ec) > { > return service_impl_.bind(impl, endpoint, ec); > } > > > > boost::system::error_code listen(implementation_type& impl, int backlog, > boost::system::error_code& ec) > { > return service_impl_.listen(impl, backlog, ec); > } > > > boost::system::error_code close(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.close(impl, ec); > } > > > native_type native(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > native_handle_type native_handle(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > template <typename SettableSocketOption> > boost::system::error_code set_option(implementation_type& impl, > const SettableSocketOption& option, boost::system::error_code& ec) > { > return service_impl_.set_option(impl, option, ec); > } > > > template <typename GettableSocketOption> > boost::system::error_code get_option(const implementation_type& impl, > GettableSocketOption& option, boost::system::error_code& ec) const > { > return service_impl_.get_option(impl, option, ec); > } > > > template <typename IoControlCommand> > boost::system::error_code io_control(implementation_type& impl, > IoControlCommand& command, boost::system::error_code& ec) > { > return service_impl_.io_control(impl, command, ec); > } > > > bool non_blocking(const implementation_type& impl) const > { > return service_impl_.non_blocking(impl); > } > > > boost::system::error_code non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.non_blocking(impl, mode, ec); > } > > > bool native_non_blocking(const implementation_type& impl) const > { > return service_impl_.native_non_blocking(impl); > } > > > boost::system::error_code native_non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.native_non_blocking(impl, mode, ec); > } > > > endpoint_type local_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.local_endpoint(impl, ec); > } > > > template <typename Protocol1, typename SocketService> > boost::system::error_code accept(implementation_type& impl, > basic_socket<Protocol1, SocketService>& peer, > endpoint_type* peer_endpoint, boost::system::error_code& ec, > typename enable_if<is_convertible<Protocol, Protocol1>::value>::type* = 0) > { > return service_impl_.accept(impl, peer, peer_endpoint, ec); > } > > > template <typename Protocol1, typename SocketService, typename AcceptHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<AcceptHandler, void (boost::system::error_code)>::type>::type > > async_accept(implementation_type& impl, > basic_socket<Protocol1, SocketService>& peer, > endpoint_type* peer_endpoint, > AcceptHandler&& handler, > typename enable_if<is_convertible<Protocol, Protocol1>::value>::type* = 0) > { > detail::async_result_init< > AcceptHandler, void (boost::system::error_code)> init( > static_cast<AcceptHandler&&>(handler)); > > service_impl_.async_accept(impl, peer, peer_endpoint, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > service_impl_type service_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 303 "/usr/include/boost/asio/socket_acceptor_service.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 53 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 >template <typename Protocol, > typename SocketAcceptorService = socket_acceptor_service<Protocol> > >class basic_socket_acceptor > : public basic_io_object<SocketAcceptorService>, > public socket_base >{ >public: > > > typedef typename SocketAcceptorService::native_handle_type native_type; > > > typedef typename SocketAcceptorService::native_handle_type native_handle_type; > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; ># 83 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > explicit basic_socket_acceptor(boost::asio::io_service& io_service) > : basic_io_object<SocketAcceptorService>(io_service) > { > } ># 100 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > basic_socket_acceptor(boost::asio::io_service& io_service, > const protocol_type& protocol) > : basic_io_object<SocketAcceptorService>(io_service) > { > boost::system::error_code ec; > this->get_service().open(this->get_implementation(), protocol, ec); > boost::asio::detail::throw_error(ec, "open"); > } ># 136 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > basic_socket_acceptor(boost::asio::io_service& io_service, > const endpoint_type& endpoint, bool reuse_addr = true) > : basic_io_object<SocketAcceptorService>(io_service) > { > boost::system::error_code ec; > const protocol_type protocol = endpoint.protocol(); > this->get_service().open(this->get_implementation(), protocol, ec); > boost::asio::detail::throw_error(ec, "open"); > if (reuse_addr) > { > this->get_service().set_option(this->get_implementation(), > socket_base::reuse_address(true), ec); > boost::asio::detail::throw_error(ec, "set_option"); > } > this->get_service().bind(this->get_implementation(), endpoint, ec); > boost::asio::detail::throw_error(ec, "bind"); > this->get_service().listen(this->get_implementation(), > socket_base::max_connections, ec); > boost::asio::detail::throw_error(ec, "listen"); > } ># 172 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > basic_socket_acceptor(boost::asio::io_service& io_service, > const protocol_type& protocol, const native_handle_type& native_acceptor) > : basic_io_object<SocketAcceptorService>(io_service) > { > boost::system::error_code ec; > this->get_service().assign(this->get_implementation(), > protocol, native_acceptor, ec); > boost::asio::detail::throw_error(ec, "assign"); > } ># 193 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > basic_socket_acceptor(basic_socket_acceptor&& other) > : basic_io_object<SocketAcceptorService>( > static_cast<basic_socket_acceptor&&>(other)) > { > } ># 209 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > basic_socket_acceptor& operator=(basic_socket_acceptor&& other) > { > basic_io_object<SocketAcceptorService>::operator=( > static_cast<basic_socket_acceptor&&>(other)); > return *this; > } > > > template <typename Protocol1, typename SocketAcceptorService1> > friend class basic_socket_acceptor; ># 231 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename Protocol1, typename SocketAcceptorService1> > basic_socket_acceptor( > basic_socket_acceptor<Protocol1, SocketAcceptorService1>&& other, > typename enable_if<is_convertible<Protocol1, Protocol>::value>::type* = 0) > : basic_io_object<SocketAcceptorService>(other.get_io_service()) > { > this->get_service().template converting_move_construct<Protocol1>( > this->get_implementation(), other.get_implementation()); > } ># 252 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename Protocol1, typename SocketAcceptorService1> > typename enable_if<is_convertible<Protocol1, Protocol>::value, > basic_socket_acceptor>::type& operator=( > basic_socket_acceptor<Protocol1, SocketAcceptorService1>&& other) > { > basic_socket_acceptor tmp(static_cast<basic_socket_acceptor< Protocol1, SocketAcceptorService1>&&> > (other)); > basic_io_object<SocketAcceptorService>::operator=( > static_cast<basic_socket_acceptor&&>(tmp)); > return *this; > } ># 280 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > void open(const protocol_type& protocol = protocol_type()) > { > boost::system::error_code ec; > this->get_service().open(this->get_implementation(), protocol, ec); > boost::asio::detail::throw_error(ec, "open"); > } ># 307 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > boost::system::error_code open(const protocol_type& protocol, > boost::system::error_code& ec) > { > return this->get_service().open(this->get_implementation(), protocol, ec); > } ># 323 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > void assign(const protocol_type& protocol, > const native_handle_type& native_acceptor) > { > boost::system::error_code ec; > this->get_service().assign(this->get_implementation(), > protocol, native_acceptor, ec); > boost::asio::detail::throw_error(ec, "assign"); > } ># 342 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > boost::system::error_code assign(const protocol_type& protocol, > const native_handle_type& native_acceptor, boost::system::error_code& ec) > { > return this->get_service().assign(this->get_implementation(), > protocol, native_acceptor, ec); > } > > > bool is_open() const > { > return this->get_service().is_open(this->get_implementation()); > } ># 373 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > void bind(const endpoint_type& endpoint) > { > boost::system::error_code ec; > this->get_service().bind(this->get_implementation(), endpoint, ec); > boost::asio::detail::throw_error(ec, "bind"); > } ># 403 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > boost::system::error_code bind(const endpoint_type& endpoint, > boost::system::error_code& ec) > { > return this->get_service().bind(this->get_implementation(), endpoint, ec); > } ># 419 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > void listen(int backlog = socket_base::max_connections) > { > boost::system::error_code ec; > this->get_service().listen(this->get_implementation(), backlog, ec); > boost::asio::detail::throw_error(ec, "listen"); > } ># 448 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > boost::system::error_code listen(int backlog, boost::system::error_code& ec) > { > return this->get_service().listen(this->get_implementation(), backlog, ec); > } ># 463 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > void close() > { > boost::system::error_code ec; > this->get_service().close(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "close"); > } ># 492 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > boost::system::error_code close(boost::system::error_code& ec) > { > return this->get_service().close(this->get_implementation(), ec); > } > > > > > > > > native_type native() > { > return this->get_service().native_handle(this->get_implementation()); > } > > > > > > > > native_handle_type native_handle() > { > return this->get_service().native_handle(this->get_implementation()); > } ># 527 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > void cancel() > { > boost::system::error_code ec; > this->get_service().cancel(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "cancel"); > } ># 542 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > boost::system::error_code cancel(boost::system::error_code& ec) > { > return this->get_service().cancel(this->get_implementation(), ec); > } ># 568 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename SettableSocketOption> > void set_option(const SettableSocketOption& option) > { > boost::system::error_code ec; > this->get_service().set_option(this->get_implementation(), option, ec); > boost::asio::detail::throw_error(ec, "set_option"); > } ># 602 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename SettableSocketOption> > boost::system::error_code set_option(const SettableSocketOption& option, > boost::system::error_code& ec) > { > return this->get_service().set_option( > this->get_implementation(), option, ec); > } ># 632 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename GettableSocketOption> > void get_option(GettableSocketOption& option) > { > boost::system::error_code ec; > this->get_service().get_option(this->get_implementation(), option, ec); > boost::asio::detail::throw_error(ec, "get_option"); > } ># 667 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename GettableSocketOption> > boost::system::error_code get_option(GettableSocketOption& option, > boost::system::error_code& ec) > { > return this->get_service().get_option( > this->get_implementation(), option, ec); > } ># 695 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename IoControlCommand> > void io_control(IoControlCommand& command) > { > boost::system::error_code ec; > this->get_service().io_control(this->get_implementation(), command, ec); > boost::asio::detail::throw_error(ec, "io_control"); > } ># 728 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename IoControlCommand> > boost::system::error_code io_control(IoControlCommand& command, > boost::system::error_code& ec) > { > return this->get_service().io_control( > this->get_implementation(), command, ec); > } ># 747 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > bool non_blocking() const > { > return this->get_service().non_blocking(this->get_implementation()); > } ># 765 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > void non_blocking(bool mode) > { > boost::system::error_code ec; > this->get_service().non_blocking(this->get_implementation(), mode, ec); > boost::asio::detail::throw_error(ec, "non_blocking"); > } ># 785 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > boost::system::error_code non_blocking( > bool mode, boost::system::error_code& ec) > { > return this->get_service().non_blocking( > this->get_implementation(), mode, ec); > } ># 806 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > bool native_non_blocking() const > { > return this->get_service().native_non_blocking(this->get_implementation()); > } ># 826 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > void native_non_blocking(bool mode) > { > boost::system::error_code ec; > this->get_service().native_non_blocking( > this->get_implementation(), mode, ec); > boost::asio::detail::throw_error(ec, "native_non_blocking"); > } ># 849 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > boost::system::error_code native_non_blocking( > bool mode, boost::system::error_code& ec) > { > return this->get_service().native_non_blocking( > this->get_implementation(), mode, ec); > } ># 871 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > endpoint_type local_endpoint() const > { > boost::system::error_code ec; > endpoint_type ep = this->get_service().local_endpoint( > this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "local_endpoint"); > return ep; > } ># 902 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > endpoint_type local_endpoint(boost::system::error_code& ec) const > { > return this->get_service().local_endpoint(this->get_implementation(), ec); > } ># 925 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename Protocol1, typename SocketService> > void accept(basic_socket<Protocol1, SocketService>& peer, > typename enable_if<is_convertible<Protocol, Protocol1>::value>::type* = 0) > { > boost::system::error_code ec; > this->get_service().accept(this->get_implementation(), > peer, static_cast<endpoint_type*>(0), ec); > boost::asio::detail::throw_error(ec, "accept"); > } ># 958 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename Protocol1, typename SocketService> > boost::system::error_code accept( > basic_socket<Protocol1, SocketService>& peer, > boost::system::error_code& ec, > typename enable_if<is_convertible<Protocol, Protocol1>::value>::type* = 0) > { > return this->get_service().accept(this->get_implementation(), > peer, static_cast<endpoint_type*>(0), ec); > } ># 1006 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename Protocol1, typename SocketService, typename AcceptHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<AcceptHandler, void (boost::system::error_code)>::type>::type > > async_accept(basic_socket<Protocol1, SocketService>& peer, > AcceptHandler&& handler, > typename enable_if<is_convertible<Protocol, Protocol1>::value>::type* = 0) > { > > > typedef typename handler_type<AcceptHandler, void(boost::system::error_code)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::one_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0))) == 1, "AcceptHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_accept(this->get_implementation(), > peer, static_cast<endpoint_type*>(0), > static_cast<AcceptHandler&&>(handler)); > } ># 1045 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename SocketService> > void accept(basic_socket<protocol_type, SocketService>& peer, > endpoint_type& peer_endpoint) > { > boost::system::error_code ec; > this->get_service().accept(this->get_implementation(), > peer, &peer_endpoint, ec); > boost::asio::detail::throw_error(ec, "accept"); > } ># 1083 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename SocketService> > boost::system::error_code accept( > basic_socket<protocol_type, SocketService>& peer, > endpoint_type& peer_endpoint, boost::system::error_code& ec) > { > return this->get_service().accept( > this->get_implementation(), peer, &peer_endpoint, ec); > } ># 1118 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 3 4 > template <typename SocketService, typename AcceptHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<AcceptHandler, void (boost::system::error_code)>::type>::type > > async_accept(basic_socket<protocol_type, SocketService>& peer, > endpoint_type& peer_endpoint, AcceptHandler&& handler) > { > > > typedef typename handler_type<AcceptHandler, void(boost::system::error_code)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::one_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0))) == 1, "AcceptHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_accept(this->get_implementation(), peer, > &peer_endpoint, static_cast<AcceptHandler&&>(handler)); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 1137 "/usr/include/boost/asio/basic_socket_acceptor.hpp" 2 3 4 ># 29 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/basic_socket_iostream.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/basic_socket_iostream.hpp" 3 4 ># 1 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/array.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/array.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > > >using std::array; > > > > >} >} >} ># 26 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/stream_socket_service.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/stream_socket_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 34 "/usr/include/boost/asio/stream_socket_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >template <typename Protocol> >class stream_socket_service > > > > : public boost::asio::detail::service_base<stream_socket_service<Protocol> > > >{ >public: > > > > > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; > >private: > > > > > > > typedef detail::reactive_socket_service<Protocol> service_impl_type; > > >public: > > > > > typedef typename service_impl_type::implementation_type implementation_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_type; > > > > > > > typedef typename service_impl_type::native_handle_type native_handle_type; > > > > explicit stream_socket_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base< > stream_socket_service<Protocol> >(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > > void move_construct(implementation_type& impl, > implementation_type& other_impl) > { > service_impl_.move_construct(impl, other_impl); > } > > > void move_assign(implementation_type& impl, > stream_socket_service& other_service, > implementation_type& other_impl) > { > service_impl_.move_assign(impl, other_service.service_impl_, other_impl); > } > > > > template <typename Protocol1> > void converting_move_construct(implementation_type& impl, > typename stream_socket_service< > Protocol1>::implementation_type& other_impl, > typename enable_if<is_convertible< > Protocol1, Protocol>::value>::type* = 0) > { > service_impl_.template converting_move_construct<Protocol1>( > impl, other_impl); > } > > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > boost::system::error_code open(implementation_type& impl, > const protocol_type& protocol, boost::system::error_code& ec) > { > if (protocol.type() == SOCK_STREAM) > service_impl_.open(impl, protocol, ec); > else > ec = boost::asio::error::invalid_argument; > return ec; > } > > > boost::system::error_code assign(implementation_type& impl, > const protocol_type& protocol, const native_handle_type& native_socket, > boost::system::error_code& ec) > { > return service_impl_.assign(impl, protocol, native_socket, ec); > } > > > bool is_open(const implementation_type& impl) const > { > return service_impl_.is_open(impl); > } > > > boost::system::error_code close(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.close(impl, ec); > } > > > native_type native(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > native_handle_type native_handle(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > bool at_mark(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.at_mark(impl, ec); > } > > > std::size_t available(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.available(impl, ec); > } > > > boost::system::error_code bind(implementation_type& impl, > const endpoint_type& endpoint, boost::system::error_code& ec) > { > return service_impl_.bind(impl, endpoint, ec); > } > > > boost::system::error_code connect(implementation_type& impl, > const endpoint_type& peer_endpoint, boost::system::error_code& ec) > { > return service_impl_.connect(impl, peer_endpoint, ec); > } > > > template <typename ConnectHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ConnectHandler, void (boost::system::error_code)>::type>::type > > async_connect(implementation_type& impl, > const endpoint_type& peer_endpoint, > ConnectHandler&& handler) > { > detail::async_result_init< > ConnectHandler, void (boost::system::error_code)> init( > static_cast<ConnectHandler&&>(handler)); > > service_impl_.async_connect(impl, peer_endpoint, init.handler); > > return init.result.get(); > } > > > template <typename SettableSocketOption> > boost::system::error_code set_option(implementation_type& impl, > const SettableSocketOption& option, boost::system::error_code& ec) > { > return service_impl_.set_option(impl, option, ec); > } > > > template <typename GettableSocketOption> > boost::system::error_code get_option(const implementation_type& impl, > GettableSocketOption& option, boost::system::error_code& ec) const > { > return service_impl_.get_option(impl, option, ec); > } > > > template <typename IoControlCommand> > boost::system::error_code io_control(implementation_type& impl, > IoControlCommand& command, boost::system::error_code& ec) > { > return service_impl_.io_control(impl, command, ec); > } > > > bool non_blocking(const implementation_type& impl) const > { > return service_impl_.non_blocking(impl); > } > > > boost::system::error_code non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.non_blocking(impl, mode, ec); > } > > > bool native_non_blocking(const implementation_type& impl) const > { > return service_impl_.native_non_blocking(impl); > } > > > boost::system::error_code native_non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.native_non_blocking(impl, mode, ec); > } > > > endpoint_type local_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.local_endpoint(impl, ec); > } > > > endpoint_type remote_endpoint(const implementation_type& impl, > boost::system::error_code& ec) const > { > return service_impl_.remote_endpoint(impl, ec); > } > > > boost::system::error_code shutdown(implementation_type& impl, > socket_base::shutdown_type what, boost::system::error_code& ec) > { > return service_impl_.shutdown(impl, what, ec); > } > > > template <typename ConstBufferSequence> > std::size_t send(implementation_type& impl, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.send(impl, buffers, flags, ec); > } > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(implementation_type& impl, > const ConstBufferSequence& buffers, > socket_base::message_flags flags, > WriteHandler&& handler) > { > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > service_impl_.async_send(impl, buffers, flags, init.handler); > > return init.result.get(); > } > > > template <typename MutableBufferSequence> > std::size_t receive(implementation_type& impl, > const MutableBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return service_impl_.receive(impl, buffers, flags, ec); > } > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(implementation_type& impl, > const MutableBufferSequence& buffers, > socket_base::message_flags flags, > ReadHandler&& handler) > { > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > service_impl_.async_receive(impl, buffers, flags, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > service_impl_type service_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 377 "/usr/include/boost/asio/stream_socket_service.hpp" 2 3 4 ># 29 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/deadline_timer.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/deadline_timer.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/deadline_timer.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/deadline_timer.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >typedef basic_deadline_timer<boost::posix_time::ptime> deadline_timer; > >} >} ># 32 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 2 3 4 ># 73 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 74 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > > >class socket_streambuf_base >{ >protected: > io_service io_service_; >}; > >} > > >template <typename Protocol, > typename StreamSocketService = stream_socket_service<Protocol>, > > > typename Time = boost::posix_time::ptime, > typename TimeTraits = boost::asio::time_traits<Time>, > typename TimerService = deadline_timer_service<Time, TimeTraits> > > > > > > >class basic_socket_streambuf > : public std::streambuf, > private detail::socket_streambuf_base, > public basic_socket<Protocol, StreamSocketService> >{ >private: > > > > typedef TimeTraits traits_helper; > > > > >public: > > typedef typename Protocol::endpoint endpoint_type; ># 127 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 3 4 > typedef typename traits_helper::time_type time_type; > typedef typename traits_helper::duration_type duration_type; > > > > basic_socket_streambuf() > : basic_socket<Protocol, StreamSocketService>( > this->detail::socket_streambuf_base::io_service_), > unbuffered_(false), > timer_service_(0), > timer_state_(no_timer) > { > init_buffers(); > } > > > virtual ~basic_socket_streambuf() > { > if (pptr() != pbase()) > overflow(traits_type::eof()); > > destroy_timer(); > } ># 158 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 3 4 > basic_socket_streambuf<Protocol, StreamSocketService, > Time, TimeTraits, TimerService>* connect( > const endpoint_type& endpoint) > { > init_buffers(); > > this->basic_socket<Protocol, StreamSocketService>::close(ec_); > > if (timer_state_ == timer_has_expired) > { > ec_ = boost::asio::error::operation_aborted; > return 0; > } > > io_handler handler = { this }; > this->basic_socket<Protocol, StreamSocketService>::async_connect( > endpoint, handler); > > ec_ = boost::asio::error::would_block; > this->get_service().get_io_service().reset(); > do this->get_service().get_io_service().run_one(); > while (ec_ == boost::asio::error::would_block); > > return !ec_ ? this : 0; > } ># 198 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 3 4 > template <typename... T> > basic_socket_streambuf<Protocol, StreamSocketService, > Time, TimeTraits, TimerService>* connect(T... x) > { > init_buffers(); > this->basic_socket<Protocol, StreamSocketService>::close(ec_); > typedef typename Protocol::resolver resolver_type; > typedef typename resolver_type::query resolver_query; > resolver_query query(x...); > resolve_and_connect(query); > return !ec_ ? this : 0; > } ># 219 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 3 4 > basic_socket_streambuf<Protocol, StreamSocketService, > Time, TimeTraits, TimerService>* close() > { > sync(); > this->basic_socket<Protocol, StreamSocketService>::close(ec_); > if (!ec_) > init_buffers(); > return !ec_ ? this : 0; > } > > > > > > > const boost::system::error_code& puberror() const > { > return error(); > } > > > > > > > time_type expires_at() const > { > return timer_service_ > ? timer_service_->expires_at(timer_implementation_) > : time_type(); > } ># 260 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 3 4 > void expires_at(const time_type& expiry_time) > { > construct_timer(); > > boost::system::error_code ec; > timer_service_->expires_at(timer_implementation_, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_at"); > > start_timer(); > } > > > > > > duration_type expires_from_now() const > { > return traits_helper::subtract(expires_at(), traits_helper::now()); > } ># 289 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 3 4 > void expires_from_now(const duration_type& expiry_time) > { > construct_timer(); > > boost::system::error_code ec; > timer_service_->expires_from_now(timer_implementation_, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_from_now"); > > start_timer(); > } > >protected: > int_type underflow() > { > if (gptr() == egptr()) > { > if (timer_state_ == timer_has_expired) > { > ec_ = boost::asio::error::operation_aborted; > return traits_type::eof(); > } > > io_handler handler = { this }; > this->get_service().async_receive(this->get_implementation(), > boost::asio::buffer(boost::asio::buffer(get_buffer_) + putback_max), > 0, handler); > > ec_ = boost::asio::error::would_block; > this->get_service().get_io_service().reset(); > do this->get_service().get_io_service().run_one(); > while (ec_ == boost::asio::error::would_block); > if (ec_) > return traits_type::eof(); > > setg(&get_buffer_[0], &get_buffer_[0] + putback_max, > &get_buffer_[0] + putback_max + bytes_transferred_); > return traits_type::to_int_type(*gptr()); > } > else > { > return traits_type::eof(); > } > } > > int_type overflow(int_type c) > { > if (unbuffered_) > { > if (traits_type::eq_int_type(c, traits_type::eof())) > { > > return traits_type::not_eof(c); > } > else > { > if (timer_state_ == timer_has_expired) > { > ec_ = boost::asio::error::operation_aborted; > return traits_type::eof(); > } > > > char_type ch = traits_type::to_char_type(c); > io_handler handler = { this }; > this->get_service().async_send(this->get_implementation(), > boost::asio::buffer(&ch, sizeof(char_type)), 0, handler); > > ec_ = boost::asio::error::would_block; > this->get_service().get_io_service().reset(); > do this->get_service().get_io_service().run_one(); > while (ec_ == boost::asio::error::would_block); > if (ec_) > return traits_type::eof(); > > return c; > } > } > else > { > > boost::asio::const_buffer buffer = > boost::asio::buffer(pbase(), pptr() - pbase()); > while (boost::asio::buffer_size(buffer) > 0) > { > if (timer_state_ == timer_has_expired) > { > ec_ = boost::asio::error::operation_aborted; > return traits_type::eof(); > } > > io_handler handler = { this }; > this->get_service().async_send(this->get_implementation(), > boost::asio::buffer(buffer), 0, handler); > > ec_ = boost::asio::error::would_block; > this->get_service().get_io_service().reset(); > do this->get_service().get_io_service().run_one(); > while (ec_ == boost::asio::error::would_block); > if (ec_) > return traits_type::eof(); > > buffer = buffer + bytes_transferred_; > } > setp(&put_buffer_[0], &put_buffer_[0] + put_buffer_.size()); > > > if (traits_type::eq_int_type(c, traits_type::eof())) > return traits_type::not_eof(c); > > > *pptr() = traits_type::to_char_type(c); > pbump(1); > return c; > } > } > > int sync() > { > return overflow(traits_type::eof()); > } > > std::streambuf* setbuf(char_type* s, std::streamsize n) > { > if (pptr() == pbase() && s == 0 && n == 0) > { > unbuffered_ = true; > setp(0, 0); > return this; > } > > return 0; > } > > > > > > > virtual const boost::system::error_code& error() const > { > return ec_; > } > >private: > void init_buffers() > { > setg(&get_buffer_[0], > &get_buffer_[0] + putback_max, > &get_buffer_[0] + putback_max); > if (unbuffered_) > setp(0, 0); > else > setp(&put_buffer_[0], &put_buffer_[0] + put_buffer_.size()); > } > > template <typename ResolverQuery> > void resolve_and_connect(const ResolverQuery& query) > { > typedef typename Protocol::resolver resolver_type; > typedef typename resolver_type::iterator iterator_type; > resolver_type resolver(detail::socket_streambuf_base::io_service_); > iterator_type i = resolver.resolve(query, ec_); > if (!ec_) > { > iterator_type end; > ec_ = boost::asio::error::host_not_found; > while (ec_ && i != end) > { > this->basic_socket<Protocol, StreamSocketService>::close(ec_); > > if (timer_state_ == timer_has_expired) > { > ec_ = boost::asio::error::operation_aborted; > return; > } > > io_handler handler = { this }; > this->basic_socket<Protocol, StreamSocketService>::async_connect( > *i, handler); > > ec_ = boost::asio::error::would_block; > this->get_service().get_io_service().reset(); > do this->get_service().get_io_service().run_one(); > while (ec_ == boost::asio::error::would_block); > > ++i; > } > } > } > > struct io_handler; > friend struct io_handler; > struct io_handler > { > basic_socket_streambuf* this_; > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred = 0) > { > this_->ec_ = ec; > this_->bytes_transferred_ = bytes_transferred; > } > }; > > struct timer_handler; > friend struct timer_handler; > struct timer_handler > { > basic_socket_streambuf* this_; > > void operator()(const boost::system::error_code&) > { > time_type now = traits_helper::now(); > > time_type expiry_time = this_->timer_service_->expires_at( > this_->timer_implementation_); > > if (traits_helper::less_than(now, expiry_time)) > { > this_->timer_state_ = timer_is_pending; > this_->timer_service_->async_wait(this_->timer_implementation_, *this); > } > else > { > this_->timer_state_ = timer_has_expired; > boost::system::error_code ec; > this_->basic_socket<Protocol, StreamSocketService>::close(ec); > } > } > }; > > void construct_timer() > { > if (timer_service_ == 0) > { > TimerService& timer_service = use_service<TimerService>( > detail::socket_streambuf_base::io_service_); > timer_service.construct(timer_implementation_); > timer_service_ = &timer_service; > } > } > > void destroy_timer() > { > if (timer_service_) > timer_service_->destroy(timer_implementation_); > } > > void start_timer() > { > if (timer_state_ != timer_is_pending) > { > timer_handler handler = { this }; > handler(boost::system::error_code()); > } > } > > enum { putback_max = 8 }; > enum { buffer_size = 512 }; > boost::asio::detail::array<char, buffer_size> get_buffer_; > boost::asio::detail::array<char, buffer_size> put_buffer_; > bool unbuffered_; > boost::system::error_code ec_; > std::size_t bytes_transferred_; > TimerService* timer_service_; > typename TimerService::implementation_type timer_implementation_; > enum state { no_timer, timer_is_pending, timer_has_expired } timer_state_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 562 "/usr/include/boost/asio/basic_socket_streambuf.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/basic_socket_iostream.hpp" 2 3 4 ># 78 "/usr/include/boost/asio/basic_socket_iostream.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 79 "/usr/include/boost/asio/basic_socket_iostream.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > > >template <typename Protocol, typename StreamSocketService, > typename Time, typename TimeTraits, typename TimerService> >class socket_iostream_base >{ >protected: > basic_socket_streambuf<Protocol, StreamSocketService, > Time, TimeTraits, TimerService> streambuf_; >}; > >} > > >template <typename Protocol, > typename StreamSocketService = stream_socket_service<Protocol>, > > > typename Time = boost::posix_time::ptime, > typename TimeTraits = boost::asio::time_traits<Time>, > typename TimerService = deadline_timer_service<Time, TimeTraits> > > > > > > >class basic_socket_iostream > : private detail::socket_iostream_base<Protocol, > StreamSocketService, Time, TimeTraits, TimerService>, > public std::basic_iostream<char> >{ >private: > > > > typedef TimeTraits traits_helper; > > > > >public: > > typedef typename Protocol::endpoint endpoint_type; ># 135 "/usr/include/boost/asio/basic_socket_iostream.hpp" 3 4 > typedef typename traits_helper::time_type time_type; > typedef typename traits_helper::duration_type duration_type; > > > > basic_socket_iostream() > : std::basic_iostream<char>( > &this->detail::socket_iostream_base< > Protocol, StreamSocketService, Time, > TimeTraits, TimerService>::streambuf_) > { > this->setf(std::ios_base::unitbuf); > } ># 159 "/usr/include/boost/asio/basic_socket_iostream.hpp" 3 4 > template <typename... T> > explicit basic_socket_iostream(T... x) > : std::basic_iostream<char>( > &this->detail::socket_iostream_base< > Protocol, StreamSocketService, Time, > TimeTraits, TimerService>::streambuf_) > { > this->setf(std::ios_base::unitbuf); > if (rdbuf()->connect(x...) == 0) > this->setstate(std::ios_base::failbit); > } ># 184 "/usr/include/boost/asio/basic_socket_iostream.hpp" 3 4 > template <typename... T> > void connect(T... x) > { > if (rdbuf()->connect(x...) == 0) > this->setstate(std::ios_base::failbit); > } > > > > > > void close() > { > if (rdbuf()->close() == 0) > this->setstate(std::ios_base::failbit); > } > > > basic_socket_streambuf<Protocol, StreamSocketService, > Time, TimeTraits, TimerService>* rdbuf() const > { > return const_cast<basic_socket_streambuf<Protocol, StreamSocketService, > Time, TimeTraits, TimerService>*>( > &this->detail::socket_iostream_base< > Protocol, StreamSocketService, Time, > TimeTraits, TimerService>::streambuf_); > } ># 224 "/usr/include/boost/asio/basic_socket_iostream.hpp" 3 4 > const boost::system::error_code& error() const > { > return rdbuf()->puberror(); > } > > > > > > time_type expires_at() const > { > return rdbuf()->expires_at(); > } ># 247 "/usr/include/boost/asio/basic_socket_iostream.hpp" 3 4 > void expires_at(const time_type& expiry_time) > { > rdbuf()->expires_at(expiry_time); > } > > > > > > duration_type expires_from_now() const > { > return rdbuf()->expires_from_now(); > } ># 270 "/usr/include/boost/asio/basic_socket_iostream.hpp" 3 4 > void expires_from_now(const duration_type& expiry_time) > { > rdbuf()->expires_from_now(expiry_time); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 280 "/usr/include/boost/asio/basic_socket_iostream.hpp" 2 3 4 ># 30 "/usr/include/boost/asio.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/basic_stream_socket.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/basic_stream_socket.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 44 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 >template <typename Protocol, > typename StreamSocketService = stream_socket_service<Protocol> > >class basic_stream_socket > : public basic_socket<Protocol, StreamSocketService> >{ >public: > > > typedef typename StreamSocketService::native_handle_type native_type; > > > typedef typename StreamSocketService::native_handle_type native_handle_type; > > > typedef Protocol protocol_type; > > > typedef typename Protocol::endpoint endpoint_type; ># 72 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > explicit basic_stream_socket(boost::asio::io_service& io_service) > : basic_socket<Protocol, StreamSocketService>(io_service) > { > } ># 89 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > basic_stream_socket(boost::asio::io_service& io_service, > const protocol_type& protocol) > : basic_socket<Protocol, StreamSocketService>(io_service, protocol) > { > } ># 110 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > basic_stream_socket(boost::asio::io_service& io_service, > const endpoint_type& endpoint) > : basic_socket<Protocol, StreamSocketService>(io_service, endpoint) > { > } ># 130 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > basic_stream_socket(boost::asio::io_service& io_service, > const protocol_type& protocol, const native_handle_type& native_socket) > : basic_socket<Protocol, StreamSocketService>( > io_service, protocol, native_socket) > { > } ># 148 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > basic_stream_socket(basic_stream_socket&& other) > : basic_socket<Protocol, StreamSocketService>( > static_cast<basic_stream_socket&&>(other)) > { > } ># 164 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > basic_stream_socket& operator=(basic_stream_socket&& other) > { > basic_socket<Protocol, StreamSocketService>::operator=( > static_cast<basic_stream_socket&&>(other)); > return *this; > } ># 182 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename Protocol1, typename StreamSocketService1> > basic_stream_socket( > basic_stream_socket<Protocol1, StreamSocketService1>&& other, > typename enable_if<is_convertible<Protocol1, Protocol>::value>::type* = 0) > : basic_socket<Protocol, StreamSocketService>( > static_cast<basic_stream_socket< Protocol1, StreamSocketService1>&&> > (other)) > { > } ># 202 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename Protocol1, typename StreamSocketService1> > typename enable_if<is_convertible<Protocol1, Protocol>::value, > basic_stream_socket>::type& operator=( > basic_stream_socket<Protocol1, StreamSocketService1>&& other) > { > basic_socket<Protocol, StreamSocketService>::operator=( > static_cast<basic_stream_socket< Protocol1, StreamSocketService1>&&> > (other)); > return *this; > } ># 239 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send( > this->get_implementation(), buffers, 0, ec); > boost::asio::detail::throw_error(ec, "send"); > return s; > } ># 276 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers, > socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send( > this->get_implementation(), buffers, flags, ec); > boost::asio::detail::throw_error(ec, "send"); > return s; > } ># 305 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t send(const ConstBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return this->get_service().send( > this->get_implementation(), buffers, flags, ec); > } ># 348 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send( > this->get_implementation(), buffers, 0, > static_cast<WriteHandler&&>(handler)); > } ># 400 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_send(const ConstBufferSequence& buffers, > socket_base::message_flags flags, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send( > this->get_implementation(), buffers, flags, > static_cast<WriteHandler&&>(handler)); > } ># 444 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive( > this->get_implementation(), buffers, 0, ec); > boost::asio::detail::throw_error(ec, "receive"); > return s; > } ># 484 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers, > socket_base::message_flags flags) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive( > this->get_implementation(), buffers, flags, ec); > boost::asio::detail::throw_error(ec, "receive"); > return s; > } ># 513 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t receive(const MutableBufferSequence& buffers, > socket_base::message_flags flags, boost::system::error_code& ec) > { > return this->get_service().receive( > this->get_implementation(), buffers, flags, ec); > } ># 558 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive(this->get_implementation(), > buffers, 0, static_cast<ReadHandler&&>(handler)); > } ># 611 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_receive(const MutableBufferSequence& buffers, > socket_base::message_flags flags, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive(this->get_implementation(), > buffers, flags, static_cast<ReadHandler&&>(handler)); > } ># 653 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().send( > this->get_implementation(), buffers, 0, ec); > boost::asio::detail::throw_error(ec, "write_some"); > return s; > } ># 679 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers, > boost::system::error_code& ec) > { > return this->get_service().send(this->get_implementation(), buffers, 0, ec); > } ># 721 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_write_some(const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_send(this->get_implementation(), > buffers, 0, static_cast<WriteHandler&&>(handler)); > } ># 763 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().receive( > this->get_implementation(), buffers, 0, ec); > boost::asio::detail::throw_error(ec, "read_some"); > return s; > } ># 790 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers, > boost::system::error_code& ec) > { > return this->get_service().receive( > this->get_implementation(), buffers, 0, ec); > } ># 834 "/usr/include/boost/asio/basic_stream_socket.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_read_some(const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_receive(this->get_implementation(), > buffers, 0, static_cast<ReadHandler&&>(handler)); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 853 "/usr/include/boost/asio/basic_stream_socket.hpp" 2 3 4 ># 32 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/basic_streambuf.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/basic_streambuf.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 24 "/usr/include/boost/asio/basic_streambuf.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/basic_streambuf_fwd.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/basic_streambuf_fwd.hpp" 3 4 >namespace boost { >namespace asio { > >template <typename Allocator = std::allocator<char> > >class basic_streambuf; > >} >} ># 28 "/usr/include/boost/asio/basic_streambuf.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 34 "/usr/include/boost/asio/basic_streambuf.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 109 "/usr/include/boost/asio/basic_streambuf.hpp" 3 4 >template <typename Allocator> > >class basic_streambuf > : public std::streambuf, > private noncopyable >{ >public: > > > > > > > > typedef boost::asio::const_buffers_1 const_buffers_type; > typedef boost::asio::mutable_buffers_1 mutable_buffers_type; > > > > > > > > explicit basic_streambuf( > std::size_t maximum_size = (std::numeric_limits<std::size_t>::max)(), > const Allocator& allocator = Allocator()) > : max_size_(maximum_size), > buffer_(allocator) > { > std::size_t pend = (std::min<std::size_t>)(max_size_, buffer_delta); > buffer_.resize((std::max<std::size_t>)(pend, 1)); > setg(&buffer_[0], &buffer_[0], &buffer_[0]); > setp(&buffer_[0], &buffer_[0] + pend); > } ># 159 "/usr/include/boost/asio/basic_streambuf.hpp" 3 4 > std::size_t size() const > { > return pptr() - gptr(); > } > > > > > > > std::size_t max_size() const > { > return max_size_; > } ># 183 "/usr/include/boost/asio/basic_streambuf.hpp" 3 4 > const_buffers_type data() const > { > return boost::asio::buffer(boost::asio::const_buffer(gptr(), > (pptr() - gptr()) * sizeof(char_type))); > } ># 205 "/usr/include/boost/asio/basic_streambuf.hpp" 3 4 > mutable_buffers_type prepare(std::size_t n) > { > reserve(n); > return boost::asio::buffer(boost::asio::mutable_buffer( > pptr(), n * sizeof(char_type))); > } ># 224 "/usr/include/boost/asio/basic_streambuf.hpp" 3 4 > void commit(std::size_t n) > { > if (pptr() + n > epptr()) > n = epptr() - pptr(); > pbump(static_cast<int>(n)); > setg(eback(), gptr(), pptr()); > } > > > > > > > > void consume(std::size_t n) > { > if (egptr() < pptr()) > setg(&buffer_[0], gptr(), pptr()); > if (gptr() + n > pptr()) > n = pptr() - gptr(); > gbump(static_cast<int>(n)); > } > >protected: > enum { buffer_delta = 128 }; > > > > > > int_type underflow() > { > if (gptr() < pptr()) > { > setg(&buffer_[0], gptr(), pptr()); > return traits_type::to_int_type(*gptr()); > } > else > { > return traits_type::eof(); > } > } ># 274 "/usr/include/boost/asio/basic_streambuf.hpp" 3 4 > int_type overflow(int_type c) > { > if (!traits_type::eq_int_type(c, traits_type::eof())) > { > if (pptr() == epptr()) > { > std::size_t buffer_size = pptr() - gptr(); > if (buffer_size < max_size_ && max_size_ - buffer_size < buffer_delta) > { > reserve(max_size_ - buffer_size); > } > else > { > reserve(buffer_delta); > } > } > > *pptr() = traits_type::to_char_type(c); > pbump(1); > return c; > } > > return traits_type::not_eof(c); > } > > void reserve(std::size_t n) > { > > std::size_t gnext = gptr() - &buffer_[0]; > std::size_t pnext = pptr() - &buffer_[0]; > std::size_t pend = epptr() - &buffer_[0]; > > > if (n <= pend - pnext) > { > return; > } > > > if (gnext > 0) > { > pnext -= gnext; > std::memmove(&buffer_[0], &buffer_[0] + gnext, pnext); > } > > > if (n > pend - pnext) > { > if (n <= max_size_ && pnext <= max_size_ - n) > { > pend = pnext + n; > buffer_.resize((std::max<std::size_t>)(pend, 1)); > } > else > { > std::length_error ex("boost::asio::streambuf too long"); > boost::asio::detail::throw_exception(ex); > } > } > > > setg(&buffer_[0], &buffer_[0], &buffer_[0] + pnext); > setp(&buffer_[0] + pnext, &buffer_[0] + pend); > } > >private: > std::size_t max_size_; > std::vector<char_type, Allocator> buffer_; > > > friend std::size_t read_size_helper( > basic_streambuf& sb, std::size_t max_size) > { > return std::min<std::size_t>( > std::max<std::size_t>(512, sb.buffer_.capacity() - sb.size()), > std::min<std::size_t>(max_size, sb.max_size() - sb.size())); > } >}; > > > >template <typename Allocator> >inline std::size_t read_size_helper( > basic_streambuf<Allocator>& sb, std::size_t max_size) >{ > return std::min<std::size_t>(512, > std::min<std::size_t>(max_size, sb.max_size() - sb.size())); >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 367 "/usr/include/boost/asio/basic_streambuf.hpp" 2 3 4 ># 33 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/basic_waitable_timer.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 ># 1 "/usr/include/boost/asio/wait_traits.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/wait_traits.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/wait_traits.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >template <typename Clock> >struct wait_traits >{ > > > > > static typename Clock::duration to_wait_duration( > const typename Clock::duration& d) > { > return d; > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 42 "/usr/include/boost/asio/wait_traits.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/basic_waitable_timer.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/waitable_timer_service.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/waitable_timer_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/chrono_time_traits.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/chrono_time_traits.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/chrono_time_traits.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > >template <typename Clock, typename WaitTraits> >struct chrono_time_traits >{ > > typedef Clock clock_type; > > > typedef typename clock_type::duration duration_type; > > > typedef typename clock_type::time_point time_type; > > > typedef typename duration_type::period period_type; > > > static time_type now() > { > return clock_type::now(); > } > > > static time_type add(const time_type& t, const duration_type& d) > { > const time_type epoch; > if (t >= epoch) > { > if ((time_type::max)() - t < d) > return (time_type::max)(); > } > else > { > if (-(t - (time_type::min)()) > d) > return (time_type::min)(); > } > > return t + d; > } > > > static duration_type subtract(const time_type& t1, const time_type& t2) > { > const time_type epoch; > if (t1 >= epoch) > { > if (t2 >= epoch) > { > return t1 - t2; > } > else if (t2 == (time_type::min)()) > { > return (duration_type::max)(); > } > else if ((time_type::max)() - t1 < epoch - t2) > { > return (duration_type::max)(); > } > else > { > return t1 - t2; > } > } > else > { > if (t2 < epoch) > { > return t1 - t2; > } > else if (t1 == (time_type::min)()) > { > return (duration_type::min)(); > } > else if ((time_type::max)() - t2 < epoch - t1) > { > return (duration_type::min)(); > } > else > { > return -(t2 - t1); > } > } > } > > > static bool less_than(const time_type& t1, const time_type& t2) > { > return t1 < t2; > } > > > > class posix_time_duration > { > public: > explicit posix_time_duration(const duration_type& d) > : d_(d) > { > } > > int64_t ticks() const > { > return d_.count(); > } > > int64_t total_seconds() const > { > return duration_cast<1, 1>(); > } > > int64_t total_milliseconds() const > { > return duration_cast<1, 1000>(); > } > > int64_t total_microseconds() const > { > return duration_cast<1, 1000000>(); > } > > private: > template <int64_t Num, int64_t Den> > int64_t duration_cast() const > { > const int64_t num = period_type::num * Den; > const int64_t den = period_type::den * Num; > > if (num == 1 && den == 1) > return ticks(); > else if (num != 1 && den == 1) > return ticks() * num; > else if (num == 1 && period_type::den != 1) > return ticks() / den; > else > return ticks() * num / den; > } > > duration_type d_; > }; > > > static posix_time_duration to_posix_duration(const duration_type& d) > { > return posix_time_duration(WaitTraits::to_wait_duration(d)); > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 178 "/usr/include/boost/asio/detail/chrono_time_traits.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/waitable_timer_service.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/waitable_timer_service.hpp" 2 3 4 > >namespace boost { >namespace asio { > > >template <typename Clock, > typename WaitTraits = boost::asio::wait_traits<Clock> > >class waitable_timer_service > > > > : public boost::asio::detail::service_base< > waitable_timer_service<Clock, WaitTraits> > > >{ >public: > > > > > > > typedef Clock clock_type; > > > typedef typename clock_type::duration duration; > > > typedef typename clock_type::time_point time_point; > > > typedef WaitTraits traits_type; > >private: > > typedef detail::deadline_timer_service< > detail::chrono_time_traits<Clock, WaitTraits> > service_impl_type; > >public: > > > > > typedef typename service_impl_type::implementation_type implementation_type; > > > > explicit waitable_timer_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base< > waitable_timer_service<Clock, WaitTraits> >(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > std::size_t cancel(implementation_type& impl, boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > std::size_t cancel_one(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel_one(impl, ec); > } > > > time_point expires_at(const implementation_type& impl) const > { > return service_impl_.expires_at(impl); > } > > > std::size_t expires_at(implementation_type& impl, > const time_point& expiry_time, boost::system::error_code& ec) > { > return service_impl_.expires_at(impl, expiry_time, ec); > } > > > duration expires_from_now(const implementation_type& impl) const > { > return service_impl_.expires_from_now(impl); > } > > > std::size_t expires_from_now(implementation_type& impl, > const duration& expiry_time, boost::system::error_code& ec) > { > return service_impl_.expires_from_now(impl, expiry_time, ec); > } > > > void wait(implementation_type& impl, boost::system::error_code& ec) > { > service_impl_.wait(impl, ec); > } > > > template <typename WaitHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WaitHandler, void (boost::system::error_code)>::type>::type > > async_wait(implementation_type& impl, > WaitHandler&& handler) > { > detail::async_result_init< > WaitHandler, void (boost::system::error_code)> init( > static_cast<WaitHandler&&>(handler)); > > service_impl_.async_wait(impl, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > service_impl_type service_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 169 "/usr/include/boost/asio/waitable_timer_service.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/basic_waitable_timer.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/basic_waitable_timer.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 124 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 >template <typename Clock, > typename WaitTraits = boost::asio::wait_traits<Clock>, > typename WaitableTimerService = waitable_timer_service<Clock, WaitTraits> > >class basic_waitable_timer > : public basic_io_object<WaitableTimerService> >{ >public: > > typedef Clock clock_type; > > > typedef typename clock_type::duration duration; > > > typedef typename clock_type::time_point time_point; > > > typedef WaitTraits traits_type; ># 152 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > explicit basic_waitable_timer(boost::asio::io_service& io_service) > : basic_io_object<WaitableTimerService>(io_service) > { > } ># 167 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > basic_waitable_timer(boost::asio::io_service& io_service, > const time_point& expiry_time) > : basic_io_object<WaitableTimerService>(io_service) > { > boost::system::error_code ec; > this->service.expires_at(this->implementation, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_at"); > } ># 186 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > basic_waitable_timer(boost::asio::io_service& io_service, > const duration& expiry_time) > : basic_io_object<WaitableTimerService>(io_service) > { > boost::system::error_code ec; > this->service.expires_from_now(this->implementation, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_from_now"); > } ># 217 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > std::size_t cancel() > { > boost::system::error_code ec; > std::size_t s = this->service.cancel(this->implementation, ec); > boost::asio::detail::throw_error(ec, "cancel"); > return s; > } ># 247 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > std::size_t cancel(boost::system::error_code& ec) > { > return this->service.cancel(this->implementation, ec); > } ># 276 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > std::size_t cancel_one() > { > boost::system::error_code ec; > std::size_t s = this->service.cancel_one(this->implementation, ec); > boost::asio::detail::throw_error(ec, "cancel_one"); > return s; > } ># 308 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > std::size_t cancel_one(boost::system::error_code& ec) > { > return this->service.cancel_one(this->implementation, ec); > } > > > > > > > time_point expires_at() const > { > return this->service.expires_at(this->implementation); > } ># 345 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > std::size_t expires_at(const time_point& expiry_time) > { > boost::system::error_code ec; > std::size_t s = this->service.expires_at( > this->implementation, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_at"); > return s; > } ># 376 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > std::size_t expires_at(const time_point& expiry_time, > boost::system::error_code& ec) > { > return this->service.expires_at(this->implementation, expiry_time, ec); > } > > > > > > > duration expires_from_now() const > { > return this->service.expires_from_now(this->implementation); > } ># 414 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > std::size_t expires_from_now(const duration& expiry_time) > { > boost::system::error_code ec; > std::size_t s = this->service.expires_from_now( > this->implementation, expiry_time, ec); > boost::asio::detail::throw_error(ec, "expires_from_now"); > return s; > } ># 445 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > std::size_t expires_from_now(const duration& expiry_time, > boost::system::error_code& ec) > { > return this->service.expires_from_now( > this->implementation, expiry_time, ec); > } ># 459 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > void wait() > { > boost::system::error_code ec; > this->service.wait(this->implementation, ec); > boost::asio::detail::throw_error(ec, "wait"); > } ># 473 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > void wait(boost::system::error_code& ec) > { > this->service.wait(this->implementation, ec); > } ># 502 "/usr/include/boost/asio/basic_waitable_timer.hpp" 3 4 > template <typename WaitHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WaitHandler, void (boost::system::error_code)>::type>::type > > async_wait(WaitHandler&& handler) > { > > > typedef typename handler_type<WaitHandler, void(boost::system::error_code)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::one_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0))) == 1, "WaitHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>()), char(0))> __attribute__((__unused__)) type_check; > > return this->service.async_wait(this->implementation, > static_cast<WaitHandler&&>(handler)); > } >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 520 "/usr/include/boost/asio/basic_waitable_timer.hpp" 2 3 4 ># 34 "/usr/include/boost/asio.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/buffered_read_stream_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/buffered_read_stream_fwd.hpp" 3 4 >namespace boost { >namespace asio { > >template <typename Stream> >class buffered_read_stream; > >} >} ># 36 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/buffered_read_stream.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/buffered_read_stream.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/buffer_resize_guard.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/buffer_resize_guard.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/buffer_resize_guard.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > >template <typename Buffer> >class buffer_resize_guard >{ >public: > > buffer_resize_guard(Buffer& buffer) > : buffer_(buffer), > old_size_(buffer.size()) > { > } > > > ~buffer_resize_guard() > { > if (old_size_ != (std::numeric_limits<size_t>::max)()) > { > buffer_.resize(old_size_); > } > } > > > void commit() > { > old_size_ = (std::numeric_limits<size_t>::max)(); > } > >private: > > Buffer& buffer_; > > > size_t old_size_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 67 "/usr/include/boost/asio/detail/buffer_resize_guard.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/buffered_read_stream.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/buffered_stream_storage.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/buffered_stream_storage.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 23 "/usr/include/boost/asio/detail/buffered_stream_storage.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/buffered_stream_storage.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class buffered_stream_storage >{ >public: > > typedef unsigned char byte_type; > > > typedef std::size_t size_type; > > > explicit buffered_stream_storage(std::size_t buffer_capacity) > : begin_offset_(0), > end_offset_(0), > buffer_(buffer_capacity) > { > } > > > void clear() > { > begin_offset_ = 0; > end_offset_ = 0; > } > > > mutable_buffer data() > { > return boost::asio::buffer(buffer_) + begin_offset_; > } > > > const_buffer data() const > { > return boost::asio::buffer(buffer_) + begin_offset_; > } > > > bool empty() const > { > return begin_offset_ == end_offset_; > } > > > size_type size() const > { > return end_offset_ - begin_offset_; > } > > > void resize(size_type length) > { > (static_cast<void> (0)); > if (begin_offset_ + length <= capacity()) > { > end_offset_ = begin_offset_ + length; > } > else > { > using namespace std; > memmove(&buffer_[0], &buffer_[0] + begin_offset_, size()); > end_offset_ = length; > begin_offset_ = 0; > } > } > > > size_type capacity() const > { > return buffer_.size(); > } > > > void consume(size_type count) > { > (static_cast<void> (0)); > begin_offset_ += count; > if (empty()) > clear(); > } > >private: > > size_type begin_offset_; > > > size_type end_offset_; > > > std::vector<byte_type> buffer_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 127 "/usr/include/boost/asio/detail/buffered_stream_storage.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/buffered_read_stream.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/buffered_read_stream.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 48 "/usr/include/boost/asio/buffered_read_stream.hpp" 3 4 >template <typename Stream> >class buffered_read_stream > : private noncopyable >{ >public: > > typedef typename remove_reference<Stream>::type next_layer_type; > > > typedef typename next_layer_type::lowest_layer_type lowest_layer_type; > > > > > > static const std::size_t default_buffer_size = 1024; > > > > template <typename Arg> > explicit buffered_read_stream(Arg& a) > : next_layer_(a), > storage_(default_buffer_size) > { > } > > > template <typename Arg> > buffered_read_stream(Arg& a, std::size_t buffer_size) > : next_layer_(a), > storage_(buffer_size) > { > } > > > next_layer_type& next_layer() > { > return next_layer_; > } > > > lowest_layer_type& lowest_layer() > { > return next_layer_.lowest_layer(); > } > > > const lowest_layer_type& lowest_layer() const > { > return next_layer_.lowest_layer(); > } > > > boost::asio::io_service& get_io_service() > { > return next_layer_.get_io_service(); > } > > > void close() > { > next_layer_.close(); > } > > > boost::system::error_code close(boost::system::error_code& ec) > { > return next_layer_.close(ec); > } > > > > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers) > { > return next_layer_.write_some(buffers); > } > > > > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers, > boost::system::error_code& ec) > { > return next_layer_.write_some(buffers, ec); > } > > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_write_some(const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > next_layer_.async_write_some(buffers, > static_cast<typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type&&> > (init.handler)); > > return init.result.get(); > } > > > > std::size_t fill(); > > > > std::size_t fill(boost::system::error_code& ec); > > > template <typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_fill(ReadHandler&& handler); > > > > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers); > > > > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers, > boost::system::error_code& ec); > > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_read_some(const MutableBufferSequence& buffers, > ReadHandler&& handler); > > > > template <typename MutableBufferSequence> > std::size_t peek(const MutableBufferSequence& buffers); > > > > template <typename MutableBufferSequence> > std::size_t peek(const MutableBufferSequence& buffers, > boost::system::error_code& ec); > > > std::size_t in_avail() > { > return storage_.size(); > } > > > std::size_t in_avail(boost::system::error_code& ec) > { > ec = boost::system::error_code(); > return storage_.size(); > } > >private: > > > template <typename MutableBufferSequence> > std::size_t copy(const MutableBufferSequence& buffers) > { > std::size_t bytes_copied = boost::asio::buffer_copy( > buffers, storage_.data(), storage_.size()); > storage_.consume(bytes_copied); > return bytes_copied; > } > > > > > template <typename MutableBufferSequence> > std::size_t peek_copy(const MutableBufferSequence& buffers) > { > return boost::asio::buffer_copy(buffers, storage_.data(), storage_.size()); > } > > > Stream next_layer_; > > > detail::buffered_stream_storage storage_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 243 "/usr/include/boost/asio/buffered_read_stream.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/buffered_read_stream.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/impl/buffered_read_stream.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/impl/buffered_read_stream.hpp" 2 3 4 > >namespace boost { >namespace asio { > >template <typename Stream> >std::size_t buffered_read_stream<Stream>::fill() >{ > detail::buffer_resize_guard<detail::buffered_stream_storage> > resize_guard(storage_); > std::size_t previous_size = storage_.size(); > storage_.resize(storage_.capacity()); > storage_.resize(previous_size + next_layer_.read_some(buffer( > storage_.data() + previous_size, > storage_.size() - previous_size))); > resize_guard.commit(); > return storage_.size() - previous_size; >} > >template <typename Stream> >std::size_t buffered_read_stream<Stream>::fill(boost::system::error_code& ec) >{ > detail::buffer_resize_guard<detail::buffered_stream_storage> > resize_guard(storage_); > std::size_t previous_size = storage_.size(); > storage_.resize(storage_.capacity()); > storage_.resize(previous_size + next_layer_.read_some(buffer( > storage_.data() + previous_size, > storage_.size() - previous_size), > ec)); > resize_guard.commit(); > return storage_.size() - previous_size; >} > >namespace detail >{ > template <typename ReadHandler> > class buffered_fill_handler > { > public: > buffered_fill_handler(detail::buffered_stream_storage& storage, > std::size_t previous_size, ReadHandler& handler) > : storage_(storage), > previous_size_(previous_size), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > buffered_fill_handler(const buffered_fill_handler& other) > : storage_(other.storage_), > previous_size_(other.previous_size_), > handler_(other.handler_) > { > } > > buffered_fill_handler(buffered_fill_handler&& other) > : storage_(other.storage_), > previous_size_(other.previous_size_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > const std::size_t bytes_transferred) > { > storage_.resize(previous_size_ + bytes_transferred); > handler_(ec, bytes_transferred); > } > > > detail::buffered_stream_storage& storage_; > std::size_t previous_size_; > ReadHandler handler_; > }; > > template <typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > buffered_fill_handler<ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > buffered_fill_handler<ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename ReadHandler> > inline bool asio_handler_is_continuation( > buffered_fill_handler<ReadHandler>* this_handler) > { > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename ReadHandler> > inline void asio_handler_invoke(Function& function, > buffered_fill_handler<ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > buffered_fill_handler<ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename Stream> >template <typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >buffered_read_stream<Stream>::async_fill( > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > std::size_t previous_size = storage_.size(); > storage_.resize(storage_.capacity()); > next_layer_.async_read_some( > buffer( > storage_.data() + previous_size, > storage_.size() - previous_size), > detail::buffered_fill_handler<typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > storage_, previous_size, init.handler)); > > return init.result.get(); >} > >template <typename Stream> >template <typename MutableBufferSequence> >std::size_t buffered_read_stream<Stream>::read_some( > const MutableBufferSequence& buffers) >{ > if (boost::asio::buffer_size(buffers) == 0) > return 0; > > if (storage_.empty()) > this->fill(); > > return this->copy(buffers); >} > >template <typename Stream> >template <typename MutableBufferSequence> >std::size_t buffered_read_stream<Stream>::read_some( > const MutableBufferSequence& buffers, boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > > if (boost::asio::buffer_size(buffers) == 0) > return 0; > > if (storage_.empty() && !this->fill(ec)) > return 0; > > return this->copy(buffers); >} > >namespace detail >{ > template <typename MutableBufferSequence, typename ReadHandler> > class buffered_read_some_handler > { > public: > buffered_read_some_handler(detail::buffered_stream_storage& storage, > const MutableBufferSequence& buffers, ReadHandler& handler) > : storage_(storage), > buffers_(buffers), > handler_(handler) > { > } > > > buffered_read_some_handler(const buffered_read_some_handler& other) > : storage_(other.storage_), > buffers_(other.buffers_), > handler_(other.handler_) > { > } > > buffered_read_some_handler(buffered_read_some_handler&& other) > : storage_(other.storage_), > buffers_(other.buffers_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, std::size_t) > { > if (ec || storage_.empty()) > { > const std::size_t length = 0; > handler_(ec, length); > } > else > { > const std::size_t bytes_copied = boost::asio::buffer_copy( > buffers_, storage_.data(), storage_.size()); > storage_.consume(bytes_copied); > handler_(ec, bytes_copied); > } > } > > > detail::buffered_stream_storage& storage_; > MutableBufferSequence buffers_; > ReadHandler handler_; > }; > > template <typename MutableBufferSequence, typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > buffered_read_some_handler< > MutableBufferSequence, ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename MutableBufferSequence, typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > buffered_read_some_handler< > MutableBufferSequence, ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename MutableBufferSequence, typename ReadHandler> > inline bool asio_handler_is_continuation( > buffered_read_some_handler< > MutableBufferSequence, ReadHandler>* this_handler) > { > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename MutableBufferSequence, > typename ReadHandler> > inline void asio_handler_invoke(Function& function, > buffered_read_some_handler< > MutableBufferSequence, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename MutableBufferSequence, > typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > buffered_read_some_handler< > MutableBufferSequence, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename Stream> >template <typename MutableBufferSequence, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >buffered_read_stream<Stream>::async_read_some( > const MutableBufferSequence& buffers, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > if (boost::asio::buffer_size(buffers) == 0 || !storage_.empty()) > { > next_layer_.async_read_some(boost::asio::mutable_buffers_1(0, 0), > detail::buffered_read_some_handler< > MutableBufferSequence, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > storage_, buffers, init.handler)); > } > else > { > this->async_fill(detail::buffered_read_some_handler< > MutableBufferSequence, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > storage_, buffers, init.handler)); > } > > return init.result.get(); >} > >template <typename Stream> >template <typename MutableBufferSequence> >std::size_t buffered_read_stream<Stream>::peek( > const MutableBufferSequence& buffers) >{ > if (storage_.empty()) > this->fill(); > return this->peek_copy(buffers); >} > >template <typename Stream> >template <typename MutableBufferSequence> >std::size_t buffered_read_stream<Stream>::peek( > const MutableBufferSequence& buffers, boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > if (storage_.empty() && !this->fill(ec)) > return 0; > return this->peek_copy(buffers); >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 359 "/usr/include/boost/asio/impl/buffered_read_stream.hpp" 2 3 4 ># 245 "/usr/include/boost/asio/buffered_read_stream.hpp" 2 3 4 ># 37 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/buffered_stream_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/buffered_stream_fwd.hpp" 3 4 >namespace boost { >namespace asio { > >template <typename Stream> >class buffered_stream; > >} >} ># 38 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/buffered_stream.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/buffered_stream.hpp" 3 4 ># 1 "/usr/include/boost/asio/buffered_write_stream.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/buffered_write_stream.hpp" 3 4 ># 1 "/usr/include/boost/asio/buffered_write_stream_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/asio/buffered_write_stream_fwd.hpp" 3 4 >namespace boost { >namespace asio { > >template <typename Stream> >class buffered_write_stream; > >} >} ># 21 "/usr/include/boost/asio/buffered_write_stream.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/completion_condition.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/completion_condition.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/completion_condition.hpp" 2 3 4 > >namespace boost { >namespace asio { > >namespace detail { > > >enum { default_max_transfer_size = 65536 }; > > > >inline std::size_t adapt_completion_condition_result(bool result) >{ > return result ? 0 : default_max_transfer_size; >} > > > > >inline std::size_t adapt_completion_condition_result(std::size_t result) >{ > return result; >} > >class transfer_all_t >{ >public: > typedef std::size_t result_type; > > template <typename Error> > std::size_t operator()(const Error& err, std::size_t) > { > return !!err ? 0 : default_max_transfer_size; > } >}; > >class transfer_at_least_t >{ >public: > typedef std::size_t result_type; > > explicit transfer_at_least_t(std::size_t minimum) > : minimum_(minimum) > { > } > > template <typename Error> > std::size_t operator()(const Error& err, std::size_t bytes_transferred) > { > return (!!err || bytes_transferred >= minimum_) > ? 0 : default_max_transfer_size; > } > >private: > std::size_t minimum_; >}; > >class transfer_exactly_t >{ >public: > typedef std::size_t result_type; > > explicit transfer_exactly_t(std::size_t size) > : size_(size) > { > } > > template <typename Error> > std::size_t operator()(const Error& err, std::size_t bytes_transferred) > { > return (!!err || bytes_transferred >= size_) ? 0 : > (size_ - bytes_transferred < default_max_transfer_size > ? size_ - bytes_transferred : std::size_t(default_max_transfer_size)); > } > >private: > std::size_t size_; >}; > >} ># 139 "/usr/include/boost/asio/completion_condition.hpp" 3 4 >inline detail::transfer_all_t transfer_all() >{ > return detail::transfer_all_t(); >} ># 173 "/usr/include/boost/asio/completion_condition.hpp" 3 4 >inline detail::transfer_at_least_t transfer_at_least(std::size_t minimum) >{ > return detail::transfer_at_least_t(minimum); >} ># 207 "/usr/include/boost/asio/completion_condition.hpp" 3 4 >inline detail::transfer_exactly_t transfer_exactly(std::size_t size) >{ > return detail::transfer_exactly_t(size); >} > > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 219 "/usr/include/boost/asio/completion_condition.hpp" 2 3 4 ># 23 "/usr/include/boost/asio/buffered_write_stream.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/write.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/write.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/write.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 72 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename SyncWriteStream, typename ConstBufferSequence> >std::size_t write(SyncWriteStream& s, const ConstBufferSequence& buffers); ># 111 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename SyncWriteStream, typename ConstBufferSequence> >std::size_t write(SyncWriteStream& s, const ConstBufferSequence& buffers, > boost::system::error_code& ec); ># 161 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename SyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition> >std::size_t write(SyncWriteStream& s, const ConstBufferSequence& buffers, > CompletionCondition completion_condition); ># 205 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename SyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition> >std::size_t write(SyncWriteStream& s, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, boost::system::error_code& ec); ># 238 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename SyncWriteStream, typename Allocator> >std::size_t write(SyncWriteStream& s, basic_streambuf<Allocator>& b); ># 267 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename SyncWriteStream, typename Allocator> >std::size_t write(SyncWriteStream& s, basic_streambuf<Allocator>& b, > boost::system::error_code& ec); ># 306 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename SyncWriteStream, typename Allocator, > typename CompletionCondition> >std::size_t write(SyncWriteStream& s, basic_streambuf<Allocator>& b, > CompletionCondition completion_condition); ># 347 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename SyncWriteStream, typename Allocator, > typename CompletionCondition> >std::size_t write(SyncWriteStream& s, basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, boost::system::error_code& ec); ># 415 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename AsyncWriteStream, typename ConstBufferSequence, > typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write(AsyncWriteStream& s, const ConstBufferSequence& buffers, > WriteHandler&& handler); ># 489 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename AsyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write(AsyncWriteStream& s, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, > WriteHandler&& handler); ># 540 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename AsyncWriteStream, typename Allocator, typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write(AsyncWriteStream& s, basic_streambuf<Allocator>& b, > WriteHandler&& handler); ># 601 "/usr/include/boost/asio/write.hpp" 3 4 >template <typename AsyncWriteStream, typename Allocator, > typename CompletionCondition, typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write(AsyncWriteStream& s, basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, > WriteHandler&& handler); > > > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 617 "/usr/include/boost/asio/write.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/write.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/impl/write.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/base_from_completion_cond.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/base_from_completion_cond.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/base_from_completion_cond.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename CompletionCondition> >class base_from_completion_cond >{ >protected: > explicit base_from_completion_cond(CompletionCondition completion_condition) > : completion_condition_(completion_condition) > { > } > > std::size_t check_for_completion( > const boost::system::error_code& ec, > std::size_t total_transferred) > { > return detail::adapt_completion_condition_result( > completion_condition_(ec, total_transferred)); > } > >private: > CompletionCondition completion_condition_; >}; > >template <> >class base_from_completion_cond<transfer_all_t> >{ >protected: > explicit base_from_completion_cond(transfer_all_t) > { > } > > static std::size_t check_for_completion( > const boost::system::error_code& ec, > std::size_t total_transferred) > { > return transfer_all_t()(ec, total_transferred); > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 69 "/usr/include/boost/asio/detail/base_from_completion_cond.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/impl/write.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/consuming_buffers.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/detail/consuming_buffers.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/consuming_buffers.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > >template <typename Buffer, typename Buffer_Iterator> >class consuming_buffers_iterator >{ >public: > > typedef std::ptrdiff_t difference_type; > > > typedef Buffer value_type; > > > typedef const Buffer* pointer; > > > typedef const Buffer& reference; > > > typedef std::forward_iterator_tag iterator_category; > > > consuming_buffers_iterator() > : at_end_(true) > { > } > > > > consuming_buffers_iterator(bool at_end, const Buffer& first, > Buffer_Iterator begin_remainder, Buffer_Iterator end_remainder, > std::size_t max_size) > : at_end_(max_size > 0 ? at_end : true), > first_(buffer(first, max_size)), > begin_remainder_(begin_remainder), > end_remainder_(end_remainder), > offset_(0), > max_size_(max_size) > { > } > > > const Buffer& operator*() const > { > return dereference(); > } > > > const Buffer* operator->() const > { > return &dereference(); > } > > > consuming_buffers_iterator& operator++() > { > increment(); > return *this; > } > > > consuming_buffers_iterator operator++(int) > { > consuming_buffers_iterator tmp(*this); > ++*this; > return tmp; > } > > > friend bool operator==(const consuming_buffers_iterator& a, > const consuming_buffers_iterator& b) > { > return a.equal(b); > } > > > friend bool operator!=(const consuming_buffers_iterator& a, > const consuming_buffers_iterator& b) > { > return !a.equal(b); > } > >private: > void increment() > { > if (!at_end_) > { > if (begin_remainder_ == end_remainder_ > || offset_ + buffer_size(first_) >= max_size_) > { > at_end_ = true; > } > else > { > offset_ += buffer_size(first_); > first_ = buffer(*begin_remainder_++, max_size_ - offset_); > } > } > } > > bool equal(const consuming_buffers_iterator& other) const > { > if (at_end_ && other.at_end_) > return true; > return !at_end_ && !other.at_end_ > && buffer_cast<const void*>(first_) > == buffer_cast<const void*>(other.first_) > && buffer_size(first_) == buffer_size(other.first_) > && begin_remainder_ == other.begin_remainder_ > && end_remainder_ == other.end_remainder_; > } > > const Buffer& dereference() const > { > return first_; > } > > bool at_end_; > Buffer first_; > Buffer_Iterator begin_remainder_; > Buffer_Iterator end_remainder_; > std::size_t offset_; > std::size_t max_size_; >}; > > >template <typename Buffer, typename Buffers> >class consuming_buffers >{ >public: > > typedef Buffer value_type; > > > typedef consuming_buffers_iterator<Buffer, typename Buffers::const_iterator> > const_iterator; > > > consuming_buffers(const Buffers& buffers) > : buffers_(buffers), > at_end_(buffers_.begin() == buffers_.end()), > begin_remainder_(buffers_.begin()), > max_size_((std::numeric_limits<std::size_t>::max)()) > { > if (!at_end_) > { > first_ = *buffers_.begin(); > ++begin_remainder_; > } > } > > > consuming_buffers(const consuming_buffers& other) > : buffers_(other.buffers_), > at_end_(other.at_end_), > first_(other.first_), > begin_remainder_(buffers_.begin()), > max_size_(other.max_size_) > { > typename Buffers::const_iterator first = other.buffers_.begin(); > typename Buffers::const_iterator second = other.begin_remainder_; > std::advance(begin_remainder_, std::distance(first, second)); > } > > > consuming_buffers& operator=(const consuming_buffers& other) > { > buffers_ = other.buffers_; > at_end_ = other.at_end_; > first_ = other.first_; > begin_remainder_ = buffers_.begin(); > typename Buffers::const_iterator first = other.buffers_.begin(); > typename Buffers::const_iterator second = other.begin_remainder_; > std::advance(begin_remainder_, std::distance(first, second)); > max_size_ = other.max_size_; > return *this; > } > > > const_iterator begin() const > { > return const_iterator(at_end_, first_, > begin_remainder_, buffers_.end(), max_size_); > } > > > const_iterator end() const > { > return const_iterator(); > } > > > void prepare(std::size_t max_size) > { > max_size_ = max_size; > } > > > void consume(std::size_t size) > { > > while (size > 0 && !at_end_) > { > if (buffer_size(first_) <= size) > { > size -= buffer_size(first_); > if (begin_remainder_ == buffers_.end()) > at_end_ = true; > else > first_ = *begin_remainder_++; > } > else > { > first_ = first_ + size; > size = 0; > } > } > > > while (!at_end_ && buffer_size(first_) == 0) > { > if (begin_remainder_ == buffers_.end()) > at_end_ = true; > else > first_ = *begin_remainder_++; > } > } > >private: > Buffers buffers_; > bool at_end_; > Buffer first_; > typename Buffers::const_iterator begin_remainder_; > std::size_t max_size_; >}; > > > >template <typename Buffer> >class consuming_buffers<Buffer, boost::asio::null_buffers> > : public boost::asio::null_buffers >{ >public: > consuming_buffers(const boost::asio::null_buffers&) > { > > } > > void prepare(std::size_t) > { > > } > > void consume(std::size_t) > { > > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 293 "/usr/include/boost/asio/detail/consuming_buffers.hpp" 2 3 4 ># 24 "/usr/include/boost/asio/impl/write.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/dependent_type.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/dependent_type.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/dependent_type.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename DependsOn, typename T> >struct dependent_type >{ > typedef T type; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 37 "/usr/include/boost/asio/detail/dependent_type.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/impl/write.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/impl/write.hpp" 2 3 4 > >namespace boost { >namespace asio { > >template <typename SyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition> >std::size_t write(SyncWriteStream& s, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > boost::asio::detail::consuming_buffers< > const_buffer, ConstBufferSequence> tmp(buffers); > std::size_t total_transferred = 0; > tmp.prepare(detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred))); > while (tmp.begin() != tmp.end()) > { > std::size_t bytes_transferred = s.write_some(tmp, ec); > tmp.consume(bytes_transferred); > total_transferred += bytes_transferred; > tmp.prepare(detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred))); > } > return total_transferred; >} > >template <typename SyncWriteStream, typename ConstBufferSequence> >inline std::size_t write(SyncWriteStream& s, const ConstBufferSequence& buffers) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = write(s, buffers, transfer_all(), ec); > boost::asio::detail::throw_error(ec, "write"); > return bytes_transferred; >} > >template <typename SyncWriteStream, typename ConstBufferSequence> >inline std::size_t write(SyncWriteStream& s, const ConstBufferSequence& buffers, > boost::system::error_code& ec) >{ > return write(s, buffers, transfer_all(), ec); >} > >template <typename SyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition> >inline std::size_t write(SyncWriteStream& s, const ConstBufferSequence& buffers, > CompletionCondition completion_condition) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = write(s, buffers, completion_condition, ec); > boost::asio::detail::throw_error(ec, "write"); > return bytes_transferred; >} > > > >template <typename SyncWriteStream, typename Allocator, > typename CompletionCondition> >std::size_t write(SyncWriteStream& s, > boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, boost::system::error_code& ec) >{ > std::size_t bytes_transferred = write(s, b.data(), completion_condition, ec); > b.consume(bytes_transferred); > return bytes_transferred; >} > >template <typename SyncWriteStream, typename Allocator> >inline std::size_t write(SyncWriteStream& s, > boost::asio::basic_streambuf<Allocator>& b) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = write(s, b, transfer_all(), ec); > boost::asio::detail::throw_error(ec, "write"); > return bytes_transferred; >} > >template <typename SyncWriteStream, typename Allocator> >inline std::size_t write(SyncWriteStream& s, > boost::asio::basic_streambuf<Allocator>& b, > boost::system::error_code& ec) >{ > return write(s, b, transfer_all(), ec); >} > >template <typename SyncWriteStream, typename Allocator, > typename CompletionCondition> >inline std::size_t write(SyncWriteStream& s, > boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = write(s, b, completion_condition, ec); > boost::asio::detail::throw_error(ec, "write"); > return bytes_transferred; >} > > > >namespace detail >{ > template <typename AsyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> > class write_op > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_op(AsyncWriteStream& stream, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_op(const write_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_op(write_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > switch (start_ = start) > { > case 1: > buffers_.prepare(this->check_for_completion(ec, total_transferred_)); > for (;;) > { > stream_.async_write_some(buffers_, > static_cast<write_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > buffers_.consume(bytes_transferred); > buffers_.prepare(this->check_for_completion(ec, total_transferred_)); > if ((!ec && bytes_transferred == 0) > || buffers_.begin() == buffers_.end()) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncWriteStream& stream_; > boost::asio::detail::consuming_buffers< > const_buffer, ConstBufferSequence> buffers_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > template <typename AsyncWriteStream, > typename CompletionCondition, typename WriteHandler> > class write_op<AsyncWriteStream, boost::asio::mutable_buffers_1, > CompletionCondition, WriteHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_op(AsyncWriteStream& stream, > const boost::asio::mutable_buffers_1& buffers, > CompletionCondition completion_condition, > WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > buffer_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_op(const write_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_op(write_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > stream_.async_write_some( > boost::asio::buffer(buffer_ + total_transferred_, n), > static_cast<write_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == boost::asio::buffer_size(buffer_)) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncWriteStream& stream_; > boost::asio::mutable_buffer buffer_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > template <typename AsyncWriteStream, > typename CompletionCondition, typename WriteHandler> > class write_op<AsyncWriteStream, boost::asio::const_buffers_1, > CompletionCondition, WriteHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_op(AsyncWriteStream& stream, > const boost::asio::const_buffers_1& buffers, > CompletionCondition completion_condition, > WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > buffer_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_op(const write_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_op(write_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > stream_.async_write_some( > boost::asio::buffer(buffer_ + total_transferred_, n), > static_cast<write_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == boost::asio::buffer_size(buffer_)) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncWriteStream& stream_; > boost::asio::const_buffer buffer_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > template <typename AsyncWriteStream, typename Elem, > typename CompletionCondition, typename WriteHandler> > class write_op<AsyncWriteStream, boost::array<Elem, 2>, > CompletionCondition, WriteHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_op(AsyncWriteStream& stream, const boost::array<Elem, 2>& buffers, > CompletionCondition completion_condition, WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_op(const write_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_op(write_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > typename boost::asio::detail::dependent_type<Elem, > boost::array<boost::asio::const_buffer, 2> >::type bufs = {{ > boost::asio::const_buffer(buffers_[0]), > boost::asio::const_buffer(buffers_[1]) }}; > std::size_t buffer_size0 = boost::asio::buffer_size(bufs[0]); > std::size_t buffer_size1 = boost::asio::buffer_size(bufs[1]); > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > bufs[0] = boost::asio::buffer(bufs[0] + total_transferred_, n); > bufs[1] = boost::asio::buffer( > bufs[1] + (total_transferred_ < buffer_size0 > ? 0 : total_transferred_ - buffer_size0), > n - boost::asio::buffer_size(bufs[0])); > stream_.async_write_some(bufs, static_cast<write_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == buffer_size0 + buffer_size1) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncWriteStream& stream_; > boost::array<Elem, 2> buffers_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > > > template <typename AsyncWriteStream, typename Elem, > typename CompletionCondition, typename WriteHandler> > class write_op<AsyncWriteStream, std::array<Elem, 2>, > CompletionCondition, WriteHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_op(AsyncWriteStream& stream, const std::array<Elem, 2>& buffers, > CompletionCondition completion_condition, WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_op(const write_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_op(write_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > typename boost::asio::detail::dependent_type<Elem, > std::array<boost::asio::const_buffer, 2> >::type bufs = {{ > boost::asio::const_buffer(buffers_[0]), > boost::asio::const_buffer(buffers_[1]) }}; > std::size_t buffer_size0 = boost::asio::buffer_size(bufs[0]); > std::size_t buffer_size1 = boost::asio::buffer_size(bufs[1]); > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > bufs[0] = boost::asio::buffer(bufs[0] + total_transferred_, n); > bufs[1] = boost::asio::buffer( > bufs[1] + (total_transferred_ < buffer_size0 > ? 0 : total_transferred_ - buffer_size0), > n - boost::asio::buffer_size(bufs[0])); > stream_.async_write_some(bufs, static_cast<write_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == buffer_size0 + buffer_size1) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncWriteStream& stream_; > std::array<Elem, 2> buffers_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > > > template <typename AsyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> > inline void* asio_handler_allocate(std::size_t size, > write_op<AsyncWriteStream, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > write_op<AsyncWriteStream, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> > inline bool asio_handler_is_continuation( > write_op<AsyncWriteStream, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncWriteStream, > typename ConstBufferSequence, typename CompletionCondition, > typename WriteHandler> > inline void asio_handler_invoke(Function& function, > write_op<AsyncWriteStream, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncWriteStream, > typename ConstBufferSequence, typename CompletionCondition, > typename WriteHandler> > inline void asio_handler_invoke(const Function& function, > write_op<AsyncWriteStream, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename AsyncWriteStream, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write(AsyncWriteStream& s, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > detail::write_op<AsyncWriteStream, ConstBufferSequence, > CompletionCondition, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, buffers, completion_condition, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > >template <typename AsyncWriteStream, typename ConstBufferSequence, > typename WriteHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write(AsyncWriteStream& s, const ConstBufferSequence& buffers, > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > detail::write_op<AsyncWriteStream, ConstBufferSequence, > detail::transfer_all_t, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, buffers, transfer_all(), init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > > > >namespace detail >{ > template <typename Allocator, typename WriteHandler> > class write_streambuf_handler > { > public: > write_streambuf_handler(boost::asio::basic_streambuf<Allocator>& streambuf, > WriteHandler& handler) > : streambuf_(streambuf), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_streambuf_handler(const write_streambuf_handler& other) > : streambuf_(other.streambuf_), > handler_(other.handler_) > { > } > > write_streambuf_handler(write_streambuf_handler&& other) > : streambuf_(other.streambuf_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > const std::size_t bytes_transferred) > { > streambuf_.consume(bytes_transferred); > handler_(ec, bytes_transferred); > } > > > boost::asio::basic_streambuf<Allocator>& streambuf_; > WriteHandler handler_; > }; > > template <typename Allocator, typename WriteHandler> > inline void* asio_handler_allocate(std::size_t size, > write_streambuf_handler<Allocator, WriteHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename Allocator, typename WriteHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > write_streambuf_handler<Allocator, WriteHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename Allocator, typename WriteHandler> > inline bool asio_handler_is_continuation( > write_streambuf_handler<Allocator, WriteHandler>* this_handler) > { > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename Allocator, typename WriteHandler> > inline void asio_handler_invoke(Function& function, > write_streambuf_handler<Allocator, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename Allocator, typename WriteHandler> > inline void asio_handler_invoke(const Function& function, > write_streambuf_handler<Allocator, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename AsyncWriteStream, typename Allocator, > typename CompletionCondition, typename WriteHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write(AsyncWriteStream& s, > boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > async_write(s, b.data(), completion_condition, > detail::write_streambuf_handler<Allocator, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > b, init.handler)); > > return init.result.get(); >} > >template <typename AsyncWriteStream, typename Allocator, typename WriteHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write(AsyncWriteStream& s, > boost::asio::basic_streambuf<Allocator>& b, > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > async_write(s, b.data(), transfer_all(), > detail::write_streambuf_handler<Allocator, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > b, init.handler)); > > return init.result.get(); >} > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 766 "/usr/include/boost/asio/impl/write.hpp" 2 3 4 ># 619 "/usr/include/boost/asio/write.hpp" 2 3 4 ># 30 "/usr/include/boost/asio/buffered_write_stream.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/buffered_write_stream.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 48 "/usr/include/boost/asio/buffered_write_stream.hpp" 3 4 >template <typename Stream> >class buffered_write_stream > : private noncopyable >{ >public: > > typedef typename remove_reference<Stream>::type next_layer_type; > > > typedef typename next_layer_type::lowest_layer_type lowest_layer_type; > > > > > > static const std::size_t default_buffer_size = 1024; > > > > template <typename Arg> > explicit buffered_write_stream(Arg& a) > : next_layer_(a), > storage_(default_buffer_size) > { > } > > > template <typename Arg> > buffered_write_stream(Arg& a, std::size_t buffer_size) > : next_layer_(a), > storage_(buffer_size) > { > } > > > next_layer_type& next_layer() > { > return next_layer_; > } > > > lowest_layer_type& lowest_layer() > { > return next_layer_.lowest_layer(); > } > > > const lowest_layer_type& lowest_layer() const > { > return next_layer_.lowest_layer(); > } > > > boost::asio::io_service& get_io_service() > { > return next_layer_.get_io_service(); > } > > > void close() > { > next_layer_.close(); > } > > > boost::system::error_code close(boost::system::error_code& ec) > { > return next_layer_.close(ec); > } > > > > > std::size_t flush(); > > > > > std::size_t flush(boost::system::error_code& ec); > > > template <typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_flush(WriteHandler&& handler); > > > > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers); > > > > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers, > boost::system::error_code& ec); > > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_write_some(const ConstBufferSequence& buffers, > WriteHandler&& handler); > > > > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers) > { > return next_layer_.read_some(buffers); > } > > > > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers, > boost::system::error_code& ec) > { > return next_layer_.read_some(buffers, ec); > } > > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_read_some(const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > next_layer_.async_read_some(buffers, > static_cast<typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type&&> > (init.handler)); > > return init.result.get(); > } > > > > template <typename MutableBufferSequence> > std::size_t peek(const MutableBufferSequence& buffers) > { > return next_layer_.peek(buffers); > } > > > > template <typename MutableBufferSequence> > std::size_t peek(const MutableBufferSequence& buffers, > boost::system::error_code& ec) > { > return next_layer_.peek(buffers, ec); > } > > > std::size_t in_avail() > { > return next_layer_.in_avail(); > } > > > std::size_t in_avail(boost::system::error_code& ec) > { > return next_layer_.in_avail(ec); > } > >private: > > > template <typename ConstBufferSequence> > std::size_t copy(const ConstBufferSequence& buffers); > > > Stream next_layer_; > > > detail::buffered_stream_storage storage_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 235 "/usr/include/boost/asio/buffered_write_stream.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/buffered_write_stream.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/impl/buffered_write_stream.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/impl/buffered_write_stream.hpp" 2 3 4 > >namespace boost { >namespace asio { > >template <typename Stream> >std::size_t buffered_write_stream<Stream>::flush() >{ > std::size_t bytes_written = write(next_layer_, > buffer(storage_.data(), storage_.size())); > storage_.consume(bytes_written); > return bytes_written; >} > >template <typename Stream> >std::size_t buffered_write_stream<Stream>::flush(boost::system::error_code& ec) >{ > std::size_t bytes_written = write(next_layer_, > buffer(storage_.data(), storage_.size()), > transfer_all(), ec); > storage_.consume(bytes_written); > return bytes_written; >} > >namespace detail >{ > template <typename WriteHandler> > class buffered_flush_handler > { > public: > buffered_flush_handler(detail::buffered_stream_storage& storage, > WriteHandler& handler) > : storage_(storage), > handler_(handler) > { > } > > > buffered_flush_handler(const buffered_flush_handler& other) > : storage_(other.storage_), > handler_(other.handler_) > { > } > > buffered_flush_handler(buffered_flush_handler&& other) > : storage_(other.storage_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > const std::size_t bytes_written) > { > storage_.consume(bytes_written); > handler_(ec, bytes_written); > } > > > detail::buffered_stream_storage& storage_; > WriteHandler handler_; > }; > > template <typename WriteHandler> > inline void* asio_handler_allocate(std::size_t size, > buffered_flush_handler<WriteHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename WriteHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > buffered_flush_handler<WriteHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename WriteHandler> > inline bool asio_handler_is_continuation( > buffered_flush_handler<WriteHandler>* this_handler) > { > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename WriteHandler> > inline void asio_handler_invoke(Function& function, > buffered_flush_handler<WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename WriteHandler> > inline void asio_handler_invoke(const Function& function, > buffered_flush_handler<WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename Stream> >template <typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >buffered_write_stream<Stream>::async_flush( > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > async_write(next_layer_, buffer(storage_.data(), storage_.size()), > detail::buffered_flush_handler<typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > storage_, init.handler)); > > return init.result.get(); >} > >template <typename Stream> >template <typename ConstBufferSequence> >std::size_t buffered_write_stream<Stream>::write_some( > const ConstBufferSequence& buffers) >{ > if (boost::asio::buffer_size(buffers) == 0) > return 0; > > if (storage_.size() == storage_.capacity()) > this->flush(); > > return this->copy(buffers); >} > >template <typename Stream> >template <typename ConstBufferSequence> >std::size_t buffered_write_stream<Stream>::write_some( > const ConstBufferSequence& buffers, boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > > if (boost::asio::buffer_size(buffers) == 0) > return 0; > > if (storage_.size() == storage_.capacity() && !flush(ec)) > return 0; > > return this->copy(buffers); >} > >namespace detail >{ > template <typename ConstBufferSequence, typename WriteHandler> > class buffered_write_some_handler > { > public: > buffered_write_some_handler(detail::buffered_stream_storage& storage, > const ConstBufferSequence& buffers, WriteHandler& handler) > : storage_(storage), > buffers_(buffers), > handler_(handler) > { > } > > > buffered_write_some_handler(const buffered_write_some_handler& other) > : storage_(other.storage_), > buffers_(other.buffers_), > handler_(other.handler_) > { > } > > buffered_write_some_handler(buffered_write_some_handler&& other) > : storage_(other.storage_), > buffers_(other.buffers_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, std::size_t) > { > if (ec) > { > const std::size_t length = 0; > handler_(ec, length); > } > else > { > std::size_t orig_size = storage_.size(); > std::size_t space_avail = storage_.capacity() - orig_size; > std::size_t bytes_avail = boost::asio::buffer_size(buffers_); > std::size_t length = bytes_avail < space_avail > ? bytes_avail : space_avail; > storage_.resize(orig_size + length); > const std::size_t bytes_copied = boost::asio::buffer_copy( > storage_.data() + orig_size, buffers_, length); > handler_(ec, bytes_copied); > } > } > > > detail::buffered_stream_storage& storage_; > ConstBufferSequence buffers_; > WriteHandler handler_; > }; > > template <typename ConstBufferSequence, typename WriteHandler> > inline void* asio_handler_allocate(std::size_t size, > buffered_write_some_handler< > ConstBufferSequence, WriteHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename ConstBufferSequence, typename WriteHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > buffered_write_some_handler< > ConstBufferSequence, WriteHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename ConstBufferSequence, typename WriteHandler> > inline bool asio_handler_is_continuation( > buffered_write_some_handler< > ConstBufferSequence, WriteHandler>* this_handler) > { > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename ConstBufferSequence, > typename WriteHandler> > inline void asio_handler_invoke(Function& function, > buffered_write_some_handler< > ConstBufferSequence, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename ConstBufferSequence, > typename WriteHandler> > inline void asio_handler_invoke(const Function& function, > buffered_write_some_handler< > ConstBufferSequence, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename Stream> >template <typename ConstBufferSequence, typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >buffered_write_stream<Stream>::async_write_some( > const ConstBufferSequence& buffers, > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > if (boost::asio::buffer_size(buffers) == 0 > || storage_.size() < storage_.capacity()) > { > next_layer_.async_write_some(boost::asio::const_buffers_1(0, 0), > detail::buffered_write_some_handler< > ConstBufferSequence, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > storage_, buffers, init.handler)); > } > else > { > this->async_flush(detail::buffered_write_some_handler< > ConstBufferSequence, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > storage_, buffers, init.handler)); > } > > return init.result.get(); >} > >template <typename Stream> >template <typename ConstBufferSequence> >std::size_t buffered_write_stream<Stream>::copy( > const ConstBufferSequence& buffers) >{ > std::size_t orig_size = storage_.size(); > std::size_t space_avail = storage_.capacity() - orig_size; > std::size_t bytes_avail = boost::asio::buffer_size(buffers); > std::size_t length = bytes_avail < space_avail ? bytes_avail : space_avail; > storage_.resize(orig_size + length); > return boost::asio::buffer_copy( > storage_.data() + orig_size, buffers, length); >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 339 "/usr/include/boost/asio/impl/buffered_write_stream.hpp" 2 3 4 ># 237 "/usr/include/boost/asio/buffered_write_stream.hpp" 2 3 4 ># 23 "/usr/include/boost/asio/buffered_stream.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/buffered_stream.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 45 "/usr/include/boost/asio/buffered_stream.hpp" 3 4 >template <typename Stream> >class buffered_stream > : private noncopyable >{ >public: > > typedef typename remove_reference<Stream>::type next_layer_type; > > > typedef typename next_layer_type::lowest_layer_type lowest_layer_type; > > > template <typename Arg> > explicit buffered_stream(Arg& a) > : inner_stream_impl_(a), > stream_impl_(inner_stream_impl_) > { > } > > > template <typename Arg> > explicit buffered_stream(Arg& a, std::size_t read_buffer_size, > std::size_t write_buffer_size) > : inner_stream_impl_(a, write_buffer_size), > stream_impl_(inner_stream_impl_, read_buffer_size) > { > } > > > next_layer_type& next_layer() > { > return stream_impl_.next_layer().next_layer(); > } > > > lowest_layer_type& lowest_layer() > { > return stream_impl_.lowest_layer(); > } > > > const lowest_layer_type& lowest_layer() const > { > return stream_impl_.lowest_layer(); > } > > > boost::asio::io_service& get_io_service() > { > return stream_impl_.get_io_service(); > } > > > void close() > { > stream_impl_.close(); > } > > > boost::system::error_code close(boost::system::error_code& ec) > { > return stream_impl_.close(ec); > } > > > > > std::size_t flush() > { > return stream_impl_.next_layer().flush(); > } > > > > > std::size_t flush(boost::system::error_code& ec) > { > return stream_impl_.next_layer().flush(ec); > } > > > template <typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_flush(WriteHandler&& handler) > { > return stream_impl_.next_layer().async_flush( > static_cast<WriteHandler&&>(handler)); > } > > > > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers) > { > return stream_impl_.write_some(buffers); > } > > > > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers, > boost::system::error_code& ec) > { > return stream_impl_.write_some(buffers, ec); > } > > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_write_some(const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > return stream_impl_.async_write_some(buffers, > static_cast<WriteHandler&&>(handler)); > } > > > > std::size_t fill() > { > return stream_impl_.fill(); > } > > > > std::size_t fill(boost::system::error_code& ec) > { > return stream_impl_.fill(ec); > } > > > template <typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_fill(ReadHandler&& handler) > { > return stream_impl_.async_fill(static_cast<ReadHandler&&>(handler)); > } > > > > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers) > { > return stream_impl_.read_some(buffers); > } > > > > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers, > boost::system::error_code& ec) > { > return stream_impl_.read_some(buffers, ec); > } > > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_read_some(const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > return stream_impl_.async_read_some(buffers, > static_cast<ReadHandler&&>(handler)); > } > > > > template <typename MutableBufferSequence> > std::size_t peek(const MutableBufferSequence& buffers) > { > return stream_impl_.peek(buffers); > } > > > > template <typename MutableBufferSequence> > std::size_t peek(const MutableBufferSequence& buffers, > boost::system::error_code& ec) > { > return stream_impl_.peek(buffers, ec); > } > > > std::size_t in_avail() > { > return stream_impl_.in_avail(); > } > > > std::size_t in_avail(boost::system::error_code& ec) > { > return stream_impl_.in_avail(ec); > } > >private: > > typedef buffered_write_stream<Stream> write_stream_type; > write_stream_type inner_stream_impl_; > > > typedef buffered_read_stream<write_stream_type&> read_stream_type; > read_stream_type stream_impl_; >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 259 "/usr/include/boost/asio/buffered_stream.hpp" 2 3 4 ># 39 "/usr/include/boost/asio.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/buffers_iterator.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/buffers_iterator.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/buffers_iterator.hpp" 2 3 4 > >namespace boost { >namespace asio { > >namespace detail >{ > template <bool IsMutable> > struct buffers_iterator_types_helper; > > template <> > struct buffers_iterator_types_helper<false> > { > typedef const_buffer buffer_type; > template <typename ByteType> > struct byte_type > { > typedef typename add_const<ByteType>::type type; > }; > }; > > template <> > struct buffers_iterator_types_helper<true> > { > typedef mutable_buffer buffer_type; > template <typename ByteType> > struct byte_type > { > typedef ByteType type; > }; > }; > > template <typename BufferSequence, typename ByteType> > struct buffers_iterator_types > { > enum > { > is_mutable = is_convertible< > typename BufferSequence::value_type, > mutable_buffer>::value > }; > typedef buffers_iterator_types_helper<is_mutable> helper; > typedef typename helper::buffer_type buffer_type; > typedef typename helper::template byte_type<ByteType>::type byte_type; > }; >} > > >template <typename BufferSequence, typename ByteType = char> >class buffers_iterator >{ >private: > typedef typename detail::buffers_iterator_types< > BufferSequence, ByteType>::buffer_type buffer_type; > >public: > > typedef std::ptrdiff_t difference_type; > > > typedef ByteType value_type; ># 96 "/usr/include/boost/asio/buffers_iterator.hpp" 3 4 > typedef typename detail::buffers_iterator_types< > BufferSequence, ByteType>::byte_type* pointer; ># 109 "/usr/include/boost/asio/buffers_iterator.hpp" 3 4 > typedef typename detail::buffers_iterator_types< > BufferSequence, ByteType>::byte_type& reference; > > > > typedef std::random_access_iterator_tag iterator_category; > > > buffers_iterator() > : current_buffer_(), > current_buffer_position_(0), > begin_(), > current_(), > end_(), > position_(0) > { > } > > > static buffers_iterator begin(const BufferSequence& buffers) > > > > { > buffers_iterator new_iter; > new_iter.begin_ = buffers.begin(); > new_iter.current_ = buffers.begin(); > new_iter.end_ = buffers.end(); > while (new_iter.current_ != new_iter.end_) > { > new_iter.current_buffer_ = *new_iter.current_; > if (boost::asio::buffer_size(new_iter.current_buffer_) > 0) > break; > ++new_iter.current_; > } > return new_iter; > } > > > static buffers_iterator end(const BufferSequence& buffers) > > > > { > buffers_iterator new_iter; > new_iter.begin_ = buffers.begin(); > new_iter.current_ = buffers.begin(); > new_iter.end_ = buffers.end(); > while (new_iter.current_ != new_iter.end_) > { > buffer_type buffer = *new_iter.current_; > new_iter.position_ += boost::asio::buffer_size(buffer); > ++new_iter.current_; > } > return new_iter; > } > > > reference operator*() const > { > return dereference(); > } > > > pointer operator->() const > { > return &dereference(); > } > > > reference operator[](std::ptrdiff_t difference) const > { > buffers_iterator tmp(*this); > tmp.advance(difference); > return *tmp; > } > > > buffers_iterator& operator++() > { > increment(); > return *this; > } > > > buffers_iterator operator++(int) > { > buffers_iterator tmp(*this); > ++*this; > return tmp; > } > > > buffers_iterator& operator--() > { > decrement(); > return *this; > } > > > buffers_iterator operator--(int) > { > buffers_iterator tmp(*this); > --*this; > return tmp; > } > > > buffers_iterator& operator+=(std::ptrdiff_t difference) > { > advance(difference); > return *this; > } > > > buffers_iterator& operator-=(std::ptrdiff_t difference) > { > advance(-difference); > return *this; > } > > > friend buffers_iterator operator+(const buffers_iterator& iter, > std::ptrdiff_t difference) > { > buffers_iterator tmp(iter); > tmp.advance(difference); > return tmp; > } > > > friend buffers_iterator operator+(std::ptrdiff_t difference, > const buffers_iterator& iter) > { > buffers_iterator tmp(iter); > tmp.advance(difference); > return tmp; > } > > > friend buffers_iterator operator-(const buffers_iterator& iter, > std::ptrdiff_t difference) > { > buffers_iterator tmp(iter); > tmp.advance(-difference); > return tmp; > } > > > friend std::ptrdiff_t operator-(const buffers_iterator& a, > const buffers_iterator& b) > { > return b.distance_to(a); > } > > > friend bool operator==(const buffers_iterator& a, const buffers_iterator& b) > { > return a.equal(b); > } > > > friend bool operator!=(const buffers_iterator& a, const buffers_iterator& b) > { > return !a.equal(b); > } > > > friend bool operator<(const buffers_iterator& a, const buffers_iterator& b) > { > return a.distance_to(b) > 0; > } > > > friend bool operator<=(const buffers_iterator& a, const buffers_iterator& b) > { > return !(b < a); > } > > > friend bool operator>(const buffers_iterator& a, const buffers_iterator& b) > { > return b < a; > } > > > friend bool operator>=(const buffers_iterator& a, const buffers_iterator& b) > { > return !(a < b); > } > >private: > > reference dereference() const > { > return buffer_cast<pointer>(current_buffer_)[current_buffer_position_]; > } > > > bool equal(const buffers_iterator& other) const > { > return position_ == other.position_; > } > > > void increment() > { > (static_cast<void> (0)); > ++position_; > > > ++current_buffer_position_; > if (current_buffer_position_ != boost::asio::buffer_size(current_buffer_)) > return; > > > ++current_; > current_buffer_position_ = 0; > while (current_ != end_) > { > current_buffer_ = *current_; > if (boost::asio::buffer_size(current_buffer_) > 0) > return; > ++current_; > } > } > > > void decrement() > { > (static_cast<void> (0)); > --position_; > > > if (current_buffer_position_ != 0) > { > --current_buffer_position_; > return; > } > > > typename BufferSequence::const_iterator iter = current_; > while (iter != begin_) > { > --iter; > buffer_type buffer = *iter; > std::size_t buffer_size = boost::asio::buffer_size(buffer); > if (buffer_size > 0) > { > current_ = iter; > current_buffer_ = buffer; > current_buffer_position_ = buffer_size - 1; > return; > } > } > } > > > void advance(std::ptrdiff_t n) > { > if (n > 0) > { > (static_cast<void> (0)); > for (;;) > { > std::ptrdiff_t current_buffer_balance > = boost::asio::buffer_size(current_buffer_) > - current_buffer_position_; > > > if (current_buffer_balance > n) > { > position_ += n; > current_buffer_position_ += n; > return; > } > > > n -= current_buffer_balance; > position_ += current_buffer_balance; > > > > if (++current_ == end_) > { > (static_cast<void> (0)); > current_buffer_ = buffer_type(); > current_buffer_position_ = 0; > return; > } > current_buffer_ = *current_; > current_buffer_position_ = 0; > } > } > else if (n < 0) > { > std::size_t abs_n = -n; > (static_cast<void> (0)); > for (;;) > { > > if (current_buffer_position_ >= abs_n) > { > position_ -= abs_n; > current_buffer_position_ -= abs_n; > return; > } > > > abs_n -= current_buffer_position_; > position_ -= current_buffer_position_; > > > if (current_ == begin_) > { > (static_cast<void> (0)); > current_buffer_position_ = 0; > return; > } > > > typename BufferSequence::const_iterator iter = current_; > while (iter != begin_) > { > --iter; > buffer_type buffer = *iter; > std::size_t buffer_size = boost::asio::buffer_size(buffer); > if (buffer_size > 0) > { > current_ = iter; > current_buffer_ = buffer; > current_buffer_position_ = buffer_size; > break; > } > } > } > } > } > > > std::ptrdiff_t distance_to(const buffers_iterator& other) const > { > return other.position_ - position_; > } > > buffer_type current_buffer_; > std::size_t current_buffer_position_; > typename BufferSequence::const_iterator begin_; > typename BufferSequence::const_iterator current_; > typename BufferSequence::const_iterator end_; > std::size_t position_; >}; > > >template <typename BufferSequence> >inline buffers_iterator<BufferSequence> buffers_begin( > const BufferSequence& buffers) >{ > return buffers_iterator<BufferSequence>::begin(buffers); >} > > >template <typename BufferSequence> >inline buffers_iterator<BufferSequence> buffers_end( > const BufferSequence& buffers) >{ > return buffers_iterator<BufferSequence>::end(buffers); >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 482 "/usr/include/boost/asio/buffers_iterator.hpp" 2 3 4 ># 42 "/usr/include/boost/asio.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/connect.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/connect.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/connect.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 64 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, typename Iterator> >Iterator connect(basic_socket<Protocol, SocketService>& s, Iterator begin); ># 101 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, typename Iterator> >Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, boost::system::error_code& ec); ># 133 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, typename Iterator> >Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end); ># 170 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, typename Iterator> >Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end, boost::system::error_code& ec); ># 233 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, > typename Iterator, typename ConnectCondition> >Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, ConnectCondition connect_condition); ># 305 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, > typename Iterator, typename ConnectCondition> >Iterator connect(basic_socket<Protocol, SocketService>& s, Iterator begin, > ConnectCondition connect_condition, boost::system::error_code& ec); ># 367 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, > typename Iterator, typename ConnectCondition> >Iterator connect(basic_socket<Protocol, SocketService>& s, Iterator begin, > Iterator end, ConnectCondition connect_condition); ># 437 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, > typename Iterator, typename ConnectCondition> >Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end, ConnectCondition connect_condition, > boost::system::error_code& ec); ># 518 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, > typename Iterator, typename ComposedConnectHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type>::type > >async_connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, ComposedConnectHandler&& handler); ># 589 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, > typename Iterator, typename ComposedConnectHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type>::type > >async_connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end, > ComposedConnectHandler&& handler); ># 699 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type>::type > >async_connect(basic_socket<Protocol, SocketService>& s, Iterator begin, > ConnectCondition connect_condition, > ComposedConnectHandler&& handler); ># 808 "/usr/include/boost/asio/connect.hpp" 3 4 >template <typename Protocol, typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type>::type > >async_connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end, ConnectCondition connect_condition, > ComposedConnectHandler&& handler); > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 822 "/usr/include/boost/asio/connect.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/connect.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/impl/connect.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/impl/connect.hpp" 2 3 4 > >namespace boost { >namespace asio { > >namespace detail >{ > struct default_connect_condition > { > template <typename Iterator> > Iterator operator()(const boost::system::error_code&, Iterator next) > { > return next; > } > }; >} > >template <typename Protocol, typename SocketService, typename Iterator> >Iterator connect(basic_socket<Protocol, SocketService>& s, Iterator begin) >{ > boost::system::error_code ec; > Iterator result = connect(s, begin, ec); > boost::asio::detail::throw_error(ec, "connect"); > return result; >} > >template <typename Protocol, typename SocketService, typename Iterator> >inline Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, boost::system::error_code& ec) >{ > return connect(s, begin, Iterator(), detail::default_connect_condition(), ec); >} > >template <typename Protocol, typename SocketService, typename Iterator> >Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end) >{ > boost::system::error_code ec; > Iterator result = connect(s, begin, end, ec); > boost::asio::detail::throw_error(ec, "connect"); > return result; >} > >template <typename Protocol, typename SocketService, typename Iterator> >inline Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end, boost::system::error_code& ec) >{ > return connect(s, begin, end, detail::default_connect_condition(), ec); >} > >template <typename Protocol, typename SocketService, > typename Iterator, typename ConnectCondition> >Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, ConnectCondition connect_condition) >{ > boost::system::error_code ec; > Iterator result = connect(s, begin, connect_condition, ec); > boost::asio::detail::throw_error(ec, "connect"); > return result; >} > >template <typename Protocol, typename SocketService, > typename Iterator, typename ConnectCondition> >inline Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, ConnectCondition connect_condition, > boost::system::error_code& ec) >{ > return connect(s, begin, Iterator(), connect_condition, ec); >} > >template <typename Protocol, typename SocketService, > typename Iterator, typename ConnectCondition> >Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end, ConnectCondition connect_condition) >{ > boost::system::error_code ec; > Iterator result = connect(s, begin, end, connect_condition, ec); > boost::asio::detail::throw_error(ec, "connect"); > return result; >} > >template <typename Protocol, typename SocketService, > typename Iterator, typename ConnectCondition> >Iterator connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end, ConnectCondition connect_condition, > boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > > for (Iterator iter = begin; iter != end; ++iter) > { > iter = connect_condition(ec, iter); > if (iter != end) > { > s.close(ec); > s.connect(*iter, ec); > if (!ec) > return iter; > } > } > > if (!ec) > ec = boost::asio::error::not_found; > > return end; >} > >namespace detail >{ > > template <typename ConnectCondition> > class base_from_connect_condition > { > protected: > explicit base_from_connect_condition( > const ConnectCondition& connect_condition) > : connect_condition_(connect_condition) > { > } > > template <typename Iterator> > void check_condition(const boost::system::error_code& ec, > Iterator& iter, Iterator& end) > { > if (iter != end) > iter = connect_condition_(ec, static_cast<const Iterator&>(iter)); > } > > private: > ConnectCondition connect_condition_; > }; > > > > template <> > class base_from_connect_condition<default_connect_condition> > { > protected: > explicit base_from_connect_condition(const default_connect_condition&) > { > } > > template <typename Iterator> > void check_condition(const boost::system::error_code&, Iterator&, Iterator&) > { > } > }; > > template <typename Protocol, typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> > class connect_op : base_from_connect_condition<ConnectCondition> > { > public: > connect_op(basic_socket<Protocol, SocketService>& sock, > const Iterator& begin, const Iterator& end, > const ConnectCondition& connect_condition, > ComposedConnectHandler& handler) > : base_from_connect_condition<ConnectCondition>(connect_condition), > socket_(sock), > iter_(begin), > end_(end), > start_(0), > handler_(static_cast<ComposedConnectHandler&&>(handler)) > { > } > > > connect_op(const connect_op& other) > : base_from_connect_condition<ConnectCondition>(other), > socket_(other.socket_), > iter_(other.iter_), > end_(other.end_), > start_(other.start_), > handler_(other.handler_) > { > } > > connect_op(connect_op&& other) > : base_from_connect_condition<ConnectCondition>(other), > socket_(other.socket_), > iter_(other.iter_), > end_(other.end_), > start_(other.start_), > handler_(static_cast<ComposedConnectHandler&&>(other.handler_)) > { > } > > > void operator()(boost::system::error_code ec, int start = 0) > { > switch (start_ = start) > { > case 1: > for (;;) > { > this->check_condition(ec, iter_, end_); > > if (iter_ != end_) > { > socket_.close(ec); > socket_.async_connect(*iter_, > static_cast<connect_op&&>(*this)); > return; > } > > if (start) > { > ec = boost::asio::error::not_found; > socket_.get_io_service().post(detail::bind_handler(*this, ec)); > return; > } > > default: > > if (iter_ == end_) > break; > > if (!socket_.is_open()) > { > ec = boost::asio::error::operation_aborted; > break; > } > > if (!ec) > break; > > ++iter_; > } > > handler_(static_cast<const boost::system::error_code&>(ec), > static_cast<const Iterator&>(iter_)); > } > } > > > basic_socket<Protocol, SocketService>& socket_; > Iterator iter_; > Iterator end_; > int start_; > ComposedConnectHandler handler_; > }; > > template <typename Protocol, typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> > inline void* asio_handler_allocate(std::size_t size, > connect_op<Protocol, SocketService, Iterator, > ConnectCondition, ComposedConnectHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename Protocol, typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > connect_op<Protocol, SocketService, Iterator, > ConnectCondition, ComposedConnectHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename Protocol, typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> > inline bool asio_handler_is_continuation( > connect_op<Protocol, SocketService, Iterator, > ConnectCondition, ComposedConnectHandler>* this_handler) > { > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename Protocol, > typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> > inline void asio_handler_invoke(Function& function, > connect_op<Protocol, SocketService, Iterator, > ConnectCondition, ComposedConnectHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename Protocol, > typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> > inline void asio_handler_invoke(const Function& function, > connect_op<Protocol, SocketService, Iterator, > ConnectCondition, ComposedConnectHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename Protocol, typename SocketService, > typename Iterator, typename ComposedConnectHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type>::type > >async_connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, ComposedConnectHandler&& handler) >{ > > > typedef typename handler_type<ComposedConnectHandler, void(boost::system::error_code, Iterator)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const Iterator*>(0))) == 1, "ComposedConnectHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const Iterator>()), char(0))> __attribute__((__unused__)) > type_check; > > detail::async_result_init<ComposedConnectHandler, > void (boost::system::error_code, Iterator)> init( > static_cast<ComposedConnectHandler&&>(handler)); > > detail::connect_op<Protocol, SocketService, Iterator, > detail::default_connect_condition, typename handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type > >(s, > begin, Iterator(), detail::default_connect_condition(), init.handler)( > boost::system::error_code(), 1); > > return init.result.get(); >} > >template <typename Protocol, typename SocketService, > typename Iterator, typename ComposedConnectHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type>::type > >async_connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end, > ComposedConnectHandler&& handler) >{ > > > typedef typename handler_type<ComposedConnectHandler, void(boost::system::error_code, Iterator)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const Iterator*>(0))) == 1, "ComposedConnectHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const Iterator>()), char(0))> __attribute__((__unused__)) > type_check; > > detail::async_result_init<ComposedConnectHandler, > void (boost::system::error_code, Iterator)> init( > static_cast<ComposedConnectHandler&&>(handler)); > > detail::connect_op<Protocol, SocketService, Iterator, > detail::default_connect_condition, typename handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type > >(s, > begin, end, detail::default_connect_condition(), init.handler)( > boost::system::error_code(), 1); > > return init.result.get(); >} > >template <typename Protocol, typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type>::type > >async_connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, ConnectCondition connect_condition, > ComposedConnectHandler&& handler) >{ > > > typedef typename handler_type<ComposedConnectHandler, void(boost::system::error_code, Iterator)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const Iterator*>(0))) == 1, "ComposedConnectHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const Iterator>()), char(0))> __attribute__((__unused__)) > type_check; > > detail::async_result_init<ComposedConnectHandler, > void (boost::system::error_code, Iterator)> init( > static_cast<ComposedConnectHandler&&>(handler)); > > detail::connect_op<Protocol, SocketService, Iterator, > ConnectCondition, typename handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type > >(s, > begin, Iterator(), connect_condition, init.handler)( > boost::system::error_code(), 1); > > return init.result.get(); >} > >template <typename Protocol, typename SocketService, typename Iterator, > typename ConnectCondition, typename ComposedConnectHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type>::type > >async_connect(basic_socket<Protocol, SocketService>& s, > Iterator begin, Iterator end, ConnectCondition connect_condition, > ComposedConnectHandler&& handler) >{ > > > typedef typename handler_type<ComposedConnectHandler, void(boost::system::error_code, Iterator)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const Iterator*>(0))) == 1, "ComposedConnectHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const Iterator>()), char(0))> __attribute__((__unused__)) > type_check; > > detail::async_result_init<ComposedConnectHandler, > void (boost::system::error_code, Iterator)> init( > static_cast<ComposedConnectHandler&&>(handler)); > > detail::connect_op<Protocol, SocketService, Iterator, > ConnectCondition, typename handler_type<ComposedConnectHandler, void (boost::system::error_code, Iterator)>::type > >(s, > begin, end, connect_condition, init.handler)( > boost::system::error_code(), 1); > > return init.result.get(); >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 429 "/usr/include/boost/asio/impl/connect.hpp" 2 3 4 ># 824 "/usr/include/boost/asio/connect.hpp" 2 3 4 ># 44 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/coroutine.hpp" 1 3 4 ># 14 "/usr/include/boost/asio/coroutine.hpp" 3 4 >namespace boost { >namespace asio { >namespace detail { > >class coroutine_ref; > >} ># 242 "/usr/include/boost/asio/coroutine.hpp" 3 4 >class coroutine >{ >public: > > coroutine() : value_(0) {} > > > bool is_child() const { return value_ < 0; } > > > bool is_parent() const { return !is_child(); } > > > bool is_complete() const { return value_ == -1; } > >private: > friend class detail::coroutine_ref; > int value_; >}; > > >namespace detail { > >class coroutine_ref >{ >public: > coroutine_ref(coroutine& c) : value_(c.value_), modified_(false) {} > coroutine_ref(coroutine* c) : value_(c->value_), modified_(false) {} > ~coroutine_ref() { if (!modified_) value_ = -1; } > operator int() const { return value_; } > int& operator=(int v) { modified_ = true; return value_ = v; } >private: > void operator=(const coroutine_ref&); > int& value_; > bool modified_; >}; > >} >} >} ># 45 "/usr/include/boost/asio.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/asio/generic/basic_endpoint.hpp" 1 3 4 ># 19 "/usr/include/boost/asio/generic/basic_endpoint.hpp" 3 4 ># 1 "/usr/include/boost/asio/generic/detail/endpoint.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/generic/detail/endpoint.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/generic/detail/endpoint.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace generic { >namespace detail { > > >class endpoint >{ >public: > > inline endpoint(); > > > inline endpoint(const void* sock_addr, > std::size_t sock_addr_size, int sock_protocol); > > > endpoint(const endpoint& other) > : data_(other.data_), > size_(other.size_), > protocol_(other.protocol_) > { > } > > > endpoint& operator=(const endpoint& other) > { > data_ = other.data_; > size_ = other.size_; > protocol_ = other.protocol_; > return *this; > } > > > int family() const > { > return data_.base.sa_family; > } > > > int protocol() const > { > return protocol_; > } > > > boost::asio::detail::socket_addr_type* data() > { > return &data_.base; > } > > > const boost::asio::detail::socket_addr_type* data() const > { > return &data_.base; > } > > > std::size_t size() const > { > return size_; > } > > > inline void resize(std::size_t size); > > > std::size_t capacity() const > { > return sizeof(boost::asio::detail::sockaddr_storage_type); > } > > > inline friend bool operator==( > const endpoint& e1, const endpoint& e2); > > > inline friend bool operator<( > const endpoint& e1, const endpoint& e2); > >private: > > union data_union > { > boost::asio::detail::socket_addr_type base; > boost::asio::detail::sockaddr_storage_type generic; > } data_; > > > std::size_t size_; > > > int protocol_; > > > inline void init(const void* sock_addr, > std::size_t sock_addr_size, int sock_protocol); >}; > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 130 "/usr/include/boost/asio/generic/detail/endpoint.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/generic/detail/impl/endpoint.ipp" 1 3 4 ># 20 "/usr/include/boost/asio/generic/detail/impl/endpoint.ipp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 21 "/usr/include/boost/asio/generic/detail/impl/endpoint.ipp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/generic/detail/endpoint.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/generic/detail/impl/endpoint.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/generic/detail/impl/endpoint.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace generic { >namespace detail { > >endpoint::endpoint() >{ > init(0, 0, 0); >} > >endpoint::endpoint(const void* sock_addr, > std::size_t sock_addr_size, int sock_protocol) >{ > init(sock_addr, sock_addr_size, sock_protocol); >} > >void endpoint::resize(std::size_t new_size) >{ > if (new_size > sizeof(boost::asio::detail::sockaddr_storage_type)) > { > boost::system::error_code ec(boost::asio::error::invalid_argument); > boost::asio::detail::throw_error(ec); > } > else > { > size_ = new_size; > protocol_ = 0; > } >} > >bool operator==(const endpoint& e1, const endpoint& e2) >{ > using namespace std; > return e1.size() == e2.size() && memcmp(e1.data(), e2.data(), e1.size()) == 0; >} > >bool operator<(const endpoint& e1, const endpoint& e2) >{ > if (e1.protocol() < e2.protocol()) > return true; > > if (e1.protocol() > e2.protocol()) > return false; > > using namespace std; > std::size_t compare_size = e1.size() < e2.size() ? e1.size() : e2.size(); > int compare_result = memcmp(e1.data(), e2.data(), compare_size); > > if (compare_result < 0) > return true; > > if (compare_result > 0) > return false; > > return e1.size() < e2.size(); >} > >void endpoint::init(const void* sock_addr, > std::size_t sock_addr_size, int sock_protocol) >{ > if (sock_addr_size > sizeof(boost::asio::detail::sockaddr_storage_type)) > { > boost::system::error_code ec(boost::asio::error::invalid_argument); > boost::asio::detail::throw_error(ec); > } > > using namespace std; > memset(&data_.generic, 0, sizeof(boost::asio::detail::sockaddr_storage_type)); > memcpy(&data_.generic, sock_addr, sock_addr_size); > > size_ = sock_addr_size; > protocol_ = sock_protocol; >} > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 110 "/usr/include/boost/asio/generic/detail/impl/endpoint.ipp" 2 3 4 ># 133 "/usr/include/boost/asio/generic/detail/endpoint.hpp" 2 3 4 ># 20 "/usr/include/boost/asio/generic/basic_endpoint.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/generic/basic_endpoint.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace generic { ># 42 "/usr/include/boost/asio/generic/basic_endpoint.hpp" 3 4 >template <typename Protocol> >class basic_endpoint >{ >public: > > typedef Protocol protocol_type; > > > > > > > typedef boost::asio::detail::socket_addr_type data_type; > > > > basic_endpoint() > { > } > > > basic_endpoint(const void* socket_address, > std::size_t socket_address_size, int socket_protocol = 0) > : impl_(socket_address, socket_address_size, socket_protocol) > { > } > > > template <typename Endpoint> > basic_endpoint(const Endpoint& endpoint) > : impl_(endpoint.data(), endpoint.size(), endpoint.protocol().protocol()) > { > } > > > basic_endpoint(const basic_endpoint& other) > : impl_(other.impl_) > { > } > > > > basic_endpoint(basic_endpoint&& other) > : impl_(other.impl_) > { > } > > > > basic_endpoint& operator=(const basic_endpoint& other) > { > impl_ = other.impl_; > return *this; > } > > > > basic_endpoint& operator=(basic_endpoint&& other) > { > impl_ = other.impl_; > return *this; > } > > > > protocol_type protocol() const > { > return protocol_type(impl_.family(), impl_.protocol()); > } > > > data_type* data() > { > return impl_.data(); > } > > > const data_type* data() const > { > return impl_.data(); > } > > > std::size_t size() const > { > return impl_.size(); > } > > > void resize(std::size_t new_size) > { > impl_.resize(new_size); > } > > > std::size_t capacity() const > { > return impl_.capacity(); > } > > > friend bool operator==(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return e1.impl_ == e2.impl_; > } > > > friend bool operator!=(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return !(e1.impl_ == e2.impl_); > } > > > friend bool operator<(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return e1.impl_ < e2.impl_; > } > > > friend bool operator>(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return e2.impl_ < e1.impl_; > } > > > friend bool operator<=(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return !(e2 < e1); > } > > > friend bool operator>=(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return !(e1 < e2); > } > >private: > > boost::asio::generic::detail::endpoint impl_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 194 "/usr/include/boost/asio/generic/basic_endpoint.hpp" 2 3 4 ># 50 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/generic/datagram_protocol.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/generic/datagram_protocol.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/generic/datagram_protocol.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace generic { ># 50 "/usr/include/boost/asio/generic/datagram_protocol.hpp" 3 4 >class datagram_protocol >{ >public: > > datagram_protocol(int address_family, int socket_protocol) > : family_(address_family), > protocol_(socket_protocol) > { > } > > > > > > template <typename Protocol> > datagram_protocol(const Protocol& source_protocol) > : family_(source_protocol.family()), > protocol_(source_protocol.protocol()) > { > if (source_protocol.type() != type()) > { > std::bad_cast ex; > boost::asio::detail::throw_exception(ex); > } > } > > > int type() const > { > return SOCK_DGRAM; > } > > > int protocol() const > { > return protocol_; > } > > > int family() const > { > return family_; > } > > > friend bool operator==(const datagram_protocol& p1, > const datagram_protocol& p2) > { > return p1.family_ == p2.family_ && p1.protocol_ == p2.protocol_; > } > > > friend bool operator!=(const datagram_protocol& p1, > const datagram_protocol& p2) > { > return !(p1 == p2); > } > > > typedef basic_endpoint<datagram_protocol> endpoint; > > > typedef basic_datagram_socket<datagram_protocol> socket; > >private: > int family_; > int protocol_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 124 "/usr/include/boost/asio/generic/datagram_protocol.hpp" 2 3 4 ># 51 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/generic/raw_protocol.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/generic/raw_protocol.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/generic/raw_protocol.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace generic { ># 50 "/usr/include/boost/asio/generic/raw_protocol.hpp" 3 4 >class raw_protocol >{ >public: > > raw_protocol(int address_family, int socket_protocol) > : family_(address_family), > protocol_(socket_protocol) > { > } > > > > > > template <typename Protocol> > raw_protocol(const Protocol& source_protocol) > : family_(source_protocol.family()), > protocol_(source_protocol.protocol()) > { > if (source_protocol.type() != type()) > { > std::bad_cast ex; > boost::asio::detail::throw_exception(ex); > } > } > > > int type() const > { > return SOCK_RAW; > } > > > int protocol() const > { > return protocol_; > } > > > int family() const > { > return family_; > } > > > friend bool operator==(const raw_protocol& p1, const raw_protocol& p2) > { > return p1.family_ == p2.family_ && p1.protocol_ == p2.protocol_; > } > > > friend bool operator!=(const raw_protocol& p1, const raw_protocol& p2) > { > return !(p1 == p2); > } > > > typedef basic_endpoint<raw_protocol> endpoint; > > > typedef basic_raw_socket<raw_protocol> socket; > >private: > int family_; > int protocol_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 122 "/usr/include/boost/asio/generic/raw_protocol.hpp" 2 3 4 ># 52 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/generic/seq_packet_protocol.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/generic/seq_packet_protocol.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/generic/seq_packet_protocol.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace generic { ># 48 "/usr/include/boost/asio/generic/seq_packet_protocol.hpp" 3 4 >class seq_packet_protocol >{ >public: > > seq_packet_protocol(int address_family, int socket_protocol) > : family_(address_family), > protocol_(socket_protocol) > { > } > > > > > > > template <typename Protocol> > seq_packet_protocol(const Protocol& source_protocol) > : family_(source_protocol.family()), > protocol_(source_protocol.protocol()) > { > if (source_protocol.type() != type()) > { > std::bad_cast ex; > boost::asio::detail::throw_exception(ex); > } > } > > > int type() const > { > return SOCK_SEQPACKET; > } > > > int protocol() const > { > return protocol_; > } > > > int family() const > { > return family_; > } > > > friend bool operator==(const seq_packet_protocol& p1, > const seq_packet_protocol& p2) > { > return p1.family_ == p2.family_ && p1.protocol_ == p2.protocol_; > } > > > friend bool operator!=(const seq_packet_protocol& p1, > const seq_packet_protocol& p2) > { > return !(p1 == p2); > } > > > typedef basic_endpoint<seq_packet_protocol> endpoint; > > > typedef basic_seq_packet_socket<seq_packet_protocol> socket; > >private: > int family_; > int protocol_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 123 "/usr/include/boost/asio/generic/seq_packet_protocol.hpp" 2 3 4 ># 53 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/generic/stream_protocol.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/generic/stream_protocol.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/generic/stream_protocol.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace generic { ># 51 "/usr/include/boost/asio/generic/stream_protocol.hpp" 3 4 >class stream_protocol >{ >public: > > stream_protocol(int address_family, int socket_protocol) > : family_(address_family), > protocol_(socket_protocol) > { > } > > > > > > template <typename Protocol> > stream_protocol(const Protocol& source_protocol) > : family_(source_protocol.family()), > protocol_(source_protocol.protocol()) > { > if (source_protocol.type() != type()) > { > std::bad_cast ex; > boost::asio::detail::throw_exception(ex); > } > } > > > int type() const > { > return SOCK_STREAM; > } > > > int protocol() const > { > return protocol_; > } > > > int family() const > { > return family_; > } > > > friend bool operator==(const stream_protocol& p1, const stream_protocol& p2) > { > return p1.family_ == p2.family_ && p1.protocol_ == p2.protocol_; > } > > > friend bool operator!=(const stream_protocol& p1, const stream_protocol& p2) > { > return !(p1 == p2); > } > > > typedef basic_endpoint<stream_protocol> endpoint; > > > typedef basic_stream_socket<stream_protocol> socket; > > > > typedef basic_socket_iostream<stream_protocol> iostream; > > >private: > int family_; > int protocol_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 128 "/usr/include/boost/asio/generic/stream_protocol.hpp" 2 3 4 ># 54 "/usr/include/boost/asio.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/ip/address.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/ip/address.hpp" 3 4 ># 1 "/usr/include/boost/asio/ip/address_v4.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/address_v4.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/winsock_init.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/address_v4.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/ip/address_v4.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 44 "/usr/include/boost/asio/ip/address_v4.hpp" 3 4 >class address_v4 >{ >public: ># 55 "/usr/include/boost/asio/ip/address_v4.hpp" 3 4 > typedef boost::asio::detail::array<unsigned char, 4> bytes_type; > > > > address_v4() > { > addr_.s_addr = 0; > } > > > inline explicit address_v4(const bytes_type& bytes); > > > inline explicit address_v4(unsigned long addr); > > > address_v4(const address_v4& other) > : addr_(other.addr_) > { > } > > > > address_v4(address_v4&& other) > : addr_(other.addr_) > { > } > > > > address_v4& operator=(const address_v4& other) > { > addr_ = other.addr_; > return *this; > } > > > > address_v4& operator=(address_v4&& other) > { > addr_ = other.addr_; > return *this; > } > > > > inline bytes_type to_bytes() const; > > > inline unsigned long to_ulong() const; > > > inline std::string to_string() const; > > > inline std::string to_string(boost::system::error_code& ec) const; > > > inline static address_v4 from_string(const char* str); > > > inline static address_v4 from_string( > const char* str, boost::system::error_code& ec); > > > inline static address_v4 from_string(const std::string& str); > > > inline static address_v4 from_string( > const std::string& str, boost::system::error_code& ec); > > > inline bool is_loopback() const; > > > inline bool is_unspecified() const; > > > inline bool is_class_a() const; > > > inline bool is_class_b() const; > > > inline bool is_class_c() const; > > > inline bool is_multicast() const; > > > friend bool operator==(const address_v4& a1, const address_v4& a2) > { > return a1.addr_.s_addr == a2.addr_.s_addr; > } > > > friend bool operator!=(const address_v4& a1, const address_v4& a2) > { > return a1.addr_.s_addr != a2.addr_.s_addr; > } > > > friend bool operator<(const address_v4& a1, const address_v4& a2) > { > return a1.to_ulong() < a2.to_ulong(); > } > > > friend bool operator>(const address_v4& a1, const address_v4& a2) > { > return a1.to_ulong() > a2.to_ulong(); > } > > > friend bool operator<=(const address_v4& a1, const address_v4& a2) > { > return a1.to_ulong() <= a2.to_ulong(); > } > > > friend bool operator>=(const address_v4& a1, const address_v4& a2) > { > return a1.to_ulong() >= a2.to_ulong(); > } > > > static address_v4 any() > { > return address_v4(); > } > > > static address_v4 loopback() > { > return address_v4(0x7F000001); > } > > > static address_v4 broadcast() > { > return address_v4(0xFFFFFFFF); > } > > > > inline static address_v4 broadcast( > const address_v4& addr, const address_v4& mask); > > > > inline static address_v4 netmask(const address_v4& addr); > >private: > > boost::asio::detail::in4_addr_type addr_; >}; ># 226 "/usr/include/boost/asio/ip/address_v4.hpp" 3 4 >template <typename Elem, typename Traits> >std::basic_ostream<Elem, Traits>& operator<<( > std::basic_ostream<Elem, Traits>& os, const address_v4& addr); > > > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 237 "/usr/include/boost/asio/ip/address_v4.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/ip/impl/address_v4.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/impl/address_v4.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/impl/address_v4.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > >template <typename Elem, typename Traits> >std::basic_ostream<Elem, Traits>& operator<<( > std::basic_ostream<Elem, Traits>& os, const address_v4& addr) >{ > boost::system::error_code ec; > std::string s = addr.to_string(ec); > if (ec) > { > if (os.exceptions() & std::basic_ostream<Elem, Traits>::failbit) > boost::asio::detail::throw_error(ec); > else > os.setstate(std::basic_ostream<Elem, Traits>::failbit); > } > else > for (std::string::iterator i = s.begin(); i != s.end(); ++i) > os << os.widen(*i); > return os; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 52 "/usr/include/boost/asio/ip/impl/address_v4.hpp" 2 3 4 ># 239 "/usr/include/boost/asio/ip/address_v4.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/ip/impl/address_v4.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/ip/impl/address_v4.ipp" 3 4 ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 20 "/usr/include/boost/asio/ip/impl/address_v4.ipp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/ip/address_v4.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/ip/impl/address_v4.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/ip/impl/address_v4.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > >address_v4::address_v4(const address_v4::bytes_type& bytes) >{ ># 44 "/usr/include/boost/asio/ip/impl/address_v4.ipp" 3 4 > using namespace std; > memcpy(&addr_.s_addr, bytes.data(), 4); >} > >address_v4::address_v4(unsigned long addr) >{ > > if (addr > 0xFFFFFFFF) > { > std::out_of_range ex("address_v4 from unsigned long"); > boost::asio::detail::throw_exception(ex); > } > > > addr_.s_addr = boost::asio::detail::socket_ops::host_to_network_long( > static_cast<boost::asio::detail::u_long_type>(addr)); >} > >address_v4::bytes_type address_v4::to_bytes() const >{ > using namespace std; > bytes_type bytes; > > memcpy(bytes.data(), &addr_.s_addr, 4); > > > > return bytes; >} > >unsigned long address_v4::to_ulong() const >{ > return boost::asio::detail::socket_ops::network_to_host_long(addr_.s_addr); >} > >std::string address_v4::to_string() const >{ > boost::system::error_code ec; > std::string addr = to_string(ec); > boost::asio::detail::throw_error(ec); > return addr; >} > >std::string address_v4::to_string(boost::system::error_code& ec) const >{ > char addr_str[boost::asio::detail::max_addr_v4_str_len]; > const char* addr = > boost::asio::detail::socket_ops::inet_ntop( > 2, &addr_, addr_str, > boost::asio::detail::max_addr_v4_str_len, 0, ec); > if (addr == 0) > return std::string(); > return addr; >} > >address_v4 address_v4::from_string(const char* str) >{ > boost::system::error_code ec; > address_v4 addr = from_string(str, ec); > boost::asio::detail::throw_error(ec); > return addr; >} > >address_v4 address_v4::from_string( > const char* str, boost::system::error_code& ec) >{ > address_v4 tmp; > if (boost::asio::detail::socket_ops::inet_pton( > 2, str, &tmp.addr_, 0, ec) <= 0) > return address_v4(); > return tmp; >} > >address_v4 address_v4::from_string(const std::string& str) >{ > return from_string(str.c_str()); >} > >address_v4 address_v4::from_string( > const std::string& str, boost::system::error_code& ec) >{ > return from_string(str.c_str(), ec); >} > >bool address_v4::is_loopback() const >{ > return (to_ulong() & 0xFF000000) == 0x7F000000; >} > >bool address_v4::is_unspecified() const >{ > return to_ulong() == 0; >} > >bool address_v4::is_class_a() const >{ > return (to_ulong() & 0x80000000) == 0; >} > >bool address_v4::is_class_b() const >{ > return (to_ulong() & 0xC0000000) == 0x80000000; >} > >bool address_v4::is_class_c() const >{ > return (to_ulong() & 0xE0000000) == 0xC0000000; >} > >bool address_v4::is_multicast() const >{ > return (to_ulong() & 0xF0000000) == 0xE0000000; >} > >address_v4 address_v4::broadcast(const address_v4& addr, const address_v4& mask) >{ > return address_v4(addr.to_ulong() | (mask.to_ulong() ^ 0xFFFFFFFF)); >} > >address_v4 address_v4::netmask(const address_v4& addr) >{ > if (addr.is_class_a()) > return address_v4(0xFF000000); > if (addr.is_class_b()) > return address_v4(0xFFFF0000); > if (addr.is_class_c()) > return address_v4(0xFFFFFF00); > return address_v4(0xFFFFFFFF); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 179 "/usr/include/boost/asio/ip/impl/address_v4.ipp" 2 3 4 ># 241 "/usr/include/boost/asio/ip/address_v4.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/ip/address.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/ip/address_v6.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/ip/address_v6.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/ip/address_v6.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 45 "/usr/include/boost/asio/ip/address_v6.hpp" 3 4 >class address_v6 >{ >public: ># 56 "/usr/include/boost/asio/ip/address_v6.hpp" 3 4 > typedef boost::asio::detail::array<unsigned char, 16> bytes_type; > > > > inline address_v6(); > > > inline explicit address_v6(const bytes_type& bytes, > unsigned long scope_id = 0); > > > inline address_v6(const address_v6& other); > > > > inline address_v6(address_v6&& other); > > > > inline address_v6& operator=(const address_v6& other); > > > > inline address_v6& operator=(address_v6&& other); > > > > > > > unsigned long scope_id() const > { > return scope_id_; > } > > > > > > void scope_id(unsigned long id) > { > scope_id_ = id; > } > > > inline bytes_type to_bytes() const; > > > inline std::string to_string() const; > > > inline std::string to_string(boost::system::error_code& ec) const; > > > inline static address_v6 from_string(const char* str); > > > inline static address_v6 from_string( > const char* str, boost::system::error_code& ec); > > > inline static address_v6 from_string(const std::string& str); > > > inline static address_v6 from_string( > const std::string& str, boost::system::error_code& ec); > > > inline address_v4 to_v4() const; > > > inline bool is_loopback() const; > > > inline bool is_unspecified() const; > > > inline bool is_link_local() const; > > > inline bool is_site_local() const; > > > inline bool is_v4_mapped() const; > > > inline bool is_v4_compatible() const; > > > inline bool is_multicast() const; > > > inline bool is_multicast_global() const; > > > inline bool is_multicast_link_local() const; > > > inline bool is_multicast_node_local() const; > > > inline bool is_multicast_org_local() const; > > > inline bool is_multicast_site_local() const; > > > inline friend bool operator==( > const address_v6& a1, const address_v6& a2); > > > friend bool operator!=(const address_v6& a1, const address_v6& a2) > { > return !(a1 == a2); > } > > > inline friend bool operator<( > const address_v6& a1, const address_v6& a2); > > > friend bool operator>(const address_v6& a1, const address_v6& a2) > { > return a2 < a1; > } > > > friend bool operator<=(const address_v6& a1, const address_v6& a2) > { > return !(a2 < a1); > } > > > friend bool operator>=(const address_v6& a1, const address_v6& a2) > { > return !(a1 < a2); > } > > > static address_v6 any() > { > return address_v6(); > } > > > inline static address_v6 loopback(); > > > inline static address_v6 v4_mapped(const address_v4& addr); > > > inline static address_v6 v4_compatible(const address_v4& addr); > >private: > > boost::asio::detail::in6_addr_type addr_; > > > unsigned long scope_id_; >}; ># 231 "/usr/include/boost/asio/ip/address_v6.hpp" 3 4 >template <typename Elem, typename Traits> >std::basic_ostream<Elem, Traits>& operator<<( > std::basic_ostream<Elem, Traits>& os, const address_v6& addr); > > > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 242 "/usr/include/boost/asio/ip/address_v6.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/ip/impl/address_v6.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/impl/address_v6.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/impl/address_v6.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > >template <typename Elem, typename Traits> >std::basic_ostream<Elem, Traits>& operator<<( > std::basic_ostream<Elem, Traits>& os, const address_v6& addr) >{ > boost::system::error_code ec; > std::string s = addr.to_string(ec); > if (ec) > { > if (os.exceptions() & std::basic_ostream<Elem, Traits>::failbit) > boost::asio::detail::throw_error(ec); > else > os.setstate(std::basic_ostream<Elem, Traits>::failbit); > } > else > for (std::string::iterator i = s.begin(); i != s.end(); ++i) > os << os.widen(*i); > return os; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 52 "/usr/include/boost/asio/ip/impl/address_v6.hpp" 2 3 4 ># 244 "/usr/include/boost/asio/ip/address_v6.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/ip/impl/address_v6.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/ip/impl/address_v6.ipp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 20 "/usr/include/boost/asio/ip/impl/address_v6.ipp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/ip/address_v6.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/ip/impl/address_v6.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/ip/impl/address_v6.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > >address_v6::address_v6() > : addr_(), > scope_id_(0) >{ >} > >address_v6::address_v6(const address_v6::bytes_type& bytes, > unsigned long scope) > : scope_id_(scope) >{ ># 55 "/usr/include/boost/asio/ip/impl/address_v6.ipp" 3 4 > using namespace std; > memcpy(addr_.__in6_u.__u6_addr8, bytes.data(), 16); >} > >address_v6::address_v6(const address_v6& other) > : addr_(other.addr_), > scope_id_(other.scope_id_) >{ >} > > >address_v6::address_v6(address_v6&& other) > : addr_(other.addr_), > scope_id_(other.scope_id_) >{ >} > > >address_v6& address_v6::operator=(const address_v6& other) >{ > addr_ = other.addr_; > scope_id_ = other.scope_id_; > return *this; >} > > >address_v6& address_v6::operator=(address_v6&& other) >{ > addr_ = other.addr_; > scope_id_ = other.scope_id_; > return *this; >} > > >address_v6::bytes_type address_v6::to_bytes() const >{ > using namespace std; > bytes_type bytes; > > memcpy(bytes.data(), addr_.__in6_u.__u6_addr8, 16); > > > > return bytes; >} > >std::string address_v6::to_string() const >{ > boost::system::error_code ec; > std::string addr = to_string(ec); > boost::asio::detail::throw_error(ec); > return addr; >} > >std::string address_v6::to_string(boost::system::error_code& ec) const >{ > char addr_str[boost::asio::detail::max_addr_v6_str_len]; > const char* addr = > boost::asio::detail::socket_ops::inet_ntop( > 10, &addr_, addr_str, > boost::asio::detail::max_addr_v6_str_len, scope_id_, ec); > if (addr == 0) > return std::string(); > return addr; >} > >address_v6 address_v6::from_string(const char* str) >{ > boost::system::error_code ec; > address_v6 addr = from_string(str, ec); > boost::asio::detail::throw_error(ec); > return addr; >} > >address_v6 address_v6::from_string( > const char* str, boost::system::error_code& ec) >{ > address_v6 tmp; > if (boost::asio::detail::socket_ops::inet_pton( > 10, str, &tmp.addr_, &tmp.scope_id_, ec) <= 0) > return address_v6(); > return tmp; >} > >address_v6 address_v6::from_string(const std::string& str) >{ > return from_string(str.c_str()); >} > >address_v6 address_v6::from_string( > const std::string& str, boost::system::error_code& ec) >{ > return from_string(str.c_str(), ec); >} > >address_v4 address_v6::to_v4() const >{ > if (!is_v4_mapped() && !is_v4_compatible()) > { > std::bad_cast ex; > boost::asio::detail::throw_exception(ex); > } > > address_v4::bytes_type v4_bytes = { { addr_.__in6_u.__u6_addr8[12], > addr_.__in6_u.__u6_addr8[13], addr_.__in6_u.__u6_addr8[14], addr_.__in6_u.__u6_addr8[15] } }; > return address_v4(v4_bytes); >} > >bool address_v6::is_loopback() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0) && (addr_.__in6_u.__u6_addr8[1] == 0) > && (addr_.__in6_u.__u6_addr8[2] == 0) && (addr_.__in6_u.__u6_addr8[3] == 0) > && (addr_.__in6_u.__u6_addr8[4] == 0) && (addr_.__in6_u.__u6_addr8[5] == 0) > && (addr_.__in6_u.__u6_addr8[6] == 0) && (addr_.__in6_u.__u6_addr8[7] == 0) > && (addr_.__in6_u.__u6_addr8[8] == 0) && (addr_.__in6_u.__u6_addr8[9] == 0) > && (addr_.__in6_u.__u6_addr8[10] == 0) && (addr_.__in6_u.__u6_addr8[11] == 0) > && (addr_.__in6_u.__u6_addr8[12] == 0) && (addr_.__in6_u.__u6_addr8[13] == 0) > && (addr_.__in6_u.__u6_addr8[14] == 0) && (addr_.__in6_u.__u6_addr8[15] == 1)); >} > >bool address_v6::is_unspecified() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0) && (addr_.__in6_u.__u6_addr8[1] == 0) > && (addr_.__in6_u.__u6_addr8[2] == 0) && (addr_.__in6_u.__u6_addr8[3] == 0) > && (addr_.__in6_u.__u6_addr8[4] == 0) && (addr_.__in6_u.__u6_addr8[5] == 0) > && (addr_.__in6_u.__u6_addr8[6] == 0) && (addr_.__in6_u.__u6_addr8[7] == 0) > && (addr_.__in6_u.__u6_addr8[8] == 0) && (addr_.__in6_u.__u6_addr8[9] == 0) > && (addr_.__in6_u.__u6_addr8[10] == 0) && (addr_.__in6_u.__u6_addr8[11] == 0) > && (addr_.__in6_u.__u6_addr8[12] == 0) && (addr_.__in6_u.__u6_addr8[13] == 0) > && (addr_.__in6_u.__u6_addr8[14] == 0) && (addr_.__in6_u.__u6_addr8[15] == 0)); >} > >bool address_v6::is_link_local() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0xfe) && ((addr_.__in6_u.__u6_addr8[1] & 0xc0) == 0x80)); >} > >bool address_v6::is_site_local() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0xfe) && ((addr_.__in6_u.__u6_addr8[1] & 0xc0) == 0xc0)); >} > >bool address_v6::is_v4_mapped() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0) && (addr_.__in6_u.__u6_addr8[1] == 0) > && (addr_.__in6_u.__u6_addr8[2] == 0) && (addr_.__in6_u.__u6_addr8[3] == 0) > && (addr_.__in6_u.__u6_addr8[4] == 0) && (addr_.__in6_u.__u6_addr8[5] == 0) > && (addr_.__in6_u.__u6_addr8[6] == 0) && (addr_.__in6_u.__u6_addr8[7] == 0) > && (addr_.__in6_u.__u6_addr8[8] == 0) && (addr_.__in6_u.__u6_addr8[9] == 0) > && (addr_.__in6_u.__u6_addr8[10] == 0xff) && (addr_.__in6_u.__u6_addr8[11] == 0xff)); >} > >bool address_v6::is_v4_compatible() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0) && (addr_.__in6_u.__u6_addr8[1] == 0) > && (addr_.__in6_u.__u6_addr8[2] == 0) && (addr_.__in6_u.__u6_addr8[3] == 0) > && (addr_.__in6_u.__u6_addr8[4] == 0) && (addr_.__in6_u.__u6_addr8[5] == 0) > && (addr_.__in6_u.__u6_addr8[6] == 0) && (addr_.__in6_u.__u6_addr8[7] == 0) > && (addr_.__in6_u.__u6_addr8[8] == 0) && (addr_.__in6_u.__u6_addr8[9] == 0) > && (addr_.__in6_u.__u6_addr8[10] == 0) && (addr_.__in6_u.__u6_addr8[11] == 0) > && !((addr_.__in6_u.__u6_addr8[12] == 0) > && (addr_.__in6_u.__u6_addr8[13] == 0) > && (addr_.__in6_u.__u6_addr8[14] == 0) > && ((addr_.__in6_u.__u6_addr8[15] == 0) || (addr_.__in6_u.__u6_addr8[15] == 1)))); >} > >bool address_v6::is_multicast() const >{ > return (addr_.__in6_u.__u6_addr8[0] == 0xff); >} > >bool address_v6::is_multicast_global() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0xff) && ((addr_.__in6_u.__u6_addr8[1] & 0x0f) == 0x0e)); >} > >bool address_v6::is_multicast_link_local() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0xff) && ((addr_.__in6_u.__u6_addr8[1] & 0x0f) == 0x02)); >} > >bool address_v6::is_multicast_node_local() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0xff) && ((addr_.__in6_u.__u6_addr8[1] & 0x0f) == 0x01)); >} > >bool address_v6::is_multicast_org_local() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0xff) && ((addr_.__in6_u.__u6_addr8[1] & 0x0f) == 0x08)); >} > >bool address_v6::is_multicast_site_local() const >{ > return ((addr_.__in6_u.__u6_addr8[0] == 0xff) && ((addr_.__in6_u.__u6_addr8[1] & 0x0f) == 0x05)); >} > >bool operator==(const address_v6& a1, const address_v6& a2) >{ > using namespace std; > return memcmp(&a1.addr_, &a2.addr_, > sizeof(boost::asio::detail::in6_addr_type)) == 0 > && a1.scope_id_ == a2.scope_id_; >} > >bool operator<(const address_v6& a1, const address_v6& a2) >{ > using namespace std; > int memcmp_result = memcmp(&a1.addr_, &a2.addr_, > sizeof(boost::asio::detail::in6_addr_type)); > if (memcmp_result < 0) > return true; > if (memcmp_result > 0) > return false; > return a1.scope_id_ < a2.scope_id_; >} > >address_v6 address_v6::loopback() >{ > address_v6 tmp; > tmp.addr_.__in6_u.__u6_addr8[15] = 1; > return tmp; >} > >address_v6 address_v6::v4_mapped(const address_v4& addr) >{ > address_v4::bytes_type v4_bytes = addr.to_bytes(); > bytes_type v6_bytes = { { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xFF, 0xFF, > v4_bytes[0], v4_bytes[1], v4_bytes[2], v4_bytes[3] } }; > return address_v6(v6_bytes); >} > >address_v6 address_v6::v4_compatible(const address_v4& addr) >{ > address_v4::bytes_type v4_bytes = addr.to_bytes(); > bytes_type v6_bytes = { { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, > v4_bytes[0], v4_bytes[1], v4_bytes[2], v4_bytes[3] } }; > return address_v6(v6_bytes); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 299 "/usr/include/boost/asio/ip/impl/address_v6.ipp" 2 3 4 ># 246 "/usr/include/boost/asio/ip/address_v6.hpp" 2 3 4 ># 23 "/usr/include/boost/asio/ip/address.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/ip/address.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 43 "/usr/include/boost/asio/ip/address.hpp" 3 4 >class address >{ >public: > > inline address(); > > > inline address(const boost::asio::ip::address_v4& ipv4_address); > > > inline address(const boost::asio::ip::address_v6& ipv6_address); > > > inline address(const address& other); > > > > inline address(address&& other); > > > > inline address& operator=(const address& other); > > > > inline address& operator=(address&& other); > > > > inline address& operator=( > const boost::asio::ip::address_v4& ipv4_address); > > > inline address& operator=( > const boost::asio::ip::address_v6& ipv6_address); > > > bool is_v4() const > { > return type_ == ipv4; > } > > > bool is_v6() const > { > return type_ == ipv6; > } > > > inline boost::asio::ip::address_v4 to_v4() const; > > > inline boost::asio::ip::address_v6 to_v6() const; > > > inline std::string to_string() const; > > > inline std::string to_string(boost::system::error_code& ec) const; > > > > inline static address from_string(const char* str); > > > > inline static address from_string( > const char* str, boost::system::error_code& ec); > > > > inline static address from_string(const std::string& str); > > > > inline static address from_string( > const std::string& str, boost::system::error_code& ec); > > > inline bool is_loopback() const; > > > inline bool is_unspecified() const; > > > inline bool is_multicast() const; > > > inline friend bool operator==(const address& a1, const address& a2); > > > friend bool operator!=(const address& a1, const address& a2) > { > return !(a1 == a2); > } > > > inline friend bool operator<(const address& a1, const address& a2); > > > friend bool operator>(const address& a1, const address& a2) > { > return a2 < a1; > } > > > friend bool operator<=(const address& a1, const address& a2) > { > return !(a2 < a1); > } > > > friend bool operator>=(const address& a1, const address& a2) > { > return !(a1 < a2); > } > >private: > > enum { ipv4, ipv6 } type_; > > > boost::asio::ip::address_v4 ipv4_address_; > > > boost::asio::ip::address_v6 ipv6_address_; >}; ># 185 "/usr/include/boost/asio/ip/address.hpp" 3 4 >template <typename Elem, typename Traits> >std::basic_ostream<Elem, Traits>& operator<<( > std::basic_ostream<Elem, Traits>& os, const address& addr); > > > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 196 "/usr/include/boost/asio/ip/address.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/ip/impl/address.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/impl/address.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/impl/address.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > >template <typename Elem, typename Traits> >std::basic_ostream<Elem, Traits>& operator<<( > std::basic_ostream<Elem, Traits>& os, const address& addr) >{ > boost::system::error_code ec; > std::string s = addr.to_string(ec); > if (ec) > { > if (os.exceptions() & std::basic_ostream<Elem, Traits>::failbit) > boost::asio::detail::throw_error(ec); > else > os.setstate(std::basic_ostream<Elem, Traits>::failbit); > } > else > for (std::string::iterator i = s.begin(); i != s.end(); ++i) > os << os.widen(*i); > return os; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 52 "/usr/include/boost/asio/ip/impl/address.hpp" 2 3 4 ># 198 "/usr/include/boost/asio/ip/address.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/ip/impl/address.ipp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/impl/address.ipp" 3 4 ># 1 "/usr/include/boost/asio/ip/address.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/ip/impl/address.ipp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/ip/impl/address.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > >address::address() > : type_(ipv4), > ipv4_address_(), > ipv6_address_() >{ >} > >address::address(const boost::asio::ip::address_v4& ipv4_address) > : type_(ipv4), > ipv4_address_(ipv4_address), > ipv6_address_() >{ >} > >address::address(const boost::asio::ip::address_v6& ipv6_address) > : type_(ipv6), > ipv4_address_(), > ipv6_address_(ipv6_address) >{ >} > >address::address(const address& other) > : type_(other.type_), > ipv4_address_(other.ipv4_address_), > ipv6_address_(other.ipv6_address_) >{ >} > > >address::address(address&& other) > : type_(other.type_), > ipv4_address_(other.ipv4_address_), > ipv6_address_(other.ipv6_address_) >{ >} > > >address& address::operator=(const address& other) >{ > type_ = other.type_; > ipv4_address_ = other.ipv4_address_; > ipv6_address_ = other.ipv6_address_; > return *this; >} > > >address& address::operator=(address&& other) >{ > type_ = other.type_; > ipv4_address_ = other.ipv4_address_; > ipv6_address_ = other.ipv6_address_; > return *this; >} > > >address& address::operator=(const boost::asio::ip::address_v4& ipv4_address) >{ > type_ = ipv4; > ipv4_address_ = ipv4_address; > ipv6_address_ = boost::asio::ip::address_v6(); > return *this; >} > >address& address::operator=(const boost::asio::ip::address_v6& ipv6_address) >{ > type_ = ipv6; > ipv4_address_ = boost::asio::ip::address_v4(); > ipv6_address_ = ipv6_address; > return *this; >} > >boost::asio::ip::address_v4 address::to_v4() const >{ > if (type_ != ipv4) > { > std::bad_cast ex; > boost::asio::detail::throw_exception(ex); > } > return ipv4_address_; >} > >boost::asio::ip::address_v6 address::to_v6() const >{ > if (type_ != ipv6) > { > std::bad_cast ex; > boost::asio::detail::throw_exception(ex); > } > return ipv6_address_; >} > >std::string address::to_string() const >{ > if (type_ == ipv6) > return ipv6_address_.to_string(); > return ipv4_address_.to_string(); >} > >std::string address::to_string(boost::system::error_code& ec) const >{ > if (type_ == ipv6) > return ipv6_address_.to_string(ec); > return ipv4_address_.to_string(ec); >} > >address address::from_string(const char* str) >{ > boost::system::error_code ec; > address addr = from_string(str, ec); > boost::asio::detail::throw_error(ec); > return addr; >} > >address address::from_string(const char* str, boost::system::error_code& ec) >{ > boost::asio::ip::address_v6 ipv6_address = > boost::asio::ip::address_v6::from_string(str, ec); > if (!ec) > { > address tmp; > tmp.type_ = ipv6; > tmp.ipv6_address_ = ipv6_address; > return tmp; > } > > boost::asio::ip::address_v4 ipv4_address = > boost::asio::ip::address_v4::from_string(str, ec); > if (!ec) > { > address tmp; > tmp.type_ = ipv4; > tmp.ipv4_address_ = ipv4_address; > return tmp; > } > > return address(); >} > >address address::from_string(const std::string& str) >{ > return from_string(str.c_str()); >} > >address address::from_string(const std::string& str, > boost::system::error_code& ec) >{ > return from_string(str.c_str(), ec); >} > >bool address::is_loopback() const >{ > return (type_ == ipv4) > ? ipv4_address_.is_loopback() > : ipv6_address_.is_loopback(); >} > >bool address::is_unspecified() const >{ > return (type_ == ipv4) > ? ipv4_address_.is_unspecified() > : ipv6_address_.is_unspecified(); >} > >bool address::is_multicast() const >{ > return (type_ == ipv4) > ? ipv4_address_.is_multicast() > : ipv6_address_.is_multicast(); >} > >bool operator==(const address& a1, const address& a2) >{ > if (a1.type_ != a2.type_) > return false; > if (a1.type_ == address::ipv6) > return a1.ipv6_address_ == a2.ipv6_address_; > return a1.ipv4_address_ == a2.ipv4_address_; >} > >bool operator<(const address& a1, const address& a2) >{ > if (a1.type_ < a2.type_) > return true; > if (a1.type_ > a2.type_) > return false; > if (a1.type_ == address::ipv6) > return a1.ipv6_address_ < a2.ipv6_address_; > return a1.ipv4_address_ < a2.ipv4_address_; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 227 "/usr/include/boost/asio/ip/impl/address.ipp" 2 3 4 ># 200 "/usr/include/boost/asio/ip/address.hpp" 2 3 4 ># 60 "/usr/include/boost/asio.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/ip/basic_endpoint.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/ip/basic_endpoint.hpp" 3 4 ># 1 "/usr/include/boost/asio/ip/detail/endpoint.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/ip/detail/endpoint.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/ip/detail/endpoint.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { >namespace detail { > > >class endpoint >{ >public: > > inline endpoint(); > > > inline endpoint(int family, unsigned short port_num); > > > inline endpoint(const boost::asio::ip::address& addr, > unsigned short port_num); > > > endpoint(const endpoint& other) > : data_(other.data_) > { > } > > > endpoint& operator=(const endpoint& other) > { > data_ = other.data_; > return *this; > } > > > boost::asio::detail::socket_addr_type* data() > { > return &data_.base; > } > > > const boost::asio::detail::socket_addr_type* data() const > { > return &data_.base; > } > > > std::size_t size() const > { > if (is_v4()) > return sizeof(boost::asio::detail::sockaddr_in4_type); > else > return sizeof(boost::asio::detail::sockaddr_in6_type); > } > > > inline void resize(std::size_t new_size); > > > std::size_t capacity() const > { > return sizeof(data_); > } > > > inline unsigned short port() const; > > > inline void port(unsigned short port_num); > > > inline boost::asio::ip::address address() const; > > > inline void address(const boost::asio::ip::address& addr); > > > inline friend bool operator==( > const endpoint& e1, const endpoint& e2); > > > inline friend bool operator<( > const endpoint& e1, const endpoint& e2); > > > bool is_v4() const > { > return data_.base.sa_family == 2; > } > > > > inline std::string to_string(boost::system::error_code& ec) const; > > >private: > > union data_union > { > boost::asio::detail::socket_addr_type base; > boost::asio::detail::sockaddr_in4_type v4; > boost::asio::detail::sockaddr_in6_type v6; > } data_; >}; > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 136 "/usr/include/boost/asio/ip/detail/endpoint.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/ip/detail/impl/endpoint.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/ip/detail/impl/endpoint.ipp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 20 "/usr/include/boost/asio/ip/detail/impl/endpoint.ipp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/ip/detail/endpoint.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/ip/detail/impl/endpoint.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/ip/detail/impl/endpoint.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { >namespace detail { > >endpoint::endpoint() > : data_() >{ > data_.v4.sin_family = 2; > data_.v4.sin_port = 0; > data_.v4.sin_addr.s_addr = ((in_addr_t) 0x00000000); >} > >endpoint::endpoint(int family, unsigned short port_num) > : data_() >{ > using namespace std; > if (family == 2) > { > data_.v4.sin_family = 2; > data_.v4.sin_port = > boost::asio::detail::socket_ops::host_to_network_short(port_num); > data_.v4.sin_addr.s_addr = ((in_addr_t) 0x00000000); > } > else > { > data_.v6.sin6_family = 10; > data_.v6.sin6_port = > boost::asio::detail::socket_ops::host_to_network_short(port_num); > data_.v6.sin6_flowinfo = 0; > data_.v6.sin6_addr.__in6_u.__u6_addr8[0] = 0; data_.v6.sin6_addr.__in6_u.__u6_addr8[1] = 0; > data_.v6.sin6_addr.__in6_u.__u6_addr8[2] = 0, data_.v6.sin6_addr.__in6_u.__u6_addr8[3] = 0; > data_.v6.sin6_addr.__in6_u.__u6_addr8[4] = 0, data_.v6.sin6_addr.__in6_u.__u6_addr8[5] = 0; > data_.v6.sin6_addr.__in6_u.__u6_addr8[6] = 0, data_.v6.sin6_addr.__in6_u.__u6_addr8[7] = 0; > data_.v6.sin6_addr.__in6_u.__u6_addr8[8] = 0, data_.v6.sin6_addr.__in6_u.__u6_addr8[9] = 0; > data_.v6.sin6_addr.__in6_u.__u6_addr8[10] = 0, data_.v6.sin6_addr.__in6_u.__u6_addr8[11] = 0; > data_.v6.sin6_addr.__in6_u.__u6_addr8[12] = 0, data_.v6.sin6_addr.__in6_u.__u6_addr8[13] = 0; > data_.v6.sin6_addr.__in6_u.__u6_addr8[14] = 0, data_.v6.sin6_addr.__in6_u.__u6_addr8[15] = 0; > data_.v6.sin6_scope_id = 0; > } >} > >endpoint::endpoint(const boost::asio::ip::address& addr, > unsigned short port_num) > : data_() >{ > using namespace std; > if (addr.is_v4()) > { > data_.v4.sin_family = 2; > data_.v4.sin_port = > boost::asio::detail::socket_ops::host_to_network_short(port_num); > data_.v4.sin_addr.s_addr = > boost::asio::detail::socket_ops::host_to_network_long( > static_cast<boost::asio::detail::u_long_type>( > addr.to_v4().to_ulong())); > } > else > { > data_.v6.sin6_family = 10; > data_.v6.sin6_port = > boost::asio::detail::socket_ops::host_to_network_short(port_num); > data_.v6.sin6_flowinfo = 0; > boost::asio::ip::address_v6 v6_addr = addr.to_v6(); > boost::asio::ip::address_v6::bytes_type bytes = v6_addr.to_bytes(); > memcpy(data_.v6.sin6_addr.__in6_u.__u6_addr8, bytes.data(), 16); > data_.v6.sin6_scope_id = > static_cast<boost::asio::detail::u_long_type>( > v6_addr.scope_id()); > } >} > >void endpoint::resize(std::size_t new_size) >{ > if (new_size > sizeof(boost::asio::detail::sockaddr_storage_type)) > { > boost::system::error_code ec(boost::asio::error::invalid_argument); > boost::asio::detail::throw_error(ec); > } >} > >unsigned short endpoint::port() const >{ > if (is_v4()) > { > return boost::asio::detail::socket_ops::network_to_host_short( > data_.v4.sin_port); > } > else > { > return boost::asio::detail::socket_ops::network_to_host_short( > data_.v6.sin6_port); > } >} > >void endpoint::port(unsigned short port_num) >{ > if (is_v4()) > { > data_.v4.sin_port > = boost::asio::detail::socket_ops::host_to_network_short(port_num); > } > else > { > data_.v6.sin6_port > = boost::asio::detail::socket_ops::host_to_network_short(port_num); > } >} > >boost::asio::ip::address endpoint::address() const >{ > using namespace std; > if (is_v4()) > { > return boost::asio::ip::address_v4( > boost::asio::detail::socket_ops::network_to_host_long( > data_.v4.sin_addr.s_addr)); > } > else > { > boost::asio::ip::address_v6::bytes_type bytes; > > memcpy(bytes.data(), data_.v6.sin6_addr.__in6_u.__u6_addr8, 16); > > > > return boost::asio::ip::address_v6(bytes, data_.v6.sin6_scope_id); > } >} > >void endpoint::address(const boost::asio::ip::address& addr) >{ > endpoint tmp_endpoint(addr, port()); > data_ = tmp_endpoint.data_; >} > >bool operator==(const endpoint& e1, const endpoint& e2) >{ > return e1.address() == e2.address() && e1.port() == e2.port(); >} > >bool operator<(const endpoint& e1, const endpoint& e2) >{ > if (e1.address() < e2.address()) > return true; > if (e1.address() != e2.address()) > return false; > return e1.port() < e2.port(); >} > > >std::string endpoint::to_string(boost::system::error_code& ec) const >{ > std::string a = address().to_string(ec); > if (ec) > return std::string(); > > std::ostringstream tmp_os; > tmp_os.imbue(std::locale::classic()); > if (is_v4()) > tmp_os << a; > else > tmp_os << '[' << a << ']'; > tmp_os << ':' << port(); > > return tmp_os.str(); >} > > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 205 "/usr/include/boost/asio/ip/detail/impl/endpoint.ipp" 2 3 4 ># 139 "/usr/include/boost/asio/ip/detail/endpoint.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/ip/basic_endpoint.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/ip/basic_endpoint.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 44 "/usr/include/boost/asio/ip/basic_endpoint.hpp" 3 4 >template <typename InternetProtocol> >class basic_endpoint >{ >public: > > typedef InternetProtocol protocol_type; > > > > > > > typedef boost::asio::detail::socket_addr_type data_type; > > > > basic_endpoint() > : impl_() > { > } ># 81 "/usr/include/boost/asio/ip/basic_endpoint.hpp" 3 4 > basic_endpoint(const InternetProtocol& internet_protocol, > unsigned short port_num) > : impl_(internet_protocol.family(), port_num) > { > } > > > > > basic_endpoint(const boost::asio::ip::address& addr, unsigned short port_num) > : impl_(addr, port_num) > { > } > > > basic_endpoint(const basic_endpoint& other) > : impl_(other.impl_) > { > } > > > > basic_endpoint(basic_endpoint&& other) > : impl_(other.impl_) > { > } > > > > basic_endpoint& operator=(const basic_endpoint& other) > { > impl_ = other.impl_; > return *this; > } > > > > basic_endpoint& operator=(basic_endpoint&& other) > { > impl_ = other.impl_; > return *this; > } > > > > protocol_type protocol() const > { > if (impl_.is_v4()) > return InternetProtocol::v4(); > return InternetProtocol::v6(); > } > > > data_type* data() > { > return impl_.data(); > } > > > const data_type* data() const > { > return impl_.data(); > } > > > std::size_t size() const > { > return impl_.size(); > } > > > void resize(std::size_t new_size) > { > impl_.resize(new_size); > } > > > std::size_t capacity() const > { > return impl_.capacity(); > } > > > > unsigned short port() const > { > return impl_.port(); > } > > > > void port(unsigned short port_num) > { > impl_.port(port_num); > } > > > boost::asio::ip::address address() const > { > return impl_.address(); > } > > > void address(const boost::asio::ip::address& addr) > { > impl_.address(addr); > } > > > friend bool operator==(const basic_endpoint<InternetProtocol>& e1, > const basic_endpoint<InternetProtocol>& e2) > { > return e1.impl_ == e2.impl_; > } > > > friend bool operator!=(const basic_endpoint<InternetProtocol>& e1, > const basic_endpoint<InternetProtocol>& e2) > { > return !(e1 == e2); > } > > > friend bool operator<(const basic_endpoint<InternetProtocol>& e1, > const basic_endpoint<InternetProtocol>& e2) > { > return e1.impl_ < e2.impl_; > } > > > friend bool operator>(const basic_endpoint<InternetProtocol>& e1, > const basic_endpoint<InternetProtocol>& e2) > { > return e2.impl_ < e1.impl_; > } > > > friend bool operator<=(const basic_endpoint<InternetProtocol>& e1, > const basic_endpoint<InternetProtocol>& e2) > { > return !(e2 < e1); > } > > > friend bool operator>=(const basic_endpoint<InternetProtocol>& e1, > const basic_endpoint<InternetProtocol>& e2) > { > return !(e1 < e2); > } > >private: > > boost::asio::ip::detail::endpoint impl_; >}; ># 250 "/usr/include/boost/asio/ip/basic_endpoint.hpp" 3 4 >template <typename Elem, typename Traits, typename InternetProtocol> >std::basic_ostream<Elem, Traits>& operator<<( > std::basic_ostream<Elem, Traits>& os, > const basic_endpoint<InternetProtocol>& endpoint); > > > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 262 "/usr/include/boost/asio/ip/basic_endpoint.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/ip/impl/basic_endpoint.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/impl/basic_endpoint.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/impl/basic_endpoint.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > >template <typename Elem, typename Traits, typename InternetProtocol> >std::basic_ostream<Elem, Traits>& operator<<( > std::basic_ostream<Elem, Traits>& os, > const basic_endpoint<InternetProtocol>& endpoint) >{ > boost::asio::ip::detail::endpoint tmp_ep(endpoint.address(), endpoint.port()); > boost::system::error_code ec; > std::string s = tmp_ep.to_string(ec); > if (ec) > { > if (os.exceptions() & std::basic_ostream<Elem, Traits>::failbit) > boost::asio::detail::throw_error(ec); > else > os.setstate(std::basic_ostream<Elem, Traits>::failbit); > } > else > for (std::string::iterator i = s.begin(); i != s.end(); ++i) > os << os.widen(*i); > return os; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 54 "/usr/include/boost/asio/ip/impl/basic_endpoint.hpp" 2 3 4 ># 264 "/usr/include/boost/asio/ip/basic_endpoint.hpp" 2 3 4 ># 63 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/ip/basic_resolver.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/basic_resolver.hpp" 3 4 ># 1 "/usr/include/boost/asio/ip/basic_resolver_iterator.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/ip/basic_resolver_iterator.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 21 "/usr/include/boost/asio/ip/basic_resolver_iterator.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/ip/basic_resolver_entry.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/ip/basic_resolver_entry.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/basic_resolver_entry.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 36 "/usr/include/boost/asio/ip/basic_resolver_entry.hpp" 3 4 >template <typename InternetProtocol> >class basic_resolver_entry >{ >public: > > typedef InternetProtocol protocol_type; > > > typedef typename InternetProtocol::endpoint endpoint_type; > > > basic_resolver_entry() > { > } > > > basic_resolver_entry(const endpoint_type& ep, > const std::string& host, const std::string& service) > : endpoint_(ep), > host_name_(host), > service_name_(service) > { > } > > > endpoint_type endpoint() const > { > return endpoint_; > } > > > operator endpoint_type() const > { > return endpoint_; > } > > > std::string host_name() const > { > return host_name_; > } > > > std::string service_name() const > { > return service_name_; > } > >private: > endpoint_type endpoint_; > std::string host_name_; > std::string service_name_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 95 "/usr/include/boost/asio/ip/basic_resolver_entry.hpp" 2 3 4 ># 28 "/usr/include/boost/asio/ip/basic_resolver_iterator.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 34 "/usr/include/boost/asio/ip/basic_resolver_iterator.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 51 "/usr/include/boost/asio/ip/basic_resolver_iterator.hpp" 3 4 >template <typename InternetProtocol> >class basic_resolver_iterator >{ >public: > > typedef std::ptrdiff_t difference_type; > > > typedef basic_resolver_entry<InternetProtocol> value_type; > > > typedef const basic_resolver_entry<InternetProtocol>* pointer; > > > typedef const basic_resolver_entry<InternetProtocol>& reference; > > > typedef std::forward_iterator_tag iterator_category; > > > basic_resolver_iterator() > : index_(0) > { > } > > > static basic_resolver_iterator create( > boost::asio::detail::addrinfo_type* address_info, > const std::string& host_name, const std::string& service_name) > { > basic_resolver_iterator iter; > if (!address_info) > return iter; > > std::string actual_host_name = host_name; > if (address_info->ai_canonname) > actual_host_name = address_info->ai_canonname; > > iter.values_.reset(new values_type); > > while (address_info) > { > if (address_info->ai_family == 2 > || address_info->ai_family == 10) > { > using namespace std; > typename InternetProtocol::endpoint endpoint; > endpoint.resize(static_cast<std::size_t>(address_info->ai_addrlen)); > memcpy(endpoint.data(), address_info->ai_addr, > address_info->ai_addrlen); > iter.values_->push_back( > basic_resolver_entry<InternetProtocol>(endpoint, > actual_host_name, service_name)); > } > address_info = address_info->ai_next; > } > > return iter; > } > > > static basic_resolver_iterator create( > const typename InternetProtocol::endpoint& endpoint, > const std::string& host_name, const std::string& service_name) > { > basic_resolver_iterator iter; > iter.values_.reset(new values_type); > iter.values_->push_back( > basic_resolver_entry<InternetProtocol>( > endpoint, host_name, service_name)); > return iter; > } > > > template <typename EndpointIterator> > static basic_resolver_iterator create( > EndpointIterator begin, EndpointIterator end, > const std::string& host_name, const std::string& service_name) > { > basic_resolver_iterator iter; > if (begin != end) > { > iter.values_.reset(new values_type); > for (EndpointIterator ep_iter = begin; ep_iter != end; ++ep_iter) > { > iter.values_->push_back( > basic_resolver_entry<InternetProtocol>( > *ep_iter, host_name, service_name)); > } > } > return iter; > } ># 186 "/usr/include/boost/asio/ip/basic_resolver_iterator.hpp" 3 4 > const basic_resolver_entry<InternetProtocol>& operator*() const > { > return dereference(); > } > > > const basic_resolver_entry<InternetProtocol>* operator->() const > { > return &dereference(); > } > > > basic_resolver_iterator& operator++() > { > increment(); > return *this; > } > > > basic_resolver_iterator operator++(int) > { > basic_resolver_iterator tmp(*this); > ++*this; > return tmp; > } > > > friend bool operator==(const basic_resolver_iterator& a, > const basic_resolver_iterator& b) > { > return a.equal(b); > } > > > friend bool operator!=(const basic_resolver_iterator& a, > const basic_resolver_iterator& b) > { > return !a.equal(b); > } > >private: > void increment() > { > if (++index_ == values_->size()) > { > > values_.reset(); > index_ = 0; > } > } > > bool equal(const basic_resolver_iterator& other) const > { > if (!values_ && !other.values_) > return true; > if (values_ != other.values_) > return false; > return index_ == other.index_; > } > > const basic_resolver_entry<InternetProtocol>& dereference() const > { > return (*values_)[index_]; > } > > typedef std::vector<basic_resolver_entry<InternetProtocol> > values_type; > boost::asio::detail::shared_ptr<values_type> values_; > std::size_t index_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 261 "/usr/include/boost/asio/ip/basic_resolver_iterator.hpp" 2 3 4 ># 24 "/usr/include/boost/asio/ip/basic_resolver.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 3 4 ># 1 "/usr/include/boost/asio/ip/resolver_query_base.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/ip/resolver_query_base.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/resolver_query_base.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > > > > >class resolver_query_base >{ >public: ># 64 "/usr/include/boost/asio/ip/resolver_query_base.hpp" 3 4 > enum flags > { > canonical_name = 0x0002, > passive = 0x0001, > numeric_host = 0x0004, > numeric_service = 0x0400, > v4_mapped = 0x0008, > all_matching = 0x0010, > address_configured = 0x0020 > }; > > > > friend flags operator&(flags x, flags y) > { > return static_cast<flags>( > static_cast<unsigned int>(x) & static_cast<unsigned int>(y)); > } > > friend flags operator|(flags x, flags y) > { > return static_cast<flags>( > static_cast<unsigned int>(x) | static_cast<unsigned int>(y)); > } > > friend flags operator^(flags x, flags y) > { > return static_cast<flags>( > static_cast<unsigned int>(x) ^ static_cast<unsigned int>(y)); > } > > friend flags operator~(flags x) > { > return static_cast<flags>(static_cast<unsigned int>(~x)); > } > > friend flags& operator&=(flags& x, flags y) > { > x = x & y; > return x; > } > > friend flags& operator|=(flags& x, flags y) > { > x = x | y; > return x; > } > > friend flags& operator^=(flags& x, flags y) > { > x = x ^ y; > return x; > } > > >protected: > > ~resolver_query_base() > { > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 131 "/usr/include/boost/asio/ip/resolver_query_base.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 38 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 3 4 >template <typename InternetProtocol> >class basic_resolver_query > : public resolver_query_base >{ >public: > > typedef InternetProtocol protocol_type; ># 63 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 3 4 > basic_resolver_query(const std::string& service, > resolver_query_base::flags resolve_flags = passive | address_configured) > : hints_(), > host_name_(), > service_name_(service) > { > typename InternetProtocol::endpoint endpoint; > hints_.ai_flags = static_cast<int>(resolve_flags); > hints_.ai_family = 0; > hints_.ai_socktype = endpoint.protocol().type(); > hints_.ai_protocol = endpoint.protocol().protocol(); > hints_.ai_addrlen = 0; > hints_.ai_canonname = 0; > hints_.ai_addr = 0; > hints_.ai_next = 0; > } ># 100 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 3 4 > basic_resolver_query(const protocol_type& protocol, > const std::string& service, > resolver_query_base::flags resolve_flags = passive | address_configured) > : hints_(), > host_name_(), > service_name_(service) > { > hints_.ai_flags = static_cast<int>(resolve_flags); > hints_.ai_family = protocol.family(); > hints_.ai_socktype = protocol.type(); > hints_.ai_protocol = protocol.protocol(); > hints_.ai_addrlen = 0; > hints_.ai_canonname = 0; > hints_.ai_addr = 0; > hints_.ai_next = 0; > } ># 148 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 3 4 > basic_resolver_query(const std::string& host, const std::string& service, > resolver_query_base::flags resolve_flags = address_configured) > : hints_(), > host_name_(host), > service_name_(service) > { > typename InternetProtocol::endpoint endpoint; > hints_.ai_flags = static_cast<int>(resolve_flags); > hints_.ai_family = 0; > hints_.ai_socktype = endpoint.protocol().type(); > hints_.ai_protocol = endpoint.protocol().protocol(); > hints_.ai_addrlen = 0; > hints_.ai_canonname = 0; > hints_.ai_addr = 0; > hints_.ai_next = 0; > } ># 199 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 3 4 > basic_resolver_query(const protocol_type& protocol, > const std::string& host, const std::string& service, > resolver_query_base::flags resolve_flags = address_configured) > : hints_(), > host_name_(host), > service_name_(service) > { > hints_.ai_flags = static_cast<int>(resolve_flags); > hints_.ai_family = protocol.family(); > hints_.ai_socktype = protocol.type(); > hints_.ai_protocol = protocol.protocol(); > hints_.ai_addrlen = 0; > hints_.ai_canonname = 0; > hints_.ai_addr = 0; > hints_.ai_next = 0; > } > > > const boost::asio::detail::addrinfo_type& hints() const > { > return hints_; > } > > > std::string host_name() const > { > return host_name_; > } > > > std::string service_name() const > { > return service_name_; > } > >private: > boost::asio::detail::addrinfo_type hints_; > std::string host_name_; > std::string service_name_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 245 "/usr/include/boost/asio/ip/basic_resolver_query.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/ip/basic_resolver.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/ip/resolver_service.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/ip/resolver_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/resolver_service.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/resolver_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/resolve_endpoint_op.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/detail/resolve_endpoint_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/detail/resolve_endpoint_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Protocol, typename Handler> >class resolve_endpoint_op : public operation >{ >public: > struct ptr { Handler* h; void* v; resolve_endpoint_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~resolve_endpoint_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(resolve_endpoint_op), *h); v = 0; } } }; > > typedef typename Protocol::endpoint endpoint_type; > typedef boost::asio::ip::basic_resolver_iterator<Protocol> iterator_type; > > resolve_endpoint_op(socket_ops::weak_cancel_token_type cancel_token, > const endpoint_type& endpoint, io_service_impl& ios, Handler& handler) > : operation(&resolve_endpoint_op::do_complete), > cancel_token_(cancel_token), > endpoint_(endpoint), > io_service_impl_(ios), > handler_(static_cast<Handler&&>(handler)) > { > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > resolve_endpoint_op* o(static_cast<resolve_endpoint_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > if (owner && owner != &o->io_service_impl_) > { > > > > > char host_name[1025]; > char service_name[32]; > socket_ops::background_getnameinfo(o->cancel_token_, o->endpoint_.data(), > o->endpoint_.size(), host_name, 1025, service_name, 32, > o->endpoint_.protocol().type(), o->ec_); > o->iter_ = iterator_type::create(o->endpoint_, host_name, service_name); > > > o->io_service_impl_.post_deferred_completion(o); > p.v = p.p = 0; > } > else > { > > > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, iterator_type> > handler(o->handler_, o->ec_, o->iter_); > p.h = boost::asio::detail::addressof(handler.handler_); > p.reset(); > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > } > >private: > socket_ops::weak_cancel_token_type cancel_token_; > endpoint_type endpoint_; > io_service_impl& io_service_impl_; > Handler handler_; > boost::system::error_code ec_; > iterator_type iter_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 122 "/usr/include/boost/asio/detail/resolve_endpoint_op.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/detail/resolver_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/resolve_op.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/detail/resolve_op.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/detail/resolve_op.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Protocol, typename Handler> >class resolve_op : public operation >{ >public: > struct ptr { Handler* h; void* v; resolve_op* p; ~ptr() { reset(); } void reset() { if (p) { p->~resolve_op(); p = 0; } if (v) { boost_asio_handler_alloc_helpers::deallocate(v, sizeof(resolve_op), *h); v = 0; } } }; > > typedef boost::asio::ip::basic_resolver_query<Protocol> query_type; > typedef boost::asio::ip::basic_resolver_iterator<Protocol> iterator_type; > > resolve_op(socket_ops::weak_cancel_token_type cancel_token, > const query_type& query, io_service_impl& ios, Handler& handler) > : operation(&resolve_op::do_complete), > cancel_token_(cancel_token), > query_(query), > io_service_impl_(ios), > handler_(static_cast<Handler&&>(handler)), > addrinfo_(0) > { > } > > ~resolve_op() > { > if (addrinfo_) > socket_ops::freeaddrinfo(addrinfo_); > } > > static void do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& , > std::size_t ) > { > > resolve_op* o(static_cast<resolve_op*>(base)); > ptr p = { boost::asio::detail::addressof(o->handler_), o, o }; > > if (owner && owner != &o->io_service_impl_) > { > > > > > socket_ops::background_getaddrinfo(o->cancel_token_, > o->query_.host_name().c_str(), o->query_.service_name().c_str(), > o->query_.hints(), &o->addrinfo_, o->ec_); > > > o->io_service_impl_.post_deferred_completion(o); > p.v = p.p = 0; > } > else > { > > > > (void)0; > > > > > > > > detail::binder2<Handler, boost::system::error_code, iterator_type> > handler(o->handler_, o->ec_, iterator_type()); > p.h = boost::asio::detail::addressof(handler.handler_); > if (o->addrinfo_) > { > handler.arg2_ = iterator_type::create(o->addrinfo_, > o->query_.host_name(), o->query_.service_name()); > } > p.reset(); > > if (owner) > { > fenced_block b(fenced_block::half); > (void)0; > boost_asio_handler_invoke_helpers::invoke(handler, handler.handler_); > (void)0; > } > } > } > >private: > socket_ops::weak_cancel_token_type cancel_token_; > query_type query_; > io_service_impl& io_service_impl_; > Handler handler_; > boost::system::error_code ec_; > boost::asio::detail::addrinfo_type* addrinfo_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 132 "/usr/include/boost/asio/detail/resolve_op.hpp" 2 3 4 ># 27 "/usr/include/boost/asio/detail/resolver_service.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/detail/resolver_service_base.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/resolver_service_base.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/thread.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/detail/thread.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/posix_thread.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/posix_thread.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/posix_thread.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >extern "C" >{ > inline void* boost_asio_detail_posix_thread_function(void* arg); >} > >class posix_thread > : private noncopyable >{ >public: > > template <typename Function> > posix_thread(Function f, unsigned int = 0) > : joined_(false) > { > start_thread(new func<Function>(f)); > } > > > inline ~posix_thread(); > > > inline void join(); > >private: > friend void* boost_asio_detail_posix_thread_function(void* arg); > > class func_base > { > public: > virtual ~func_base() {} > virtual void run() = 0; > }; > > struct auto_func_base_ptr > { > func_base* ptr; > ~auto_func_base_ptr() { delete ptr; } > }; > > template <typename Function> > class func > : public func_base > { > public: > func(Function f) > : f_(f) > { > } > > virtual void run() > { > f_(); > } > > private: > Function f_; > }; > > inline void start_thread(func_base* arg); > > ::pthread_t thread_; > bool joined_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 100 "/usr/include/boost/asio/detail/posix_thread.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/posix_thread.ipp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/impl/posix_thread.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/posix_thread.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/impl/posix_thread.ipp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/detail/impl/posix_thread.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >posix_thread::~posix_thread() >{ > if (!joined_) > ::pthread_detach(thread_); >} > >void posix_thread::join() >{ > if (!joined_) > { > ::pthread_join(thread_, 0); > joined_ = true; > } >} > >void posix_thread::start_thread(func_base* arg) >{ > int error = ::pthread_create(&thread_, 0, > boost_asio_detail_posix_thread_function, arg); > if (error != 0) > { > delete arg; > boost::system::error_code ec(error, > boost::asio::error::get_system_category()); > boost::asio::detail::throw_error(ec, "thread"); > } >} > >void* boost_asio_detail_posix_thread_function(void* arg) >{ > posix_thread::auto_func_base_ptr func = { > static_cast<posix_thread::func_base*>(arg) }; > func.ptr->run(); > return 0; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 73 "/usr/include/boost/asio/detail/impl/posix_thread.ipp" 2 3 4 ># 103 "/usr/include/boost/asio/detail/posix_thread.hpp" 2 3 4 ># 30 "/usr/include/boost/asio/detail/thread.hpp" 2 3 4 > > > > > > >namespace boost { >namespace asio { >namespace detail { ># 49 "/usr/include/boost/asio/detail/thread.hpp" 3 4 >typedef posix_thread thread; > > > > >} >} >} ># 28 "/usr/include/boost/asio/detail/resolver_service_base.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/detail/resolver_service_base.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class resolver_service_base >{ >public: > > > typedef socket_ops::shared_cancel_token_type implementation_type; > > > inline resolver_service_base(boost::asio::io_service& io_service); > > > inline ~resolver_service_base(); > > > inline void shutdown_service(); > > > inline void fork_service( > boost::asio::io_service::fork_event fork_ev); > > > inline void construct(implementation_type& impl); > > > inline void destroy(implementation_type&); > > > inline void cancel(implementation_type& impl); > >protected: > > inline void start_resolve_op(operation* op); > > > > class auto_addrinfo > : private boost::asio::detail::noncopyable > { > public: > explicit auto_addrinfo(boost::asio::detail::addrinfo_type* ai) > : ai_(ai) > { > } > > ~auto_addrinfo() > { > if (ai_) > socket_ops::freeaddrinfo(ai_); > } > > operator boost::asio::detail::addrinfo_type*() > { > return ai_; > } > > private: > boost::asio::detail::addrinfo_type* ai_; > }; > > > > class work_io_service_runner; > > > inline void start_work_thread(); > > > io_service_impl& io_service_impl_; > >private: > > boost::asio::detail::mutex mutex_; > > > boost::asio::detail::scoped_ptr<boost::asio::io_service> work_io_service_; > > > io_service_impl& work_io_service_impl_; > > > boost::asio::detail::scoped_ptr<boost::asio::io_service::work> work_; > > > boost::asio::detail::scoped_ptr<boost::asio::detail::thread> work_thread_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 126 "/usr/include/boost/asio/detail/resolver_service_base.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/impl/resolver_service_base.ipp" 1 3 4 ># 19 "/usr/include/boost/asio/detail/impl/resolver_service_base.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/resolver_service_base.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/impl/resolver_service_base.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/detail/impl/resolver_service_base.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >class resolver_service_base::work_io_service_runner >{ >public: > work_io_service_runner(boost::asio::io_service& io_service) > : io_service_(io_service) {} > void operator()() { io_service_.run(); } >private: > boost::asio::io_service& io_service_; >}; > >resolver_service_base::resolver_service_base( > boost::asio::io_service& io_service) > : io_service_impl_(boost::asio::use_service<io_service_impl>(io_service)), > work_io_service_(new boost::asio::io_service), > work_io_service_impl_(boost::asio::use_service< > io_service_impl>(*work_io_service_)), > work_(new boost::asio::io_service::work(*work_io_service_)), > work_thread_(0) >{ >} > >resolver_service_base::~resolver_service_base() >{ > shutdown_service(); >} > >void resolver_service_base::shutdown_service() >{ > work_.reset(); > if (work_io_service_.get()) > { > work_io_service_->stop(); > if (work_thread_.get()) > { > work_thread_->join(); > work_thread_.reset(); > } > work_io_service_.reset(); > } >} > >void resolver_service_base::fork_service( > boost::asio::io_service::fork_event fork_ev) >{ > if (work_thread_.get()) > { > if (fork_ev == boost::asio::io_service::fork_prepare) > { > work_io_service_->stop(); > work_thread_->join(); > } > else > { > work_io_service_->reset(); > work_thread_.reset(new boost::asio::detail::thread( > work_io_service_runner(*work_io_service_))); > } > } >} > >void resolver_service_base::construct( > resolver_service_base::implementation_type& impl) >{ > impl.reset(static_cast<void*>(0), socket_ops::noop_deleter()); >} > >void resolver_service_base::destroy( > resolver_service_base::implementation_type& impl) >{ > (void)0; > > impl.reset(); >} > >void resolver_service_base::cancel( > resolver_service_base::implementation_type& impl) >{ > (void)0; > > impl.reset(static_cast<void*>(0), socket_ops::noop_deleter()); >} > >void resolver_service_base::start_resolve_op(operation* op) >{ > start_work_thread(); > io_service_impl_.work_started(); > work_io_service_impl_.post_immediate_completion(op, false); >} > >void resolver_service_base::start_work_thread() >{ > boost::asio::detail::mutex::scoped_lock lock(mutex_); > if (!work_thread_.get()) > { > work_thread_.reset(new boost::asio::detail::thread( > work_io_service_runner(*work_io_service_))); > } >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 131 "/usr/include/boost/asio/detail/impl/resolver_service_base.ipp" 2 3 4 ># 129 "/usr/include/boost/asio/detail/resolver_service_base.hpp" 2 3 4 ># 28 "/usr/include/boost/asio/detail/resolver_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/detail/resolver_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >template <typename Protocol> >class resolver_service : public resolver_service_base >{ >public: > > > typedef socket_ops::shared_cancel_token_type implementation_type; > > > typedef typename Protocol::endpoint endpoint_type; > > > typedef boost::asio::ip::basic_resolver_query<Protocol> query_type; > > > typedef boost::asio::ip::basic_resolver_iterator<Protocol> iterator_type; > > > resolver_service(boost::asio::io_service& io_service) > : resolver_service_base(io_service) > { > } > > > iterator_type resolve(implementation_type&, const query_type& query, > boost::system::error_code& ec) > { > boost::asio::detail::addrinfo_type* address_info = 0; > > socket_ops::getaddrinfo(query.host_name().c_str(), > query.service_name().c_str(), query.hints(), &address_info, ec); > auto_addrinfo auto_address_info(address_info); > > return ec ? iterator_type() : iterator_type::create( > address_info, query.host_name(), query.service_name()); > } > > > template <typename Handler> > void async_resolve(implementation_type& impl, > const query_type& query, Handler& handler) > { > > typedef resolve_op<Protocol, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl, query, io_service_impl_, handler); > > (void)0; > > start_resolve_op(p.p); > p.v = p.p = 0; > } > > > iterator_type resolve(implementation_type&, > const endpoint_type& endpoint, boost::system::error_code& ec) > { > char host_name[1025]; > char service_name[32]; > socket_ops::sync_getnameinfo(endpoint.data(), endpoint.size(), > host_name, 1025, service_name, 32, > endpoint.protocol().type(), ec); > > return ec ? iterator_type() : iterator_type::create( > endpoint, host_name, service_name); > } > > > template <typename Handler> > void async_resolve(implementation_type& impl, > const endpoint_type& endpoint, Handler& handler) > { > > typedef resolve_endpoint_op<Protocol, Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(impl, endpoint, io_service_impl_, handler); > > (void)0; > > start_resolve_op(p.p); > p.v = p.p = 0; > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 128 "/usr/include/boost/asio/detail/resolver_service.hpp" 2 3 4 ># 29 "/usr/include/boost/asio/ip/resolver_service.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/ip/resolver_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > > >template <typename InternetProtocol> >class resolver_service > > > > : public boost::asio::detail::service_base< > resolver_service<InternetProtocol> > > >{ >public: > > > > > > > typedef InternetProtocol protocol_type; > > > typedef typename InternetProtocol::endpoint endpoint_type; > > > typedef basic_resolver_query<InternetProtocol> query_type; > > > typedef basic_resolver_iterator<InternetProtocol> iterator_type; > >private: > > > > > > typedef boost::asio::detail::resolver_service<InternetProtocol> > service_impl_type; > > >public: > > > > > typedef typename service_impl_type::implementation_type implementation_type; > > > > explicit resolver_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base< > resolver_service<InternetProtocol> >(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > void cancel(implementation_type& impl) > { > service_impl_.cancel(impl); > } > > > iterator_type resolve(implementation_type& impl, const query_type& query, > boost::system::error_code& ec) > { > return service_impl_.resolve(impl, query, ec); > } > > > template <typename ResolveHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ResolveHandler, void (boost::system::error_code, iterator_type)>::type>::type > > async_resolve(implementation_type& impl, const query_type& query, > ResolveHandler&& handler) > { > boost::asio::detail::async_result_init< > ResolveHandler, void (boost::system::error_code, iterator_type)> init( > static_cast<ResolveHandler&&>(handler)); > > service_impl_.async_resolve(impl, query, init.handler); > > return init.result.get(); > } > > > iterator_type resolve(implementation_type& impl, > const endpoint_type& endpoint, boost::system::error_code& ec) > { > return service_impl_.resolve(impl, endpoint, ec); > } > > > template <typename ResolveHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ResolveHandler, void (boost::system::error_code, iterator_type)>::type>::type > > async_resolve(implementation_type& impl, const endpoint_type& endpoint, > ResolveHandler&& handler) > { > boost::asio::detail::async_result_init< > ResolveHandler, void (boost::system::error_code, iterator_type)> init( > static_cast<ResolveHandler&&>(handler)); > > service_impl_.async_resolve(impl, endpoint, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > void fork_service(boost::asio::io_service::fork_event event) > { > service_impl_.fork_service(event); > } > > > service_impl_type service_impl_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 177 "/usr/include/boost/asio/ip/resolver_service.hpp" 2 3 4 ># 26 "/usr/include/boost/asio/ip/basic_resolver.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/ip/basic_resolver.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 42 "/usr/include/boost/asio/ip/basic_resolver.hpp" 3 4 >template <typename InternetProtocol, > typename ResolverService = resolver_service<InternetProtocol> > >class basic_resolver > : public basic_io_object<ResolverService> >{ >public: > > typedef InternetProtocol protocol_type; > > > typedef typename InternetProtocol::endpoint endpoint_type; > > > typedef basic_resolver_query<InternetProtocol> query; > > > typedef basic_resolver_iterator<InternetProtocol> iterator; ># 67 "/usr/include/boost/asio/ip/basic_resolver.hpp" 3 4 > explicit basic_resolver(boost::asio::io_service& io_service) > : basic_io_object<ResolverService>(io_service) > { > } > > > > > > > > void cancel() > { > return this->service.cancel(this->implementation); > } ># 99 "/usr/include/boost/asio/ip/basic_resolver.hpp" 3 4 > iterator resolve(const query& q) > { > boost::system::error_code ec; > iterator i = this->service.resolve(this->implementation, q, ec); > boost::asio::detail::throw_error(ec, "resolve"); > return i; > } ># 124 "/usr/include/boost/asio/ip/basic_resolver.hpp" 3 4 > iterator resolve(const query& q, boost::system::error_code& ec) > { > return this->service.resolve(this->implementation, q, ec); > } ># 155 "/usr/include/boost/asio/ip/basic_resolver.hpp" 3 4 > template <typename ResolveHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ResolveHandler, void (boost::system::error_code, iterator)>::type>::type > > async_resolve(const query& q, > ResolveHandler&& handler) > { > > > typedef typename handler_type<ResolveHandler, void(boost::system::error_code, iterator)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const iterator*>(0))) == 1, "ResolveHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const iterator>()), char(0))> __attribute__((__unused__)) > type_check; > > return this->service.async_resolve(this->implementation, q, > static_cast<ResolveHandler&&>(handler)); > } ># 188 "/usr/include/boost/asio/ip/basic_resolver.hpp" 3 4 > iterator resolve(const endpoint_type& e) > { > boost::system::error_code ec; > iterator i = this->service.resolve(this->implementation, e, ec); > boost::asio::detail::throw_error(ec, "resolve"); > return i; > } ># 215 "/usr/include/boost/asio/ip/basic_resolver.hpp" 3 4 > iterator resolve(const endpoint_type& e, boost::system::error_code& ec) > { > return this->service.resolve(this->implementation, e, ec); > } ># 248 "/usr/include/boost/asio/ip/basic_resolver.hpp" 3 4 > template <typename ResolveHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ResolveHandler, void (boost::system::error_code, iterator)>::type>::type > > async_resolve(const endpoint_type& e, > ResolveHandler&& handler) > { > > > typedef typename handler_type<ResolveHandler, void(boost::system::error_code, iterator)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const iterator*>(0))) == 1, "ResolveHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const iterator>()), char(0))> __attribute__((__unused__)) > type_check; > > return this->service.async_resolve(this->implementation, e, > static_cast<ResolveHandler&&>(handler)); > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 269 "/usr/include/boost/asio/ip/basic_resolver.hpp" 2 3 4 ># 64 "/usr/include/boost/asio.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/ip/host_name.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/host_name.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/host_name.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > > >inline std::string host_name(); > > >inline std::string host_name(boost::system::error_code& ec); > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 39 "/usr/include/boost/asio/ip/host_name.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/ip/impl/host_name.ipp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/impl/host_name.ipp" 3 4 ># 1 "/usr/include/boost/asio/ip/host_name.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/impl/host_name.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/ip/impl/host_name.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { > >std::string host_name() >{ > char name[1024]; > boost::system::error_code ec; > if (boost::asio::detail::socket_ops::gethostname(name, sizeof(name), ec) != 0) > { > boost::asio::detail::throw_error(ec); > return std::string(); > } > return std::string(name); >} > >std::string host_name(boost::system::error_code& ec) >{ > char name[1024]; > if (boost::asio::detail::socket_ops::gethostname(name, sizeof(name), ec) != 0) > return std::string(); > return std::string(name); >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 55 "/usr/include/boost/asio/ip/impl/host_name.ipp" 2 3 4 ># 42 "/usr/include/boost/asio/ip/host_name.hpp" 2 3 4 ># 68 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/ip/icmp.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/ip/icmp.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/ip/icmp.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 43 "/usr/include/boost/asio/ip/icmp.hpp" 3 4 >class icmp >{ >public: > > typedef basic_endpoint<icmp> endpoint; > > > static icmp v4() > { > return icmp(IPPROTO_ICMP, > 2); > } > > > static icmp v6() > { > return icmp(IPPROTO_ICMPV6, > 10); > } > > > int type() const > { > return SOCK_RAW; > } > > > int protocol() const > { > return protocol_; > } > > > int family() const > { > return family_; > } > > > typedef basic_raw_socket<icmp> socket; > > > typedef basic_resolver<icmp> resolver; > > > friend bool operator==(const icmp& p1, const icmp& p2) > { > return p1.protocol_ == p2.protocol_ && p1.family_ == p2.family_; > } > > > friend bool operator!=(const icmp& p1, const icmp& p2) > { > return p1.protocol_ != p2.protocol_ || p1.family_ != p2.family_; > } > >private: > > explicit icmp(int protocol_id, int protocol_family) > : protocol_(protocol_id), > family_(protocol_family) > { > } > > int protocol_; > int family_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 116 "/usr/include/boost/asio/ip/icmp.hpp" 2 3 4 ># 69 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/ip/multicast.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/ip/multicast.hpp" 3 4 ># 1 "/usr/include/boost/asio/ip/detail/socket_option.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/ip/detail/socket_option.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 21 "/usr/include/boost/asio/ip/detail/socket_option.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/ip/detail/socket_option.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { >namespace detail { >namespace socket_option { > > >template <int IPv4_Level, int IPv4_Name, int IPv6_Level, int IPv6_Name> >class multicast_enable_loopback >{ >public: > > > > > > > > typedef int ipv4_value_type; > typedef int ipv6_value_type; > > > > multicast_enable_loopback() > : ipv4_value_(0), > ipv6_value_(0) > { > } > > > explicit multicast_enable_loopback(bool v) > : ipv4_value_(v ? 1 : 0), > ipv6_value_(v ? 1 : 0) > { > } > > > multicast_enable_loopback& operator=(bool v) > { > ipv4_value_ = v ? 1 : 0; > ipv6_value_ = v ? 1 : 0; > return *this; > } > > > bool value() const > { > return !!ipv4_value_; > } > > > operator bool() const > { > return !!ipv4_value_; > } > > > bool operator!() const > { > return !ipv4_value_; > } > > > template <typename Protocol> > int level(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Level; > return IPv4_Level; > } > > > template <typename Protocol> > int name(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Name; > return IPv4_Name; > } > > > template <typename Protocol> > void* data(const Protocol& protocol) > { > if (protocol.family() == 10) > return &ipv6_value_; > return &ipv4_value_; > } > > > template <typename Protocol> > const void* data(const Protocol& protocol) const > { > if (protocol.family() == 10) > return &ipv6_value_; > return &ipv4_value_; > } > > > template <typename Protocol> > std::size_t size(const Protocol& protocol) const > { > if (protocol.family() == 10) > return sizeof(ipv6_value_); > return sizeof(ipv4_value_); > } > > > template <typename Protocol> > void resize(const Protocol& protocol, std::size_t s) > { > if (protocol.family() == 10) > { > if (s != sizeof(ipv6_value_)) > { > std::length_error ex("multicast_enable_loopback socket option resize"); > boost::asio::detail::throw_exception(ex); > } > ipv4_value_ = ipv6_value_ ? 1 : 0; > } > else > { > if (s != sizeof(ipv4_value_)) > { > std::length_error ex("multicast_enable_loopback socket option resize"); > boost::asio::detail::throw_exception(ex); > } > ipv6_value_ = ipv4_value_ ? 1 : 0; > } > } > >private: > ipv4_value_type ipv4_value_; > ipv6_value_type ipv6_value_; >}; > > >template <int IPv4_Level, int IPv4_Name, int IPv6_Level, int IPv6_Name> >class unicast_hops >{ >public: > > unicast_hops() > : value_(0) > { > } > > > explicit unicast_hops(int v) > : value_(v) > { > } > > > unicast_hops& operator=(int v) > { > value_ = v; > return *this; > } > > > int value() const > { > return value_; > } > > > template <typename Protocol> > int level(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Level; > return IPv4_Level; > } > > > template <typename Protocol> > int name(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Name; > return IPv4_Name; > } > > > template <typename Protocol> > int* data(const Protocol&) > { > return &value_; > } > > > template <typename Protocol> > const int* data(const Protocol&) const > { > return &value_; > } > > > template <typename Protocol> > std::size_t size(const Protocol&) const > { > return sizeof(value_); > } > > > template <typename Protocol> > void resize(const Protocol&, std::size_t s) > { > if (s != sizeof(value_)) > { > std::length_error ex("unicast hops socket option resize"); > boost::asio::detail::throw_exception(ex); > } > > > > > } > >private: > int value_; >}; > > >template <int IPv4_Level, int IPv4_Name, int IPv6_Level, int IPv6_Name> >class multicast_hops >{ >public: > > > > typedef unsigned char ipv4_value_type; > > typedef int ipv6_value_type; > > > multicast_hops() > : ipv4_value_(0), > ipv6_value_(0) > { > } > > > explicit multicast_hops(int v) > { > if (v < 0 || v > 255) > { > std::out_of_range ex("multicast hops value out of range"); > boost::asio::detail::throw_exception(ex); > } > ipv4_value_ = (ipv4_value_type)v; > ipv6_value_ = v; > } > > > multicast_hops& operator=(int v) > { > if (v < 0 || v > 255) > { > std::out_of_range ex("multicast hops value out of range"); > boost::asio::detail::throw_exception(ex); > } > ipv4_value_ = (ipv4_value_type)v; > ipv6_value_ = v; > return *this; > } > > > int value() const > { > return ipv6_value_; > } > > > template <typename Protocol> > int level(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Level; > return IPv4_Level; > } > > > template <typename Protocol> > int name(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Name; > return IPv4_Name; > } > > > template <typename Protocol> > void* data(const Protocol& protocol) > { > if (protocol.family() == 10) > return &ipv6_value_; > return &ipv4_value_; > } > > > template <typename Protocol> > const void* data(const Protocol& protocol) const > { > if (protocol.family() == 10) > return &ipv6_value_; > return &ipv4_value_; > } > > > template <typename Protocol> > std::size_t size(const Protocol& protocol) const > { > if (protocol.family() == 10) > return sizeof(ipv6_value_); > return sizeof(ipv4_value_); > } > > > template <typename Protocol> > void resize(const Protocol& protocol, std::size_t s) > { > if (protocol.family() == 10) > { > if (s != sizeof(ipv6_value_)) > { > std::length_error ex("multicast hops socket option resize"); > boost::asio::detail::throw_exception(ex); > } > if (ipv6_value_ < 0) > ipv4_value_ = 0; > else if (ipv6_value_ > 255) > ipv4_value_ = 255; > else > ipv4_value_ = (ipv4_value_type)ipv6_value_; > } > else > { > if (s != sizeof(ipv4_value_)) > { > std::length_error ex("multicast hops socket option resize"); > boost::asio::detail::throw_exception(ex); > } > ipv6_value_ = ipv4_value_; > } > } > >private: > ipv4_value_type ipv4_value_; > ipv6_value_type ipv6_value_; >}; > > >template <int IPv4_Level, int IPv4_Name, int IPv6_Level, int IPv6_Name> >class multicast_request >{ >public: > > multicast_request() > : ipv4_value_(), > ipv6_value_() > { > } > > > explicit multicast_request(const boost::asio::ip::address& multicast_address) > : ipv4_value_(), > ipv6_value_() > { > if (multicast_address.is_v6()) > { > using namespace std; > boost::asio::ip::address_v6 ipv6_address = multicast_address.to_v6(); > boost::asio::ip::address_v6::bytes_type bytes = ipv6_address.to_bytes(); > memcpy(ipv6_value_.ipv6mr_multiaddr.__in6_u.__u6_addr8, bytes.data(), 16); > ipv6_value_.ipv6mr_interface = 0; > } > else > { > ipv4_value_.imr_multiaddr.s_addr = > boost::asio::detail::socket_ops::host_to_network_long( > multicast_address.to_v4().to_ulong()); > ipv4_value_.imr_interface.s_addr = > boost::asio::detail::socket_ops::host_to_network_long( > boost::asio::ip::address_v4::any().to_ulong()); > } > } > > > explicit multicast_request( > const boost::asio::ip::address_v4& multicast_address, > const boost::asio::ip::address_v4& network_interface > = boost::asio::ip::address_v4::any()) > : ipv6_value_() > { > ipv4_value_.imr_multiaddr.s_addr = > boost::asio::detail::socket_ops::host_to_network_long( > multicast_address.to_ulong()); > ipv4_value_.imr_interface.s_addr = > boost::asio::detail::socket_ops::host_to_network_long( > network_interface.to_ulong()); > } > > > explicit multicast_request( > const boost::asio::ip::address_v6& multicast_address, > unsigned long network_interface = 0) > : ipv4_value_() > { > using namespace std; > boost::asio::ip::address_v6::bytes_type bytes = > multicast_address.to_bytes(); > memcpy(ipv6_value_.ipv6mr_multiaddr.__in6_u.__u6_addr8, bytes.data(), 16); > ipv6_value_.ipv6mr_interface = network_interface; > } > > > template <typename Protocol> > int level(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Level; > return IPv4_Level; > } > > > template <typename Protocol> > int name(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Name; > return IPv4_Name; > } > > > template <typename Protocol> > const void* data(const Protocol& protocol) const > { > if (protocol.family() == 10) > return &ipv6_value_; > return &ipv4_value_; > } > > > template <typename Protocol> > std::size_t size(const Protocol& protocol) const > { > if (protocol.family() == 10) > return sizeof(ipv6_value_); > return sizeof(ipv4_value_); > } > >private: > boost::asio::detail::in4_mreq_type ipv4_value_; > boost::asio::detail::in6_mreq_type ipv6_value_; >}; > > >template <int IPv4_Level, int IPv4_Name, int IPv6_Level, int IPv6_Name> >class network_interface >{ >public: > > network_interface() > { > ipv4_value_.s_addr = > boost::asio::detail::socket_ops::host_to_network_long( > boost::asio::ip::address_v4::any().to_ulong()); > ipv6_value_ = 0; > } > > > explicit network_interface(const boost::asio::ip::address_v4& ipv4_interface) > { > ipv4_value_.s_addr = > boost::asio::detail::socket_ops::host_to_network_long( > ipv4_interface.to_ulong()); > ipv6_value_ = 0; > } > > > explicit network_interface(unsigned int ipv6_interface) > { > ipv4_value_.s_addr = > boost::asio::detail::socket_ops::host_to_network_long( > boost::asio::ip::address_v4::any().to_ulong()); > ipv6_value_ = ipv6_interface; > } > > > template <typename Protocol> > int level(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Level; > return IPv4_Level; > } > > > template <typename Protocol> > int name(const Protocol& protocol) const > { > if (protocol.family() == 10) > return IPv6_Name; > return IPv4_Name; > } > > > template <typename Protocol> > const void* data(const Protocol& protocol) const > { > if (protocol.family() == 10) > return &ipv6_value_; > return &ipv4_value_; > } > > > template <typename Protocol> > std::size_t size(const Protocol& protocol) const > { > if (protocol.family() == 10) > return sizeof(ipv6_value_); > return sizeof(ipv4_value_); > } > >private: > boost::asio::detail::in4_addr_type ipv4_value_; > unsigned int ipv6_value_; >}; > >} >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 567 "/usr/include/boost/asio/ip/detail/socket_option.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/ip/multicast.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/multicast.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { >namespace multicast { ># 50 "/usr/include/boost/asio/ip/multicast.hpp" 3 4 >typedef boost::asio::ip::detail::socket_option::multicast_request< > IPPROTO_IP, > 35, > IPPROTO_IPV6, > 20> join_group; ># 78 "/usr/include/boost/asio/ip/multicast.hpp" 3 4 >typedef boost::asio::ip::detail::socket_option::multicast_request< > IPPROTO_IP, > 36, > IPPROTO_IPV6, > 21> leave_group; ># 106 "/usr/include/boost/asio/ip/multicast.hpp" 3 4 >typedef boost::asio::ip::detail::socket_option::network_interface< > IPPROTO_IP, > 32, > IPPROTO_IPV6, > 17> outbound_interface; ># 142 "/usr/include/boost/asio/ip/multicast.hpp" 3 4 >typedef boost::asio::ip::detail::socket_option::multicast_hops< > IPPROTO_IP, > 33, > IPPROTO_IPV6, > 18> hops; ># 179 "/usr/include/boost/asio/ip/multicast.hpp" 3 4 >typedef boost::asio::ip::detail::socket_option::multicast_enable_loopback< > IPPROTO_IP, > 34, > IPPROTO_IPV6, > 19> enable_loopback; > > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 192 "/usr/include/boost/asio/ip/multicast.hpp" 2 3 4 ># 70 "/usr/include/boost/asio.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/ip/tcp.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/ip/tcp.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/ip/tcp.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 46 "/usr/include/boost/asio/ip/tcp.hpp" 3 4 >class tcp >{ >public: > > typedef basic_endpoint<tcp> endpoint; > > > static tcp v4() > { > return tcp(2); > } > > > static tcp v6() > { > return tcp(10); > } > > > int type() const > { > return SOCK_STREAM; > } > > > int protocol() const > { > return IPPROTO_TCP; > } > > > int family() const > { > return family_; > } > > > typedef basic_stream_socket<tcp> socket; > > > typedef basic_socket_acceptor<tcp> acceptor; > > > typedef basic_resolver<tcp> resolver; > > > > typedef basic_socket_iostream<tcp> iostream; ># 125 "/usr/include/boost/asio/ip/tcp.hpp" 3 4 > typedef boost::asio::detail::socket_option::boolean< > IPPROTO_TCP, 1> no_delay; > > > > friend bool operator==(const tcp& p1, const tcp& p2) > { > return p1.family_ == p2.family_; > } > > > friend bool operator!=(const tcp& p1, const tcp& p2) > { > return p1.family_ != p2.family_; > } > >private: > > explicit tcp(int protocol_family) > : family_(protocol_family) > { > } > > int family_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 156 "/usr/include/boost/asio/ip/tcp.hpp" 2 3 4 ># 73 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/ip/udp.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/ip/udp.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/ip/udp.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 43 "/usr/include/boost/asio/ip/udp.hpp" 3 4 >class udp >{ >public: > > typedef basic_endpoint<udp> endpoint; > > > static udp v4() > { > return udp(2); > } > > > static udp v6() > { > return udp(10); > } > > > int type() const > { > return SOCK_DGRAM; > } > > > int protocol() const > { > return IPPROTO_UDP; > } > > > int family() const > { > return family_; > } > > > typedef basic_datagram_socket<udp> socket; > > > typedef basic_resolver<udp> resolver; > > > friend bool operator==(const udp& p1, const udp& p2) > { > return p1.family_ == p2.family_; > } > > > friend bool operator!=(const udp& p1, const udp& p2) > { > return p1.family_ != p2.family_; > } > >private: > > explicit udp(int protocol_family) > : family_(protocol_family) > { > } > > int family_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 112 "/usr/include/boost/asio/ip/udp.hpp" 2 3 4 ># 74 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/ip/unicast.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/unicast.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/ip/unicast.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { >namespace unicast { ># 58 "/usr/include/boost/asio/ip/unicast.hpp" 3 4 >typedef boost::asio::ip::detail::socket_option::unicast_hops< > IPPROTO_IP, > 2, > IPPROTO_IPV6, > 16> hops; > > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 71 "/usr/include/boost/asio/ip/unicast.hpp" 2 3 4 ># 75 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/ip/v6_only.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/ip/v6_only.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/ip/v6_only.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace ip { ># 57 "/usr/include/boost/asio/ip/v6_only.hpp" 3 4 >typedef boost::asio::detail::socket_option::boolean< > IPPROTO_IPV6, 26> v6_only; > > > > > > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 70 "/usr/include/boost/asio/ip/v6_only.hpp" 2 3 4 ># 76 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/is_read_buffered.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/is_read_buffered.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/is_read_buffered.hpp" 2 3 4 > >namespace boost { >namespace asio { > >namespace detail { > >template <typename Stream> >char is_read_buffered_helper(buffered_stream<Stream>* s); > >template <typename Stream> >char is_read_buffered_helper(buffered_read_stream<Stream>* s); > >struct is_read_buffered_big_type { char data[10]; }; >is_read_buffered_big_type is_read_buffered_helper(...); > >} > > > >template <typename Stream> >class is_read_buffered >{ >public: > > > > > > static const bool value = sizeof(detail::is_read_buffered_helper((Stream*)0)) == 1 > ; > >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 60 "/usr/include/boost/asio/is_read_buffered.hpp" 2 3 4 ># 77 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/is_write_buffered.hpp" 1 3 4 ># 22 "/usr/include/boost/asio/is_write_buffered.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/is_write_buffered.hpp" 2 3 4 > >namespace boost { >namespace asio { > >namespace detail { > >template <typename Stream> >char is_write_buffered_helper(buffered_stream<Stream>* s); > >template <typename Stream> >char is_write_buffered_helper(buffered_write_stream<Stream>* s); > >struct is_write_buffered_big_type { char data[10]; }; >is_write_buffered_big_type is_write_buffered_helper(...); > >} > > > >template <typename Stream> >class is_write_buffered >{ >public: > > > > > > static const bool value = sizeof(detail::is_write_buffered_helper((Stream*)0)) == 1 > ; > >}; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 60 "/usr/include/boost/asio/is_write_buffered.hpp" 2 3 4 ># 78 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/local/basic_endpoint.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/local/basic_endpoint.hpp" 3 4 ># 1 "/usr/include/boost/asio/local/detail/endpoint.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/local/detail/endpoint.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/local/detail/endpoint.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace local { >namespace detail { > > >class endpoint >{ >public: > > inline endpoint(); > > > inline endpoint(const char* path_name); > > > inline endpoint(const std::string& path_name); > > > endpoint(const endpoint& other) > : data_(other.data_), > path_length_(other.path_length_) > { > } > > > endpoint& operator=(const endpoint& other) > { > data_ = other.data_; > path_length_ = other.path_length_; > return *this; > } > > > boost::asio::detail::socket_addr_type* data() > { > return &data_.base; > } > > > const boost::asio::detail::socket_addr_type* data() const > { > return &data_.base; > } > > > std::size_t size() const > { > return path_length_ > + __builtin_offsetof (boost::asio::detail::sockaddr_un_type, sun_path); > } > > > inline void resize(std::size_t size); > > > std::size_t capacity() const > { > return sizeof(boost::asio::detail::sockaddr_un_type); > } > > > inline std::string path() const; > > > inline void path(const char* p); > > > inline void path(const std::string& p); > > > inline friend bool operator==( > const endpoint& e1, const endpoint& e2); > > > inline friend bool operator<( > const endpoint& e1, const endpoint& e2); > >private: > > union data_union > { > boost::asio::detail::socket_addr_type base; > boost::asio::detail::sockaddr_un_type local; > } data_; > > > std::size_t path_length_; > > > inline void init(const char* path, std::size_t path_length); >}; > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 128 "/usr/include/boost/asio/local/detail/endpoint.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/local/detail/impl/endpoint.ipp" 1 3 4 ># 23 "/usr/include/boost/asio/local/detail/impl/endpoint.ipp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 24 "/usr/include/boost/asio/local/detail/impl/endpoint.ipp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/local/detail/endpoint.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/local/detail/impl/endpoint.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/local/detail/impl/endpoint.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace local { >namespace detail { > >endpoint::endpoint() >{ > init("", 0); >} > >endpoint::endpoint(const char* path_name) >{ > using namespace std; > init(path_name, strlen(path_name)); >} > >endpoint::endpoint(const std::string& path_name) >{ > init(path_name.data(), path_name.length()); >} > >void endpoint::resize(std::size_t new_size) >{ > if (new_size > sizeof(boost::asio::detail::sockaddr_un_type)) > { > boost::system::error_code ec(boost::asio::error::invalid_argument); > boost::asio::detail::throw_error(ec); > } > else if (new_size == 0) > { > path_length_ = 0; > } > else > { > path_length_ = new_size > - __builtin_offsetof (boost::asio::detail::sockaddr_un_type, sun_path); > > > if (path_length_ > 0 && data_.local.sun_path[path_length_ - 1] == 0) > --path_length_; > } >} > >std::string endpoint::path() const >{ > return std::string(data_.local.sun_path, path_length_); >} > >void endpoint::path(const char* p) >{ > using namespace std; > init(p, strlen(p)); >} > >void endpoint::path(const std::string& p) >{ > init(p.data(), p.length()); >} > >bool operator==(const endpoint& e1, const endpoint& e2) >{ > return e1.path() == e2.path(); >} > >bool operator<(const endpoint& e1, const endpoint& e2) >{ > return e1.path() < e2.path(); >} > >void endpoint::init(const char* path_name, std::size_t path_length) >{ > if (path_length > sizeof(data_.local.sun_path) - 1) > { > > boost::system::error_code ec(boost::asio::error::name_too_long); > boost::asio::detail::throw_error(ec); > } > > using namespace std; > data_.local = boost::asio::detail::sockaddr_un_type(); > data_.local.sun_family = 1; > memcpy(data_.local.sun_path, path_name, path_length); > path_length_ = path_length; > > > > if (path_length > 0 && data_.local.sun_path[0] == 0) > data_.local.sun_path[path_length] = 0; >} > >} >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 127 "/usr/include/boost/asio/local/detail/impl/endpoint.ipp" 2 3 4 ># 131 "/usr/include/boost/asio/local/detail/endpoint.hpp" 2 3 4 ># 25 "/usr/include/boost/asio/local/basic_endpoint.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/local/basic_endpoint.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace local { ># 48 "/usr/include/boost/asio/local/basic_endpoint.hpp" 3 4 >template <typename Protocol> >class basic_endpoint >{ >public: > > typedef Protocol protocol_type; > > > > > > > typedef boost::asio::detail::socket_addr_type data_type; > > > > basic_endpoint() > { > } > > > basic_endpoint(const char* path_name) > : impl_(path_name) > { > } > > > basic_endpoint(const std::string& path_name) > : impl_(path_name) > { > } > > > basic_endpoint(const basic_endpoint& other) > : impl_(other.impl_) > { > } > > > > basic_endpoint(basic_endpoint&& other) > : impl_(other.impl_) > { > } > > > > basic_endpoint& operator=(const basic_endpoint& other) > { > impl_ = other.impl_; > return *this; > } > > > > basic_endpoint& operator=(basic_endpoint&& other) > { > impl_ = other.impl_; > return *this; > } > > > > protocol_type protocol() const > { > return protocol_type(); > } > > > data_type* data() > { > return impl_.data(); > } > > > const data_type* data() const > { > return impl_.data(); > } > > > std::size_t size() const > { > return impl_.size(); > } > > > void resize(std::size_t new_size) > { > impl_.resize(new_size); > } > > > std::size_t capacity() const > { > return impl_.capacity(); > } > > > std::string path() const > { > return impl_.path(); > } > > > void path(const char* p) > { > impl_.path(p); > } > > > void path(const std::string& p) > { > impl_.path(p); > } > > > friend bool operator==(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return e1.impl_ == e2.impl_; > } > > > friend bool operator!=(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return !(e1.impl_ == e2.impl_); > } > > > friend bool operator<(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return e1.impl_ < e2.impl_; > } > > > friend bool operator>(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return e2.impl_ < e1.impl_; > } > > > friend bool operator<=(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return !(e2 < e1); > } > > > friend bool operator>=(const basic_endpoint<Protocol>& e1, > const basic_endpoint<Protocol>& e2) > { > return !(e1 < e2); > } > >private: > > boost::asio::local::detail::endpoint impl_; >}; ># 223 "/usr/include/boost/asio/local/basic_endpoint.hpp" 3 4 >template <typename Elem, typename Traits, typename Protocol> >std::basic_ostream<Elem, Traits>& operator<<( > std::basic_ostream<Elem, Traits>& os, > const basic_endpoint<Protocol>& endpoint) >{ > os << endpoint.path(); > return os; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 237 "/usr/include/boost/asio/local/basic_endpoint.hpp" 2 3 4 ># 79 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/local/connect_pair.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/local/connect_pair.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/local/connect_pair.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace local { > > >template <typename Protocol, typename SocketService1, typename SocketService2> >void connect_pair( > basic_socket<Protocol, SocketService1>& socket1, > basic_socket<Protocol, SocketService2>& socket2); > > >template <typename Protocol, typename SocketService1, typename SocketService2> >boost::system::error_code connect_pair( > basic_socket<Protocol, SocketService1>& socket1, > basic_socket<Protocol, SocketService2>& socket2, > boost::system::error_code& ec); > >template <typename Protocol, typename SocketService1, typename SocketService2> >inline void connect_pair( > basic_socket<Protocol, SocketService1>& socket1, > basic_socket<Protocol, SocketService2>& socket2) >{ > boost::system::error_code ec; > connect_pair(socket1, socket2, ec); > boost::asio::detail::throw_error(ec, "connect_pair"); >} > >template <typename Protocol, typename SocketService1, typename SocketService2> >inline boost::system::error_code connect_pair( > basic_socket<Protocol, SocketService1>& socket1, > basic_socket<Protocol, SocketService2>& socket2, > boost::system::error_code& ec) >{ > > boost::asio::local::basic_endpoint<Protocol>* tmp > = static_cast<typename Protocol::endpoint*>(0); > (void)tmp; > > Protocol protocol; > boost::asio::detail::socket_type sv[2]; > if (boost::asio::detail::socket_ops::socketpair(protocol.family(), > protocol.type(), protocol.protocol(), sv, ec) > == boost::asio::detail::socket_error_retval) > return ec; > > if (socket1.assign(protocol, sv[0], ec)) > { > boost::system::error_code temp_ec; > boost::asio::detail::socket_ops::state_type state[2] = { 0, 0 }; > boost::asio::detail::socket_ops::close(sv[0], state[0], true, temp_ec); > boost::asio::detail::socket_ops::close(sv[1], state[1], true, temp_ec); > return ec; > } > > if (socket2.assign(protocol, sv[1], ec)) > { > boost::system::error_code temp_ec; > socket1.close(temp_ec); > boost::asio::detail::socket_ops::state_type state = 0; > boost::asio::detail::socket_ops::close(sv[1], state, true, temp_ec); > return ec; > } > > return ec; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 102 "/usr/include/boost/asio/local/connect_pair.hpp" 2 3 4 ># 80 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/local/datagram_protocol.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/local/datagram_protocol.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/local/datagram_protocol.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace local { ># 45 "/usr/include/boost/asio/local/datagram_protocol.hpp" 3 4 >class datagram_protocol >{ >public: > > int type() const > { > return SOCK_DGRAM; > } > > > int protocol() const > { > return 0; > } > > > int family() const > { > return 1; > } > > > typedef basic_endpoint<datagram_protocol> endpoint; > > > typedef basic_datagram_socket<datagram_protocol> socket; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 78 "/usr/include/boost/asio/local/datagram_protocol.hpp" 2 3 4 ># 81 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/local/stream_protocol.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/local/stream_protocol.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/local/stream_protocol.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace local { ># 47 "/usr/include/boost/asio/local/stream_protocol.hpp" 3 4 >class stream_protocol >{ >public: > > int type() const > { > return SOCK_STREAM; > } > > > int protocol() const > { > return 0; > } > > > int family() const > { > return 1; > } > > > typedef basic_endpoint<stream_protocol> endpoint; > > > typedef basic_stream_socket<stream_protocol> socket; > > > typedef basic_socket_acceptor<stream_protocol> acceptor; > > > > typedef basic_socket_iostream<stream_protocol> iostream; > >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 88 "/usr/include/boost/asio/local/stream_protocol.hpp" 2 3 4 ># 82 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/placeholders.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/placeholders.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/placeholders.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace placeholders { ># 55 "/usr/include/boost/asio/placeholders.hpp" 3 4 >inline boost::arg<1> error() >{ > return boost::arg<1>(); >} > >inline boost::arg<2> bytes_transferred() >{ > return boost::arg<2>(); >} > >inline boost::arg<2> iterator() >{ > return boost::arg<2>(); >} > >inline boost::arg<2> signal_number() >{ > return boost::arg<2>(); >} ># 119 "/usr/include/boost/asio/placeholders.hpp" 3 4 >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 124 "/usr/include/boost/asio/placeholders.hpp" 2 3 4 ># 83 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 ># 1 "/usr/include/boost/asio/posix/descriptor_base.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/posix/descriptor_base.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 27 "/usr/include/boost/asio/posix/descriptor_base.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace posix { > > > > >class descriptor_base >{ >public: ># 57 "/usr/include/boost/asio/posix/descriptor_base.hpp" 3 4 > typedef boost::asio::detail::io_control::non_blocking_io non_blocking_io; ># 80 "/usr/include/boost/asio/posix/descriptor_base.hpp" 3 4 > typedef boost::asio::detail::io_control::bytes_readable bytes_readable; > > >protected: > > ~descriptor_base() > { > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 95 "/usr/include/boost/asio/posix/descriptor_base.hpp" 2 3 4 ># 27 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace posix { ># 43 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 >template <typename DescriptorService> >class basic_descriptor > : public basic_io_object<DescriptorService>, > public descriptor_base >{ >public: > > > typedef typename DescriptorService::native_handle_type native_type; > > > typedef typename DescriptorService::native_handle_type native_handle_type; > > > typedef basic_descriptor<DescriptorService> lowest_layer_type; ># 67 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > explicit basic_descriptor(boost::asio::io_service& io_service) > : basic_io_object<DescriptorService>(io_service) > { > } ># 85 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > basic_descriptor(boost::asio::io_service& io_service, > const native_handle_type& native_descriptor) > : basic_io_object<DescriptorService>(io_service) > { > boost::system::error_code ec; > this->get_service().assign(this->get_implementation(), > native_descriptor, ec); > boost::asio::detail::throw_error(ec, "assign"); > } ># 106 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > basic_descriptor(basic_descriptor&& other) > : basic_io_object<DescriptorService>( > static_cast<basic_descriptor&&>(other)) > { > } ># 122 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > basic_descriptor& operator=(basic_descriptor&& other) > { > basic_io_object<DescriptorService>::operator=( > static_cast<basic_descriptor&&>(other)); > return *this; > } ># 139 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > lowest_layer_type& lowest_layer() > { > return *this; > } ># 153 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > const lowest_layer_type& lowest_layer() const > { > return *this; > } ># 166 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > void assign(const native_handle_type& native_descriptor) > { > boost::system::error_code ec; > this->get_service().assign(this->get_implementation(), > native_descriptor, ec); > boost::asio::detail::throw_error(ec, "assign"); > } ># 182 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > boost::system::error_code assign(const native_handle_type& native_descriptor, > boost::system::error_code& ec) > { > return this->get_service().assign( > this->get_implementation(), native_descriptor, ec); > } > > > bool is_open() const > { > return this->get_service().is_open(this->implementation); > } ># 204 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > void close() > { > boost::system::error_code ec; > this->get_service().close(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "close"); > } ># 220 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > boost::system::error_code close(boost::system::error_code& ec) > { > return this->get_service().close(this->get_implementation(), ec); > } ># 232 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > native_type native() > { > return this->get_service().native_handle(this->implementation); > } > > > > > > > > native_handle_type native_handle() > { > return this->get_service().native_handle(this->implementation); > } ># 258 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > native_handle_type release() > { > return this->get_service().release(this->implementation); > } ># 271 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > void cancel() > { > boost::system::error_code ec; > this->get_service().cancel(this->get_implementation(), ec); > boost::asio::detail::throw_error(ec, "cancel"); > } ># 286 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > boost::system::error_code cancel(boost::system::error_code& ec) > { > return this->get_service().cancel(this->get_implementation(), ec); > } ># 313 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > template <typename IoControlCommand> > void io_control(IoControlCommand& command) > { > boost::system::error_code ec; > this->get_service().io_control(this->get_implementation(), command, ec); > boost::asio::detail::throw_error(ec, "io_control"); > } ># 348 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > template <typename IoControlCommand> > boost::system::error_code io_control(IoControlCommand& command, > boost::system::error_code& ec) > { > return this->get_service().io_control( > this->get_implementation(), command, ec); > } ># 367 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > bool non_blocking() const > { > return this->get_service().non_blocking(this->implementation); > } ># 385 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > void non_blocking(bool mode) > { > boost::system::error_code ec; > this->get_service().non_blocking(this->get_implementation(), mode, ec); > boost::asio::detail::throw_error(ec, "non_blocking"); > } ># 405 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > boost::system::error_code non_blocking( > bool mode, boost::system::error_code& ec) > { > return this->get_service().non_blocking( > this->get_implementation(), mode, ec); > } ># 426 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > bool native_non_blocking() const > { > return this->get_service().native_non_blocking(this->implementation); > } ># 446 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > void native_non_blocking(bool mode) > { > boost::system::error_code ec; > this->get_service().native_non_blocking( > this->get_implementation(), mode, ec); > boost::asio::detail::throw_error(ec, "native_non_blocking"); > } ># 469 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 3 4 > boost::system::error_code native_non_blocking( > bool mode, boost::system::error_code& ec) > { > return this->get_service().native_non_blocking( > this->get_implementation(), mode, ec); > } > >protected: > > ~basic_descriptor() > { > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 488 "/usr/include/boost/asio/posix/basic_descriptor.hpp" 2 3 4 ># 84 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 1 3 4 ># 28 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 ># 1 "/usr/include/boost/asio/posix/stream_descriptor_service.hpp" 1 3 4 ># 29 "/usr/include/boost/asio/posix/stream_descriptor_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 30 "/usr/include/boost/asio/posix/stream_descriptor_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace posix { > > >class stream_descriptor_service > > > > : public boost::asio::detail::service_base<stream_descriptor_service> > >{ >public: > > > > > >private: > > typedef detail::reactive_descriptor_service service_impl_type; > >public: > > > > > typedef service_impl_type::implementation_type implementation_type; > > > > > > > typedef service_impl_type::native_handle_type native_type; > > > > > > > typedef service_impl_type::native_handle_type native_handle_type; > > > > explicit stream_descriptor_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base<stream_descriptor_service>(io_service), > service_impl_(io_service) > { > } > > > void construct(implementation_type& impl) > { > service_impl_.construct(impl); > } > > > > void move_construct(implementation_type& impl, > implementation_type& other_impl) > { > service_impl_.move_construct(impl, other_impl); > } > > > void move_assign(implementation_type& impl, > stream_descriptor_service& other_service, > implementation_type& other_impl) > { > service_impl_.move_assign(impl, other_service.service_impl_, other_impl); > } > > > > void destroy(implementation_type& impl) > { > service_impl_.destroy(impl); > } > > > boost::system::error_code assign(implementation_type& impl, > const native_handle_type& native_descriptor, > boost::system::error_code& ec) > { > return service_impl_.assign(impl, native_descriptor, ec); > } > > > bool is_open(const implementation_type& impl) const > { > return service_impl_.is_open(impl); > } > > > boost::system::error_code close(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.close(impl, ec); > } > > > > native_type native(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > native_handle_type native_handle(implementation_type& impl) > { > return service_impl_.native_handle(impl); > } > > > native_handle_type release(implementation_type& impl) > { > return service_impl_.release(impl); > } > > > boost::system::error_code cancel(implementation_type& impl, > boost::system::error_code& ec) > { > return service_impl_.cancel(impl, ec); > } > > > template <typename IoControlCommand> > boost::system::error_code io_control(implementation_type& impl, > IoControlCommand& command, boost::system::error_code& ec) > { > return service_impl_.io_control(impl, command, ec); > } > > > bool non_blocking(const implementation_type& impl) const > { > return service_impl_.non_blocking(impl); > } > > > boost::system::error_code non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.non_blocking(impl, mode, ec); > } > > > bool native_non_blocking(const implementation_type& impl) const > { > return service_impl_.native_non_blocking(impl); > } > > > boost::system::error_code native_non_blocking(implementation_type& impl, > bool mode, boost::system::error_code& ec) > { > return service_impl_.native_non_blocking(impl, mode, ec); > } > > > template <typename ConstBufferSequence> > std::size_t write_some(implementation_type& impl, > const ConstBufferSequence& buffers, boost::system::error_code& ec) > { > return service_impl_.write_some(impl, buffers, ec); > } > > > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_write_some(implementation_type& impl, > const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > boost::asio::detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > service_impl_.async_write_some(impl, buffers, init.handler); > > return init.result.get(); > } > > > template <typename MutableBufferSequence> > std::size_t read_some(implementation_type& impl, > const MutableBufferSequence& buffers, boost::system::error_code& ec) > { > return service_impl_.read_some(impl, buffers, ec); > } > > > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_read_some(implementation_type& impl, > const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > boost::asio::detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > service_impl_.async_read_some(impl, buffers, init.handler); > > return init.result.get(); > } > >private: > > void shutdown_service() > { > service_impl_.shutdown_service(); > } > > > service_impl_type service_impl_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 258 "/usr/include/boost/asio/posix/stream_descriptor_service.hpp" 2 3 4 ># 29 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace posix { ># 48 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 >template <typename StreamDescriptorService = stream_descriptor_service> >class basic_stream_descriptor > : public basic_descriptor<StreamDescriptorService> >{ >public: > > > typedef typename StreamDescriptorService::native_handle_type native_type; > > > typedef typename StreamDescriptorService::native_handle_type > native_handle_type; ># 71 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > explicit basic_stream_descriptor(boost::asio::io_service& io_service) > : basic_descriptor<StreamDescriptorService>(io_service) > { > } ># 89 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > basic_stream_descriptor(boost::asio::io_service& io_service, > const native_handle_type& native_descriptor) > : basic_descriptor<StreamDescriptorService>(io_service, native_descriptor) > { > } ># 106 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > basic_stream_descriptor(basic_stream_descriptor&& other) > : basic_descriptor<StreamDescriptorService>( > static_cast<basic_stream_descriptor&&>(other)) > { > } ># 123 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > basic_stream_descriptor& operator=(basic_stream_descriptor&& other) > { > basic_descriptor<StreamDescriptorService>::operator=( > static_cast<basic_stream_descriptor&&>(other)); > return *this; > } ># 158 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().write_some( > this->get_implementation(), buffers, ec); > boost::asio::detail::throw_error(ec, "write_some"); > return s; > } ># 184 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > template <typename ConstBufferSequence> > std::size_t write_some(const ConstBufferSequence& buffers, > boost::system::error_code& ec) > { > return this->get_service().write_some( > this->get_implementation(), buffers, ec); > } ># 227 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > template <typename ConstBufferSequence, typename WriteHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_write_some(const ConstBufferSequence& buffers, > WriteHandler&& handler) > { > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_write_some(this->get_implementation(), > buffers, static_cast<WriteHandler&&>(handler)); > } ># 269 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers) > { > boost::system::error_code ec; > std::size_t s = this->get_service().read_some( > this->get_implementation(), buffers, ec); > boost::asio::detail::throw_error(ec, "read_some"); > return s; > } ># 296 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > template <typename MutableBufferSequence> > std::size_t read_some(const MutableBufferSequence& buffers, > boost::system::error_code& ec) > { > return this->get_service().read_some( > this->get_implementation(), buffers, ec); > } ># 340 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 3 4 > template <typename MutableBufferSequence, typename ReadHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > > async_read_some(const MutableBufferSequence& buffers, > ReadHandler&& handler) > { > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > return this->get_service().async_read_some(this->get_implementation(), > buffers, static_cast<ReadHandler&&>(handler)); > } >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 360 "/usr/include/boost/asio/posix/basic_stream_descriptor.hpp" 2 3 4 ># 85 "/usr/include/boost/asio.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/posix/stream_descriptor.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/posix/stream_descriptor.hpp" 3 4 >namespace boost { >namespace asio { >namespace posix { > > >typedef basic_stream_descriptor<> stream_descriptor; > >} >} >} ># 87 "/usr/include/boost/asio.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/read.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/read.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/read.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 73 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename SyncReadStream, typename MutableBufferSequence> >std::size_t read(SyncReadStream& s, const MutableBufferSequence& buffers); ># 112 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename SyncReadStream, typename MutableBufferSequence> >std::size_t read(SyncReadStream& s, const MutableBufferSequence& buffers, > boost::system::error_code& ec); ># 162 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename SyncReadStream, typename MutableBufferSequence, > typename CompletionCondition> >std::size_t read(SyncReadStream& s, const MutableBufferSequence& buffers, > CompletionCondition completion_condition); ># 206 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename SyncReadStream, typename MutableBufferSequence, > typename CompletionCondition> >std::size_t read(SyncReadStream& s, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, boost::system::error_code& ec); ># 239 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename SyncReadStream, typename Allocator> >std::size_t read(SyncReadStream& s, basic_streambuf<Allocator>& b); ># 268 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename SyncReadStream, typename Allocator> >std::size_t read(SyncReadStream& s, basic_streambuf<Allocator>& b, > boost::system::error_code& ec); ># 307 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename SyncReadStream, typename Allocator, > typename CompletionCondition> >std::size_t read(SyncReadStream& s, basic_streambuf<Allocator>& b, > CompletionCondition completion_condition); ># 348 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename SyncReadStream, typename Allocator, > typename CompletionCondition> >std::size_t read(SyncReadStream& s, basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, boost::system::error_code& ec); ># 424 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename AsyncReadStream, typename MutableBufferSequence, > typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read(AsyncReadStream& s, const MutableBufferSequence& buffers, > ReadHandler&& handler); ># 494 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename AsyncReadStream, typename MutableBufferSequence, > typename CompletionCondition, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read(AsyncReadStream& s, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, > ReadHandler&& handler); ># 552 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename AsyncReadStream, typename Allocator, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read(AsyncReadStream& s, basic_streambuf<Allocator>& b, > ReadHandler&& handler); ># 614 "/usr/include/boost/asio/read.hpp" 3 4 >template <typename AsyncReadStream, typename Allocator, > typename CompletionCondition, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read(AsyncReadStream& s, basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, > ReadHandler&& handler); > > > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 630 "/usr/include/boost/asio/read.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/read.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/impl/read.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 34 "/usr/include/boost/asio/impl/read.hpp" 2 3 4 > >namespace boost { >namespace asio { > >template <typename SyncReadStream, typename MutableBufferSequence, > typename CompletionCondition> >std::size_t read(SyncReadStream& s, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > boost::asio::detail::consuming_buffers< > mutable_buffer, MutableBufferSequence> tmp(buffers); > std::size_t total_transferred = 0; > tmp.prepare(detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred))); > while (tmp.begin() != tmp.end()) > { > std::size_t bytes_transferred = s.read_some(tmp, ec); > tmp.consume(bytes_transferred); > total_transferred += bytes_transferred; > tmp.prepare(detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred))); > } > return total_transferred; >} > >template <typename SyncReadStream, typename MutableBufferSequence> >inline std::size_t read(SyncReadStream& s, const MutableBufferSequence& buffers) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read(s, buffers, transfer_all(), ec); > boost::asio::detail::throw_error(ec, "read"); > return bytes_transferred; >} > >template <typename SyncReadStream, typename MutableBufferSequence> >inline std::size_t read(SyncReadStream& s, const MutableBufferSequence& buffers, > boost::system::error_code& ec) >{ > return read(s, buffers, transfer_all(), ec); >} > >template <typename SyncReadStream, typename MutableBufferSequence, > typename CompletionCondition> >inline std::size_t read(SyncReadStream& s, const MutableBufferSequence& buffers, > CompletionCondition completion_condition) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read(s, buffers, completion_condition, ec); > boost::asio::detail::throw_error(ec, "read"); > return bytes_transferred; >} > > > >template <typename SyncReadStream, typename Allocator, > typename CompletionCondition> >std::size_t read(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > std::size_t total_transferred = 0; > std::size_t max_size = detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred)); > std::size_t bytes_available = read_size_helper(b, max_size); > while (bytes_available > 0) > { > std::size_t bytes_transferred = s.read_some(b.prepare(bytes_available), ec); > b.commit(bytes_transferred); > total_transferred += bytes_transferred; > max_size = detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred)); > bytes_available = read_size_helper(b, max_size); > } > return total_transferred; >} > >template <typename SyncReadStream, typename Allocator> >inline std::size_t read(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read(s, b, transfer_all(), ec); > boost::asio::detail::throw_error(ec, "read"); > return bytes_transferred; >} > >template <typename SyncReadStream, typename Allocator> >inline std::size_t read(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > boost::system::error_code& ec) >{ > return read(s, b, transfer_all(), ec); >} > >template <typename SyncReadStream, typename Allocator, > typename CompletionCondition> >inline std::size_t read(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read(s, b, completion_condition, ec); > boost::asio::detail::throw_error(ec, "read"); > return bytes_transferred; >} > > > >namespace detail >{ > template <typename AsyncReadStream, typename MutableBufferSequence, > typename CompletionCondition, typename ReadHandler> > class read_op > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_op(AsyncReadStream& stream, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_op(const read_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_op(read_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > switch (start_ = start) > { > case 1: > buffers_.prepare(this->check_for_completion(ec, total_transferred_)); > for (;;) > { > stream_.async_read_some(buffers_, > static_cast<read_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > buffers_.consume(bytes_transferred); > buffers_.prepare(this->check_for_completion(ec, total_transferred_)); > if ((!ec && bytes_transferred == 0) > || buffers_.begin() == buffers_.end()) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncReadStream& stream_; > boost::asio::detail::consuming_buffers< > mutable_buffer, MutableBufferSequence> buffers_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > template <typename AsyncReadStream, > typename CompletionCondition, typename ReadHandler> > class read_op<AsyncReadStream, boost::asio::mutable_buffers_1, > CompletionCondition, ReadHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_op(AsyncReadStream& stream, > const boost::asio::mutable_buffers_1& buffers, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > buffer_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_op(const read_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_op(read_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > stream_.async_read_some( > boost::asio::buffer(buffer_ + total_transferred_, n), > static_cast<read_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == boost::asio::buffer_size(buffer_)) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncReadStream& stream_; > boost::asio::mutable_buffer buffer_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > template <typename AsyncReadStream, typename Elem, > typename CompletionCondition, typename ReadHandler> > class read_op<AsyncReadStream, boost::array<Elem, 2>, > CompletionCondition, ReadHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_op(AsyncReadStream& stream, const boost::array<Elem, 2>& buffers, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_op(const read_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_op(read_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > typename boost::asio::detail::dependent_type<Elem, > boost::array<boost::asio::mutable_buffer, 2> >::type bufs = {{ > boost::asio::mutable_buffer(buffers_[0]), > boost::asio::mutable_buffer(buffers_[1]) }}; > std::size_t buffer_size0 = boost::asio::buffer_size(bufs[0]); > std::size_t buffer_size1 = boost::asio::buffer_size(bufs[1]); > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > bufs[0] = boost::asio::buffer(bufs[0] + total_transferred_, n); > bufs[1] = boost::asio::buffer( > bufs[1] + (total_transferred_ < buffer_size0 > ? 0 : total_transferred_ - buffer_size0), > n - boost::asio::buffer_size(bufs[0])); > stream_.async_read_some(bufs, static_cast<read_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == buffer_size0 + buffer_size1) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncReadStream& stream_; > boost::array<Elem, 2> buffers_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > > > template <typename AsyncReadStream, typename Elem, > typename CompletionCondition, typename ReadHandler> > class read_op<AsyncReadStream, std::array<Elem, 2>, > CompletionCondition, ReadHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_op(AsyncReadStream& stream, const std::array<Elem, 2>& buffers, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_op(const read_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_op(read_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > typename boost::asio::detail::dependent_type<Elem, > std::array<boost::asio::mutable_buffer, 2> >::type bufs = {{ > boost::asio::mutable_buffer(buffers_[0]), > boost::asio::mutable_buffer(buffers_[1]) }}; > std::size_t buffer_size0 = boost::asio::buffer_size(bufs[0]); > std::size_t buffer_size1 = boost::asio::buffer_size(bufs[1]); > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > bufs[0] = boost::asio::buffer(bufs[0] + total_transferred_, n); > bufs[1] = boost::asio::buffer( > bufs[1] + (total_transferred_ < buffer_size0 > ? 0 : total_transferred_ - buffer_size0), > n - boost::asio::buffer_size(bufs[0])); > stream_.async_read_some(bufs, static_cast<read_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == buffer_size0 + buffer_size1) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncReadStream& stream_; > std::array<Elem, 2> buffers_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > > > template <typename AsyncReadStream, typename MutableBufferSequence, > typename CompletionCondition, typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > read_op<AsyncReadStream, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename MutableBufferSequence, > typename CompletionCondition, typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > read_op<AsyncReadStream, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename MutableBufferSequence, > typename CompletionCondition, typename ReadHandler> > inline bool asio_handler_is_continuation( > read_op<AsyncReadStream, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, > typename MutableBufferSequence, typename CompletionCondition, > typename ReadHandler> > inline void asio_handler_invoke(Function& function, > read_op<AsyncReadStream, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, > typename MutableBufferSequence, typename CompletionCondition, > typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > read_op<AsyncReadStream, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename AsyncReadStream, typename MutableBufferSequence, > typename CompletionCondition, typename ReadHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read(AsyncReadStream& s, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_op<AsyncReadStream, MutableBufferSequence, > CompletionCondition, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, buffers, completion_condition, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > >template <typename AsyncReadStream, typename MutableBufferSequence, > typename ReadHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read(AsyncReadStream& s, const MutableBufferSequence& buffers, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_op<AsyncReadStream, MutableBufferSequence, > detail::transfer_all_t, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, buffers, transfer_all(), init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > > > >namespace detail >{ > template <typename AsyncReadStream, typename Allocator, > typename CompletionCondition, typename ReadHandler> > class read_streambuf_op > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_streambuf_op(AsyncReadStream& stream, > basic_streambuf<Allocator>& streambuf, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > stream_(stream), > streambuf_(streambuf), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_streambuf_op(const read_streambuf_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > streambuf_(other.streambuf_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_streambuf_op(read_streambuf_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > stream_(other.stream_), > streambuf_(other.streambuf_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > std::size_t max_size, bytes_available; > switch (start_ = start) > { > case 1: > max_size = this->check_for_completion(ec, total_transferred_); > bytes_available = read_size_helper(streambuf_, max_size); > for (;;) > { > stream_.async_read_some(streambuf_.prepare(bytes_available), > static_cast<read_streambuf_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > streambuf_.commit(bytes_transferred); > max_size = this->check_for_completion(ec, total_transferred_); > bytes_available = read_size_helper(streambuf_, max_size); > if ((!ec && bytes_transferred == 0) || bytes_available == 0) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncReadStream& stream_; > boost::asio::basic_streambuf<Allocator>& streambuf_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > template <typename AsyncReadStream, typename Allocator, > typename CompletionCondition, typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > read_streambuf_op<AsyncReadStream, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, > typename CompletionCondition, typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > read_streambuf_op<AsyncReadStream, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, > typename CompletionCondition, typename ReadHandler> > inline bool asio_handler_is_continuation( > read_streambuf_op<AsyncReadStream, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, > typename Allocator, typename CompletionCondition, typename ReadHandler> > inline void asio_handler_invoke(Function& function, > read_streambuf_op<AsyncReadStream, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, > typename Allocator, typename CompletionCondition, typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > read_streambuf_op<AsyncReadStream, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename AsyncReadStream, typename Allocator, > typename CompletionCondition, typename ReadHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_streambuf_op<AsyncReadStream, Allocator, > CompletionCondition, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, b, completion_condition, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > >template <typename AsyncReadStream, typename Allocator, typename ReadHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_streambuf_op<AsyncReadStream, Allocator, > detail::transfer_all_t, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, b, transfer_all(), init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 754 "/usr/include/boost/asio/impl/read.hpp" 2 3 4 ># 632 "/usr/include/boost/asio/read.hpp" 2 3 4 ># 90 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/read_at.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/read_at.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/read_at.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 78 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename SyncRandomAccessReadDevice, typename MutableBufferSequence> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers); ># 123 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename SyncRandomAccessReadDevice, typename MutableBufferSequence> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > boost::system::error_code& ec); ># 178 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename SyncRandomAccessReadDevice, typename MutableBufferSequence, > typename CompletionCondition> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > CompletionCondition completion_condition); ># 227 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename SyncRandomAccessReadDevice, typename MutableBufferSequence, > typename CompletionCondition> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, boost::system::error_code& ec); ># 263 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename SyncRandomAccessReadDevice, typename Allocator> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, basic_streambuf<Allocator>& b); ># 295 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename SyncRandomAccessReadDevice, typename Allocator> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, basic_streambuf<Allocator>& b, > boost::system::error_code& ec); ># 337 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename SyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, basic_streambuf<Allocator>& b, > CompletionCondition completion_condition); ># 381 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename SyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, boost::system::error_code& ec); ># 457 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename AsyncRandomAccessReadDevice, typename MutableBufferSequence, > typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_at(AsyncRandomAccessReadDevice& d, uint64_t offset, > const MutableBufferSequence& buffers, > ReadHandler&& handler); ># 530 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename AsyncRandomAccessReadDevice, typename MutableBufferSequence, > typename CompletionCondition, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_at(AsyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, > ReadHandler&& handler); ># 586 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename AsyncRandomAccessReadDevice, typename Allocator, > typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_at(AsyncRandomAccessReadDevice& d, uint64_t offset, > basic_streambuf<Allocator>& b, ReadHandler&& handler); ># 646 "/usr/include/boost/asio/read_at.hpp" 3 4 >template <typename AsyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_at(AsyncRandomAccessReadDevice& d, > uint64_t offset, basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, > ReadHandler&& handler); > > > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 663 "/usr/include/boost/asio/read_at.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/read_at.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/impl/read_at.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 34 "/usr/include/boost/asio/impl/read_at.hpp" 2 3 4 > >namespace boost { >namespace asio { > >template <typename SyncRandomAccessReadDevice, typename MutableBufferSequence, > typename CompletionCondition> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > boost::asio::detail::consuming_buffers< > mutable_buffer, MutableBufferSequence> tmp(buffers); > std::size_t total_transferred = 0; > tmp.prepare(detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred))); > while (tmp.begin() != tmp.end()) > { > std::size_t bytes_transferred = d.read_some_at( > offset + total_transferred, tmp, ec); > tmp.consume(bytes_transferred); > total_transferred += bytes_transferred; > tmp.prepare(detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred))); > } > return total_transferred; >} > >template <typename SyncRandomAccessReadDevice, typename MutableBufferSequence> >inline std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read_at( > d, offset, buffers, transfer_all(), ec); > boost::asio::detail::throw_error(ec, "read_at"); > return bytes_transferred; >} > >template <typename SyncRandomAccessReadDevice, typename MutableBufferSequence> >inline std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > boost::system::error_code& ec) >{ > return read_at(d, offset, buffers, transfer_all(), ec); >} > >template <typename SyncRandomAccessReadDevice, typename MutableBufferSequence, > typename CompletionCondition> >inline std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > CompletionCondition completion_condition) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read_at( > d, offset, buffers, completion_condition, ec); > boost::asio::detail::throw_error(ec, "read_at"); > return bytes_transferred; >} > > > >template <typename SyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition> >std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > std::size_t total_transferred = 0; > std::size_t max_size = detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred)); > std::size_t bytes_available = read_size_helper(b, max_size); > while (bytes_available > 0) > { > std::size_t bytes_transferred = d.read_some_at( > offset + total_transferred, b.prepare(bytes_available), ec); > b.commit(bytes_transferred); > total_transferred += bytes_transferred; > max_size = detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred)); > bytes_available = read_size_helper(b, max_size); > } > return total_transferred; >} > >template <typename SyncRandomAccessReadDevice, typename Allocator> >inline std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read_at( > d, offset, b, transfer_all(), ec); > boost::asio::detail::throw_error(ec, "read_at"); > return bytes_transferred; >} > >template <typename SyncRandomAccessReadDevice, typename Allocator> >inline std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > boost::system::error_code& ec) >{ > return read_at(d, offset, b, transfer_all(), ec); >} > >template <typename SyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition> >inline std::size_t read_at(SyncRandomAccessReadDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read_at( > d, offset, b, completion_condition, ec); > boost::asio::detail::throw_error(ec, "read_at"); > return bytes_transferred; >} > > > >namespace detail >{ > template <typename AsyncRandomAccessReadDevice, > typename MutableBufferSequence, typename CompletionCondition, > typename ReadHandler> > class read_at_op > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_at_op(AsyncRandomAccessReadDevice& device, > uint64_t offset, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_at_op(const read_at_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_at_op(read_at_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > switch (start_ = start) > { > case 1: > buffers_.prepare(this->check_for_completion(ec, total_transferred_)); > for (;;) > { > device_.async_read_some_at(offset_ + total_transferred_, > buffers_, static_cast<read_at_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > buffers_.consume(bytes_transferred); > buffers_.prepare(this->check_for_completion(ec, total_transferred_)); > if ((!ec && bytes_transferred == 0) > || buffers_.begin() == buffers_.end()) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessReadDevice& device_; > uint64_t offset_; > boost::asio::detail::consuming_buffers< > mutable_buffer, MutableBufferSequence> buffers_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > template <typename AsyncRandomAccessReadDevice, > typename CompletionCondition, typename ReadHandler> > class read_at_op<AsyncRandomAccessReadDevice, > boost::asio::mutable_buffers_1, CompletionCondition, ReadHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_at_op(AsyncRandomAccessReadDevice& device, > uint64_t offset, const boost::asio::mutable_buffers_1& buffers, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > buffer_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_at_op(const read_at_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_at_op(read_at_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > device_.async_read_some_at(offset_ + total_transferred_, > boost::asio::buffer(buffer_ + total_transferred_, n), > static_cast<read_at_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == boost::asio::buffer_size(buffer_)) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessReadDevice& device_; > uint64_t offset_; > boost::asio::mutable_buffer buffer_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > template <typename AsyncRandomAccessReadDevice, typename Elem, > typename CompletionCondition, typename ReadHandler> > class read_at_op<AsyncRandomAccessReadDevice, boost::array<Elem, 2>, > CompletionCondition, ReadHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_at_op(AsyncRandomAccessReadDevice& device, > uint64_t offset, const boost::array<Elem, 2>& buffers, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_at_op(const read_at_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_at_op(read_at_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > typename boost::asio::detail::dependent_type<Elem, > boost::array<boost::asio::mutable_buffer, 2> >::type bufs = {{ > boost::asio::mutable_buffer(buffers_[0]), > boost::asio::mutable_buffer(buffers_[1]) }}; > std::size_t buffer_size0 = boost::asio::buffer_size(bufs[0]); > std::size_t buffer_size1 = boost::asio::buffer_size(bufs[1]); > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > bufs[0] = boost::asio::buffer(bufs[0] + total_transferred_, n); > bufs[1] = boost::asio::buffer( > bufs[1] + (total_transferred_ < buffer_size0 > ? 0 : total_transferred_ - buffer_size0), > n - boost::asio::buffer_size(bufs[0])); > device_.async_read_some_at(offset_ + total_transferred_, > bufs, static_cast<read_at_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == buffer_size0 + buffer_size1) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessReadDevice& device_; > uint64_t offset_; > boost::array<Elem, 2> buffers_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > > > template <typename AsyncRandomAccessReadDevice, typename Elem, > typename CompletionCondition, typename ReadHandler> > class read_at_op<AsyncRandomAccessReadDevice, std::array<Elem, 2>, > CompletionCondition, ReadHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_at_op(AsyncRandomAccessReadDevice& device, > uint64_t offset, const std::array<Elem, 2>& buffers, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_at_op(const read_at_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_at_op(read_at_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > typename boost::asio::detail::dependent_type<Elem, > std::array<boost::asio::mutable_buffer, 2> >::type bufs = {{ > boost::asio::mutable_buffer(buffers_[0]), > boost::asio::mutable_buffer(buffers_[1]) }}; > std::size_t buffer_size0 = boost::asio::buffer_size(bufs[0]); > std::size_t buffer_size1 = boost::asio::buffer_size(bufs[1]); > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > bufs[0] = boost::asio::buffer(bufs[0] + total_transferred_, n); > bufs[1] = boost::asio::buffer( > bufs[1] + (total_transferred_ < buffer_size0 > ? 0 : total_transferred_ - buffer_size0), > n - boost::asio::buffer_size(bufs[0])); > device_.async_read_some_at(offset_ + total_transferred_, > bufs, static_cast<read_at_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == buffer_size0 + buffer_size1) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessReadDevice& device_; > uint64_t offset_; > std::array<Elem, 2> buffers_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > > > template <typename AsyncRandomAccessReadDevice, > typename MutableBufferSequence, typename CompletionCondition, > typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > read_at_op<AsyncRandomAccessReadDevice, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncRandomAccessReadDevice, > typename MutableBufferSequence, typename CompletionCondition, > typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > read_at_op<AsyncRandomAccessReadDevice, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncRandomAccessReadDevice, > typename MutableBufferSequence, typename CompletionCondition, > typename ReadHandler> > inline bool asio_handler_is_continuation( > read_at_op<AsyncRandomAccessReadDevice, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncRandomAccessReadDevice, > typename MutableBufferSequence, typename CompletionCondition, > typename ReadHandler> > inline void asio_handler_invoke(Function& function, > read_at_op<AsyncRandomAccessReadDevice, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncRandomAccessReadDevice, > typename MutableBufferSequence, typename CompletionCondition, > typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > read_at_op<AsyncRandomAccessReadDevice, MutableBufferSequence, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename AsyncRandomAccessReadDevice, > typename MutableBufferSequence, typename CompletionCondition, > typename ReadHandler> > inline read_at_op<AsyncRandomAccessReadDevice, > MutableBufferSequence, CompletionCondition, ReadHandler> > make_read_at_op(AsyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, ReadHandler handler) > { > return read_at_op<AsyncRandomAccessReadDevice, > MutableBufferSequence, CompletionCondition, ReadHandler>( > d, offset, buffers, completion_condition, handler); > } >} > >template <typename AsyncRandomAccessReadDevice, typename MutableBufferSequence, > typename CompletionCondition, typename ReadHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_at(AsyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > CompletionCondition completion_condition, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_at_op<AsyncRandomAccessReadDevice, MutableBufferSequence, > CompletionCondition, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > d, offset, buffers, completion_condition, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > >template <typename AsyncRandomAccessReadDevice, typename MutableBufferSequence, > typename ReadHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_at(AsyncRandomAccessReadDevice& d, > uint64_t offset, const MutableBufferSequence& buffers, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_at_op<AsyncRandomAccessReadDevice, MutableBufferSequence, > detail::transfer_all_t, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > d, offset, buffers, transfer_all(), init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > > > >namespace detail >{ > template <typename AsyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition, typename ReadHandler> > class read_at_streambuf_op > : detail::base_from_completion_cond<CompletionCondition> > { > public: > read_at_streambuf_op(AsyncRandomAccessReadDevice& device, > uint64_t offset, basic_streambuf<Allocator>& streambuf, > CompletionCondition completion_condition, ReadHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > streambuf_(streambuf), > start_(0), > total_transferred_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_at_streambuf_op(const read_at_streambuf_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > streambuf_(other.streambuf_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > read_at_streambuf_op(read_at_streambuf_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > streambuf_(other.streambuf_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > std::size_t max_size, bytes_available; > switch (start_ = start) > { > case 1: > max_size = this->check_for_completion(ec, total_transferred_); > bytes_available = read_size_helper(streambuf_, max_size); > for (;;) > { > device_.async_read_some_at(offset_ + total_transferred_, > streambuf_.prepare(bytes_available), > static_cast<read_at_streambuf_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > streambuf_.commit(bytes_transferred); > max_size = this->check_for_completion(ec, total_transferred_); > bytes_available = read_size_helper(streambuf_, max_size); > if ((!ec && bytes_transferred == 0) || bytes_available == 0) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessReadDevice& device_; > uint64_t offset_; > boost::asio::basic_streambuf<Allocator>& streambuf_; > int start_; > std::size_t total_transferred_; > ReadHandler handler_; > }; > > template <typename AsyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition, typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > read_at_streambuf_op<AsyncRandomAccessReadDevice, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition, typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > read_at_streambuf_op<AsyncRandomAccessReadDevice, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition, typename ReadHandler> > inline bool asio_handler_is_continuation( > read_at_streambuf_op<AsyncRandomAccessReadDevice, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncRandomAccessReadDevice, > typename Allocator, typename CompletionCondition, typename ReadHandler> > inline void asio_handler_invoke(Function& function, > read_at_streambuf_op<AsyncRandomAccessReadDevice, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncRandomAccessReadDevice, > typename Allocator, typename CompletionCondition, typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > read_at_streambuf_op<AsyncRandomAccessReadDevice, Allocator, > CompletionCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename AsyncRandomAccessReadDevice, typename Allocator, > typename CompletionCondition, typename ReadHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_at(AsyncRandomAccessReadDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_at_streambuf_op<AsyncRandomAccessReadDevice, Allocator, > CompletionCondition, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > d, offset, b, completion_condition, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > >template <typename AsyncRandomAccessReadDevice, typename Allocator, > typename ReadHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_at(AsyncRandomAccessReadDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_at_streambuf_op<AsyncRandomAccessReadDevice, Allocator, > detail::transfer_all_t, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > d, offset, b, transfer_all(), init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 811 "/usr/include/boost/asio/impl/read_at.hpp" 2 3 4 ># 665 "/usr/include/boost/asio/read_at.hpp" 2 3 4 ># 91 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/read_until.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/read_until.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/regex_fwd.hpp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/regex_fwd.hpp" 3 4 ># 1 "/usr/include/boost/regex_fwd.hpp" 1 3 4 ># 24 "/usr/include/boost/regex_fwd.hpp" 3 4 ># 1 "/usr/include/boost/regex/config.hpp" 1 3 4 ># 41 "/usr/include/boost/regex/config.hpp" 3 4 ># 1 "/usr/include/boost/regex/user.hpp" 1 3 4 ># 42 "/usr/include/boost/regex/config.hpp" 2 3 4 ># 121 "/usr/include/boost/regex/config.hpp" 3 4 ># 1 "/usr/include/boost/regex/config/cwchar.hpp" 1 3 4 ># 22 "/usr/include/boost/regex/config/cwchar.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cwchar" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cwchar" 3 4 ># 40 "/usr/include/c++/4.9.0/cwchar" 3 > > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 45 "/usr/include/c++/4.9.0/cwchar" 2 3 ># 23 "/usr/include/boost/regex/config/cwchar.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cwctype" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cwctype" 3 4 ># 40 "/usr/include/c++/4.9.0/cwctype" 3 ># 24 "/usr/include/boost/regex/config/cwchar.hpp" 2 3 4 ># 49 "/usr/include/boost/regex/config/cwchar.hpp" 3 4 >namespace std{ > > >extern "C"{ ># 201 "/usr/include/boost/regex/config/cwchar.hpp" 3 4 >} > > >} ># 122 "/usr/include/boost/regex/config.hpp" 2 3 4 ># 218 "/usr/include/boost/regex/config.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 219 "/usr/include/boost/regex/config.hpp" 2 3 4 ># 390 "/usr/include/boost/regex/config.hpp" 3 4 >namespace boost{ namespace re_detail{ > > void* get_mem_block(); > void put_mem_block(void*); > >}} ># 25 "/usr/include/boost/regex_fwd.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_fwd.hpp" 1 3 4 ># 37 "/usr/include/boost/regex/v4/regex_fwd.hpp" 3 4 >namespace boost{ > >template <class charT> >class cpp_regex_traits; >template <class charT> >struct c_regex_traits; >template <class charT> >class w32_regex_traits; > > > > > >template <class charT, class implementationT = cpp_regex_traits<charT> > >struct regex_traits; > > > > > >template <class charT, class traits = regex_traits<charT> > >class basic_regex; > >typedef basic_regex<char, regex_traits<char> > regex; > >typedef basic_regex<wchar_t, regex_traits<wchar_t> > wregex; > > >} ># 28 "/usr/include/boost/regex_fwd.hpp" 2 3 4 ># 21 "/usr/include/boost/asio/detail/regex_fwd.hpp" 2 3 4 ># 1 "/usr/include/boost/regex/v4/match_flags.hpp" 1 3 4 ># 23 "/usr/include/boost/regex/v4/match_flags.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 24 "/usr/include/boost/regex/v4/match_flags.hpp" 2 3 4 > > > >namespace boost{ > namespace regex_constants{ > > >typedef enum _match_flags >{ > match_default = 0, > match_not_bol = 1, > match_not_eol = match_not_bol << 1, > match_not_bob = match_not_eol << 1, > match_not_eob = match_not_bob << 1, > match_not_bow = match_not_eob << 1, > match_not_eow = match_not_bow << 1, > match_not_dot_newline = match_not_eow << 1, > match_not_dot_null = match_not_dot_newline << 1, > match_prev_avail = match_not_dot_null << 1, > match_init = match_prev_avail << 1, > match_any = match_init << 1, > match_not_null = match_any << 1, > match_continuous = match_not_null << 1, > > match_partial = match_continuous << 1, > > match_stop = match_partial << 1, > match_not_initial_null = match_stop, > match_all = match_stop << 1, > match_perl = match_all << 1, > match_posix = match_perl << 1, > match_nosubs = match_posix << 1, > match_extra = match_nosubs << 1, > match_single_line = match_extra << 1, > match_unused1 = match_single_line << 1, > match_unused2 = match_unused1 << 1, > match_unused3 = match_unused2 << 1, > match_max = match_unused3, > > format_perl = 0, > format_default = 0, > format_sed = match_max << 1, > format_all = format_sed << 1, > format_no_copy = format_all << 1, > format_first_only = format_no_copy << 1, > format_is_if = format_first_only << 1, > format_literal = format_is_if << 1 > >} match_flags; > > > > >typedef match_flags match_flag_type; > > > >inline match_flags operator&(match_flags m1, match_flags m2) >{ return static_cast<match_flags>(static_cast<boost::int32_t>(m1) & static_cast<boost::int32_t>(m2)); } >inline match_flags operator|(match_flags m1, match_flags m2) >{ return static_cast<match_flags>(static_cast<boost::int32_t>(m1) | static_cast<boost::int32_t>(m2)); } >inline match_flags operator^(match_flags m1, match_flags m2) >{ return static_cast<match_flags>(static_cast<boost::int32_t>(m1) ^ static_cast<boost::int32_t>(m2)); } >inline match_flags operator~(match_flags m1) >{ return static_cast<match_flags>(~static_cast<boost::int32_t>(m1)); } >inline match_flags& operator&=(match_flags& m1, match_flags m2) >{ m1 = m1&m2; return m1; } >inline match_flags& operator|=(match_flags& m1, match_flags m2) >{ m1 = m1|m2; return m1; } >inline match_flags& operator^=(match_flags& m1, match_flags m2) >{ m1 = m1^m2; return m1; } > > > > >} > > > >using regex_constants::match_flag_type; >using regex_constants::match_default; >using regex_constants::match_not_bol; >using regex_constants::match_not_eol; >using regex_constants::match_not_bob; >using regex_constants::match_not_eob; >using regex_constants::match_not_bow; >using regex_constants::match_not_eow; >using regex_constants::match_not_dot_newline; >using regex_constants::match_not_dot_null; >using regex_constants::match_prev_avail; > >using regex_constants::match_any; >using regex_constants::match_not_null; >using regex_constants::match_continuous; >using regex_constants::match_partial; > >using regex_constants::match_all; >using regex_constants::match_perl; >using regex_constants::match_posix; >using regex_constants::match_nosubs; >using regex_constants::match_extra; >using regex_constants::match_single_line; > >using regex_constants::format_all; >using regex_constants::format_sed; >using regex_constants::format_perl; >using regex_constants::format_default; >using regex_constants::format_no_copy; >using regex_constants::format_first_only; > > >} ># 22 "/usr/include/boost/asio/detail/regex_fwd.hpp" 2 3 4 > >namespace boost { > >template <class BidiIterator> >struct sub_match; > >template <class BidiIterator, class Allocator> >class match_results; > >} ># 27 "/usr/include/boost/asio/read_until.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/read_until.hpp" 2 3 4 > >namespace boost { >namespace asio { > >namespace detail >{ > char (&has_result_type_helper(...))[2]; > > template <typename T> > char has_result_type_helper(T*, typename T::result_type* = 0); > > template <typename T> > struct has_result_type > { > enum { value = (sizeof((has_result_type_helper)((T*)(0))) == 1) }; > }; >} > > > >template <typename T> >struct is_match_condition >{ > > > > > enum > { > value = boost::asio::is_function< > typename boost::asio::remove_pointer<T>::type>::value > || detail::has_result_type<T>::value > }; > >}; ># 123 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename SyncReadStream, typename Allocator> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, char delim); ># 157 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename SyncReadStream, typename Allocator> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, char delim, > boost::system::error_code& ec); ># 210 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename SyncReadStream, typename Allocator> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const std::string& delim); ># 244 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename SyncReadStream, typename Allocator> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const std::string& delim, > boost::system::error_code& ec); ># 302 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename SyncReadStream, typename Allocator> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const boost::regex& expr); ># 339 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename SyncReadStream, typename Allocator> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const boost::regex& expr, > boost::system::error_code& ec); ># 446 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename SyncReadStream, typename Allocator, typename MatchCondition> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, MatchCondition match_condition, > typename enable_if<is_match_condition<MatchCondition>::value>::type* = 0); ># 501 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename SyncReadStream, typename Allocator, typename MatchCondition> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > MatchCondition match_condition, boost::system::error_code& ec, > typename enable_if<is_match_condition<MatchCondition>::value>::type* = 0); ># 595 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename AsyncReadStream, typename Allocator, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_until(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > char delim, ReadHandler&& handler); ># 680 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename AsyncReadStream, typename Allocator, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_until(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const std::string& delim, > ReadHandler&& handler); ># 772 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename AsyncReadStream, typename Allocator, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_until(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const boost::regex& expr, > ReadHandler&& handler); ># 905 "/usr/include/boost/asio/read_until.hpp" 3 4 >template <typename AsyncReadStream, typename Allocator, > typename MatchCondition, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_until(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > MatchCondition match_condition, ReadHandler&& handler, > typename enable_if<is_match_condition<MatchCondition>::value>::type* = 0); > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 920 "/usr/include/boost/asio/read_until.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/read_until.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/impl/read_until.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 33 "/usr/include/boost/asio/impl/read_until.hpp" 2 3 4 > >namespace boost { >namespace asio { > >template <typename SyncReadStream, typename Allocator> >inline std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, char delim) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read_until(s, b, delim, ec); > boost::asio::detail::throw_error(ec, "read_until"); > return bytes_transferred; >} > >template <typename SyncReadStream, typename Allocator> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, char delim, > boost::system::error_code& ec) >{ > std::size_t search_position = 0; > for (;;) > { > > typedef typename boost::asio::basic_streambuf< > Allocator>::const_buffers_type const_buffers_type; > typedef boost::asio::buffers_iterator<const_buffers_type> iterator; > const_buffers_type buffers = b.data(); > iterator begin = iterator::begin(buffers); > iterator start_pos = begin + search_position; > iterator end = iterator::end(buffers); > > > iterator iter = std::find(start_pos, end, delim); > if (iter != end) > { > > ec = boost::system::error_code(); > return iter - begin + 1; > } > else > { > > search_position = end - begin; > } > > > if (b.size() == b.max_size()) > { > ec = error::not_found; > return 0; > } > > > std::size_t bytes_to_read = read_size_helper(b, 65536); > b.commit(s.read_some(b.prepare(bytes_to_read), ec)); > if (ec) > return 0; > } >} > >template <typename SyncReadStream, typename Allocator> >inline std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const std::string& delim) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read_until(s, b, delim, ec); > boost::asio::detail::throw_error(ec, "read_until"); > return bytes_transferred; >} > >namespace detail >{ > > > > > > > template <typename Iterator1, typename Iterator2> > std::pair<Iterator1, bool> partial_search( > Iterator1 first1, Iterator1 last1, Iterator2 first2, Iterator2 last2) > { > for (Iterator1 iter1 = first1; iter1 != last1; ++iter1) > { > Iterator1 test_iter1 = iter1; > Iterator2 test_iter2 = first2; > for (;; ++test_iter1, ++test_iter2) > { > if (test_iter2 == last2) > return std::make_pair(iter1, true); > if (test_iter1 == last1) > { > if (test_iter2 != first2) > return std::make_pair(iter1, false); > else > break; > } > if (*test_iter1 != *test_iter2) > break; > } > } > return std::make_pair(last1, false); > } >} > >template <typename SyncReadStream, typename Allocator> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const std::string& delim, > boost::system::error_code& ec) >{ > std::size_t search_position = 0; > for (;;) > { > > typedef typename boost::asio::basic_streambuf< > Allocator>::const_buffers_type const_buffers_type; > typedef boost::asio::buffers_iterator<const_buffers_type> iterator; > const_buffers_type buffers = b.data(); > iterator begin = iterator::begin(buffers); > iterator start_pos = begin + search_position; > iterator end = iterator::end(buffers); > > > std::pair<iterator, bool> result = detail::partial_search( > start_pos, end, delim.begin(), delim.end()); > if (result.first != end) > { > if (result.second) > { > > ec = boost::system::error_code(); > return result.first - begin + delim.length(); > } > else > { > > search_position = result.first - begin; > } > } > else > { > > search_position = end - begin; > } > > > if (b.size() == b.max_size()) > { > ec = error::not_found; > return 0; > } > > > std::size_t bytes_to_read = read_size_helper(b, 65536); > b.commit(s.read_some(b.prepare(bytes_to_read), ec)); > if (ec) > return 0; > } >} > > > >template <typename SyncReadStream, typename Allocator> >inline std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const boost::regex& expr) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read_until(s, b, expr, ec); > boost::asio::detail::throw_error(ec, "read_until"); > return bytes_transferred; >} > >template <typename SyncReadStream, typename Allocator> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const boost::regex& expr, > boost::system::error_code& ec) >{ > std::size_t search_position = 0; > for (;;) > { > > typedef typename boost::asio::basic_streambuf< > Allocator>::const_buffers_type const_buffers_type; > typedef boost::asio::buffers_iterator<const_buffers_type> iterator; > const_buffers_type buffers = b.data(); > iterator begin = iterator::begin(buffers); > iterator start_pos = begin + search_position; > iterator end = iterator::end(buffers); > > > boost::match_results<iterator, > typename std::vector<boost::sub_match<iterator> >::allocator_type> > match_results; > if (regex_search(start_pos, end, match_results, expr, > boost::match_default | boost::match_partial)) > { > if (match_results[0].matched) > { > > ec = boost::system::error_code(); > return match_results[0].second - begin; > } > else > { > > search_position = match_results[0].first - begin; > } > } > else > { > > search_position = end - begin; > } > > > if (b.size() == b.max_size()) > { > ec = error::not_found; > return 0; > } > > > std::size_t bytes_to_read = read_size_helper(b, 65536); > b.commit(s.read_some(b.prepare(bytes_to_read), ec)); > if (ec) > return 0; > } >} > > > >template <typename SyncReadStream, typename Allocator, typename MatchCondition> >std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > MatchCondition match_condition, boost::system::error_code& ec, > typename enable_if<is_match_condition<MatchCondition>::value>::type*) >{ > std::size_t search_position = 0; > for (;;) > { > > typedef typename boost::asio::basic_streambuf< > Allocator>::const_buffers_type const_buffers_type; > typedef boost::asio::buffers_iterator<const_buffers_type> iterator; > const_buffers_type buffers = b.data(); > iterator begin = iterator::begin(buffers); > iterator start_pos = begin + search_position; > iterator end = iterator::end(buffers); > > > std::pair<iterator, bool> result = match_condition(start_pos, end); > if (result.second) > { > > ec = boost::system::error_code(); > return result.first - begin; > } > else if (result.first != end) > { > > search_position = result.first - begin; > } > else > { > > search_position = end - begin; > } > > > if (b.size() == b.max_size()) > { > ec = error::not_found; > return 0; > } > > > std::size_t bytes_to_read = read_size_helper(b, 65536); > b.commit(s.read_some(b.prepare(bytes_to_read), ec)); > if (ec) > return 0; > } >} > >template <typename SyncReadStream, typename Allocator, typename MatchCondition> >inline std::size_t read_until(SyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, MatchCondition match_condition, > typename enable_if<is_match_condition<MatchCondition>::value>::type*) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = read_until(s, b, match_condition, ec); > boost::asio::detail::throw_error(ec, "read_until"); > return bytes_transferred; >} > >namespace detail >{ > template <typename AsyncReadStream, typename Allocator, typename ReadHandler> > class read_until_delim_op > { > public: > read_until_delim_op(AsyncReadStream& stream, > boost::asio::basic_streambuf<Allocator>& streambuf, > char delim, ReadHandler& handler) > : stream_(stream), > streambuf_(streambuf), > delim_(delim), > start_(0), > search_position_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_until_delim_op(const read_until_delim_op& other) > : stream_(other.stream_), > streambuf_(other.streambuf_), > delim_(other.delim_), > start_(other.start_), > search_position_(other.search_position_), > handler_(other.handler_) > { > } > > read_until_delim_op(read_until_delim_op&& other) > : stream_(other.stream_), > streambuf_(other.streambuf_), > delim_(other.delim_), > start_(other.start_), > search_position_(other.search_position_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > const std::size_t not_found = (std::numeric_limits<std::size_t>::max)(); > std::size_t bytes_to_read; > switch (start_ = start) > { > case 1: > for (;;) > { > { > > typedef typename boost::asio::basic_streambuf< > Allocator>::const_buffers_type const_buffers_type; > typedef boost::asio::buffers_iterator<const_buffers_type> iterator; > const_buffers_type buffers = streambuf_.data(); > iterator begin = iterator::begin(buffers); > iterator start_pos = begin + search_position_; > iterator end = iterator::end(buffers); > > > iterator iter = std::find(start_pos, end, delim_); > if (iter != end) > { > > search_position_ = iter - begin + 1; > bytes_to_read = 0; > } > > > else if (streambuf_.size() == streambuf_.max_size()) > { > search_position_ = not_found; > bytes_to_read = 0; > } > > > else > { > > search_position_ = end - begin; > bytes_to_read = read_size_helper(streambuf_, 65536); > } > } > > > if (!start && bytes_to_read == 0) > break; > > > stream_.async_read_some(streambuf_.prepare(bytes_to_read), > static_cast<read_until_delim_op&&>(*this)); > return; default: > streambuf_.commit(bytes_transferred); > if (ec || bytes_transferred == 0) > break; > } > > const boost::system::error_code result_ec = > (search_position_ == not_found) > ? error::not_found : ec; > > const std::size_t result_n = > (ec || search_position_ == not_found) > ? 0 : search_position_; > > handler_(result_ec, result_n); > } > } > > > AsyncReadStream& stream_; > boost::asio::basic_streambuf<Allocator>& streambuf_; > char delim_; > int start_; > std::size_t search_position_; > ReadHandler handler_; > }; > > template <typename AsyncReadStream, typename Allocator, typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > read_until_delim_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > read_until_delim_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, typename ReadHandler> > inline bool asio_handler_is_continuation( > read_until_delim_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, typename Allocator, > typename ReadHandler> > inline void asio_handler_invoke(Function& function, > read_until_delim_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, typename Allocator, > typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > read_until_delim_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename AsyncReadStream, typename Allocator, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_until(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, char delim, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_until_delim_op<AsyncReadStream, > Allocator, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, b, delim, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > >namespace detail >{ > template <typename AsyncReadStream, typename Allocator, typename ReadHandler> > class read_until_delim_string_op > { > public: > read_until_delim_string_op(AsyncReadStream& stream, > boost::asio::basic_streambuf<Allocator>& streambuf, > const std::string& delim, ReadHandler& handler) > : stream_(stream), > streambuf_(streambuf), > delim_(delim), > start_(0), > search_position_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_until_delim_string_op(const read_until_delim_string_op& other) > : stream_(other.stream_), > streambuf_(other.streambuf_), > delim_(other.delim_), > start_(other.start_), > search_position_(other.search_position_), > handler_(other.handler_) > { > } > > read_until_delim_string_op(read_until_delim_string_op&& other) > : stream_(other.stream_), > streambuf_(other.streambuf_), > delim_(static_cast<std::string&&>(other.delim_)), > start_(other.start_), > search_position_(other.search_position_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > const std::size_t not_found = (std::numeric_limits<std::size_t>::max)(); > std::size_t bytes_to_read; > switch (start_ = start) > { > case 1: > for (;;) > { > { > > typedef typename boost::asio::basic_streambuf< > Allocator>::const_buffers_type const_buffers_type; > typedef boost::asio::buffers_iterator<const_buffers_type> iterator; > const_buffers_type buffers = streambuf_.data(); > iterator begin = iterator::begin(buffers); > iterator start_pos = begin + search_position_; > iterator end = iterator::end(buffers); > > > std::pair<iterator, bool> result = detail::partial_search( > start_pos, end, delim_.begin(), delim_.end()); > if (result.first != end && result.second) > { > > search_position_ = result.first - begin + delim_.length(); > bytes_to_read = 0; > } > > > else if (streambuf_.size() == streambuf_.max_size()) > { > search_position_ = not_found; > bytes_to_read = 0; > } > > > else > { > if (result.first != end) > { > > > search_position_ = result.first - begin; > } > else > { > > search_position_ = end - begin; > } > > bytes_to_read = read_size_helper(streambuf_, 65536); > } > } > > > if (!start && bytes_to_read == 0) > break; > > > stream_.async_read_some(streambuf_.prepare(bytes_to_read), > static_cast<read_until_delim_string_op&&>(*this)); > return; default: > streambuf_.commit(bytes_transferred); > if (ec || bytes_transferred == 0) > break; > } > > const boost::system::error_code result_ec = > (search_position_ == not_found) > ? error::not_found : ec; > > const std::size_t result_n = > (ec || search_position_ == not_found) > ? 0 : search_position_; > > handler_(result_ec, result_n); > } > } > > > AsyncReadStream& stream_; > boost::asio::basic_streambuf<Allocator>& streambuf_; > std::string delim_; > int start_; > std::size_t search_position_; > ReadHandler handler_; > }; > > template <typename AsyncReadStream, typename Allocator, typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > read_until_delim_string_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > read_until_delim_string_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, typename ReadHandler> > inline bool asio_handler_is_continuation( > read_until_delim_string_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, > typename Allocator, typename ReadHandler> > inline void asio_handler_invoke(Function& function, > read_until_delim_string_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, > typename Allocator, typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > read_until_delim_string_op<AsyncReadStream, > Allocator, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename AsyncReadStream, typename Allocator, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_until(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const std::string& delim, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_until_delim_string_op<AsyncReadStream, > Allocator, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, b, delim, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > > > >namespace detail >{ > template <typename AsyncReadStream, typename Allocator, > typename RegEx, typename ReadHandler> > class read_until_expr_op > { > public: > read_until_expr_op(AsyncReadStream& stream, > boost::asio::basic_streambuf<Allocator>& streambuf, > const boost::regex& expr, ReadHandler& handler) > : stream_(stream), > streambuf_(streambuf), > expr_(expr), > start_(0), > search_position_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_until_expr_op(const read_until_expr_op& other) > : stream_(other.stream_), > streambuf_(other.streambuf_), > expr_(other.expr_), > start_(other.start_), > search_position_(other.search_position_), > handler_(other.handler_) > { > } > > read_until_expr_op(read_until_expr_op&& other) > : stream_(other.stream_), > streambuf_(other.streambuf_), > expr_(other.expr_), > start_(other.start_), > search_position_(other.search_position_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > const std::size_t not_found = (std::numeric_limits<std::size_t>::max)(); > std::size_t bytes_to_read; > switch (start_ = start) > { > case 1: > for (;;) > { > { > > typedef typename boost::asio::basic_streambuf< > Allocator>::const_buffers_type const_buffers_type; > typedef boost::asio::buffers_iterator<const_buffers_type> iterator; > const_buffers_type buffers = streambuf_.data(); > iterator begin = iterator::begin(buffers); > iterator start_pos = begin + search_position_; > iterator end = iterator::end(buffers); > > > boost::match_results<iterator, > typename std::vector<boost::sub_match<iterator> >::allocator_type> > match_results; > bool match = regex_search(start_pos, end, match_results, expr_, > boost::match_default | boost::match_partial); > if (match && match_results[0].matched) > { > > search_position_ = match_results[0].second - begin; > bytes_to_read = 0; > } > > > else if (streambuf_.size() == streambuf_.max_size()) > { > search_position_ = not_found; > bytes_to_read = 0; > } > > > else > { > if (match) > { > > > search_position_ = match_results[0].first - begin; > } > else > { > > search_position_ = end - begin; > } > > bytes_to_read = read_size_helper(streambuf_, 65536); > } > } > > > if (!start && bytes_to_read == 0) > break; > > > stream_.async_read_some(streambuf_.prepare(bytes_to_read), > static_cast<read_until_expr_op&&>(*this)); > return; default: > streambuf_.commit(bytes_transferred); > if (ec || bytes_transferred == 0) > break; > } > > const boost::system::error_code result_ec = > (search_position_ == not_found) > ? error::not_found : ec; > > const std::size_t result_n = > (ec || search_position_ == not_found) > ? 0 : search_position_; > > handler_(result_ec, result_n); > } > } > > > AsyncReadStream& stream_; > boost::asio::basic_streambuf<Allocator>& streambuf_; > RegEx expr_; > int start_; > std::size_t search_position_; > ReadHandler handler_; > }; > > template <typename AsyncReadStream, typename Allocator, > typename RegEx, typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > read_until_expr_op<AsyncReadStream, > Allocator, RegEx, ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, > typename RegEx, typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > read_until_expr_op<AsyncReadStream, > Allocator, RegEx, ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, > typename RegEx, typename ReadHandler> > inline bool asio_handler_is_continuation( > read_until_expr_op<AsyncReadStream, > Allocator, RegEx, ReadHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, typename Allocator, > typename RegEx, typename ReadHandler> > inline void asio_handler_invoke(Function& function, > read_until_expr_op<AsyncReadStream, > Allocator, RegEx, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, typename Allocator, > typename RegEx, typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > read_until_expr_op<AsyncReadStream, > Allocator, RegEx, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename AsyncReadStream, typename Allocator, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_until(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, const boost::regex& expr, > ReadHandler&& handler) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_until_expr_op<AsyncReadStream, Allocator, > boost::regex, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, b, expr, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > > > >namespace detail >{ > template <typename AsyncReadStream, typename Allocator, > typename MatchCondition, typename ReadHandler> > class read_until_match_op > { > public: > read_until_match_op(AsyncReadStream& stream, > boost::asio::basic_streambuf<Allocator>& streambuf, > MatchCondition match_condition, ReadHandler& handler) > : stream_(stream), > streambuf_(streambuf), > match_condition_(match_condition), > start_(0), > search_position_(0), > handler_(static_cast<ReadHandler&&>(handler)) > { > } > > > read_until_match_op(const read_until_match_op& other) > : stream_(other.stream_), > streambuf_(other.streambuf_), > match_condition_(other.match_condition_), > start_(other.start_), > search_position_(other.search_position_), > handler_(other.handler_) > { > } > > read_until_match_op(read_until_match_op&& other) > : stream_(other.stream_), > streambuf_(other.streambuf_), > match_condition_(other.match_condition_), > start_(other.start_), > search_position_(other.search_position_), > handler_(static_cast<ReadHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > const std::size_t not_found = (std::numeric_limits<std::size_t>::max)(); > std::size_t bytes_to_read; > switch (start_ = start) > { > case 1: > for (;;) > { > { > > typedef typename boost::asio::basic_streambuf< > Allocator>::const_buffers_type const_buffers_type; > typedef boost::asio::buffers_iterator<const_buffers_type> iterator; > const_buffers_type buffers = streambuf_.data(); > iterator begin = iterator::begin(buffers); > iterator start_pos = begin + search_position_; > iterator end = iterator::end(buffers); > > > std::pair<iterator, bool> result = match_condition_(start_pos, end); > if (result.second) > { > > search_position_ = result.first - begin; > bytes_to_read = 0; > } > > > else if (streambuf_.size() == streambuf_.max_size()) > { > search_position_ = not_found; > bytes_to_read = 0; > } > > > else > { > if (result.first != end) > { > > > search_position_ = result.first - begin; > } > else > { > > search_position_ = end - begin; > } > > bytes_to_read = read_size_helper(streambuf_, 65536); > } > } > > > if (!start && bytes_to_read == 0) > break; > > > stream_.async_read_some(streambuf_.prepare(bytes_to_read), > static_cast<read_until_match_op&&>(*this)); > return; default: > streambuf_.commit(bytes_transferred); > if (ec || bytes_transferred == 0) > break; > } > > const boost::system::error_code result_ec = > (search_position_ == not_found) > ? error::not_found : ec; > > const std::size_t result_n = > (ec || search_position_ == not_found) > ? 0 : search_position_; > > handler_(result_ec, result_n); > } > } > > > AsyncReadStream& stream_; > boost::asio::basic_streambuf<Allocator>& streambuf_; > MatchCondition match_condition_; > int start_; > std::size_t search_position_; > ReadHandler handler_; > }; > > template <typename AsyncReadStream, typename Allocator, > typename MatchCondition, typename ReadHandler> > inline void* asio_handler_allocate(std::size_t size, > read_until_match_op<AsyncReadStream, > Allocator, MatchCondition, ReadHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, > typename MatchCondition, typename ReadHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > read_until_match_op<AsyncReadStream, > Allocator, MatchCondition, ReadHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncReadStream, typename Allocator, > typename MatchCondition, typename ReadHandler> > inline bool asio_handler_is_continuation( > read_until_match_op<AsyncReadStream, > Allocator, MatchCondition, ReadHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, typename Allocator, > typename MatchCondition, typename ReadHandler> > inline void asio_handler_invoke(Function& function, > read_until_match_op<AsyncReadStream, > Allocator, MatchCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncReadStream, typename Allocator, > typename MatchCondition, typename ReadHandler> > inline void asio_handler_invoke(const Function& function, > read_until_match_op<AsyncReadStream, > Allocator, MatchCondition, ReadHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } >} > >template <typename AsyncReadStream, typename Allocator, > typename MatchCondition, typename ReadHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_read_until(AsyncReadStream& s, > boost::asio::basic_streambuf<Allocator>& b, > MatchCondition match_condition, ReadHandler&& handler, > typename enable_if<is_match_condition<MatchCondition>::value>::type*) >{ > > > typedef typename handler_type<ReadHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "ReadHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > ReadHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<ReadHandler&&>(handler)); > > detail::read_until_match_op<AsyncReadStream, Allocator, > MatchCondition, typename handler_type<ReadHandler, void (boost::system::error_code, std::size_t)>::type > >( > s, b, match_condition, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 1148 "/usr/include/boost/asio/impl/read_until.hpp" 2 3 4 ># 922 "/usr/include/boost/asio/read_until.hpp" 2 3 4 ># 92 "/usr/include/boost/asio.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/serial_port.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/serial_port.hpp" 3 4 >namespace boost { >namespace asio { > > >typedef basic_serial_port<> serial_port; > >} >} ># 94 "/usr/include/boost/asio.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/signal_set.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/signal_set.hpp" 3 4 >namespace boost { >namespace asio { > > >typedef basic_signal_set<> signal_set; > >} >} ># 97 "/usr/include/boost/asio.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/strand.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/strand.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/strand_service.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/strand_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/strand_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > > >class strand_service > : public boost::asio::detail::service_base<strand_service> >{ >private: > > struct on_do_complete_exit; > > > struct on_dispatch_exit; > >public: > > > class strand_impl > : public operation > { > public: > strand_impl(); > > private: > > friend class strand_service; > friend struct on_do_complete_exit; > friend struct on_dispatch_exit; > > > boost::asio::detail::mutex mutex_; > > > > > bool locked_; > > > > > op_queue<operation> waiting_queue_; > > > > > op_queue<operation> ready_queue_; > }; > > typedef strand_impl* implementation_type; > > > inline explicit strand_service(boost::asio::io_service& io_service); > > > inline void shutdown_service(); > > > inline void construct(implementation_type& impl); > > > template <typename Handler> > void dispatch(implementation_type& impl, Handler& handler); > > > template <typename Handler> > void post(implementation_type& impl, Handler& handler); > > > inline bool running_in_this_thread( > const implementation_type& impl) const; > >private: > > > inline bool do_dispatch(implementation_type& impl, operation* op); > > > inline void do_post(implementation_type& impl, > operation* op, bool is_continuation); > > inline static void do_complete(io_service_impl* owner, > operation* base, const boost::system::error_code& ec, > std::size_t bytes_transferred); > > > io_service_impl& io_service_; > > > boost::asio::detail::mutex mutex_; > > > > > > enum { num_implementations = 193 }; > > > > scoped_ptr<strand_impl> implementations_[num_implementations]; > > > > std::size_t salt_; >}; > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 138 "/usr/include/boost/asio/detail/strand_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/impl/strand_service.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/detail/impl/strand_service.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/detail/impl/strand_service.hpp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >inline strand_service::strand_impl::strand_impl() > : operation(&strand_service::do_complete), > locked_(false) >{ >} > >struct strand_service::on_dispatch_exit >{ > io_service_impl* io_service_; > strand_impl* impl_; > > ~on_dispatch_exit() > { > impl_->mutex_.lock(); > impl_->ready_queue_.push(impl_->waiting_queue_); > bool more_handlers = impl_->locked_ = !impl_->ready_queue_.empty(); > impl_->mutex_.unlock(); > > if (more_handlers) > io_service_->post_immediate_completion(impl_, false); > } >}; > >template <typename Handler> >void strand_service::dispatch(strand_service::implementation_type& impl, > Handler& handler) >{ > > if (call_stack<strand_impl>::contains(impl)) > { > fenced_block b(fenced_block::full); > boost_asio_handler_invoke_helpers::invoke(handler, handler); > return; > } > > > typedef completion_handler<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0; > > bool dispatch_immediately = do_dispatch(impl, p.p); > operation* o = p.p; > p.v = p.p = 0; > > if (dispatch_immediately) > { > > call_stack<strand_impl>::context ctx(impl); > > > on_dispatch_exit on_exit = { &io_service_, impl }; > (void)on_exit; > > completion_handler<Handler>::do_complete( > &io_service_, o, boost::system::error_code(), 0); > } >} > > >template <typename Handler> >void strand_service::post(strand_service::implementation_type& impl, > Handler& handler) >{ > bool is_continuation = > boost_asio_handler_cont_helpers::is_continuation(handler); > > > typedef completion_handler<Handler> op; > typename op::ptr p = { boost::asio::detail::addressof(handler), > boost_asio_handler_alloc_helpers::allocate( > sizeof(op), handler), 0 }; > p.p = new (p.v) op(handler); > > (void)0; > > do_post(impl, p.p, is_continuation); > p.v = p.p = 0; >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 119 "/usr/include/boost/asio/detail/impl/strand_service.hpp" 2 3 4 ># 140 "/usr/include/boost/asio/detail/strand_service.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/impl/strand_service.ipp" 1 3 4 ># 20 "/usr/include/boost/asio/detail/impl/strand_service.ipp" 3 4 ># 1 "/usr/include/boost/asio/detail/strand_service.hpp" 1 3 4 ># 21 "/usr/include/boost/asio/detail/impl/strand_service.ipp" 2 3 4 > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 23 "/usr/include/boost/asio/detail/impl/strand_service.ipp" 2 3 4 > >namespace boost { >namespace asio { >namespace detail { > >struct strand_service::on_do_complete_exit >{ > io_service_impl* owner_; > strand_impl* impl_; > > ~on_do_complete_exit() > { > impl_->mutex_.lock(); > impl_->ready_queue_.push(impl_->waiting_queue_); > bool more_handlers = impl_->locked_ = !impl_->ready_queue_.empty(); > impl_->mutex_.unlock(); > > if (more_handlers) > owner_->post_immediate_completion(impl_, true); > } >}; > >strand_service::strand_service(boost::asio::io_service& io_service) > : boost::asio::detail::service_base<strand_service>(io_service), > io_service_(boost::asio::use_service<io_service_impl>(io_service)), > mutex_(), > salt_(0) >{ >} > >void strand_service::shutdown_service() >{ > op_queue<operation> ops; > > boost::asio::detail::mutex::scoped_lock lock(mutex_); > > for (std::size_t i = 0; i < num_implementations; ++i) > { > if (strand_impl* impl = implementations_[i].get()) > { > ops.push(impl->waiting_queue_); > ops.push(impl->ready_queue_); > } > } >} > >void strand_service::construct(strand_service::implementation_type& impl) >{ > boost::asio::detail::mutex::scoped_lock lock(mutex_); > > std::size_t salt = salt_++; > > > > std::size_t index = reinterpret_cast<std::size_t>(&impl); > index += (reinterpret_cast<std::size_t>(&impl) >> 3); > index ^= salt + 0x9e3779b9 + (index << 6) + (index >> 2); > > index = index % num_implementations; > > if (!implementations_[index].get()) > implementations_[index].reset(new strand_impl); > impl = implementations_[index].get(); >} > >bool strand_service::running_in_this_thread( > const implementation_type& impl) const >{ > return call_stack<strand_impl>::contains(impl) != 0; >} > >bool strand_service::do_dispatch(implementation_type& impl, operation* op) >{ > > > bool can_dispatch = io_service_.can_dispatch(); > impl->mutex_.lock(); > if (can_dispatch && !impl->locked_) > { > > impl->locked_ = true; > impl->mutex_.unlock(); > return true; > } > > if (impl->locked_) > { > > impl->waiting_queue_.push(op); > impl->mutex_.unlock(); > } > else > { > > > impl->locked_ = true; > impl->mutex_.unlock(); > impl->ready_queue_.push(op); > io_service_.post_immediate_completion(impl, false); > } > > return false; >} > >void strand_service::do_post(implementation_type& impl, > operation* op, bool is_continuation) >{ > impl->mutex_.lock(); > if (impl->locked_) > { > > impl->waiting_queue_.push(op); > impl->mutex_.unlock(); > } > else > { > > > impl->locked_ = true; > impl->mutex_.unlock(); > impl->ready_queue_.push(op); > io_service_.post_immediate_completion(impl, is_continuation); > } >} > >void strand_service::do_complete(io_service_impl* owner, operation* base, > const boost::system::error_code& ec, std::size_t ) >{ > if (owner) > { > strand_impl* impl = static_cast<strand_impl*>(base); > > > call_stack<strand_impl>::context ctx(impl); > > > on_do_complete_exit on_exit = { owner, impl }; > (void)on_exit; > > > > while (operation* o = impl->ready_queue_.front()) > { > impl->ready_queue_.pop(); > o->complete(*owner, ec, 0); > } > } >} > >} >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 177 "/usr/include/boost/asio/detail/impl/strand_service.ipp" 2 3 4 ># 142 "/usr/include/boost/asio/detail/strand_service.hpp" 2 3 4 ># 22 "/usr/include/boost/asio/strand.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/strand.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 86 "/usr/include/boost/asio/strand.hpp" 3 4 >class io_service::strand >{ >public: > > > > > > > > explicit strand(boost::asio::io_service& io_service) > : service_(boost::asio::use_service< > boost::asio::detail::strand_service>(io_service)) > { > service_.construct(impl_); > } ># 110 "/usr/include/boost/asio/strand.hpp" 3 4 > ~strand() > { > } ># 122 "/usr/include/boost/asio/strand.hpp" 3 4 > boost::asio::io_service& get_io_service() > { > return service_.get_io_service(); > } ># 146 "/usr/include/boost/asio/strand.hpp" 3 4 > template <typename CompletionHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<CompletionHandler, void ()>::type>::type > dispatch(CompletionHandler&& handler) > { > > > typedef typename handler_type<CompletionHandler, void()>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::zero_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), 0)) == 1, "CompletionHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()(), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > CompletionHandler, void ()> init( > static_cast<CompletionHandler&&>(handler)); > > service_.dispatch(impl_, init.handler); > > return init.result.get(); > } ># 179 "/usr/include/boost/asio/strand.hpp" 3 4 > template <typename CompletionHandler> > typename ::boost::asio::async_result< typename ::boost::asio::handler_type<CompletionHandler, void ()>::type>::type > post(CompletionHandler&& handler) > { > > > typedef typename handler_type<CompletionHandler, void()>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::zero_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), 0)) == 1, "CompletionHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()(), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > CompletionHandler, void ()> init( > static_cast<CompletionHandler&&>(handler)); > > service_.post(impl_, init.handler); > > return init.result.get(); > } ># 217 "/usr/include/boost/asio/strand.hpp" 3 4 > template <typename Handler> > > > > detail::wrapped_handler<strand, Handler, detail::is_continuation_if_running> > > wrap(Handler handler) > { > return detail::wrapped_handler<io_service::strand, Handler, > detail::is_continuation_if_running>(*this, handler); > } > > > > > > > > bool running_in_this_thread() const > { > return service_.running_in_this_thread(impl_); > } > >private: > boost::asio::detail::strand_service& service_; > boost::asio::detail::strand_service::implementation_type impl_; >}; > > >typedef boost::asio::io_service::strand strand; > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 252 "/usr/include/boost/asio/strand.hpp" 2 3 4 ># 101 "/usr/include/boost/asio.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/streambuf.hpp" 1 3 4 ># 24 "/usr/include/boost/asio/streambuf.hpp" 3 4 >namespace boost { >namespace asio { > > >typedef basic_streambuf<> streambuf; > >} >} ># 103 "/usr/include/boost/asio.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/version.hpp" 1 3 4 ># 105 "/usr/include/boost/asio.hpp" 2 3 4 > > ># 1 "/usr/include/boost/asio/windows/basic_handle.hpp" 1 3 4 ># 108 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/basic_object_handle.hpp" 1 3 4 ># 109 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/basic_random_access_handle.hpp" 1 3 4 ># 110 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/basic_stream_handle.hpp" 1 3 4 ># 111 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/object_handle.hpp" 1 3 4 ># 112 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/object_handle_service.hpp" 1 3 4 ># 113 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/overlapped_ptr.hpp" 1 3 4 ># 114 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/random_access_handle.hpp" 1 3 4 ># 115 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/random_access_handle_service.hpp" 1 3 4 ># 116 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/stream_handle.hpp" 1 3 4 ># 117 "/usr/include/boost/asio.hpp" 2 3 4 ># 1 "/usr/include/boost/asio/windows/stream_handle_service.hpp" 1 3 4 ># 118 "/usr/include/boost/asio.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/write_at.hpp" 1 3 4 ># 25 "/usr/include/boost/asio/write_at.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 26 "/usr/include/boost/asio/write_at.hpp" 2 3 4 > >namespace boost { >namespace asio { ># 76 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence> >std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers); ># 120 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence> >std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > boost::system::error_code& ec); ># 174 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition> >std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > CompletionCondition completion_condition); ># 222 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition> >std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, boost::system::error_code& ec); ># 259 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename SyncRandomAccessWriteDevice, typename Allocator> >std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, basic_streambuf<Allocator>& b); ># 292 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename SyncRandomAccessWriteDevice, typename Allocator> >std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, basic_streambuf<Allocator>& b, > boost::system::error_code& ec); ># 335 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename SyncRandomAccessWriteDevice, typename Allocator, > typename CompletionCondition> >std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, > basic_streambuf<Allocator>& b, CompletionCondition completion_condition); ># 379 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename SyncRandomAccessWriteDevice, typename Allocator, > typename CompletionCondition> >std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, > basic_streambuf<Allocator>& b, CompletionCondition completion_condition, > boost::system::error_code& ec); ># 452 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write_at(AsyncRandomAccessWriteDevice& d, uint64_t offset, > const ConstBufferSequence& buffers, > WriteHandler&& handler); ># 531 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write_at(AsyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, > WriteHandler&& handler); ># 587 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename AsyncRandomAccessWriteDevice, typename Allocator, > typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write_at(AsyncRandomAccessWriteDevice& d, uint64_t offset, > basic_streambuf<Allocator>& b, WriteHandler&& handler); ># 653 "/usr/include/boost/asio/write_at.hpp" 3 4 >template <typename AsyncRandomAccessWriteDevice, typename Allocator, > typename CompletionCondition, typename WriteHandler> >typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write_at(AsyncRandomAccessWriteDevice& d, uint64_t offset, > basic_streambuf<Allocator>& b, CompletionCondition completion_condition, > WriteHandler&& handler); > > > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 669 "/usr/include/boost/asio/write_at.hpp" 2 3 4 > ># 1 "/usr/include/boost/asio/impl/write_at.hpp" 1 3 4 ># 31 "/usr/include/boost/asio/impl/write_at.hpp" 3 4 ># 1 "/usr/include/boost/asio/detail/push_options.hpp" 1 3 4 ># 32 "/usr/include/boost/asio/impl/write_at.hpp" 2 3 4 > >namespace boost { >namespace asio { > >template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition> >std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, boost::system::error_code& ec) >{ > ec = boost::system::error_code(); > boost::asio::detail::consuming_buffers< > const_buffer, ConstBufferSequence> tmp(buffers); > std::size_t total_transferred = 0; > tmp.prepare(detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred))); > while (tmp.begin() != tmp.end()) > { > std::size_t bytes_transferred = d.write_some_at( > offset + total_transferred, tmp, ec); > tmp.consume(bytes_transferred); > total_transferred += bytes_transferred; > tmp.prepare(detail::adapt_completion_condition_result( > completion_condition(ec, total_transferred))); > } > return total_transferred; >} > >template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence> >inline std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = write_at( > d, offset, buffers, transfer_all(), ec); > boost::asio::detail::throw_error(ec, "write_at"); > return bytes_transferred; >} > >template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence> >inline std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > boost::system::error_code& ec) >{ > return write_at(d, offset, buffers, transfer_all(), ec); >} > >template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition> >inline std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > CompletionCondition completion_condition) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = write_at( > d, offset, buffers, completion_condition, ec); > boost::asio::detail::throw_error(ec, "write_at"); > return bytes_transferred; >} > > > >template <typename SyncRandomAccessWriteDevice, typename Allocator, > typename CompletionCondition> >std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, boost::system::error_code& ec) >{ > std::size_t bytes_transferred = write_at( > d, offset, b.data(), completion_condition, ec); > b.consume(bytes_transferred); > return bytes_transferred; >} > >template <typename SyncRandomAccessWriteDevice, typename Allocator> >inline std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = write_at(d, offset, b, transfer_all(), ec); > boost::asio::detail::throw_error(ec, "write_at"); > return bytes_transferred; >} > >template <typename SyncRandomAccessWriteDevice, typename Allocator> >inline std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > boost::system::error_code& ec) >{ > return write_at(d, offset, b, transfer_all(), ec); >} > >template <typename SyncRandomAccessWriteDevice, typename Allocator, > typename CompletionCondition> >inline std::size_t write_at(SyncRandomAccessWriteDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition) >{ > boost::system::error_code ec; > std::size_t bytes_transferred = write_at( > d, offset, b, completion_condition, ec); > boost::asio::detail::throw_error(ec, "write_at"); > return bytes_transferred; >} > > > >namespace detail >{ > template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> > class write_at_op > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_at_op(AsyncRandomAccessWriteDevice& device, > uint64_t offset, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_at_op(const write_at_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_at_op(write_at_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > switch (start_ = start) > { > case 1: > buffers_.prepare(this->check_for_completion(ec, total_transferred_)); > for (;;) > { > device_.async_write_some_at( > offset_ + total_transferred_, buffers_, > static_cast<write_at_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > buffers_.consume(bytes_transferred); > buffers_.prepare(this->check_for_completion(ec, total_transferred_)); > if ((!ec && bytes_transferred == 0) > || buffers_.begin() == buffers_.end()) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessWriteDevice& device_; > uint64_t offset_; > boost::asio::detail::consuming_buffers< > const_buffer, ConstBufferSequence> buffers_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > template <typename AsyncRandomAccessWriteDevice, > typename CompletionCondition, typename WriteHandler> > class write_at_op<AsyncRandomAccessWriteDevice, > boost::asio::mutable_buffers_1, CompletionCondition, WriteHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_at_op(AsyncRandomAccessWriteDevice& device, > uint64_t offset, const boost::asio::mutable_buffers_1& buffers, > CompletionCondition completion_condition, > WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > buffer_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_at_op(const write_at_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_at_op(write_at_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > device_.async_write_some_at(offset_ + total_transferred_, > boost::asio::buffer(buffer_ + total_transferred_, n), > static_cast<write_at_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == boost::asio::buffer_size(buffer_)) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessWriteDevice& device_; > uint64_t offset_; > boost::asio::mutable_buffer buffer_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > template <typename AsyncRandomAccessWriteDevice, > typename CompletionCondition, typename WriteHandler> > class write_at_op<AsyncRandomAccessWriteDevice, boost::asio::const_buffers_1, > CompletionCondition, WriteHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_at_op(AsyncRandomAccessWriteDevice& device, > uint64_t offset, const boost::asio::const_buffers_1& buffers, > CompletionCondition completion_condition, > WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > buffer_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_at_op(const write_at_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_at_op(write_at_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffer_(other.buffer_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > device_.async_write_some_at(offset_ + total_transferred_, > boost::asio::buffer(buffer_ + total_transferred_, n), > static_cast<write_at_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == boost::asio::buffer_size(buffer_)) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessWriteDevice& device_; > uint64_t offset_; > boost::asio::const_buffer buffer_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > template <typename AsyncRandomAccessWriteDevice, typename Elem, > typename CompletionCondition, typename WriteHandler> > class write_at_op<AsyncRandomAccessWriteDevice, boost::array<Elem, 2>, > CompletionCondition, WriteHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_at_op(AsyncRandomAccessWriteDevice& device, > uint64_t offset, const boost::array<Elem, 2>& buffers, > CompletionCondition completion_condition, WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_at_op(const write_at_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_at_op(write_at_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > typename boost::asio::detail::dependent_type<Elem, > boost::array<boost::asio::const_buffer, 2> >::type bufs = {{ > boost::asio::const_buffer(buffers_[0]), > boost::asio::const_buffer(buffers_[1]) }}; > std::size_t buffer_size0 = boost::asio::buffer_size(bufs[0]); > std::size_t buffer_size1 = boost::asio::buffer_size(bufs[1]); > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > bufs[0] = boost::asio::buffer(bufs[0] + total_transferred_, n); > bufs[1] = boost::asio::buffer( > bufs[1] + (total_transferred_ < buffer_size0 > ? 0 : total_transferred_ - buffer_size0), > n - boost::asio::buffer_size(bufs[0])); > device_.async_write_some_at(offset_ + total_transferred_, > bufs, static_cast<write_at_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == buffer_size0 + buffer_size1) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessWriteDevice& device_; > uint64_t offset_; > boost::array<Elem, 2> buffers_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > > > template <typename AsyncRandomAccessWriteDevice, typename Elem, > typename CompletionCondition, typename WriteHandler> > class write_at_op<AsyncRandomAccessWriteDevice, std::array<Elem, 2>, > CompletionCondition, WriteHandler> > : detail::base_from_completion_cond<CompletionCondition> > { > public: > write_at_op(AsyncRandomAccessWriteDevice& device, > uint64_t offset, const std::array<Elem, 2>& buffers, > CompletionCondition completion_condition, WriteHandler& handler) > : detail::base_from_completion_cond< > CompletionCondition>(completion_condition), > device_(device), > offset_(offset), > buffers_(buffers), > start_(0), > total_transferred_(0), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_at_op(const write_at_op& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(other.handler_) > { > } > > write_at_op(write_at_op&& other) > : detail::base_from_completion_cond<CompletionCondition>(other), > device_(other.device_), > offset_(other.offset_), > buffers_(other.buffers_), > start_(other.start_), > total_transferred_(other.total_transferred_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > std::size_t bytes_transferred, int start = 0) > { > typename boost::asio::detail::dependent_type<Elem, > std::array<boost::asio::const_buffer, 2> >::type bufs = {{ > boost::asio::const_buffer(buffers_[0]), > boost::asio::const_buffer(buffers_[1]) }}; > std::size_t buffer_size0 = boost::asio::buffer_size(bufs[0]); > std::size_t buffer_size1 = boost::asio::buffer_size(bufs[1]); > std::size_t n = 0; > switch (start_ = start) > { > case 1: > n = this->check_for_completion(ec, total_transferred_); > for (;;) > { > bufs[0] = boost::asio::buffer(bufs[0] + total_transferred_, n); > bufs[1] = boost::asio::buffer( > bufs[1] + (total_transferred_ < buffer_size0 > ? 0 : total_transferred_ - buffer_size0), > n - boost::asio::buffer_size(bufs[0])); > device_.async_write_some_at(offset_ + total_transferred_, > bufs, static_cast<write_at_op&&>(*this)); > return; default: > total_transferred_ += bytes_transferred; > if ((!ec && bytes_transferred == 0) > || (n = this->check_for_completion(ec, total_transferred_)) == 0 > || total_transferred_ == buffer_size0 + buffer_size1) > break; > } > > handler_(ec, static_cast<const std::size_t&>(total_transferred_)); > } > } > > > AsyncRandomAccessWriteDevice& device_; > uint64_t offset_; > std::array<Elem, 2> buffers_; > int start_; > std::size_t total_transferred_; > WriteHandler handler_; > }; > > > > template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> > inline void* asio_handler_allocate(std::size_t size, > write_at_op<AsyncRandomAccessWriteDevice, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > write_at_op<AsyncRandomAccessWriteDevice, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> > inline bool asio_handler_is_continuation( > write_at_op<AsyncRandomAccessWriteDevice, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > return this_handler->start_ == 0 ? true > : boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename AsyncRandomAccessWriteDevice, > typename ConstBufferSequence, typename CompletionCondition, > typename WriteHandler> > inline void asio_handler_invoke(Function& function, > write_at_op<AsyncRandomAccessWriteDevice, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename AsyncRandomAccessWriteDevice, > typename ConstBufferSequence, typename CompletionCondition, > typename WriteHandler> > inline void asio_handler_invoke(const Function& function, > write_at_op<AsyncRandomAccessWriteDevice, ConstBufferSequence, > CompletionCondition, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> > inline write_at_op<AsyncRandomAccessWriteDevice, > ConstBufferSequence, CompletionCondition, WriteHandler> > make_write_at_op(AsyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, WriteHandler handler) > { > return write_at_op<AsyncRandomAccessWriteDevice, > ConstBufferSequence, CompletionCondition, WriteHandler>( > d, offset, buffers, completion_condition, handler); > } >} > >template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename CompletionCondition, typename WriteHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write_at(AsyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > CompletionCondition completion_condition, > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > detail::write_at_op<AsyncRandomAccessWriteDevice, ConstBufferSequence, > CompletionCondition, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > d, offset, buffers, completion_condition, init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > >template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, > typename WriteHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write_at(AsyncRandomAccessWriteDevice& d, > uint64_t offset, const ConstBufferSequence& buffers, > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > detail::write_at_op<AsyncRandomAccessWriteDevice, ConstBufferSequence, > detail::transfer_all_t, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > d, offset, buffers, transfer_all(), init.handler)( > boost::system::error_code(), 0, 1); > > return init.result.get(); >} > > > >namespace detail >{ > template <typename Allocator, typename WriteHandler> > class write_at_streambuf_op > { > public: > write_at_streambuf_op( > boost::asio::basic_streambuf<Allocator>& streambuf, > WriteHandler& handler) > : streambuf_(streambuf), > handler_(static_cast<WriteHandler&&>(handler)) > { > } > > > write_at_streambuf_op(const write_at_streambuf_op& other) > : streambuf_(other.streambuf_), > handler_(other.handler_) > { > } > > write_at_streambuf_op(write_at_streambuf_op&& other) > : streambuf_(other.streambuf_), > handler_(static_cast<WriteHandler&&>(other.handler_)) > { > } > > > void operator()(const boost::system::error_code& ec, > const std::size_t bytes_transferred) > { > streambuf_.consume(bytes_transferred); > handler_(ec, bytes_transferred); > } > > > boost::asio::basic_streambuf<Allocator>& streambuf_; > WriteHandler handler_; > }; > > template <typename Allocator, typename WriteHandler> > inline void* asio_handler_allocate(std::size_t size, > write_at_streambuf_op<Allocator, WriteHandler>* this_handler) > { > return boost_asio_handler_alloc_helpers::allocate( > size, this_handler->handler_); > } > > template <typename Allocator, typename WriteHandler> > inline void asio_handler_deallocate(void* pointer, std::size_t size, > write_at_streambuf_op<Allocator, WriteHandler>* this_handler) > { > boost_asio_handler_alloc_helpers::deallocate( > pointer, size, this_handler->handler_); > } > > template <typename Allocator, typename WriteHandler> > inline bool asio_handler_is_continuation( > write_at_streambuf_op<Allocator, WriteHandler>* this_handler) > { > return boost_asio_handler_cont_helpers::is_continuation( > this_handler->handler_); > } > > template <typename Function, typename Allocator, typename WriteHandler> > inline void asio_handler_invoke(Function& function, > write_at_streambuf_op<Allocator, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Function, typename Allocator, typename WriteHandler> > inline void asio_handler_invoke(const Function& function, > write_at_streambuf_op<Allocator, WriteHandler>* this_handler) > { > boost_asio_handler_invoke_helpers::invoke( > function, this_handler->handler_); > } > > template <typename Allocator, typename WriteHandler> > inline write_at_streambuf_op<Allocator, WriteHandler> > make_write_at_streambuf_op( > boost::asio::basic_streambuf<Allocator>& b, WriteHandler handler) > { > return write_at_streambuf_op<Allocator, WriteHandler>(b, handler); > } >} > >template <typename AsyncRandomAccessWriteDevice, typename Allocator, > typename CompletionCondition, typename WriteHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write_at(AsyncRandomAccessWriteDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > CompletionCondition completion_condition, > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > async_write_at(d, offset, b.data(), completion_condition, > detail::write_at_streambuf_op<Allocator, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > b, init.handler)); > > return init.result.get(); >} > >template <typename AsyncRandomAccessWriteDevice, typename Allocator, > typename WriteHandler> >inline typename ::boost::asio::async_result< typename ::boost::asio::handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type>::type > >async_write_at(AsyncRandomAccessWriteDevice& d, > uint64_t offset, boost::asio::basic_streambuf<Allocator>& b, > WriteHandler&& handler) >{ > > > typedef typename handler_type<WriteHandler, void(boost::system::error_code, std::size_t)>::type asio_true_handler_type; static_assert(sizeof(boost::asio::detail::two_arg_handler_test( boost::asio::detail::clvref< asio_true_handler_type>(), static_cast<const boost::system::error_code*>(0), static_cast<const std::size_t*>(0))) == 1, "WriteHandler type requirements not met"); typedef boost::asio::detail::handler_type_requirements< sizeof( boost::asio::detail::argbyv( boost::asio::detail::clvref< asio_true_handler_type>())) + sizeof( boost::asio::detail::lvref< asio_true_handler_type>()( boost::asio::detail::lvref<const boost::system::error_code>(), boost::asio::detail::lvref<const std::size_t>()), char(0))> __attribute__((__unused__)) type_check; > > detail::async_result_init< > WriteHandler, void (boost::system::error_code, std::size_t)> init( > static_cast<WriteHandler&&>(handler)); > > async_write_at(d, offset, b.data(), transfer_all(), > detail::write_at_streambuf_op<Allocator, typename handler_type<WriteHandler, void (boost::system::error_code, std::size_t)>::type > >( > b, init.handler)); > > return init.result.get(); >} > > > >} >} > ># 1 "/usr/include/boost/asio/detail/pop_options.hpp" 1 3 4 ># 826 "/usr/include/boost/asio/impl/write_at.hpp" 2 3 4 ># 671 "/usr/include/boost/asio/write_at.hpp" 2 3 4 ># 120 "/usr/include/boost/asio.hpp" 2 3 4 ># 40 "/c/honeypenny/contrib/epee/include/string_tools.h" 2 > > ># 1 "/c/honeypenny/contrib/epee/include/warnings.h" 1 ># 43 "/c/honeypenny/contrib/epee/include/string_tools.h" 2 ># 53 "/c/honeypenny/contrib/epee/include/string_tools.h" >namespace epee >{ >namespace string_tools >{ > inline std::wstring get_str_from_guid(const boost::uuids::uuid& rid) > { > return boost::lexical_cast<std::wstring>(rid); > } > > inline std::string get_str_from_guid_a(const boost::uuids::uuid& rid) > { > return boost::lexical_cast<std::string>(rid); > } > > inline bool get_guid_from_string( boost::uuids::uuid& inetifer, std::wstring str_id) > { > if(str_id.size() < 36) > return false; > > if('{' == *str_id.begin()) > str_id.erase(0, 1); > > if('}' == *(--str_id.end())) > str_id.erase(--str_id.end()); > > try > { > inetifer = boost::lexical_cast<boost::uuids::uuid>(str_id); > return true; > } > catch(...) > { > return false; > } > } > > inline bool get_guid_from_string( boost::uuids::uuid& inetifer, const std::string& str_id) > { > std::string local_str_id = str_id; > if(local_str_id.size() < 36) > return false; > > if('{' == *local_str_id.begin()) > local_str_id.erase(0, 1); > > if('}' == *(--local_str_id.end())) > local_str_id.erase(--local_str_id.end()); > > try > { > inetifer = boost::lexical_cast<boost::uuids::uuid>(local_str_id); > return true; > } > catch(...) > { > return false; > } > } > > template<class CharT> > std::basic_string<CharT> buff_to_hex(const std::basic_string<CharT>& s) > { > using namespace std; > basic_stringstream<CharT> hexStream; > hexStream << hex << noshowbase << setw(2); > > for(typename std::basic_string<CharT>::const_iterator it = s.begin(); it != s.end(); it++) > { > hexStream << "0x"<< static_cast<unsigned int>(static_cast<unsigned char>(*it)) << " "; > } > return hexStream.str(); > } > > template<class CharT> > std::basic_string<CharT> buff_to_hex_nodelimer(const std::basic_string<CharT>& s) > { > using namespace std; > basic_stringstream<CharT> hexStream; > hexStream << hex << noshowbase; > > for(typename std::basic_string<CharT>::const_iterator it = s.begin(); it != s.end(); it++) > { > hexStream << setw(2) << setfill('0') << static_cast<unsigned int>(static_cast<unsigned char>(*it)); > } > return hexStream.str(); > } > > template<class CharT> > bool parse_hexstr_to_binbuff(const std::basic_string<CharT>& s, std::basic_string<CharT>& res) > { > res.clear(); > try > { > long v = 0; > for(size_t i = 0; i < (s.size() + 1) / 2; i++) > { > CharT byte_str[3]; > size_t copied = s.copy(byte_str, 2, 2 * i); > byte_str[copied] = CharT(0); > CharT* endptr; > v = strtoul(byte_str, &endptr, 16); > if (v < 0 || 0xFF < v || endptr != byte_str + copied) > { > return false; > } > res.push_back(static_cast<unsigned char>(v)); > } > > return true; > }catch(...) > { > return false; > } > } > > template<class t_pod_type> > bool parse_tpod_from_hex_string(const std::string& str_hash, t_pod_type& t_pod) > { > std::string buf; > bool res = epee::string_tools::parse_hexstr_to_binbuff(str_hash, buf); > if (!res || buf.size() != sizeof(t_pod_type)) > { > return false; > } > else > { > buf.copy(reinterpret_cast<char *>(&t_pod), sizeof(t_pod_type)); > return true; > } > } ># 184 "/c/honeypenny/contrib/epee/include/string_tools.h" >#pragma GCC diagnostic push ># 184 "/c/honeypenny/contrib/epee/include/string_tools.h" ># 185 "/c/honeypenny/contrib/epee/include/string_tools.h" >#pragma GCC diagnostic ignored "-Wmaybe-uninitialized" ># 185 "/c/honeypenny/contrib/epee/include/string_tools.h" > > template<class XType> > inline bool get_xtype_from_string( XType& val, const std::string& str_id) > { > if (std::is_integral<XType>::value && !std::numeric_limits<XType>::is_signed && !std::is_same<XType, bool>::value) > { > for (char c : str_id) > { > if (!std::isdigit(c)) > return false; > } > } > > try > { > val = boost::lexical_cast<XType>(str_id); > return true; > } > catch(std::exception& ) > { > > return false; > } > catch(...) > { > return false; > } > > return true; > } ># 215 "/c/honeypenny/contrib/epee/include/string_tools.h" >#pragma GCC diagnostic pop ># 215 "/c/honeypenny/contrib/epee/include/string_tools.h" > > > template<typename int_t> > bool get_xnum_from_hex_string(const std::string str, int_t& res ) > { > try > { > std::stringstream ss; > ss << std::hex << str; > ss >> res; > return true; > } > catch(...) > { > return false; > } > } > > template<class XType> > inline bool xtype_to_string(const XType& val, std::string& str) > { > try > { > str = boost::lexical_cast<std::string>(val); > } > catch(...) > { > return false; > } > > return true; > } > > typedef std::map<std::string, std::string> command_line_params_a; > typedef std::map<std::wstring, std::wstring> command_line_params_w; > > template<typename t_pod_data> > void apped_pod_to_strbuff(std::string& buff, const t_pod_data& pod) > { > buff.append(reinterpret_cast<const char*>(&pod), sizeof(pod)); > } > > > > template<class t_string> > bool parse_commandline(std::map<t_string, t_string>& res, int argc, char** argv) > { > t_string key; > for(int i = 1; i < argc; i++) > { > if(!argv[i]) > break; > t_string s = argv[i]; > std::string::size_type p = s.find('='); > if(std::string::npos == p) > { > res[s] = ""; > }else > { > std::string ss; > t_string nm = s.substr(0, p); > t_string vl = s.substr(p+1, s.size()); > res[nm] = vl; > } > } > return true; > } ># 290 "/c/honeypenny/contrib/epee/include/string_tools.h" > template<class t_string, typename t_type> > bool get_xparam_from_command_line(const std::map<t_string, t_string>& res, const t_string & key, t_type& val) > { > typename std::map<t_string, t_string>::const_iterator it = res.find(key); > if(it == res.end()) > return false; > > if(it->second.size()) > { > return get_xtype_from_string(val, it->second); > } > > return true; > } > > template<class t_string, typename t_type> > t_type get_xparam_from_command_line(const std::map<t_string, t_string>& res, const t_string & key, const t_type& default_value) > { > typename std::map<t_string, t_string>::const_iterator it = res.find(key); > if(it == res.end()) > return default_value; > > if(it->second.size()) > { > t_type s; > get_xtype_from_string(s, it->second); > return s; > } > > return default_value; > } > > template<class t_string> > bool have_in_command_line(const std::map<t_string, t_string>& res, const std::basic_string<typename t_string::value_type>& key) > { > typename std::map<t_string, t_string>::const_iterator it = res.find(key); > if(it == res.end()) > return false; > > return true; > } > > > > inline std::string get_ip_string_from_int32(uint32_t ip) > { > in_addr adr; > adr.s_addr = ip; > const char* pbuf = inet_ntoa(adr); > if(pbuf) > return pbuf; > else > return "[failed]"; > } > > inline bool get_ip_int32_from_string(uint32_t& ip, const std::string& ip_str) > { > ip = inet_addr(ip_str.c_str()); > if(((in_addr_t) 0xffffffff) == ip) > return false; > > return true; > } > > inline bool parse_peer_from_string(uint32_t& ip, uint32_t& port, const std::string& addres) > { > > std::string::size_type p = addres.find(':'); > if(p == std::string::npos) > { > return false; > } > std::string ip_str = addres.substr(0, p); > std::string port_str = addres.substr(p+1, addres.size()); > > if(!get_ip_int32_from_string(ip, ip_str)) > { > return false; > } > > if(!get_xtype_from_string(port, port_str)) > { > return false; > } > return true; > } > > > > template<typename t> > inline std::string get_t_as_hex_nwidth(const t& v, std::streamsize w = 8) > { > std::stringstream ss; > ss << std::setfill ('0') << std::setw (w) << std::hex << std::noshowbase; > ss << v; > return ss.str(); > } > > inline std::string num_to_string_fast(int64_t val) > { > > > > > return boost::lexical_cast<std::string>(val); > } > > inline bool string_to_num_fast(const std::string& buff, int64_t& val) > { > > > > > val = atoll(buff.c_str()); > > > > > if(buff != "0" && val == 0) > return false; > return true; > } > > inline bool string_to_num_fast(const std::string& buff, int& val) > { > val = atoi(buff.c_str()); > if(buff != "0" && val == 0) > return false; > > return true; > } ># 460 "/c/honeypenny/contrib/epee/include/string_tools.h" > inline bool compare_no_case(const std::string& str1, const std::string& str2) > { > > return !boost::iequals(str1, str2); > } > > inline bool compare_no_case(const std::wstring& str1, const std::wstring& str2) > { > return !boost::iequals(str1, str2); > } > > inline bool is_match_prefix(const std::wstring& str1, const std::wstring& prefix) > { > if(prefix.size()>str1.size()) > return false; > > if(!compare_no_case(str1.substr(0, prefix.size()), prefix)) > return true; > else > return false; > } > > inline bool is_match_prefix(const std::string& str1, const std::string& prefix) > { > if(prefix.size()>str1.size()) > return false; > > if(!compare_no_case(str1.substr(0, prefix.size()), prefix)) > return true; > else > return false; > } > > inline std::string& get_current_module_name() > { > static std::string module_name; > return module_name; > } > > inline std::string& get_current_module_folder() > { > static std::string module_folder; > return module_folder; > } ># 515 "/c/honeypenny/contrib/epee/include/string_tools.h" > inline bool set_module_name_and_folder(const std::string& path_to_process_) > { > std::string path_to_process = path_to_process_; > > > > std::string::size_type a = path_to_process.rfind( '\\' ); > if(a == std::string::npos ) > { > a = path_to_process.rfind( '/' ); > } > if ( a != std::string::npos ) > { > get_current_module_name() = path_to_process.substr(a+1, path_to_process.size()); > get_current_module_folder() = path_to_process.substr(0, a); > return true; > }else > return false; > > } > > > inline bool trim_left(std::string& str) > { > for(std::string::iterator it = str.begin(); it!= str.end() && isspace(static_cast<unsigned char>(*it));) > str.erase(str.begin()); > > return true; > } > > inline bool trim_right(std::string& str) > { > > for(std::string::reverse_iterator it = str.rbegin(); it!= str.rend() && isspace(static_cast<unsigned char>(*it));) > str.erase( --((it++).base())); > > return true; > } > > inline std::string& trim(std::string& str) > { > > trim_left(str); > trim_right(str); > return str; > } > > inline std::string trim(const std::string& str_) > { > std::string str = str_; > trim_left(str); > trim_right(str); > return str; > } > > template<class t_pod_type> > std::string pod_to_hex(const t_pod_type& s) > { > std::string buff; > buff.assign(reinterpret_cast<const char*>(&s), sizeof(s)); > return buff_to_hex_nodelimer(buff); > } > > template<class t_pod_type> > bool hex_to_pod(const std::string& hex_str, t_pod_type& s) > { > std::string hex_str_tr = trim(hex_str); > if(sizeof(s)*2 != hex_str.size()) > return false; > std::string bin_buff; > if(!parse_hexstr_to_binbuff(hex_str_tr, bin_buff)) > return false; > if(bin_buff.size()!=sizeof(s)) > return false; > > s = *(t_pod_type*)bin_buff.data(); > return true; > } > > inline std::string get_extension(const std::string& str) > { > std::string res; > std::string::size_type pos = str.rfind('.'); > if(std::string::npos == pos) > return res; > > res = str.substr(pos+1, str.size()-pos); > return res; > } > > inline std::string get_filename_from_path(const std::string& str) > { > std::string res; > std::string::size_type pos = str.rfind('\\'); > if(std::string::npos == pos) > return str; > > res = str.substr(pos+1, str.size()-pos); > return res; > } > > > > > inline std::string cut_off_extension(const std::string& str) > { > std::string res; > std::string::size_type pos = str.rfind('.'); > if(std::string::npos == pos) > return str; > > res = str.substr(0, pos); > return res; > } ># 750 "/c/honeypenny/contrib/epee/include/string_tools.h" >} >} ># 55 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/time_helper.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/time_helper.h" > > > > ># 1 "/usr/include/boost/date_time/posix_time/posix_time.hpp" 1 3 4 ># 24 "/usr/include/boost/date_time/posix_time/posix_time.hpp" 3 4 ># 1 "/usr/include/boost/date_time/posix_time/time_formatters.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/posix_time/time_formatters.hpp" 3 4 ># 1 "/usr/include/boost/date_time/gregorian/gregorian.hpp" 1 3 4 ># 25 "/usr/include/boost/date_time/gregorian/gregorian.hpp" 3 4 ># 1 "/usr/include/boost/date_time/gregorian/formatters.hpp" 1 3 4 ># 17 "/usr/include/boost/date_time/gregorian/formatters.hpp" 3 4 ># 1 "/usr/include/boost/date_time/date_formatting.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/date_formatting.hpp" 3 4 ># 1 "/usr/include/boost/date_time/iso_format.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/iso_format.hpp" 3 4 ># 1 "/usr/include/boost/date_time/parse_format_base.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/parse_format_base.hpp" 3 4 >namespace boost { >namespace date_time { > > > enum month_format_spec {month_as_integer, month_as_short_string, > month_as_long_string}; > > > > > enum ymd_order_spec {ymd_order_iso, > ymd_order_dmy, > ymd_order_us}; > > >} } ># 13 "/usr/include/boost/date_time/iso_format.hpp" 2 3 4 > >namespace boost { >namespace date_time { > > >template<class charT> >class iso_format_base { >public: > > static month_format_spec month_format() > { > return month_as_integer; > } > > > static const charT* not_a_date() > { > return "not-a-date-time"; > } > > static const charT* pos_infinity() > { > return "+infinity"; > } > > static const charT* neg_infinity() > { > return "-infinity"; > } > > > static charT year_sep_char() > { > return 'Y'; > } > > static charT month_sep_char() > { > return '-'; > } > > static charT day_sep_char() > { > return '-'; > } > > static charT hour_sep_char() > { > return ':'; > } > > static charT minute_sep_char() > { > return ':'; > } > > static charT second_sep_char() > { > return ':'; > } > > static charT period_start_char() > { > return 'P'; > } > > static charT time_start_char() > { > return 'T'; > } > > > static charT week_start_char() > { > return 'W'; > } > > > static charT period_sep_char() > { > return '/'; > } > > static charT time_sep_char() > { > return ':'; > } > > 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 '-'; > } > >}; > > > > >template<> >class iso_format_base<wchar_t> { >public: > > static month_format_spec month_format() > { > return month_as_integer; > } > > > static const wchar_t* not_a_date() > { > return L"not-a-date-time"; > } > > static const wchar_t* pos_infinity() > { > return L"+infinity"; > } > > static const wchar_t* neg_infinity() > { > return L"-infinity"; > } > > > static wchar_t year_sep_char() > { > return 'Y'; > } > > static wchar_t month_sep_char() > { > return '-'; > } > > static wchar_t day_sep_char() > { > return '-'; > } > > static wchar_t hour_sep_char() > { > return ':'; > } > > static wchar_t minute_sep_char() > { > return ':'; > } > > static wchar_t second_sep_char() > { > return ':'; > } > > static wchar_t period_start_char() > { > return 'P'; > } > > static wchar_t time_start_char() > { > return 'T'; > } > > > static wchar_t week_start_char() > { > return 'W'; > } > > > static wchar_t period_sep_char() > { > return '/'; > } > > static wchar_t time_sep_char() > { > return ':'; > } > > 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 '-'; > } > >}; > > > > >template<class charT> >class iso_format : public iso_format_base<charT> { >public: > > static bool has_date_sep_chars() > { > return false; > } >}; > > >template<class charT> >class iso_extended_format : public iso_format_base<charT> { >public: > > static bool has_date_sep_chars() > { > return true; > } > >}; > >} } ># 13 "/usr/include/boost/date_time/date_formatting.hpp" 2 3 4 ># 23 "/usr/include/boost/date_time/date_formatting.hpp" 3 4 >namespace boost { >namespace date_time { > > > template<class month_type, class format_type, class charT=char> > class month_formatter > { > typedef std::basic_ostream<charT> ostream_type; > public: > > > > > > 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; > } > }; > > > > template<class ymd_type, class format_type, class charT=char> > class ymd_formatter > { > public: ># 80 "/usr/include/boost/date_time/date_formatting.hpp" 3 4 > static std::basic_string<charT> ymd_to_string(ymd_type ymd) > { > typedef typename ymd_type::month_type month_type; > std::basic_ostringstream<charT> ss; > > > > 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(); > } > > month_formatter<month_type,format_type,charT>::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(); > } > }; > > > > template<class date_type, class format_type, class charT=char> > class date_formatter > { > public: > typedef std::basic_string<charT> string_type; > > 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_type, format_type, charT>::ymd_to_string(ymd); > } > }; > > >} } ># 18 "/usr/include/boost/date_time/gregorian/formatters.hpp" 2 3 4 > > ># 1 "/usr/include/boost/date_time/date_format_simple.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/date_format_simple.hpp" 3 4 >namespace boost { >namespace date_time { > > >template<class charT> >class simple_format { >public: > > > static const charT* not_a_date() > { > return "not-a-date-time"; > } > > static const charT* pos_infinity() > { > return "+infinity"; > } > > static const charT* neg_infinity() > { > return "-infinity"; > } > > static month_format_spec month_format() > { > return month_as_short_string; > } > static ymd_order_spec date_order() > { > return ymd_order_iso; > } > > static bool has_date_sep_chars() > { > return true; > } > > static charT year_sep_char() > { > return '-'; > } > > static charT month_sep_char() > { > return '-'; > } > > static charT day_sep_char() > { > return '-'; > } > > static charT hour_sep_char() > { > return ' '; > } > > static charT minute_sep_char() > { > return ':'; > } > > static charT second_sep_char() > { > return ':'; > } > >}; > > > > >template<> >class simple_format<wchar_t> { >public: > > > static const wchar_t* not_a_date() > { > return L"not-a-date-time"; > } > > static const wchar_t* pos_infinity() > { > return L"+infinity"; > } > > static const wchar_t* neg_infinity() > { > return L"-infinity"; > } > > static month_format_spec month_format() > { > return month_as_short_string; > } > static ymd_order_spec date_order() > { > return ymd_order_iso; > } > > static bool has_date_sep_chars() > { > return true; > } > > static wchar_t year_sep_char() > { > return '-'; > } > > static wchar_t month_sep_char() > { > return '-'; > } > > static wchar_t day_sep_char() > { > return '-'; > } > > static wchar_t hour_sep_char() > { > return ' '; > } > > static wchar_t minute_sep_char() > { > return ':'; > } > > static wchar_t second_sep_char() > { > return ':'; > } > >}; > > >} } ># 21 "/usr/include/boost/date_time/gregorian/formatters.hpp" 2 3 4 > > > > > > >namespace boost { >namespace gregorian { > > > template<class charT> > inline > std::basic_string<charT> to_simple_string_type(const date& d) { > return date_time::date_formatter<date,date_time::simple_format<charT>,charT>::date_to_string(d); > } > > > > inline std::string to_simple_string(const date& d) { > return to_simple_string_type<char>(d); > } > > > > template<class charT> > inline std::basic_string<charT> to_simple_string_type(const date_period& d) { > typedef std::basic_string<charT> string_type; > charT b = '[', m = '/', e=']'; > > string_type d1(date_time::date_formatter<date,date_time::simple_format<charT>,charT>::date_to_string(d.begin())); > string_type d2(date_time::date_formatter<date,date_time::simple_format<charT>,charT>::date_to_string(d.last())); > return string_type(b + d1 + m + d2 + e); > } > > > > inline std::string to_simple_string(const date_period& d) { > return to_simple_string_type<char>(d); > } > > > template<class charT> > inline std::basic_string<charT> to_iso_string_type(const date_period& d) { > charT sep = '/'; > std::basic_string<charT> s(date_time::date_formatter<date,date_time::iso_format<charT>,charT>::date_to_string(d.begin())); > return s + sep + date_time::date_formatter<date,date_time::iso_format<charT>,charT>::date_to_string(d.last()); > } > > > > inline std::string to_iso_string(const date_period& d) { > return to_iso_string_type<char>(d); > } > > > > template<class charT> > inline std::basic_string<charT> to_iso_extended_string_type(const date& d) { > return date_time::date_formatter<date,date_time::iso_extended_format<charT>,charT>::date_to_string(d); > } > > > > inline std::string to_iso_extended_string(const date& d) { > return to_iso_extended_string_type<char>(d); > } > > > template<class charT> > inline std::basic_string<charT> to_iso_string_type(const date& d) { > return date_time::date_formatter<date,date_time::iso_format<charT>,charT>::date_to_string(d); > } > > > > inline std::string to_iso_string(const date& d) { > return to_iso_string_type<char>(d); > } > > > > > > template<class charT> > inline std::basic_string<charT> to_sql_string_type(const date& d) > { > date::ymd_type ymd = d.year_month_day(); > std::basic_ostringstream<charT> ss; > ss << ymd.year << "-" > << std::setw(2) << std::setfill(ss.widen('0')) > << ymd.month.as_number() > << "-" > << 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<char>(d); > } > > > > > > > inline std::wstring to_simple_wstring(const date_period& d) { > return to_simple_string_type<wchar_t>(d); > } > > > > inline std::wstring to_simple_wstring(const date& d) { > return to_simple_string_type<wchar_t>(d); > } > > > > inline std::wstring to_iso_wstring(const date_period& d) { > return to_iso_string_type<wchar_t>(d); > } > > > > inline std::wstring to_iso_extended_wstring(const date& d) { > return to_iso_extended_string_type<wchar_t>(d); > } > > > > inline std::wstring to_iso_wstring(const date& d) { > return to_iso_string_type<wchar_t>(d); > } > inline std::wstring to_sql_wstring(const date& d) { > return to_sql_string_type<wchar_t>(d); > } > > >} } ># 26 "/usr/include/boost/date_time/gregorian/gregorian.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/date_time/gregorian/gregorian_io.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/gregorian/gregorian_io.hpp" 3 4 ># 1 "/usr/include/boost/date_time/date_facet.hpp" 1 3 4 ># 21 "/usr/include/boost/date_time/date_facet.hpp" 3 4 ># 1 "/usr/include/boost/date_time/special_values_formatter.hpp" 1 3 4 ># 17 "/usr/include/boost/date_time/special_values_formatter.hpp" 3 4 >namespace boost { namespace date_time { ># 29 "/usr/include/boost/date_time/special_values_formatter.hpp" 3 4 > template <class CharT, class OutItrT = std::ostreambuf_iterator<CharT, std::char_traits<CharT> > > > class special_values_formatter > { > public: > typedef std::basic_string<CharT> string_type; > typedef CharT char_type; > typedef std::vector<string_type> collection_type; > static const char_type default_special_value_names[3][17]; > > > > > special_values_formatter() > { > std::copy(&default_special_value_names[0], > &default_special_value_names[3], > std::back_inserter(m_special_value_names)); > } ># 58 "/usr/include/boost/date_time/special_values_formatter.hpp" 3 4 > 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; > }; > > > > > > > template <class CharT, class OutItrT> > const typename special_values_formatter<CharT, OutItrT>::char_type special_values_formatter<CharT, OutItrT>::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'} }; > > } } ># 22 "/usr/include/boost/date_time/date_facet.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/period_formatter.hpp" 1 3 4 ># 15 "/usr/include/boost/date_time/period_formatter.hpp" 3 4 >namespace boost { namespace date_time { ># 36 "/usr/include/boost/date_time/period_formatter.hpp" 3 4 > template <class CharT, class OutItrT = std::ostreambuf_iterator<CharT, std::char_traits<CharT> > > > class period_formatter { > public: > typedef std::basic_string<CharT> string_type; > typedef CharT char_type; > typedef typename std::basic_string<char_type>::const_iterator const_itr_type; > typedef std::vector<std::basic_string<CharT> > 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 }; > > > 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) > {} > > > 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; > } > > > 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; > } > > > 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; > } > > > 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; > } ># 150 "/usr/include/boost/date_time/period_formatter.hpp" 3 4 > template<class period_type, class facet_type> > 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 <class CharT, class OutItrT> > const typename period_formatter<CharT, OutItrT>::char_type > period_formatter<CharT, OutItrT>::default_period_separator[2] = {'/'}; > > template <class CharT, class OutItrT> > const typename period_formatter<CharT, OutItrT>::char_type > period_formatter<CharT, OutItrT>::default_period_start_delimeter[2] = {'['}; > > template <class CharT, class OutItrT> > const typename period_formatter<CharT, OutItrT>::char_type > period_formatter<CharT, OutItrT>::default_period_open_range_end_delimeter[2] = {')'}; > > template <class CharT, class OutItrT> > const typename period_formatter<CharT, OutItrT>::char_type > period_formatter<CharT, OutItrT>::default_period_closed_range_end_delimeter[2] = {']'}; > > } } ># 23 "/usr/include/boost/date_time/date_facet.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/period_parser.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/period_parser.hpp" 3 4 ># 1 "/usr/include/boost/date_time/string_parse_tree.hpp" 1 3 4 ># 20 "/usr/include/boost/date_time/string_parse_tree.hpp" 3 4 >namespace boost { namespace date_time { > > >template<typename charT> >struct parse_match_result >{ > parse_match_result() : > match_depth(0), > current_match(-1) > {} > typedef std::basic_string<charT> string_type; > string_type remaining() const > { > if (match_depth == cache.size()) { > return string_type(); > } > if (current_match == -1) { > return cache; > } > > return string_type(cache, match_depth); > } > charT last_char() const > { > return cache[cache.size()-1]; > } > > > > > bool has_remaining() const > { > return (cache.size() > match_depth); > } > > > string_type cache; > unsigned short match_depth; > short current_match; > enum PARSE_STATE { PARSE_ERROR= -1 }; >}; > > >template<typename charT> >std::basic_ostream<charT>& >operator<<(std::basic_ostream<charT>& os, parse_match_result<charT>& mr) >{ > os << "cm: " << mr.current_match > << " C: '" << mr.cache > << "' md: " << mr.match_depth > << " R: " << mr.remaining(); > return os; >} ># 82 "/usr/include/boost/date_time/string_parse_tree.hpp" 3 4 >template<typename charT> >struct string_parse_tree >{ > > > > typedef std::multimap<charT, string_parse_tree > ptree_coll; > > 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<charT> string_type; > typedef std::vector<std::basic_string<charT> > collection_type; > typedef parse_match_result<charT> parse_match_result_type; > > > > > > > string_parse_tree(collection_type names, unsigned int starting_point=0) > { > > unsigned short index = 0; > while (index != names.size() ) { > string_type s = boost::algorithm::to_lower_copy(names[index]); > insert(s, static_cast<unsigned short>(index + starting_point)); > index++; > } > > 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<charT>(value))); > } > else { > ti = m_next_chars.insert(value_type(s[i], > string_parse_tree<charT>())); > } > } > else { > if (i == (s.size()-1)) { > ti = ti->second.m_next_chars.insert(value_type(s[i], > string_parse_tree<charT>(value))); > } > > else { > ti = ti->second.m_next_chars.insert(value_type(s[i], > string_parse_tree<charT>())); > } > > } > i++; > } > } ># 165 "/usr/include/boost/date_time/string_parse_tree.hpp" 3 4 > short > match(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end, > parse_match_result_type& result, > unsigned int& level) const > { > > level++; > charT c; > > > bool adv_itr = true; > if (level > result.cache.size()) { > if (sitr == stream_end) return 0; > c = static_cast<charT>(std::tolower(*sitr)); > > > } > else { > > > adv_itr = false; > c = static_cast<charT>(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) { > if(adv_itr) { > sitr++; > result.cache += c; > } > if (litr->second.m_value != -1) { > if (result.match_depth < level) { > result.current_match = litr->second.m_value; > result.match_depth = static_cast<unsigned short>(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; > > } > > > > > > > parse_match_result_type > match(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end) const > { > > unsigned int level = 0; > > 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(); > > 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++; > } > } > >}; > > >} } ># 15 "/usr/include/boost/date_time/period_parser.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/string_convert.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/string_convert.hpp" 3 4 >namespace boost { >namespace date_time { > > > > > template<class InputT, class OutputT> > inline > std::basic_string<OutputT> convert_string_type(const std::basic_string<InputT>& inp_str) > { > typedef std::basic_string<InputT> input_type; > typedef std::basic_string<OutputT> output_type; > output_type result; > result.insert(result.begin(), inp_str.begin(), inp_str.end()); > return result; > } > >}} ># 16 "/usr/include/boost/date_time/period_parser.hpp" 2 3 4 > > >namespace boost { namespace date_time { ># 35 "/usr/include/boost/date_time/period_parser.hpp" 3 4 > template<class date_type, typename CharT> > class period_parser { > public: > typedef std::basic_string<CharT> string_type; > typedef CharT char_type; > > typedef std::istreambuf_iterator<CharT> stream_itr_type; > typedef string_parse_tree<CharT> parse_tree_type; > typedef typename parse_tree_type::parse_match_result_type match_results; > typedef std::vector<std::basic_string<CharT> > 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 }; > > > 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<date_type,CharT>& 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); > } ># 119 "/usr/include/boost/date_time/period_parser.hpp" 3 4 > template<class period_type, class duration_type, class facet_type> > period_type get_period(stream_itr_type& sitr, > stream_itr_type& stream_end, > std::ios_base& a_ios, > const period_type& , > const duration_type& dur_unit, > const facet_type& facet) const > { > > 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]); > facet.get(sitr, stream_end, a_ios, p1); > consume_delim(sitr, stream_end, delimiters[SEPARATOR]); > facet.get(sitr, stream_end, a_ios, p2); > > > if (m_range_option == AS_CLOSED_RANGE) { > consume_delim(sitr, stream_end, delimiters[CLOSED_END]); > > p2 += dur_unit; > } > else { > consume_delim(sitr, stream_end, delimiters[OPEN_END]); > } > > return period_type(p1, p2); > } > > private: > collection_type delimiters; > period_range_option m_range_option; > > enum delim_ids { SEPARATOR, START, OPEN_END, CLOSED_END }; > > > void consume_delim(stream_itr_type& sitr, > stream_itr_type& stream_end, > const string_type& delim) const > { > > > > > > 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<char_type,char>(delim) + "' but found '" + convert_string_type<char_type,char>(s) + "'")); > } > } > }; > > template <class date_type, class char_type> > const typename period_parser<date_type, char_type>::char_type > period_parser<date_type, char_type>::default_period_separator[2] = {'/'}; > > template <class date_type, class char_type> > const typename period_parser<date_type, char_type>::char_type > period_parser<date_type, char_type>::default_period_start_delimeter[2] = {'['}; > > template <class date_type, class char_type> > const typename period_parser<date_type, char_type>::char_type > period_parser<date_type, char_type>::default_period_open_range_end_delimeter[2] = {')'}; > > template <class date_type, class char_type> > const typename period_parser<date_type, char_type>::char_type > period_parser<date_type, char_type>::default_period_closed_range_end_delimeter[2] = {']'}; > > } } ># 24 "/usr/include/boost/date_time/date_facet.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/date_generator_formatter.hpp" 1 3 4 ># 18 "/usr/include/boost/date_time/date_generator_formatter.hpp" 3 4 >namespace boost { >namespace date_time { ># 37 "/usr/include/boost/date_time/date_generator_formatter.hpp" 3 4 > template <class date_type, class CharT, class OutItrT = std::ostreambuf_iterator<CharT, std::char_traits<CharT> > > > class date_generator_formatter { > public: > typedef partial_date<date_type> partial_date_type; > typedef nth_kday_of_month<date_type> nth_kday_type; > typedef first_kday_of_month<date_type> first_kday_type; > typedef last_kday_of_month<date_type> last_kday_type; > typedef first_kday_after<date_type> kday_after_type; > typedef first_kday_before<date_type> kday_before_type; > > typedef CharT char_type; > typedef std::basic_string<char_type> string_type; > typedef std::vector<string_type> 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}; > > > 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)); > } > > > 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); > } ># 114 "/usr/include/boost/date_time/date_generator_formatter.hpp" 3 4 > 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); > > } > } > > > template<class facet_type> > 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; > facet.put(next, a_ios, a_fill, pd.month()); > return next; > } > > > template<class facet_type> > 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; > facet.put(next, a_ios, a_fill, nkd.day_of_week()); > next = a_fill; > put_string(next, string_type(of_string)); > next = a_fill; > facet.put(next, a_ios, a_fill, nkd.month()); > return next; > } > > > template<class facet_type> > 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; > facet.put(next, a_ios, a_fill, fkd.day_of_week()); > next = a_fill; > put_string(next, string_type(of_string)); > next = a_fill; > facet.put(next, a_ios, a_fill, fkd.month()); > return next; > } > > > template<class facet_type> > 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; > facet.put(next, a_ios, a_fill, lkd.day_of_week()); > next = a_fill; > put_string(next, string_type(of_string)); > next = a_fill; > facet.put(next, a_ios, a_fill, lkd.month()); > return next; > } > > > template<class facet_type> > 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; > put_string(next, phrase_strings[before]); > return next; > } > > > template<class facet_type> > 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; > put_string(next, phrase_strings[after]); > return next; > } > > > private: > collection_type phrase_strings; > > > 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<class date_type, class CharT, class OutItrT> > const typename date_generator_formatter<date_type, CharT, OutItrT>::char_type > date_generator_formatter<date_type, CharT, OutItrT>::first_string[6] = > {'f','i','r','s','t'}; > template<class date_type, class CharT, class OutItrT> > const typename date_generator_formatter<date_type, CharT, OutItrT>::char_type > date_generator_formatter<date_type, CharT, OutItrT>::second_string[7] = > {'s','e','c','o','n','d'}; > template<class date_type, class CharT, class OutItrT> > const typename date_generator_formatter<date_type, CharT, OutItrT>::char_type > date_generator_formatter<date_type, CharT, OutItrT>::third_string[6] = > {'t','h','i','r','d'}; > template<class date_type, class CharT, class OutItrT> > const typename date_generator_formatter<date_type, CharT, OutItrT>::char_type > date_generator_formatter<date_type, CharT, OutItrT>::fourth_string[7] = > {'f','o','u','r','t','h'}; > template<class date_type, class CharT, class OutItrT> > const typename date_generator_formatter<date_type, CharT, OutItrT>::char_type > date_generator_formatter<date_type, CharT, OutItrT>::fifth_string[6] = > {'f','i','f','t','h'}; > template<class date_type, class CharT, class OutItrT> > const typename date_generator_formatter<date_type, CharT, OutItrT>::char_type > date_generator_formatter<date_type, CharT, OutItrT>::last_string[5] = > {'l','a','s','t'}; > template<class date_type, class CharT, class OutItrT> > const typename date_generator_formatter<date_type, CharT, OutItrT>::char_type > date_generator_formatter<date_type, CharT, OutItrT>::before_string[8] = > {'b','e','f','o','r','e'}; > template<class date_type, class CharT, class OutItrT> > const typename date_generator_formatter<date_type, CharT, OutItrT>::char_type > date_generator_formatter<date_type, CharT, OutItrT>::after_string[6] = > {'a','f','t','e','r'}; > template<class date_type, class CharT, class OutItrT> > const typename date_generator_formatter<date_type, CharT, OutItrT>::char_type > date_generator_formatter<date_type, CharT, OutItrT>::of_string[3] = > {'o','f'}; >} } ># 25 "/usr/include/boost/date_time/date_facet.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/date_generator_parser.hpp" 1 3 4 ># 20 "/usr/include/boost/date_time/date_generator_parser.hpp" 3 4 ># 1 "/usr/include/boost/date_time/format_date_parser.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/format_date_parser.hpp" 3 4 ># 1 "/usr/include/boost/date_time/strings_from_facet.hpp" 1 3 4 ># 17 "/usr/include/boost/date_time/strings_from_facet.hpp" 3 4 >namespace boost { namespace date_time { ># 32 "/usr/include/boost/date_time/strings_from_facet.hpp" 3 4 >template<typename charT> >std::vector<std::basic_string<charT> > >gather_month_strings(const std::locale& locale, bool short_strings=true) >{ > typedef std::basic_string<charT> string_type; > typedef std::vector<string_type> collection_type; > typedef std::basic_ostringstream<charT> ostream_type; > typedef std::ostreambuf_iterator<charT> ostream_iter_type; > typedef std::basic_ostringstream<charT> stringstream_type; > typedef std::time_put<charT> 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; > } > { > > > 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<time_put_facet_type>(locale).put(oitr, ss, ss.fill(), > &tm_value, > p_outfmt, > p_outfmt_end); > months.push_back(ss.str()); > } > } > return months; >} ># 83 "/usr/include/boost/date_time/strings_from_facet.hpp" 3 4 >template<typename charT> >std::vector<std::basic_string<charT> > >gather_weekday_strings(const std::locale& locale, bool short_strings=true) >{ > typedef std::basic_string<charT> string_type; > typedef std::vector<string_type> collection_type; > typedef std::basic_ostringstream<charT> ostream_type; > typedef std::ostreambuf_iterator<charT> ostream_iter_type; > typedef std::basic_ostringstream<charT> stringstream_type; > typedef std::time_put<charT> 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; > } > { > > > 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<time_put_facet_type>(locale).put(oitr, ss, ss.fill(), > &tm_value, > p_outfmt, > p_outfmt_end); > > weekdays.push_back(ss.str()); > } > } > return weekdays; >} > >} } ># 17 "/usr/include/boost/date_time/format_date_parser.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/special_values_parser.hpp" 1 3 4 ># 19 "/usr/include/boost/date_time/special_values_parser.hpp" 3 4 >namespace boost { namespace date_time { ># 32 "/usr/include/boost/date_time/special_values_parser.hpp" 3 4 > template<class date_type, typename charT> > class special_values_parser > { > public: > typedef std::basic_string<charT> string_type; > > typedef std::istreambuf_iterator<charT> stream_itr_type; > > > > typedef typename date_type::duration_type duration_type; > > > typedef string_parse_tree<charT> parse_tree_type; > typedef typename parse_tree_type::parse_match_result_type match_results; > typedef std::vector<std::basic_string<charT> > 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]; > > > 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)); > } > > > 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<int>(not_a_date_time)); > } > > special_values_parser(const special_values_parser<date_type,charT>& svp) > { > this->m_sv_strings = svp.m_sv_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<int>(not_a_date_time)); > } > > > > > > > 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); > } ># 130 "/usr/include/boost/date_time/special_values_parser.hpp" 3 4 > private: > parse_tree_type m_sv_strings; > > }; > > template<class date_type, class CharT> > const typename special_values_parser<date_type, CharT>::char_type > special_values_parser<date_type, CharT>::nadt_string[16] = > {'n','o','t','-','a','-','d','a','t','e','-','t','i','m','e'}; > template<class date_type, class CharT> > const typename special_values_parser<date_type, CharT>::char_type > special_values_parser<date_type, CharT>::neg_inf_string[10] = > {'-','i','n','f','i','n','i','t','y'}; > template<class date_type, class CharT> > const typename special_values_parser<date_type, CharT>::char_type > special_values_parser<date_type, CharT>::pos_inf_string[10] = > {'+','i','n','f','i','n','i','t','y'}; > template<class date_type, class CharT> > const typename special_values_parser<date_type, CharT>::char_type > special_values_parser<date_type, CharT>::min_date_time_string[18] = > {'m','i','n','i','m','u','m','-','d','a','t','e','-','t','i','m','e'}; > template<class date_type, class CharT> > const typename special_values_parser<date_type, CharT>::char_type > special_values_parser<date_type, CharT>::max_date_time_string[18] = > {'m','a','x','i','m','u','m','-','d','a','t','e','-','t','i','m','e'}; > >} } ># 18 "/usr/include/boost/date_time/format_date_parser.hpp" 2 3 4 > > > > > ># 1 "/usr/include/c++/4.9.0/cctype" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cctype" 3 4 ># 40 "/usr/include/c++/4.9.0/cctype" 3 ># 24 "/usr/include/boost/date_time/format_date_parser.hpp" 2 3 4 ># 34 "/usr/include/boost/date_time/format_date_parser.hpp" 3 4 >namespace boost { namespace date_time { > > > > > > >template<typename int_type, typename charT> >inline >int_type >fixed_string_to_int(std::istreambuf_iterator<charT>& itr, > std::istreambuf_iterator<charT>& stream_end, > parse_match_result<charT>& mr, > unsigned int length, > const charT& fill_char) >{ > > unsigned int j = 0; > > while (j < length && itr != stream_end && > (std::isdigit(*itr) || *itr == fill_char)) { > if(*itr == fill_char) { > > > mr.cache += ('0'); > } > else { > mr.cache += (*itr); > } > itr++; > j++; > } > int_type i = -1; > > if(mr.cache.size() < length) { > return i; > } > try { > i = boost::lexical_cast<int_type>(mr.cache); > }catch(bad_lexical_cast&){ > > } > return i; >} > > > > > > >template<typename int_type, typename charT> >inline >int_type >fixed_string_to_int(std::istreambuf_iterator<charT>& itr, > std::istreambuf_iterator<charT>& stream_end, > parse_match_result<charT>& mr, > unsigned int length) >{ > return fixed_string_to_int<int_type, charT>(itr, stream_end, mr, length, '0'); >} > > > > > >template<typename int_type, typename charT> >inline >int_type >var_string_to_int(std::istreambuf_iterator<charT>& itr, > const std::istreambuf_iterator<charT>& stream_end, > unsigned int max_length) >{ > typedef std::basic_string<charT> 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<int_type>(s); > } > return i; >} ># 150 "/usr/include/boost/date_time/format_date_parser.hpp" 3 4 >template<class date_type, typename charT> >class format_date_parser >{ > public: > typedef std::basic_string<charT> string_type; > typedef std::basic_istringstream<charT> stringstream_type; > typedef std::istreambuf_iterator<charT> 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<charT> parse_tree_type; > typedef typename parse_tree_type::parse_match_result_type match_results; > typedef std::vector<std::basic_string<charT> > input_collection_type; > > > > 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<charT>(locale), 1), > m_month_long_names(gather_month_strings<charT>(locale, false), 1), > m_weekday_short_names(gather_weekday_strings<charT>(locale)), > m_weekday_long_names(gather_weekday_strings<charT>(locale, false)) > {} > > format_date_parser(const format_date_parser<date_type,charT>& 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<date_type,charT>& 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<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end, > const special_values_parser<date_type,charT>& sv_parser) const > { > return parse_date(sitr, stream_end, m_format, sv_parser); > } > > > > > date_type > parse_date(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end, > string_type format_str, > const special_values_parser<date_type,charT>& sv_parser) const > { > bool use_current_char = false; > > > while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } > > short year(0), month(0), day(0), day_of_year(0); > > > > > 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': > { > > > > > match_results mr = m_weekday_short_names.match(sitr, stream_end); > if(mr.current_match == match_results::PARSE_ERROR) { > > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(mr.current_match)); > } > } > wkday = mr.current_match; > if (mr.has_remaining()) { > use_current_char = true; > } > break; > } > case 'A': > { > > > > > match_results mr = m_weekday_long_names.match(sitr, stream_end); > if(mr.current_match == match_results::PARSE_ERROR) { > > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(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) { > > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(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) { > > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(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<short, charT>(sitr, stream_end, mr, 2); > if(day == -1) { > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(mr.current_match)); > } > } > t_day = day_type(day); > break; > } > case 'e': > { > match_results mr; > day = fixed_string_to_int<short, charT>(sitr, stream_end, mr, 2, ' '); > if(day == -1) { > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(mr.current_match)); > } > } > t_day = day_type(day); > break; > } > case 'j': > { > match_results mr; > day_of_year = fixed_string_to_int<short, charT>(sitr, stream_end, mr, 3); > if(day_of_year == -1) { > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(mr.current_match)); > } > } > > 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<short, charT>(sitr, stream_end, mr, 2); > if(month == -1) { > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(mr.current_match)); > } > } > t_month = month_type(month); > break; > } > case 'Y': > { > match_results mr; > year = fixed_string_to_int<short, charT>(sitr, stream_end, mr, 4); > if(year == -1) { > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(mr.current_match)); > } > } > t_year = year_type(year); > break; > } > case 'y': > { > match_results mr; > year = fixed_string_to_int<short, charT>(sitr, stream_end, mr, 2); > if(year == -1) { > if(sv_parser.match(sitr, stream_end, mr)) { > return date_type(static_cast<special_values>(mr.current_match)); > } > } > year += 2000; > t_year = year_type(year); > break; > } > default: > {} > > } > > } > else { > sitr++; > } > > itr++; > } > else { > itr++; > if (use_current_char) { > use_current_char = false; > } > else { > sitr++; > } > } > } > > if (day_of_year > 0) { > date_type d(static_cast<unsigned short>(year-1),12,31); > return d + duration_type(day_of_year); > } > > return date_type(t_year, t_month, t_day); > > } > > > month_type > parse_month(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end, > string_type format_str) const > { > match_results mr; > return parse_month(sitr, stream_end, format_str, mr); > } > > > month_type > parse_month(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end, > string_type format_str, > match_results& mr) const > { > bool use_current_char = false; > > > 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<short, charT>(sitr, stream_end, 2); > > > break; > } > default: > {} > > } > > } > else { > sitr++; > } > > itr++; > } > else { > itr++; > if (use_current_char) { > use_current_char = false; > } > else { > sitr++; > } > } > } > > return month_type(month); > } > > > day_type > parse_var_day_of_month(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end) const > { > > while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } > > return day_type(var_string_to_int<short, charT>(sitr, stream_end, 2)); > } > > day_type > parse_day_of_month(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end) const > { > > while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } > > > match_results mr; > return day_type(fixed_string_to_int<short, charT>(sitr, stream_end, mr, 2)); > } > > day_of_week_type > parse_weekday(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& 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<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end, > string_type format_str, > match_results& mr) const > { > bool use_current_char = false; > > > 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': > { > > > > > mr = m_weekday_short_names.match(sitr, stream_end); > wkday = mr.current_match; > if (mr.has_remaining()) { > use_current_char = true; > } > break; > } > case 'A': > { > > > > > mr = m_weekday_long_names.match(sitr, stream_end); > wkday = mr.current_match; > if (mr.has_remaining()) { > use_current_char = true; > } > break; > } > case 'w': > { > > wkday = var_string_to_int<short, charT>(sitr, stream_end, 2); > break; > } > default: > {} > > } > > } > else { > sitr++; > } > > itr++; > } > else { > itr++; > if (use_current_char) { > use_current_char = false; > } > else { > sitr++; > } > } > } > > return day_of_week_type(wkday); > > } > > > year_type > parse_year(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end, > string_type format_str) const > { > match_results mr; > return parse_year(sitr, stream_end, format_str, mr); > } > > > year_type > parse_year(std::istreambuf_iterator<charT>& sitr, > std::istreambuf_iterator<charT>& stream_end, > string_type format_str, > match_results& mr) const > { > bool use_current_char = false; > > > 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 != '%') { > > switch(*itr) { > case 'Y': > { > > year = fixed_string_to_int<short, charT>(sitr, stream_end, mr, 4); > break; > } > case 'y': > { > > year = fixed_string_to_int<short, charT>(sitr, stream_end, mr, 2); > year += 2000; > break; > } > default: > {} > > } > > } > else { > sitr++; > } > > itr++; > } > else { > itr++; > if (use_current_char) { > use_current_char = false; > } > else { > sitr++; > } > } > } > > return year_type(year); > } > > > 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; > >}; > >} } ># 21 "/usr/include/boost/date_time/date_generator_parser.hpp" 2 3 4 > >namespace boost { namespace date_time { ># 40 "/usr/include/boost/date_time/date_generator_parser.hpp" 3 4 > template<class date_type, typename charT> > class date_generator_parser > { > public: > typedef std::basic_string<charT> string_type; > typedef std::istreambuf_iterator<charT> 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<charT> parse_tree_type; > typedef typename parse_tree_type::parse_match_result_type match_results; > typedef std::vector<std::basic_string<charT> > collection_type; > > typedef partial_date<date_type> partial_date_type; > typedef nth_kday_of_month<date_type> nth_kday_type; > typedef first_kday_of_month<date_type> first_kday_type; > typedef last_kday_of_month<date_type> last_kday_type; > typedef first_kday_after<date_type> kday_after_type; > typedef first_kday_before<date_type> 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}; > > > 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)); > } > > > 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); > } > > > 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); > } > > void element_strings(const collection_type& col) > { > m_element_strings = parse_tree_type(col, this->first); > } > > > template<class facet_type> > 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 > { > > 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); > } > > > template<class facet_type> > 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 > { > > while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } > > typename nth_kday_type::week_num wn; > day_of_week_type wd(0); > month_type m(1); > > 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 + "'")); > std::abort(); > } > } > facet.get(sitr, stream_end, a_ios, wd); > extract_element(sitr, stream_end, of); > facet.get(sitr, stream_end, a_ios, m); > > return nth_kday_type(wn, wd, m); > } > > > template<class facet_type> > 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 > { > > while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } > > day_of_week_type wd(0); > month_type m(1); > > extract_element(sitr, stream_end, first); > facet.get(sitr, stream_end, a_ios, wd); > extract_element(sitr, stream_end, of); > facet.get(sitr, stream_end, a_ios, m); > > > return first_kday_type(wd, m); > } > > > template<class facet_type> > 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 > { > > while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } > > day_of_week_type wd(0); > month_type m(1); > > extract_element(sitr, stream_end, last); > facet.get(sitr, stream_end, a_ios, wd); > extract_element(sitr, stream_end, of); > facet.get(sitr, stream_end, a_ios, m); > > > return last_kday_type(wd, m); > } > > > template<class facet_type> > 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 > { > > while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } > > day_of_week_type wd(0); > > facet.get(sitr, stream_end, a_ios, wd); > extract_element(sitr, stream_end, before); > > return kday_before_type(wd); > } > > > template<class facet_type> > 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 > { > > while(std::isspace(*sitr) && sitr != stream_end) { ++sitr; } > > day_of_week_type wd(0); > > facet.get(sitr, stream_end, a_ios, wd); > extract_element(sitr, stream_end, after); > > return kday_after_type(wd); > } > > private: > parse_tree_type m_element_strings; > > > void extract_element(stream_itr_type& sitr, > stream_itr_type& stream_end, > typename date_generator_parser::phrase_elements ele) const > { > > 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<class date_type, class CharT> > const typename date_generator_parser<date_type, CharT>::char_type > date_generator_parser<date_type, CharT>::first_string[6] = > {'f','i','r','s','t'}; > template<class date_type, class CharT> > const typename date_generator_parser<date_type, CharT>::char_type > date_generator_parser<date_type, CharT>::second_string[7] = > {'s','e','c','o','n','d'}; > template<class date_type, class CharT> > const typename date_generator_parser<date_type, CharT>::char_type > date_generator_parser<date_type, CharT>::third_string[6] = > {'t','h','i','r','d'}; > template<class date_type, class CharT> > const typename date_generator_parser<date_type, CharT>::char_type > date_generator_parser<date_type, CharT>::fourth_string[7] = > {'f','o','u','r','t','h'}; > template<class date_type, class CharT> > const typename date_generator_parser<date_type, CharT>::char_type > date_generator_parser<date_type, CharT>::fifth_string[6] = > {'f','i','f','t','h'}; > template<class date_type, class CharT> > const typename date_generator_parser<date_type, CharT>::char_type > date_generator_parser<date_type, CharT>::last_string[5] = > {'l','a','s','t'}; > template<class date_type, class CharT> > const typename date_generator_parser<date_type, CharT>::char_type > date_generator_parser<date_type, CharT>::before_string[8] = > {'b','e','f','o','r','e'}; > template<class date_type, class CharT> > const typename date_generator_parser<date_type, CharT>::char_type > date_generator_parser<date_type, CharT>::after_string[6] = > {'a','f','t','e','r'}; > template<class date_type, class CharT> > const typename date_generator_parser<date_type, CharT>::char_type > date_generator_parser<date_type, CharT>::of_string[3] = > {'o','f'}; > >} } ># 26 "/usr/include/boost/date_time/date_facet.hpp" 2 3 4 > > >namespace boost { namespace date_time { ># 46 "/usr/include/boost/date_time/date_facet.hpp" 3 4 > template <class date_type, > class CharT, > class OutItrT = std::ostreambuf_iterator<CharT, std::char_traits<CharT> > > > class date_facet : public std::locale::facet { > public: > 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 typename date_type::month_type month_type; > typedef boost::date_time::period<date_type,duration_type> period_type; > typedef std::basic_string<CharT> string_type; > typedef CharT char_type; > typedef boost::date_time::period_formatter<CharT> period_formatter_type; > typedef boost::date_time::special_values_formatter<CharT> special_values_formatter_type; > typedef std::vector<std::basic_string<CharT> > input_collection_type; > > typedef date_generator_formatter<date_type, CharT> date_gen_formatter_type; > typedef partial_date<date_type> partial_date_type; > typedef nth_kday_of_month<date_type> nth_kday_type; > typedef first_kday_of_month<date_type> first_kday_type; > typedef last_kday_of_month<date_type> last_kday_type; > typedef first_kday_after<date_type> kday_after_type; > typedef first_kday_before<date_type> 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]; > static std::locale::id id; > > > > > > explicit date_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) > {} > > 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()); > } > > 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<CharT, OutItrT> num_put; > if (std::has_facet<num_put>(a_ios.getloc())) { > return std::use_facet<num_put>(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 > { > > > > > 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); > } > > > 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 > { > > > > > 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& , > char_type , > 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 > { > > 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]); > } > > const char_type* p_format = a_format.c_str(); > return std::use_facet<std::time_put<CharT> >(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 <class date_type, class CharT, class OutItrT> > std::locale::id date_facet<date_type, CharT, OutItrT>::id; > > template <class date_type, class CharT, class OutItrT> > const typename date_facet<date_type, CharT, OutItrT>::char_type > date_facet<date_type, CharT, OutItrT>::long_weekday_format[3] = {'%','A'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_facet<date_type, CharT, OutItrT>::char_type > date_facet<date_type, CharT, OutItrT>::short_weekday_format[3] = {'%','a'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_facet<date_type, CharT, OutItrT>::char_type > date_facet<date_type, CharT, OutItrT>::long_month_format[3] = {'%','B'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_facet<date_type, CharT, OutItrT>::char_type > date_facet<date_type, CharT, OutItrT>::short_month_format[3] = {'%','b'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_facet<date_type, CharT, OutItrT>::char_type > date_facet<date_type, CharT, OutItrT>::default_period_separator[4] = { ' ', '/', ' '}; > > template <class date_type, class CharT, class OutItrT> > const typename date_facet<date_type, CharT, OutItrT>::char_type > date_facet<date_type, CharT, OutItrT>::standard_format_specifier[3] = > {'%', 'x' }; > > template <class date_type, class CharT, class OutItrT> > const typename date_facet<date_type, CharT, OutItrT>::char_type > date_facet<date_type, CharT, OutItrT>::iso_format_specifier[7] = > {'%', 'Y', '%', 'm', '%', 'd' }; > > template <class date_type, class CharT, class OutItrT> > const typename date_facet<date_type, CharT, OutItrT>::char_type > date_facet<date_type, CharT, OutItrT>::iso_format_extended_specifier[9] = > {'%', 'Y', '-', '%', 'm', '-', '%', 'd' }; > > template <class date_type, class CharT, class OutItrT> > const typename date_facet<date_type, CharT, OutItrT>::char_type > date_facet<date_type, CharT, OutItrT>::default_date_format[9] = > {'%','Y','-','%','b','-','%','d'}; > > > > > template <class date_type, > class CharT, > class InItrT = std::istreambuf_iterator<CharT, std::char_traits<CharT> > > > class date_input_facet : public std::locale::facet { > public: > 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 typename date_type::month_type month_type; > typedef typename date_type::year_type year_type; > typedef boost::date_time::period<date_type,duration_type> period_type; > typedef std::basic_string<CharT> string_type; > typedef CharT char_type; > typedef boost::date_time::period_parser<date_type, CharT> period_parser_type; > typedef boost::date_time::special_values_parser<date_type,CharT> special_values_parser_type; > typedef std::vector<std::basic_string<CharT> > input_collection_type; > typedef format_date_parser<date_type, CharT> format_date_parser_type; > > typedef date_generator_parser<date_type, CharT> date_gen_parser_type; > typedef partial_date<date_type> partial_date_type; > typedef nth_kday_of_month<date_type> nth_kday_type; > typedef first_kday_of_month<date_type> first_kday_type; > typedef last_kday_of_month<date_type> last_kday_type; > typedef first_kday_after<date_type> kday_after_type; > typedef first_kday_before<date_type> 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]; > 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()) > > {} > > 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()) > > {} > > 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& , > 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& , > 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& , > day_of_week_type& wd) const > { > wd = m_parser.parse_weekday(from, to, m_weekday_format); > return from; > } > > InItrT get(InItrT& from, > InItrT& to, > std::ios_base& , > 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& , > 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 > { > > while(std::isspace(*from) && from != to) { ++from; } > > > > > > char_type c = '\0'; > > if(*from == '-' || *from == '+') { > c = *from; > } > typedef std::num_get<CharT, InItrT> num_get; > typename duration_type::duration_rep_type val = 0; > std::ios_base::iostate err = std::ios_base::goodbit; > > if (std::has_facet<num_get>(a_ios.getloc())) { > from = std::use_facet<num_get>(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 == '+') { > 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 + "'")); > std::abort(); > } > dd = duration_type(static_cast<special_values>(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 <class date_type, class CharT, class OutItrT> > std::locale::id date_input_facet<date_type, CharT, OutItrT>::id; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::long_weekday_format[3] = {'%','A'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::short_weekday_format[3] = {'%','a'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::long_month_format[3] = {'%','B'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::short_month_format[3] = {'%','b'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::four_digit_year_format[3] = {'%','Y'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::two_digit_year_format[3] = {'%','y'}; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::default_period_separator[4] = { ' ', '/', ' '}; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::standard_format_specifier[3] = > {'%', 'x' }; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::iso_format_specifier[7] = > {'%', 'Y', '%', 'm', '%', 'd' }; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::iso_format_extended_specifier[9] = > {'%', 'Y', '-', '%', 'm', '-', '%', 'd' }; > > template <class date_type, class CharT, class OutItrT> > const typename date_input_facet<date_type, CharT, OutItrT>::char_type > date_input_facet<date_type, CharT, OutItrT>::default_date_format[9] = > {'%','Y','-','%','b','-','%','d'}; > >} } ># 17 "/usr/include/boost/date_time/gregorian/gregorian_io.hpp" 2 3 4 > > > > > > > >namespace boost { >namespace gregorian { > > > typedef boost::date_time::period_formatter<wchar_t> wperiod_formatter; > typedef boost::date_time::period_formatter<char> period_formatter; > > typedef boost::date_time::date_facet<date,wchar_t> wdate_facet; > typedef boost::date_time::date_facet<date,char> date_facet; > > typedef boost::date_time::period_parser<date,char> period_parser; > typedef boost::date_time::period_parser<date,wchar_t> wperiod_parser; > > typedef boost::date_time::special_values_formatter<char> special_values_formatter; > typedef boost::date_time::special_values_formatter<wchar_t> wspecial_values_formatter; > > typedef boost::date_time::special_values_parser<date,char> special_values_parser; > typedef boost::date_time::special_values_parser<date,wchar_t> wspecial_values_parser; > > typedef boost::date_time::date_input_facet<date,char> date_input_facet; > typedef boost::date_time::date_input_facet<date,wchar_t> wdate_input_facet; > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, const boost::gregorian::date& d) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::date_facet<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) > std::use_facet<custom_date_facet>(os.getloc()).put(output_itr, os, os.fill(), d); > 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(), d); > } > return os; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, date& d) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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(...) { > > 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; > } > else { > > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, const boost::gregorian::date_duration& dd) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::date_facet<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) > std::use_facet<custom_date_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; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, date_duration& dd) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, const boost::gregorian::date_period& dp) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::date_facet<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) > std::use_facet<custom_date_facet>(os.getloc()).put(output_itr, os, os.fill(), dp); > 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(), dp); > > } > return os; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, date_period& dp) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, const boost::gregorian::greg_month& gm) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::date_facet<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) > std::use_facet<custom_date_facet>(os.getloc()).put(output_itr, os, os.fill(), gm); > 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(), gm); > } > return os; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, greg_month& m) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, const boost::gregorian::greg_weekday& gw) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::date_facet<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) > std::use_facet<custom_date_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; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, greg_weekday& wd) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, greg_day& gd) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, greg_year& gy) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, const boost::gregorian::partial_date& pd) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::date_facet<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) > std::use_facet<custom_date_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; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, partial_date& pd) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& 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<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) > std::use_facet<custom_date_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; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, > nth_day_of_the_week_in_month& nday) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& 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<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) > std::use_facet<custom_date_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; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, > first_day_of_the_week_in_month& fkd) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& 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<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) > std::use_facet<custom_date_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; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, > last_day_of_the_week_in_month& lkd) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, const boost::gregorian::first_day_of_the_week_after& fda) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::date_facet<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) { > std::use_facet<custom_date_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; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, > first_day_of_the_week_after& fka) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > template <class CharT, class TraitsT> > inline std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, const boost::gregorian::first_day_of_the_week_before& fdb) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::date_facet<date, CharT> custom_date_facet; > std::ostreambuf_iterator<CharT> output_itr(os); > if (std::has_facet<custom_date_facet>(os.getloc())) { > std::use_facet<custom_date_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; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, > first_day_of_the_week_before& fkb) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::date_input_facet<date, CharT> date_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<date_input_facet>(is.getloc())) { > std::use_facet<date_input_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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > >} } ># 32 "/usr/include/boost/date_time/gregorian/gregorian.hpp" 2 3 4 > > ># 1 "/usr/include/boost/date_time/gregorian/parsers.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/gregorian/parsers.hpp" 3 4 ># 1 "/usr/include/boost/date_time/date_parsing.hpp" 1 3 4 ># 15 "/usr/include/boost/date_time/date_parsing.hpp" 3 4 ># 1 "/usr/include/boost/tokenizer.hpp" 1 3 4 ># 20 "/usr/include/boost/tokenizer.hpp" 3 4 ># 1 "/usr/include/boost/token_iterator.hpp" 1 3 4 ># 21 "/usr/include/boost/token_iterator.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 22 "/usr/include/boost/token_iterator.hpp" 2 3 4 > ># 1 "/usr/include/boost/iterator/detail/minimum_category.hpp" 1 3 4 ># 12 "/usr/include/boost/iterator/detail/minimum_category.hpp" 3 4 >namespace boost { namespace detail { ># 23 "/usr/include/boost/iterator/detail/minimum_category.hpp" 3 4 >template <bool GreaterEqual, bool LessEqual> >struct minimum_category_impl ># 34 "/usr/include/boost/iterator/detail/minimum_category.hpp" 3 4 >; > >template <class T1, class T2> >struct error_not_related_by_convertibility; > >template <> >struct minimum_category_impl<true,false> >{ > template <class T1, class T2> struct apply > { > typedef T2 type; > }; >}; > >template <> >struct minimum_category_impl<false,true> >{ > template <class T1, class T2> struct apply > { > typedef T1 type; > }; >}; > >template <> >struct minimum_category_impl<true,true> >{ > template <class T1, class T2> struct apply > { > static_assert((is_same<T1,T2>::value), "(is_same<T1,T2>::value)"); > typedef T1 type; > }; >}; > >template <> >struct minimum_category_impl<false,false> >{ > template <class T1, class T2> struct apply > : error_not_related_by_convertibility<T1,T2> > { > }; >}; > >template <class T1 = mpl::_1, class T2 = mpl::_2> >struct minimum_category >{ > typedef minimum_category_impl< > > > > ::boost::is_convertible<T1,T2>::value > , ::boost::is_convertible<T2,T1>::value > > > > > outer; > > typedef typename outer::template apply<T1,T2> inner; > typedef typename inner::type type; > > >}; > >template <> >struct minimum_category<mpl::_1,mpl::_2> >{ > template <class T1, class T2> > struct apply : minimum_category<T1,T2> > {}; > > >}; ># 114 "/usr/include/boost/iterator/detail/minimum_category.hpp" 3 4 >}} ># 24 "/usr/include/boost/token_iterator.hpp" 2 3 4 ># 1 "/usr/include/boost/token_functions.hpp" 1 3 4 ># 37 "/usr/include/boost/token_functions.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cctype" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cctype" 3 4 ># 40 "/usr/include/c++/4.9.0/cctype" 3 ># 38 "/usr/include/boost/token_functions.hpp" 2 3 4 > > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 41 "/usr/include/boost/token_functions.hpp" 2 3 4 > > > ># 1 "/usr/include/c++/4.9.0/cwctype" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cwctype" 3 4 ># 40 "/usr/include/c++/4.9.0/cwctype" 3 ># 45 "/usr/include/boost/token_functions.hpp" 2 3 4 ># 77 "/usr/include/boost/token_functions.hpp" 3 4 >namespace boost{ ># 88 "/usr/include/boost/token_functions.hpp" 3 4 > struct escaped_list_error : public std::runtime_error{ > escaped_list_error(const std::string& what_arg):std::runtime_error(what_arg) { } > }; > > > > > template <class Char, > class Traits = typename std::basic_string<Char>::traits_type > > class escaped_list_separator { > > private: > typedef std::basic_string<Char,Traits> string_type; > struct char_eq { > Char e_; > char_eq(Char e):e_(e) { } > bool operator()(Char c) { > return Traits::eq(e_,c); > } > }; > string_type escape_; > string_type c_; > string_type quote_; > bool last_; > > bool is_escape(Char e) { > char_eq f(e); > return std::find_if(escape_.begin(),escape_.end(),f)!=escape_.end(); > } > bool is_c(Char e) { > char_eq f(e); > return std::find_if(c_.begin(),c_.end(),f)!=c_.end(); > } > bool is_quote(Char e) { > char_eq f(e); > return std::find_if(quote_.begin(),quote_.end(),f)!=quote_.end(); > } > template <typename iterator, typename Token> > void do_escape(iterator& next,iterator end,Token& tok) { > if (++next == end) > throw escaped_list_error(std::string("cannot end with escape")); > if (Traits::eq(*next,'n')) { > tok+='\n'; > return; > } > else if (is_quote(*next)) { > tok+=*next; > return; > } > else if (is_c(*next)) { > tok+=*next; > return; > } > else if (is_escape(*next)) { > tok+=*next; > return; > } > else > throw escaped_list_error(std::string("unknown escape sequence")); > } > > public: > > explicit escaped_list_separator(Char e = '\\', > Char c = ',',Char q = '\"') > : escape_(1,e), c_(1,c), quote_(1,q), last_(false) { } > > escaped_list_separator(string_type e, string_type c, string_type q) > : escape_(e), c_(c), quote_(q), last_(false) { } > > void reset() {last_=false;} > > template <typename InputIterator, typename Token> > bool operator()(InputIterator& next,InputIterator end,Token& tok) { > bool bInQuote = false; > tok = Token(); > > if (next == end) { > if (last_) { > last_ = false; > return true; > } > else > return false; > } > last_ = false; > for (;next != end;++next) { > if (is_escape(*next)) { > do_escape(next,end,tok); > } > else if (is_c(*next)) { > if (!bInQuote) { > > ++next; > > > last_ = true; > return true; > } > else tok+=*next; > } > else if (is_quote(*next)) { > bInQuote=!bInQuote; > } > else { > tok += *next; > } > } > return true; > } > }; > > > > > > namespace tokenizer_detail { ># 214 "/usr/include/boost/token_functions.hpp" 3 4 > template<typename traits, int N> > struct traits_extension_details : public traits { > typedef typename traits::char_type char_type; > static bool isspace(char_type c) > { > return std::iswspace(c) != 0; > } > static bool ispunct(char_type c) > { > return std::iswpunct(c) != 0; > } > }; > > template<typename traits> > struct traits_extension_details<traits, 1> : public traits { > typedef typename traits::char_type char_type; > static bool isspace(char_type c) > { > return std::isspace(c) != 0; > } > static bool ispunct(char_type c) > { > return std::ispunct(c) != 0; > } > }; > > > > > > template<typename traits> > struct traits_extension : public traits { > typedef typename traits::char_type char_type; > static bool isspace(char_type c) > { > > return traits_extension_details<traits, sizeof(char_type)>::isspace(c); > > > > } > > static bool ispunct(char_type c) > { > > return traits_extension_details<traits, sizeof(char_type)>::ispunct(c); > > > > } > }; ># 277 "/usr/include/boost/token_functions.hpp" 3 4 > template<class IteratorTag> > struct assign_or_plus_equal { > template<class Iterator, class Token> > static void assign(Iterator b, Iterator e, Token &t) { ># 294 "/usr/include/boost/token_functions.hpp" 3 4 > t.assign(b, e); > > > } > > template<class Token, class Value> > static void plus_equal(Token &, const Value &) { } > > > > > template<class Token> > static void clear(Token &) { } > }; > > template <> > struct assign_or_plus_equal<std::input_iterator_tag> { > template<class Iterator, class Token> > static void assign(Iterator , Iterator , Token &) { } > template<class Token, class Value> > static void plus_equal(Token &t, const Value &v) { > t += v; > } > template<class Token> > static void clear(Token &t) { > t = Token(); > } > }; > > > template<class Iterator> > struct pointer_iterator_category{ > typedef std::random_access_iterator_tag type; > }; > > > template<class Iterator> > struct class_iterator_category{ > typedef typename Iterator::iterator_category type; > }; > > > > > template<class Iterator> > struct get_iterator_category{ > typedef typename mpl::if_<is_pointer<Iterator>, > pointer_iterator_category<Iterator>, > class_iterator_category<Iterator> > >::type cat; > > typedef typename cat::type iterator_category; > }; > > > } > > > > > > > class offset_separator { > private: > > std::vector<int> offsets_; > unsigned int current_offset_; > bool wrap_offsets_; > bool return_partial_last_; > > public: > template <typename Iter> > offset_separator(Iter begin, Iter end, bool wrap_offsets = true, > bool return_partial_last = true) > : offsets_(begin,end), current_offset_(0), > wrap_offsets_(wrap_offsets), > return_partial_last_(return_partial_last) { } > > offset_separator() > : offsets_(1,1), current_offset_(), > wrap_offsets_(true), return_partial_last_(true) { } > > void reset() { > current_offset_ = 0; > } > > template <typename InputIterator, typename Token> > bool operator()(InputIterator& next, InputIterator end, Token& tok) > { > typedef tokenizer_detail::assign_or_plus_equal< > typename tokenizer_detail::get_iterator_category< > InputIterator > >::iterator_category > > assigner; > > (static_cast<void> (0)); > > assigner::clear(tok); > InputIterator start(next); > > if (next == end) > return false; > > if (current_offset_ == offsets_.size()) > { > if (wrap_offsets_) > current_offset_=0; > else > return false; > } > > int c = offsets_[current_offset_]; > int i = 0; > for (; i < c; ++i) { > if (next == end)break; > assigner::plus_equal(tok,*next++); > } > assigner::assign(start,next,tok); > > if (!return_partial_last_) > if (i < (c-1) ) > return false; > > ++current_offset_; > return true; > } > }; ># 437 "/usr/include/boost/token_functions.hpp" 3 4 > enum empty_token_policy { drop_empty_tokens, keep_empty_tokens }; > > > template <typename Char, > typename Tr = typename std::basic_string<Char>::traits_type > > class char_separator > { > typedef tokenizer_detail::traits_extension<Tr> Traits; > typedef std::basic_string<Char,Tr> string_type; > public: > explicit > char_separator(const Char* dropped_delims, > const Char* kept_delims = 0, > empty_token_policy empty_tokens = drop_empty_tokens) > : m_dropped_delims(dropped_delims), > m_use_ispunct(false), > m_use_isspace(false), > m_empty_tokens(empty_tokens), > m_output_done(false) > { > > if (kept_delims) > m_kept_delims = kept_delims; > } > > > explicit > char_separator() > : m_use_ispunct(true), > m_use_isspace(true), > m_empty_tokens(drop_empty_tokens) { } > > void reset() { } > > template <typename InputIterator, typename Token> > bool operator()(InputIterator& next, InputIterator end, Token& tok) > { > typedef tokenizer_detail::assign_or_plus_equal< > typename tokenizer_detail::get_iterator_category< > InputIterator > >::iterator_category > > assigner; > > assigner::clear(tok); > > > if (m_empty_tokens == drop_empty_tokens) > for (; next != end && is_dropped(*next); ++next) > { } > > InputIterator start(next); > > if (m_empty_tokens == drop_empty_tokens) { > > if (next == end) > return false; > > > > if (is_kept(*next)) { > assigner::plus_equal(tok,*next); > ++next; > } else > > for (; next != end && !is_dropped(*next) && !is_kept(*next); ++next) > assigner::plus_equal(tok,*next); > } > else { > > > if (next == end) > { > if (m_output_done == false) > { > m_output_done = true; > assigner::assign(start,next,tok); > return true; > } > else > return false; > } > > if (is_kept(*next)) { > if (m_output_done == false) > m_output_done = true; > else { > assigner::plus_equal(tok,*next); > ++next; > m_output_done = false; > } > } > else if (m_output_done == false && is_dropped(*next)) { > m_output_done = true; > } > else { > if (is_dropped(*next)) > start=++next; > for (; next != end && !is_dropped(*next) && !is_kept(*next); ++next) > assigner::plus_equal(tok,*next); > m_output_done = true; > } > } > assigner::assign(start,next,tok); > return true; > } > > private: > string_type m_kept_delims; > string_type m_dropped_delims; > bool m_use_ispunct; > bool m_use_isspace; > empty_token_policy m_empty_tokens; > bool m_output_done; > > bool is_kept(Char E) const > { > if (m_kept_delims.length()) > return m_kept_delims.find(E) != string_type::npos; > else if (m_use_ispunct) { > return Traits::ispunct(E) != 0; > } else > return false; > } > bool is_dropped(Char E) const > { > if (m_dropped_delims.length()) > return m_dropped_delims.find(E) != string_type::npos; > else if (m_use_isspace) { > return Traits::isspace(E) != 0; > } else > return false; > } > }; ># 582 "/usr/include/boost/token_functions.hpp" 3 4 > template <class Char, > class Tr = typename std::basic_string<Char>::traits_type > > class char_delimiters_separator { > private: > > typedef tokenizer_detail::traits_extension<Tr> Traits; > typedef std::basic_string<Char,Tr> string_type; > string_type returnable_; > string_type nonreturnable_; > bool return_delims_; > bool no_ispunct_; > bool no_isspace_; > > bool is_ret(Char E)const > { > if (returnable_.length()) > return returnable_.find(E) != string_type::npos; > else{ > if (no_ispunct_) {return false;} > else{ > int r = Traits::ispunct(E); > return r != 0; > } > } > } > bool is_nonret(Char E)const > { > if (nonreturnable_.length()) > return nonreturnable_.find(E) != string_type::npos; > else{ > if (no_isspace_) {return false;} > else{ > int r = Traits::isspace(E); > return r != 0; > } > } > } > > public: > explicit char_delimiters_separator(bool return_delims = false, > const Char* returnable = 0, > const Char* nonreturnable = 0) > : returnable_(returnable ? returnable : string_type().c_str()), > nonreturnable_(nonreturnable ? nonreturnable:string_type().c_str()), > return_delims_(return_delims), no_ispunct_(returnable!=0), > no_isspace_(nonreturnable!=0) { } > > void reset() { } > > public: > > template <typename InputIterator, typename Token> > bool operator()(InputIterator& next, InputIterator end,Token& tok) { > tok = Token(); > > > > for (;next!=end && ( is_nonret(*next) || (is_ret(*next) > && !return_delims_ ) );++next) { } > > if (next == end) { > return false; > } > > > > if (is_ret(*next) && return_delims_) { > tok+=*next; > ++next; > } > else > > for (;next!=end && !is_nonret(*next) && !is_ret(*next);++next) > tok+=*next; > > > return true; > } > }; > > >} ># 25 "/usr/include/boost/token_iterator.hpp" 2 3 4 > > >namespace boost >{ > template <class TokenizerFunc, class Iterator, class Type> > class token_iterator > : public iterator_facade< > token_iterator<TokenizerFunc, Iterator, Type> > , Type > , typename detail::minimum_category< > forward_traversal_tag > , typename iterator_traversal<Iterator>::type > >::type > , const Type& > > > { > > friend class iterator_core_access; > > TokenizerFunc f_; > Iterator begin_; > Iterator end_; > bool valid_; > Type tok_; > > void increment(){ > (static_cast<void> (0)); > valid_ = f_(begin_,end_,tok_); > } > > const Type& dereference() const { > (static_cast<void> (0)); > return tok_; > } > template<class Other> > bool equal(const Other& a) const{ > return (a.valid_ && valid_) > ?( (a.begin_==begin_) && (a.end_ == end_) ) > :(a.valid_==valid_); > > } > > void initialize(){ > if(valid_) return; > f_.reset(); > valid_ = (begin_ != end_)? > f_(begin_,end_,tok_):false; > } > public: > token_iterator():begin_(),end_(),valid_(false),tok_() { } > > token_iterator(TokenizerFunc f, Iterator begin, Iterator e = Iterator()) > : f_(f),begin_(begin),end_(e),valid_(false),tok_(){ initialize(); } > > token_iterator(Iterator begin, Iterator e = Iterator()) > : f_(),begin_(begin),end_(e),valid_(false),tok_() {initialize();} > > template<class OtherIter> > token_iterator( > token_iterator<TokenizerFunc, OtherIter,Type> const& t > , typename enable_if_convertible<OtherIter, Iterator>::type* = 0) > : f_(t.tokenizer_function()),begin_(t.base()) > ,end_(t.end()),valid_(!t.at_end()),tok_(t.current_token()) {} > > Iterator base()const{return begin_;} > > Iterator end()const{return end_;}; > > TokenizerFunc tokenizer_function()const{return f_;} > > Type current_token()const{return tok_;} > > bool at_end()const{return !valid_;} > > > > > }; > template < > class TokenizerFunc = char_delimiters_separator<char>, > class Iterator = std::string::const_iterator, > class Type = std::string > > > class token_iterator_generator { > > private: > public: > typedef token_iterator<TokenizerFunc,Iterator,Type> type; > }; > > > > > template<class Type, class Iterator, class TokenizerFunc> > typename token_iterator_generator<TokenizerFunc,Iterator,Type>::type > make_token_iterator(Iterator begin, Iterator end,const TokenizerFunc& fun){ > typedef typename > token_iterator_generator<TokenizerFunc,Iterator,Type>::type ret_type; > return ret_type(fun,begin,end); > } > >} ># 21 "/usr/include/boost/tokenizer.hpp" 2 3 4 > >namespace boost { > > > > > template < > typename TokenizerFunc = char_delimiters_separator<char>, > typename Iterator = std::string::const_iterator, > typename Type = std::string > > > class tokenizer { > private: > typedef token_iterator_generator<TokenizerFunc,Iterator,Type> TGen; > > > > > typedef typename TGen::type iter; > > public: > > typedef iter iterator; > typedef iter const_iterator; > typedef Type value_type; > typedef value_type& reference; > typedef const value_type& const_reference; > typedef value_type* pointer; > typedef const pointer const_pointer; > typedef void size_type; > typedef void difference_type; > > tokenizer(Iterator first, Iterator last, > const TokenizerFunc& f = TokenizerFunc()) > : first_(first), last_(last), f_(f) { } > > template <typename Container> > tokenizer(const Container& c) > : first_(c.begin()), last_(c.end()), f_() { } > > template <typename Container> > tokenizer(const Container& c,const TokenizerFunc& f) > : first_(c.begin()), last_(c.end()), f_(f) { } > > void assign(Iterator first, Iterator last){ > first_ = first; > last_ = last; > } > > void assign(Iterator first, Iterator last, const TokenizerFunc& f){ > assign(first,last); > f_ = f; > } > > template <typename Container> > void assign(const Container& c){ > assign(c.begin(),c.end()); > } > > > template <typename Container> > void assign(const Container& c, const TokenizerFunc& f){ > assign(c.begin(),c.end(),f); > } > > iter begin() const { return iter(f_,first_,last_); } > iter end() const { return iter(f_,last_,last_); } > > private: > Iterator first_; > Iterator last_; > TokenizerFunc f_; > }; > > >} ># 16 "/usr/include/boost/date_time/date_parsing.hpp" 2 3 4 ># 26 "/usr/include/boost/date_time/date_parsing.hpp" 3 4 >namespace boost { >namespace date_time { > > > > > > > > inline > std::string > convert_to_lower(std::string inp) > { > > const std::locale loc(std::locale::classic()); > > std::string::size_type i = 0, n = inp.length(); > for (; i < n; ++i) { > inp[i] = > > > > > > std::tolower(inp[i], loc); > > } > return inp; > } > > > > > template<class month_type> > inline unsigned short > month_str_to_ushort(std::string const& s) { > if((s.at(0) >= '0') && (s.at(0) <= '9')) { > return boost::lexical_cast<unsigned short>(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()) { > return iter->second; > } > } > return 13; > } ># 83 "/usr/include/boost/date_time/date_parsing.hpp" 3 4 > template<class charT> > short find_match(const charT* const* short_names, > const charT* const* long_names, > short size, > const std::basic_string<charT>& s) { > for(short i = 0; i < size; ++i){ > if(short_names[i] == s || long_names[i] == s){ > return i; > } > } > return size; > } > > > > > > > > template<class date_type> > 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 { > 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<char>::traits_type traits_type; > typedef boost::char_separator<char, traits_type> char_separator_type; > typedef boost::tokenizer<char_separator_type, > std::basic_string<char>::const_iterator, > std::basic_string<char> > tokenizer; > typedef boost::tokenizer<char_separator_type, > std::basic_string<char>::const_iterator, > std::basic_string<char> >::iterator tokenizer_iterator; > > 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<unsigned short>(*beg); > break; > } > case 'm': > { > month = month_str_to_ushort<month_type>(*beg); > break; > } > case 'd': > { > day = boost::lexical_cast<unsigned short>(*beg); > break; > } > default: break; > } > } > return date_type(year, month, day); > } > > > template<class date_type> > 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; > > unsigned short y = 0, m = 0, d = 0; > > > > > > > boost::offset_separator osf(offsets, offsets+3, false, false); > > typedef typename boost::tokenizer<boost::offset_separator, > std::basic_string<char>::const_iterator, > std::basic_string<char> > 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<unsigned short>(*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); > } > > > > > > template<class date_type, class iterator_type> > 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<date_type>(ss.str()); > } > > > > > template<class date_type, class iterator_type> > inline > date_type > from_stream_type(iterator_type& beg, > iterator_type const& , > std::string const&) > { > return parse_date<date_type>(*beg); > } > > > > > > > > template<class date_type, class iterator_type> > inline > date_type from_stream_type(iterator_type& beg, > iterator_type const& end, > wchar_t) > { > std::ostringstream ss; > > std::locale loc; > std::ctype<wchar_t> const& fac = std::use_facet<std::ctype<wchar_t> >(loc); > while(beg != end) { > ss << fac.narrow(*beg++, 'X'); > } ># 250 "/usr/include/boost/date_time/date_parsing.hpp" 3 4 > return parse_date<date_type>(ss.str()); > } > > > > > template<class date_type, class iterator_type> > inline > date_type > from_stream_type(iterator_type& beg, > iterator_type const& , > std::wstring const&) { > std::wstring ws = *beg; > std::ostringstream ss; > std::wstring::iterator wsb = ws.begin(), wse = ws.end(); > > std::locale loc; > std::ctype<wchar_t> const& fac = std::use_facet<std::ctype<wchar_t> >(loc); > while(wsb != wse) { > ss << fac.narrow(*wsb++, 'X'); > } ># 280 "/usr/include/boost/date_time/date_parsing.hpp" 3 4 > return parse_date<date_type>(ss.str()); > } > > > > > > template<class date_type, class charT> > period<date_type, typename date_type::duration_type> > from_simple_string_type(const std::basic_string<charT>& s){ > typedef typename std::basic_string<charT>::traits_type traits_type; > typedef typename boost::char_separator<charT, traits_type> char_separator; > typedef typename boost::tokenizer<char_separator, > typename std::basic_string<charT>::const_iterator, > std::basic_string<charT> > 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<charT> date_string = *tok_it; > > typename std::basic_string<charT>::iterator date_string_start = date_string.begin(), > date_string_end = date_string.end(); > typedef typename std::iterator_traits<typename std::basic_string<charT>::iterator>::value_type value_type; > date_type d1 = from_stream_type<date_type>(date_string_start, date_string_end, value_type()); > date_string = *(++tok_it); > date_string_start = date_string.begin(), date_string_end = date_string.end(); > date_type d2 = from_stream_type<date_type>(date_string_start, date_string_end, value_type()); > return period<date_type, typename date_type::duration_type>(d1, d2); > } > > >} } ># 14 "/usr/include/boost/date_time/gregorian/parsers.hpp" 2 3 4 > > > > > >namespace boost { >namespace gregorian { > > > > > > special_values special_value_from_string(const std::string& s); > > > inline date from_string(std::string s) { > return date_time::parse_date<date>(s); > } > > > inline date from_simple_string(std::string s) { > return date_time::parse_date<date>(s, date_time::ymd_order_iso); > } > > > inline date from_us_string(std::string s) { > return date_time::parse_date<date>(s, date_time::ymd_order_us); > } > > > inline date from_uk_string(std::string s) { > return date_time::parse_date<date>(s, date_time::ymd_order_dmy); > } > > > inline date from_undelimited_string(std::string s) { > return date_time::parse_undelimited_date<date>(s); > } > > > inline date date_from_iso_string(const std::string& s) { > return date_time::parse_undelimited_date<date>(s); > } > > > > > > > template<class iterator_type> > inline date from_stream(iterator_type beg, iterator_type end) { > if(beg == end) > { > return date(not_a_date_time); > } > typedef typename std::iterator_traits<iterator_type>::value_type value_type; > return date_time::from_stream_type<date>(beg, end, value_type()); > } > > > > > > > inline date_period date_period_from_string(const std::string& s){ > return date_time::from_simple_string_type<date,char>(s); > } > > > inline date_period date_period_from_wstring(const std::wstring& s){ > return date_time::from_simple_string_type<date,wchar_t>(s); > } > > > >} } ># 35 "/usr/include/boost/date_time/gregorian/gregorian.hpp" 2 3 4 ># 13 "/usr/include/boost/date_time/posix_time/time_formatters.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/date_time/time_formatting_streams.hpp" 1 3 4 ># 19 "/usr/include/boost/date_time/time_formatting_streams.hpp" 3 4 ># 1 "/usr/include/boost/date_time/date_formatting_locales.hpp" 1 3 4 ># 18 "/usr/include/boost/date_time/date_formatting_locales.hpp" 3 4 ># 1 "/usr/include/boost/date_time/date_names_put.hpp" 1 3 4 ># 24 "/usr/include/boost/date_time/date_names_put.hpp" 3 4 >namespace boost { >namespace date_time { ># 39 "/usr/include/boost/date_time/date_names_put.hpp" 3 4 > template<class Config, > class charT = char, > class OutputIterator = std::ostreambuf_iterator<charT> > > 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 std::basic_string<charT> 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; > > > > > > 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); > } > > void month_sep_char(iter_type& oitr) const > { > do_month_sep_char(oitr); > } > > void day_sep_char(iter_type& oitr) const > { > do_day_sep_char(oitr); > } > > ymd_order_spec date_order() const > { > return do_date_order(); > } > > month_format_spec month_format() const > { > return do_month_format(); > } > > protected: > > 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)); > } > > 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)); > } > > virtual void do_put_special_value(iter_type& oitr, special_value_enum sv) const > { > if(sv <= 2) { > 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); > } > > virtual void do_month_sep_char(iter_type& oitr) const > { > string_type s(separator); > put_string(oitr, s); > } > > virtual void do_day_sep_char(iter_type& oitr) const > { > string_type s(separator); > put_string(oitr, s); > } > > virtual ymd_order_spec do_date_order() const > { > return ymd_order_iso; > } > > 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<string_type>(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<class Config, class charT, class OutputIterator> > const typename date_names_put<Config, charT, OutputIterator>::char_type > date_names_put<Config, charT, OutputIterator>::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<class Config, class charT, class OutputIterator> > const typename date_names_put<Config, charT, OutputIterator>::char_type > date_names_put<Config, charT, OutputIterator>::separator[2] = > {'-', '\0'} ; > > > > template<class Config, class charT, class OutputIterator> > std::locale::id date_names_put<Config, charT, OutputIterator>::id; > > > template<class Config, > class charT = char, > class OutputIterator = std::ostreambuf_iterator<charT> > > class all_date_names_put : public date_names_put<Config, charT, OutputIterator> > { > 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: > > virtual void do_put_month_short(iter_type& oitr, month_enum moy) const > { > this->put_string(oitr, month_short_names_[moy-1]); > } > > virtual void do_put_month_long(iter_type& oitr, month_enum moy) const > { > this->put_string(oitr, month_long_names_[moy-1]); > } > > 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]); > } > > virtual void do_month_sep_char(iter_type& oitr) const > { > this->put_string(oitr, separator_char_); > } > > virtual void do_day_sep_char(iter_type& oitr) const > { > this->put_string(oitr, separator_char_); > } > > virtual ymd_order_spec do_date_order() const > { > return order_spec_; > } > > 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_; > }; > >} } ># 19 "/usr/include/boost/date_time/date_formatting_locales.hpp" 2 3 4 > > > > > > >namespace boost { >namespace date_time { > > > template<class facet_type, > class charT = char> > class ostream_month_formatter > { > public: > typedef typename facet_type::month_type month_type; > typedef std::basic_ostream<charT> ostream_type; > > > 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<charT> oitr(os); > f.put_month_short(oitr, month.as_enum()); > break; > } > case month_as_long_string: > { > std::ostreambuf_iterator<charT> 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; > } > > } > } > > }; > > > > template<class weekday_type, > class facet_type, > class charT = char> > class ostream_weekday_formatter > { > public: > typedef typename facet_type::month_type month_type; > typedef std::basic_ostream<charT> ostream_type; > > > static void format_weekday(const weekday_type& wd, > ostream_type& os, > const facet_type& f, > bool as_long_string) > { > > std::ostreambuf_iterator<charT> oitr(os); > if (as_long_string) { > f.put_weekday_long(oitr, wd.as_enum()); > } > else { > f.put_weekday_short(oitr, wd.as_enum()); > } > > } > > }; > > > > template<class ymd_type, > class facet_type, > class charT = char> > class ostream_ymd_formatter > { > public: > typedef typename ymd_type::month_type month_type; > typedef ostream_month_formatter<facet_type, charT> month_formatter_type; > typedef std::basic_ostream<charT> ostream_type; > typedef std::basic_string<charT> foo_type; ># 131 "/usr/include/boost/date_time/date_formatting_locales.hpp" 3 4 > static void ymd_put(ymd_type ymd, > ostream_type& os, > const facet_type& f) > { > std::ostreambuf_iterator<charT> 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; > } > } > } > }; > > > > template<class date_type, > class facet_type, > class charT = char> > class ostream_date_formatter > { > public: > typedef std::basic_ostream<charT> ostream_type; > typedef typename date_type::ymd_type ymd_type; > > > 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_type, facet_type, charT>::ymd_put(ymd, os, f); > } > else { > std::ostreambuf_iterator<charT> coi(os); > f.put_special_value(coi, sv); > } > } > > > > static void date_put(const date_type& d, > ostream_type& os) > { > > std::locale locale = os.getloc(); > if (std::has_facet<facet_type>(locale)) { > const facet_type& f = std::use_facet<facet_type>(locale); > date_put(d, os, f); > } > else { > > facet_type default_facet; > date_put(d, os, default_facet); > } > } > }; > > >} } ># 20 "/usr/include/boost/date_time/time_formatting_streams.hpp" 2 3 4 > > >namespace boost { >namespace date_time { > > > > template<class time_duration_type, > class charT = char> > class ostream_time_duration_formatter > { > public: > typedef std::basic_ostream<charT> ostream_type; > typedef typename time_duration_type::fractional_seconds_type fractional_seconds_type; > > > 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; > } > } > } > }; > > > template<class time_type, > class charT = char> > class ostream_time_formatter > { > public: > typedef std::basic_ostream<charT> 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<time_duration_type, charT> duration_formatter; > > > 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 << " "; > duration_formatter::duration_put(t.time_of_day(), os); > } > > } > }; > > > > template<class time_period_type, > class charT = char> > class ostream_time_period_formatter > { > public: > typedef std::basic_ostream<charT> ostream_type; > typedef typename time_period_type::point_type time_type; > typedef ostream_time_formatter<time_type, charT> time_formatter; > > > static void period_put(const time_period_type& tp, > ostream_type& os) > { > os << '['; > time_formatter::time_put(tp.begin(), os); > os << '/'; > time_formatter::time_put(tp.last(), os); > os << ']'; > > } > > }; > > > >} } ># 18 "/usr/include/boost/date_time/posix_time/time_formatters.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/time_parsing.hpp" 1 3 4 ># 15 "/usr/include/boost/date_time/time_parsing.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/time_parsing.hpp" 2 3 4 > > >namespace boost { >namespace date_time { > > > > > template<class int_type> > 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; > } ># 45 "/usr/include/boost/date_time/time_parsing.hpp" 3 4 > template<class time_duration, class char_type> > inline > time_duration > str_from_delimited_time_duration(const std::basic_string<char_type>& 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<char_type>::traits_type traits_type; > typedef boost::char_separator<char_type, traits_type> char_separator_type; > typedef boost::tokenizer<char_separator_type, > typename std::basic_string<char_type>::const_iterator, > std::basic_string<char_type> > tokenizer; > typedef typename boost::tokenizer<char_separator_type, > typename std::basic_string<char_type>::const_iterator, > typename std::basic_string<char_type> >::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<int>(*beg); > break; > } > case 1: { > min = boost::lexical_cast<unsigned short>(*beg); > break; > } > case 2: { > sec = boost::lexical_cast<unsigned short>(*beg); > break; > }; > case 3: { > int digits = static_cast<int>(beg->length()); ># 101 "/usr/include/boost/date_time/time_parsing.hpp" 3 4 > int precision = time_duration::num_fractional_digits(); > if(digits >= precision) { > > fs = boost::lexical_cast<boost::int64_t>(beg->substr(0, precision)); > } > else { > fs = boost::lexical_cast<boost::int64_t>(*beg); > } > > if(digits < precision){ > > > > fs *= power(10, precision - digits); > } > > break; > } > default: break; > } > pos++; > } > if(is_neg) { > return -time_duration(hour, min, sec, fs); > } > else { > return time_duration(hour, min, sec, fs); > } > } ># 141 "/usr/include/boost/date_time/time_parsing.hpp" 3 4 > template<class time_duration> > inline > time_duration > parse_delimited_time_duration(const std::string& s) > { > return str_from_delimited_time_duration<time_duration,char>(s); > } > > > 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<class time_type> > 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; > > > std::string date_string, tod_string; > split(s, sep, date_string, tod_string); > > date_type d = parse_date<date_type>(date_string); > > time_duration td = parse_delimited_time_duration<time_duration>(tod_string); > > return time_type(d, td); > > } > > > template<class time_duration> > inline > time_duration > parse_undelimited_time_duration(const std::string& s) > { > int precision = 0; > { > > > > time_duration tmp(0,0,0,1); > precision = tmp.num_fractional_digits(); > } > > 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; > > if(s.at(sign) == '-') > { > ++sign; > } > > > std::string remain = s.substr(sign); > > > > > > bool wrap_off = false; > bool ret_part = true; > boost::offset_separator osf(offsets, offsets+4, wrap_off, ret_part); > typedef boost::tokenizer<boost::offset_separator, > std::basic_string<char>::const_iterator, > std::basic_string<char> > tokenizer; > typedef boost::tokenizer<boost::offset_separator, > std::basic_string<char>::const_iterator, > std::basic_string<char> >::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<int>(*ti); > break; > } > case 1: > { > min = boost::lexical_cast<short>(*ti); > break; > } > case 2: > { > sec = boost::lexical_cast<short>(*ti); > break; > } > case 3: > { > std::string char_digits(ti->substr(1)); > int digits = static_cast<int>(char_digits.length()); ># 265 "/usr/include/boost/date_time/time_parsing.hpp" 3 4 > if(digits >= precision) { > > fs = boost::lexical_cast<boost::int64_t>(char_digits.substr(0, precision)); > } > else if(digits == 0) { > fs = 0; > } > else { > fs = boost::lexical_cast<boost::int64_t>(char_digits); > } > > if(digits < precision){ > > > > 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); > } > } > > > template<class time_type> > 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; > > > std::string date_string, tod_string; > split(s, sep, date_string, tod_string); > > date_type d = parse_undelimited_date<date_type>(date_string); > > time_duration td = parse_undelimited_time_duration<time_duration>(tod_string); > > return time_type(d, td); > } > > > >} } ># 20 "/usr/include/boost/date_time/posix_time/time_formatters.hpp" 2 3 4 > > > > > > >namespace boost { > >namespace posix_time { > > > > template<class charT> > inline std::basic_string<charT> to_simple_string_type(time_duration td) { > std::basic_ostringstream<charT> ss; > if(td.is_special()) { > > > > switch(td.get_rep().as_special()) > { > case not_a_date_time: > > 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()); ># 74 "/usr/include/boost/date_time/posix_time/time_formatters.hpp" 3 4 > time_duration::fractional_seconds_type frac_sec = > date_time::absolute_value(td.fractional_seconds()); > > if (frac_sec != 0) { > ss << "." << std::setw(time_duration::num_fractional_digits()) > << std::setfill(fill_char) > > > > > > << frac_sec; > > } > } > return ss.str(); > } > > > > inline std::string to_simple_string(time_duration td) { > return to_simple_string_type<char>(td); > } > > > > > template<class charT> > inline std::basic_string<charT> to_iso_string_type(time_duration td) > { > std::basic_ostringstream<charT> ss; > if(td.is_special()) { > > > > switch(td.get_rep().as_special()) { > case not_a_date_time: > > 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()); ># 143 "/usr/include/boost/date_time/posix_time/time_formatters.hpp" 3 4 > time_duration::fractional_seconds_type frac_sec = > date_time::absolute_value(td.fractional_seconds()); > > if (frac_sec != 0) { > ss << "." << std::setw(time_duration::num_fractional_digits()) > << std::setfill(fill_char) > > > > > > << frac_sec; > > } > } > return ss.str(); > } > > > > inline std::string to_iso_string(time_duration td){ > return to_iso_string_type<char>(td); > } > > > > > template<class charT> > inline std::basic_string<charT> to_simple_string_type(ptime t) > { > > std::basic_string<charT> ts = gregorian::to_simple_string_type<charT>(t.date()); > if(!t.time_of_day().is_special()) { > charT space = ' '; > return ts + space + to_simple_string_type<charT>(t.time_of_day()); > } > else { > return ts; > } > } > inline std::string to_simple_string(ptime t){ > return to_simple_string_type<char>(t); > } > > > > template<class charT> > inline std::basic_string<charT> to_simple_string_type(time_period tp) > { > charT beg = '[', mid = '/', end = ']'; > std::basic_string<charT> d1(to_simple_string_type<charT>(tp.begin())); > std::basic_string<charT> d2(to_simple_string_type<charT>(tp.last())); > return std::basic_string<charT>(beg + d1 + mid + d2 + end); > } > > > > inline std::string to_simple_string(time_period tp){ > return to_simple_string_type<char>(tp); > } > > > > template<class charT> > inline std::basic_string<charT> to_iso_string_type(ptime t) > { > std::basic_string<charT> ts = gregorian::to_iso_string_type<charT>(t.date()); > if(!t.time_of_day().is_special()) { > charT sep = 'T'; > return ts + sep + to_iso_string_type<charT>(t.time_of_day()); > } > else { > return ts; > } > } > > > > inline std::string to_iso_string(ptime t){ > return to_iso_string_type<char>(t); > } > > > > > template<class charT> > inline std::basic_string<charT> to_iso_extended_string_type(ptime t) > { > std::basic_string<charT> ts = gregorian::to_iso_extended_string_type<charT>(t.date()); > if(!t.time_of_day().is_special()) { > charT sep = 'T'; > return ts + sep + to_simple_string_type<charT>(t.time_of_day()); > } > else { > return ts; > } > } > > > > inline std::string to_iso_extended_string(ptime t){ > return to_iso_extended_string_type<char>(t); > } > > > > > > inline std::wstring to_simple_wstring(time_duration td) { > return to_simple_string_type<wchar_t>(td); > } > > > > inline std::wstring to_iso_wstring(time_duration td){ > return to_iso_string_type<wchar_t>(td); > } > inline std::wstring to_simple_wstring(ptime t){ > return to_simple_string_type<wchar_t>(t); > } > > > > inline std::wstring to_simple_wstring(time_period tp){ > return to_simple_string_type<wchar_t>(tp); > } > > > > inline std::wstring to_iso_wstring(ptime t){ > return to_iso_string_type<wchar_t>(t); > } > > > > inline std::wstring to_iso_extended_wstring(ptime t){ > return to_iso_extended_string_type<wchar_t>(t); > } > > > > >} } ># 25 "/usr/include/boost/date_time/posix_time/posix_time.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/date_time/posix_time/posix_time_io.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/posix_time/posix_time_io.hpp" 3 4 ># 1 "/usr/include/boost/date_time/time_facet.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/time_facet.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cctype" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cctype" 3 4 ># 40 "/usr/include/c++/4.9.0/cctype" 3 ># 14 "/usr/include/boost/date_time/time_facet.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 22 "/usr/include/boost/date_time/time_facet.hpp" 2 3 4 ># 33 "/usr/include/boost/date_time/time_facet.hpp" 3 4 >namespace boost { >namespace date_time { > > template <class CharT> > struct time_formats { > public: > typedef CharT char_type; > static const char_type fractional_seconds_format[3]; > static const char_type fractional_seconds_or_none_format[3]; > static const char_type seconds_with_fractional_seconds_format[3]; > static const char_type seconds_format[3]; > static const char_type hours_format[3]; > static const char_type unrestricted_hours_format[3]; > static const char_type full_24_hour_time_format[3]; > static const char_type full_24_hour_time_expanded_format[9]; > static const char_type short_24_hour_time_format[3]; > static const char_type short_24_hour_time_expanded_format[6]; > static const char_type standard_format[9]; > static const char_type zone_abbrev_format[3]; > static const char_type zone_name_format[3]; > static const char_type zone_iso_format[3]; > static const char_type zone_iso_extended_format[3]; > static const char_type posix_zone_string_format[4]; > static const char_type duration_sign_negative_only[3]; > static const char_type duration_sign_always[3]; > static const char_type duration_seperator[2]; > static const char_type negative_sign[2]; > static const char_type positive_sign[2]; > static const char_type iso_time_format_specifier[18]; > static const char_type iso_time_format_extended_specifier[22]; > > static const char_type default_time_format[23]; > > static const char_type default_time_input_format[24]; > > static const char_type default_time_duration_format[11]; > }; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::fractional_seconds_format[3] = {'%','f'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::fractional_seconds_or_none_format[3] = {'%','F'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::seconds_with_fractional_seconds_format[3] = {'%','s'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::seconds_format[3] = {'%','S'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::hours_format[3] = {'%','H'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::unrestricted_hours_format[3] = {'%','O'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::full_24_hour_time_format[3] = {'%','T'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::full_24_hour_time_expanded_format[9] = > {'%','H',':','%','M',':','%','S'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::short_24_hour_time_format[3] = {'%','R'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::short_24_hour_time_expanded_format[6] = > {'%','H',':','%','M'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > > time_formats<CharT>::standard_format[9] = {'%','x',' ','%','X',' ','%','z'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::zone_abbrev_format[3] = {'%','z'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::zone_name_format[3] = {'%','Z'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::zone_iso_format[3] = {'%','q'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::zone_iso_extended_format[3] ={'%','Q'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::posix_zone_string_format[4] ={'%','Z','P'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::duration_seperator[2] = {':'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::negative_sign[2] = {'-'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::positive_sign[2] = {'+'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::duration_sign_negative_only[3] ={'%','-'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::duration_sign_always[3] ={'%','+'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::iso_time_format_specifier[18] = > {'%', 'Y', '%', 'm', '%', 'd', 'T', > '%', 'H', '%', 'M', '%', 'S', '%', 'F', '%','q' }; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::iso_time_format_extended_specifier[22] = > {'%', 'Y', '-', '%', 'm', '-', '%', 'd', ' ', > '%', 'H', ':', '%', 'M', ':', '%', 'S', '%', 'F','%','Q'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::default_time_format[23] = > {'%','Y','-','%','b','-','%','d',' ', > '%','H',':','%','M',':','%','S','%','F',' ','%','z'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::default_time_input_format[24] = > {'%','Y','-','%','b','-','%','d',' ', > '%','H',':','%','M',':','%','S','%','F',' ','%','Z','P'}; > > template <class CharT> > const typename time_formats<CharT>::char_type > time_formats<CharT>::default_time_duration_format[11] = > {'%','O',':','%','M',':','%','S','%','F'}; ># 200 "/usr/include/boost/date_time/time_facet.hpp" 3 4 > template <class time_type, > class CharT, > class OutItrT = std::ostreambuf_iterator<CharT, std::char_traits<CharT> > > > class time_facet : > public boost::date_time::date_facet<typename time_type::date_type , CharT, OutItrT> { > typedef time_formats< CharT > formats_type; > public: > typedef typename time_type::date_type date_type; > typedef typename time_type::time_duration_type time_duration_type; > typedef boost::date_time::period<time_type,time_duration_type> period_type; > typedef boost::date_time::date_facet<typename time_type::date_type, CharT, OutItrT> base_type; > typedef typename base_type::string_type string_type; > typedef typename base_type::char_type char_type; > typedef typename base_type::period_formatter_type period_formatter_type; > typedef typename base_type::special_values_formatter_type special_values_formatter_type; > typedef typename base_type::date_gen_formatter_type date_gen_formatter_type; > static const char_type* fractional_seconds_format; > static const char_type* fractional_seconds_or_none_format; > static const char_type* seconds_with_fractional_seconds_format; > static const char_type* seconds_format; > static const char_type* hours_format; > static const char_type* unrestricted_hours_format; > static const char_type* standard_format; > static const char_type* zone_abbrev_format; > static const char_type* zone_name_format; > static const char_type* zone_iso_format; > static const char_type* zone_iso_extended_format; > static const char_type* posix_zone_string_format; > static const char_type* duration_seperator; > static const char_type* duration_sign_always; > static const char_type* duration_sign_negative_only; > static const char_type* negative_sign; > static const char_type* positive_sign; > static const char_type* iso_time_format_specifier; > static const char_type* iso_time_format_extended_specifier; > > > static const char_type* default_time_format; > > static const char_type* default_time_duration_format; > static std::locale::id id; > > > > > > > explicit time_facet(::size_t ref_arg = 0) > : base_type(default_time_format, period_formatter_type(), special_values_formatter_type(), date_gen_formatter_type(), ref_arg), > m_time_duration_format(string_type(duration_sign_negative_only) + default_time_duration_format) > {} > > > explicit time_facet(const char_type* format_arg, > period_formatter_type period_formatter_arg = period_formatter_type(), > const special_values_formatter_type& special_value_formatter = special_values_formatter_type(), > date_gen_formatter_type dg_formatter = date_gen_formatter_type(), > ::size_t ref_arg = 0) > : base_type(format_arg, > period_formatter_arg, > special_value_formatter, > dg_formatter, > ref_arg), > m_time_duration_format(string_type(duration_sign_negative_only) + default_time_duration_format) > {} > > > void time_duration_format(const char_type* const format) > { > m_time_duration_format = format; > } > > virtual void set_iso_format() > { > this->m_format = iso_time_format_specifier; > } > virtual void set_iso_extended_format() > { > this->m_format = iso_time_format_extended_specifier; > } > > OutItrT put(OutItrT next_arg, > std::ios_base& ios_arg, > char_type fill_arg, > const time_type& time_arg) const > { > if (time_arg.is_special()) { > return this->do_put_special(next_arg, ios_arg, fill_arg, > time_arg.date().as_special()); > } > string_type local_format(this->m_format); > > > boost::algorithm::replace_all(local_format, > boost::as_literal(formats_type::full_24_hour_time_format), > boost::as_literal(formats_type::full_24_hour_time_expanded_format)); > boost::algorithm::replace_all(local_format, > boost::as_literal(formats_type::short_24_hour_time_format), > boost::as_literal(formats_type::short_24_hour_time_expanded_format)); > > string_type frac_str; > if (local_format.find(seconds_with_fractional_seconds_format) != string_type::npos) { > > frac_str = > fractional_seconds_as_string(time_arg.time_of_day(), false); > char_type sep = std::use_facet<std::numpunct<char_type> >(ios_arg.getloc()).decimal_point(); > > string_type replace_string(seconds_format); > replace_string += sep; > replace_string += frac_str; > boost::algorithm::replace_all(local_format, > seconds_with_fractional_seconds_format, > replace_string); > } > > > > if (local_format.find(posix_zone_string_format) != string_type::npos) { > if(time_arg.zone_abbrev().empty()) { > > > boost::algorithm::erase_all(local_format, posix_zone_string_format); > } > else{ > boost::algorithm::replace_all(local_format, > posix_zone_string_format, > time_arg.zone_as_posix_string()); > } > } > if (local_format.find(zone_name_format) != string_type::npos) { > if(time_arg.zone_name().empty()) { > > > > > > > std::basic_ostringstream<char_type> ss; > ss << ' ' << zone_name_format; > boost::algorithm::erase_all(local_format, ss.str()); > } > else{ > boost::algorithm::replace_all(local_format, > zone_name_format, > time_arg.zone_name()); > } > } > if (local_format.find(zone_abbrev_format) != string_type::npos) { > if(time_arg.zone_abbrev(false).empty()) { > > > > > > > std::basic_ostringstream<char_type> ss; > ss << ' ' << zone_abbrev_format; > boost::algorithm::erase_all(local_format, ss.str()); > } > else{ > boost::algorithm::replace_all(local_format, > zone_abbrev_format, > time_arg.zone_abbrev(false)); > } > } > if (local_format.find(zone_iso_extended_format) != string_type::npos) { > if(time_arg.zone_name(true).empty()) { > > > > > > > boost::algorithm::erase_all(local_format, zone_iso_extended_format); > } > else{ > boost::algorithm::replace_all(local_format, > zone_iso_extended_format, > time_arg.zone_name(true)); > } > } > > if (local_format.find(zone_iso_format) != string_type::npos) { > if(time_arg.zone_abbrev(true).empty()) { > > > > > > > boost::algorithm::erase_all(local_format, zone_iso_format); > } > else{ > boost::algorithm::replace_all(local_format, > zone_iso_format, > time_arg.zone_abbrev(true)); > } > } > if (local_format.find(fractional_seconds_format) != string_type::npos) { > > if (frac_str.empty()) { > frac_str = fractional_seconds_as_string(time_arg.time_of_day(), false); > } > boost::algorithm::replace_all(local_format, > fractional_seconds_format, > frac_str); > } > > if (local_format.find(fractional_seconds_or_none_format) != string_type::npos) { > > frac_str = > fractional_seconds_as_string(time_arg.time_of_day(), true); > if (frac_str.size()) { > char_type sep = std::use_facet<std::numpunct<char_type> >(ios_arg.getloc()).decimal_point(); > string_type replace_string; > replace_string += sep; > replace_string += frac_str; > boost::algorithm::replace_all(local_format, > fractional_seconds_or_none_format, > replace_string); > } > else { > boost::algorithm::erase_all(local_format, > fractional_seconds_or_none_format); > } > } > > return this->do_put_tm(next_arg, ios_arg, fill_arg, > to_tm(time_arg), local_format); > } > > > OutItrT put(OutItrT next_arg, > std::ios_base& ios_arg, > char_type fill_arg, > const time_duration_type& time_dur_arg) const > { > if (time_dur_arg.is_special()) { > return this->do_put_special(next_arg, ios_arg, fill_arg, > time_dur_arg.get_rep().as_special()); > } > > string_type format(m_time_duration_format); > if (time_dur_arg.is_negative()) { > > boost::algorithm::replace_all(format, > duration_sign_negative_only, > negative_sign); > > boost::algorithm::replace_all(format, > duration_sign_always, > negative_sign); > } > else { > > boost::algorithm::erase_all(format, duration_sign_negative_only); > > boost::algorithm::replace_all(format, > duration_sign_always, > positive_sign); > } > > > boost::algorithm::replace_all(format, > boost::as_literal(formats_type::full_24_hour_time_format), > boost::as_literal(formats_type::full_24_hour_time_expanded_format)); > boost::algorithm::replace_all(format, > boost::as_literal(formats_type::short_24_hour_time_format), > boost::as_literal(formats_type::short_24_hour_time_expanded_format)); ># 478 "/usr/include/boost/date_time/time_facet.hpp" 3 4 > string_type hours_str; > if (format.find(unrestricted_hours_format) != string_type::npos) { > hours_str = hours_as_string(time_dur_arg); > boost::algorithm::replace_all(format, unrestricted_hours_format, hours_str); > } > > > > if (format.find(hours_format) != string_type::npos) { > if (hours_str.empty()) > hours_str = hours_as_string(time_dur_arg); > (static_cast<void> (0)); > boost::algorithm::replace_all(format, hours_format, hours_str); > } > > string_type frac_str; > if (format.find(seconds_with_fractional_seconds_format) != string_type::npos) { > > frac_str = > fractional_seconds_as_string(time_dur_arg, false); > char_type sep = std::use_facet<std::numpunct<char_type> >(ios_arg.getloc()).decimal_point(); > > string_type replace_string(seconds_format); > replace_string += sep; > replace_string += frac_str; > boost::algorithm::replace_all(format, > seconds_with_fractional_seconds_format, > replace_string); > } > if (format.find(fractional_seconds_format) != string_type::npos) { > > if (!frac_str.size()) { > frac_str = fractional_seconds_as_string(time_dur_arg, false); > } > boost::algorithm::replace_all(format, > fractional_seconds_format, > frac_str); > } > > if (format.find(fractional_seconds_or_none_format) != string_type::npos) { > > frac_str = > fractional_seconds_as_string(time_dur_arg, true); > if (frac_str.size()) { > char_type sep = std::use_facet<std::numpunct<char_type> >(ios_arg.getloc()).decimal_point(); > string_type replace_string; > replace_string += sep; > replace_string += frac_str; > boost::algorithm::replace_all(format, > fractional_seconds_or_none_format, > replace_string); > } > else { > boost::algorithm::erase_all(format, > fractional_seconds_or_none_format); > } > } > > return this->do_put_tm(next_arg, ios_arg, fill_arg, > to_tm(time_dur_arg), format); > } > > OutItrT put(OutItrT next, std::ios_base& ios_arg, > char_type fill, const period_type& p) const > { > return this->m_period_formatter.put_period(next, ios_arg, fill,p,*this); > } > > > protected: > > static > string_type > fractional_seconds_as_string(const time_duration_type& time_arg, > bool null_when_zero) > { > typename time_duration_type::fractional_seconds_type frac_sec = > time_arg.fractional_seconds(); > > if (null_when_zero && (frac_sec == 0)) { > return string_type(); > } > > > return integral_as_string( > date_time::absolute_value(frac_sec), > time_duration_type::num_fractional_digits()); > } > > static > string_type > hours_as_string(const time_duration_type& time_arg, int width = 2) > { > return integral_as_string(date_time::absolute_value(time_arg.hours()), width); > } > > template< typename IntT > > static > string_type > integral_as_string(IntT val, int width = 2) > { > std::basic_ostringstream<char_type> ss; > ss.imbue(std::locale::classic()); > ss << std::setw(width) > << std::setfill(static_cast<char_type>('0')); > > > > > > ss << val; > > return ss.str(); > } > > private: > string_type m_time_duration_format; > > }; > > template <class time_type, class CharT, class OutItrT> > std::locale::id time_facet<time_type, CharT, OutItrT>::id; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::fractional_seconds_format = time_formats<CharT>::fractional_seconds_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::fractional_seconds_or_none_format = time_formats<CharT>::fractional_seconds_or_none_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::seconds_with_fractional_seconds_format = > time_formats<CharT>::seconds_with_fractional_seconds_format; > > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::zone_name_format = time_formats<CharT>::zone_name_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::zone_abbrev_format = time_formats<CharT>::zone_abbrev_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::zone_iso_extended_format =time_formats<CharT>::zone_iso_extended_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::posix_zone_string_format =time_formats<CharT>::posix_zone_string_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::zone_iso_format = time_formats<CharT>::zone_iso_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::seconds_format = time_formats<CharT>::seconds_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::hours_format = time_formats<CharT>::hours_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::unrestricted_hours_format = time_formats<CharT>::unrestricted_hours_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::standard_format = time_formats<CharT>::standard_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::duration_seperator = time_formats<CharT>::duration_seperator; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::negative_sign = time_formats<CharT>::negative_sign; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::positive_sign = time_formats<CharT>::positive_sign; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::duration_sign_negative_only = time_formats<CharT>::duration_sign_negative_only; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::duration_sign_always = time_formats<CharT>::duration_sign_always; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type,CharT, OutItrT>::char_type* > time_facet<time_type,CharT, OutItrT>::iso_time_format_specifier = time_formats<CharT>::iso_time_format_specifier; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::iso_time_format_extended_specifier = time_formats<CharT>::iso_time_format_extended_specifier; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::default_time_format = > time_formats<CharT>::default_time_format; > > template <class time_type, class CharT, class OutItrT> > const typename time_facet<time_type, CharT, OutItrT>::char_type* > time_facet<time_type, CharT, OutItrT>::default_time_duration_format = > time_formats<CharT>::default_time_duration_format; > > > > > > template <class time_type, > class CharT, > class InItrT = std::istreambuf_iterator<CharT, std::char_traits<CharT> > > > class time_input_facet : > public boost::date_time::date_input_facet<typename time_type::date_type , CharT, InItrT> { > public: > typedef typename time_type::date_type date_type; > typedef typename time_type::time_duration_type time_duration_type; > typedef typename time_duration_type::fractional_seconds_type fracional_seconds_type; > typedef boost::date_time::period<time_type,time_duration_type> period_type; > typedef boost::date_time::date_input_facet<typename time_type::date_type, CharT, InItrT> base_type; > typedef typename base_type::duration_type date_duration_type; > typedef typename base_type::year_type year_type; > typedef typename base_type::month_type month_type; > typedef typename base_type::day_type day_type; > typedef typename base_type::string_type string_type; > typedef typename string_type::const_iterator const_itr; > typedef typename base_type::char_type char_type; > typedef typename base_type::format_date_parser_type format_date_parser_type; > typedef typename base_type::period_parser_type period_parser_type; > typedef typename base_type::special_values_parser_type special_values_parser_type; > typedef typename base_type::date_gen_parser_type date_gen_parser_type; > typedef typename base_type::special_values_parser_type::match_results match_results; > > static const char_type* fractional_seconds_format; > static const char_type* fractional_seconds_or_none_format; > static const char_type* seconds_with_fractional_seconds_format; > static const char_type* seconds_format; > static const char_type* standard_format; > static const char_type* zone_abbrev_format; > static const char_type* zone_name_format; > static const char_type* zone_iso_format; > static const char_type* zone_iso_extended_format; > static const char_type* duration_seperator; > static const char_type* iso_time_format_specifier; > static const char_type* iso_time_format_extended_specifier; > static const char_type* default_time_input_format; > static const char_type* default_time_duration_format; > static std::locale::id id; > > > explicit time_input_facet(const string_type& format, ::size_t ref_arg = 0) > : base_type(format, ref_arg), > m_time_duration_format(default_time_duration_format) > { } > > explicit time_input_facet(const string_type& format, > 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_arg = 0) > : base_type(format, > date_parser, > sv_parser, > per_parser, > date_gen_parser, > ref_arg), > m_time_duration_format(default_time_duration_format) > {} > > > explicit time_input_facet(::size_t ref_arg = 0) > : base_type(default_time_input_format, ref_arg), > m_time_duration_format(default_time_duration_format) > { } > > > void time_duration_format(const char_type* const format) { > m_time_duration_format = format; > } > virtual void set_iso_format() > { > this->m_format = iso_time_format_specifier; > } > virtual void set_iso_extended_format() > { > this->m_format = iso_time_format_extended_specifier; > } > > InItrT get(InItrT& sitr, > InItrT& stream_end, > std::ios_base& ios_arg, > period_type& p) const > { > p = this->m_period_parser.get_period(sitr, > stream_end, > ios_arg, > p, > time_duration_type::unit(), > *this); > return sitr; > } > > > > > InItrT get(InItrT& sitr, > InItrT& stream_end, > std::ios_base& ios_arg, > time_duration_type& td) const > { > > while((sitr != stream_end) && std::isspace(*sitr)) { ++sitr; } > > bool use_current_char = false; > > > char_type c = '\0'; > if((sitr != stream_end) && (*sitr == '-' || *sitr == '+')) { > c = *sitr; > } > > typedef typename time_duration_type::hour_type hour_type; > typedef typename time_duration_type::min_type min_type; > typedef typename time_duration_type::sec_type sec_type; > > hour_type hour = 0; > min_type min = 0; > sec_type sec = 0; > typename time_duration_type::fractional_seconds_type frac(0); > > typedef std::num_get<CharT, InItrT> num_get; > if(!std::has_facet<num_get>(ios_arg.getloc())) { > num_get* ng = new num_get(); > std::locale loc = std::locale(ios_arg.getloc(), ng); > ios_arg.imbue(loc); > } > > const_itr itr(m_time_duration_format.begin()); > while (itr != m_time_duration_format.end() && (sitr != stream_end)) { > if (*itr == '%') { > if (++itr == m_time_duration_format.end()) break; > if (*itr != '%') { > switch(*itr) { > case 'O': > { > > > hour = var_string_to_int<hour_type, CharT>(sitr, stream_end, > std::numeric_limits<hour_type>::digits10 + 1); > if(hour == -1){ > return check_special_value(sitr, stream_end, td, c); > } > break; > } > case 'H': > { > match_results mr; > hour = fixed_string_to_int<hour_type, CharT>(sitr, stream_end, mr, 2); > if(hour == -1){ > return check_special_value(sitr, stream_end, td, c); > } > break; > } > case 'M': > { > match_results mr; > min = fixed_string_to_int<min_type, CharT>(sitr, stream_end, mr, 2); > if(min == -1){ > return check_special_value(sitr, stream_end, td, c); > } > break; > } > case 's': > case 'S': > { > match_results mr; > sec = fixed_string_to_int<sec_type, CharT>(sitr, stream_end, mr, 2); > if(sec == -1){ > return check_special_value(sitr, stream_end, td, c); > } > if (*itr == 'S') > break; > > } > case 'f': > { > > if(*sitr == '.') { > ++sitr; > parse_frac_type(sitr, stream_end, frac); > > > use_current_char = true; > } > else { > return check_special_value(sitr, stream_end, td, c); > } > break; > } > case 'F': > { > > if(*sitr == '.') { > ++sitr; > parse_frac_type(sitr, stream_end, frac); > > > use_current_char = true; > } > else { > > use_current_char = true; > } > break; > } > default: > {} > } > } > else { > ++sitr; > } > > ++itr; > } > else { > ++itr; > > > if (use_current_char) { > use_current_char = false; > } > else { > ++sitr; > } > } > } > > td = time_duration_type(hour, min, sec, frac); > return sitr; > } > > > > InItrT get(InItrT& sitr, > InItrT& stream_end, > std::ios_base& ios_arg, > time_type& t) const > { > string_type tz_str; > return get(sitr, stream_end, ios_arg, t, tz_str, false); > } > > InItrT get_local_time(InItrT& sitr, > InItrT& stream_end, > std::ios_base& ios_arg, > time_type& t, > string_type& tz_str) const > { > return get(sitr, stream_end, ios_arg, t, tz_str, true); > } > > protected: > > InItrT get(InItrT& sitr, > InItrT& stream_end, > std::ios_base& ios_arg, > time_type& t, > string_type& tz_str, > bool time_is_local) const > { > > while((sitr != stream_end) && std::isspace(*sitr)) { ++sitr; } > > bool use_current_char = false; > bool use_current_format_char = false; > > > char_type c = '\0'; > if((sitr != stream_end) && (*sitr == '-' || *sitr == '+')) { > c = *sitr; > } > > typedef typename time_duration_type::hour_type hour_type; > typedef typename time_duration_type::min_type min_type; > typedef typename time_duration_type::sec_type sec_type; > > > hour_type hour = 0; > min_type min = 0; > sec_type sec = 0; > typename time_duration_type::fractional_seconds_type frac(0); > > short day_of_year(0); > > > > > year_type t_year(1400); > month_type t_month(1); > day_type t_day(1); > > typedef std::num_get<CharT, InItrT> num_get; > if(!std::has_facet<num_get>(ios_arg.getloc())) { > num_get* ng = new num_get(); > std::locale loc = std::locale(ios_arg.getloc(), ng); > ios_arg.imbue(loc); > } > > const_itr itr(this->m_format.begin()); > while (itr != this->m_format.end() && (sitr != stream_end)) { > if (*itr == '%') { > if (++itr == this->m_format.end()) break; > if (*itr != '%') { > > switch(*itr) { > > case 'Y': > case 'y': > { > char_type cs[3] = { '%', *itr }; > string_type s(cs); > match_results mr; > try { > t_year = this->m_parser.parse_year(sitr, stream_end, s, mr); > } > catch(std::out_of_range&) { > if(this->m_sv_parser.match(sitr, stream_end, mr)) { > t = time_type(static_cast<special_values>(mr.current_match)); > return sitr; > } > else { > throw; > } > } > break; > } > case 'B': > case 'b': > case 'm': > { > char_type cs[3] = { '%', *itr }; > string_type s(cs); > match_results mr; > try { > t_month = this->m_parser.parse_month(sitr, stream_end, s, mr); > } > catch(std::out_of_range&) { > if(this->m_sv_parser.match(sitr, stream_end, mr)) { > t = time_type(static_cast<special_values>(mr.current_match)); > return sitr; > } > else { > throw; > } > } > > if(mr.has_remaining()) { > use_current_char = true; > } > break; > } > case 'a': > case 'A': > case 'w': > { > > char_type cs[3] = { '%', *itr }; > string_type s(cs); > match_results mr; > typename date_type::day_of_week_type wd(0); > try { > wd = this->m_parser.parse_weekday(sitr, stream_end, s, mr); > } > catch(std::out_of_range&) { > if(this->m_sv_parser.match(sitr, stream_end, mr)) { > t = time_type(static_cast<special_values>(mr.current_match)); > return sitr; > } > else { > throw; > } > } > > if(mr.has_remaining()) { > use_current_char = true; > } > break; > } > case 'j': > { > > match_results mr; > day_of_year = fixed_string_to_int<unsigned short, CharT>(sitr, stream_end, mr, 3); > if(day_of_year == -1) { > if(this->m_sv_parser.match(sitr, stream_end, mr)) { > t = time_type(static_cast<special_values>(mr.current_match)); > return sitr; > } > } > > typedef typename time_type::date_type::day_of_year_type day_of_year_type; > day_of_year_type t_day_of_year(day_of_year); > break; > } > case 'd': > { > try { > t_day = this->m_parser.parse_day_of_month(sitr, stream_end); > } > catch(std::out_of_range&) { > match_results mr; > if(this->m_sv_parser.match(sitr, stream_end, mr)) { > t = time_type(static_cast<special_values>(mr.current_match)); > return sitr; > } > else { > throw; > } > } > break; > } > > case 'H': > { > match_results mr; > hour = fixed_string_to_int<hour_type, CharT>(sitr, stream_end, mr, 2); > if(hour == -1){ > return check_special_value(sitr, stream_end, t, c); > } > break; > } > case 'M': > { > match_results mr; > min = fixed_string_to_int<min_type, CharT>(sitr, stream_end, mr, 2); > if(min == -1){ > return check_special_value(sitr, stream_end, t, c); > } > break; > } > case 's': > case 'S': > { > match_results mr; > sec = fixed_string_to_int<sec_type, CharT>(sitr, stream_end, mr, 2); > if(sec == -1){ > return check_special_value(sitr, stream_end, t, c); > } > if (*itr == 'S') > break; > > } > case 'f': > { > > if(*sitr == '.') { > ++sitr; > parse_frac_type(sitr, stream_end, frac); > > > use_current_char = true; > } > else { > return check_special_value(sitr, stream_end, t, c); > } > break; > } > case 'F': > { > > if(*sitr == '.') { > ++sitr; > parse_frac_type(sitr, stream_end, frac); > > > use_current_char = true; > } > else { > > use_current_char = true; > } > break; > } > > > > > case 'Z': > { > if(time_is_local) { > ++itr; > if(*itr == 'P') { > > while((sitr != stream_end) && std::isspace(*sitr)) { ++sitr; } > > while((sitr != stream_end) && (!std::isspace(*sitr))) { > tz_str += *sitr; > ++sitr; > } > } > else { > use_current_format_char = true; > } > > } > else { > > use_current_char = true; > } > > break; > } > default: > {} > } > } > else { > ++sitr; > } > > if(use_current_format_char) { > use_current_format_char = false; > } > else { > ++itr; > } > > } > else { > ++itr; > > > if (use_current_char) { > use_current_char = false; > } > else { > ++sitr; > } > } > } > > date_type d(not_a_date_time); > if (day_of_year > 0) { > d = date_type(static_cast<unsigned short>(t_year-1),12,31) + date_duration_type(day_of_year); > } > else { > d = date_type(t_year, t_month, t_day); > } > > time_duration_type td(hour, min, sec, frac); > t = time_type(d, td); > return sitr; > } > > > > > > template<class temporal_type> > inline > InItrT check_special_value(InItrT& sitr,InItrT& stream_end, temporal_type& tt, char_type c='\0') const > { > match_results mr; > if((c == '-' || c == '+') && (*sitr != c)) { > mr.cache += c; > } > this->m_sv_parser.match(sitr, stream_end, mr); > if(mr.current_match == match_results::PARSE_ERROR) { > std::string tmp = convert_string_type<char_type, char>(mr.cache); > boost::throw_exception(std::ios_base::failure("Parse failed. No match found for '" + tmp + "'")); > std::abort(); > } > tt = temporal_type(static_cast<special_values>(mr.current_match)); > return sitr; > } > > > void parse_frac_type(InItrT& sitr, > InItrT& stream_end, > fracional_seconds_type& frac) const > { > string_type cache; > while((sitr != stream_end) && std::isdigit(*sitr)) { > cache += *sitr; > ++sitr; > } > if(cache.size() > 0) { > unsigned short precision = time_duration_type::num_fractional_digits(); > > if(cache.size() < precision) { > frac = lexical_cast<fracional_seconds_type>(cache); > frac = decimal_adjust(frac, static_cast<unsigned short>(precision - cache.size())); > } > else { > > frac = lexical_cast<fracional_seconds_type>(cache.substr(0, precision)); > } > } > } > > private: > string_type m_time_duration_format; > > > template<class int_type> > inline > int_type decimal_adjust(int_type val, const unsigned short places) const > { > unsigned long factor = 1; > for(int i = 0; i < places; ++i){ > factor *= 10; > } > return val * factor; > } > > }; > >template <class time_type, class CharT, class InItrT> > std::locale::id time_input_facet<time_type, CharT, InItrT>::id; > >template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::fractional_seconds_format = time_formats<CharT>::fractional_seconds_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::fractional_seconds_or_none_format = time_formats<CharT>::fractional_seconds_or_none_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::seconds_with_fractional_seconds_format = time_formats<CharT>::seconds_with_fractional_seconds_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::seconds_format = time_formats<CharT>::seconds_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::standard_format = time_formats<CharT>::standard_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::zone_abbrev_format = time_formats<CharT>::zone_abbrev_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::zone_name_format = time_formats<CharT>::zone_name_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::zone_iso_format = time_formats<CharT>::zone_iso_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::zone_iso_extended_format = time_formats<CharT>::zone_iso_extended_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::duration_seperator = time_formats<CharT>::duration_seperator; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::iso_time_format_specifier = time_formats<CharT>::iso_time_format_specifier; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::iso_time_format_extended_specifier = time_formats<CharT>::iso_time_format_extended_specifier; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::default_time_input_format = time_formats<CharT>::default_time_input_format; > > template <class time_type, class CharT, class InItrT> > const typename time_input_facet<time_type, CharT, InItrT>::char_type* > time_input_facet<time_type, CharT, InItrT>::default_time_duration_format = time_formats<CharT>::default_time_duration_format; > > >} } ># 17 "/usr/include/boost/date_time/posix_time/posix_time_io.hpp" 2 3 4 > > > > > > >namespace boost { >namespace posix_time { ># 37 "/usr/include/boost/date_time/posix_time/posix_time_io.hpp" 3 4 > typedef boost::date_time::time_facet<ptime, wchar_t> wtime_facet; > typedef boost::date_time::time_facet<ptime, char> time_facet; > > typedef boost::date_time::time_input_facet<ptime, wchar_t> wtime_input_facet; > typedef boost::date_time::time_input_facet<ptime, char> time_input_facet; > > template <class CharT, class TraitsT> > inline > std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, > const ptime& p) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::time_facet<ptime, CharT> custom_ptime_facet; > typedef std::time_put<CharT> std_ptime_facet; > std::ostreambuf_iterator<CharT> oitr(os); > if (std::has_facet<custom_ptime_facet>(os.getloc())) > std::use_facet<custom_ptime_facet>(os.getloc()).put(oitr, os, os.fill(), p); > else { > > > > > > custom_ptime_facet* f = new custom_ptime_facet(); > std::locale l = std::locale(os.getloc(), f); > os.imbue(l); > f->put(oitr, os, os.fill(), p); > } > return os; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, ptime& pt) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::time_input_facet<ptime, CharT> time_input_facet; > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<time_input_facet>(is.getloc())) { > std::use_facet<time_input_facet>(is.getloc()).get(sit, str_end, is, pt); > } > else { > time_input_facet* f = new time_input_facet(); > std::locale l = std::locale(is.getloc(), f); > is.imbue(l); > f->get(sit, str_end, is, pt); > } > } > 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; > } > else { > > is.setstate(std::ios_base::failbit); > } > } > } > return is; > } > > > template <class CharT, class TraitsT> > inline > std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, > const boost::posix_time::time_period& p) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::time_facet<ptime, CharT> custom_ptime_facet; > typedef std::time_put<CharT> std_time_facet; > std::ostreambuf_iterator<CharT> oitr(os); > if (std::has_facet<custom_ptime_facet>(os.getloc())) { > std::use_facet<custom_ptime_facet>(os.getloc()).put(oitr, os, os.fill(), p); > } > else { > > > > > > custom_ptime_facet* f = new custom_ptime_facet(); > std::locale l = std::locale(os.getloc(), f); > os.imbue(l); > f->put(oitr, os, os.fill(), p); > } > return os; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, time_period& tp) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::time_input_facet<ptime, CharT> time_input_facet; > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<time_input_facet>(is.getloc())) { > std::use_facet<time_input_facet>(is.getloc()).get(sit, str_end, is, tp); > } > else { > time_input_facet* f = new time_input_facet(); > std::locale l = std::locale(is.getloc(), f); > is.imbue(l); > f->get(sit, str_end, is, tp); > } > } > 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; > } > else { > is.setstate(std::ios_base::failbit); > } > } > } > return is; > } > > > > > template <class CharT, class Traits> > inline > std::basic_ostream<CharT, Traits>& > operator<<(std::basic_ostream<CharT, Traits>& os, const time_duration& td) > { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::time_facet<ptime, CharT> custom_ptime_facet; > typedef std::time_put<CharT> std_ptime_facet; > std::ostreambuf_iterator<CharT> oitr(os); > if (std::has_facet<custom_ptime_facet>(os.getloc())) > std::use_facet<custom_ptime_facet>(os.getloc()).put(oitr, os, os.fill(), td); > else { > > > > > > custom_ptime_facet* f = new custom_ptime_facet(); > std::locale l = std::locale(os.getloc(), f); > os.imbue(l); > f->put(oitr, os, os.fill(), td); > } > return os; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, time_duration& td) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::time_input_facet<ptime, CharT> time_input_facet; > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<time_input_facet>(is.getloc())) { > std::use_facet<time_input_facet>(is.getloc()).get(sit, str_end, is, td); > } > else { > time_input_facet* f = new time_input_facet(); > std::locale l = std::locale(is.getloc(), f); > is.imbue(l); > f->get(sit, str_end, is, td); > } > } > 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; > } > else { > is.setstate(std::ios_base::failbit); > } > } > } > return is; > } > >} } ># 32 "/usr/include/boost/date_time/posix_time/posix_time.hpp" 2 3 4 > > ># 1 "/usr/include/boost/date_time/posix_time/time_parsers.hpp" 1 3 4 ># 17 "/usr/include/boost/date_time/posix_time/time_parsers.hpp" 3 4 >namespace boost { > >namespace posix_time { > > > > > > > inline time_duration duration_from_string(const std::string& s) { > return date_time::parse_delimited_time_duration<time_duration>(s); > } > > inline ptime time_from_string(const std::string& s) { > return date_time::parse_delimited_time<ptime>(s, ' '); > } > > inline ptime from_iso_string(const std::string& s) { > return date_time::parse_iso_time<ptime>(s, 'T'); > } > > > >} } ># 35 "/usr/include/boost/date_time/posix_time/posix_time.hpp" 2 3 4 ># 34 "/c/honeypenny/contrib/epee/include/time_helper.h" 2 ># 1 "/usr/include/boost/date_time/local_time/local_time.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/local_time/local_time.hpp" 3 4 ># 1 "/usr/include/boost/date_time/local_time/local_date_time.hpp" 1 3 4 ># 20 "/usr/include/boost/date_time/local_time/local_date_time.hpp" 3 4 ># 1 "/usr/include/boost/date_time/time_zone_base.hpp" 1 3 4 ># 15 "/usr/include/boost/date_time/time_zone_base.hpp" 3 4 >namespace boost { >namespace date_time { ># 33 "/usr/include/boost/date_time/time_zone_base.hpp" 3 4 > template<typename time_type, typename CharT> > class time_zone_base { > public: > typedef CharT char_type; > typedef std::basic_string<CharT> string_type; > typedef std::basic_ostringstream<CharT> stringstream_type; > typedef typename time_type::date_type::year_type year_type; > typedef typename time_type::time_duration_type time_duration_type; > > time_zone_base() {} > virtual ~time_zone_base() {} > > virtual string_type dst_zone_abbrev() const=0; > > virtual string_type std_zone_abbrev() const=0; > > virtual string_type dst_zone_name() const=0; > > virtual string_type std_zone_name() const=0; > > virtual bool has_dst() const=0; > > virtual time_type dst_local_start_time(year_type y) const=0; > > virtual time_type dst_local_end_time(year_type y) const=0; > > virtual time_duration_type base_utc_offset() const=0; > > virtual time_duration_type dst_offset() const=0; > > virtual string_type to_posix_string() const =0; > > private: > > }; > > > > > > > template<class time_duration_type> > class dst_adjustment_offsets > { > public: > dst_adjustment_offsets(const time_duration_type& dst_adjust, > const time_duration_type& dst_start_offset, > const time_duration_type& dst_end_offset) : > dst_adjust_(dst_adjust), > dst_start_offset_(dst_start_offset), > dst_end_offset_(dst_end_offset) > {} > > > time_duration_type dst_adjust_; > > time_duration_type dst_start_offset_; > > time_duration_type dst_end_offset_; > }; > > >} } ># 21 "/usr/include/boost/date_time/local_time/local_date_time.hpp" 2 3 4 > > > >namespace boost { >namespace local_time { > > > struct ambiguous_result : public std::logic_error > { > ambiguous_result (std::string const& msg = std::string()) : > std::logic_error(std::string("Daylight Savings Results are ambiguous: " + msg)) {} > }; > > struct time_label_invalid : public std::logic_error > { > time_label_invalid (std::string const& msg = std::string()) : > std::logic_error(std::string("Time label given is invalid: " + msg)) {} > }; > struct dst_not_valid: public std::logic_error > { > dst_not_valid(std::string const& msg = std::string()) : > std::logic_error(std::string("is_dst flag does not match resulting dst for time label given: " + msg)) {} > }; > > > > using date_time::time_is_dst_result; > using date_time::is_in_dst; > using date_time::is_not_in_dst; > using date_time::ambiguous; > using date_time::invalid_time_label; ># 62 "/usr/include/boost/date_time/local_time/local_date_time.hpp" 3 4 > template<class utc_time_=posix_time::ptime, > class tz_type=date_time::time_zone_base<utc_time_,char> > > class local_date_time_base : public date_time::base_time<utc_time_, > boost::posix_time::posix_time_system> { > public: > typedef utc_time_ utc_time_type; > typedef typename utc_time_type::time_duration_type time_duration_type; > typedef typename utc_time_type::date_type date_type; > typedef typename date_type::duration_type date_duration_type; > typedef typename utc_time_type::time_system_type time_system_type; ># 81 "/usr/include/boost/date_time/local_time/local_date_time.hpp" 3 4 > local_date_time_base(utc_time_type t, > boost::shared_ptr<tz_type> tz) : > date_time::base_time<utc_time_type, time_system_type>(t), > zone_(tz) > { > > } ># 100 "/usr/include/boost/date_time/local_time/local_date_time.hpp" 3 4 > local_date_time_base(date_type d, > time_duration_type td, > boost::shared_ptr<tz_type> tz, > bool dst_flag) : > date_time::base_time<utc_time_type,time_system_type>(construction_adjustment(utc_time_type(d, td), tz, dst_flag)), > zone_(tz) > { > if(tz != boost::shared_ptr<tz_type>() && tz->has_dst()){ > > > time_is_dst_result result = check_dst(d, td, tz); > bool in_dst = (result == is_in_dst); > > > if(result == invalid_time_label){ > > std::ostringstream ss; > ss << "time given: " << d << ' ' << td; > boost::throw_exception(time_label_invalid(ss.str())); > } > else if(result != ambiguous && in_dst != dst_flag){ > > > std::ostringstream ss; > ss.setf(std::ios_base::boolalpha); > ss << "flag given: dst=" << dst_flag << ", dst calculated: dst=" << in_dst; > boost::throw_exception(dst_not_valid(ss.str())); > } > > > } > } > > > enum DST_CALC_OPTIONS { EXCEPTION_ON_ERROR, NOT_DATE_TIME_ON_ERROR }; > > > > > > > local_date_time_base(date_type d, > time_duration_type td, > boost::shared_ptr<tz_type> tz, > DST_CALC_OPTIONS calc_option) : > > date_time::base_time<utc_time_type,time_system_type>(utc_time_type(d,td)), > zone_(tz) > { > time_is_dst_result result = check_dst(d, td, tz); > if(result == ambiguous) { > if(calc_option == EXCEPTION_ON_ERROR){ > std::ostringstream ss; > ss << "time given: " << d << ' ' << td; > boost::throw_exception(ambiguous_result(ss.str())); > } > else{ > this->time_ = posix_time::posix_time_system::get_time_rep(date_type(date_time::not_a_date_time), time_duration_type(date_time::not_a_date_time)); > } > } > else if(result == invalid_time_label){ > if(calc_option == EXCEPTION_ON_ERROR){ > std::ostringstream ss; > ss << "time given: " << d << ' ' << td; > boost::throw_exception(time_label_invalid(ss.str())); > } > else{ > this->time_ = posix_time::posix_time_system::get_time_rep(date_type(date_time::not_a_date_time), time_duration_type(date_time::not_a_date_time)); > } > } > else if(result == is_in_dst){ > utc_time_type t = > construction_adjustment(utc_time_type(d, td), tz, true); > this->time_ = posix_time::posix_time_system::get_time_rep(t.date(), > t.time_of_day()); > } > else{ > utc_time_type t = > construction_adjustment(utc_time_type(d, td), tz, false); > this->time_ = posix_time::posix_time_system::get_time_rep(t.date(), > t.time_of_day()); > } > } > > > > > > > > static time_is_dst_result check_dst(date_type d, > time_duration_type td, > boost::shared_ptr<tz_type> tz) > { > if(tz != boost::shared_ptr<tz_type>() && tz->has_dst()) { > typedef typename date_time::dst_calculator<date_type, time_duration_type> dst_calculator; > return dst_calculator::local_is_dst( > d, td, > tz->dst_local_start_time(d.year()).date(), > tz->dst_local_start_time(d.year()).time_of_day(), > tz->dst_local_end_time(d.year()).date(), > tz->dst_local_end_time(d.year()).time_of_day(), > tz->dst_offset() > ); > } > else{ > return is_not_in_dst; > } > } > > > ~local_date_time_base() {} > > > local_date_time_base(const local_date_time_base& rhs) : > date_time::base_time<utc_time_type, time_system_type>(rhs), > zone_(rhs.zone_) > {} > > > explicit local_date_time_base(const boost::date_time::special_values sv, > boost::shared_ptr<tz_type> tz = boost::shared_ptr<tz_type>()) : > date_time::base_time<utc_time_type, time_system_type>(utc_time_type(sv)), > zone_(tz) > {} > > > boost::shared_ptr<tz_type> zone() const > { > return zone_; > } > > bool is_dst() const > { > if(zone_ != boost::shared_ptr<tz_type>() && zone_->has_dst() && !this->is_special()) { > > utc_time_type lt(this->time_); > lt += zone_->base_utc_offset(); > > > > switch(check_dst(lt.date(), lt.time_of_day(), zone_)){ > case is_not_in_dst: > return false; > case is_in_dst: > return true; > case ambiguous: > if(lt + zone_->dst_offset() < zone_->dst_local_end_time(lt.date().year())) { > return true; > } > break; > case invalid_time_label: > if(lt >= zone_->dst_local_start_time(lt.date().year())) { > return true; > } > break; > } > } > return false; > } > > utc_time_type utc_time() const > { > return utc_time_type(this->time_); > } > > utc_time_type local_time() const > { > if(zone_ != boost::shared_ptr<tz_type>()){ > utc_time_type lt = this->utc_time() + zone_->base_utc_offset(); > if (is_dst()) { > lt += zone_->dst_offset(); > } > return lt; > } > return utc_time_type(this->time_); > } > > > > > std::string to_string() const > { > > std::ostringstream ss; > if(this->is_special()){ > ss << utc_time(); > return ss.str(); > } > if(zone_ == boost::shared_ptr<tz_type>()) { > ss << utc_time() << " UTC"; > return ss.str(); > } > bool is_dst_ = is_dst(); > utc_time_type lt = this->utc_time() + zone_->base_utc_offset(); > if (is_dst_) { > lt += zone_->dst_offset(); > } > ss << local_time() << " "; > if (is_dst()) { > ss << zone_->dst_zone_abbrev(); > } > else { > ss << zone_->std_zone_abbrev(); > } > return ss.str(); > } > > > local_date_time_base local_time_in(boost::shared_ptr<tz_type> new_tz, > time_duration_type td=time_duration_type(0,0,0)) const > { > return local_date_time_base(utc_time_type(this->time_) + td, new_tz); > } > > > > > > std::string zone_name(bool as_offset=false) const > { > if(zone_ == boost::shared_ptr<tz_type>()) { > if(as_offset) { > return std::string("Z"); > } > else { > return std::string("Coordinated Universal Time"); > } > } > if (is_dst()) { > if(as_offset) { > time_duration_type td = zone_->base_utc_offset(); > td += zone_->dst_offset(); > return zone_as_offset(td, ":"); > } > else { > return zone_->dst_zone_name(); > } > } > else { > if(as_offset) { > time_duration_type td = zone_->base_utc_offset(); > return zone_as_offset(td, ":"); > } > else { > return zone_->std_zone_name(); > } > } > } > > > > > std::string zone_abbrev(bool as_offset=false) const > { > if(zone_ == boost::shared_ptr<tz_type>()) { > if(as_offset) { > return std::string("Z"); > } > else { > return std::string("UTC"); > } > } > if (is_dst()) { > if(as_offset) { > time_duration_type td = zone_->base_utc_offset(); > td += zone_->dst_offset(); > return zone_as_offset(td, ""); > } > else { > return zone_->dst_zone_abbrev(); > } > } > else { > if(as_offset) { > time_duration_type td = zone_->base_utc_offset(); > return zone_as_offset(td, ""); > } > else { > return zone_->std_zone_abbrev(); > } > } > } > > > std::string zone_as_posix_string() const > { > if(zone_ == shared_ptr<tz_type>()) { > return std::string("UTC+00"); > } > return zone_->to_posix_string(); > } ># 400 "/usr/include/boost/date_time/local_time/local_date_time.hpp" 3 4 > bool operator==(const local_date_time_base& rhs) const > { > return time_system_type::is_equal(this->time_, rhs.time_); > } > > bool operator!=(const local_date_time_base& rhs) const > { > return !(*this == rhs); > } > > bool operator<(const local_date_time_base& rhs) const > { > return time_system_type::is_less(this->time_, rhs.time_); > } > > bool operator<=(const local_date_time_base& rhs) const > { > return (*this < rhs || *this == rhs); > } > > bool operator>(const local_date_time_base& rhs) const > { > return !(*this <= rhs); > } > > bool operator>=(const local_date_time_base& rhs) const > { > return (*this > rhs || *this == rhs); > } > > > local_date_time_base operator+(const date_duration_type& dd) const > { > return local_date_time_base(time_system_type::add_days(this->time_,dd), zone_); > } > > local_date_time_base operator+=(const date_duration_type& dd) > { > this->time_ = time_system_type::add_days(this->time_,dd); > return *this; > } > > local_date_time_base operator-(const date_duration_type& dd) const > { > return local_date_time_base(time_system_type::subtract_days(this->time_,dd), zone_); > } > > local_date_time_base operator-=(const date_duration_type& dd) > { > this->time_ = time_system_type::subtract_days(this->time_,dd); > return *this; > } > > local_date_time_base operator+(const time_duration_type& td) const > { > return local_date_time_base(time_system_type::add_time_duration(this->time_,td), zone_); > } > > local_date_time_base operator+=(const time_duration_type& td) > { > this->time_ = time_system_type::add_time_duration(this->time_,td); > return *this; > } > > local_date_time_base operator-(const time_duration_type& td) const > { > return local_date_time_base(time_system_type::subtract_time_duration(this->time_,td), zone_); > } > > local_date_time_base operator-=(const time_duration_type& td) > { > this->time_ = time_system_type::subtract_time_duration(this->time_,td); > return *this; > } > > time_duration_type operator-(const local_date_time_base& rhs) const > { > return utc_time_type(this->time_) - utc_time_type(rhs.time_); > } > private: > boost::shared_ptr<tz_type> zone_; > > > > > utc_time_type construction_adjustment(utc_time_type t, > boost::shared_ptr<tz_type> z, > bool dst_flag) > { > if(z != boost::shared_ptr<tz_type>()) { > if(dst_flag && z->has_dst()) { > t -= z->dst_offset(); > } > t -= z->base_utc_offset(); > } > return t; > } > > > > std::string zone_as_offset(const time_duration_type& td, > const std::string& separator) const > { > std::ostringstream ss; > if(td.is_negative()) { > > > > ss << "-"; > } > else { > ss << "+"; > } > ss << std::setw(2) << std::setfill('0') > << date_time::absolute_value(td.hours()) > << separator > << std::setw(2) << std::setfill('0') > << date_time::absolute_value(td.minutes()); > return ss.str(); > } > }; > > > typedef local_date_time_base<> local_date_time; > >} } ># 13 "/usr/include/boost/date_time/local_time/local_time.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/local_time/local_time_types.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/local_time/local_time_types.hpp" 3 4 ># 1 "/usr/include/boost/date_time/local_time/date_duration_operators.hpp" 1 3 4 ># 15 "/usr/include/boost/date_time/local_time/date_duration_operators.hpp" 3 4 >namespace boost { >namespace local_time { ># 29 "/usr/include/boost/date_time/local_time/date_duration_operators.hpp" 3 4 > inline > local_date_time > operator+(const local_date_time& t, const boost::gregorian::months& m) > { > return t + m.get_offset(t.utc_time().date()); > } > > > > > inline > local_date_time > operator+=(local_date_time& t, const boost::gregorian::months& m) > { > return t += m.get_offset(t.utc_time().date()); > } > > > > > inline > local_date_time > operator-(const local_date_time& t, const boost::gregorian::months& m) > { > > return t + m.get_neg_offset(t.utc_time().date()); > } > > > > > inline > local_date_time > operator-=(local_date_time& t, const boost::gregorian::months& m) > { > > return t += m.get_neg_offset(t.utc_time().date()); > } > > > > > > > inline > local_date_time > operator+(const local_date_time& t, const boost::gregorian::years& y) > { > return t + y.get_offset(t.utc_time().date()); > } > > > > > inline > local_date_time > operator+=(local_date_time& t, const boost::gregorian::years& y) > { > return t += y.get_offset(t.utc_time().date()); > } > > > > > inline > local_date_time > operator-(const local_date_time& t, const boost::gregorian::years& y) > { > > return t + y.get_neg_offset(t.utc_time().date()); > } > > > > > inline > local_date_time > operator-=(local_date_time& t, const boost::gregorian::years& y) > { > > return t += y.get_neg_offset(t.utc_time().date()); > } > > >}} ># 17 "/usr/include/boost/date_time/local_time/local_time_types.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/local_time/custom_time_zone.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/local_time/custom_time_zone.hpp" 3 4 ># 1 "/usr/include/boost/date_time/time_zone_names.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/time_zone_names.hpp" 3 4 >namespace boost { >namespace date_time { > > template<class CharT> > struct default_zone_names { > public: > typedef CharT char_type; > static const char_type standard_name[9]; > static const char_type standard_abbrev[11]; > static const char_type non_dst_identifier[7]; > }; > template <class CharT> > const typename default_zone_names<CharT>::char_type > default_zone_names<CharT>::standard_name[9] = > {'s','t','d','_','n','a','m','e'}; > > template <class CharT> > const typename default_zone_names<CharT>::char_type > default_zone_names<CharT>::standard_abbrev[11] = > {'s','t','d','_','a','b','b','r','e','v'}; > > template <class CharT> > const typename default_zone_names<CharT>::char_type > default_zone_names<CharT>::non_dst_identifier[7] = > {'n','o','-','d','s','t'}; ># 48 "/usr/include/boost/date_time/time_zone_names.hpp" 3 4 > template<class CharT> > class time_zone_names_base > { > public: > typedef std::basic_string<CharT> string_type; > time_zone_names_base() : > std_zone_name_(default_zone_names<CharT>::standard_name), > std_zone_abbrev_(default_zone_names<CharT>::standard_abbrev), > dst_zone_name_(default_zone_names<CharT>::non_dst_identifier), > dst_zone_abbrev_(default_zone_names<CharT>::non_dst_identifier) > {} > time_zone_names_base(const string_type& std_zone_name_str, > const string_type& std_zone_abbrev_str, > const string_type& dst_zone_name_str, > const string_type& dst_zone_abbrev_str) : > std_zone_name_(std_zone_name_str), > std_zone_abbrev_(std_zone_abbrev_str), > dst_zone_name_(dst_zone_name_str), > dst_zone_abbrev_(dst_zone_abbrev_str) > {} > string_type dst_zone_abbrev() const > { > return dst_zone_abbrev_; > } > string_type std_zone_abbrev() const > { > return std_zone_abbrev_; > } > string_type dst_zone_name() const > { > return dst_zone_name_; > } > string_type std_zone_name() const > { > return std_zone_name_; > } > private: > string_type std_zone_name_; > string_type std_zone_abbrev_; > string_type dst_zone_name_; > string_type dst_zone_abbrev_; > > }; > > > > >} } ># 13 "/usr/include/boost/date_time/local_time/custom_time_zone.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/local_time/dst_transition_day_rules.hpp" 1 3 4 ># 13 "/usr/include/boost/date_time/local_time/dst_transition_day_rules.hpp" 3 4 ># 1 "/usr/include/boost/date_time/dst_transition_generators.hpp" 1 3 4 ># 12 "/usr/include/boost/date_time/dst_transition_generators.hpp" 3 4 >namespace boost { >namespace date_time { > > > template<class date_type> > class dst_day_calc_rule > { > public: > typedef typename date_type::year_type year_type; > virtual ~dst_day_calc_rule() {} > virtual date_type start_day(year_type y) const=0; > virtual std::string start_rule_as_string() const=0; > virtual date_type end_day(year_type y) const=0; > virtual std::string end_rule_as_string() const=0; > > }; ># 36 "/usr/include/boost/date_time/dst_transition_generators.hpp" 3 4 > template<class spec> > class day_calc_dst_rule : public dst_day_calc_rule<typename spec::date_type> > { > public: > typedef typename spec::date_type date_type; > typedef typename date_type::year_type year_type; > typedef typename spec::start_rule start_rule; > typedef typename spec::end_rule end_rule; > day_calc_dst_rule(start_rule dst_start, > end_rule dst_end) : > dst_start_(dst_start), > dst_end_(dst_end) > {} > virtual date_type start_day(year_type y) const > { > return dst_start_.get_date(y); > } > virtual std::string start_rule_as_string() const > { > return dst_start_.to_string(); > } > virtual date_type end_day(year_type y) const > { > return dst_end_.get_date(y); > } > virtual std::string end_rule_as_string() const > { > return dst_end_.to_string(); > } > private: > start_rule dst_start_; > end_rule dst_end_; > }; > > >} } ># 14 "/usr/include/boost/date_time/local_time/dst_transition_day_rules.hpp" 2 3 4 > >namespace boost { >namespace local_time { > > > typedef date_time::dst_day_calc_rule<gregorian::date> dst_calc_rule; > > struct partial_date_rule_spec > { > typedef gregorian::date date_type; > typedef gregorian::partial_date start_rule; > typedef gregorian::partial_date end_rule; > }; > > > typedef date_time::day_calc_dst_rule<partial_date_rule_spec> partial_date_dst_rule; > > struct first_last_rule_spec > { > typedef gregorian::date date_type; > typedef gregorian::first_kday_of_month start_rule; > typedef gregorian::last_kday_of_month end_rule; > }; > > > typedef date_time::day_calc_dst_rule<first_last_rule_spec> first_last_dst_rule; > > struct last_last_rule_spec > { > typedef gregorian::date date_type; > typedef gregorian::last_kday_of_month start_rule; > typedef gregorian::last_kday_of_month end_rule; > }; > > > typedef date_time::day_calc_dst_rule<last_last_rule_spec> last_last_dst_rule; > > struct nth_last_rule_spec > { > typedef gregorian::date date_type; > typedef gregorian::nth_kday_of_month start_rule; > typedef gregorian::last_kday_of_month end_rule; > }; > > > typedef date_time::day_calc_dst_rule<nth_last_rule_spec> nth_last_dst_rule; > > struct nth_kday_rule_spec > { > typedef gregorian::date date_type; > typedef gregorian::nth_kday_of_month start_rule; > typedef gregorian::nth_kday_of_month end_rule; > }; > > > typedef date_time::day_calc_dst_rule<nth_kday_rule_spec> nth_kday_dst_rule; > > typedef date_time::day_calc_dst_rule<nth_kday_rule_spec> nth_day_of_the_week_in_month_dst_rule; > > >} } ># 15 "/usr/include/boost/date_time/local_time/custom_time_zone.hpp" 2 3 4 > > > > >namespace boost { >namespace local_time { > > > typedef boost::date_time::dst_adjustment_offsets<boost::posix_time::time_duration> dst_adjustment_offsets; > > typedef boost::shared_ptr<dst_calc_rule> dst_calc_rule_ptr; > > > template<class CharT> > class custom_time_zone_base : public date_time::time_zone_base<posix_time::ptime,CharT> { > public: > typedef boost::posix_time::time_duration time_duration_type; > typedef date_time::time_zone_base<posix_time::ptime,CharT> base_type; > typedef typename base_type::string_type string_type; > typedef typename base_type::stringstream_type stringstream_type; > typedef date_time::time_zone_names_base<CharT> time_zone_names; > typedef CharT char_type; > > custom_time_zone_base(const time_zone_names& zone_names, > const time_duration_type& utc_offset, > const dst_adjustment_offsets& dst_shift, > boost::shared_ptr<dst_calc_rule> calc_rule) : > zone_names_(zone_names), > base_utc_offset_(utc_offset), > dst_offsets_(dst_shift), > dst_calc_rules_(calc_rule) > {} > virtual ~custom_time_zone_base() {} > virtual string_type dst_zone_abbrev() const > { > return zone_names_.dst_zone_abbrev(); > } > virtual string_type std_zone_abbrev() const > { > return zone_names_.std_zone_abbrev(); > } > virtual string_type dst_zone_name() const > { > return zone_names_.dst_zone_name(); > } > virtual string_type std_zone_name() const > { > return zone_names_.std_zone_name(); > } > > virtual bool has_dst() const > { > return (bool) dst_calc_rules_; > } > > virtual posix_time::ptime dst_local_start_time(gregorian::greg_year y) const > { > gregorian::date d(gregorian::not_a_date_time); > if (dst_calc_rules_) { > d = dst_calc_rules_->start_day(y); > } > return posix_time::ptime(d, dst_offsets_.dst_start_offset_); > } > > virtual posix_time::ptime dst_local_end_time(gregorian::greg_year y) const > { > gregorian::date d(gregorian::not_a_date_time); > if (dst_calc_rules_) { > d = dst_calc_rules_->end_day(y); > } > return posix_time::ptime(d, dst_offsets_.dst_end_offset_); > } > > virtual time_duration_type base_utc_offset() const > { > return base_utc_offset_; > } > > virtual time_duration_type dst_offset() const > { > return dst_offsets_.dst_adjust_; > } > > virtual string_type to_posix_string() const > { > > stringstream_type ss; > ss.fill('0'); > boost::shared_ptr<dst_calc_rule> no_rules; > > ss << std_zone_abbrev(); > > if(base_utc_offset().is_negative()) { > > ss << '-' << std::setw(2) << base_utc_offset().invert_sign().hours(); > } > else { > ss << '+' << std::setw(2) << base_utc_offset().hours(); > } > if(base_utc_offset().minutes() != 0 || base_utc_offset().seconds() != 0) { > ss << ':' << std::setw(2) << base_utc_offset().minutes(); > if(base_utc_offset().seconds() != 0) { > ss << ':' << std::setw(2) << base_utc_offset().seconds(); > } > } > if(dst_calc_rules_ != no_rules) { > > ss << dst_zone_abbrev(); > > if(dst_offset().is_negative()) { > > ss << '-' << std::setw(2) << dst_offset().invert_sign().hours(); > } > else { > ss << '+' << std::setw(2) << dst_offset().hours(); > } > if(dst_offset().minutes() != 0 || dst_offset().seconds() != 0) { > ss << ':' << std::setw(2) << dst_offset().minutes(); > if(dst_offset().seconds() != 0) { > ss << ':' << std::setw(2) << dst_offset().seconds(); > } > } > > ss << ',' << date_time::convert_string_type<char, char_type>(dst_calc_rules_->start_rule_as_string()) << '/' > << std::setw(2) << dst_offsets_.dst_start_offset_.hours() << ':' > << std::setw(2) << dst_offsets_.dst_start_offset_.minutes(); > if(dst_offsets_.dst_start_offset_.seconds() != 0) { > ss << ':' << std::setw(2) << dst_offsets_.dst_start_offset_.seconds(); > } > > ss << ',' << date_time::convert_string_type<char, char_type>(dst_calc_rules_->end_rule_as_string()) << '/' > << std::setw(2) << dst_offsets_.dst_end_offset_.hours() << ':' > << std::setw(2) << dst_offsets_.dst_end_offset_.minutes(); > if(dst_offsets_.dst_end_offset_.seconds() != 0) { > ss << ':' << std::setw(2) << dst_offsets_.dst_end_offset_.seconds(); > } > } > > return ss.str(); > } > private: > time_zone_names zone_names_; > bool has_dst_; > time_duration_type base_utc_offset_; > dst_adjustment_offsets dst_offsets_; > boost::shared_ptr<dst_calc_rule> dst_calc_rules_; > }; > > typedef custom_time_zone_base<char> custom_time_zone; > >} } ># 19 "/usr/include/boost/date_time/local_time/local_time_types.hpp" 2 3 4 > >namespace boost { >namespace local_time { > > typedef boost::date_time::period<local_date_time, > boost::posix_time::time_duration> local_time_period; > > typedef date_time::time_itr<local_date_time> local_time_iterator; > > typedef date_time::second_clock<local_date_time> local_sec_clock; > typedef date_time::microsec_clock<local_date_time> local_microsec_clock; > > typedef date_time::time_zone_base<posix_time::ptime, char> time_zone; > typedef date_time::time_zone_base<posix_time::ptime, wchar_t> wtime_zone; > > > typedef boost::shared_ptr<time_zone> time_zone_ptr; > typedef boost::shared_ptr<wtime_zone> wtime_zone_ptr; > > typedef date_time::time_zone_names_base<char> time_zone_names; > typedef date_time::time_zone_names_base<wchar_t> wtime_zone_names; > > > 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; > >}} ># 14 "/usr/include/boost/date_time/local_time/local_time.hpp" 2 3 4 > ># 1 "/usr/include/boost/date_time/local_time/local_time_io.hpp" 1 3 4 ># 18 "/usr/include/boost/date_time/local_time/local_time_io.hpp" 3 4 ># 1 "/usr/include/boost/date_time/local_time/posix_time_zone.hpp" 1 3 4 ># 24 "/usr/include/boost/date_time/local_time/posix_time_zone.hpp" 3 4 >namespace boost{ >namespace local_time{ > > > struct bad_offset : public std::out_of_range > { > bad_offset(std::string const& msg = std::string()) : > std::out_of_range(std::string("Offset out of range: " + msg)) {} > }; > > struct bad_adjustment : public std::out_of_range > { > bad_adjustment(std::string const& msg = std::string()) : > std::out_of_range(std::string("Adjustment out of range: " + msg)) {} > }; > > typedef boost::date_time::dst_adjustment_offsets<boost::posix_time::time_duration> dst_adjustment_offsets; ># 69 "/usr/include/boost/date_time/local_time/posix_time_zone.hpp" 3 4 > template<class CharT> > class posix_time_zone_base : public date_time::time_zone_base<posix_time::ptime,CharT> { > public: > typedef boost::posix_time::time_duration time_duration_type; > typedef date_time::time_zone_names_base<CharT> time_zone_names; > typedef date_time::time_zone_base<posix_time::ptime,CharT> base_type; > typedef typename base_type::string_type string_type; > typedef CharT char_type; > typedef typename base_type::stringstream_type stringstream_type; > typedef boost::char_separator<char_type, std::char_traits<char_type> > char_separator_type; > typedef boost::tokenizer<char_separator_type, > typename string_type::const_iterator, > string_type> tokenizer_type; > typedef typename tokenizer_type::iterator tokenizer_iterator_type; > > > posix_time_zone_base(const string_type& s) : > > zone_names_(), > has_dst_(false), > base_utc_offset_(posix_time::hours(0)), > dst_offsets_(posix_time::hours(0),posix_time::hours(0),posix_time::hours(0)), > dst_calc_rules_() > { > > > > > > const char_type sep_chars[2] = {','}; > > char_separator_type sep(sep_chars); > tokenizer_type tokens(s, sep); > tokenizer_iterator_type it = tokens.begin(), end = tokens.end(); > if (it == end) > ::boost::exception_detail::throw_exception_(std::invalid_argument("Could not parse time zone name"),__PRETTY_FUNCTION__,"/usr/include/boost/date_time/local_time/posix_time_zone.hpp",104); > calc_zone(*it++); > if(has_dst_) > { > if (it == end) > ::boost::exception_detail::throw_exception_(std::invalid_argument("Could not parse DST begin time"),__PRETTY_FUNCTION__,"/usr/include/boost/date_time/local_time/posix_time_zone.hpp",109); > string_type dst_begin = *it++; > > if (it == end) > ::boost::exception_detail::throw_exception_(std::invalid_argument("Could not parse DST end time"),__PRETTY_FUNCTION__,"/usr/include/boost/date_time/local_time/posix_time_zone.hpp",113); > string_type dst_end = *it; > calc_rules(dst_begin, dst_end); > } > } > virtual ~posix_time_zone_base() {} > > virtual string_type std_zone_abbrev()const > { > return zone_names_.std_zone_abbrev(); > } > > > virtual string_type dst_zone_abbrev() const > { > return zone_names_.dst_zone_abbrev(); > } > > > > virtual string_type std_zone_name()const > { > return zone_names_.std_zone_name(); > } > > > > > virtual string_type dst_zone_name()const > { > return zone_names_.dst_zone_name(); > } > > virtual bool has_dst()const > { > return has_dst_; > } > > virtual posix_time::ptime dst_local_start_time(gregorian::greg_year y)const > { > gregorian::date d(gregorian::not_a_date_time); > if(has_dst_) > { > d = dst_calc_rules_->start_day(y); > } > return posix_time::ptime(d, dst_offsets_.dst_start_offset_); > } > > virtual posix_time::ptime dst_local_end_time(gregorian::greg_year y)const > { > gregorian::date d(gregorian::not_a_date_time); > if(has_dst_) > { > d = dst_calc_rules_->end_day(y); > } > return posix_time::ptime(d, dst_offsets_.dst_end_offset_); > } > > virtual time_duration_type base_utc_offset()const > { > return base_utc_offset_; > } > > virtual time_duration_type dst_offset()const > { > return dst_offsets_.dst_adjust_; > } > > > virtual string_type to_posix_string() const > { > > stringstream_type ss; > ss.fill('0'); > boost::shared_ptr<dst_calc_rule> no_rules; > > ss << std_zone_abbrev(); > > if(base_utc_offset().is_negative()) { > > ss << '-' << std::setw(2) << base_utc_offset().invert_sign().hours(); > } > else { > ss << '+' << std::setw(2) << base_utc_offset().hours(); > } > if(base_utc_offset().minutes() != 0 || base_utc_offset().seconds() != 0) { > ss << ':' << std::setw(2) << base_utc_offset().minutes(); > if(base_utc_offset().seconds() != 0) { > ss << ':' << std::setw(2) << base_utc_offset().seconds(); > } > } > if(dst_calc_rules_ != no_rules) { > > ss << dst_zone_abbrev(); > > if(dst_offset().is_negative()) { > > ss << '-' << std::setw(2) << dst_offset().invert_sign().hours(); > } > else { > ss << '+' << std::setw(2) << dst_offset().hours(); > } > if(dst_offset().minutes() != 0 || dst_offset().seconds() != 0) { > ss << ':' << std::setw(2) << dst_offset().minutes(); > if(dst_offset().seconds() != 0) { > ss << ':' << std::setw(2) << dst_offset().seconds(); > } > } > > ss << ',' << date_time::convert_string_type<char, char_type>(dst_calc_rules_->start_rule_as_string()) << '/' > << std::setw(2) << dst_offsets_.dst_start_offset_.hours() << ':' > << std::setw(2) << dst_offsets_.dst_start_offset_.minutes(); > if(dst_offsets_.dst_start_offset_.seconds() != 0) { > ss << ':' << std::setw(2) << dst_offsets_.dst_start_offset_.seconds(); > } > > ss << ',' << date_time::convert_string_type<char, char_type>(dst_calc_rules_->end_rule_as_string()) << '/' > << std::setw(2) << dst_offsets_.dst_end_offset_.hours() << ':' > << std::setw(2) << dst_offsets_.dst_end_offset_.minutes(); > if(dst_offsets_.dst_end_offset_.seconds() != 0) { > ss << ':' << std::setw(2) << dst_offsets_.dst_end_offset_.seconds(); > } > } > > return ss.str(); > } > private: > time_zone_names zone_names_; > bool has_dst_; > time_duration_type base_utc_offset_; > dst_adjustment_offsets dst_offsets_; > boost::shared_ptr<dst_calc_rule> dst_calc_rules_; > > > > > > void calc_zone(const string_type& obj){ > const char_type empty_string[2] = {'\0'}; > stringstream_type ss(empty_string); > typename string_type::const_pointer sit = obj.c_str(), obj_end = sit + obj.size(); > string_type l_std_zone_abbrev, l_dst_zone_abbrev; > > > while(std::isalpha(*sit)){ > ss << *sit++; > } > l_std_zone_abbrev = ss.str(); > ss.str(empty_string); > > > if(sit != obj_end){ > > while(sit != obj_end && !std::isalpha(*sit)){ > ss << *sit++; > } > base_utc_offset_ = date_time::str_from_delimited_time_duration<time_duration_type,char_type>(ss.str()); > ss.str(empty_string); > > > if(base_utc_offset_ < time_duration_type(-12,0,0) || > base_utc_offset_ > time_duration_type(14,0,0)) > { > boost::throw_exception(bad_offset(posix_time::to_simple_string(base_utc_offset_))); > } > } > > > if(sit != obj_end){ > has_dst_ = true; > > > while(sit != obj_end && std::isalpha(*sit)){ > ss << *sit++; > } > l_dst_zone_abbrev = ss.str(); > ss.str(empty_string); > > > if(sit != obj_end){ > > while(sit != obj_end && !std::isalpha(*sit)){ > ss << *sit++; > } > dst_offsets_.dst_adjust_ = date_time::str_from_delimited_time_duration<time_duration_type,char_type>(ss.str()); > ss.str(empty_string); > } > else{ > dst_offsets_.dst_adjust_ = posix_time::hours(1); > } > > > if(dst_offsets_.dst_adjust_ <= time_duration_type(-24,0,0) || > dst_offsets_.dst_adjust_ >= time_duration_type(24,0,0)) > { > boost::throw_exception(bad_adjustment(posix_time::to_simple_string(dst_offsets_.dst_adjust_))); > } > } > > zone_names_ = time_zone_names(l_std_zone_abbrev, l_std_zone_abbrev, l_dst_zone_abbrev, l_dst_zone_abbrev); > } > > void calc_rules(const string_type& start, const string_type& end){ > > > > > > const char_type sep_chars[2] = {'/'}; > > char_separator_type sep(sep_chars); > tokenizer_type st_tok(start, sep); > tokenizer_type et_tok(end, sep); > tokenizer_iterator_type sit = st_tok.begin(); > tokenizer_iterator_type eit = et_tok.begin(); > > > char_type x = string_type(*sit).at(0); > if(x == 'M'){ > M_func(*sit, *eit); > } > else if(x == 'J'){ > julian_no_leap(*sit, *eit); > } > else{ > julian_day(*sit, *eit); > } > > ++sit; > ++eit; > > > if(sit != st_tok.end()){ > dst_offsets_.dst_start_offset_ = date_time::str_from_delimited_time_duration<time_duration_type,char_type>(*sit); > } > else{ > > dst_offsets_.dst_start_offset_ = posix_time::hours(2); > } > > if(dst_offsets_.dst_start_offset_ < time_duration_type(0,0,0) || > dst_offsets_.dst_start_offset_ >= time_duration_type(24,0,0)) > { > boost::throw_exception(bad_offset(posix_time::to_simple_string(dst_offsets_.dst_start_offset_))); > } > > > if(eit != et_tok.end()){ > dst_offsets_.dst_end_offset_ = date_time::str_from_delimited_time_duration<time_duration_type,char_type>(*eit); > } > else{ > > dst_offsets_.dst_end_offset_ = posix_time::hours(2); > } > > if(dst_offsets_.dst_end_offset_ < time_duration_type(0,0,0) || > dst_offsets_.dst_end_offset_ >= time_duration_type(24,0,0)) > { > boost::throw_exception(bad_offset(posix_time::to_simple_string(dst_offsets_.dst_end_offset_))); > } > } > > > > > > void M_func(const string_type& s, const string_type& e){ > typedef gregorian::nth_kday_of_month nkday; > unsigned short sm=0,sw=0,sd=0,em=0,ew=0,ed=0; > > > > > > const char_type sep_chars[3] = {'M','.'}; > > char_separator_type sep(sep_chars); > tokenizer_type stok(s, sep), etok(e, sep); > > tokenizer_iterator_type it = stok.begin(); > sm = lexical_cast<unsigned short>(*it++); > sw = lexical_cast<unsigned short>(*it++); > sd = lexical_cast<unsigned short>(*it); > > it = etok.begin(); > em = lexical_cast<unsigned short>(*it++); > ew = lexical_cast<unsigned short>(*it++); > ed = lexical_cast<unsigned short>(*it); > > dst_calc_rules_ = shared_ptr<dst_calc_rule>( > new nth_kday_dst_rule( > nth_last_dst_rule::start_rule( > static_cast<nkday::week_num>(sw),sd,sm), > nth_last_dst_rule::start_rule( > static_cast<nkday::week_num>(ew),ed,em) > ) > ); > } > > > > void julian_no_leap(const string_type& s, const string_type& e){ > typedef gregorian::gregorian_calendar calendar; > const unsigned short year = 2001; > unsigned short sm=1; > int sd=0; > sd = lexical_cast<int>(s.substr(1)); > while(sd >= calendar::end_of_month_day(year,sm)){ > sd -= calendar::end_of_month_day(year,sm++); > } > unsigned short em=1; > int ed=0; > ed = lexical_cast<int>(e.substr(1)); > while(ed > calendar::end_of_month_day(year,em)){ > ed -= calendar::end_of_month_day(year,em++); > } > > dst_calc_rules_ = shared_ptr<dst_calc_rule>( > new partial_date_dst_rule( > partial_date_dst_rule::start_rule( > sd, static_cast<date_time::months_of_year>(sm)), > partial_date_dst_rule::end_rule( > ed, static_cast<date_time::months_of_year>(em)) > ) > ); > } > > > > void julian_day(const string_type& s, const string_type& e){ > int sd=0, ed=0; > sd = lexical_cast<int>(s); > ed = lexical_cast<int>(e); > dst_calc_rules_ = shared_ptr<dst_calc_rule>( > new partial_date_dst_rule( > partial_date_dst_rule::start_rule(++sd), > partial_date_dst_rule::end_rule(++ed) > ) > ); > } > > > static std::string td_as_string(const time_duration_type& td) > { > std::string s; > > > > std::stringstream ss; > ss << td; > s = ss.str(); > > return s; > } > }; > > typedef posix_time_zone_base<char> posix_time_zone; > >} } ># 19 "/usr/include/boost/date_time/local_time/local_time_io.hpp" 2 3 4 ># 1 "/usr/include/boost/date_time/local_time/conversion.hpp" 1 3 4 ># 16 "/usr/include/boost/date_time/local_time/conversion.hpp" 3 4 >namespace boost { >namespace local_time { > > >inline >std::tm to_tm(const local_date_time& lt) { > std::tm lt_tm = posix_time::to_tm(lt.local_time()); > if(lt.is_dst()){ > lt_tm.tm_isdst = 1; > } > else{ > lt_tm.tm_isdst = 0; > } > return lt_tm; >} > > >}} ># 20 "/usr/include/boost/date_time/local_time/local_time_io.hpp" 2 3 4 > >namespace boost { >namespace local_time { > > typedef boost::date_time::time_facet<local_date_time, wchar_t> wlocal_time_facet; > typedef boost::date_time::time_facet<local_date_time, char> local_time_facet; > > typedef boost::date_time::time_input_facet<local_date_time::utc_time_type,wchar_t> wlocal_time_input_facet; > typedef boost::date_time::time_input_facet<local_date_time::utc_time_type,char> local_time_input_facet; > > > template<class CharT, class TraitsT> > inline > std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, const local_date_time& ldt) > { > boost::io::ios_flags_saver iflags(os); > typedef local_date_time time_type; > typedef date_time::time_facet<time_type, CharT> custom_time_facet; > typedef std::time_put<CharT> std_time_facet; > std::ostreambuf_iterator<CharT> oitr(os); > > if(std::has_facet<custom_time_facet>(os.getloc())) { > std::use_facet<custom_time_facet>(os.getloc()).put(oitr, > os, > os.fill(), > ldt); > } > else { > custom_time_facet* f = new custom_time_facet(); > std::locale l = std::locale(os.getloc(), f); > os.imbue(l); > f->put(oitr, os, os.fill(), ldt); > } > > return os; > } > > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, local_date_time& ldt) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename local_date_time::utc_time_type utc_time_type; > typedef typename date_time::time_input_facet<utc_time_type, CharT> time_input_facet; > > > std::basic_string<CharT> tz_str; > utc_time_type pt(not_a_date_time); > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<time_input_facet>(is.getloc())) { > std::use_facet<time_input_facet>(is.getloc()).get_local_time(sit, str_end, is, pt, tz_str); > } > else { > time_input_facet* f = new time_input_facet(); > std::locale l = std::locale(is.getloc(), f); > is.imbue(l); > f->get_local_time(sit, str_end, is, pt, tz_str); > } > if(tz_str.empty()) { > time_zone_ptr null_ptr; > > ldt = local_date_time(pt, null_ptr); > } > else { > time_zone_ptr tz_ptr(new posix_time_zone(date_time::convert_string_type<CharT,char>(tz_str))); > > > ldt = local_date_time(pt.date(), pt.time_of_day(), tz_ptr, local_date_time::EXCEPTION_ON_ERROR); > } > } > 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; > } > else { > > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > > > template <class CharT, class TraitsT> > inline > std::basic_ostream<CharT, TraitsT>& > operator<<(std::basic_ostream<CharT, TraitsT>& os, > const boost::local_time::local_time_period& p) { > boost::io::ios_flags_saver iflags(os); > typedef boost::date_time::time_facet<local_date_time, CharT> custom_facet; > typedef std::time_put<CharT> std_time_facet; > std::ostreambuf_iterator<CharT> oitr(os); > if (std::has_facet<custom_facet>(os.getloc())) { > std::use_facet<custom_facet>(os.getloc()).put(oitr, os, os.fill(), p); > } > else { > > > > > > custom_facet* f = new custom_facet(); > std::locale l = std::locale(os.getloc(), f); > os.imbue(l); > f->put(oitr, os, os.fill(), p); > } > return os; > } > > > template <class CharT, class Traits> > inline > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, boost::local_time::local_time_period& tp) > { > boost::io::ios_flags_saver iflags(is); > typename std::basic_istream<CharT, Traits>::sentry strm_sentry(is, false); > if (strm_sentry) { > try { > typedef typename date_time::time_input_facet<local_date_time, CharT> time_input_facet; > > std::istreambuf_iterator<CharT,Traits> sit(is), str_end; > if(std::has_facet<time_input_facet>(is.getloc())) { > std::use_facet<time_input_facet>(is.getloc()).get(sit, str_end, is, tp); > } > else { > time_input_facet* f = new time_input_facet(); > std::locale l = std::locale(is.getloc(), f); > is.imbue(l); > f->get(sit, str_end, is, tp); > } > } > 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; > } > else { > is.setstate(std::ios_base::failbit); > } > > } > } > return is; > } > >} } ># 16 "/usr/include/boost/date_time/local_time/local_time.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/date_time/local_time/tz_database.hpp" 1 3 4 ># 14 "/usr/include/boost/date_time/local_time/tz_database.hpp" 3 4 ># 1 "/usr/include/boost/date_time/tz_db_base.hpp" 1 3 4 ># 25 "/usr/include/boost/date_time/tz_db_base.hpp" 3 4 >namespace boost { > namespace date_time { > > > class data_not_accessible : public std::logic_error > { > public: > data_not_accessible() : > std::logic_error(std::string("Unable to locate or access the required datafile.")) > {} > data_not_accessible(const std::string& filespec) : > std::logic_error(std::string("Unable to locate or access the required datafile. Filespec: " + filespec)) > {} > }; > > > class bad_field_count : public std::out_of_range > { > public: > bad_field_count(const std::string& s) : > std::out_of_range(s) > {} > }; ># 147 "/usr/include/boost/date_time/tz_db_base.hpp" 3 4 > template<class time_zone_type, class rule_type> > class tz_db_base { > public: ># 158 "/usr/include/boost/date_time/tz_db_base.hpp" 3 4 > typedef char char_type; > > typedef typename time_zone_type::base_type time_zone_base_type; > typedef typename time_zone_type::time_duration_type time_duration_type; > typedef time_zone_names_base<char_type> time_zone_names; > typedef boost::date_time::dst_adjustment_offsets<time_duration_type> dst_adjustment_offsets; > typedef std::basic_string<char_type> string_type; > > > tz_db_base() {} > > > > void load_from_stream(std::istream &in) > { > std::string buff; > while( std::getline(in, buff)) { > parse_string(buff); > } > } > > > > void load_from_file(const std::string& pathspec) > { > string_type in_str; > std::string buff; > > std::ifstream ifs(pathspec.c_str()); > if(!ifs){ > boost::throw_exception(data_not_accessible(pathspec)); > } > std::getline(ifs, buff); > this->load_from_stream(ifs); > } > > > > > > bool add_record(const string_type& region, > boost::shared_ptr<time_zone_base_type> tz) > { > typename map_type::value_type p(region, tz); > return (m_zone_map.insert(p)).second; > } > > > > > > boost::shared_ptr<time_zone_base_type> > time_zone_from_region(const string_type& region) const > { > > typename map_type::const_iterator record = m_zone_map.find(region); > if(record == m_zone_map.end()){ > return boost::shared_ptr<time_zone_base_type>(); > } > return record->second; > } > > > std::vector<std::string> region_list() const > { > typedef std::vector<std::string> vector_type; > vector_type regions; > typename map_type::const_iterator itr = m_zone_map.begin(); > while(itr != m_zone_map.end()) { > regions.push_back(itr->first); > ++itr; > } > return regions; > } > > private: > typedef std::map<string_type, boost::shared_ptr<time_zone_base_type> > map_type; > map_type m_zone_map; > > > typedef typename rule_type::start_rule::week_num week_num; > > > > > > > rule_type* parse_rules(const string_type& sr, const string_type& er) const > { > using namespace gregorian; > > > typedef typename rule_type::start_rule start_rule; > typedef typename rule_type::end_rule end_rule; > > > int s_nth = 0, s_d = 0, s_m = 0; > int e_nth = 0, e_d = 0, e_m = 0; > split_rule_spec(s_nth, s_d, s_m, sr); > split_rule_spec(e_nth, e_d, e_m, er); > > typename start_rule::week_num s_wn, e_wn; > s_wn = get_week_num(s_nth); > e_wn = get_week_num(e_nth); > > > return new rule_type(start_rule(s_wn, s_d, s_m), > end_rule(e_wn, e_d, e_m)); > } > > week_num get_week_num(int nth) const > { > typedef typename rule_type::start_rule start_rule; > switch(nth){ > case 1: > return start_rule::first; > case 2: > return start_rule::second; > case 3: > return start_rule::third; > case 4: > return start_rule::fourth; > case 5: > case -1: > return start_rule::fifth; > default: > > break; > } > return start_rule::fifth; > } > > > void split_rule_spec(int& nth, int& d, int& m, string_type rule) const > { > typedef boost::char_separator<char_type, std::char_traits<char_type> > char_separator_type; > typedef boost::tokenizer<char_separator_type, > std::basic_string<char_type>::const_iterator, > std::basic_string<char_type> > tokenizer; > typedef boost::tokenizer<char_separator_type, > std::basic_string<char_type>::const_iterator, > std::basic_string<char_type> >::iterator tokenizer_iterator; > > const char_type sep_char[] = { ';', '\0'}; > char_separator_type sep(sep_char); > tokenizer tokens(rule, sep); > > if ( std::distance ( tokens.begin(), tokens.end ()) != 3 ) { > std::ostringstream msg; > msg << "Expecting 3 fields, got " > << std::distance ( tokens.begin(), tokens.end ()) > << " fields in line: " << rule; > boost::throw_exception(bad_field_count(msg.str())); > } > > tokenizer_iterator tok_iter = tokens.begin(); > nth = std::atoi(tok_iter->c_str()); ++tok_iter; > d = std::atoi(tok_iter->c_str()); ++tok_iter; > m = std::atoi(tok_iter->c_str()); > } > > > > > > > > bool parse_string(string_type& s) > { > std::vector<string_type> result; > typedef boost::token_iterator_generator<boost::escaped_list_separator<char_type>, string_type::const_iterator, string_type >::type token_iter_type; > > token_iter_type i = boost::make_token_iterator<string_type>(s.begin(), s.end(),boost::escaped_list_separator<char_type>()); > > token_iter_type end; > while (i != end) { > result.push_back(*i); > i++; > } > > enum db_fields { ID, STDABBR, STDNAME, DSTABBR, DSTNAME, GMTOFFSET, > DSTADJUST, START_DATE_RULE, START_TIME, END_DATE_RULE, > END_TIME, FIELD_COUNT }; > > > const unsigned int expected_fields = static_cast<unsigned int>(FIELD_COUNT); > if (result.size() != expected_fields) { > std::ostringstream msg; > msg << "Expecting " << FIELD_COUNT << " fields, got " > << result.size() << " fields in line: " << s; > boost::throw_exception(bad_field_count(msg.str())); > std::abort(); > } > > > bool has_dst = true; > if(result[DSTABBR] == std::string()){ > has_dst = false; > } > > > > time_zone_names names(result[STDNAME], result[STDABBR], > result[DSTNAME], result[DSTABBR]); > > time_duration_type utc_offset = > str_from_delimited_time_duration<time_duration_type,char_type>(result[GMTOFFSET]); > > dst_adjustment_offsets adjust(time_duration_type(0,0,0), > time_duration_type(0,0,0), > time_duration_type(0,0,0)); > > boost::shared_ptr<rule_type> rules; > > if(has_dst){ > adjust = dst_adjustment_offsets( > str_from_delimited_time_duration<time_duration_type,char_type>(result[DSTADJUST]), > str_from_delimited_time_duration<time_duration_type,char_type>(result[START_TIME]), > str_from_delimited_time_duration<time_duration_type,char_type>(result[END_TIME]) > ); > > rules = > boost::shared_ptr<rule_type>(parse_rules(result[START_DATE_RULE], > result[END_DATE_RULE])); > } > string_type id(result[ID]); > boost::shared_ptr<time_zone_base_type> zone(new time_zone_type(names, utc_offset, adjust, rules)); > return (add_record(id, zone)); > > } > > }; > >} } ># 15 "/usr/include/boost/date_time/local_time/tz_database.hpp" 2 3 4 > > >namespace boost { >namespace local_time { > > using date_time::data_not_accessible; > using date_time::bad_field_count; > > > > > > typedef date_time::tz_db_base<custom_time_zone, nth_kday_dst_rule> tz_database; > >}} ># 20 "/usr/include/boost/date_time/local_time/local_time.hpp" 2 3 4 ># 35 "/c/honeypenny/contrib/epee/include/time_helper.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/pragma_comp_defs.h" 1 ># 36 "/c/honeypenny/contrib/epee/include/time_helper.h" 2 > >namespace epee >{ >namespace misc_utils >{ ># 55 "/c/honeypenny/contrib/epee/include/time_helper.h" > inline > std::string get_time_str(const time_t& time_) > { > > > char tmpbuf[200] = {0}; > tm* pt = __null; ># 62 "/c/honeypenny/contrib/epee/include/time_helper.h" >#pragma GCC diagnostic push ># 62 "/c/honeypenny/contrib/epee/include/time_helper.h" > > > pt = localtime(&time_); ># 65 "/c/honeypenny/contrib/epee/include/time_helper.h" >#pragma GCC diagnostic pop ># 65 "/c/honeypenny/contrib/epee/include/time_helper.h" > > > if(pt) > strftime( tmpbuf, 199, "%d.%m.%Y %H:%M:%S", pt ); > else > { > std::stringstream strs; > strs << "[wrong_time: " << std::hex << time_ << "]"; > return strs.str(); > } > return tmpbuf; > } > > inline > std::string get_time_str_v2(const time_t& time_) > { > > char tmpbuf[200] = {0}; > tm* pt = __null; ># 84 "/c/honeypenny/contrib/epee/include/time_helper.h" >#pragma GCC diagnostic push ># 84 "/c/honeypenny/contrib/epee/include/time_helper.h" > > > pt = localtime(&time_); ># 87 "/c/honeypenny/contrib/epee/include/time_helper.h" >#pragma GCC diagnostic pop ># 87 "/c/honeypenny/contrib/epee/include/time_helper.h" > > > if(pt) > strftime( tmpbuf, 199, "%Y_%m_%d %H_%M_%S", pt ); > else > { > std::stringstream strs; > strs << "[wrong_time: " << std::hex << time_ << "]"; > return strs.str(); > } > return tmpbuf; > } > > inline > std::string get_time_str_v3(const boost::posix_time::ptime& time_) > { > return boost::posix_time::to_simple_string(time_); > } > > > > inline std::string get_internet_time_str(const time_t& time_) > { > char tmpbuf[200] = {0}; > tm* pt = __null; ># 112 "/c/honeypenny/contrib/epee/include/time_helper.h" >#pragma GCC diagnostic push ># 112 "/c/honeypenny/contrib/epee/include/time_helper.h" > > > pt = gmtime(&time_); ># 115 "/c/honeypenny/contrib/epee/include/time_helper.h" >#pragma GCC diagnostic pop ># 115 "/c/honeypenny/contrib/epee/include/time_helper.h" > > strftime( tmpbuf, 199, "%a, %d %b %Y %H:%M:%S GMT", pt ); > return tmpbuf; > } > > inline std::string get_time_interval_string(const time_t& time_) > { > std::string res; > time_t tail = time_; ># 124 "/c/honeypenny/contrib/epee/include/time_helper.h" >#pragma GCC diagnostic push ># 124 "/c/honeypenny/contrib/epee/include/time_helper.h" > > > int days = tail/(60*60*24); > tail = tail%(60*60*24); > int hours = tail/(60*60); > tail = tail%(60*60); > int minutes = tail/(60); > tail = tail%(60); > int seconds = tail; ># 133 "/c/honeypenny/contrib/epee/include/time_helper.h" >#pragma GCC diagnostic pop ># 133 "/c/honeypenny/contrib/epee/include/time_helper.h" > > res = std::string() + "d" + boost::lexical_cast<std::string>(days) + ".h" + boost::lexical_cast<std::string>(hours) + ".m" + boost::lexical_cast<std::string>(minutes) + ".s" + boost::lexical_cast<std::string>(seconds); > return res; > } ># 158 "/c/honeypenny/contrib/epee/include/time_helper.h" >} >} ># 56 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/misc_os_dependent.h" 1 ># 45 "/c/honeypenny/contrib/epee/include/misc_os_dependent.h" > >namespace epee >{ >namespace misc_utils >{ > > inline uint64_t get_tick_count() > { ># 65 "/c/honeypenny/contrib/epee/include/misc_os_dependent.h" > struct timespec ts; > if(clock_gettime(1, &ts) != 0) { > return 0; > } > return (ts.tv_sec * 1000) + (ts.tv_nsec/1000000); > > } > > > inline int call_sys_cmd(const std::string& cmd) > { > std::cout << "# " << cmd << std::endl; > > FILE * fp ; > > char path[1000] = {0}; > > > > fp = popen(cmd.c_str(), "r"); > > while ( fgets( path, 1000, fp ) != __null ) > std::cout << path; > > > > > pclose(fp); > > return 0; > > } > > > inline std::string get_thread_string_id() > { > > > > return boost::lexical_cast<std::string>(pthread_self()); > > } >} >} ># 57 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 > ># 1 "/c/honeypenny/contrib/epee/include/syncobj.h" 1 ># 33 "/c/honeypenny/contrib/epee/include/syncobj.h" ># 1 "/usr/include/c++/4.9.0/condition_variable" 1 3 ># 32 "/usr/include/c++/4.9.0/condition_variable" 3 ># 33 "/usr/include/c++/4.9.0/condition_variable" 3 > > > > > ># 1 "/usr/include/c++/4.9.0/chrono" 1 3 ># 32 "/usr/include/c++/4.9.0/chrono" 3 ># 33 "/usr/include/c++/4.9.0/chrono" 3 > > > > > ># 1 "/usr/include/c++/4.9.0/ratio" 1 3 ># 32 "/usr/include/c++/4.9.0/ratio" 3 ># 33 "/usr/include/c++/4.9.0/ratio" 3 ># 43 "/usr/include/c++/4.9.0/ratio" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 55 "/usr/include/c++/4.9.0/ratio" 3 > template<intmax_t _Pn> > struct __static_sign > : integral_constant<intmax_t, (_Pn < 0) ? -1 : 1> > { }; > > template<intmax_t _Pn> > struct __static_abs > : integral_constant<intmax_t, _Pn * __static_sign<_Pn>::value> > { }; > > template<intmax_t _Pn, intmax_t _Qn> > struct __static_gcd > : __static_gcd<_Qn, (_Pn % _Qn)> > { }; > > template<intmax_t _Pn> > struct __static_gcd<_Pn, 0> > : integral_constant<intmax_t, __static_abs<_Pn>::value> > { }; > > template<intmax_t _Qn> > struct __static_gcd<0, _Qn> > : integral_constant<intmax_t, __static_abs<_Qn>::value> > { }; > > > > > > > > template<intmax_t _Pn, intmax_t _Qn> > struct __safe_multiply > { > private: > static const uintmax_t __c = uintmax_t(1) << (sizeof(intmax_t) * 4); > > static const uintmax_t __a0 = __static_abs<_Pn>::value % __c; > static const uintmax_t __a1 = __static_abs<_Pn>::value / __c; > static const uintmax_t __b0 = __static_abs<_Qn>::value % __c; > static const uintmax_t __b1 = __static_abs<_Qn>::value / __c; > > static_assert(__a1 == 0 || __b1 == 0, > "overflow in multiplication"); > static_assert(__a0 * __b1 + __b0 * __a1 < (__c >> 1), > "overflow in multiplication"); > static_assert(__b0 * __a0 <= 9223372036854775807L, > "overflow in multiplication"); > static_assert((__a0 * __b1 + __b0 * __a1) * __c > <= 9223372036854775807L - __b0 * __a0, > "overflow in multiplication"); > > public: > static const intmax_t value = _Pn * _Qn; > }; > > > > template<uintmax_t __hi1, uintmax_t __lo1, uintmax_t __hi2, uintmax_t __lo2> > struct __big_less > : integral_constant<bool, (__hi1 < __hi2 > || (__hi1 == __hi2 && __lo1 < __lo2))> > { }; > > template<uintmax_t __hi1, uintmax_t __lo1, uintmax_t __hi2, uintmax_t __lo2> > struct __big_add > { > static constexpr uintmax_t __lo = __lo1 + __lo2; > static constexpr uintmax_t __hi = (__hi1 + __hi2 + > (__lo1 + __lo2 < __lo1)); > }; > > > template<uintmax_t __hi1, uintmax_t __lo1, uintmax_t __hi2, uintmax_t __lo2> > struct __big_sub > { > static_assert(!__big_less<__hi1, __lo1, __hi2, __lo2>::value, > "Internal library error"); > static constexpr uintmax_t __lo = __lo1 - __lo2; > static constexpr uintmax_t __hi = (__hi1 - __hi2 - > (__lo1 < __lo2)); > }; > > > template<uintmax_t __x, uintmax_t __y> > struct __big_mul > { > private: > static constexpr uintmax_t __c = uintmax_t(1) << (sizeof(intmax_t) * 4); > static constexpr uintmax_t __x0 = __x % __c; > static constexpr uintmax_t __x1 = __x / __c; > static constexpr uintmax_t __y0 = __y % __c; > static constexpr uintmax_t __y1 = __y / __c; > static constexpr uintmax_t __x0y0 = __x0 * __y0; > static constexpr uintmax_t __x0y1 = __x0 * __y1; > static constexpr uintmax_t __x1y0 = __x1 * __y0; > static constexpr uintmax_t __x1y1 = __x1 * __y1; > static constexpr uintmax_t __mix = __x0y1 + __x1y0; > static constexpr uintmax_t __mix_lo = __mix * __c; > static constexpr uintmax_t __mix_hi > = __mix / __c + ((__mix < __x0y1) ? __c : 0); > typedef __big_add<__mix_hi, __mix_lo, __x1y1, __x0y0> _Res; > public: > static constexpr uintmax_t __hi = _Res::__hi; > static constexpr uintmax_t __lo = _Res::__lo; > }; > > > > template<uintmax_t __n1, uintmax_t __n0, uintmax_t __d> > struct __big_div_impl > { > private: > static_assert(__d >= (uintmax_t(1) << (sizeof(intmax_t) * 8 - 1)), > "Internal library error"); > static_assert(__n1 < __d, "Internal library error"); > static constexpr uintmax_t __c = uintmax_t(1) << (sizeof(intmax_t) * 4); > static constexpr uintmax_t __d1 = __d / __c; > static constexpr uintmax_t __d0 = __d % __c; > > static constexpr uintmax_t __q1x = __n1 / __d1; > static constexpr uintmax_t __r1x = __n1 % __d1; > static constexpr uintmax_t __m = __q1x * __d0; > static constexpr uintmax_t __r1y = __r1x * __c + __n0 / __c; > static constexpr uintmax_t __r1z = __r1y + __d; > static constexpr uintmax_t __r1 > = ((__r1y < __m) ? ((__r1z >= __d) && (__r1z < __m)) > ? (__r1z + __d) : __r1z : __r1y) - __m; > static constexpr uintmax_t __q1 > = __q1x - ((__r1y < __m) > ? ((__r1z >= __d) && (__r1z < __m)) ? 2 : 1 : 0); > static constexpr uintmax_t __q0x = __r1 / __d1; > static constexpr uintmax_t __r0x = __r1 % __d1; > static constexpr uintmax_t __n = __q0x * __d0; > static constexpr uintmax_t __r0y = __r0x * __c + __n0 % __c; > static constexpr uintmax_t __r0z = __r0y + __d; > static constexpr uintmax_t __r0 > = ((__r0y < __n) ? ((__r0z >= __d) && (__r0z < __n)) > ? (__r0z + __d) : __r0z : __r0y) - __n; > static constexpr uintmax_t __q0 > = __q0x - ((__r0y < __n) ? ((__r0z >= __d) > && (__r0z < __n)) ? 2 : 1 : 0); > > public: > static constexpr uintmax_t __quot = __q1 * __c + __q0; > static constexpr uintmax_t __rem = __r0; > > private: > typedef __big_mul<__quot, __d> _Prod; > typedef __big_add<_Prod::__hi, _Prod::__lo, 0, __rem> _Sum; > static_assert(_Sum::__hi == __n1 && _Sum::__lo == __n0, > "Internal library error"); > }; > > template<uintmax_t __n1, uintmax_t __n0, uintmax_t __d> > struct __big_div > { > private: > static_assert(__d != 0, "Internal library error"); > static_assert(sizeof (uintmax_t) == sizeof (unsigned long long), > "This library calls __builtin_clzll on uintmax_t, which " > "is unsafe on your platform. Please complain to " > "http://gcc.gnu.org/bugzilla/"); > static constexpr int __shift = __builtin_clzll(__d); > static constexpr int __coshift_ = sizeof(uintmax_t) * 8 - __shift; > static constexpr int __coshift = (__shift != 0) ? __coshift_ : 0; > static constexpr uintmax_t __c1 = uintmax_t(1) << __shift; > static constexpr uintmax_t __c2 = uintmax_t(1) << __coshift; > static constexpr uintmax_t __new_d = __d * __c1; > static constexpr uintmax_t __new_n0 = __n0 * __c1; > static constexpr uintmax_t __n1_shifted = (__n1 % __d) * __c1; > static constexpr uintmax_t __n0_top = (__shift != 0) ? (__n0 / __c2) : 0; > static constexpr uintmax_t __new_n1 = __n1_shifted + __n0_top; > typedef __big_div_impl<__new_n1, __new_n0, __new_d> _Res; > > public: > static constexpr uintmax_t __quot_hi = __n1 / __d; > static constexpr uintmax_t __quot_lo = _Res::__quot; > static constexpr uintmax_t __rem = _Res::__rem / __c1; > > private: > typedef __big_mul<__quot_lo, __d> _P0; > typedef __big_mul<__quot_hi, __d> _P1; > typedef __big_add<_P0::__hi, _P0::__lo, _P1::__lo, __rem> _Sum; > > static_assert(_P1::__hi == 0, "Internal library error"); > static_assert(_Sum::__hi >= _P0::__hi, "Internal library error"); > > static_assert(_Sum::__hi == __n1 && _Sum::__lo == __n0, > "Internal library error"); > static_assert(__rem < __d, "Internal library error"); > }; ># 262 "/usr/include/c++/4.9.0/ratio" 3 > template<intmax_t _Num, intmax_t _Den = 1> > struct ratio > { > static_assert(_Den != 0, "denominator cannot be zero"); > static_assert(_Num >= -9223372036854775807L && _Den >= -9223372036854775807L, > "out of range"); > > > static constexpr intmax_t num = > _Num * __static_sign<_Den>::value / __static_gcd<_Num, _Den>::value; > > static constexpr intmax_t den = > __static_abs<_Den>::value / __static_gcd<_Num, _Den>::value; > > typedef ratio<num, den> type; > }; > > template<intmax_t _Num, intmax_t _Den> > constexpr intmax_t ratio<_Num, _Den>::num; > > template<intmax_t _Num, intmax_t _Den> > constexpr intmax_t ratio<_Num, _Den>::den; > > template<typename _R1, typename _R2> > struct __ratio_multiply > { > private: > static const intmax_t __gcd1 = > __static_gcd<_R1::num, _R2::den>::value; > static const intmax_t __gcd2 = > __static_gcd<_R2::num, _R1::den>::value; > > public: > typedef ratio< > __safe_multiply<(_R1::num / __gcd1), > (_R2::num / __gcd2)>::value, > __safe_multiply<(_R1::den / __gcd2), > (_R2::den / __gcd1)>::value> type; > > static constexpr intmax_t num = type::num; > static constexpr intmax_t den = type::den; > }; > > template<typename _R1, typename _R2> > constexpr intmax_t __ratio_multiply<_R1, _R2>::num; > > template<typename _R1, typename _R2> > constexpr intmax_t __ratio_multiply<_R1, _R2>::den; > > > template<typename _R1, typename _R2> > using ratio_multiply = typename __ratio_multiply<_R1, _R2>::type; > > template<typename _R1, typename _R2> > struct __ratio_divide > { > static_assert(_R2::num != 0, "division by 0"); > > typedef typename __ratio_multiply< > _R1, > ratio<_R2::den, _R2::num>>::type type; > > static constexpr intmax_t num = type::num; > static constexpr intmax_t den = type::den; > }; > > template<typename _R1, typename _R2> > constexpr intmax_t __ratio_divide<_R1, _R2>::num; > > template<typename _R1, typename _R2> > constexpr intmax_t __ratio_divide<_R1, _R2>::den; > > > template<typename _R1, typename _R2> > using ratio_divide = typename __ratio_divide<_R1, _R2>::type; > > > template<typename _R1, typename _R2> > struct ratio_equal > : integral_constant<bool, _R1::num == _R2::num && _R1::den == _R2::den> > { }; > > > template<typename _R1, typename _R2> > struct ratio_not_equal > : integral_constant<bool, !ratio_equal<_R1, _R2>::value> > { }; > > > template<typename _R1, typename _R2, > typename _Left = __big_mul<_R1::num,_R2::den>, > typename _Right = __big_mul<_R2::num,_R1::den> > > struct __ratio_less_impl_1 > : integral_constant<bool, __big_less<_Left::__hi, _Left::__lo, > _Right::__hi, _Right::__lo>::value> > { }; > > template<typename _R1, typename _R2, > bool = (_R1::num == 0 || _R2::num == 0 > || (__static_sign<_R1::num>::value > != __static_sign<_R2::num>::value)), > bool = (__static_sign<_R1::num>::value == -1 > && __static_sign<_R2::num>::value == -1)> > struct __ratio_less_impl > : __ratio_less_impl_1<_R1, _R2>::type > { }; > > template<typename _R1, typename _R2> > struct __ratio_less_impl<_R1, _R2, true, false> > : integral_constant<bool, _R1::num < _R2::num> > { }; > > template<typename _R1, typename _R2> > struct __ratio_less_impl<_R1, _R2, false, true> > : __ratio_less_impl_1<ratio<-_R2::num, _R2::den>, > ratio<-_R1::num, _R1::den> >::type > { }; > > > template<typename _R1, typename _R2> > struct ratio_less > : __ratio_less_impl<_R1, _R2>::type > { }; > > > template<typename _R1, typename _R2> > struct ratio_less_equal > : integral_constant<bool, !ratio_less<_R2, _R1>::value> > { }; > > > template<typename _R1, typename _R2> > struct ratio_greater > : integral_constant<bool, ratio_less<_R2, _R1>::value> > { }; > > > template<typename _R1, typename _R2> > struct ratio_greater_equal > : integral_constant<bool, !ratio_less<_R1, _R2>::value> > { }; > > template<typename _R1, typename _R2, > bool = (_R1::num >= 0), > bool = (_R2::num >= 0), > bool = ratio_less<ratio<__static_abs<_R1::num>::value, _R1::den>, > ratio<__static_abs<_R2::num>::value, _R2::den> >::value> > struct __ratio_add_impl > { > private: > typedef typename __ratio_add_impl< > ratio<-_R1::num, _R1::den>, > ratio<-_R2::num, _R2::den> >::type __t; > public: > typedef ratio<-__t::num, __t::den> type; > }; > > > template<typename _R1, typename _R2, bool __b> > struct __ratio_add_impl<_R1, _R2, true, true, __b> > { > private: > static constexpr uintmax_t __g = __static_gcd<_R1::den, _R2::den>::value; > static constexpr uintmax_t __d2 = _R2::den / __g; > typedef __big_mul<_R1::den, __d2> __d; > typedef __big_mul<_R1::num, _R2::den / __g> __x; > typedef __big_mul<_R2::num, _R1::den / __g> __y; > typedef __big_add<__x::__hi, __x::__lo, __y::__hi, __y::__lo> __n; > static_assert(__n::__hi >= __x::__hi, "Internal library error"); > typedef __big_div<__n::__hi, __n::__lo, __g> __ng; > static constexpr uintmax_t __g2 = __static_gcd<__ng::__rem, __g>::value; > typedef __big_div<__n::__hi, __n::__lo, __g2> __n_final; > static_assert(__n_final::__rem == 0, "Internal library error"); > static_assert(__n_final::__quot_hi == 0 && > __n_final::__quot_lo <= 9223372036854775807L, "overflow in addition"); > typedef __big_mul<_R1::den / __g2, __d2> __d_final; > static_assert(__d_final::__hi == 0 && > __d_final::__lo <= 9223372036854775807L, "overflow in addition"); > public: > typedef ratio<__n_final::__quot_lo, __d_final::__lo> type; > }; > > template<typename _R1, typename _R2> > struct __ratio_add_impl<_R1, _R2, false, true, true> > : __ratio_add_impl<_R2, _R1> > { }; > > > template<typename _R1, typename _R2> > struct __ratio_add_impl<_R1, _R2, true, false, false> > { > private: > static constexpr uintmax_t __g = __static_gcd<_R1::den, _R2::den>::value; > static constexpr uintmax_t __d2 = _R2::den / __g; > typedef __big_mul<_R1::den, __d2> __d; > typedef __big_mul<_R1::num, _R2::den / __g> __x; > typedef __big_mul<-_R2::num, _R1::den / __g> __y; > typedef __big_sub<__x::__hi, __x::__lo, __y::__hi, __y::__lo> __n; > typedef __big_div<__n::__hi, __n::__lo, __g> __ng; > static constexpr uintmax_t __g2 = __static_gcd<__ng::__rem, __g>::value; > typedef __big_div<__n::__hi, __n::__lo, __g2> __n_final; > static_assert(__n_final::__rem == 0, "Internal library error"); > static_assert(__n_final::__quot_hi == 0 && > __n_final::__quot_lo <= 9223372036854775807L, "overflow in addition"); > typedef __big_mul<_R1::den / __g2, __d2> __d_final; > static_assert(__d_final::__hi == 0 && > __d_final::__lo <= 9223372036854775807L, "overflow in addition"); > public: > typedef ratio<__n_final::__quot_lo, __d_final::__lo> type; > }; > > template<typename _R1, typename _R2> > struct __ratio_add > { > typedef typename __ratio_add_impl<_R1, _R2>::type type; > static constexpr intmax_t num = type::num; > static constexpr intmax_t den = type::den; > }; > > template<typename _R1, typename _R2> > constexpr intmax_t __ratio_add<_R1, _R2>::num; > > template<typename _R1, typename _R2> > constexpr intmax_t __ratio_add<_R1, _R2>::den; > > > template<typename _R1, typename _R2> > using ratio_add = typename __ratio_add<_R1, _R2>::type; > > template<typename _R1, typename _R2> > struct __ratio_subtract > { > typedef typename __ratio_add< > _R1, > ratio<-_R2::num, _R2::den>>::type type; > > static constexpr intmax_t num = type::num; > static constexpr intmax_t den = type::den; > }; > > template<typename _R1, typename _R2> > constexpr intmax_t __ratio_subtract<_R1, _R2>::num; > > template<typename _R1, typename _R2> > constexpr intmax_t __ratio_subtract<_R1, _R2>::den; > > > template<typename _R1, typename _R2> > using ratio_subtract = typename __ratio_subtract<_R1, _R2>::type; > > > typedef ratio<1, 1000000000000000000> atto; > typedef ratio<1, 1000000000000000> femto; > typedef ratio<1, 1000000000000> pico; > typedef ratio<1, 1000000000> nano; > typedef ratio<1, 1000000> micro; > typedef ratio<1, 1000> milli; > typedef ratio<1, 100> centi; > typedef ratio<1, 10> deci; > typedef ratio< 10, 1> deca; > typedef ratio< 100, 1> hecto; > typedef ratio< 1000, 1> kilo; > typedef ratio< 1000000, 1> mega; > typedef ratio< 1000000000, 1> giga; > typedef ratio< 1000000000000, 1> tera; > typedef ratio< 1000000000000000, 1> peta; > typedef ratio< 1000000000000000000, 1> exa; > > > >} ># 39 "/usr/include/c++/4.9.0/chrono" 2 3 > > ># 1 "/usr/include/c++/4.9.0/ctime" 1 3 ># 39 "/usr/include/c++/4.9.0/ctime" 3 ># 40 "/usr/include/c++/4.9.0/ctime" 3 ># 42 "/usr/include/c++/4.9.0/chrono" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/parse_numbers.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/parse_numbers.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/parse_numbers.h" 3 ># 43 "/usr/include/c++/4.9.0/chrono" 2 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 59 "/usr/include/c++/4.9.0/chrono" 3 > namespace chrono > { > > > template<typename _Rep, typename _Period = ratio<1>> > struct duration; > > template<typename _Clock, typename _Dur = typename _Clock::duration> > struct time_point; > > > } > > > > > > template<typename _CT, typename _Period1, typename _Period2> > struct __duration_common_type_wrapper > { > private: > typedef __static_gcd<_Period1::num, _Period2::num> __gcd_num; > typedef __static_gcd<_Period1::den, _Period2::den> __gcd_den; > typedef typename _CT::type __cr; > typedef ratio<__gcd_num::value, > (_Period1::den / __gcd_den::value) * _Period2::den> __r; > public: > typedef __success_type<chrono::duration<__cr, __r>> type; > }; > > template<typename _Period1, typename _Period2> > struct __duration_common_type_wrapper<__failure_type, _Period1, _Period2> > { typedef __failure_type type; }; > > template<typename _Rep1, typename _Period1, typename _Rep2, typename _Period2> > struct common_type<chrono::duration<_Rep1, _Period1>, > chrono::duration<_Rep2, _Period2>> > : public __duration_common_type_wrapper<typename __member_type_wrapper< > common_type<_Rep1, _Rep2>>::type, _Period1, _Period2>::type > { }; > > > > template<typename _CT, typename _Clock> > struct __timepoint_common_type_wrapper > { > typedef __success_type<chrono::time_point<_Clock, typename _CT::type>> > type; > }; > > template<typename _Clock> > struct __timepoint_common_type_wrapper<__failure_type, _Clock> > { typedef __failure_type type; }; > > template<typename _Clock, typename _Duration1, typename _Duration2> > struct common_type<chrono::time_point<_Clock, _Duration1>, > chrono::time_point<_Clock, _Duration2>> > : public __timepoint_common_type_wrapper<typename __member_type_wrapper< > common_type<_Duration1, _Duration2>>::type, _Clock>::type > { }; > > > > namespace chrono > { > > > > template<typename _ToDur, typename _CF, typename _CR, > bool _NumIsOne = false, bool _DenIsOne = false> > struct __duration_cast_impl > { > template<typename _Rep, typename _Period> > static constexpr _ToDur > __cast(const duration<_Rep, _Period>& __d) > { > typedef typename _ToDur::rep __to_rep; > return _ToDur(static_cast<__to_rep>(static_cast<_CR>(__d.count()) > * static_cast<_CR>(_CF::num) > / static_cast<_CR>(_CF::den))); > } > }; > > template<typename _ToDur, typename _CF, typename _CR> > struct __duration_cast_impl<_ToDur, _CF, _CR, true, true> > { > template<typename _Rep, typename _Period> > static constexpr _ToDur > __cast(const duration<_Rep, _Period>& __d) > { > typedef typename _ToDur::rep __to_rep; > return _ToDur(static_cast<__to_rep>(__d.count())); > } > }; > > template<typename _ToDur, typename _CF, typename _CR> > struct __duration_cast_impl<_ToDur, _CF, _CR, true, false> > { > template<typename _Rep, typename _Period> > static constexpr _ToDur > __cast(const duration<_Rep, _Period>& __d) > { > typedef typename _ToDur::rep __to_rep; > return _ToDur(static_cast<__to_rep>( > static_cast<_CR>(__d.count()) / static_cast<_CR>(_CF::den))); > } > }; > > template<typename _ToDur, typename _CF, typename _CR> > struct __duration_cast_impl<_ToDur, _CF, _CR, false, true> > { > template<typename _Rep, typename _Period> > static constexpr _ToDur > __cast(const duration<_Rep, _Period>& __d) > { > typedef typename _ToDur::rep __to_rep; > return _ToDur(static_cast<__to_rep>( > static_cast<_CR>(__d.count()) * static_cast<_CR>(_CF::num))); > } > }; > > template<typename _Tp> > struct __is_duration > : std::false_type > { }; > > template<typename _Rep, typename _Period> > struct __is_duration<duration<_Rep, _Period>> > : std::true_type > { }; > > > template<typename _ToDur, typename _Rep, typename _Period> > constexpr typename enable_if<__is_duration<_ToDur>::value, > _ToDur>::type > duration_cast(const duration<_Rep, _Period>& __d) > { > typedef typename _ToDur::period __to_period; > typedef typename _ToDur::rep __to_rep; > typedef ratio_divide<_Period, __to_period> __cf; > typedef typename common_type<__to_rep, _Rep, intmax_t>::type > __cr; > typedef __duration_cast_impl<_ToDur, __cf, __cr, > __cf::num == 1, __cf::den == 1> __dc; > return __dc::__cast(__d); > } > > > template<typename _Rep> > struct treat_as_floating_point > : is_floating_point<_Rep> > { }; > > > template<typename _Rep> > struct duration_values > { > static constexpr _Rep > zero() > { return _Rep(0); } > > static constexpr _Rep > max() > { return numeric_limits<_Rep>::max(); } > > static constexpr _Rep > min() > { return numeric_limits<_Rep>::lowest(); } > }; > > template<typename _Tp> > struct __is_ratio > : std::false_type > { }; > > template<intmax_t _Num, intmax_t _Den> > struct __is_ratio<ratio<_Num, _Den>> > : std::true_type > { }; > > > template<typename _Rep, typename _Period> > struct duration > { > typedef _Rep rep; > typedef _Period period; > > static_assert(!__is_duration<_Rep>::value, "rep cannot be a duration"); > static_assert(__is_ratio<_Period>::value, > "period must be a specialization of ratio"); > static_assert(_Period::num > 0, "period must be positive"); > > > constexpr duration() = default; > > > > > duration(const duration&) = default; > > template<typename _Rep2, typename = typename > enable_if<is_convertible<_Rep2, rep>::value > && (treat_as_floating_point<rep>::value > || !treat_as_floating_point<_Rep2>::value)>::type> > constexpr explicit duration(const _Rep2& __rep) > : __r(static_cast<rep>(__rep)) { } > > template<typename _Rep2, typename _Period2, typename = typename > enable_if<treat_as_floating_point<rep>::value > || (ratio_divide<_Period2, period>::den == 1 > && !treat_as_floating_point<_Rep2>::value)>::type> > constexpr duration(const duration<_Rep2, _Period2>& __d) > : __r(duration_cast<duration>(__d).count()) { } > > ~duration() = default; > duration& operator=(const duration&) = default; > > > constexpr rep > count() const > { return __r; } > > > constexpr duration > operator+() const > { return *this; } > > constexpr duration > operator-() const > { return duration(-__r); } > > duration& > operator++() > { > ++__r; > return *this; > } > > duration > operator++(int) > { return duration(__r++); } > > duration& > operator--() > { > --__r; > return *this; > } > > duration > operator--(int) > { return duration(__r--); } > > duration& > operator+=(const duration& __d) > { > __r += __d.count(); > return *this; > } > > duration& > operator-=(const duration& __d) > { > __r -= __d.count(); > return *this; > } > > duration& > operator*=(const rep& __rhs) > { > __r *= __rhs; > return *this; > } > > duration& > operator/=(const rep& __rhs) > { > __r /= __rhs; > return *this; > } > > > template<typename _Rep2 = rep> > typename enable_if<!treat_as_floating_point<_Rep2>::value, > duration&>::type > operator%=(const rep& __rhs) > { > __r %= __rhs; > return *this; > } > > template<typename _Rep2 = rep> > typename enable_if<!treat_as_floating_point<_Rep2>::value, > duration&>::type > operator%=(const duration& __d) > { > __r %= __d.count(); > return *this; > } > > > static constexpr duration > zero() > { return duration(duration_values<rep>::zero()); } > > static constexpr duration > min() > { return duration(duration_values<rep>::min()); } > > static constexpr duration > max() > { return duration(duration_values<rep>::max()); } > > private: > rep __r; > }; > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr typename common_type<duration<_Rep1, _Period1>, > duration<_Rep2, _Period2>>::type > operator+(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { > typedef duration<_Rep1, _Period1> __dur1; > typedef duration<_Rep2, _Period2> __dur2; > typedef typename common_type<__dur1,__dur2>::type __cd; > return __cd(__cd(__lhs).count() + __cd(__rhs).count()); > } > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr typename common_type<duration<_Rep1, _Period1>, > duration<_Rep2, _Period2>>::type > operator-(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { > typedef duration<_Rep1, _Period1> __dur1; > typedef duration<_Rep2, _Period2> __dur2; > typedef typename common_type<__dur1,__dur2>::type __cd; > return __cd(__cd(__lhs).count() - __cd(__rhs).count()); > } > > template<typename _Rep1, typename _Rep2, bool = > is_convertible<_Rep2, > typename common_type<_Rep1, _Rep2>::type>::value> > struct __common_rep_type { }; > > template<typename _Rep1, typename _Rep2> > struct __common_rep_type<_Rep1, _Rep2, true> > { typedef typename common_type<_Rep1, _Rep2>::type type; }; > > template<typename _Rep1, typename _Period, typename _Rep2> > constexpr > duration<typename __common_rep_type<_Rep1, _Rep2>::type, _Period> > operator*(const duration<_Rep1, _Period>& __d, const _Rep2& __s) > { > typedef duration<typename common_type<_Rep1, _Rep2>::type, _Period> > __cd; > return __cd(__cd(__d).count() * __s); > } > > template<typename _Rep1, typename _Rep2, typename _Period> > constexpr > duration<typename __common_rep_type<_Rep2, _Rep1>::type, _Period> > operator*(const _Rep1& __s, const duration<_Rep2, _Period>& __d) > { return __d * __s; } > > template<typename _Rep1, typename _Period, typename _Rep2> > constexpr duration<typename __common_rep_type<_Rep1, typename > enable_if<!__is_duration<_Rep2>::value, _Rep2>::type>::type, _Period> > operator/(const duration<_Rep1, _Period>& __d, const _Rep2& __s) > { > typedef duration<typename common_type<_Rep1, _Rep2>::type, _Period> > __cd; > return __cd(__cd(__d).count() / __s); > } > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr typename common_type<_Rep1, _Rep2>::type > operator/(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { > typedef duration<_Rep1, _Period1> __dur1; > typedef duration<_Rep2, _Period2> __dur2; > typedef typename common_type<__dur1,__dur2>::type __cd; > return __cd(__lhs).count() / __cd(__rhs).count(); > } > > > template<typename _Rep1, typename _Period, typename _Rep2> > constexpr duration<typename __common_rep_type<_Rep1, typename > enable_if<!__is_duration<_Rep2>::value, _Rep2>::type>::type, _Period> > operator%(const duration<_Rep1, _Period>& __d, const _Rep2& __s) > { > typedef duration<typename common_type<_Rep1, _Rep2>::type, _Period> > __cd; > return __cd(__cd(__d).count() % __s); > } > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr typename common_type<duration<_Rep1, _Period1>, > duration<_Rep2, _Period2>>::type > operator%(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { > typedef duration<_Rep1, _Period1> __dur1; > typedef duration<_Rep2, _Period2> __dur2; > typedef typename common_type<__dur1,__dur2>::type __cd; > return __cd(__cd(__lhs).count() % __cd(__rhs).count()); > } > > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr bool > operator==(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { > typedef duration<_Rep1, _Period1> __dur1; > typedef duration<_Rep2, _Period2> __dur2; > typedef typename common_type<__dur1,__dur2>::type __ct; > return __ct(__lhs).count() == __ct(__rhs).count(); > } > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr bool > operator<(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { > typedef duration<_Rep1, _Period1> __dur1; > typedef duration<_Rep2, _Period2> __dur2; > typedef typename common_type<__dur1,__dur2>::type __ct; > return __ct(__lhs).count() < __ct(__rhs).count(); > } > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr bool > operator!=(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { return !(__lhs == __rhs); } > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr bool > operator<=(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { return !(__rhs < __lhs); } > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr bool > operator>(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { return __rhs < __lhs; } > > template<typename _Rep1, typename _Period1, > typename _Rep2, typename _Period2> > constexpr bool > operator>=(const duration<_Rep1, _Period1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { return !(__lhs < __rhs); } > > > typedef duration<int64_t, nano> nanoseconds; > > > typedef duration<int64_t, micro> microseconds; > > > typedef duration<int64_t, milli> milliseconds; > > > typedef duration<int64_t> seconds; > > > typedef duration<int64_t, ratio< 60>> minutes; > > > typedef duration<int64_t, ratio<3600>> hours; > > > template<typename _Clock, typename _Dur> > struct time_point > { > typedef _Clock clock; > typedef _Dur duration; > typedef typename duration::rep rep; > typedef typename duration::period period; > > constexpr time_point() : __d(duration::zero()) > { } > > constexpr explicit time_point(const duration& __dur) > : __d(__dur) > { } > > > template<typename _Dur2> > constexpr time_point(const time_point<clock, _Dur2>& __t) > : __d(__t.time_since_epoch()) > { } > > > constexpr duration > time_since_epoch() const > { return __d; } > > > time_point& > operator+=(const duration& __dur) > { > __d += __dur; > return *this; > } > > time_point& > operator-=(const duration& __dur) > { > __d -= __dur; > return *this; > } > > > static constexpr time_point > min() > { return time_point(duration::min()); } > > static constexpr time_point > max() > { return time_point(duration::max()); } > > private: > duration __d; > }; > > > template<typename _ToDur, typename _Clock, typename _Dur> > constexpr typename enable_if<__is_duration<_ToDur>::value, > time_point<_Clock, _ToDur>>::type > time_point_cast(const time_point<_Clock, _Dur>& __t) > { > typedef time_point<_Clock, _ToDur> __time_point; > return __time_point(duration_cast<_ToDur>(__t.time_since_epoch())); > } > > template<typename _Clock, typename _Dur1, > typename _Rep2, typename _Period2> > constexpr time_point<_Clock, > typename common_type<_Dur1, duration<_Rep2, _Period2>>::type> > operator+(const time_point<_Clock, _Dur1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { > typedef duration<_Rep2, _Period2> __dur2; > typedef typename common_type<_Dur1,__dur2>::type __ct; > typedef time_point<_Clock, __ct> __time_point; > return __time_point(__lhs.time_since_epoch() + __rhs); > } > > template<typename _Rep1, typename _Period1, > typename _Clock, typename _Dur2> > constexpr time_point<_Clock, > typename common_type<duration<_Rep1, _Period1>, _Dur2>::type> > operator+(const duration<_Rep1, _Period1>& __lhs, > const time_point<_Clock, _Dur2>& __rhs) > { > typedef duration<_Rep1, _Period1> __dur1; > typedef typename common_type<__dur1,_Dur2>::type __ct; > typedef time_point<_Clock, __ct> __time_point; > return __time_point(__rhs.time_since_epoch() + __lhs); > } > > template<typename _Clock, typename _Dur1, > typename _Rep2, typename _Period2> > constexpr time_point<_Clock, > typename common_type<_Dur1, duration<_Rep2, _Period2>>::type> > operator-(const time_point<_Clock, _Dur1>& __lhs, > const duration<_Rep2, _Period2>& __rhs) > { > typedef duration<_Rep2, _Period2> __dur2; > typedef typename common_type<_Dur1,__dur2>::type __ct; > typedef time_point<_Clock, __ct> __time_point; > return __time_point(__lhs.time_since_epoch() -__rhs); > } > > template<typename _Clock, typename _Dur1, typename _Dur2> > constexpr typename common_type<_Dur1, _Dur2>::type > operator-(const time_point<_Clock, _Dur1>& __lhs, > const time_point<_Clock, _Dur2>& __rhs) > { return __lhs.time_since_epoch() - __rhs.time_since_epoch(); } > > template<typename _Clock, typename _Dur1, typename _Dur2> > constexpr bool > operator==(const time_point<_Clock, _Dur1>& __lhs, > const time_point<_Clock, _Dur2>& __rhs) > { return __lhs.time_since_epoch() == __rhs.time_since_epoch(); } > > template<typename _Clock, typename _Dur1, typename _Dur2> > constexpr bool > operator!=(const time_point<_Clock, _Dur1>& __lhs, > const time_point<_Clock, _Dur2>& __rhs) > { return !(__lhs == __rhs); } > > template<typename _Clock, typename _Dur1, typename _Dur2> > constexpr bool > operator<(const time_point<_Clock, _Dur1>& __lhs, > const time_point<_Clock, _Dur2>& __rhs) > { return __lhs.time_since_epoch() < __rhs.time_since_epoch(); } > > template<typename _Clock, typename _Dur1, typename _Dur2> > constexpr bool > operator<=(const time_point<_Clock, _Dur1>& __lhs, > const time_point<_Clock, _Dur2>& __rhs) > { return !(__rhs < __lhs); } > > template<typename _Clock, typename _Dur1, typename _Dur2> > constexpr bool > operator>(const time_point<_Clock, _Dur1>& __lhs, > const time_point<_Clock, _Dur2>& __rhs) > { return __rhs < __lhs; } > > template<typename _Clock, typename _Dur1, typename _Dur2> > constexpr bool > operator>=(const time_point<_Clock, _Dur1>& __lhs, > const time_point<_Clock, _Dur2>& __rhs) > { return !(__lhs < __rhs); } ># 709 "/usr/include/c++/4.9.0/chrono" 3 > inline namespace _V2 { > > > > > > > struct system_clock > { > typedef chrono::nanoseconds duration; > typedef duration::rep rep; > typedef duration::period period; > typedef chrono::time_point<system_clock, duration> time_point; > > static_assert(system_clock::duration::min() > < system_clock::duration::zero(), > "a clock's minimum duration cannot be less than its epoch"); > > static constexpr bool is_steady = false; > > static time_point > now() noexcept; > > > static std::time_t > to_time_t(const time_point& __t) noexcept > { > return std::time_t(duration_cast<chrono::seconds> > (__t.time_since_epoch()).count()); > } > > static time_point > from_time_t(std::time_t __t) noexcept > { > typedef chrono::time_point<system_clock, seconds> __from; > return time_point_cast<system_clock::duration> > (__from(chrono::seconds(__t))); > } > }; > > > > > > > > struct steady_clock > { > typedef chrono::nanoseconds duration; > typedef duration::rep rep; > typedef duration::period period; > typedef chrono::time_point<steady_clock, duration> time_point; > > static constexpr bool is_steady = true; > > static time_point > now() noexcept; > }; ># 776 "/usr/include/c++/4.9.0/chrono" 3 > using high_resolution_clock = system_clock; > > } > > > } ># 908 "/usr/include/c++/4.9.0/chrono" 3 >} ># 39 "/usr/include/c++/4.9.0/condition_variable" 2 3 ># 1 "/usr/include/c++/4.9.0/mutex" 1 3 ># 32 "/usr/include/c++/4.9.0/mutex" 3 ># 33 "/usr/include/c++/4.9.0/mutex" 3 ># 43 "/usr/include/c++/4.9.0/mutex" 3 ># 1 "/usr/include/c++/4.9.0/system_error" 1 3 ># 32 "/usr/include/c++/4.9.0/system_error" 3 ># 33 "/usr/include/c++/4.9.0/system_error" 3 > > > > > > ># 1 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/error_constants.h" 1 3 ># 34 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/error_constants.h" 3 ># 1 "/usr/include/c++/4.9.0/cerrno" 1 3 ># 39 "/usr/include/c++/4.9.0/cerrno" 3 ># 40 "/usr/include/c++/4.9.0/cerrno" 3 > ># 1 "/usr/include/errno.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/cerrno" 2 3 ># 35 "/usr/include/c++/4.9.0/x86_64-redhat-linux/bits/error_constants.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > enum class errc > { > address_family_not_supported = 97, > address_in_use = 98, > address_not_available = 99, > already_connected = 106, > argument_list_too_long = 7, > argument_out_of_domain = 33, > bad_address = 14, > bad_file_descriptor = 9, > > > bad_message = 74, > > > broken_pipe = 32, > connection_aborted = 103, > connection_already_in_progress = 114, > connection_refused = 111, > connection_reset = 104, > cross_device_link = 18, > destination_address_required = 89, > device_or_resource_busy = 16, > directory_not_empty = 39, > executable_format_error = 8, > file_exists = 17, > file_too_large = 27, > filename_too_long = 36, > function_not_supported = 38, > host_unreachable = 113, > > > identifier_removed = 43, > > > illegal_byte_sequence = 84, > inappropriate_io_control_operation = 25, > interrupted = 4, > invalid_argument = 22, > invalid_seek = 29, > io_error = 5, > is_a_directory = 21, > message_size = 90, > network_down = 100, > network_reset = 102, > network_unreachable = 101, > no_buffer_space = 105, > no_child_process = 10, > > > no_link = 67, > > > no_lock_available = 37, > > > no_message_available = 61, > > > no_message = 42, > no_protocol_option = 92, > no_space_on_device = 28, > > > no_stream_resources = 63, > > > no_such_device_or_address = 6, > no_such_device = 19, > no_such_file_or_directory = 2, > no_such_process = 3, > not_a_directory = 20, > not_a_socket = 88, > > > not_a_stream = 60, > > > not_connected = 107, > not_enough_memory = 12, > > > not_supported = 95, > > > > operation_canceled = 125, > > > operation_in_progress = 115, > operation_not_permitted = 1, > operation_not_supported = 95, > operation_would_block = 11, > > > owner_dead = 130, > > > permission_denied = 13, > > > protocol_error = 71, > > > protocol_not_supported = 93, > read_only_file_system = 30, > resource_deadlock_would_occur = 35, > resource_unavailable_try_again = 11, > result_out_of_range = 34, > > > state_not_recoverable = 131, > > > > stream_timeout = 62, > > > > text_file_busy = 26, > > > timed_out = 110, > too_many_files_open_in_system = 23, > too_many_files_open = 24, > too_many_links = 31, > too_many_symbolic_link_levels = 40, > > > value_too_large = 75, > > > wrong_protocol_type = 91 > }; > > >} ># 40 "/usr/include/c++/4.9.0/system_error" 2 3 > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > class error_code; > class error_condition; > class error_category; > class system_error; > > > template<typename _Tp> > struct is_error_code_enum : public false_type { }; > > > template<typename _Tp> > struct is_error_condition_enum : public false_type { }; > > template<> > struct is_error_condition_enum<errc> > : public true_type { }; > > > > class error_category > { > public: > > > > constexpr error_category() noexcept = default; > > > virtual ~error_category(); > > error_category(const error_category&) = delete; > error_category& operator=(const error_category&) = delete; > > virtual const char* > name() const noexcept = 0; > > virtual string > message(int) const = 0; > > virtual error_condition > default_error_condition(int __i) const noexcept; > > virtual bool > equivalent(int __i, const error_condition& __cond) const noexcept; > > virtual bool > equivalent(const error_code& __code, int __i) const noexcept; > > bool > operator<(const error_category& __other) const noexcept > { return less<const error_category*>()(this, &__other); } > > bool > operator==(const error_category& __other) const noexcept > { return this == &__other; } > > bool > operator!=(const error_category& __other) const noexcept > { return this != &__other; } > }; > > > __attribute__ ((__const__)) const error_category& system_category() noexcept; > __attribute__ ((__const__)) const error_category& generic_category() noexcept; > > error_code make_error_code(errc) noexcept; > > template<typename _Tp> > struct hash; > > > > struct error_code > { > error_code() noexcept > : _M_value(0), _M_cat(&system_category()) { } > > error_code(int __v, const error_category& __cat) noexcept > : _M_value(__v), _M_cat(&__cat) { } > > template<typename _ErrorCodeEnum, typename = typename > enable_if<is_error_code_enum<_ErrorCodeEnum>::value>::type> > error_code(_ErrorCodeEnum __e) noexcept > { *this = make_error_code(__e); } > > void > assign(int __v, const error_category& __cat) noexcept > { > _M_value = __v; > _M_cat = &__cat; > } > > void > clear() noexcept > { assign(0, system_category()); } > > > template<typename _ErrorCodeEnum> > typename enable_if<is_error_code_enum<_ErrorCodeEnum>::value, > error_code&>::type > operator=(_ErrorCodeEnum __e) noexcept > { return *this = make_error_code(__e); } > > int > value() const noexcept { return _M_value; } > > const error_category& > category() const noexcept { return *_M_cat; } > > error_condition > default_error_condition() const noexcept; > > string > message() const > { return category().message(value()); } > > explicit operator bool() const noexcept > { return _M_value != 0 ? true : false; } > > > private: > friend class hash<error_code>; > > int _M_value; > const error_category* _M_cat; > }; > > > inline error_code > make_error_code(errc __e) noexcept > { return error_code(static_cast<int>(__e), generic_category()); } > > inline bool > operator<(const error_code& __lhs, const error_code& __rhs) noexcept > { > return (__lhs.category() < __rhs.category() > || (__lhs.category() == __rhs.category() > && __lhs.value() < __rhs.value())); > } > > template<typename _CharT, typename _Traits> > basic_ostream<_CharT, _Traits>& > operator<<(basic_ostream<_CharT, _Traits>& __os, const error_code& __e) > { return (__os << __e.category().name() << ':' << __e.value()); } > > error_condition make_error_condition(errc) noexcept; > > > > struct error_condition > { > error_condition() noexcept > : _M_value(0), _M_cat(&generic_category()) { } > > error_condition(int __v, const error_category& __cat) noexcept > : _M_value(__v), _M_cat(&__cat) { } > > template<typename _ErrorConditionEnum, typename = typename > enable_if<is_error_condition_enum<_ErrorConditionEnum>::value>::type> > error_condition(_ErrorConditionEnum __e) noexcept > { *this = make_error_condition(__e); } > > void > assign(int __v, const error_category& __cat) noexcept > { > _M_value = __v; > _M_cat = &__cat; > } > > > template<typename _ErrorConditionEnum> > typename enable_if<is_error_condition_enum > <_ErrorConditionEnum>::value, error_condition&>::type > operator=(_ErrorConditionEnum __e) noexcept > { return *this = make_error_condition(__e); } > > void > clear() noexcept > { assign(0, generic_category()); } > > > int > value() const noexcept { return _M_value; } > > const error_category& > category() const noexcept { return *_M_cat; } > > string > message() const > { return category().message(value()); } > > explicit operator bool() const noexcept > { return _M_value != 0 ? true : false; } > > > private: > int _M_value; > const error_category* _M_cat; > }; > > > inline error_condition > make_error_condition(errc __e) noexcept > { return error_condition(static_cast<int>(__e), generic_category()); } > > inline bool > operator<(const error_condition& __lhs, > const error_condition& __rhs) noexcept > { > return (__lhs.category() < __rhs.category() > || (__lhs.category() == __rhs.category() > && __lhs.value() < __rhs.value())); > } > > > inline bool > operator==(const error_code& __lhs, const error_code& __rhs) noexcept > { return (__lhs.category() == __rhs.category() > && __lhs.value() == __rhs.value()); } > > inline bool > operator==(const error_code& __lhs, const error_condition& __rhs) noexcept > { > return (__lhs.category().equivalent(__lhs.value(), __rhs) > || __rhs.category().equivalent(__lhs, __rhs.value())); > } > > inline bool > operator==(const error_condition& __lhs, const error_code& __rhs) noexcept > { > return (__rhs.category().equivalent(__rhs.value(), __lhs) > || __lhs.category().equivalent(__rhs, __lhs.value())); > } > > inline bool > operator==(const error_condition& __lhs, > const error_condition& __rhs) noexcept > { > return (__lhs.category() == __rhs.category() > && __lhs.value() == __rhs.value()); > } > > inline bool > operator!=(const error_code& __lhs, const error_code& __rhs) noexcept > { return !(__lhs == __rhs); } > > inline bool > operator!=(const error_code& __lhs, const error_condition& __rhs) noexcept > { return !(__lhs == __rhs); } > > inline bool > operator!=(const error_condition& __lhs, const error_code& __rhs) noexcept > { return !(__lhs == __rhs); } > > inline bool > operator!=(const error_condition& __lhs, > const error_condition& __rhs) noexcept > { return !(__lhs == __rhs); } > > > > > > > > class system_error : public std::runtime_error > { > private: > error_code _M_code; > > public: > system_error(error_code __ec = error_code()) > : runtime_error(__ec.message()), _M_code(__ec) { } > > system_error(error_code __ec, const string& __what) > : runtime_error(__what + ": " + __ec.message()), _M_code(__ec) { } ># 335 "/usr/include/c++/4.9.0/system_error" 3 > system_error(int __v, const error_category& __ecat) > : runtime_error(error_code(__v, __ecat).message()), > _M_code(__v, __ecat) { } > > system_error(int __v, const error_category& __ecat, const string& __what) > : runtime_error(__what + ": " + error_code(__v, __ecat).message()), > _M_code(__v, __ecat) { } > > virtual ~system_error() noexcept; > > const error_code& > code() const noexcept { return _M_code; } > }; > > >} > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > template<> > struct hash<error_code> > : public __hash_base<size_t, error_code> > { > size_t > operator()(const error_code& __e) const noexcept > { > const size_t __tmp = std::_Hash_impl::hash(__e._M_value); > return std::_Hash_impl::__hash_combine(__e._M_cat, __tmp); > } > }; > > >} ># 44 "/usr/include/c++/4.9.0/mutex" 2 3 > > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > class __mutex_base > { > protected: > typedef __gthread_mutex_t __native_type; > > > __native_type _M_mutex = { { 0, 0, 0, 0, 0, 0, 0, { 0, 0 } } }; > > constexpr __mutex_base() noexcept = default; ># 77 "/usr/include/c++/4.9.0/mutex" 3 > __mutex_base(const __mutex_base&) = delete; > __mutex_base& operator=(const __mutex_base&) = delete; > }; > > > class __recursive_mutex_base > { > protected: > typedef __gthread_recursive_mutex_t __native_type; > > __recursive_mutex_base(const __recursive_mutex_base&) = delete; > __recursive_mutex_base& operator=(const __recursive_mutex_base&) = delete; > > > __native_type _M_mutex = { { 0, 0, 0, 0, PTHREAD_MUTEX_RECURSIVE_NP, 0, 0, { 0, 0 } } }; > > __recursive_mutex_base() = default; ># 106 "/usr/include/c++/4.9.0/mutex" 3 > }; ># 117 "/usr/include/c++/4.9.0/mutex" 3 > class mutex : private __mutex_base > { > public: > typedef __native_type* native_handle_type; > > > constexpr > > mutex() noexcept = default; > ~mutex() = default; > > mutex(const mutex&) = delete; > mutex& operator=(const mutex&) = delete; > > void > lock() > { > int __e = __gthread_mutex_lock(&_M_mutex); > > > if (__e) > __throw_system_error(__e); > } > > bool > try_lock() noexcept > { > > return !__gthread_mutex_trylock(&_M_mutex); > } > > void > unlock() > { > > __gthread_mutex_unlock(&_M_mutex); > } > > native_handle_type > native_handle() > { return &_M_mutex; } > }; > > > class recursive_mutex : private __recursive_mutex_base > { > public: > typedef __native_type* native_handle_type; > > recursive_mutex() = default; > ~recursive_mutex() = default; > > recursive_mutex(const recursive_mutex&) = delete; > recursive_mutex& operator=(const recursive_mutex&) = delete; > > void > lock() > { > int __e = __gthread_recursive_mutex_lock(&_M_mutex); > > > if (__e) > __throw_system_error(__e); > } > > bool > try_lock() noexcept > { > > return !__gthread_recursive_mutex_trylock(&_M_mutex); > } > > void > unlock() > { > > __gthread_recursive_mutex_unlock(&_M_mutex); > } > > native_handle_type > native_handle() > { return &_M_mutex; } > }; > > > template<typename _Derived> > class __timed_mutex_impl > { > protected: > typedef chrono::high_resolution_clock __clock_t; > > template<typename _Rep, typename _Period> > bool > _M_try_lock_for(const chrono::duration<_Rep, _Period>& __rtime) > { > using chrono::steady_clock; > auto __rt = chrono::duration_cast<steady_clock::duration>(__rtime); > if (ratio_greater<steady_clock::period, _Period>()) > ++__rt; > return _M_try_lock_until(steady_clock::now() + __rt); > } > > template<typename _Duration> > bool > _M_try_lock_until(const chrono::time_point<__clock_t, > _Duration>& __atime) > { > auto __s = chrono::time_point_cast<chrono::seconds>(__atime); > auto __ns = chrono::duration_cast<chrono::nanoseconds>(__atime - __s); > > __gthread_time_t __ts = { > static_cast<std::time_t>(__s.time_since_epoch().count()), > static_cast<long>(__ns.count()) > }; > > auto __mutex = static_cast<_Derived*>(this)->native_handle(); > return !__gthread_mutex_timedlock(__mutex, &__ts); > } > > template<typename _Clock, typename _Duration> > bool > _M_try_lock_until(const chrono::time_point<_Clock, _Duration>& __atime) > { > auto __rtime = __atime - _Clock::now(); > return _M_try_lock_until(__clock_t::now() + __rtime); > } > }; > > > class timed_mutex > : private __mutex_base, public __timed_mutex_impl<timed_mutex> > { > public: > typedef __native_type* native_handle_type; > > timed_mutex() = default; > ~timed_mutex() = default; > > timed_mutex(const timed_mutex&) = delete; > timed_mutex& operator=(const timed_mutex&) = delete; > > void > lock() > { > int __e = __gthread_mutex_lock(&_M_mutex); > > > if (__e) > __throw_system_error(__e); > } > > bool > try_lock() noexcept > { > > return !__gthread_mutex_trylock(&_M_mutex); > } > > template <class _Rep, class _Period> > bool > try_lock_for(const chrono::duration<_Rep, _Period>& __rtime) > { return _M_try_lock_for(__rtime); } > > template <class _Clock, class _Duration> > bool > try_lock_until(const chrono::time_point<_Clock, _Duration>& __atime) > { return _M_try_lock_until(__atime); } > > void > unlock() > { > > __gthread_mutex_unlock(&_M_mutex); > } > > native_handle_type > native_handle() > { return &_M_mutex; } > }; > > > class recursive_timed_mutex > : private __recursive_mutex_base, > public __timed_mutex_impl<recursive_timed_mutex> > { > public: > typedef __native_type* native_handle_type; > > recursive_timed_mutex() = default; > ~recursive_timed_mutex() = default; > > recursive_timed_mutex(const recursive_timed_mutex&) = delete; > recursive_timed_mutex& operator=(const recursive_timed_mutex&) = delete; > > void > lock() > { > int __e = __gthread_recursive_mutex_lock(&_M_mutex); > > > if (__e) > __throw_system_error(__e); > } > > bool > try_lock() noexcept > { > > return !__gthread_recursive_mutex_trylock(&_M_mutex); > } > > template <class _Rep, class _Period> > bool > try_lock_for(const chrono::duration<_Rep, _Period>& __rtime) > { return _M_try_lock_for(__rtime); } > > template <class _Clock, class _Duration> > bool > try_lock_until(const chrono::time_point<_Clock, _Duration>& __atime) > { return _M_try_lock_until(__atime); } > > void > unlock() > { > > __gthread_recursive_mutex_unlock(&_M_mutex); > } > > native_handle_type > native_handle() > { return &_M_mutex; } > }; > > > > > struct defer_lock_t { }; > > > struct try_to_lock_t { }; > > > > struct adopt_lock_t { }; > > constexpr defer_lock_t defer_lock { }; > constexpr try_to_lock_t try_to_lock { }; > constexpr adopt_lock_t adopt_lock { }; > > > > > template<typename _Mutex> > class lock_guard > { > public: > typedef _Mutex mutex_type; > > explicit lock_guard(mutex_type& __m) : _M_device(__m) > { _M_device.lock(); } > > lock_guard(mutex_type& __m, adopt_lock_t) : _M_device(__m) > { } > > ~lock_guard() > { _M_device.unlock(); } > > lock_guard(const lock_guard&) = delete; > lock_guard& operator=(const lock_guard&) = delete; > > private: > mutex_type& _M_device; > }; > > > template<typename _Mutex> > class unique_lock > { > public: > typedef _Mutex mutex_type; > > unique_lock() noexcept > : _M_device(0), _M_owns(false) > { } > > explicit unique_lock(mutex_type& __m) > : _M_device(&__m), _M_owns(false) > { > lock(); > _M_owns = true; > } > > unique_lock(mutex_type& __m, defer_lock_t) noexcept > : _M_device(&__m), _M_owns(false) > { } > > unique_lock(mutex_type& __m, try_to_lock_t) > : _M_device(&__m), _M_owns(_M_device->try_lock()) > { } > > unique_lock(mutex_type& __m, adopt_lock_t) > : _M_device(&__m), _M_owns(true) > { > > } > > template<typename _Clock, typename _Duration> > unique_lock(mutex_type& __m, > const chrono::time_point<_Clock, _Duration>& __atime) > : _M_device(&__m), _M_owns(_M_device->try_lock_until(__atime)) > { } > > template<typename _Rep, typename _Period> > unique_lock(mutex_type& __m, > const chrono::duration<_Rep, _Period>& __rtime) > : _M_device(&__m), _M_owns(_M_device->try_lock_for(__rtime)) > { } > > ~unique_lock() > { > if (_M_owns) > unlock(); > } > > unique_lock(const unique_lock&) = delete; > unique_lock& operator=(const unique_lock&) = delete; > > unique_lock(unique_lock&& __u) noexcept > : _M_device(__u._M_device), _M_owns(__u._M_owns) > { > __u._M_device = 0; > __u._M_owns = false; > } > > unique_lock& operator=(unique_lock&& __u) noexcept > { > if(_M_owns) > unlock(); > > unique_lock(std::move(__u)).swap(*this); > > __u._M_device = 0; > __u._M_owns = false; > > return *this; > } > > void > lock() > { > if (!_M_device) > __throw_system_error(int(errc::operation_not_permitted)); > else if (_M_owns) > __throw_system_error(int(errc::resource_deadlock_would_occur)); > else > { > _M_device->lock(); > _M_owns = true; > } > } > > bool > try_lock() > { > if (!_M_device) > __throw_system_error(int(errc::operation_not_permitted)); > else if (_M_owns) > __throw_system_error(int(errc::resource_deadlock_would_occur)); > else > { > _M_owns = _M_device->try_lock(); > return _M_owns; > } > } > > template<typename _Clock, typename _Duration> > bool > try_lock_until(const chrono::time_point<_Clock, _Duration>& __atime) > { > if (!_M_device) > __throw_system_error(int(errc::operation_not_permitted)); > else if (_M_owns) > __throw_system_error(int(errc::resource_deadlock_would_occur)); > else > { > _M_owns = _M_device->try_lock_until(__atime); > return _M_owns; > } > } > > template<typename _Rep, typename _Period> > bool > try_lock_for(const chrono::duration<_Rep, _Period>& __rtime) > { > if (!_M_device) > __throw_system_error(int(errc::operation_not_permitted)); > else if (_M_owns) > __throw_system_error(int(errc::resource_deadlock_would_occur)); > else > { > _M_owns = _M_device->try_lock_for(__rtime); > return _M_owns; > } > } > > void > unlock() > { > if (!_M_owns) > __throw_system_error(int(errc::operation_not_permitted)); > else if (_M_device) > { > _M_device->unlock(); > _M_owns = false; > } > } > > void > swap(unique_lock& __u) noexcept > { > std::swap(_M_device, __u._M_device); > std::swap(_M_owns, __u._M_owns); > } > > mutex_type* > release() noexcept > { > mutex_type* __ret = _M_device; > _M_device = 0; > _M_owns = false; > return __ret; > } > > bool > owns_lock() const noexcept > { return _M_owns; } > > explicit operator bool() const noexcept > { return owns_lock(); } > > mutex_type* > mutex() const noexcept > { return _M_device; } > > private: > mutex_type* _M_device; > bool _M_owns; > }; > > > template<typename _Mutex> > inline void > swap(unique_lock<_Mutex>& __x, unique_lock<_Mutex>& __y) noexcept > { __x.swap(__y); } > > template<int _Idx> > struct __unlock_impl > { > template<typename... _Lock> > static void > __do_unlock(tuple<_Lock&...>& __locks) > { > std::get<_Idx>(__locks).unlock(); > __unlock_impl<_Idx - 1>::__do_unlock(__locks); > } > }; > > template<> > struct __unlock_impl<-1> > { > template<typename... _Lock> > static void > __do_unlock(tuple<_Lock&...>&) > { } > }; > > template<typename _Lock> > unique_lock<_Lock> > __try_to_lock(_Lock& __l) > { return unique_lock<_Lock>(__l, try_to_lock); } > > template<int _Idx, bool _Continue = true> > struct __try_lock_impl > { > template<typename... _Lock> > static void > __do_try_lock(tuple<_Lock&...>& __locks, int& __idx) > { > __idx = _Idx; > auto __lock = __try_to_lock(std::get<_Idx>(__locks)); > if (__lock.owns_lock()) > { > __try_lock_impl<_Idx + 1, _Idx + 2 < sizeof...(_Lock)>:: > __do_try_lock(__locks, __idx); > if (__idx == -1) > __lock.release(); > } > } > }; > > template<int _Idx> > struct __try_lock_impl<_Idx, false> > { > template<typename... _Lock> > static void > __do_try_lock(tuple<_Lock&...>& __locks, int& __idx) > { > __idx = _Idx; > auto __lock = __try_to_lock(std::get<_Idx>(__locks)); > if (__lock.owns_lock()) > { > __idx = -1; > __lock.release(); > } > } > }; ># 644 "/usr/include/c++/4.9.0/mutex" 3 > template<typename _Lock1, typename _Lock2, typename... _Lock3> > int > try_lock(_Lock1& __l1, _Lock2& __l2, _Lock3&... __l3) > { > int __idx; > auto __locks = std::tie(__l1, __l2, __l3...); > try > { __try_lock_impl<0>::__do_try_lock(__locks, __idx); } > catch(...) > { } > return __idx; > } ># 668 "/usr/include/c++/4.9.0/mutex" 3 > template<typename _L1, typename _L2, typename ..._L3> > void > lock(_L1& __l1, _L2& __l2, _L3&... __l3) > { > while (true) > { > unique_lock<_L1> __first(__l1); > int __idx; > auto __locks = std::tie(__l2, __l3...); > __try_lock_impl<0, sizeof...(_L3)>::__do_try_lock(__locks, __idx); > if (__idx == -1) > { > __first.release(); > return; > } > } > } > > > > struct once_flag > { > private: > typedef __gthread_once_t __native_type; > __native_type _M_once = 0; > > public: > > constexpr once_flag() noexcept = default; > > > once_flag(const once_flag&) = delete; > > once_flag& operator=(const once_flag&) = delete; > > template<typename _Callable, typename... _Args> > friend void > call_once(once_flag& __once, _Callable&& __f, _Args&&... __args); > }; > > > extern __thread void* __once_callable; > extern __thread void (*__once_call)(); > > template<typename _Callable> > inline void > __once_call_impl() > { > (*(_Callable*)__once_callable)(); > } ># 728 "/usr/include/c++/4.9.0/mutex" 3 > extern "C" void __once_proxy(void); > > > template<typename _Callable, typename... _Args> > void > call_once(once_flag& __once, _Callable&& __f, _Args&&... __args) > { > > auto __bound_functor = std::__bind_simple(std::forward<_Callable>(__f), > std::forward<_Args>(__args)...); > __once_callable = &__bound_functor; > __once_call = &__once_call_impl<decltype(__bound_functor)>; ># 748 "/usr/include/c++/4.9.0/mutex" 3 > int __e = __gthread_once(&__once._M_once, &__once_proxy); > > > > > > > if (__e) > __throw_system_error(__e); > } > > > > >} ># 40 "/usr/include/c++/4.9.0/condition_variable" 2 3 ># 48 "/usr/include/c++/4.9.0/condition_variable" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 61 "/usr/include/c++/4.9.0/condition_variable" 3 > enum class cv_status { no_timeout, timeout }; > > > class condition_variable > { > typedef chrono::system_clock __clock_t; > typedef __gthread_cond_t __native_type; > > > __native_type _M_cond = { { 0, 0, 0, 0, 0, (void *) 0, 0, 0 } }; > > > > > public: > typedef __native_type* native_handle_type; > > condition_variable() noexcept; > ~condition_variable() noexcept; > > condition_variable(const condition_variable&) = delete; > condition_variable& operator=(const condition_variable&) = delete; > > void > notify_one() noexcept; > > void > notify_all() noexcept; > > void > wait(unique_lock<mutex>& __lock); > > template<typename _Predicate> > void > wait(unique_lock<mutex>& __lock, _Predicate __p) > { > while (!__p()) > wait(__lock); > } > > template<typename _Duration> > cv_status > wait_until(unique_lock<mutex>& __lock, > const chrono::time_point<__clock_t, _Duration>& __atime) > { return __wait_until_impl(__lock, __atime); } > > template<typename _Clock, typename _Duration> > cv_status > wait_until(unique_lock<mutex>& __lock, > const chrono::time_point<_Clock, _Duration>& __atime) > { > > const typename _Clock::time_point __c_entry = _Clock::now(); > const __clock_t::time_point __s_entry = __clock_t::now(); > const auto __delta = __atime - __c_entry; > const auto __s_atime = __s_entry + __delta; > > return __wait_until_impl(__lock, __s_atime); > } > > template<typename _Clock, typename _Duration, typename _Predicate> > bool > wait_until(unique_lock<mutex>& __lock, > const chrono::time_point<_Clock, _Duration>& __atime, > _Predicate __p) > { > while (!__p()) > if (wait_until(__lock, __atime) == cv_status::timeout) > return __p(); > return true; > } > > template<typename _Rep, typename _Period> > cv_status > wait_for(unique_lock<mutex>& __lock, > const chrono::duration<_Rep, _Period>& __rtime) > { return wait_until(__lock, __clock_t::now() + __rtime); } > > template<typename _Rep, typename _Period, typename _Predicate> > bool > wait_for(unique_lock<mutex>& __lock, > const chrono::duration<_Rep, _Period>& __rtime, > _Predicate __p) > { return wait_until(__lock, __clock_t::now() + __rtime, std::move(__p)); } > > native_handle_type > native_handle() > { return &_M_cond; } > > private: > template<typename _Dur> > cv_status > __wait_until_impl(unique_lock<mutex>& __lock, > const chrono::time_point<__clock_t, _Dur>& __atime) > { > auto __s = chrono::time_point_cast<chrono::seconds>(__atime); > auto __ns = chrono::duration_cast<chrono::nanoseconds>(__atime - __s); > > __gthread_time_t __ts = > { > static_cast<std::time_t>(__s.time_since_epoch().count()), > static_cast<long>(__ns.count()) > }; > > __gthread_cond_timedwait(&_M_cond, __lock.mutex()->native_handle(), > &__ts); > > return (__clock_t::now() < __atime > ? cv_status::no_timeout : cv_status::timeout); > } > }; > > inline namespace _V2 { > > > > class condition_variable_any > { > typedef chrono::system_clock __clock_t; > condition_variable _M_cond; > shared_ptr<mutex> _M_mutex; > > > template<typename _Lock> > struct _Unlock > { > explicit _Unlock(_Lock& __lk) : _M_lock(__lk) { __lk.unlock(); } > > ~_Unlock() noexcept(false) > { > if (uncaught_exception()) > try { _M_lock.lock(); } catch(...) { } > else > _M_lock.lock(); > } > > _Unlock(const _Unlock&) = delete; > _Unlock& operator=(const _Unlock&) = delete; > > _Lock& _M_lock; > }; > > public: > condition_variable_any() : _M_mutex(std::make_shared<mutex>()) { } > ~condition_variable_any() = default; > > condition_variable_any(const condition_variable_any&) = delete; > condition_variable_any& operator=(const condition_variable_any&) = delete; > > void > notify_one() noexcept > { > lock_guard<mutex> __lock(*_M_mutex); > _M_cond.notify_one(); > } > > void > notify_all() noexcept > { > lock_guard<mutex> __lock(*_M_mutex); > _M_cond.notify_all(); > } > > template<typename _Lock> > void > wait(_Lock& __lock) > { > shared_ptr<mutex> __mutex = _M_mutex; > unique_lock<mutex> __my_lock(*__mutex); > _Unlock<_Lock> __unlock(__lock); > > > unique_lock<mutex> __my_lock2(std::move(__my_lock)); > _M_cond.wait(__my_lock2); > } > > > template<typename _Lock, typename _Predicate> > void > wait(_Lock& __lock, _Predicate __p) > { > while (!__p()) > wait(__lock); > } > > template<typename _Lock, typename _Clock, typename _Duration> > cv_status > wait_until(_Lock& __lock, > const chrono::time_point<_Clock, _Duration>& __atime) > { > shared_ptr<mutex> __mutex = _M_mutex; > unique_lock<mutex> __my_lock(*__mutex); > _Unlock<_Lock> __unlock(__lock); > > > unique_lock<mutex> __my_lock2(std::move(__my_lock)); > return _M_cond.wait_until(__my_lock2, __atime); > } > > template<typename _Lock, typename _Clock, > typename _Duration, typename _Predicate> > bool > wait_until(_Lock& __lock, > const chrono::time_point<_Clock, _Duration>& __atime, > _Predicate __p) > { > while (!__p()) > if (wait_until(__lock, __atime) == cv_status::timeout) > return __p(); > return true; > } > > template<typename _Lock, typename _Rep, typename _Period> > cv_status > wait_for(_Lock& __lock, const chrono::duration<_Rep, _Period>& __rtime) > { return wait_until(__lock, __clock_t::now() + __rtime); } > > template<typename _Lock, typename _Rep, > typename _Period, typename _Predicate> > bool > wait_for(_Lock& __lock, > const chrono::duration<_Rep, _Period>& __rtime, _Predicate __p) > { return wait_until(__lock, __clock_t::now() + __rtime, std::move(__p)); } > }; > > } > > > >} ># 34 "/c/honeypenny/contrib/epee/include/syncobj.h" 2 > > > > > >namespace epee >{ > > struct simple_event > { > simple_event() : m_rised(false) > { > } > > void raise() > { > std::unique_lock<std::mutex> lock(m_mx); > m_rised = true; > m_cond_var.notify_one(); > } > > void wait() > { > std::unique_lock<std::mutex> lock(m_mx); > while (!m_rised) > m_cond_var.wait(lock); > m_rised = false; > } > > private: > std::mutex m_mx; > std::condition_variable m_cond_var; > bool m_rised; > }; > > class critical_region; > > class critical_section > { > boost::recursive_mutex m_section; > > public: > > critical_section(const critical_section& section) > { > } > > critical_section() > { > } > > ~critical_section() > { > } > > void lock() > { > m_section.lock(); > > } > > void unlock() > { > m_section.unlock(); > } > > bool tryLock() > { > return m_section.try_lock(); > } > > > critical_section& operator=(const critical_section& section) > { > return *this; > } > }; > > > template<class t_lock> > class critical_region_t > { > t_lock& m_locker; > bool m_unlocked; > > critical_region_t(const critical_region_t&) {} > > public: > critical_region_t(t_lock& cs): m_locker(cs), m_unlocked(false) > { > m_locker.lock(); > } > > ~critical_region_t() > { > unlock(); > } > > void unlock() > { > if (!m_unlocked) > { > m_locker.unlock(); > m_unlocked = true; > } > } > }; ># 241 "/c/honeypenny/contrib/epee/include/syncobj.h" >} ># 59 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 79 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" ># 1 "/usr/include/assert.h" 1 3 4 ># 80 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 2 ># 88 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" >namespace epee >{ >namespace debug >{ > inline bool get_set_enable_assert(bool set = false, bool v = false) > { > static bool e = true; > if(set) > e = v; > return e; > } >} >namespace log_space >{ > class logger; > class log_message; > class log_singletone; > > > > > enum console_colors > { > console_color_default, > console_color_white, > console_color_red, > console_color_green, > console_color_blue, > console_color_cyan, > console_color_magenta, > console_color_yellow > }; > > > struct ibase_log_stream > { > ibase_log_stream(){} > virtual ~ibase_log_stream(){} > virtual bool out_buffer( const char* buffer, int buffer_len , int log_level, int color, const char* plog_name = __null)=0; > virtual int get_type(){return 0;} > > virtual bool set_max_logfile_size(uint64_t max_size){return true;}; > virtual bool set_log_rotate_cmd(const std::string& cmd){return true;}; > }; ># 171 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > struct delete_ptr > { > template <class P> > void operator() (P p) > { > delete p.first; > } > }; ># 203 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > inline bool is_stdout_a_tty() > { > static std::atomic<bool> initialized(false); > static std::atomic<bool> is_a_tty(false); > > if (!initialized.load(std::memory_order_acquire)) > { > > > > is_a_tty.store(0 != isatty(fileno(stdout)), std::memory_order_relaxed); > > initialized.store(true, std::memory_order_release); > } > > return is_a_tty.load(std::memory_order_relaxed); > } > > inline void set_console_color(int color, bool bright) > { > if (!is_stdout_a_tty()) > return; > > switch(color) > { > case console_color_default: > { > > > > > if(bright) > std::cout << "\033[1;37m"; > else > std::cout << "\033[0m"; > > } > break; > case console_color_white: > { > > > > > if(bright) > std::cout << "\033[1;37m"; > else > std::cout << "\033[0;37m"; > > } > break; > case console_color_red: > { > > > > > if(bright) > std::cout << "\033[1;31m"; > else > std::cout << "\033[0;31m"; > > } > break; > case console_color_green: > { > > > > > if(bright) > std::cout << "\033[1;32m"; > else > std::cout << "\033[0;32m"; > > } > break; > > case console_color_blue: > { > > > > > if(bright) > std::cout << "\033[1;34m"; > else > std::cout << "\033[0;34m"; > > } > break; > > case console_color_cyan: > { > > > > > if(bright) > std::cout << "\033[1;36m"; > else > std::cout << "\033[0;36m"; > > } > break; > > case console_color_magenta: > { > > > > > if(bright) > std::cout << "\033[1;35m"; > else > std::cout << "\033[0;35m"; > > } > break; > > case console_color_yellow: > { > > > > > if(bright) > std::cout << "\033[1;33m"; > else > std::cout << "\033[0;33m"; > > } > break; > > } > } > > inline void reset_console_color() { > if (!is_stdout_a_tty()) > return; > > > > > > std::cout << "\033[0m"; > std::cout.flush(); > > } > > class console_output_stream: public ibase_log_stream > { > > > > > public: > console_output_stream() > { ># 371 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > } > > ~console_output_stream() > { > > > > > } > int get_type(){return 3;} > > > > virtual bool out_buffer( const char* buffer, int buffer_len , int log_level, int color, const char* plog_name = __null) > { > if(plog_name) > return true; > > set_console_color(color, log_level < 1); ># 419 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > std::string buf(buffer, buffer_len); > for(size_t i = 0; i!= buf.size(); i++) > { > if(buf[i] == 7 || buf[i] == -107) > buf[i] = '^'; > } > > std::cout << buf; > > reset_console_color(); > return true; > } > > > }; > > inline bool rotate_log_file(const char* pfile_path) > { ># 449 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > return false; > > return true; > } > > > > > > class file_output_stream : public ibase_log_stream > { > public: > typedef std::map<std::string, std::ofstream*> named_log_streams; > > file_output_stream( std::string default_log_file_name, std::string log_path ) > { > m_default_log_filename = default_log_file_name; > m_max_logfile_size = 0; > m_default_log_path = log_path; > m_pdefault_file_stream = add_new_stream_and_open(default_log_file_name.c_str()); > } > > ~file_output_stream() > { > for(named_log_streams::iterator it = m_log_file_names.begin(); it!=m_log_file_names.end(); it++) > { > if ( it->second->is_open() ) > { > it->second->flush(); > it->second->close(); > } > delete it->second; > } > } > private: > named_log_streams m_log_file_names; > std::string m_default_log_path; > std::ofstream* m_pdefault_file_stream; > std::string m_log_rotate_cmd; > std::string m_default_log_filename; > uint64_t m_max_logfile_size; > > > std::ofstream* add_new_stream_and_open(const char* pstream_name) > { > > > std::ofstream* pstream = (m_log_file_names[pstream_name] = new std::ofstream); > std::string target_path = m_default_log_path + "/" + pstream_name; > pstream->open( target_path.c_str(), std::ios_base::out | std::ios::app ); > if(pstream->fail()) > return __null; > return pstream; > } > > bool set_max_logfile_size(uint64_t max_size) > { > m_max_logfile_size = max_size; > return true; > } > > bool set_log_rotate_cmd(const std::string& cmd) > { > m_log_rotate_cmd = cmd; > return true; > } > > > > virtual bool out_buffer( const char* buffer, int buffer_len, int log_level, int color, const char* plog_name = __null ) > { > std::ofstream* m_target_file_stream = m_pdefault_file_stream; > if(plog_name) > { > named_log_streams::iterator it = m_log_file_names.find(plog_name); > if(it == m_log_file_names.end()) > m_target_file_stream = add_new_stream_and_open(plog_name); > else > m_target_file_stream = it->second; > } > if(!m_target_file_stream || !m_target_file_stream->is_open()) > return false; > > m_target_file_stream->write(buffer, buffer_len ); > m_target_file_stream->flush(); > > if(m_max_logfile_size) > { > std::ofstream::pos_type pt = m_target_file_stream->tellp(); > uint64_t current_sz = pt; > if(current_sz > m_max_logfile_size) > { > std::cout << "current_sz= " << current_sz << " m_max_logfile_size= " << m_max_logfile_size << std::endl; > std::string log_file_name; > if(!plog_name) > log_file_name = m_default_log_filename; > else > log_file_name = plog_name; > > m_target_file_stream->close(); > std::string new_log_file_name = log_file_name; > > time_t tm = 0; > time(&tm); > > int err_count = 0; > boost::system::error_code ec; > do > { > new_log_file_name = string_tools::cut_off_extension(log_file_name); > if(err_count) > new_log_file_name += misc_utils::get_time_str_v2(tm) + "(" + boost::lexical_cast<std::string>(err_count) + ")" + ".log"; > else > new_log_file_name += misc_utils::get_time_str_v2(tm) + ".log"; > > err_count++; > }while(boost::filesystem::exists(m_default_log_path + "/" + new_log_file_name, ec)); > > std::string new_log_file_path = m_default_log_path + "/" + new_log_file_name; > boost::filesystem::rename(m_default_log_path + "/" + log_file_name, new_log_file_path, ec); > if(ec) > { > std::cout << "Filed to rename, ec = " << ec.message() << std::endl; > } > > if(m_log_rotate_cmd.size()) > { > > std::string m_log_rotate_cmd_local_copy = m_log_rotate_cmd; > > boost::replace_all(m_log_rotate_cmd_local_copy, "[*TARGET*]", new_log_file_path); > > misc_utils::call_sys_cmd(m_log_rotate_cmd_local_copy); > } > > m_target_file_stream->open( (m_default_log_path + "/" + log_file_name).c_str(), std::ios_base::out | std::ios::app ); > if(m_target_file_stream->fail()) > return false; > } > } > > return true; > } > int get_type(){return 1;} > }; > > > > class log_stream_splitter > { > public: > typedef std::list<std::pair<ibase_log_stream*, int> > streams_container; > > log_stream_splitter(){} > ~log_stream_splitter() > { > > std::for_each(m_log_streams.begin(), m_log_streams.end(), delete_ptr()); > } > > bool set_max_logfile_size(uint64_t max_size) > { > for(streams_container::iterator it = m_log_streams.begin(); it!=m_log_streams.end();it++) > it->first->set_max_logfile_size(max_size); > return true; > } > > bool set_log_rotate_cmd(const std::string& cmd) > { > for(streams_container::iterator it = m_log_streams.begin(); it!=m_log_streams.end();it++) > it->first->set_log_rotate_cmd(cmd); > return true; > } > > bool do_log_message(const std::string& rlog_mes, int log_level, int color, const char* plog_name = __null) > { > std::string str_mess = rlog_mes; > size_t str_len = str_mess.size(); > const char* pstr = str_mess.c_str(); > for(streams_container::iterator it = m_log_streams.begin(); it!=m_log_streams.end();it++) > if(it->second >= log_level) > it->first->out_buffer(pstr, (int)str_len, log_level, color, plog_name); > return true; > } > > bool add_logger( int type, const char* pdefault_file_name, const char* pdefault_log_folder, int log_level_limit = 4 ) > { > ibase_log_stream* ls = __null; > > switch( type ) > { > case 1: > ls = new file_output_stream( pdefault_file_name, pdefault_log_folder ); > break; > > case 2: > > > > return false; > > break; > case 3: > ls = new console_output_stream( ); > break; > } > > if ( ls ) { > m_log_streams.push_back(streams_container::value_type(ls, log_level_limit)); > return true; > } > return ls ? true:false; > } > bool add_logger( ibase_log_stream* pstream, int log_level_limit = 4 ) > { > m_log_streams.push_back(streams_container::value_type(pstream, log_level_limit) ); > return true; > } > > bool remove_logger(int type) > { > streams_container::iterator it = m_log_streams.begin(); > for(;it!=m_log_streams.end(); it++) > { > if(it->first->get_type() == type) > { > delete it->first; > m_log_streams.erase(it); > return true; > } > } > return false; > > } > > protected: > private: > > streams_container m_log_streams; > }; > > > > > inline int get_set_log_detalisation_level(bool is_need_set = false, int log_level_to_set = 1); > inline int get_set_time_level(bool is_need_set = false, int time_log_level = 0); > inline bool get_set_need_thread_id(bool is_need_set = false, bool is_need_val = false); > inline bool get_set_need_proc_name(bool is_need_set = false, bool is_need_val = false); > > > inline std::string get_daytime_string2() > { > boost::posix_time::ptime p = boost::posix_time::microsec_clock::local_time(); > return misc_utils::get_time_str_v3(p); > } > inline std::string get_day_time_string() > { > return get_daytime_string2(); > > > > } > > inline std::string get_time_string() > { > return get_daytime_string2(); > > } ># 740 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > class logger > { > public: > friend class log_singletone; > > logger() > { > { epee::critical_region_t<decltype(m_critical_sec)> critical_region_var(m_critical_sec); > init(); > }; > } > ~logger() > { > } > > bool set_max_logfile_size(uint64_t max_size) > { > { epee::critical_region_t<decltype(m_critical_sec)> critical_region_var(m_critical_sec); > m_log_target.set_max_logfile_size(max_size); > }; > return true; > } > > bool set_log_rotate_cmd(const std::string& cmd) > { > { epee::critical_region_t<decltype(m_critical_sec)> critical_region_var(m_critical_sec); > m_log_target.set_log_rotate_cmd(cmd); > }; > return true; > } > > bool take_away_journal(std::list<std::string>& journal) > { > { epee::critical_region_t<decltype(m_critical_sec)> critical_region_var(m_critical_sec); > m_journal.swap(journal); > }; > return true; > } > > bool do_log_message(const std::string& rlog_mes, int log_level, int color, bool add_to_journal = false, const char* plog_name = __null) > { > { epee::critical_region_t<decltype(m_critical_sec)> critical_region_var(m_critical_sec); > m_log_target.do_log_message(rlog_mes, log_level, color, plog_name); > if(add_to_journal) > m_journal.push_back(rlog_mes); > > return true; > }; > } > > bool add_logger( int type, const char* pdefault_file_name, const char* pdefault_log_folder , int log_level_limit = 4) > { > { epee::critical_region_t<decltype(m_critical_sec)> critical_region_var(m_critical_sec); > return m_log_target.add_logger( type, pdefault_file_name, pdefault_log_folder, log_level_limit); > }; > } > bool add_logger( ibase_log_stream* pstream, int log_level_limit = 4) > { > { epee::critical_region_t<decltype(m_critical_sec)> critical_region_var(m_critical_sec); > return m_log_target.add_logger(pstream, log_level_limit); > }; > } > > bool remove_logger(int type) > { > { epee::critical_region_t<decltype(m_critical_sec)> critical_region_var(m_critical_sec); > return m_log_target.remove_logger(type); > }; > } > > > bool set_thread_prefix(const std::string& prefix) > { > { epee::critical_region_t<decltype(m_critical_sec)> critical_region_var(m_critical_sec); > m_thr_prefix_strings[misc_utils::get_thread_string_id()] = prefix; > }; > return true; > } > > > std::string get_default_log_file() > { > return m_default_log_file; > } > > std::string get_default_log_folder() > { > return m_default_log_folder; > } > > protected: > private: > bool init() > { > > > m_process_name = string_tools::get_current_module_name(); > > init_log_path_by_default(); > > > init_default_loggers(); > > std::stringstream ss; > ss << get_time_string() << " Init logging. Level=" << get_set_log_detalisation_level() > << " Log path=" << m_default_log_folder << std::endl; > this->do_log_message(ss.str(), console_color_white, 0); > return true; > } > bool init_default_loggers() > { > > return true; > } > > bool init_log_path_by_default() > { > > m_default_log_folder = string_tools::get_current_module_folder(); > > m_default_log_file = m_process_name; > std::string::size_type a = m_default_log_file.rfind('.'); > if ( a != std::string::npos ) > m_default_log_file.erase( a, m_default_log_file.size()); > m_default_log_file += ".log"; > > return true; > } > > log_stream_splitter m_log_target; > > std::string m_default_log_folder; > std::string m_default_log_file; > std::string m_process_name; > std::map<std::string, std::string> m_thr_prefix_strings; > std::list<std::string> m_journal; > critical_section m_critical_sec; > }; > > > > class log_singletone > { > public: > friend class initializer<log_singletone>; > friend class logger; > static int get_log_detalisation_level() > { > get_or_create_instance(); > return get_set_log_detalisation_level(); > } > > static bool is_filter_error(int error_code) > { > return false; > } > > > static bool do_log_message(const std::string& rlog_mes, int log_level, int color, bool keep_in_journal, const char* plog_name = __null) > { > logger* plogger = get_or_create_instance(); > bool res = false; > if(plogger) > res = plogger->do_log_message(rlog_mes, log_level, color, keep_in_journal, plog_name); > else > { > plogger = new logger(); > > res = plogger->do_log_message(rlog_mes, log_level, color, keep_in_journal, plog_name); > delete plogger; > plogger = __null; > } > return res; > } > > static bool take_away_journal(std::list<std::string>& journal) > { > logger* plogger = get_or_create_instance(); > bool res = false; > if(plogger) > res = plogger->take_away_journal(journal); > > return res; > } > > static bool set_max_logfile_size(uint64_t file_size) > { > logger* plogger = get_or_create_instance(); > if(!plogger) return false; > return plogger->set_max_logfile_size(file_size); > } > > > static bool set_log_rotate_cmd(const std::string& cmd) > { > logger* plogger = get_or_create_instance(); > if(!plogger) return false; > return plogger->set_log_rotate_cmd(cmd); > } > > > static bool add_logger( int type, const char* pdefault_file_name, const char* pdefault_log_folder, int log_level_limit = 4) > { > logger* plogger = get_or_create_instance(); > if(!plogger) return false; > return plogger->add_logger(type, pdefault_file_name, pdefault_log_folder, log_level_limit); > } > > static std::string get_default_log_file() > { > logger* plogger = get_or_create_instance(); > if(plogger) > return plogger->get_default_log_file(); > > return ""; > } > > static std::string get_default_log_folder() > { > logger* plogger = get_or_create_instance(); > if(plogger) > return plogger->get_default_log_folder(); > > return ""; > } > > static bool add_logger( ibase_log_stream* pstream, int log_level_limit = 4 ) > { > logger* plogger = get_or_create_instance(); > if(!plogger) return false; > return plogger->add_logger(pstream, log_level_limit); > } > > > static bool remove_logger( int type ) > { > logger* plogger = get_or_create_instance(); > if(!plogger) return false; > return plogger->remove_logger(type); > } ># 980 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" >#pragma GCC diagnostic push ># 980 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" ># 981 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" >#pragma GCC diagnostic ignored "-Wmaybe-uninitialized" ># 981 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > > static int get_set_log_detalisation_level(bool is_need_set = false, int log_level_to_set = 1) > { > static int log_detalisation_level = 1; > if(is_need_set) > log_detalisation_level = log_level_to_set; > return log_detalisation_level; > } ># 989 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" >#pragma GCC diagnostic pop ># 989 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > > static int get_set_time_level(bool is_need_set = false, int time_log_level = 0) > { > static int val_time_log_level = 0; > if(is_need_set) > val_time_log_level = time_log_level; > > return val_time_log_level; > } > > static int get_set_process_level(bool is_need_set = false, int process_log_level = 0) > { > static int val_process_log_level = 0; > if(is_need_set) > val_process_log_level = process_log_level; > > return val_process_log_level; > } ># 1017 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > static bool get_set_need_thread_id(bool is_need_set = false, bool is_need_val = false) > { > static bool is_need = false; > if(is_need_set) > is_need = is_need_val; > > return is_need; > } > > static bool get_set_need_proc_name(bool is_need_set = false, bool is_need_val = false) > { > static bool is_need = true; > if(is_need_set) > is_need = is_need_val; > > return is_need; > } > static uint64_t get_set_err_count(bool is_need_set = false, uint64_t err_val = false) > { > static uint64_t err_count = 0; > if(is_need_set) > err_count = err_val; > > return err_count; > } ># 1080 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > static bool set_thread_log_prefix(const std::string& prefix) > { > > > > > > logger* plogger = get_or_create_instance(); > if(!plogger) return false; > return plogger->set_thread_prefix(prefix); > } > > > static std::string get_prefix_entry() > { > std::stringstream str_prefix; > > if ( get_set_time_level() <= get_set_log_detalisation_level() ) > str_prefix << get_day_time_string() << " "; > > > logger* plogger = get_or_create_instance(); > > if(!plogger) > { > plogger = new logger(); > } > > > > > if ( get_set_need_thread_id() ) > str_prefix << "tid:" << misc_utils::get_thread_string_id() << " "; > > > if(plogger->m_thr_prefix_strings.size()) > { > epee::critical_region_t<decltype(plogger->m_critical_sec)> critical_region_var(plogger->m_critical_sec); > std::string thr_str = misc_utils::get_thread_string_id(); > std::map<std::string, std::string>::iterator it = plogger->m_thr_prefix_strings.find(thr_str); > if(it!=plogger->m_thr_prefix_strings.end()) > { > str_prefix << it->second; > } > } > > > if(get_set_is_uninitialized()) > delete plogger; > > return str_prefix.str(); > } > > private: > log_singletone(){} > > > static bool init() > { > return true; > } > static bool un_init() > { > > logger* plogger = get_set_instance_internal(); > if(plogger) delete plogger; > > get_set_is_uninitialized(true, true); > get_set_instance_internal(true, __null); > return true; > } > > static logger* get_or_create_instance() > { > logger* plogger = get_set_instance_internal(); > if(!plogger) > if(!get_set_is_uninitialized()) > get_set_instance_internal(true, plogger = new logger); > > return plogger; > } > > static logger* get_set_instance_internal(bool is_need_set = false, logger* pnew_logger_val = __null) > { > static logger* val_plogger = __null; > > if(is_need_set) > val_plogger = pnew_logger_val; > > return val_plogger; > } > > static bool get_set_is_uninitialized(bool is_need_set = false, bool is_uninitialized = false) > { > static bool val_is_uninitialized = false; > > if(is_need_set) > val_is_uninitialized = is_uninitialized; > > return val_is_uninitialized; > } > > }; > > const static initializer<log_singletone> log_initializer; ># 1208 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > class log_frame > { > std::string m_name; > int m_level; > const char* m_plog_name; > public: > > log_frame(const std::string& name, int dlevel = 2 , const char* plog_name = __null) > { > > > > m_plog_name = plog_name; > if ( dlevel <= log_singletone::get_log_detalisation_level() ) > { > m_name = name; > std::stringstream ss; > ss << log_space::log_singletone::get_prefix_entry() << "-->>" << m_name << std::endl; > log_singletone::do_log_message(ss.str(), dlevel, console_color_default, false, m_plog_name); > } > m_level = dlevel; > > > > } > ~log_frame() > { > > > > > if (m_level <= log_singletone::get_log_detalisation_level() ) > { > std::stringstream ss; > ss << log_space::log_singletone::get_prefix_entry() << "<<--" << m_name << std::endl; > log_singletone::do_log_message(ss.str(), m_level, console_color_default, false,m_plog_name); > } > > > > } > }; > > inline int get_set_time_level(bool is_need_set, int time_log_level) > { > return log_singletone::get_set_time_level(is_need_set, time_log_level); > } > inline int get_set_log_detalisation_level(bool is_need_set, int log_level_to_set) > { > return log_singletone::get_set_log_detalisation_level(is_need_set, log_level_to_set); > } > inline std::string get_prefix_entry() > { > return log_singletone::get_prefix_entry(); > } > inline bool get_set_need_thread_id(bool is_need_set, bool is_need_val) > { > return log_singletone::get_set_need_thread_id(is_need_set, is_need_val); > } > inline bool get_set_need_proc_name(bool is_need_set, bool is_need_val ) > { > return log_singletone::get_set_need_proc_name(is_need_set, is_need_val); > } > > inline std::string get_win32_err_descr(int err_no) > { ># 1297 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" > return "Not implemented yet"; > > } > > inline bool getwin32_err_text(std::stringstream& ref_message, int error_no) > { > ref_message << "win32 error:" << get_win32_err_descr(error_no); > return true; > } >} ># 1468 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" >} ># 33 "/c/honeypenny/contrib/epee/include/include_base_utils.h" 2 ># 8 "/c/honeypenny/src/rpc/core_rpc_server.cpp" 2 >using namespace epee; > ># 1 "/c/honeypenny/src/rpc/core_rpc_server.h" 1 > > > > > > ># 1 "/usr/include/boost/program_options/options_description.hpp" 1 3 4 ># 11 "/usr/include/boost/program_options/options_description.hpp" 3 4 ># 1 "/usr/include/boost/program_options/config.hpp" 1 3 4 ># 30 "/usr/include/boost/program_options/config.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 31 "/usr/include/boost/program_options/config.hpp" 2 3 4 ># 12 "/usr/include/boost/program_options/options_description.hpp" 2 3 4 ># 1 "/usr/include/boost/program_options/errors.hpp" 1 3 4 ># 24 "/usr/include/boost/program_options/errors.hpp" 3 4 >namespace boost { namespace program_options { > > inline std::string strip_prefixes(const std::string& text) > { > return text.substr(text.find_last_of("-/") + 1); > } > > > class error : public std::logic_error { > public: > error(const std::string& xwhat) : std::logic_error(xwhat) {} > }; > > > > > > class too_many_positional_options_error : public error { > public: > too_many_positional_options_error() > : error("too many positional options have been specified on the command line") > {} > }; > > > class invalid_command_line_style : public error { > public: > invalid_command_line_style(const std::string& msg) > : error(msg) > {} > }; > > > class reading_file : public error { > public: > reading_file(const char* filename) > : error(std::string("can not read options configuration file '").append(filename).append("'")) > {} > }; ># 88 "/usr/include/boost/program_options/errors.hpp" 3 4 > class error_with_option_name : public error { > > protected: > > > > > > > int m_option_style; > > > > > std::map<std::string, std::string> m_substitutions; > typedef std::pair<std::string, std::string> string_pair; > std::map<std::string, string_pair > m_substitution_defaults; > > public: > > std::string m_error_template; > > error_with_option_name(const std::string& template_, > const std::string& option_name = "", > const std::string& original_token = "", > int option_style = 0); > > > > > ~error_with_option_name() throw() {} ># 141 "/usr/include/boost/program_options/errors.hpp" 3 4 > void set_substitute(const std::string& parameter_name, const std::string& value) > { m_substitutions[parameter_name] = value; } > > > > void set_substitute_default(const std::string& parameter_name, > const std::string& from, > const std::string& to) > { > m_substitution_defaults[parameter_name] = std::make_pair(from, to); > } > > > > void add_context(const std::string& option_name, > const std::string& original_token, > int option_style) > { > set_option_name(option_name); > set_original_token(original_token); > set_prefix(option_style); > } > > void set_prefix(int option_style) > { m_option_style = option_style;} > > > virtual void set_option_name(const std::string& option_name) > { set_substitute("option", option_name);} > > std::string get_option_name() const throw() > { return get_canonical_option_name(); } > > void set_original_token(const std::string& original_token) > { set_substitute("original_token", original_token);} > > > > > virtual const char* what() const throw(); > > protected: > > mutable std::string m_message; > > > virtual void substitute_placeholders(const std::string& error_template) const; > > > void replace_token(const std::string& from, const std::string& to) const; > > > > std::string get_canonical_option_name() const; > std::string get_canonical_option_prefix() const; > }; > > > > > class multiple_values : public error_with_option_name { > public: > multiple_values() > : error_with_option_name("option '%canonical_option%' only takes a single argument"){} > > ~multiple_values() throw() {} > }; > > > > > class multiple_occurrences : public error_with_option_name { > public: > multiple_occurrences() > : error_with_option_name("option '%canonical_option%' cannot be specified more than once"){} > > ~multiple_occurrences() throw() {} > > }; > > > class required_option : public error_with_option_name { > public: > > required_option(const std::string& option_name) > : error_with_option_name("the option '%canonical_option%' is required but missing", "", option_name) > { > } > > ~required_option() throw() {} > }; ># 244 "/usr/include/boost/program_options/errors.hpp" 3 4 > class error_with_no_option_name : public error_with_option_name { > public: > error_with_no_option_name(const std::string& template_, > const std::string& original_token = "") > : error_with_option_name(template_, "", original_token) > { > } > > > virtual void set_option_name(const std::string&) {} > > ~error_with_no_option_name() throw() {} > }; > > > > class unknown_option : public error_with_no_option_name { > public: > unknown_option(const std::string& original_token = "") > : error_with_no_option_name("unrecognised option '%canonical_option%'", original_token) > { > } > > ~unknown_option() throw() {} > }; > > > > > class ambiguous_option : public error_with_no_option_name { > public: > ambiguous_option(const std::vector<std::string>& xalternatives) > : error_with_no_option_name("option '%canonical_option%' is ambiguous"), > m_alternatives(xalternatives) > {} > > ~ambiguous_option() throw() {} > > const std::vector<std::string>& alternatives() const throw() {return m_alternatives;} > > protected: > > virtual void substitute_placeholders(const std::string& error_template) const; > private: > > std::vector<std::string> m_alternatives; > }; > > > > > > class invalid_syntax : public error_with_option_name { > public: > enum kind_t { > long_not_allowed = 30, > long_adjacent_not_allowed, > short_adjacent_not_allowed, > empty_adjacent_parameter, > missing_parameter, > extra_parameter, > unrecognized_line > }; > > invalid_syntax(kind_t kind, > const std::string& option_name = "", > const std::string& original_token = "", > int option_style = 0): > error_with_option_name(get_template(kind), option_name, original_token, option_style), > m_kind(kind) > { > } > > ~invalid_syntax() throw() {} > > kind_t kind() const {return m_kind;} > > > virtual std::string tokens() const {return get_option_name(); } > protected: > > std::string get_template(kind_t kind); > kind_t m_kind; > }; > > class invalid_config_file_syntax : public invalid_syntax { > public: > invalid_config_file_syntax(const std::string& invalid_line, kind_t kind): > invalid_syntax(kind) > { > m_substitutions["invalid_line"] = invalid_line; > } > > ~invalid_config_file_syntax() throw() {} > > > virtual std::string tokens() const {return m_substitutions.find("invalid_line")->second; } > }; > > > > class invalid_command_line_syntax : public invalid_syntax { > public: > invalid_command_line_syntax(kind_t kind, > const std::string& option_name = "", > const std::string& original_token = "", > int option_style = 0): > invalid_syntax(kind, option_name, original_token, option_style) {} > ~invalid_command_line_syntax() throw() {} > }; > > > > class validation_error : public error_with_option_name { > public: > enum kind_t { > multiple_values_not_allowed = 30, > at_least_one_value_required, > invalid_bool_value, > invalid_option_value, > invalid_option > }; > > public: > validation_error(kind_t kind, > const std::string& option_name = "", > const std::string& original_token = "", > int option_style = 0): > error_with_option_name(get_template(kind), option_name, original_token, option_style) > { > } > > ~validation_error() throw() {} > > protected: > > std::string get_template(kind_t kind); > kind_t m_kind; > }; > > > class invalid_option_value > : public validation_error > { > public: > invalid_option_value(const std::string& value); > > invalid_option_value(const std::wstring& value); > > }; > > > class invalid_bool_value > : public validation_error > { > public: > invalid_bool_value(const std::string& value); > }; > > > > > > > >}} ># 13 "/usr/include/boost/program_options/options_description.hpp" 2 3 4 ># 1 "/usr/include/boost/program_options/value_semantic.hpp" 1 3 4 ># 12 "/usr/include/boost/program_options/value_semantic.hpp" 3 4 ># 1 "/usr/include/boost/any.hpp" 1 3 4 ># 40 "/usr/include/boost/any.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 41 "/usr/include/boost/any.hpp" 2 3 4 > > > > > > > >namespace boost >{ > class any > { > public: > > any() noexcept > : content(0) > { > } > > template<typename ValueType> > any(const ValueType & value) > : content(new holder<typename decay<const ValueType>::type>(value)) > { > } > > any(const any & other) > : content(other.content ? other.content->clone() : 0) > { > } > > > > any(any&& other) noexcept > : content(other.content) > { > other.content = 0; > } > > > template<typename ValueType> > any(ValueType&& value > , typename boost::disable_if<boost::is_same<any&, ValueType> >::type* = 0 > , typename boost::disable_if<boost::is_const<ValueType> >::type* = 0) > : content(new holder< typename decay<ValueType>::type >(static_cast<ValueType&&>(value))) > { > } > > > ~any() noexcept > { > delete content; > } > > public: > > any & swap(any & rhs) noexcept > { > std::swap(content, rhs.content); > return *this; > } ># 117 "/usr/include/boost/any.hpp" 3 4 > any & operator=(const any& rhs) > { > any(rhs).swap(*this); > return *this; > } > > > any & operator=(any&& rhs) noexcept > { > rhs.swap(*this); > any().swap(rhs); > return *this; > } > > > template <class ValueType> > any & operator=(ValueType&& rhs) > { > any(static_cast<ValueType&&>(rhs)).swap(*this); > return *this; > } > > > public: > > bool empty() const noexcept > { > return !content; > } > > void clear() noexcept > { > any().swap(*this); > } > > const std::type_info & type() const noexcept > { > return content ? content->type() : typeid(void); > } > > > private: > > > > > class placeholder > { > public: > > virtual ~placeholder() > { > } > > public: > > virtual const std::type_info & type() const noexcept = 0; > > virtual placeholder * clone() const = 0; > > }; > > template<typename ValueType> > class holder : public placeholder > { > public: > > holder(const ValueType & value) > : held(value) > { > } > > > holder(ValueType&& value) > : held(static_cast< ValueType&& >(value)) > { > } > > public: > > virtual const std::type_info & type() const noexcept > { > return typeid(ValueType); > } > > virtual placeholder * clone() const > { > return new holder(held); > } > > public: > > ValueType held; > > private: > holder & operator=(const holder &); > }; > > > > private: > > template<typename ValueType> > friend ValueType * any_cast(any *) noexcept; > > template<typename ValueType> > friend ValueType * unsafe_any_cast(any *) noexcept; > > > > > > > > placeholder * content; > > }; > > inline void swap(any & lhs, any & rhs) noexcept > { > lhs.swap(rhs); > } > > class __attribute__((__visibility__("default"))) bad_any_cast : public std::bad_cast > { > public: > virtual const char * what() const noexcept > { > return "boost::bad_any_cast: " > "failed conversion using boost::any_cast"; > } > }; > > template<typename ValueType> > ValueType * any_cast(any * operand) noexcept > { > return operand && > > std::strcmp(operand->type().name(), typeid(ValueType).name()) == 0 > > > > ? &static_cast<any::holder<ValueType> *>(operand->content)->held > : 0; > } > > template<typename ValueType> > inline const ValueType * any_cast(const any * operand) noexcept > { > return any_cast<ValueType>(const_cast<any *>(operand)); > } > > template<typename ValueType> > ValueType any_cast(any & operand) > { > typedef typename remove_reference<ValueType>::type nonref; ># 284 "/usr/include/boost/any.hpp" 3 4 > nonref * result = any_cast<nonref>(&operand); > if(!result) > boost::throw_exception(bad_any_cast()); > > > > > > typedef typename boost::mpl::if_< > boost::is_reference<ValueType>, > ValueType, > typename boost::add_reference<ValueType>::type > >::type ref_type; > > return static_cast<ref_type>(*result); > } > > template<typename ValueType> > inline ValueType any_cast(const any & operand) > { > typedef typename remove_reference<ValueType>::type nonref; > > > > > > > > return any_cast<const nonref &>(const_cast<any &>(operand)); > } > > > template<typename ValueType> > inline ValueType&& any_cast(any&& operand) > { > static_assert(boost::is_rvalue_reference<ValueType&&>::value || boost::is_const< typename boost::remove_reference<ValueType>::type >::value, "boost::any_cast shall not be used for getting nonconst references to temporary objects") > > > > ; > return any_cast<ValueType&&>(operand); > } ># 334 "/usr/include/boost/any.hpp" 3 4 > template<typename ValueType> > inline ValueType * unsafe_any_cast(any * operand) noexcept > { > return &static_cast<any::holder<ValueType> *>(operand->content)->held; > } > > template<typename ValueType> > inline const ValueType * unsafe_any_cast(const any * operand) noexcept > { > return unsafe_any_cast<ValueType>(const_cast<any *>(operand)); > } >} ># 13 "/usr/include/boost/program_options/value_semantic.hpp" 2 3 4 ># 1 "/usr/include/boost/function/function1.hpp" 1 3 4 ># 11 "/usr/include/boost/function/function1.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 12 "/usr/include/boost/function/function1.hpp" 2 3 4 ># 14 "/usr/include/boost/program_options/value_semantic.hpp" 2 3 4 > > > > > > > >namespace boost { namespace program_options { > > > > > class value_semantic { > public: > > > > virtual std::string name() const = 0; > > > > virtual unsigned min_tokens() const = 0; > > > > virtual unsigned max_tokens() const = 0; > > > > > > virtual bool is_composing() const = 0; > > > > > virtual bool is_required() const = 0; > > > > > > > virtual void parse(boost::any& value_store, > const std::vector<std::string>& new_tokens, > bool utf8) const > = 0; > > > > > virtual bool apply_default(boost::any& value_store) const = 0; > > > > virtual void notify(const boost::any& value_store) const = 0; > > virtual ~value_semantic() {} > }; > > > > > template<class charT> > class value_semantic_codecvt_helper { > > }; ># 89 "/usr/include/boost/program_options/value_semantic.hpp" 3 4 > template<> > class > value_semantic_codecvt_helper<char> : public value_semantic { > private: > void parse(boost::any& value_store, > const std::vector<std::string>& new_tokens, > bool utf8) const; > protected: > virtual void xparse(boost::any& value_store, > const std::vector<std::string>& new_tokens) > const = 0; > }; ># 109 "/usr/include/boost/program_options/value_semantic.hpp" 3 4 > template<> > class > value_semantic_codecvt_helper<wchar_t> : public value_semantic { > private: > void parse(boost::any& value_store, > const std::vector<std::string>& new_tokens, > bool utf8) const; > protected: > > virtual void xparse(boost::any& value_store, > const std::vector<std::wstring>& new_tokens) > const = 0; > > }; > > > > class > untyped_value : public value_semantic_codecvt_helper<char> { > public: > untyped_value(bool zero_tokens = false) > : m_zero_tokens(zero_tokens) > {} > > std::string name() const; > > unsigned min_tokens() const; > unsigned max_tokens() const; > > bool is_composing() const { return false; } > > bool is_required() const { return false; } > > > > > > > void xparse(boost::any& value_store, > const std::vector<std::string>& new_tokens) const; > > > bool apply_default(boost::any&) const { return false; } > > > void notify(const boost::any&) const {} > private: > bool m_zero_tokens; > }; > > > > > > > > class typed_value_base > { > public: > > > virtual const std::type_info& value_type() const = 0; > > > virtual ~typed_value_base() {} > }; > > > > template<class T, class charT = char> > class typed_value : public value_semantic_codecvt_helper<charT>, > public typed_value_base > { > public: > > > typed_value(T* store_to) > : m_store_to(store_to), m_composing(false), > m_multitoken(false), m_zero_tokens(false), > m_required(false) > {} > > > > > > typed_value* default_value(const T& v) > { > m_default_value = boost::any(v); > m_default_value_as_text = boost::lexical_cast<std::string>(v); > return this; > } > > > > > > > > typed_value* default_value(const T& v, const std::string& textual) > { > m_default_value = boost::any(v); > m_default_value_as_text = textual; > return this; > } ># 222 "/usr/include/boost/program_options/value_semantic.hpp" 3 4 > typed_value* implicit_value(const T &v) > { > m_implicit_value = boost::any(v); > m_implicit_value_as_text = > boost::lexical_cast<std::string>(v); > return this; > } > > > typed_value* value_name(const std::string& name) > { > m_value_name = name; > return this; > } ># 247 "/usr/include/boost/program_options/value_semantic.hpp" 3 4 > typed_value* implicit_value(const T &v, const std::string& textual) > { > m_implicit_value = boost::any(v); > m_implicit_value_as_text = textual; > return this; > } > > > > typed_value* notifier(function1<void, const T&> f) > { > m_notifier = f; > return this; > } > > > > > typed_value* composing() > { > m_composing = true; > return this; > } > > > > typed_value* multitoken() > { > m_multitoken = true; > return this; > } ># 286 "/usr/include/boost/program_options/value_semantic.hpp" 3 4 > typed_value* zero_tokens() > { > m_zero_tokens = true; > return this; > } > > > typed_value* required() > { > m_required = true; > return this; > } > > public: > > std::string name() const; > > bool is_composing() const { return m_composing; } > > unsigned min_tokens() const > { > if (m_zero_tokens || !m_implicit_value.empty()) { > return 0; > } else { > return 1; > } > } > > unsigned max_tokens() const { > if (m_multitoken) { > return 32000; > } else if (m_zero_tokens) { > return 0; > } else { > return 1; > } > } > > bool is_required() const { return m_required; } > > > > void xparse(boost::any& value_store, > const std::vector< std::basic_string<charT> >& new_tokens) > const; > > > > > > virtual bool apply_default(boost::any& value_store) const > { > if (m_default_value.empty()) { > return false; > } else { > value_store = m_default_value; > return true; > } > } > > > > > void notify(const boost::any& value_store) const; > > public: > > const std::type_info& value_type() const > { > return typeid(T); > } > > > private: > T* m_store_to; > > > > std::string m_value_name; > boost::any m_default_value; > std::string m_default_value_as_text; > boost::any m_implicit_value; > std::string m_implicit_value_as_text; > bool m_composing, m_implicit, m_multitoken, m_zero_tokens, m_required; > boost::function1<void, const T&> m_notifier; > }; ># 380 "/usr/include/boost/program_options/value_semantic.hpp" 3 4 > template<class T> > typed_value<T>* > value(); > > > > template<class T> > typed_value<T>* > value(T* v); > > > > > > template<class T> > typed_value<T, wchar_t>* > wvalue(); > > > > template<class T> > typed_value<T, wchar_t>* > wvalue(T* v); > > > > > > typed_value<bool>* > bool_switch(); > > > > typed_value<bool>* > bool_switch(bool* v); > >}} > ># 1 "/usr/include/boost/program_options/detail/value_semantic.hpp" 1 3 4 ># 11 "/usr/include/boost/program_options/detail/value_semantic.hpp" 3 4 >namespace boost { namespace program_options { > > extern std::string arg; > > template<class T, class charT> > std::string > typed_value<T, charT>::name() const > { > std::string const& var = (m_value_name.empty() ? arg : m_value_name); > if (!m_implicit_value.empty() && !m_implicit_value_as_text.empty()) { > std::string msg = "[=" + var + "(=" + m_implicit_value_as_text + ")]"; > if (!m_default_value.empty() && !m_default_value_as_text.empty()) > msg += " (=" + m_default_value_as_text + ")"; > return msg; > } > else if (!m_default_value.empty() && !m_default_value_as_text.empty()) { > return var + " (=" + m_default_value_as_text + ")"; > } else { > return var; > } > } > > template<class T, class charT> > void > typed_value<T, charT>::notify(const boost::any& value_store) const > { > const T* value = boost::any_cast<T>(&value_store); > if (m_store_to) { > *m_store_to = *value; > } > if (m_notifier) { > m_notifier(*value); > } > } > > namespace validators { > > > > > > template<class charT> > const std::basic_string<charT>& get_single_string( > const std::vector<std::basic_string<charT> >& v, > bool allow_empty = false) > { > static std::basic_string<charT> empty; > if (v.size() > 1) > boost::throw_exception(validation_error(validation_error::multiple_values_not_allowed)); > else if (v.size() == 1) > return v.front(); > else if (!allow_empty) > boost::throw_exception(validation_error(validation_error::at_least_one_value_required)); > return empty; > } > > > void > check_first_occurrence(const boost::any& value); > } > > using namespace validators; ># 81 "/usr/include/boost/program_options/detail/value_semantic.hpp" 3 4 > template<class T, class charT> > void validate(boost::any& v, > const std::vector< std::basic_string<charT> >& xs, > T*, long) > { > validators::check_first_occurrence(v); > std::basic_string<charT> s(validators::get_single_string(xs)); > try { > v = any(lexical_cast<T>(s)); > } > catch(const bad_lexical_cast&) { > boost::throw_exception(invalid_option_value(s)); > } > } > > void validate(boost::any& v, > const std::vector<std::string>& xs, > bool*, > int); > > > void validate(boost::any& v, > const std::vector<std::wstring>& xs, > bool*, > int); ># 114 "/usr/include/boost/program_options/detail/value_semantic.hpp" 3 4 > void validate(boost::any& v, > const std::vector<std::string>& xs, > std::string*, > int); > > > void validate(boost::any& v, > const std::vector<std::wstring>& xs, > std::string*, > int); > > > > > > template<class T, class charT> > void validate(boost::any& v, > const std::vector<std::basic_string<charT> >& s, > std::vector<T>*, > int) > { > if (v.empty()) { > v = boost::any(std::vector<T>()); > } > std::vector<T>* tv = boost::any_cast< std::vector<T> >(&v); > (static_cast<void> (0)); > for (unsigned i = 0; i < s.size(); ++i) > { > try { > > > > boost::any a; > std::vector<std::basic_string<charT> > cv; > cv.push_back(s[i]); > validate(a, cv, (T*)0, 0); > tv->push_back(boost::any_cast<T>(a)); > } > catch(const bad_lexical_cast& ) { > boost::throw_exception(invalid_option_value(s[i])); > } > } > } > > template<class T, class charT> > void > typed_value<T, charT>:: > xparse(boost::any& value_store, > const std::vector<std::basic_string<charT> >& new_tokens) const > { > > > > if (new_tokens.empty() && !m_implicit_value.empty()) > value_store = m_implicit_value; > else > validate(value_store, new_tokens, (T*)0, 0); > } > > template<class T> > typed_value<T>* > value() > { > > return boost::program_options::value<T>(0); > } > > template<class T> > typed_value<T>* > value(T* v) > { > typed_value<T>* r = new typed_value<T>(v); > > return r; > } > > template<class T> > typed_value<T, wchar_t>* > wvalue() > { > return wvalue<T>(0); > } > > template<class T> > typed_value<T, wchar_t>* > wvalue(T* v) > { > typed_value<T, wchar_t>* r = new typed_value<T, wchar_t>(v); > > return r; > } > > > >}} ># 419 "/usr/include/boost/program_options/value_semantic.hpp" 2 3 4 ># 14 "/usr/include/boost/program_options/options_description.hpp" 2 3 4 > ># 1 "/usr/include/boost/function.hpp" 1 3 4 ># 64 "/usr/include/boost/function.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 25 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 27 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 58 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 63 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 68 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 73 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 78 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 83 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 88 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 93 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 98 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 65 "/usr/include/boost/function.hpp" 2 3 4 ># 16 "/usr/include/boost/program_options/options_description.hpp" 2 3 4 ># 35 "/usr/include/boost/program_options/options_description.hpp" 3 4 >namespace boost { > >namespace program_options { ># 47 "/usr/include/boost/program_options/options_description.hpp" 3 4 > class option_description { > public: > > option_description(); ># 76 "/usr/include/boost/program_options/options_description.hpp" 3 4 > option_description(const char* name, > const value_semantic* s); > > > > option_description(const char* name, > const value_semantic* s, > const char* description); > > virtual ~option_description(); > > enum match_result { no_match, full_match, approximate_match }; > > > > > match_result match(const std::string& option, bool approx, > bool long_ignore_case, bool short_ignore_case) const; ># 103 "/usr/include/boost/program_options/options_description.hpp" 3 4 > const std::string& key(const std::string& option) const; ># 113 "/usr/include/boost/program_options/options_description.hpp" 3 4 > std::string canonical_display_name(int canonical_option_style = 0) const; > > const std::string& long_name() const; > > > const std::string& description() const; > > > shared_ptr<const value_semantic> semantic() const; > > > std::string format_name() const; > > > > std::string format_parameter() const; > > private: > > option_description& set_name(const char* name); > > std::string m_short_name, m_long_name, m_description; > > > shared_ptr<const value_semantic> m_value_semantic; > }; > > class options_description; > > > > class options_description_easy_init { > public: > options_description_easy_init(options_description* owner); > > options_description_easy_init& > operator()(const char* name, > const char* description); > > options_description_easy_init& > operator()(const char* name, > const value_semantic* s); > > options_description_easy_init& > operator()(const char* name, > const value_semantic* s, > const char* description); > > private: > options_description* owner; > }; ># 173 "/usr/include/boost/program_options/options_description.hpp" 3 4 > class options_description { > public: > static const unsigned m_default_line_length; > > > options_description(unsigned line_length = m_default_line_length, > unsigned min_description_length = m_default_line_length / 2); > > > > > > > > options_description(const std::string& caption, > unsigned line_length = m_default_line_length, > unsigned min_description_length = m_default_line_length / 2); > > > > void add(shared_ptr<option_description> desc); > > > > > > > options_description& add(const options_description& desc); > > public: > > > > > > > options_description_easy_init add_options(); > > const option_description& find(const std::string& name, > bool approx, > bool long_ignore_case = false, > bool short_ignore_case = false) const; > > const option_description* find_nothrow(const std::string& name, > bool approx, > bool long_ignore_case = false, > bool short_ignore_case = false) const; > > > const std::vector< shared_ptr<option_description> >& options() const; > > > > > friend std::ostream& operator<<(std::ostream& os, > const options_description& desc); > > > > void print(std::ostream& os) const; > > private: > typedef std::map<std::string, int>::const_iterator name2index_iterator; > typedef std::pair<name2index_iterator, name2index_iterator> > approximation_range; > > > > std::string m_caption; > const unsigned m_line_length; > const unsigned m_min_description_length; > > > > > std::vector< shared_ptr<option_description> > m_options; > > > > > > > > std::vector<bool> belong_to_group; > > > std::vector< shared_ptr<options_description> > groups; > > }; > > > class duplicate_option_error : public error { > public: > duplicate_option_error(const std::string& xwhat) : error(xwhat) {} > }; >}} ># 8 "/c/honeypenny/src/rpc/core_rpc_server.h" 2 ># 1 "/usr/include/boost/program_options/variables_map.hpp" 1 3 4 ># 24 "/usr/include/boost/program_options/variables_map.hpp" 3 4 >namespace boost { namespace program_options { > > template<class charT> > class basic_parsed_options; > > class value_semantic; > class variables_map; ># 39 "/usr/include/boost/program_options/variables_map.hpp" 3 4 > void store(const basic_parsed_options<char>& options, variables_map& m, > bool utf8 = false); > > > > > > > > void store(const basic_parsed_options<wchar_t>& options, > variables_map& m); > > > > void notify(variables_map& m); > > > > > class variable_value { > public: > variable_value() : m_defaulted(false) {} > variable_value(const boost::any& xv, bool xdefaulted) > : v(xv), m_defaulted(xdefaulted) > {} > > > > template<class T> > const T& as() const { > return boost::any_cast<const T&>(v); > } > > template<class T> > T& as() { > return boost::any_cast<T&>(v); > } > > > bool empty() const; > > > bool defaulted() const; > > const boost::any& value() const; > > > boost::any& value(); > private: > boost::any v; > bool m_defaulted; > > > > > > shared_ptr<const value_semantic> m_value_semantic; > > friend > void store(const basic_parsed_options<char>& options, > variables_map& m, bool); > > friend class variables_map; > }; > > > > class abstract_variables_map { > public: > abstract_variables_map(); > abstract_variables_map(const abstract_variables_map* next); > > virtual ~abstract_variables_map() {} ># 127 "/usr/include/boost/program_options/variables_map.hpp" 3 4 > const variable_value& operator[](const std::string& name) const; > > > > void next(abstract_variables_map* next); > > private: > > > virtual const variable_value& get(const std::string& name) const = 0; > > const abstract_variables_map* m_next; > }; > > > > > > > class variables_map : public abstract_variables_map, > public std::map<std::string, variable_value> > { > public: > variables_map(); > variables_map(const abstract_variables_map* next); > > > const variable_value& operator[](const std::string& name) const > { return abstract_variables_map::operator[](name); } > > > void clear(); > > void notify(); > > private: > > > const variable_value& get(const std::string& name) const; > > > > std::set<std::string> m_final; > > friend > void store(const basic_parsed_options<char>& options, > variables_map& xm, > bool utf8); > > > > > > std::map<std::string, std::string> m_required; > }; > > > > > > > inline bool > variable_value::empty() const > { > return v.empty(); > } > > inline bool > variable_value::defaulted() const > { > return m_defaulted; > } > > inline > const boost::any& > variable_value::value() const > { > return v; > } > > inline > boost::any& > variable_value::value() > { > return v; > } > >}} ># 9 "/c/honeypenny/src/rpc/core_rpc_server.h" 2 > ># 1 "/c/honeypenny/contrib/epee/include/net/http_server_impl_base.h" 1 ># 30 "/c/honeypenny/contrib/epee/include/net/http_server_impl_base.h" > > > > > > ># 1 "/c/honeypenny/contrib/epee/include/net/http_server_cp2.h" 1 ># 33 "/c/honeypenny/contrib/epee/include/net/http_server_cp2.h" ># 1 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.h" 1 ># 45 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.h" ># 1 "/usr/include/boost/interprocess/detail/atomic.hpp" 1 3 4 ># 18 "/usr/include/boost/interprocess/detail/atomic.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 19 "/usr/include/boost/interprocess/detail/atomic.hpp" 2 3 4 ># 1 "/usr/include/boost/interprocess/detail/workaround.hpp" 1 3 4 ># 14 "/usr/include/boost/interprocess/detail/workaround.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 15 "/usr/include/boost/interprocess/detail/workaround.hpp" 2 3 4 ># 192 "/usr/include/boost/interprocess/detail/workaround.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 193 "/usr/include/boost/interprocess/detail/workaround.hpp" 2 3 4 ># 20 "/usr/include/boost/interprocess/detail/atomic.hpp" 2 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 21 "/usr/include/boost/interprocess/detail/atomic.hpp" 2 3 4 > >namespace boost{ >namespace interprocess{ >namespace ipcdetail{ > > > > >inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem); > > >inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem); > > > > >inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val); > > > > > > > >inline boost::uint32_t atomic_cas32 > (volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp); > >} >} >} ># 98 "/usr/include/boost/interprocess/detail/atomic.hpp" 3 4 >namespace boost { >namespace interprocess { >namespace ipcdetail{ > > > > > > > >inline boost::uint32_t atomic_cas32 > (volatile boost::uint32_t *mem, boost::uint32_t with, boost::uint32_t cmp) >{ > boost::uint32_t prev = cmp; > > __asm__ __volatile__ ( "lock\n\t" > "cmpxchg %2,%0" > : "+m"(*mem), "+a"(prev) > : "r"(with) > : "cc"); > > return prev; >} > > > > > >inline boost::uint32_t atomic_add32 > (volatile boost::uint32_t *mem, boost::uint32_t val) >{ > > > > int r; > > asm volatile > ( > "lock\n\t" > "xadd %1, %0": > "+m"( *mem ), "=r"( r ): > "1"( val ): > "memory", "cc" > ); > > return r; >} > > > > >inline boost::uint32_t atomic_inc32(volatile boost::uint32_t *mem) >{ return atomic_add32(mem, 1); } > > > > >inline boost::uint32_t atomic_dec32(volatile boost::uint32_t *mem) >{ return atomic_add32(mem, (boost::uint32_t)-1); } > > >inline boost::uint32_t atomic_read32(volatile boost::uint32_t *mem) >{ return *mem; } > > > > >inline void atomic_write32(volatile boost::uint32_t *mem, boost::uint32_t val) >{ *mem = val; } > >} >} >} ># 541 "/usr/include/boost/interprocess/detail/atomic.hpp" 3 4 >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; >} > >} >} >} > > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 561 "/usr/include/boost/interprocess/detail/atomic.hpp" 2 3 4 ># 46 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.h" 2 > ># 1 "/c/honeypenny/contrib/epee/include/net/net_utils_base.h" 1 ># 33 "/c/honeypenny/contrib/epee/include/net/net_utils_base.h" ># 1 "/c/honeypenny/contrib/epee/include/string_tools.h" 1 ># 34 "/c/honeypenny/contrib/epee/include/net/net_utils_base.h" 2 > > > > > > >namespace epee >{ >namespace net_utils >{ > > > > struct connection_context_base > { > const boost::uuids::uuid m_connection_id; > const uint32_t m_remote_ip; > const uint32_t m_remote_port; > const bool m_is_income; > const time_t m_started; > time_t m_last_recv; > time_t m_last_send; > uint64_t m_recv_cnt; > uint64_t m_send_cnt; > > connection_context_base(boost::uuids::uuid connection_id, long remote_ip, int remote_port, bool is_income, time_t last_recv = 0, time_t last_send = 0, uint64_t recv_cnt = 0, uint64_t send_cnt = 0): > m_connection_id(connection_id), > m_remote_ip(remote_ip), > m_remote_port(remote_port), > m_is_income(is_income), > m_last_recv(last_recv), > m_last_send(last_send), > m_recv_cnt(recv_cnt), > m_send_cnt(send_cnt), > m_started(time(__null)) > {} > > connection_context_base(): m_connection_id(), > m_remote_ip(0), > m_remote_port(0), > m_is_income(false), > m_last_recv(0), > m_last_send(0), > m_recv_cnt(0), > m_send_cnt(0), > m_started(time(__null)) > {} > > connection_context_base& operator=(const connection_context_base& a) > { > set_details(a.m_connection_id, a.m_remote_ip, a.m_remote_port, a.m_is_income); > return *this; > } > > private: > template<class t_protocol_handler> > friend class connection; > void set_details(boost::uuids::uuid connection_id, long remote_ip, int remote_port, bool is_income) > { > this->~connection_context_base(); > new(this) connection_context_base(connection_id, remote_ip, remote_port, is_income); > } > > }; > > > > > struct i_service_endpoint > { > virtual bool do_send(const void* ptr, size_t cb)=0; > virtual bool close()=0; > virtual bool call_run_once_service_io()=0; > virtual bool request_callback()=0; > virtual boost::asio::io_service& get_io_service()=0; > > virtual bool add_ref()=0; > virtual bool release()=0; > protected: > virtual ~i_service_endpoint(){} > }; > > > > > > inline > std::string print_connection_context(const connection_context_base& ctx) > { > std::stringstream ss; > ss << epee::string_tools::get_ip_string_from_int32(ctx.m_remote_ip) << ":" << ctx.m_remote_port << " " << epee::string_tools::get_str_from_guid_a(ctx.m_connection_id) << (ctx.m_is_income ? " INC":" OUT"); > return ss.str(); > } > > inline > std::string print_connection_context_short(const connection_context_base& ctx) > { > std::stringstream ss; > ss << epee::string_tools::get_ip_string_from_int32(ctx.m_remote_ip) << ":" << ctx.m_remote_port << (ctx.m_is_income ? " INC":" OUT"); > return ss.str(); > } ># 166 "/c/honeypenny/contrib/epee/include/net/net_utils_base.h" >} >} ># 48 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/syncobj.h" 1 ># 49 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.h" 2 > > > > >namespace epee >{ >namespace net_utils >{ > > struct i_connection_filter > { > virtual bool is_remote_ip_allowed(uint32_t adress)=0; > protected: > virtual ~i_connection_filter(){} > }; > > > > > > template<class t_protocol_handler> > class connection > : public boost::enable_shared_from_this<connection<t_protocol_handler> >, > private boost::noncopyable, > public i_service_endpoint > { > public: > typedef typename t_protocol_handler::connection_context t_connection_context; > > explicit connection(boost::asio::io_service& io_service, > typename t_protocol_handler::config_type& config, volatile uint32_t& sock_count, i_connection_filter * &pfilter); > > virtual ~connection(); > > boost::asio::ip::tcp::socket& socket(); > > > bool start(bool is_income, bool is_multithreaded); > > void get_context(t_connection_context& context_){context_ = context;} > > void call_back_starter(); > private: > > virtual bool do_send(const void* ptr, size_t cb); > virtual bool close(); > virtual bool call_run_once_service_io(); > virtual bool request_callback(); > virtual boost::asio::io_service& get_io_service(); > virtual bool add_ref(); > virtual bool release(); > > boost::shared_ptr<connection<t_protocol_handler> > safe_shared_from_this(); > bool shutdown(); > > void handle_read(const boost::system::error_code& e, > std::size_t bytes_transferred); > > > void handle_write(const boost::system::error_code& e, size_t cb); > > > boost::asio::io_service::strand strand_; > > > boost::asio::ip::tcp::socket socket_; > > > boost::array<char, 8192> buffer_; > > t_connection_context context; > volatile uint32_t m_want_close_connection; > std::atomic<bool> m_was_shutdown; > critical_section m_send_que_lock; > std::list<std::string> m_send_que; > volatile uint32_t& m_ref_sockets_count; > i_connection_filter* &m_pfilter; > volatile bool m_is_multithreaded; > > > t_protocol_handler m_protocol_handler; > > std::list<boost::shared_ptr<connection<t_protocol_handler> > > m_self_refs; > critical_section m_self_refs_lock; > }; > > > > > > template<class t_protocol_handler> > class boosted_tcp_server > : private boost::noncopyable > { > public: > typedef boost::shared_ptr<connection<t_protocol_handler> > connection_ptr; > typedef typename t_protocol_handler::connection_context t_connection_context; > > > boosted_tcp_server(); > explicit boosted_tcp_server(boost::asio::io_service& external_io_service); > ~boosted_tcp_server(); > > bool init_server(uint32_t port, const std::string address = "0.0.0.0"); > bool init_server(const std::string port, const std::string& address = "0.0.0.0"); > > > bool run_server(size_t threads_count, bool wait = true); > > > bool timed_wait_server_stop(uint64_t wait_mseconds); > > > void send_stop_signal(); > > bool is_stop_signal_sent(); > > void set_threads_prefix(const std::string& prefix_name); > > bool deinit_server(){return true;} > > size_t get_threads_count(){return m_threads_count;} > > void set_connection_filter(i_connection_filter* pfilter); > > bool connect(const std::string& adr, const std::string& port, uint32_t conn_timeot, t_connection_context& cn, const std::string& bind_ip = "0.0.0.0"); > template<class t_callback> > bool connect_async(const std::string& adr, const std::string& port, uint32_t conn_timeot, t_callback cb, const std::string& bind_ip = "0.0.0.0"); > > typename t_protocol_handler::config_type& get_config_object(){return m_config;} > > int get_binded_port(){return m_port;} > > boost::asio::io_service& get_io_service(){return io_service_;} > > struct idle_callback_conext_base > { > virtual ~idle_callback_conext_base(){} > > virtual bool call_handler(){return true;} > > idle_callback_conext_base(boost::asio::io_service& io_serice): > m_timer(io_serice) > {} > boost::asio::deadline_timer m_timer; > uint64_t m_period; > }; > > template <class t_handler> > struct idle_callback_conext: public idle_callback_conext_base > { > idle_callback_conext(boost::asio::io_service& io_serice, t_handler& h, uint64_t period): > idle_callback_conext_base(io_serice), > m_handler(h) > {this->m_period = period;} > > t_handler m_handler; > virtual bool call_handler() > { > return m_handler(); > } > }; > > template<class t_handler> > bool add_idle_handler(t_handler t_callback, uint64_t timeout_ms) > { > boost::shared_ptr<idle_callback_conext_base> ptr(new idle_callback_conext<t_handler>(io_service_, t_callback, timeout_ms)); > > ptr->m_timer.expires_from_now(boost::posix_time::milliseconds(ptr->m_period)); > ptr->m_timer.async_wait(boost::bind(&boosted_tcp_server<t_protocol_handler>::global_timer_handler, this, ptr)); > return true; > } > > bool global_timer_handler( boost::shared_ptr<idle_callback_conext_base> ptr) > { > > if(!ptr->call_handler()) > return true; > ptr->m_timer.expires_from_now(boost::posix_time::milliseconds(ptr->m_period)); > ptr->m_timer.async_wait(boost::bind(&boosted_tcp_server<t_protocol_handler>::global_timer_handler, this, ptr)); > return true; > } > > template<class t_handler> > bool async_call(t_handler t_callback) > { > io_service_.post(t_callback); > return true; > } > > protected: > typename t_protocol_handler::config_type m_config; > > private: > > bool worker_thread(); > > void handle_accept(const boost::system::error_code& e); > > bool is_thread_worker(); > > > std::unique_ptr<boost::asio::io_service> m_io_service_local_instance; > boost::asio::io_service& io_service_; > > > boost::asio::ip::tcp::acceptor acceptor_; > > > connection_ptr new_connection_; > std::atomic<bool> m_stop_signal_sent; > uint32_t m_port; > volatile uint32_t m_sockets_count; > std::string m_address; > std::string m_thread_name_prefix; > size_t m_threads_count; > i_connection_filter* m_pfilter; > std::vector<boost::shared_ptr<boost::thread> > m_threads; > boost::thread::id m_main_thread_id; > critical_section m_threads_lock; > volatile uint32_t m_thread_index; > }; >} >} > ># 1 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" 1 ># 30 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" ># 1 "/usr/include/boost/lambda/bind.hpp" 1 3 4 ># 15 "/usr/include/boost/lambda/bind.hpp" 3 4 ># 1 "/usr/include/boost/lambda/core.hpp" 1 3 4 ># 25 "/usr/include/boost/lambda/core.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/transform_traits.hpp" 1 3 4 ># 26 "/usr/include/boost/lambda/core.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/cv_traits.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/cv_traits.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/add_cv.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/add_cv.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/add_cv.hpp" 2 3 4 > >namespace boost { ># 34 "/usr/include/boost/type_traits/add_cv.hpp" 3 4 >template< typename T > struct add_cv { public: typedef T const volatile type; }; > > > > > > >template< typename T > struct add_cv<T&> { public: typedef T& type; }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 47 "/usr/include/boost/type_traits/add_cv.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/cv_traits.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/type_traits/remove_volatile.hpp" 1 3 4 ># 27 "/usr/include/boost/type_traits/remove_volatile.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 28 "/usr/include/boost/type_traits/remove_volatile.hpp" 2 3 4 > >namespace boost { > > > >namespace detail { > >template <typename T, bool is_const> >struct remove_volatile_helper >{ > typedef T type; >}; > >template <typename T> >struct remove_volatile_helper<T,true> >{ > typedef T const type; >}; > >template <typename T> >struct remove_volatile_impl >{ > typedef typename remove_volatile_helper< > typename cv_traits_imp<T*>::unqualified_type > , ::boost::is_const<T>::value > >::type type; >}; > > > > > > >template <typename T> >struct remove_volatile_impl<T&&> >{ > typedef T&& type; >}; > >} > > > >template< typename T > struct remove_volatile { public: typedef typename boost::detail::remove_volatile_impl<T>::type type; }; >template< typename T > struct remove_volatile<T&> { public: typedef T& type; }; > >template< typename T, std::size_t N > struct remove_volatile<T volatile[N]> { public: typedef T type[N]; }; >template< typename T, std::size_t N > struct remove_volatile<T const volatile[N]> { public: typedef T const type[N]; }; ># 84 "/usr/include/boost/type_traits/remove_volatile.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 87 "/usr/include/boost/type_traits/remove_volatile.hpp" 2 3 4 ># 22 "/usr/include/boost/type_traits/cv_traits.hpp" 2 3 4 ># 27 "/usr/include/boost/lambda/core.hpp" 2 3 4 > ># 1 "/usr/include/boost/tuple/tuple.hpp" 1 3 4 ># 33 "/usr/include/boost/tuple/tuple.hpp" 3 4 ># 1 "/usr/include/boost/tuple/detail/tuple_basic.hpp" 1 3 4 ># 44 "/usr/include/boost/tuple/detail/tuple_basic.hpp" 3 4 >namespace boost { >namespace tuples { > > >struct null_type {}; > > >namespace detail { > inline const null_type cnull() { return null_type(); } > > > > > >template <bool If, class Then, class Else> struct IF { typedef Then RET; }; > >template <class Then, class Else> struct IF<false, Then, Else> { > typedef Else RET; >}; > >} > > >template <class HT, class TT> struct cons; > > > >template < > class T0 = null_type, class T1 = null_type, class T2 = null_type, > class T3 = null_type, class T4 = null_type, class T5 = null_type, > class T6 = null_type, class T7 = null_type, class T8 = null_type, > class T9 = null_type> >class tuple; > > >template<class T> struct length; > > > >namespace detail { > > > >template<class T> >class generate_error; > >template<int N> >struct drop_front { > template<class Tuple> > struct apply { > typedef typename drop_front<N-1>::template > apply<Tuple> next; > typedef typename next::type::tail_type type; > static const type& call(const Tuple& tup) { > return next::call(tup).tail; > } > }; >}; > >template<> >struct drop_front<0> { > template<class Tuple> > struct apply { > typedef Tuple type; > static const type& call(const Tuple& tup) { > return tup; > } > }; >}; > >} ># 124 "/usr/include/boost/tuple/detail/tuple_basic.hpp" 3 4 >template<int N, class T> >struct element >{ > typedef typename detail::drop_front<N>::template > apply<T>::type::head_type type; >}; > >template<int N, class T> >struct element<N, const T> >{ >private: > typedef typename detail::drop_front<N>::template > apply<T>::type::head_type unqualified_type; >public: > > > > typedef typename boost::add_const<unqualified_type>::type type; > >}; ># 184 "/usr/include/boost/tuple/detail/tuple_basic.hpp" 3 4 >template <class T> struct access_traits { > typedef const T& const_type; > typedef T& non_const_type; > > typedef const typename boost::remove_cv<T>::type& parameter_type; > > > > > > >}; > >template <class T> struct access_traits<T&> { > > typedef T& const_type; > typedef T& non_const_type; > > typedef T& parameter_type; >}; > > > >template<int N, class HT, class TT> >inline typename access_traits< > typename element<N, cons<HT, TT> >::type > >::non_const_type >get(cons<HT, TT>& c ) { > typedef typename detail::drop_front<N>::template > apply<cons<HT, TT> > impl; > typedef typename impl::type cons_element; > return const_cast<cons_element&>(impl::call(c)).head; >} > > > > >template<int N, class HT, class TT> >inline typename access_traits< > typename element<N, cons<HT, TT> >::type > >::const_type >get(const cons<HT, TT>& c ) { > typedef typename detail::drop_front<N>::template > apply<cons<HT, TT> > impl; > typedef typename impl::type cons_element; > return impl::call(c).head; >} > > >namespace detail { > > > > > > > >template <class T> class non_storeable_type { > non_storeable_type(); >}; > >template <class T> struct wrap_non_storeable_type { > typedef typename IF< > ::boost::is_function<T>::value, non_storeable_type<T>, T > >::RET type; >}; >template <> struct wrap_non_storeable_type<void> { > typedef non_storeable_type<void> type; >}; > >} > >template <class HT, class TT> >struct cons { > > typedef HT head_type; > typedef TT tail_type; > > typedef typename > detail::wrap_non_storeable_type<head_type>::type stored_head_type; > > stored_head_type head; > tail_type tail; > > typename access_traits<stored_head_type>::non_const_type > get_head() { return head; } > > typename access_traits<tail_type>::non_const_type > get_tail() { return tail; } > > typename access_traits<stored_head_type>::const_type > get_head() const { return head; } > > typename access_traits<tail_type>::const_type > get_tail() const { return tail; } > > cons() : head(), tail() {} > > > > > > > > cons(typename access_traits<stored_head_type>::parameter_type h, > const tail_type& t) > : head (h), tail(t) {} > > template <class T1, class T2, class T3, class T4, class T5, > class T6, class T7, class T8, class T9, class T10> > cons( T1& t1, T2& t2, T3& t3, T4& t4, T5& t5, > T6& t6, T7& t7, T8& t8, T9& t9, T10& t10 ) > : head (t1), > tail (t2, t3, t4, t5, t6, t7, t8, t9, t10, detail::cnull()) > {} > > template <class T2, class T3, class T4, class T5, > class T6, class T7, class T8, class T9, class T10> > cons( const null_type& , T2& t2, T3& t3, T4& t4, T5& t5, > T6& t6, T7& t7, T8& t8, T9& t9, T10& t10 ) > : head (), > tail (t2, t3, t4, t5, t6, t7, t8, t9, t10, detail::cnull()) > {} > > > template <class HT2, class TT2> > cons( const cons<HT2, TT2>& u ) : head(u.head), tail(u.tail) {} > > template <class HT2, class TT2> > cons& operator=( const cons<HT2, TT2>& u ) { > head=u.head; tail=u.tail; return *this; > } > > > > cons& operator=(const cons& u) { > head = u.head; tail = u.tail; return *this; > } > > template <class T1, class T2> > cons& operator=( const std::pair<T1, T2>& u ) { > static_assert(length<cons>::value == 2, "length<cons>::value == 2"); > head = u.first; tail.head = u.second; return *this; > } > > > template <int N> > typename access_traits< > typename element<N, cons<HT, TT> >::type > >::non_const_type > get() { > return boost::tuples::get<N>(*this); > } > > template <int N> > typename access_traits< > typename element<N, cons<HT, TT> >::type > >::const_type > get() const { > return boost::tuples::get<N>(*this); > } >}; > >template <class HT> >struct cons<HT, null_type> { > > typedef HT head_type; > typedef null_type tail_type; > typedef cons<HT, null_type> self_type; > > typedef typename > detail::wrap_non_storeable_type<head_type>::type stored_head_type; > stored_head_type head; > > typename access_traits<stored_head_type>::non_const_type > get_head() { return head; } > > null_type get_tail() { return null_type(); } > > typename access_traits<stored_head_type>::const_type > get_head() const { return head; } > > const null_type get_tail() const { return null_type(); } > > > cons() : head() {} > > cons(typename access_traits<stored_head_type>::parameter_type h, > const null_type& = null_type()) > : head (h) {} > > template<class T1> > cons(T1& t1, const null_type&, const null_type&, const null_type&, > const null_type&, const null_type&, const null_type&, > const null_type&, const null_type&, const null_type&) > : head (t1) {} > > cons(const null_type&, > const null_type&, const null_type&, const null_type&, > const null_type&, const null_type&, const null_type&, > const null_type&, const null_type&, const null_type&) > : head () {} > > template <class HT2> > cons( const cons<HT2, null_type>& u ) : head(u.head) {} > > template <class HT2> > cons& operator=(const cons<HT2, null_type>& u ) > { head = u.head; return *this; } > > > > cons& operator=(const cons& u) { head = u.head; return *this; } > > template <int N> > typename access_traits< > typename element<N, self_type>::type > >::non_const_type > get() { > return boost::tuples::get<N>(*this); > } > > template <int N> > typename access_traits< > typename element<N, self_type>::type > >::const_type > get() const { > return boost::tuples::get<N>(*this); > } > >}; > > > >template<class T> >struct length { > static const int value = 1 + length<typename T::tail_type>::value; >}; > >template<> >struct length<tuple<> > { > static const int value = 0; >}; > >template<> >struct length<tuple<> const> { > static const int value = 0; >}; > >template<> >struct length<null_type> { > static const int value = 0; >}; > >template<> >struct length<null_type const> { > static const int value = 0; >}; > >namespace detail { > > >template <class T0, class T1, class T2, class T3, class T4, > class T5, class T6, class T7, class T8, class T9> >struct map_tuple_to_cons >{ > typedef cons<T0, > typename map_tuple_to_cons<T1, T2, T3, T4, T5, > T6, T7, T8, T9, null_type>::type > > type; >}; > > >template <> >struct map_tuple_to_cons<null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type> >{ > typedef null_type type; >}; > >} > > > >template <class T0, class T1, class T2, class T3, class T4, > class T5, class T6, class T7, class T8, class T9> > >class tuple : > public detail::map_tuple_to_cons<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type >{ >public: > typedef typename > detail::map_tuple_to_cons<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type inherited; > typedef typename inherited::head_type head_type; > typedef typename inherited::tail_type tail_type; > > > > tuple() {} > > tuple(typename access_traits<T0>::parameter_type t0) > : inherited(t0, detail::cnull(), detail::cnull(), detail::cnull(), > detail::cnull(), detail::cnull(), detail::cnull(), > detail::cnull(), detail::cnull(), detail::cnull()) {} > > tuple(typename access_traits<T0>::parameter_type t0, > typename access_traits<T1>::parameter_type t1) > : inherited(t0, t1, detail::cnull(), detail::cnull(), > detail::cnull(), detail::cnull(), detail::cnull(), > detail::cnull(), detail::cnull(), detail::cnull()) {} > > tuple(typename access_traits<T0>::parameter_type t0, > typename access_traits<T1>::parameter_type t1, > typename access_traits<T2>::parameter_type t2) > : inherited(t0, t1, t2, detail::cnull(), detail::cnull(), > detail::cnull(), detail::cnull(), detail::cnull(), > detail::cnull(), detail::cnull()) {} > > tuple(typename access_traits<T0>::parameter_type t0, > typename access_traits<T1>::parameter_type t1, > typename access_traits<T2>::parameter_type t2, > typename access_traits<T3>::parameter_type t3) > : inherited(t0, t1, t2, t3, detail::cnull(), detail::cnull(), > detail::cnull(), detail::cnull(), detail::cnull(), > detail::cnull()) {} > > tuple(typename access_traits<T0>::parameter_type t0, > typename access_traits<T1>::parameter_type t1, > typename access_traits<T2>::parameter_type t2, > typename access_traits<T3>::parameter_type t3, > typename access_traits<T4>::parameter_type t4) > : inherited(t0, t1, t2, t3, t4, detail::cnull(), detail::cnull(), > detail::cnull(), detail::cnull(), detail::cnull()) {} > > tuple(typename access_traits<T0>::parameter_type t0, > typename access_traits<T1>::parameter_type t1, > typename access_traits<T2>::parameter_type t2, > typename access_traits<T3>::parameter_type t3, > typename access_traits<T4>::parameter_type t4, > typename access_traits<T5>::parameter_type t5) > : inherited(t0, t1, t2, t3, t4, t5, detail::cnull(), detail::cnull(), > detail::cnull(), detail::cnull()) {} > > tuple(typename access_traits<T0>::parameter_type t0, > typename access_traits<T1>::parameter_type t1, > typename access_traits<T2>::parameter_type t2, > typename access_traits<T3>::parameter_type t3, > typename access_traits<T4>::parameter_type t4, > typename access_traits<T5>::parameter_type t5, > typename access_traits<T6>::parameter_type t6) > : inherited(t0, t1, t2, t3, t4, t5, t6, detail::cnull(), > detail::cnull(), detail::cnull()) {} > > tuple(typename access_traits<T0>::parameter_type t0, > typename access_traits<T1>::parameter_type t1, > typename access_traits<T2>::parameter_type t2, > typename access_traits<T3>::parameter_type t3, > typename access_traits<T4>::parameter_type t4, > typename access_traits<T5>::parameter_type t5, > typename access_traits<T6>::parameter_type t6, > typename access_traits<T7>::parameter_type t7) > : inherited(t0, t1, t2, t3, t4, t5, t6, t7, detail::cnull(), > detail::cnull()) {} > > tuple(typename access_traits<T0>::parameter_type t0, > typename access_traits<T1>::parameter_type t1, > typename access_traits<T2>::parameter_type t2, > typename access_traits<T3>::parameter_type t3, > typename access_traits<T4>::parameter_type t4, > typename access_traits<T5>::parameter_type t5, > typename access_traits<T6>::parameter_type t6, > typename access_traits<T7>::parameter_type t7, > typename access_traits<T8>::parameter_type t8) > : inherited(t0, t1, t2, t3, t4, t5, t6, t7, t8, detail::cnull()) {} > > tuple(typename access_traits<T0>::parameter_type t0, > typename access_traits<T1>::parameter_type t1, > typename access_traits<T2>::parameter_type t2, > typename access_traits<T3>::parameter_type t3, > typename access_traits<T4>::parameter_type t4, > typename access_traits<T5>::parameter_type t5, > typename access_traits<T6>::parameter_type t6, > typename access_traits<T7>::parameter_type t7, > typename access_traits<T8>::parameter_type t8, > typename access_traits<T9>::parameter_type t9) > : inherited(t0, t1, t2, t3, t4, t5, t6, t7, t8, t9) {} > > > template<class U1, class U2> > tuple(const cons<U1, U2>& p) : inherited(p) {} > > template <class U1, class U2> > tuple& operator=(const cons<U1, U2>& k) { > inherited::operator=(k); > return *this; > } > > template <class U1, class U2> > tuple& operator=(const std::pair<U1, U2>& k) { > static_assert(length<tuple>::value == 2, "length<tuple>::value == 2"); > this->head = k.first; > this->tail.head = k.second; > return *this; > } > >}; > > >template <> >class tuple<null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type> : > public null_type >{ >public: > typedef null_type inherited; >}; > > > >namespace detail { > >struct swallow_assign; >typedef void (detail::swallow_assign::*ignore_t)(); >struct swallow_assign { > swallow_assign(ignore_t(*)(ignore_t)) {} > template<typename T> > swallow_assign const& operator=(const T&) const { > return *this; > } >}; > > >} > > >inline detail::ignore_t ignore(detail::ignore_t) { return 0; } ># 636 "/usr/include/boost/tuple/detail/tuple_basic.hpp" 3 4 >template<class T> >struct make_tuple_traits { > typedef T type; > > > > > > > >}; ># 660 "/usr/include/boost/tuple/detail/tuple_basic.hpp" 3 4 >template<class T> >struct make_tuple_traits<T&> { > typedef typename > detail::generate_error<T&>:: > do_not_use_with_reference_type error; >}; > > > > > >template<class T, int n> struct make_tuple_traits <T[n]> { > typedef const T (&type)[n]; >}; > >template<class T, int n> >struct make_tuple_traits<const T[n]> { > typedef const T (&type)[n]; >}; > >template<class T, int n> struct make_tuple_traits<volatile T[n]> { > typedef const volatile T (&type)[n]; >}; > >template<class T, int n> >struct make_tuple_traits<const volatile T[n]> { > typedef const volatile T (&type)[n]; >}; > >template<class T> >struct make_tuple_traits<reference_wrapper<T> >{ > typedef T& type; >}; > >template<class T> >struct make_tuple_traits<const reference_wrapper<T> >{ > typedef T& type; >}; > >template<> >struct make_tuple_traits<detail::ignore_t(detail::ignore_t)> { > typedef detail::swallow_assign type; >}; > > > >namespace detail { > > > >template < > class T0 = null_type, class T1 = null_type, class T2 = null_type, > class T3 = null_type, class T4 = null_type, class T5 = null_type, > class T6 = null_type, class T7 = null_type, class T8 = null_type, > class T9 = null_type >> >struct make_tuple_mapper { > typedef > tuple<typename make_tuple_traits<T0>::type, > typename make_tuple_traits<T1>::type, > typename make_tuple_traits<T2>::type, > typename make_tuple_traits<T3>::type, > typename make_tuple_traits<T4>::type, > typename make_tuple_traits<T5>::type, > typename make_tuple_traits<T6>::type, > typename make_tuple_traits<T7>::type, > typename make_tuple_traits<T8>::type, > typename make_tuple_traits<T9>::type> type; >}; > >} > > >inline tuple<> make_tuple() { > return tuple<>(); >} > >template<class T0> >inline typename detail::make_tuple_mapper<T0>::type >make_tuple(const T0& t0) { > typedef typename detail::make_tuple_mapper<T0>::type t; > return t(t0); >} > >template<class T0, class T1> >inline typename detail::make_tuple_mapper<T0, T1>::type >make_tuple(const T0& t0, const T1& t1) { > typedef typename detail::make_tuple_mapper<T0, T1>::type t; > return t(t0, t1); >} > >template<class T0, class T1, class T2> >inline typename detail::make_tuple_mapper<T0, T1, T2>::type >make_tuple(const T0& t0, const T1& t1, const T2& t2) { > typedef typename detail::make_tuple_mapper<T0, T1, T2>::type t; > return t(t0, t1, t2); >} > >template<class T0, class T1, class T2, class T3> >inline typename detail::make_tuple_mapper<T0, T1, T2, T3>::type >make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3) { > typedef typename detail::make_tuple_mapper<T0, T1, T2, T3>::type t; > return t(t0, t1, t2, t3); >} > >template<class T0, class T1, class T2, class T3, class T4> >inline typename detail::make_tuple_mapper<T0, T1, T2, T3, T4>::type >make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3, > const T4& t4) { > typedef typename detail::make_tuple_mapper<T0, T1, T2, T3, T4>::type t; > return t(t0, t1, t2, t3, t4); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5> >inline typename detail::make_tuple_mapper<T0, T1, T2, T3, T4, T5>::type >make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3, > const T4& t4, const T5& t5) { > typedef typename detail::make_tuple_mapper<T0, T1, T2, T3, T4, T5>::type t; > return t(t0, t1, t2, t3, t4, t5); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5, class T6> >inline typename detail::make_tuple_mapper<T0, T1, T2, T3, T4, T5, T6>::type >make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3, > const T4& t4, const T5& t5, const T6& t6) { > typedef typename detail::make_tuple_mapper > <T0, T1, T2, T3, T4, T5, T6>::type t; > return t(t0, t1, t2, t3, t4, t5, t6); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5, class T6, > class T7> >inline typename detail::make_tuple_mapper<T0, T1, T2, T3, T4, T5, T6, T7>::type >make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3, > const T4& t4, const T5& t5, const T6& t6, const T7& t7) { > typedef typename detail::make_tuple_mapper > <T0, T1, T2, T3, T4, T5, T6, T7>::type t; > return t(t0, t1, t2, t3, t4, t5, t6, t7); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5, class T6, > class T7, class T8> >inline typename detail::make_tuple_mapper > <T0, T1, T2, T3, T4, T5, T6, T7, T8>::type >make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3, > const T4& t4, const T5& t5, const T6& t6, const T7& t7, > const T8& t8) { > typedef typename detail::make_tuple_mapper > <T0, T1, T2, T3, T4, T5, T6, T7, T8>::type t; > return t(t0, t1, t2, t3, t4, t5, t6, t7, t8); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5, class T6, > class T7, class T8, class T9> >inline typename detail::make_tuple_mapper > <T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type >make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3, > const T4& t4, const T5& t5, const T6& t6, const T7& t7, > const T8& t8, const T9& t9) { > typedef typename detail::make_tuple_mapper > <T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type t; > return t(t0, t1, t2, t3, t4, t5, t6, t7, t8, t9); >} > >namespace detail { > >template<class T> >struct tie_traits { > typedef T& type; >}; > >template<> >struct tie_traits<ignore_t(ignore_t)> { > typedef swallow_assign type; >}; > >template<> >struct tie_traits<void> { > typedef null_type type; >}; > >template < > class T0 = void, class T1 = void, class T2 = void, > class T3 = void, class T4 = void, class T5 = void, > class T6 = void, class T7 = void, class T8 = void, > class T9 = void >> >struct tie_mapper { > typedef > tuple<typename tie_traits<T0>::type, > typename tie_traits<T1>::type, > typename tie_traits<T2>::type, > typename tie_traits<T3>::type, > typename tie_traits<T4>::type, > typename tie_traits<T5>::type, > typename tie_traits<T6>::type, > typename tie_traits<T7>::type, > typename tie_traits<T8>::type, > typename tie_traits<T9>::type> type; >}; > >} > > >template<class T0> >inline typename detail::tie_mapper<T0>::type >tie(T0& t0) { > typedef typename detail::tie_mapper<T0>::type t; > return t(t0); >} > >template<class T0, class T1> >inline typename detail::tie_mapper<T0, T1>::type >tie(T0& t0, T1& t1) { > typedef typename detail::tie_mapper<T0, T1>::type t; > return t(t0, t1); >} > >template<class T0, class T1, class T2> >inline typename detail::tie_mapper<T0, T1, T2>::type >tie(T0& t0, T1& t1, T2& t2) { > typedef typename detail::tie_mapper<T0, T1, T2>::type t; > return t(t0, t1, t2); >} > >template<class T0, class T1, class T2, class T3> >inline typename detail::tie_mapper<T0, T1, T2, T3>::type >tie(T0& t0, T1& t1, T2& t2, T3& t3) { > typedef typename detail::tie_mapper<T0, T1, T2, T3>::type t; > return t(t0, t1, t2, t3); >} > >template<class T0, class T1, class T2, class T3, class T4> >inline typename detail::tie_mapper<T0, T1, T2, T3, T4>::type >tie(T0& t0, T1& t1, T2& t2, T3& t3, > T4& t4) { > typedef typename detail::tie_mapper<T0, T1, T2, T3, T4>::type t; > return t(t0, t1, t2, t3, t4); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5> >inline typename detail::tie_mapper<T0, T1, T2, T3, T4, T5>::type >tie(T0& t0, T1& t1, T2& t2, T3& t3, > T4& t4, T5& t5) { > typedef typename detail::tie_mapper<T0, T1, T2, T3, T4, T5>::type t; > return t(t0, t1, t2, t3, t4, t5); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5, class T6> >inline typename detail::tie_mapper<T0, T1, T2, T3, T4, T5, T6>::type >tie(T0& t0, T1& t1, T2& t2, T3& t3, > T4& t4, T5& t5, T6& t6) { > typedef typename detail::tie_mapper > <T0, T1, T2, T3, T4, T5, T6>::type t; > return t(t0, t1, t2, t3, t4, t5, t6); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5, class T6, > class T7> >inline typename detail::tie_mapper<T0, T1, T2, T3, T4, T5, T6, T7>::type >tie(T0& t0, T1& t1, T2& t2, T3& t3, > T4& t4, T5& t5, T6& t6, T7& t7) { > typedef typename detail::tie_mapper > <T0, T1, T2, T3, T4, T5, T6, T7>::type t; > return t(t0, t1, t2, t3, t4, t5, t6, t7); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5, class T6, > class T7, class T8> >inline typename detail::tie_mapper > <T0, T1, T2, T3, T4, T5, T6, T7, T8>::type >tie(T0& t0, T1& t1, T2& t2, T3& t3, > T4& t4, T5& t5, T6& t6, T7& t7, > T8& t8) { > typedef typename detail::tie_mapper > <T0, T1, T2, T3, T4, T5, T6, T7, T8>::type t; > return t(t0, t1, t2, t3, t4, t5, t6, t7, t8); >} > >template<class T0, class T1, class T2, class T3, class T4, class T5, class T6, > class T7, class T8, class T9> >inline typename detail::tie_mapper > <T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type >tie(T0& t0, T1& t1, T2& t2, T3& t3, > T4& t4, T5& t5, T6& t6, T7& t7, > T8& t8, T9& t9) { > typedef typename detail::tie_mapper > <T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type t; > return t(t0, t1, t2, t3, t4, t5, t6, t7, t8, t9); >} > >template <class T0, class T1, class T2, class T3, class T4, > class T5, class T6, class T7, class T8, class T9> >void swap(tuple<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>& lhs, > tuple<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>& rhs); >inline void swap(null_type&, null_type&) {} >template<class HH> >inline void swap(cons<HH, null_type>& lhs, cons<HH, null_type>& rhs) { > ::boost::swap(lhs.head, rhs.head); >} >template<class HH, class TT> >inline void swap(cons<HH, TT>& lhs, cons<HH, TT>& rhs) { > ::boost::swap(lhs.head, rhs.head); > ::boost::tuples::swap(lhs.tail, rhs.tail); >} >template <class T0, class T1, class T2, class T3, class T4, > class T5, class T6, class T7, class T8, class T9> >inline void swap(tuple<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>& lhs, > tuple<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>& rhs) { > typedef tuple<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9> tuple_type; > typedef typename tuple_type::inherited base; > ::boost::tuples::swap(static_cast<base&>(lhs), static_cast<base&>(rhs)); >} > >} >} ># 34 "/usr/include/boost/tuple/tuple.hpp" 2 3 4 > > > >namespace boost { > >using tuples::tuple; >using tuples::make_tuple; >using tuples::tie; > >using tuples::get; ># 87 "/usr/include/boost/tuple/tuple.hpp" 3 4 >} ># 29 "/usr/include/boost/lambda/core.hpp" 2 3 4 > > >namespace boost { >namespace lambda { > >using ::boost::tuples::tuple; >using ::boost::tuples::null_type; > >} >} > ># 1 "/usr/include/boost/lambda/detail/lambda_config.hpp" 1 3 4 ># 41 "/usr/include/boost/lambda/core.hpp" 2 3 4 ># 1 "/usr/include/boost/lambda/detail/lambda_fwd.hpp" 1 3 4 ># 16 "/usr/include/boost/lambda/detail/lambda_fwd.hpp" 3 4 >namespace boost { >namespace lambda { > >namespace detail { > >template<class T> struct generate_error; > >} > > >template <int I> struct placeholder; > > >template <class Func> >struct function_adaptor; > >template <int I, class Act> class action; > >template <class Base> >class lambda_functor; > >template <class Act, class Args> >class lambda_functor_base; > >} >} ># 57 "/usr/include/boost/lambda/detail/lambda_fwd.hpp" 3 4 >namespace boost { >namespace lambda { >namespace detail { > >template<class A1, class A2, class A3, class A4> >void do_nothing(A1&, A2&, A3&, A4&) {} > >} >} >} ># 42 "/usr/include/boost/lambda/core.hpp" 2 3 4 > ># 1 "/usr/include/boost/lambda/detail/arity_code.hpp" 1 3 4 ># 19 "/usr/include/boost/lambda/detail/arity_code.hpp" 3 4 >namespace boost { >namespace lambda { ># 30 "/usr/include/boost/lambda/detail/arity_code.hpp" 3 4 >enum { NONE = 0x00, > FIRST = 0x01, > SECOND = 0x02, > THIRD = 0x04, > EXCEPTION = 0x08, > RETHROW = 0x10}; > > >template<class T> >struct get_tuple_arity; > >namespace detail { > >template <class T> struct get_arity_; > >} > >template <class T> struct get_arity { > > static const int value = detail::get_arity_<typename boost::remove_cv<typename boost::remove_reference<T>::type>::type>::value; > >}; > >namespace detail { > >template<class T> >struct get_arity_ { > static const int value = 0; >}; > >template<class T> >struct get_arity_<lambda_functor<T> > { > static const int value = get_arity<T>::value; >}; > >template<class Action, class Args> >struct get_arity_<lambda_functor_base<Action, Args> > { > static const int value = get_tuple_arity<Args>::value; >}; > >template<int I> >struct get_arity_<placeholder<I> > { > static const int value = I; >}; > >} > >template<class T> >struct get_tuple_arity { > static const int value = get_arity<typename T::head_type>::value | get_tuple_arity<typename T::tail_type>::value; >}; > > >template<> >struct get_tuple_arity<null_type> { > static const int value = 0; >}; > > > > >template<class T, int I> >struct has_placeholder { > static const bool value = (get_arity<T>::value & I) != 0; >}; > >template<int I, int J> >struct includes_placeholder { > static const bool value = (J & I) != 0; >}; > >template<int I, int J> >struct lacks_placeholder { > static const bool value = ((J & I) == 0); >}; > > >} >} ># 44 "/usr/include/boost/lambda/core.hpp" 2 3 4 ># 1 "/usr/include/boost/lambda/detail/actions.hpp" 1 3 4 ># 16 "/usr/include/boost/lambda/detail/actions.hpp" 3 4 >namespace boost { >namespace lambda { > > > >template<int Arity, class Act> class action; > > > > >class assignment_action {}; >class subscript_action {}; > >template <class Action> class other_action; > > >template <class RET> class explicit_return_type_action {}; > > >struct protect_action {}; > > >struct comma_action {}; > > > > > >template <class Action> struct is_protectable { > static const bool value = false; >}; > > > > >template<> struct is_protectable<other_action<comma_action> > { > static const bool value = true; >}; > > >namespace detail { > > > > > class unspecified {}; >} > > > > > > > >template <int I, class Result_type = detail::unspecified> >class function_action {}; > >template<class T> class function_action<1, T> { >public: > template<class RET, class A1> > static RET apply(A1& a1) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1); > } >}; > >template<class T> class function_action<2, T> { >public: > template<class RET, class A1, class A2> > static RET apply(A1& a1, A2& a2) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1, a2); > } >}; > >template<class T> class function_action<3, T> { >public: > template<class RET, class A1, class A2, class A3> > static RET apply(A1& a1, A2& a2, A3& a3) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1, a2, a3); > } >}; > >template<class T> class function_action<4, T> { >public: > template<class RET, class A1, class A2, class A3, class A4> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1, a2, a3, a4); > } >}; > >template<class T> class function_action<5, T> { >public: > template<class RET, class A1, class A2, class A3, class A4, class A5> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1, a2, a3, a4, a5); > } >}; > >template<class T> class function_action<6, T> { >public: > template<class RET, class A1, class A2, class A3, class A4, class A5, > class A6> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1, a2, a3, a4, a5, a6); > } >}; > >template<class T> class function_action<7, T> { >public: > template<class RET, class A1, class A2, class A3, class A4, class A5, > class A6, class A7> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1, a2, a3, a4, a5, a6, a7); > } >}; > >template<class T> class function_action<8, T> { >public: > template<class RET, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, > A8& a8) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1, a2, a3, a4, a5, a6, a7, a8); > } >}; > >template<class T> class function_action<9, T> { >public: > template<class RET, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8, class A9> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, > A8& a8, A9& a9) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1, a2, a3, a4, a5, a6, a7, a8, a9); > } >}; > >template<class T> class function_action<10, T> { >public: > template<class RET, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8, class A9, class A10> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, > A8& a8, A9& a9, A10& a10) { > return function_adaptor<typename boost::remove_cv<A1>::type>:: > template apply<RET>(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10); > } >}; > >} >} ># 45 "/usr/include/boost/lambda/core.hpp" 2 3 4 > ># 1 "/usr/include/boost/lambda/detail/lambda_traits.hpp" 1 3 4 ># 18 "/usr/include/boost/lambda/detail/lambda_traits.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/object_traits.hpp" 1 3 4 ># 26 "/usr/include/boost/type_traits/object_traits.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_compound.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/is_compound.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/is_compound.hpp" 2 3 4 > >namespace boost { > > >namespace detail { > >template <typename T> >struct is_compound_impl >{ > static const bool value = (::boost::type_traits::ice_not< ::boost::is_fundamental<T>::value >::value) > > > ; >}; > >} > > > > > >template< typename T > struct is_compound : public ::boost::integral_constant<bool,::boost::detail::is_compound_impl<T>::value> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 45 "/usr/include/boost/type_traits/is_compound.hpp" 2 3 4 ># 27 "/usr/include/boost/type_traits/object_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_empty.hpp" 1 3 4 ># 32 "/usr/include/boost/type_traits/is_empty.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 33 "/usr/include/boost/type_traits/is_empty.hpp" 2 3 4 > > > > > > > >namespace boost { > >namespace detail { ># 51 "/usr/include/boost/type_traits/is_empty.hpp" 3 4 >template <typename T> >struct empty_helper_t1 : public T >{ > empty_helper_t1(); > int i[256]; >private: > > empty_helper_t1(const empty_helper_t1&); > empty_helper_t1& operator=(const empty_helper_t1&); >}; > > > > > >struct empty_helper_t2 { int i[256]; }; > > > >template <typename T, bool is_a_class = false> >struct empty_helper >{ > static const bool value = false; >}; > >template <typename T> >struct empty_helper<T, true> >{ > static const bool value = (sizeof(empty_helper_t1<T>) == sizeof(empty_helper_t2)) > > ; >}; > >template <typename T> >struct is_empty_impl >{ > typedef typename remove_cv<T>::type cvt; > static const bool value = ( ::boost::type_traits::ice_or< ::boost::detail::empty_helper<cvt,::boost::is_class<T>::value>::value , false >::value ) > > > > > > ; >}; ># 211 "/usr/include/boost/type_traits/is_empty.hpp" 3 4 >template<> struct is_empty_impl< void > { public: static const bool value = (false); }; > >template<> struct is_empty_impl< void const > { public: static const bool value = (false); }; >template<> struct is_empty_impl< void volatile > { public: static const bool value = (false); }; >template<> struct is_empty_impl< void const volatile > { public: static const bool value = (false); }; > > >} > >template< typename T > struct is_empty : public ::boost::integral_constant<bool,::boost::detail::is_empty_impl<T>::value> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 225 "/usr/include/boost/type_traits/is_empty.hpp" 2 3 4 ># 28 "/usr/include/boost/type_traits/object_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/type_traits/is_object.hpp" 1 3 4 ># 20 "/usr/include/boost/type_traits/is_object.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 21 "/usr/include/boost/type_traits/is_object.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct is_object_impl >{ > > static const bool value = (::boost::type_traits::ice_and< ::boost::type_traits::ice_not< ::boost::is_reference<T>::value>::value, ::boost::type_traits::ice_not< ::boost::is_void<T>::value>::value, ::boost::type_traits::ice_not< ::boost::is_function<T>::value>::value >::value) > > > > > ; > > > > > > > >}; > >} > >template< typename T > struct is_object : public ::boost::integral_constant<bool,::boost::detail::is_object_impl<T>::value> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 52 "/usr/include/boost/type_traits/is_object.hpp" 2 3 4 ># 29 "/usr/include/boost/type_traits/object_traits.hpp" 2 3 4 > > ># 1 "/usr/include/boost/type_traits/is_stateless.hpp" 1 3 4 ># 21 "/usr/include/boost/type_traits/is_stateless.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 22 "/usr/include/boost/type_traits/is_stateless.hpp" 2 3 4 > >namespace boost { > >namespace detail { > >template <typename T> >struct is_stateless_impl >{ > static const bool value = (::boost::type_traits::ice_and< ::boost::has_trivial_constructor<T>::value, ::boost::has_trivial_copy<T>::value, ::boost::has_trivial_destructor<T>::value, ::boost::is_class<T>::value, ::boost::is_empty<T>::value >::value) > > > > > > > ; >}; > >} > >template< typename T > struct is_stateless : public ::boost::integral_constant<bool,::boost::detail::is_stateless_impl<T>::value> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 47 "/usr/include/boost/type_traits/is_stateless.hpp" 2 3 4 ># 32 "/usr/include/boost/type_traits/object_traits.hpp" 2 3 4 ># 19 "/usr/include/boost/lambda/detail/lambda_traits.hpp" 2 3 4 > > >namespace boost { >namespace lambda { > > > > >namespace detail { > >template <bool If, class Then, class Else> struct IF { typedef Then RET; }; > >template <class Then, class Else> struct IF<false, Then, Else> { > typedef Else RET; >}; ># 43 "/usr/include/boost/lambda/detail/lambda_traits.hpp" 3 4 >template<class T> >struct IF_type_ >{ > typedef typename T::type type; >}; > > >template<bool C, class T, class E> >struct IF_type >{ > typedef typename > IF_type_<typename IF<C, T, E>::RET >::type type; >}; > > >template <class T> struct identity_mapping { typedef T type; }; > > > > > > >template<class T> >struct IF_value_ >{ > static const int value = T::value; >}; > > >template<bool C, class T, class E> >struct IF_value >{ > static const int value = (IF_value_<typename IF<C, T, E>::RET>::value); >}; > > > > > >template<class T> class remove_reference_if_valid >{ > > typedef typename boost::remove_reference<T>::type plainT; >public: > typedef typename IF< > boost::is_function<plainT>::value, > T, > plainT > >::RET type; > >}; > > >template<class T> struct remove_reference_and_cv { > typedef typename boost::remove_cv< > typename boost::remove_reference<T>::type > >::type type; >}; > > > > >template<int N, class T> struct tuple_element_as_reference { > typedef typename > boost::tuples::access_traits< > typename boost::tuples::element<N, T>::type > >::non_const_type type; >}; > > >template<int N, class T> struct tuple_element_stripped { > typedef typename > remove_reference_and_cv< > typename boost::tuples::element<N, T>::type > >::type type; >}; > > > >template <class T> struct is_lambda_functor_ { > static const bool value = false; >}; > >template <class Arg> struct is_lambda_functor_<lambda_functor<Arg> > { > static const bool value = true; >}; > >} > > >template <class T> struct is_lambda_functor { > static const bool value = detail::is_lambda_functor_< typename detail::remove_reference_and_cv<T>::type >::value > > > > ; >}; > > >namespace detail { ># 159 "/usr/include/boost/lambda/detail/lambda_traits.hpp" 3 4 >template<class T1, class T2> >struct parameter_traits_ { > typedef T2 type; >}; > > >template<class T, class Any> struct parameter_traits_<T&, Any> { > typedef typename > generate_error<T&>:: > parameter_traits_class_instantiated_with_reference_type type; >}; > > >template<class T, int n, class Any> struct parameter_traits_<T[n], Any> { > typedef T (&type)[n]; >}; > >template<class T, int n, class Any> >struct parameter_traits_<const T[n], Any> { > typedef const T (&type)[n]; >}; > >template<class T, int n, class Any> >struct parameter_traits_<volatile T[n], Any> { > typedef volatile T (&type)[n]; >}; >template<class T, int n, class Any> >struct parameter_traits_<const volatile T[n], Any> { > typedef const volatile T (&type)[n]; >}; > > >template<class T, class Any> >struct parameter_traits_<boost::reference_wrapper<T>, Any >{ > typedef T& type; >}; > >template<class T, class Any> >struct parameter_traits_<const boost::reference_wrapper<T>, Any >{ > typedef T& type; >}; > >template<class T, class Any> >struct parameter_traits_<volatile boost::reference_wrapper<T>, Any >{ > typedef T& type; >}; > >template<class T, class Any> >struct parameter_traits_<const volatile boost::reference_wrapper<T>, Any >{ > typedef T& type; >}; > >template<class Any> >struct parameter_traits_<void, Any> { > typedef void type; >}; > >template<class Arg, class Any> >struct parameter_traits_<lambda_functor<Arg>, Any > { > typedef lambda_functor<Arg> type; >}; > >template<class Arg, class Any> >struct parameter_traits_<const lambda_functor<Arg>, Any > { > typedef lambda_functor<Arg> type; >}; > > >template<class Arg, class Any> >struct parameter_traits_<volatile lambda_functor<Arg>, Any > { > typedef lambda_functor<Arg> type; >}; > >template<class Arg, class Any> >struct parameter_traits_<const volatile lambda_functor<Arg>, Any > { > typedef lambda_functor<Arg> type; >}; > >} ># 251 "/usr/include/boost/lambda/detail/lambda_traits.hpp" 3 4 >template<class T> >struct const_copy_argument { > typedef typename > detail::parameter_traits_< > T, > typename detail::IF<boost::is_function<T>::value, T&, const T>::RET > >::type type; >}; ># 267 "/usr/include/boost/lambda/detail/lambda_traits.hpp" 3 4 >template<class T, int n> struct const_copy_argument <T[n]> { > typedef const T (&type)[n]; >}; >template<class T, int n> struct const_copy_argument <volatile T[n]> { > typedef const volatile T (&type)[n]; >}; > >template<class T> >struct const_copy_argument<T&> {}; > > > > >template<> >struct const_copy_argument<void> { > typedef void type; >}; > > > >template<class T> >struct bound_argument_conversion { > typedef typename const_copy_argument<T>::type type; >}; > >template<class T> >struct bound_argument_conversion<T&> { > typedef T& type; >}; > > > > > > >template<class T> >struct reference_argument { > typedef typename detail::parameter_traits_<T, T&>::type type; >}; > >template<class T> >struct reference_argument<T&> { > typedef typename detail::generate_error<T&>::references_not_allowed type; >}; > >template<class Arg> >struct reference_argument<lambda_functor<Arg> > { > typedef lambda_functor<Arg> type; >}; > >template<class Arg> >struct reference_argument<const lambda_functor<Arg> > { > typedef lambda_functor<Arg> type; >}; > > >template<class Arg> >struct reference_argument<volatile lambda_functor<Arg> > { > typedef lambda_functor<Arg> type; >}; > >template<class Arg> >struct reference_argument<const volatile lambda_functor<Arg> > { > typedef lambda_functor<Arg> type; >}; > >template<> >struct reference_argument<void> { > typedef void type; >}; > >namespace detail { > > >template <class T> >struct array_to_pointer { > typedef T type; >}; > >template <class T, int N> >struct array_to_pointer <const T[N]> { > typedef const T* type; >}; >template <class T, int N> >struct array_to_pointer <T[N]> { > typedef T* type; >}; > >template <class T, int N> >struct array_to_pointer <const T (&) [N]> { > typedef const T* type; >}; >template <class T, int N> >struct array_to_pointer <T (&) [N]> { > typedef T* type; >}; ># 388 "/usr/include/boost/lambda/detail/lambda_traits.hpp" 3 4 >template<class T> >struct bind_traits { > typedef const T type; >}; > >template<class T> >struct bind_traits<T&> { > typedef T& type; >}; > > > >template<> >struct bind_traits<null_type> { > typedef null_type type; >}; > > > >template<> >struct bind_traits<const null_type> { > typedef null_type type; >}; > > > > > >template<class T, int n> struct bind_traits <T[n]> { > typedef const T (&type)[n]; >}; > >template<class T, int n> >struct bind_traits<const T[n]> { > typedef const T (&type)[n]; >}; > >template<class T, int n> struct bind_traits<volatile T[n]> { > typedef const volatile T (&type)[n]; >}; > >template<class T, int n> >struct bind_traits<const volatile T[n]> { > typedef const volatile T (&type)[n]; >}; > >template<class R> >struct bind_traits<R()> { > typedef R(&type)(); >}; > >template<class R, class Arg1> >struct bind_traits<R(Arg1)> { > typedef R(&type)(Arg1); >}; > >template<class R, class Arg1, class Arg2> >struct bind_traits<R(Arg1, Arg2)> { > typedef R(&type)(Arg1, Arg2); >}; > >template<class R, class Arg1, class Arg2, class Arg3> >struct bind_traits<R(Arg1, Arg2, Arg3)> { > typedef R(&type)(Arg1, Arg2, Arg3); >}; > >template<class R, class Arg1, class Arg2, class Arg3, class Arg4> >struct bind_traits<R(Arg1, Arg2, Arg3, Arg4)> { > typedef R(&type)(Arg1, Arg2, Arg3, Arg4); >}; > >template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5> >struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5)> { > typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5); >}; > >template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6> >struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6)> { > typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6); >}; > >template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7> >struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7)> { > typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7); >}; > >template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8> >struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8)> { > typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8); >}; > >template<class R, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Arg9> >struct bind_traits<R(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9)> { > typedef R(&type)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9); >}; > >template<class T> >struct bind_traits<reference_wrapper<T> >{ > typedef T& type; >}; > >template<class T> >struct bind_traits<const reference_wrapper<T> >{ > typedef T& type; >}; > >template<> >struct bind_traits<void> { > typedef void type; >}; > > > >template < > class T0 = null_type, class T1 = null_type, class T2 = null_type, > class T3 = null_type, class T4 = null_type, class T5 = null_type, > class T6 = null_type, class T7 = null_type, class T8 = null_type, > class T9 = null_type >> >struct bind_tuple_mapper { > typedef > tuple<typename bind_traits<T0>::type, > typename bind_traits<T1>::type, > typename bind_traits<T2>::type, > typename bind_traits<T3>::type, > typename bind_traits<T4>::type, > typename bind_traits<T5>::type, > typename bind_traits<T6>::type, > typename bind_traits<T7>::type, > typename bind_traits<T8>::type, > typename bind_traits<T9>::type> type; >}; > > > > > template <class T> struct remove_const_reference { > typedef typename bind_traits<T>::type type; > }; > > template <class T> struct remove_const_reference<const T&> { > typedef const T type; > }; > > > >template < > class T0 = null_type, class T1 = null_type, class T2 = null_type, > class T3 = null_type, class T4 = null_type, class T5 = null_type, > class T6 = null_type, class T7 = null_type, class T8 = null_type, > class T9 = null_type >> >class bind_type_generator { > > typedef typename > detail::bind_tuple_mapper< > T0, T1, T2, T3, T4, T5, T6, T7, T8, T9 > >::type args_t; > > static const int nof_elems = boost::tuples::length<args_t>::value; > > typedef > action< > nof_elems, > function_action<nof_elems> > > action_type; > >public: > typedef > lambda_functor< > lambda_functor_base< > action_type, > args_t > > > > type; > >}; > > > >} > >template <class T> inline const T& make_const(const T& t) { return t; } > > >} >} ># 47 "/usr/include/boost/lambda/core.hpp" 2 3 4 > ># 1 "/usr/include/boost/lambda/detail/function_adaptors.hpp" 1 3 4 ># 17 "/usr/include/boost/lambda/detail/function_adaptors.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/same_traits.hpp" 1 3 4 ># 18 "/usr/include/boost/lambda/detail/function_adaptors.hpp" 2 3 4 > > > > > > >namespace boost { >namespace lambda { > >namespace detail { > >template< typename T , typename fallback_ = boost::mpl::bool_< false > > class has_sig { template< typename U > struct has_sig_introspect { template< template< typename V0 > class V > struct has_sig_substitute0 { }; template< template< typename V0 , typename V1 > class V > struct has_sig_substitute1 { }; template< template< typename V0 , typename V1 , typename V2 > class V > struct has_sig_substitute2 { }; template< template< typename V0 , typename V1 , typename V2 , typename V3 > class V > struct has_sig_substitute3 { }; template< template< typename V0 , typename V1 , typename V2 , typename V3 , typename V4 > class V > struct has_sig_substitute4 { }; template< typename V > static boost::mpl::aux::no_tag has_sig_test(...); template< typename V > static boost::mpl::aux::yes_tag has_sig_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_sig_substitute0 < V::template sig >* = 0 ); template< typename V > static boost::mpl::aux::yes_tag has_sig_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_sig_substitute1 < V::template sig >* = 0 ); template< typename V > static boost::mpl::aux::yes_tag has_sig_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_sig_substitute2 < V::template sig >* = 0 ); template< typename V > static boost::mpl::aux::yes_tag has_sig_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_sig_substitute3 < V::template sig >* = 0 ); template< typename V > static boost::mpl::aux::yes_tag has_sig_test( boost::mpl::aux::type_wrapper< V > const volatile* , has_sig_substitute4 < V::template sig >* = 0 ); static const bool value = sizeof(has_sig_test< U >(0)) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_< value > type; }; public: static const bool value = has_sig_introspect< T >::value; typedef typename has_sig_introspect< T >::type type; }; > >template<class Tuple> >struct remove_references_from_elements { > typedef typename boost::tuples::cons< > typename boost::remove_reference<typename Tuple::head_type>::type, > typename remove_references_from_elements<typename Tuple::tail_type>::type > > type; >}; > >template<> >struct remove_references_from_elements<boost::tuples::null_type> { > typedef boost::tuples::null_type type; >}; > >} > >template <class Func> struct function_adaptor { > > typedef typename detail::remove_reference_and_cv<Func>::type plainF; > > > > template<class Tuple, int Length, bool HasSig> > struct result_converter; > template<class Tuple, int Length> > struct result_converter<Tuple, Length, true> > : plainF::template sig< > typename detail::remove_references_from_elements<Tuple>::type > > > {}; > template<class Tuple> > struct result_converter<Tuple, 0, false> > : result_of<plainF()> > {}; > template<class Tuple> > struct result_converter<Tuple, 1, false> > : result_of<plainF( > typename tuples::element<1, Tuple>::type) > > > {}; > template<class Tuple> > struct result_converter<Tuple, 2, false> > : result_of<plainF( > typename tuples::element<1, Tuple>::type, > typename tuples::element<2, Tuple>::type) > > > {}; > template<class Tuple> > struct result_converter<Tuple, 3, false> > : result_of<plainF( > typename tuples::element<1, Tuple>::type, > typename tuples::element<2, Tuple>::type, > typename tuples::element<3, Tuple>::type) > > > {}; > template<class Tuple> > struct result_converter<Tuple, 4, false> > : result_of<plainF( > typename tuples::element<1, Tuple>::type, > typename tuples::element<2, Tuple>::type, > typename tuples::element<3, Tuple>::type, > typename tuples::element<4, Tuple>::type) > > > {}; > template<class Tuple> > struct result_converter<Tuple, 5, false> > : result_of<plainF( > typename tuples::element<1, Tuple>::type, > typename tuples::element<2, Tuple>::type, > typename tuples::element<3, Tuple>::type, > typename tuples::element<4, Tuple>::type, > typename tuples::element<5, Tuple>::type) > > > {}; > template<class Tuple> > struct result_converter<Tuple, 6, false> > : result_of<plainF( > typename tuples::element<1, Tuple>::type, > typename tuples::element<2, Tuple>::type, > typename tuples::element<3, Tuple>::type, > typename tuples::element<4, Tuple>::type, > typename tuples::element<5, Tuple>::type, > typename tuples::element<6, Tuple>::type) > > > {}; > template<class Tuple> > struct result_converter<Tuple, 7, false> > : result_of<plainF( > typename tuples::element<1, Tuple>::type, > typename tuples::element<2, Tuple>::type, > typename tuples::element<3, Tuple>::type, > typename tuples::element<4, Tuple>::type, > typename tuples::element<5, Tuple>::type, > typename tuples::element<6, Tuple>::type, > typename tuples::element<7, Tuple>::type) > > > {}; > template<class Tuple> > struct result_converter<Tuple, 8, false> > : result_of<plainF( > typename tuples::element<1, Tuple>::type, > typename tuples::element<2, Tuple>::type, > typename tuples::element<3, Tuple>::type, > typename tuples::element<4, Tuple>::type, > typename tuples::element<5, Tuple>::type, > typename tuples::element<6, Tuple>::type, > typename tuples::element<7, Tuple>::type, > typename tuples::element<8, Tuple>::type) > > > {}; > template<class Tuple> > struct result_converter<Tuple, 9, false> > : result_of<plainF( > typename tuples::element<1, Tuple>::type, > typename tuples::element<2, Tuple>::type, > typename tuples::element<3, Tuple>::type, > typename tuples::element<4, Tuple>::type, > typename tuples::element<5, Tuple>::type, > typename tuples::element<6, Tuple>::type, > typename tuples::element<7, Tuple>::type, > typename tuples::element<8, Tuple>::type, > typename tuples::element<9, Tuple>::type) > > > {}; > > > > > > > > template <class Args> > struct sig > : result_converter< > Args > , tuples::length<typename Args::tail_type>::value > , detail::has_sig<plainF>::value > > > {}; ># 180 "/usr/include/boost/lambda/detail/function_adaptors.hpp" 3 4 > template<class RET, class A1> > static RET apply(A1& a1) { > return a1(); > } > template<class RET, class A1, class A2> > static RET apply(A1& a1, A2& a2) { > return a1(a2); > } > template<class RET, class A1, class A2, class A3> > static RET apply(A1& a1, A2& a2, A3& a3) { > return a1(a2, a3); > } > template<class RET, class A1, class A2, class A3, class A4> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4) { > return a1(a2, a3, a4); > } > template<class RET, class A1, class A2, class A3, class A4, class A5> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) { > return a1(a2, a3, a4, a5); > } > template<class RET, class A1, class A2, class A3, class A4, class A5, class A6> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) { > return a1(a2, a3, a4, a5, a6); > } > template<class RET, class A1, class A2, class A3, class A4, class A5, class A6, > class A7> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, > A7& a7) { > return a1(a2, a3, a4, a5, a6, a7); > } > template<class RET, class A1, class A2, class A3, class A4, class A5, class A6, > class A7, class A8> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, > A7& a7, A8& a8) { > return a1(a2, a3, a4, a5, a6, a7, a8); > } > template<class RET, class A1, class A2, class A3, class A4, class A5, class A6, > class A7, class A8, class A9> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, > A7& a7, A8& a8, A9& a9) { > return a1(a2, a3, a4, a5, a6, a7, a8, a9); > } > template<class RET, class A1, class A2, class A3, class A4, class A5, class A6, > class A7, class A8, class A9, class A10> > static RET apply(A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, > A7& a7, A8& a8, A9& a9, A10& a10) { > return a1(a2, a3, a4, a5, a6, a7, a8, a9, a10); > } >}; > >template <class Func> struct function_adaptor<const Func>; > > >template <class Object, class T> >struct function_adaptor<T Object::*> { > > > > > > > template<class Args> class sig { > typedef typename boost::tuples::element<1, Args>::type argument_type; > typedef typename boost::remove_reference< > argument_type > >::type unref_type; > > typedef typename detail::IF<boost::is_const<unref_type>::value, > typename boost::add_const<T>::type, > T > >::RET properly_consted_return_type; > > typedef typename detail::IF<boost::is_volatile<unref_type>::value, > typename boost::add_volatile<properly_consted_return_type>::type, > properly_consted_return_type > >::RET properly_cvd_return_type; > > > public: > typedef typename detail::IF<boost::is_reference<argument_type>::value, > typename boost::add_reference<properly_cvd_return_type>::type, > typename boost::remove_cv<T>::type > >::RET type; > }; > > template <class RET> > static RET apply( T Object::*data, Object& o) { > return o.*data; > } > template <class RET> > static RET apply( T Object::*data, const Object& o) { > return o.*data; > } > template <class RET> > static RET apply( T Object::*data, volatile Object& o) { > return o.*data; > } > template <class RET> > static RET apply( T Object::*data, const volatile Object& o) { > return o.*data; > } > template <class RET> > static RET apply( T Object::*data, Object* o) { > return o->*data; > } > template <class RET> > static RET apply( T Object::*data, const Object* o) { > return o->*data; > } > template <class RET> > static RET apply( T Object::*data, volatile Object* o) { > return o->*data; > } > template <class RET> > static RET apply( T Object::*data, const volatile Object* o) { > return o->*data; > } >}; > > > >template <class Result> >struct function_adaptor<Result (void)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET> > static Result apply(Result (*func)()) { > return func(); > } >}; > >template <class Result> >struct function_adaptor<Result (*)(void)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET> > static Result apply(Result (*func)()) { > return func(); > } >}; > > > >template <class Object, class Result> >struct function_adaptor<Result (Object::*)() const> { > > template<class T> struct sig { typedef Result type; }; > template <class RET> > static Result apply( Result (Object::*func)() const, const Object* o) { > return (o->*func)(); > } > template <class RET> > static Result apply( Result (Object::*func)() const, const Object& o) { > return (o.*func)(); > } >}; > >template <class Object, class Result> >struct function_adaptor<Result (Object::*)()> { > > template<class T> struct sig { typedef Result type; }; > template <class RET> > static Result apply( Result (Object::*func)(), Object* o) { > return (o->*func)(); > } > template <class RET> > static Result apply( Result (Object::*func)(), Object& o) { > return (o.*func)(); > } >}; > >template <class Arg1, class Result> >struct function_adaptor<Result (Arg1)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1> > static Result apply(Result (*func)(Arg1), A1& a1) { > return func(a1); > } >}; > >template <class Arg1, class Result> >struct function_adaptor<Result (*)(Arg1)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1> > static Result apply(Result (*func)(Arg1), A1& a1) { > return func(a1); > } >}; > > > >template <class Object, class Arg1, class Result> >struct function_adaptor<Result (Object::*)(Arg1) const> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1> > static Result apply( Result (Object::*func)(Arg1) const, const Object* o, > A1& a1) { > return (o->*func)(a1); > } > template <class RET, class A1> > static Result apply( Result (Object::*func)(Arg1) const, const Object& o, > A1& a1) { > return (o.*func)(a1); > } >}; > >template <class Object, class Arg1, class Result> >struct function_adaptor<Result (Object::*)(Arg1)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1> > static Result apply( Result (Object::*func)(Arg1), Object* o, A1& a1) { > return (o->*func)(a1); > } > template <class RET, class A1> > static Result apply( Result (Object::*func)(Arg1), Object& o, A1& a1) { > return (o.*func)(a1); > } >}; > >template <class Arg1, class Arg2, class Result> >struct function_adaptor<Result (Arg1, Arg2)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2> > static Result apply(Result (*func)(Arg1, Arg2), A1& a1, A2& a2) { > return func(a1, a2); > } >}; > >template <class Arg1, class Arg2, class Result> >struct function_adaptor<Result (*)(Arg1, Arg2)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2> > static Result apply(Result (*func)(Arg1, Arg2), A1& a1, A2& a2) { > return func(a1, a2); > } >}; > > > >template <class Object, class Arg1, class Arg2, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2) const> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2> > static Result apply( Result (Object::*func)(Arg1, Arg2) const, const Object* o, A1& a1, A2& a2) { > return (o->*func)(a1, a2); > } > template <class RET, class A1, class A2> > static Result apply( Result (Object::*func)(Arg1, Arg2) const, const Object& o, A1& a1, A2& a2) { > return (o.*func)(a1, a2); > } >}; > >template <class Object, class Arg1, class Arg2, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2> > static Result apply( Result (Object::*func)(Arg1, Arg2), Object* o, A1& a1, A2& a2) { > return (o->*func)(a1, a2); > } > template <class RET, class A1, class A2> > static Result apply( Result (Object::*func)(Arg1, Arg2), Object& o, A1& a1, A2& a2) { > return (o.*func)(a1, a2); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Result> >struct function_adaptor<Result (Arg1, Arg2, Arg3)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3> > static Result apply(Result (*func)(Arg1, Arg2, Arg3), A1& a1, A2& a2, A3& a3) { > return func(a1, a2, a3); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Result> >struct function_adaptor<Result (*)(Arg1, Arg2, Arg3)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3> > static Result apply(Result (*func)(Arg1, Arg2, Arg3), A1& a1, A2& a2, A3& a3) { > return func(a1, a2, a3); > } >}; > > > >template <class Object, class Arg1, class Arg2, class Arg3, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3) const> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3) const, const Object* o, A1& a1, A2& a2, A3& a3) { > return (o->*func)(a1, a2, a3); > } > template <class RET, class A1, class A2, class A3> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3) const, const Object& o, A1& a1, A2& a2, A3& a3) { > return (o.*func)(a1, a2, a3); > } >}; > >template <class Object, class Arg1, class Arg2, class Arg3, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3), Object* o, A1& a1, A2& a2, A3& a3) { > return (o->*func)(a1, a2, a3); > } > template <class RET, class A1, class A2, class A3> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3), Object& o, A1& a1, A2& a2, A3& a3) { > return (o.*func)(a1, a2, a3); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Result> >struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4), A1& a1, A2& a2, A3& a3, A4& a4) { > return func(a1, a2, a3, a4); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Result> >struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4), A1& a1, A2& a2, A3& a3, A4& a4) { > return func(a1, a2, a3, a4); > } >}; > > > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4) const> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4) { > return (o->*func)(a1, a2, a3, a4); > } > template <class RET, class A1, class A2, class A3, class A4> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4) { > return (o.*func)(a1, a2, a3, a4); > } >}; > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4), Object* o, A1& a1, A2& a2, A3& a3, A4& a4) { > return (o->*func)(a1, a2, a3, a4); > } > template <class RET, class A1, class A2, class A3, class A4> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4), Object& o, A1& a1, A2& a2, A3& a3, A4& a4) { > return (o.*func)(a1, a2, a3, a4); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Result> >struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) { > return func(a1, a2, a3, a4, a5); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Result> >struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) { > return func(a1, a2, a3, a4, a5); > } >}; > > > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5) const> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) { > return (o->*func)(a1, a2, a3, a4, a5); > } > template <class RET, class A1, class A2, class A3, class A4, class A5> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) { > return (o.*func)(a1, a2, a3, a4, a5); > } >}; > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5), Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) { > return (o->*func)(a1, a2, a3, a4, a5); > } > template <class RET, class A1, class A2, class A3, class A4, class A5> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5), Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5) { > return (o.*func)(a1, a2, a3, a4, a5); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Result> >struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5, Arg6)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) { > return func(a1, a2, a3, a4, a5, a6); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Result> >struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) { > return func(a1, a2, a3, a4, a5, a6); > } >}; > > > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6) const> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) { > return (o->*func)(a1, a2, a3, a4, a5, a6); > } > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) { > return (o.*func)(a1, a2, a3, a4, a5, a6); > } >}; > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6), Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) { > return (o->*func)(a1, a2, a3, a4, a5, a6); > } > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6), Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6) { > return (o.*func)(a1, a2, a3, a4, a5, a6); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Result> >struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) { > return func(a1, a2, a3, a4, a5, a6, a7); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Result> >struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) { > return func(a1, a2, a3, a4, a5, a6, a7); > } >}; > > > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7) const> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) { > return (o->*func)(a1, a2, a3, a4, a5, a6, a7); > } > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) { > return (o.*func)(a1, a2, a3, a4, a5, a6, a7); > } >}; > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7), Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) { > return (o->*func)(a1, a2, a3, a4, a5, a6, a7); > } > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7), Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7) { > return (o.*func)(a1, a2, a3, a4, a5, a6, a7); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Result> >struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) { > return func(a1, a2, a3, a4, a5, a6, a7, a8); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Result> >struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) { > return func(a1, a2, a3, a4, a5, a6, a7, a8); > } >}; > > > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8) const> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8) const, const Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) { > return (o->*func)(a1, a2, a3, a4, a5, a6, a7, a8); > } > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8) const, const Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) { > return (o.*func)(a1, a2, a3, a4, a5, a6, a7, a8); > } >}; > >template <class Object, class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Result> >struct function_adaptor<Result (Object::*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8), Object* o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) { > return (o->*func)(a1, a2, a3, a4, a5, a6, a7, a8); > } > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8> > static Result apply( Result (Object::*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8), Object& o, A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8) { > return (o.*func)(a1, a2, a3, a4, a5, a6, a7, a8); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Arg9, class Result> >struct function_adaptor<Result (Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8, A9& a9) { > return func(a1, a2, a3, a4, a5, a6, a7, a8, a9); > } >}; > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, class Arg8, class Arg9, class Result> >struct function_adaptor<Result (*)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9)> { > > template<class T> struct sig { typedef Result type; }; > template <class RET, class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9> > static Result apply(Result (*func)(Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9), A1& a1, A2& a2, A3& a3, A4& a4, A5& a5, A6& a6, A7& a7, A8& a8, A9& a9) { > return func(a1, a2, a3, a4, a5, a6, a7, a8, a9); > } >}; > >} >} ># 49 "/usr/include/boost/lambda/core.hpp" 2 3 4 ># 1 "/usr/include/boost/lambda/detail/return_type_traits.hpp" 1 3 4 ># 19 "/usr/include/boost/lambda/detail/return_type_traits.hpp" 3 4 >namespace boost { >namespace lambda { > >using ::boost::type_traits::ice_and; >using ::boost::type_traits::ice_or; >using ::boost::type_traits::ice_not; > > > > > >template <class Act, class A1> struct return_type_1; >template <class Act, class A1, class A2> struct return_type_2; >template <class Act, class Args> struct return_type_N; > >template <class Act, class A1> struct return_type_1_prot; >template <class Act, class A1, class A2> struct return_type_2_prot; >template <class Act, class A1> struct return_type_N_prot; > > >namespace detail { > >template<class> class return_type_deduction_failure {}; ># 60 "/usr/include/boost/lambda/detail/return_type_traits.hpp" 3 4 >} ># 76 "/usr/include/boost/lambda/detail/return_type_traits.hpp" 3 4 >template <class Act, class A> struct return_type_1_prot { >public: > typedef typename > detail::IF< > > ice_and<is_protectable<Act>::value, is_lambda_functor<A>::value>::value, > lambda_functor< > lambda_functor_base< > Act, > tuple<typename detail::remove_reference_and_cv<A>::type> > > > >, > typename return_type_1<Act, A>::type > >::RET type; >}; > > >template<class Act> struct return_type_1_prot<Act, null_type> { > typedef null_type type; >}; > > > >template<class Act, class A> struct return_type_1 { > typedef typename > detail::return_type_deduction_failure<return_type_1> type; >}; > > >namespace detail { > > template <class T> > class protect_conversion { > typedef typename boost::remove_reference<T>::type non_ref_T; > public: > > > > typedef typename detail::IF_type< > > ice_and<boost::is_reference<T>::value, > ice_not<boost::is_const<non_ref_T>::value>::value>::value, > detail::identity_mapping<T>, > const_copy_argument<non_ref_T> > >::type type; > }; > >} > >template <class Act, class A, class B> struct return_type_2_prot { ># 146 "/usr/include/boost/lambda/detail/return_type_traits.hpp" 3 4 > typedef typename boost::remove_reference<A>::type non_ref_A; > typedef typename boost::remove_reference<B>::type non_ref_B; > >typedef typename > detail::IF< > > > ice_and<is_protectable<Act>::value, > ice_or<is_lambda_functor<A>::value, > is_lambda_functor<B>::value>::value>::value, > lambda_functor< > lambda_functor_base< > Act, > tuple<typename detail::protect_conversion<A>::type, > typename detail::protect_conversion<B>::type> > > > >, > typename return_type_2<Act, non_ref_A, non_ref_B>::type > >::RET type; >}; > > >template<class Act> struct return_type_2_prot<Act, null_type, null_type> { > typedef null_type type; >}; > >template<class Act, class Other> struct return_type_2_prot<Act, Other, null_type> { > typedef null_type type; >}; > >template<class Act, class Other> struct return_type_2_prot<Act, null_type, Other> { > typedef null_type type; >}; > > > >template<class A, class B> >struct return_type_2_comma >{ > typedef typename boost::remove_reference<A>::type non_ref_A; > typedef typename boost::remove_reference<B>::type non_ref_B; > >typedef typename > detail::IF< > > > ice_and<is_protectable<other_action<comma_action> >::value, > ice_or<is_lambda_functor<A>::value, > is_lambda_functor<B>::value>::value>::value, > lambda_functor< > lambda_functor_base< > other_action<comma_action>, > tuple<typename detail::protect_conversion<A>::type, > typename detail::protect_conversion<B>::type> > > > >, > typename > return_type_2<other_action<comma_action>, non_ref_A, non_ref_B>::type > >::RET type1; > > > > typedef typename > detail::IF< > boost::is_same<type1, detail::unspecified>::value, > B, > type1 > >::RET type; > >}; > > > > >template<class Act, class Args> struct return_type_N_prot { > typedef typename return_type_N<Act, Args>::type type; >}; > > >template<class Act> struct return_type_N_prot<Act, null_type> { > typedef null_type type; >}; > > > > >template<int I, class Args, class Ret> >struct return_type_N<function_action<I, Ret>, Args> { > typedef Ret type; >}; > > > >namespace detail >{ > >template< typename T, typename fallback_ = boost::mpl::bool_<false> > struct has_result_type { struct gcc_3_2_wknd { template< typename U > static boost::mpl::aux::yes_tag test( boost::mpl::aux::type_wrapper<U> const volatile* , boost::mpl::aux::type_wrapper<typename U::result_type>* = 0 ); static boost::mpl::aux::no_tag test(...); }; typedef boost::mpl::aux::type_wrapper<T> t_; static const bool value = sizeof(gcc_3_2_wknd::test(static_cast<t_*>(0))) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_<value> type; }; > >template<class F> struct get_result_type >{ > typedef typename F::result_type type; >}; > >template<class F, class A> struct get_sig >{ > typedef typename function_adaptor<F>::template sig<A>::type type; >}; > >} > > >template<int I, class Args> >struct return_type_N<function_action<I, detail::unspecified>, Args > { > > > > typedef typename Args::head_type Func; > typedef typename detail::remove_reference_and_cv<Func>::type plain_Func; > >public: > > > typedef typename detail::IF< > detail::has_result_type<plain_Func>::value, > detail::get_result_type<plain_Func>, > detail::get_sig<plain_Func, Args> > >::RET::type type; >}; > > >} >} ># 50 "/usr/include/boost/lambda/core.hpp" 2 3 4 > ># 1 "/usr/include/boost/lambda/detail/select_functions.hpp" 1 3 4 ># 15 "/usr/include/boost/lambda/detail/select_functions.hpp" 3 4 >namespace boost { >namespace lambda { >namespace detail { > > > >template<class Any, class A, class B, class C, class Env> >inline Any& select(Any& any, A& a, B& b, C& c, Env& env) { ::boost::lambda::detail::do_nothing(a, b, c, env); return any; } > > >template<class Arg, class A, class B, class C, class Env> >inline typename Arg::template sig<tuple<A&, B&, C&, Env&> >::type >select ( const lambda_functor<Arg>& op, A& a, B& b, C& c, Env& env ) { > return op.template call< > typename Arg::template sig<tuple<A&, B&, C&, Env&> >::type > >(a, b, c, env); >} >template<class Arg, class A, class B, class C, class Env> >inline typename Arg::template sig<tuple<A&, B&, C&, Env&> >::type >select ( lambda_functor<Arg>& op, A& a, B& b, C& c, Env& env) { > return op.template call< > typename Arg::template sig<tuple<A&, B&, C&, Env&> >::type > >(a, b, c, env); >} ># 50 "/usr/include/boost/lambda/detail/select_functions.hpp" 3 4 >template<class RET> struct r_select { > > > template<class Any, class A, class B, class C, class Env> > static > inline RET go (Any& any, A& a, B& b, C& c, Env& env) { ::boost::lambda::detail::do_nothing(a, b, c, env); return any; } > > > template<class Arg, class A, class B, class C, class Env> > static > inline RET go (const lambda_functor<Arg>& op, A& a, B& b, C& c, Env& env ) { > return op.template call<RET>(a, b, c, env); > } > template<class Arg, class A, class B, class C, class Env> > static > inline RET go (lambda_functor<Arg>& op, A& a, B& b, C& c, Env& env ) { > return op.template call<RET>(a, b, c, env); > } >}; > >} >} >} ># 52 "/usr/include/boost/lambda/core.hpp" 2 3 4 > ># 1 "/usr/include/boost/lambda/detail/lambda_functor_base.hpp" 1 3 4 ># 22 "/usr/include/boost/lambda/detail/lambda_functor_base.hpp" 3 4 >namespace boost { >namespace lambda { ># 32 "/usr/include/boost/lambda/detail/lambda_functor_base.hpp" 3 4 >template <class T> >class identity { > > T elem; >public: > > typedef T element_t; > > > > typedef typename boost::add_reference< > typename boost::add_const<T>::type > >::type par_t; > > explicit identity(par_t t) : elem(t) {} > > template <typename SigArgs> > struct sig { typedef typename boost::remove_const<element_t>::type type; }; > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { ::boost::lambda::detail::do_nothing(a, b, c, env); return elem; } >}; > > > > > >template <class T> >inline lambda_functor<identity<T&> > var(T& t) { return identity<T&>(t); } > > > > >template <class T> >lambda_functor<T> var(const lambda_functor<T>& t) { return t; } > >template <class T> struct var_type { > typedef lambda_functor<identity<T&> > type; >}; > > >template <class T> >inline >lambda_functor<identity<typename bound_argument_conversion<const T>::type> > >constant(const T& t) { > return identity<typename bound_argument_conversion<const T>::type>(t); >} >template <class T> >lambda_functor<T> constant(const lambda_functor<T>& t) { return t; } > >template <class T> struct constant_type { > typedef > lambda_functor< > identity<typename bound_argument_conversion<const T>::type> > > type; >}; > > > >template <class T> >inline lambda_functor<identity<const T&> > constant_ref(const T& t) { > return identity<const T&>(t); >} >template <class T> >lambda_functor<T> constant_ref(const lambda_functor<T>& t) { return t; } > >template <class T> struct constant_ref_type { > typedef > lambda_functor<identity<const T&> > type; >}; > > > > > >template <class T> >struct as_lambda_functor { > typedef typename > detail::remove_reference_and_cv<T>::type plain_T; > typedef typename > detail::IF<is_lambda_functor<plain_T>::value, > plain_T, > lambda_functor< > identity<typename bound_argument_conversion<T>::type> > > > >::RET type; >}; > > >template <class T> >inline >lambda_functor<identity<typename bound_argument_conversion<const T>::type> > >to_lambda_functor(const T& t) { > return identity<typename bound_argument_conversion<const T>::type>(t); >} > >template <class T> >inline lambda_functor<T> >to_lambda_functor(const lambda_functor<T>& t) { > return t; >} > >namespace detail { ># 144 "/usr/include/boost/lambda/detail/lambda_functor_base.hpp" 3 4 >template <class T> struct constify_rvals { > template<class U> > static inline const U& go(const U& u) { return u; } >}; > >template <class T> struct constify_rvals<T&> { > template<class U> > static inline U& go(U& u) { return u; } >}; > > > > > >template <class T> struct is_null_type >{ static const bool value = false; }; > >template <> struct is_null_type<null_type> >{ static const bool value = true; }; > >template<class Tuple> struct has_null_type { > static const bool value = (is_null_type<typename Tuple::head_type>::value || has_null_type<typename Tuple::tail_type>::value); >}; >template<> struct has_null_type<null_type> { > static const bool value = false; >}; > > > > > >template<class Args, class SigArgs> >class deduce_argument_types_ { > typedef typename as_lambda_functor<typename Args::head_type>::type lf_t; > typedef typename lf_t::inherited::template sig<SigArgs>::type el_t; >public: > typedef > boost::tuples::cons< > el_t, > typename deduce_argument_types_<typename Args::tail_type, SigArgs>::type > > type; >}; > >template<class SigArgs> >class deduce_argument_types_<null_type, SigArgs> { >public: > typedef null_type type; >}; ># 202 "/usr/include/boost/lambda/detail/lambda_functor_base.hpp" 3 4 >template<class Args, class SigArgs> >class deduce_non_ref_argument_types_ { > typedef typename as_lambda_functor<typename Args::head_type>::type lf_t; > typedef typename lf_t::inherited::template sig<SigArgs>::type el_t; >public: > typedef > boost::tuples::cons< > > typename boost::remove_reference<el_t>::type, > typename deduce_non_ref_argument_types_<typename Args::tail_type, SigArgs>::type > > type; >}; > >template<class SigArgs> >class deduce_non_ref_argument_types_<null_type, SigArgs> { >public: > typedef null_type type; >}; > > > > > >template<class Args, class SigArgs> >class deduce_argument_types { > typedef typename deduce_argument_types_<Args, SigArgs>::type t1; >public: > typedef typename detail::IF< > has_null_type<t1>::value, null_type, t1 > >::RET type; >}; > > > > >template<class Args, class SigArgs> >class deduce_non_ref_argument_types { > typedef typename deduce_non_ref_argument_types_<Args, SigArgs>::type t1; >public: > typedef typename detail::IF< > has_null_type<t1>::value, null_type, t1 > >::RET type; >}; > >template <int N, class Args, class SigArgs> >struct nth_return_type_sig { > typedef typename > as_lambda_functor< > typename boost::tuples::element<N, Args>::type > > >::type lf_type; > > typedef typename lf_type::inherited::template sig<SigArgs>::type type; >}; > >template<int N, class Tuple> struct element_or_null { > typedef typename boost::tuples::element<N, Tuple>::type type; >}; > >template<int N> struct element_or_null<N, null_type> { > typedef null_type type; >}; > > > > >} > > > > >template<class RET, class Args> >class lambda_functor_base<explicit_return_type_action<RET>, Args> >{ >public: > Args args; > > typedef RET result_type; > > explicit lambda_functor_base(const Args& a) : args(a) {} > > template <class SigArgs> struct sig { typedef RET type; }; > > template<class RET_, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const > { > return detail::constify_rvals<RET>::go( > detail::r_select<RET>::go(boost::tuples::get<0>(args), a, b, c, env)); > } >}; > > >template<class Args> >class lambda_functor_base<protect_action, Args> >{ >public: > Args args; >public: > > explicit lambda_functor_base(const Args& a) : args(a) {} > > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const > { > ::boost::lambda::detail::do_nothing(a, b, c, env); > return boost::tuples::get<0>(args); > } > > template<class SigArgs> struct sig { > > typedef typename boost::tuples::element<0, Args>::type type; > }; >}; > > >class do_nothing_action {}; > >template<class Args> >class lambda_functor_base<do_nothing_action, Args> { > >public: > > lambda_functor_base() {} > > > template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { > return ::boost::lambda::detail::do_nothing(a, b, c, env); > } > > template<class SigArgs> struct sig { typedef void type; }; >}; ># 351 "/usr/include/boost/lambda/detail/lambda_functor_base.hpp" 3 4 >template<class Act, class Args> >class lambda_functor_base<action<0, Act>, Args> >{ >public: > > explicit lambda_functor_base(const Args& ) {} > > template<class SigArgs> struct sig { > typedef typename return_type_N<Act, null_type>::type type; > }; > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { > ::boost::lambda::detail::do_nothing(a, b, c, env); > return Act::template apply<RET>(); > } >}; ># 401 "/usr/include/boost/lambda/detail/lambda_functor_base.hpp" 3 4 >template<class Act, class Args> class lambda_functor_base<action<1, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > typedef typename element_or_null<0, rets_t>::type rt0; > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)) > ); > } >}; > > >template<class Act, class Args> class lambda_functor_base<action<2, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > typedef typename element_or_null<0, rets_t>::type rt0; > typedef typename element_or_null<1, rets_t>::type rt1; > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)), > constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), a, b, c, env)) > ); > } >}; > >template<class Act, class Args> class lambda_functor_base<action<3, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > > typedef typename element_or_null<0, rets_t>::type rt0; > typedef typename element_or_null<1, rets_t>::type rt1; > typedef typename element_or_null<2, rets_t>::type rt2; > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)), > constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), a, b, c, env)), > constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), a, b, c, env)) > ); > } >}; > >template<class Act, class Args> class lambda_functor_base<action<4, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > typedef typename element_or_null<0, rets_t>::type rt0; > typedef typename element_or_null<1, rets_t>::type rt1; > typedef typename element_or_null<2, rets_t>::type rt2; > typedef typename element_or_null<3, rets_t>::type rt3; > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)), > constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), a, b, c, env)), > constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), a, b, c, env)), > constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), a, b, c, env)) > ); > } >}; > >template<class Act, class Args> class lambda_functor_base<action<5, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > typedef typename element_or_null<0, rets_t>::type rt0; > typedef typename element_or_null<1, rets_t>::type rt1; > typedef typename element_or_null<2, rets_t>::type rt2; > typedef typename element_or_null<3, rets_t>::type rt3; > typedef typename element_or_null<4, rets_t>::type rt4; > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)), > constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), a, b, c, env)), > constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), a, b, c, env)), > constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), a, b, c, env)), > constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), a, b, c, env)) > ); > } >}; > >template<class Act, class Args> class lambda_functor_base<action<6, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > typedef typename element_or_null<0, rets_t>::type rt0; > typedef typename element_or_null<1, rets_t>::type rt1; > typedef typename element_or_null<2, rets_t>::type rt2; > typedef typename element_or_null<3, rets_t>::type rt3; > typedef typename element_or_null<4, rets_t>::type rt4; > typedef typename element_or_null<5, rets_t>::type rt5; > > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)), > constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), a, b, c, env)), > constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), a, b, c, env)), > constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), a, b, c, env)), > constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), a, b, c, env)), > constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), a, b, c, env)) > ); > } >}; > >template<class Act, class Args> class lambda_functor_base<action<7, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > typedef typename element_or_null<0, rets_t>::type rt0; > typedef typename element_or_null<1, rets_t>::type rt1; > typedef typename element_or_null<2, rets_t>::type rt2; > typedef typename element_or_null<3, rets_t>::type rt3; > typedef typename element_or_null<4, rets_t>::type rt4; > typedef typename element_or_null<5, rets_t>::type rt5; > typedef typename element_or_null<6, rets_t>::type rt6; > > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)), > constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), a, b, c, env)), > constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), a, b, c, env)), > constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), a, b, c, env)), > constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), a, b, c, env)), > constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), a, b, c, env)), > constify_rvals<rt6>::go(r_select<rt6>::go(get<6>(args), a, b, c, env)) > ); > } >}; > >template<class Act, class Args> class lambda_functor_base<action<8, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > typedef typename element_or_null<0, rets_t>::type rt0; > typedef typename element_or_null<1, rets_t>::type rt1; > typedef typename element_or_null<2, rets_t>::type rt2; > typedef typename element_or_null<3, rets_t>::type rt3; > typedef typename element_or_null<4, rets_t>::type rt4; > typedef typename element_or_null<5, rets_t>::type rt5; > typedef typename element_or_null<6, rets_t>::type rt6; > typedef typename element_or_null<7, rets_t>::type rt7; > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)), > constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), a, b, c, env)), > constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), a, b, c, env)), > constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), a, b, c, env)), > constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), a, b, c, env)), > constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), a, b, c, env)), > constify_rvals<rt6>::go(r_select<rt6>::go(get<6>(args), a, b, c, env)), > constify_rvals<rt7>::go(r_select<rt7>::go(get<7>(args), a, b, c, env)) > ); > } >}; > >template<class Act, class Args> class lambda_functor_base<action<9, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > typedef typename element_or_null<0, rets_t>::type rt0; > typedef typename element_or_null<1, rets_t>::type rt1; > typedef typename element_or_null<2, rets_t>::type rt2; > typedef typename element_or_null<3, rets_t>::type rt3; > typedef typename element_or_null<4, rets_t>::type rt4; > typedef typename element_or_null<5, rets_t>::type rt5; > typedef typename element_or_null<6, rets_t>::type rt6; > typedef typename element_or_null<7, rets_t>::type rt7; > typedef typename element_or_null<8, rets_t>::type rt8; > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)), > constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), a, b, c, env)), > constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), a, b, c, env)), > constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), a, b, c, env)), > constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), a, b, c, env)), > constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), a, b, c, env)), > constify_rvals<rt6>::go(r_select<rt6>::go(get<6>(args), a, b, c, env)), > constify_rvals<rt7>::go(r_select<rt7>::go(get<7>(args), a, b, c, env)), > constify_rvals<rt8>::go(r_select<rt8>::go(get<8>(args), a, b, c, env)) > ); > } >}; > >template<class Act, class Args> class lambda_functor_base<action<10, Act>, Args> { public: Args args; explicit lambda_functor_base(const Args& a) : args(a) {} template<class SigArgs> struct sig { typedef typename detail::deduce_argument_types<Args, SigArgs>::type rets_t; public: typedef typename return_type_N_prot<Act, rets_t>::type type; }; template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { using boost::tuples::get; using detail::constify_rvals; using detail::r_select; using detail::element_or_null; using detail::deduce_argument_types; > typedef typename > deduce_argument_types<Args, tuple<A&, B&, C&, Env&> >::type rets_t; > typedef typename element_or_null<0, rets_t>::type rt0; > typedef typename element_or_null<1, rets_t>::type rt1; > typedef typename element_or_null<2, rets_t>::type rt2; > typedef typename element_or_null<3, rets_t>::type rt3; > typedef typename element_or_null<4, rets_t>::type rt4; > typedef typename element_or_null<5, rets_t>::type rt5; > typedef typename element_or_null<6, rets_t>::type rt6; > typedef typename element_or_null<7, rets_t>::type rt7; > typedef typename element_or_null<8, rets_t>::type rt8; > typedef typename element_or_null<9, rets_t>::type rt9; > > return Act::template apply<RET>( > constify_rvals<rt0>::go(r_select<rt0>::go(get<0>(args), a, b, c, env)), > constify_rvals<rt1>::go(r_select<rt1>::go(get<1>(args), a, b, c, env)), > constify_rvals<rt2>::go(r_select<rt2>::go(get<2>(args), a, b, c, env)), > constify_rvals<rt3>::go(r_select<rt3>::go(get<3>(args), a, b, c, env)), > constify_rvals<rt4>::go(r_select<rt4>::go(get<4>(args), a, b, c, env)), > constify_rvals<rt5>::go(r_select<rt5>::go(get<5>(args), a, b, c, env)), > constify_rvals<rt6>::go(r_select<rt6>::go(get<6>(args), a, b, c, env)), > constify_rvals<rt7>::go(r_select<rt7>::go(get<7>(args), a, b, c, env)), > constify_rvals<rt8>::go(r_select<rt8>::go(get<8>(args), a, b, c, env)), > constify_rvals<rt9>::go(r_select<rt9>::go(get<9>(args), a, b, c, env)) > ); > } >}; > > > > >} >} ># 54 "/usr/include/boost/lambda/core.hpp" 2 3 4 > ># 1 "/usr/include/boost/lambda/detail/lambda_functors.hpp" 1 3 4 ># 41 "/usr/include/boost/lambda/detail/lambda_functors.hpp" 3 4 >namespace boost { >namespace lambda { > > > > > > >namespace detail { >namespace { > > static const null_type constant_null_type = null_type(); > >} >} > >class unused {}; > > > > > > > >namespace detail { > template<int N, class Tuple> struct get_element_or_null_type { > typedef typename > detail::tuple_element_as_reference<N, Tuple>::type type; > }; > template<int N> struct get_element_or_null_type<N, null_type> { > typedef null_type type; > }; >} > >template <int I> struct placeholder; > >template<> struct placeholder<FIRST> { > > template<class SigArgs> struct sig { > typedef typename detail::get_element_or_null_type<0, SigArgs>::type type; > }; > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { > static_assert(boost::is_reference<RET>::value, "boost::is_reference<RET>::value"); > ::boost::lambda::detail::do_nothing(a, b, c, env); > return a; > } >}; > >template<> struct placeholder<SECOND> { > > template<class SigArgs> struct sig { > typedef typename detail::get_element_or_null_type<1, SigArgs>::type type; > }; > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { ::boost::lambda::detail::do_nothing(a, b, c, env); return b; } >}; > >template<> struct placeholder<THIRD> { > > template<class SigArgs> struct sig { > typedef typename detail::get_element_or_null_type<2, SigArgs>::type type; > }; > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { ::boost::lambda::detail::do_nothing(a, b, c, env); return c; } >}; > >template<> struct placeholder<EXCEPTION> { > > template<class SigArgs> struct sig { > typedef typename detail::get_element_or_null_type<3, SigArgs>::type type; > }; > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { ::boost::lambda::detail::do_nothing(a, b, c, env); return env; } >}; > >typedef const lambda_functor<placeholder<FIRST> > placeholder1_type; >typedef const lambda_functor<placeholder<SECOND> > placeholder2_type; >typedef const lambda_functor<placeholder<THIRD> > placeholder3_type; ># 139 "/usr/include/boost/lambda/detail/lambda_functors.hpp" 3 4 >template <class T> >class lambda_functor : public T >{ > >static const int arity_bits = get_arity<T>::value; > >public: > typedef T inherited; > > lambda_functor() {} > lambda_functor(const lambda_functor& l) : inherited(l) {} > > lambda_functor(const T& t) : inherited(t) {} > > template <class SigArgs> struct sig { > typedef typename inherited::template > sig<typename SigArgs::tail_type>::type type; > }; > > > > > typedef typename > inherited::template sig<null_type>::type > nullary_return_type; > > > template <class Sig> struct result; > template <class F> > struct result<F()> { > typedef nullary_return_type type; > }; > template <class F, class A> > struct result<F(A)> { > typedef typename sig<tuple<F, A> >::type type; > }; > template <class F, class A, class B> > struct result<F(A, B)> { > typedef typename sig<tuple<F, A, B> >::type type; > }; > template <class F, class A, class B, class C> > struct result<F(A, B, C)> { > typedef typename sig<tuple<F, A, B, C> >::type type; > }; > > nullary_return_type operator()() const { > return inherited::template > call<nullary_return_type> > (detail::constant_null_type, detail::constant_null_type, detail::constant_null_type, detail::constant_null_type); > } > > template<class A> > typename inherited::template sig<tuple<A&> >::type > operator()(A& a) const { > return inherited::template call< > typename inherited::template sig<tuple<A&> >::type > >(a, detail::constant_null_type, detail::constant_null_type, detail::constant_null_type); > } > > template<class A> > typename inherited::template sig<tuple<A const&> >::type > operator()(A const& a) const { > return inherited::template call< > typename inherited::template sig<tuple<A const&> >::type > >(a, detail::constant_null_type, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B> > typename inherited::template sig<tuple<A&, B&> >::type > operator()(A& a, B& b) const { > return inherited::template call< > typename inherited::template sig<tuple<A&, B&> >::type > >(a, b, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B> > typename inherited::template sig<tuple<A const&, B&> >::type > operator()(A const& a, B& b) const { > return inherited::template call< > typename inherited::template sig<tuple<A const&, B&> >::type > >(a, b, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B> > typename inherited::template sig<tuple<A&, B const&> >::type > operator()(A& a, B const& b) const { > return inherited::template call< > typename inherited::template sig<tuple<A&, B const&> >::type > >(a, b, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B> > typename inherited::template sig<tuple<A const&, B const&> >::type > operator()(A const& a, B const& b) const { > return inherited::template call< > typename inherited::template sig<tuple<A const&, B const&> >::type > >(a, b, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B, class C> > typename inherited::template sig<tuple<A&, B&, C&> >::type > operator()(A& a, B& b, C& c) const > { > return inherited::template call< > typename inherited::template sig<tuple<A&, B&, C&> >::type > >(a, b, c, detail::constant_null_type); > } > > template<class A, class B, class C> > typename inherited::template sig<tuple<A const&, B const&, C const&> >::type > operator()(A const& a, B const& b, C const& c) const > { > return inherited::template call< > typename inherited::template sig<tuple<A const&, B const&, C const&> >::type > >(a, b, c, detail::constant_null_type); > } > > > template<class A, class B, class C, class Env> > typename inherited::template sig<tuple<A&, B&, C&, Env&> >::type > internal_call(A& a, B& b, C& c, Env& env) const { > return inherited::template > call<typename inherited::template > sig<tuple<A&, B&, C&, Env&> >::type>(a, b, c, env); > } > > template<class A> > const lambda_functor<lambda_functor_base< > other_action<assignment_action>, > boost::tuple<lambda_functor, > typename const_copy_argument <const A>::type> > > > operator=(const A& a) const { > return lambda_functor_base< > other_action<assignment_action>, > boost::tuple<lambda_functor, > typename const_copy_argument <const A>::type> > > ( boost::tuple<lambda_functor, > typename const_copy_argument <const A>::type>(*this, a) ); > } > > template<class A> > const lambda_functor<lambda_functor_base< > other_action<subscript_action>, > boost::tuple<lambda_functor, > typename const_copy_argument <const A>::type> > > > operator[](const A& a) const { > return lambda_functor_base< > other_action<subscript_action>, > boost::tuple<lambda_functor, > typename const_copy_argument <const A>::type> > > ( boost::tuple<lambda_functor, > typename const_copy_argument <const A>::type>(*this, a ) ); > } >}; > > > > > >} >} > >namespace boost { ># 319 "/usr/include/boost/lambda/detail/lambda_functors.hpp" 3 4 >template<class T> >struct tr1_result_of<boost::lambda::lambda_functor<T>()> >{ > typedef typename boost::lambda::lambda_functor<T>::nullary_return_type type; >}; > >template<class T> >struct tr1_result_of<const boost::lambda::lambda_functor<T>()> >{ > typedef typename boost::lambda::lambda_functor<T>::nullary_return_type type; >}; > >} > > > > > >namespace boost >{ > >template<> struct is_placeholder< lambda::lambda_functor< lambda::placeholder<lambda::FIRST> > > >{ > enum _vt { value = 1 }; >}; > >template<> struct is_placeholder< lambda::lambda_functor< lambda::placeholder<lambda::SECOND> > > >{ > enum _vt { value = 2 }; >}; > >template<> struct is_placeholder< lambda::lambda_functor< lambda::placeholder<lambda::THIRD> > > >{ > enum _vt { value = 3 }; >}; > >} ># 56 "/usr/include/boost/lambda/core.hpp" 2 3 4 > ># 1 "/usr/include/boost/lambda/detail/ret.hpp" 1 3 4 ># 15 "/usr/include/boost/lambda/detail/ret.hpp" 3 4 >namespace boost { >namespace lambda { ># 38 "/usr/include/boost/lambda/detail/ret.hpp" 3 4 >template<class RET, class Arg> >inline const >lambda_functor< > lambda_functor_base< > explicit_return_type_action<RET>, > tuple<lambda_functor<Arg> > > > >> >ret(const lambda_functor<Arg>& a1) >{ > return > lambda_functor_base< > explicit_return_type_action<RET>, > tuple<lambda_functor<Arg> > > > > (tuple<lambda_functor<Arg> >(a1)); >} > > > > >template <class T> >inline const T& protect(const T& t) { return t; } > >template<class Arg> >inline const >lambda_functor< > lambda_functor_base< > protect_action, > tuple<lambda_functor<Arg> > > > >> >protect(const lambda_functor<Arg>& a1) >{ > return > lambda_functor_base< > protect_action, > tuple<lambda_functor<Arg> > > > > (tuple<lambda_functor<Arg> >(a1)); >} ># 90 "/usr/include/boost/lambda/detail/ret.hpp" 3 4 >template <class LambdaFunctor> >class non_lambda_functor >{ > LambdaFunctor lf; >public: > > > > > template <class SigArgs> struct sig { > typedef typename > LambdaFunctor::inherited:: > template sig<typename SigArgs::tail_type>::type type; > }; > > explicit non_lambda_functor(const LambdaFunctor& a) : lf(a) {} > > typename LambdaFunctor::nullary_return_type > operator()() const { > return lf.template > call<typename LambdaFunctor::nullary_return_type> > (detail::constant_null_type, detail::constant_null_type, detail::constant_null_type, detail::constant_null_type); > } > > template<class A> > typename sig<tuple<const non_lambda_functor, A&> >::type > operator()(A& a) const { > return lf.template call<typename sig<tuple<const non_lambda_functor, A&> >::type >(a, detail::constant_null_type, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B> > typename sig<tuple<const non_lambda_functor, A&, B&> >::type > operator()(A& a, B& b) const { > return lf.template call<typename sig<tuple<const non_lambda_functor, A&, B&> >::type >(a, b, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B, class C> > typename sig<tuple<const non_lambda_functor, A&, B&, C&> >::type > operator()(A& a, B& b, C& c) const { > return lf.template call<typename sig<tuple<const non_lambda_functor, A&, B&, C&> >::type>(a, b, c, detail::constant_null_type); > } >}; > >template <class Arg> >inline const Arg& unlambda(const Arg& a) { return a; } > >template <class Arg> >inline const non_lambda_functor<lambda_functor<Arg> > >unlambda(const lambda_functor<Arg>& a) >{ > return non_lambda_functor<lambda_functor<Arg> >(a); >} ># 155 "/usr/include/boost/lambda/detail/ret.hpp" 3 4 >template <class LambdaFunctor> >struct const_incorrect_lambda_functor { > LambdaFunctor lf; >public: > > explicit const_incorrect_lambda_functor(const LambdaFunctor& a) : lf(a) {} > > template <class SigArgs> struct sig { > typedef typename > LambdaFunctor::inherited::template > sig<typename SigArgs::tail_type>::type type; > }; > > > > template<class A> > typename sig<tuple<const const_incorrect_lambda_functor, A&> >::type > operator()(const A& a) const { > return lf.template call<typename sig<tuple<const const_incorrect_lambda_functor, A&> >::type >(const_cast<A&>(a), detail::constant_null_type, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B> > typename sig<tuple<const const_incorrect_lambda_functor, A&, B&> >::type > operator()(const A& a, const B& b) const { > return lf.template call<typename sig<tuple<const const_incorrect_lambda_functor, A&, B&> >::type >(const_cast<A&>(a), const_cast<B&>(b), detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B, class C> > typename sig<tuple<const const_incorrect_lambda_functor, A&, B&, C&> >::type > operator()(const A& a, const B& b, const C& c) const { > return lf.template call<typename sig<tuple<const const_incorrect_lambda_functor, A&, B&, C&> >::type>(const_cast<A&>(a), const_cast<B&>(b), const_cast<C&>(c), detail::constant_null_type); > } >}; ># 196 "/usr/include/boost/lambda/detail/ret.hpp" 3 4 >template <class LambdaFunctor> >struct const_parameter_lambda_functor { > LambdaFunctor lf; >public: > > explicit const_parameter_lambda_functor(const LambdaFunctor& a) : lf(a) {} > > template <class SigArgs> struct sig { > typedef typename > LambdaFunctor::inherited::template > sig<typename SigArgs::tail_type>::type type; > }; > > > > template<class A> > typename sig<tuple<const const_parameter_lambda_functor, const A&> >::type > operator()(const A& a) const { > return lf.template call<typename sig<tuple<const const_parameter_lambda_functor, const A&> >::type >(a, detail::constant_null_type, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B> > typename sig<tuple<const const_parameter_lambda_functor, const A&, const B&> >::type > operator()(const A& a, const B& b) const { > return lf.template call<typename sig<tuple<const const_parameter_lambda_functor, const A&, const B&> >::type >(a, b, detail::constant_null_type, detail::constant_null_type); > } > > template<class A, class B, class C> > typename sig<tuple<const const_parameter_lambda_functor, const A&, const B&, const C&> >>::type > operator()(const A& a, const B& b, const C& c) const { > return lf.template call<typename sig<tuple<const const_parameter_lambda_functor, const A&, const B&, const C&> >::type>(a, b, c, detail::constant_null_type); > } >}; > >template <class Arg> >inline const const_incorrect_lambda_functor<lambda_functor<Arg> > >break_const(const lambda_functor<Arg>& lf) >{ > return const_incorrect_lambda_functor<lambda_functor<Arg> >(lf); >} > > >template <class Arg> >inline const const_parameter_lambda_functor<lambda_functor<Arg> > >const_parameters(const lambda_functor<Arg>& lf) >{ > return const_parameter_lambda_functor<lambda_functor<Arg> >(lf); >} ># 254 "/usr/include/boost/lambda/detail/ret.hpp" 3 4 >struct voidifier_action { > template<class Ret, class A> static void apply(A&) {} >}; > >template<class Args> struct return_type_N<voidifier_action, Args> { > typedef void type; >}; > >template<class Arg1> >inline const >lambda_functor< > lambda_functor_base< > action<1, voidifier_action>, > tuple<lambda_functor<Arg1> > > > >> >make_void(const lambda_functor<Arg1>& a1) { >return > lambda_functor_base< > action<1, voidifier_action>, > tuple<lambda_functor<Arg1> > > > > (tuple<lambda_functor<Arg1> > (a1)); >} > > > > >template<class Arg1> >inline const >lambda_functor< > lambda_functor_base<do_nothing_action, null_type> >> >make_void(const Arg1&) { >return > lambda_functor_base<do_nothing_action, null_type>(); >} ># 305 "/usr/include/boost/lambda/detail/ret.hpp" 3 4 >template<class T> >struct result_type_to_sig : public T { > template<class Args> struct sig { typedef typename T::result_type type; }; > result_type_to_sig(const T& t) : T(t) {} >}; > >template<class F> >inline result_type_to_sig<F> std_functor(const F& f) { return f; } > > >} >} ># 58 "/usr/include/boost/lambda/core.hpp" 2 3 4 > >namespace boost { >namespace lambda { > >namespace { > > > boost::lambda::placeholder1_type free1 = boost::lambda::placeholder1_type(); > boost::lambda::placeholder2_type free2 = boost::lambda::placeholder2_type(); > boost::lambda::placeholder3_type free3 = boost::lambda::placeholder3_type(); > > boost::lambda::placeholder1_type& _1 = free1; > boost::lambda::placeholder2_type& _2 = free2; > boost::lambda::placeholder3_type& _3 = free3; > >} > >} >} ># 16 "/usr/include/boost/lambda/bind.hpp" 2 3 4 > ># 1 "/usr/include/boost/lambda/detail/bind_functions.hpp" 1 3 4 ># 17 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >namespace boost { >namespace lambda { ># 40 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result> >inline const >lambda_functor< > lambda_functor_base< > action<1, function_action<1, Result> >, > typename detail::bind_tuple_mapper<Result(&)()>::type > > >> > >bind(Result(& a1)()) { > return > lambda_functor_base< > action<1, function_action<1, Result> >, > typename detail::bind_tuple_mapper<Result(&)()>::type > > > ( typename detail::bind_tuple_mapper<Result(&)()>::type > (a1) > ); >} > > > >template <class Arg1> >inline const >lambda_functor< > lambda_functor_base< > action<1, function_action<1> >, > typename detail::bind_tuple_mapper<const Arg1>::type > > >> > >bind(const Arg1& a1) { > return > lambda_functor_base< > action<1, function_action<1> >, > typename detail::bind_tuple_mapper<const Arg1>::type > > > ( typename detail::bind_tuple_mapper<const Arg1>::type > (a1) > ); >} > >template <class Result, class Arg1> >inline const >lambda_functor< > lambda_functor_base< > action<1, function_action<1, Result> >, > typename detail::bind_tuple_mapper<const Arg1>::type > > >> > >bind(const Arg1& a1) { > return > lambda_functor_base< > action<1, function_action<1, Result> >, > typename detail::bind_tuple_mapper<const Arg1>::type > > > ( typename detail::bind_tuple_mapper<const Arg1>::type > (a1) > ); >} ># 181 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result, class Par1, class Arg2> >inline const >lambda_functor< > lambda_functor_base< > action<2, function_action<2, Result> >, > typename detail::bind_tuple_mapper<Result(&)(Par1), const Arg2>::type > > >> > >bind(Result(&a1)(Par1), const Arg2& a2) { > return > lambda_functor_base< > action<2, function_action<2, Result> >, > typename detail::bind_tuple_mapper<Result(&)(Par1), const Arg2>::type > > > ( typename detail::bind_tuple_mapper<Result(&)(Par1), const Arg2>::type > (a1, a2) > ); >} > > > >template <class Arg1, class Arg2> >inline const >lambda_functor< > lambda_functor_base< > action<2, function_action<2> >, > typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type > > >> > >bind(const Arg1& a1, const Arg2& a2) { > return > lambda_functor_base< > action<2, function_action<2> >, > typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type > > > ( typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type > (a1, a2) > ); >} > >template <class Result, class Arg1, class Arg2> >inline const >lambda_functor< > lambda_functor_base< > action<2, function_action<2, Result> >, > typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type > > >> > >bind(const Arg1& a1, const Arg2& a2) { > return > lambda_functor_base< > action<2, function_action<2, Result> >, > typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type > > > ( typename detail::bind_tuple_mapper<const Arg1, const Arg2>::type > (a1, a2) > ); >} ># 322 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result, class Par1, class Par2, class Arg2, class Arg3> >inline const >lambda_functor< > lambda_functor_base< > action<3, function_action<3, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2), const Arg2, const Arg3 > >::type > > >> > >bind(Result(&a1)(Par1, Par2), const Arg2& a2, const Arg3& a3) { > return > lambda_functor_base< > action<3, function_action<3, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2), const Arg2, const Arg3 > >::type > > > ( typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2), const Arg2, const Arg3 > >::type > (a1, a2, a3) > ); >} > > > >template <class Arg1, class Arg2, class Arg3> >inline const >lambda_functor< > lambda_functor_base< > action<3, function_action<3> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3) { > return > lambda_functor_base< > action<3, function_action<3> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3 > >::type > (a1, a2, a3) > ); >} > >template <class Result, class Arg1, class Arg2, class Arg3> >inline const >lambda_functor< > lambda_functor_base< > action<3, function_action<3, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3) { > return > lambda_functor_base< > action<3, function_action<3, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3 > >::type > (a1, a2, a3) > ); >} ># 491 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result, class Par1, class Par2, class Par3, class Arg2, > class Arg3, class Arg4> >inline const >lambda_functor< > lambda_functor_base< > action<4, function_action<4, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3), const Arg2, const Arg3, const Arg4 > >::type > > >> > >bind(Result(&a1)(Par1, Par2, Par3), const Arg2& a2, const Arg3& a3, > const Arg4& a4) { > return > lambda_functor_base< > action<4, function_action<4, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3), const Arg2, const Arg3, const Arg4 > >::type > > > ( typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3), const Arg2, const Arg3, const Arg4 > >::type > (a1, a2, a3, a4) > ); >} > > > >template <class Arg1, class Arg2, class Arg3, class Arg4> >inline const >lambda_functor< > lambda_functor_base< > action<4, function_action<4> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4) { > return > lambda_functor_base< > action<4, function_action<4> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4 > >::type > (a1, a2, a3, a4) > ); >} > >template <class Result, class Arg1, class Arg2, class Arg3, class Arg4> >inline const >lambda_functor< > lambda_functor_base< > action<4, function_action<4, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4) { > return > lambda_functor_base< > action<4, function_action<4, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4 > >::type > (a1, a2, a3, a4) > ); >} ># 666 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result, class Par1, class Par2, class Par3, class Par4, > class Arg2, class Arg3, class Arg4, class Arg5> >inline const >lambda_functor< > lambda_functor_base< > action<5, function_action<5, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4), const Arg2, const Arg3, const Arg4, > const Arg5 > >::type > > >> > >bind(Result(&a1)(Par1, Par2, Par3, Par4), const Arg2& a2, const Arg3& a3, > const Arg4& a4, const Arg5& a5) { > return > lambda_functor_base< > action<5, function_action<5, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4), const Arg2, const Arg3, const Arg4, > const Arg5 > >::type > > > ( typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4), const Arg2, const Arg3, const Arg4, > const Arg5 > >::type > (a1, a2, a3, a4, a5) > ); >} > > > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5> >inline const >lambda_functor< > lambda_functor_base< > action<5, function_action<5> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5) { > return > lambda_functor_base< > action<5, function_action<5> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5 > >::type > (a1, a2, a3, a4, a5) > ); >} > >template <class Result, class Arg1, class Arg2, class Arg3, class Arg4, > class Arg5> >inline const >lambda_functor< > lambda_functor_base< > action<5, function_action<5, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5) { > return > lambda_functor_base< > action<5, function_action<5, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5 > >::type > (a1, a2, a3, a4, a5) > ); >} ># 853 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result, class Par1, class Par2, class Par3, class Par4, > class Par5, class Arg2, class Arg3, class Arg4, class Arg5, > class Arg6> >inline const >lambda_functor< > lambda_functor_base< > action<6, function_action<6, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5), const Arg2, const Arg3, > const Arg4, const Arg5, const Arg6 > >::type > > >> > >bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5), const Arg2& a2, > const Arg3& a3, const Arg4& a4, const Arg5& a5, const Arg6& a6) { > return > lambda_functor_base< > action<6, function_action<6, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5), const Arg2, const Arg3, > const Arg4, const Arg5, const Arg6 > >::type > > > ( typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5), const Arg2, const Arg3, > const Arg4, const Arg5, const Arg6 > >::type > (a1, a2, a3, a4, a5, a6) > ); >} > > > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, > class Arg6> >inline const >lambda_functor< > lambda_functor_base< > action<6, function_action<6> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6) { > return > lambda_functor_base< > action<6, function_action<6> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6 > >::type > (a1, a2, a3, a4, a5, a6) > ); >} > >template <class Result, class Arg1, class Arg2, class Arg3, class Arg4, > class Arg5, class Arg6> >inline const >lambda_functor< > lambda_functor_base< > action<6, function_action<6, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6) { > return > lambda_functor_base< > action<6, function_action<6, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6 > >::type > (a1, a2, a3, a4, a5, a6) > ); >} ># 1044 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result, class Par1, class Par2, class Par3, class Par4, > class Par5, class Par6, class Arg2, class Arg3, class Arg4, > class Arg5, class Arg6, class Arg7> >inline const >lambda_functor< > lambda_functor_base< > action<7, function_action<7, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2, const Arg3, > const Arg4, const Arg5, const Arg6, const Arg7 > >::type > > >> > >bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2& a2, > const Arg3& a3, const Arg4& a4, const Arg5& a5, const Arg6& a6, > const Arg7& a7) { > return > lambda_functor_base< > action<7, function_action<7, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2, const Arg3, > const Arg4, const Arg5, const Arg6, const Arg7 > >::type > > > ( typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6), const Arg2, const Arg3, > const Arg4, const Arg5, const Arg6, const Arg7 > >::type > (a1, a2, a3, a4, a5, a6, a7) > ); >} > > > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, > class Arg6, class Arg7> >inline const >lambda_functor< > lambda_functor_base< > action<7, function_action<7> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6, const Arg7& a7) { > return > lambda_functor_base< > action<7, function_action<7> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7 > >::type > (a1, a2, a3, a4, a5, a6, a7) > ); >} > >template <class Result, class Arg1, class Arg2, class Arg3, class Arg4, > class Arg5, class Arg6, class Arg7> >inline const >lambda_functor< > lambda_functor_base< > action<7, function_action<7, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6, const Arg7& a7) { > return > lambda_functor_base< > action<7, function_action<7, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7 > >::type > (a1, a2, a3, a4, a5, a6, a7) > ); >} ># 1243 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result, class Par1, class Par2, class Par3, class Par4, > class Par5, class Par6, class Par7, class Arg2, class Arg3, > class Arg4, class Arg5, class Arg6, class Arg7, class Arg8> >inline const >lambda_functor< > lambda_functor_base< > action<8, function_action<8, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2, > const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8 > >::type > > >> > >bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2& a2, > const Arg3& a3, const Arg4& a4, const Arg5& a5, const Arg6& a6, > const Arg7& a7, const Arg8& a8) { > return > lambda_functor_base< > action<8, function_action<8, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2, > const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8 > >::type > > > ( typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7), const Arg2, > const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8 > >::type > (a1, a2, a3, a4, a5, a6, a7, a8) > ); >} > > > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, > class Arg6, class Arg7, class Arg8> >inline const >lambda_functor< > lambda_functor_base< > action<8, function_action<8> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7, const Arg8 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8) { > return > lambda_functor_base< > action<8, function_action<8> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8 > >::type > (a1, a2, a3, a4, a5, a6, a7, a8) > ); >} > >template <class Result, class Arg1, class Arg2, class Arg3, class Arg4, > class Arg5, class Arg6, class Arg7, class Arg8> >inline const >lambda_functor< > lambda_functor_base< > action<8, function_action<8, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7, const Arg8 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8) { > return > lambda_functor_base< > action<8, function_action<8, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8 > >::type > (a1, a2, a3, a4, a5, a6, a7, a8) > ); >} ># 1442 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result, class Par1, class Par2, class Par3, class Par4, > class Par5, class Par6, class Par7, class Par8, class Arg2, > class Arg3, class Arg4, class Arg5, class Arg6, class Arg7, > class Arg8, class Arg9> >inline const >lambda_functor< > lambda_functor_base< > action<9, function_action<9, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), const Arg2, > const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, const Arg8, > const Arg9 > >::type > > >> > >bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), > const Arg2& a2, const Arg3& a3, const Arg4& a4, const Arg5& a5, > const Arg6& a6, const Arg7& a7, const Arg8& a8, const Arg9& a9) { > return > lambda_functor_base< > action<9, function_action<9, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), const Arg2, > const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, > const Arg8, const Arg9 > >::type > > > ( typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8), const Arg2, > const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, > const Arg8, const Arg9 > >::type > (a1, a2, a3, a4, a5, a6, a7, a8, a9) > ); >} > > > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, > class Arg6, class Arg7, class Arg8, class Arg9> >inline const >lambda_functor< > lambda_functor_base< > action<9, function_action<9> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7, const Arg8, const Arg9 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8, > const Arg9& a9) { > return > lambda_functor_base< > action<9, function_action<9> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8, const Arg9 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8, const Arg9 > >::type > (a1, a2, a3, a4, a5, a6, a7, a8, a9) > ); >} > >template <class Result, class Arg1, class Arg2, class Arg3, class Arg4, > class Arg5, class Arg6, class Arg7, class Arg8, class Arg9> >inline const >lambda_functor< > lambda_functor_base< > action<9, function_action<9, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7, const Arg8, const Arg9 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8, > const Arg9& a9) { > return > lambda_functor_base< > action<9, function_action<9, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8, const Arg9 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8, const Arg9 > >::type > (a1, a2, a3, a4, a5, a6, a7, a8, a9) > ); >} ># 1657 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >template <class Result, class Par1, class Par2, class Par3, class Par4, > class Par5, class Par6, class Par7, class Par8, class Par9, > class Arg2, class Arg3, class Arg4, class Arg5, class Arg6, > class Arg7, class Arg8, class Arg9, class Arg10> >inline const >lambda_functor< > lambda_functor_base< > action<10, function_action<10, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9), > const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, const Arg7, > const Arg8, const Arg9, const Arg10 > >::type > > >> > >bind(Result(&a1)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9), > const Arg2& a2, const Arg3& a3, const Arg4& a4, const Arg5& a5, > const Arg6& a6, const Arg7& a7, const Arg8& a8, const Arg9& a9, > const Arg10& a10) { > return > lambda_functor_base< > action<10, function_action<10, Result> >, > typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9), > const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7, const Arg8, const Arg9, const Arg10 > >::type > > > ( typename detail::bind_tuple_mapper< > Result(&)(Par1, Par2, Par3, Par4, Par5, Par6, Par7, Par8, Par9), > const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7, const Arg8, const Arg9, const Arg10 > >::type > (a1, a2, a3, a4, a5, a6, a7, a8, a9, a10) > ); >} > > > >template <class Arg1, class Arg2, class Arg3, class Arg4, class Arg5, > class Arg6, class Arg7, class Arg8, class Arg9, class Arg10> >inline const >lambda_functor< > lambda_functor_base< > action<10, function_action<10> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7, const Arg8, const Arg9, const Arg10 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8, > const Arg9& a9, const Arg10& a10) { > return > lambda_functor_base< > action<10, function_action<10> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8, const Arg9, const Arg10 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8, const Arg9, const Arg10 > >::type > (a1, a2, a3, a4, a5, a6, a7, a8, a9, a10) > ); >} > >template <class Result, class Arg1, class Arg2, class Arg3, class Arg4, > class Arg5, class Arg6, class Arg7, class Arg8, class Arg9, > class Arg10> >inline const >lambda_functor< > lambda_functor_base< > action<10, function_action<10, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, const Arg6, > const Arg7, const Arg8, const Arg9, const Arg10 > >::type > > >> > >bind(const Arg1& a1, const Arg2& a2, const Arg3& a3, const Arg4& a4, > const Arg5& a5, const Arg6& a6, const Arg7& a7, const Arg8& a8, > const Arg9& a9, const Arg10& a10) { > return > lambda_functor_base< > action<10, function_action<10, Result> >, > typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8, const Arg9, const Arg10 > >::type > > > ( typename detail::bind_tuple_mapper< > const Arg1, const Arg2, const Arg3, const Arg4, const Arg5, > const Arg6, const Arg7, const Arg8, const Arg9, const Arg10 > >::type > (a1, a2, a3, a4, a5, a6, a7, a8, a9, a10) > ); >} ># 1876 "/usr/include/boost/lambda/detail/bind_functions.hpp" 3 4 >} >} ># 18 "/usr/include/boost/lambda/bind.hpp" 2 3 4 ># 31 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" 2 > ># 1 "/usr/include/boost/lambda/lambda.hpp" 1 3 4 ># 21 "/usr/include/boost/lambda/lambda.hpp" 3 4 ># 1 "/usr/include/boost/lambda/detail/operator_actions.hpp" 1 3 4 ># 14 "/usr/include/boost/lambda/detail/operator_actions.hpp" 3 4 >namespace boost { >namespace lambda { > > > > >class plus_action {}; >class minus_action {}; >class multiply_action {}; >class divide_action {}; >class remainder_action {}; > > > >class leftshift_action {}; >class rightshift_action {}; >class xor_action {}; > > > > >class and_action {}; >class or_action {}; >class not_action {}; > > > >class less_action {}; >class greater_action {}; >class lessorequal_action {}; >class greaterorequal_action {}; >class equal_action {}; >class notequal_action {}; > > > >class increment_action {}; >class decrement_action {}; > > > > > >class addressof_action {}; > >class contentsof_action {}; > > > > > >template <class Action> class arithmetic_action; >template <class Action> class bitwise_action; >template <class Action> class logical_action; >template <class Action> class relational_action; >template <class Action> class arithmetic_assignment_action; >template <class Action> class bitwise_assignment_action; >template <class Action> class unary_arithmetic_action; >template <class Action> class pre_increment_decrement_action; >template <class Action> class post_increment_decrement_action; > > > > > > >template <class Act> struct is_protectable<arithmetic_action<Act> > { > static const bool value = true; >}; >template <class Act> struct is_protectable<bitwise_action<Act> > { > static const bool value = true; >}; >template <class Act> struct is_protectable<logical_action<Act> > { > static const bool value = true; >}; >template <class Act> struct is_protectable<relational_action<Act> > { > static const bool value = true; >}; >template <class Act> >struct is_protectable<arithmetic_assignment_action<Act> > { > static const bool value = true; >}; >template <class Act> struct is_protectable<bitwise_assignment_action<Act> > { > static const bool value = true; >}; >template <class Act> struct is_protectable<unary_arithmetic_action<Act> > { > static const bool value = true; >}; >template <class Act> >struct is_protectable<pre_increment_decrement_action<Act> > { > static const bool value = true; >}; >template <class Act> struct >is_protectable<post_increment_decrement_action<Act> > { > static const bool value = true; >}; > >template <> struct is_protectable<other_action<addressof_action> > { > static const bool value = true; >}; >template <> struct is_protectable<other_action<contentsof_action> > { > static const bool value = true; >}; > >template<> struct is_protectable<other_action<subscript_action> > { > static const bool value = true; >}; >template<> struct is_protectable<other_action<assignment_action> > { > static const bool value = true; >}; > > > > > >} >} ># 22 "/usr/include/boost/lambda/lambda.hpp" 2 3 4 ># 1 "/usr/include/boost/lambda/detail/operator_lambda_func_base.hpp" 1 3 4 ># 16 "/usr/include/boost/lambda/detail/operator_lambda_func_base.hpp" 3 4 >namespace boost { >namespace lambda { > > > > > > > >template<class Args> >class lambda_functor_base<other_action<comma_action>, Args> { >public: > Args args; >public: > explicit lambda_functor_base(const Args& a) : args(a) {} > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { > return detail::select(boost::tuples::get<0>(args), a, b, c, env), > detail::select(boost::tuples::get<1>(args), a, b, c, env); > } > > > template<class SigArgs> struct sig { > private: > typedef typename > detail::deduce_argument_types<Args, SigArgs>::type rets_t; > public: > typedef typename return_type_2_comma< > typename detail::element_or_null<0, rets_t>::type, > typename detail::element_or_null<1, rets_t>::type > >::type type; > }; > >}; > >namespace detail { > > > > >template<class Action, class Bound, class Open> class binary_rt { > private: > typedef typename > detail::deduce_argument_types<Bound, Open>::type rets_t; > public: > typedef typename return_type_2_prot< > Action, > typename detail::element_or_null<0, rets_t>::type, > typename detail::element_or_null<1, rets_t>::type > >::type type; >}; > > > >template<class Action, class Bound, class Open> class unary_rt { > private: > typedef typename > detail::deduce_argument_types<Bound, Open>::type rets_t; > public: > typedef typename return_type_1_prot< > Action, > typename detail::element_or_null<0, rets_t>::type > >::type type; >}; > > >} > > > >template<class Args> >class lambda_functor_base<logical_action<and_action>, Args> { >public: > Args args; >public: > explicit lambda_functor_base(const Args& a) : args(a) {} > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { > return detail::select(boost::tuples::get<0>(args), a, b, c, env) && > detail::select(boost::tuples::get<1>(args), a, b, c, env); > } > template<class SigArgs> struct sig { > typedef typename > detail::binary_rt<logical_action<and_action>, Args, SigArgs>::type type; > }; >}; > > > >template<class Args> >class lambda_functor_base<logical_action< or_action>, Args> { >public: > Args args; >public: > explicit lambda_functor_base(const Args& a) : args(a) {} > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { > return detail::select(boost::tuples::get<0>(args), a, b, c, env) || > detail::select(boost::tuples::get<1>(args), a, b, c, env); > } > > template<class SigArgs> struct sig { > typedef typename > detail::binary_rt<logical_action<or_action>, Args, SigArgs>::type type; > }; >}; > > >template<class Args> >class lambda_functor_base<other_action<subscript_action>, Args> { >public: > Args args; >public: > explicit lambda_functor_base(const Args& a) : args(a) {} > > template<class RET, class A, class B, class C, class Env> > RET call(A& a, B& b, C& c, Env& env) const { > return detail::select(boost::tuples::get<0>(args), a, b, c, env) > [detail::select(boost::tuples::get<1>(args), a, b, c, env)]; > } > > template<class SigArgs> struct sig { > typedef typename > detail::binary_rt<other_action<subscript_action>, Args, SigArgs>::type > type; > }; >}; ># 206 "/usr/include/boost/lambda/detail/operator_lambda_func_base.hpp" 3 4 >template<class Args> class lambda_functor_base<arithmetic_action<plus_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) + detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_action<plus_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<arithmetic_action<minus_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) - detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_action<minus_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<arithmetic_action<multiply_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) * detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_action<multiply_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<arithmetic_action<divide_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) / detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_action<divide_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<arithmetic_action<remainder_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) % detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_action<remainder_action>, Args, SigArgs>::type type; }; }; > >template<class Args> class lambda_functor_base<bitwise_action<leftshift_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) << detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_action<leftshift_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<bitwise_action<rightshift_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) >> detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_action<rightshift_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<bitwise_action<and_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) & detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_action<and_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<bitwise_action<or_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) | detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_action<or_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<bitwise_action<xor_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) ^ detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_action<xor_action>, Args, SigArgs>::type type; }; }; > >template<class Args> class lambda_functor_base<relational_action<less_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) < detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<relational_action<less_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<relational_action<greater_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) > detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<relational_action<greater_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<relational_action<lessorequal_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) <= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<relational_action<lessorequal_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<relational_action<greaterorequal_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) >= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<relational_action<greaterorequal_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<relational_action<equal_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) == detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<relational_action<equal_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<relational_action<notequal_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) != detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<relational_action<notequal_action>, Args, SigArgs>::type type; }; }; > >template<class Args> class lambda_functor_base<arithmetic_assignment_action<plus_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) += detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_assignment_action<plus_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<arithmetic_assignment_action<minus_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) -= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_assignment_action<minus_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<arithmetic_assignment_action<multiply_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) *= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_assignment_action<multiply_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<arithmetic_assignment_action<divide_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) /= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_assignment_action<divide_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<arithmetic_assignment_action<remainder_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) %= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<arithmetic_assignment_action<remainder_action>, Args, SigArgs>::type type; }; }; > >template<class Args> class lambda_functor_base<bitwise_assignment_action<leftshift_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) <<= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_assignment_action<leftshift_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<bitwise_assignment_action<rightshift_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) >>= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_assignment_action<rightshift_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<bitwise_assignment_action<and_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) &= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_assignment_action<and_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<bitwise_assignment_action<or_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) |= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_assignment_action<or_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<bitwise_assignment_action<xor_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) ^= detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<bitwise_assignment_action<xor_action>, Args, SigArgs>::type type; }; }; > >template<class Args> class lambda_functor_base<other_action< assignment_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) = detail::select(boost::tuples::get<1>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::binary_rt<other_action< assignment_action>, Args, SigArgs>::type type; }; }; > > >template<class Args> class lambda_functor_base<unary_arithmetic_action<plus_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return + detail::select(boost::tuples::get<0>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::unary_rt<unary_arithmetic_action<plus_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<unary_arithmetic_action<minus_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return - detail::select(boost::tuples::get<0>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::unary_rt<unary_arithmetic_action<minus_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<bitwise_action<not_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return ~ detail::select(boost::tuples::get<0>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::unary_rt<bitwise_action<not_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<logical_action<not_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return ! detail::select(boost::tuples::get<0>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::unary_rt<logical_action<not_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<pre_increment_decrement_action<increment_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return ++ detail::select(boost::tuples::get<0>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::unary_rt<pre_increment_decrement_action<increment_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<pre_increment_decrement_action<decrement_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return -- detail::select(boost::tuples::get<0>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::unary_rt<pre_increment_decrement_action<decrement_action>, Args, SigArgs>::type type; }; }; > >template<class Args> class lambda_functor_base<other_action<addressof_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return & detail::select(boost::tuples::get<0>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::unary_rt<other_action<addressof_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<other_action<contentsof_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return * detail::select(boost::tuples::get<0>(args), a, b, c, env); } template<class SigArgs> struct sig { typedef typename detail::unary_rt<other_action<contentsof_action>, Args, SigArgs>::type type; }; }; > >template<class Args> class lambda_functor_base<post_increment_decrement_action<increment_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) ++; } template<class SigArgs> struct sig { typedef typename detail::unary_rt<post_increment_decrement_action<increment_action>, Args, SigArgs>::type type; }; }; >template<class Args> class lambda_functor_base<post_increment_decrement_action<decrement_action>, Args> { public: Args args; public: explicit lambda_functor_base(const Args& a) : args(a) {} template<class RET, class A, class B, class C, class Env> RET call(A& a, B& b, C& c, Env& env) const { return detail::select(boost::tuples::get<0>(args), a, b, c, env) --; } template<class SigArgs> struct sig { typedef typename detail::unary_rt<post_increment_decrement_action<decrement_action>, Args, SigArgs>::type type; }; }; > > > > > > >} >} ># 23 "/usr/include/boost/lambda/lambda.hpp" 2 3 4 ># 1 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 1 3 4 ># 14 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 3 4 ># 1 "/usr/include/boost/lambda/detail/is_instance_of.hpp" 1 3 4 ># 18 "/usr/include/boost/lambda/detail/is_instance_of.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/enum_shifted_params.hpp" 1 3 4 ># 19 "/usr/include/boost/lambda/detail/is_instance_of.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/repeat_2nd.hpp" 1 3 4 ># 20 "/usr/include/boost/lambda/detail/is_instance_of.hpp" 2 3 4 ># 51 "/usr/include/boost/lambda/detail/is_instance_of.hpp" 3 4 >namespace boost { >namespace lambda { ># 85 "/usr/include/boost/lambda/detail/is_instance_of.hpp" 3 4 >namespace detail { template <template< class> class F> struct conversion_tester_1 { template< class A0> conversion_tester_1 (const F< A0>&); }; } template <class From, template < class> class To> struct is_instance_of_1 { private: typedef ::boost::is_convertible< From, detail::conversion_tester_1<To> > helper_type; public: static const bool value = helper_type::value; }; namespace detail { template <template< class , class> class F> struct conversion_tester_2 { template< class A0 , class A1> conversion_tester_2 (const F< A0 , A1>&); }; } template <class From, template < class , class> class To> struct is_instance_of_2 { private: typedef ::boost::is_convertible< From, detail::conversion_tester_2<To> > helper_type; public: static const bool value = helper_type::value; }; namespace detail { template <template< class , class , class> class F> struct conversion_tester_3 { template< class A0 , class A1 , class A2> conversion_tester_3 (const F< A0 , A1 , A2>&); }; } template <class From, template < class , class , class> class To> struct is_instance_of_3 { private: typedef ::boost::is_convertible< From, detail::conversion_tester_3<To> > helper_type; public: static const bool value = helper_type::value; }; namespace detail { template <template< class , class , class , class> class F> struct conversion_tester_4 { template< class A0 , class A1 , class A2 , class A3> conversion_tester_4 (const F< A0 , A1 , A2 , A3>&); }; } template <class From, template < class , class , class , class> class To> struct is_instance_of_4 { private: typedef ::boost::is_convertible< From, detail::conversion_tester_4<To> > helper_type; public: static const bool value = helper_type::value; }; ># 96 "/usr/include/boost/lambda/detail/is_instance_of.hpp" 3 4 >} >} ># 15 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 2 3 4 > > ># 1 "/usr/include/boost/indirect_reference.hpp" 1 3 4 ># 14 "/usr/include/boost/indirect_reference.hpp" 3 4 ># 1 "/usr/include/boost/detail/is_incrementable.hpp" 1 3 4 > > > > > > ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 8 "/usr/include/boost/detail/is_incrementable.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 15 "/usr/include/boost/detail/is_incrementable.hpp" 2 3 4 > >namespace boost { namespace detail { ># 25 "/usr/include/boost/detail/is_incrementable.hpp" 3 4 >namespace is_incrementable_ >{ > > > struct tag {}; > > > > > struct any { template <class T> any(T const&); }; ># 53 "/usr/include/boost/detail/is_incrementable.hpp" 3 4 > tag operator++(any const&); > tag operator++(any const&,int); ># 63 "/usr/include/boost/detail/is_incrementable.hpp" 3 4 > tag operator,(tag,int); ># 73 "/usr/include/boost/detail/is_incrementable.hpp" 3 4 > char (& check_(tag) )[2]; > > template <class T> > char check_(T const&); > > > template <class T> > struct impl > { > static typename boost::remove_cv<T>::type& x; > > static const bool value = sizeof(is_incrementable_::check_((++x,0))) == 1 > > > ; > }; > > template <class T> > struct postfix_impl > { > static typename boost::remove_cv<T>::type& x; > > static const bool value = sizeof(is_incrementable_::check_((x++,0))) == 1 > > > ; > }; > > > > > >} > > > >template<typename T> >struct is_incrementable >: public ::boost::integral_constant<bool,::boost::detail::is_incrementable_::impl<T>::value> >{ > > >}; > >template<typename T> >struct is_postfix_incrementable >: public ::boost::integral_constant<bool,::boost::detail::is_incrementable_::impl<T>::value> >{ > > >}; > >} > > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 133 "/usr/include/boost/detail/is_incrementable.hpp" 2 3 4 ># 15 "/usr/include/boost/indirect_reference.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/pointee.hpp" 1 3 4 ># 23 "/usr/include/boost/pointee.hpp" 3 4 >namespace boost { > >namespace detail >{ > template <class P> > struct smart_ptr_pointee > { > typedef typename P::element_type type; > }; > > template <class Iterator> > struct iterator_pointee > { > typedef typename iterator_traits<Iterator>::value_type value_type; > > struct impl > { > template <class T> > static char test(T const&); > > static char (& test(value_type&) )[2]; > > static Iterator& x; > }; > > static const bool is_constant = sizeof(impl::test(*impl::x)) == 1; > > typedef typename mpl::if_c< > > > > is_constant > > , typename add_const<value_type>::type > , value_type > >::type type; > }; >} > >template <class P> >struct pointee > : mpl::eval_if< > detail::is_incrementable<P> > , detail::iterator_pointee<P> > , detail::smart_ptr_pointee<P> > > >{ >}; > >} ># 19 "/usr/include/boost/indirect_reference.hpp" 2 3 4 > >namespace boost { > >namespace detail >{ > template <class P> > struct smart_ptr_reference > { > typedef typename boost::pointee<P>::type& type; > }; >} > >template <class P> >struct indirect_reference > : mpl::eval_if< > detail::is_incrementable<P> > , iterator_reference<P> > , detail::smart_ptr_reference<P> > > >{ >}; > >} ># 18 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 2 3 4 > > > > > > > >namespace boost { >namespace lambda { >namespace detail { > > > > > >template <class A> struct promote_code { static const int value = -1; }; > > > > >template <> struct promote_code<bool> { static const int value = 10; }; >template <> struct promote_code<char> { static const int value = 20; }; >template <> struct promote_code<unsigned char> { static const int value = 30; }; >template <> struct promote_code<signed char> { static const int value = 40; }; >template <> struct promote_code<short int> { static const int value = 50; }; > > >template <> struct promote_code<int> { static const int value = 100; }; >template <> struct promote_code<unsigned int> { static const int value = 200; }; >template <> struct promote_code<long> { static const int value = 300; }; >template <> struct promote_code<unsigned long> { static const int value = 400; }; > >template <> struct promote_code<float> { static const int value = 500; }; >template <> struct promote_code<double> { static const int value = 600; }; >template <> struct promote_code<long double> { static const int value = 700; }; > > > > > >} >} >} > >namespace boost { >namespace lambda { >namespace detail { > >template <> struct promote_code< std::complex<float> > { static const int value = 800; }; >template <> struct promote_code< std::complex<double> > { static const int value = 900; }; >template <> struct promote_code< std::complex<long double> > { static const int value = 1000; }; > > >template <class T> struct promote_to_int { typedef T type; }; > >template <> struct promote_to_int<bool> { typedef int type; }; >template <> struct promote_to_int<char> { typedef int type; }; >template <> struct promote_to_int<unsigned char> { typedef int type; }; >template <> struct promote_to_int<signed char> { typedef int type; }; >template <> struct promote_to_int<short int> { typedef int type; }; > > > > >template <> struct promote_to_int<unsigned short int> >{ > typedef > detail::IF<sizeof(int) <= sizeof(unsigned short int), > > unsigned int, > int>::RET type; >}; > > > > >} > > > > > >template<class Act, class A> >struct plain_return_type_1 { > typedef detail::unspecified type; >}; > > > >template<class Act, class A> >struct plain_return_type_1<unary_arithmetic_action<Act>, A> { > typedef A type; >}; > >template<class Act, class A> >struct return_type_1<unary_arithmetic_action<Act>, A> { > typedef > typename plain_return_type_1< > unary_arithmetic_action<Act>, > typename detail::remove_reference_and_cv<A>::type > >::type type; >}; > > >template<class A> >struct plain_return_type_1<bitwise_action<not_action>, A> { > typedef A type; >}; > > >template<class A> struct return_type_1<bitwise_action<not_action>, A> { > typedef > typename plain_return_type_1< > bitwise_action<not_action>, > typename detail::remove_reference_and_cv<A>::type > >::type type; >}; > > > > >template<class Act, class A> >struct plain_return_type_1<pre_increment_decrement_action<Act>, A> { > typedef A& type; >}; > >template<class Act, class A> >struct return_type_1<pre_increment_decrement_action<Act>, A> { > typedef > typename plain_return_type_1< > pre_increment_decrement_action<Act>, > typename detail::remove_reference_and_cv<A>::type > >::type type; >}; > > >template<class Act, class A> >struct plain_return_type_1<post_increment_decrement_action<Act>, A> { > typedef A type; >}; > >template<class Act, class A> >struct return_type_1<post_increment_decrement_action<Act>, A> >{ > typedef > typename plain_return_type_1< > post_increment_decrement_action<Act>, > typename detail::remove_reference_and_cv<A>::type > >::type type; >}; > > >template<class A> >struct plain_return_type_1<logical_action<not_action>, A> { > typedef bool type; >}; > >template<class A> >struct return_type_1<logical_action<not_action>, A> { > typedef > typename plain_return_type_1< > logical_action<not_action>, > typename detail::remove_reference_and_cv<A>::type > >::type type; >}; > > > > >template<class A> >struct return_type_1<other_action<addressof_action>, A> { > typedef > typename plain_return_type_1< > other_action<addressof_action>, > typename detail::remove_reference_and_cv<A>::type > >::type type1; > > > > typedef typename detail::IF< > boost::is_same<type1, detail::unspecified>::value, > typename boost::remove_reference<A>::type*, > type1 > >::RET type; >}; ># 214 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 3 4 >namespace detail { > > >template <class A> struct contentsof_type { > typedef typename boost::indirect_reference<A>::type type; >}; > > >template <> struct contentsof_type<null_type> { > typedef detail::unspecified type; >}; > > >template <class A> struct contentsof_type<const A> { > typedef typename contentsof_type<A>::type type; >}; > >template <class A> struct contentsof_type<volatile A> { > typedef typename contentsof_type<A>::type type; >}; > >template <class A> struct contentsof_type<const volatile A> { > typedef typename contentsof_type<A>::type type; >}; > > > > >template <class A> struct contentsof_type<A*> { > typedef A& type; >}; >template <class A> struct contentsof_type<A* const> { > typedef A& type; >}; >template <class A> struct contentsof_type<A* volatile> { > typedef A& type; >}; >template <class A> struct contentsof_type<A* const volatile> { > typedef A& type; >}; > >template<class A, int N> struct contentsof_type<A[N]> { > typedef A& type; >}; >template<class A, int N> struct contentsof_type<const A[N]> { > typedef const A& type; >}; >template<class A, int N> struct contentsof_type<volatile A[N]> { > typedef volatile A& type; >}; >template<class A, int N> struct contentsof_type<const volatile A[N]> { > typedef const volatile A& type; >}; > > > > > >} > >template<class A> >struct return_type_1<other_action<contentsof_action>, A> { > > typedef > typename plain_return_type_1< > other_action<contentsof_action>, > typename detail::remove_reference_and_cv<A>::type > >::type type1; > > > > typedef typename > detail::IF_type< > boost::is_same<type1, detail::unspecified>::value, > detail::contentsof_type< > typename boost::remove_reference<A>::type > >, > detail::identity_mapping<type1> > >::type type; >}; > > > > > > > >template <class Act, class A, class B> >struct plain_return_type_2 { > typedef detail::unspecified type; >}; > >namespace detail { > > >class illegal_pointer_arithmetic{}; > > > > > > > >template<class Act, class A, class B> >struct pointer_arithmetic_traits { static const bool value = false; }; > >template<class A, class B> >struct pointer_arithmetic_traits<plus_action, A, B> { > > typedef typename > array_to_pointer<typename boost::remove_reference<A>::type>::type AP; > typedef typename > array_to_pointer<typename boost::remove_reference<B>::type>::type BP; > > static const bool is_pointer_A = boost::is_pointer<AP>::value; > static const bool is_pointer_B = boost::is_pointer<BP>::value; > > static const bool value = is_pointer_A || is_pointer_B; > > > > > > > typedef typename > detail::IF< > is_pointer_A && is_pointer_B, > detail::return_type_deduction_failure< > detail::illegal_pointer_arithmetic > >, > typename detail::IF<is_pointer_A, AP, BP>::RET > >::RET type; > >}; > >template<class A, class B> >struct pointer_arithmetic_traits<minus_action, A, B> { > typedef typename > array_to_pointer<typename boost::remove_reference<A>::type>::type AP; > typedef typename > array_to_pointer<typename boost::remove_reference<B>::type>::type BP; > > static const bool is_pointer_A = boost::is_pointer<AP>::value; > static const bool is_pointer_B = boost::is_pointer<BP>::value; > > static const bool value = is_pointer_A || is_pointer_B; > > static const bool same_pointer_type = > is_pointer_A && is_pointer_B && > boost::is_same< > typename boost::remove_const< > typename boost::remove_pointer< > typename boost::remove_const<AP>::type > >::type > >::type, > typename boost::remove_const< > typename boost::remove_pointer< > typename boost::remove_const<BP>::type > >::type > >::type > >::value; > > > > > > > typedef typename > detail::IF< > same_pointer_type, const std::ptrdiff_t, > typename detail::IF< > is_pointer_A, > AP, > detail::return_type_deduction_failure<detail::illegal_pointer_arithmetic> > >::RET > >::RET type; >}; > >} > > > >namespace detail { > >template<bool is_pointer_arithmetic, class Act, class A, class B> >struct return_type_2_arithmetic_phase_1; > >template<class A, class B> struct return_type_2_arithmetic_phase_2; >template<class A, class B> struct return_type_2_arithmetic_phase_3; > >} > > > >template<class A, class B, class Act> >struct return_type_2<arithmetic_action<Act>, A, B> >{ > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2<arithmetic_action<Act>, plain_A, plain_B>::type type1; > > > typedef typename > detail::IF_type< > boost::is_same<type1, detail::unspecified>::value, > detail::return_type_2_arithmetic_phase_1< > detail::pointer_arithmetic_traits<Act, A, B>::value, Act, A, B > >, > plain_return_type_2<arithmetic_action<Act>, plain_A, plain_B> > >::type type; >}; > >namespace detail { > > >template<bool is_pointer_arithmetic, class Act, class A, class B> >struct return_type_2_arithmetic_phase_1 >{ > typedef typename > return_type_2_arithmetic_phase_2< > typename remove_reference_and_cv<A>::type, > typename remove_reference_and_cv<B>::type > >::type type; >}; > > >template<class Act, class A, class B> >struct return_type_2_arithmetic_phase_1<true, Act, A, B> >{ > typedef typename > pointer_arithmetic_traits<Act, A, B>::type type; >}; > >template<class A, class B> >struct return_type_2_arithmetic_phase_2 { > typedef typename > return_type_2_arithmetic_phase_3< > typename promote_to_int<A>::type, > typename promote_to_int<B>::type > >::type type; >}; ># 466 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 3 4 >struct promotion_of_unsigned_int >{ > typedef > detail::IF<sizeof(long) <= sizeof(unsigned int), > unsigned long, > long>::RET type; >}; > >template<> >struct return_type_2_arithmetic_phase_2<unsigned int, long> >{ > typedef promotion_of_unsigned_int::type type; >}; >template<> >struct return_type_2_arithmetic_phase_2<long, unsigned int> >{ > typedef promotion_of_unsigned_int::type type; >}; > > >template<class A, class B> struct return_type_2_arithmetic_phase_3 { > enum { promote_code_A_value = promote_code<A>::value, > promote_code_B_value = promote_code<B>::value }; > typedef typename > detail::IF< > promote_code_A_value == -1 || promote_code_B_value == -1, > detail::return_type_deduction_failure<return_type_2_arithmetic_phase_3>, > typename detail::IF< > ((int)promote_code_A_value > (int)promote_code_B_value), > A, > B > >::RET > >::RET type; >}; > >} > > > > > >template<class A, class B, class Act> >struct return_type_2<bitwise_action<Act>, A, B> >{ > > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2<bitwise_action<Act>, plain_A, plain_B>::type type1; > > > typedef typename > detail::IF_type< > boost::is_same<type1, detail::unspecified>::value, > return_type_2<arithmetic_action<plus_action>, A, B>, > plain_return_type_2<bitwise_action<Act>, plain_A, plain_B> > >::type type; ># 533 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 3 4 > static_assert(!(boost::is_float<plain_A>::value && boost::is_float<plain_B>::value), "!(boost::is_float<plain_A>::value && boost::is_float<plain_B>::value)"); > >}; > >namespace detail { ># 570 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 3 4 >template <class T> struct get_ostream_type { > typedef std::basic_ostream<typename T::char_type, > typename T::traits_type>& type; >}; > >template <class T> struct get_istream_type { > typedef std::basic_istream<typename T::char_type, > typename T::traits_type>& type; >}; > >template<class A, class B> >struct leftshift_type { >private: > typedef typename boost::remove_reference<A>::type plainA; >public: > typedef typename detail::IF_type< > is_instance_of_2<plainA, std::basic_ostream>::value, > get_ostream_type<plainA>, > detail::remove_reference_and_cv<A> > >::type type; >}; > >template<class A, class B> >struct rightshift_type { >private: > typedef typename boost::remove_reference<A>::type plainA; >public: > typedef typename detail::IF_type< > is_instance_of_2<plainA, std::basic_istream>::value, > get_istream_type<plainA>, > detail::remove_reference_and_cv<A> > >::type type; >}; > > > > >} > > >template<class A, class B> >struct return_type_2<bitwise_action<leftshift_action>, A, B> >{ > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2<bitwise_action<leftshift_action>, plain_A, plain_B>::type type1; > > > typedef typename > detail::IF_type< > boost::is_same<type1, detail::unspecified>::value, > detail::leftshift_type<A, B>, > plain_return_type_2<bitwise_action<leftshift_action>, plain_A, plain_B> > >::type type; >}; > > >template<class A, class B> >struct return_type_2<bitwise_action<rightshift_action>, A, B> >{ > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2<bitwise_action<rightshift_action>, plain_A, plain_B>::type type1; > > > typedef typename > detail::IF_type< > boost::is_same<type1, detail::unspecified>::value, > detail::rightshift_type<A, B>, > plain_return_type_2<bitwise_action<rightshift_action>, plain_A, plain_B> > >::type type; >}; > > > > >template<class A, class B, class Act> >struct plain_return_type_2<logical_action<Act>, A, B> { > typedef bool type; >}; > >template<class A, class B, class Act> >struct return_type_2<logical_action<Act>, A, B> { > > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2<logical_action<Act>, plain_A, plain_B>::type type; > >}; > > > > > >template<class A, class B, class Act> >struct plain_return_type_2<relational_action<Act>, A, B> { > typedef bool type; >}; > >template<class A, class B, class Act> >struct return_type_2<relational_action<Act>, A, B> { > > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2<relational_action<Act>, plain_A, plain_B>::type type; >}; ># 693 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 3 4 >template<class A, class B, class Act> >struct return_type_2<arithmetic_assignment_action<Act>, A, B> { > > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2< > arithmetic_assignment_action<Act>, plain_A, plain_B > >::type type1; > > typedef typename > detail::IF< > boost::is_same<type1, detail::unspecified>::value, > typename boost::add_reference<A>::type, > type1 > >::RET type; >}; > >template<class A, class B, class Act> >struct return_type_2<bitwise_assignment_action<Act>, A, B> { > > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2< > bitwise_assignment_action<Act>, plain_A, plain_B > >::type type1; > > typedef typename > detail::IF< > boost::is_same<type1, detail::unspecified>::value, > typename boost::add_reference<A>::type, > type1 > >::RET type; >}; > >template<class A, class B> >struct return_type_2<other_action<assignment_action>, A, B> { > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2< > other_action<assignment_action>, plain_A, plain_B > >::type type1; > > typedef typename > detail::IF< > boost::is_same<type1, detail::unspecified>::value, > typename boost::add_reference<A>::type, > type1 > >::RET type; >}; ># 759 "/usr/include/boost/lambda/detail/operator_return_type_traits.hpp" 3 4 >template<class A, class B> >struct return_type_2<other_action<comma_action>, A, B> { > > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename > plain_return_type_2< > other_action<comma_action>, plain_A, plain_B > >::type type; > }; > > > > >namespace detail { > >template <class A, class B> struct subscript_type { > typedef detail::unspecified type; >}; > >template <class A, class B> struct subscript_type<A*, B> { > typedef A& type; >}; >template <class A, class B> struct subscript_type<A* const, B> { > typedef A& type; >}; >template <class A, class B> struct subscript_type<A* volatile, B> { > typedef A& type; >}; >template <class A, class B> struct subscript_type<A* const volatile, B> { > typedef A& type; >}; > > >template<class A, class B, int N> struct subscript_type<A[N], B> { > typedef A& type; >}; > > >template<class A, class B, int N> struct subscript_type<const A[N], B> { > typedef const A& type; >}; >template<class A, class B, int N> struct subscript_type<volatile A[N], B> { > typedef volatile A& type; >}; >template<class A, class B, int N> struct subscript_type<const volatile A[N], B> { > typedef const volatile A& type; >}; > >} > >template<class A, class B> >struct return_type_2<other_action<subscript_action>, A, B> { > > typedef typename detail::remove_reference_and_cv<A>::type plain_A; > typedef typename detail::remove_reference_and_cv<B>::type plain_B; > > typedef typename boost::remove_reference<A>::type nonref_A; > typedef typename boost::remove_reference<B>::type nonref_B; > > typedef typename > plain_return_type_2< > other_action<subscript_action>, plain_A, plain_B > >::type type1; > > typedef typename > detail::IF_type< > boost::is_same<type1, detail::unspecified>::value, > detail::subscript_type<nonref_A, nonref_B>, > plain_return_type_2<other_action<subscript_action>, plain_A, plain_B> > >::type type; > >}; > >template<class Key, class T, class Cmp, class Allocator, class B> >struct plain_return_type_2<other_action<subscript_action>, std::map<Key, T, Cmp, Allocator>, B> { > typedef T& type; > >}; > >template<class Key, class T, class Cmp, class Allocator, class B> >struct plain_return_type_2<other_action<subscript_action>, std::multimap<Key, T, Cmp, Allocator>, B> { > typedef T& type; > >}; > > >template<class T, class Allocator, class B> >struct plain_return_type_2<other_action<subscript_action>, std::deque<T, Allocator>, B> { > typedef typename std::deque<T, Allocator>::reference type; >}; >template<class T, class Allocator, class B> >struct plain_return_type_2<other_action<subscript_action>, const std::deque<T, Allocator>, B> { > typedef typename std::deque<T, Allocator>::const_reference type; >}; > > >template<class T, class Allocator, class B> >struct plain_return_type_2<other_action<subscript_action>, std::vector<T, Allocator>, B> { > typedef typename std::vector<T, Allocator>::reference type; >}; >template<class T, class Allocator, class B> >struct plain_return_type_2<other_action<subscript_action>, const std::vector<T, Allocator>, B> { > typedef typename std::vector<T, Allocator>::const_reference type; >}; > > >template<class Char, class Traits, class Allocator, class B> >struct plain_return_type_2<other_action<subscript_action>, std::basic_string<Char, Traits, Allocator>, B> { > typedef typename std::basic_string<Char, Traits, Allocator>::reference type; >}; >template<class Char, class Traits, class Allocator, class B> >struct plain_return_type_2<other_action<subscript_action>, const std::basic_string<Char, Traits, Allocator>, B> { > typedef typename std::basic_string<Char, Traits, Allocator>::const_reference type; >}; > >template<class Char, class Traits, class Allocator> >struct plain_return_type_2<arithmetic_action<plus_action>, > std::basic_string<Char, Traits, Allocator>, > std::basic_string<Char, Traits, Allocator> > { > typedef std::basic_string<Char, Traits, Allocator> type; >}; > >template<class Char, class Traits, class Allocator> >struct plain_return_type_2<arithmetic_action<plus_action>, > const Char*, > std::basic_string<Char, Traits, Allocator> > { > typedef std::basic_string<Char, Traits, Allocator> type; >}; > >template<class Char, class Traits, class Allocator> >struct plain_return_type_2<arithmetic_action<plus_action>, > std::basic_string<Char, Traits, Allocator>, > const Char*> { > typedef std::basic_string<Char, Traits, Allocator> type; >}; > >template<class Char, class Traits, class Allocator, std::size_t N> >struct plain_return_type_2<arithmetic_action<plus_action>, > Char[N], > std::basic_string<Char, Traits, Allocator> > { > typedef std::basic_string<Char, Traits, Allocator> type; >}; > >template<class Char, class Traits, class Allocator, std::size_t N> >struct plain_return_type_2<arithmetic_action<plus_action>, > std::basic_string<Char, Traits, Allocator>, > Char[N]> { > typedef std::basic_string<Char, Traits, Allocator> type; >}; > > >} >} ># 24 "/usr/include/boost/lambda/lambda.hpp" 2 3 4 > > ># 1 "/usr/include/boost/lambda/detail/operators.hpp" 1 3 4 ># 18 "/usr/include/boost/lambda/detail/operators.hpp" 3 4 >namespace boost { >namespace lambda { ># 109 "/usr/include/boost/lambda/detail/operators.hpp" 3 4 >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_action<plus_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator+ (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_action<plus_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_action<plus_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator+ (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_action<plus_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_action<plus_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator+ (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_action<plus_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_action<minus_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator- (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_action<minus_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_action<minus_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator- (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_action<minus_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_action<minus_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator- (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_action<minus_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_action<multiply_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator* (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_action<multiply_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_action<multiply_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator* (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_action<multiply_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_action<multiply_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator* (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_action<multiply_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_action<divide_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator/ (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_action<divide_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_action<divide_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator/ (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_action<divide_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_action<divide_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator/ (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_action<divide_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_action<remainder_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator% (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_action<remainder_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_action<remainder_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator% (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_action<remainder_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_action<remainder_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator% (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_action<remainder_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_action<leftshift_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator<< (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_action<leftshift_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_action<leftshift_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator<< (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_action<leftshift_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_action<leftshift_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator<< (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_action<leftshift_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_action<rightshift_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator>> (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_action<rightshift_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_action<rightshift_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator>> (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_action<rightshift_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_action<rightshift_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator>> (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_action<rightshift_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_action<and_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator& (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_action<and_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_action<and_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator& (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_action<and_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_action<and_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator& (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_action<and_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_action<or_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator| (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_action<or_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_action<or_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator| (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_action<or_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_action<or_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator| (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_action<or_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_action<xor_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator^ (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_action<xor_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_action<xor_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator^ (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_action<xor_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_action<xor_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator^ (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_action<xor_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< logical_action<and_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator&& (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< logical_action<and_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< logical_action<and_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator&& (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< logical_action<and_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< logical_action<and_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator&& (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< logical_action<and_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< logical_action<or_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator|| (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< logical_action<or_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< logical_action<or_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator|| (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< logical_action<or_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< logical_action<or_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator|| (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< logical_action<or_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< relational_action<less_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator< (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< relational_action<less_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< relational_action<less_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator< (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< relational_action<less_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< relational_action<less_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator< (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< relational_action<less_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< relational_action<greater_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator> (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< relational_action<greater_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< relational_action<greater_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator> (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< relational_action<greater_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< relational_action<greater_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator> (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< relational_action<greater_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< relational_action<lessorequal_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator<= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< relational_action<lessorequal_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< relational_action<lessorequal_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator<= (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< relational_action<lessorequal_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< relational_action<lessorequal_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator<= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< relational_action<lessorequal_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< relational_action<greaterorequal_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator>= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< relational_action<greaterorequal_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< relational_action<greaterorequal_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator>= (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< relational_action<greaterorequal_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< relational_action<greaterorequal_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator>= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< relational_action<greaterorequal_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< relational_action<equal_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator== (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< relational_action<equal_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< relational_action<equal_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator== (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< relational_action<equal_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< relational_action<equal_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator== (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< relational_action<equal_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< relational_action<notequal_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator!= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< relational_action<notequal_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< relational_action<notequal_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator!= (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< relational_action<notequal_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< relational_action<notequal_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator!= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< relational_action<notequal_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } > >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<plus_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator+= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_assignment_action<plus_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<plus_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator+= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_assignment_action<plus_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<plus_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator+= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_assignment_action<plus_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<minus_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator-= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_assignment_action<minus_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<minus_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator-= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_assignment_action<minus_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<minus_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator-= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_assignment_action<minus_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<multiply_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator*= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_assignment_action<multiply_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<multiply_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator*= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_assignment_action<multiply_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<multiply_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator*= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_assignment_action<multiply_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<divide_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator/= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_assignment_action<divide_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<divide_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator/= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_assignment_action<divide_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<divide_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator/= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_assignment_action<divide_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<remainder_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator%= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< arithmetic_assignment_action<remainder_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<remainder_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator%= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< arithmetic_assignment_action<remainder_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< arithmetic_assignment_action<remainder_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator%= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< arithmetic_assignment_action<remainder_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<leftshift_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator<<= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_assignment_action<leftshift_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<leftshift_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator<<= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_assignment_action<leftshift_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<leftshift_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator<<= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_assignment_action<leftshift_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<rightshift_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator>>= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_assignment_action<rightshift_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<rightshift_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator>>= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_assignment_action<rightshift_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<rightshift_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator>>= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_assignment_action<rightshift_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<and_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator&= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_assignment_action<and_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<and_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator&= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_assignment_action<and_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<and_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator&= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_assignment_action<and_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<or_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator|= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_assignment_action<or_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<or_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator|= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_assignment_action<or_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<or_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator|= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_assignment_action<or_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<xor_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator^= (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< bitwise_assignment_action<xor_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<xor_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > > operator^= (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_assignment_action<xor_action>, tuple<typename reference_argument <A>::type, lambda_functor<Arg> > > (tuple<typename reference_argument <A>::type, lambda_functor<Arg> >(a, b)); } template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< bitwise_assignment_action<xor_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator^= (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< bitwise_assignment_action<xor_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } ># 147 "/usr/include/boost/lambda/detail/operators.hpp" 3 4 >template<class Arg, class B> inline const lambda_functor< lambda_functor_base< other_action<comma_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > > operator, (const lambda_functor<Arg>& a, const B& b) { return lambda_functor_base< other_action<comma_action>, tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type> > (tuple<lambda_functor<Arg>, typename const_copy_argument <const B>::type>(a, b)); } >template<class A, class Arg> inline const lambda_functor< lambda_functor_base< other_action<comma_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > > operator, (const A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< other_action<comma_action>, tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> > > (tuple<typename const_copy_argument <const A>::type, lambda_functor<Arg> >(a, b)); } >template<class ArgA, class ArgB> inline const lambda_functor< lambda_functor_base< other_action<comma_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > > operator, (const lambda_functor<ArgA>& a, const lambda_functor<ArgB>& b) { return lambda_functor_base< other_action<comma_action>, tuple<lambda_functor<ArgA>, lambda_functor<ArgB> > > (tuple<lambda_functor<ArgA>, lambda_functor<ArgB> >(a, b)); } > > > >namespace detail { ># 182 "/usr/include/boost/lambda/detail/operators.hpp" 3 4 >template<class T> struct convert_ostream_to_ref_others_to_c_plain_by_default { > typedef typename detail::IF< > is_instance_of_2< > T, std::basic_ostream > >::value, > T&, > typename const_copy_argument <T>::type > >::RET type; >}; > >template<class T> struct convert_istream_to_ref_others_to_c_plain_by_default { > typedef typename detail::IF< > is_instance_of_2< > T, std::basic_istream > >::value, > T&, > typename const_copy_argument <T>::type > >::RET type; >}; > > >} > >template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_action< leftshift_action>, tuple<typename detail::convert_ostream_to_ref_others_to_c_plain_by_default <A>::type, lambda_functor<Arg> > > > operator<< (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_action< leftshift_action>, tuple<typename detail::convert_ostream_to_ref_others_to_c_plain_by_default <A>::type, lambda_functor<Arg> > > (tuple<typename detail::convert_ostream_to_ref_others_to_c_plain_by_default <A>::type, lambda_functor<Arg> >(a, b)); } >template<class A, class Arg> inline const lambda_functor< lambda_functor_base< bitwise_action< rightshift_action>, tuple<typename detail::convert_istream_to_ref_others_to_c_plain_by_default <A>::type, lambda_functor<Arg> > > > operator>> (A& a, const lambda_functor<Arg>& b) { return lambda_functor_base< bitwise_action< rightshift_action>, tuple<typename detail::convert_istream_to_ref_others_to_c_plain_by_default <A>::type, lambda_functor<Arg> > > (tuple<typename detail::convert_istream_to_ref_others_to_c_plain_by_default <A>::type, lambda_functor<Arg> >(a, b)); } > > > > > > > >template<class Arg, class Ret, class ManipArg> >inline const >lambda_functor< > lambda_functor_base< > bitwise_action<leftshift_action>, > tuple<lambda_functor<Arg>, Ret(&)(ManipArg)> > > >> >operator<<(const lambda_functor<Arg>& a, Ret(&b)(ManipArg)) >{ > return > lambda_functor_base< > bitwise_action<leftshift_action>, > tuple<lambda_functor<Arg>, Ret(&)(ManipArg)> > > > ( tuple<lambda_functor<Arg>, Ret(&)(ManipArg)>(a, b) ); >} > >template<class Arg, class Ret, class ManipArg> >inline const >lambda_functor< > lambda_functor_base< > bitwise_action<rightshift_action>, > tuple<lambda_functor<Arg>, Ret(&)(ManipArg)> > > >> >operator>>(const lambda_functor<Arg>& a, Ret(&b)(ManipArg)) >{ > return > lambda_functor_base< > bitwise_action<rightshift_action>, > tuple<lambda_functor<Arg>, Ret(&)(ManipArg)> > > > ( tuple<lambda_functor<Arg>, Ret(&)(ManipArg)>(a, b) ); >} ># 293 "/usr/include/boost/lambda/detail/operators.hpp" 3 4 >template<class Arg, int N, class B> inline const lambda_functor< lambda_functor_base<arithmetic_action<plus_action>, tuple<lambda_functor<Arg>, B(&)[N]> > > operator+ (const lambda_functor<Arg>& a, B(&b)[N]) { return lambda_functor_base<arithmetic_action<plus_action>, tuple<lambda_functor<Arg>, B(&)[N]> > (tuple<lambda_functor<Arg>, B(&)[N]>(a, b)); } >template<int N, class A, class Arg> inline const lambda_functor< lambda_functor_base<arithmetic_action<plus_action>, tuple<A(&)[N], lambda_functor<Arg> > > > operator+ (A(&a)[N], const lambda_functor<Arg>& b) { return lambda_functor_base<arithmetic_action<plus_action>, tuple<A(&)[N], lambda_functor<Arg> > > (tuple<A(&)[N], lambda_functor<Arg> >(a, b)); } >template<class Arg, int N, class B> inline const lambda_functor< lambda_functor_base<arithmetic_action<plus_action>, tuple<lambda_functor<Arg>, const B(&)[N]> > > operator+ (const lambda_functor<Arg>& a, const B(&b)[N]) { return lambda_functor_base<arithmetic_action<plus_action>, tuple<lambda_functor<Arg>, const B(&)[N]> > (tuple<lambda_functor<Arg>, const B(&)[N]>(a, b)); } >template<int N, class A, class Arg> inline const lambda_functor< lambda_functor_base<arithmetic_action<plus_action>, tuple<const A(&)[N], lambda_functor<Arg> > > > operator+ (const A(&a)[N], const lambda_functor<Arg>& b) { return lambda_functor_base<arithmetic_action<plus_action>, tuple<const A(&)[N], lambda_functor<Arg> > > (tuple<const A(&)[N], lambda_functor<Arg> >(a, b)); } > > > > > >template<int N, class A, class Arg> inline const lambda_functor< lambda_functor_base<arithmetic_action<minus_action>, tuple<A(&)[N], lambda_functor<Arg> > > > operator- (A(&a)[N], const lambda_functor<Arg>& b) { return lambda_functor_base<arithmetic_action<minus_action>, tuple<A(&)[N], lambda_functor<Arg> > > (tuple<A(&)[N], lambda_functor<Arg> >(a, b)); } >template<int N, class A, class Arg> inline const lambda_functor< lambda_functor_base<arithmetic_action<minus_action>, tuple<const A(&)[N], lambda_functor<Arg> > > > operator- (const A(&a)[N], const lambda_functor<Arg>& b) { return lambda_functor_base<arithmetic_action<minus_action>, tuple<const A(&)[N], lambda_functor<Arg> > > (tuple<const A(&)[N], lambda_functor<Arg> >(a, b)); } ># 336 "/usr/include/boost/lambda/detail/operators.hpp" 3 4 >template<class Arg> inline const lambda_functor<lambda_functor_base<unary_arithmetic_action<plus_action>, tuple<lambda_functor<Arg> > > > operator+ (const lambda_functor<Arg>& a) { return lambda_functor_base<unary_arithmetic_action<plus_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } >template<class Arg> inline const lambda_functor<lambda_functor_base<unary_arithmetic_action<minus_action>, tuple<lambda_functor<Arg> > > > operator- (const lambda_functor<Arg>& a) { return lambda_functor_base<unary_arithmetic_action<minus_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } >template<class Arg> inline const lambda_functor<lambda_functor_base<bitwise_action<not_action>, tuple<lambda_functor<Arg> > > > operator~ (const lambda_functor<Arg>& a) { return lambda_functor_base<bitwise_action<not_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } >template<class Arg> inline const lambda_functor<lambda_functor_base<logical_action<not_action>, tuple<lambda_functor<Arg> > > > operator! (const lambda_functor<Arg>& a) { return lambda_functor_base<logical_action<not_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } >template<class Arg> inline const lambda_functor<lambda_functor_base<pre_increment_decrement_action<increment_action>, tuple<lambda_functor<Arg> > > > operator++ (const lambda_functor<Arg>& a) { return lambda_functor_base<pre_increment_decrement_action<increment_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } >template<class Arg> inline const lambda_functor<lambda_functor_base<pre_increment_decrement_action<decrement_action>, tuple<lambda_functor<Arg> > > > operator-- (const lambda_functor<Arg>& a) { return lambda_functor_base<pre_increment_decrement_action<decrement_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } >template<class Arg> inline const lambda_functor<lambda_functor_base<other_action<contentsof_action>, tuple<lambda_functor<Arg> > > > operator* (const lambda_functor<Arg>& a) { return lambda_functor_base<other_action<contentsof_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } >template<class Arg> inline const lambda_functor<lambda_functor_base<other_action<addressof_action>, tuple<lambda_functor<Arg> > > > operator& (const lambda_functor<Arg>& a) { return lambda_functor_base<other_action<addressof_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } ># 361 "/usr/include/boost/lambda/detail/operators.hpp" 3 4 >template<class Arg> inline const lambda_functor<lambda_functor_base<post_increment_decrement_action<increment_action>, tuple<lambda_functor<Arg> > > > operator++ (const lambda_functor<Arg>& a, int) { return lambda_functor_base<post_increment_decrement_action<increment_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } >template<class Arg> inline const lambda_functor<lambda_functor_base<post_increment_decrement_action<decrement_action>, tuple<lambda_functor<Arg> > > > operator-- (const lambda_functor<Arg>& a, int) { return lambda_functor_base<post_increment_decrement_action<decrement_action>, tuple<lambda_functor<Arg> > > ( tuple<lambda_functor<Arg> >(a) ); } > > > > >} >} ># 27 "/usr/include/boost/lambda/lambda.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/lambda/detail/member_ptr.hpp" 1 3 4 ># 17 "/usr/include/boost/lambda/detail/member_ptr.hpp" 3 4 >namespace boost { >namespace lambda { > > >class member_pointer_action {}; > > >namespace detail { > > > >template<class T> >struct member_pointer { > typedef typename boost::add_reference<T>::type type; > typedef detail::unspecified class_type; > typedef detail::unspecified qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = false; >}; > >template<class T, class U> >struct member_pointer<T U::*> { > typedef typename boost::add_reference<T>::type type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = true; > static const bool is_function_member = false; >}; > >template<class T, class U> >struct member_pointer<const T U::*> { > typedef typename boost::add_reference<const T>::type type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = true; > static const bool is_function_member = false; >}; > >template<class T, class U> >struct member_pointer<volatile T U::*> { > typedef typename boost::add_reference<volatile T>::type type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = true; > static const bool is_function_member = false; >}; > >template<class T, class U> >struct member_pointer<const volatile T U::*> { > typedef typename boost::add_reference<const volatile T>::type type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = true; > static const bool is_function_member = false; >}; > > >template<class T, class U> >struct member_pointer<T (U::*)()> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1> >struct member_pointer<T (U::*)(A1)> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2> >struct member_pointer<T (U::*)(A1, A2)> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3> >struct member_pointer<T (U::*)(A1, A2, A3)> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4> >struct member_pointer<T (U::*)(A1, A2, A3, A4)> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5)> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6)> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7)> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8)> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8, class A9> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8, A9)> { > typedef T type; > typedef U class_type; > typedef U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; > >template<class T, class U> >struct member_pointer<T (U::*)() const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1> >struct member_pointer<T (U::*)(A1) const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2> >struct member_pointer<T (U::*)(A1, A2) const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3> >struct member_pointer<T (U::*)(A1, A2, A3) const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4> >struct member_pointer<T (U::*)(A1, A2, A3, A4) const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5) const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6) const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7) const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8) const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8, class A9> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8, A9) const> { > typedef T type; > typedef U class_type; > typedef const U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; > >template<class T, class U> >struct member_pointer<T (U::*)() volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1> >struct member_pointer<T (U::*)(A1) volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2> >struct member_pointer<T (U::*)(A1, A2) volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3> >struct member_pointer<T (U::*)(A1, A2, A3) volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4> >struct member_pointer<T (U::*)(A1, A2, A3, A4) volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5) volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6) volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7) volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8) volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8, class A9> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8, A9) volatile> { > typedef T type; > typedef U class_type; > typedef volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; > >template<class T, class U> >struct member_pointer<T (U::*)() const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1> >struct member_pointer<T (U::*)(A1) const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2> >struct member_pointer<T (U::*)(A1, A2) const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3> >struct member_pointer<T (U::*)(A1, A2, A3) const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4> >struct member_pointer<T (U::*)(A1, A2, A3, A4) const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5) const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6) const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7) const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8) const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; >template<class T, class U, class A1, class A2, class A3, class A4, class A5, > class A6, class A7, class A8, class A9> >struct member_pointer<T (U::*)(A1, A2, A3, A4, A5, A6, A7, A8, A9) const volatile> { > typedef T type; > typedef U class_type; > typedef const volatile U qualified_class_type; > static const bool is_data_member = false; > static const bool is_function_member = true; >}; > >} > >namespace detail { ># 432 "/usr/include/boost/lambda/detail/member_ptr.hpp" 3 4 >template<class RET, class A, class B> >class member_pointer_caller { > A a; B b; > >public: > member_pointer_caller(const A& aa, const B& bb) : a(aa), b(bb) {} > > RET operator()() const { return (a->*b)(); } > > template<class A1> > RET operator()(const A1& a1) const { return (a->*b)(a1); } > > template<class A1, class A2> > RET operator()(const A1& a1, const A2& a2) const { return (a->*b)(a1, a2); } > > template<class A1, class A2, class A3> > RET operator()(const A1& a1, const A2& a2, const A3& a3) const { > return (a->*b)(a1, a2, a3); > } > > template<class A1, class A2, class A3, class A4> > RET operator()(const A1& a1, const A2& a2, const A3& a3, > const A4& a4) const { > return (a->*b)(a1, a2, a3, a4); > } > > template<class A1, class A2, class A3, class A4, class A5> > RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, > const A5& a5) const { > return (a->*b)(a1, a2, a3, a4, a5); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6> > RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, > const A5& a5, const A6& a6) const { > return (a->*b)(a1, a2, a3, a4, a5, a6); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6, > class A7> > RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, > const A5& a5, const A6& a6, const A7& a7) const { > return (a->*b)(a1, a2, a3, a4, a5, a6, a7); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6, > class A7, class A8> > RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, > const A5& a5, const A6& a6, const A7& a7, > const A8& a8) const { > return (a->*b)(a1, a2, a3, a4, a5, a6, a7, a8); > } > > template<class A1, class A2, class A3, class A4, class A5, class A6, > class A7, class A8, class A9> > RET operator()(const A1& a1, const A2& a2, const A3& a3, const A4& a4, > const A5& a5, const A6& a6, const A7& a7, > const A8& a8, const A9& a9) const { > return (a->*b)(a1, a2, a3, a4, a5, a6, a7, a8, a9); > } > >}; > > > > > >template <bool Is_data_member, bool Is_function_member> >struct member_pointer_action_helper; > > > > > >template <> >struct member_pointer_action_helper<true, false> { >public: > > template<class RET, class A, class B> > static RET apply(A& a, B& b) { > return a->*b; > } > > template<class A, class B> > struct return_type { > private: > typedef typename detail::remove_reference_and_cv<B>::type plainB; > > typedef typename detail::member_pointer<plainB>::type type0; > > typedef typename boost::remove_reference<type0>::type type1; > > > > typedef typename > detail::remove_reference_and_cv<A>::type non_ref_A; > > > typedef typename ::boost::remove_pointer<non_ref_A>::type non_pointer_A; > > public: > > > > > typedef typename detail::IF< > ::boost::is_const<non_pointer_A>::value, > typename ::boost::add_const<type1>::type, > type1 > >::RET type2; > typedef typename detail::IF< > ::boost::is_volatile<non_pointer_A>::value, > typename ::boost::add_volatile<type2>::type, > type2 > >::RET type3; > > typedef typename ::boost::add_reference<type3>::type type; > }; >}; > > >template <> >struct member_pointer_action_helper<false, false> { >public: > template<class RET, class A, class B> > static RET apply(A& a, B& b) { > > return a->*b; > } > > > > > template<class A, class B> > struct return_type { > > typedef typename plain_return_type_2< > other_action<member_pointer_action>, A, B > >::type type; > }; > >}; > > > > > > > >template <> >struct member_pointer_action_helper<false, true> { > public: > > template<class RET, class A, class B> > static RET apply(A& a, B& b) { > typedef typename ::boost::remove_cv<B>::type plainB; > typedef typename detail::member_pointer<plainB>::type ret_t; > typedef typename ::boost::remove_cv<A>::type plainA; > > > > > > return detail::member_pointer_caller<ret_t, plainA, plainB>(a, b); > } > > template<class A, class B> > struct return_type { > typedef typename detail::remove_reference_and_cv<B>::type plainB; > typedef typename detail::member_pointer<plainB>::type ret_t; > typedef typename detail::remove_reference_and_cv<A>::type plainA; > > typedef detail::member_pointer_caller<ret_t, plainA, plainB> type; > }; >}; > >} > >template<> class other_action<member_pointer_action> { >public: > template<class RET, class A, class B> > static RET apply(A& a, B& b) { > typedef typename > ::boost::remove_cv<B>::type plainB; > > return detail::member_pointer_action_helper< > boost::is_pointer<A>::value && > detail::member_pointer<plainB>::is_data_member, > boost::is_pointer<A>::value && > detail::member_pointer<plainB>::is_function_member > >::template apply<RET>(a, b); > } >}; ># 642 "/usr/include/boost/lambda/detail/member_ptr.hpp" 3 4 >template<class A, class B> >struct return_type_2<other_action<member_pointer_action>, A, B> { >private: > typedef typename > detail::remove_reference_and_cv<B>::type plainB; >public: > typedef typename > detail::member_pointer_action_helper< > detail::member_pointer<plainB>::is_data_member, > detail::member_pointer<plainB>::is_function_member > >::template return_type<A, B>::type type; >}; > > > > >template<class Args> >struct return_type_N<other_action<member_pointer_action>, Args> { > typedef typename boost::tuples::element<0, Args>::type A; > typedef typename boost::tuples::element<1, Args>::type B; > typedef typename > return_type_2<other_action<member_pointer_action>, > typename boost::remove_reference<A>::type, > typename boost::remove_reference<B>::type > >::type type; >}; > > >template<class Arg1, class Arg2> >inline const >lambda_functor< > lambda_functor_base< > action<2, other_action<member_pointer_action> >, > tuple<lambda_functor<Arg1>, typename const_copy_argument<Arg2>::type> > > >> >operator->*(const lambda_functor<Arg1>& a1, const Arg2& a2) >{ > return > lambda_functor_base< > action<2, other_action<member_pointer_action> >, > tuple<lambda_functor<Arg1>, typename const_copy_argument<Arg2>::type> > > > (tuple<lambda_functor<Arg1>, > typename const_copy_argument<Arg2>::type>(a1, a2)); >} > >template<class Arg1, class Arg2> >inline const >lambda_functor< > lambda_functor_base< > action<2, other_action<member_pointer_action> >, > tuple<lambda_functor<Arg1>, lambda_functor<Arg2> > > > >> >operator->*(const lambda_functor<Arg1>& a1, const lambda_functor<Arg2>& a2) >{ > return > lambda_functor_base< > action<2, other_action<member_pointer_action> >, > tuple<lambda_functor<Arg1>, lambda_functor<Arg2> > > > > (tuple<lambda_functor<Arg1>, lambda_functor<Arg2> >(a1, a2)); >} > >template<class Arg1, class Arg2> >inline const >lambda_functor< > lambda_functor_base< > action<2, other_action<member_pointer_action> >, > tuple<typename const_copy_argument<Arg1>::type, lambda_functor<Arg2> > > > >> >operator->*(const Arg1& a1, const lambda_functor<Arg2>& a2) >{ > return > lambda_functor_base< > action<2, other_action<member_pointer_action> >, > tuple<typename const_copy_argument<Arg1>::type, lambda_functor<Arg2> > > > > (tuple<typename const_copy_argument<Arg1>::type, > lambda_functor<Arg2> >(a1, a2)); >} > > >} >} ># 31 "/usr/include/boost/lambda/lambda.hpp" 2 3 4 ># 33 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" 2 ># 1 "/usr/include/boost/uuid/random_generator.hpp" 1 3 4 ># 12 "/usr/include/boost/uuid/random_generator.hpp" 3 4 ># 1 "/usr/include/boost/uuid/seed_rng.hpp" 1 3 4 ># 25 "/usr/include/boost/uuid/seed_rng.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 26 "/usr/include/boost/uuid/seed_rng.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/ctime" 1 3 4 ># 39 "/usr/include/c++/4.9.0/ctime" 3 4 ># 40 "/usr/include/c++/4.9.0/ctime" 3 ># 28 "/usr/include/boost/uuid/seed_rng.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 29 "/usr/include/boost/uuid/seed_rng.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cstdio" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdio" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdio" 3 ># 30 "/usr/include/boost/uuid/seed_rng.hpp" 2 3 4 ># 1 "/usr/include/boost/uuid/sha1.hpp" 1 3 4 ># 30 "/usr/include/boost/uuid/sha1.hpp" 3 4 >namespace boost { >namespace uuids { >namespace detail { > >static_assert(sizeof(unsigned char)*8 == 8, "sizeof(unsigned char)*8 == 8"); >static_assert(sizeof(unsigned int)*8 == 32, "sizeof(unsigned int)*8 == 32"); > >inline unsigned int left_rotate(unsigned int x, std::size_t n) >{ > return (x<<n) ^ (x>> (32-n)); >} > >class sha1 >{ >public: > typedef unsigned int(&digest_type)[5]; >public: > sha1(); > > void reset(); > > void process_byte(unsigned char byte); > void process_block(void const* bytes_begin, void const* bytes_end); > void process_bytes(void const* buffer, std::size_t byte_count); > > void get_digest(digest_type digest); > >private: > void process_block(); > void process_byte_impl(unsigned char byte); > >private: > unsigned int h_[5]; > > unsigned char block_[64]; > > std::size_t block_byte_index_; > std::size_t bit_count_low; > std::size_t bit_count_high; >}; > >inline sha1::sha1() >{ > reset(); >} > >inline void sha1::reset() >{ > h_[0] = 0x67452301; > h_[1] = 0xEFCDAB89; > h_[2] = 0x98BADCFE; > h_[3] = 0x10325476; > h_[4] = 0xC3D2E1F0; > > block_byte_index_ = 0; > bit_count_low = 0; > bit_count_high = 0; >} > >inline void sha1::process_byte(unsigned char byte) >{ > process_byte_impl(byte); > > > > > if (bit_count_low < 0xFFFFFFF8) { > bit_count_low += 8; > } else { > bit_count_low = 0; > > if (bit_count_high <= 0xFFFFFFFE) { > ++bit_count_high; > } else { > ::boost::exception_detail::throw_exception_(std::runtime_error("sha1 too many bytes"),__PRETTY_FUNCTION__,"/usr/include/boost/uuid/sha1.hpp",104); > } > } >} > >inline void sha1::process_byte_impl(unsigned char byte) >{ > block_[block_byte_index_++] = byte; > > if (block_byte_index_ == 64) { > block_byte_index_ = 0; > process_block(); > } >} > >inline void sha1::process_block(void const* bytes_begin, void const* bytes_end) >{ > unsigned char const* begin = static_cast<unsigned char const*>(bytes_begin); > unsigned char const* end = static_cast<unsigned char const*>(bytes_end); > for(; begin != end; ++begin) { > process_byte(*begin); > } >} > >inline void sha1::process_bytes(void const* buffer, std::size_t byte_count) >{ > unsigned char const* b = static_cast<unsigned char const*>(buffer); > process_block(b, b+byte_count); >} > >inline void sha1::process_block() >{ > unsigned int w[80]; > for (std::size_t i=0; i<16; ++i) { > w[i] = (block_[i*4 + 0] << 24); > w[i] |= (block_[i*4 + 1] << 16); > w[i] |= (block_[i*4 + 2] << 8); > w[i] |= (block_[i*4 + 3]); > } > for (std::size_t i=16; i<80; ++i) { > w[i] = left_rotate((w[i-3] ^ w[i-8] ^ w[i-14] ^ w[i-16]), 1); > } > > unsigned int a = h_[0]; > unsigned int b = h_[1]; > unsigned int c = h_[2]; > unsigned int d = h_[3]; > unsigned int e = h_[4]; > > for (std::size_t i=0; i<80; ++i) { > unsigned int f; > unsigned int k; > > if (i<20) { > f = (b & c) | (~b & d); > k = 0x5A827999; > } else if (i<40) { > f = b ^ c ^ d; > k = 0x6ED9EBA1; > } else if (i<60) { > f = (b & c) | (b & d) | (c & d); > k = 0x8F1BBCDC; > } else { > f = b ^ c ^ d; > k = 0xCA62C1D6; > } > > unsigned temp = left_rotate(a, 5) + f + e + k + w[i]; > e = d; > d = c; > c = left_rotate(b, 30); > b = a; > a = temp; > } > > h_[0] += a; > h_[1] += b; > h_[2] += c; > h_[3] += d; > h_[4] += e; >} > >inline void sha1::get_digest(digest_type digest) >{ > > process_byte_impl(0x80); > > > > > if (block_byte_index_ > 56) { > > while (block_byte_index_ != 0) { > process_byte_impl(0); > } > > > while (block_byte_index_ < 56) { > process_byte_impl(0); > } > } else { > while (block_byte_index_ < 56) { > process_byte_impl(0); > } > } > > > > process_byte_impl( static_cast<unsigned char>((bit_count_high>>24) & 0xFF) ); > process_byte_impl( static_cast<unsigned char>((bit_count_high>>16) & 0xFF) ); > process_byte_impl( static_cast<unsigned char>((bit_count_high>>8 ) & 0xFF) ); > process_byte_impl( static_cast<unsigned char>((bit_count_high) & 0xFF) ); > process_byte_impl( static_cast<unsigned char>((bit_count_low>>24) & 0xFF) ); > process_byte_impl( static_cast<unsigned char>((bit_count_low>>16) & 0xFF) ); > process_byte_impl( static_cast<unsigned char>((bit_count_low>>8 ) & 0xFF) ); > process_byte_impl( static_cast<unsigned char>((bit_count_low) & 0xFF) ); > > > digest[0] = h_[0]; > digest[1] = h_[1]; > digest[2] = h_[2]; > digest[3] = h_[3]; > digest[4] = h_[4]; >} > >}}} ># 31 "/usr/include/boost/uuid/seed_rng.hpp" 2 3 4 ># 59 "/usr/include/boost/uuid/seed_rng.hpp" 3 4 >namespace boost { namespace random { >class random_device; >}} > >namespace boost { >namespace uuids { >namespace detail { > > >class seed_rng >{ >public: > typedef unsigned int result_type; > static const bool has_fixed_range = false; > > > >public: > > seed_rng() > : rd_index_(5) > , random_(std::fopen( "/dev/urandom", "rb" )) > {} > > ~seed_rng() > { > if (random_) { > std::fclose(random_); > } > } > > result_type min () const > { > return (std::numeric_limits<result_type>::min)(); > } > result_type max () const > { > return (std::numeric_limits<result_type>::max)(); > } > > result_type operator()() > { > if (rd_index_ >= 5) { > > sha1_random_digest_(); > > rd_index_ = 0; > } > > return rd_[rd_index_++]; > } > >private: > inline void ignore_size(size_t) {} > > static unsigned int * sha1_random_digest_state_() > { > static unsigned int state[ 5 ]; > return state; > } > > void sha1_random_digest_() > { > boost::uuids::detail::sha1 sha; > > unsigned int * ps = sha1_random_digest_state_(); > > unsigned int state[ 5 ]; > std::memcpy( state, ps, sizeof( state ) ); > > sha.process_bytes( (unsigned char const*)state, sizeof( state ) ); > sha.process_bytes( (unsigned char const*)&ps, sizeof( ps ) ); > > { > std::time_t tm = std::time( 0 ); > sha.process_bytes( (unsigned char const*)&tm, sizeof( tm ) ); > } > > { > std::clock_t ck = std::clock(); > sha.process_bytes( (unsigned char const*)&ck, sizeof( ck ) ); > } > > { > unsigned int rn[] = > { static_cast<unsigned int>(std::rand()) > , static_cast<unsigned int>(std::rand()) > , static_cast<unsigned int>(std::rand()) > }; > sha.process_bytes( (unsigned char const*)rn, sizeof( rn ) ); > } > > { > > unsigned char buffer[ 20 ]; > > if(random_) > { > ignore_size(std::fread( buffer, 1, 20, random_ )); > } > > > > sha.process_bytes( buffer, sizeof( buffer ) ); > } > > { > > unsigned int * p = new unsigned int; > > sha.process_bytes( (unsigned char const*)p, sizeof( *p ) ); > sha.process_bytes( (unsigned char const*)&p, sizeof( p ) ); > > delete p; > } > > sha.process_bytes( (unsigned char const*)rd_, sizeof( rd_ ) ); > > unsigned int digest[ 5 ]; > sha.get_digest( digest ); > > for( int i = 0; i < 5; ++i ) > { > > ps[ i ] ^= digest[ i ]; > rd_[ i ] ^= digest[ i ]; > } > } > >private: > unsigned int rd_[5]; > int rd_index_; > std::FILE * random_; > >private: > seed_rng(seed_rng const&); > seed_rng& operator=(seed_rng const&); >}; > > > >template <class Generator> >class generator_iterator > : public iterator_facade< > generator_iterator<Generator> > , typename Generator::result_type > , single_pass_traversal_tag > , typename Generator::result_type const& > > >{ > typedef iterator_facade< > generator_iterator<Generator> > , typename Generator::result_type > , single_pass_traversal_tag > , typename Generator::result_type const& > > super_t; > > public: > generator_iterator() : m_g(__null), m_value(0) {} > generator_iterator(Generator* g) : m_g(g), m_value((*m_g)()) {} > > void increment() > { > m_value = (*m_g)(); > } > > const typename Generator::result_type& > dereference() const > { > return m_value; > } > > bool equal(generator_iterator const& y) const > { > return this->m_g == y.m_g && this->m_value == y.m_value; > } > > private: > Generator* m_g; > typename Generator::result_type m_value; >}; > > > >template <typename UniformRandomNumberGenerator> >inline void seed(UniformRandomNumberGenerator& rng) >{ > seed_rng seed_gen; > generator_iterator<seed_rng> begin(&seed_gen); > generator_iterator<seed_rng> end; > rng.seed(begin, end); >} > > >template <> >inline void seed<boost::random::random_device>(boost::random::random_device&) {} > > >template <> >inline void seed<seed_rng>(seed_rng&) {} > >}}} ># 13 "/usr/include/boost/uuid/random_generator.hpp" 2 3 4 ># 1 "/usr/include/boost/random/uniform_int.hpp" 1 3 4 ># 20 "/usr/include/boost/random/uniform_int.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 21 "/usr/include/boost/random/uniform_int.hpp" 2 3 4 ># 1 "/usr/include/boost/random/uniform_int_distribution.hpp" 1 3 4 ># 26 "/usr/include/boost/random/uniform_int_distribution.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 27 "/usr/include/boost/random/uniform_int_distribution.hpp" 2 3 4 ># 1 "/usr/include/boost/random/detail/config.hpp" 1 3 4 ># 28 "/usr/include/boost/random/uniform_int_distribution.hpp" 2 3 4 ># 1 "/usr/include/boost/random/detail/operators.hpp" 1 3 4 ># 16 "/usr/include/boost/random/detail/operators.hpp" 3 4 ># 1 "/usr/include/boost/random/detail/config.hpp" 1 3 4 ># 17 "/usr/include/boost/random/detail/operators.hpp" 2 3 4 ># 29 "/usr/include/boost/random/uniform_int_distribution.hpp" 2 3 4 ># 1 "/usr/include/boost/random/detail/uniform_int_float.hpp" 1 3 4 ># 21 "/usr/include/boost/random/detail/uniform_int_float.hpp" 3 4 ># 1 "/usr/include/boost/random/detail/config.hpp" 1 3 4 ># 22 "/usr/include/boost/random/detail/uniform_int_float.hpp" 2 3 4 ># 1 "/usr/include/boost/random/detail/generator_bits.hpp" 1 3 4 ># 19 "/usr/include/boost/random/detail/generator_bits.hpp" 3 4 >namespace boost { >namespace random { >namespace detail { > > > >template<class URNG> >struct generator_bits { > static std::size_t value() { > return std::numeric_limits<typename URNG::result_type>::digits; > } >}; > >} >} >} ># 23 "/usr/include/boost/random/detail/uniform_int_float.hpp" 2 3 4 > ># 1 "/usr/include/boost/random/detail/disable_warnings.hpp" 1 3 4 ># 25 "/usr/include/boost/random/detail/uniform_int_float.hpp" 2 3 4 > >namespace boost { >namespace random { >namespace detail { > >template<class URNG> >class uniform_int_float >{ >public: > typedef URNG base_type; > typedef typename base_type::result_type base_result; > > typedef typename boost::uint_t< > (std::numeric_limits<boost::uintmax_t>::digits < > std::numeric_limits<base_result>::digits)? > std::numeric_limits<boost::uintmax_t>::digits : > std::numeric_limits<base_result>::digits > >::fast result_type; > > uniform_int_float(base_type& rng) > : _rng(rng) {} > > static result_type min () > { return 0; } > static result_type max () > { > std::size_t digits = std::numeric_limits<result_type>::digits; > if(detail::generator_bits<URNG>::value() < digits) { > digits = detail::generator_bits<URNG>::value(); > } > return (result_type(2) << (digits - 1)) - 1; > } > base_type& base() { return _rng; } > const base_type& base() const { return _rng; } > > result_type operator()() > { > base_result range = static_cast<base_result>((max)())+1; > return static_cast<result_type>(_rng() * range); > } > >private: > base_type& _rng; >}; > >} >} >} > ># 1 "/usr/include/boost/random/detail/enable_warnings.hpp" 1 3 4 ># 75 "/usr/include/boost/random/detail/uniform_int_float.hpp" 2 3 4 ># 30 "/usr/include/boost/random/uniform_int_distribution.hpp" 2 3 4 ># 1 "/usr/include/boost/random/detail/signed_unsigned_tools.hpp" 1 3 4 ># 18 "/usr/include/boost/random/detail/signed_unsigned_tools.hpp" 3 4 >namespace boost { >namespace random { >namespace detail { > > > > > > >template<class T, bool sgn = std::numeric_limits<T>::is_signed> >struct subtract { }; > >template<class T> >struct subtract<T, false> >{ > typedef T result_type; > result_type operator()(T x, T y) { return x - y; } >}; > >template<class T> >struct subtract<T, true> >{ > typedef typename make_unsigned<T>::type result_type; > result_type operator()(T x, T y) > { > if (y >= 0) > return result_type(x) - result_type(y); > if (x >= 0) > > return result_type(x) + result_type(-(y+1)) + 1; > > return result_type(x - y); > } >}; > > > > > >template<class T1, class T2, bool sgn = std::numeric_limits<T2>::is_signed> >struct add { }; > >template<class T1, class T2> >struct add<T1, T2, false> >{ > typedef T2 result_type; > result_type operator()(T1 x, T2 y) { return T2(x) + y; } >}; > >template<class T1, class T2> >struct add<T1, T2, true> >{ > typedef T2 result_type; > result_type operator()(T1 x, T2 y) > { > if (y >= 0) > return T2(x) + y; > > if (x > T1(-(y+1))) > > return T2(x - T1(-(y+1)) - 1); > > return T2(x) + y; > } >}; > >} >} >} ># 31 "/usr/include/boost/random/uniform_int_distribution.hpp" 2 3 4 > > > >namespace boost { >namespace random { >namespace detail { ># 46 "/usr/include/boost/random/uniform_int_distribution.hpp" 3 4 >template<class Engine, class T> >T generate_uniform_int( > Engine& eng, T min_value, T max_value, > boost::mpl::true_ ) >{ > typedef T result_type; > typedef typename make_unsigned<T>::type range_type; > typedef typename Engine::result_type base_result; > > typedef typename make_unsigned<base_result>::type base_unsigned; > const range_type range = random::detail::subtract<result_type>()(max_value, min_value); > const base_result bmin = (eng.min)(); > const base_unsigned brange = > random::detail::subtract<base_result>()((eng.max)(), (eng.min)()); > > if(range == 0) { > return min_value; > } else if(brange == range) { > > > base_unsigned v = random::detail::subtract<base_result>()(eng(), bmin); > return random::detail::add<base_unsigned, result_type>()(v, min_value); > } else if(brange < range) { > > for(;;) { > > > > > > range_type limit; > if(range == (std::numeric_limits<range_type>::max)()) { > limit = range/(range_type(brange)+1); > if(range % (range_type(brange)+1) == range_type(brange)) > ++limit; > } else { > limit = (range+1)/(range_type(brange)+1); > } > > > > range_type result = range_type(0); > range_type mult = range_type(1); > > > > > while(mult <= limit) { ># 114 "/usr/include/boost/random/uniform_int_distribution.hpp" 3 4 > result += static_cast<range_type>(random::detail::subtract<base_result>()(eng(), bmin) * mult); > > > if(mult * range_type(brange) == range - mult + 1) { > > > return(result); > } ># 134 "/usr/include/boost/random/uniform_int_distribution.hpp" 3 4 > mult *= range_type(brange)+range_type(1); > } ># 162 "/usr/include/boost/random/uniform_int_distribution.hpp" 3 4 > range_type result_increment = > generate_uniform_int( > eng, > static_cast<range_type>(0), > static_cast<range_type>(range/mult), > boost::mpl::true_()); > if((std::numeric_limits<range_type>::max)() / mult < result_increment) { > > continue; > } > result_increment *= mult; > > result += result_increment; > if(result < result_increment) { > > continue; > } > if(result > range) { > > continue; > } > return random::detail::add<range_type, result_type>()(result, min_value); > } > } else { > base_unsigned bucket_size; > > > > > if(brange == (std::numeric_limits<base_unsigned>::max)()) { > bucket_size = brange / (static_cast<base_unsigned>(range)+1); > if(brange % (static_cast<base_unsigned>(range)+1) == static_cast<base_unsigned>(range)) { > ++bucket_size; > } > } else { > bucket_size = (brange+1) / (static_cast<base_unsigned>(range)+1); > } > for(;;) { > base_unsigned result = > random::detail::subtract<base_result>()(eng(), bmin); > result /= bucket_size; > > > if(result <= static_cast<base_unsigned>(range)) > return random::detail::add<base_unsigned, result_type>()(result, min_value); > } > } >} > > > > > >template<class Engine, class T> >inline T generate_uniform_int( > Engine& eng, T min_value, T max_value, > boost::mpl::false_ ) >{ > uniform_int_float<Engine> wrapper(eng); > return generate_uniform_int(wrapper, min_value, max_value, boost::mpl::true_()); >} > >template<class Engine, class T> >inline T generate_uniform_int(Engine& eng, T min_value, T max_value) >{ > typedef typename Engine::result_type base_result; > return generate_uniform_int(eng, min_value, max_value, > boost::is_integral<base_result>()); >} > >} ># 241 "/usr/include/boost/random/uniform_int_distribution.hpp" 3 4 >template<class IntType = int> >class uniform_int_distribution >{ >public: > typedef IntType input_type; > typedef IntType result_type; > > class param_type > { > public: > > typedef uniform_int_distribution distribution_type; > > > > > > > explicit param_type( > IntType min_arg = 0, > IntType max_arg = (std::numeric_limits<IntType>::max)()) > : _min(min_arg), _max(max_arg) > { > (static_cast<void> (0)); > } > > > IntType a() const { return _min; } > > IntType b() const { return _max; } > > > template<class CharT, class Traits> friend std::basic_ostream<CharT,Traits>& operator<<(std::basic_ostream<CharT,Traits>& os, const param_type& parm) > { > os << parm._min << " " << parm._max; > return os; > } > > > template<class CharT, class Traits> friend std::basic_istream<CharT,Traits>& operator>>(std::basic_istream<CharT,Traits>& is, param_type& parm) > { > IntType min_in, max_in; > if(is >> min_in >> std::ws >> max_in) { > if(min_in <= max_in) { > parm._min = min_in; > parm._max = max_in; > } else { > is.setstate(std::ios_base::failbit); > } > } > return is; > } > > > friend bool operator==(const param_type& lhs, const param_type& rhs) > { return lhs._min == rhs._min && lhs._max == rhs._max; } > > > friend bool operator!=(const param_type& lhs, const param_type& rhs) { return !(lhs == rhs); } > > private: > > IntType _min; > IntType _max; > }; > > > > > > > > explicit uniform_int_distribution( > IntType min_arg = 0, > IntType max_arg = (std::numeric_limits<IntType>::max)()) > : _min(min_arg), _max(max_arg) > { > (static_cast<void> (0)); > } > > explicit uniform_int_distribution(const param_type& parm) > : _min(parm.a()), _max(parm.b()) {} > > > IntType min () const { return _min; } > > IntType max () const { return _max; } > > > IntType a() const { return _min; } > > IntType b() const { return _max; } > > > param_type param() const { return param_type(_min, _max); } > > void param(const param_type& parm) > { > _min = parm.a(); > _max = parm.b(); > } > > > > > > void reset() { } > > > template<class Engine> > result_type operator()(Engine& eng) const > { return detail::generate_uniform_int(eng, _min, _max); } > > > > > > template<class Engine> > result_type operator()(Engine& eng, const param_type& parm) const > { return detail::generate_uniform_int(eng, parm.a(), parm.b()); } > > > template<class CharT, class Traits> friend std::basic_ostream<CharT,Traits>& operator<<(std::basic_ostream<CharT,Traits>& os, const uniform_int_distribution& ud) > { > os << ud.param(); > return os; > } > > > template<class CharT, class Traits> friend std::basic_istream<CharT,Traits>& operator>>(std::basic_istream<CharT,Traits>& is, uniform_int_distribution& ud) > { > param_type parm; > if(is >> parm) { > ud.param(parm); > } > return is; > } > > > > > > friend bool operator==(const uniform_int_distribution& lhs, const uniform_int_distribution& rhs) > { return lhs._min == rhs._min && lhs._max == rhs._max; } > > > > > > friend bool operator!=(const uniform_int_distribution& lhs, const uniform_int_distribution& rhs) { return !(lhs == rhs); } > >private: > IntType _min; > IntType _max; >}; > >} >} ># 22 "/usr/include/boost/random/uniform_int.hpp" 2 3 4 > >namespace boost { ># 35 "/usr/include/boost/random/uniform_int.hpp" 3 4 >template<class IntType = int> >class uniform_int : public random::uniform_int_distribution<IntType> >{ > typedef random::uniform_int_distribution<IntType> base_type; >public: > > class param_type : public base_type::param_type > { > public: > typedef uniform_int distribution_type; > > > > > > explicit param_type(IntType min_arg = 0, IntType max_arg = 9) > : base_type::param_type(min_arg, max_arg) > {} > }; > > > > > > > > explicit uniform_int(IntType min_arg = 0, IntType max_arg = 9) > : base_type(min_arg, max_arg) > {} > > > explicit uniform_int(const param_type& parm) > : base_type(parm) > {} > > > param_type param() const { return param_type(this->a(), this->b()); } > > void param(const param_type& parm) { this->base_type::param(parm); } > > > > template<class Engine> > IntType operator()(Engine& eng) const > { > return static_cast<const base_type&>(*this)(eng); > } > > template<class Engine> > IntType operator()(Engine& eng, const param_type& parm) const > { > return static_cast<const base_type&>(*this)(eng, parm); > } > > template<class Engine> > IntType operator()(Engine& eng, IntType n) const > { > (static_cast<void> (0)); > return static_cast<const base_type&>(*this)(eng, param_type(0, n - 1)); > } >}; > >} ># 14 "/usr/include/boost/uuid/random_generator.hpp" 2 3 4 ># 1 "/usr/include/boost/random/variate_generator.hpp" 1 3 4 ># 18 "/usr/include/boost/random/variate_generator.hpp" 3 4 ># 1 "/usr/include/boost/random/detail/ptr_helper.hpp" 1 3 4 ># 20 "/usr/include/boost/random/detail/ptr_helper.hpp" 3 4 >namespace boost { >namespace random { >namespace detail { > > >template<class T> >struct ptr_helper >{ > typedef T value_type; > typedef T& reference_type; > typedef const T& rvalue_type; > static reference_type ref(T& r) { return r; } > static const T& ref(const T& r) { return r; } >}; > > >template<class T> >struct ptr_helper<T&> >{ > typedef T value_type; > typedef T& reference_type; > typedef T& rvalue_type; > static reference_type ref(T& r) { return r; } > static const T& ref(const T& r) { return r; } >}; > >template<class T> >struct ptr_helper<T*> >{ > typedef T value_type; > typedef T& reference_type; > typedef T* rvalue_type; > static reference_type ref(T * p) { return *p; } > static const T& ref(const T * p) { return *p; } >}; > > >} >} >} ># 19 "/usr/include/boost/random/variate_generator.hpp" 2 3 4 > ># 1 "/usr/include/boost/random/detail/disable_warnings.hpp" 1 3 4 ># 21 "/usr/include/boost/random/variate_generator.hpp" 2 3 4 > >namespace boost { > > > >namespace random { ># 50 "/usr/include/boost/random/variate_generator.hpp" 3 4 >template<class Engine, class Distribution> >class variate_generator >{ >private: > typedef boost::random::detail::ptr_helper<Engine> helper_type; >public: > typedef typename helper_type::value_type engine_value_type; > typedef Engine engine_type; > typedef Distribution distribution_type; > typedef typename Distribution::result_type result_type; ># 69 "/usr/include/boost/random/variate_generator.hpp" 3 4 > variate_generator(Engine e, Distribution d) > : _eng(e), _dist(d) { } > > > result_type operator()() { return _dist(engine()); } > > > > template<class T> > result_type operator()(const T& value) { return _dist(engine(), value); } > > > > > engine_value_type& engine() { return helper_type::ref(_eng); } > > > > const engine_value_type& engine() const { return helper_type::ref(_eng); } > > > distribution_type& distribution() { return _dist; } > > > > const distribution_type& distribution() const { return _dist; } > > > > > > > result_type min () const { return (distribution().min)(); } > > > > > > result_type max () const { return (distribution().max)(); } > >private: > Engine _eng; > distribution_type _dist; >}; > >} > >using random::variate_generator; > >} > ># 1 "/usr/include/boost/random/detail/enable_warnings.hpp" 1 3 4 ># 121 "/usr/include/boost/random/variate_generator.hpp" 2 3 4 ># 15 "/usr/include/boost/uuid/random_generator.hpp" 2 3 4 ># 1 "/usr/include/boost/random/mersenne_twister.hpp" 1 3 4 ># 24 "/usr/include/boost/random/mersenne_twister.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 25 "/usr/include/boost/random/mersenne_twister.hpp" 2 3 4 ># 1 "/usr/include/boost/integer/integer_mask.hpp" 1 3 4 ># 18 "/usr/include/boost/integer/integer_mask.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 19 "/usr/include/boost/integer/integer_mask.hpp" 2 3 4 ># 32 "/usr/include/boost/integer/integer_mask.hpp" 3 4 ># 33 "/usr/include/boost/integer/integer_mask.hpp" 3 > > >namespace boost >{ > > > > > >template < std::size_t Bit > >struct high_bit_mask_t >{ > typedef typename uint_t<(Bit + 1)>::least least; > typedef typename uint_t<(Bit + 1)>::fast fast; > > static const least high_bit = (least( 1u ) << Bit); > static const fast high_bit_fast = (fast( 1u ) << Bit); > > static const std::size_t bit_position = Bit; > >}; > > > > > > >template < std::size_t Bits > >struct low_bits_mask_t >{ > typedef typename uint_t<Bits>::least least; > typedef typename uint_t<Bits>::fast fast; > > static const least sig_bits = (~( ~(least( 0u )) << Bits )); > static const fast sig_bits_fast = fast(sig_bits); > > static const std::size_t bit_count = Bits; > >}; ># 89 "/usr/include/boost/integer/integer_mask.hpp" 3 >template < > struct low_bits_mask_t< std::numeric_limits<unsigned char>::digits > { typedef std::numeric_limits<unsigned char> limits_type; typedef uint_t<limits_type::digits>::least least; typedef uint_t<limits_type::digits>::fast fast; static const least sig_bits = (~( least(0u) )); static const fast sig_bits_fast = fast(sig_bits); static const std::size_t bit_count = limits_type::digits; }; > > >template < > struct low_bits_mask_t< std::numeric_limits<unsigned short>::digits > { typedef std::numeric_limits<unsigned short> limits_type; typedef uint_t<limits_type::digits>::least least; typedef uint_t<limits_type::digits>::fast fast; static const least sig_bits = (~( least(0u) )); static const fast sig_bits_fast = fast(sig_bits); static const std::size_t bit_count = limits_type::digits; }; > > > >template < > struct low_bits_mask_t< std::numeric_limits<unsigned int>::digits > { typedef std::numeric_limits<unsigned int> limits_type; typedef uint_t<limits_type::digits>::least least; typedef uint_t<limits_type::digits>::fast fast; static const least sig_bits = (~( least(0u) )); static const fast sig_bits_fast = fast(sig_bits); static const std::size_t bit_count = limits_type::digits; }; > > > >template < > struct low_bits_mask_t< std::numeric_limits<unsigned long>::digits > { typedef std::numeric_limits<unsigned long> limits_type; typedef uint_t<limits_type::digits>::least least; typedef uint_t<limits_type::digits>::fast fast; static const least sig_bits = (~( least(0u) )); static const fast sig_bits_fast = fast(sig_bits); static const std::size_t bit_count = limits_type::digits; }; ># 123 "/usr/include/boost/integer/integer_mask.hpp" 3 >} ># 26 "/usr/include/boost/random/mersenne_twister.hpp" 2 3 4 ># 1 "/usr/include/boost/random/detail/config.hpp" 1 3 4 ># 27 "/usr/include/boost/random/mersenne_twister.hpp" 2 3 4 > ># 1 "/usr/include/boost/random/detail/seed.hpp" 1 3 4 ># 25 "/usr/include/boost/random/detail/seed.hpp" 3 4 >namespace boost { >namespace random { >namespace detail { > >template<class T> >struct disable_seed : boost::disable_if<boost::is_arithmetic<T> > {}; > >template<class Engine, class T> >struct disable_constructor : disable_seed<T> {}; > >template<class Engine> >struct disable_constructor<Engine, Engine> {}; ># 59 "/usr/include/boost/random/detail/seed.hpp" 3 4 >} >} >} ># 29 "/usr/include/boost/random/mersenne_twister.hpp" 2 3 4 ># 1 "/usr/include/boost/random/detail/seed_impl.hpp" 1 3 4 ># 17 "/usr/include/boost/random/detail/seed_impl.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 18 "/usr/include/boost/random/detail/seed_impl.hpp" 2 3 4 ># 27 "/usr/include/boost/random/detail/seed_impl.hpp" 3 4 ># 1 "/usr/include/boost/random/detail/const_mod.hpp" 1 3 4 ># 19 "/usr/include/boost/random/detail/const_mod.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 20 "/usr/include/boost/random/detail/const_mod.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/random/detail/large_arithmetic.hpp" 1 3 4 ># 16 "/usr/include/boost/random/detail/large_arithmetic.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 17 "/usr/include/boost/random/detail/large_arithmetic.hpp" 2 3 4 > > ># 1 "/usr/include/boost/random/detail/integer_log2.hpp" 1 3 4 ># 19 "/usr/include/boost/random/detail/integer_log2.hpp" 3 4 ># 1 "/usr/include/boost/pending/integer_log2.hpp" 1 3 4 ># 18 "/usr/include/boost/pending/integer_log2.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 19 "/usr/include/boost/pending/integer_log2.hpp" 2 3 4 > > > > > > > >namespace boost { > namespace detail { > > template <typename T> > int integer_log2_impl(T x, int n) { > > int result = 0; > > while (x != 1) { > > const T t = static_cast<T>(x >> n); > if (t) { > result += n; > x = t; > } > n /= 2; > > } > > return result; > } > > > > > > > > template <int p, int n> > struct max_pow2_less { > > enum { c = 2*n < p }; > > static const int value = c ? (max_pow2_less< c*p, 2*c*n>::value) : n > ; > > }; > > template <> > struct max_pow2_less<0, 0> { > > static const int value = 0; > }; > > > > > > > template <typename T> > struct width { > > > > > static const int value = (std::numeric_limits<T>::digits); > > > }; > > } > > > > > > > template <typename T> > int integer_log2(T x) { > > (static_cast<void> (0)); > > const int n = detail::max_pow2_less< > detail::width<T> :: value, 4 > > :: value; > > return detail::integer_log2_impl(x, n); > > } > > > >} ># 20 "/usr/include/boost/random/detail/integer_log2.hpp" 2 3 4 > >namespace boost { >namespace random { >namespace detail { ># 35 "/usr/include/boost/random/detail/integer_log2.hpp" 3 4 >template<int Shift> >struct integer_log2_impl >{ ># 46 "/usr/include/boost/random/detail/integer_log2.hpp" 3 4 > template<class T> > constexpr static int apply2(T t, int accum, int update) > { > return integer_log2_impl<Shift / 2>::apply(t >> update, accum + update); > } > > template<class T> > constexpr static int apply(T t, int accum) > { > return apply2(t, accum, ((t >> Shift) != 0) * Shift); > } > >}; > >template<> >struct integer_log2_impl<1> >{ > template<class T> > constexpr static int apply(T t, int accum) > { > return int(t >> 1) + accum; > } >}; > >template<class T> >constexpr int integer_log2(T t) >{ > return integer_log2_impl< > ::boost::detail::max_pow2_less< > ::std::numeric_limits<T>::digits, 4 > >::value > >::apply(t, 0); >} > >} >} >} ># 20 "/usr/include/boost/random/detail/large_arithmetic.hpp" 2 3 4 > ># 1 "/usr/include/boost/random/detail/disable_warnings.hpp" 1 3 4 ># 22 "/usr/include/boost/random/detail/large_arithmetic.hpp" 2 3 4 > >namespace boost { >namespace random { >namespace detail { > >struct div_t { > boost::uintmax_t quotient; > boost::uintmax_t remainder; >}; > >inline div_t muldivmod(boost::uintmax_t a, boost::uintmax_t b, boost::uintmax_t m) >{ > static const int bits = > ::std::numeric_limits< ::boost::uintmax_t>::digits / 2; > static const ::boost::uintmax_t mask = (::boost::uintmax_t(1) << bits) - 1; > typedef ::boost::uint_t<bits>::fast digit_t; > > int shift = std::numeric_limits< ::boost::uintmax_t>::digits - 1 > - detail::integer_log2(m); > > a <<= shift; > m <<= shift; > > digit_t product[4] = { 0, 0, 0, 0 }; > digit_t a_[2] = { digit_t(a & mask), digit_t((a >> bits) & mask) }; > digit_t b_[2] = { digit_t(b & mask), digit_t((b >> bits) & mask) }; > digit_t m_[2] = { digit_t(m & mask), digit_t((m >> bits) & mask) }; > > > for(int i = 0; i < 2; ++i) { > digit_t carry = 0; > for(int j = 0; j < 2; ++j) { > ::boost::uint64_t temp = ::boost::uintmax_t(a_[i]) * b_[j] + > carry + product[i + j]; > product[i + j] = digit_t(temp & mask); > carry = digit_t(temp >> bits); > } > if(carry != 0) { > product[i + 2] += carry; > } > } > > digit_t quotient[2]; > > if(m == 0) { > div_t result = { > ((::boost::uintmax_t(product[3]) << bits) | product[2]), > ((::boost::uintmax_t(product[1]) << bits) | product[0]) >> shift, > }; > return result; > } > > > for(int i = 3; i >= 2; --i) { > ::boost::uintmax_t temp = > ::boost::uintmax_t(product[i]) << bits | product[i - 1]; > > digit_t q = digit_t((product[i] == m_[1]) ? mask : temp / m_[1]); > > ::boost::uintmax_t rem = > ((temp - ::boost::uintmax_t(q) * m_[1]) << bits) + product[i - 2]; > > ::boost::uintmax_t diff = m_[0] * ::boost::uintmax_t(q); > > int error = 0; > if(diff > rem) { > if(diff - rem > m) { > error = 2; > } else { > error = 1; > } > } > q -= error; > rem = rem + error * m - diff; > > quotient[i - 2] = q; > product[i] = 0; > product[i-1] = (rem >> bits) & mask; > product[i-2] = rem & mask; > } > > div_t result = { > ((::boost::uintmax_t(quotient[1]) << bits) | quotient[0]), > ((::boost::uintmax_t(product[1]) << bits) | product[0]) >> shift, > }; > return result; >} > >inline boost::uintmax_t muldiv(boost::uintmax_t a, boost::uintmax_t b, boost::uintmax_t m) >{ return detail::muldivmod(a, b, m).quotient; } > >inline boost::uintmax_t mulmod(boost::uintmax_t a, boost::uintmax_t b, boost::uintmax_t m) >{ return detail::muldivmod(a, b, m).remainder; } > >} >} >} > ># 1 "/usr/include/boost/random/detail/enable_warnings.hpp" 1 3 4 ># 121 "/usr/include/boost/random/detail/large_arithmetic.hpp" 2 3 4 ># 24 "/usr/include/boost/random/detail/const_mod.hpp" 2 3 4 > ># 1 "/usr/include/boost/random/detail/disable_warnings.hpp" 1 3 4 ># 26 "/usr/include/boost/random/detail/const_mod.hpp" 2 3 4 > >namespace boost { >namespace random { > >template<class IntType, IntType m> >class const_mod >{ >public: > static IntType apply(IntType x) > { > if(((unsigned_m() - 1) & unsigned_m()) == 0) > return (unsigned_type(x)) & (unsigned_m() - 1); > else { > IntType supress_warnings = (m == 0); > (static_cast<void> (0)); > return x % (m + supress_warnings); > } > } > > static IntType add(IntType x, IntType c) > { > if(((unsigned_m() - 1) & unsigned_m()) == 0) > return (unsigned_type(x) + unsigned_type(c)) & (unsigned_m() - 1); > else if(c == 0) > return x; > else if(x < m - c) > return x + c; > else > return x - (m - c); > } > > static IntType mult(IntType a, IntType x) > { > if(((unsigned_m() - 1) & unsigned_m()) == 0) > return unsigned_type(a) * unsigned_type(x) & (unsigned_m() - 1); > else if(a == 0) > return 0; > else if(a == 1) > return x; > else if(m <= traits::const_max/a) > return mult_small(a, x); > else if(traits::is_signed && (m%a < m/a)) > return mult_schrage(a, x); > else > return mult_general(a, x); > } > > static IntType mult_add(IntType a, IntType x, IntType c) > { > if(((unsigned_m() - 1) & unsigned_m()) == 0) > return (unsigned_type(a) * unsigned_type(x) + unsigned_type(c)) & (unsigned_m() - 1); > else if(a == 0) > return c; > else if(m <= (traits::const_max-c)/a) { > IntType supress_warnings = (m == 0); > (static_cast<void> (0)); > return (a*x+c) % (m + supress_warnings); > } else > return add(mult(a, x), c); > } > > static IntType pow(IntType a, boost::uintmax_t exponent) > { > IntType result = 1; > while(exponent != 0) { > if(exponent % 2 == 1) { > result = mult(result, a); > } > a = mult(a, a); > exponent /= 2; > } > return result; > } > > static IntType invert(IntType x) > { return x == 0 ? 0 : (m == 0? invert_euclidian0(x) : invert_euclidian(x)); } > >private: > typedef integer_traits<IntType> traits; > typedef typename make_unsigned<IntType>::type unsigned_type; > > const_mod(); > > static IntType mult_small(IntType a, IntType x) > { > IntType supress_warnings = (m == 0); > (static_cast<void> (0)); > return a*x % (m + supress_warnings); > } > > static IntType mult_schrage(IntType a, IntType value) > { > const IntType q = m / a; > const IntType r = m % a; > > (static_cast<void> (0)); > > return sub(a*(value%q), r*(value/q)); > } > > static IntType mult_general(IntType a, IntType b) > { > IntType suppress_warnings = (m == 0); > (static_cast<void> (0)); > IntType modulus = m + suppress_warnings; > (static_cast<void> (0)); > if(::boost::uintmax_t(modulus) <= > (::std::numeric_limits< ::boost::uintmax_t>::max)() / modulus) > { > return static_cast<IntType>(boost::uintmax_t(a) * b % modulus); > } else { > return static_cast<IntType>(detail::mulmod(a, b, modulus)); > } > } > > static IntType sub(IntType a, IntType b) > { > if(a < b) > return m - (b - a); > else > return a - b; > } > > static unsigned_type unsigned_m() > { > if(m == 0) { > return unsigned_type((std::numeric_limits<IntType>::max)()) + 1; > } else { > return unsigned_type(m); > } > } > > > static IntType invert_euclidian(IntType c) > { > > (static_cast<void> (0)); > IntType l1 = 0; > IntType l2 = 1; > IntType n = c; > IntType p = m; > for(;;) { > IntType q = p / n; > l1 += q * l2; > p -= q * n; > if(p == 0) > return l2; > IntType q2 = n / p; > l2 += q2 * l1; > n -= q2 * p; > if(n == 0) > return m - l1; > } > } > > > static IntType invert_euclidian0(IntType c) > { > > (static_cast<void> (0)); > if(c == 1) return 1; > IntType l1 = 0; > IntType l2 = 1; > IntType n = c; > IntType p = m; > IntType max = (std::numeric_limits<IntType>::max)(); > IntType q = max / n; > (static_cast<void> (0)); > l1 += q * l2; > p = max - q * n + 1; > for(;;) { > if(p == 0) > return l2; > IntType q2 = n / p; > l2 += q2 * l1; > n -= q2 * p; > if(n == 0) > return m - l1; > q = p / n; > l1 += q * l2; > p -= q * n; > } > } >}; > >} >} > ># 1 "/usr/include/boost/random/detail/enable_warnings.hpp" 1 3 4 ># 215 "/usr/include/boost/random/detail/const_mod.hpp" 2 3 4 ># 28 "/usr/include/boost/random/detail/seed_impl.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/random/detail/disable_warnings.hpp" 1 3 4 ># 33 "/usr/include/boost/random/detail/seed_impl.hpp" 2 3 4 > >namespace boost { >namespace random { >namespace detail { > > > > > >template<class T> >struct seed_type >{ > typedef typename boost::mpl::if_<boost::is_integral<T>, > T, > boost::uint32_t > >::type type; >}; > >template<int N> >struct const_pow_impl >{ > template<class T> > static T call(T arg, int n, T result) > { > return const_pow_impl<N / 2>::call(arg * arg, n / 2, > n%2 == 0? result : result * arg); > } >}; > >template<> >struct const_pow_impl<0> >{ > template<class T> > static T call(T, int, T result) > { > return result; > } >}; > > >template<int N, class T> >inline T const_pow(T arg, int n) { return const_pow_impl<N>::call(arg, n, T(1)); } > >template<class T> >inline T pow2(int n) >{ > typedef unsigned int_type; > const int max_bits = std::numeric_limits<int_type>::digits; > T multiplier = T(int_type(1) << (max_bits - 1)) * 2; > return (int_type(1) << (n % max_bits)) * > const_pow<std::numeric_limits<T>::digits / max_bits>(multiplier, n / max_bits); >} > >template<class Engine, class Iter> >void generate_from_real(Engine& eng, Iter begin, Iter end) >{ > using std::fmod; > typedef typename Engine::result_type RealType; > const int Bits = detail::generator_bits<Engine>::value(); > int remaining_bits = 0; > boost::uint_least32_t saved_bits = 0; > RealType multiplier = pow2<RealType>( Bits); > RealType mult32 = RealType(4294967296.0); > while(true) { > RealType val = eng() * multiplier; > int available_bits = Bits; > > > if(Bits < 32 && available_bits < 32 - remaining_bits) { > saved_bits |= boost::uint_least32_t(val) << remaining_bits; > remaining_bits += Bits; > } else { > > > > if(Bits < 32 || remaining_bits != 0) { > boost::uint_least32_t divisor = > (boost::uint_least32_t(1) << (32 - remaining_bits)); > boost::uint_least32_t extra_bits = boost::uint_least32_t(fmod(val, mult32)) & (divisor - 1); > val = val / divisor; > *begin++ = saved_bits | (extra_bits << remaining_bits); > if(begin == end) return; > available_bits -= 32 - remaining_bits; > remaining_bits = 0; > } > > if(Bits >= 32) { > for(; available_bits >= 32; available_bits -= 32) { > boost::uint_least32_t word = boost::uint_least32_t(fmod(val, mult32)); > val /= mult32; > *begin++ = word; > if(begin == end) return; > } > } > remaining_bits = available_bits; > saved_bits = static_cast<boost::uint_least32_t>(val); > } > } >} > >template<class Engine, class Iter> >void generate_from_int(Engine& eng, Iter begin, Iter end) >{ > typedef typename Engine::result_type IntType; > typedef typename boost::make_unsigned<IntType>::type unsigned_type; > int remaining_bits = 0; > boost::uint_least32_t saved_bits = 0; > unsigned_type range = boost::random::detail::subtract<IntType>()((eng.max)(), (eng.min)()); > > int bits = > (range == (std::numeric_limits<unsigned_type>::max)()) ? > std::numeric_limits<unsigned_type>::digits : > detail::integer_log2(range + 1); > > { > int discarded_bits = detail::integer_log2(bits); > unsigned_type excess = (range + 1) >> (bits - discarded_bits); > if(excess != 0) { > int extra_bits = detail::integer_log2((excess - 1) ^ excess); > bits = bits - discarded_bits + extra_bits; > } > } > > unsigned_type mask = (static_cast<unsigned_type>(2) << (bits - 1)) - 1; > unsigned_type limit = ((range + 1) & ~mask) - 1; > > while(true) { > unsigned_type val; > do { > val = boost::random::detail::subtract<IntType>()(eng(), (eng.min)()); > } while(limit != range && val > limit); > val &= mask; > int available_bits = bits; > if(available_bits == 32) { > *begin++ = static_cast<boost::uint_least32_t>(val) & 0xFFFFFFFFu; > if(begin == end) return; > } else if(available_bits % 32 == 0) { > for(int i = 0; i < available_bits / 32; ++i) { > boost::uint_least32_t word = boost::uint_least32_t(val) & 0xFFFFFFFFu; > int supress_warning = (bits >= 32); > (static_cast<void> (0)); > val >>= (32 * supress_warning); > *begin++ = word; > if(begin == end) return; > } > } else if(bits < 32 && available_bits < 32 - remaining_bits) { > saved_bits |= boost::uint_least32_t(val) << remaining_bits; > remaining_bits += bits; > } else { > if(bits < 32 || remaining_bits != 0) { > boost::uint_least32_t extra_bits = boost::uint_least32_t(val) & ((boost::uint_least32_t(1) << (32 - remaining_bits)) - 1); > val >>= 32 - remaining_bits; > *begin++ = saved_bits | (extra_bits << remaining_bits); > if(begin == end) return; > available_bits -= 32 - remaining_bits; > remaining_bits = 0; > } > if(bits >= 32) { > for(; available_bits >= 32; available_bits -= 32) { > boost::uint_least32_t word = boost::uint_least32_t(val) & 0xFFFFFFFFu; > int supress_warning = (bits >= 32); > (static_cast<void> (0)); > val >>= (32 * supress_warning); > *begin++ = word; > if(begin == end) return; > } > } > remaining_bits = available_bits; > saved_bits = static_cast<boost::uint_least32_t>(val); > } > } >} > >template<class Engine, class Iter> >void generate_impl(Engine& eng, Iter first, Iter last, boost::mpl::true_) >{ > return detail::generate_from_int(eng, first, last); >} > >template<class Engine, class Iter> >void generate_impl(Engine& eng, Iter first, Iter last, boost::mpl::false_) >{ > return detail::generate_from_real(eng, first, last); >} > >template<class Engine, class Iter> >void generate(Engine& eng, Iter first, Iter last) >{ > return detail::generate_impl(eng, first, last, boost::is_integral<typename Engine::result_type>()); >} > > > >template<class IntType, IntType m, class SeedSeq> >IntType seed_one_int(SeedSeq& seq) >{ > static const int log = ::boost::mpl::if_c<(m == 0), > ::boost::mpl::int_<(::std::numeric_limits<IntType>::digits)>, > ::boost::static_log2<m> >::type::value; > static const int k = > (log + ((~(static_cast<IntType>(2) << (log - 1)) & m)? 32 : 31)) / 32; > ::boost::uint_least32_t array[log / 32 + 4]; > seq.generate(&array[0], &array[0] + k + 3); > IntType s = 0; > for(int j = 0; j < k; ++j) { > IntType digit = const_mod<IntType, m>::apply(IntType(array[j+3])); > IntType mult = IntType(1) << 32*j; > s = const_mod<IntType, m>::mult_add(mult, digit, s); > } > return s; >} > >template<class IntType, IntType m, class Iter> >IntType get_one_int(Iter& first, Iter last) >{ > static const int log = ::boost::mpl::if_c<(m == 0), > ::boost::mpl::int_<(::std::numeric_limits<IntType>::digits)>, > ::boost::static_log2<m> >::type::value; > static const int k = > (log + ((~(static_cast<IntType>(2) << (log - 1)) & m)? 32 : 31)) / 32; > IntType s = 0; > for(int j = 0; j < k; ++j) { > if(first == last) { > throw ::std::invalid_argument("Not enough elements in call to seed."); > } > IntType digit = const_mod<IntType, m>::apply(IntType(*first++)); > IntType mult = IntType(1) << 32*j; > s = const_mod<IntType, m>::mult_add(mult, digit, s); > } > return s; >} > > >template<int w, std::size_t n, class SeedSeq, class UIntType> >void seed_array_int_impl(SeedSeq& seq, UIntType (&x)[n]) >{ > boost::uint_least32_t storage[((w+31)/32) * n]; > seq.generate(&storage[0], &storage[0] + ((w+31)/32) * n); > for(std::size_t j = 0; j < n; j++) { > UIntType val = 0; > for(std::size_t k = 0; k < (w+31)/32; ++k) { > val += static_cast<UIntType>(storage[(w+31)/32*j + k]) << 32*k; > } > x[j] = val & ::boost::low_bits_mask_t<w>::sig_bits; > } >} > >template<int w, std::size_t n, class SeedSeq, class IntType> >inline void seed_array_int_impl(SeedSeq& seq, IntType (&x)[n], boost::mpl::true_) >{ > typedef typename boost::make_unsigned<IntType>::type unsigned_array[n]; > seed_array_int_impl<w>(seq, reinterpret_cast<unsigned_array&>(x)); >} > >template<int w, std::size_t n, class SeedSeq, class IntType> >inline void seed_array_int_impl(SeedSeq& seq, IntType (&x)[n], boost::mpl::false_) >{ > seed_array_int_impl<w>(seq, x); >} > >template<int w, std::size_t n, class SeedSeq, class IntType> >inline void seed_array_int(SeedSeq& seq, IntType (&x)[n]) >{ > seed_array_int_impl<w>(seq, x, boost::is_signed<IntType>()); >} > >template<int w, std::size_t n, class Iter, class UIntType> >void fill_array_int_impl(Iter& first, Iter last, UIntType (&x)[n]) >{ > for(std::size_t j = 0; j < n; j++) { > UIntType val = 0; > for(std::size_t k = 0; k < (w+31)/32; ++k) { > if(first == last) { > throw std::invalid_argument("Not enough elements in call to seed."); > } > val += static_cast<UIntType>(*first++) << 32*k; > } > x[j] = val & ::boost::low_bits_mask_t<w>::sig_bits; > } >} > >template<int w, std::size_t n, class Iter, class IntType> >inline void fill_array_int_impl(Iter& first, Iter last, IntType (&x)[n], boost::mpl::true_) >{ > typedef typename boost::make_unsigned<IntType>::type unsigned_array[n]; > fill_array_int_impl<w>(first, last, reinterpret_cast<unsigned_array&>(x)); >} > >template<int w, std::size_t n, class Iter, class IntType> >inline void fill_array_int_impl(Iter& first, Iter last, IntType (&x)[n], boost::mpl::false_) >{ > fill_array_int_impl<w>(first, last, x); >} > >template<int w, std::size_t n, class Iter, class IntType> >inline void fill_array_int(Iter& first, Iter last, IntType (&x)[n]) >{ > fill_array_int_impl<w>(first, last, x, boost::is_signed<IntType>()); >} > >template<int w, std::size_t n, class RealType> >void seed_array_real_impl(const boost::uint_least32_t* storage, RealType (&x)[n]) >{ > boost::uint_least32_t mask = ~((~boost::uint_least32_t(0)) << (w%32)); > RealType two32 = 4294967296.0; > const RealType divisor = RealType(1)/detail::pow2<RealType>(w); > unsigned int j; > for(j = 0; j < n; ++j) { > RealType val = RealType(0); > RealType mult = divisor; > for(int k = 0; k < w/32; ++k) { > val += *storage++ * mult; > mult *= two32; > } > if(mask != 0) { > val += (*storage++ & mask) * mult; > } > (static_cast<void> (0)); > (static_cast<void> (0)); > x[j] = val; > } >} > >template<int w, std::size_t n, class SeedSeq, class RealType> >void seed_array_real(SeedSeq& seq, RealType (&x)[n]) >{ > using std::pow; > boost::uint_least32_t storage[((w+31)/32) * n]; > seq.generate(&storage[0], &storage[0] + ((w+31)/32) * n); > seed_array_real_impl<w>(storage, x); >} > >template<int w, std::size_t n, class Iter, class RealType> >void fill_array_real(Iter& first, Iter last, RealType (&x)[n]) >{ > boost::uint_least32_t mask = ~((~boost::uint_least32_t(0)) << (w%32)); > RealType two32 = 4294967296.0; > const RealType divisor = RealType(1)/detail::pow2<RealType>(w); > unsigned int j; > for(j = 0; j < n; ++j) { > RealType val = RealType(0); > RealType mult = divisor; > for(int k = 0; k < w/32; ++k, ++first) { > if(first == last) throw std::invalid_argument("Not enough elements in call to seed."); > val += *first * mult; > mult *= two32; > } > if(mask != 0) { > if(first == last) throw std::invalid_argument("Not enough elements in call to seed."); > val += (*first & mask) * mult; > ++first; > } > (static_cast<void> (0)); > (static_cast<void> (0)); > x[j] = val; > } >} > >} >} >} > ># 1 "/usr/include/boost/random/detail/enable_warnings.hpp" 1 3 4 ># 396 "/usr/include/boost/random/detail/seed_impl.hpp" 2 3 4 ># 30 "/usr/include/boost/random/mersenne_twister.hpp" 2 3 4 ># 1 "/usr/include/boost/random/detail/generator_seed_seq.hpp" 1 3 4 ># 18 "/usr/include/boost/random/detail/generator_seed_seq.hpp" 3 4 >namespace boost { >namespace random { >namespace detail { > >template<class Generator> >class generator_seed_seq { >public: > generator_seed_seq(Generator& g) : gen(&g) {} > template<class It> > void generate(It first, It last) { > for(; first != last; ++first) { > *first = (*gen)(); > } > } >private: > Generator* gen; >}; > >} >} >} ># 31 "/usr/include/boost/random/mersenne_twister.hpp" 2 3 4 > >namespace boost { >namespace random { ># 63 "/usr/include/boost/random/mersenne_twister.hpp" 3 4 >template<class UIntType, > std::size_t w, std::size_t n, std::size_t m, std::size_t r, > UIntType a, std::size_t u, UIntType d, std::size_t s, > UIntType b, std::size_t t, > UIntType c, std::size_t l, UIntType f> >class mersenne_twister_engine >{ >public: > typedef UIntType result_type; > static const std::size_t word_size = w; > static const std::size_t state_size = n; > static const std::size_t shift_size = m; > static const std::size_t mask_bits = r; > static const UIntType xor_mask = a; > static const std::size_t tempering_u = u; > static const UIntType tempering_d = d; > static const std::size_t tempering_s = s; > static const UIntType tempering_b = b; > static const std::size_t tempering_t = t; > static const UIntType tempering_c = c; > static const std::size_t tempering_l = l; > static const UIntType initialization_multiplier = f; > static const UIntType default_seed = 5489u; > > > static const UIntType parameter_a = a; > static const std::size_t output_u = u; > static const std::size_t output_s = s; > static const UIntType output_b = b; > static const std::size_t output_t = t; > static const UIntType output_c = c; > static const std::size_t output_l = l; > > > static const bool has_fixed_range = false; > > > > > > mersenne_twister_engine() { seed(); } > > > > > explicit mersenne_twister_engine(const UIntType& value) > > { seed(value); } > template<class It> mersenne_twister_engine(It& first, It last) > { seed(first,last); } ># 122 "/usr/include/boost/random/mersenne_twister.hpp" 3 4 > template<class SeedSeq> explicit mersenne_twister_engine(SeedSeq& seq, typename ::boost::random::detail::disable_constructor<mersenne_twister_engine, SeedSeq>::type* = 0) > > { seed(seq); } > > > > > void seed() { seed(default_seed); } > > > > > > > > void seed(const UIntType& value) > { > > > > > const UIntType mask = (max)(); > x[0] = value & mask; > for (i = 1; i < n; i++) { > > > x[i] = (f * (x[i-1] ^ (x[i-1] >> (w-2))) + i) & mask; > } > } > > > > > template<class SeeqSeq> void seed(SeeqSeq& seq, typename ::boost::random::detail::disable_seed<SeeqSeq>::type* = 0) > { > detail::seed_array_int<w>(seq, x); > i = n; > > > if((x[0] & (~static_cast<UIntType>(0) << r)) == 0) { > for(std::size_t j = 1; j < n; ++j) { > if(x[j] != 0) return; > } > x[0] = static_cast<UIntType>(1) << (w-1); > } > } > > > template<class It> > void seed(It& first, It last) > { > detail::fill_array_int<w>(first, last, x); > i = n; > > > if((x[0] & (~static_cast<UIntType>(0) << r)) == 0) { > for(std::size_t j = 1; j < n; ++j) { > if(x[j] != 0) return; > } > x[0] = static_cast<UIntType>(1) << (w-1); > } > } > > > static result_type min () > { return 0; } > > static result_type max () > { return boost::low_bits_mask_t<w>::sig_bits; } > > > result_type operator()(); > > > template<class Iter> > void generate(Iter first, Iter last) > { detail::generate_from_int(*this, first, last); } ># 209 "/usr/include/boost/random/mersenne_twister.hpp" 3 4 > void discard(boost::uintmax_t z) > { > for(boost::uintmax_t j = 0; j < z; ++j) { > (*this)(); > } > } > > > > template<class CharT, class Traits> > friend std::basic_ostream<CharT,Traits>& > operator<<(std::basic_ostream<CharT,Traits>& os, > const mersenne_twister_engine& mt) > { > mt.print(os); > return os; > } > > > template<class CharT, class Traits> > friend std::basic_istream<CharT,Traits>& > operator>>(std::basic_istream<CharT,Traits>& is, > mersenne_twister_engine& mt) > { > for(std::size_t j = 0; j < mt.state_size; ++j) > is >> mt.x[j] >> std::ws; > > > > mt.i = mt.state_size; > return is; > } > > > > > > > friend bool operator==(const mersenne_twister_engine& x, > const mersenne_twister_engine& y) > { > if(x.i < y.i) return x.equal_imp(y); > else return y.equal_imp(x); > } > > > > > friend bool operator!=(const mersenne_twister_engine& x, > const mersenne_twister_engine& y) > { return !(x == y); } > >private: > > > void twist(); ># 274 "/usr/include/boost/random/mersenne_twister.hpp" 3 4 > bool equal_imp(const mersenne_twister_engine& other) const > { > UIntType back[n]; > std::size_t offset = other.i - i; > for(std::size_t j = 0; j + offset < n; ++j) > if(x[j] != other.x[j+offset]) > return false; > rewind(&back[n-1], offset); > for(std::size_t j = 0; j < offset; ++j) > if(back[j + n - offset] != other.x[j]) > return false; > return true; > } > > > > > > template<class CharT, class Traits> > void print(std::basic_ostream<CharT, Traits>& os) const > { > UIntType data[n]; > for(std::size_t j = 0; j < i; ++j) { > data[j + n - i] = x[j]; > } > if(i != n) { > rewind(&data[n - i - 1], n - i); > } > os << data[0]; > for(std::size_t j = 1; j < n; ++j) { > os << ' ' << data[j]; > } > } > > > > > > void rewind(UIntType* last, std::size_t z) const > { > const UIntType upper_mask = (~static_cast<UIntType>(0)) << r; > const UIntType lower_mask = ~upper_mask; > UIntType y0 = x[m-1] ^ x[n-1]; > if(y0 & (static_cast<UIntType>(1) << (w-1))) { > y0 = ((y0 ^ a) << 1) | 1; > } else { > y0 = y0 << 1; > } > for(std::size_t sz = 0; sz < z; ++sz) { > UIntType y1 = > rewind_find(last, sz, m-1) ^ rewind_find(last, sz, n-1); > if(y1 & (static_cast<UIntType>(1) << (w-1))) { > y1 = ((y1 ^ a) << 1) | 1; > } else { > y1 = y1 << 1; > } > *(last - sz) = (y0 & upper_mask) | (y1 & lower_mask); > y0 = y1; > } > } > > > > > > > UIntType > rewind_find(UIntType* last, std::size_t size, std::size_t j) const > { > std::size_t index = (j + n - size + n - 1) % n; > if(index < n - size) { > return x[index]; > } else { > return *(last - (n - 1 - index)); > } > } > > > > > > > > UIntType x[n]; > std::size_t i; >}; ># 370 "/usr/include/boost/random/mersenne_twister.hpp" 3 4 >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::word_size; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::state_size; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::shift_size; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::mask_bits; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const UIntType mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::xor_mask; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::tempering_u; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const UIntType mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::tempering_d; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::tempering_s; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const UIntType mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::tempering_b; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::tempering_t; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const UIntType mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::tempering_c; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::tempering_l; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const UIntType mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::initialization_multiplier; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const UIntType mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::default_seed; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const UIntType mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::parameter_a; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::output_u; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::output_s; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const UIntType mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::output_b; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::output_t; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const UIntType mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::output_c; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const std::size_t mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::output_l; >template<class UIntType, std::size_t w, std::size_t n, std::size_t m, std::size_t r, UIntType a, std::size_t u, UIntType d, std::size_t s, UIntType b, std::size_t t, UIntType c, std::size_t l, UIntType f> const bool mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::has_fixed_range; > > > >template<class UIntType, > std::size_t w, std::size_t n, std::size_t m, std::size_t r, > UIntType a, std::size_t u, UIntType d, std::size_t s, > UIntType b, std::size_t t, > UIntType c, std::size_t l, UIntType f> >void >mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::twist() >{ > const UIntType upper_mask = (~static_cast<UIntType>(0)) << r; > const UIntType lower_mask = ~upper_mask; > > const std::size_t unroll_factor = 6; > const std::size_t unroll_extra1 = (n-m) % unroll_factor; > const std::size_t unroll_extra2 = (m-1) % unroll_factor; > > > { > for(std::size_t j = 0; j < n-m-unroll_extra1; j++) { > UIntType y = (x[j] & upper_mask) | (x[j+1] & lower_mask); > x[j] = x[j+m] ^ (y >> 1) ^ ((x[j+1]&1) * a); > } > } > { > for(std::size_t j = n-m-unroll_extra1; j < n-m; j++) { > UIntType y = (x[j] & upper_mask) | (x[j+1] & lower_mask); > x[j] = x[j+m] ^ (y >> 1) ^ ((x[j+1]&1) * a); > } > } > { > for(std::size_t j = n-m; j < n-1-unroll_extra2; j++) { > UIntType y = (x[j] & upper_mask) | (x[j+1] & lower_mask); > x[j] = x[j-(n-m)] ^ (y >> 1) ^ ((x[j+1]&1) * a); > } > } > { > for(std::size_t j = n-1-unroll_extra2; j < n-1; j++) { > UIntType y = (x[j] & upper_mask) | (x[j+1] & lower_mask); > x[j] = x[j-(n-m)] ^ (y >> 1) ^ ((x[j+1]&1) * a); > } > } > > UIntType y = (x[n-1] & upper_mask) | (x[0] & lower_mask); > x[n-1] = x[m-1] ^ (y >> 1) ^ ((x[0]&1) * a); > i = 0; >} > > >template<class UIntType, > std::size_t w, std::size_t n, std::size_t m, std::size_t r, > UIntType a, std::size_t u, UIntType d, std::size_t s, > UIntType b, std::size_t t, > UIntType c, std::size_t l, UIntType f> >inline typename >mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::result_type >mersenne_twister_engine<UIntType,w,n,m,r,a,u,d,s,b,t,c,l,f>::operator()() >{ > if(i == n) > twist(); > > UIntType z = x[i]; > ++i; > z ^= ((z >> u) & d); > z ^= ((z << s) & b); > z ^= ((z << t) & c); > z ^= (z >> l); > return z; >} ># 474 "/usr/include/boost/random/mersenne_twister.hpp" 3 4 >typedef mersenne_twister_engine<uint32_t,32,351,175,19,0xccab8ee7, > 11,0xffffffff,7,0x31b6ab00,15,0xffe50000,17,1812433253> mt11213b; ># 488 "/usr/include/boost/random/mersenne_twister.hpp" 3 4 >typedef mersenne_twister_engine<uint32_t,32,624,397,31,0x9908b0df, > 11,0xffffffff,7,0x9d2c5680,15,0xefc60000,18,1812433253> mt19937; > > >typedef mersenne_twister_engine<uint64_t,64,312,156,31, > 0xb5026f5aa96619e9UL,29,0x5555555555555555UL,17, > 0x71d67fffeda60000UL,37,0xfff7eee000000000UL,43, > 6364136223846793005UL> mt19937_64; > > > > >template<class UIntType, > int w, int n, int m, int r, > UIntType a, int u, std::size_t s, > UIntType b, int t, > UIntType c, int l, UIntType v> >class mersenne_twister : > public mersenne_twister_engine<UIntType, > w, n, m, r, a, u, ~(UIntType)0, s, b, t, c, l, 1812433253> >{ > typedef mersenne_twister_engine<UIntType, > w, n, m, r, a, u, ~(UIntType)0, s, b, t, c, l, 1812433253> base_type; >public: > mersenne_twister() {} > template<class Gen> explicit mersenne_twister(Gen& gen, typename ::boost::random::detail::disable_constructor<mersenne_twister, Gen>::type* = 0) > { seed(gen); } > explicit mersenne_twister(const UIntType& val) > { seed(val); } > template<class It> > mersenne_twister(It& first, It last) : base_type(first, last) {} > void seed() { base_type::seed(); } > template<class Gen> void seed(Gen& gen, typename ::boost::random::detail::disable_seed<Gen>::type* = 0) > { > detail::generator_seed_seq<Gen> seq(gen); > base_type::seed(seq); > } > void seed(const UIntType& val) > { base_type::seed(val); } > template<class It> > void seed(It& first, It last) { base_type::seed(first, last); } >}; > > > >} > >using random::mt11213b; >using random::mt19937; >using random::mt19937_64; > >} ># 16 "/usr/include/boost/uuid/random_generator.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 17 "/usr/include/boost/uuid/random_generator.hpp" 2 3 4 > > > >namespace boost { >namespace uuids { > > >template <typename UniformRandomNumberGenerator> >class basic_random_generator { >private: > typedef uniform_int<unsigned long> distribution_type; > typedef variate_generator<UniformRandomNumberGenerator*, distribution_type> generator_type; > > struct null_deleter > { > void operator()(void const *) const {} > }; > >public: > typedef uuid result_type; > > > basic_random_generator() > : pURNG(new UniformRandomNumberGenerator) > , generator > ( pURNG.get() > , distribution_type > ( (std::numeric_limits<unsigned long>::min)() > , (std::numeric_limits<unsigned long>::max)() > ) > ) > { > > detail::seed(*pURNG); > } > > > > explicit basic_random_generator(UniformRandomNumberGenerator& gen) > : pURNG(&gen, null_deleter()) > , generator > ( pURNG.get() > , distribution_type > ( (std::numeric_limits<unsigned long>::min)() > , (std::numeric_limits<unsigned long>::max)() > ) > ) > {} > > > > explicit basic_random_generator(UniformRandomNumberGenerator* pGen) > : pURNG(pGen, null_deleter()) > , generator > ( pURNG.get() > , distribution_type > ( (std::numeric_limits<unsigned long>::min)() > , (std::numeric_limits<unsigned long>::max)() > ) > ) > { > (static_cast<void> (0)); > } > > uuid operator()() > { > uuid u; > > int i=0; > unsigned long random_value = generator(); > for (uuid::iterator it=u.begin(); it!=u.end(); ++it, ++i) { > if (i==sizeof(unsigned long)) { > random_value = generator(); > i = 0; > } > > > *it = static_cast<uuid::value_type>((random_value >> (i*8)) & 0xFF); > } > > > > *(u.begin()+8) &= 0xBF; > *(u.begin()+8) |= 0x80; > > > > *(u.begin()+6) &= 0x4F; > *(u.begin()+6) |= 0x40; > > return u; > } > >private: > shared_ptr<UniformRandomNumberGenerator> pURNG; > generator_type generator; >}; > >typedef basic_random_generator<mt19937> random_generator; > >}} ># 34 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" 2 ># 1 "/usr/include/boost/chrono.hpp" 1 3 4 ># 17 "/usr/include/boost/chrono.hpp" 3 4 ># 1 "/usr/include/boost/chrono/include.hpp" 1 3 4 ># 15 "/usr/include/boost/chrono/include.hpp" 3 4 ># 1 "/usr/include/boost/chrono/chrono.hpp" 1 3 4 ># 16 "/usr/include/boost/chrono/include.hpp" 2 3 4 ># 1 "/usr/include/boost/chrono/chrono_io.hpp" 1 3 4 ># 29 "/usr/include/boost/chrono/chrono_io.hpp" 3 4 ># 1 "/usr/include/boost/chrono/io_v1/chrono_io.hpp" 1 3 4 ># 17 "/usr/include/boost/chrono/io_v1/chrono_io.hpp" 3 4 ># 1 "/usr/include/boost/chrono/process_cpu_clocks.hpp" 1 3 4 ># 27 "/usr/include/boost/chrono/process_cpu_clocks.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 28 "/usr/include/boost/chrono/process_cpu_clocks.hpp" 2 3 4 > > >namespace boost { namespace chrono { > > class process_real_cpu_clock { > public: > typedef nanoseconds duration; > typedef duration::rep rep; > typedef duration::period period; > typedef chrono::time_point<process_real_cpu_clock> time_point; > static constexpr bool is_steady = true; > > static time_point now() noexcept; > > static time_point now(system::error_code & ec ); > > }; > > class process_user_cpu_clock { > public: > typedef nanoseconds duration; > typedef duration::rep rep; > typedef duration::period period; > typedef chrono::time_point<process_user_cpu_clock> time_point; > static constexpr bool is_steady = true; > > static time_point now() noexcept; > > static time_point now(system::error_code & ec ); > > }; > > class process_system_cpu_clock { > public: > typedef nanoseconds duration; > typedef duration::rep rep; > typedef duration::period period; > typedef chrono::time_point<process_system_cpu_clock> time_point; > static constexpr bool is_steady = true; > > static time_point now() noexcept; > > static time_point now(system::error_code & ec ); > > }; > > template <typename Rep> > struct process_times > : arithmetic<process_times<Rep>, > multiplicative<process_times<Rep>, Rep, > less_than_comparable<process_times<Rep> > > > > { > > typedef Rep rep; > process_times() > : real(0) > , user(0) > , system(0){} > template <typename Rep2> > explicit process_times( > Rep2 r) > : real(r) > , user(r) > , system(r){} > template <typename Rep2> > explicit process_times( > process_times<Rep2> const& rhs) > : real(rhs.real) > , user(rhs.user) > , system(rhs.system){} > process_times( > rep r, > rep u, > rep s) > : real(r) > , user(u) > , system(s){} > > rep real; > rep user; > rep system; > > operator rep() const > { > return real; > } > template <typename Rep2> > bool operator==(process_times<Rep2> const& rhs) { > return (real==rhs.real && > user==rhs.user && > system==rhs.system); > } > > process_times& operator+=( > process_times const& rhs) > { > real+=rhs.real; > user+=rhs.user; > system+=rhs.system; > return *this; > } > process_times& operator-=( > process_times const& rhs) > { > real-=rhs.real; > user-=rhs.user; > system-=rhs.system; > return *this; > } > process_times& operator*=( > process_times const& rhs) > { > real*=rhs.real; > user*=rhs.user; > system*=rhs.system; > return *this; > } > process_times& operator*=(rep const& rhs) > { > real*=rhs; > user*=rhs; > system*=rhs; > return *this; > } > process_times& operator/=(process_times const& rhs) > { > real/=rhs.real; > user/=rhs.user; > system/=rhs.system; > return *this; > } > process_times& operator/=(rep const& rhs) > { > real/=rhs; > user/=rhs; > system/=rhs; > return *this; > } > bool operator<(process_times const & rhs) const > { > if (real < rhs.real) return true; > if (real > rhs.real) return false; > if (user < rhs.user) return true; > if (user > rhs.user) return false; > if (system < rhs.system) return true; > else return false; > } > > template <class CharT, class Traits> > void print(std::basic_ostream<CharT, Traits>& os) const > { > os << "{"<< real <<";"<< user <<";"<< system << "}"; > } > > template <class CharT, class Traits> > void read(std::basic_istream<CharT, Traits>& is) const > { > typedef std::istreambuf_iterator<CharT, Traits> in_iterator; > in_iterator i(is); > in_iterator e; > if (i == e || *i != '{') > { > is.setstate(is.failbit | is.eofbit); > return; > } > CharT x,y,z; > is >> real >> x >> user >> y >> system >> z; > if (!is.good() || (x != ';')|| (y != ';')|| (z != '}')) > { > is.setstate(is.failbit); > } > } > }; >} >template <class Rep1, class Rep2> >struct common_type< > chrono::process_times<Rep1>, > chrono::process_times<Rep2> >> >{ > typedef chrono::process_times<typename common_type<Rep1, Rep2>::type> type; >}; > >template <class Rep1, class Rep2> >struct common_type< > chrono::process_times<Rep1>, > Rep2 >> >{ > typedef chrono::process_times<typename common_type<Rep1, Rep2>::type> type; >}; > >template <class Rep1, class Rep2> >struct common_type< > Rep1, > chrono::process_times<Rep2> >> >{ > typedef chrono::process_times<typename common_type<Rep1, Rep2>::type> type; >}; > > >namespace chrono >{ > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator==(const duration<process_times<Rep1>, Period1>& lhs, > const duration<process_times<Rep2>, Period2>& rhs) > { > return boost::chrono::detail::duration_eq< > duration<process_times<Rep1>, Period1>, duration<process_times<Rep2>, Period2> >()(lhs, rhs); > } > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator==(const duration<process_times<Rep1>, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > return boost::chrono::detail::duration_eq< > duration<Rep1, Period1>, duration<Rep2, Period2> >()(duration<Rep1, Period1>(lhs.count().real), rhs); > } > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator==(const duration<Rep1, Period1>& lhs, > const duration<process_times<Rep2>, Period2>& rhs) > { > return rhs == lhs; > } > > > > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator< (const duration<process_times<Rep1>, Period1>& lhs, > const duration<Rep2, Period2>& rhs) > { > return boost::chrono::detail::duration_lt< > duration<Rep1, Period1>, duration<Rep2, Period2> >()(duration<Rep1, Period1>(lhs.count().real), rhs); > } > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator< (const duration<Rep1, Period1>& lhs, > const duration<process_times<Rep2>, Period2>& rhs) > { > return rhs < lhs; > } > > template <class Rep1, class Period1, class Rep2, class Period2> > inline constexpr > bool > operator< (const duration<process_times<Rep1>, Period1>& lhs, > const duration<process_times<Rep2>, Period2>& rhs) > { > return boost::chrono::detail::duration_lt< > duration<Rep1, Period1>, duration<Rep2, Period2> >()(lhs, rhs); > } > > > typedef process_times<nanoseconds::rep> process_cpu_clock_times; > class process_cpu_clock > { > public: > > typedef process_cpu_clock_times times; > typedef boost::chrono::duration<times, nano> duration; > typedef duration::rep rep; > typedef duration::period period; > typedef chrono::time_point<process_cpu_clock> time_point; > static constexpr bool is_steady = true; > > static time_point now() noexcept; > > static time_point now(system::error_code & ec ); > > }; > > template <class CharT, class Traits, typename Rep> > std::basic_ostream<CharT, Traits>& > operator<<(std::basic_ostream<CharT, Traits>& os, > process_times<Rep> const& rhs) > { > rhs.print(os); > return os; > } > > template <class CharT, class Traits, typename Rep> > std::basic_istream<CharT, Traits>& > operator>>(std::basic_istream<CharT, Traits>& is, > process_times<Rep> const& rhs) > { > rhs.read(is); > return is; > } > > template <typename Rep> > struct duration_values<process_times<Rep> > > { > typedef process_times<Rep> Res; > public: > static Res zero() > { > return Res(); > } > static Res max () > { > return Res((std::numeric_limits<Rep>::max)(), > (std::numeric_limits<Rep>::max)(), > (std::numeric_limits<Rep>::max)()); > } > static Res min () > { > return Res((std::numeric_limits<Rep>::min)(), > (std::numeric_limits<Rep>::min)(), > (std::numeric_limits<Rep>::min)()); > } > }; > > template<class CharT> > struct clock_string<process_real_cpu_clock, CharT> > { > static std::basic_string<CharT> name() > { > static const CharT > u[] = > { 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'r', 'e', 'a', 'l', '_', 'c', 'l', 'o', 'c', 'k' }; > static const std::basic_string<CharT> str(u, u + sizeof(u) > / sizeof(u[0])); > return str; > } > static std::basic_string<CharT> since() > { > const CharT > u[] = > { ' ', 's', 'i', 'n', 'c', 'e', ' ', 'p', 'r', 'o', 'c', 'e', 's', 's', ' ', 's', 't', 'a', 'r', 't', '-', 'u', 'p' }; > const std::basic_string<CharT> str(u, u + sizeof(u) / sizeof(u[0])); > return str; > } > }; > > template<class CharT> > struct clock_string<process_user_cpu_clock, CharT> > { > static std::basic_string<CharT> name() > { > static const CharT > u[] = > { 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'u', 's', 'e', 'r', '_', 'c', 'l', 'o', 'c', 'k' }; > static const std::basic_string<CharT> str(u, u + sizeof(u) > / sizeof(u[0])); > return str; > } > static std::basic_string<CharT> since() > { > const CharT > u[] = > { ' ', 's', 'i', 'n', 'c', 'e', ' ', 'p', 'r', 'o', 'c', 'e', 's', 's', ' ', 's', 't', 'a', 'r', 't', '-', 'u', 'p' }; > const std::basic_string<CharT> str(u, u + sizeof(u) / sizeof(u[0])); > return str; > } > }; > > template<class CharT> > struct clock_string<process_system_cpu_clock, CharT> > { > static std::basic_string<CharT> name() > { > static const CharT > u[] = > { 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 's', 'y', 's', 't', 't', 'e', 'm', '_', 'c', 'l', 'o', 'c', 'k' }; > static const std::basic_string<CharT> str(u, u + sizeof(u) > / sizeof(u[0])); > return str; > } > static std::basic_string<CharT> since() > { > const CharT > u[] = > { ' ', 's', 'i', 'n', 'c', 'e', ' ', 'p', 'r', 'o', 'c', 'e', 's', 's', ' ', 's', 't', 'a', 'r', 't', '-', 'u', 'p' }; > const std::basic_string<CharT> str(u, u + sizeof(u) / sizeof(u[0])); > return str; > } > }; > > template<class CharT> > struct clock_string<process_cpu_clock, CharT> > { > static std::basic_string<CharT> name() > { > static const CharT u[] = > { 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'c', 'l', 'o', 'c', 'k' }; > static const std::basic_string<CharT> str(u, u + sizeof(u) > / sizeof(u[0])); > return str; > } > static std::basic_string<CharT> since() > { > const CharT > u[] = > { ' ', 's', 'i', 'n', 'c', 'e', ' ', 'p', 'r', 'o', 'c', 'e', 's', 's', ' ', 's', 't', 'a', 'r', 't', '-', 'u', 'p' }; > const std::basic_string<CharT> str(u, u + sizeof(u) / sizeof(u[0])); > return str; > } > }; > >} >} > >namespace std { > > template <typename Rep> > struct numeric_limits<boost::chrono::process_times<Rep> > > { > typedef boost::chrono::process_times<Rep> Res; > > public: > static const bool is_specialized = true; > static Res min () > { > return Res((std::numeric_limits<Rep>::min)(), > (std::numeric_limits<Rep>::min)(), > (std::numeric_limits<Rep>::min)()); > } > static Res max () > { > return Res((std::numeric_limits<Rep>::max)(), > (std::numeric_limits<Rep>::max)(), > (std::numeric_limits<Rep>::max)()); > } > static Res lowest() throw() > { > return (min)(); > } > static const int digits = std::numeric_limits<Rep>::digits+ > std::numeric_limits<Rep>::digits+ > std::numeric_limits<Rep>::digits; > static const int digits10 = std::numeric_limits<Rep>::digits10+ > std::numeric_limits<Rep>::digits10+ > std::numeric_limits<Rep>::digits10; > static const bool is_signed = Rep::is_signed; > static const bool is_integer = Rep::is_integer; > static const bool is_exact = Rep::is_exact; > static const int radix = 0; ># 500 "/usr/include/boost/chrono/process_cpu_clocks.hpp" 3 4 > }; >} > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 505 "/usr/include/boost/chrono/process_cpu_clocks.hpp" 2 3 4 ># 18 "/usr/include/boost/chrono/io_v1/chrono_io.hpp" 2 3 4 ># 1 "/usr/include/boost/chrono/thread_clock.hpp" 1 3 4 ># 24 "/usr/include/boost/chrono/thread_clock.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 25 "/usr/include/boost/chrono/thread_clock.hpp" 2 3 4 > > >namespace boost { namespace chrono { > >class thread_clock { >public: > typedef nanoseconds duration; > typedef duration::rep rep; > typedef duration::period period; > typedef chrono::time_point<thread_clock> time_point; > static constexpr bool is_steady = true; > > static time_point now( ) noexcept; > > static time_point now( system::error_code & ec ); > >}; > >template <class CharT> >struct clock_string<thread_clock, CharT> >{ > static std::basic_string<CharT> name() > { > static const CharT u[] = > { 't', 'h', 'r', 'e', 'a', 'd', '_', > 'c', 'l','o', 'c', 'k'}; > static const std::basic_string<CharT> str(u, u + sizeof(u)/sizeof(u[0])); > return str; > } > static std::basic_string<CharT> since() > { > const CharT u[] = > { ' ', 's', 'i', 'n', 'c', 'e', ' ', 't', 'h', 'r', 'e', 'a', 'd', ' ', 's', 't', 'a', 'r', 't', '-', 'u', 'p'}; > const std::basic_string<CharT> str(u, u + sizeof(u)/sizeof(u[0])); > return str; > } >}; > >} >} > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 69 "/usr/include/boost/chrono/thread_clock.hpp" 2 3 4 ># 19 "/usr/include/boost/chrono/io_v1/chrono_io.hpp" 2 3 4 > ># 1 "/usr/include/boost/ratio/ratio_io.hpp" 1 3 4 ># 38 "/usr/include/boost/ratio/ratio_io.hpp" 3 4 ># 1 "/usr/include/boost/ratio/detail/ratio_io.hpp" 1 3 4 ># 55 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >namespace boost { > > > > > > >template <class Ratio, class CharT> >struct ratio_string >{ > static std::basic_string<CharT> short_name() {return long_name();} > static std::basic_string<CharT> long_name(); > static std::basic_string<CharT> symbol() {return short_name();} > static std::basic_string<CharT> prefix() {return long_name();} >}; > >template <class Ratio, class CharT> >std::basic_string<CharT> >ratio_string<Ratio, CharT>::long_name() >{ > std::basic_ostringstream<CharT> os; > os << CharT('[') << Ratio::num << CharT('/') > << Ratio::den << CharT(']'); > return os.str(); >} ># 117 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<atto, char> >{ > static std::string short_name() {return std::string(1, 'a');} > static std::string long_name() {return std::string("atto");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<atto, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'a');} > static std::u16string long_name() {return std::u16string(u"atto");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<atto, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'a');} > static std::u32string long_name() {return std::u32string(U"atto");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<atto, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'a');} > static std::wstring long_name() {return std::wstring(L"atto");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 176 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<femto, char> >{ > static std::string short_name() {return std::string(1, 'f');} > static std::string long_name() {return std::string("femto");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<femto, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'f');} > static std::u16string long_name() {return std::u16string(u"femto");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<femto, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'f');} > static std::u32string long_name() {return std::u32string(U"femto");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<femto, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'f');} > static std::wstring long_name() {return std::wstring(L"femto");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 234 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<pico, char> >{ > static std::string short_name() {return std::string(1, 'p');} > static std::string long_name() {return std::string("pico");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<pico, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'p');} > static std::u16string long_name() {return std::u16string(u"pico");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<pico, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'p');} > static std::u32string long_name() {return std::u32string(U"pico");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<pico, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'p');} > static std::wstring long_name() {return std::wstring(L"pico");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 292 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<nano, char> >{ > static std::string short_name() {return std::string(1, 'n');} > static std::string long_name() {return std::string("nano");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<nano, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'n');} > static std::u16string long_name() {return std::u16string(u"nano");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<nano, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'n');} > static std::u32string long_name() {return std::u32string(U"nano");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<nano, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'n');} > static std::wstring long_name() {return std::wstring(L"nano");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 350 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<micro, char> >{ > static std::string short_name() {return std::string("\xC2\xB5");} > static std::string long_name() {return std::string("micro");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<micro, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'\xB5');} > static std::u16string long_name() {return std::u16string(u"micro");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<micro, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'\xB5');} > static std::u32string long_name() {return std::u32string(U"micro");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<micro, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'\xB5');} > static std::wstring long_name() {return std::wstring(L"micro");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 408 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<milli, char> >{ > static std::string short_name() {return std::string(1, 'm');} > static std::string long_name() {return std::string("milli");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<milli, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'm');} > static std::u16string long_name() {return std::u16string(u"milli");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<milli, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'm');} > static std::u32string long_name() {return std::u32string(U"milli");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<milli, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'm');} > static std::wstring long_name() {return std::wstring(L"milli");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 466 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<centi, char> >{ > static std::string short_name() {return std::string(1, 'c');} > static std::string long_name() {return std::string("centi");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<centi, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'c');} > static std::u16string long_name() {return std::u16string(u"centi");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<centi, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'c');} > static std::u32string long_name() {return std::u32string(U"centi");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<centi, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'c');} > static std::wstring long_name() {return std::wstring(L"centi");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 525 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<deci, char> >{ > static std::string short_name() {return std::string(1, 'd');} > static std::string long_name() {return std::string("deci");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<deci, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'd');} > static std::u16string long_name() {return std::u16string(u"deci");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<deci, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'd');} > static std::u32string long_name() {return std::u32string(U"deci");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<deci, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'd');} > static std::wstring long_name() {return std::wstring(L"deci");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 590 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<deca, char> >{ > static std::string short_name() {return std::string("da");} > static std::string long_name() {return std::string("deca");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<deca, char16_t> >{ > static std::u16string short_name() {return std::u16string(u"da");} > static std::u16string long_name() {return std::u16string(u"deca");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<deca, char32_t> >{ > static std::u32string short_name() {return std::u32string(U"da");} > static std::u32string long_name() {return std::u32string(U"deca");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<deca, wchar_t> >{ > static std::wstring short_name() {return std::wstring(L"da");} > static std::wstring long_name() {return std::wstring(L"deca");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 649 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<hecto, char> >{ > static std::string short_name() {return std::string(1, 'h');} > static std::string long_name() {return std::string("hecto");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<hecto, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'h');} > static std::u16string long_name() {return std::u16string(u"hecto");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<hecto, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'h');} > static std::u32string long_name() {return std::u32string(U"hecto");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<hecto, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'h');} > static std::wstring long_name() {return std::wstring(L"hecto");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 707 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<kilo, char> >{ > static std::string short_name() {return std::string(1, 'k');} > static std::string long_name() {return std::string("kilo");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<kilo, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'k');} > static std::u16string long_name() {return std::u16string(u"kilo");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<kilo, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'k');} > static std::u32string long_name() {return std::u32string(U"kilo");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<kilo, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'k');} > static std::wstring long_name() {return std::wstring(L"kilo");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 766 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<mega, char> >{ > static std::string short_name() {return std::string(1, 'M');} > static std::string long_name() {return std::string("mega");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<mega, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'M');} > static std::u16string long_name() {return std::u16string(u"mega");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<mega, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'M');} > static std::u32string long_name() {return std::u32string(U"mega");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<mega, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'M');} > static std::wstring long_name() {return std::wstring(L"mega");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 825 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<giga, char> >{ > static std::string short_name() {return std::string(1, 'G');} > static std::string long_name() {return std::string("giga");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<giga, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'G');} > static std::u16string long_name() {return std::u16string(u"giga");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<giga, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'G');} > static std::u32string long_name() {return std::u32string(U"giga");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<giga, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'G');} > static std::wstring long_name() {return std::wstring(L"giga");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 883 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<tera, char> >{ > static std::string short_name() {return std::string(1, 'T');} > static std::string long_name() {return std::string("tera");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<tera, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'T');} > static std::u16string long_name() {return std::u16string(u"tera");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<tera, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'T');} > static std::u32string long_name() {return std::u32string(U"tera");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<tera, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'T');} > static std::wstring long_name() {return std::wstring(L"tera");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 942 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<peta, char> >{ > static std::string short_name() {return std::string(1, 'P');} > static std::string long_name() {return std::string("peta");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<peta, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'P');} > static std::u16string long_name() {return std::u16string(u"peta");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<peta, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'P');} > static std::u32string long_name() {return std::u32string(U"peta");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<peta, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'P');} > static std::wstring long_name() {return std::wstring(L"peta");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; ># 1000 "/usr/include/boost/ratio/detail/ratio_io.hpp" 3 4 >template <> >struct ratio_string<exa, char> >{ > static std::string short_name() {return std::string(1, 'E');} > static std::string long_name() {return std::string("exa");} > static std::string symbol() {return short_name();} > static std::string prefix() {return long_name();} >}; > > > >template <> >struct ratio_string<exa, char16_t> >{ > static std::u16string short_name() {return std::u16string(1, u'E');} > static std::u16string long_name() {return std::u16string(u"exa");} > static std::u16string symbol() {return short_name();} > static std::u16string prefix() {return long_name();} >}; > >template <> >struct ratio_string<exa, char32_t> >{ > static std::u32string short_name() {return std::u32string(1, U'E');} > static std::u32string long_name() {return std::u32string(U"exa");} > static std::u32string symbol() {return short_name();} > static std::u32string prefix() {return long_name();} >}; > > > > >template <> >struct ratio_string<exa, wchar_t> >{ > static std::wstring short_name() {return std::wstring(1, L'E');} > static std::wstring long_name() {return std::wstring(L"exa");} > static std::wstring symbol() {return short_name();} > static std::wstring prefix() {return long_name();} >}; > > > >} ># 39 "/usr/include/boost/ratio/ratio_io.hpp" 2 3 4 ># 21 "/usr/include/boost/chrono/io_v1/chrono_io.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/math/common_factor_rt.hpp" 1 3 4 ># 18 "/usr/include/boost/math/common_factor_rt.hpp" 3 4 ># 1 "/usr/include/boost/math_fwd.hpp" 1 3 4 ># 12 "/usr/include/boost/math_fwd.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 13 "/usr/include/boost/math_fwd.hpp" 2 3 4 > >namespace boost >{ >namespace math >{ > > > > >template < typename T > > class quaternion; > >template < > > class quaternion< float >; >template < > > class quaternion< double >; >template < > > class quaternion< long double >; > > > > > > >template < typename T > > class octonion; > >template < > > class octonion< float >; >template < > > class octonion< double >; >template < > > class octonion< long double >; ># 85 "/usr/include/boost/math_fwd.hpp" 3 4 > typedef boost::uintmax_t static_gcd_type; > > >template < static_gcd_type Value1, static_gcd_type Value2 > > struct static_gcd; >template < static_gcd_type Value1, static_gcd_type Value2 > > struct static_lcm; > > > > >template < typename IntegerType > > class gcd_evaluator; >template < typename IntegerType > > class lcm_evaluator; > > > > >} >} ># 19 "/usr/include/boost/math/common_factor_rt.hpp" 2 3 4 > > > ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 23 "/usr/include/boost/math/common_factor_rt.hpp" 2 3 4 > > > > > > > >namespace boost >{ >namespace math >{ > > > > >template < typename IntegerType > > IntegerType gcd( IntegerType const &a, IntegerType const &b ); > >template < typename IntegerType > > IntegerType lcm( IntegerType const &a, IntegerType const &b ); > > > > >template < typename IntegerType > >class gcd_evaluator >{ >public: > > typedef IntegerType result_type, first_argument_type, second_argument_type; > > > result_type operator ()( first_argument_type const &a, > second_argument_type const &b ) const; > >}; > > > > >template < typename IntegerType > >class lcm_evaluator >{ >public: > > typedef IntegerType result_type, first_argument_type, second_argument_type; > > > result_type operator ()( first_argument_type const &a, > second_argument_type const &b ) const; > >}; > > > > >namespace detail >{ > > template < typename RingType > > RingType > gcd_euclidean > ( > RingType a, > RingType b > ) > { > > > RingType const zero = static_cast<RingType>( 0 ); > > > > > > while ( true ) > { > if ( a == zero ) > return b; > b %= a; > > if ( b == zero ) > return a; > a %= b; > } > } > > > template < typename IntegerType > > inline > IntegerType > gcd_integer > ( > IntegerType const & a, > IntegerType const & b > ) > { > > IntegerType const zero = static_cast<IntegerType>( 0 ); > IntegerType const result = gcd_euclidean( a, b ); > > return ( result < zero ) ? static_cast<IntegerType>(-result) : result; > } > > > template < typename BuiltInUnsigned > > BuiltInUnsigned > gcd_binary > ( > BuiltInUnsigned u, > BuiltInUnsigned v > ) > { > if ( u && v ) > { > > unsigned shifts = 0; > > while ( !(u & 1u) && !(v & 1u) ) > { > ++shifts; > u >>= 1; > v >>= 1; > } > > > BuiltInUnsigned r[] = { u, v }; > unsigned which = static_cast<bool>( u & 1u ); > > > do > { > > > > > > > > while ( !(r[ which ] & 1u) ) > { > r[ which ] >>= 1; > } > > > > if ( r[!which] > r[which] ) > { > which ^= 1u; > } > > r[ which ] -= r[ !which ]; > } > while ( r[which] ); > > > return r[ !which ] << shifts; > } > else > { > > > > return u + v; > } > } > > > template < typename RingType > > inline > RingType > lcm_euclidean > ( > RingType const & a, > RingType const & b > ) > { > RingType const zero = static_cast<RingType>( 0 ); > RingType const temp = gcd_euclidean( a, b ); > > return ( temp != zero ) ? ( a / temp * b ) : zero; > } > > > template < typename IntegerType > > inline > IntegerType > lcm_integer > ( > IntegerType const & a, > IntegerType const & b > ) > { > > IntegerType const zero = static_cast<IntegerType>( 0 ); > IntegerType const result = lcm_euclidean( a, b ); > > return ( result < zero ) ? static_cast<IntegerType>(-result) : result; > } > > > > > template < typename T, bool IsSpecialized, bool IsSigned > > struct gcd_optimal_evaluator_helper_t > { > T operator ()( T const &a, T const &b ) > { > return gcd_euclidean( a, b ); > } > }; > > template < typename T > > struct gcd_optimal_evaluator_helper_t< T, true, true > > { > T operator ()( T const &a, T const &b ) > { > return gcd_integer( a, b ); > } > }; ># 278 "/usr/include/boost/math/common_factor_rt.hpp" 3 4 > template < typename T > > struct gcd_optimal_evaluator > { > T operator ()( T const &a, T const &b ) > { > typedef ::std::numeric_limits<T> limits_type; > > typedef gcd_optimal_evaluator_helper_t<T, > limits_type::is_specialized, limits_type::is_signed> helper_type; > > helper_type solver; > > return solver( a, b ); > } > }; ># 309 "/usr/include/boost/math/common_factor_rt.hpp" 3 4 > template < > struct gcd_optimal_evaluator<unsigned char> { unsigned char operator ()( unsigned char a, unsigned char b ) const { return gcd_binary( a, b ); } }; > template < > struct gcd_optimal_evaluator<unsigned short> { unsigned short operator ()( unsigned short a, unsigned short b ) const { return gcd_binary( a, b ); } }; > template < > struct gcd_optimal_evaluator<unsigned> { unsigned operator ()( unsigned a, unsigned b ) const { return gcd_binary( a, b ); } }; > template < > struct gcd_optimal_evaluator<unsigned long> { unsigned long operator ()( unsigned long a, unsigned long b ) const { return gcd_binary( a, b ); } }; > > > template < > struct gcd_optimal_evaluator<boost::ulong_long_type> { boost::ulong_long_type operator ()( boost::ulong_long_type a, boost::ulong_long_type b ) const { return gcd_binary( a, b ); } }; ># 333 "/usr/include/boost/math/common_factor_rt.hpp" 3 4 > template < > struct gcd_optimal_evaluator<signed char> { signed char operator ()( signed char a, signed char b ) const { unsigned char const a_abs = static_cast<unsigned char>( a < 0 ? -a : +a ), b_abs = static_cast<unsigned char>( b < 0 ? -b : +b ); return static_cast<signed char>( gcd_optimal_evaluator<unsigned char>()(a_abs, b_abs) ); } }; > template < > struct gcd_optimal_evaluator<short> { short operator ()( short a, short b ) const { unsigned short const a_abs = static_cast<unsigned short>( a < 0 ? -a : +a ), b_abs = static_cast<unsigned short>( b < 0 ? -b : +b ); return static_cast<short>( gcd_optimal_evaluator<unsigned short>()(a_abs, b_abs) ); } }; > template < > struct gcd_optimal_evaluator<int> { int operator ()( int a, int b ) const { unsigned const a_abs = static_cast<unsigned>( a < 0 ? -a : +a ), b_abs = static_cast<unsigned>( b < 0 ? -b : +b ); return static_cast<int>( gcd_optimal_evaluator<unsigned>()(a_abs, b_abs) ); } }; > template < > struct gcd_optimal_evaluator<long> { long operator ()( long a, long b ) const { unsigned long const a_abs = static_cast<unsigned long>( a < 0 ? -a : +a ), b_abs = static_cast<unsigned long>( b < 0 ? -b : +b ); return static_cast<long>( gcd_optimal_evaluator<unsigned long>()(a_abs, b_abs) ); } }; > > > template < > struct gcd_optimal_evaluator<char> { char operator ()( char a, char b ) const { unsigned char const a_abs = static_cast<unsigned char>( a < 0 ? -a : +a ), b_abs = static_cast<unsigned char>( b < 0 ? -b : +b ); return static_cast<char>( gcd_optimal_evaluator<unsigned char>()(a_abs, b_abs) ); } }; > > > > template < > struct gcd_optimal_evaluator<boost::long_long_type> { boost::long_long_type operator ()( boost::long_long_type a, boost::long_long_type b ) const { boost::ulong_long_type const a_abs = static_cast<boost::ulong_long_type>( a < 0 ? -a : +a ), b_abs = static_cast<boost::ulong_long_type>( b < 0 ? -b : +b ); return static_cast<boost::long_long_type>( gcd_optimal_evaluator<boost::ulong_long_type>()(a_abs, b_abs) ); } }; ># 352 "/usr/include/boost/math/common_factor_rt.hpp" 3 4 > template < typename T, bool IsSpecialized, bool IsSigned > > struct lcm_optimal_evaluator_helper_t > { > T operator ()( T const &a, T const &b ) > { > return lcm_euclidean( a, b ); > } > }; > > template < typename T > > struct lcm_optimal_evaluator_helper_t< T, true, true > > { > T operator ()( T const &a, T const &b ) > { > return lcm_integer( a, b ); > } > }; ># 404 "/usr/include/boost/math/common_factor_rt.hpp" 3 4 > template < typename T > > struct lcm_optimal_evaluator > { > T operator ()( T const &a, T const &b ) > { > typedef ::std::numeric_limits<T> limits_type; > > typedef lcm_optimal_evaluator_helper_t<T, > limits_type::is_specialized, limits_type::is_signed> helper_type; > > helper_type solver; > > return solver( a, b ); > } > }; ># 431 "/usr/include/boost/math/common_factor_rt.hpp" 3 4 > template < typename T > > inline > T > gcd_optimal > ( > T const & a, > T const & b > ) > { > gcd_optimal_evaluator<T> solver; > > return solver( a, b ); > } > > template < typename T > > inline > T > lcm_optimal > ( > T const & a, > T const & b > ) > { > lcm_optimal_evaluator<T> solver; > > return solver( a, b ); > } > >} > > > > >template < typename IntegerType > >inline >typename gcd_evaluator<IntegerType>::result_type >gcd_evaluator<IntegerType>::operator () >( > first_argument_type const & a, > second_argument_type const & b >) const >{ > return detail::gcd_optimal( a, b ); >} > > > > >template < typename IntegerType > >inline >typename lcm_evaluator<IntegerType>::result_type >lcm_evaluator<IntegerType>::operator () >( > first_argument_type const & a, > second_argument_type const & b >) const >{ > return detail::lcm_optimal( a, b ); >} > > > > >template < typename IntegerType > >inline >IntegerType >gcd >( > IntegerType const & a, > IntegerType const & b >) >{ > gcd_evaluator<IntegerType> solver; > > return solver( a, b ); >} > >template < typename IntegerType > >inline >IntegerType >lcm >( > IntegerType const & a, > IntegerType const & b >) >{ > lcm_evaluator<IntegerType> solver; > > return solver( a, b ); >} > > >} >} ># 26 "/usr/include/boost/chrono/io_v1/chrono_io.hpp" 2 3 4 ># 1 "/usr/include/boost/chrono/detail/scan_keyword.hpp" 1 3 4 ># 22 "/usr/include/boost/chrono/detail/scan_keyword.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 1 3 4 ># 19 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 20 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 2 3 4 > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 22 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 2 3 4 ># 1 "/usr/include/boost/interprocess/detail/utilities.hpp" 1 3 4 ># 21 "/usr/include/boost/interprocess/detail/utilities.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 22 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 > > ># 1 "/usr/include/boost/interprocess/interprocess_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/interprocess/interprocess_fwd.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 19 "/usr/include/boost/interprocess/interprocess_fwd.hpp" 2 3 4 ># 29 "/usr/include/boost/interprocess/interprocess_fwd.hpp" 3 4 >namespace boost{ >namespace intrusive{ >}} > >namespace boost{ >namespace interprocess{ >namespace bi = boost::intrusive; >}} ># 46 "/usr/include/boost/interprocess/interprocess_fwd.hpp" 3 4 >namespace boost { namespace interprocess { > > > > > >class permissions; > > > > > >class shared_memory_object; ># 68 "/usr/include/boost/interprocess/interprocess_fwd.hpp" 3 4 >class file_mapping; >class mapped_region; >class mapped_file; > > > > > >class null_mutex; > >class interprocess_mutex; >class interprocess_recursive_mutex; > >class named_mutex; >class named_recursive_mutex; > >class interprocess_semaphore; >class named_semaphore; > > > > > >struct mutex_family; >struct null_mutex_family; > > > > > >class barrier; >class interprocess_sharable_mutex; >class interprocess_condition; > > > > > >template <class Mutex> >class scoped_lock; > >template <class SharableMutex> >class sharable_lock; > >template <class UpgradableMutex> >class upgradable_lock; > > > > > >template<class T, class SegmentManager> >class allocator; > >template<class T, class SegmentManager, std::size_t NodesPerBlock = 64> >class node_allocator; > >template<class T, class SegmentManager, std::size_t NodesPerBlock = 64> >class private_node_allocator; > >template<class T, class SegmentManager, std::size_t NodesPerBlock = 64> >class cached_node_allocator; > >template<class T, class SegmentManager, std::size_t NodesPerBlock = 64, std::size_t MaxFreeBlocks = 2 > , unsigned char OverheadPercent = 5 >> >class adaptive_pool; > >template<class T, class SegmentManager, std::size_t NodesPerBlock = 64, std::size_t MaxFreeBlocks = 2 > , unsigned char OverheadPercent = 5 >> >class private_adaptive_pool; > >template<class T, class SegmentManager, std::size_t NodesPerBlock = 64, std::size_t MaxFreeBlocks = 2 > , unsigned char OverheadPercent = 5 >> >class cached_adaptive_pool; > > > > > > >static const std::size_t offset_type_alignment = 0; > >template <class T, class DifferenceType = std::ptrdiff_t, class OffsetType = std::size_t, std::size_t Alignment = offset_type_alignment> >class offset_ptr; > > > > > > >template<class MutexFamily, class VoidMutex = offset_ptr<void> > >class simple_seq_fit; > >template<class MutexFamily, class VoidMutex = offset_ptr<void>, std::size_t MemAlignment = 0> >class rbtree_best_fit; > > > > > >template<class IndexConfig> class flat_map_index; >template<class IndexConfig> class iset_index; >template<class IndexConfig> class iunordered_set_index; >template<class IndexConfig> class map_index; >template<class IndexConfig> class null_index; >template<class IndexConfig> class unordered_map_index; > > > > > >template <class CharType > ,class MemoryAlgorithm > ,template<class IndexConfig> class IndexType> >class segment_manager; > > > > > >template <class CharType > ,class MemoryAlgorithm > ,template<class IndexConfig> class IndexType> >class basic_managed_external_buffer; > >typedef basic_managed_external_buffer > <char > ,rbtree_best_fit<null_mutex_family> > ,iset_index> >managed_external_buffer; > >typedef basic_managed_external_buffer > <wchar_t > ,rbtree_best_fit<null_mutex_family> > ,iset_index> >wmanaged_external_buffer; > > > > > >template <class CharType > ,class MemoryAlgorithm > ,template<class IndexConfig> class IndexType> >class basic_managed_shared_memory; > >typedef basic_managed_shared_memory > <char > ,rbtree_best_fit<mutex_family> > ,iset_index> >managed_shared_memory; > >typedef basic_managed_shared_memory > <wchar_t > ,rbtree_best_fit<mutex_family> > ,iset_index> >wmanaged_shared_memory; ># 257 "/usr/include/boost/interprocess/interprocess_fwd.hpp" 3 4 >template <class CharType > ,class MemoryAlgorithm > ,template<class IndexConfig> class IndexType> >class basic_managed_xsi_shared_memory; > >typedef basic_managed_xsi_shared_memory > <char > ,rbtree_best_fit<mutex_family> > ,iset_index> >managed_xsi_shared_memory; > >typedef basic_managed_xsi_shared_memory > <wchar_t > ,rbtree_best_fit<mutex_family> > ,iset_index> >wmanaged_xsi_shared_memory; > > > > > > > >typedef basic_managed_shared_memory > <char > ,rbtree_best_fit<mutex_family, void*> > ,iset_index> >fixed_managed_shared_memory; > >typedef basic_managed_shared_memory > <wchar_t > ,rbtree_best_fit<mutex_family, void*> > ,iset_index> >wfixed_managed_shared_memory; > > > > > >template > <class CharType > ,class MemoryAlgorithm > ,template<class IndexConfig> class IndexType> >class basic_managed_heap_memory; > >typedef basic_managed_heap_memory > <char > ,rbtree_best_fit<null_mutex_family> > ,iset_index> >managed_heap_memory; > >typedef basic_managed_heap_memory > <wchar_t > ,rbtree_best_fit<null_mutex_family> > ,iset_index> >wmanaged_heap_memory; > > > > > >template > <class CharType > ,class MemoryAlgorithm > ,template<class IndexConfig> class IndexType> >class basic_managed_mapped_file; > >typedef basic_managed_mapped_file > <char > ,rbtree_best_fit<mutex_family> > ,iset_index> >managed_mapped_file; > >typedef basic_managed_mapped_file > <wchar_t > ,rbtree_best_fit<mutex_family> > ,iset_index> >wmanaged_mapped_file; > > > > > >class interprocess_exception; >class lock_exception; >class bad_alloc; > > > > > > >template <class CharT > ,class CharTraits = std::char_traits<CharT> > >class basic_bufferbuf; > >template <class CharT > ,class CharTraits = std::char_traits<CharT> > >class basic_ibufferstream; > >template <class CharT > ,class CharTraits = std::char_traits<CharT> > >class basic_obufferstream; > >template <class CharT > ,class CharTraits = std::char_traits<CharT> > >class basic_bufferstream; > > > > > >template <class CharVector > ,class CharTraits = std::char_traits<typename CharVector::value_type> > >class basic_vectorbuf; > >template <class CharVector > ,class CharTraits = std::char_traits<typename CharVector::value_type> > >class basic_ivectorstream; > >template <class CharVector > ,class CharTraits = std::char_traits<typename CharVector::value_type> > >class basic_ovectorstream; > >template <class CharVector > ,class CharTraits = std::char_traits<typename CharVector::value_type> > >class basic_vectorstream; > > > > > >template<class T, class Deleter> >class scoped_ptr; > >template<class T, class VoidPointer> >class intrusive_ptr; > >template<class T, class VoidAllocator, class Deleter> >class shared_ptr; > >template<class T, class VoidAllocator, class Deleter> >class weak_ptr; > > > > > >template<class VoidPointer> >class message_queue_t; > >typedef message_queue_t<offset_ptr<void> > message_queue; > >}} > > > > > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 417 "/usr/include/boost/interprocess/interprocess_fwd.hpp" 2 3 4 ># 25 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 ># 1 "/usr/include/boost/move/move.hpp" 1 3 4 ># 20 "/usr/include/boost/move/move.hpp" 3 4 ># 1 "/usr/include/boost/move/detail/config_begin.hpp" 1 3 4 ># 21 "/usr/include/boost/move/move.hpp" 2 3 4 > ># 1 "/usr/include/boost/move/iterator.hpp" 1 3 4 ># 17 "/usr/include/boost/move/iterator.hpp" 3 4 ># 1 "/usr/include/boost/move/detail/config_begin.hpp" 1 3 4 ># 18 "/usr/include/boost/move/iterator.hpp" 2 3 4 > > > >namespace boost { ># 34 "/usr/include/boost/move/iterator.hpp" 3 4 >template <class It> >class move_iterator >{ > public: > typedef It iterator_type; > typedef typename std::iterator_traits<iterator_type>::value_type value_type; > > typedef value_type && reference; > > > > > > > typedef It pointer; > typedef typename std::iterator_traits<iterator_type>::difference_type difference_type; > typedef typename std::iterator_traits<iterator_type>::iterator_category iterator_category; > > move_iterator() > {} > > explicit move_iterator(It i) > : m_it(i) > {} > > template <class U> > move_iterator(const move_iterator<U>& u) > : m_it(u.base()) > {} > > iterator_type base() const > { return m_it; } > > reference operator*() const > { > > > > return ::boost::move(*m_it); > > } > > pointer operator->() const > { return m_it; } > > move_iterator& operator++() > { ++m_it; return *this; } > > move_iterator<iterator_type> operator++(int) > { move_iterator<iterator_type> tmp(*this); ++(*this); return tmp; } > > move_iterator& operator--() > { --m_it; return *this; } > > move_iterator<iterator_type> operator--(int) > { move_iterator<iterator_type> tmp(*this); --(*this); return tmp; } > > move_iterator<iterator_type> operator+ (difference_type n) const > { return move_iterator<iterator_type>(m_it + n); } > > move_iterator& operator+=(difference_type n) > { m_it += n; return *this; } > > move_iterator<iterator_type> operator- (difference_type n) const > { return move_iterator<iterator_type>(m_it - n); } > > move_iterator& operator-=(difference_type n) > { m_it -= n; return *this; } > > reference operator[](difference_type n) const > { > > > > return ::boost::move(m_it[n]); > > } > > friend bool operator==(const move_iterator& x, const move_iterator& y) > { return x.base() == y.base(); } > > friend bool operator!=(const move_iterator& x, const move_iterator& y) > { return x.base() != y.base(); } > > friend bool operator< (const move_iterator& x, const move_iterator& y) > { return x.base() < y.base(); } > > friend bool operator<=(const move_iterator& x, const move_iterator& y) > { return x.base() <= y.base(); } > > friend bool operator> (const move_iterator& x, const move_iterator& y) > { return x.base() > y.base(); } > > friend bool operator>=(const move_iterator& x, const move_iterator& y) > { return x.base() >= y.base(); } > > friend difference_type operator-(const move_iterator& x, const move_iterator& y) > { return x.base() - y.base(); } > > friend move_iterator operator+(difference_type n, const move_iterator& x) > { return move_iterator(x.base() + n); } > > private: > It m_it; >}; > > >namespace move_detail { > >template <class I> >struct is_move_iterator > : public ::boost::move_detail::integral_constant<bool, false> >{ >}; > >template <class I> >struct is_move_iterator< ::boost::move_iterator<I> > > : public ::boost::move_detail::integral_constant<bool, true> >{ >}; > >} ># 165 "/usr/include/boost/move/iterator.hpp" 3 4 >template<class It> >inline move_iterator<It> make_move_iterator(const It &it) >{ return move_iterator<It>(it); } ># 178 "/usr/include/boost/move/iterator.hpp" 3 4 >template <typename C> >class back_move_insert_iterator > : public std::iterator<std::output_iterator_tag, void, void, void, void> >{ > C* container_m; > > public: > typedef C container_type; > typedef typename C::value_type value_type; > typedef typename C::reference reference; > > explicit back_move_insert_iterator(C& x) : container_m(&x) { } > > back_move_insert_iterator& operator=(reference x) > { container_m->push_back(boost::move(x)); return *this; } > > back_move_insert_iterator& operator=(value_type && x) > { reference rx = x; return this->operator=(rx); } > > back_move_insert_iterator& operator*() { return *this; } > back_move_insert_iterator& operator++() { return *this; } > back_move_insert_iterator& operator++(int) { return *this; } >}; > > > >template <typename C> >inline back_move_insert_iterator<C> back_move_inserter(C& x) >{ > return back_move_insert_iterator<C>(x); >} ># 218 "/usr/include/boost/move/iterator.hpp" 3 4 >template <typename C> >class front_move_insert_iterator > : public std::iterator<std::output_iterator_tag, void, void, void, void> >{ > C* container_m; > >public: > typedef C container_type; > typedef typename C::value_type value_type; > typedef typename C::reference reference; > > explicit front_move_insert_iterator(C& x) : container_m(&x) { } > > front_move_insert_iterator& operator=(reference x) > { container_m->push_front(boost::move(x)); return *this; } > > front_move_insert_iterator& operator=(value_type && x) > { reference rx = x; return this->operator=(rx); } > > front_move_insert_iterator& operator*() { return *this; } > front_move_insert_iterator& operator++() { return *this; } > front_move_insert_iterator& operator++(int) { return *this; } >}; > > > >template <typename C> >inline front_move_insert_iterator<C> front_move_inserter(C& x) >{ > return front_move_insert_iterator<C>(x); >} > > > > > > >template <typename C> >class move_insert_iterator > : public std::iterator<std::output_iterator_tag, void, void, void, void> >{ > C* container_m; > typename C::iterator pos_; > > public: > typedef C container_type; > typedef typename C::value_type value_type; > typedef typename C::reference reference; > > explicit move_insert_iterator(C& x, typename C::iterator pos) > : container_m(&x), pos_(pos) > {} > > move_insert_iterator& operator=(reference x) > { > pos_ = container_m->insert(pos_, ::boost::move(x)); > ++pos_; > return *this; > } > > move_insert_iterator& operator=(value_type && x) > { reference rx = x; return this->operator=(rx); } > > move_insert_iterator& operator*() { return *this; } > move_insert_iterator& operator++() { return *this; } > move_insert_iterator& operator++(int) { return *this; } >}; > > > >template <typename C> >inline move_insert_iterator<C> move_inserter(C& x, typename C::iterator it) >{ > return move_insert_iterator<C>(x, it); >} > >} > ># 1 "/usr/include/boost/move/detail/config_end.hpp" 1 3 4 ># 297 "/usr/include/boost/move/iterator.hpp" 2 3 4 ># 23 "/usr/include/boost/move/move.hpp" 2 3 4 > ># 1 "/usr/include/boost/move/algorithm.hpp" 1 3 4 ># 17 "/usr/include/boost/move/algorithm.hpp" 3 4 ># 1 "/usr/include/boost/move/detail/config_begin.hpp" 1 3 4 ># 18 "/usr/include/boost/move/algorithm.hpp" 2 3 4 ># 26 "/usr/include/boost/move/algorithm.hpp" 3 4 >namespace boost { ># 45 "/usr/include/boost/move/algorithm.hpp" 3 4 > template <typename I, > typename O> > O move(I f, I l, O result) > { > while (f != l) { > *result = ::boost::move(*f); > ++f; ++result; > } > return result; > } ># 72 "/usr/include/boost/move/algorithm.hpp" 3 4 > template <typename I, > typename O> > O move_backward(I f, I l, O result) > { > while (f != l) { > --l; --result; > *result = ::boost::move(*l); > } > return result; > } ># 103 "/usr/include/boost/move/algorithm.hpp" 3 4 >template > <typename I, > typename F> >F uninitialized_move(I f, I l, F r > > > > ) >{ > typedef typename std::iterator_traits<I>::value_type input_value_type; > > F back = r; > { try{ > while (f != l) { > void * const addr = static_cast<void*>(::boost::move_detail::addressof(*r)); > ::new(addr) input_value_type(::boost::move(*f)); > ++f; ++r; > } > } > catch(...){ > for (; back != r; ++back){ > back->~input_value_type(); > } > throw;; > } > } > return r; >} ># 150 "/usr/include/boost/move/algorithm.hpp" 3 4 >namespace move_detail { > >template ><typename I, >typename F> >inline F uninitialized_move_move_iterator(I f, I l, F r > >) >{ > return ::boost::uninitialized_move(f, l, r); >} ># 171 "/usr/include/boost/move/algorithm.hpp" 3 4 >} > >template ><typename I, >typename F> >inline F uninitialized_copy_or_move(I f, I l, F r, > typename ::boost::move_detail::enable_if< move_detail::is_move_iterator<I> >::type* = 0) >{ > return ::boost::move_detail::uninitialized_move_move_iterator(f, l, r); >} > > > > > > > >namespace move_detail { > >template ><typename I, >typename F> >inline F move_move_iterator(I f, I l, F r > >) >{ > return ::boost::move(f, l, r); >} ># 210 "/usr/include/boost/move/algorithm.hpp" 3 4 >} > >template ><typename I, >typename F> >inline F copy_or_move(I f, I l, F r, > typename ::boost::move_detail::enable_if< move_detail::is_move_iterator<I> >::type* = 0) >{ > return ::boost::move_detail::move_move_iterator(f, l, r); >} ># 235 "/usr/include/boost/move/algorithm.hpp" 3 4 >template ><typename I, >typename F> >inline F uninitialized_copy_or_move(I f, I l, F r > > ,typename ::boost::move_detail::disable_if< move_detail::is_move_iterator<I> >::type* = 0 > > ) >{ > return std::uninitialized_copy(f, l, r); >} ># 258 "/usr/include/boost/move/algorithm.hpp" 3 4 >template ><typename I, >typename F> >inline F copy_or_move(I f, I l, F r > > ,typename ::boost::move_detail::disable_if< move_detail::is_move_iterator<I> >::type* = 0 > > ) >{ > return std::copy(f, l, r); >} > >} > ># 1 "/usr/include/boost/move/detail/config_end.hpp" 1 3 4 ># 273 "/usr/include/boost/move/algorithm.hpp" 2 3 4 ># 25 "/usr/include/boost/move/move.hpp" 2 3 4 ># 1 "/usr/include/boost/move/detail/config_end.hpp" 1 3 4 ># 26 "/usr/include/boost/move/move.hpp" 2 3 4 ># 26 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 > ># 1 "/usr/include/boost/interprocess/detail/min_max.hpp" 1 3 4 ># 20 "/usr/include/boost/interprocess/detail/min_max.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 21 "/usr/include/boost/interprocess/detail/min_max.hpp" 2 3 4 > > >namespace boost { >namespace interprocess { > >template<class T> >const T &max_value(const T &a, const T &b) >{ return a > b ? a : b; } > >template<class T> >const T &min_value(const T &a, const T &b) >{ return a < b ? a : b; } > >} >} > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 38 "/usr/include/boost/interprocess/detail/min_max.hpp" 2 3 4 ># 28 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 ># 1 "/usr/include/boost/interprocess/detail/type_traits.hpp" 1 3 4 ># 20 "/usr/include/boost/interprocess/detail/type_traits.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 21 "/usr/include/boost/interprocess/detail/type_traits.hpp" 2 3 4 > >namespace boost { >namespace interprocess { >namespace ipcdetail { > >struct nat{}; > >template<class T> >struct remove_reference >{ > typedef T type; >}; > >template<class T> >struct remove_reference<T&> >{ > typedef T type; >}; > >template<class T> >struct is_reference >{ > static const bool value = false; >}; > >template<class T> >struct is_reference<T&> >{ > static const bool value = true; >}; > >template<class T> >struct is_pointer >{ > static const bool value = false; >}; > >template<class T> >struct is_pointer<T*> >{ > static const bool value = true; >}; > >template <typename T> >struct add_reference >{ > typedef T& type; >}; > >template<class T> >struct add_reference<T&> >{ > typedef T& type; >}; > >template<> >struct add_reference<void> >{ > typedef nat &type; >}; > >template<> >struct add_reference<const void> >{ > typedef const nat &type; >}; > >template <class T> >struct add_const_reference >{ typedef const T &type; }; > >template <class T> >struct add_const_reference<T&> >{ typedef T& type; }; > >template<class T> >struct remove_const >{ > typedef T type; >}; > >template<class T> >struct remove_const<const T> >{ > typedef T type; >}; > >template<class T> >struct remove_volatile >{ > typedef T type; >}; > >template<class T> >struct remove_volatile<volatile T> >{ > typedef T type; >}; > >template<class T> >struct remove_const_volatile >{ > typedef typename remove_const<typename remove_volatile<T>::type>::type type; >}; > >template <typename T, typename U> >struct is_same >{ > typedef char yes_type; > struct no_type > { > char padding[8]; > }; > > template <typename V> > 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<class T, class U> >struct is_cv_same >{ > static const bool value = is_same< typename remove_const_volatile<T>::type > , typename remove_const_volatile<U>::type >::value; >}; > >} >} >} > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 157 "/usr/include/boost/interprocess/detail/type_traits.hpp" 2 3 4 ># 29 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 ># 1 "/usr/include/boost/interprocess/detail/transform_iterator.hpp" 1 3 4 ># 21 "/usr/include/boost/interprocess/detail/transform_iterator.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 22 "/usr/include/boost/interprocess/detail/transform_iterator.hpp" 2 3 4 > > > > > > > >namespace boost { >namespace interprocess { > >template <class PseudoReference> >struct operator_arrow_proxy >{ > operator_arrow_proxy(const PseudoReference &px) > : m_value(px) > {} > > PseudoReference* operator->() const { return &m_value; } > > > > mutable PseudoReference m_value; >}; > >template <class T> >struct operator_arrow_proxy<T&> >{ > operator_arrow_proxy(T &px) > : m_value(px) > {} > > T* operator->() const { return const_cast<T*>(&m_value); } > > > > T &m_value; >}; > >template <class Iterator, class UnaryFunction> >class transform_iterator > : public UnaryFunction > , public std::iterator > < typename Iterator::iterator_category > , typename ipcdetail::remove_reference<typename UnaryFunction::result_type>::type > , typename Iterator::difference_type > , operator_arrow_proxy<typename UnaryFunction::result_type> > , 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() > {} > > > 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); } > > > 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<typename UnaryFunction::result_type> > operator->() const > { return operator_arrow_proxy<typename UnaryFunction::result_type>(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 <class Iterator, class UnaryFunc> >transform_iterator<Iterator, UnaryFunc> >make_transform_iterator(Iterator it, UnaryFunc fun) >{ > return transform_iterator<Iterator, UnaryFunc>(it, fun); >} > >} >} > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 193 "/usr/include/boost/interprocess/detail/transform_iterator.hpp" 2 3 4 ># 30 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 ># 1 "/usr/include/boost/interprocess/detail/mpl.hpp" 1 3 4 ># 22 "/usr/include/boost/interprocess/detail/mpl.hpp" 3 4 >namespace boost { >namespace interprocess { >namespace ipcdetail { > >template <class T, T val> >struct integral_constant >{ > static const T value = val; > typedef integral_constant<T,val> type; >}; > >template< bool C_ > >struct bool_ : integral_constant<bool, C_> >{ > static const bool value = C_; >}; > >typedef bool_<true> true_; >typedef bool_<false> false_; > >typedef true_ true_type; >typedef false_ false_type; > >typedef char yes_type; >struct no_type >{ > char padding[8]; >}; > >template <bool B, class T = void> >struct enable_if_c { > typedef T type; >}; > >template <class T> >struct enable_if_c<false, T> {}; > >template <class Cond, class T = void> >struct enable_if : public enable_if_c<Cond::value, T> {}; > >template <class Cond, class T = void> >struct disable_if : public enable_if_c<!Cond::value, T> {}; > >template <class T, class U> >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<false,T1,T2> >{ > typedef T2 type; >}; > >template< > typename T1 > , typename T2 > , typename T3 > > >struct if_ >{ > typedef typename if_c<0 != T1::value, T2, T3>::type type; >}; > > >template <class Pair> >struct select1st > >{ > template<class OtherPair> > 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; } >}; > > >template <class T> >struct identity > >{ > typedef T type; > const T& operator()(const T& x) const > { return x; } >}; > >template<std::size_t S> >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; >}; > >} >} >} ># 31 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 ># 1 "/usr/include/boost/interprocess/containers/version_type.hpp" 1 3 4 ># 18 "/usr/include/boost/interprocess/containers/version_type.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 19 "/usr/include/boost/interprocess/containers/version_type.hpp" 2 3 4 ># 1 "/usr/include/boost/container/detail/version_type.hpp" 1 3 4 ># 19 "/usr/include/boost/container/detail/version_type.hpp" 3 4 ># 1 "/usr/include/boost/container/detail/config_begin.hpp" 1 3 4 ># 20 "/usr/include/boost/container/detail/version_type.hpp" 2 3 4 > ># 1 "/usr/include/boost/container/detail/mpl.hpp" 1 3 4 ># 22 "/usr/include/boost/container/detail/mpl.hpp" 3 4 >namespace boost { >namespace container { >namespace container_detail { > >template <class T, T val> >struct integral_constant >{ > static const T value = val; > typedef integral_constant<T,val> type; >}; > >template< bool C_ > >struct bool_ : integral_constant<bool, C_> >{ > static const bool value = C_; > operator bool() const { return bool_::value; } >}; > >typedef bool_<true> true_; >typedef bool_<false> false_; > >typedef true_ true_type; >typedef false_ false_type; > >typedef char yes_type; >struct no_type >{ > char padding[8]; >}; > >template <bool B, class T = void> >struct enable_if_c { > typedef T type; >}; > >template <class T> >struct enable_if_c<false, T> {}; > >template <class Cond, class T = void> >struct enable_if : public enable_if_c<Cond::value, T> {}; > >template <class Cond, class T = void> >struct disable_if : public enable_if_c<!Cond::value, T> {}; > >template <bool B, class T = void> >struct disable_if_c : public enable_if_c<!B, T> {}; > >template <class T, class U> >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<false,T1,T2> >{ > typedef T2 type; >}; > >template< > typename T1 > , typename T2 > , typename T3 > > >struct if_ >{ > typedef typename if_c<0 != T1::value, T2, T3>::type type; >}; > > >template <class Pair> >struct select1st > >{ > template<class OtherPair> > 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; } >}; > > >template <class T> >struct identity > >{ > typedef T type; > const T& operator()(const T& x) const > { return x; } >}; > >template<std::size_t S> >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 <typename T> struct unvoid { typedef T type; }; >template <> struct unvoid<void> { struct type { }; }; >template <> struct unvoid<const void> { struct type { }; }; > >} >} >} ># 22 "/usr/include/boost/container/detail/version_type.hpp" 2 3 4 ># 1 "/usr/include/boost/container/detail/type_traits.hpp" 1 3 4 ># 22 "/usr/include/boost/container/detail/type_traits.hpp" 3 4 ># 1 "/usr/include/boost/container/detail/config_begin.hpp" 1 3 4 ># 23 "/usr/include/boost/container/detail/type_traits.hpp" 2 3 4 > > > >namespace boost { >namespace container { >namespace container_detail { > >struct nat{}; > >template <typename U> >struct LowPriorityConversion >{ > > LowPriorityConversion(const U&) { } >}; > > > >template <typename T> struct alignment_of; > >template <typename T> >struct alignment_of_hack >{ > char c; > T t; > alignment_of_hack(); >}; > >template <unsigned A, unsigned S> >struct alignment_logic >{ > enum{ value = A < S ? A : S }; >}; > >template< typename T > >struct alignment_of >{ > enum{ value = alignment_logic > < sizeof(alignment_of_hack<T>) - sizeof(T) > , sizeof(T)>::value }; >}; > > >union max_align >{ > char char_; > short short_; > int int_; > long long_; > > long long long_long_; > > float float_; > double double_; > long double long_double_; > void * void_ptr_; >}; > >template<class T> >struct remove_reference >{ > typedef T type; >}; > >template<class T> >struct remove_reference<T&> >{ > typedef T type; >}; > > > >template<class T> >struct remove_reference<T&&> >{ > typedef T type; >}; ># 111 "/usr/include/boost/container/detail/type_traits.hpp" 3 4 >template<class T> >struct is_reference >{ > enum { value = false }; >}; > >template<class T> >struct is_reference<T&> >{ > enum { value = true }; >}; > >template<class T> >struct is_pointer >{ > enum { value = false }; >}; > >template<class T> >struct is_pointer<T*> >{ > enum { value = true }; >}; > >template <typename T> >struct add_reference >{ > typedef T& type; >}; > >template<class T> >struct add_reference<T&> >{ > typedef T& type; >}; > >template<> >struct add_reference<void> >{ > typedef nat &type; >}; > >template<> >struct add_reference<const void> >{ > typedef const nat &type; >}; > >template <class T> >struct add_const_reference >{ typedef const T &type; }; > >template <class T> >struct add_const_reference<T&> >{ typedef T& type; }; > >template <typename T, typename U> >struct is_same >{ > typedef char yes_type; > struct no_type > { > char padding[8]; > }; > > template <typename V> > 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<class T> >struct remove_const >{ > typedef T type; >}; > >template<class T> >struct remove_const< const T> >{ > typedef T type; >}; > >template<class T> >struct remove_ref_const >{ > typedef typename remove_const< typename remove_reference<T>::type >::type type; >}; > >} >} >} > ># 1 "/usr/include/boost/container/detail/config_end.hpp" 1 3 4 ># 209 "/usr/include/boost/container/detail/type_traits.hpp" 2 3 4 ># 23 "/usr/include/boost/container/detail/version_type.hpp" 2 3 4 > >namespace boost{ >namespace container { >namespace container_detail { > > > >template <class T, unsigned V> >struct version_type > : public container_detail::integral_constant<unsigned, V> >{ > typedef T type; > > version_type(const version_type<T, 0>&); >}; > >namespace impl{ > >template <class T, > bool = container_detail::is_convertible<version_type<T, 0>, typename T::version>::value> >struct extract_version >{ > static const unsigned value = 1; >}; > >template <class T> >struct extract_version<T, true> >{ > static const unsigned value = T::version::value; >}; > >template <class T> >struct has_version >{ > private: > struct two {char _[2];}; > template <class U> static two test(...); > template <class U> static char test(const typename U::version*); > public: > static const bool value = sizeof(test<T>(0)) == 1; > void dummy(){} >}; > >template <class T, bool = has_version<T>::value> >struct version >{ > static const unsigned value = 1; >}; > >template <class T> >struct version<T, true> >{ > static const unsigned value = extract_version<T>::value; >}; > >} > >template <class T> >struct version > : public container_detail::integral_constant<unsigned, impl::version<T>::value> >{ >}; > >} >} >} > ># 1 "/usr/include/boost/container/detail/config_end.hpp" 1 3 4 ># 91 "/usr/include/boost/container/detail/version_type.hpp" 2 3 4 ># 20 "/usr/include/boost/interprocess/containers/version_type.hpp" 2 3 4 > >namespace boost { >namespace interprocess { > >using boost::container::container_detail::version_type; >using boost::container::container_detail::version; > >} >} > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 31 "/usr/include/boost/interprocess/containers/version_type.hpp" 2 3 4 ># 32 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 ># 1 "/usr/include/boost/intrusive/pointer_traits.hpp" 1 3 4 ># 24 "/usr/include/boost/intrusive/pointer_traits.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/config_begin.hpp" 1 3 4 ># 25 "/usr/include/boost/intrusive/pointer_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/intrusive/detail/workaround.hpp" 1 3 4 ># 14 "/usr/include/boost/intrusive/detail/workaround.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/config_begin.hpp" 1 3 4 ># 15 "/usr/include/boost/intrusive/detail/workaround.hpp" 2 3 4 ># 24 "/usr/include/boost/intrusive/detail/workaround.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/config_end.hpp" 1 3 4 ># 25 "/usr/include/boost/intrusive/detail/workaround.hpp" 2 3 4 ># 26 "/usr/include/boost/intrusive/pointer_traits.hpp" 2 3 4 ># 1 "/usr/include/boost/intrusive/detail/memory_util.hpp" 1 3 4 ># 24 "/usr/include/boost/intrusive/detail/memory_util.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/config_begin.hpp" 1 3 4 ># 25 "/usr/include/boost/intrusive/detail/memory_util.hpp" 2 3 4 > ># 1 "/usr/include/boost/intrusive/detail/mpl.hpp" 1 3 4 ># 16 "/usr/include/boost/intrusive/detail/mpl.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/config_begin.hpp" 1 3 4 ># 17 "/usr/include/boost/intrusive/detail/mpl.hpp" 2 3 4 > > >namespace boost { >namespace intrusive { >namespace detail { > >typedef char one; >struct two {one _[2];}; > >template< bool C_ > >struct bool_ >{ > static const bool value = C_; >}; > >typedef bool_<true> true_; >typedef bool_<false> false_; > >typedef true_ true_type; >typedef false_ false_type; > >typedef char yes_type; >struct no_type >{ > char padding[8]; >}; > >template <bool B, class T = void> >struct enable_if_c { > typedef T type; >}; > >template <class T> >struct enable_if_c<false, T> {}; > >template <class Cond, class T = void> >struct enable_if : public enable_if_c<Cond::value, T>{}; > >template<class F, class Param> >struct apply >{ > typedef typename F::template apply<Param>::type type; >}; > >template <class T, class U> >class is_convertible >{ > typedef char true_t; > class false_t { char dummy[2]; }; > static true_t dispatch(U); > static false_t dispatch(...); > static const 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<false,T1,T2> >{ > typedef T2 type; >}; > >template< > typename C > , typename T1 > , typename T2 > > >struct if_ >{ > typedef typename if_c<0 != C::value, T1, T2>::type type; >}; > >template< > bool C > , typename F1 > , typename F2 > > >struct eval_if_c > : if_c<C,F1,F2>::type >{}; > >template< > typename C > , typename T1 > , typename T2 > > >struct eval_if > : if_<C,T1,T2>::type >{}; > > >template <class T> >struct identity >{ > typedef T type; >}; ># 137 "/usr/include/boost/intrusive/detail/mpl.hpp" 3 4 >template <typename T> >struct is_unary_or_binary_function_impl >{ static const bool value = false; }; > > > > > >template <typename R> >struct is_unary_or_binary_function_impl<R (*)()> >{ static const bool value = true; }; > >template <typename R> >struct is_unary_or_binary_function_impl<R (*)(...)> >{ static const bool value = true; }; ># 181 "/usr/include/boost/intrusive/detail/mpl.hpp" 3 4 >template <typename R, class T0> >struct is_unary_or_binary_function_impl<R (*)(T0)> >{ static const bool value = true; }; > >template <typename R, class T0> >struct is_unary_or_binary_function_impl<R (*)(T0...)> >{ static const bool value = true; }; ># 217 "/usr/include/boost/intrusive/detail/mpl.hpp" 3 4 >template <typename R, class T0, class T1> >struct is_unary_or_binary_function_impl<R (*)(T0, T1)> >{ static const bool value = true; }; > >template <typename R, class T0, class T1> >struct is_unary_or_binary_function_impl<R (*)(T0, T1...)> >{ static const bool value = true; }; ># 248 "/usr/include/boost/intrusive/detail/mpl.hpp" 3 4 >template <typename T> >struct is_unary_or_binary_function_impl<T&> >{ static const bool value = false; }; > >template<typename T> >struct is_unary_or_binary_function >{ static const bool value = is_unary_or_binary_function_impl<T>::value; }; > > > >template <typename T> struct alignment_of; > >template <typename T> >struct alignment_of_hack >{ > char c; > T t; > alignment_of_hack(); >}; > >template <unsigned A, unsigned S> >struct alignment_logic >{ > static const std::size_t value = A < S ? A : S; >}; > >template< typename T > >struct alignment_of >{ > static const std::size_t value = alignment_logic > < sizeof(alignment_of_hack<T>) - sizeof(T) > , sizeof(T) > >::value; >}; > >template <typename T, typename U> >struct is_same >{ > static const bool value = false; >}; > >template <typename T> >struct is_same<T, T> >{ > static const bool value = true; >}; > >template<typename T> >struct add_const >{ typedef const T type; }; > >template<typename T> >struct remove_const >{ typedef T type; }; > >template<typename T> >struct remove_const<const T> >{ typedef T type; }; > >template<typename T> >struct remove_cv >{ typedef T type; }; > >template<typename T> >struct remove_cv<const T> >{ typedef T type; }; > >template<typename T> >struct remove_cv<const volatile T> >{ typedef T type; }; > >template<typename T> >struct remove_cv<volatile T> >{ typedef T type; }; > >template<class T> >struct remove_reference >{ > typedef T type; >}; > >template<class T> >struct remove_reference<T&> >{ > typedef T type; >}; > >template<class Class> >class is_empty_class >{ > template <typename T> > struct empty_helper_t1 : public T > { > empty_helper_t1(); > int i[256]; > }; > > struct empty_helper_t2 > { int i[256]; }; > > public: > static const bool value = sizeof(empty_helper_t1<Class>) == sizeof(empty_helper_t2); >}; > >template<std::size_t S> >struct ls_zeros >{ > static const std::size_t value = (S & std::size_t(1)) ? 0 : (1 + 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; >}; > >} >} >} > ># 1 "/usr/include/boost/intrusive/detail/config_end.hpp" 1 3 4 ># 375 "/usr/include/boost/intrusive/detail/mpl.hpp" 2 3 4 ># 27 "/usr/include/boost/intrusive/detail/memory_util.hpp" 2 3 4 ># 1 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 1 3 4 ># 18 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/config_begin.hpp" 1 3 4 ># 19 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 2 3 4 > > ># 1 "/usr/include/boost/preprocessor/iteration/local.hpp" 1 3 4 ># 22 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/punctuation/paren_if.hpp" 1 3 4 ># 23 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/control/expr_if.hpp" 1 3 4 ># 25 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/preprocessor/repetition/enum_trailing.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/repetition/enum_trailing.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/repetition/enum_trailing.hpp" 2 3 4 ># 30 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/repetition/enum_shifted.hpp" 1 3 4 ># 22 "/usr/include/boost/preprocessor/repetition/enum_shifted.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 23 "/usr/include/boost/preprocessor/repetition/enum_shifted.hpp" 2 3 4 ># 32 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/logical/not.hpp" 1 3 4 ># 34 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 2 3 4 ># 50 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/config_end.hpp" 1 3 4 ># 51 "/usr/include/boost/intrusive/detail/preprocessor.hpp" 2 3 4 ># 28 "/usr/include/boost/intrusive/detail/memory_util.hpp" 2 3 4 > >namespace boost { >namespace intrusive { >namespace detail { > >template <typename T> >inline T* addressof(T& obj) >{ > return static_cast<T*> > (static_cast<void*> > (const_cast<char*> > (&reinterpret_cast<const char&>(obj)) > ) > ); >} > >template <typename T> struct unvoid { typedef T type; }; >template <> struct unvoid<void> { struct type { }; }; >template <> struct unvoid<const void> { struct type { }; }; > >template <typename T> struct unvoid_ref { typedef T &type; }; >template <> struct unvoid_ref<void> { struct type_impl { }; typedef type_impl & type; }; >template <> struct unvoid_ref<const void> { struct type_impl { }; typedef type_impl & type; }; > >template <typename T> >struct LowPriorityConversion >{ > > LowPriorityConversion(const T&) { } >}; ># 114 "/usr/include/boost/intrusive/detail/memory_util.hpp" 3 4 >}}} > ># 1 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 1 3 4 ># 18 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/config_begin.hpp" 1 3 4 ># 19 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 2 3 4 ># 33 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 > 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; > struct no_type{ char dummy[2]; }; > > template<typename T> > no_type is_private_type(T const &); > yes_type is_private_type(private_type const &); > > } > ># 1 "/usr/include/boost/intrusive/detail/config_end.hpp" 1 3 4 ># 56 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 2 3 4 ># 117 "/usr/include/boost/intrusive/detail/memory_util.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 25 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 27 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 1 3 4 ># 79 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 > namespace boost { namespace intrusive { namespace detail { > > template <typename Type> > class has_member_function_named_pointer_to > { > struct BaseMixin > { > void pointer_to(); > }; > > struct Base : public ::boost::intrusive::detail::remove_cv<Type>::type, public BaseMixin { Base(); }; > template <typename T, T t> class Helper{}; > > template <typename U> > static boost_intrusive_has_member_function_callable_with::no_type deduce > (U*, Helper<void (BaseMixin::*)(), &U::pointer_to>* = 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))); > }; ># 188 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 > template<typename Fun, bool HasFunc, class ...Args> > struct has_member_function_callable_with_pointer_to_impl; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_pointer_to_impl > <Fun, false, Args...> > { > static const bool value = false; > }; > > > template< class F > , std::size_t N = > sizeof((boost::move_detail::declval<F>(). > pointer_to (), 0))> > struct zeroarg_checker_pointer_to > { > boost_intrusive_has_member_function_callable_with::yes_type dummy; > zeroarg_checker_pointer_to(int); > }; > > > > template<class F> > struct zeroarg_checker_pointer_to<F, 0> > { > boost_intrusive_has_member_function_callable_with::no_type dummy; > zeroarg_checker_pointer_to(int); > }; > > template<typename Fun> > struct has_member_function_callable_with_pointer_to_impl > <Fun, true> > { > template<class U> > static zeroarg_checker_pointer_to > <U> Test(zeroarg_checker_pointer_to<U>*); > > template <class U> > 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<typename Fun, class ...DontCares> > struct funwrap_pointer_to > : Fun > { > funwrap_pointer_to(); > using Fun::pointer_to; > > boost_intrusive_has_member_function_callable_with::private_type > pointer_to > ( DontCares...) const; > }; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_pointer_to_impl > <Fun, true , Args...> > { > template<class T> > struct make_dontcare > { > typedef boost_intrusive_has_member_function_callable_with::dont_care type; > }; > > typedef funwrap_pointer_to > <Fun, typename make_dontcare<Args>::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 >(). > pointer_to > ( ::boost::move_detail::declval<Args>()... ), 0) ) > ) > ); > }; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_pointer_to > > : public has_member_function_callable_with_pointer_to_impl > > < Fun > , has_member_function_named_pointer_to > <Fun>::value > , Args... > > {}; > > > > }}} ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 1 3 4 ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 123 "/usr/include/boost/intrusive/detail/memory_util.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 25 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 27 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 1 3 4 ># 79 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 > namespace boost { namespace intrusive { namespace detail { > > template <typename Type> > class has_member_function_named_static_cast_from > { > struct BaseMixin > { > void static_cast_from(); > }; > > struct Base : public ::boost::intrusive::detail::remove_cv<Type>::type, public BaseMixin { Base(); }; > template <typename T, T t> class Helper{}; > > template <typename U> > static boost_intrusive_has_member_function_callable_with::no_type deduce > (U*, Helper<void (BaseMixin::*)(), &U::static_cast_from>* = 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))); > }; ># 188 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 > template<typename Fun, bool HasFunc, class ...Args> > struct has_member_function_callable_with_static_cast_from_impl; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_static_cast_from_impl > <Fun, false, Args...> > { > static const bool value = false; > }; > > > template< class F > , std::size_t N = > sizeof((boost::move_detail::declval<F>(). > static_cast_from (), 0))> > struct zeroarg_checker_static_cast_from > { > boost_intrusive_has_member_function_callable_with::yes_type dummy; > zeroarg_checker_static_cast_from(int); > }; > > > > template<class F> > struct zeroarg_checker_static_cast_from<F, 0> > { > boost_intrusive_has_member_function_callable_with::no_type dummy; > zeroarg_checker_static_cast_from(int); > }; > > template<typename Fun> > struct has_member_function_callable_with_static_cast_from_impl > <Fun, true> > { > template<class U> > static zeroarg_checker_static_cast_from > <U> Test(zeroarg_checker_static_cast_from<U>*); > > template <class U> > 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<typename Fun, class ...DontCares> > struct funwrap_static_cast_from > : Fun > { > funwrap_static_cast_from(); > using Fun::static_cast_from; > > boost_intrusive_has_member_function_callable_with::private_type > static_cast_from > ( DontCares...) const; > }; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_static_cast_from_impl > <Fun, true , Args...> > { > template<class T> > struct make_dontcare > { > typedef boost_intrusive_has_member_function_callable_with::dont_care type; > }; > > typedef funwrap_static_cast_from > <Fun, typename make_dontcare<Args>::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 >(). > static_cast_from > ( ::boost::move_detail::declval<Args>()... ), 0) ) > ) > ); > }; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_static_cast_from > > : public has_member_function_callable_with_static_cast_from_impl > > < Fun > , has_member_function_named_static_cast_from > <Fun>::value > , Args... > > {}; > > > > }}} ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 1 3 4 ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 129 "/usr/include/boost/intrusive/detail/memory_util.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 25 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 27 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 1 3 4 ># 79 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 > namespace boost { namespace intrusive { namespace detail { > > template <typename Type> > class has_member_function_named_const_cast_from > { > struct BaseMixin > { > void const_cast_from(); > }; > > struct Base : public ::boost::intrusive::detail::remove_cv<Type>::type, public BaseMixin { Base(); }; > template <typename T, T t> class Helper{}; > > template <typename U> > static boost_intrusive_has_member_function_callable_with::no_type deduce > (U*, Helper<void (BaseMixin::*)(), &U::const_cast_from>* = 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))); > }; ># 188 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 > template<typename Fun, bool HasFunc, class ...Args> > struct has_member_function_callable_with_const_cast_from_impl; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_const_cast_from_impl > <Fun, false, Args...> > { > static const bool value = false; > }; > > > template< class F > , std::size_t N = > sizeof((boost::move_detail::declval<F>(). > const_cast_from (), 0))> > struct zeroarg_checker_const_cast_from > { > boost_intrusive_has_member_function_callable_with::yes_type dummy; > zeroarg_checker_const_cast_from(int); > }; > > > > template<class F> > struct zeroarg_checker_const_cast_from<F, 0> > { > boost_intrusive_has_member_function_callable_with::no_type dummy; > zeroarg_checker_const_cast_from(int); > }; > > template<typename Fun> > struct has_member_function_callable_with_const_cast_from_impl > <Fun, true> > { > template<class U> > static zeroarg_checker_const_cast_from > <U> Test(zeroarg_checker_const_cast_from<U>*); > > template <class U> > 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<typename Fun, class ...DontCares> > struct funwrap_const_cast_from > : Fun > { > funwrap_const_cast_from(); > using Fun::const_cast_from; > > boost_intrusive_has_member_function_callable_with::private_type > const_cast_from > ( DontCares...) const; > }; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_const_cast_from_impl > <Fun, true , Args...> > { > template<class T> > struct make_dontcare > { > typedef boost_intrusive_has_member_function_callable_with::dont_care type; > }; > > typedef funwrap_const_cast_from > <Fun, typename make_dontcare<Args>::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 >(). > const_cast_from > ( ::boost::move_detail::declval<Args>()... ), 0) ) > ) > ); > }; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_const_cast_from > > : public has_member_function_callable_with_const_cast_from_impl > > < Fun > , has_member_function_named_const_cast_from > <Fun>::value > , Args... > > {}; > > > > }}} ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 1 3 4 ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 135 "/usr/include/boost/intrusive/detail/memory_util.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 25 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 27 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 1 3 4 ># 79 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 > namespace boost { namespace intrusive { namespace detail { > > template <typename Type> > class has_member_function_named_dynamic_cast_from > { > struct BaseMixin > { > void dynamic_cast_from(); > }; > > struct Base : public ::boost::intrusive::detail::remove_cv<Type>::type, public BaseMixin { Base(); }; > template <typename T, T t> class Helper{}; > > template <typename U> > static boost_intrusive_has_member_function_callable_with::no_type deduce > (U*, Helper<void (BaseMixin::*)(), &U::dynamic_cast_from>* = 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))); > }; ># 188 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 3 4 > template<typename Fun, bool HasFunc, class ...Args> > struct has_member_function_callable_with_dynamic_cast_from_impl; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_dynamic_cast_from_impl > <Fun, false, Args...> > { > static const bool value = false; > }; > > > template< class F > , std::size_t N = > sizeof((boost::move_detail::declval<F>(). > dynamic_cast_from (), 0))> > struct zeroarg_checker_dynamic_cast_from > { > boost_intrusive_has_member_function_callable_with::yes_type dummy; > zeroarg_checker_dynamic_cast_from(int); > }; > > > > template<class F> > struct zeroarg_checker_dynamic_cast_from<F, 0> > { > boost_intrusive_has_member_function_callable_with::no_type dummy; > zeroarg_checker_dynamic_cast_from(int); > }; > > template<typename Fun> > struct has_member_function_callable_with_dynamic_cast_from_impl > <Fun, true> > { > template<class U> > static zeroarg_checker_dynamic_cast_from > <U> Test(zeroarg_checker_dynamic_cast_from<U>*); > > template <class U> > 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<typename Fun, class ...DontCares> > struct funwrap_dynamic_cast_from > : Fun > { > funwrap_dynamic_cast_from(); > using Fun::dynamic_cast_from; > > boost_intrusive_has_member_function_callable_with::private_type > dynamic_cast_from > ( DontCares...) const; > }; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_dynamic_cast_from_impl > <Fun, true , Args...> > { > template<class T> > struct make_dontcare > { > typedef boost_intrusive_has_member_function_callable_with::dont_care type; > }; > > typedef funwrap_dynamic_cast_from > <Fun, typename make_dontcare<Args>::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 >(). > dynamic_cast_from > ( ::boost::move_detail::declval<Args>()... ), 0) ) > ) > ); > }; > > template<typename Fun, class ...Args> > struct has_member_function_callable_with_dynamic_cast_from > > : public has_member_function_callable_with_dynamic_cast_from_impl > > < Fun > , has_member_function_named_dynamic_cast_from > <Fun>::value > , Args... > > {}; > > > > }}} ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/intrusive/detail/has_member_function_callable_with.hpp" 1 3 4 ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 141 "/usr/include/boost/intrusive/detail/memory_util.hpp" 2 3 4 > >namespace boost { >namespace intrusive { >namespace detail { > >template <typename T, typename DefaultType> struct boost_intrusive_default_type_element_type { template <typename X> static char test(int, typename X::element_type*); template <typename X> static int test(boost::intrusive::detail:: LowPriorityConversion<int>, void*); struct DefaultWrap { typedef DefaultType element_type; }; static const bool value = (1 == sizeof(test<T>(0, 0))); typedef typename ::boost::intrusive::detail::if_c <value, T, DefaultWrap>::type::element_type type; }; template <typename T, typename DefaultType> struct boost_intrusive_eval_default_type_element_type { template <typename X> static char test(int, typename X::element_type*); template <typename X> static int test(boost::intrusive::detail:: LowPriorityConversion<int>, void*); struct DefaultWrap { typedef typename DefaultType::type element_type; }; static const bool value = (1 == sizeof(test<T>(0, 0))); typedef typename ::boost::intrusive::detail::eval_if_c < value , ::boost::intrusive::detail::identity<T> , ::boost::intrusive::detail::identity<DefaultWrap> >::type::element_type type; }; >template <typename T, typename DefaultType> struct boost_intrusive_default_type_difference_type { template <typename X> static char test(int, typename X::difference_type*); template <typename X> static int test(boost::intrusive::detail:: LowPriorityConversion<int>, void*); struct DefaultWrap { typedef DefaultType difference_type; }; static const bool value = (1 == sizeof(test<T>(0, 0))); typedef typename ::boost::intrusive::detail::if_c <value, T, DefaultWrap>::type::difference_type type; }; template <typename T, typename DefaultType> struct boost_intrusive_eval_default_type_difference_type { template <typename X> static char test(int, typename X::difference_type*); template <typename X> static int test(boost::intrusive::detail:: LowPriorityConversion<int>, void*); struct DefaultWrap { typedef typename DefaultType::type difference_type; }; static const bool value = (1 == sizeof(test<T>(0, 0))); typedef typename ::boost::intrusive::detail::eval_if_c < value , ::boost::intrusive::detail::identity<T> , ::boost::intrusive::detail::identity<DefaultWrap> >::type::difference_type type; }; > > > > > >template <typename T> struct first_param >{ typedef void type; }; > > > > template <template <typename, typename...> class TemplateClass, typename T, typename... Args> > struct first_param< TemplateClass<T, Args...> > > { > typedef T type; > }; ># 185 "/usr/include/boost/intrusive/detail/memory_util.hpp" 3 4 >template <typename Ptr, typename T> >struct type_has_rebind >{ > template <typename X> > > static char test(int, typename X::template rebind<T>*); > > > > > template <typename X> > static int test(boost::intrusive::detail::LowPriorityConversion<int>, void*); > > static const bool value = (1 == sizeof(test<Ptr>(0, 0))); >}; > >template <typename Ptr, typename T> >struct type_has_rebind_other >{ > template <typename X> > > static char test(int, typename X::template rebind<T>::other*); > > > > > template <typename X> > static int test(boost::intrusive::detail::LowPriorityConversion<int>, void*); > > static const bool value = (1 == sizeof(test<Ptr>(0, 0))); >}; > >template <typename Ptr, typename T> >struct type_rebind_mode >{ > static const unsigned int rebind = (unsigned int)type_has_rebind<Ptr, T>::value; > static const unsigned int rebind_other = (unsigned int)type_has_rebind_other<Ptr, T>::value; > static const unsigned int mode = rebind + rebind*rebind_other; >}; > > > > >template <typename Ptr, typename U, unsigned int RebindMode = type_rebind_mode<Ptr, U>::mode> >struct type_rebinder; > > > >template <typename Ptr, typename U> >struct type_rebinder< Ptr, U, 2u > >{ > typedef typename Ptr::template rebind<U>::other type; >}; > > > >template <typename Ptr, typename U> >struct type_rebinder< Ptr, U, 1u > >{ > typedef typename Ptr::template rebind<U> type; >}; ># 254 "/usr/include/boost/intrusive/detail/memory_util.hpp" 3 4 >template <template <class, class...> class Ptr, typename T, class... Tn, class U> >struct type_rebinder<Ptr<T, Tn...>, U, 0u > >{ > typedef Ptr<U, Tn...> type; >}; > > >template <template <class> class Ptr, typename T, class U> >struct type_rebinder<Ptr<T>, U, 0u > >{ > typedef Ptr<U> type; >}; ># 286 "/usr/include/boost/intrusive/detail/memory_util.hpp" 3 4 >} >} >} > ># 1 "/usr/include/boost/intrusive/detail/config_end.hpp" 1 3 4 ># 291 "/usr/include/boost/intrusive/detail/memory_util.hpp" 2 3 4 ># 27 "/usr/include/boost/intrusive/pointer_traits.hpp" 2 3 4 > > > >namespace boost { >namespace intrusive { > > > > > >template <typename Ptr> >struct pointer_traits >{ ># 68 "/usr/include/boost/intrusive/pointer_traits.hpp" 3 4 > typedef Ptr pointer; > > typedef typename boost::intrusive::detail:: boost_intrusive_eval_default_type_element_type< Ptr, boost::intrusive::detail::first_param<Ptr> >::type > > element_type; > > typedef typename boost::intrusive::detail:: boost_intrusive_default_type_difference_type< Ptr, std::ptrdiff_t >::type > difference_type; > > typedef typename boost::intrusive::detail::unvoid_ref<element_type>::type reference; > > template <class U> struct rebind_pointer > { > typedef typename boost::intrusive::detail::type_rebinder<Ptr, U>::type type; > }; > > > template <class U> using rebind = typename boost::intrusive::detail::type_rebinder<Ptr, U>::type; ># 94 "/usr/include/boost/intrusive/pointer_traits.hpp" 3 4 > static pointer pointer_to(reference r) > { > > > const bool value = boost::intrusive::detail:: > has_member_function_callable_with_pointer_to > <Ptr, typename boost::intrusive::detail::unvoid<element_type &>::type>::value; > ::boost::integral_constant<bool, value> flag; > return pointer_traits::priv_pointer_to(flag, r); > } > > > > > > template<class UPtr> > static pointer static_cast_from(const UPtr &uptr) > { > const bool value = boost::intrusive::detail:: > has_member_function_callable_with_static_cast_from > <Ptr, const UPtr>::value; > ::boost::integral_constant<bool, value> flag; > return pointer_traits::priv_static_cast_from(flag, uptr); > } > > > > > > template<class UPtr> > static pointer const_cast_from(const UPtr &uptr) > { > const bool value = boost::intrusive::detail:: > has_member_function_callable_with_const_cast_from > <Ptr, const UPtr>::value; > ::boost::integral_constant<bool, value> flag; > return pointer_traits::priv_const_cast_from(flag, uptr); > } > > > > > > template<class UPtr> > static pointer dynamic_cast_from(const UPtr &uptr) > { > const bool value = boost::intrusive::detail:: > has_member_function_callable_with_dynamic_cast_from > <Ptr, const UPtr>::value; > ::boost::integral_constant<bool, value> flag; > return pointer_traits::priv_dynamic_cast_from(flag, uptr); > } > > > private: > > template <class T> > static T* to_raw_pointer(T* p) > { return p; } > > template <class Pointer> > static typename pointer_traits<Pointer>::element_type* > to_raw_pointer(const Pointer &p) > { return pointer_traits::to_raw_pointer(p.operator->()); } > > > static pointer priv_pointer_to(boost::true_type, typename boost::intrusive::detail::unvoid<element_type>::type& r) > { return Ptr::pointer_to(r); } > > static pointer priv_pointer_to(boost::false_type, typename boost::intrusive::detail::unvoid<element_type>::type& r) > { return pointer(boost::intrusive::detail::addressof(r)); } > > > template<class UPtr> > static pointer priv_static_cast_from(boost::true_type, const UPtr &uptr) > { return Ptr::static_cast_from(uptr); } > > template<class UPtr> > static pointer priv_static_cast_from(boost::false_type, const UPtr &uptr) > { return pointer_to(*static_cast<element_type*>(to_raw_pointer(uptr))); } > > > template<class UPtr> > static pointer priv_const_cast_from(boost::true_type, const UPtr &uptr) > { return Ptr::const_cast_from(uptr); } > > template<class UPtr> > static pointer priv_const_cast_from(boost::false_type, const UPtr &uptr) > { return pointer_to(const_cast<element_type&>(*uptr)); } > > > template<class UPtr> > static pointer priv_dynamic_cast_from(boost::true_type, const UPtr &uptr) > { return Ptr::dynamic_cast_from(uptr); } > > template<class UPtr> > static pointer priv_dynamic_cast_from(boost::false_type, const UPtr &uptr) > { return pointer_to(*dynamic_cast<element_type*>(&*uptr)); } > >}; > > > > >template <typename Ptr> >struct pointer_traits<const Ptr> : pointer_traits<Ptr> {}; >template <typename Ptr> >struct pointer_traits<volatile Ptr> : pointer_traits<Ptr> { }; >template <typename Ptr> >struct pointer_traits<const volatile Ptr> : pointer_traits<Ptr> { }; > >template <typename Ptr> >struct pointer_traits<Ptr&> : pointer_traits<Ptr> { }; > > > > > >template <typename T> >struct pointer_traits<T*> >{ > typedef T element_type; > typedef T* pointer; > typedef std::ptrdiff_t difference_type; ># 227 "/usr/include/boost/intrusive/pointer_traits.hpp" 3 4 > typedef typename boost::intrusive::detail::unvoid_ref<element_type>::type reference; > > template <class U> using rebind = U*; > > > > template <class U> struct rebind_pointer > { typedef U* type; }; > > > > static pointer pointer_to(reference r) > { return boost::intrusive::detail::addressof(r); } > > > > template<class U> > static pointer static_cast_from(U *uptr) > { return static_cast<pointer>(uptr); } > > > > template<class U> > static pointer const_cast_from(U *uptr) > { return const_cast<pointer>(uptr); } > > > > template<class U> > static pointer dynamic_cast_from(U *uptr) > { return dynamic_cast<pointer>(uptr); } >}; > >} >} > ># 1 "/usr/include/boost/intrusive/detail/config_end.hpp" 1 3 4 ># 264 "/usr/include/boost/intrusive/pointer_traits.hpp" 2 3 4 ># 33 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 > > > > ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 38 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 > >namespace boost { >namespace interprocess { >namespace ipcdetail { > >template <class T> >inline T* to_raw_pointer(T* p) >{ return p; } > >template <class Pointer> >inline typename boost::intrusive::pointer_traits<Pointer>::element_type* >to_raw_pointer(const Pointer &p) >{ return boost::interprocess::ipcdetail::to_raw_pointer(p.operator->()); } > > >template <class T> >inline void do_swap(T& x, T& y) >{ > using std::swap; > swap(x, y); >} > > >template<class SizeType> >inline SizeType get_rounded_size(SizeType orig_size, SizeType round_to) >{ > return ((orig_size-1)/round_to+1)*round_to; >} > > >template<class SizeType> >inline SizeType get_truncated_size(SizeType orig_size, SizeType multiple) >{ > return orig_size/multiple*multiple; >} > > >template<class SizeType> >inline SizeType get_rounded_size_po2(SizeType orig_size, SizeType round_to) >{ > return ((orig_size-1)&(~(round_to-1))) + round_to; >} > > >template<class SizeType> >inline SizeType get_truncated_size_po2(SizeType orig_size, SizeType multiple) >{ > return (orig_size & (~(multiple-1))); >} > >template <std::size_t OrigSize, std::size_t RoundTo> >struct ct_rounded_size >{ > static_assert((RoundTo != 0), "(RoundTo != 0)"); > static const std::size_t intermediate_value = (OrigSize-1)/RoundTo+1; > static_assert(intermediate_value <= std::size_t(-1)/RoundTo, "intermediate_value <= std::size_t(-1)/RoundTo"); > static const std::size_t value = intermediate_value*RoundTo; >}; > > >template <int p, int n = 4> >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; >}; > >} > > > > >template <class Index> >struct is_node_index >{ > static const bool value = false; >}; > > > > > >template <class Index> >struct is_intrusive_index >{ > static const bool value = false; >}; > >template <typename T> T* >addressof(T& v) >{ > return reinterpret_cast<T*>( > &const_cast<char&>(reinterpret_cast<const volatile char &>(v))); >} > >template<class SizeType> >struct sqrt_size_type_max >{ > static const SizeType value = (SizeType(1) << (sizeof(SizeType)*(8/2)))-1; >}; > >template<class SizeType> >inline bool multiplication_overflows(SizeType a, SizeType b) >{ > const SizeType sqrt_size_max = sqrt_size_type_max<SizeType>::value; > return > ( (a | b) > sqrt_size_max && > > b && a > SizeType(-1)/b > ); >} > >template<std::size_t SztSizeOfType, class SizeType> >inline bool size_overflows(SizeType count) >{ > > static_assert(SztSizeOfType <= SizeType(-1), "SztSizeOfType <= SizeType(-1)"); > > return multiplication_overflows(SizeType(SztSizeOfType), count); >} > >template<class RawPointer> >class pointer_size_t_caster >{ > public: > explicit pointer_size_t_caster(std::size_t sz) > : m_ptr(reinterpret_cast<RawPointer>(sz)) > {} > > explicit pointer_size_t_caster(RawPointer p) > : m_ptr(p) > {} > > std::size_t size() const > { return reinterpret_cast<std::size_t>(m_ptr); } > > RawPointer pointer() const > { return m_ptr; } > > private: > RawPointer m_ptr; >}; > > >template<class SizeType> >inline bool sum_overflows(SizeType a, SizeType b) >{ return SizeType(-1) - a < b; } > > >template<class Cont> >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; >}; > >} >} > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 216 "/usr/include/boost/interprocess/detail/utilities.hpp" 2 3 4 ># 23 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 2 3 4 ># 1 "/usr/include/boost/interprocess/detail/pointer_type.hpp" 1 3 4 ># 21 "/usr/include/boost/interprocess/detail/pointer_type.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 22 "/usr/include/boost/interprocess/detail/pointer_type.hpp" 2 3 4 > > > >namespace boost { >namespace interprocess { >namespace ipcdetail { > >struct two {char _[2];}; > >namespace pointer_type_imp { > >template <class U> static two test(...); >template <class U> static char test(typename U::pointer* = 0); > >} > >template <class T> >struct has_pointer_type >{ > static const bool value = sizeof(pointer_type_imp::test<T>(0)) == 1; >}; > >namespace pointer_type_imp { > >template <class T, class D, bool = has_pointer_type<D>::value> >struct pointer_type >{ > typedef typename D::pointer type; >}; > >template <class T, class D> >struct pointer_type<T, D, false> >{ > typedef T* type; >}; > >} > >template <class T, class D> >struct pointer_type >{ > typedef typename pointer_type_imp::pointer_type<T, > typename remove_reference<D>::type>::type type; >}; > >} >} >} > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 72 "/usr/include/boost/interprocess/detail/pointer_type.hpp" 2 3 4 ># 24 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 2 3 4 > ># 1 "/usr/include/boost/compressed_pair.hpp" 1 3 4 ># 21 "/usr/include/boost/compressed_pair.hpp" 3 4 ># 1 "/usr/include/boost/detail/compressed_pair.hpp" 1 3 4 ># 28 "/usr/include/boost/detail/compressed_pair.hpp" 3 4 ># 1 "/usr/include/boost/call_traits.hpp" 1 3 4 ># 21 "/usr/include/boost/call_traits.hpp" 3 4 ># 1 "/usr/include/boost/detail/call_traits.hpp" 1 3 4 ># 31 "/usr/include/boost/detail/call_traits.hpp" 3 4 >namespace boost{ > >namespace detail{ > >template <typename T, bool small_> >struct ct_imp2 >{ > typedef const T& param_type; >}; > >template <typename T> >struct ct_imp2<T, true> >{ > typedef const T param_type; >}; > >template <typename T, bool isp, bool b1, bool b2> >struct ct_imp >{ > typedef const T& param_type; >}; > >template <typename T, bool isp, bool b2> >struct ct_imp<T, isp, true, b2> >{ > typedef typename ct_imp2<T, sizeof(T) <= sizeof(void*)>::param_type param_type; >}; > >template <typename T, bool isp, bool b1> >struct ct_imp<T, isp, b1, true> >{ > typedef typename ct_imp2<T, sizeof(T) <= sizeof(void*)>::param_type param_type; >}; > >template <typename T, bool b1, bool b2> >struct ct_imp<T, true, b1, b2> >{ > typedef const T param_type; >}; > >} > >template <typename T> >struct call_traits >{ >public: > typedef T value_type; > typedef T& reference; > typedef const T& const_reference; > > > > > > > typedef typename boost::detail::ct_imp< > T, > ::boost::is_pointer<T>::value, > ::boost::is_arithmetic<T>::value, > ::boost::is_enum<T>::value > >::param_type param_type; >}; > >template <typename T> >struct call_traits<T&> >{ > typedef T& value_type; > typedef T& reference; > typedef const T& const_reference; > typedef T& param_type; >}; ># 143 "/usr/include/boost/detail/call_traits.hpp" 3 4 >template <typename T, std::size_t N> >struct call_traits<T [N]> >{ >private: > typedef T array_type[N]; >public: > > typedef const T* value_type; > typedef array_type& reference; > typedef const array_type& const_reference; > typedef const T* const param_type; >}; > >template <typename T, std::size_t N> >struct call_traits<const T [N]> >{ >private: > typedef const T array_type[N]; >public: > > typedef const T* value_type; > typedef array_type& reference; > typedef const array_type& const_reference; > typedef const T* const param_type; >}; > > >} ># 22 "/usr/include/boost/call_traits.hpp" 2 3 4 ># 29 "/usr/include/boost/detail/compressed_pair.hpp" 2 3 4 > > > > > >namespace boost >{ > >template <class T1, class T2> >class compressed_pair; > > > > >namespace details >{ > > template <class T1, class T2, bool IsSame, bool FirstEmpty, bool SecondEmpty> > struct compressed_pair_switch; > > template <class T1, class T2> > struct compressed_pair_switch<T1, T2, false, false, false> > {static const int value = 0;}; > > template <class T1, class T2> > struct compressed_pair_switch<T1, T2, false, true, true> > {static const int value = 3;}; > > template <class T1, class T2> > struct compressed_pair_switch<T1, T2, false, true, false> > {static const int value = 1;}; > > template <class T1, class T2> > struct compressed_pair_switch<T1, T2, false, false, true> > {static const int value = 2;}; > > template <class T1, class T2> > struct compressed_pair_switch<T1, T2, true, true, true> > {static const int value = 4;}; > > template <class T1, class T2> > struct compressed_pair_switch<T1, T2, true, false, false> > {static const int value = 5;}; > > template <class T1, class T2, int Version> class compressed_pair_imp; > > > > using std::swap; > > > > > > > template <typename T> > inline void cp_swap(T& t1, T& t2) > { > > > > swap(t1, t2); > } > > > > template <class T1, class T2> > class compressed_pair_imp<T1, T2, 0> > { > public: > typedef T1 first_type; > typedef T2 second_type; > typedef typename call_traits<first_type>::param_type first_param_type; > typedef typename call_traits<second_type>::param_type second_param_type; > typedef typename call_traits<first_type>::reference first_reference; > typedef typename call_traits<second_type>::reference second_reference; > typedef typename call_traits<first_type>::const_reference first_const_reference; > typedef typename call_traits<second_type>::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<T1, T2>& y) > { > cp_swap(first_, y.first()); > cp_swap(second_, y.second()); > } > private: > first_type first_; > second_type second_; > }; > > > > template <class T1, class T2> > class compressed_pair_imp<T1, T2, 1> > : protected ::boost::remove_cv<T1>::type > { > public: > typedef T1 first_type; > typedef T2 second_type; > typedef typename call_traits<first_type>::param_type first_param_type; > typedef typename call_traits<second_type>::param_type second_param_type; > typedef typename call_traits<first_type>::reference first_reference; > typedef typename call_traits<second_type>::reference second_reference; > typedef typename call_traits<first_type>::const_reference first_const_reference; > typedef typename call_traits<second_type>::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<T1,T2>& y) > { > > cp_swap(second_, y.second()); > } > private: > second_type second_; > }; > > > > template <class T1, class T2> > class compressed_pair_imp<T1, T2, 2> > : protected ::boost::remove_cv<T2>::type > { > public: > typedef T1 first_type; > typedef T2 second_type; > typedef typename call_traits<first_type>::param_type first_param_type; > typedef typename call_traits<second_type>::param_type second_param_type; > typedef typename call_traits<first_type>::reference first_reference; > typedef typename call_traits<second_type>::reference second_reference; > typedef typename call_traits<first_type>::const_reference first_const_reference; > typedef typename call_traits<second_type>::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<T1,T2>& y) > { > > cp_swap(first_, y.first()); > } > > private: > first_type first_; > }; > > > > template <class T1, class T2> > class compressed_pair_imp<T1, T2, 3> > : protected ::boost::remove_cv<T1>::type, > protected ::boost::remove_cv<T2>::type > { > public: > typedef T1 first_type; > typedef T2 second_type; > typedef typename call_traits<first_type>::param_type first_param_type; > typedef typename call_traits<second_type>::param_type second_param_type; > typedef typename call_traits<first_type>::reference first_reference; > typedef typename call_traits<second_type>::reference second_reference; > typedef typename call_traits<first_type>::const_reference first_const_reference; > typedef typename call_traits<second_type>::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;} > > > void swap(::boost::compressed_pair<T1,T2>&) {} > }; ># 265 "/usr/include/boost/detail/compressed_pair.hpp" 3 4 > template <class T1, class T2> > class compressed_pair_imp<T1, T2, 4> > : protected ::boost::remove_cv<T1>::type > { > public: > typedef T1 first_type; > typedef T2 second_type; > typedef typename call_traits<first_type>::param_type first_param_type; > typedef typename call_traits<second_type>::param_type second_param_type; > typedef typename call_traits<first_type>::reference first_reference; > typedef typename call_traits<second_type>::reference second_reference; > typedef typename call_traits<first_type>::const_reference first_const_reference; > typedef typename call_traits<second_type>::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<T1,T2>&) {} > private: > T2 m_second; > }; > > > > template <class T1, class T2> > class compressed_pair_imp<T1, T2, 5> > { > public: > typedef T1 first_type; > typedef T2 second_type; > typedef typename call_traits<first_type>::param_type first_param_type; > typedef typename call_traits<second_type>::param_type second_param_type; > typedef typename call_traits<first_type>::reference first_reference; > typedef typename call_traits<second_type>::reference second_reference; > typedef typename call_traits<first_type>::const_reference first_const_reference; > typedef typename call_traits<second_type>::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<T1, T2>& y) > { > cp_swap(first_, y.first()); > cp_swap(second_, y.second()); > } > private: > first_type first_; > second_type second_; > }; > >} > >template <class T1, class T2> >class compressed_pair > : private ::boost::details::compressed_pair_imp<T1, T2, > ::boost::details::compressed_pair_switch< > T1, > T2, > ::boost::is_same<typename remove_cv<T1>::type, typename remove_cv<T2>::type>::value, > ::boost::is_empty<T1>::value, > ::boost::is_empty<T2>::value>::value> >{ >private: > typedef details::compressed_pair_imp<T1, T2, > ::boost::details::compressed_pair_switch< > T1, > T2, > ::boost::is_same<typename remove_cv<T1>::type, typename remove_cv<T2>::type>::value, > ::boost::is_empty<T1>::value, > ::boost::is_empty<T2>::value>::value> base; >public: > typedef T1 first_type; > typedef T2 second_type; > typedef typename call_traits<first_type>::param_type first_param_type; > typedef typename call_traits<second_type>::param_type second_param_type; > typedef typename call_traits<first_type>::reference first_reference; > typedef typename call_traits<second_type>::reference second_reference; > typedef typename call_traits<first_type>::const_reference first_const_reference; > typedef typename call_traits<second_type>::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); } >}; > > > > >template <class T> >class compressed_pair<T, T> > : private details::compressed_pair_imp<T, T, > ::boost::details::compressed_pair_switch< > T, > T, > ::boost::is_same<typename remove_cv<T>::type, typename remove_cv<T>::type>::value, > ::boost::is_empty<T>::value, > ::boost::is_empty<T>::value>::value> >{ >private: > typedef details::compressed_pair_imp<T, T, > ::boost::details::compressed_pair_switch< > T, > T, > ::boost::is_same<typename remove_cv<T>::type, typename remove_cv<T>::type>::value, > ::boost::is_empty<T>::value, > ::boost::is_empty<T>::value>::value> base; >public: > typedef T first_type; > typedef T second_type; > typedef typename call_traits<first_type>::param_type first_param_type; > typedef typename call_traits<second_type>::param_type second_param_type; > typedef typename call_traits<first_type>::reference first_reference; > typedef typename call_traits<second_type>::reference second_reference; > typedef typename call_traits<first_type>::const_reference first_const_reference; > typedef typename call_traits<second_type>::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) {} > > 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<T,T>& y) { base::swap(y); } >}; > >template <class T1, class T2> >inline >void >swap(compressed_pair<T1, T2>& x, compressed_pair<T1, T2>& y) >{ > x.swap(y); >} > >} ># 22 "/usr/include/boost/compressed_pair.hpp" 2 3 4 ># 26 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/interprocess/smart_ptr/deleter.hpp" 1 3 4 ># 20 "/usr/include/boost/interprocess/smart_ptr/deleter.hpp" 3 4 ># 1 "/usr/include/boost/interprocess/detail/config_begin.hpp" 1 3 4 ># 21 "/usr/include/boost/interprocess/smart_ptr/deleter.hpp" 2 3 4 > > > > > > > >namespace boost { >namespace interprocess { > > > > > >template<class T, class SegmentManager> >class deleter >{ > public: > typedef typename boost::intrusive:: > pointer_traits<typename SegmentManager::void_pointer>::template > rebind_pointer<T>::type pointer; > > private: > typedef typename boost::intrusive:: > pointer_traits<pointer>::template > rebind_pointer<SegmentManager>::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)); } >}; > >} >} > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 63 "/usr/include/boost/interprocess/smart_ptr/deleter.hpp" 2 3 4 ># 30 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 2 3 4 > > > > > >namespace boost{ >namespace interprocess{ > > >template <class T, class D> class unique_ptr; > >namespace ipcdetail { > >template <class T> struct unique_ptr_error; > >template <class T, class D> >struct unique_ptr_error<const unique_ptr<T, D> > >{ > typedef unique_ptr<T, D> type; >}; > >} ># 81 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 >template <class T, class D> >class unique_ptr >{ > > struct nat {int for_bool;}; > struct nat2 {int for_nullptr;}; > typedef int nat2::*nullptr_t; > typedef typename ipcdetail::add_reference<D>::type deleter_reference; > typedef typename ipcdetail::add_reference<const D>::type deleter_const_reference; > > > public: > > typedef T element_type; > typedef D deleter_type; > typedef typename ipcdetail::pointer_type<T, D>::type pointer; ># 107 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 > unique_ptr() > : ptr_(pointer(0)) > {} ># 121 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 > explicit unique_ptr(pointer p) > : ptr_(p) > {} ># 132 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 > unique_ptr(pointer p > ,typename ipcdetail::if_<ipcdetail::is_reference<D> > ,D > ,typename ipcdetail::add_reference<const D>::type>::type d) > : ptr_(p, d) > {} ># 156 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 > unique_ptr(unique_ptr && u) > : ptr_(u.release(), boost::forward<D>(u.get_deleter())) > {} ># 179 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 > template <class U, class E> > unique_ptr( unique_ptr<U, E> && u, > typename ipcdetail::enable_if_c< > ipcdetail::is_convertible<typename unique_ptr<U, E>::pointer, pointer>::value && > ipcdetail::is_convertible<E, D>::value && > ( > !ipcdetail::is_reference<D>::value || > ipcdetail::is_same<D, E>::value > ) > , > nat > >::type = nat()) > : ptr_(const_cast<unique_ptr<U,E>&>(u).release(), boost::move<D>(u.get_deleter())) > {} > > > > > ~unique_ptr() > { reset(); } ># 213 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 > unique_ptr& operator=(unique_ptr && u) > { > reset(u.release()); > ptr_.second() = boost::move(u.get_deleter()); > return *this; > } ># 234 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 > template <class U, class E> > unique_ptr& operator=( unique_ptr<U, E> && u) > { > reset(u.release()); > ptr_.second() = boost::move(u.get_deleter()); > return *this; > } ># 251 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 > unique_ptr& operator=(nullptr_t) > { > reset(); > return *this; > } > > > > > typename ipcdetail::add_reference<T>::type operator*() const > { return *ptr_.first(); } > > > > > pointer operator->() const > { return ptr_.first(); } > > > > pointer get() const > { return ptr_.first(); } > > > > > deleter_reference get_deleter() > { return ptr_.second(); } > > > > > deleter_const_reference get_deleter() const > { return ptr_.second(); } > > > > > > operator int nat::*() const > { return ptr_.first() ? &nat::for_bool : 0; } > > > > > > > pointer release() > { > pointer tmp = ptr_.first(); > ptr_.first() = 0; > return tmp; > } > > > > > > > void reset(pointer p = 0) > { > if (ptr_.first() != p){ > if (ptr_.first()) > ptr_.second()(ptr_.first()); > ptr_.first() = p; > } > } > > > > > > > void swap(unique_ptr& u) > { ptr_.swap(u.ptr_); } > > > private: > boost::compressed_pair<pointer, D> ptr_; > public: unique_ptr(unique_ptr const &) = delete; unique_ptr& operator=(unique_ptr const &) = delete; public: typedef int boost_move_no_copy_constructor_or_assign; private: public: typedef int boost_move_emulation_t; > template <class U, class E> unique_ptr(unique_ptr<U, E>&); > template <class U> unique_ptr(U&, typename ipcdetail::unique_ptr_error<U>::type = 0); > > template <class U, class E> unique_ptr& operator=(unique_ptr<U, E>&); > template <class U> typename ipcdetail::unique_ptr_error<U>::type operator=(U&); > >}; ># 496 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 3 4 >template <class T, class D> inline >void swap(unique_ptr<T, D>& x, unique_ptr<T, D>& y) >{ x.swap(y); } > >template <class T1, class D1, class T2, class D2> inline >bool operator==(const unique_ptr<T1, D1>& x, const unique_ptr<T2, D2>& y) >{ return x.get() == y.get(); } > >template <class T1, class D1, class T2, class D2> inline >bool operator!=(const unique_ptr<T1, D1>& x, const unique_ptr<T2, D2>& y) >{ return x.get() != y.get(); } > >template <class T1, class D1, class T2, class D2> inline >bool operator <(const unique_ptr<T1, D1>& x, const unique_ptr<T2, D2>& y) >{ return x.get() < y.get(); } > >template <class T1, class D1, class T2, class D2> inline >bool operator<=(const unique_ptr<T1, D1>& x, const unique_ptr<T2, D2>& y) >{ return x.get() <= y.get(); } > >template <class T1, class D1, class T2, class D2> inline >bool operator >(const unique_ptr<T1, D1>& x, const unique_ptr<T2, D2>& y) >{ return x.get() > y.get(); } > >template <class T1, class D1, class T2, class D2> inline >bool operator>=(const unique_ptr<T1, D1>& x, const unique_ptr<T2, D2>& y) >{ return x.get() >= y.get(); } > > > > > >template<class T, class ManagedMemory> >struct managed_unique_ptr >{ > typedef unique_ptr > < T > , typename ManagedMemory::template deleter<T>::type > > type; >}; > > > > >template<class T, class ManagedMemory> >inline typename managed_unique_ptr<T, ManagedMemory>::type > make_managed_unique_ptr(T *constructed_object, ManagedMemory &managed_memory) >{ > return typename managed_unique_ptr<T, ManagedMemory>::type > (constructed_object, managed_memory.template get_deleter<T>()); >} > >} >} > ># 1 "/usr/include/boost/interprocess/detail/config_end.hpp" 1 3 4 ># 552 "/usr/include/boost/interprocess/smart_ptr/unique_ptr.hpp" 2 3 4 ># 23 "/usr/include/boost/chrono/detail/scan_keyword.hpp" 2 3 4 > > > > > >namespace boost { > using interprocess::unique_ptr; > >namespace chrono { >namespace chrono_detail { > >inline void free_aux(void* ptr) { free(ptr); } ># 54 "/usr/include/boost/chrono/detail/scan_keyword.hpp" 3 4 >template <class InputIterator, class ForwardIterator> >ForwardIterator >scan_keyword(InputIterator& b, InputIterator e, > ForwardIterator kb, ForwardIterator ke, > std::ios_base::iostate& err > ) >{ > typedef typename std::iterator_traits<InputIterator>::value_type CharT; > size_t nkw = std::distance(kb, ke); > const unsigned char doesnt_match = '\0'; > const unsigned char might_match = '\1'; > const unsigned char does_match = '\2'; > unsigned char statbuf[100]; > unsigned char* status = statbuf; > > > unique_ptr<unsigned char, void(*)(void*)> stat_hold(0, free_aux); > if (nkw > sizeof(statbuf)) > { > status = (unsigned char*)malloc(nkw); > if (status == 0) > throw_exception(std::bad_alloc()); > stat_hold.reset(status); > } > size_t n_might_match = nkw; > size_t n_does_match = 0; > > unsigned char* st = status; > for (ForwardIterator ky = kb; ky != ke; ++ky, ++st) > { > if (!ky->empty()) > *st = might_match; > else > { > *st = does_match; > --n_might_match; > ++n_does_match; > } > } > > for (size_t indx = 0; b != e && n_might_match > 0; ++indx) > { > > CharT c = *b; > bool consume = false; > > > > > > > st = status; > for (ForwardIterator ky = kb; ky != ke; ++ky, ++st) > { > if (*st == might_match) > { > CharT kc = (*ky)[indx]; > if (c == kc) > { > consume = true; > if (ky->size() == indx+1) > { > *st = does_match; > --n_might_match; > ++n_does_match; > } > } > else > { > *st = doesnt_match; > --n_might_match; > } > } > } > > if (consume) > { > ++b; > > > > if (n_might_match + n_does_match > 1) > { > st = status; > for (ForwardIterator ky = kb; ky != ke; ++ky, ++st) > { > if (*st == does_match && ky->size() != indx+1) > { > *st = doesnt_match; > --n_does_match; > } > } > } > } > } > > if (b == e) > err |= std::ios_base::eofbit; > > for (st = status; kb != ke; ++kb, ++st) > if (*st == does_match) > break; > if (kb == ke) > err |= std::ios_base::failbit; > return kb; >} >} >} >} ># 27 "/usr/include/boost/chrono/io_v1/chrono_io.hpp" 2 3 4 > ># 1 "/usr/include/boost/chrono/detail/no_warning/signed_unsigned_cmp.hpp" 1 3 4 ># 21 "/usr/include/boost/chrono/detail/no_warning/signed_unsigned_cmp.hpp" 3 4 ># 22 "/usr/include/boost/chrono/detail/no_warning/signed_unsigned_cmp.hpp" 3 > > > > > > >namespace boost { >namespace chrono { >namespace detail { > > template <class T, class U> > bool lt(T t, U u) > { > return t < u; > } > > template <class T, class U> > bool gt(T t, U u) > { > return t > u; > } > >} >} >} ># 29 "/usr/include/boost/chrono/io_v1/chrono_io.hpp" 2 3 4 > >namespace boost >{ > >namespace chrono >{ > >template <class CharT> >class duration_punct > : public std::locale::facet >{ >public: > typedef std::basic_string<CharT> string_type; > enum {use_long, use_short}; > >private: > bool use_short_; > string_type long_seconds_; > string_type long_minutes_; > string_type long_hours_; > string_type short_seconds_; > string_type short_minutes_; > string_type short_hours_; > > template <class Period> > string_type short_name(Period) const > {return ::boost::ratio_string<Period, CharT>::short_name() + short_seconds_;} > > string_type short_name(ratio<1>) const {return short_seconds_;} > string_type short_name(ratio<60>) const {return short_minutes_;} > string_type short_name(ratio<3600>) const {return short_hours_;} > > template <class Period> > string_type long_name(Period) const > {return ::boost::ratio_string<Period, CharT>::long_name() + long_seconds_;} > > string_type long_name(ratio<1>) const {return long_seconds_;} > string_type long_name(ratio<60>) const {return long_minutes_;} > string_type long_name(ratio<3600>) const {return long_hours_;} > > void init_C(); >public: > static std::locale::id id; > > explicit duration_punct(int use = use_long) > : use_short_(use==use_short) {init_C();} > > duration_punct(int use, > const string_type& long_seconds, const string_type& long_minutes, > const string_type& long_hours, const string_type& short_seconds, > const string_type& short_minutes, const string_type& short_hours); > > duration_punct(int use, const duration_punct& d); > > template <class Period> > string_type short_name() const > {return short_name(typename Period::type());} > > template <class Period> > string_type long_name() const > {return long_name(typename Period::type());} > > template <class Period> > string_type plural() const > {return long_name(typename Period::type());} > > template <class Period> > string_type singular() const > { > return string_type(long_name(typename Period::type()), 0, long_name(typename Period::type()).size()-1); > } > > template <class Period> > string_type name() const > { > if (use_short_) return short_name<Period>(); > else { > return long_name<Period>(); > } > } > template <class Period, class D> > string_type name(D v) const > { > if (use_short_) return short_name<Period>(); > else > { > if (v==-1 || v==1) > return singular<Period>(); > else > return plural<Period>(); > } > } > > bool is_short_name() const {return use_short_;} > bool is_long_name() const {return !use_short_;} >}; > >template <class CharT> >std::locale::id >duration_punct<CharT>::id; > >template <class CharT> >void >duration_punct<CharT>::init_C() >{ > short_seconds_ = CharT('s'); > short_minutes_ = CharT('m'); > short_hours_ = CharT('h'); > const CharT s[] = {'s', 'e', 'c', 'o', 'n', 'd', 's'}; > const CharT m[] = {'m', 'i', 'n', 'u', 't', 'e', 's'}; > const CharT h[] = {'h', 'o', 'u', 'r', 's'}; > long_seconds_.assign(s, s + sizeof(s)/sizeof(s[0])); > long_minutes_.assign(m, m + sizeof(m)/sizeof(m[0])); > long_hours_.assign(h, h + sizeof(h)/sizeof(h[0])); >} > >template <class CharT> >duration_punct<CharT>::duration_punct(int use, > const string_type& long_seconds, const string_type& long_minutes, > const string_type& long_hours, const string_type& short_seconds, > const string_type& short_minutes, const string_type& short_hours) > : use_short_(use==use_short), > long_seconds_(long_seconds), > long_minutes_(long_minutes), > long_hours_(long_hours), > short_seconds_(short_seconds), > short_minutes_(short_minutes), > short_hours_(short_hours) >{} > >template <class CharT> >duration_punct<CharT>::duration_punct(int use, const duration_punct& d) > : use_short_(use==use_short), > long_seconds_(d.long_seconds_), > long_minutes_(d.long_minutes_), > long_hours_(d.long_hours_), > short_seconds_(d.short_seconds_), > short_minutes_(d.short_minutes_), > short_hours_(d.short_hours_) >{} > >template <class CharT, class Traits> >std::basic_ostream<CharT, Traits>& >duration_short(std::basic_ostream<CharT, Traits>& os) >{ > typedef duration_punct<CharT> Facet; > std::locale loc = os.getloc(); > if (std::has_facet<Facet>(loc)) > { > const Facet& f = std::use_facet<Facet>(loc); > if (f.is_long_name()) > os.imbue(std::locale(loc, new Facet(Facet::use_short, f))); > } > else > os.imbue(std::locale(loc, new Facet(Facet::use_short))); > return os; >} > >template <class CharT, class Traits> >std::basic_ostream<CharT, Traits>& >duration_long(std::basic_ostream<CharT, Traits>& os) >{ > typedef duration_punct<CharT> Facet; > std::locale loc = os.getloc(); > if (std::has_facet<Facet>(loc)) > { > const Facet& f = std::use_facet<Facet>(loc); > if (f.is_short_name()) > os.imbue(std::locale(loc, new Facet(Facet::use_long, f))); > } > return os; >} > >template <class CharT, class Traits, class Rep, class Period> >std::basic_ostream<CharT, Traits>& >operator<<(std::basic_ostream<CharT, Traits>& os, const duration<Rep, Period>& d) >{ > typedef duration_punct<CharT> Facet; > std::locale loc = os.getloc(); > if (!std::has_facet<Facet>(loc)) > os.imbue(std::locale(loc, new Facet)); > const Facet& f = std::use_facet<Facet>(os.getloc()); > return os << d.count() << ' ' << f.template name<Period>(d.count()); >} > >namespace chrono_detail { >template <class Rep, bool = is_scalar<Rep>::value> >struct duration_io_intermediate >{ > typedef Rep type; >}; > >template <class Rep> >struct duration_io_intermediate<Rep, true> >{ > typedef typename mpl::if_c > < > is_floating_point<Rep>::value, > long double, > typename mpl::if_c > < > is_signed<Rep>::value, > long long, > unsigned long long > >::type > >::type type; >}; > >template <typename intermediate_type> >typename enable_if<is_integral<intermediate_type>, bool>::type >reduce(intermediate_type& r, unsigned long long& den, std::ios_base::iostate& err) >{ > typedef typename common_type<intermediate_type, unsigned long long>::type common_type_t; > > > common_type_t t = math::gcd<common_type_t>(common_type_t(r), common_type_t(den)); > r /= t; > den /= t; > if (den != 1) > { > > err |= std::ios_base::failbit; > return false; > } > return true; >} >template <typename intermediate_type> >typename disable_if<is_integral<intermediate_type>, bool>::type >reduce(intermediate_type& , unsigned long long& , std::ios_base::iostate& ) >{ > return true; >} > >} > >template <class CharT, class Traits, class Rep, class Period> >std::basic_istream<CharT, Traits>& >operator>>(std::basic_istream<CharT, Traits>& is, duration<Rep, Period>& d) >{ > > typedef duration_punct<CharT> Facet; > std::locale loc = is.getloc(); > > if (!std::has_facet<Facet>(loc)) { > > is.imbue(std::locale(loc, new Facet)); > } > > loc = is.getloc(); > const Facet& f = std::use_facet<Facet>(loc); > typedef typename chrono_detail::duration_io_intermediate<Rep>::type intermediate_type; > intermediate_type r; > std::ios_base::iostate err = std::ios_base::goodbit; > > > is >> r; > > if (is.good()) > { > > > typedef std::istreambuf_iterator<CharT, Traits> in_iterator; > in_iterator i(is); > in_iterator e; > > if (i != e && *i == ' ') > { > > ++i; > if (i != e) > { > > > unsigned long long num = 0; > unsigned long long den = 0; > if (*i == '[') > { > > > ++i; > CharT x; > is >> num >> x >> den; > if (!is.good() || (x != '/')) > { > > is.setstate(is.failbit); > return is; > } > i = in_iterator(is); > if (*i != ']') > { > > is.setstate(is.failbit); > return is; > } > ++i; > const std::basic_string<CharT> units[] = > { > f.template singular<ratio<1> >(), > f.template plural<ratio<1> >(), > f.template short_name<ratio<1> >() > }; > > const std::basic_string<CharT>* k = chrono_detail::scan_keyword(i, e, > units, units + sizeof(units)/sizeof(units[0]), > > err); > > is.setstate(err); > switch ((k - units) / 3) > { > case 0: > > break; > default: > is.setstate(err); > > return is; > } > } > else > { > > > const std::basic_string<CharT> units[] = > { > f.template singular<atto>(), > f.template plural<atto>(), > f.template short_name<atto>(), > f.template singular<femto>(), > f.template plural<femto>(), > f.template short_name<femto>(), > f.template singular<pico>(), > f.template plural<pico>(), > f.template short_name<pico>(), > f.template singular<nano>(), > f.template plural<nano>(), > f.template short_name<nano>(), > f.template singular<micro>(), > f.template plural<micro>(), > f.template short_name<micro>(), > f.template singular<milli>(), > f.template plural<milli>(), > f.template short_name<milli>(), > f.template singular<centi>(), > f.template plural<centi>(), > f.template short_name<centi>(), > f.template singular<deci>(), > f.template plural<deci>(), > f.template short_name<deci>(), > f.template singular<deca>(), > f.template plural<deca>(), > f.template short_name<deca>(), > f.template singular<hecto>(), > f.template plural<hecto>(), > f.template short_name<hecto>(), > f.template singular<kilo>(), > f.template plural<kilo>(), > f.template short_name<kilo>(), > f.template singular<mega>(), > f.template plural<mega>(), > f.template short_name<mega>(), > f.template singular<giga>(), > f.template plural<giga>(), > f.template short_name<giga>(), > f.template singular<tera>(), > f.template plural<tera>(), > f.template short_name<tera>(), > f.template singular<peta>(), > f.template plural<peta>(), > f.template short_name<peta>(), > f.template singular<exa>(), > f.template plural<exa>(), > f.template short_name<exa>(), > f.template singular<ratio<1> >(), > f.template plural<ratio<1> >(), > f.template short_name<ratio<1> >(), > f.template singular<ratio<60> >(), > f.template plural<ratio<60> >(), > f.template short_name<ratio<60> >(), > f.template singular<ratio<3600> >(), > f.template plural<ratio<3600> >(), > f.template short_name<ratio<3600> >() > }; > > const std::basic_string<CharT>* k = chrono_detail::scan_keyword(i, e, > units, units + sizeof(units)/sizeof(units[0]), > > err); > > switch ((k - units) / 3) > { > case 0: > num = 1ULL; > den = 1000000000000000000ULL; > break; > case 1: > num = 1ULL; > den = 1000000000000000ULL; > break; > case 2: > num = 1ULL; > den = 1000000000000ULL; > break; > case 3: > num = 1ULL; > den = 1000000000ULL; > break; > case 4: > num = 1ULL; > den = 1000000ULL; > break; > case 5: > num = 1ULL; > den = 1000ULL; > break; > case 6: > num = 1ULL; > den = 100ULL; > break; > case 7: > num = 1ULL; > den = 10ULL; > break; > case 8: > num = 10ULL; > den = 1ULL; > break; > case 9: > num = 100ULL; > den = 1ULL; > break; > case 10: > num = 1000ULL; > den = 1ULL; > break; > case 11: > num = 1000000ULL; > den = 1ULL; > break; > case 12: > num = 1000000000ULL; > den = 1ULL; > break; > case 13: > num = 1000000000000ULL; > den = 1ULL; > break; > case 14: > num = 1000000000000000ULL; > den = 1ULL; > break; > case 15: > num = 1000000000000000000ULL; > den = 1ULL; > break; > case 16: > num = 1; > den = 1; > break; > case 17: > num = 60; > den = 1; > break; > case 18: > num = 3600; > den = 1; > break; > default: > > is.setstate(err|is.failbit); > return is; > } > } > > > > > unsigned long long gcd_n1_n2 = math::gcd<unsigned long long>(num, Period::num); > unsigned long long gcd_d1_d2 = math::gcd<unsigned long long>(den, Period::den); > num /= gcd_n1_n2; > den /= gcd_d1_d2; > unsigned long long n2 = Period::num / gcd_n1_n2; > unsigned long long d2 = Period::den / gcd_d1_d2; > if (num > (std::numeric_limits<unsigned long long>::max)() / d2 || > den > (std::numeric_limits<unsigned long long>::max)() / n2) > { > > > is.setstate(err|is.failbit); > return is; > } > num *= d2; > den *= n2; > > typedef typename common_type<intermediate_type, unsigned long long>::type common_type_t; > > > > if (!chrono_detail::reduce(r, den, err)) > { > > is.setstate(err|is.failbit); > return is; > } > > > > if (chrono::detail::gt(r,((duration_values<common_type_t>::max)() / num))) > { > > > is.setstate(err|is.failbit); > return is; > } > > common_type_t t = r * num; > t /= den; > > > if (t > 0) > { > > Rep pt = t; > if ( (duration_values<Rep>::max)() < pt) > { > > > is.setstate(err|is.failbit); > return is; > } > } > > > r = Rep(t); > d = duration<Rep, Period>(r); > is.setstate(err); > > return is; > } > else { > > is.setstate(is.failbit | is.eofbit); > return is; > } > } > else > { > > if (i == e) > is.setstate(is.failbit|is.eofbit); > else > is.setstate(is.failbit); > > return is; > } > } > else { > > > return is; > } >} > > >template <class CharT, class Traits, class Clock, class Duration> >std::basic_ostream<CharT, Traits>& >operator<<(std::basic_ostream<CharT, Traits>& os, > const time_point<Clock, Duration>& tp) >{ > return os << tp.time_since_epoch() << clock_string<Clock, CharT>::since(); >} > >template <class CharT, class Traits, class Clock, class Duration> >std::basic_istream<CharT, Traits>& >operator>>(std::basic_istream<CharT, Traits>& is, > time_point<Clock, Duration>& tp) >{ > Duration d; > is >> d; > if (is.good()) > { > const std::basic_string<CharT> units=clock_string<Clock, CharT>::since(); > std::ios_base::iostate err = std::ios_base::goodbit; > typedef std::istreambuf_iterator<CharT, Traits> in_iterator; > in_iterator i(is); > in_iterator e; > std::ptrdiff_t k = chrono_detail::scan_keyword(i, e, > &units, &units + 1, > > err) - &units; > is.setstate(err); > if (k == 1) > { > is.setstate(err | is.failbit); > > return is; > } > tp = time_point<Clock, Duration>(d); > } > else > is.setstate(is.failbit); > return is; >} >} > >} ># 30 "/usr/include/boost/chrono/chrono_io.hpp" 2 3 4 > > ># 1 "/usr/include/boost/chrono/io/utility/to_string.hpp" 1 3 4 ># 15 "/usr/include/boost/chrono/io/utility/to_string.hpp" 3 4 >namespace boost >{ > namespace chrono > { > template <typename CharT, typename T> > std::basic_string<CharT> to_basic_string(T const&v) { > std::basic_stringstream<CharT> sstr; > sstr << v; > return sstr.str(); > } > > template <typename T> > std::string to_string(T const&v) { > return to_basic_string<char>(v); > } > > template <typename T> > std::wstring to_wstring(T const&v) { > return to_basic_string<wchar_t>(v); > } > > > template <typename T> > std::basic_string<char16_t> to_u16string(T const&v) { > return to_basic_string<char16_t>(v); > } > template <typename T> > std::basic_string<char32_t> to_u32string(T const&v) { > return to_basic_string<char32_t>(v); > } > > } > >} ># 33 "/usr/include/boost/chrono/chrono_io.hpp" 2 3 4 ># 17 "/usr/include/boost/chrono/include.hpp" 2 3 4 > ># 1 "/usr/include/boost/chrono/thread_clock.hpp" 1 3 4 ># 19 "/usr/include/boost/chrono/include.hpp" 2 3 4 > ># 1 "/usr/include/boost/chrono/floor.hpp" 1 3 4 ># 16 "/usr/include/boost/chrono/floor.hpp" 3 4 >namespace boost >{ > namespace chrono > { > > > > > template <class To, class Rep, class Period> > To floor(const duration<Rep, Period>& d) > { > return duration_cast<To>(d); > } > > > } >} ># 21 "/usr/include/boost/chrono/include.hpp" 2 3 4 ># 1 "/usr/include/boost/chrono/round.hpp" 1 3 4 ># 18 "/usr/include/boost/chrono/round.hpp" 3 4 >namespace boost >{ > namespace chrono > { > > > > > template <class To, class Rep, class Period> > To round(const duration<Rep, Period>& d) > { > To t0 = duration_cast<To>(d); > To t1 = t0; > ++t1; > > > > > > typedef typename common_type<To, duration<Rep, Period> >::type result_type; > result_type diff0 = d - t0; > result_type diff1 = t1 - d; > > if (diff0 == diff1) > { > if (t0.count() & 1) > return t1; > return t0; > } > else if (diff0 < diff1) > return t0; > return t1; > } > > } >} ># 22 "/usr/include/boost/chrono/include.hpp" 2 3 4 ># 18 "/usr/include/boost/chrono.hpp" 2 3 4 ># 35 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" 2 ># 1 "/usr/include/boost/utility/value_init.hpp" 1 3 4 ># 24 "/usr/include/boost/utility/value_init.hpp" 3 4 ># 1 "/usr/include/boost/aligned_storage.hpp" 1 3 4 ># 27 "/usr/include/boost/aligned_storage.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 28 "/usr/include/boost/aligned_storage.hpp" 2 3 4 > >namespace boost { > >namespace detail { namespace aligned_storage { > >static const std::size_t alignment_of_max_align = ::boost::alignment_of<max_align>::value > > > ; > > > > >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<detail::max_align> > , type_with_alignment<alignment_> > >::type align_; > } data_; > void* address() const { return const_cast<aligned_storage_imp*>(this); } >}; > >template< std::size_t alignment_ > >struct aligned_storage_imp<0u,alignment_> >{ > > void* address() const { return 0; } >}; > >}} > >template < > std::size_t size_ > , std::size_t alignment_ = std::size_t(-1) >> >class aligned_storage : > > private > > > > detail::aligned_storage::aligned_storage_imp<size_, alignment_> >{ > >public: > > typedef detail::aligned_storage::aligned_storage_imp<size_, alignment_> type; > > static const std::size_t size = size_ > > > ; > static const std::size_t alignment = ( alignment_ == std::size_t(-1) ? ::boost::detail::aligned_storage::alignment_of_max_align : alignment_ ) > > > > > > > ; > > > > > > >private: > > aligned_storage(const aligned_storage&); > aligned_storage& operator=(const aligned_storage&); ># 118 "/usr/include/boost/aligned_storage.hpp" 3 4 >public: > > aligned_storage() > { > } > > ~aligned_storage() > { > } > >public: > > void* address() > { > return static_cast<type*>(this)->address(); > } > > > > const void* address() const > { > return static_cast<const type*>(this)->address(); > } > > > > > > > >}; ># 168 "/usr/include/boost/aligned_storage.hpp" 3 4 >template <std::size_t size_, std::size_t alignment_> >struct is_pod<boost::detail::aligned_storage::aligned_storage_imp<size_,alignment_> > > : public ::boost::integral_constant<bool,true> >{ > >}; > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 180 "/usr/include/boost/aligned_storage.hpp" 2 3 4 ># 25 "/usr/include/boost/utility/value_init.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 32 "/usr/include/boost/utility/value_init.hpp" 2 3 4 ># 63 "/usr/include/boost/utility/value_init.hpp" 3 4 >namespace boost { > >template<class T> >class initialized >{ > private : > struct wrapper > { > > typename > > remove_const<T>::type data; > > wrapper() > : > data() > { > } > > wrapper(T const & arg) > : > data(arg) > { > } > }; > > mutable > > typename > > aligned_storage<sizeof(wrapper), alignment_of<wrapper>::value>::type x; > > wrapper * wrapper_address() const > { > return static_cast<wrapper *>( static_cast<void*>(&x)); > } > > public : > > initialized() > { > > > > new (wrapper_address()) wrapper(); > } > > initialized(initialized const & arg) > { > new (wrapper_address()) wrapper( static_cast<wrapper const &>(*(arg.wrapper_address()))); > } > > explicit initialized(T const & arg) > { > new (wrapper_address()) wrapper(arg); > } > > initialized & operator=(initialized const & arg) > { > > static_assert(! is_const<T>::value, "! is_const<T>::value"); > *wrapper_address() = static_cast<wrapper const &>(*(arg.wrapper_address())); > return *this; > } > > ~initialized() > { > wrapper_address()->wrapper::~wrapper(); > } > > T const & data() const > { > return wrapper_address()->data; > } > > T& data() > { > return wrapper_address()->data; > } > > void swap(initialized & arg) > { > ::boost::swap( this->data(), arg.data() ); > } > > operator T const &() const > { > return wrapper_address()->data; > } > > operator T&() > { > return wrapper_address()->data; > } > >} ; > >template<class T> >T const& get ( initialized<T> const& x ) >{ > return x.data() ; >} > >template<class T> >T& get ( initialized<T>& x ) >{ > return x.data() ; >} > >template<class T> >void swap ( initialized<T> & lhs, initialized<T> & rhs ) >{ > lhs.swap(rhs) ; >} > >template<class T> >class value_initialized >{ > private : > > > initialized<T> m_data; > > public : > > value_initialized() > : > m_data() > { } > > T const & data() const > { > return m_data.data(); > } > > T& data() > { > return m_data.data(); > } > > void swap(value_initialized & arg) > { > m_data.swap(arg.m_data); > } > > operator T const &() const > { > return m_data; > } > > operator T&() > { > return m_data; > } >} ; > > >template<class T> >T const& get ( value_initialized<T> const& x ) >{ > return x.data() ; >} > >template<class T> >T& get ( value_initialized<T>& x ) >{ > return x.data() ; >} > >template<class T> >void swap ( value_initialized<T> & lhs, value_initialized<T> & rhs ) >{ > lhs.swap(rhs) ; >} > > >class initialized_value_t >{ > public : > > template <class T> operator T() const > { > return initialized<T>().data(); > } >}; > >initialized_value_t const initialized_value = {} ; > > >} ># 36 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" 2 > ># 1 "/c/honeypenny/contrib/epee/include/misc_language.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/misc_language.h" > > > > > >namespace epee >{ ># 53 "/c/honeypenny/contrib/epee/include/misc_language.h" > template<class base_class> > class namespace_accessor: public base_class{}; ># 64 "/c/honeypenny/contrib/epee/include/misc_language.h" >namespace misc_utils >{ > template<typename t_type> > t_type get_max_t_val(t_type t) > { > return (std::numeric_limits<t_type>::max)(); > } > > > template<typename t_iterator> > t_iterator move_it_forward(t_iterator it, size_t count) > { > while(count--) > it++; > return it; > } > > template<typename t_iterator> > t_iterator move_it_backward(t_iterator it, size_t count) > { > while(count--) > it--; > return it; > } > > > > template<class _Ty> > struct less_as_pod > : public std::binary_function<_Ty, _Ty, bool> > { > bool operator()(const _Ty& _Left, const _Ty& _Right) const > { > return memcmp(&_Left, &_Right, sizeof(_Left)) < 0; > } > }; > > template<class _Ty> > bool is_less_as_pod(const _Ty& _Left, const _Ty& _Right) > { > return memcmp(&_Left, &_Right, sizeof(_Left)) < 0; > } > > > inline > bool sleep_no_w(long ms ) > { > boost::this_thread::sleep( > boost::get_system_time() + > boost::posix_time::milliseconds( std::max<long>(ms,0) ) ); > > return true; > } > > template<class type_vec_type> > type_vec_type median(std::vector<type_vec_type> &v) > { > if(v.empty()) > return boost::value_initialized<type_vec_type>(); > if(v.size() == 1) > return v[0]; > > size_t n = (v.size()) / 2; > std::sort(v.begin(), v.end()); > > if(v.size()%2) > { > return v[n]; > }else > { > return (v[n-1] + v[n])/2; > } > > } > > > > > > struct call_befor_die_base > { > virtual ~call_befor_die_base(){} > }; > > typedef boost::shared_ptr<call_befor_die_base> auto_scope_leave_caller; > > > template<class t_scope_leave_handler> > struct call_befor_die: public call_befor_die_base > { > t_scope_leave_handler m_func; > call_befor_die(t_scope_leave_handler f):m_func(f) > {} > ~call_befor_die() > { > m_func(); > } > }; > > template<class t_scope_leave_handler> > auto_scope_leave_caller create_scope_leave_handler(t_scope_leave_handler f) > { > auto_scope_leave_caller slc(new call_befor_die<t_scope_leave_handler>(f)); > return slc; > } > > template< typename t_contaner, typename t_redicate> > void erase_if( t_contaner& items, const t_redicate& predicate ) > { > for(auto it = items.begin(); it != items.end(); ) > { > if( predicate(*it) ) > it = items.erase(it); > else > ++it; > } > }; > > >} >} ># 38 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" 2 ># 40 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" >#pragma GCC diagnostic push ># 40 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" > >namespace epee >{ >namespace net_utils >{ > > > > > > template<class t_protocol_handler> > connection<t_protocol_handler>::connection(boost::asio::io_service& io_service, > typename t_protocol_handler::config_type& config, volatile uint32_t& sock_count, i_connection_filter* &pfilter) > : strand_(io_service), > socket_(io_service), > m_protocol_handler(this, config, context), > m_want_close_connection(0), > m_was_shutdown(0), > m_ref_sockets_count(sock_count), > m_pfilter(pfilter) > { > boost::interprocess::ipcdetail::atomic_inc32(&m_ref_sockets_count); > } > > > template<class t_protocol_handler> > connection<t_protocol_handler>::~connection() > { > if(!m_was_shutdown) > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] Socket destroyed without shutdown." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > shutdown(); > } > > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] Socket destroyed" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > boost::interprocess::ipcdetail::atomic_dec32(&m_ref_sockets_count); > } > > template<class t_protocol_handler> > boost::asio::ip::tcp::socket& connection<t_protocol_handler>::socket() > { > return socket_; > } > > template<class t_protocol_handler> > boost::shared_ptr<connection<t_protocol_handler> > connection<t_protocol_handler>::safe_shared_from_this() > { > try > { > return connection<t_protocol_handler>::shared_from_this(); > } > catch (const boost::bad_weak_ptr&) > { > > return boost::shared_ptr<connection<t_protocol_handler> >(); > } > } > > template<class t_protocol_handler> > bool connection<t_protocol_handler>::start(bool is_income, bool is_multithreaded) > { > try {; > > > auto self = safe_shared_from_this(); > if(!self) > return false; > > m_is_multithreaded = is_multithreaded; > > boost::system::error_code ec; > auto remote_ep = socket_.remote_endpoint(ec); > do{if(!(!ec)) {{if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to get remote endpoint: " << ec.message() << ':' << ec.value() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; return false;};}while(0); > > auto local_ep = socket_.local_endpoint(ec); > do{if(!(!ec)) {{if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to get local endpoint: " << ec.message() << ':' << ec.value() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; return false;};}while(0); > > context = boost::value_initialized<t_connection_context>(); > long ip_ = boost::asio::detail::socket_ops::host_to_network_long(remote_ep.address().to_v4().to_ulong()); > > context.set_details(boost::uuids::random_generator()(), ip_, remote_ep.port(), is_income); > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] new connection from " << print_connection_context_short(context) << " to " << local_ep.address().to_string() << ':' << local_ep.port() << ", total sockets objects " << m_ref_sockets_count << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}} > > ; > > if(m_pfilter && !m_pfilter->is_remote_ip_allowed(context.m_remote_ip)) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] ip denied " << string_tools::get_ip_string_from_int32(context.m_remote_ip) << ", shutdowning connection" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > close(); > return false; > } > > m_protocol_handler.after_init_connection(); > > socket_.async_read_some(boost::asio::buffer(buffer_), > strand_.wrap( > boost::bind(&connection<t_protocol_handler>::handle_read, self, > boost::asio::placeholders::error, > boost::asio::placeholders::bytes_transferred))); > > return true; > > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 142 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::start()" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 142 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::start()" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > bool connection<t_protocol_handler>::request_callback() > { > try {; > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << print_connection_context_short(context) << "] request_callback" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > > auto self = safe_shared_from_this(); > if(!self) > return false; > > strand_.post(boost::bind(&connection<t_protocol_handler>::call_back_starter, self)); > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 156 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::request_callback()" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 156 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::request_callback()" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > return true; > } > > template<class t_protocol_handler> > boost::asio::io_service& connection<t_protocol_handler>::get_io_service() > { > return socket_.get_io_service(); > } > > template<class t_protocol_handler> > bool connection<t_protocol_handler>::add_ref() > { > try {; > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] add_ref" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > epee::critical_region_t<decltype(m_self_refs_lock)> critical_region_var(m_self_refs_lock); > > > auto self = safe_shared_from_this(); > if(!self) > return false; > if(m_was_shutdown) > return false; > m_self_refs.push_back(self); > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 181 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::add_ref()" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 181 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::add_ref()" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > bool connection<t_protocol_handler>::release() > { > try {; > boost::shared_ptr<connection<t_protocol_handler> > back_connection_copy; > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] release" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > { epee::critical_region_t<decltype(m_self_refs_lock)> critical_region_var(m_self_refs_lock); > do{if(!(m_self_refs.size())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 191 << "|" << __FUNCTION__ << "|" << "[sock " << socket_.native_handle() << "] m_self_refs empty at connection<t_protocol_handler>::release() call" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > back_connection_copy = m_self_refs.back(); > m_self_refs.pop_back(); > }; > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 197 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::release()" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 197 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::release()" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > void connection<t_protocol_handler>::call_back_starter() > { > try {; > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << print_connection_context_short(context) << "] fired_callback" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > m_protocol_handler.handle_qued_callback(); > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 206 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::call_back_starter()" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 206 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::call_back_starter()" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); }; > } > > template<class t_protocol_handler> > void connection<t_protocol_handler>::handle_read(const boost::system::error_code& e, > std::size_t bytes_transferred) > { > try {; > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] Assync read calledback." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > > if (!e) > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] RECV " << bytes_transferred << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > context.m_last_recv = time(__null); > context.m_recv_cnt += bytes_transferred; > bool recv_res = m_protocol_handler.handle_recv(buffer_.data(), bytes_transferred); > if(!recv_res) > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] protocol_want_close" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > > > boost::interprocess::ipcdetail::atomic_write32(&m_want_close_connection, 1); > bool do_shutdown = false; > { epee::critical_region_t<decltype(m_send_que_lock)> critical_region_var(m_send_que_lock); > if(!m_send_que.size()) > do_shutdown = true; > }; > if(do_shutdown) > shutdown(); > }else > { > socket_.async_read_some(boost::asio::buffer(buffer_), > strand_.wrap( > boost::bind(&connection<t_protocol_handler>::handle_read, connection<t_protocol_handler>::shared_from_this(), > boost::asio::placeholders::error, > boost::asio::placeholders::bytes_transferred))); > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "]Assync read requested." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > } > }else > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] Some not success at read: " << e.message() << ':' << e.value() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > if(e.value() != 2) > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] Some problems at read: " << e.message() << ':' << e.value() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > shutdown(); > } > } > > > > > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 257 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::handle_read" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 257 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::handle_read" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); }; > } > > template<class t_protocol_handler> > bool connection<t_protocol_handler>::call_run_once_service_io() > { > try {; > if(!m_is_multithreaded) > { > > size_t cnt = socket_.get_io_service().run_one(); > if(!cnt) > return false; > }else > { > > > > > > size_t cnt = socket_.get_io_service().poll_one(); > if(!cnt) > misc_utils::sleep_no_w(0); > } > > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 283 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::call_run_once_service_io" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 283 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::call_run_once_service_io" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > bool connection<t_protocol_handler>::do_send(const void* ptr, size_t cb) > { > try {; > > auto self = safe_shared_from_this(); > if(!self) > return false; > if(m_was_shutdown) > return false; > > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] SEND " << cb << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > context.m_last_send = time(__null); > context.m_send_cnt += cb; > > > > epee::critical_region_t<decltype(m_send_que_lock)> send_guard(m_send_que_lock); > if(m_send_que.size() > 100) > { > send_guard.unlock(); > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 307 << "|" << __FUNCTION__ << "|" << "send que size is more than ABSTRACT_SERVER_SEND_QUE_MAX_COUNT(" << 100 << "), shutting down connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > close(); > return false; > } > > m_send_que.resize(m_send_que.size()+1); > m_send_que.back().assign((const char*)ptr, cb); > > if(m_send_que.size() > 1) > { > > }else > { > > if(m_send_que.size()!=1) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 323 << "|" << __FUNCTION__ << "|" << "Looks like no active operations, but send que size != 1!!" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > boost::asio::async_write(socket_, boost::asio::buffer(m_send_que.front().data(), m_send_que.front().size()), > > boost::bind(&connection<t_protocol_handler>::handle_write, self, _1, _2) > > ); > > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] Assync send requested " << m_send_que.front().size() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > } > > return true; > > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 338 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::do_send" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 338 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::do_send" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > bool connection<t_protocol_handler>::shutdown() > { > > boost::system::error_code ignored_ec; > socket_.shutdown(boost::asio::ip::tcp::socket::shutdown_both, ignored_ec); > m_was_shutdown = true; > m_protocol_handler.release_protocol(); > return true; > } > > template<class t_protocol_handler> > bool connection<t_protocol_handler>::close() > { > try {; > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] Que Shutdown called." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > size_t send_que_size = 0; > { epee::critical_region_t<decltype(m_send_que_lock)> critical_region_var(m_send_que_lock); > send_que_size = m_send_que.size(); > }; > boost::interprocess::ipcdetail::atomic_write32(&m_want_close_connection, 1); > if(!send_que_size) > { > shutdown(); > } > > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 368 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::close" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 368 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::close" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > void connection<t_protocol_handler>::handle_write(const boost::system::error_code& e, size_t cb) > { > try {; > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] Assync send calledback " << cb << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > > if (e) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << socket_.native_handle() << "] Some problems at write: " << e.message() << ':' << e.value() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > shutdown(); > return; > } > > bool do_shutdown = false; > { epee::critical_region_t<decltype(m_send_que_lock)> critical_region_var(m_send_que_lock); > if(m_send_que.empty()) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 388 << "|" << __FUNCTION__ << "|" << "[sock " << socket_.native_handle() << "] m_send_que.size() == 0 at handle_write!" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return; > } > > m_send_que.pop_front(); > if(m_send_que.empty()) > { > if(boost::interprocess::ipcdetail::atomic_read32(&m_want_close_connection)) > { > do_shutdown = true; > } > }else > { > > boost::asio::async_write(socket_, boost::asio::buffer(m_send_que.front().data(), m_send_que.front().size()), > > boost::bind(&connection<t_protocol_handler>::handle_write, connection<t_protocol_handler>::shared_from_this(), _1, _2)); > > } > }; > > if(do_shutdown) > { > shutdown(); > } > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 413 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::handle_write" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 413 << "|" << __FUNCTION__ << "|" << "Exception at [" << "connection<t_protocol_handler>::handle_write" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); }; > } > > > > template<class t_protocol_handler> > boosted_tcp_server<t_protocol_handler>::boosted_tcp_server(): > m_io_service_local_instance(new boost::asio::io_service()), > io_service_(*m_io_service_local_instance.get()), > acceptor_(io_service_), > new_connection_(new connection<t_protocol_handler>(io_service_, m_config, m_sockets_count, m_pfilter)), > m_stop_signal_sent(false), m_port(0), m_sockets_count(0), m_threads_count(0), m_pfilter(__null), m_thread_index(0) > { > m_thread_name_prefix = "NET"; > } > > template<class t_protocol_handler> > boosted_tcp_server<t_protocol_handler>::boosted_tcp_server(boost::asio::io_service& extarnal_io_service): > io_service_(extarnal_io_service), > acceptor_(io_service_), > new_connection_(new connection<t_protocol_handler>(io_service_, m_config, m_sockets_count, m_pfilter)), > m_stop_signal_sent(false), m_port(0), m_sockets_count(0), m_threads_count(0), m_pfilter(__null), m_thread_index(0) > { > m_thread_name_prefix = "NET"; > } > > template<class t_protocol_handler> > boosted_tcp_server<t_protocol_handler>::~boosted_tcp_server() > { > this->send_stop_signal(); > timed_wait_server_stop(10000); > } > > template<class t_protocol_handler> > bool boosted_tcp_server<t_protocol_handler>::init_server(uint32_t port, const std::string address) > { > try {; > m_stop_signal_sent = false; > m_port = port; > m_address = address; > > boost::asio::ip::tcp::resolver resolver(io_service_); > boost::asio::ip::tcp::resolver::query query(address, boost::lexical_cast<std::string>(port)); > boost::asio::ip::tcp::endpoint endpoint = *resolver.resolve(query); > acceptor_.open(endpoint.protocol()); > acceptor_.set_option(boost::asio::ip::tcp::acceptor::reuse_address(true)); > acceptor_.bind(endpoint); > acceptor_.listen(); > boost::asio::ip::tcp::endpoint binded_endpoint = acceptor_.local_endpoint(); > m_port = binded_endpoint.port(); > acceptor_.async_accept(new_connection_->socket(), > boost::bind(&boosted_tcp_server<t_protocol_handler>::handle_accept, this, > boost::asio::placeholders::error)); > > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 468 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::init_server" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 468 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::init_server" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } ># 471 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" >#pragma GCC diagnostic push ># 471 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" ># 472 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" >#pragma GCC diagnostic ignored "-Wmaybe-uninitialized" ># 472 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" > > template<class t_protocol_handler> > bool boosted_tcp_server<t_protocol_handler>::init_server(const std::string port, const std::string& address) > { > uint32_t p = 0; > > if (port.size() && !string_tools::get_xtype_from_string(p, port)) { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 479 << "|" << __FUNCTION__ << "|" << "Failed to convert port no = " << port << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > return this->init_server(p, address); > } ># 484 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" >#pragma GCC diagnostic pop ># 484 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" > > > template<class t_protocol_handler> > bool boosted_tcp_server<t_protocol_handler>::worker_thread() > { > try {; > uint32_t local_thr_index = boost::interprocess::ipcdetail::atomic_inc32(&m_thread_index); > std::string thread_name = std::string("[") + m_thread_name_prefix; > thread_name += boost::to_string(local_thr_index) + "]"; > log_space::log_singletone::set_thread_log_prefix(thread_name); > while(!m_stop_signal_sent) > { > try > { > io_service_.run(); > } > catch(const std::exception& ex) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 502 << "|" << __FUNCTION__ << "|" << "Exception at server worker thread, what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > } > catch(...) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 506 << "|" << __FUNCTION__ << "|" << "Exception at server worker thread, unknown execption" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > } > } > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Worker thread finished" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 511 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::worker_thread" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 511 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::worker_thread" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > void boosted_tcp_server<t_protocol_handler>::set_threads_prefix(const std::string& prefix_name) > { > m_thread_name_prefix = prefix_name; > } > > template<class t_protocol_handler> > void boosted_tcp_server<t_protocol_handler>::set_connection_filter(i_connection_filter* pfilter) > { > m_pfilter = pfilter; > } > > template<class t_protocol_handler> > bool boosted_tcp_server<t_protocol_handler>::run_server(size_t threads_count, bool wait) > { > try {; > m_threads_count = threads_count; > m_main_thread_id = boost::this_thread::get_id(); > log_space::log_singletone::set_thread_log_prefix("[SRV_MAIN]"); > while(!m_stop_signal_sent) > { > > > { epee::critical_region_t<decltype(m_threads_lock)> critical_region_var(m_threads_lock); > for (std::size_t i = 0; i < threads_count; ++i) > { > boost::shared_ptr<boost::thread> thread(new boost::thread( > boost::bind(&boosted_tcp_server<t_protocol_handler>::worker_thread, this))); > m_threads.push_back(thread); > } > }; > > if(wait) > { > for (std::size_t i = 0; i < m_threads.size(); ++i) > m_threads[i]->join(); > m_threads.clear(); > > }else > { > return true; > } > > if(wait && !m_stop_signal_sent) > { > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Net service stopped without stop request, restarting..." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > if(!this->init_server(m_port, m_address)) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Reiniting service failed, exit." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return false; > }else > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Reiniting OK." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > } > } > } > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 572 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::run_server" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 572 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::run_server" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > bool boosted_tcp_server<t_protocol_handler>::is_thread_worker() > { > try {; > epee::critical_region_t<decltype(m_threads_lock)> critical_region_var(m_threads_lock); > if (boost::foreach_detail_::auto_any_t _foreach_col580 = boost::foreach_detail_::contain( (m_threads) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((m_threads), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(m_threads) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(m_threads) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur580 = boost::foreach_detail_::begin( _foreach_col580 , (true ? 0 : boost::foreach_detail_::encode_type(m_threads, boost::foreach_detail_::is_const_(m_threads))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((m_threads), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(m_threads) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(m_threads) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end580 = boost::foreach_detail_::end( _foreach_col580 , (true ? 0 : boost::foreach_detail_::encode_type(m_threads, boost::foreach_detail_::is_const_(m_threads))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((m_threads), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(m_threads) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(m_threads) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue580 = true; _foreach_continue580 && !boost::foreach_detail_::done( _foreach_cur580 , _foreach_end580 , (true ? 0 : boost::foreach_detail_::encode_type(m_threads, boost::foreach_detail_::is_const_(m_threads)))); _foreach_continue580 ? boost::foreach_detail_::next( _foreach_cur580 , (true ? 0 : boost::foreach_detail_::encode_type(m_threads, boost::foreach_detail_::is_const_(m_threads)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue580)) {} else for (boost::shared_ptr<boost::thread>& thp = boost::foreach_detail_::deref( _foreach_cur580 , (true ? 0 : boost::foreach_detail_::encode_type(m_threads, boost::foreach_detail_::is_const_(m_threads)))); !_foreach_continue580; _foreach_continue580 = true) > { > if(thp->get_id() == boost::this_thread::get_id()) > return true; > } > if(m_threads_count == 1 && boost::this_thread::get_id() == m_main_thread_id) > return true; > return false; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 588 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::is_thread_worker" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 588 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::is_thread_worker" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > bool boosted_tcp_server<t_protocol_handler>::timed_wait_server_stop(uint64_t wait_mseconds) > { > try {; > boost::chrono::milliseconds ms(wait_mseconds); > for (std::size_t i = 0; i < m_threads.size(); ++i) > { > if(m_threads[i]->joinable() && !m_threads[i]->try_join_for(ms)) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Interrupting thread " << m_threads[i]->native_handle() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > m_threads[i]->interrupt(); > } > } > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 605 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::timed_wait_server_stop" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 605 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::timed_wait_server_stop" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> > void boosted_tcp_server<t_protocol_handler>::send_stop_signal() > { > m_stop_signal_sent = true; > try {; > io_service_.stop(); > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 614 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::send_stop_signal()" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 614 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::send_stop_signal()" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); }; > } > > template<class t_protocol_handler> > bool boosted_tcp_server<t_protocol_handler>::is_stop_signal_sent() > { > return m_stop_signal_sent; > } > > template<class t_protocol_handler> > void boosted_tcp_server<t_protocol_handler>::handle_accept(const boost::system::error_code& e) > { > try {; > if (!e) > { > connection_ptr conn(std::move(new_connection_)); > > new_connection_.reset(new connection<t_protocol_handler>(io_service_, m_config, m_sockets_count, m_pfilter)); > acceptor_.async_accept(new_connection_->socket(), > boost::bind(&boosted_tcp_server<t_protocol_handler>::handle_accept, this, > boost::asio::placeholders::error)); > > bool r = conn->start(true, 1 < m_threads_count); > if (!r) > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 638 << "|" << __FUNCTION__ << "|" << "[sock " << conn->socket().native_handle() << "] Failed to start connection, connections_count = " << m_sockets_count << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > }else > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 641 << "|" << __FUNCTION__ << "|" << "Some problems at accept: " << e.message() << ", connections_count = " << m_sockets_count << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > } > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 643 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::handle_accept" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 643 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::handle_accept" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void(); }; > } > > template<class t_protocol_handler> > bool boosted_tcp_server<t_protocol_handler>::connect(const std::string& adr, const std::string& port, uint32_t conn_timeout, t_connection_context& conn_context, const std::string& bind_ip) > { > try {; > > connection_ptr new_connection_l(new connection<t_protocol_handler>(io_service_, m_config, m_sockets_count, m_pfilter) ); > boost::asio::ip::tcp::socket& sock_ = new_connection_l->socket(); > > > boost::asio::ip::tcp::resolver resolver(io_service_); > boost::asio::ip::tcp::resolver::query query(boost::asio::ip::tcp::v4(), adr, port); > boost::asio::ip::tcp::resolver::iterator iterator = resolver.resolve(query); > boost::asio::ip::tcp::resolver::iterator end; > if(iterator == end) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 661 << "|" << __FUNCTION__ << "|" << "Failed to resolve " << adr << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > > > > boost::asio::ip::tcp::endpoint remote_endpoint(*iterator); > > sock_.open(remote_endpoint.protocol()); > if(bind_ip != "0.0.0.0" && bind_ip != "0" && bind_ip != "" ) > { > boost::asio::ip::tcp::endpoint local_endpoint(boost::asio::ip::address::from_string(adr.c_str()), 0); > sock_.bind(local_endpoint); > } > > > > > > boost::system::error_code ec = boost::asio::error::would_block; > > > struct local_async_context > { > boost::system::error_code ec; > boost::mutex connect_mut; > boost::condition_variable cond; > }; > > boost::shared_ptr<local_async_context> local_shared_context(new local_async_context()); > local_shared_context->ec = boost::asio::error::would_block; > boost::unique_lock<boost::mutex> lock(local_shared_context->connect_mut); > auto connect_callback = [](boost::system::error_code ec_, boost::shared_ptr<local_async_context> shared_context) > { > shared_context->connect_mut.lock(); shared_context->ec = ec_; shared_context->connect_mut.unlock(); shared_context->cond.notify_one(); > }; > > sock_.async_connect(remote_endpoint, boost::bind<void>(connect_callback, _1, local_shared_context)); > while(local_shared_context->ec == boost::asio::error::would_block) > { > bool r = local_shared_context->cond.timed_wait(lock, boost::get_system_time() + boost::posix_time::milliseconds(conn_timeout)); > if(local_shared_context->ec == boost::asio::error::would_block && !r) > { > > sock_.close(); > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to connect to " << adr << ":" << port << ", because of timeout (" << conn_timeout << ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > return false; > } > } > ec = local_shared_context->ec; > > if (ec || !sock_.is_open()) > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Some problems at connect, message: " << ec.message() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > return false; > } > > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Connected success to " << adr << ':' << port << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > > bool r = new_connection_l->start(false, 1 < m_threads_count); > if (r) > { > new_connection_l->get_context(conn_context); > > } > else > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 729 << "|" << __FUNCTION__ << "|" << "[sock " << new_connection_->socket().native_handle() << "] Failed to start connection, connections_count = " << m_sockets_count << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > } > > return r; > > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 734 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::connect" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 734 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::connect" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_protocol_handler> template<class t_callback> > bool boosted_tcp_server<t_protocol_handler>::connect_async(const std::string& adr, const std::string& port, uint32_t conn_timeout, t_callback cb, const std::string& bind_ip) > { > try {; > connection_ptr new_connection_l(new connection<t_protocol_handler>(io_service_, m_config, m_sockets_count, m_pfilter) ); > boost::asio::ip::tcp::socket& sock_ = new_connection_l->socket(); > > > boost::asio::ip::tcp::resolver resolver(io_service_); > boost::asio::ip::tcp::resolver::query query(boost::asio::ip::tcp::v4(), adr, port); > boost::asio::ip::tcp::resolver::iterator iterator = resolver.resolve(query); > boost::asio::ip::tcp::resolver::iterator end; > if(iterator == end) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 751 << "|" << __FUNCTION__ << "|" << "Failed to resolve " << adr << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > boost::asio::ip::tcp::endpoint remote_endpoint(*iterator); > > sock_.open(remote_endpoint.protocol()); > if(bind_ip != "0.0.0.0" && bind_ip != "0" && bind_ip != "" ) > { > boost::asio::ip::tcp::endpoint local_endpoint(boost::asio::ip::address::from_string(adr.c_str()), 0); > sock_.bind(local_endpoint); > } > > boost::shared_ptr<boost::asio::deadline_timer> sh_deadline(new boost::asio::deadline_timer(io_service_)); > > sh_deadline->expires_from_now(boost::posix_time::milliseconds(conn_timeout)); > sh_deadline->async_wait([=](const boost::system::error_code& error) > { > if(error != boost::asio::error::operation_aborted) > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to connect to " << adr << ':' << port << ", because of timeout (" << conn_timeout << ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > new_connection_l->socket().close(); > } > }); > > sock_.async_connect(remote_endpoint, [=](const boost::system::error_code& ec_) > { > t_connection_context conn_context = boost::value_initialized<decltype(conn_context)>(); > boost::system::error_code ignored_ec; > boost::asio::ip::tcp::socket::endpoint_type lep = new_connection_l->socket().local_endpoint(ignored_ec); > if(!ec_) > { > if(!sh_deadline->cancel()) > { > cb(conn_context, boost::asio::error::operation_aborted); > }else > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << new_connection_l->socket().native_handle() << "] Connected success to " << adr << ':' << port << " from " << lep.address().to_string() << ':' << lep.port() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}} > ; > bool r = new_connection_l->start(false, 1 < m_threads_count); > if (r) > { > new_connection_l->get_context(conn_context); > cb(conn_context, ec_); > } > else > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << new_connection_l->socket().native_handle() << "] Failed to start connection to " << adr << ':' << port << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > cb(conn_context, boost::asio::error::fault); > } > } > }else > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[sock " << new_connection_l->socket().native_handle() << "] Failed to connect to " << adr << ':' << port << " from " << lep.address().to_string() << ':' << lep.port() << ": " << ec_.message() << ':' << ec_.value() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}} > ; > cb(conn_context, ec_); > } > }); > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 810 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::connect_async" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" << ":" << 810 << "|" << __FUNCTION__ << "|" << "Exception at [" << "boosted_tcp_server<t_protocol_handler>::connect_async" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } >} >} ># 814 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" >#pragma GCC diagnostic pop ># 814 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.inl" ># 275 "/c/honeypenny/contrib/epee/include/net/abstract_tcp_server2.h" 2 ># 34 "/c/honeypenny/contrib/epee/include/net/http_server_cp2.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.h" 1 ># 35 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.h" ># 1 "/c/honeypenny/contrib/epee/include/to_nonconst_iterator.h" 1 ># 32 "/c/honeypenny/contrib/epee/include/to_nonconst_iterator.h" >namespace epee >{ > >template<class Type> >typename Type::iterator to_nonsonst_iterator(Type& obj, typename Type::const_iterator it) >{ > typename Type::difference_type dist = std::distance(static_cast<typename Type::const_iterator>(obj.begin()), it); > typename Type::iterator res_it = obj.begin()+dist; > return res_it; >} > > >template<class Type> >typename Type::iterator to_nonsonst_iterator(typename Type::iterator base_it, typename Type::const_iterator it) >{ > typename Type::difference_type dist = std::distance(static_cast<typename Type::const_iterator>(base_it), it); > typename Type::iterator res_it = base_it+dist; > return res_it; >} >} ># 36 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/net/http_base.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/net/http_base.h" > > ># 1 "/usr/include/boost/regex.hpp" 1 3 4 ># 31 "/usr/include/boost/regex.hpp" 3 4 ># 1 "/usr/include/boost/regex/v4/regex.hpp" 1 3 4 ># 32 "/usr/include/boost/regex/v4/regex.hpp" 3 4 ># 1 "/usr/include/boost/regex/v4/regex_workaround.hpp" 1 3 4 ># 24 "/usr/include/boost/regex/v4/regex_workaround.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 25 "/usr/include/boost/regex/v4/regex_workaround.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 26 "/usr/include/boost/regex/v4/regex_workaround.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/cassert" 1 3 4 ># 41 "/usr/include/c++/4.9.0/cassert" 3 4 ># 42 "/usr/include/c++/4.9.0/cassert" 3 > ># 1 "/usr/include/assert.h" 1 3 4 ># 43 "/usr/include/c++/4.9.0/cassert" 2 3 ># 28 "/usr/include/boost/regex/v4/regex_workaround.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/cstdio" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdio" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdio" 3 ># 29 "/usr/include/boost/regex/v4/regex_workaround.hpp" 2 3 4 ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 30 "/usr/include/boost/regex/v4/regex_workaround.hpp" 2 3 4 ># 38 "/usr/include/boost/regex/v4/regex_workaround.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 39 "/usr/include/boost/regex/v4/regex_workaround.hpp" 2 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 40 "/usr/include/boost/regex/v4/regex_workaround.hpp" 2 3 4 ># 55 "/usr/include/boost/regex/v4/regex_workaround.hpp" 3 4 >namespace boost{ namespace re_detail{ > > > > > >using std::distance; > >}} ># 97 "/usr/include/boost/regex/v4/regex_workaround.hpp" 3 4 >namespace boost{ namespace re_detail{ > > > > > > >template <class T> >inline void pointer_destroy(T* p) >{ p->~T(); (void)p; } > > > > > >template <class T> >inline void pointer_construct(T* p, const T& t) >{ new (p) T(t); } > >}} ># 126 "/usr/include/boost/regex/v4/regex_workaround.hpp" 3 4 >namespace boost{ namespace re_detail{ ># 184 "/usr/include/boost/regex/v4/regex_workaround.hpp" 3 4 > using std::copy; > using std::equal; > > > > > > > > inline std::size_t strcpy_s( > char *strDestination, > std::size_t sizeInBytes, > const char *strSource > ) > { > if(std::strlen(strSource)+1 > sizeInBytes) > return 1; > std::strcpy(strDestination, strSource); > return 0; > } > inline std::size_t strcat_s( > char *strDestination, > std::size_t sizeInBytes, > const char *strSource > ) > { > if(std::strlen(strSource) + std::strlen(strDestination) + 1 > sizeInBytes) > return 1; > std::strcat(strDestination, strSource); > return 0; > } > > > > inline void overflow_error_if_not_zero(std::size_t i) > { > if(i) > { > std::overflow_error e("String buffer too small"); > boost::throw_exception(e); > } > } > >}} ># 33 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/regex/regex_traits.hpp" 1 3 4 ># 27 "/usr/include/boost/regex/regex_traits.hpp" 3 4 ># 1 "/usr/include/boost/regex/v4/regex_traits.hpp" 1 3 4 ># 29 "/usr/include/boost/regex/v4/regex_traits.hpp" 3 4 ># 1 "/usr/include/boost/regex/v4/syntax_type.hpp" 1 3 4 ># 22 "/usr/include/boost/regex/v4/syntax_type.hpp" 3 4 >namespace boost{ >namespace regex_constants{ > >typedef unsigned char syntax_type; > > > > >static const syntax_type syntax_char = 0; >static const syntax_type syntax_open_mark = 1; >static const syntax_type syntax_close_mark = 2; >static const syntax_type syntax_dollar = 3; >static const syntax_type syntax_caret = 4; >static const syntax_type syntax_dot = 5; >static const syntax_type syntax_star = 6; >static const syntax_type syntax_plus = 7; >static const syntax_type syntax_question = 8; >static const syntax_type syntax_open_set = 9; >static const syntax_type syntax_close_set = 10; >static const syntax_type syntax_or = 11; >static const syntax_type syntax_escape = 12; >static const syntax_type syntax_dash = 14; >static const syntax_type syntax_open_brace = 15; >static const syntax_type syntax_close_brace = 16; >static const syntax_type syntax_digit = 17; >static const syntax_type syntax_comma = 27; >static const syntax_type syntax_equal = 37; >static const syntax_type syntax_colon = 36; >static const syntax_type syntax_not = 53; > > > >static const syntax_type syntax_hash = 13; >static const syntax_type syntax_newline = 26; > > > >typedef syntax_type escape_syntax_type; > >static const escape_syntax_type escape_type_word_assert = 18; >static const escape_syntax_type escape_type_not_word_assert = 19; >static const escape_syntax_type escape_type_control_f = 29; >static const escape_syntax_type escape_type_control_n = 30; >static const escape_syntax_type escape_type_control_r = 31; >static const escape_syntax_type escape_type_control_t = 32; >static const escape_syntax_type escape_type_control_v = 33; >static const escape_syntax_type escape_type_ascii_control = 35; >static const escape_syntax_type escape_type_hex = 34; >static const escape_syntax_type escape_type_unicode = 0; >static const escape_syntax_type escape_type_identity = 0; >static const escape_syntax_type escape_type_backref = syntax_digit; >static const escape_syntax_type escape_type_decimal = syntax_digit; >static const escape_syntax_type escape_type_class = 22; >static const escape_syntax_type escape_type_not_class = 23; > > > >static const escape_syntax_type escape_type_left_word = 20; >static const escape_syntax_type escape_type_right_word = 21; >static const escape_syntax_type escape_type_start_buffer = 24; >static const escape_syntax_type escape_type_end_buffer = 25; >static const escape_syntax_type escape_type_control_a = 28; >static const escape_syntax_type escape_type_e = 38; >static const escape_syntax_type escape_type_E = 47; >static const escape_syntax_type escape_type_Q = 48; >static const escape_syntax_type escape_type_X = 49; >static const escape_syntax_type escape_type_C = 50; >static const escape_syntax_type escape_type_Z = 51; >static const escape_syntax_type escape_type_G = 52; > >static const escape_syntax_type escape_type_property = 54; >static const escape_syntax_type escape_type_not_property = 55; >static const escape_syntax_type escape_type_named_char = 56; >static const escape_syntax_type escape_type_extended_backref = 57; >static const escape_syntax_type escape_type_reset_start_mark = 58; >static const escape_syntax_type escape_type_line_ending = 59; > >static const escape_syntax_type syntax_max = 60; > >} >} ># 30 "/usr/include/boost/regex/v4/regex_traits.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/error_type.hpp" 1 3 4 ># 23 "/usr/include/boost/regex/v4/error_type.hpp" 3 4 >namespace boost{ > > > >namespace regex_constants{ > >enum error_type{ > > error_ok = 0, > error_no_match = 1, > error_bad_pattern = 2, > error_collate = 3, > error_ctype = 4, > error_escape = 5, > error_backref = 6, > error_brack = 7, > error_paren = 8, > error_brace = 9, > error_badbrace = 10, > error_range = 11, > error_space = 12, > error_badrepeat = 13, > error_end = 14, > error_size = 15, > error_right_paren = 16, > error_empty = 17, > error_complexity = 18, > error_stack = 19, > error_perl_extension = 20, > error_unknown = 21 >}; > >} >} ># 33 "/usr/include/boost/regex/v4/regex_traits.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_traits_defaults.hpp" 1 3 4 ># 46 "/usr/include/boost/regex/v4/regex_traits_defaults.hpp" 3 4 >namespace boost{ namespace re_detail{ > > > > > >template <class charT> >inline bool is_extended(charT c) >{ return c > 256; } >inline bool is_extended(char) >{ return false; } > > > const char* get_default_syntax(regex_constants::syntax_type n); > const char* get_default_error_string(regex_constants::error_type n); > regex_constants::syntax_type get_default_syntax_type(char c); > regex_constants::escape_syntax_type get_default_escape_syntax_type(char c); > > > bool is_combining_implementation(uint_least16_t s); > >template <class charT> >inline bool is_combining(charT c) >{ > return (c <= static_cast<charT>(0)) ? false : ((c >= static_cast<charT>((std::numeric_limits<uint_least16_t>::max)())) ? false : is_combining_implementation(static_cast<unsigned short>(c))); >} >template <> >inline bool is_combining<char>(char) >{ > return false; >} >template <> >inline bool is_combining<signed char>(signed char) >{ > return false; >} >template <> >inline bool is_combining<unsigned char>(unsigned char) >{ > return false; >} ># 114 "/usr/include/boost/regex/v4/regex_traits_defaults.hpp" 3 4 >template <class charT> >inline bool is_separator(charT c) >{ > return static_cast<bool>((c == static_cast<charT>('\n')) || (c == static_cast<charT>('\r')) || (c == static_cast<charT>('\f')) || (static_cast<boost::uint16_t>(c) == 0x2028u) || (static_cast<boost::uint16_t>(c) == 0x2029u) || (static_cast<boost::uint16_t>(c) == 0x85u)) > > > > > > ; >} >template <> >inline bool is_separator<char>(char c) >{ > return static_cast<bool>((c == '\n') || (c == '\r') || (c == '\f')); >} > > > > > std::string lookup_default_collate_name(const std::string& name); > > > > > >template <class charT> >struct character_pointer_range >{ > const charT* p1; > const charT* p2; > > bool operator < (const character_pointer_range& r)const > { > return std::lexicographical_compare(p1, p2, r.p1, r.p2); > } > bool operator == (const character_pointer_range& r)const > { > > > > > return ((p2 - p1) == (r.p2 - r.p1)) && re_detail::equal(p1, p2, r.p1); > } >}; >template <class charT> >int get_default_class_id(const charT* p1, const charT* p2) >{ > static const charT data[73] = { > 'a', 'l', 'n', 'u', 'm', > 'a', 'l', 'p', 'h', 'a', > 'b', 'l', 'a', 'n', 'k', > 'c', 'n', 't', 'r', 'l', > 'd', 'i', 'g', 'i', 't', > 'g', 'r', 'a', 'p', 'h', > 'l', 'o', 'w', 'e', 'r', > 'p', 'r', 'i', 'n', 't', > 'p', 'u', 'n', 'c', 't', > 's', 'p', 'a', 'c', 'e', > 'u', 'n', 'i', 'c', 'o', 'd', 'e', > 'u', 'p', 'p', 'e', 'r', > 'v', > 'w', 'o', 'r', 'd', > 'x', 'd', 'i', 'g', 'i', 't', > }; > > static const character_pointer_range<charT> ranges[21] = > { > {data+0, data+5,}, > {data+5, data+10,}, > {data+10, data+15,}, > {data+15, data+20,}, > {data+20, data+21,}, > {data+20, data+25,}, > {data+25, data+30,}, > {data+29, data+30,}, > {data+30, data+31,}, > {data+30, data+35,}, > {data+35, data+40,}, > {data+40, data+45,}, > {data+45, data+46,}, > {data+45, data+50,}, > {data+57, data+58,}, > {data+50, data+57,}, > {data+57, data+62,}, > {data+62, data+63,}, > {data+63, data+64,}, > {data+63, data+67,}, > {data+67, data+73,}, > }; > static const character_pointer_range<charT>* ranges_begin = ranges; > static const character_pointer_range<charT>* ranges_end = ranges + (sizeof(ranges)/sizeof(ranges[0])); > > character_pointer_range<charT> t = { p1, p2, }; > const character_pointer_range<charT>* p = std::lower_bound(ranges_begin, ranges_end, t); > if((p != ranges_end) && (t == *p)) > return static_cast<int>(p - ranges); > return -1; >} > > > > >template <class charT> >std::ptrdiff_t global_length(const charT* p) >{ > std::ptrdiff_t n = 0; > while(*p) > { > ++p; > ++n; > } > return n; >} >template<> >inline std::ptrdiff_t global_length<char>(const char* p) >{ > return (std::strlen)(p); >} > >template<> >inline std::ptrdiff_t global_length<wchar_t>(const wchar_t* p) >{ > return (std::wcslen)(p); >} > >template <class charT> >inline charT global_lower(charT c) >{ > return c; >} >template <class charT> >inline charT global_upper(charT c) >{ > return c; >} > > char do_global_lower(char c); > char do_global_upper(char c); > > wchar_t do_global_lower(wchar_t c); > wchar_t do_global_upper(wchar_t c); ># 271 "/usr/include/boost/regex/v4/regex_traits_defaults.hpp" 3 4 >template<> inline char global_lower<char>(char c){ return do_global_lower(c); } >template<> inline char global_upper<char>(char c){ return do_global_upper(c); } > >template<> inline wchar_t global_lower<wchar_t>(wchar_t c){ return do_global_lower(c); } >template<> inline wchar_t global_upper<wchar_t>(wchar_t c){ return do_global_upper(c); } > > > > > > >template <class charT> >int global_value(charT c) >{ > static const charT zero = '0'; > static const charT nine = '9'; > static const charT a = 'a'; > static const charT f = 'f'; > static const charT A = 'A'; > static const charT F = 'F'; > > if(c > f) return -1; > if(c >= a) return 10 + (c - a); > if(c > F) return -1; > if(c >= A) return 10 + (c - A); > if(c > nine) return -1; > if(c >= zero) return c - zero; > return -1; >} >template <class charT, class traits> >int global_toi(const charT*& p1, const charT* p2, int radix, const traits& t) >{ > (void)t; > int next_value = t.value(*p1, radix); > if((p1 == p2) || (next_value < 0) || (next_value >= radix)) > return -1; > int result = 0; > while(p1 != p2) > { > next_value = t.value(*p1, radix); > if((next_value < 0) || (next_value >= radix)) > break; > result *= radix; > result += next_value; > ++p1; > } > return result; >} > >template <class charT> >inline const charT* get_escape_R_string() >{ > > > > > static const charT e1[] = { '(', '?', '>', '\x0D', '\x0A', '?', > '|', '[', '\x0A', '\x0B', '\x0C', static_cast<unsigned char>('\x85'), '\\', 'x', '{', '2', '0', '2', '8', '}', > '\\', 'x', '{', '2', '0', '2', '9', '}', ']', ')', '\0' }; > static const charT e2[] = { '(', '?', '>', '\x0D', '\x0A', '?', > '|', '[', '\x0A', '\x0B', '\x0C', static_cast<unsigned char>('\x85'), ']', ')', '\0' }; > > charT c = static_cast<charT>(0x2029u); > bool b = (static_cast<unsigned>(c) == 0x2029u); > > return (b ? e1 : e2); > > > >} > >template <> >inline const char* get_escape_R_string<char>() >{ > > > > > static const char e2[] = { '(', '?', '>', '\x0D', '\x0A', '?', > '|', '[', '\x0A', '\x0B', '\x0C', '\x85', ']', ')', '\0' }; > return e2; > > > >} > >} >} ># 36 "/usr/include/boost/regex/v4/regex_traits.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 1 3 4 ># 28 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 ># 1 "/usr/include/boost/regex/pattern_except.hpp" 1 3 4 ># 30 "/usr/include/boost/regex/pattern_except.hpp" 3 4 >namespace boost{ ># 47 "/usr/include/boost/regex/pattern_except.hpp" 3 4 >class regex_error : public std::runtime_error >{ >public: > explicit regex_error(const std::string& s, regex_constants::error_type err = regex_constants::error_unknown, std::ptrdiff_t pos = 0); > explicit regex_error(regex_constants::error_type err); > ~regex_error() throw(); > regex_constants::error_type code()const > { return m_error_code; } > std::ptrdiff_t position()const > { return m_position; } > void raise()const; >private: > regex_constants::error_type m_error_code; > std::ptrdiff_t m_position; >}; > >typedef regex_error bad_pattern; >typedef regex_error bad_expression; > >namespace re_detail{ > > void raise_runtime_error(const std::runtime_error& ex); > >template <class traits> >void raise_error(const traits& t, regex_constants::error_type code) >{ > (void)t; > std::runtime_error e(t.error_string(code)); > ::boost::re_detail::raise_runtime_error(e); >} > >} ># 95 "/usr/include/boost/regex/pattern_except.hpp" 3 4 >} ># 29 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/regex/pending/static_mutex.hpp" 1 3 4 ># 37 "/usr/include/boost/regex/pending/static_mutex.hpp" 3 4 >namespace boost{ > >class static_mutex; > > > >class scoped_static_mutex_lock >{ >public: > scoped_static_mutex_lock(static_mutex& mut, bool lk = true); > ~scoped_static_mutex_lock(); > inline bool locked()const > { > return m_have_lock; > } > inline operator void const*()const > { > return locked() ? this : 0; > } > void lock(); > void unlock(); >private: > static_mutex& m_mutex; > bool m_have_lock; >}; > >class static_mutex >{ >public: > typedef scoped_static_mutex_lock scoped_lock; > pthread_mutex_t m_mutex; >}; > >} ># 35 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/primary_transform.hpp" 1 3 4 ># 34 "/usr/include/boost/regex/v4/primary_transform.hpp" 3 4 >namespace boost{ > namespace re_detail{ > > >enum{ > sort_C, > sort_fixed, > sort_delim, > sort_unknown >}; > >template <class S, class charT> >unsigned count_chars(const S& s, charT c) >{ > > > > > > > unsigned int count = 0; > for(unsigned pos = 0; pos < s.size(); ++pos) > { > if(s[pos] == c) ++count; > } > return count; >} > > >template <class traits, class charT> >unsigned find_sort_syntax(const traits* pt, charT* delim) >{ > > > > > typedef typename traits::string_type string_type; > typedef typename traits::char_type char_type; > > > (void)pt; > > char_type a[2] = {'a', '\0', }; > string_type sa(pt->transform(a, a+1)); > if(sa == a) > { > *delim = 0; > return sort_C; > } > char_type A[2] = { 'A', '\0', }; > string_type sA(pt->transform(A, A+1)); > char_type c[2] = { ';', '\0', }; > string_type sc(pt->transform(c, c+1)); > > int pos = 0; > while((pos <= static_cast<int>(sa.size())) && (pos <= static_cast<int>(sA.size())) && (sa[pos] == sA[pos])) ++pos; > --pos; > if(pos < 0) > { > *delim = 0; > return sort_unknown; > } > > > > > charT maybe_delim = sa[pos]; > if((pos != 0) && (count_chars(sa, maybe_delim) == count_chars(sA, maybe_delim)) && (count_chars(sa, maybe_delim) == count_chars(sc, maybe_delim))) > { > *delim = maybe_delim; > return sort_delim; > } > > > > if((sa.size() == sA.size()) && (sa.size() == sc.size())) > { > > > > *delim = static_cast<charT>(++pos); > return sort_fixed; > } > > > > *delim = 0; > return sort_unknown; >} > > > } >} ># 38 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/pending/object_cache.hpp" 1 3 4 ># 32 "/usr/include/boost/regex/pending/object_cache.hpp" 3 4 >namespace boost{ > >template <class Key, class Object> >class object_cache >{ >public: > typedef std::pair< ::boost::shared_ptr<Object const>, Key const*> value_type; > typedef std::list<value_type> list_type; > typedef typename list_type::iterator list_iterator; > typedef std::map<Key, list_iterator> map_type; > typedef typename map_type::iterator map_iterator; > typedef typename list_type::size_type size_type; > static boost::shared_ptr<Object const> get(const Key& k, size_type l_max_cache_size); > >private: > static boost::shared_ptr<Object const> do_get(const Key& k, size_type l_max_cache_size); > > struct data > { > list_type cont; > map_type index; > }; > > > > friend struct data; >}; > >template <class Key, class Object> >boost::shared_ptr<Object const> object_cache<Key, Object>::get(const Key& k, size_type l_max_cache_size) >{ > > static boost::static_mutex mut = { { { 0, 0, 0, 0, 0, 0, 0, { 0, 0 } } }, }; > > boost::static_mutex::scoped_lock l(mut); > if(l) > { > return do_get(k, l_max_cache_size); > } > > > > > ::boost::throw_exception(std::runtime_error("Error in thread safety code: could not acquire a lock")); > > > > > > >} > >template <class Key, class Object> >boost::shared_ptr<Object const> object_cache<Key, Object>::do_get(const Key& k, size_type l_max_cache_size) >{ > typedef typename object_cache<Key, Object>::data object_data; > typedef typename map_type::size_type map_size_type; > static object_data s_data; > > > > > map_iterator mpos = s_data.index.find(k); > if(mpos != s_data.index.end()) > { > > > > > if(--(s_data.cont.end()) != mpos->second) > { > > list_type temp; > temp.splice(temp.end(), s_data.cont, mpos->second); > > s_data.cont.splice(s_data.cont.end(), temp, temp.begin()); > (static_cast<void> (0)); > > mpos->second = --(s_data.cont.end()); > (static_cast<void> (0)); > (static_cast<void> (0)); > } > return s_data.cont.back().first; > } > > > > > boost::shared_ptr<Object const> result(new Object(k)); > > > > s_data.cont.push_back(value_type(result, static_cast<Key const*>(0))); > s_data.index.insert(std::make_pair(k, --(s_data.cont.end()))); > s_data.cont.back().second = &(s_data.index.find(k)->first); > map_size_type s = s_data.index.size(); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > if(s > l_max_cache_size) > { > > > > > > list_iterator pos = s_data.cont.begin(); > list_iterator last = s_data.cont.end(); > while((pos != last) && (s > l_max_cache_size)) > { > if(pos->first.unique()) > { > list_iterator condemmed(pos); > ++pos; > > > (static_cast<void> (0)); > s_data.index.erase(*(condemmed->second)); > s_data.cont.erase(condemmed); > --s; > } > else > ++pos; > } > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > } > return result; >} > >} ># 41 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 2 3 4 > > > > ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 46 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 2 3 4 ># 63 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 >namespace boost{ > > > > >template <class charT> >class cpp_regex_traits; > >namespace re_detail{ > > > > > >template <class charT, > class traits = ::std::char_traits<charT> > >class parser_buf : public ::std::basic_streambuf<charT, traits> >{ > typedef ::std::basic_streambuf<charT, traits> base_type; > typedef typename base_type::int_type int_type; > typedef typename base_type::char_type char_type; > typedef typename base_type::pos_type pos_type; > typedef ::std::streamsize streamsize; > typedef typename base_type::off_type off_type; >public: > parser_buf() : base_type() { setbuf(0, 0); } > const charT* getnext() { return this->gptr(); } >protected: > std::basic_streambuf<charT, traits>* setbuf(char_type* s, streamsize n); > typename parser_buf<charT, traits>::pos_type seekpos(pos_type sp, ::std::ios_base::openmode which); > typename parser_buf<charT, traits>::pos_type seekoff(off_type off, ::std::ios_base::seekdir way, ::std::ios_base::openmode which); >private: > parser_buf& operator=(const parser_buf&); > parser_buf(const parser_buf&); >}; > >template<class charT, class traits> >std::basic_streambuf<charT, traits>* >parser_buf<charT, traits>::setbuf(char_type* s, streamsize n) >{ > this->setg(s, s, s + n); > return this; >} > >template<class charT, class traits> >typename parser_buf<charT, traits>::pos_type >parser_buf<charT, traits>::seekoff(off_type off, ::std::ios_base::seekdir way, ::std::ios_base::openmode which) >{ > typedef typename boost::int_t<sizeof(way) * 8>::least cast_type; > > if(which & ::std::ios_base::out) > return pos_type(off_type(-1)); > std::ptrdiff_t size = this->egptr() - this->eback(); > std::ptrdiff_t pos = this->gptr() - this->eback(); > charT* g = this->eback(); > switch(static_cast<cast_type>(way)) > { > case ::std::ios_base::beg: > if((off < 0) || (off > size)) > return pos_type(off_type(-1)); > else > this->setg(g, g + off, g + size); > break; > case ::std::ios_base::end: > if((off < 0) || (off > size)) > return pos_type(off_type(-1)); > else > this->setg(g, g + size - off, g + size); > break; > case ::std::ios_base::cur: > { > std::ptrdiff_t newpos = static_cast<std::ptrdiff_t>(pos + off); > if((newpos < 0) || (newpos > size)) > return pos_type(off_type(-1)); > else > this->setg(g, g + newpos, g + size); > break; > } > default: ; > } > > > > > return static_cast<pos_type>(this->gptr() - this->eback()); > > > >} > >template<class charT, class traits> >typename parser_buf<charT, traits>::pos_type >parser_buf<charT, traits>::seekpos(pos_type sp, ::std::ios_base::openmode which) >{ > if(which & ::std::ios_base::out) > return pos_type(off_type(-1)); > off_type size = static_cast<off_type>(this->egptr() - this->eback()); > charT* g = this->eback(); > if(off_type(sp) <= size) > { > this->setg(g, g + off_type(sp), g + size); > } > return pos_type(off_type(-1)); >} > > > > > >template <class charT> >struct cpp_regex_traits_base >{ > cpp_regex_traits_base(const std::locale& l) > { imbue(l); } > std::locale imbue(const std::locale& l); > > std::locale m_locale; > std::ctype<charT> const* m_pctype; > > std::messages<charT> const* m_pmessages; > > std::collate<charT> const* m_pcollate; > > bool operator<(const cpp_regex_traits_base& b)const > { > if(m_pctype == b.m_pctype) > { > > if(m_pmessages == b.m_pmessages) > { > return m_pcollate < b.m_pcollate; > } > return m_pmessages < b.m_pmessages; > > > > } > return m_pctype < b.m_pctype; > } > bool operator==(const cpp_regex_traits_base& b)const > { > return (m_pctype == b.m_pctype) > > && (m_pmessages == b.m_pmessages) > > && (m_pcollate == b.m_pcollate); > } >}; > >template <class charT> >std::locale cpp_regex_traits_base<charT>::imbue(const std::locale& l) >{ > std::locale result(m_locale); > m_locale = l; > m_pctype = &std::use_facet< std::ctype<charT> >(l); > > m_pmessages = std::has_facet< std::messages<charT> >(l) ? &std::use_facet< std::messages<charT> >(l) : 0; > > m_pcollate = &std::use_facet< std::collate<charT> >(l); > return result; >} > > > > > >template <class charT> >class cpp_regex_traits_char_layer : public cpp_regex_traits_base<charT> >{ > typedef std::basic_string<charT> string_type; > typedef std::map<charT, regex_constants::syntax_type> map_type; > typedef typename map_type::const_iterator map_iterator_type; >public: > cpp_regex_traits_char_layer(const std::locale& l) > : cpp_regex_traits_base<charT>(l) > { > init(); > } > cpp_regex_traits_char_layer(const cpp_regex_traits_base<charT>& b) > : cpp_regex_traits_base<charT>(b) > { > init(); > } > void init(); > > regex_constants::syntax_type syntax_type(charT c)const > { > map_iterator_type i = m_char_map.find(c); > return ((i == m_char_map.end()) ? 0 : i->second); > } > regex_constants::escape_syntax_type escape_syntax_type(charT c) const > { > map_iterator_type i = m_char_map.find(c); > if(i == m_char_map.end()) > { > if(this->m_pctype->is(std::ctype_base::lower, c)) return regex_constants::escape_type_class; > if(this->m_pctype->is(std::ctype_base::upper, c)) return regex_constants::escape_type_not_class; > return 0; > } > return i->second; > } > >private: > string_type get_default_message(regex_constants::syntax_type); > > map_type m_char_map; >}; > >template <class charT> >void cpp_regex_traits_char_layer<charT>::init() >{ > > > > > typename std::messages<charT>::catalog cat = static_cast<std::messages<char>::catalog>(-1); > > > > std::string cat_name(cpp_regex_traits<charT>::get_catalog_name()); > if(cat_name.size() && (this->m_pmessages != 0)) > { > cat = this->m_pmessages->open( > cat_name, > this->m_locale); > if((int)cat < 0) > { > std::string m("Unable to open message catalog: "); > std::runtime_error err(m + cat_name); > boost::re_detail::raise_runtime_error(err); > } > } > > > > if((int)cat >= 0) > { > > try{ > > for(regex_constants::syntax_type i = 1; i < regex_constants::syntax_max; ++i) > { > string_type mss = this->m_pmessages->get(cat, 0, i, get_default_message(i)); > for(typename string_type::size_type j = 0; j < mss.size(); ++j) > { > m_char_map[mss[j]] = i; > } > } > this->m_pmessages->close(cat); > > } > catch(...) > { > if(this->m_pmessages) > this->m_pmessages->close(cat); > throw; > } > > } > else > { > > for(regex_constants::syntax_type i = 1; i < regex_constants::syntax_max; ++i) > { > const char* ptr = get_default_syntax(i); > while(ptr && *ptr) > { > m_char_map[this->m_pctype->widen(*ptr)] = i; > ++ptr; > } > } > > } > >} > >template <class charT> >typename cpp_regex_traits_char_layer<charT>::string_type > cpp_regex_traits_char_layer<charT>::get_default_message(regex_constants::syntax_type i) >{ > const char* ptr = get_default_syntax(i); > string_type result; > while(ptr && *ptr) > { > result.append(1, this->m_pctype->widen(*ptr)); > ++ptr; > } > return result; >} > > > > >template <> >class cpp_regex_traits_char_layer<char> : public cpp_regex_traits_base<char> >{ > typedef std::string string_type; >public: > cpp_regex_traits_char_layer(const std::locale& l) > : cpp_regex_traits_base<char>(l) > { > init(); > } > cpp_regex_traits_char_layer(const cpp_regex_traits_base<char>& l) > : cpp_regex_traits_base<char>(l) > { > init(); > } > > regex_constants::syntax_type syntax_type(char c)const > { > return m_char_map[static_cast<unsigned char>(c)]; > } > regex_constants::escape_syntax_type escape_syntax_type(char c) const > { > return m_char_map[static_cast<unsigned char>(c)]; > } > >private: > regex_constants::syntax_type m_char_map[1u << 8]; > void init(); >}; ># 413 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 >template <class charT> >class cpp_regex_traits_implementation : public cpp_regex_traits_char_layer<charT> >{ >public: > typedef typename cpp_regex_traits<charT>::char_class_type char_class_type; > typedef typename std::ctype<charT>::mask native_mask_type; > > static const char_class_type mask_blank = 1u << 24; > static const char_class_type mask_word = 1u << 25; > static const char_class_type mask_unicode = 1u << 26; > static const char_class_type mask_horizontal = 1u << 27; > static const char_class_type mask_vertical = 1u << 28; > > > typedef std::basic_string<charT> string_type; > typedef charT char_type; > > cpp_regex_traits_implementation(const std::locale& l) > : cpp_regex_traits_char_layer<charT>(l) > { > init(); > } > cpp_regex_traits_implementation(const cpp_regex_traits_base<charT>& l) > : cpp_regex_traits_char_layer<charT>(l) > { > init(); > } > std::string error_string(regex_constants::error_type n) const > { > if(!m_error_strings.empty()) > { > std::map<int, std::string>::const_iterator p = m_error_strings.find(n); > return (p == m_error_strings.end()) ? std::string(get_default_error_string(n)) : p->second; > } > return get_default_error_string(n); > } > char_class_type lookup_classname(const charT* p1, const charT* p2) const > { > char_class_type result = lookup_classname_imp(p1, p2); > if(result == 0) > { > string_type temp(p1, p2); > this->m_pctype->tolower(&*temp.begin(), &*temp.begin() + temp.size()); > result = lookup_classname_imp(&*temp.begin(), &*temp.begin() + temp.size()); > } > return result; > } > string_type lookup_collatename(const charT* p1, const charT* p2) const; > string_type transform_primary(const charT* p1, const charT* p2) const; > string_type transform(const charT* p1, const charT* p2) const; >private: > std::map<int, std::string> m_error_strings; > std::map<string_type, char_class_type> m_custom_class_names; > std::map<string_type, string_type> m_custom_collate_names; > unsigned m_collate_type; > charT m_collate_delim; > > > > char_class_type lookup_classname_imp(const charT* p1, const charT* p2) const; > void init(); > > > > >}; > > > > >template <class charT> >typename cpp_regex_traits_implementation<charT>::char_class_type const cpp_regex_traits_implementation<charT>::mask_blank; >template <class charT> >typename cpp_regex_traits_implementation<charT>::char_class_type const cpp_regex_traits_implementation<charT>::mask_word; >template <class charT> >typename cpp_regex_traits_implementation<charT>::char_class_type const cpp_regex_traits_implementation<charT>::mask_unicode; >template <class charT> >typename cpp_regex_traits_implementation<charT>::char_class_type const cpp_regex_traits_implementation<charT>::mask_vertical; >template <class charT> >typename cpp_regex_traits_implementation<charT>::char_class_type const cpp_regex_traits_implementation<charT>::mask_horizontal; > > > > >template <class charT> >typename cpp_regex_traits_implementation<charT>::string_type > cpp_regex_traits_implementation<charT>::transform_primary(const charT* p1, const charT* p2) const >{ ># 509 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 > (static_cast<void> (0)); > > string_type result; > > > > > > > try{ > > > > > > switch(m_collate_type) > { > case sort_C: > case sort_unknown: > > { > result.assign(p1, p2); > this->m_pctype->tolower(&*result.begin(), &*result.begin() + result.size()); > result = this->m_pcollate->transform(&*result.begin(), &*result.begin() + result.size()); > break; > } > case sort_fixed: > { > > result.assign(this->m_pcollate->transform(p1, p2)); > result.erase(this->m_collate_delim); > break; > } > case sort_delim: > > result.assign(this->m_pcollate->transform(p1, p2)); > std::size_t i; > for(i = 0; i < result.size(); ++i) > { > if(result[i] == m_collate_delim) > break; > } > result.erase(i); > break; > } > > }catch(...){} > > while(result.size() && (charT(0) == *result.rbegin())) > result.erase(result.size() - 1); > if(result.empty()) > { > > result = string_type(1, charT(0)); > } > return result; >} > >template <class charT> >typename cpp_regex_traits_implementation<charT>::string_type > cpp_regex_traits_implementation<charT>::transform(const charT* p1, const charT* p2) const >{ ># 579 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 > (static_cast<void> (0)); > > > > > > string_type result; > > try{ > > result = this->m_pcollate->transform(p1, p2); ># 601 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 > while(result.size() && (charT(0) == *result.rbegin())) > result.erase(result.size() - 1); > > (static_cast<void> (0)); > > } > catch(...) > { > } > > return result; >} > > >template <class charT> >typename cpp_regex_traits_implementation<charT>::string_type > cpp_regex_traits_implementation<charT>::lookup_collatename(const charT* p1, const charT* p2) const >{ > typedef typename std::map<string_type, string_type>::const_iterator iter_type; > if(m_custom_collate_names.size()) > { > iter_type pos = m_custom_collate_names.find(string_type(p1, p2)); > if(pos != m_custom_collate_names.end()) > return pos->second; > } > > > > std::string name(p1, p2); > > > > > > > name = lookup_default_collate_name(name); > > > > if(name.size()) > return string_type(name.begin(), name.end()); ># 654 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 > if(p2 - p1 == 1) > return string_type(1, *p1); > return string_type(); >} > >template <class charT> >void cpp_regex_traits_implementation<charT>::init() >{ > > > typename std::messages<charT>::catalog cat = static_cast<std::messages<char>::catalog>(-1); > > > > std::string cat_name(cpp_regex_traits<charT>::get_catalog_name()); > if(cat_name.size() && (this->m_pmessages != 0)) > { > cat = this->m_pmessages->open( > cat_name, > this->m_locale); > if((int)cat < 0) > { > std::string m("Unable to open message catalog: "); > std::runtime_error err(m + cat_name); > boost::re_detail::raise_runtime_error(err); > } > } > > > > if((int)cat >= 0) > { > > > > for(boost::regex_constants::error_type i = static_cast<boost::regex_constants::error_type>(0); > i <= boost::regex_constants::error_unknown; > i = static_cast<boost::regex_constants::error_type>(i + 1)) > { > const char* p = get_default_error_string(i); > string_type default_message; > while(*p) > { > default_message.append(1, this->m_pctype->widen(*p)); > ++p; > } > string_type s = this->m_pmessages->get(cat, 0, i+200, default_message); > std::string result; > for(std::string::size_type j = 0; j < s.size(); ++j) > { > result.append(1, this->m_pctype->narrow(s[j], 0)); > } > m_error_strings[i] = result; > } > > > > > static const char_class_type masks[16] = > { > std::ctype<charT>::alnum, > std::ctype<charT>::alpha, > std::ctype<charT>::cntrl, > std::ctype<charT>::digit, > std::ctype<charT>::graph, > cpp_regex_traits_implementation<charT>::mask_horizontal, > std::ctype<charT>::lower, > std::ctype<charT>::print, > std::ctype<charT>::punct, > std::ctype<charT>::space, > std::ctype<charT>::upper, > cpp_regex_traits_implementation<charT>::mask_vertical, > std::ctype<charT>::xdigit, > cpp_regex_traits_implementation<charT>::mask_blank, > cpp_regex_traits_implementation<charT>::mask_word, > cpp_regex_traits_implementation<charT>::mask_unicode, > }; ># 752 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 > static const string_type null_string; > for(unsigned int j = 0; j <= 13; ++j) > { > string_type s(this->m_pmessages->get(cat, 0, j+300, null_string)); > if(s.size()) > this->m_custom_class_names[s] = masks[j]; > } > } > > > > > m_collate_type = re_detail::find_sort_syntax(this, &m_collate_delim); >} > >template <class charT> >typename cpp_regex_traits_implementation<charT>::char_class_type > cpp_regex_traits_implementation<charT>::lookup_classname_imp(const charT* p1, const charT* p2) const >{ > > static const char_class_type masks[22] = > { > 0, > std::ctype<char>::alnum, > std::ctype<char>::alpha, > cpp_regex_traits_implementation<charT>::mask_blank, > std::ctype<char>::cntrl, > std::ctype<char>::digit, > std::ctype<char>::digit, > std::ctype<char>::graph, > cpp_regex_traits_implementation<charT>::mask_horizontal, > std::ctype<char>::lower, > std::ctype<char>::lower, > std::ctype<char>::print, > std::ctype<char>::punct, > std::ctype<char>::space, > std::ctype<char>::space, > std::ctype<char>::upper, > cpp_regex_traits_implementation<charT>::mask_unicode, > std::ctype<char>::upper, > cpp_regex_traits_implementation<charT>::mask_vertical, > std::ctype<char>::alnum | cpp_regex_traits_implementation<charT>::mask_word, > std::ctype<char>::alnum | cpp_regex_traits_implementation<charT>::mask_word, > std::ctype<char>::xdigit, > }; ># 824 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 > if(m_custom_class_names.size()) > { > typedef typename std::map<std::basic_string<charT>, char_class_type>::const_iterator map_iter; > map_iter pos = m_custom_class_names.find(string_type(p1, p2)); > if(pos != m_custom_class_names.end()) > return pos->second; > } > std::size_t state_id = 1 + re_detail::get_default_class_id(p1, p2); > (static_cast<void> (0)); > return masks[state_id]; >} ># 859 "/usr/include/boost/regex/v4/cpp_regex_traits.hpp" 3 4 >template <class charT> >inline boost::shared_ptr<const cpp_regex_traits_implementation<charT> > create_cpp_regex_traits(const std::locale& l ) >{ > cpp_regex_traits_base<charT> key(l); > return ::boost::object_cache<cpp_regex_traits_base<charT>, cpp_regex_traits_implementation<charT> >::get(key, 5); >} > >} > >template <class charT> >class cpp_regex_traits >{ >private: > typedef std::ctype<charT> ctype_type; >public: > typedef charT char_type; > typedef std::size_t size_type; > typedef std::basic_string<char_type> string_type; > typedef std::locale locale_type; > typedef boost::uint_least32_t char_class_type; > > struct boost_extensions_tag{}; > > cpp_regex_traits() > : m_pimpl(re_detail::create_cpp_regex_traits<charT>(std::locale())) > { } > static size_type length(const char_type* p) > { > return std::char_traits<charT>::length(p); > } > regex_constants::syntax_type syntax_type(charT c)const > { > return m_pimpl->syntax_type(c); > } > regex_constants::escape_syntax_type escape_syntax_type(charT c) const > { > return m_pimpl->escape_syntax_type(c); > } > charT translate(charT c) const > { > return c; > } > charT translate_nocase(charT c) const > { > return m_pimpl->m_pctype->tolower(c); > } > charT translate(charT c, bool icase) const > { > return icase ? m_pimpl->m_pctype->tolower(c) : c; > } > charT tolower(charT c) const > { > return m_pimpl->m_pctype->tolower(c); > } > charT toupper(charT c) const > { > return m_pimpl->m_pctype->toupper(c); > } > string_type transform(const charT* p1, const charT* p2) const > { > return m_pimpl->transform(p1, p2); > } > string_type transform_primary(const charT* p1, const charT* p2) const > { > return m_pimpl->transform_primary(p1, p2); > } > char_class_type lookup_classname(const charT* p1, const charT* p2) const > { > return m_pimpl->lookup_classname(p1, p2); > } > string_type lookup_collatename(const charT* p1, const charT* p2) const > { > return m_pimpl->lookup_collatename(p1, p2); > } > bool isctype(charT c, char_class_type f) const > { > > typedef typename std::ctype<charT>::mask ctype_mask; > > static const ctype_mask mask_base = > static_cast<ctype_mask>( > std::ctype<charT>::alnum > | std::ctype<charT>::alpha > | std::ctype<charT>::cntrl > | std::ctype<charT>::digit > | std::ctype<charT>::graph > | std::ctype<charT>::lower > | std::ctype<charT>::print > | std::ctype<charT>::punct > | std::ctype<charT>::space > | std::ctype<charT>::upper > | std::ctype<charT>::xdigit); > > if((f & mask_base) > && (m_pimpl->m_pctype->is( > static_cast<ctype_mask>(f & mask_base), c))) > return true; > else if((f & re_detail::cpp_regex_traits_implementation<charT>::mask_unicode) && re_detail::is_extended(c)) > return true; > else if((f & re_detail::cpp_regex_traits_implementation<charT>::mask_word) && (c == '_')) > return true; > else if((f & re_detail::cpp_regex_traits_implementation<charT>::mask_blank) > && m_pimpl->m_pctype->is(std::ctype<charT>::space, c) > && !re_detail::is_separator(c)) > return true; > else if((f & re_detail::cpp_regex_traits_implementation<charT>::mask_vertical) > && (::boost::re_detail::is_separator(c) || (c == '\v'))) > return true; > else if((f & re_detail::cpp_regex_traits_implementation<charT>::mask_horizontal) > && this->isctype(c, std::ctype<charT>::space) && !this->isctype(c, re_detail::cpp_regex_traits_implementation<charT>::mask_vertical)) > return true; > return false; > > > > } > int toi(const charT*& p1, const charT* p2, int radix)const; > int value(charT c, int radix)const > { > const charT* pc = &c; > return toi(pc, pc + 1, radix); > } > locale_type imbue(locale_type l) > { > std::locale result(getloc()); > m_pimpl = re_detail::create_cpp_regex_traits<charT>(l); > return result; > } > locale_type getloc()const > { > return m_pimpl->m_locale; > } > std::string error_string(regex_constants::error_type n) const > { > return m_pimpl->error_string(n); > } > > > > > > static std::string catalog_name(const std::string& name); > static std::string get_catalog_name(); > >private: > boost::shared_ptr<const re_detail::cpp_regex_traits_implementation<charT> > m_pimpl; > > > > static std::string& get_catalog_name_inst(); > > > static static_mutex& get_mutex_inst(); > >}; > > >template <class charT> >int cpp_regex_traits<charT>::toi(const charT*& first, const charT* last, int radix)const >{ > re_detail::parser_buf<charT> sbuf; > std::basic_istream<charT> is(&sbuf); > > > last = std::find(first, last, std::use_facet< std::numpunct<charT> >(is.getloc()).thousands_sep()); > > sbuf.pubsetbuf(const_cast<charT*>(static_cast<const charT*>(first)), static_cast<std::streamsize>(last-first)); > is.clear(); > if(std::abs(radix) == 16) is >> std::hex; > else if(std::abs(radix) == 8) is >> std::oct; > else is >> std::dec; > int val; > if(is >> val) > { > first = first + ((last - first) - sbuf.in_avail()); > return val; > } > else > return -1; >} > >template <class charT> >std::string cpp_regex_traits<charT>::catalog_name(const std::string& name) >{ > > static_mutex::scoped_lock lk(get_mutex_inst()); > > std::string result(get_catalog_name_inst()); > get_catalog_name_inst() = name; > return result; >} > >template <class charT> >std::string& cpp_regex_traits<charT>::get_catalog_name_inst() >{ > static std::string s_name; > return s_name; >} > >template <class charT> >std::string cpp_regex_traits<charT>::get_catalog_name() >{ > > static_mutex::scoped_lock lk(get_mutex_inst()); > > std::string result(get_catalog_name_inst()); > return result; >} > > >template <class charT> >static_mutex& cpp_regex_traits<charT>::get_mutex_inst() >{ > static static_mutex s_mutex = { { { 0, 0, 0, 0, 0, 0, 0, { 0, 0 } } }, }; > return s_mutex; >} > > > >} ># 40 "/usr/include/boost/regex/v4/regex_traits.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/regex/v4/c_regex_traits.hpp" 1 3 4 ># 29 "/usr/include/boost/regex/v4/c_regex_traits.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cctype" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cctype" 3 4 ># 40 "/usr/include/c++/4.9.0/cctype" 3 ># 30 "/usr/include/boost/regex/v4/c_regex_traits.hpp" 2 3 4 ># 48 "/usr/include/boost/regex/v4/c_regex_traits.hpp" 3 4 >namespace boost{ > >template <class charT> >struct c_regex_traits; > >template<> >struct c_regex_traits<char> >{ > c_regex_traits(){} > typedef char char_type; > typedef std::size_t size_type; > typedef std::string string_type; > struct locale_type{}; > typedef boost::uint32_t char_class_type; > > static size_type length(const char_type* p) > { > return (std::strlen)(p); > } > > char translate(char c) const > { > return c; > } > char translate_nocase(char c) const > { > return static_cast<char>((std::tolower)(static_cast<unsigned char>(c))); > } > > static string_type transform(const char* p1, const char* p2); > static string_type transform_primary(const char* p1, const char* p2); > > static char_class_type lookup_classname(const char* p1, const char* p2); > static string_type lookup_collatename(const char* p1, const char* p2); > > static bool isctype(char, char_class_type); > static int value(char, int); > > locale_type imbue(locale_type l) > { return l; } > locale_type getloc()const > { return locale_type(); } > >private: > > c_regex_traits(const c_regex_traits&); > c_regex_traits& operator=(const c_regex_traits&); >}; > > >template<> >struct c_regex_traits<wchar_t> >{ > c_regex_traits(){} > typedef wchar_t char_type; > typedef std::size_t size_type; > typedef std::wstring string_type; > struct locale_type{}; > typedef boost::uint32_t char_class_type; > > static size_type length(const char_type* p) > { > return (std::wcslen)(p); > } > > wchar_t translate(wchar_t c) const > { > return c; > } > wchar_t translate_nocase(wchar_t c) const > { > return (std::towlower)(c); > } > > static string_type transform(const wchar_t* p1, const wchar_t* p2); > static string_type transform_primary(const wchar_t* p1, const wchar_t* p2); > > static char_class_type lookup_classname(const wchar_t* p1, const wchar_t* p2); > static string_type lookup_collatename(const wchar_t* p1, const wchar_t* p2); > > static bool isctype(wchar_t, char_class_type); > static int value(wchar_t, int); > > locale_type imbue(locale_type l) > { return l; } > locale_type getloc()const > { return locale_type(); } > >private: > > c_regex_traits(const c_regex_traits&); > c_regex_traits& operator=(const c_regex_traits&); >}; ># 195 "/usr/include/boost/regex/v4/c_regex_traits.hpp" 3 4 >} ># 45 "/usr/include/boost/regex/v4/regex_traits.hpp" 2 3 4 ># 70 "/usr/include/boost/regex/v4/regex_traits.hpp" 3 4 >namespace boost{ > >template <class charT, class implementationT > >struct regex_traits : public implementationT >{ > regex_traits() : implementationT() {} >}; ># 85 "/usr/include/boost/regex/v4/regex_traits.hpp" 3 4 >namespace re_detail{ > >template< typename T, typename fallback_ = boost::mpl::bool_<false> > struct has_boost_extensions_tag { struct gcc_3_2_wknd { template< typename U > static boost::mpl::aux::yes_tag test( boost::mpl::aux::type_wrapper<U> const volatile* , boost::mpl::aux::type_wrapper<typename U::boost_extensions_tag>* = 0 ); static boost::mpl::aux::no_tag test(...); }; typedef boost::mpl::aux::type_wrapper<T> t_; static const bool value = sizeof(gcc_3_2_wknd::test(static_cast<t_*>(0))) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_<value> type; }; ># 96 "/usr/include/boost/regex/v4/regex_traits.hpp" 3 4 >template <class BaseT> >struct default_wrapper : public BaseT >{ > typedef typename BaseT::char_type char_type; > std::string error_string(::boost::regex_constants::error_type e)const > { > return ::boost::re_detail::get_default_error_string(e); > } > ::boost::regex_constants::syntax_type syntax_type(char_type c)const > { > return ((c & 0x7f) == c) ? get_default_syntax_type(static_cast<char>(c)) : ::boost::regex_constants::syntax_char; > } > ::boost::regex_constants::escape_syntax_type escape_syntax_type(char_type c)const > { > return ((c & 0x7f) == c) ? get_default_escape_syntax_type(static_cast<char>(c)) : ::boost::regex_constants::escape_type_identity; > } > int toi(const char_type*& p1, const char_type* p2, int radix)const > { > return ::boost::re_detail::global_toi(p1, p2, radix, *this); > } > char_type translate(char_type c, bool icase)const > { > return (icase ? this->translate_nocase(c) : this->translate(c)); > } > char_type translate(char_type c)const > { > return BaseT::translate(c); > } > char_type tolower(char_type c)const > { > return ::boost::re_detail::global_lower(c); > } > char_type toupper(char_type c)const > { > return ::boost::re_detail::global_upper(c); > } >}; > >template <class BaseT, bool has_extensions> >struct compute_wrapper_base >{ > typedef BaseT type; >}; > >template <class BaseT> >struct compute_wrapper_base<BaseT, false> >{ > typedef default_wrapper<BaseT> type; >}; ># 160 "/usr/include/boost/regex/v4/regex_traits.hpp" 3 4 >} > >template <class BaseT> >struct regex_traits_wrapper > : public ::boost::re_detail::compute_wrapper_base< > BaseT, > ::boost::re_detail::has_boost_extensions_tag<BaseT>::value > >::type >{ > regex_traits_wrapper(){} >private: > regex_traits_wrapper(const regex_traits_wrapper&); > regex_traits_wrapper& operator=(const regex_traits_wrapper&); >}; > >} ># 28 "/usr/include/boost/regex/regex_traits.hpp" 2 3 4 ># 40 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 ># 48 "/usr/include/boost/regex/v4/regex.hpp" 3 4 ># 1 "/usr/include/boost/regex/v4/regex_raw_buffer.hpp" 1 3 4 ># 31 "/usr/include/boost/regex/v4/regex_raw_buffer.hpp" 3 4 >namespace boost{ > namespace re_detail{ ># 45 "/usr/include/boost/regex/v4/regex_raw_buffer.hpp" 3 4 >struct empty_padding{}; > >union padding >{ > void* p; > unsigned int i; >}; > >template <int N> >struct padding3 >{ > enum{ > padding_size = 8, > padding_mask = 7 > }; >}; > >template<> >struct padding3<2> >{ > enum{ > padding_size = 2, > padding_mask = 1 > }; >}; > >template<> >struct padding3<4> >{ > enum{ > padding_size = 4, > padding_mask = 3 > }; >}; > >template<> >struct padding3<8> >{ > enum{ > padding_size = 8, > padding_mask = 7 > }; >}; > >template<> >struct padding3<16> >{ > enum{ > padding_size = 16, > padding_mask = 15 > }; >}; > >enum{ > padding_size = padding3<sizeof(padding)>::padding_size, > padding_mask = padding3<sizeof(padding)>::padding_mask >}; > > > > > > > >class raw_storage >{ >public: > typedef std::size_t size_type; > typedef unsigned char* pointer; >private: > pointer last, start, end; >public: > > raw_storage(); > raw_storage(size_type n); > > ~raw_storage() > { > ::operator delete(start); > } > > void resize(size_type n); > > void* extend(size_type n) > { > if(size_type(last - end) < n) > resize(n + (end - start)); > register pointer result = end; > end += n; > return result; > } > > void* insert(size_type pos, size_type n); > > size_type size() > { > return end - start; > } > > size_type capacity() > { > return last - start; > } > > void* data()const > { > return start; > } > > size_type index(void* ptr) > { > return static_cast<pointer>(ptr) - static_cast<pointer>(data()); > } > > void clear() > { > end = start; > } > > void align() > { > > end = start + (((end - start) + padding_mask) & ~padding_mask); > } > void swap(raw_storage& that) > { > std::swap(start, that.start); > std::swap(end, that.end); > std::swap(last, that.last); > } >}; > >inline raw_storage::raw_storage() >{ > last = start = end = 0; >} > >inline raw_storage::raw_storage(size_type n) >{ > start = end = static_cast<pointer>(::operator new(n)); > > last = start + n; >} ># 201 "/usr/include/boost/regex/v4/regex_raw_buffer.hpp" 3 4 >} >} ># 49 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/regex/v4/char_regex_traits.hpp" 1 3 4 ># 34 "/usr/include/boost/regex/v4/char_regex_traits.hpp" 3 4 >namespace boost{ > >namespace deprecated{ > > > >template <class charT> >class char_regex_traits_i : public regex_traits<charT> {}; > >template<> >class char_regex_traits_i<char> : public regex_traits<char> >{ >public: > typedef char char_type; > typedef unsigned char uchar_type; > typedef unsigned int size_type; > typedef regex_traits<char> base_type; > >}; > > >template<> >class char_regex_traits_i<wchar_t> : public regex_traits<wchar_t> >{ >public: > typedef wchar_t char_type; > typedef unsigned short uchar_type; > typedef unsigned int size_type; > typedef regex_traits<wchar_t> base_type; > >}; > >} >} ># 56 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/states.hpp" 1 3 4 ># 33 "/usr/include/boost/regex/v4/states.hpp" 3 4 >namespace boost{ >namespace re_detail{ > > > > > > > >enum mask_type >{ > mask_take = 1, > mask_skip = 2, > mask_init = 4, > mask_any = mask_skip | mask_take, > mask_all = mask_any >}; > > > > > >struct _narrow_type{}; >struct _wide_type{}; >template <class charT> struct is_byte; >template<> struct is_byte<char> { typedef _narrow_type width_type; }; >template<> struct is_byte<unsigned char>{ typedef _narrow_type width_type; }; >template<> struct is_byte<signed char> { typedef _narrow_type width_type; }; >template <class charT> struct is_byte { typedef _wide_type width_type; }; > > > > >enum syntax_element_type >{ > > syntax_element_startmark = 0, > > syntax_element_endmark = syntax_element_startmark + 1, > > syntax_element_literal = syntax_element_endmark + 1, > > syntax_element_start_line = syntax_element_literal + 1, > > syntax_element_end_line = syntax_element_start_line + 1, > > syntax_element_wild = syntax_element_end_line + 1, > > syntax_element_match = syntax_element_wild + 1, > > syntax_element_word_boundary = syntax_element_match + 1, > > syntax_element_within_word = syntax_element_word_boundary + 1, > > syntax_element_word_start = syntax_element_within_word + 1, > > syntax_element_word_end = syntax_element_word_start + 1, > > syntax_element_buffer_start = syntax_element_word_end + 1, > > syntax_element_buffer_end = syntax_element_buffer_start + 1, > > syntax_element_backref = syntax_element_buffer_end + 1, > > syntax_element_long_set = syntax_element_backref + 1, > > syntax_element_set = syntax_element_long_set + 1, > > syntax_element_jump = syntax_element_set + 1, > > syntax_element_alt = syntax_element_jump + 1, > > syntax_element_rep = syntax_element_alt + 1, > > syntax_element_combining = syntax_element_rep + 1, > > syntax_element_soft_buffer_end = syntax_element_combining + 1, > > syntax_element_restart_continue = syntax_element_soft_buffer_end + 1, > > syntax_element_dot_rep = syntax_element_restart_continue + 1, > syntax_element_char_rep = syntax_element_dot_rep + 1, > syntax_element_short_set_rep = syntax_element_char_rep + 1, > syntax_element_long_set_rep = syntax_element_short_set_rep + 1, > > syntax_element_backstep = syntax_element_long_set_rep + 1, > > syntax_element_assert_backref = syntax_element_backstep + 1, > syntax_element_toggle_case = syntax_element_assert_backref + 1, > > syntax_element_recurse = syntax_element_toggle_case + 1 >}; > > > > > > >struct re_syntax_base; > > > > > > >union offset_type >{ > re_syntax_base* p; > std::ptrdiff_t i; >}; > > > > >struct re_syntax_base >{ > syntax_element_type type; > offset_type next; >}; > > > > >struct re_brace : public re_syntax_base >{ > > > int index; > bool icase; >}; > > > > >enum >{ > dont_care = 1, > force_not_newline = 0, > force_newline = 2, > > test_not_newline = 2, > test_newline = 3 >}; >struct re_dot : public re_syntax_base >{ > unsigned char mask; >}; > > > > > >struct re_literal : public re_syntax_base >{ > unsigned int length; >}; > > > > >struct re_case : public re_syntax_base >{ > bool icase; >}; ># 205 "/usr/include/boost/regex/v4/states.hpp" 3 4 >template <class mask_type> >struct re_set_long : public re_syntax_base >{ > unsigned int csingles, cranges, cequivalents; > mask_type cclasses; > mask_type cnclasses; > bool isnot; > bool singleton; >}; > > > > >struct re_set : public re_syntax_base >{ > unsigned char _map[1 << 8]; >}; > > > > >struct re_jump : public re_syntax_base >{ > offset_type alt; >}; > > > > >struct re_alt : public re_jump >{ > unsigned char _map[1 << 8]; > unsigned int can_be_null; >}; > > > > >struct re_repeat : public re_alt >{ > std::size_t min, max; > int state_id; > bool leading; > bool greedy; >}; > > > > >struct re_recurse : public re_jump >{ > int state_id; >}; > > > > > > >enum re_jump_size_type >{ > re_jump_size = (sizeof(re_jump) + padding_mask) & ~(padding_mask), > re_repeater_size = (sizeof(re_repeat) + padding_mask) & ~(padding_mask), > re_alt_size = (sizeof(re_alt) + padding_mask) & ~(padding_mask) >}; > > > > > >template<class charT, class traits> >struct regex_data; > >template <class iterator, class charT, class traits_type, class char_classT> >iterator re_is_set_member(iterator next, > iterator last, > const re_set_long<char_classT>* set_, > const regex_data<charT, traits_type>& e, bool icase); > >} > >} ># 59 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regbase.hpp" 1 3 4 ># 33 "/usr/include/boost/regex/v4/regbase.hpp" 3 4 >namespace boost{ > > > > >class regbase >{ >public: > enum flag_type_ > { ># 53 "/usr/include/boost/regex/v4/regbase.hpp" 3 4 > perl_syntax_group = 0, > basic_syntax_group = 1, > literal = 2, > main_option_type = literal | basic_syntax_group | perl_syntax_group, > > > > no_bk_refs = 1 << 8, > no_perl_ex = 1 << 9, > no_mod_m = 1 << 10, > mod_x = 1 << 11, > mod_s = 1 << 12, > no_mod_s = 1 << 13, > > > > > no_char_classes = 1 << 8, > no_intervals = 1 << 9, > bk_plus_qm = 1 << 10, > bk_vbar = 1 << 11, > emacs_ex = 1 << 12, > > > > > no_escape_in_lists = 1 << 16, > newline_alt = 1 << 17, > no_except = 1 << 18, > failbit = 1 << 19, > icase = 1 << 20, > nocollate = 0, > collate = 1 << 21, > nosubs = 1 << 22, > save_subexpression_location = 1 << 23, > no_empty_expressions = 1 << 24, > optimize = 0, > > > > basic = basic_syntax_group | collate | no_escape_in_lists, > extended = no_bk_refs | collate | no_perl_ex | no_escape_in_lists, > normal = 0, > emacs = basic_syntax_group | collate | emacs_ex | bk_vbar, > awk = no_bk_refs | collate | no_perl_ex, > grep = basic | newline_alt, > egrep = extended | newline_alt, > sed = basic, > perl = normal, > ECMAScript = normal, > JavaScript = normal, > JScript = normal > }; > typedef unsigned int flag_type; > > enum restart_info > { > restart_any = 0, > restart_word = 1, > restart_line = 2, > restart_buf = 3, > restart_continue = 4, > restart_lit = 5, > restart_fixed_lit = 6, > restart_count = 7 > }; >}; > > > > >namespace regex_constants{ > > enum flag_type_ > { > > no_except = ::boost::regbase::no_except, > failbit = ::boost::regbase::failbit, > literal = ::boost::regbase::literal, > icase = ::boost::regbase::icase, > nocollate = ::boost::regbase::nocollate, > collate = ::boost::regbase::collate, > nosubs = ::boost::regbase::nosubs, > optimize = ::boost::regbase::optimize, > bk_plus_qm = ::boost::regbase::bk_plus_qm, > bk_vbar = ::boost::regbase::bk_vbar, > no_intervals = ::boost::regbase::no_intervals, > no_char_classes = ::boost::regbase::no_char_classes, > no_escape_in_lists = ::boost::regbase::no_escape_in_lists, > no_mod_m = ::boost::regbase::no_mod_m, > mod_x = ::boost::regbase::mod_x, > mod_s = ::boost::regbase::mod_s, > no_mod_s = ::boost::regbase::no_mod_s, > save_subexpression_location = ::boost::regbase::save_subexpression_location, > no_empty_expressions = ::boost::regbase::no_empty_expressions, > > basic = ::boost::regbase::basic, > extended = ::boost::regbase::extended, > normal = ::boost::regbase::normal, > emacs = ::boost::regbase::emacs, > awk = ::boost::regbase::awk, > grep = ::boost::regbase::grep, > egrep = ::boost::regbase::egrep, > sed = basic, > perl = normal, > ECMAScript = normal, > JavaScript = normal, > JScript = normal > }; > typedef ::boost::regbase::flag_type syntax_option_type; > >} > >} ># 62 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/iterator_traits.hpp" 1 3 4 ># 33 "/usr/include/boost/regex/v4/iterator_traits.hpp" 3 4 >namespace boost{ >namespace re_detail{ ># 115 "/usr/include/boost/regex/v4/iterator_traits.hpp" 3 4 >template <class T> >struct regex_iterator_traits : public std::iterator_traits<T> {}; > > > >} >} ># 65 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/basic_regex.hpp" 1 3 4 ># 23 "/usr/include/boost/regex/v4/basic_regex.hpp" 3 4 ># 1 "/usr/include/boost/functional/hash.hpp" 1 3 4 > > > > > ># 1 "/usr/include/boost/functional/hash/hash.hpp" 1 3 4 ># 7 "/usr/include/boost/functional/hash.hpp" 2 3 4 ># 24 "/usr/include/boost/regex/v4/basic_regex.hpp" 2 3 4 ># 36 "/usr/include/boost/regex/v4/basic_regex.hpp" 3 4 >namespace boost{ ># 45 "/usr/include/boost/regex/v4/basic_regex.hpp" 3 4 >namespace re_detail{ > > > > >template <class charT, class traits> >class basic_regex_parser; > >template <class I> >void bubble_down_one(I first, I last) >{ > if(first != last) > { > I next = last - 1; > while((next != first) && (*next < *(next-1))) > { > (next-1)->swap(*next); > --next; > } > } >} > >template <class Iterator> >inline int hash_value_from_capture_name(Iterator i, Iterator j) >{ > std::size_t r = boost::hash_range(i, j); > r %= ((std::numeric_limits<int>::max)() - 10001); > r += 10000; > return static_cast<int>(r); >} > >class named_subexpressions >{ >public: > struct name > { > template <class charT> > name(const charT* i, const charT* j, int idx) > : index(idx) > { > hash = hash_value_from_capture_name(i, j); > } > name(int h, int idx) > : index(idx), hash(h) > { > } > int index; > int hash; > bool operator < (const name& other)const > { > return hash < other.hash; > } > bool operator == (const name& other)const > { > return hash == other.hash; > } > void swap(name& other) > { > std::swap(index, other.index); > std::swap(hash, other.hash); > } > }; > > typedef std::vector<name>::const_iterator const_iterator; > typedef std::pair<const_iterator, const_iterator> range_type; > > named_subexpressions(){} > > template <class charT> > void set_name(const charT* i, const charT* j, int index) > { > m_sub_names.push_back(name(i, j, index)); > bubble_down_one(m_sub_names.begin(), m_sub_names.end()); > } > template <class charT> > int get_id(const charT* i, const charT* j)const > { > name t(i, j, 0); > typename std::vector<name>::const_iterator pos = std::lower_bound(m_sub_names.begin(), m_sub_names.end(), t); > if((pos != m_sub_names.end()) && (*pos == t)) > { > return pos->index; > } > return -1; > } > template <class charT> > range_type equal_range(const charT* i, const charT* j)const > { > name t(i, j, 0); > return std::equal_range(m_sub_names.begin(), m_sub_names.end(), t); > } > int get_id(int h)const > { > name t(h, 0); > std::vector<name>::const_iterator pos = std::lower_bound(m_sub_names.begin(), m_sub_names.end(), t); > if((pos != m_sub_names.end()) && (*pos == t)) > { > return pos->index; > } > return -1; > } > range_type equal_range(int h)const > { > name t(h, 0); > return std::equal_range(m_sub_names.begin(), m_sub_names.end(), t); > } >private: > std::vector<name> m_sub_names; >}; > > > > > >template <class charT, class traits> >struct regex_data : public named_subexpressions >{ > typedef regex_constants::syntax_option_type flag_type; > typedef std::size_t size_type; > > regex_data(const ::boost::shared_ptr< > ::boost::regex_traits_wrapper<traits> >& t) > : m_ptraits(t), m_expression(0), m_expression_len(0) {} > regex_data() > : m_ptraits(new ::boost::regex_traits_wrapper<traits>()), m_expression(0), m_expression_len(0) {} > > ::boost::shared_ptr< > ::boost::regex_traits_wrapper<traits> > > m_ptraits; > flag_type m_flags; > int m_status; > const charT* m_expression; > std::ptrdiff_t m_expression_len; > size_type m_mark_count; > re_detail::re_syntax_base* m_first_state; > unsigned m_restart_type; > unsigned char m_startmap[1 << 8]; > unsigned int m_can_be_null; > re_detail::raw_storage m_data; > typename traits::char_class_type m_word_mask; > std::vector< > std::pair< > std::size_t, std::size_t> > m_subs; > bool m_has_recursions; >}; > > > > >template <class charT, class traits> >class basic_regex_implementation > : public regex_data<charT, traits> >{ >public: > typedef regex_constants::syntax_option_type flag_type; > typedef std::ptrdiff_t difference_type; > typedef std::size_t size_type; > typedef typename traits::locale_type locale_type; > typedef const charT* const_iterator; > > basic_regex_implementation(){} > basic_regex_implementation(const ::boost::shared_ptr< > ::boost::regex_traits_wrapper<traits> >& t) > : regex_data<charT, traits>(t) {} > void assign(const charT* arg_first, > const charT* arg_last, > flag_type f) > { > regex_data<charT, traits>* pdat = this; > basic_regex_parser<charT, traits> parser(pdat); > parser.parse(arg_first, arg_last, f); > } > > locale_type imbue(locale_type l) > { > return this->m_ptraits->imbue(l); > } > locale_type getloc()const > { > return this->m_ptraits->getloc(); > } > std::basic_string<charT> str()const > { > std::basic_string<charT> result; > if(this->m_status == 0) > result = std::basic_string<charT>(this->m_expression, this->m_expression_len); > return result; > } > const_iterator expression()const > { > return this->m_expression; > } > std::pair<const_iterator, const_iterator> subexpression(std::size_t n)const > { > if(n == 0) > boost::throw_exception(std::out_of_range("0 is not a valid subexpression index.")); > const std::pair<std::size_t, std::size_t>& pi = this->m_subs.at(n - 1); > std::pair<const_iterator, const_iterator> p(expression() + pi.first, expression() + pi.second); > return p; > } > > > const_iterator begin()const > { > return (this->m_status ? 0 : this->m_expression); > } > const_iterator end()const > { > return (this->m_status ? 0 : this->m_expression + this->m_expression_len); > } > flag_type flags()const > { > return this->m_flags; > } > size_type size()const > { > return this->m_expression_len; > } > int status()const > { > return this->m_status; > } > size_type mark_count()const > { > return this->m_mark_count; > } > const re_detail::re_syntax_base* get_first_state()const > { > return this->m_first_state; > } > unsigned get_restart_type()const > { > return this->m_restart_type; > } > const unsigned char* get_map()const > { > return this->m_startmap; > } > const ::boost::regex_traits_wrapper<traits>& get_traits()const > { > return *(this->m_ptraits); > } > bool can_be_null()const > { > return this->m_can_be_null; > } > const regex_data<charT, traits>& get_data()const > { > basic_regex_implementation<charT, traits> const* p = this; > return *static_cast<const regex_data<charT, traits>*>(p); > } >}; > >} ># 308 "/usr/include/boost/regex/v4/basic_regex.hpp" 3 4 >template <class charT, class traits > > >class basic_regex : public regbase >{ >public: > > typedef std::size_t traits_size_type; > typedef typename traits::string_type traits_string_type; > typedef charT char_type; > typedef traits traits_type; > > typedef charT value_type; > typedef charT& reference; > typedef const charT& const_reference; > typedef const charT* const_iterator; > typedef const_iterator iterator; > typedef std::ptrdiff_t difference_type; > typedef std::size_t size_type; > typedef regex_constants::syntax_option_type flag_type; > > > > typedef typename traits::locale_type locale_type; > >public: > explicit basic_regex(){} > explicit basic_regex(const charT* p, flag_type f = regex_constants::normal) > { > assign(p, f); > } > basic_regex(const charT* p1, const charT* p2, flag_type f = regex_constants::normal) > { > assign(p1, p2, f); > } > basic_regex(const charT* p, size_type len, flag_type f) > { > assign(p, len, f); > } > basic_regex(const basic_regex& that) > : m_pimpl(that.m_pimpl) {} > ~basic_regex(){} > basic_regex& operator=(const basic_regex& that) > { > return assign(that); > } > basic_regex& operator=(const charT* ptr) > { > return assign(ptr); > } > > > > basic_regex& assign(const basic_regex& that) > { > m_pimpl = that.m_pimpl; > return *this; > } > basic_regex& assign(const charT* p, flag_type f = regex_constants::normal) > { > return assign(p, p + traits::length(p), f); > } > basic_regex& assign(const charT* p, size_type len, flag_type f) > { > return assign(p, p + len, f); > } >private: > basic_regex& do_assign(const charT* p1, > const charT* p2, > flag_type f); >public: > basic_regex& assign(const charT* p1, > const charT* p2, > flag_type f = regex_constants::normal) > { > return do_assign(p1, p2, f); > } > > > template <class ST, class SA> > unsigned int set_expression(const std::basic_string<charT, ST, SA>& p, flag_type f = regex_constants::normal) > { > return set_expression(p.data(), p.data() + p.size(), f); > } > > template <class ST, class SA> > explicit basic_regex(const std::basic_string<charT, ST, SA>& p, flag_type f = regex_constants::normal) > { > assign(p, f); > } > > template <class InputIterator> > basic_regex(InputIterator arg_first, InputIterator arg_last, flag_type f = regex_constants::normal) > { > typedef typename traits::string_type seq_type; > seq_type a(arg_first, arg_last); > if(a.size()) > assign(static_cast<const charT*>(&*a.begin()), static_cast<const charT*>(&*a.begin() + a.size()), f); > else > assign(static_cast<const charT*>(0), static_cast<const charT*>(0), f); > } > > template <class ST, class SA> > basic_regex& operator=(const std::basic_string<charT, ST, SA>& p) > { > return assign(p.data(), p.data() + p.size(), regex_constants::normal); > } > > template <class string_traits, class A> > basic_regex& assign( > const std::basic_string<charT, string_traits, A>& s, > flag_type f = regex_constants::normal) > { > return assign(s.data(), s.data() + s.size(), f); > } > > template <class InputIterator> > basic_regex& assign(InputIterator arg_first, > InputIterator arg_last, > flag_type f = regex_constants::normal) > { > typedef typename traits::string_type seq_type; > seq_type a(arg_first, arg_last); > if(a.size()) > { > const charT* p1 = &*a.begin(); > const charT* p2 = &*a.begin() + a.size(); > return assign(p1, p2, f); > } > return assign(static_cast<const charT*>(0), static_cast<const charT*>(0), f); > } ># 465 "/usr/include/boost/regex/v4/basic_regex.hpp" 3 4 > locale_type imbue(locale_type l); > locale_type getloc()const > { > return m_pimpl.get() ? m_pimpl->getloc() : locale_type(); > } > > > > > flag_type getflags()const > { > return flags(); > } > flag_type flags()const > { > return m_pimpl.get() ? m_pimpl->flags() : 0; > } > > > std::basic_string<charT> str()const > { > return m_pimpl.get() ? m_pimpl->str() : std::basic_string<charT>(); > } > > > std::pair<const_iterator, const_iterator> subexpression(std::size_t n)const > { > if(!m_pimpl.get()) > boost::throw_exception(std::logic_error("Can't access subexpressions in an invalid regex.")); > return m_pimpl->subexpression(n); > } > const_iterator begin()const > { > return (m_pimpl.get() ? m_pimpl->begin() : 0); > } > const_iterator end()const > { > return (m_pimpl.get() ? m_pimpl->end() : 0); > } > > > void swap(basic_regex& that)throw() > { > m_pimpl.swap(that.m_pimpl); > } > > > size_type size()const > { > return (m_pimpl.get() ? m_pimpl->size() : 0); > } > > > size_type max_size()const > { > return (2147483647 * 2U + 1U); > } > > > bool empty()const > { > return (m_pimpl.get() ? 0 != m_pimpl->status() : true); > } > > size_type mark_count()const > { > return (m_pimpl.get() ? m_pimpl->mark_count() : 0); > } > > int status()const > { > return (m_pimpl.get() ? m_pimpl->status() : regex_constants::error_empty); > } > > int compare(const basic_regex& that) const > { > if(m_pimpl.get() == that.m_pimpl.get()) > return 0; > if(!m_pimpl.get()) > return -1; > if(!that.m_pimpl.get()) > return 1; > if(status() != that.status()) > return status() - that.status(); > if(flags() != that.flags()) > return flags() - that.flags(); > return str().compare(that.str()); > } > bool operator==(const basic_regex& e)const > { > return compare(e) == 0; > } > bool operator != (const basic_regex& e)const > { > return compare(e) != 0; > } > bool operator<(const basic_regex& e)const > { > return compare(e) < 0; > } > bool operator>(const basic_regex& e)const > { > return compare(e) > 0; > } > bool operator<=(const basic_regex& e)const > { > return compare(e) <= 0; > } > bool operator>=(const basic_regex& e)const > { > return compare(e) >= 0; > } > > > > > const charT* expression()const > { > return (m_pimpl.get() && !m_pimpl->status() ? m_pimpl->expression() : 0); > } > unsigned int set_expression(const charT* p1, const charT* p2, flag_type f = regex_constants::normal) > { > assign(p1, p2, f | regex_constants::no_except); > return status(); > } > unsigned int set_expression(const charT* p, flag_type f = regex_constants::normal) > { > assign(p, f | regex_constants::no_except); > return status(); > } > unsigned int error_code()const > { > return status(); > } > > > > const re_detail::re_syntax_base* get_first_state()const > { > (static_cast<void> (0)); > return m_pimpl->get_first_state(); > } > unsigned get_restart_type()const > { > (static_cast<void> (0)); > return m_pimpl->get_restart_type(); > } > const unsigned char* get_map()const > { > (static_cast<void> (0)); > return m_pimpl->get_map(); > } > const ::boost::regex_traits_wrapper<traits>& get_traits()const > { > (static_cast<void> (0)); > return m_pimpl->get_traits(); > } > bool can_be_null()const > { > (static_cast<void> (0)); > return m_pimpl->can_be_null(); > } > const re_detail::regex_data<charT, traits>& get_data()const > { > (static_cast<void> (0)); > return m_pimpl->get_data(); > } > boost::shared_ptr<re_detail::named_subexpressions > get_named_subs()const > { > return m_pimpl; > } > >private: > shared_ptr<re_detail::basic_regex_implementation<charT, traits> > m_pimpl; >}; > > > > > > > >template <class charT, class traits> >basic_regex<charT, traits>& basic_regex<charT, traits>::do_assign(const charT* p1, > const charT* p2, > flag_type f) >{ > shared_ptr<re_detail::basic_regex_implementation<charT, traits> > temp; > if(!m_pimpl.get()) > { > temp = shared_ptr<re_detail::basic_regex_implementation<charT, traits> >(new re_detail::basic_regex_implementation<charT, traits>()); > } > else > { > temp = shared_ptr<re_detail::basic_regex_implementation<charT, traits> >(new re_detail::basic_regex_implementation<charT, traits>(m_pimpl->m_ptraits)); > } > temp->assign(p1, p2, f); > temp.swap(m_pimpl); > return *this; >} > >template <class charT, class traits> >typename basic_regex<charT, traits>::locale_type basic_regex<charT, traits>::imbue(locale_type l) >{ > shared_ptr<re_detail::basic_regex_implementation<charT, traits> > temp(new re_detail::basic_regex_implementation<charT, traits>()); > locale_type result = temp->imbue(l); > temp.swap(m_pimpl); > return result; >} > > > > >template <class charT, class traits> >void swap(basic_regex<charT, traits>& e1, basic_regex<charT, traits>& e2) >{ > e1.swap(e2); >} > > >template <class charT, class traits, class traits2> >std::basic_ostream<charT, traits>& > operator << (std::basic_ostream<charT, traits>& os, > const basic_regex<charT, traits2>& e) >{ > return (os << e.str()); >} ># 708 "/usr/include/boost/regex/v4/basic_regex.hpp" 3 4 >template <class charT, class traits > > >class reg_expression : public basic_regex<charT, traits> >{ >public: > typedef typename basic_regex<charT, traits>::flag_type flag_type; > typedef typename basic_regex<charT, traits>::size_type size_type; > explicit reg_expression(){} > explicit reg_expression(const charT* p, flag_type f = regex_constants::normal) > : basic_regex<charT, traits>(p, f){} > reg_expression(const charT* p1, const charT* p2, flag_type f = regex_constants::normal) > : basic_regex<charT, traits>(p1, p2, f){} > reg_expression(const charT* p, size_type len, flag_type f) > : basic_regex<charT, traits>(p, len, f){} > reg_expression(const reg_expression& that) > : basic_regex<charT, traits>(that) {} > ~reg_expression(){} > reg_expression& operator=(const reg_expression& that) > { > return this->assign(that); > } > > > template <class ST, class SA> > explicit reg_expression(const std::basic_string<charT, ST, SA>& p, flag_type f = regex_constants::normal) > : basic_regex<charT, traits>(p, f) > { > } > > template <class InputIterator> > reg_expression(InputIterator arg_first, InputIterator arg_last, flag_type f = regex_constants::normal) > : basic_regex<charT, traits>(arg_first, arg_last, f) > { > } > > template <class ST, class SA> > reg_expression& operator=(const std::basic_string<charT, ST, SA>& p) > { > this->assign(p); > return *this; > } ># 762 "/usr/include/boost/regex/v4/basic_regex.hpp" 3 4 >}; > > > > > >} ># 68 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/basic_regex_creator.hpp" 1 3 4 ># 39 "/usr/include/boost/regex/v4/basic_regex_creator.hpp" 3 4 >namespace boost{ > >namespace re_detail{ > >template <class charT> >struct digraph : public std::pair<charT, charT> >{ > digraph() : std::pair<charT, charT>(0, 0){} > digraph(charT c1) : std::pair<charT, charT>(c1, 0){} > digraph(charT c1, charT c2) : std::pair<charT, charT>(c1, c2) > {} > > digraph(const digraph<charT>& d) : std::pair<charT, charT>(d.first, d.second){} > > template <class Seq> > digraph(const Seq& s) : std::pair<charT, charT>() > { > (static_cast<void> (0)); > (static_cast<void> (0)); > this->first = s[0]; > this->second = (s.size() > 1) ? s[1] : 0; > } >}; > >template <class charT, class traits> >class basic_char_set >{ >public: > typedef digraph<charT> digraph_type; > typedef typename traits::string_type string_type; > typedef typename traits::char_class_type m_type; > > basic_char_set() > { > m_negate = false; > m_has_digraphs = false; > m_classes = 0; > m_negated_classes = 0; > m_empty = true; > } > > void add_single(const digraph_type& s) > { > m_singles.insert(m_singles.end(), s); > if(s.second) > m_has_digraphs = true; > m_empty = false; > } > void add_range(const digraph_type& first, const digraph_type& end) > { > m_ranges.insert(m_ranges.end(), first); > m_ranges.insert(m_ranges.end(), end); > if(first.second) > { > m_has_digraphs = true; > add_single(first); > } > if(end.second) > { > m_has_digraphs = true; > add_single(end); > } > m_empty = false; > } > void add_class(m_type m) > { > m_classes |= m; > m_empty = false; > } > void add_negated_class(m_type m) > { > m_negated_classes |= m; > m_empty = false; > } > void add_equivalent(const digraph_type& s) > { > m_equivalents.insert(m_equivalents.end(), s); > if(s.second) > { > m_has_digraphs = true; > add_single(s); > } > m_empty = false; > } > void negate() > { > m_negate = true; > > } > > > > > bool has_digraphs()const > { > return m_has_digraphs; > } > bool is_negated()const > { > return m_negate; > } > typedef typename std::vector<digraph_type>::const_iterator list_iterator; > list_iterator singles_begin()const > { > return m_singles.begin(); > } > list_iterator singles_end()const > { > return m_singles.end(); > } > list_iterator ranges_begin()const > { > return m_ranges.begin(); > } > list_iterator ranges_end()const > { > return m_ranges.end(); > } > list_iterator equivalents_begin()const > { > return m_equivalents.begin(); > } > list_iterator equivalents_end()const > { > return m_equivalents.end(); > } > m_type classes()const > { > return m_classes; > } > m_type negated_classes()const > { > return m_negated_classes; > } > bool empty()const > { > return m_empty; > } >private: > std::vector<digraph_type> m_singles; > std::vector<digraph_type> m_ranges; > bool m_negate; > bool m_has_digraphs; > m_type m_classes; > m_type m_negated_classes; > bool m_empty; > std::vector<digraph_type> m_equivalents; >}; > >template <class charT, class traits> >class basic_regex_creator >{ >public: > basic_regex_creator(regex_data<charT, traits>* data); > std::ptrdiff_t getoffset(void* addr) > { > return getoffset(addr, m_pdata->m_data.data()); > } > std::ptrdiff_t getoffset(const void* addr, const void* base) > { > return static_cast<const char*>(addr) - static_cast<const char*>(base); > } > re_syntax_base* getaddress(std::ptrdiff_t off) > { > return getaddress(off, m_pdata->m_data.data()); > } > re_syntax_base* getaddress(std::ptrdiff_t off, void* base) > { > return static_cast<re_syntax_base*>(static_cast<void*>(static_cast<char*>(base) + off)); > } > void init(unsigned l_flags) > { > m_pdata->m_flags = l_flags; > m_icase = l_flags & regex_constants::icase; > } > regbase::flag_type flags() > { > return m_pdata->m_flags; > } > void flags(regbase::flag_type f) > { > m_pdata->m_flags = f; > if(m_icase != static_cast<bool>(f & regbase::icase)) > { > m_icase = static_cast<bool>(f & regbase::icase); > } > } > re_syntax_base* append_state(syntax_element_type t, std::size_t s = sizeof(re_syntax_base)); > re_syntax_base* insert_state(std::ptrdiff_t pos, syntax_element_type t, std::size_t s = sizeof(re_syntax_base)); > re_literal* append_literal(charT c); > re_syntax_base* append_set(const basic_char_set<charT, traits>& char_set); > re_syntax_base* append_set(const basic_char_set<charT, traits>& char_set, mpl::false_*); > re_syntax_base* append_set(const basic_char_set<charT, traits>& char_set, mpl::true_*); > void finalize(const charT* p1, const charT* p2); >protected: > regex_data<charT, traits>* m_pdata; > const ::boost::regex_traits_wrapper<traits>& > m_traits; > re_syntax_base* m_last_state; > bool m_icase; > unsigned m_repeater_id; > bool m_has_backrefs; > unsigned m_backrefs; > boost::uintmax_t m_bad_repeats; > bool m_has_recursions; > std::vector<bool> m_recursion_checks; > typename traits::char_class_type m_word_mask; > typename traits::char_class_type m_mask_space; > typename traits::char_class_type m_lower_mask; > typename traits::char_class_type m_upper_mask; > typename traits::char_class_type m_alpha_mask; >private: > basic_regex_creator& operator=(const basic_regex_creator&); > basic_regex_creator(const basic_regex_creator&); > > void fixup_pointers(re_syntax_base* state); > void fixup_recursions(re_syntax_base* state); > void create_startmaps(re_syntax_base* state); > int calculate_backstep(re_syntax_base* state); > void create_startmap(re_syntax_base* state, unsigned char* l_map, unsigned int* pnull, unsigned char mask); > unsigned get_restart_type(re_syntax_base* state); > void set_all_masks(unsigned char* bits, unsigned char); > bool is_bad_repeat(re_syntax_base* pt); > void set_bad_repeat(re_syntax_base* pt); > syntax_element_type get_repeat_type(re_syntax_base* state); > void probe_leading_repeat(re_syntax_base* state); >}; > >template <class charT, class traits> >basic_regex_creator<charT, traits>::basic_regex_creator(regex_data<charT, traits>* data) > : m_pdata(data), m_traits(*(data->m_ptraits)), m_last_state(0), m_repeater_id(0), m_has_backrefs(false), m_backrefs(0), m_has_recursions(false) >{ > m_pdata->m_data.clear(); > m_pdata->m_status = ::boost::regex_constants::error_ok; > static const charT w = 'w'; > static const charT s = 's'; > static const charT l[5] = { 'l', 'o', 'w', 'e', 'r', }; > static const charT u[5] = { 'u', 'p', 'p', 'e', 'r', }; > static const charT a[5] = { 'a', 'l', 'p', 'h', 'a', }; > m_word_mask = m_traits.lookup_classname(&w, &w +1); > m_mask_space = m_traits.lookup_classname(&s, &s +1); > m_lower_mask = m_traits.lookup_classname(l, l + 5); > m_upper_mask = m_traits.lookup_classname(u, u + 5); > m_alpha_mask = m_traits.lookup_classname(a, a + 5); > m_pdata->m_word_mask = m_word_mask; > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); >} > >template <class charT, class traits> >re_syntax_base* basic_regex_creator<charT, traits>::append_state(syntax_element_type t, std::size_t s) >{ > > if(t == syntax_element_backref) > this->m_has_backrefs = true; > > m_pdata->m_data.align(); > > if(m_last_state) > m_last_state->next.i = m_pdata->m_data.size() - getoffset(m_last_state); > > m_last_state = static_cast<re_syntax_base*>(m_pdata->m_data.extend(s)); > > m_last_state->next.i = 0; > m_last_state->type = t; > return m_last_state; >} > >template <class charT, class traits> >re_syntax_base* basic_regex_creator<charT, traits>::insert_state(std::ptrdiff_t pos, syntax_element_type t, std::size_t s) >{ > > m_pdata->m_data.align(); > > if(m_last_state) > m_last_state->next.i = m_pdata->m_data.size() - getoffset(m_last_state); > > std::ptrdiff_t off = getoffset(m_last_state) + s; > > re_syntax_base* new_state = static_cast<re_syntax_base*>(m_pdata->m_data.insert(pos, s)); > > new_state->next.i = s; > new_state->type = t; > m_last_state = getaddress(off); > return new_state; >} > >template <class charT, class traits> >re_literal* basic_regex_creator<charT, traits>::append_literal(charT c) >{ > re_literal* result; > > if((0 == m_last_state) || (m_last_state->type != syntax_element_literal)) > { > > result = static_cast<re_literal*>(append_state(syntax_element_literal, sizeof(re_literal) + sizeof(charT))); > result->length = 1; > *static_cast<charT*>(static_cast<void*>(result+1)) = m_traits.translate(c, m_icase); > } > else > { > > std::ptrdiff_t off = getoffset(m_last_state); > m_pdata->m_data.extend(sizeof(charT)); > m_last_state = result = static_cast<re_literal*>(getaddress(off)); > charT* characters = static_cast<charT*>(static_cast<void*>(result+1)); > characters[result->length] = m_traits.translate(c, m_icase); > ++(result->length); > } > return result; >} > >template <class charT, class traits> >inline re_syntax_base* basic_regex_creator<charT, traits>::append_set( > const basic_char_set<charT, traits>& char_set) >{ > typedef mpl::bool_< (sizeof(charT) == 1) > truth_type; > return char_set.has_digraphs() > ? append_set(char_set, static_cast<mpl::false_*>(0)) > : append_set(char_set, static_cast<truth_type*>(0)); >} > >template <class charT, class traits> >re_syntax_base* basic_regex_creator<charT, traits>::append_set( > const basic_char_set<charT, traits>& char_set, mpl::false_*) >{ > typedef typename traits::string_type string_type; > typedef typename basic_char_set<charT, traits>::list_iterator item_iterator; > typedef typename traits::char_class_type m_type; > > re_set_long<m_type>* result = static_cast<re_set_long<m_type>*>(append_state(syntax_element_long_set, sizeof(re_set_long<m_type>))); > > > > result->csingles = static_cast<unsigned int>(::boost::re_detail::distance(char_set.singles_begin(), char_set.singles_end())); > result->cranges = static_cast<unsigned int>(::boost::re_detail::distance(char_set.ranges_begin(), char_set.ranges_end())) / 2; > result->cequivalents = static_cast<unsigned int>(::boost::re_detail::distance(char_set.equivalents_begin(), char_set.equivalents_end())); > result->cclasses = char_set.classes(); > result->cnclasses = char_set.negated_classes(); > if(flags() & regbase::icase) > { > > if(((result->cclasses & m_lower_mask) == m_lower_mask) || ((result->cclasses & m_upper_mask) == m_upper_mask)) > result->cclasses |= m_alpha_mask; > if(((result->cnclasses & m_lower_mask) == m_lower_mask) || ((result->cnclasses & m_upper_mask) == m_upper_mask)) > result->cnclasses |= m_alpha_mask; > } > > result->isnot = char_set.is_negated(); > result->singleton = !char_set.has_digraphs(); > > > > std::ptrdiff_t offset = getoffset(result); > > > > item_iterator first, last; > first = char_set.singles_begin(); > last = char_set.singles_end(); > while(first != last) > { > charT* p = static_cast<charT*>(this->m_pdata->m_data.extend(sizeof(charT) * (first->second ? 3 : 2))); > p[0] = m_traits.translate(first->first, m_icase); > if(first->second) > { > p[1] = m_traits.translate(first->second, m_icase); > p[2] = 0; > } > else > p[1] = 0; > ++first; > } > > > > first = char_set.ranges_begin(); > last = char_set.ranges_end(); > while(first != last) > { > > digraph<charT> c1 = *first; > c1.first = this->m_traits.translate(c1.first, this->m_icase); > c1.second = this->m_traits.translate(c1.second, this->m_icase); > ++first; > digraph<charT> c2 = *first; > c2.first = this->m_traits.translate(c2.first, this->m_icase); > c2.second = this->m_traits.translate(c2.second, this->m_icase); > ++first; > string_type s1, s2; > > if(flags() & regex_constants::collate) > { ># 445 "/usr/include/boost/regex/v4/basic_regex_creator.hpp" 3 4 > charT a1[3] = { c1.first, c1.second, charT(0), }; > charT a2[3] = { c2.first, c2.second, charT(0), }; > s1 = this->m_traits.transform(a1, (a1[1] ? a1+2 : a1+1)); > s2 = this->m_traits.transform(a2, (a2[1] ? a2+2 : a2+1)); > > if(s1.size() == 0) > s1 = string_type(1, charT(0)); > if(s2.size() == 0) > s2 = string_type(1, charT(0)); > } > else > { > if(c1.second) > { > s1.insert(s1.end(), c1.first); > s1.insert(s1.end(), c1.second); > } > else > s1 = string_type(1, c1.first); > if(c2.second) > { > s2.insert(s2.end(), c2.first); > s2.insert(s2.end(), c2.second); > } > else > s2.insert(s2.end(), c2.first); > } > if(s1 > s2) > { > > return 0; > } > charT* p = static_cast<charT*>(this->m_pdata->m_data.extend(sizeof(charT) * (s1.size() + s2.size() + 2) ) ); > re_detail::copy(s1.begin(), s1.end(), p); > p[s1.size()] = charT(0); > p += s1.size() + 1; > re_detail::copy(s2.begin(), s2.end(), p); > p[s2.size()] = charT(0); > } > > > > first = char_set.equivalents_begin(); > last = char_set.equivalents_end(); > while(first != last) > { > string_type s; > if(first->second) > { > > > > > > > charT cs[3] = { first->first, first->second, charT(0), }; > s = m_traits.transform_primary(cs, cs+2); > > } > else > s = m_traits.transform_primary(&first->first, &first->first+1); > if(s.empty()) > return 0; > charT* p = static_cast<charT*>(this->m_pdata->m_data.extend(sizeof(charT) * (s.size()+1) ) ); > re_detail::copy(s.begin(), s.end(), p); > p[s.size()] = charT(0); > ++first; > } > > > > m_last_state = result = static_cast<re_set_long<m_type>*>(getaddress(offset)); > return result; >} > >template<class T> >inline bool char_less(T t1, T t2) >{ > return t1 < t2; >} >inline bool char_less(char t1, char t2) >{ > return static_cast<unsigned char>(t1) < static_cast<unsigned char>(t2); >} >inline bool char_less(signed char t1, signed char t2) >{ > return static_cast<unsigned char>(t1) < static_cast<unsigned char>(t2); >} > >template <class charT, class traits> >re_syntax_base* basic_regex_creator<charT, traits>::append_set( > const basic_char_set<charT, traits>& char_set, mpl::true_*) >{ > typedef typename traits::string_type string_type; > typedef typename basic_char_set<charT, traits>::list_iterator item_iterator; > > re_set* result = static_cast<re_set*>(append_state(syntax_element_set, sizeof(re_set))); > bool negate = char_set.is_negated(); > std::memset(result->_map, 0, sizeof(result->_map)); > > > > item_iterator first, last; > first = char_set.singles_begin(); > last = char_set.singles_end(); > while(first != last) > { > for(unsigned int i = 0; i < (1 << 8); ++i) > { > if(this->m_traits.translate(static_cast<charT>(i), this->m_icase) > == this->m_traits.translate(first->first, this->m_icase)) > result->_map[i] = true; > } > ++first; > } > > > > first = char_set.ranges_begin(); > last = char_set.ranges_end(); > while(first != last) > { > > charT c1 = this->m_traits.translate(first->first, this->m_icase); > ++first; > charT c2 = this->m_traits.translate(first->first, this->m_icase); > ++first; > > if(flags() & regex_constants::collate) > { > > charT c3[2] = { c1, charT(0), }; > string_type s1 = this->m_traits.transform(c3, c3+1); > c3[0] = c2; > string_type s2 = this->m_traits.transform(c3, c3+1); > if(s1 > s2) > { > > return 0; > } > (static_cast<void> (0)); > for(unsigned i = 0; i < (1u << 8); ++i) > { > c3[0] = static_cast<charT>(i); > string_type s3 = this->m_traits.transform(c3, c3 +1); > if((s1 <= s3) && (s3 <= s2)) > result->_map[i] = true; > } > } > else > { > if(char_less(c2, c1)) > { > > return 0; > } > > std::memset(result->_map + static_cast<unsigned char>(c1), true, 1 + static_cast<unsigned char>(c2) - static_cast<unsigned char>(c1)); > } > } > > > > typedef typename traits::char_class_type m_type; > m_type m = char_set.classes(); > if(flags() & regbase::icase) > { > > if(((m & m_lower_mask) == m_lower_mask) || ((m & m_upper_mask) == m_upper_mask)) > m |= m_alpha_mask; > } > if(m != 0) > { > for(unsigned i = 0; i < (1u << 8); ++i) > { > if(this->m_traits.isctype(static_cast<charT>(i), m)) > result->_map[i] = true; > } > } > > > > m = char_set.negated_classes(); > if(flags() & regbase::icase) > { > > if(((m & m_lower_mask) == m_lower_mask) || ((m & m_upper_mask) == m_upper_mask)) > m |= m_alpha_mask; > } > if(m != 0) > { > for(unsigned i = 0; i < (1u << 8); ++i) > { > if(0 == this->m_traits.isctype(static_cast<charT>(i), m)) > result->_map[i] = true; > } > } > > > > first = char_set.equivalents_begin(); > last = char_set.equivalents_end(); > while(first != last) > { > string_type s; > (static_cast<void> (0)); > s = m_traits.transform_primary(&first->first, &first->first+1); > if(s.empty()) > return 0; > for(unsigned i = 0; i < (1u << 8); ++i) > { > charT c[2] = { (static_cast<charT>(i)), charT(0), }; > string_type s2 = this->m_traits.transform_primary(c, c+1); > if(s == s2) > result->_map[i] = true; > } > ++first; > } > if(negate) > { > for(unsigned i = 0; i < (1u << 8); ++i) > { > result->_map[i] = !(result->_map[i]); > } > } > return result; >} > >template <class charT, class traits> >void basic_regex_creator<charT, traits>::finalize(const charT* p1, const charT* p2) >{ > if(this->m_pdata->m_status) > return; > > > append_state(syntax_element_match); > > std::ptrdiff_t len = p2 - p1; > m_pdata->m_expression_len = len; > charT* ps = static_cast<charT*>(m_pdata->m_data.extend(sizeof(charT) * (1 + (p2 - p1)))); > m_pdata->m_expression = ps; > re_detail::copy(p1, p2, ps); > ps[p2 - p1] = 0; > > > m_pdata->m_status = 0; > > m_pdata->m_first_state = static_cast<re_syntax_base*>(m_pdata->m_data.data()); > > fixup_pointers(m_pdata->m_first_state); > if(m_has_recursions) > { > m_pdata->m_has_recursions = true; > fixup_recursions(m_pdata->m_first_state); > if(this->m_pdata->m_status) > return; > } > else > m_pdata->m_has_recursions = false; > > create_startmaps(m_pdata->m_first_state); > > std::memset(m_pdata->m_startmap, 0, sizeof(m_pdata->m_startmap)); > m_pdata->m_can_be_null = 0; > > m_bad_repeats = 0; > if(m_has_recursions) > m_recursion_checks.assign(1 + m_pdata->m_mark_count, false); > create_startmap(m_pdata->m_first_state, m_pdata->m_startmap, &(m_pdata->m_can_be_null), mask_all); > > m_pdata->m_restart_type = get_restart_type(m_pdata->m_first_state); > > probe_leading_repeat(m_pdata->m_first_state); >} > >template <class charT, class traits> >void basic_regex_creator<charT, traits>::fixup_pointers(re_syntax_base* state) >{ > while(state) > { > switch(state->type) > { > case syntax_element_recurse: > m_has_recursions = true; > if(state->next.i) > state->next.p = getaddress(state->next.i, state); > else > state->next.p = 0; > break; > case syntax_element_rep: > case syntax_element_dot_rep: > case syntax_element_char_rep: > case syntax_element_short_set_rep: > case syntax_element_long_set_rep: > > static_cast<re_repeat*>(state)->state_id = m_repeater_id++; > ((void)0); > case syntax_element_alt: > std::memset(static_cast<re_alt*>(state)->_map, 0, sizeof(static_cast<re_alt*>(state)->_map)); > static_cast<re_alt*>(state)->can_be_null = 0; > ((void)0); > case syntax_element_jump: > static_cast<re_jump*>(state)->alt.p = getaddress(static_cast<re_jump*>(state)->alt.i, state); > ((void)0); > default: > if(state->next.i) > state->next.p = getaddress(state->next.i, state); > else > state->next.p = 0; > } > state = state->next.p; > } >} > >template <class charT, class traits> >void basic_regex_creator<charT, traits>::fixup_recursions(re_syntax_base* state) >{ > re_syntax_base* base = state; > while(state) > { > switch(state->type) > { > case syntax_element_assert_backref: > { > > int idx = static_cast<const re_brace*>(state)->index; > if(idx < 0) > { > idx = -idx-1; > if(idx >= 10000) > { > idx = m_pdata->get_id(idx); > if(idx <= 0) > { > > if(0 == this->m_pdata->m_status) > this->m_pdata->m_status = boost::regex_constants::error_bad_pattern; > > > > this->m_pdata->m_expression = 0; > this->m_pdata->m_expression_len = 0; > > > > if(0 == (this->flags() & regex_constants::no_except)) > { > std::string message = "Encountered a forward reference to a marked sub-expression that does not exist."; > boost::regex_error e(message, boost::regex_constants::error_bad_pattern, 0); > e.raise(); > } > } > } > } > } > break; > case syntax_element_recurse: > { > bool ok = false; > re_syntax_base* p = base; > std::ptrdiff_t idx = static_cast<re_jump*>(state)->alt.i; > if(idx > 10000) > { > > > > > idx = m_pdata->get_id(static_cast<int>(idx)); > } > while(p) > { > if((p->type == syntax_element_startmark) && (static_cast<re_brace*>(p)->index == idx)) > { > > > > static_cast<re_jump*>(state)->alt.p = p; > ok = true; > > > > p = p->next.p; > int next_rep_id = 0; > while(p) > { > switch(p->type) > { > case syntax_element_rep: > case syntax_element_dot_rep: > case syntax_element_char_rep: > case syntax_element_short_set_rep: > case syntax_element_long_set_rep: > next_rep_id = static_cast<re_repeat*>(p)->state_id; > break; > case syntax_element_endmark: > if(static_cast<const re_brace*>(p)->index == idx) > next_rep_id = -1; > break; > default: > break; > } > if(next_rep_id) > break; > p = p->next.p; > } > if(next_rep_id > 0) > { > static_cast<re_recurse*>(state)->state_id = next_rep_id - 1; > } > > break; > } > p = p->next.p; > } > if(!ok) > { > > if(0 == this->m_pdata->m_status) > this->m_pdata->m_status = boost::regex_constants::error_bad_pattern; > > > > this->m_pdata->m_expression = 0; > this->m_pdata->m_expression_len = 0; > > > > if(0 == (this->flags() & regex_constants::no_except)) > { > std::string message = "Encountered a forward reference to a recursive sub-expression that does not exist."; > boost::regex_error e(message, boost::regex_constants::error_bad_pattern, 0); > e.raise(); > } > } > } > break; > default: > break; > } > state = state->next.p; > } >} > >template <class charT, class traits> >void basic_regex_creator<charT, traits>::create_startmaps(re_syntax_base* state) >{ ># 899 "/usr/include/boost/regex/v4/basic_regex_creator.hpp" 3 4 > bool l_icase = m_icase; > std::vector<std::pair<bool, re_syntax_base*> > v; > > while(state) > { > switch(state->type) > { > case syntax_element_toggle_case: > > m_icase = static_cast<re_case*>(state)->icase; > state = state->next.p; > continue; > case syntax_element_alt: > case syntax_element_rep: > case syntax_element_dot_rep: > case syntax_element_char_rep: > case syntax_element_short_set_rep: > case syntax_element_long_set_rep: > > v.push_back(std::pair<bool, re_syntax_base*>(m_icase, state)); > state = state->next.p; > break; > case syntax_element_backstep: > > static_cast<re_brace*>(state)->index > = this->calculate_backstep(state->next.p); > if(static_cast<re_brace*>(state)->index < 0) > { > > if(0 == this->m_pdata->m_status) > this->m_pdata->m_status = boost::regex_constants::error_bad_pattern; > > > > this->m_pdata->m_expression = 0; > this->m_pdata->m_expression_len = 0; > > > > if(0 == (this->flags() & regex_constants::no_except)) > { > std::string message = "Invalid lookbehind assertion encountered in the regular expression."; > boost::regex_error e(message, boost::regex_constants::error_bad_pattern, 0); > e.raise(); > } > } > ((void)0); > default: > state = state->next.p; > } > } > > > while(v.size()) > { > > if(m_has_recursions) > m_recursion_checks.assign(1 + m_pdata->m_mark_count, false); > > const std::pair<bool, re_syntax_base*>& p = v.back(); > m_icase = p.first; > state = p.second; > v.pop_back(); > > > m_bad_repeats = 0; > create_startmap(state->next.p, static_cast<re_alt*>(state)->_map, &static_cast<re_alt*>(state)->can_be_null, mask_take); > m_bad_repeats = 0; > > if(m_has_recursions) > m_recursion_checks.assign(1 + m_pdata->m_mark_count, false); > create_startmap(static_cast<re_alt*>(state)->alt.p, static_cast<re_alt*>(state)->_map, &static_cast<re_alt*>(state)->can_be_null, mask_skip); > > state->type = this->get_repeat_type(state); > } > > m_icase = l_icase; >} > >template <class charT, class traits> >int basic_regex_creator<charT, traits>::calculate_backstep(re_syntax_base* state) >{ > typedef typename traits::char_class_type m_type; > int result = 0; > while(state) > { > switch(state->type) > { > case syntax_element_startmark: > if((static_cast<re_brace*>(state)->index == -1) > || (static_cast<re_brace*>(state)->index == -2)) > { > state = static_cast<re_jump*>(state->next.p)->alt.p->next.p; > continue; > } > else if(static_cast<re_brace*>(state)->index == -3) > { > state = state->next.p->next.p; > continue; > } > break; > case syntax_element_endmark: > if((static_cast<re_brace*>(state)->index == -1) > || (static_cast<re_brace*>(state)->index == -2)) > return result; > break; > case syntax_element_literal: > result += static_cast<re_literal*>(state)->length; > break; > case syntax_element_wild: > case syntax_element_set: > result += 1; > break; > case syntax_element_dot_rep: > case syntax_element_char_rep: > case syntax_element_short_set_rep: > case syntax_element_backref: > case syntax_element_rep: > case syntax_element_combining: > case syntax_element_long_set_rep: > case syntax_element_backstep: > { > re_repeat* rep = static_cast<re_repeat *>(state); > > state->type = this->get_repeat_type(state); > if((state->type == syntax_element_dot_rep) > || (state->type == syntax_element_char_rep) > || (state->type == syntax_element_short_set_rep)) > { > if(rep->max != rep->min) > return -1; > result += static_cast<int>(rep->min); > state = rep->alt.p; > continue; > } > else if(state->type == syntax_element_long_set_rep) > { > (static_cast<void> (0)); > if(static_cast<re_set_long<m_type>*>(rep->next.p)->singleton == 0) > return -1; > if(rep->max != rep->min) > return -1; > result += static_cast<int>(rep->min); > state = rep->alt.p; > continue; > } > } > return -1; > case syntax_element_long_set: > if(static_cast<re_set_long<m_type>*>(state)->singleton == 0) > return -1; > result += 1; > break; > case syntax_element_jump: > state = static_cast<re_jump*>(state)->alt.p; > continue; > case syntax_element_alt: > { > int r1 = calculate_backstep(state->next.p); > int r2 = calculate_backstep(static_cast<re_alt*>(state)->alt.p); > if((r1 < 0) || (r1 != r2)) > return -1; > return result + r1; > } > default: > break; > } > state = state->next.p; > } > return -1; >} > >template <class charT, class traits> >void basic_regex_creator<charT, traits>::create_startmap(re_syntax_base* state, unsigned char* l_map, unsigned int* pnull, unsigned char mask) >{ > int not_last_jump = 1; > re_syntax_base* recursion_start = 0; > int recursion_sub = 0; > re_syntax_base* recursion_restart = 0; > > > bool l_icase = m_icase; > > while(state) > { > switch(state->type) > { > case syntax_element_toggle_case: > l_icase = static_cast<re_case*>(state)->icase; > state = state->next.p; > break; > case syntax_element_literal: > { > > > if(l_map) > { > l_map[0] |= mask_init; > charT first_char = *static_cast<charT*>(static_cast<void*>(static_cast<re_literal*>(state) + 1)); > for(unsigned int i = 0; i < (1u << 8); ++i) > { > if(m_traits.translate(static_cast<charT>(i), l_icase) == first_char) > l_map[i] |= mask; > } > } > return; > } > case syntax_element_end_line: > { > > if(l_map) > { > l_map[0] |= mask_init; > l_map[static_cast<unsigned>('\n')] |= mask; > l_map[static_cast<unsigned>('\r')] |= mask; > l_map[static_cast<unsigned>('\f')] |= mask; > l_map[0x85] |= mask; > } > > if(pnull) > create_startmap(state->next.p, 0, pnull, mask); > return; > } > case syntax_element_recurse: > { > if(state->type == syntax_element_startmark) > recursion_sub = static_cast<re_brace*>(state)->index; > else > recursion_sub = 0; > if(m_recursion_checks[recursion_sub]) > { > > if(0 == this->m_pdata->m_status) > this->m_pdata->m_status = boost::regex_constants::error_bad_pattern; > > > > this->m_pdata->m_expression = 0; > this->m_pdata->m_expression_len = 0; > > > > if(0 == (this->flags() & regex_constants::no_except)) > { > std::string message = "Encountered an infinite recursion."; > boost::regex_error e(message, boost::regex_constants::error_bad_pattern, 0); > e.raise(); > } > } > else if(recursion_start == 0) > { > recursion_start = state; > recursion_restart = state->next.p; > state = static_cast<re_jump*>(state)->alt.p; > m_recursion_checks[recursion_sub] = true; > break; > } > m_recursion_checks[recursion_sub] = true; > > ((void)0); > } > case syntax_element_backref: > > if(pnull) > *pnull |= mask; > ((void)0); > case syntax_element_wild: > { > > set_all_masks(l_map, mask); > return; > } > case syntax_element_match: > { > > set_all_masks(l_map, mask); > if(pnull) > *pnull |= mask; > return; > } > case syntax_element_word_start: > { > > create_startmap(state->next.p, l_map, pnull, mask); > if(l_map) > { > l_map[0] |= mask_init; > for(unsigned int i = 0; i < (1u << 8); ++i) > { > if(!m_traits.isctype(static_cast<charT>(i), m_word_mask)) > l_map[i] &= static_cast<unsigned char>(~mask); > } > } > return; > } > case syntax_element_word_end: > { > > create_startmap(state->next.p, l_map, pnull, mask); > if(l_map) > { > l_map[0] |= mask_init; > for(unsigned int i = 0; i < (1u << 8); ++i) > { > if(m_traits.isctype(static_cast<charT>(i), m_word_mask)) > l_map[i] &= static_cast<unsigned char>(~mask); > } > } > return; > } > case syntax_element_buffer_end: > { > > if(pnull) > *pnull |= mask; > return; > } > case syntax_element_long_set: > if(l_map) > { > typedef typename traits::char_class_type m_type; > if(static_cast<re_set_long<m_type>*>(state)->singleton) > { > l_map[0] |= mask_init; > for(unsigned int i = 0; i < (1u << 8); ++i) > { > charT c = static_cast<charT>(i); > if(&c != re_is_set_member(&c, &c + 1, static_cast<re_set_long<m_type>*>(state), *m_pdata, l_icase)) > l_map[i] |= mask; > } > } > else > set_all_masks(l_map, mask); > } > return; > case syntax_element_set: > if(l_map) > { > l_map[0] |= mask_init; > for(unsigned int i = 0; i < (1u << 8); ++i) > { > if(static_cast<re_set*>(state)->_map[ > static_cast<unsigned char>(m_traits.translate(static_cast<charT>(i), l_icase))]) > l_map[i] |= mask; > } > } > return; > case syntax_element_jump: > > state = static_cast<re_alt*>(state)->alt.p; > not_last_jump = -1; > break; > case syntax_element_alt: > case syntax_element_rep: > case syntax_element_dot_rep: > case syntax_element_char_rep: > case syntax_element_short_set_rep: > case syntax_element_long_set_rep: > { > re_alt* rep = static_cast<re_alt*>(state); > if(rep->_map[0] & mask_init) > { > if(l_map) > { > > l_map[0] |= mask_init; > for(unsigned int i = 0; i <= (127 * 2 + 1); ++i) > { > if(rep->_map[i] & mask_any) > l_map[i] |= mask; > } > } > if(pnull) > { > if(rep->can_be_null & mask_any) > *pnull |= mask; > } > } > else > { > > > if(is_bad_repeat(state)) > { > set_all_masks(l_map, mask); > if(pnull) > *pnull |= mask; > return; > } > set_bad_repeat(state); > create_startmap(state->next.p, l_map, pnull, mask); > if((state->type == syntax_element_alt) > || (static_cast<re_repeat*>(state)->min == 0) > || (not_last_jump == 0)) > create_startmap(rep->alt.p, l_map, pnull, mask); > } > } > return; > case syntax_element_soft_buffer_end: > > if(l_map) > { > l_map[0] |= mask_init; > l_map[static_cast<unsigned>('\n')] |= mask; > l_map[static_cast<unsigned>('\r')] |= mask; > } > if(pnull) > *pnull |= mask; > return; > case syntax_element_endmark: > > if(static_cast<re_brace*>(state)->index < 0) > { > > set_all_masks(l_map, mask); > if(pnull) > *pnull |= mask; > return; > } > else if(recursion_start && (recursion_sub != 0) && (recursion_sub == static_cast<re_brace*>(state)->index)) > { > > recursion_start = 0; > state = recursion_restart; > break; > } > > > > > > > > if(m_pdata->m_has_recursions && static_cast<re_brace*>(state)->index) > { > bool ok = false; > re_syntax_base* p = m_pdata->m_first_state; > while(p) > { > if(p->type == syntax_element_recurse) > { > re_brace* p2 = static_cast<re_brace*>(static_cast<re_jump*>(p)->alt.p); > if((p2->type == syntax_element_startmark) && (p2->index == static_cast<re_brace*>(state)->index)) > { > ok = true; > break; > } > } > p = p->next.p; > } > if(ok) > { > create_startmap(p->next.p, l_map, pnull, mask); > } > } > state = state->next.p; > break; > > case syntax_element_startmark: > > if(static_cast<re_brace*>(state)->index == -3) > { > state = state->next.p->next.p; > break; > } > ((void)0); > default: > state = state->next.p; > } > ++not_last_jump; > } >} > >template <class charT, class traits> >unsigned basic_regex_creator<charT, traits>::get_restart_type(re_syntax_base* state) >{ > > > > while(state) > { > switch(state->type) > { > case syntax_element_startmark: > case syntax_element_endmark: > state = state->next.p; > continue; > case syntax_element_start_line: > return regbase::restart_line; > case syntax_element_word_start: > return regbase::restart_word; > case syntax_element_buffer_start: > return regbase::restart_buf; > case syntax_element_restart_continue: > return regbase::restart_continue; > default: > state = 0; > continue; > } > } > return regbase::restart_any; >} > >template <class charT, class traits> >void basic_regex_creator<charT, traits>::set_all_masks(unsigned char* bits, unsigned char mask) >{ > > > > > > if(bits) > { > if(bits[0] == 0) > (std::memset)(bits, mask, 1u << 8); > else > { > for(unsigned i = 0; i < (1u << 8); ++i) > bits[i] |= mask; > } > bits[0] |= mask_init; > } >} > >template <class charT, class traits> >bool basic_regex_creator<charT, traits>::is_bad_repeat(re_syntax_base* pt) >{ > switch(pt->type) > { > case syntax_element_rep: > case syntax_element_dot_rep: > case syntax_element_char_rep: > case syntax_element_short_set_rep: > case syntax_element_long_set_rep: > { > unsigned state_id = static_cast<re_repeat*>(pt)->state_id; > if(state_id > sizeof(m_bad_repeats) * 8) > return true; > static const boost::uintmax_t one = 1uL; > return m_bad_repeats & (one << state_id); > } > default: > return false; > } >} > >template <class charT, class traits> >void basic_regex_creator<charT, traits>::set_bad_repeat(re_syntax_base* pt) >{ > switch(pt->type) > { > case syntax_element_rep: > case syntax_element_dot_rep: > case syntax_element_char_rep: > case syntax_element_short_set_rep: > case syntax_element_long_set_rep: > { > unsigned state_id = static_cast<re_repeat*>(pt)->state_id; > static const boost::uintmax_t one = 1uL; > if(state_id <= sizeof(m_bad_repeats) * 8) > m_bad_repeats |= (one << state_id); > } > break; > default: > break; > } >} > >template <class charT, class traits> >syntax_element_type basic_regex_creator<charT, traits>::get_repeat_type(re_syntax_base* state) >{ > typedef typename traits::char_class_type m_type; > if(state->type == syntax_element_rep) > { > > if(state->next.p->next.p->next.p == static_cast<re_alt*>(state)->alt.p) > { > switch(state->next.p->type) > { > case re_detail::syntax_element_wild: > return re_detail::syntax_element_dot_rep; > case re_detail::syntax_element_literal: > return re_detail::syntax_element_char_rep; > case re_detail::syntax_element_set: > return re_detail::syntax_element_short_set_rep; > case re_detail::syntax_element_long_set: > if(static_cast<re_detail::re_set_long<m_type>*>(state->next.p)->singleton) > return re_detail::syntax_element_long_set_rep; > break; > default: > break; > } > } > } > return state->type; >} > >template <class charT, class traits> >void basic_regex_creator<charT, traits>::probe_leading_repeat(re_syntax_base* state) >{ > > > do > { > switch(state->type) > { > case syntax_element_startmark: > if(static_cast<re_brace*>(state)->index >= 0) > { > state = state->next.p; > continue; > } > if((static_cast<re_brace*>(state)->index == -1) > || (static_cast<re_brace*>(state)->index == -2)) > { > > state = static_cast<const re_jump*>(state->next.p)->alt.p->next.p; > continue; > } > if(static_cast<re_brace*>(state)->index == -3) > { > > state = state->next.p->next.p; > continue; > } > return; > case syntax_element_endmark: > case syntax_element_start_line: > case syntax_element_end_line: > case syntax_element_word_boundary: > case syntax_element_within_word: > case syntax_element_word_start: > case syntax_element_word_end: > case syntax_element_buffer_start: > case syntax_element_buffer_end: > case syntax_element_restart_continue: > state = state->next.p; > break; > case syntax_element_dot_rep: > case syntax_element_char_rep: > case syntax_element_short_set_rep: > case syntax_element_long_set_rep: > if(this->m_has_backrefs == 0) > static_cast<re_repeat*>(state)->leading = true; > ((void)0); > default: > return; > } > }while(state); >} > > >} > >} ># 71 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/basic_regex_parser.hpp" 1 3 4 ># 33 "/usr/include/boost/regex/v4/basic_regex_parser.hpp" 3 4 >namespace boost{ >namespace re_detail{ > > > > > > >template <class charT, class traits> >class basic_regex_parser : public basic_regex_creator<charT, traits> >{ >public: > basic_regex_parser(regex_data<charT, traits>* data); > void parse(const charT* p1, const charT* p2, unsigned flags); > void fail(regex_constants::error_type error_code, std::ptrdiff_t position); > void fail(regex_constants::error_type error_code, std::ptrdiff_t position, std::string message, std::ptrdiff_t start_pos); > void fail(regex_constants::error_type error_code, std::ptrdiff_t position, const std::string& message) > { > fail(error_code, position, message, position); > } > > bool parse_all(); > bool parse_basic(); > bool parse_extended(); > bool parse_literal(); > bool parse_open_paren(); > bool parse_basic_escape(); > bool parse_extended_escape(); > bool parse_match_any(); > bool parse_repeat(std::size_t low = 0, std::size_t high = (std::numeric_limits<std::size_t>::max)()); > bool parse_repeat_range(bool isbasic); > bool parse_alt(); > bool parse_set(); > bool parse_backref(); > void parse_set_literal(basic_char_set<charT, traits>& char_set); > bool parse_inner_set(basic_char_set<charT, traits>& char_set); > bool parse_QE(); > bool parse_perl_extension(); > bool add_emacs_code(bool negate); > bool unwind_alts(std::ptrdiff_t last_paren_start); > digraph<charT> get_next_set_literal(basic_char_set<charT, traits>& char_set); > charT unescape_character(); > regex_constants::syntax_option_type parse_options(); > >private: > typedef bool (basic_regex_parser::*parser_proc_type)(); > typedef typename traits::string_type string_type; > typedef typename traits::char_class_type char_class_type; > parser_proc_type m_parser_proc; > const charT* m_base; > const charT* m_end; > const charT* m_position; > unsigned m_mark_count; > int m_mark_reset; > unsigned m_max_mark; > std::ptrdiff_t m_paren_start; > std::ptrdiff_t m_alt_insert_point; > bool m_has_case_change; > > > > > > > std::vector<std::ptrdiff_t> m_alt_jumps; > > > basic_regex_parser& operator=(const basic_regex_parser&); > basic_regex_parser(const basic_regex_parser&); >}; > >template <class charT, class traits> >basic_regex_parser<charT, traits>::basic_regex_parser(regex_data<charT, traits>* data) > : basic_regex_creator<charT, traits>(data), m_mark_count(0), m_mark_reset(-1), m_max_mark(0), m_paren_start(0), m_alt_insert_point(0), m_has_case_change(false) >{ >} > >template <class charT, class traits> >void basic_regex_parser<charT, traits>::parse(const charT* p1, const charT* p2, unsigned l_flags) >{ > > this->init(l_flags); > > m_position = m_base = p1; > m_end = p2; > > if((p1 == p2) && > ( > ((l_flags & regbase::main_option_type) != regbase::perl_syntax_group) > || (l_flags & regbase::no_empty_expressions) > ) > ) > { > fail(regex_constants::error_empty, 0); > return; > } > > switch(l_flags & regbase::main_option_type) > { > case regbase::perl_syntax_group: > { > m_parser_proc = &basic_regex_parser<charT, traits>::parse_extended; > > > > re_brace* br = static_cast<re_brace*>(this->append_state(syntax_element_startmark, sizeof(re_brace))); > br->index = 0; > br->icase = this->flags() & regbase::icase; > break; > } > case regbase::basic_syntax_group: > m_parser_proc = &basic_regex_parser<charT, traits>::parse_basic; > break; > case regbase::literal: > m_parser_proc = &basic_regex_parser<charT, traits>::parse_literal; > break; > default: > > > fail(regex_constants::error_unknown, 0, "An invalid combination of regular expression syntax flags was used."); > return; > } > > > bool result = parse_all(); > > > > unwind_alts(-1); > > this->flags(l_flags); > > > if(!result) > { > fail(regex_constants::error_paren, ::boost::re_detail::distance(m_base, m_position), "Found a closing ) with no corresponding openening parenthesis."); > return; > } > > if(this->m_pdata->m_status) > return; > > this->m_pdata->m_mark_count = 1 + m_mark_count; > this->finalize(p1, p2); >} > >template <class charT, class traits> >void basic_regex_parser<charT, traits>::fail(regex_constants::error_type error_code, std::ptrdiff_t position) >{ > > std::string message = this->m_pdata->m_ptraits->error_string(error_code); > fail(error_code, position, message); >} > >template <class charT, class traits> >void basic_regex_parser<charT, traits>::fail(regex_constants::error_type error_code, std::ptrdiff_t position, std::string message, std::ptrdiff_t start_pos) >{ > if(0 == this->m_pdata->m_status) > this->m_pdata->m_status = error_code; > m_position = m_end; > > > > > > if(start_pos == position) > start_pos = (std::max)(static_cast<std::ptrdiff_t>(0), position - static_cast<std::ptrdiff_t>(10)); > std::ptrdiff_t end_pos = (std::min)(position + static_cast<std::ptrdiff_t>(10), static_cast<std::ptrdiff_t>(m_end - m_base)); > if(error_code != regex_constants::error_empty) > { > if((start_pos != 0) || (end_pos != (m_end - m_base))) > message += " The error occurred while parsing the regular expression fragment: '"; > else > message += " The error occurred while parsing the regular expression: '"; > if(start_pos != end_pos) > { > message += std::string(m_base + start_pos, m_base + position); > message += ">>>HERE>>>"; > message += std::string(m_base + position, m_base + end_pos); > } > message += "'."; > } > > > > if(0 == (this->flags() & regex_constants::no_except)) > { > boost::regex_error e(message, error_code, position); > e.raise(); > } > > > >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_all() >{ > bool result = true; > while(result && (m_position != m_end)) > { > result = (this->*m_parser_proc)(); > } > return result; >} > > > > > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_basic() >{ > switch(this->m_traits.syntax_type(*m_position)) > { > case regex_constants::syntax_escape: > return parse_basic_escape(); > case regex_constants::syntax_dot: > return parse_match_any(); > case regex_constants::syntax_caret: > ++m_position; > this->append_state(syntax_element_start_line); > break; > case regex_constants::syntax_dollar: > ++m_position; > this->append_state(syntax_element_end_line); > break; > case regex_constants::syntax_star: > if(!(this->m_last_state) || (this->m_last_state->type == syntax_element_start_line)) > return parse_literal(); > else > { > ++m_position; > return parse_repeat(); > } > case regex_constants::syntax_plus: > if(!(this->m_last_state) || (this->m_last_state->type == syntax_element_start_line) || !(this->flags() & regbase::emacs_ex)) > return parse_literal(); > else > { > ++m_position; > return parse_repeat(1); > } > case regex_constants::syntax_question: > if(!(this->m_last_state) || (this->m_last_state->type == syntax_element_start_line) || !(this->flags() & regbase::emacs_ex)) > return parse_literal(); > else > { > ++m_position; > return parse_repeat(0, 1); > } > case regex_constants::syntax_open_set: > return parse_set(); > case regex_constants::syntax_newline: > if(this->flags() & regbase::newline_alt) > return parse_alt(); > else > return parse_literal(); > default: > return parse_literal(); > } > return true; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_extended() >{ > bool result = true; > switch(this->m_traits.syntax_type(*m_position)) > { > case regex_constants::syntax_open_mark: > return parse_open_paren(); > case regex_constants::syntax_close_mark: > return false; > case regex_constants::syntax_escape: > return parse_extended_escape(); > case regex_constants::syntax_dot: > return parse_match_any(); > case regex_constants::syntax_caret: > ++m_position; > this->append_state( > (this->flags() & regex_constants::no_mod_m ? syntax_element_buffer_start : syntax_element_start_line)); > break; > case regex_constants::syntax_dollar: > ++m_position; > this->append_state( > (this->flags() & regex_constants::no_mod_m ? syntax_element_buffer_end : syntax_element_end_line)); > break; > case regex_constants::syntax_star: > if(m_position == this->m_base) > { > fail(regex_constants::error_badrepeat, 0, "The repeat operator \"*\" cannot start a regular expression."); > return false; > } > ++m_position; > return parse_repeat(); > case regex_constants::syntax_question: > if(m_position == this->m_base) > { > fail(regex_constants::error_badrepeat, 0, "The repeat operator \"?\" cannot start a regular expression."); > return false; > } > ++m_position; > return parse_repeat(0,1); > case regex_constants::syntax_plus: > if(m_position == this->m_base) > { > fail(regex_constants::error_badrepeat, 0, "The repeat operator \"+\" cannot start a regular expression."); > return false; > } > ++m_position; > return parse_repeat(1); > case regex_constants::syntax_open_brace: > ++m_position; > return parse_repeat_range(false); > case regex_constants::syntax_close_brace: > fail(regex_constants::error_brace, this->m_position - this->m_base, "Found a closing repetition operator } with no corresponding {."); > return false; > case regex_constants::syntax_or: > return parse_alt(); > case regex_constants::syntax_open_set: > return parse_set(); > case regex_constants::syntax_newline: > if(this->flags() & regbase::newline_alt) > return parse_alt(); > else > return parse_literal(); > case regex_constants::syntax_hash: > > > > > if((this->flags() > & (regbase::no_perl_ex|regbase::mod_x)) > == regbase::mod_x) > { > while((m_position != m_end) && !is_separator(*m_position++)){} > return true; > } > ((void)0); > default: > result = parse_literal(); > break; > } > return result; >} > > > > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_literal() >{ > > > if( > ((this->flags() > & (regbase::main_option_type|regbase::mod_x|regbase::no_perl_ex)) > != regbase::mod_x) > || !this->m_traits.isctype(*m_position, this->m_mask_space)) > this->append_literal(*m_position); > ++m_position; > return true; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_open_paren() >{ > > > > if(++m_position == m_end) > { > fail(regex_constants::error_paren, m_position - m_base); > return false; > } > > > > if( > ((this->flags() & (regbase::main_option_type | regbase::no_perl_ex)) == 0) > || ((this->flags() & (regbase::main_option_type | regbase::emacs_ex)) == (regbase::basic_syntax_group|regbase::emacs_ex)) > ) > { > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_question) > return parse_perl_extension(); > } > > > > unsigned markid = 0; > if(0 == (this->flags() & regbase::nosubs)) > { > markid = ++m_mark_count; > > if(this->flags() & regbase::save_subexpression_location) > this->m_pdata->m_subs.push_back(std::pair<std::size_t, std::size_t>(std::distance(m_base, m_position) - 1, 0)); > > > > > } > re_brace* pb = static_cast<re_brace*>(this->append_state(syntax_element_startmark, sizeof(re_brace))); > pb->index = markid; > pb->icase = this->flags() & regbase::icase; > std::ptrdiff_t last_paren_start = this->getoffset(pb); > > std::ptrdiff_t last_alt_point = m_alt_insert_point; > this->m_pdata->m_data.align(); > m_alt_insert_point = this->m_pdata->m_data.size(); > > > > regex_constants::syntax_option_type opts = this->flags(); > bool old_case_change = m_has_case_change; > m_has_case_change = false; > > > > int mark_reset = m_mark_reset; > m_mark_reset = -1; > > > > > parse_all(); > > > > if(0 == unwind_alts(last_paren_start)) > return false; > > > > if(m_has_case_change) > { > > > > static_cast<re_case*>( > this->append_state(syntax_element_toggle_case, sizeof(re_case)) > )->icase = opts & regbase::icase; > } > this->flags(opts); > m_has_case_change = old_case_change; > > > > m_mark_reset = mark_reset; > > > > if(m_position == m_end) > { > this->fail(regex_constants::error_paren, ::boost::re_detail::distance(m_base, m_end)); > return false; > } > (static_cast<void> (0)); > > if(markid && (this->flags() & regbase::save_subexpression_location)) > this->m_pdata->m_subs.at(markid - 1).second = std::distance(m_base, m_position); > > > > > ++m_position; > > > > pb = static_cast<re_brace*>(this->append_state(syntax_element_endmark, sizeof(re_brace))); > pb->index = markid; > pb->icase = this->flags() & regbase::icase; > this->m_paren_start = last_paren_start; > > > > this->m_alt_insert_point = last_alt_point; > > > > if((markid > 0) && (markid < sizeof(unsigned) * 8)) > this->m_backrefs |= 1u << (markid - 1); > > return true; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_basic_escape() >{ > ++m_position; > bool result = true; > switch(this->m_traits.escape_syntax_type(*m_position)) > { > case regex_constants::syntax_open_mark: > return parse_open_paren(); > case regex_constants::syntax_close_mark: > return false; > case regex_constants::syntax_plus: > if(this->flags() & regex_constants::bk_plus_qm) > { > ++m_position; > return parse_repeat(1); > } > else > return parse_literal(); > case regex_constants::syntax_question: > if(this->flags() & regex_constants::bk_plus_qm) > { > ++m_position; > return parse_repeat(0, 1); > } > else > return parse_literal(); > case regex_constants::syntax_open_brace: > if(this->flags() & regbase::no_intervals) > return parse_literal(); > ++m_position; > return parse_repeat_range(true); > case regex_constants::syntax_close_brace: > if(this->flags() & regbase::no_intervals) > return parse_literal(); > fail(regex_constants::error_brace, this->m_position - this->m_base, "Found a closing repetition operator } with no corresponding {."); > return false; > case regex_constants::syntax_or: > if(this->flags() & regbase::bk_vbar) > return parse_alt(); > else > result = parse_literal(); > break; > case regex_constants::syntax_digit: > return parse_backref(); > case regex_constants::escape_type_start_buffer: > if(this->flags() & regbase::emacs_ex) > { > ++m_position; > this->append_state(syntax_element_buffer_start); > } > else > result = parse_literal(); > break; > case regex_constants::escape_type_end_buffer: > if(this->flags() & regbase::emacs_ex) > { > ++m_position; > this->append_state(syntax_element_buffer_end); > } > else > result = parse_literal(); > break; > case regex_constants::escape_type_word_assert: > if(this->flags() & regbase::emacs_ex) > { > ++m_position; > this->append_state(syntax_element_word_boundary); > } > else > result = parse_literal(); > break; > case regex_constants::escape_type_not_word_assert: > if(this->flags() & regbase::emacs_ex) > { > ++m_position; > this->append_state(syntax_element_within_word); > } > else > result = parse_literal(); > break; > case regex_constants::escape_type_left_word: > if(this->flags() & regbase::emacs_ex) > { > ++m_position; > this->append_state(syntax_element_word_start); > } > else > result = parse_literal(); > break; > case regex_constants::escape_type_right_word: > if(this->flags() & regbase::emacs_ex) > { > ++m_position; > this->append_state(syntax_element_word_end); > } > else > result = parse_literal(); > break; > default: > if(this->flags() & regbase::emacs_ex) > { > bool negate = true; > switch(*m_position) > { > case 'w': > negate = false; > ((void)0); > case 'W': > { > basic_char_set<charT, traits> char_set; > if(negate) > char_set.negate(); > char_set.add_class(this->m_word_mask); > if(0 == this->append_set(char_set)) > { > fail(regex_constants::error_ctype, m_position - m_base); > return false; > } > ++m_position; > return true; > } > case 's': > negate = false; > ((void)0); > case 'S': > return add_emacs_code(negate); > case 'c': > case 'C': > > fail(regex_constants::error_escape, m_position - m_base, "The \\c and \\C escape sequences are not supported by POSIX basic regular expressions: try the Perl syntax instead."); > return false; > default: > break; > } > } > result = parse_literal(); > break; > } > return result; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_extended_escape() >{ > ++m_position; > if(m_position == m_end) > { > fail(regex_constants::error_escape, m_position - m_base, "Incomplete escape sequence found."); > return false; > } > bool negate = false; > switch(this->m_traits.escape_syntax_type(*m_position)) > { > case regex_constants::escape_type_not_class: > negate = true; > ((void)0); > case regex_constants::escape_type_class: > { >escape_type_class_jump: > typedef typename traits::char_class_type m_type; > m_type m = this->m_traits.lookup_classname(m_position, m_position+1); > if(m != 0) > { > basic_char_set<charT, traits> char_set; > if(negate) > char_set.negate(); > char_set.add_class(m); > if(0 == this->append_set(char_set)) > { > fail(regex_constants::error_ctype, m_position - m_base); > return false; > } > ++m_position; > return true; > } > > > > this->append_literal(unescape_character()); > break; > } > case regex_constants::syntax_digit: > return parse_backref(); > case regex_constants::escape_type_left_word: > ++m_position; > this->append_state(syntax_element_word_start); > break; > case regex_constants::escape_type_right_word: > ++m_position; > this->append_state(syntax_element_word_end); > break; > case regex_constants::escape_type_start_buffer: > ++m_position; > this->append_state(syntax_element_buffer_start); > break; > case regex_constants::escape_type_end_buffer: > ++m_position; > this->append_state(syntax_element_buffer_end); > break; > case regex_constants::escape_type_word_assert: > ++m_position; > this->append_state(syntax_element_word_boundary); > break; > case regex_constants::escape_type_not_word_assert: > ++m_position; > this->append_state(syntax_element_within_word); > break; > case regex_constants::escape_type_Z: > ++m_position; > this->append_state(syntax_element_soft_buffer_end); > break; > case regex_constants::escape_type_Q: > return parse_QE(); > case regex_constants::escape_type_C: > return parse_match_any(); > case regex_constants::escape_type_X: > ++m_position; > this->append_state(syntax_element_combining); > break; > case regex_constants::escape_type_G: > ++m_position; > this->append_state(syntax_element_restart_continue); > break; > case regex_constants::escape_type_not_property: > negate = true; > ((void)0); > case regex_constants::escape_type_property: > { > ++m_position; > char_class_type m; > if(m_position == m_end) > { > fail(regex_constants::error_escape, m_position - m_base, "Incomplete property escape found."); > return false; > } > > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_open_brace) > { > const charT* base = m_position; > > while((m_position != m_end) && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_brace)) > ++m_position; > if(m_position == m_end) > { > fail(regex_constants::error_escape, m_position - m_base, "Closing } missing from property escape sequence."); > return false; > } > m = this->m_traits.lookup_classname(++base, m_position++); > } > else > { > m = this->m_traits.lookup_classname(m_position, m_position+1); > ++m_position; > } > if(m != 0) > { > basic_char_set<charT, traits> char_set; > if(negate) > char_set.negate(); > char_set.add_class(m); > if(0 == this->append_set(char_set)) > { > fail(regex_constants::error_ctype, m_position - m_base); > return false; > } > return true; > } > fail(regex_constants::error_ctype, m_position - m_base, "Escape sequence was neither a valid property nor a valid character class name."); > return false; > } > case regex_constants::escape_type_reset_start_mark: > if(0 == (this->flags() & (regbase::main_option_type | regbase::no_perl_ex))) > { > re_brace* pb = static_cast<re_brace*>(this->append_state(syntax_element_startmark, sizeof(re_brace))); > pb->index = -5; > pb->icase = this->flags() & regbase::icase; > this->m_pdata->m_data.align(); > ++m_position; > return true; > } > goto escape_type_class_jump; > case regex_constants::escape_type_line_ending: > if(0 == (this->flags() & (regbase::main_option_type | regbase::no_perl_ex))) > { > const charT* e = get_escape_R_string<charT>(); > const charT* old_position = m_position; > const charT* old_end = m_end; > const charT* old_base = m_base; > m_position = e; > m_base = e; > m_end = e + traits::length(e); > bool r = parse_all(); > m_position = ++old_position; > m_end = old_end; > m_base = old_base; > return r; > } > goto escape_type_class_jump; > case regex_constants::escape_type_extended_backref: > if(0 == (this->flags() & (regbase::main_option_type | regbase::no_perl_ex))) > { > bool have_brace = false; > bool negative = false; > static const char* incomplete_message = "Incomplete \\g escape found."; > if(++m_position == m_end) > { > fail(regex_constants::error_escape, m_position - m_base, incomplete_message); > return false; > } > > regex_constants::syntax_type syn = this->m_traits.syntax_type(*m_position); > regex_constants::syntax_type syn_end = 0; > if((syn == regex_constants::syntax_open_brace) > || (syn == regex_constants::escape_type_left_word) > || (syn == regex_constants::escape_type_end_buffer)) > { > if(++m_position == m_end) > { > fail(regex_constants::error_escape, m_position - m_base, incomplete_message); > return false; > } > have_brace = true; > switch(syn) > { > case regex_constants::syntax_open_brace: > syn_end = regex_constants::syntax_close_brace; > break; > case regex_constants::escape_type_left_word: > syn_end = regex_constants::escape_type_right_word; > break; > default: > syn_end = regex_constants::escape_type_end_buffer; > break; > } > } > negative = (*m_position == static_cast<charT>('-')); > if((negative) && (++m_position == m_end)) > { > fail(regex_constants::error_escape, m_position - m_base, incomplete_message); > return false; > } > const charT* pc = m_position; > int i = this->m_traits.toi(pc, m_end, 10); > if((i < 0) && syn_end) > { > > const charT* base = m_position; > while((m_position != m_end) && (this->m_traits.syntax_type(*m_position) != syn_end)) > { > ++m_position; > } > i = hash_value_from_capture_name(base, m_position); > pc = m_position; > } > if(negative) > i = 1 + m_mark_count - i; > if(((i > 0) && (this->m_backrefs & (1u << (i-1)))) || ((i > 10000) && (this->m_pdata->get_id(i) > 0) && (this->m_backrefs & (1u << (this->m_pdata->get_id(i)-1))))) > { > m_position = pc; > re_brace* pb = static_cast<re_brace*>(this->append_state(syntax_element_backref, sizeof(re_brace))); > pb->index = i; > pb->icase = this->flags() & regbase::icase; > } > else > { > fail(regex_constants::error_backref, m_position - m_base); > return false; > } > m_position = pc; > if(have_brace) > { > if((m_position == m_end) || (this->m_traits.syntax_type(*m_position) != syn_end)) > { > fail(regex_constants::error_escape, m_position - m_base, incomplete_message); > return false; > } > ++m_position; > } > return true; > } > goto escape_type_class_jump; > case regex_constants::escape_type_control_v: > if(0 == (this->flags() & (regbase::main_option_type | regbase::no_perl_ex))) > goto escape_type_class_jump; > ((void)0); > default: > this->append_literal(unescape_character()); > break; > } > return true; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_match_any() >{ > > > > ++m_position; > static_cast<re_dot*>( > this->append_state(syntax_element_wild, sizeof(re_dot)) > )->mask = static_cast<unsigned char>(this->flags() & regbase::no_mod_s > ? re_detail::force_not_newline > : this->flags() & regbase::mod_s ? > re_detail::force_newline : re_detail::dont_care); > return true; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_repeat(std::size_t low, std::size_t high) >{ > bool greedy = true; > bool pocessive = false; > std::size_t insert_point; > > > > if((m_position != m_end) > && ( > (0 == (this->flags() & (regbase::main_option_type | regbase::no_perl_ex))) > || ((regbase::basic_syntax_group|regbase::emacs_ex) == (this->flags() & (regbase::main_option_type | regbase::emacs_ex))) > ) > ) > { > > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_question) > { > greedy = false; > ++m_position; > } > > if((m_position != m_end) > && (0 == (this->flags() & regbase::main_option_type)) > && (this->m_traits.syntax_type(*m_position) == regex_constants::syntax_plus)) > { > pocessive = true; > ++m_position; > } > } > if(0 == this->m_last_state) > { > fail(regex_constants::error_badrepeat, ::boost::re_detail::distance(m_base, m_position), "Nothing to repeat."); > return false; > } > if(this->m_last_state->type == syntax_element_endmark) > { > > insert_point = this->m_paren_start; > } > else if((this->m_last_state->type == syntax_element_literal) && (static_cast<re_literal*>(this->m_last_state)->length > 1)) > { > > re_literal* lit = static_cast<re_literal*>(this->m_last_state); > charT c = (static_cast<charT*>(static_cast<void*>(lit+1)))[lit->length - 1]; > --(lit->length); > > lit = static_cast<re_literal*>(this->append_state(syntax_element_literal, sizeof(re_literal) + sizeof(charT))); > lit->length = 1; > (static_cast<charT*>(static_cast<void*>(lit+1)))[0] = c; > insert_point = this->getoffset(this->m_last_state); > } > else > { > > switch(this->m_last_state->type) > { > case syntax_element_start_line: > case syntax_element_end_line: > case syntax_element_word_boundary: > case syntax_element_within_word: > case syntax_element_word_start: > case syntax_element_word_end: > case syntax_element_buffer_start: > case syntax_element_buffer_end: > case syntax_element_alt: > case syntax_element_soft_buffer_end: > case syntax_element_restart_continue: > case syntax_element_jump: > case syntax_element_startmark: > case syntax_element_backstep: > > fail(regex_constants::error_badrepeat, m_position - m_base); > return false; > default: > > break; > } > insert_point = this->getoffset(this->m_last_state); > } > > > > re_repeat* rep = static_cast<re_repeat*>(this->insert_state(insert_point, syntax_element_rep, re_repeater_size)); > rep->min = low; > rep->max = high; > rep->greedy = greedy; > rep->leading = false; > > std::ptrdiff_t rep_off = this->getoffset(rep); > > re_jump* jmp = static_cast<re_jump*>(this->append_state(syntax_element_jump, sizeof(re_jump))); > jmp->alt.i = rep_off - this->getoffset(jmp); > this->m_pdata->m_data.align(); > > rep = static_cast<re_repeat*>(this->getaddress(rep_off)); > rep->alt.i = this->m_pdata->m_data.size() - rep_off; > > > > > if(pocessive) > { > if(m_position != m_end) > { > > > > > switch(this->m_traits.syntax_type(*m_position)) > { > case regex_constants::syntax_star: > case regex_constants::syntax_plus: > case regex_constants::syntax_question: > case regex_constants::syntax_open_brace: > fail(regex_constants::error_badrepeat, m_position - m_base); > return false; > } > } > re_brace* pb = static_cast<re_brace*>(this->insert_state(insert_point, syntax_element_startmark, sizeof(re_brace))); > pb->index = -3; > pb->icase = this->flags() & regbase::icase; > jmp = static_cast<re_jump*>(this->insert_state(insert_point + sizeof(re_brace), syntax_element_jump, sizeof(re_jump))); > this->m_pdata->m_data.align(); > jmp->alt.i = this->m_pdata->m_data.size() - this->getoffset(jmp); > pb = static_cast<re_brace*>(this->append_state(syntax_element_endmark, sizeof(re_brace))); > pb->index = -3; > pb->icase = this->flags() & regbase::icase; > } > return true; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_repeat_range(bool isbasic) >{ > static const char* incomplete_message = "Missing } in quantified repetition."; > > > > std::size_t min, max; > int v; > > while((m_position != m_end) && this->m_traits.isctype(*m_position, this->m_mask_space)) > ++m_position; > if(this->m_position == this->m_end) > { > if(this->flags() & (regbase::main_option_type | regbase::no_perl_ex)) > { > fail(regex_constants::error_brace, this->m_position - this->m_base, incomplete_message); > return false; > } > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_brace) --m_position; > return parse_literal(); > } > > v = this->m_traits.toi(m_position, m_end, 10); > > if(v < 0) > { > if(this->flags() & (regbase::main_option_type | regbase::no_perl_ex)) > { > fail(regex_constants::error_brace, this->m_position - this->m_base, incomplete_message); > return false; > } > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_brace) --m_position; > return parse_literal(); > } > while((m_position != m_end) && this->m_traits.isctype(*m_position, this->m_mask_space)) > ++m_position; > if(this->m_position == this->m_end) > { > if(this->flags() & (regbase::main_option_type | regbase::no_perl_ex)) > { > fail(regex_constants::error_brace, this->m_position - this->m_base, incomplete_message); > return false; > } > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_brace) --m_position; > return parse_literal(); > } > min = v; > > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_comma) > { > > ++m_position; > > while((m_position != m_end) && this->m_traits.isctype(*m_position, this->m_mask_space)) > ++m_position; > if(this->m_position == this->m_end) > { > if(this->flags() & (regbase::main_option_type | regbase::no_perl_ex)) > { > fail(regex_constants::error_brace, this->m_position - this->m_base, incomplete_message); > return false; > } > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_brace) --m_position; > return parse_literal(); > } > > v = this->m_traits.toi(m_position, m_end, 10); > max = (v >= 0) ? (std::size_t)v : (std::numeric_limits<std::size_t>::max)(); > } > else > { > > max = min; > } > > while((m_position != m_end) && this->m_traits.isctype(*m_position, this->m_mask_space)) > ++m_position; > > if(this->m_position == this->m_end) > { > if(this->flags() & (regbase::main_option_type | regbase::no_perl_ex)) > { > fail(regex_constants::error_brace, this->m_position - this->m_base, incomplete_message); > return false; > } > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_brace) --m_position; > return parse_literal(); > } > if(isbasic) > { > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_escape) > { > ++m_position; > if(this->m_position == this->m_end) > { > fail(regex_constants::error_brace, this->m_position - this->m_base, incomplete_message); > return false; > } > } > else > { > fail(regex_constants::error_brace, this->m_position - this->m_base, incomplete_message); > return false; > } > } > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_close_brace) > ++m_position; > else > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_brace) --m_position; > return parse_literal(); > } > > > > if(min > max) > { > > m_position -= 2; > while(this->m_traits.isctype(*m_position, this->m_word_mask)) --m_position; > ++m_position; > fail(regex_constants::error_badbrace, m_position - m_base); > return false; > } > return parse_repeat(min, max); >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_alt() >{ > > > > > if( > ((this->m_last_state == 0) || (this->m_last_state->type == syntax_element_startmark)) > && > !( > ((this->flags() & regbase::main_option_type) == regbase::perl_syntax_group) > && > ((this->flags() & regbase::no_empty_expressions) == 0) > ) > ) > { > fail(regex_constants::error_empty, this->m_position - this->m_base, "A regular expression can start with the alternation operator |."); > return false; > } > > > > if(m_max_mark < m_mark_count) > m_max_mark = m_mark_count; > if(m_mark_reset >= 0) > m_mark_count = m_mark_reset; > > ++m_position; > > > > re_syntax_base* pj = this->append_state(re_detail::syntax_element_jump, sizeof(re_jump)); > std::ptrdiff_t jump_offset = this->getoffset(pj); > > > > re_alt* palt = static_cast<re_alt*>(this->insert_state(this->m_alt_insert_point, syntax_element_alt, re_alt_size)); > jump_offset += re_alt_size; > this->m_pdata->m_data.align(); > palt->alt.i = this->m_pdata->m_data.size() - this->getoffset(palt); > > > > > this->m_alt_insert_point = this->m_pdata->m_data.size(); > > > > > if(m_has_case_change) > { > static_cast<re_case*>( > this->append_state(syntax_element_toggle_case, sizeof(re_case)) > )->icase = this->m_icase; > } > > > > > > > m_alt_jumps.push_back(jump_offset); > return true; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_set() >{ > static const char* incomplete_message = "Character set declaration starting with [ terminated prematurely - either no ] was found or the set had no content."; > ++m_position; > if(m_position == m_end) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > basic_char_set<charT, traits> char_set; > > const charT* base = m_position; > const charT* item_base = m_position; > > while(m_position != m_end) > { > switch(this->m_traits.syntax_type(*m_position)) > { > case regex_constants::syntax_caret: > if(m_position == base) > { > char_set.negate(); > ++m_position; > item_base = m_position; > } > else > parse_set_literal(char_set); > break; > case regex_constants::syntax_close_set: > if(m_position == item_base) > { > parse_set_literal(char_set); > break; > } > else > { > ++m_position; > if(0 == this->append_set(char_set)) > { > fail(regex_constants::error_ctype, m_position - m_base); > return false; > } > } > return true; > case regex_constants::syntax_open_set: > if(parse_inner_set(char_set)) > break; > return true; > case regex_constants::syntax_escape: > { > > > > > ++m_position; > if(this->m_traits.escape_syntax_type(*m_position) > == regex_constants::escape_type_class) > { > char_class_type m = this->m_traits.lookup_classname(m_position, m_position+1); > if(m != 0) > { > char_set.add_class(m); > ++m_position; > break; > } > } > else if(this->m_traits.escape_syntax_type(*m_position) > == regex_constants::escape_type_not_class) > { > > char_class_type m = this->m_traits.lookup_classname(m_position, m_position+1); > if(m != 0) > { > char_set.add_negated_class(m); > ++m_position; > break; > } > } > > --m_position; > parse_set_literal(char_set); > break; > } > default: > parse_set_literal(char_set); > break; > } > } > return m_position != m_end; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_inner_set(basic_char_set<charT, traits>& char_set) >{ > static const char* incomplete_message = "Character class declaration starting with [ terminated prematurely - either no ] was found or the set had no content."; > > > > > > if(m_end == ++m_position) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > switch(this->m_traits.syntax_type(*m_position)) > { > case regex_constants::syntax_dot: > > > > --m_position; > parse_set_literal(char_set); > return true; > case regex_constants::syntax_colon: > { > > if((this->flags() & (regbase::main_option_type | regbase::no_char_classes)) > == (regbase::basic_syntax_group | regbase::no_char_classes)) > { > --m_position; > parse_set_literal(char_set); > return true; > } > > if(m_end == ++m_position) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > const charT* name_first = m_position; > > if(m_end == ++m_position) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > while((m_position != m_end) > && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_colon)) > ++m_position; > const charT* name_last = m_position; > if(m_end == m_position) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > if((m_end == ++m_position) > || (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_set)) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > > > > bool negated = false; > if(this->m_traits.syntax_type(*name_first) == regex_constants::syntax_caret) > { > ++name_first; > negated = true; > } > typedef typename traits::char_class_type m_type; > m_type m = this->m_traits.lookup_classname(name_first, name_last); > if(m == 0) > { > if(char_set.empty() && (name_last - name_first == 1)) > { > > ++m_position; > if( (m_position != m_end) > && (this->m_traits.syntax_type(*m_position) > == regex_constants::syntax_close_set)) > { > if(this->m_traits.escape_syntax_type(*name_first) > == regex_constants::escape_type_left_word) > { > ++m_position; > this->append_state(syntax_element_word_start); > return false; > } > if(this->m_traits.escape_syntax_type(*name_first) > == regex_constants::escape_type_right_word) > { > ++m_position; > this->append_state(syntax_element_word_end); > return false; > } > } > } > fail(regex_constants::error_ctype, name_first - m_base); > return false; > } > if(negated == false) > char_set.add_class(m); > else > char_set.add_negated_class(m); > ++m_position; > break; > } > case regex_constants::syntax_equal: > { > > if(m_end == ++m_position) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > const charT* name_first = m_position; > > if(m_end == ++m_position) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > while((m_position != m_end) > && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_equal)) > ++m_position; > const charT* name_last = m_position; > if(m_end == m_position) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > if((m_end == ++m_position) > || (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_set)) > { > fail(regex_constants::error_brack, m_position - m_base, incomplete_message); > return false; > } > string_type m = this->m_traits.lookup_collatename(name_first, name_last); > if((0 == m.size()) || (m.size() > 2)) > { > fail(regex_constants::error_collate, name_first - m_base); > return false; > } > digraph<charT> d; > d.first = m[0]; > if(m.size() > 1) > d.second = m[1]; > else > d.second = 0; > char_set.add_equivalent(d); > ++m_position; > break; > } > default: > --m_position; > parse_set_literal(char_set); > break; > } > return true; >} > >template <class charT, class traits> >void basic_regex_parser<charT, traits>::parse_set_literal(basic_char_set<charT, traits>& char_set) >{ > digraph<charT> start_range(get_next_set_literal(char_set)); > if(m_end == m_position) > { > fail(regex_constants::error_brack, m_position - m_base); > return; > } > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_dash) > { > > if(m_end == ++m_position) > { > fail(regex_constants::error_brack, m_position - m_base); > return; > } > if(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_set) > { > digraph<charT> end_range = get_next_set_literal(char_set); > char_set.add_range(start_range, end_range); > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_dash) > { > if(m_end == ++m_position) > { > fail(regex_constants::error_brack, m_position - m_base); > return; > } > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_close_set) > { > > --m_position; > return; > } > fail(regex_constants::error_range, m_position - m_base); > return; > } > return; > } > --m_position; > } > char_set.add_single(start_range); >} > >template <class charT, class traits> >digraph<charT> basic_regex_parser<charT, traits>::get_next_set_literal(basic_char_set<charT, traits>& char_set) >{ > digraph<charT> result; > switch(this->m_traits.syntax_type(*m_position)) > { > case regex_constants::syntax_dash: > if(!char_set.empty()) > { > > if((++m_position == m_end) || (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_set)) > { > fail(regex_constants::error_range, m_position - m_base); > return result; > } > --m_position; > } > result.first = *m_position++; > return result; > case regex_constants::syntax_escape: > > if(this->flags() & regex_constants::no_escape_in_lists) > { > result = *m_position++; > break; > } > ++m_position; > result = unescape_character(); > break; > case regex_constants::syntax_open_set: > { > if(m_end == ++m_position) > { > fail(regex_constants::error_collate, m_position - m_base); > return result; > } > if(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_dot) > { > --m_position; > result.first = *m_position; > ++m_position; > return result; > } > if(m_end == ++m_position) > { > fail(regex_constants::error_collate, m_position - m_base); > return result; > } > const charT* name_first = m_position; > > if(m_end == ++m_position) > { > fail(regex_constants::error_collate, name_first - m_base); > return result; > } > while((m_position != m_end) > && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_dot)) > ++m_position; > const charT* name_last = m_position; > if(m_end == m_position) > { > fail(regex_constants::error_collate, name_first - m_base); > return result; > } > if((m_end == ++m_position) > || (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_set)) > { > fail(regex_constants::error_collate, name_first - m_base); > return result; > } > ++m_position; > string_type s = this->m_traits.lookup_collatename(name_first, name_last); > if(s.empty() || (s.size() > 2)) > { > fail(regex_constants::error_collate, name_first - m_base); > return result; > } > result.first = s[0]; > if(s.size() > 1) > result.second = s[1]; > else > result.second = 0; > return result; > } > default: > result = *m_position++; > } > return result; >} > > > > >template <class charT> >bool valid_value(charT, int v, const mpl::true_&) >{ > return (v >> (sizeof(charT) * 8)) == 0; >} >template <class charT> >bool valid_value(charT, int, const mpl::false_&) >{ > return true; >} >template <class charT> >bool valid_value(charT c, int v) >{ > return valid_value(c, v, mpl::bool_<(sizeof(charT) < sizeof(int))>()); >} > >template <class charT, class traits> >charT basic_regex_parser<charT, traits>::unescape_character() >{ > > > > > charT result(0); > if(m_position == m_end) > { > fail(regex_constants::error_escape, m_position - m_base, "Escape sequence terminated prematurely."); > return false; > } > switch(this->m_traits.escape_syntax_type(*m_position)) > { > case regex_constants::escape_type_control_a: > result = charT('\a'); > break; > case regex_constants::escape_type_e: > result = charT(27); > break; > case regex_constants::escape_type_control_f: > result = charT('\f'); > break; > case regex_constants::escape_type_control_n: > result = charT('\n'); > break; > case regex_constants::escape_type_control_r: > result = charT('\r'); > break; > case regex_constants::escape_type_control_t: > result = charT('\t'); > break; > case regex_constants::escape_type_control_v: > result = charT('\v'); > break; > case regex_constants::escape_type_word_assert: > result = charT('\b'); > break; > case regex_constants::escape_type_ascii_control: > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_escape, m_position - m_base, "ASCII escape sequence terminated prematurely."); > return result; > } > result = static_cast<charT>(*m_position % 32); > break; > case regex_constants::escape_type_hex: > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_escape, m_position - m_base, "Hexadecimal escape sequence terminated prematurely."); > return result; > } > > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_open_brace) > { > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_escape, m_position - m_base, "Missing } in hexadecimal escape sequence."); > return result; > } > int i = this->m_traits.toi(m_position, m_end, 16); > if((m_position == m_end) > || (i < 0) > || ((std::numeric_limits<charT>::is_specialized) && (i > (int)(std::numeric_limits<charT>::max)())) > || (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_brace)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_badbrace, m_position - m_base, "Hexadecimal escape sequence was invalid."); > return result; > } > ++m_position; > result = charT(i); > } > else > { > std::ptrdiff_t len = (std::min)(static_cast<std::ptrdiff_t>(2), static_cast<std::ptrdiff_t>(m_end - m_position)); > int i = this->m_traits.toi(m_position, m_position + len, 16); > if((i < 0) > || !valid_value(charT(0), i)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_escape, m_position - m_base, "Escape sequence did not encode a valid character."); > return result; > } > result = charT(i); > } > return result; > case regex_constants::syntax_digit: > { > > > std::ptrdiff_t len = (std::min)(::boost::re_detail::distance(m_position, m_end), static_cast<std::ptrdiff_t>(4)); > const charT* bp = m_position; > int val = this->m_traits.toi(bp, bp + 1, 8); > if(val != 0) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > > fail(regex_constants::error_escape, m_position - m_base, "Invalid octal escape sequence."); > return result; > } > val = this->m_traits.toi(m_position, m_position + len, 8); > if(val < 0) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_escape, m_position - m_base, "Octal escape sequence is invalid."); > return result; > } > return static_cast<charT>(val); > } > case regex_constants::escape_type_named_char: > { > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_escape, m_position - m_base); > return false; > } > > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_open_brace) > { > const charT* base = m_position; > > while((m_position != m_end) && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_brace)) > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_escape, m_position - m_base); > return false; > } > string_type s = this->m_traits.lookup_collatename(++base, m_position++); > if(s.empty()) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_collate, m_position - m_base); > return false; > } > if(s.size() == 1) > { > return s[0]; > } > } > > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_escape, m_position - m_base); > return false; > } > default: > result = *m_position; > break; > } > ++m_position; > return result; > > > >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_backref() >{ > (static_cast<void> (0)); > const charT* pc = m_position; > int i = this->m_traits.toi(pc, pc + 1, 10); > if((i == 0) || (((this->flags() & regbase::main_option_type) == regbase::perl_syntax_group) && (this->flags() & regbase::no_bk_refs))) > { > > charT c = unescape_character(); > this->append_literal(c); > } > else if((i > 0) && (this->m_backrefs & (1u << (i-1)))) > { > m_position = pc; > re_brace* pb = static_cast<re_brace*>(this->append_state(syntax_element_backref, sizeof(re_brace))); > pb->index = i; > pb->icase = this->flags() & regbase::icase; > } > else > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_backref, m_position - m_base); > return false; > } > return true; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_QE() >{ > > > > > > > > ++m_position; > const charT* start = m_position; > const charT* end; > do > { > while((m_position != m_end) > && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape)) > ++m_position; > if(m_position == m_end) > { > > end = m_position; > break; > } > if(++m_position == m_end) > { > fail(regex_constants::error_escape, m_position - m_base, "Unterminated \\Q...\\E sequence."); > return false; > } > > if(this->m_traits.escape_syntax_type(*m_position) == regex_constants::escape_type_E) > { > ++m_position; > end = m_position - 2; > break; > } > > }while(true); > > > > while(start != end) > { > this->append_literal(*start); > ++start; > } > return true; > > > >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::parse_perl_extension() >{ > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > > > > > > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_hash) > { > while((m_position != m_end) > && (this->m_traits.syntax_type(*m_position++) != regex_constants::syntax_close_mark)) > {} > return true; > } > > > > int markid = 0; > std::ptrdiff_t jump_offset = 0; > re_brace* pb = static_cast<re_brace*>(this->append_state(syntax_element_startmark, sizeof(re_brace))); > pb->icase = this->flags() & regbase::icase; > std::ptrdiff_t last_paren_start = this->getoffset(pb); > > std::ptrdiff_t last_alt_point = m_alt_insert_point; > this->m_pdata->m_data.align(); > m_alt_insert_point = this->m_pdata->m_data.size(); > std::ptrdiff_t expected_alt_point = m_alt_insert_point; > bool restore_flags = true; > regex_constants::syntax_option_type old_flags = this->flags(); > bool old_case_change = m_has_case_change; > m_has_case_change = false; > charT name_delim; > int mark_reset = m_mark_reset; > int max_mark = m_max_mark; > m_mark_reset = -1; > m_max_mark = m_mark_count; > int v; > > > > switch(this->m_traits.syntax_type(*m_position)) > { > case regex_constants::syntax_or: > m_mark_reset = m_mark_count; > ((void)0); > case regex_constants::syntax_colon: > > > > pb->index = markid = 0; > ++m_position; > break; > case regex_constants::syntax_digit: > { > > > > v = this->m_traits.toi(m_position, m_end, 10); > if((v < 0) || (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base, "The recursive sub-expression refers to an invalid marking group, or is unterminated."); > return false; > } >insert_recursion: > pb->index = markid = 0; > re_recurse* pr = static_cast<re_recurse*>(this->append_state(syntax_element_recurse, sizeof(re_recurse))); > pr->alt.i = v; > pr->state_id = 0; > static_cast<re_case*>( > this->append_state(syntax_element_toggle_case, sizeof(re_case)) > )->icase = this->flags() & regbase::icase; > break; > } > case regex_constants::syntax_plus: > > > > ++m_position; > v = this->m_traits.toi(m_position, m_end, 10); > if((v <= 0) || (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base, "An invalid or unterminated recursive sub-expression."); > return false; > } > v += m_mark_count; > goto insert_recursion; > case regex_constants::syntax_dash: > > > > ++m_position; > v = this->m_traits.toi(m_position, m_end, 10); > if(v <= 0) > { > --m_position; > > goto option_group_jump; > } > v = m_mark_count + 1 - v; > if(v <= 0) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base, "An invalid or unterminated recursive sub-expression."); > return false; > } > goto insert_recursion; > case regex_constants::syntax_equal: > pb->index = markid = -1; > ++m_position; > jump_offset = this->getoffset(this->append_state(syntax_element_jump, sizeof(re_jump))); > this->m_pdata->m_data.align(); > m_alt_insert_point = this->m_pdata->m_data.size(); > break; > case regex_constants::syntax_not: > pb->index = markid = -2; > ++m_position; > jump_offset = this->getoffset(this->append_state(syntax_element_jump, sizeof(re_jump))); > this->m_pdata->m_data.align(); > m_alt_insert_point = this->m_pdata->m_data.size(); > break; > case regex_constants::escape_type_left_word: > { > > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > regex_constants::syntax_type t = this->m_traits.syntax_type(*m_position); > if(t == regex_constants::syntax_not) > pb->index = markid = -2; > else if(t == regex_constants::syntax_equal) > pb->index = markid = -1; > else > { > > name_delim = '>'; > --m_position; > goto named_capture_jump; > } > ++m_position; > jump_offset = this->getoffset(this->append_state(syntax_element_jump, sizeof(re_jump))); > this->append_state(syntax_element_backstep, sizeof(re_brace)); > this->m_pdata->m_data.align(); > m_alt_insert_point = this->m_pdata->m_data.size(); > break; > } > case regex_constants::escape_type_right_word: > > > > pb->index = markid = -3; > ++m_position; > jump_offset = this->getoffset(this->append_state(syntax_element_jump, sizeof(re_jump))); > this->m_pdata->m_data.align(); > m_alt_insert_point = this->m_pdata->m_data.size(); > break; > case regex_constants::syntax_open_mark: > { > > pb->index = markid = -4; > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > v = this->m_traits.toi(m_position, m_end, 10); > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if(*m_position == charT('R')) > { > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if(*m_position == charT('&')) > { > const charT* base = ++m_position; > while((m_position != m_end) && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark)) > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > v = -static_cast<int>(hash_value_from_capture_name(base, m_position)); > } > else > { > v = -this->m_traits.toi(m_position, m_end, 10); > } > re_brace* br = static_cast<re_brace*>(this->append_state(syntax_element_assert_backref, sizeof(re_brace))); > br->index = v < 0 ? (v - 1) : 0; > if(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > } > else if((*m_position == charT('\'')) || (*m_position == charT('<'))) > { > const charT* base = ++m_position; > while((m_position != m_end) && (*m_position != charT('>')) && (*m_position != charT('\''))) > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > v = static_cast<int>(hash_value_from_capture_name(base, m_position)); > re_brace* br = static_cast<re_brace*>(this->append_state(syntax_element_assert_backref, sizeof(re_brace))); > br->index = v; > if(((*m_position != charT('>')) && (*m_position != charT('\''))) || (++m_position == m_end)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base, "Unterminated named capture."); > return false; > } > if(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > } > else if(*m_position == charT('D')) > { > const char* def = "DEFINE"; > while(*def && (m_position != m_end) && (*m_position == charT(*def))) > ++m_position, ++def; > if((m_position == m_end) || *def) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > re_brace* br = static_cast<re_brace*>(this->append_state(syntax_element_assert_backref, sizeof(re_brace))); > br->index = 9999; > if(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > } > else if(v > 0) > { > re_brace* br = static_cast<re_brace*>(this->append_state(syntax_element_assert_backref, sizeof(re_brace))); > br->index = v; > if(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > } > else > { > > if(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_question) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if(this->m_traits.syntax_type(*m_position) == regex_constants::escape_type_left_word) > { > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if((this->m_traits.syntax_type(*m_position) != regex_constants::syntax_equal) > && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_not)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > m_position -= 3; > } > else > { > if((this->m_traits.syntax_type(*m_position) != regex_constants::syntax_equal) > && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_not)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > m_position -= 2; > } > } > break; > } > case regex_constants::syntax_close_mark: > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > case regex_constants::escape_type_end_buffer: > { > name_delim = *m_position; >named_capture_jump: > markid = 0; > if(0 == (this->flags() & regbase::nosubs)) > { > markid = ++m_mark_count; > > if(this->flags() & regbase::save_subexpression_location) > this->m_pdata->m_subs.push_back(std::pair<std::size_t, std::size_t>(std::distance(m_base, m_position) - 2, 0)); > > > > > } > pb->index = markid; > const charT* base = ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > while((m_position != m_end) && (*m_position != name_delim)) > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > this->m_pdata->set_name(base, m_position, markid); > ++m_position; > break; > } > default: > if(*m_position == charT('R')) > { > ++m_position; > v = 0; > if(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > goto insert_recursion; > } > if(*m_position == charT('&')) > { > ++m_position; > const charT* base = m_position; > while((m_position != m_end) && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark)) > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > v = static_cast<int>(hash_value_from_capture_name(base, m_position)); > goto insert_recursion; > } > if(*m_position == charT('P')) > { > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > if(*m_position == charT('>')) > { > ++m_position; > const charT* base = m_position; > while((m_position != m_end) && (this->m_traits.syntax_type(*m_position) != regex_constants::syntax_close_mark)) > ++m_position; > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > v = static_cast<int>(hash_value_from_capture_name(base, m_position)); > goto insert_recursion; > } > } > > > >option_group_jump: > regex_constants::syntax_option_type opts = parse_options(); > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > > m_has_case_change = ((opts & regbase::icase) != (this->flags() & regbase::icase)); > pb->index = markid = 0; > if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_close_mark) > { > > this->flags(opts); > restore_flags = false; > old_case_change |= m_has_case_change; > } > else if(this->m_traits.syntax_type(*m_position) == regex_constants::syntax_colon) > { > > this->flags(opts); > ++m_position; > } > else > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base); > return false; > } > > > if(m_has_case_change) > { > static_cast<re_case*>( > this->append_state(syntax_element_toggle_case, sizeof(re_case)) > )->icase = opts & regbase::icase; > } > > } > > > > > parse_all(); > > > > if(0 == unwind_alts(last_paren_start)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base, "Invalid alternation operators within (?...) block."); > return false; > } > > > > if(m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > this->fail(regex_constants::error_paren, ::boost::re_detail::distance(m_base, m_end)); > return false; > } > (static_cast<void> (0)); > ++m_position; > > > > if(restore_flags) > { > > if(m_has_case_change) > { > static_cast<re_case*>( > this->append_state(syntax_element_toggle_case, sizeof(re_case)) > )->icase = old_flags & regbase::icase; > } > this->flags(old_flags); > } > > > > if(jump_offset) > { > this->m_pdata->m_data.align(); > re_jump* jmp = static_cast<re_jump*>(this->getaddress(jump_offset)); > jmp->alt.i = this->m_pdata->m_data.size() - this->getoffset(jmp); > if((this->m_last_state == jmp) && (markid != -2)) > { > > > > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_perl_extension, m_position - m_base, "Invalid or empty zero width assertion."); > return false; > } > } > > > > > if(markid == -4) > { > re_syntax_base* b = this->getaddress(expected_alt_point); > > if(b->type != syntax_element_alt) > { > re_alt* alt = static_cast<re_alt*>(this->insert_state(expected_alt_point, syntax_element_alt, sizeof(re_alt))); > alt->alt.i = this->m_pdata->m_data.size() - this->getoffset(alt); > } > else if(this->getaddress(static_cast<re_alt*>(b)->alt.i, b)->type == syntax_element_alt) > { > > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_bad_pattern, m_position - m_base, "More than one alternation operator | was encountered inside a conditional expression."); > return false; > } > else > { > > b = this->getaddress(b->next.i, b); > if((b->type == syntax_element_assert_backref) && (static_cast<re_brace*>(b)->index == 9999)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_bad_pattern, m_position - m_base, "Alternation operators are not allowed inside a DEFINE block."); > return false; > } > } > > b = this->getaddress(expected_alt_point); > b = this->getaddress(static_cast<re_alt*>(b)->next.i, b); > if((b->type != syntax_element_assert_backref) > && (b->type != syntax_element_startmark)) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_badrepeat, m_position - m_base, "A repetition operator cannot be applied to a zero-width assertion."); > return false; > } > } > > > > pb = static_cast<re_brace*>(this->append_state(syntax_element_endmark, sizeof(re_brace))); > pb->index = markid; > pb->icase = this->flags() & regbase::icase; > this->m_paren_start = last_paren_start; > > > > this->m_alt_insert_point = last_alt_point; > > > > m_has_case_change = old_case_change; > > > > if(m_max_mark > m_mark_count) > { > m_mark_count = m_max_mark; > } > m_mark_reset = mark_reset; > m_max_mark = max_mark; > > > if(markid > 0) > { > > if(this->flags() & regbase::save_subexpression_location) > this->m_pdata->m_subs.at(markid - 1).second = std::distance(m_base, m_position) - 1; > > > > > > > > if((markid > 0) && (markid < (int)(sizeof(unsigned) * 8))) > this->m_backrefs |= 1u << (markid - 1); > } > return true; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::add_emacs_code(bool negate) >{ > > > > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_escape) --m_position; > fail(regex_constants::error_escape, m_position - m_base); > return false; > } > basic_char_set<charT, traits> char_set; > if(negate) > char_set.negate(); > > static const charT s_punct[5] = { 'p', 'u', 'n', 'c', 't', }; > > switch(*m_position) > { > case 's': > case ' ': > char_set.add_class(this->m_mask_space); > break; > case 'w': > char_set.add_class(this->m_word_mask); > break; > case '_': > char_set.add_single(digraph<charT>(charT('$'))); > char_set.add_single(digraph<charT>(charT('&'))); > char_set.add_single(digraph<charT>(charT('*'))); > char_set.add_single(digraph<charT>(charT('+'))); > char_set.add_single(digraph<charT>(charT('-'))); > char_set.add_single(digraph<charT>(charT('_'))); > char_set.add_single(digraph<charT>(charT('<'))); > char_set.add_single(digraph<charT>(charT('>'))); > break; > case '.': > char_set.add_class(this->m_traits.lookup_classname(s_punct, s_punct+5)); > break; > case '(': > char_set.add_single(digraph<charT>(charT('('))); > char_set.add_single(digraph<charT>(charT('['))); > char_set.add_single(digraph<charT>(charT('{'))); > break; > case ')': > char_set.add_single(digraph<charT>(charT(')'))); > char_set.add_single(digraph<charT>(charT(']'))); > char_set.add_single(digraph<charT>(charT('}'))); > break; > case '"': > char_set.add_single(digraph<charT>(charT('"'))); > char_set.add_single(digraph<charT>(charT('\''))); > char_set.add_single(digraph<charT>(charT('`'))); > break; > case '\'': > char_set.add_single(digraph<charT>(charT('\''))); > char_set.add_single(digraph<charT>(charT(','))); > char_set.add_single(digraph<charT>(charT('#'))); > break; > case '<': > char_set.add_single(digraph<charT>(charT(';'))); > break; > case '>': > char_set.add_single(digraph<charT>(charT('\n'))); > char_set.add_single(digraph<charT>(charT('\f'))); > break; > default: > fail(regex_constants::error_ctype, m_position - m_base); > return false; > } > if(0 == this->append_set(char_set)) > { > fail(regex_constants::error_ctype, m_position - m_base); > return false; > } > ++m_position; > return true; >} > >template <class charT, class traits> >regex_constants::syntax_option_type basic_regex_parser<charT, traits>::parse_options() >{ > > regex_constants::syntax_option_type f = this->flags(); > bool breakout = false; > do > { > switch(*m_position) > { > case 's': > f |= regex_constants::mod_s; > f &= ~regex_constants::no_mod_s; > break; > case 'm': > f &= ~regex_constants::no_mod_m; > break; > case 'i': > f |= regex_constants::icase; > break; > case 'x': > f |= regex_constants::mod_x; > break; > default: > breakout = true; > continue; > } > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_paren, m_position - m_base); > return false; > } > } > while(!breakout); > > breakout = false; > > if(*m_position == static_cast<charT>('-')) > { > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_paren, m_position - m_base); > return false; > } > do > { > switch(*m_position) > { > case 's': > f &= ~regex_constants::mod_s; > f |= regex_constants::no_mod_s; > break; > case 'm': > f |= regex_constants::no_mod_m; > break; > case 'i': > f &= ~regex_constants::icase; > break; > case 'x': > f &= ~regex_constants::mod_x; > break; > default: > breakout = true; > continue; > } > if(++m_position == m_end) > { > > --m_position; > while(this->m_traits.syntax_type(*m_position) != regex_constants::syntax_open_mark) --m_position; > fail(regex_constants::error_paren, m_position - m_base); > return false; > } > } > while(!breakout); > } > return f; >} > >template <class charT, class traits> >bool basic_regex_parser<charT, traits>::unwind_alts(std::ptrdiff_t last_paren_start) >{ > > > > > if((this->m_alt_insert_point == static_cast<std::ptrdiff_t>(this->m_pdata->m_data.size())) > && m_alt_jumps.size() && (m_alt_jumps.back() > last_paren_start) > && > !( > ((this->flags() & regbase::main_option_type) == regbase::perl_syntax_group) > && > ((this->flags() & regbase::no_empty_expressions) == 0) > ) > ) > { > fail(regex_constants::error_empty, this->m_position - this->m_base, "Can't terminate a sub-expression with an alternation operator |."); > return false; > } > > > > while(m_alt_jumps.size() && (m_alt_jumps.back() > last_paren_start)) > { > > > > > std::ptrdiff_t jump_offset = m_alt_jumps.back(); > m_alt_jumps.pop_back(); > this->m_pdata->m_data.align(); > re_jump* jmp = static_cast<re_jump*>(this->getaddress(jump_offset)); > (static_cast<void> (0)); > jmp->alt.i = this->m_pdata->m_data.size() - jump_offset; > } > return true; >} > > > > > >} >} ># 74 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/sub_match.hpp" 1 3 4 ># 33 "/usr/include/boost/regex/v4/sub_match.hpp" 3 4 >namespace boost{ > >template <class BidiIterator> >struct sub_match : public std::pair<BidiIterator, BidiIterator> >{ > typedef typename re_detail::regex_iterator_traits<BidiIterator>::value_type value_type; > > > > typedef typename re_detail::regex_iterator_traits<BidiIterator>::difference_type difference_type; > > typedef BidiIterator iterator_type; > typedef BidiIterator iterator; > typedef BidiIterator const_iterator; > > bool matched; > > sub_match() : std::pair<BidiIterator, BidiIterator>(), matched(false) {} > sub_match(BidiIterator i) : std::pair<BidiIterator, BidiIterator>(i, i), matched(false) {} > > > > > template <class T, class A> > operator std::basic_string<value_type, T, A> ()const > { > return matched ? std::basic_string<value_type, T, A>(this->first, this->second) : std::basic_string<value_type, T, A>(); > } > > > > > > > difference_type length()const > { > difference_type n = matched ? ::boost::re_detail::distance((BidiIterator)this->first, (BidiIterator)this->second) : 0; > return n; > } > std::basic_string<value_type> str()const > { > std::basic_string<value_type> result; > if(matched) > { > std::size_t len = ::boost::re_detail::distance((BidiIterator)this->first, (BidiIterator)this->second); > result.reserve(len); > BidiIterator i = this->first; > while(i != this->second) > { > result.append(1, *i); > ++i; > } > } > return result; > } > int compare(const sub_match& s)const > { > if(matched != s.matched) > return static_cast<int>(matched) - static_cast<int>(s.matched); > return str().compare(s.str()); > } > int compare(const std::basic_string<value_type>& s)const > { > return str().compare(s); > } > int compare(const value_type* p)const > { > return str().compare(p); > } > > bool operator==(const sub_match& that)const > { return compare(that) == 0; } > bool operator !=(const sub_match& that)const > { return compare(that) != 0; } > bool operator<(const sub_match& that)const > { return compare(that) < 0; } > bool operator>(const sub_match& that)const > { return compare(that) > 0; } > bool operator<=(const sub_match& that)const > { return compare(that) <= 0; } > bool operator>=(const sub_match& that)const > { return compare(that) >= 0; } ># 140 "/usr/include/boost/regex/v4/sub_match.hpp" 3 4 > sub_match(const sub_match& that, bool > > > > = true > ) > : std::pair<BidiIterator, BidiIterator>(that), > matched(that.matched) > { > > > > > > } > sub_match& operator=(const sub_match& that) > { > this->first = that.first; > this->second = that.second; > matched = that.matched; > > > > > return *this; > } ># 183 "/usr/include/boost/regex/v4/sub_match.hpp" 3 4 >}; > >typedef sub_match<const char*> csub_match; >typedef sub_match<std::string::const_iterator> ssub_match; > >typedef sub_match<const wchar_t*> wcsub_match; >typedef sub_match<std::wstring::const_iterator> wssub_match; > > > >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator == (const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s, > const sub_match<RandomAccessIterator>& m) >{ return s.compare(m.str()) == 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator != (const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s, > const sub_match<RandomAccessIterator>& m) >{ return s.compare(m.str()) != 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator < (const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s, > const sub_match<RandomAccessIterator>& m) >{ return s.compare(m.str()) < 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator <= (const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s, > const sub_match<RandomAccessIterator>& m) >{ return s.compare(m.str()) <= 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator >= (const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s, > const sub_match<RandomAccessIterator>& m) >{ return s.compare(m.str()) >= 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator > (const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s, > const sub_match<RandomAccessIterator>& m) >{ return s.compare(m.str()) > 0; } > >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator == (const sub_match<RandomAccessIterator>& m, > const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s) >{ return m.str().compare(s) == 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator != (const sub_match<RandomAccessIterator>& m, > const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s) >{ return m.str().compare(s) != 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator < (const sub_match<RandomAccessIterator>& m, > const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s) >{ return m.str().compare(s) < 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator > (const sub_match<RandomAccessIterator>& m, > const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s) >{ return m.str().compare(s) > 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator <= (const sub_match<RandomAccessIterator>& m, > const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s) >{ return m.str().compare(s) <= 0; } >template <class RandomAccessIterator, class traits, class Allocator> >inline bool operator >= (const sub_match<RandomAccessIterator>& m, > const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s) >{ return m.str().compare(s) >= 0; } > >template <class RandomAccessIterator> >inline bool operator == (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s) >{ return m.str().compare(s) == 0; } >template <class RandomAccessIterator> >inline bool operator != (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s) >{ return m.str().compare(s) != 0; } >template <class RandomAccessIterator> >inline bool operator > (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s) >{ return m.str().compare(s) > 0; } >template <class RandomAccessIterator> >inline bool operator < (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s) >{ return m.str().compare(s) < 0; } >template <class RandomAccessIterator> >inline bool operator >= (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s) >{ return m.str().compare(s) >= 0; } >template <class RandomAccessIterator> >inline bool operator <= (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s) >{ return m.str().compare(s) <= 0; } > >template <class RandomAccessIterator> >inline bool operator == (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(s) == 0; } >template <class RandomAccessIterator> >inline bool operator != (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(s) != 0; } >template <class RandomAccessIterator> >inline bool operator < (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(s) > 0; } >template <class RandomAccessIterator> >inline bool operator > (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(s) < 0; } >template <class RandomAccessIterator> >inline bool operator <= (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(s) >= 0; } >template <class RandomAccessIterator> >inline bool operator >= (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(s) <= 0; } > > >template <class RandomAccessIterator> >inline bool operator == (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s) >{ return m.str().compare(0, m.length(), &s, 1) == 0; } >template <class RandomAccessIterator> >inline bool operator != (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s) >{ return m.str().compare(0, m.length(), &s, 1) != 0; } >template <class RandomAccessIterator> >inline bool operator > (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s) >{ return m.str().compare(0, m.length(), &s, 1) > 0; } >template <class RandomAccessIterator> >inline bool operator < (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s) >{ return m.str().compare(0, m.length(), &s, 1) < 0; } >template <class RandomAccessIterator> >inline bool operator >= (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s) >{ return m.str().compare(0, m.length(), &s, 1) >= 0; } >template <class RandomAccessIterator> >inline bool operator <= (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s) >{ return m.str().compare(0, m.length(), &s, 1) <= 0; } > >template <class RandomAccessIterator> >inline bool operator == (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(0, m.length(), &s, 1) == 0; } >template <class RandomAccessIterator> >inline bool operator != (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(0, m.length(), &s, 1) != 0; } >template <class RandomAccessIterator> >inline bool operator < (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(0, m.length(), &s, 1) > 0; } >template <class RandomAccessIterator> >inline bool operator > (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(0, m.length(), &s, 1) < 0; } >template <class RandomAccessIterator> >inline bool operator <= (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(0, m.length(), &s, 1) >= 0; } >template <class RandomAccessIterator> >inline bool operator >= (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s, > const sub_match<RandomAccessIterator>& m) >{ return m.str().compare(0, m.length(), &s, 1) <= 0; } > > >template <class RandomAccessIterator, class traits, class Allocator> >inline std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator> >operator + (const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s, > const sub_match<RandomAccessIterator>& m) >{ > std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator> result; > result.reserve(s.size() + m.length() + 1); > return result.append(s).append(m.first, m.second); >} >template <class RandomAccessIterator, class traits, class Allocator> >inline std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator> >operator + (const sub_match<RandomAccessIterator>& m, > const std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator>& s) >{ > std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type, traits, Allocator> result; > result.reserve(s.size() + m.length() + 1); > return result.append(m.first, m.second).append(s); >} > >template <class RandomAccessIterator> >inline std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> >operator + (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const* s, > const sub_match<RandomAccessIterator>& m) >{ > std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> result; > result.reserve(std::char_traits<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type>::length(s) + m.length() + 1); > return result.append(s).append(m.first, m.second); >} >template <class RandomAccessIterator> >inline std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> >operator + (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const * s) >{ > std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> result; > result.reserve(std::char_traits<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type>::length(s) + m.length() + 1); > return result.append(m.first, m.second).append(s); >} ># 399 "/usr/include/boost/regex/v4/sub_match.hpp" 3 4 >template <class RandomAccessIterator> >inline std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> >operator + (typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s, > const sub_match<RandomAccessIterator>& m) >{ > std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> result; > result.reserve(m.length() + 2); > return result.append(1, s).append(m.first, m.second); >} >template <class RandomAccessIterator> >inline std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> >operator + (const sub_match<RandomAccessIterator>& m, > typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type const& s) >{ > std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> result; > result.reserve(m.length() + 2); > return result.append(m.first, m.second).append(1, s); >} >template <class RandomAccessIterator> >inline std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> >operator + (const sub_match<RandomAccessIterator>& m1, > const sub_match<RandomAccessIterator>& m2) >{ > std::basic_string<typename re_detail::regex_iterator_traits<RandomAccessIterator>::value_type> result; > result.reserve(m1.length() + m2.length() + 1); > return result.append(m1.first, m1.second).append(m2.first, m2.second); >} > >template <class charT, class traits, class RandomAccessIterator> >std::basic_ostream<charT, traits>& > operator << (std::basic_ostream<charT, traits>& os, > const sub_match<RandomAccessIterator>& s) >{ > return (os << s.str()); >} ># 498 "/usr/include/boost/regex/v4/sub_match.hpp" 3 4 >} ># 77 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_format.hpp" 1 3 4 ># 39 "/usr/include/boost/regex/v4/regex_format.hpp" 3 4 >namespace boost{ ># 55 "/usr/include/boost/regex/v4/regex_format.hpp" 3 4 > template <class BidiIterator, class Allocator = typename std::vector<sub_match<BidiIterator> >::allocator_type > >class match_results; > >namespace re_detail{ > > > > > > >template <class charT> >struct trivial_format_traits >{ > typedef charT char_type; > > static std::ptrdiff_t length(const charT* p) > { > return global_length(p); > } > static charT tolower(charT c) > { > return ::boost::re_detail::global_lower(c); > } > static charT toupper(charT c) > { > return ::boost::re_detail::global_upper(c); > } > static int value(const charT c, int radix) > { > int result = global_value(c); > return result >= radix ? -1 : result; > } > int toi(const charT*& p1, const charT* p2, int radix)const > { > return global_toi(p1, p2, radix, *this); > } >}; > >template <class OutputIterator, class Results, class traits, class ForwardIter> >class basic_regex_formatter >{ >public: > typedef typename traits::char_type char_type; > basic_regex_formatter(OutputIterator o, const Results& r, const traits& t) > : m_traits(t), m_results(r), m_out(o), m_state(output_copy), m_restore_state(output_copy), m_have_conditional(false) {} > OutputIterator format(ForwardIter p1, ForwardIter p2, match_flag_type f); > OutputIterator format(ForwardIter p1, match_flag_type f) > { > return format(p1, p1 + m_traits.length(p1), f); > } >private: > typedef typename Results::value_type sub_match_type; > enum output_state > { > output_copy, > output_next_lower, > output_next_upper, > output_lower, > output_upper, > output_none > }; > > void put(char_type c); > void put(const sub_match_type& sub); > void format_all(); > void format_perl(); > void format_escape(); > void format_conditional(); > void format_until_scope_end(); > bool handle_perl_verb(bool have_brace); > > inline typename Results::value_type const& get_named_sub(ForwardIter i, ForwardIter j, const mpl::false_&) > { > std::vector<char_type> v(i, j); > return (i != j) ? this->m_results.named_subexpression(&v[0], &v[0] + v.size()) > : this->m_results.named_subexpression(static_cast<const char_type*>(0), static_cast<const char_type*>(0)); > } > inline typename Results::value_type const& get_named_sub(ForwardIter i, ForwardIter j, const mpl::true_&) > { > return this->m_results.named_subexpression(i, j); > } > inline typename Results::value_type const& get_named_sub(ForwardIter i, ForwardIter j) > { > typedef typename boost::is_convertible<ForwardIter, const char_type*>::type tag_type; > return get_named_sub(i, j, tag_type()); > } > inline int get_named_sub_index(ForwardIter i, ForwardIter j, const mpl::false_&) > { > std::vector<char_type> v(i, j); > return (i != j) ? this->m_results.named_subexpression_index(&v[0], &v[0] + v.size()) > : this->m_results.named_subexpression_index(static_cast<const char_type*>(0), static_cast<const char_type*>(0)); > } > inline int get_named_sub_index(ForwardIter i, ForwardIter j, const mpl::true_&) > { > return this->m_results.named_subexpression_index(i, j); > } > inline int get_named_sub_index(ForwardIter i, ForwardIter j) > { > typedef typename boost::is_convertible<ForwardIter, const char_type*>::type tag_type; > return get_named_sub_index(i, j, tag_type()); > } > > > > > > inline int toi(ForwardIter& i, ForwardIter j, int base, const boost::mpl::false_&) > { > if(i != j) > { > std::vector<char_type> v(i, j); > const char_type* start = &v[0]; > const char_type* pos = start; > int r = m_traits.toi(pos, &v[0] + v.size(), base); > std::advance(i, pos - start); > return r; > } > return -1; > } > > > > inline int toi(ForwardIter& i, ForwardIter j, int base, const boost::mpl::true_&) > { > return m_traits.toi(i, j, base); > } > inline int toi(ForwardIter& i, ForwardIter j, int base) > { > > > > > > typedef typename boost::is_convertible<ForwardIter, const char_type*&>::type tag_type; > return toi(i, j, base, tag_type()); > > } > > const traits& m_traits; > const Results& m_results; > OutputIterator m_out; > ForwardIter m_position; > ForwardIter m_end; > match_flag_type m_flags; > output_state m_state; > output_state m_restore_state; > bool m_have_conditional; >private: > basic_regex_formatter(const basic_regex_formatter&); > basic_regex_formatter& operator=(const basic_regex_formatter&); >}; > >template <class OutputIterator, class Results, class traits, class ForwardIter> >OutputIterator basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format(ForwardIter p1, ForwardIter p2, match_flag_type f) >{ > m_position = p1; > m_end = p2; > m_flags = f; > format_all(); > return m_out; >} > >template <class OutputIterator, class Results, class traits, class ForwardIter> >void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format_all() >{ > > while(m_position != m_end) > { > switch(*m_position) > { > case '&': > if(m_flags & ::boost::regex_constants::format_sed) > { > ++m_position; > put(m_results[0]); > break; > } > put(*m_position++); > break; > case '\\': > format_escape(); > break; > case '(': > if(m_flags & boost::regex_constants::format_all) > { > ++m_position; > bool have_conditional = m_have_conditional; > m_have_conditional = false; > format_until_scope_end(); > m_have_conditional = have_conditional; > if(m_position == m_end) > return; > (static_cast<void> (0)); > ++m_position; > break; > } > put(*m_position); > ++m_position; > break; > case ')': > if(m_flags & boost::regex_constants::format_all) > { > return; > } > put(*m_position); > ++m_position; > break; > case ':': > if((m_flags & boost::regex_constants::format_all) && m_have_conditional) > { > return; > } > put(*m_position); > ++m_position; > break; > case '?': > if(m_flags & boost::regex_constants::format_all) > { > ++m_position; > format_conditional(); > break; > } > put(*m_position); > ++m_position; > break; > case '$': > if((m_flags & format_sed) == 0) > { > format_perl(); > break; > } > > ((void)0); > default: > put(*m_position); > ++m_position; > break; > } > } >} > >template <class OutputIterator, class Results, class traits, class ForwardIter> >void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format_perl() >{ > > > > > (static_cast<void> (0)); > > > > if(++m_position == m_end) > { > --m_position; > put(*m_position); > ++m_position; > return; > } > > > > bool have_brace = false; > ForwardIter save_position = m_position; > switch(*m_position) > { > case '&': > ++m_position; > put(this->m_results[0]); > break; > case '`': > ++m_position; > put(this->m_results.prefix()); > break; > case '\'': > ++m_position; > put(this->m_results.suffix()); > break; > case '$': > put(*m_position++); > break; > case '+': > if((++m_position != m_end) && (*m_position == '{')) > { > ForwardIter base = ++m_position; > while((m_position != m_end) && (*m_position != '}')) ++m_position; > if(m_position != m_end) > { > > put(get_named_sub(base, m_position)); > ++m_position; > break; > } > else > { > m_position = --base; > } > } > put((this->m_results)[this->m_results.size() > 1 ? static_cast<int>(this->m_results.size() - 1) : 1]); > break; > case '{': > have_brace = true; > ++m_position; > ((void)0); > default: > > { > std::ptrdiff_t len = ::boost::re_detail::distance(m_position, m_end); > > int v = this->toi(m_position, m_position + len, 10); > if((v < 0) || (have_brace && ((m_position == m_end) || (*m_position != '}')))) > { > > if(!handle_perl_verb(have_brace)) > { > > m_position = --save_position; > put(*m_position); > ++m_position; > } > break; > } > > put(this->m_results[v]); > if(have_brace) > ++m_position; > } > } >} > >template <class OutputIterator, class Results, class traits, class ForwardIter> >bool basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::handle_perl_verb(bool have_brace) >{ > > > > static const char_type MATCH[] = { 'M', 'A', 'T', 'C', 'H' }; > static const char_type PREMATCH[] = { 'P', 'R', 'E', 'M', 'A', 'T', 'C', 'H' }; > static const char_type POSTMATCH[] = { 'P', 'O', 'S', 'T', 'M', 'A', 'T', 'C', 'H' }; > static const char_type LAST_PAREN_MATCH[] = { 'L', 'A', 'S', 'T', '_', 'P', 'A', 'R', 'E', 'N', '_', 'M', 'A', 'T', 'C', 'H' }; > static const char_type LAST_SUBMATCH_RESULT[] = { 'L', 'A', 'S', 'T', '_', 'S', 'U', 'B', 'M', 'A', 'T', 'C', 'H', '_', 'R', 'E', 'S', 'U', 'L', 'T' }; > static const char_type LAST_SUBMATCH_RESULT_ALT[] = { '^', 'N' }; > > if(m_position == m_end) > return false; > if(have_brace && (*m_position == '^')) > ++m_position; > > std::ptrdiff_t max_len = m_end - m_position; > > if((max_len >= 5) && std::equal(m_position, m_position + 5, MATCH)) > { > m_position += 5; > if(have_brace) > { > if((m_position != m_end) && (*m_position == '}')) > ++m_position; > else > { > m_position -= 5; > return false; > } > } > put(this->m_results[0]); > return true; > } > if((max_len >= 8) && std::equal(m_position, m_position + 8, PREMATCH)) > { > m_position += 8; > if(have_brace) > { > if((m_position != m_end) && (*m_position == '}')) > ++m_position; > else > { > m_position -= 8; > return false; > } > } > put(this->m_results.prefix()); > return true; > } > if((max_len >= 9) && std::equal(m_position, m_position + 9, POSTMATCH)) > { > m_position += 9; > if(have_brace) > { > if((m_position != m_end) && (*m_position == '}')) > ++m_position; > else > { > m_position -= 9; > return false; > } > } > put(this->m_results.suffix()); > return true; > } > if((max_len >= 16) && std::equal(m_position, m_position + 16, LAST_PAREN_MATCH)) > { > m_position += 16; > if(have_brace) > { > if((m_position != m_end) && (*m_position == '}')) > ++m_position; > else > { > m_position -= 16; > return false; > } > } > put((this->m_results)[this->m_results.size() > 1 ? static_cast<int>(this->m_results.size() - 1) : 1]); > return true; > } > if((max_len >= 20) && std::equal(m_position, m_position + 20, LAST_SUBMATCH_RESULT)) > { > m_position += 20; > if(have_brace) > { > if((m_position != m_end) && (*m_position == '}')) > ++m_position; > else > { > m_position -= 20; > return false; > } > } > put(this->m_results.get_last_closed_paren()); > return true; > } > if((max_len >= 2) && std::equal(m_position, m_position + 2, LAST_SUBMATCH_RESULT_ALT)) > { > m_position += 2; > if(have_brace) > { > if((m_position != m_end) && (*m_position == '}')) > ++m_position; > else > { > m_position -= 2; > return false; > } > } > put(this->m_results.get_last_closed_paren()); > return true; > } > return false; >} > >template <class OutputIterator, class Results, class traits, class ForwardIter> >void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format_escape() >{ > > if(++m_position == m_end) > { > put(static_cast<char_type>('\\')); > return; > } > > switch(*m_position) > { > case 'a': > put(static_cast<char_type>('\a')); > ++m_position; > break; > case 'f': > put(static_cast<char_type>('\f')); > ++m_position; > break; > case 'n': > put(static_cast<char_type>('\n')); > ++m_position; > break; > case 'r': > put(static_cast<char_type>('\r')); > ++m_position; > break; > case 't': > put(static_cast<char_type>('\t')); > ++m_position; > break; > case 'v': > put(static_cast<char_type>('\v')); > ++m_position; > break; > case 'x': > if(++m_position == m_end) > { > put(static_cast<char_type>('x')); > return; > } > > if(*m_position == static_cast<char_type>('{')) > { > ++m_position; > int val = this->toi(m_position, m_end, 16); > if(val < 0) > { > > put(static_cast<char_type>('x')); > put(static_cast<char_type>('{')); > return; > } > if((m_position == m_end) || (*m_position != static_cast<char_type>('}'))) > { > --m_position; > while(*m_position != static_cast<char_type>('\\')) > --m_position; > ++m_position; > put(*m_position++); > return; > } > ++m_position; > put(static_cast<char_type>(val)); > return; > } > else > { > std::ptrdiff_t len = ::boost::re_detail::distance(m_position, m_end); > len = (std::min)(static_cast<std::ptrdiff_t>(2), len); > int val = this->toi(m_position, m_position + len, 16); > if(val < 0) > { > --m_position; > put(*m_position++); > return; > } > put(static_cast<char_type>(val)); > } > break; > case 'c': > if(++m_position == m_end) > { > --m_position; > put(*m_position++); > return; > } > put(static_cast<char_type>(*m_position++ % 32)); > break; > case 'e': > put(static_cast<char_type>(27)); > ++m_position; > break; > default: > > if((m_flags & boost::regex_constants::format_sed) == 0) > { > bool breakout = false; > switch(*m_position) > { > case 'l': > ++m_position; > m_restore_state = m_state; > m_state = output_next_lower; > breakout = true; > break; > case 'L': > ++m_position; > m_state = output_lower; > breakout = true; > break; > case 'u': > ++m_position; > m_restore_state = m_state; > m_state = output_next_upper; > breakout = true; > break; > case 'U': > ++m_position; > m_state = output_upper; > breakout = true; > break; > case 'E': > ++m_position; > m_state = output_copy; > breakout = true; > break; > } > if(breakout) > break; > } > > std::ptrdiff_t len = ::boost::re_detail::distance(m_position, m_end); > len = (std::min)(static_cast<std::ptrdiff_t>(1), len); > int v = this->toi(m_position, m_position+len, 10); > if((v > 0) || ((v == 0) && (m_flags & ::boost::regex_constants::format_sed))) > { > put(m_results[v]); > break; > } > else if(v == 0) > { > > --m_position; > len = ::boost::re_detail::distance(m_position, m_end); > len = (std::min)(static_cast<std::ptrdiff_t>(4), len); > v = this->toi(m_position, m_position + len, 8); > (static_cast<void> (0)); > put(static_cast<char_type>(v)); > break; > } > > put(*m_position++); > break; > } >} > >template <class OutputIterator, class Results, class traits, class ForwardIter> >void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format_conditional() >{ > if(m_position == m_end) > { > > put(static_cast<char_type>('?')); > return; > } > int v; > if(*m_position == '{') > { > ForwardIter base = m_position; > ++m_position; > v = this->toi(m_position, m_end, 10); > if(v < 0) > { > > while((m_position != m_end) && (*m_position != '}')) > ++m_position; > v = this->get_named_sub_index(base + 1, m_position); > } > if((v < 0) || (*m_position != '}')) > { > m_position = base; > > put(static_cast<char_type>('?')); > return; > } > > ++m_position; > } > else > { > std::ptrdiff_t len = ::boost::re_detail::distance(m_position, m_end); > len = (std::min)(static_cast<std::ptrdiff_t>(2), len); > v = this->toi(m_position, m_position + len, 10); > } > if(v < 0) > { > > put(static_cast<char_type>('?')); > return; > } > > > if(m_results[v].matched) > { > m_have_conditional = true; > format_all(); > m_have_conditional = false; > if((m_position != m_end) && (*m_position == static_cast<char_type>(':'))) > { > > ++m_position; > > output_state saved_state = m_state; > m_state = output_none; > > format_until_scope_end(); > > m_state = saved_state; > } > } > else > { > > output_state saved_state = m_state; > m_state = output_none; > > m_have_conditional = true; > format_all(); > m_have_conditional = false; > > m_state = saved_state; > if((m_position != m_end) && (*m_position == static_cast<char_type>(':'))) > { > > ++m_position; > > format_until_scope_end(); > } > } >} > >template <class OutputIterator, class Results, class traits, class ForwardIter> >void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::format_until_scope_end() >{ > do > { > format_all(); > if((m_position == m_end) || (*m_position == static_cast<char_type>(')'))) > return; > put(*m_position++); > }while(m_position != m_end); >} > >template <class OutputIterator, class Results, class traits, class ForwardIter> >void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::put(char_type c) >{ > > > switch(this->m_state) > { > case output_none: > return; > case output_next_lower: > c = m_traits.tolower(c); > this->m_state = m_restore_state; > break; > case output_next_upper: > c = m_traits.toupper(c); > this->m_state = m_restore_state; > break; > case output_lower: > c = m_traits.tolower(c); > break; > case output_upper: > c = m_traits.toupper(c); > break; > default: > break; > } > *m_out = c; > ++m_out; >} > >template <class OutputIterator, class Results, class traits, class ForwardIter> >void basic_regex_formatter<OutputIterator, Results, traits, ForwardIter>::put(const sub_match_type& sub) >{ > typedef typename sub_match_type::iterator iterator_type; > iterator_type i = sub.first; > while(i != sub.second) > { > put(*i); > ++i; > } >} > >template <class S> >class string_out_iterator > > : public std::iterator<std::output_iterator_tag, typename S::value_type> > >{ > S* out; >public: > string_out_iterator(S& s) : out(&s) {} > string_out_iterator& operator++() { return *this; } > string_out_iterator& operator++(int) { return *this; } > string_out_iterator& operator*() { return *this; } > string_out_iterator& operator=(typename S::value_type v) > { > out->append(1, v); > return *this; > } ># 826 "/usr/include/boost/regex/v4/regex_format.hpp" 3 4 >}; > >template <class OutputIterator, class Iterator, class Alloc, class ForwardIter, class traits> >OutputIterator regex_format_imp(OutputIterator out, > const match_results<Iterator, Alloc>& m, > ForwardIter p1, ForwardIter p2, > match_flag_type flags, > const traits& t > ) >{ > if(flags & regex_constants::format_literal) > { > return re_detail::copy(p1, p2, out); > } > > re_detail::basic_regex_formatter< > OutputIterator, > match_results<Iterator, Alloc>, > traits, ForwardIter> f(out, m, t); > return f.format(p1, p2, flags); >} > > > >template< typename T, typename fallback_ = boost::mpl::bool_<false> > struct has_const_iterator { struct gcc_3_2_wknd { template< typename U > static boost::mpl::aux::yes_tag test( boost::mpl::aux::type_wrapper<U> const volatile* , boost::mpl::aux::type_wrapper<typename U::const_iterator>* = 0 ); static boost::mpl::aux::no_tag test(...); }; typedef boost::mpl::aux::type_wrapper<T> t_; static const bool value = sizeof(gcc_3_2_wknd::test(static_cast<t_*>(0))) == sizeof(boost::mpl::aux::yes_tag); typedef boost::mpl::bool_<value> type; }; > >struct any_type >{ > template <class T> > any_type(const T&); > template <class T, class U> > any_type(const T&, const U&); > template <class T, class U, class V> > any_type(const T&, const U&, const V&); >}; >typedef char no_type; >typedef char (&unary_type)[2]; >typedef char (&binary_type)[3]; >typedef char (&ternary_type)[4]; > >no_type check_is_formatter(unary_type, binary_type, ternary_type); >template<typename T> >unary_type check_is_formatter(T const &, binary_type, ternary_type); >template<typename T> >binary_type check_is_formatter(unary_type, T const &, ternary_type); >template<typename T, typename U> >binary_type check_is_formatter(T const &, U const &, ternary_type); >template<typename T> >ternary_type check_is_formatter(unary_type, binary_type, T const &); >template<typename T, typename U> >ternary_type check_is_formatter(T const &, binary_type, U const &); >template<typename T, typename U> >ternary_type check_is_formatter(unary_type, T const &, U const &); >template<typename T, typename U, typename V> >ternary_type check_is_formatter(T const &, U const &, V const &); > >struct unary_binary_ternary >{ > typedef unary_type (*unary_fun)(any_type); > typedef binary_type (*binary_fun)(any_type, any_type); > typedef ternary_type (*ternary_fun)(any_type, any_type, any_type); > operator unary_fun(); > operator binary_fun(); > operator ternary_fun(); >}; > >template<typename Formatter, bool IsFunction = boost::is_function<Formatter>::value> >struct formatter_wrapper > : Formatter > , unary_binary_ternary >{ > formatter_wrapper(){} >}; > >template<typename Formatter> >struct formatter_wrapper<Formatter, true> > : unary_binary_ternary >{ > operator Formatter *(); >}; > >template<typename Formatter> >struct formatter_wrapper<Formatter *, false> > : unary_binary_ternary >{ > operator Formatter *(); >}; > >template <class F, class M, class O> >struct format_traits_imp >{ >private: > > > > static_assert((::boost::is_pointer<F>::value || ::boost::is_function<F>::value || ::boost::is_class<F>::value), "(::boost::is_pointer<F>::value || ::boost::is_function<F>::value || ::boost::is_class<F>::value)"); > static formatter_wrapper<typename unwrap_reference<F>::type> f; > static M m; > static O out; > static boost::regex_constants::match_flag_type flags; >public: > static const int value = sizeof(check_is_formatter(f(m), f(m, out), f(m, out, flags))); >}; > >template <class F, class M, class O> >struct format_traits >{ >public: ># 943 "/usr/include/boost/regex/v4/regex_format.hpp" 3 4 > typedef typename boost::mpl::if_< > boost::mpl::and_<boost::is_pointer<F>, boost::mpl::not_<boost::is_function<typename boost::remove_pointer<F>::type> > >, > boost::mpl::int_<0>, > typename boost::mpl::if_< > has_const_iterator<F>, > boost::mpl::int_<1>, > boost::mpl::int_<format_traits_imp<F, M, O>::value> > >::type > >::type type; > > > > > static_assert(boost::is_class<F>::value && !has_const_iterator<F>::value ? (type::value > 1) : true, "boost::is_class<F>::value && !has_const_iterator<F>::value ? (type::value > 1) : true"); >}; ># 983 "/usr/include/boost/regex/v4/regex_format.hpp" 3 4 >template <class Base, class Match> >struct format_functor3 >{ > format_functor3(Base b) : func(b) {} > template <class OutputIter> > OutputIter operator()(const Match& m, OutputIter i, boost::regex_constants::match_flag_type f) > { > return boost::unwrap_ref(func)(m, i, f); > } > template <class OutputIter, class Traits> > OutputIter operator()(const Match& m, OutputIter i, boost::regex_constants::match_flag_type f, const Traits&) > { > return (*this)(m, i, f); > } >private: > Base func; > format_functor3(const format_functor3&); > format_functor3& operator=(const format_functor3&); >}; > >template <class Base, class Match> >struct format_functor2 >{ > format_functor2(Base b) : func(b) {} > template <class OutputIter> > OutputIter operator()(const Match& m, OutputIter i, boost::regex_constants::match_flag_type ) > { > return boost::unwrap_ref(func)(m, i); > } > template <class OutputIter, class Traits> > OutputIter operator()(const Match& m, OutputIter i, boost::regex_constants::match_flag_type f, const Traits&) > { > return (*this)(m, i, f); > } >private: > Base func; > format_functor2(const format_functor2&); > format_functor2& operator=(const format_functor2&); >}; > >template <class Base, class Match> >struct format_functor1 >{ > format_functor1(Base b) : func(b) {} > > template <class S, class OutputIter> > OutputIter do_format_string(const S& s, OutputIter i) > { > return re_detail::copy(s.begin(), s.end(), i); > } > template <class S, class OutputIter> > inline OutputIter do_format_string(const S* s, OutputIter i) > { > while(s && *s) > { > *i = *s; > ++i; > ++s; > } > return i; > } > template <class OutputIter> > OutputIter operator()(const Match& m, OutputIter i, boost::regex_constants::match_flag_type ) > { > return do_format_string(boost::unwrap_ref(func)(m), i); > } > template <class OutputIter, class Traits> > OutputIter operator()(const Match& m, OutputIter i, boost::regex_constants::match_flag_type f, const Traits&) > { > return (*this)(m, i, f); > } >private: > Base func; > format_functor1(const format_functor1&); > format_functor1& operator=(const format_functor1&); >}; > >template <class charT, class Match, class Traits> >struct format_functor_c_string >{ > format_functor_c_string(const charT* ps) : func(ps) {} > > template <class OutputIter> > OutputIter operator()(const Match& m, OutputIter i, boost::regex_constants::match_flag_type f, const Traits& t = Traits()) > { > > const charT* end = func; > while(*end) ++end; > return regex_format_imp(i, m, func, end, f, t); > } >private: > const charT* func; > format_functor_c_string(const format_functor_c_string&); > format_functor_c_string& operator=(const format_functor_c_string&); >}; > >template <class Container, class Match, class Traits> >struct format_functor_container >{ > format_functor_container(const Container& c) : func(c) {} > > template <class OutputIter> > OutputIter operator()(const Match& m, OutputIter i, boost::regex_constants::match_flag_type f, const Traits& t = Traits()) > { > > return re_detail::regex_format_imp(i, m, func.begin(), func.end(), f, t); > } >private: > const Container& func; > format_functor_container(const format_functor_container&); > format_functor_container& operator=(const format_functor_container&); >}; > >template <class Func, class Match, class OutputIterator, class Traits = re_detail::trivial_format_traits<typename Match::char_type> > >struct compute_functor_type >{ > typedef typename format_traits<Func, Match, OutputIterator>::type tag; > typedef typename boost::remove_cv< typename boost::remove_pointer<Func>::type>::type maybe_char_type; > > typedef typename mpl::if_< > ::boost::is_same<tag, mpl::int_<0> >, format_functor_c_string<maybe_char_type, Match, Traits>, > typename mpl::if_< > ::boost::is_same<tag, mpl::int_<1> >, format_functor_container<Func, Match, Traits>, > typename mpl::if_< > ::boost::is_same<tag, mpl::int_<2> >, format_functor1<Func, Match>, > typename mpl::if_< > ::boost::is_same<tag, mpl::int_<3> >, format_functor2<Func, Match>, > format_functor3<Func, Match> > >::type > >::type > >::type > >::type type; >}; > >} > >template <class OutputIterator, class Iterator, class Allocator, class Functor> >inline OutputIterator regex_format(OutputIterator out, > const match_results<Iterator, Allocator>& m, > Functor fmt, > match_flag_type flags = format_all > ) >{ > return m.format(out, fmt, flags); >} > >template <class Iterator, class Allocator, class Functor> >inline std::basic_string<typename match_results<Iterator, Allocator>::char_type> regex_format(const match_results<Iterator, Allocator>& m, > Functor fmt, > match_flag_type flags = format_all) >{ > return m.format(fmt, flags); >} ># 1148 "/usr/include/boost/regex/v4/regex_format.hpp" 3 4 >} ># 80 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/match_results.hpp" 1 3 4 ># 33 "/usr/include/boost/regex/v4/match_results.hpp" 3 4 >namespace boost{ ># 42 "/usr/include/boost/regex/v4/match_results.hpp" 3 4 >namespace re_detail{ > >class named_subexpressions; > >} > >template <class BidiIterator, class Allocator> >class match_results >{ >private: > > typedef std::vector<sub_match<BidiIterator>, Allocator> vector_type; > > > >public: > typedef sub_match<BidiIterator> value_type; > > typedef typename Allocator::const_reference const_reference; > > > > typedef const_reference reference; > typedef typename vector_type::const_iterator const_iterator; > typedef const_iterator iterator; > typedef typename re_detail::regex_iterator_traits< > BidiIterator>::difference_type difference_type; > typedef typename Allocator::size_type size_type; > typedef Allocator allocator_type; > typedef typename re_detail::regex_iterator_traits< > BidiIterator>::value_type char_type; > typedef std::basic_string<char_type> string_type; > typedef re_detail::named_subexpressions named_sub_type; > > > explicit match_results(const Allocator& a = Allocator()) > > : m_subs(a), m_base(), m_last_closed_paren(0), m_is_singular(true) {} > > > > match_results(const match_results& m) > : m_subs(m.m_subs), m_named_subs(m.m_named_subs), m_last_closed_paren(m.m_last_closed_paren), m_is_singular(m.m_is_singular) > { > if(!m_is_singular) > { > m_base = m.m_base; > m_null = m.m_null; > } > } > match_results& operator=(const match_results& m) > { > m_subs = m.m_subs; > m_named_subs = m.m_named_subs; > m_last_closed_paren = m.m_last_closed_paren; > m_is_singular = m.m_is_singular; > if(!m_is_singular) > { > m_base = m.m_base; > m_null = m.m_null; > } > return *this; > } > ~match_results(){} > > > size_type size() const > { return empty() ? 0 : m_subs.size() - 2; } > size_type max_size() const > { return m_subs.max_size(); } > bool empty() const > { return m_subs.size() < 2; } > > difference_type length(int sub = 0) const > { > if(m_is_singular) > raise_logic_error(); > sub += 2; > if((sub < (int)m_subs.size()) && (sub > 0)) > return m_subs[sub].length(); > return 0; > } > difference_type length(const char_type* sub) const > { > if(m_is_singular) > raise_logic_error(); > const char_type* sub_end = sub; > while(*sub_end) ++sub_end; > return length(named_subexpression_index(sub, sub_end)); > } > template <class charT> > difference_type length(const charT* sub) const > { > if(m_is_singular) > raise_logic_error(); > const charT* sub_end = sub; > while(*sub_end) ++sub_end; > return length(named_subexpression_index(sub, sub_end)); > } > template <class charT, class Traits, class A> > difference_type length(const std::basic_string<charT, Traits, A>& sub) const > { > return length(sub.c_str()); > } > difference_type position(size_type sub = 0) const > { > if(m_is_singular) > raise_logic_error(); > sub += 2; > if(sub < m_subs.size()) > { > const sub_match<BidiIterator>& s = m_subs[sub]; > if(s.matched || (sub == 2)) > { > return ::boost::re_detail::distance((BidiIterator)(m_base), (BidiIterator)(s.first)); > } > } > return ~static_cast<difference_type>(0); > } > difference_type position(const char_type* sub) const > { > const char_type* sub_end = sub; > while(*sub_end) ++sub_end; > return position(named_subexpression_index(sub, sub_end)); > } > template <class charT> > difference_type position(const charT* sub) const > { > const charT* sub_end = sub; > while(*sub_end) ++sub_end; > return position(named_subexpression_index(sub, sub_end)); > } > template <class charT, class Traits, class A> > difference_type position(const std::basic_string<charT, Traits, A>& sub) const > { > return position(sub.c_str()); > } > string_type str(int sub = 0) const > { > if(m_is_singular) > raise_logic_error(); > sub += 2; > string_type result; > if(sub < (int)m_subs.size() && (sub > 0)) > { > const sub_match<BidiIterator>& s = m_subs[sub]; > if(s.matched) > { > result = s.str(); > } > } > return result; > } > string_type str(const char_type* sub) const > { > return (*this)[sub].str(); > } > template <class Traits, class A> > string_type str(const std::basic_string<char_type, Traits, A>& sub) const > { > return (*this)[sub].str(); > } > template <class charT> > string_type str(const charT* sub) const > { > return (*this)[sub].str(); > } > template <class charT, class Traits, class A> > string_type str(const std::basic_string<charT, Traits, A>& sub) const > { > return (*this)[sub].str(); > } > const_reference operator[](int sub) const > { > if(m_is_singular && m_subs.empty()) > raise_logic_error(); > sub += 2; > if(sub < (int)m_subs.size() && (sub >= 0)) > { > return m_subs[sub]; > } > return m_null; > } > > > > const_reference named_subexpression(const char_type* i, const char_type* j) const > { > > > > if(m_is_singular) > raise_logic_error(); > re_detail::named_subexpressions::range_type r = m_named_subs->equal_range(i, j); > while((r.first != r.second) && ((*this)[r.first->index].matched == false)) > ++r.first; > return r.first != r.second ? (*this)[r.first->index] : m_null; > } > template <class charT> > const_reference named_subexpression(const charT* i, const charT* j) const > { > static_assert(sizeof(charT) <= sizeof(char_type), "sizeof(charT) <= sizeof(char_type)"); > if(i == j) > return m_null; > std::vector<char_type> s; > while(i != j) > s.insert(s.end(), *i++); > return named_subexpression(&*s.begin(), &*s.begin() + s.size()); > } > int named_subexpression_index(const char_type* i, const char_type* j) const > { > > > > > > if(m_is_singular) > raise_logic_error(); > re_detail::named_subexpressions::range_type s, r; > s = r = m_named_subs->equal_range(i, j); > while((r.first != r.second) && ((*this)[r.first->index].matched == false)) > ++r.first; > if(r.first == r.second) > r = s; > return r.first != r.second ? r.first->index : -20; > } > template <class charT> > int named_subexpression_index(const charT* i, const charT* j) const > { > static_assert(sizeof(charT) <= sizeof(char_type), "sizeof(charT) <= sizeof(char_type)"); > if(i == j) > return -20; > std::vector<char_type> s; > while(i != j) > s.insert(s.end(), *i++); > return named_subexpression_index(&*s.begin(), &*s.begin() + s.size()); > } > template <class Traits, class A> > const_reference operator[](const std::basic_string<char_type, Traits, A>& s) const > { > return named_subexpression(s.c_str(), s.c_str() + s.size()); > } > const_reference operator[](const char_type* p) const > { > const char_type* e = p; > while(*e) ++e; > return named_subexpression(p, e); > } > > template <class charT> > const_reference operator[](const charT* p) const > { > static_assert(sizeof(charT) <= sizeof(char_type), "sizeof(charT) <= sizeof(char_type)"); > if(*p == 0) > return m_null; > std::vector<char_type> s; > while(*p) > s.insert(s.end(), *p++); > return named_subexpression(&*s.begin(), &*s.begin() + s.size()); > } > template <class charT, class Traits, class A> > const_reference operator[](const std::basic_string<charT, Traits, A>& ns) const > { > static_assert(sizeof(charT) <= sizeof(char_type), "sizeof(charT) <= sizeof(char_type)"); > if(ns.empty()) > return m_null; > std::vector<char_type> s; > for(unsigned i = 0; i < ns.size(); ++i) > s.insert(s.end(), ns[i]); > return named_subexpression(&*s.begin(), &*s.begin() + s.size()); > } > > const_reference prefix() const > { > if(m_is_singular) > raise_logic_error(); > return (*this)[-1]; > } > > const_reference suffix() const > { > if(m_is_singular) > raise_logic_error(); > return (*this)[-2]; > } > const_iterator begin() const > { > return (m_subs.size() > 2) ? (m_subs.begin() + 2) : m_subs.end(); > } > const_iterator end() const > { > return m_subs.end(); > } > > template <class OutputIterator, class Functor> > OutputIterator format(OutputIterator out, > Functor fmt, > match_flag_type flags = format_default) const > { > if(m_is_singular) > raise_logic_error(); > typedef typename re_detail::compute_functor_type<Functor, match_results<BidiIterator, Allocator>, OutputIterator>::type F; > F func(fmt); > return func(*this, out, flags); > } > template <class Functor> > string_type format(Functor fmt, match_flag_type flags = format_default) const > { > if(m_is_singular) > raise_logic_error(); > std::basic_string<char_type> result; > re_detail::string_out_iterator<std::basic_string<char_type> > i(result); > > typedef typename re_detail::compute_functor_type<Functor, match_results<BidiIterator, Allocator>, re_detail::string_out_iterator<std::basic_string<char_type> > >::type F; > F func(fmt); > > func(*this, i, flags); > return result; > } > > template <class OutputIterator, class Functor, class RegexT> > OutputIterator format(OutputIterator out, > Functor fmt, > match_flag_type flags, > const RegexT& re) const > { > if(m_is_singular) > raise_logic_error(); > typedef ::boost::regex_traits_wrapper<typename RegexT::traits_type> traits_type; > typedef typename re_detail::compute_functor_type<Functor, match_results<BidiIterator, Allocator>, OutputIterator, traits_type>::type F; > F func(fmt); > return func(*this, out, flags, re.get_traits()); > } > template <class RegexT, class Functor> > string_type format(Functor fmt, > match_flag_type flags, > const RegexT& re) const > { > if(m_is_singular) > raise_logic_error(); > typedef ::boost::regex_traits_wrapper<typename RegexT::traits_type> traits_type; > std::basic_string<char_type> result; > re_detail::string_out_iterator<std::basic_string<char_type> > i(result); > > typedef typename re_detail::compute_functor_type<Functor, match_results<BidiIterator, Allocator>, re_detail::string_out_iterator<std::basic_string<char_type> >, traits_type >::type F; > F func(fmt); > > func(*this, i, flags, re.get_traits()); > return result; > } > > const_reference get_last_closed_paren()const > { > if(m_is_singular) > raise_logic_error(); > return m_last_closed_paren == 0 ? m_null : (*this)[m_last_closed_paren]; > } > > allocator_type get_allocator() const > { > > return m_subs.get_allocator(); > > > > } > void swap(match_results& that) > { > std::swap(m_subs, that.m_subs); > std::swap(m_named_subs, that.m_named_subs); > std::swap(m_last_closed_paren, that.m_last_closed_paren); > if(m_is_singular) > { > if(!that.m_is_singular) > { > m_base = that.m_base; > m_null = that.m_null; > } > } > else if(that.m_is_singular) > { > that.m_base = m_base; > that.m_null = m_null; > } > else > { > std::swap(m_base, that.m_base); > std::swap(m_null, that.m_null); > } > std::swap(m_is_singular, that.m_is_singular); > } > bool operator==(const match_results& that)const > { > if(m_is_singular) > { > return that.m_is_singular; > } > else if(that.m_is_singular) > { > return false; > } > return (m_subs == that.m_subs) && (m_base == that.m_base) && (m_last_closed_paren == that.m_last_closed_paren); > } > bool operator!=(const match_results& that)const > { return !(*this == that); } ># 461 "/usr/include/boost/regex/v4/match_results.hpp" 3 4 > void set_second(BidiIterator i) > { > (static_cast<void> (0)); > m_subs[2].second = i; > m_subs[2].matched = true; > m_subs[0].first = i; > m_subs[0].matched = (m_subs[0].first != m_subs[0].second); > m_null.first = i; > m_null.second = i; > m_null.matched = false; > m_is_singular = false; > } > > void set_second(BidiIterator i, size_type pos, bool m = true, bool escape_k = false) > { > if(pos) > m_last_closed_paren = static_cast<int>(pos); > pos += 2; > (static_cast<void> (0)); > m_subs[pos].second = i; > m_subs[pos].matched = m; > if((pos == 2) && !escape_k) > { > m_subs[0].first = i; > m_subs[0].matched = (m_subs[0].first != m_subs[0].second); > m_null.first = i; > m_null.second = i; > m_null.matched = false; > m_is_singular = false; > } > } > void set_size(size_type n, BidiIterator i, BidiIterator j) > { > value_type v(j); > size_type len = m_subs.size(); > if(len > n + 2) > { > m_subs.erase(m_subs.begin()+n+2, m_subs.end()); > std::fill(m_subs.begin(), m_subs.end(), v); > } > else > { > std::fill(m_subs.begin(), m_subs.end(), v); > if(n+2 != len) > m_subs.insert(m_subs.end(), n+2-len, v); > } > m_subs[1].first = i; > m_last_closed_paren = 0; > } > void set_base(BidiIterator pos) > { > m_base = pos; > } > BidiIterator base()const > { > return m_base; > } > void set_first(BidiIterator i) > { > (static_cast<void> (0)); > > m_subs[1].second = i; > m_subs[1].matched = (m_subs[1].first != i); > > m_subs[2].first = i; > > for(size_type n = 3; n < m_subs.size(); ++n) > { > m_subs[n].first = m_subs[n].second = m_subs[0].second; > m_subs[n].matched = false; > } > } > void set_first(BidiIterator i, size_type pos, bool escape_k = false) > { > (static_cast<void> (0)); > if(pos || escape_k) > { > m_subs[pos+2].first = i; > if(escape_k) > { > m_subs[1].second = i; > m_subs[1].matched = (m_subs[1].first != m_subs[1].second); > } > } > else > set_first(i); > } > void maybe_assign(const match_results<BidiIterator, Allocator>& m); > > void set_named_subs(boost::shared_ptr<named_sub_type> subs) > { > m_named_subs = subs; > } > >private: > > > > static void raise_logic_error() > { > std::logic_error e("Attempt to access an uninitialzed boost::match_results<> class."); > boost::throw_exception(e); > } > > > vector_type m_subs; > BidiIterator m_base; > sub_match<BidiIterator> m_null; > boost::shared_ptr<named_sub_type> m_named_subs; > int m_last_closed_paren; > bool m_is_singular; >}; > >template <class BidiIterator, class Allocator> >void match_results<BidiIterator, Allocator>::maybe_assign(const match_results<BidiIterator, Allocator>& m) >{ > if(m_is_singular) > { > *this = m; > return; > } > const_iterator p1, p2; > p1 = begin(); > p2 = m.begin(); ># 595 "/usr/include/boost/regex/v4/match_results.hpp" 3 4 > BidiIterator l_end = this->suffix().second; > BidiIterator l_base = (p1->first == l_end) ? this->prefix().first : (*this)[0].first; > difference_type len1 = 0; > difference_type len2 = 0; > difference_type base1 = 0; > difference_type base2 = 0; > std::size_t i; > for(i = 0; i < size(); ++i, ++p1, ++p2) > { > > > > > > > > if(p1->first == l_end) > { > if(p2->first != l_end) > { > > > base1 = 1; > base2 = 0; > break; > } > else > { > > > if((p1->matched == false) && (p2->matched == true)) > break; > if((p1->matched == true) && (p2->matched == false)) > return; > continue; > } > } > else if(p2->first == l_end) > { > > return; > } > base1 = ::boost::re_detail::distance(l_base, p1->first); > base2 = ::boost::re_detail::distance(l_base, p2->first); > (static_cast<void> (0)); > (static_cast<void> (0)); > if(base1 < base2) return; > if(base2 < base1) break; > > len1 = ::boost::re_detail::distance((BidiIterator)p1->first, (BidiIterator)p1->second); > len2 = ::boost::re_detail::distance((BidiIterator)p2->first, (BidiIterator)p2->second); > (static_cast<void> (0)); > (static_cast<void> (0)); > if((len1 != len2) || ((p1->matched == false) && (p2->matched == true))) > break; > if((p1->matched == true) && (p2->matched == false)) > return; > } > if(i == size()) > return; > if(base2 < base1) > *this = m; > else if((len2 > len1) || ((p1->matched == false) && (p2->matched == true)) ) > *this = m; >} > >template <class BidiIterator, class Allocator> >void swap(match_results<BidiIterator, Allocator>& a, match_results<BidiIterator, Allocator>& b) >{ > a.swap(b); >} > > >template <class charT, class traits, class BidiIterator, class Allocator> >std::basic_ostream<charT, traits>& > operator << (std::basic_ostream<charT, traits>& os, > const match_results<BidiIterator, Allocator>& s) >{ > return (os << s.str()); >} ># 687 "/usr/include/boost/regex/v4/match_results.hpp" 3 4 >} ># 83 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/protected_call.hpp" 1 3 4 ># 34 "/usr/include/boost/regex/v4/protected_call.hpp" 3 4 >namespace boost{ >namespace re_detail{ > >class abstract_protected_call >{ >public: > bool execute()const; > > virtual ~abstract_protected_call(){} >private: > virtual bool call()const = 0; >}; > >template <class T> >class concrete_protected_call > : public abstract_protected_call >{ >public: > typedef bool (T::*proc_type)(); > concrete_protected_call(T* o, proc_type p) > : obj(o), proc(p) {} >private: > virtual bool call()const; > T* obj; > proc_type proc; >}; > >template <class T> >bool concrete_protected_call<T>::call()const >{ > return (obj->*proc)(); >} > >} >} ># 86 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/perl_matcher.hpp" 1 3 4 ># 15 "/usr/include/boost/regex/v4/perl_matcher.hpp" 3 4 ># 1 "/usr/include/boost/regex/v4/iterator_category.hpp" 1 3 4 ># 28 "/usr/include/boost/regex/v4/iterator_category.hpp" 3 4 >namespace boost{ >namespace detail{ > >template <class I> >struct is_random_imp >{ > >private: > typedef typename std::iterator_traits<I>::iterator_category cat; >public: > static const bool value = (::boost::is_convertible<cat*, std::random_access_iterator_tag*>::value); > > > >}; > >template <class I> >struct is_random_pointer_imp >{ > static const bool value = true; >}; > >template <bool is_pointer_type> >struct is_random_imp_selector >{ > template <class I> > struct rebind > { > typedef is_random_imp<I> type; > }; >}; > >template <> >struct is_random_imp_selector<true> >{ > template <class I> > struct rebind > { > typedef is_random_pointer_imp<I> type; > }; >}; > >} > >template <class I> >struct is_random_access_iterator >{ >private: > typedef detail::is_random_imp_selector< ::boost::is_pointer<I>::value> selector; > typedef typename selector::template rebind<I> bound_type; > typedef typename bound_type::type answer; >public: > static const bool value = answer::value; >}; > > >template <class I> >const bool is_random_access_iterator<I>::value; > > >} ># 16 "/usr/include/boost/regex/v4/perl_matcher.hpp" 2 3 4 ># 33 "/usr/include/boost/regex/v4/perl_matcher.hpp" 3 4 >namespace boost{ >namespace re_detail{ > > > > > void verify_options(boost::regex_constants::syntax_option_type ef, match_flag_type mf); > > > >template <class charT> >inline bool can_start(charT c, const unsigned char* map, unsigned char mask) >{ > return ((c < static_cast<charT>(0)) ? true : ((c >= static_cast<charT>(1 << 8)) ? true : map[c] & mask)); >} >inline bool can_start(char c, const unsigned char* map, unsigned char mask) >{ > return map[(unsigned char)c] & mask; >} >inline bool can_start(signed char c, const unsigned char* map, unsigned char mask) >{ > return map[(unsigned char)c] & mask; >} >inline bool can_start(unsigned char c, const unsigned char* map, unsigned char mask) >{ > return map[c] & mask; >} >inline bool can_start(unsigned short c, const unsigned char* map, unsigned char mask) >{ > return ((c >= (1 << 8)) ? true : map[c] & mask); >} ># 73 "/usr/include/boost/regex/v4/perl_matcher.hpp" 3 4 >inline bool can_start(unsigned int c, const unsigned char* map, unsigned char mask) >{ > return (((c >= static_cast<unsigned int>(1u << 8)) ? true : map[c] & mask)); >} ># 90 "/usr/include/boost/regex/v4/perl_matcher.hpp" 3 4 >template <class C, class T, class A> >inline int string_compare(const std::basic_string<C,T,A>& s, const C* p) >{ > if(0 == *p) > { > if(s.empty() || ((s.size() == 1) && (s[0] == 0))) > return 0; > } > return s.compare(p); >} ># 121 "/usr/include/boost/regex/v4/perl_matcher.hpp" 3 4 >template <class Seq, class C> >inline int string_compare(const Seq& s, const C* p) >{ > std::size_t i = 0; > while((i < s.size()) && (p[i] == s[i])) > { > ++i; > } > return (i == s.size()) ? -p[i] : s[i] - p[i]; >} > > >template<class charT> >inline const charT* re_skip_past_null(const charT* p) >{ > while (*p != static_cast<charT>(0)) ++p; > return ++p; >} > >template <class iterator, class charT, class traits_type, class char_classT> >iterator re_is_set_member(iterator next, > iterator last, > const re_set_long<char_classT>* set_, > const regex_data<charT, traits_type>& e, bool icase) >{ > const charT* p = reinterpret_cast<const charT*>(set_+1); > iterator ptr; > unsigned int i; > > > if(next == last) return next; > > typedef typename traits_type::string_type traits_string_type; > const ::boost::regex_traits_wrapper<traits_type>& traits_inst = *(e.m_ptraits); > > > > (void)traits_inst; > > > > for(i = 0; i < set_->csingles; ++i) > { > ptr = next; > if(*p == static_cast<charT>(0)) > { > > if(traits_inst.translate(*ptr, icase) != *p) > { > while(*p == static_cast<charT>(0))++p; > continue; > } > return set_->isnot ? next : (ptr == next) ? ++next : ptr; > } > else > { > while(*p && (ptr != last)) > { > if(traits_inst.translate(*ptr, icase) != *p) > break; > ++p; > ++ptr; > } > > if(*p == static_cast<charT>(0)) > return set_->isnot ? next : (ptr == next) ? ++next : ptr; > > p = re_skip_past_null(p); > } > } > > charT col = traits_inst.translate(*next, icase); > > > if(set_->cranges || set_->cequivalents) > { > traits_string_type s1; > > > if(set_->cranges) > { > if((e.m_flags & regex_constants::collate) == 0) > s1.assign(1, col); > else > { > charT a[2] = { col, charT(0), }; > s1 = traits_inst.transform(a, a + 1); > } > for(i = 0; i < set_->cranges; ++i) > { > if(string_compare(s1,p) >= 0) > { > do{ ++p; }while(*p); > ++p; > if(string_compare(s1,p) <= 0) > return set_->isnot ? next : ++next; > } > else > { > > do{ ++p; }while(*p); > ++p; > } > > do{ ++p; }while(*p); > ++p; > } > } > > > if(set_->cequivalents) > { > charT a[2] = { col, charT(0), }; > s1 = traits_inst.transform_primary(a, a +1); > for(i = 0; i < set_->cequivalents; ++i) > { > if(string_compare(s1,p) == 0) > return set_->isnot ? next : ++next; > > do{ ++p; }while(*p); > ++p; > } > } > } > if(traits_inst.isctype(col, set_->cclasses) == true) > return set_->isnot ? next : ++next; > if((set_->cnclasses != 0) && (traits_inst.isctype(col, set_->cnclasses) == false)) > return set_->isnot ? next : ++next; > return set_->isnot ? ++next : next; >} > >template <class BidiIterator> >class repeater_count >{ > repeater_count** stack; > repeater_count* next; > int state_id; > std::size_t count; > BidiIterator start_pos; >public: > repeater_count(repeater_count** s) > { > stack = s; > next = 0; > state_id = -1; > count = 0; > } > repeater_count(int i, repeater_count** s, BidiIterator start) > : start_pos(start) > { > state_id = i; > stack = s; > next = *stack; > *stack = this; > if(state_id > next->state_id) > count = 0; > else > { > repeater_count* p = next; > while(p && (p->state_id != state_id)) > p = p->next; > if(p) > { > count = p->count; > start_pos = p->start_pos; > } > else > count = 0; > } > } > ~repeater_count() > { > if(next) > *stack = next; > } > std::size_t get_count() { return count; } > int get_id() { return state_id; } > std::size_t operator++() { return ++count; } > bool check_null_repeat(const BidiIterator& pos, std::size_t max) > { > > > > bool result = (count == 0) ? false : (pos == start_pos); > if(result) > count = max; > else > start_pos = pos; > return result; > } >}; > >struct saved_state; > >enum saved_state_type >{ > saved_type_end = 0, > saved_type_paren = 1, > saved_type_recurse = 2, > saved_type_assertion = 3, > saved_state_alt = 4, > saved_state_repeater_count = 5, > saved_state_extra_block = 6, > saved_state_greedy_single_repeat = 7, > saved_state_rep_slow_dot = 8, > saved_state_rep_fast_dot = 9, > saved_state_rep_char = 10, > saved_state_rep_short_set = 11, > saved_state_rep_long_set = 12, > saved_state_non_greedy_long_repeat = 13, > saved_state_count = 14 >}; > >template <class Results> >struct recursion_info >{ > typedef typename Results::value_type value_type; > typedef typename value_type::iterator iterator; > int idx; > const re_syntax_base* preturn_address; > Results results; > repeater_count<iterator>* repeater_stack; >}; ># 353 "/usr/include/boost/regex/v4/perl_matcher.hpp" 3 4 >template <class BidiIterator, class Allocator, class traits> >class perl_matcher >{ >public: > typedef typename traits::char_type char_type; > typedef perl_matcher<BidiIterator, Allocator, traits> self_type; > typedef bool (self_type::*matcher_proc_type)(void); > typedef std::size_t traits_size_type; > typedef typename is_byte<char_type>::width_type width_type; > typedef typename regex_iterator_traits<BidiIterator>::difference_type difference_type; > typedef match_results<BidiIterator, Allocator> results_type; > > perl_matcher(BidiIterator first, BidiIterator end, > match_results<BidiIterator, Allocator>& what, > const basic_regex<char_type, traits>& e, > match_flag_type f, > BidiIterator l_base) > : m_result(what), base(first), last(end), > position(first), backstop(l_base), re(e), traits_inst(e.get_traits()), > m_independent(false), next_count(&rep_obj), rep_obj(&next_count) > { > construct_init(e, f); > } > > bool match(); > bool find(); > > void setf(match_flag_type f) > { m_match_flags |= f; } > void unsetf(match_flag_type f) > { m_match_flags &= ~f; } > >private: > void construct_init(const basic_regex<char_type, traits>& e, match_flag_type f); > > bool find_imp(); > bool match_imp(); > > > > > void estimate_max_state_count(std::random_access_iterator_tag*); > void estimate_max_state_count(void*); > bool match_prefix(); > bool match_all_states(); > > > bool match_startmark(); > bool match_endmark(); > bool match_literal(); > bool match_start_line(); > bool match_end_line(); > bool match_wild(); > bool match_match(); > bool match_word_boundary(); > bool match_within_word(); > bool match_word_start(); > bool match_word_end(); > bool match_buffer_start(); > bool match_buffer_end(); > bool match_backref(); > bool match_long_set(); > bool match_set(); > bool match_jump(); > bool match_alt(); > bool match_rep(); > bool match_combining(); > bool match_soft_buffer_end(); > bool match_restart_continue(); > bool match_long_set_repeat(); > bool match_set_repeat(); > bool match_char_repeat(); > bool match_dot_repeat_fast(); > bool match_dot_repeat_slow(); > bool match_dot_repeat_dispatch() > { > return ::boost::is_random_access_iterator<BidiIterator>::value ? match_dot_repeat_fast() : match_dot_repeat_slow(); > } > bool match_backstep(); > bool match_assert_backref(); > bool match_toggle_case(); > > > > bool match_recursion(); > > > bool find_restart_any(); > bool find_restart_word(); > bool find_restart_line(); > bool find_restart_buf(); > bool find_restart_lit(); > >private: > > match_results<BidiIterator, Allocator>& m_result; > > scoped_ptr<match_results<BidiIterator, Allocator> > m_temp_match; > > match_results<BidiIterator, Allocator>* m_presult; > > BidiIterator base; > > BidiIterator last; > > BidiIterator position; > > BidiIterator restart; > > BidiIterator search_base; > > BidiIterator backstop; > > const basic_regex<char_type, traits>& re; > > const ::boost::regex_traits_wrapper<traits>& traits_inst; > > const re_syntax_base* pstate; > > match_flag_type m_match_flags; > > std::ptrdiff_t state_count; > > std::ptrdiff_t max_state_count; > > bool icase; > > bool m_has_partial_match; > > bool m_has_found_match; > > bool m_independent; > > repeater_count<BidiIterator>* next_count; > > repeater_count<BidiIterator> rep_obj; > > typename traits::char_class_type m_word_mask; > > unsigned char match_any_mask; > > std::vector<recursion_info<results_type> > recursion_stack; > > > > > > typedef bool (self_type::*unwind_proc_type)(bool); > > void extend_stack(); > bool unwind(bool); > bool unwind_end(bool); > bool unwind_paren(bool); > bool unwind_recursion_stopper(bool); > bool unwind_assertion(bool); > bool unwind_alt(bool); > bool unwind_repeater_counter(bool); > bool unwind_extra_block(bool); > bool unwind_greedy_single_repeat(bool); > bool unwind_slow_dot_repeat(bool); > bool unwind_fast_dot_repeat(bool); > bool unwind_char_repeat(bool); > bool unwind_short_set_repeat(bool); > bool unwind_long_set_repeat(bool); > bool unwind_non_greedy_repeat(bool); > bool unwind_recursion(bool); > bool unwind_recursion_pop(bool); > void destroy_single_repeat(); > void push_matched_paren(int index, const sub_match<BidiIterator>& sub); > void push_recursion_stopper(); > void push_assertion(const re_syntax_base* ps, bool positive); > void push_alt(const re_syntax_base* ps); > void push_repeater_count(int i, repeater_count<BidiIterator>** s); > void push_single_repeat(std::size_t c, const re_repeat* r, BidiIterator last_position, int state_id); > void push_non_greedy_repeat(const re_syntax_base* ps); > void push_recursion(int idx, const re_syntax_base* p, results_type* presults); > void push_recursion_pop(); > > > saved_state* m_stack_base; > > saved_state* m_backup_state; > > > bool m_recursive_result; > > unsigned used_block_count; > > > > > perl_matcher& operator=(const perl_matcher&) > { > return *this; > } > perl_matcher(const perl_matcher& that) > : m_result(that.m_result), re(that.re), traits_inst(that.traits_inst), rep_obj(0) {} >}; > > > > > >} ># 569 "/usr/include/boost/regex/v4/perl_matcher.hpp" 3 4 >} ># 581 "/usr/include/boost/regex/v4/perl_matcher.hpp" 3 4 ># 1 "/usr/include/boost/regex/v4/perl_matcher_non_recursive.hpp" 1 3 4 ># 40 "/usr/include/boost/regex/v4/perl_matcher_non_recursive.hpp" 3 4 >namespace boost{ >namespace re_detail{ > >template <class T> >inline void inplace_destroy(T* p) >{ > (void)p; > p->~T(); >} > >struct saved_state >{ > union{ > unsigned int state_id; > > std::size_t padding1; > std::ptrdiff_t padding2; > void* padding3; > }; > saved_state(unsigned i) : state_id(i) {} >}; > >template <class BidiIterator> >struct saved_matched_paren : public saved_state >{ > int index; > sub_match<BidiIterator> sub; > saved_matched_paren(int i, const sub_match<BidiIterator>& s) : saved_state(1), index(i), sub(s){}; >}; > >template <class BidiIterator> >struct saved_position : public saved_state >{ > const re_syntax_base* pstate; > BidiIterator position; > saved_position(const re_syntax_base* ps, BidiIterator pos, int i) : saved_state(i), pstate(ps), position(pos){}; >}; > >template <class BidiIterator> >struct saved_assertion : public saved_position<BidiIterator> >{ > bool positive; > saved_assertion(bool p, const re_syntax_base* ps, BidiIterator pos) > : saved_position<BidiIterator>(ps, pos, saved_type_assertion), positive(p){}; >}; > >template <class BidiIterator> >struct saved_repeater : public saved_state >{ > repeater_count<BidiIterator> count; > saved_repeater(int i, repeater_count<BidiIterator>** s, BidiIterator start) > : saved_state(saved_state_repeater_count), count(i,s,start){} >}; > >struct saved_extra_block : public saved_state >{ > saved_state *base, *end; > saved_extra_block(saved_state* b, saved_state* e) > : saved_state(saved_state_extra_block), base(b), end(e) {} >}; > >struct save_state_init >{ > saved_state** stack; > save_state_init(saved_state** base, saved_state** end) > : stack(base) > { > *base = static_cast<saved_state*>(get_mem_block()); > *end = reinterpret_cast<saved_state*>(reinterpret_cast<char*>(*base)+4096); > --(*end); > (void) new (*end)saved_state(0); > (static_cast<void> (0)); > } > ~save_state_init() > { > put_mem_block(*stack); > *stack = 0; > } >}; > >template <class BidiIterator> >struct saved_single_repeat : public saved_state >{ > std::size_t count; > const re_repeat* rep; > BidiIterator last_position; > saved_single_repeat(std::size_t c, const re_repeat* r, BidiIterator lp, int arg_id) > : saved_state(arg_id), count(c), rep(r), last_position(lp){} >}; > >template <class Results> >struct saved_recursion : public saved_state >{ > saved_recursion(int idx, const re_syntax_base* p, Results* pr) > : saved_state(14), recursion_id(idx), preturn_address(p), results(*pr) > {} > int recursion_id; > const re_syntax_base* preturn_address; > Results results; >}; > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_all_states() >{ > static matcher_proc_type const s_match_vtable[30] = > { > (&perl_matcher<BidiIterator, Allocator, traits>::match_startmark), > &perl_matcher<BidiIterator, Allocator, traits>::match_endmark, > &perl_matcher<BidiIterator, Allocator, traits>::match_literal, > &perl_matcher<BidiIterator, Allocator, traits>::match_start_line, > &perl_matcher<BidiIterator, Allocator, traits>::match_end_line, > &perl_matcher<BidiIterator, Allocator, traits>::match_wild, > &perl_matcher<BidiIterator, Allocator, traits>::match_match, > &perl_matcher<BidiIterator, Allocator, traits>::match_word_boundary, > &perl_matcher<BidiIterator, Allocator, traits>::match_within_word, > &perl_matcher<BidiIterator, Allocator, traits>::match_word_start, > &perl_matcher<BidiIterator, Allocator, traits>::match_word_end, > &perl_matcher<BidiIterator, Allocator, traits>::match_buffer_start, > &perl_matcher<BidiIterator, Allocator, traits>::match_buffer_end, > &perl_matcher<BidiIterator, Allocator, traits>::match_backref, > &perl_matcher<BidiIterator, Allocator, traits>::match_long_set, > &perl_matcher<BidiIterator, Allocator, traits>::match_set, > &perl_matcher<BidiIterator, Allocator, traits>::match_jump, > &perl_matcher<BidiIterator, Allocator, traits>::match_alt, > &perl_matcher<BidiIterator, Allocator, traits>::match_rep, > &perl_matcher<BidiIterator, Allocator, traits>::match_combining, > &perl_matcher<BidiIterator, Allocator, traits>::match_soft_buffer_end, > &perl_matcher<BidiIterator, Allocator, traits>::match_restart_continue, > > > > > &perl_matcher<BidiIterator, Allocator, traits>::match_dot_repeat_dispatch, > &perl_matcher<BidiIterator, Allocator, traits>::match_char_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::match_set_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::match_long_set_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::match_backstep, > &perl_matcher<BidiIterator, Allocator, traits>::match_assert_backref, > &perl_matcher<BidiIterator, Allocator, traits>::match_toggle_case, > &perl_matcher<BidiIterator, Allocator, traits>::match_recursion, > }; > > push_recursion_stopper(); > do{ > while(pstate) > { > matcher_proc_type proc = s_match_vtable[pstate->type]; > ++state_count; > if(!(this->*proc)()) > { > if(state_count > max_state_count) > raise_error(traits_inst, regex_constants::error_complexity); > if((m_match_flags & match_partial) && (position == last) && (position != search_base)) > m_has_partial_match = true; > bool successful_unwind = unwind(false); > if((m_match_flags & match_partial) && (position == last) && (position != search_base)) > m_has_partial_match = true; > if(false == successful_unwind) > return m_recursive_result; > } > } > }while(unwind(true)); > return m_recursive_result; >} > >template <class BidiIterator, class Allocator, class traits> >void perl_matcher<BidiIterator, Allocator, traits>::extend_stack() >{ > if(used_block_count) > { > --used_block_count; > saved_state* stack_base; > saved_state* backup_state; > stack_base = static_cast<saved_state*>(get_mem_block()); > backup_state = reinterpret_cast<saved_state*>(reinterpret_cast<char*>(stack_base)+4096); > saved_extra_block* block = static_cast<saved_extra_block*>(backup_state); > --block; > (void) new (block) saved_extra_block(m_stack_base, m_backup_state); > m_stack_base = stack_base; > m_backup_state = block; > } > else > raise_error(traits_inst, regex_constants::error_stack); >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::push_matched_paren(int index, const sub_match<BidiIterator>& sub) >{ > > saved_matched_paren<BidiIterator>* pmp = static_cast<saved_matched_paren<BidiIterator>*>(m_backup_state); > --pmp; > if(pmp < m_stack_base) > { > extend_stack(); > pmp = static_cast<saved_matched_paren<BidiIterator>*>(m_backup_state); > --pmp; > } > (void) new (pmp)saved_matched_paren<BidiIterator>(index, sub); > m_backup_state = pmp; >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::push_recursion_stopper() >{ > saved_state* pmp = m_backup_state; > --pmp; > if(pmp < m_stack_base) > { > extend_stack(); > pmp = m_backup_state; > --pmp; > } > (void) new (pmp)saved_state(saved_type_recurse); > m_backup_state = pmp; >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::push_assertion(const re_syntax_base* ps, bool positive) >{ > saved_assertion<BidiIterator>* pmp = static_cast<saved_assertion<BidiIterator>*>(m_backup_state); > --pmp; > if(pmp < m_stack_base) > { > extend_stack(); > pmp = static_cast<saved_assertion<BidiIterator>*>(m_backup_state); > --pmp; > } > (void) new (pmp)saved_assertion<BidiIterator>(positive, ps, position); > m_backup_state = pmp; >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::push_alt(const re_syntax_base* ps) >{ > saved_position<BidiIterator>* pmp = static_cast<saved_position<BidiIterator>*>(m_backup_state); > --pmp; > if(pmp < m_stack_base) > { > extend_stack(); > pmp = static_cast<saved_position<BidiIterator>*>(m_backup_state); > --pmp; > } > (void) new (pmp)saved_position<BidiIterator>(ps, position, saved_state_alt); > m_backup_state = pmp; >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::push_non_greedy_repeat(const re_syntax_base* ps) >{ > saved_position<BidiIterator>* pmp = static_cast<saved_position<BidiIterator>*>(m_backup_state); > --pmp; > if(pmp < m_stack_base) > { > extend_stack(); > pmp = static_cast<saved_position<BidiIterator>*>(m_backup_state); > --pmp; > } > (void) new (pmp)saved_position<BidiIterator>(ps, position, saved_state_non_greedy_long_repeat); > m_backup_state = pmp; >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::push_repeater_count(int i, repeater_count<BidiIterator>** s) >{ > saved_repeater<BidiIterator>* pmp = static_cast<saved_repeater<BidiIterator>*>(m_backup_state); > --pmp; > if(pmp < m_stack_base) > { > extend_stack(); > pmp = static_cast<saved_repeater<BidiIterator>*>(m_backup_state); > --pmp; > } > (void) new (pmp)saved_repeater<BidiIterator>(i, s, position); > m_backup_state = pmp; >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::push_single_repeat(std::size_t c, const re_repeat* r, BidiIterator last_position, int state_id) >{ > saved_single_repeat<BidiIterator>* pmp = static_cast<saved_single_repeat<BidiIterator>*>(m_backup_state); > --pmp; > if(pmp < m_stack_base) > { > extend_stack(); > pmp = static_cast<saved_single_repeat<BidiIterator>*>(m_backup_state); > --pmp; > } > (void) new (pmp)saved_single_repeat<BidiIterator>(c, r, last_position, state_id); > m_backup_state = pmp; >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::push_recursion(int idx, const re_syntax_base* p, results_type* presults) >{ > saved_recursion<results_type>* pmp = static_cast<saved_recursion<results_type>*>(m_backup_state); > --pmp; > if(pmp < m_stack_base) > { > extend_stack(); > pmp = static_cast<saved_recursion<results_type>*>(m_backup_state); > --pmp; > } > (void) new (pmp)saved_recursion<results_type>(idx, p, presults); > m_backup_state = pmp; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_startmark() >{ > int index = static_cast<const re_brace*>(pstate)->index; > icase = static_cast<const re_brace*>(pstate)->icase; > switch(index) > { > case 0: > pstate = pstate->next.p; > break; > case -1: > case -2: > { > > const re_syntax_base* next_pstate = static_cast<const re_jump*>(pstate->next.p)->alt.p->next.p; > pstate = pstate->next.p->next.p; > push_assertion(next_pstate, index == -1); > break; > } > case -3: > { > > bool old_independent = m_independent; > m_independent = true; > const re_syntax_base* next_pstate = static_cast<const re_jump*>(pstate->next.p)->alt.p->next.p; > pstate = pstate->next.p->next.p; > bool r = match_all_states(); > pstate = next_pstate; > m_independent = old_independent; ># 402 "/usr/include/boost/regex/v4/perl_matcher_non_recursive.hpp" 3 4 > return r; > } > case -4: > { > > const re_alt* alt = static_cast<const re_alt*>(pstate->next.p); > (static_cast<void> (0)); > pstate = alt->next.p; > if(pstate->type == syntax_element_assert_backref) > { > if(!match_assert_backref()) > pstate = alt->alt.p; > break; > } > else > { > > (static_cast<void> (0)); > bool negated = static_cast<const re_brace*>(pstate)->index == -2; > BidiIterator saved_position = position; > const re_syntax_base* next_pstate = static_cast<const re_jump*>(pstate->next.p)->alt.p->next.p; > pstate = pstate->next.p->next.p; > bool r = match_all_states(); > position = saved_position; > if(negated) > r = !r; > if(r) > pstate = next_pstate; > else > pstate = alt->alt.p; > break; > } > } > case -5: > { > push_matched_paren(0, (*m_presult)[0]); > m_presult->set_first(position, 0, true); > pstate = pstate->next.p; > break; > } > default: > { > (static_cast<void> (0)); > if((m_match_flags & match_nosubs) == 0) > { > push_matched_paren(index, (*m_presult)[index]); > m_presult->set_first(position, index); > } > pstate = pstate->next.p; > break; > } > } > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_alt() >{ > bool take_first, take_second; > const re_alt* jmp = static_cast<const re_alt*>(pstate); > > > if(position == last) > { > take_first = jmp->can_be_null & mask_take; > take_second = jmp->can_be_null & mask_skip; > } > else > { > take_first = can_start(*position, jmp->_map, (unsigned char)mask_take); > take_second = can_start(*position, jmp->_map, (unsigned char)mask_skip); > } > > if(take_first) > { > > > if(take_second) > { > push_alt(jmp->alt.p); > } > pstate = pstate->next.p; > return true; > } > if(take_second) > { > pstate = jmp->alt.p; > return true; > } > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_rep() >{ > > > > > > > > const re_repeat* rep = static_cast<const re_repeat*>(pstate); > > > bool take_first, take_second; > if(position == last) > { > take_first = rep->can_be_null & mask_take; > take_second = rep->can_be_null & mask_skip; > } > else > { > take_first = can_start(*position, rep->_map, (unsigned char)mask_take); > take_second = can_start(*position, rep->_map, (unsigned char)mask_skip); > } > > if((m_backup_state->state_id != saved_state_repeater_count) > || (static_cast<saved_repeater<BidiIterator>*>(m_backup_state)->count.get_id() != rep->state_id) > || (next_count->get_id() != rep->state_id)) > { > > > push_repeater_count(rep->state_id, &next_count); > } > > > > > > next_count->check_null_repeat(position, rep->max); > > if(next_count->get_count() < rep->min) > { > > if(take_first) > { > > ++(*next_count); > pstate = rep->next.p; > return true; > } > return false; > } > > bool greedy = (rep->greedy) && (!(m_match_flags & regex_constants::match_any) || m_independent); > if(greedy) > { > > if((next_count->get_count() < rep->max) && take_first) > { > if(take_second) > { > > push_alt(rep->alt.p); > } > > ++(*next_count); > pstate = rep->next.p; > return true; > } > else if(take_second) > { > pstate = rep->alt.p; > return true; > } > return false; > } > else > { > > if(take_second) > { > if((next_count->get_count() < rep->max) && take_first) > { > > push_non_greedy_repeat(rep->next.p); > } > pstate = rep->alt.p; > return true; > } > if((next_count->get_count() < rep->max) && take_first) > { > > ++(*next_count); > pstate = rep->next.p; > return true; > } > } > return false; > > > > > > >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_dot_repeat_slow() >{ > unsigned count = 0; > const re_repeat* rep = static_cast<const re_repeat*>(pstate); > re_syntax_base* psingle = rep->next.p; > > while(count < rep->min) > { > pstate = psingle; > if(!match_wild()) > return false; > ++count; > } > bool greedy = (rep->greedy) && (!(m_match_flags & regex_constants::match_any) || m_independent); > if(greedy) > { > > while(count < rep->max) > { > pstate = psingle; > if(!match_wild()) > break; > ++count; > } > > if((rep->leading) && (count < rep->max)) > restart = position; > > if(count - rep->min) > push_single_repeat(count, rep, position, saved_state_greedy_single_repeat); > > pstate = rep->alt.p; > return true; > } > else > { > > if(count < rep->max) > push_single_repeat(count, rep, position, saved_state_rep_slow_dot); > pstate = rep->alt.p; > return (position == last) ? (rep->can_be_null & mask_skip) : can_start(*position, rep->_map, mask_skip); > } >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_dot_repeat_fast() >{ > if(m_match_flags & match_not_dot_null) > return match_dot_repeat_slow(); > if((static_cast<const re_dot*>(pstate->next.p)->mask & match_any_mask) == 0) > return match_dot_repeat_slow(); > > const re_repeat* rep = static_cast<const re_repeat*>(pstate); > bool greedy = (rep->greedy) && (!(m_match_flags & regex_constants::match_any) || m_independent); > unsigned count = static_cast<unsigned>((std::min)(static_cast<unsigned>(::boost::re_detail::distance(position, last)), static_cast<unsigned>(greedy ? rep->max : rep->min))); > if(rep->min > count) > { > position = last; > return false; > } > std::advance(position, count); > > if(greedy) > { > if((rep->leading) && (count < rep->max)) > restart = position; > > if(count - rep->min) > push_single_repeat(count, rep, position, saved_state_greedy_single_repeat); > > pstate = rep->alt.p; > return true; > } > else > { > > if(count < rep->max) > push_single_repeat(count, rep, position, saved_state_rep_fast_dot); > pstate = rep->alt.p; > return (position == last) ? (rep->can_be_null & mask_skip) : can_start(*position, rep->_map, mask_skip); > } >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_char_repeat() >{ > > > > > > > > const re_repeat* rep = static_cast<const re_repeat*>(pstate); > (static_cast<void> (0)); > const char_type what = *reinterpret_cast<const char_type*>(static_cast<const re_literal*>(rep->next.p) + 1); > std::size_t count = 0; > > > > bool greedy = (rep->greedy) && (!(m_match_flags & regex_constants::match_any) || m_independent); > std::size_t desired = greedy ? rep->max : rep->min; > if(::boost::is_random_access_iterator<BidiIterator>::value) > { > BidiIterator end = position; > > > std::size_t len = (desired == (std::numeric_limits<std::size_t>::max)()) ? 0u : ::boost::re_detail::distance(position, last); > if(desired >= len) > end = last; > else > std::advance(end, desired); > BidiIterator origin(position); > while((position != end) && (traits_inst.translate(*position, icase) == what)) > { > ++position; > } > count = (unsigned)::boost::re_detail::distance(origin, position); > } > else > { > while((count < desired) && (position != last) && (traits_inst.translate(*position, icase) == what)) > { > ++position; > ++count; > } > } > > if(count < rep->min) > return false; > > if(greedy) > { > if((rep->leading) && (count < rep->max)) > restart = position; > > if(count - rep->min) > push_single_repeat(count, rep, position, saved_state_greedy_single_repeat); > > pstate = rep->alt.p; > return true; > } > else > { > > if(count < rep->max) > push_single_repeat(count, rep, position, saved_state_rep_char); > pstate = rep->alt.p; > return (position == last) ? (rep->can_be_null & mask_skip) : can_start(*position, rep->_map, mask_skip); > } > > > > > > >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_set_repeat() >{ > > > > > > > > const re_repeat* rep = static_cast<const re_repeat*>(pstate); > const unsigned char* map = static_cast<const re_set*>(rep->next.p)->_map; > std::size_t count = 0; > > > > bool greedy = (rep->greedy) && (!(m_match_flags & regex_constants::match_any) || m_independent); > std::size_t desired = greedy ? rep->max : rep->min; > if(::boost::is_random_access_iterator<BidiIterator>::value) > { > BidiIterator end = position; > > > std::size_t len = (desired == (std::numeric_limits<std::size_t>::max)()) ? 0u : ::boost::re_detail::distance(position, last); > if(desired >= len) > end = last; > else > std::advance(end, desired); > BidiIterator origin(position); > while((position != end) && map[static_cast<unsigned char>(traits_inst.translate(*position, icase))]) > { > ++position; > } > count = (unsigned)::boost::re_detail::distance(origin, position); > } > else > { > while((count < desired) && (position != last) && map[static_cast<unsigned char>(traits_inst.translate(*position, icase))]) > { > ++position; > ++count; > } > } > > if(count < rep->min) > return false; > > if(greedy) > { > if((rep->leading) && (count < rep->max)) > restart = position; > > if(count - rep->min) > push_single_repeat(count, rep, position, saved_state_greedy_single_repeat); > > pstate = rep->alt.p; > return true; > } > else > { > > if(count < rep->max) > push_single_repeat(count, rep, position, saved_state_rep_short_set); > pstate = rep->alt.p; > return (position == last) ? (rep->can_be_null & mask_skip) : can_start(*position, rep->_map, mask_skip); > } > > > > > > >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_long_set_repeat() >{ > > > > > > > > typedef typename traits::char_class_type m_type; > const re_repeat* rep = static_cast<const re_repeat*>(pstate); > const re_set_long<m_type>* set = static_cast<const re_set_long<m_type>*>(pstate->next.p); > std::size_t count = 0; > > > > bool greedy = (rep->greedy) && (!(m_match_flags & regex_constants::match_any) || m_independent); > std::size_t desired = greedy ? rep->max : rep->min; > if(::boost::is_random_access_iterator<BidiIterator>::value) > { > BidiIterator end = position; > > > std::size_t len = (desired == (std::numeric_limits<std::size_t>::max)()) ? 0u : ::boost::re_detail::distance(position, last); > if(desired >= len) > end = last; > else > std::advance(end, desired); > BidiIterator origin(position); > while((position != end) && (position != re_is_set_member(position, last, set, re.get_data(), icase))) > { > ++position; > } > count = (unsigned)::boost::re_detail::distance(origin, position); > } > else > { > while((count < desired) && (position != last) && (position != re_is_set_member(position, last, set, re.get_data(), icase))) > { > ++position; > ++count; > } > } > > if(count < rep->min) > return false; > > if(greedy) > { > if((rep->leading) && (count < rep->max)) > restart = position; > > if(count - rep->min) > push_single_repeat(count, rep, position, saved_state_greedy_single_repeat); > > pstate = rep->alt.p; > return true; > } > else > { > > if(count < rep->max) > push_single_repeat(count, rep, position, saved_state_rep_long_set); > pstate = rep->alt.p; > return (position == last) ? (rep->can_be_null & mask_skip) : can_start(*position, rep->_map, mask_skip); > } > > > > > > >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_recursion() >{ > (static_cast<void> (0)); > > > > push_recursion_pop(); > > > > if(recursion_stack.capacity() == 0) > { > recursion_stack.reserve(50); > } > recursion_stack.push_back(recursion_info<results_type>()); > recursion_stack.back().preturn_address = pstate->next.p; > recursion_stack.back().results = *m_presult; > if(static_cast<const re_recurse*>(pstate)->state_id > 0) > { > push_repeater_count(static_cast<const re_recurse*>(pstate)->state_id, &next_count); > } > pstate = static_cast<const re_jump*>(pstate)->alt.p; > recursion_stack.back().idx = static_cast<const re_brace*>(pstate)->index; > > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_endmark() >{ > int index = static_cast<const re_brace*>(pstate)->index; > icase = static_cast<const re_brace*>(pstate)->icase; > if(index > 0) > { > if((m_match_flags & match_nosubs) == 0) > { > m_presult->set_second(position, index); > } > if(!recursion_stack.empty()) > { > if(index == recursion_stack.back().idx) > { > pstate = recursion_stack.back().preturn_address; > *m_presult = recursion_stack.back().results; > push_recursion(recursion_stack.back().idx, recursion_stack.back().preturn_address, &recursion_stack.back().results); > recursion_stack.pop_back(); > } > } > } > else if((index < 0) && (index != -4)) > { > > pstate = 0; > return true; > } > pstate = pstate->next.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_match() >{ > if(!recursion_stack.empty()) > { > (static_cast<void> (0)); > pstate = recursion_stack.back().preturn_address; > *m_presult = recursion_stack.back().results; > push_recursion(recursion_stack.back().idx, recursion_stack.back().preturn_address, &recursion_stack.back().results); > recursion_stack.pop_back(); > return true; > } > if((m_match_flags & match_not_null) && (position == (*m_presult)[0].first)) > return false; > if((m_match_flags & match_all) && (position != last)) > return false; > if((m_match_flags & regex_constants::match_not_initial_null) && (position == search_base)) > return false; > m_presult->set_second(position); > pstate = 0; > m_has_found_match = true; > if((m_match_flags & match_posix) == match_posix) > { > m_result.maybe_assign(*m_presult); > if((m_match_flags & match_any) == 0) > return false; > } ># 1003 "/usr/include/boost/regex/v4/perl_matcher_non_recursive.hpp" 3 4 > return true; >} ># 1013 "/usr/include/boost/regex/v4/perl_matcher_non_recursive.hpp" 3 4 >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind(bool have_match) >{ > static unwind_proc_type const s_unwind_table[18] = > { > &perl_matcher<BidiIterator, Allocator, traits>::unwind_end, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_paren, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_recursion_stopper, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_assertion, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_alt, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_repeater_counter, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_extra_block, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_greedy_single_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_slow_dot_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_fast_dot_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_char_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_short_set_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_long_set_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_non_greedy_repeat, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_recursion, > &perl_matcher<BidiIterator, Allocator, traits>::unwind_recursion_pop, > }; > > m_recursive_result = have_match; > unwind_proc_type unwinder; > bool cont; > > > > do > { > unwinder = s_unwind_table[m_backup_state->state_id]; > cont = (this->*unwinder)(m_recursive_result); > }while(cont); > > > > return pstate ? true : false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_end(bool) >{ > pstate = 0; > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_paren(bool have_match) >{ > saved_matched_paren<BidiIterator>* pmp = static_cast<saved_matched_paren<BidiIterator>*>(m_backup_state); > > if(have_match == false) > { > m_presult->set_first(pmp->sub.first, pmp->index, pmp->index == 0); > m_presult->set_second(pmp->sub.second, pmp->index, pmp->sub.matched, pmp->index == 0); > } ># 1078 "/usr/include/boost/regex/v4/perl_matcher_non_recursive.hpp" 3 4 > m_backup_state = pmp+1; > boost::re_detail::inplace_destroy(pmp); > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_recursion_stopper(bool) >{ > boost::re_detail::inplace_destroy(m_backup_state++); > pstate = 0; > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_assertion(bool r) >{ > saved_assertion<BidiIterator>* pmp = static_cast<saved_assertion<BidiIterator>*>(m_backup_state); > pstate = pmp->pstate; > position = pmp->position; > bool result = (r == pmp->positive); > m_recursive_result = pmp->positive ? r : !r; > boost::re_detail::inplace_destroy(pmp++); > m_backup_state = pmp; > return !result; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_alt(bool r) >{ > saved_position<BidiIterator>* pmp = static_cast<saved_position<BidiIterator>*>(m_backup_state); > if(!r) > { > pstate = pmp->pstate; > position = pmp->position; > } > boost::re_detail::inplace_destroy(pmp++); > m_backup_state = pmp; > return r; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_repeater_counter(bool) >{ > saved_repeater<BidiIterator>* pmp = static_cast<saved_repeater<BidiIterator>*>(m_backup_state); > boost::re_detail::inplace_destroy(pmp++); > m_backup_state = pmp; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_extra_block(bool) >{ > saved_extra_block* pmp = static_cast<saved_extra_block*>(m_backup_state); > void* condemmed = m_stack_base; > m_stack_base = pmp->base; > m_backup_state = pmp->end; > boost::re_detail::inplace_destroy(pmp); > put_mem_block(condemmed); > return true; >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::destroy_single_repeat() >{ > saved_single_repeat<BidiIterator>* p = static_cast<saved_single_repeat<BidiIterator>*>(m_backup_state); > boost::re_detail::inplace_destroy(p++); > m_backup_state = p; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_greedy_single_repeat(bool r) >{ > saved_single_repeat<BidiIterator>* pmp = static_cast<saved_single_repeat<BidiIterator>*>(m_backup_state); > > > if(r) > { > destroy_single_repeat(); > return true; > } > > const re_repeat* rep = pmp->rep; > std::size_t count = pmp->count; > (static_cast<void> (0)); > (static_cast<void> (0)); > > count -= rep->min; > > if((m_match_flags & match_partial) && (position == last)) > m_has_partial_match = true; > > (static_cast<void> (0)); > position = pmp->last_position; > > > do > { > --position; > --count; > ++state_count; > }while(count && !can_start(*position, rep->_map, mask_skip)); > > > if(count == 0) > { > destroy_single_repeat(); > if(!can_start(*position, rep->_map, mask_skip)) > return true; > } > else > { > pmp->count = count + rep->min; > pmp->last_position = position; > } > pstate = rep->alt.p; > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_slow_dot_repeat(bool r) >{ > saved_single_repeat<BidiIterator>* pmp = static_cast<saved_single_repeat<BidiIterator>*>(m_backup_state); > > > if(r) > { > destroy_single_repeat(); > return true; > } > > const re_repeat* rep = pmp->rep; > std::size_t count = pmp->count; > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > > (static_cast<void> (0)); > pstate = rep->next.p; > position = pmp->last_position; > > if(position != last) > { > > do > { > if(!match_wild()) > { > > destroy_single_repeat(); > return true; > } > ++count; > ++state_count; > pstate = rep->next.p; > }while((count < rep->max) && (position != last) && !can_start(*position, rep->_map, mask_skip)); > } > if(position == last) > { > > destroy_single_repeat(); > if((m_match_flags & match_partial) && (position == last) && (position != search_base)) > m_has_partial_match = true; > if(0 == (rep->can_be_null & mask_skip)) > return true; > } > else if(count == rep->max) > { > > destroy_single_repeat(); > if(!can_start(*position, rep->_map, mask_skip)) > return true; > } > else > { > pmp->count = count; > pmp->last_position = position; > } > pstate = rep->alt.p; > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_fast_dot_repeat(bool r) >{ > saved_single_repeat<BidiIterator>* pmp = static_cast<saved_single_repeat<BidiIterator>*>(m_backup_state); > > > if(r) > { > destroy_single_repeat(); > return true; > } > > const re_repeat* rep = pmp->rep; > std::size_t count = pmp->count; > > (static_cast<void> (0)); > position = pmp->last_position; > if(position != last) > { > > > do > { > ++position; > ++count; > ++state_count; > }while((count < rep->max) && (position != last) && !can_start(*position, rep->_map, mask_skip)); > } > > > if((rep->leading) && (count < rep->max)) > restart = position; > if(position == last) > { > > destroy_single_repeat(); > if((m_match_flags & match_partial) && (position == last) && (position != search_base)) > m_has_partial_match = true; > if(0 == (rep->can_be_null & mask_skip)) > return true; > } > else if(count == rep->max) > { > > destroy_single_repeat(); > if(!can_start(*position, rep->_map, mask_skip)) > return true; > } > else > { > pmp->count = count; > pmp->last_position = position; > } > pstate = rep->alt.p; > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_char_repeat(bool r) >{ > saved_single_repeat<BidiIterator>* pmp = static_cast<saved_single_repeat<BidiIterator>*>(m_backup_state); > > > if(r) > { > destroy_single_repeat(); > return true; > } > > const re_repeat* rep = pmp->rep; > std::size_t count = pmp->count; > pstate = rep->next.p; > const char_type what = *reinterpret_cast<const char_type*>(static_cast<const re_literal*>(pstate) + 1); > position = pmp->last_position; > > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > > if(position != last) > { > > do > { > if(traits_inst.translate(*position, icase) != what) > { > > destroy_single_repeat(); > return true; > } > ++count; > ++ position; > ++state_count; > pstate = rep->next.p; > }while((count < rep->max) && (position != last) && !can_start(*position, rep->_map, mask_skip)); > } > > if((rep->leading) && (count < rep->max)) > restart = position; > if(position == last) > { > > destroy_single_repeat(); > if((m_match_flags & match_partial) && (position == last) && (position != search_base)) > m_has_partial_match = true; > if(0 == (rep->can_be_null & mask_skip)) > return true; > } > else if(count == rep->max) > { > > destroy_single_repeat(); > if(!can_start(*position, rep->_map, mask_skip)) > return true; > } > else > { > pmp->count = count; > pmp->last_position = position; > } > pstate = rep->alt.p; > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_short_set_repeat(bool r) >{ > saved_single_repeat<BidiIterator>* pmp = static_cast<saved_single_repeat<BidiIterator>*>(m_backup_state); > > > if(r) > { > destroy_single_repeat(); > return true; > } > > const re_repeat* rep = pmp->rep; > std::size_t count = pmp->count; > pstate = rep->next.p; > const unsigned char* map = static_cast<const re_set*>(rep->next.p)->_map; > position = pmp->last_position; > > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > > if(position != last) > { > > do > { > if(!map[static_cast<unsigned char>(traits_inst.translate(*position, icase))]) > { > > destroy_single_repeat(); > return true; > } > ++count; > ++ position; > ++state_count; > pstate = rep->next.p; > }while((count < rep->max) && (position != last) && !can_start(*position, rep->_map, mask_skip)); > } > > if((rep->leading) && (count < rep->max)) > restart = position; > if(position == last) > { > > destroy_single_repeat(); > if((m_match_flags & match_partial) && (position == last) && (position != search_base)) > m_has_partial_match = true; > if(0 == (rep->can_be_null & mask_skip)) > return true; > } > else if(count == rep->max) > { > > destroy_single_repeat(); > if(!can_start(*position, rep->_map, mask_skip)) > return true; > } > else > { > pmp->count = count; > pmp->last_position = position; > } > pstate = rep->alt.p; > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_long_set_repeat(bool r) >{ > typedef typename traits::char_class_type m_type; > saved_single_repeat<BidiIterator>* pmp = static_cast<saved_single_repeat<BidiIterator>*>(m_backup_state); > > > if(r) > { > destroy_single_repeat(); > return true; > } > > const re_repeat* rep = pmp->rep; > std::size_t count = pmp->count; > pstate = rep->next.p; > const re_set_long<m_type>* set = static_cast<const re_set_long<m_type>*>(pstate); > position = pmp->last_position; > > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > (static_cast<void> (0)); > > if(position != last) > { > > do > { > if(position == re_is_set_member(position, last, set, re.get_data(), icase)) > { > > destroy_single_repeat(); > return true; > } > ++position; > ++count; > ++state_count; > pstate = rep->next.p; > }while((count < rep->max) && (position != last) && !can_start(*position, rep->_map, mask_skip)); > } > > if((rep->leading) && (count < rep->max)) > restart = position; > if(position == last) > { > > destroy_single_repeat(); > if((m_match_flags & match_partial) && (position == last) && (position != search_base)) > m_has_partial_match = true; > if(0 == (rep->can_be_null & mask_skip)) > return true; > } > else if(count == rep->max) > { > > destroy_single_repeat(); > if(!can_start(*position, rep->_map, mask_skip)) > return true; > } > else > { > pmp->count = count; > pmp->last_position = position; > } > pstate = rep->alt.p; > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_non_greedy_repeat(bool r) >{ > saved_position<BidiIterator>* pmp = static_cast<saved_position<BidiIterator>*>(m_backup_state); > if(!r) > { > position = pmp->position; > pstate = pmp->pstate; > ++(*next_count); > } > boost::re_detail::inplace_destroy(pmp++); > m_backup_state = pmp; > return r; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_recursion(bool r) >{ > saved_recursion<results_type>* pmp = static_cast<saved_recursion<results_type>*>(m_backup_state); > if(!r) > { > recursion_stack.push_back(recursion_info<results_type>()); > recursion_stack.back().idx = pmp->recursion_id; > recursion_stack.back().preturn_address = pmp->preturn_address; > recursion_stack.back().results = pmp->results; > } > boost::re_detail::inplace_destroy(pmp++); > m_backup_state = pmp; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::unwind_recursion_pop(bool r) >{ > saved_state* pmp = static_cast<saved_state*>(m_backup_state); > if(!r) > { > recursion_stack.pop_back(); > } > boost::re_detail::inplace_destroy(pmp++); > m_backup_state = pmp; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >void perl_matcher<BidiIterator, Allocator, traits>::push_recursion_pop() >{ > saved_state* pmp = static_cast<saved_state*>(m_backup_state); > --pmp; > if(pmp < m_stack_base) > { > extend_stack(); > pmp = static_cast<saved_state*>(m_backup_state); > --pmp; > } > (void) new (pmp)saved_state(15); > m_backup_state = pmp; >} ># 1640 "/usr/include/boost/regex/v4/perl_matcher_non_recursive.hpp" 3 4 >} >} ># 582 "/usr/include/boost/regex/v4/perl_matcher.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/perl_matcher_common.hpp" 1 3 4 ># 42 "/usr/include/boost/regex/v4/perl_matcher_common.hpp" 3 4 >namespace boost{ >namespace re_detail{ > >template <class BidiIterator, class Allocator, class traits> >void perl_matcher<BidiIterator, Allocator, traits>::construct_init(const basic_regex<char_type, traits>& e, match_flag_type f) >{ > typedef typename regex_iterator_traits<BidiIterator>::iterator_category category; > typedef typename basic_regex<char_type, traits>::flag_type expression_flag_type; > > if(e.empty()) > { > > std::invalid_argument ex("Invalid regular expression object"); > boost::throw_exception(ex); > } > pstate = 0; > m_match_flags = f; > estimate_max_state_count(static_cast<category*>(0)); > expression_flag_type re_f = re.flags(); > icase = re_f & regex_constants::icase; > if(!(m_match_flags & (match_perl|match_posix))) > { > if((re_f & (regbase::main_option_type|regbase::no_perl_ex)) == 0) > m_match_flags |= match_perl; > else if((re_f & (regbase::main_option_type|regbase::emacs_ex)) == (regbase::basic_syntax_group|regbase::emacs_ex)) > m_match_flags |= match_perl; > else if((re_f & (regbase::main_option_type|regbase::literal)) == (regbase::literal)) > m_match_flags |= match_perl; > else > m_match_flags |= match_posix; > } > if(m_match_flags & match_posix) > { > m_temp_match.reset(new match_results<BidiIterator, Allocator>()); > m_presult = m_temp_match.get(); > } > else > m_presult = &m_result; > > m_stack_base = 0; > m_backup_state = 0; > > > m_word_mask = re.get_data().m_word_mask; > > match_any_mask = static_cast<unsigned char>((f & match_not_dot_newline) ? re_detail::test_not_newline : re_detail::test_newline); >} > >template <class BidiIterator, class Allocator, class traits> >void perl_matcher<BidiIterator, Allocator, traits>::estimate_max_state_count(std::random_access_iterator_tag*) >{ ># 103 "/usr/include/boost/regex/v4/perl_matcher_common.hpp" 3 4 > static const std::ptrdiff_t k = 100000; > std::ptrdiff_t dist = boost::re_detail::distance(base, last); > if(dist == 0) > dist = 1; > std::ptrdiff_t states = re.size(); > if(states == 0) > states = 1; > states *= states; > if((std::numeric_limits<std::ptrdiff_t>::max)() / dist < states) > { > max_state_count = (std::min)((std::ptrdiff_t)100000000, (std::numeric_limits<std::ptrdiff_t>::max)() - 2); > return; > } > states *= dist; > if((std::numeric_limits<std::ptrdiff_t>::max)() - k < states) > { > max_state_count = (std::min)((std::ptrdiff_t)100000000, (std::numeric_limits<std::ptrdiff_t>::max)() - 2); > return; > } > states += k; > > max_state_count = states; > > > > > states = dist; > if((std::numeric_limits<std::ptrdiff_t>::max)() / dist < states) > { > max_state_count = (std::min)((std::ptrdiff_t)100000000, (std::numeric_limits<std::ptrdiff_t>::max)() - 2); > return; > } > states *= dist; > if((std::numeric_limits<std::ptrdiff_t>::max)() - k < states) > { > max_state_count = (std::min)((std::ptrdiff_t)100000000, (std::numeric_limits<std::ptrdiff_t>::max)() - 2); > return; > } > states += k; > > > > > if(states > 100000000) > states = 100000000; > > > > > if(states > max_state_count) > max_state_count = states; >} > >template <class BidiIterator, class Allocator, class traits> >inline void perl_matcher<BidiIterator, Allocator, traits>::estimate_max_state_count(void*) >{ > > max_state_count = 100000000; >} ># 176 "/usr/include/boost/regex/v4/perl_matcher_common.hpp" 3 4 >template <class BidiIterator, class Allocator, class traits> >inline bool perl_matcher<BidiIterator, Allocator, traits>::match() >{ > > > > return match_imp(); > >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_imp() >{ > > > save_state_init init(&m_stack_base, &m_backup_state); > used_block_count = 1024; > > try{ > > > > > position = base; > search_base = base; > state_count = 0; > m_match_flags |= regex_constants::match_all; > m_presult->set_size((m_match_flags & match_nosubs) ? 1 : re.mark_count(), search_base, last); > m_presult->set_base(base); > m_presult->set_named_subs(this->re.get_named_subs()); > if(m_match_flags & match_posix) > m_result = *m_presult; > verify_options(re.flags(), m_match_flags); > if(0 == match_prefix()) > return false; > return (m_result[0].second == last) && (m_result[0].first == base); > > > } > catch(...) > { > > > > while(unwind(true)){} > throw; > } > >} > >template <class BidiIterator, class Allocator, class traits> >inline bool perl_matcher<BidiIterator, Allocator, traits>::find() >{ > > > > return find_imp(); > >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::find_imp() >{ > static matcher_proc_type const s_find_vtable[7] = > { > &perl_matcher<BidiIterator, Allocator, traits>::find_restart_any, > &perl_matcher<BidiIterator, Allocator, traits>::find_restart_word, > &perl_matcher<BidiIterator, Allocator, traits>::find_restart_line, > &perl_matcher<BidiIterator, Allocator, traits>::find_restart_buf, > &perl_matcher<BidiIterator, Allocator, traits>::match_prefix, > &perl_matcher<BidiIterator, Allocator, traits>::find_restart_lit, > &perl_matcher<BidiIterator, Allocator, traits>::find_restart_lit, > }; > > > > save_state_init init(&m_stack_base, &m_backup_state); > used_block_count = 1024; > > try{ > > > > state_count = 0; > if((m_match_flags & regex_constants::match_init) == 0) > { > > search_base = position = base; > pstate = re.get_first_state(); > m_presult->set_size((m_match_flags & match_nosubs) ? 1 : re.mark_count(), base, last); > m_presult->set_base(base); > m_presult->set_named_subs(this->re.get_named_subs()); > m_match_flags |= regex_constants::match_init; > } > else > { > > search_base = position = m_result[0].second; > > > if(((m_match_flags & match_not_null) == 0) && (m_result.length() == 0)) > { > if(position == last) > return false; > else > ++position; > } > > m_presult->set_size((m_match_flags & match_nosubs) ? 1 : re.mark_count(), search_base, last); > > > } > if(m_match_flags & match_posix) > { > m_result.set_size(re.mark_count(), base, last); > m_result.set_base(base); > } > > verify_options(re.flags(), m_match_flags); > > unsigned type = (m_match_flags & match_continuous) ? > static_cast<unsigned int>(regbase::restart_continue) > : static_cast<unsigned int>(re.get_restart_type()); > > > matcher_proc_type proc = s_find_vtable[type]; > return (this->*proc)(); > > > } > catch(...) > { > > > > while(unwind(true)){} > throw; > } > >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_prefix() >{ > m_has_partial_match = false; > m_has_found_match = false; > pstate = re.get_first_state(); > m_presult->set_first(position); > restart = position; > match_all_states(); > if(!m_has_found_match && m_has_partial_match && (m_match_flags & match_partial)) > { > m_has_found_match = true; > m_presult->set_second(last, 0, false); > position = last; > if((m_match_flags & match_posix) == match_posix) > { > m_result.maybe_assign(*m_presult); > } > } ># 349 "/usr/include/boost/regex/v4/perl_matcher_common.hpp" 3 4 > if(!m_has_found_match) > position = restart; > return m_has_found_match; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_literal() >{ > unsigned int len = static_cast<const re_literal*>(pstate)->length; > const char_type* what = reinterpret_cast<const char_type*>(static_cast<const re_literal*>(pstate) + 1); > > > > for(unsigned int i = 0; i < len; ++i, ++position) > { > if((position == last) || (traits_inst.translate(*position, icase) != what[i])) > return false; > } > pstate = pstate->next.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_start_line() >{ > if(position == backstop) > { > if((m_match_flags & match_prev_avail) == 0) > { > if((m_match_flags & match_not_bol) == 0) > { > pstate = pstate->next.p; > return true; > } > return false; > } > } > else if(m_match_flags & match_single_line) > return false; > > > BidiIterator t(position); > --t; > if(position != last) > { > if(is_separator(*t) && !((*t == static_cast<char_type>('\r')) && (*position == static_cast<char_type>('\n'))) ) > { > pstate = pstate->next.p; > return true; > } > } > else if(is_separator(*t)) > { > pstate = pstate->next.p; > return true; > } > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_end_line() >{ > if(position != last) > { > if(m_match_flags & match_single_line) > return false; > > if(is_separator(*position)) > { > if((position != backstop) || (m_match_flags & match_prev_avail)) > { > > BidiIterator t(position); > --t; > if((*t == static_cast<char_type>('\r')) && (*position == static_cast<char_type>('\n'))) > { > return false; > } > } > pstate = pstate->next.p; > return true; > } > } > else if((m_match_flags & match_not_eol) == 0) > { > pstate = pstate->next.p; > return true; > } > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_wild() >{ > if(position == last) > return false; > if(is_separator(*position) && ((match_any_mask & static_cast<const re_dot*>(pstate)->mask) == 0)) > return false; > if((*position == char_type(0)) && (m_match_flags & match_not_dot_null)) > return false; > pstate = pstate->next.p; > ++position; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_word_boundary() >{ > bool b; > if(position != last) > { > > > > > b = traits_inst.isctype(*position, m_word_mask); > > } > else > { > b = (m_match_flags & match_not_eow) ? true : false; > } > if((position == backstop) && ((m_match_flags & match_prev_avail) == 0)) > { > if(m_match_flags & match_not_bow) > b ^= true; > else > b ^= false; > } > else > { > --position; > b ^= traits_inst.isctype(*position, m_word_mask); > ++position; > } > if(b) > { > pstate = pstate->next.p; > return true; > } > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_within_word() >{ > if(position == last) > return false; > > bool prev = traits_inst.isctype(*position, m_word_mask); > { > bool b; > if((position == backstop) && ((m_match_flags & match_prev_avail) == 0)) > return false; > else > { > --position; > b = traits_inst.isctype(*position, m_word_mask); > ++position; > } > if(b == prev) > { > pstate = pstate->next.p; > return true; > } > } > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_word_start() >{ > if(position == last) > return false; > if(!traits_inst.isctype(*position, m_word_mask)) > return false; > if((position == backstop) && ((m_match_flags & match_prev_avail) == 0)) > { > if(m_match_flags & match_not_bow) > return false; > } > else > { > > BidiIterator t(position); > --t; > if(traits_inst.isctype(*t, m_word_mask)) > return false; > } > > pstate = pstate->next.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_word_end() >{ > if((position == backstop) && ((m_match_flags & match_prev_avail) == 0)) > return false; > BidiIterator t(position); > --t; > if(traits_inst.isctype(*t, m_word_mask) == false) > return false; > > if(position == last) > { > if(m_match_flags & match_not_eow) > return false; > } > else > { > > if(traits_inst.isctype(*position, m_word_mask)) > return false; > } > pstate = pstate->next.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_buffer_start() >{ > if((position != backstop) || (m_match_flags & match_not_bob)) > return false; > > pstate = pstate->next.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_buffer_end() >{ > if((position != last) || (m_match_flags & match_not_eob)) > return false; > > pstate = pstate->next.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_backref() >{ > > > > > > > int index = static_cast<const re_brace*>(pstate)->index; > if(index >= 10000) > { > named_subexpressions::range_type r = re.get_data().equal_range(index); > (static_cast<void> (0)); > do > { > index = r.first->index; > ++r.first; > }while((r.first != r.second) && ((*m_presult)[index].matched != true)); > } > > if((m_match_flags & match_perl) && !(*m_presult)[index].matched) > return false; > > BidiIterator i = (*m_presult)[index].first; > BidiIterator j = (*m_presult)[index].second; > while(i != j) > { > if((position == last) || (traits_inst.translate(*position, icase) != traits_inst.translate(*i, icase))) > return false; > ++i; > ++position; > } > pstate = pstate->next.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_long_set() >{ > typedef typename traits::char_class_type char_class_type; > > if(position == last) > return false; > BidiIterator t = re_is_set_member(position, last, static_cast<const re_set_long<char_class_type>*>(pstate), re.get_data(), icase); > if(t != position) > { > pstate = pstate->next.p; > position = t; > return true; > } > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_set() >{ > if(position == last) > return false; > if(static_cast<const re_set*>(pstate)->_map[static_cast<unsigned char>(traits_inst.translate(*position, icase))]) > { > pstate = pstate->next.p; > ++position; > return true; > } > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_jump() >{ > pstate = static_cast<const re_jump*>(pstate)->alt.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_combining() >{ > if(position == last) > return false; > if(is_combining(traits_inst.translate(*position, icase))) > return false; > ++position; > while((position != last) && is_combining(traits_inst.translate(*position, icase))) > ++position; > pstate = pstate->next.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_soft_buffer_end() >{ > if(m_match_flags & match_not_eob) > return false; > BidiIterator p(position); > while((p != last) && is_separator(traits_inst.translate(*p, icase)))++p; > if(p != last) > return false; > pstate = pstate->next.p; > return true; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_restart_continue() >{ > if(position == search_base) > { > pstate = pstate->next.p; > return true; > } > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_backstep() >{ > > > > > if( ::boost::is_random_access_iterator<BidiIterator>::value) > { > std::ptrdiff_t maxlen = ::boost::re_detail::distance(backstop, position); > if(maxlen < static_cast<const re_brace*>(pstate)->index) > return false; > std::advance(position, -static_cast<const re_brace*>(pstate)->index); > } > else > { > int c = static_cast<const re_brace*>(pstate)->index; > while(c--) > { > if(position == backstop) > return false; > --position; > } > } > pstate = pstate->next.p; > return true; > > > >} > >template <class BidiIterator, class Allocator, class traits> >inline bool perl_matcher<BidiIterator, Allocator, traits>::match_assert_backref() >{ > > int index = static_cast<const re_brace*>(pstate)->index; > bool result = false; > if(index == 9999) > { > > return false; > } > else if(index > 0) > { > > > if(index >= 10000) > { > named_subexpressions::range_type r = re.get_data().equal_range(index); > while(r.first != r.second) > { > if((*m_presult)[r.first->index].matched) > { > result = true; > break; > } > ++r.first; > } > } > else > { > result = (*m_presult)[index].matched; > } > pstate = pstate->next.p; > } > else > { > > > int idx = -index-1; > if(idx >= 10000) > { > named_subexpressions::range_type r = re.get_data().equal_range(idx); > int stack_index = recursion_stack.empty() ? -1 : recursion_stack.back().idx; > while(r.first != r.second) > { > result |= (stack_index == r.first->index); > if(result)break; > ++r.first; > } > } > else > { > result = !recursion_stack.empty() && ((recursion_stack.back().idx == idx) || (index == 0)); > } > pstate = pstate->next.p; > } > return result; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::match_toggle_case() >{ > > this->icase = static_cast<const re_case*>(pstate)->icase; > pstate = pstate->next.p; > return true; >} > > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::find_restart_any() >{ > > > > > const unsigned char* _map = re.get_map(); > while(true) > { > > while((position != last) && !can_start(*position, _map, (unsigned char)mask_any) ) > ++position; > if(position == last) > { > > if(re.can_be_null()) > return match_prefix(); > break; > } > > if(match_prefix()) > return true; > if(position == last) > return false; > ++position; > } > return false; > > > >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::find_restart_word() >{ > > > > > > const unsigned char* _map = re.get_map(); > if((m_match_flags & match_prev_avail) || (position != base)) > --position; > else if(match_prefix()) > return true; > do > { > while((position != last) && traits_inst.isctype(*position, m_word_mask)) > ++position; > while((position != last) && !traits_inst.isctype(*position, m_word_mask)) > ++position; > if(position == last) > break; > > if(can_start(*position, _map, (unsigned char)mask_any) ) > { > if(match_prefix()) > return true; > } > if(position == last) > break; > } while(true); > return false; > > > >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::find_restart_line() >{ > > const unsigned char* _map = re.get_map(); > if(match_prefix()) > return true; > while(position != last) > { > while((position != last) && !is_separator(*position)) > ++position; > if(position == last) > return false; > ++position; > if(position == last) > { > if(re.can_be_null() && match_prefix()) > return true; > return false; > } > > if( can_start(*position, _map, (unsigned char)mask_any) ) > { > if(match_prefix()) > return true; > } > if(position == last) > return false; > > } > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::find_restart_buf() >{ > if((position == base) && ((m_match_flags & match_not_bob) == 0)) > return match_prefix(); > return false; >} > >template <class BidiIterator, class Allocator, class traits> >bool perl_matcher<BidiIterator, Allocator, traits>::find_restart_lit() >{ ># 970 "/usr/include/boost/regex/v4/perl_matcher_common.hpp" 3 4 > return false; >} > >} > >} ># 585 "/usr/include/boost/regex/v4/perl_matcher.hpp" 2 3 4 ># 89 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 ># 97 "/usr/include/boost/regex/v4/regex.hpp" 3 4 ># 1 "/usr/include/boost/regex/v4/instances.hpp" 1 3 4 ># 25 "/usr/include/boost/regex/v4/instances.hpp" 3 4 >namespace boost{ ># 135 "/usr/include/boost/regex/v4/instances.hpp" 3 4 >namespace re_detail{ >__extension__ extern template >std::locale cpp_regex_traits_base<char>::imbue(const std::locale& l); > >__extension__ extern template >cpp_regex_traits_implementation<char>::string_type > cpp_regex_traits_implementation<char>::transform_primary(const char* p1, const char* p2) const; >__extension__ extern template >cpp_regex_traits_implementation<char>::string_type > cpp_regex_traits_implementation<char>::transform(const char* p1, const char* p2) const; >__extension__ extern template >cpp_regex_traits_implementation<char>::string_type > cpp_regex_traits_implementation<char>::lookup_collatename(const char* p1, const char* p2) const; >__extension__ extern template >void cpp_regex_traits_implementation<char>::init(); >__extension__ extern template >cpp_regex_traits_implementation<char>::char_class_type > cpp_regex_traits_implementation<char>::lookup_classname_imp(const char* p1, const char* p2) const; > > > > >} >__extension__ extern template >int cpp_regex_traits<char>::toi(const char*& first, const char* last, int radix)const; >__extension__ extern template >std::string cpp_regex_traits<char>::catalog_name(const std::string& name); >__extension__ extern template >std::string& cpp_regex_traits<char>::get_catalog_name_inst(); >__extension__ extern template >std::string cpp_regex_traits<char>::get_catalog_name(); > >__extension__ extern template >static_mutex& cpp_regex_traits<char>::get_mutex_inst(); > > > >__extension__ extern template basic_regex<char , boost::regex_traits<char > >& > basic_regex<char , boost::regex_traits<char > >::do_assign( > const char* p1, > const char* p2, > flag_type f); >__extension__ extern template basic_regex<char , boost::regex_traits<char > >::locale_type > basic_regex<char , boost::regex_traits<char > >::imbue(locale_type l); > >__extension__ extern template void > match_results<const char*>::maybe_assign( > const match_results<const char*>& m); > >namespace re_detail{ >__extension__ extern template void perl_matcher<char const *, match_results< const char* >::allocator_type , boost::regex_traits<char > >::construct_init( > const basic_regex<char , boost::regex_traits<char > >& e, match_flag_type f); >__extension__ extern template bool perl_matcher<char const *, match_results< const char* >::allocator_type , boost::regex_traits<char > >::match(); >__extension__ extern template bool perl_matcher<char const *, match_results< const char* >::allocator_type , boost::regex_traits<char > >::find(); >} > > > > > > >__extension__ extern template void > match_results<std::basic_string<char>::const_iterator>::maybe_assign( > const match_results<std::basic_string<char>::const_iterator>& m); > >namespace re_detail{ >__extension__ extern template void perl_matcher<std::basic_string<char>::const_iterator, match_results< std::basic_string<char>::const_iterator >::allocator_type, boost::regex_traits<char > >::construct_init( > const basic_regex<char>& e, match_flag_type f); >__extension__ extern template bool perl_matcher<std::basic_string<char>::const_iterator, match_results< std::basic_string<char>::const_iterator >::allocator_type, boost::regex_traits<char > >::match(); >__extension__ extern template bool perl_matcher<std::basic_string<char>::const_iterator, match_results< std::basic_string<char>::const_iterator >::allocator_type, boost::regex_traits<char > >::find(); >} ># 215 "/usr/include/boost/regex/v4/instances.hpp" 3 4 >} ># 98 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 ># 108 "/usr/include/boost/regex/v4/regex.hpp" 3 4 ># 1 "/usr/include/boost/regex/v4/instances.hpp" 1 3 4 ># 25 "/usr/include/boost/regex/v4/instances.hpp" 3 4 >namespace boost{ ># 135 "/usr/include/boost/regex/v4/instances.hpp" 3 4 >namespace re_detail{ >__extension__ extern template >std::locale cpp_regex_traits_base<wchar_t>::imbue(const std::locale& l); > >__extension__ extern template >cpp_regex_traits_implementation<wchar_t>::string_type > cpp_regex_traits_implementation<wchar_t>::transform_primary(const wchar_t* p1, const wchar_t* p2) const; >__extension__ extern template >cpp_regex_traits_implementation<wchar_t>::string_type > cpp_regex_traits_implementation<wchar_t>::transform(const wchar_t* p1, const wchar_t* p2) const; >__extension__ extern template >cpp_regex_traits_implementation<wchar_t>::string_type > cpp_regex_traits_implementation<wchar_t>::lookup_collatename(const wchar_t* p1, const wchar_t* p2) const; >__extension__ extern template >void cpp_regex_traits_implementation<wchar_t>::init(); >__extension__ extern template >cpp_regex_traits_implementation<wchar_t>::char_class_type > cpp_regex_traits_implementation<wchar_t>::lookup_classname_imp(const wchar_t* p1, const wchar_t* p2) const; > > > > >} >__extension__ extern template >int cpp_regex_traits<wchar_t>::toi(const wchar_t*& first, const wchar_t* last, int radix)const; >__extension__ extern template >std::string cpp_regex_traits<wchar_t>::catalog_name(const std::string& name); >__extension__ extern template >std::string& cpp_regex_traits<wchar_t>::get_catalog_name_inst(); >__extension__ extern template >std::string cpp_regex_traits<wchar_t>::get_catalog_name(); > >__extension__ extern template >static_mutex& cpp_regex_traits<wchar_t>::get_mutex_inst(); > > > >__extension__ extern template basic_regex<wchar_t , boost::regex_traits<wchar_t > >& > basic_regex<wchar_t , boost::regex_traits<wchar_t > >::do_assign( > const wchar_t* p1, > const wchar_t* p2, > flag_type f); >__extension__ extern template basic_regex<wchar_t , boost::regex_traits<wchar_t > >::locale_type > basic_regex<wchar_t , boost::regex_traits<wchar_t > >::imbue(locale_type l); > >__extension__ extern template void > match_results<const wchar_t*>::maybe_assign( > const match_results<const wchar_t*>& m); > >namespace re_detail{ >__extension__ extern template void perl_matcher<wchar_t const *, match_results< const wchar_t* >::allocator_type , boost::regex_traits<wchar_t > >::construct_init( > const basic_regex<wchar_t , boost::regex_traits<wchar_t > >& e, match_flag_type f); >__extension__ extern template bool perl_matcher<wchar_t const *, match_results< const wchar_t* >::allocator_type , boost::regex_traits<wchar_t > >::match(); >__extension__ extern template bool perl_matcher<wchar_t const *, match_results< const wchar_t* >::allocator_type , boost::regex_traits<wchar_t > >::find(); >} > > > > > > >__extension__ extern template void > match_results<std::basic_string<wchar_t>::const_iterator>::maybe_assign( > const match_results<std::basic_string<wchar_t>::const_iterator>& m); > >namespace re_detail{ >__extension__ extern template void perl_matcher<std::basic_string<wchar_t>::const_iterator, match_results< std::basic_string<wchar_t>::const_iterator >::allocator_type, boost::regex_traits<wchar_t > >::construct_init( > const basic_regex<wchar_t>& e, match_flag_type f); >__extension__ extern template bool perl_matcher<std::basic_string<wchar_t>::const_iterator, match_results< std::basic_string<wchar_t>::const_iterator >::allocator_type, boost::regex_traits<wchar_t > >::match(); >__extension__ extern template bool perl_matcher<std::basic_string<wchar_t>::const_iterator, match_results< std::basic_string<wchar_t>::const_iterator >::allocator_type, boost::regex_traits<wchar_t > >::find(); >} ># 215 "/usr/include/boost/regex/v4/instances.hpp" 3 4 >} ># 109 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 ># 128 "/usr/include/boost/regex/v4/regex.hpp" 3 4 >namespace boost{ > > > > > > > >typedef match_results<const char*> cmatch; >typedef match_results<std::string::const_iterator> smatch; > >typedef match_results<const wchar_t*> wcmatch; >typedef match_results<std::wstring::const_iterator> wsmatch; > > >} > ># 1 "/usr/include/boost/regex/v4/regex_match.hpp" 1 3 4 ># 25 "/usr/include/boost/regex/v4/regex_match.hpp" 3 4 >namespace boost{ ># 43 "/usr/include/boost/regex/v4/regex_match.hpp" 3 4 >template <class BidiIterator, class Allocator, class charT, class traits> >bool regex_match(BidiIterator first, BidiIterator last, > match_results<BidiIterator, Allocator>& m, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > re_detail::perl_matcher<BidiIterator, Allocator, traits> matcher(first, last, m, e, flags, first); > return matcher.match(); >} >template <class iterator, class charT, class traits> >bool regex_match(iterator first, iterator last, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > match_results<iterator> m; > return regex_match(first, last, m, e, flags | regex_constants::match_any); >} > > > > > > > >template <class charT, class Allocator, class traits> >inline bool regex_match(const charT* str, > match_results<const charT*, Allocator>& m, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > return regex_match(str, str + traits::length(str), m, e, flags); >} > >template <class ST, class SA, class Allocator, class charT, class traits> >inline bool regex_match(const std::basic_string<charT, ST, SA>& s, > match_results<typename std::basic_string<charT, ST, SA>::const_iterator, Allocator>& m, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > return regex_match(s.begin(), s.end(), m, e, flags); >} >template <class charT, class traits> >inline bool regex_match(const charT* str, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > match_results<const charT*> m; > return regex_match(str, str + traits::length(str), m, e, flags | regex_constants::match_any); >} > >template <class ST, class SA, class charT, class traits> >inline bool regex_match(const std::basic_string<charT, ST, SA>& s, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > typedef typename std::basic_string<charT, ST, SA>::const_iterator iterator; > match_results<iterator> m; > return regex_match(s.begin(), s.end(), m, e, flags | regex_constants::match_any); >} ># 362 "/usr/include/boost/regex/v4/regex_match.hpp" 3 4 >} ># 146 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_search.hpp" 1 3 4 ># 23 "/usr/include/boost/regex/v4/regex_search.hpp" 3 4 >namespace boost{ ># 36 "/usr/include/boost/regex/v4/regex_search.hpp" 3 4 >template <class BidiIterator, class Allocator, class charT, class traits> >bool regex_search(BidiIterator first, BidiIterator last, > match_results<BidiIterator, Allocator>& m, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > return regex_search(first, last, m, e, flags, first); >} > >template <class BidiIterator, class Allocator, class charT, class traits> >bool regex_search(BidiIterator first, BidiIterator last, > match_results<BidiIterator, Allocator>& m, > const basic_regex<charT, traits>& e, > match_flag_type flags, > BidiIterator base) >{ > if(e.flags() & regex_constants::failbit) > return false; > > re_detail::perl_matcher<BidiIterator, Allocator, traits> matcher(first, last, m, e, flags, base); > return matcher.find(); >} ># 66 "/usr/include/boost/regex/v4/regex_search.hpp" 3 4 >template <class charT, class Allocator, class traits> >inline bool regex_search(const charT* str, > match_results<const charT*, Allocator>& m, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > return regex_search(str, str + traits::length(str), m, e, flags); >} > >template <class ST, class SA, class Allocator, class charT, class traits> >inline bool regex_search(const std::basic_string<charT, ST, SA>& s, > match_results<typename std::basic_string<charT, ST, SA>::const_iterator, Allocator>& m, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > return regex_search(s.begin(), s.end(), m, e, flags); >} ># 134 "/usr/include/boost/regex/v4/regex_search.hpp" 3 4 >template <class BidiIterator, class charT, class traits> >bool regex_search(BidiIterator first, BidiIterator last, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > if(e.flags() & regex_constants::failbit) > return false; > > match_results<BidiIterator> m; > typedef typename match_results<BidiIterator>::allocator_type match_alloc_type; > re_detail::perl_matcher<BidiIterator, match_alloc_type, traits> matcher(first, last, m, e, flags | regex_constants::match_any, first); > return matcher.find(); >} > > > >template <class charT, class traits> >inline bool regex_search(const charT* str, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > return regex_search(str, str + traits::length(str), e, flags); >} > >template <class ST, class SA, class charT, class traits> >inline bool regex_search(const std::basic_string<charT, ST, SA>& s, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > return regex_search(s.begin(), s.end(), e, flags); >} ># 213 "/usr/include/boost/regex/v4/regex_search.hpp" 3 4 >} ># 149 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_iterator.hpp" 1 3 4 ># 24 "/usr/include/boost/regex/v4/regex_iterator.hpp" 3 4 >namespace boost{ ># 37 "/usr/include/boost/regex/v4/regex_iterator.hpp" 3 4 >template <class BidirectionalIterator, > class charT, > class traits> >class regex_iterator_implementation >{ > typedef basic_regex<charT, traits> regex_type; > > match_results<BidirectionalIterator> what; > BidirectionalIterator base; > BidirectionalIterator end; > const regex_type re; > match_flag_type flags; > >public: > regex_iterator_implementation(const regex_type* p, BidirectionalIterator last, match_flag_type f) > : base(), end(last), re(*p), flags(f){} > bool init(BidirectionalIterator first) > { > base = first; > return regex_search(first, end, what, re, flags); > } > bool compare(const regex_iterator_implementation& that) > { > if(this == &that) return true; > return (&re.get_data() == &that.re.get_data()) && (end == that.end) && (flags == that.flags) && (what[0].first == that.what[0].first) && (what[0].second == that.what[0].second); > } > const match_results<BidirectionalIterator>& get() > { return what; } > bool next() > { > > > BidirectionalIterator next_start = what[0].second; > match_flag_type f(flags); > if(!what.length() || (f & regex_constants::match_posix)) > f |= regex_constants::match_not_initial_null; > > > bool result = regex_search(next_start, end, what, re, f, base); > if(result) > what.set_base(base); > return result; > } >private: > regex_iterator_implementation& operator=(const regex_iterator_implementation&); >}; > >template <class BidirectionalIterator, > class charT = typename re_detail::regex_iterator_traits<BidirectionalIterator>::value_type, > class traits = regex_traits<charT> > >class regex_iterator > > : public std::iterator< > std::forward_iterator_tag, > match_results<BidirectionalIterator>, > typename re_detail::regex_iterator_traits<BidirectionalIterator>::difference_type, > const match_results<BidirectionalIterator>*, > const match_results<BidirectionalIterator>& > > >{ >private: > typedef regex_iterator_implementation<BidirectionalIterator, charT, traits> impl; > typedef shared_ptr<impl> pimpl; >public: > typedef basic_regex<charT, traits> regex_type; > typedef match_results<BidirectionalIterator> value_type; > typedef typename re_detail::regex_iterator_traits<BidirectionalIterator>::difference_type > difference_type; > typedef const value_type* pointer; > typedef const value_type& reference; > typedef std::forward_iterator_tag iterator_category; > > regex_iterator(){} > regex_iterator(BidirectionalIterator a, BidirectionalIterator b, > const regex_type& re, > match_flag_type m = match_default) > : pdata(new impl(&re, b, m)) > { > if(!pdata->init(a)) > { > pdata.reset(); > } > } > regex_iterator(const regex_iterator& that) > : pdata(that.pdata) {} > regex_iterator& operator=(const regex_iterator& that) > { > pdata = that.pdata; > return *this; > } > bool operator==(const regex_iterator& that)const > { > if((pdata.get() == 0) || (that.pdata.get() == 0)) > return pdata.get() == that.pdata.get(); > return pdata->compare(*(that.pdata.get())); > } > bool operator!=(const regex_iterator& that)const > { return !(*this == that); } > const value_type& operator*()const > { return pdata->get(); } > const value_type* operator->()const > { return &(pdata->get()); } > regex_iterator& operator++() > { > cow(); > if(0 == pdata->next()) > { > pdata.reset(); > } > return *this; > } > regex_iterator operator++(int) > { > regex_iterator result(*this); > ++(*this); > return result; > } >private: > > pimpl pdata; > > void cow() > { > > if(pdata.get() && !pdata.unique()) > { > pdata.reset(new impl(*(pdata.get()))); > } > } >}; > >typedef regex_iterator<const char*> cregex_iterator; >typedef regex_iterator<std::string::const_iterator> sregex_iterator; > >typedef regex_iterator<const wchar_t*> wcregex_iterator; >typedef regex_iterator<std::wstring::const_iterator> wsregex_iterator; > > > >template <class charT, class traits> >inline regex_iterator<const charT*, charT, traits> make_regex_iterator(const charT* p, const basic_regex<charT, traits>& e, regex_constants::match_flag_type m = regex_constants::match_default) >{ > return regex_iterator<const charT*, charT, traits>(p, p+traits::length(p), e, m); >} >template <class charT, class traits, class ST, class SA> >inline regex_iterator<typename std::basic_string<charT, ST, SA>::const_iterator, charT, traits> make_regex_iterator(const std::basic_string<charT, ST, SA>& p, const basic_regex<charT, traits>& e, regex_constants::match_flag_type m = regex_constants::match_default) >{ > return regex_iterator<typename std::basic_string<charT, ST, SA>::const_iterator, charT, traits>(p.begin(), p.end(), e, m); >} ># 198 "/usr/include/boost/regex/v4/regex_iterator.hpp" 3 4 >} ># 152 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_token_iterator.hpp" 1 3 4 ># 37 "/usr/include/boost/regex/v4/regex_token_iterator.hpp" 3 4 >namespace boost{ ># 54 "/usr/include/boost/regex/v4/regex_token_iterator.hpp" 3 4 >template <class BidirectionalIterator, > class charT, > class traits> >class regex_token_iterator_implementation >{ > typedef basic_regex<charT, traits> regex_type; > typedef sub_match<BidirectionalIterator> value_type; > > match_results<BidirectionalIterator> what; > BidirectionalIterator base; > BidirectionalIterator end; > const regex_type re; > match_flag_type flags; > value_type result; > int N; > std::vector<int> subs; > >public: > regex_token_iterator_implementation(const regex_type* p, BidirectionalIterator last, int sub, match_flag_type f) > : end(last), re(*p), flags(f){ subs.push_back(sub); } > regex_token_iterator_implementation(const regex_type* p, BidirectionalIterator last, const std::vector<int>& v, match_flag_type f) > : end(last), re(*p), flags(f), subs(v){} ># 94 "/usr/include/boost/regex/v4/regex_token_iterator.hpp" 3 4 > template <std::size_t CN> > regex_token_iterator_implementation(const regex_type* p, BidirectionalIterator last, const int (&submatches)[CN], match_flag_type f) > : end(last), re(*p), flags(f) > { > for(std::size_t i = 0; i < CN; ++i) > { > subs.push_back(submatches[i]); > } > } > > > bool init(BidirectionalIterator first) > { > N = 0; > base = first; > if(regex_search(first, end, what, re, flags, base) == true) > { > N = 0; > result = ((subs[N] == -1) ? what.prefix() : what[(int)subs[N]]); > return true; > } > else if((subs[N] == -1) && (first != end)) > { > result.first = first; > result.second = end; > result.matched = (first != end); > N = -1; > return true; > } > return false; > } > bool compare(const regex_token_iterator_implementation& that) > { > if(this == &that) return true; > return (&re.get_data() == &that.re.get_data()) > && (end == that.end) > && (flags == that.flags) > && (N == that.N) > && (what[0].first == that.what[0].first) > && (what[0].second == that.what[0].second); > } > const value_type& get() > { return result; } > bool next() > { > if(N == -1) > return false; > if(N+1 < (int)subs.size()) > { > ++N; > result =((subs[N] == -1) ? what.prefix() : what[subs[N]]); > return true; > } > > > BidirectionalIterator last_end(what[0].second); > if(regex_search(last_end, end, what, re, ((what[0].first == what[0].second) ? flags | regex_constants::match_not_initial_null : flags), base)) > { > N =0; > result =((subs[N] == -1) ? what.prefix() : what[subs[N]]); > return true; > } > else if((last_end != end) && (subs[0] == -1)) > { > N =-1; > result.first = last_end; > result.second = end; > result.matched = (last_end != end); > return true; > } > return false; > } >private: > regex_token_iterator_implementation& operator=(const regex_token_iterator_implementation&); >}; > >template <class BidirectionalIterator, > class charT = typename re_detail::regex_iterator_traits<BidirectionalIterator>::value_type, > class traits = regex_traits<charT> > >class regex_token_iterator > > : public std::iterator< > std::forward_iterator_tag, > sub_match<BidirectionalIterator>, > typename re_detail::regex_iterator_traits<BidirectionalIterator>::difference_type, > const sub_match<BidirectionalIterator>*, > const sub_match<BidirectionalIterator>& > > >{ >private: > typedef regex_token_iterator_implementation<BidirectionalIterator, charT, traits> impl; > typedef shared_ptr<impl> pimpl; >public: > typedef basic_regex<charT, traits> regex_type; > typedef sub_match<BidirectionalIterator> value_type; > typedef typename re_detail::regex_iterator_traits<BidirectionalIterator>::difference_type > difference_type; > typedef const value_type* pointer; > typedef const value_type& reference; > typedef std::forward_iterator_tag iterator_category; > > regex_token_iterator(){} > regex_token_iterator(BidirectionalIterator a, BidirectionalIterator b, const regex_type& re, > int submatch = 0, match_flag_type m = match_default) > : pdata(new impl(&re, b, submatch, m)) > { > if(!pdata->init(a)) > pdata.reset(); > } > regex_token_iterator(BidirectionalIterator a, BidirectionalIterator b, const regex_type& re, > const std::vector<int>& submatches, match_flag_type m = match_default) > : pdata(new impl(&re, b, submatches, m)) > { > if(!pdata->init(a)) > pdata.reset(); > } ># 224 "/usr/include/boost/regex/v4/regex_token_iterator.hpp" 3 4 > template <std::size_t N> > regex_token_iterator(BidirectionalIterator a, BidirectionalIterator b, const regex_type& re, > const int (&submatches)[N], match_flag_type m = match_default) > : pdata(new impl(&re, b, submatches, m)) > { > if(!pdata->init(a)) > pdata.reset(); > } > > > regex_token_iterator(const regex_token_iterator& that) > : pdata(that.pdata) {} > regex_token_iterator& operator=(const regex_token_iterator& that) > { > pdata = that.pdata; > return *this; > } > bool operator==(const regex_token_iterator& that)const > { > if((pdata.get() == 0) || (that.pdata.get() == 0)) > return pdata.get() == that.pdata.get(); > return pdata->compare(*(that.pdata.get())); > } > bool operator!=(const regex_token_iterator& that)const > { return !(*this == that); } > const value_type& operator*()const > { return pdata->get(); } > const value_type* operator->()const > { return &(pdata->get()); } > regex_token_iterator& operator++() > { > cow(); > if(0 == pdata->next()) > { > pdata.reset(); > } > return *this; > } > regex_token_iterator operator++(int) > { > regex_token_iterator result(*this); > ++(*this); > return result; > } >private: > > pimpl pdata; > > void cow() > { > > if(pdata.get() && !pdata.unique()) > { > pdata.reset(new impl(*(pdata.get()))); > } > } >}; > >typedef regex_token_iterator<const char*> cregex_token_iterator; >typedef regex_token_iterator<std::string::const_iterator> sregex_token_iterator; > >typedef regex_token_iterator<const wchar_t*> wcregex_token_iterator; >typedef regex_token_iterator<std::wstring::const_iterator> wsregex_token_iterator; > > >template <class charT, class traits> >inline regex_token_iterator<const charT*, charT, traits> make_regex_token_iterator(const charT* p, const basic_regex<charT, traits>& e, int submatch = 0, regex_constants::match_flag_type m = regex_constants::match_default) >{ > return regex_token_iterator<const charT*, charT, traits>(p, p+traits::length(p), e, submatch, m); >} >template <class charT, class traits, class ST, class SA> >inline regex_token_iterator<typename std::basic_string<charT, ST, SA>::const_iterator, charT, traits> make_regex_token_iterator(const std::basic_string<charT, ST, SA>& p, const basic_regex<charT, traits>& e, int submatch = 0, regex_constants::match_flag_type m = regex_constants::match_default) >{ > return regex_token_iterator<typename std::basic_string<charT, ST, SA>::const_iterator, charT, traits>(p.begin(), p.end(), e, submatch, m); >} > >template <class charT, class traits, std::size_t N> >inline regex_token_iterator<const charT*, charT, traits> make_regex_token_iterator(const charT* p, const basic_regex<charT, traits>& e, const int (&submatch)[N], regex_constants::match_flag_type m = regex_constants::match_default) >{ > return regex_token_iterator<const charT*, charT, traits>(p, p+traits::length(p), e, submatch, m); >} >template <class charT, class traits, class ST, class SA, std::size_t N> >inline regex_token_iterator<typename std::basic_string<charT, ST, SA>::const_iterator, charT, traits> make_regex_token_iterator(const std::basic_string<charT, ST, SA>& p, const basic_regex<charT, traits>& e, const int (&submatch)[N], regex_constants::match_flag_type m = regex_constants::match_default) >{ > return regex_token_iterator<typename std::basic_string<charT, ST, SA>::const_iterator, charT, traits>(p.begin(), p.end(), e, submatch, m); >} > >template <class charT, class traits> >inline regex_token_iterator<const charT*, charT, traits> make_regex_token_iterator(const charT* p, const basic_regex<charT, traits>& e, const std::vector<int>& submatch, regex_constants::match_flag_type m = regex_constants::match_default) >{ > return regex_token_iterator<const charT*, charT, traits>(p, p+traits::length(p), e, submatch, m); >} >template <class charT, class traits, class ST, class SA> >inline regex_token_iterator<typename std::basic_string<charT, ST, SA>::const_iterator, charT, traits> make_regex_token_iterator(const std::basic_string<charT, ST, SA>& p, const basic_regex<charT, traits>& e, const std::vector<int>& submatch, regex_constants::match_flag_type m = regex_constants::match_default) >{ > return regex_token_iterator<typename std::basic_string<charT, ST, SA>::const_iterator, charT, traits>(p.begin(), p.end(), e, submatch, m); >} ># 336 "/usr/include/boost/regex/v4/regex_token_iterator.hpp" 3 4 >} ># 155 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_grep.hpp" 1 3 4 ># 23 "/usr/include/boost/regex/v4/regex_grep.hpp" 3 4 >namespace boost{ ># 40 "/usr/include/boost/regex/v4/regex_grep.hpp" 3 4 >template <class Predicate, class BidiIterator, class charT, class traits> >inline unsigned int regex_grep(Predicate foo, > BidiIterator first, > BidiIterator last, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > if(e.flags() & regex_constants::failbit) > return false; > > typedef typename match_results<BidiIterator>::allocator_type match_allocator_type; > > match_results<BidiIterator> m; > re_detail::perl_matcher<BidiIterator, match_allocator_type, traits> matcher(first, last, m, e, flags, first); > unsigned int count = 0; > while(matcher.find()) > { > ++count; > if(0 == foo(m)) > return count; > if(m[0].second == last) > return count; > if(m.length() == 0) > { > if(m[0].second == last) > return count; > > > match_results<BidiIterator, match_allocator_type> m2(m); > matcher.setf(match_not_null | match_continuous); > if(matcher.find()) > { > ++count; > if(0 == foo(m)) > return count; > } > else > { > > m = m2; > } > matcher.unsetf((match_not_null | match_continuous) & ~flags); > } > } > return count; >} ># 94 "/usr/include/boost/regex/v4/regex_grep.hpp" 3 4 >template <class Predicate, class charT, class traits> >inline unsigned int regex_grep(Predicate foo, const charT* str, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > return regex_grep(foo, str, str + traits::length(str), e, flags); >} > >template <class Predicate, class ST, class SA, class charT, class traits> >inline unsigned int regex_grep(Predicate foo, const std::basic_string<charT, ST, SA>& s, > const basic_regex<charT, traits>& e, > match_flag_type flags = match_default) >{ > return regex_grep(foo, s.begin(), s.end(), e, flags); >} ># 152 "/usr/include/boost/regex/v4/regex_grep.hpp" 3 4 >} ># 158 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_replace.hpp" 1 3 4 ># 25 "/usr/include/boost/regex/v4/regex_replace.hpp" 3 4 >namespace boost{ ># 38 "/usr/include/boost/regex/v4/regex_replace.hpp" 3 4 >template <class OutputIterator, class BidirectionalIterator, class traits, class charT, class Formatter> >OutputIterator regex_replace(OutputIterator out, > BidirectionalIterator first, > BidirectionalIterator last, > const basic_regex<charT, traits>& e, > Formatter fmt, > match_flag_type flags = match_default) >{ > regex_iterator<BidirectionalIterator, charT, traits> i(first, last, e, flags); > regex_iterator<BidirectionalIterator, charT, traits> j; > if(i == j) > { > if(!(flags & regex_constants::format_no_copy)) > out = re_detail::copy(first, last, out); > } > else > { > BidirectionalIterator last_m(first); > while(i != j) > { > if(!(flags & regex_constants::format_no_copy)) > out = re_detail::copy(i->prefix().first, i->prefix().second, out); > out = i->format(out, fmt, flags, e); > last_m = (*i)[0].second; > if(flags & regex_constants::format_first_only) > break; > ++i; > } > if(!(flags & regex_constants::format_no_copy)) > out = re_detail::copy(last_m, last, out); > } > return out; >} > >template <class traits, class charT, class Formatter> >std::basic_string<charT> regex_replace(const std::basic_string<charT>& s, > const basic_regex<charT, traits>& e, > Formatter fmt, > match_flag_type flags = match_default) >{ > std::basic_string<charT> result; > re_detail::string_out_iterator<std::basic_string<charT> > i(result); > regex_replace(i, s.begin(), s.end(), e, fmt, flags); > return result; >} ># 95 "/usr/include/boost/regex/v4/regex_replace.hpp" 3 4 >} ># 161 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_merge.hpp" 1 3 4 ># 25 "/usr/include/boost/regex/v4/regex_merge.hpp" 3 4 >namespace boost{ ># 38 "/usr/include/boost/regex/v4/regex_merge.hpp" 3 4 >template <class OutputIterator, class Iterator, class traits, class charT> >inline OutputIterator regex_merge(OutputIterator out, > Iterator first, > Iterator last, > const basic_regex<charT, traits>& e, > const charT* fmt, > match_flag_type flags = match_default) >{ > return regex_replace(out, first, last, e, fmt, flags); >} > >template <class OutputIterator, class Iterator, class traits, class charT> >inline OutputIterator regex_merge(OutputIterator out, > Iterator first, > Iterator last, > const basic_regex<charT, traits>& e, > const std::basic_string<charT>& fmt, > match_flag_type flags = match_default) >{ > return regex_merge(out, first, last, e, fmt.c_str(), flags); >} > >template <class traits, class charT> >inline std::basic_string<charT> regex_merge(const std::basic_string<charT>& s, > const basic_regex<charT, traits>& e, > const charT* fmt, > match_flag_type flags = match_default) >{ > return regex_replace(s, e, fmt, flags); >} > >template <class traits, class charT> >inline std::basic_string<charT> regex_merge(const std::basic_string<charT>& s, > const basic_regex<charT, traits>& e, > const std::basic_string<charT>& fmt, > match_flag_type flags = match_default) >{ > return regex_replace(s, e, fmt, flags); >} ># 89 "/usr/include/boost/regex/v4/regex_merge.hpp" 3 4 >} ># 164 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 > > ># 1 "/usr/include/boost/regex/v4/regex_split.hpp" 1 3 4 ># 24 "/usr/include/boost/regex/v4/regex_split.hpp" 3 4 >namespace boost{ ># 42 "/usr/include/boost/regex/v4/regex_split.hpp" 3 4 >namespace re_detail{ > >template <class charT> >const basic_regex<charT>& get_default_expression(charT) >{ > static const charT expression_text[4] = { '\\', 's', '+', '\00', }; > static const basic_regex<charT> e(expression_text); > return e; >} > >template <class OutputIterator, class charT, class Traits1, class Alloc1> >class split_pred >{ > typedef std::basic_string<charT, Traits1, Alloc1> string_type; > typedef typename string_type::const_iterator iterator_type; > iterator_type* p_last; > OutputIterator* p_out; > std::size_t* p_max; > std::size_t initial_max; >public: > split_pred(iterator_type* a, OutputIterator* b, std::size_t* c) > : p_last(a), p_out(b), p_max(c), initial_max(*c) {} > > bool operator()(const match_results<iterator_type>& what); >}; > >template <class OutputIterator, class charT, class Traits1, class Alloc1> >bool split_pred<OutputIterator, charT, Traits1, Alloc1>::operator() > (const match_results<iterator_type>& what) >{ > *p_last = what[0].second; > if(what.size() > 1) > { > > for(unsigned i = 1; i < what.size(); ++i) > { > *(*p_out) = what.str(i); > ++(*p_out); > if(0 == --*p_max) return false; > } > return *p_max != 0; > } > else > { > > const sub_match<iterator_type>& sub = what[-1]; > if((sub.first != sub.second) || (*p_max != initial_max)) > { > *(*p_out) = sub.str(); > ++(*p_out); > return --*p_max; > } > } > > > return true; >} > >} > >template <class OutputIterator, class charT, class Traits1, class Alloc1, class Traits2> >std::size_t regex_split(OutputIterator out, > std::basic_string<charT, Traits1, Alloc1>& s, > const basic_regex<charT, Traits2>& e, > match_flag_type flags, > std::size_t max_split) >{ > typedef typename std::basic_string<charT, Traits1, Alloc1>::const_iterator ci_t; > > ci_t last = s.begin(); > std::size_t init_size = max_split; > re_detail::split_pred<OutputIterator, charT, Traits1, Alloc1> pred(&last, &out, &max_split); > ci_t i, j; > i = s.begin(); > j = s.end(); > regex_grep(pred, i, j, e, flags); > > > > > if(max_split && (last != s.end()) && (e.mark_count() == 1)) > { > *out = std::basic_string<charT, Traits1, Alloc1>((ci_t)last, (ci_t)s.end()); > ++out; > last = s.end(); > --max_split; > } > > > s.erase(0, last - s.begin()); > > > return init_size - max_split; >} > >template <class OutputIterator, class charT, class Traits1, class Alloc1, class Traits2> >inline std::size_t regex_split(OutputIterator out, > std::basic_string<charT, Traits1, Alloc1>& s, > const basic_regex<charT, Traits2>& e, > match_flag_type flags = match_default) >{ > return regex_split(out, s, e, flags, (2147483647 * 2U + 1U)); >} > >template <class OutputIterator, class charT, class Traits1, class Alloc1> >inline std::size_t regex_split(OutputIterator out, > std::basic_string<charT, Traits1, Alloc1>& s) >{ > return regex_split(out, s, re_detail::get_default_expression(charT(0)), match_default, (2147483647 * 2U + 1U)); >} ># 168 "/usr/include/boost/regex/v4/regex_split.hpp" 3 4 >} ># 167 "/usr/include/boost/regex/v4/regex.hpp" 2 3 4 ># 32 "/usr/include/boost/regex.hpp" 2 3 4 ># 32 "/c/honeypenny/contrib/epee/include/net/http_base.h" 2 > > >namespace epee >{ >namespace net_utils >{ > namespace http > { > > enum http_method{ > http_method_get, > http_method_post, > http_method_put, > http_method_head, > http_method_etc, > http_method_unknown > }; > > enum http_content_type > { > http_content_type_text_html, > http_content_type_image_gif, > http_content_type_other, > http_content_type_not_set > }; > > typedef std::list<std::pair<std::string, std::string> > fields_list; > > inline > std::string get_value_from_fields_list(const std::string& param_name, const net_utils::http::fields_list& fields) > { > fields_list::const_iterator it = fields.begin(); > for(; it != fields.end(); it++) > if(!string_tools::compare_no_case(param_name, it->first)) > break; > > if(it==fields.end()) > return std::string(); > > return it->second; > } > > > inline > std::string get_value_from_uri_line(const std::string& param_name, const std::string& uri) > { > std::string buff = "([\\?|&])"; > buff += param_name + "=([^&]*)"; > boost::regex match_param(buff.c_str(), boost::regex::icase | boost::regex::normal); > boost::smatch result; > if(boost::regex_search(uri, result, match_param, boost::match_default) && result[0].matched) > { > return result[2]; > } > return std::string(); > } > > > > struct http_header_info > { > std::string m_connection; > std::string m_referer; > std::string m_content_length; > std::string m_content_type; > std::string m_transfer_encoding; > std::string m_content_encoding; > std::string m_host; > std::string m_cookie; > fields_list m_etc_fields; > > void clear() > { > m_connection.clear(); > m_referer.clear(); > m_content_length.clear(); > m_content_type.clear(); > m_transfer_encoding.clear(); > m_content_encoding.clear(); > m_host.clear(); > m_cookie.clear(); > m_etc_fields.clear(); > } > }; > > struct uri_content > { > std::string m_path; > std::string m_query; > std::string m_fragment; > std::list<std::pair<std::string, std::string> > m_query_params; > }; > > struct url_content > { > std::string schema; > std::string host; > std::string uri; > uint64_t port; > uri_content m_uri_content; > }; > > > struct http_request_info > { > http_request_info():m_http_method(http_method_unknown), > m_http_ver_hi(0), > m_http_ver_lo(0), > m_have_to_block(false) > {} > > http_method m_http_method; > std::string m_URI; > std::string m_http_method_str; > std::string m_full_request_str; > std::string m_replace_html; > std::string m_request_head; > int m_http_ver_hi; > int m_http_ver_lo; > bool m_have_to_block; > http_header_info m_header_info; > uri_content m_uri_content; > size_t m_full_request_buf_size; > std::string m_body; > > void clear() > { > this->~http_request_info(); > new(this) http_request_info(); > } > }; > > > struct http_response_info > { > int m_response_code; > std::string m_response_comment; > fields_list m_additional_fields; > std::string m_body; > std::string m_mime_tipe; > http_header_info m_header_info; > int m_http_ver_hi; > int m_http_ver_lo; > > void clear() > { > this->~http_response_info(); > new(this) http_response_info(); > } > }; > } >} >} ># 37 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.h" 2 > >namespace epee >{ >namespace net_utils >{ > namespace http > { > > > > > > struct http_server_config > { > std::string m_folder; > critical_section m_lock; > }; > > > > > template<class t_connection_context = net_utils::connection_context_base> > class simple_http_connection_handler > { > public: > typedef t_connection_context connection_context; > typedef http_server_config config_type; > > simple_http_connection_handler(i_service_endpoint* psnd_hndlr, config_type& config); > virtual ~simple_http_connection_handler(){} > > bool release_protocol() > { > return true; > } > > virtual bool thread_init() > { > return true; > } > > virtual bool thread_deinit() > { > return true; > } > bool after_init_connection() > { > return true; > } > virtual bool handle_recv(const void* ptr, size_t cb); > virtual bool handle_request(const http::http_request_info& query_info, http_response_info& response); > > > > > > private: > enum machine_state{ > http_state_retriving_comand_line, > http_state_retriving_header, > http_state_retriving_body, > http_state_connection_close, > http_state_error > }; > > enum body_transfer_type{ > http_body_transfer_chunked, > http_body_transfer_measure, > http_body_transfer_chunked_instead_measure, > http_body_transfer_connection_close, > http_body_transfer_multipart, > http_body_transfer_undefined > }; > > bool handle_buff_in(std::string& buf); > > bool analize_cached_request_header_and_invoke_state(size_t pos); > > bool handle_invoke_query_line(); > bool parse_cached_header(http_header_info& body_info, const std::string& m_cache_to_process, size_t pos); > std::string::size_type match_end_of_header(const std::string& buf); > bool get_len_from_content_lenght(const std::string& str, size_t& len); > bool handle_retriving_query_body(); > bool handle_query_measure(); > bool set_ready_state(); > bool slash_to_back_slash(std::string& str); > std::string get_file_mime_tipe(const std::string& path); > std::string get_response_header(const http_response_info& response); > > > inline bool handle_request_and_send_response(const http::http_request_info& query_info); > > > std::string get_not_found_response_body(const std::string& URI); > > std::string m_root_path; > std::string m_cache; > machine_state m_state; > body_transfer_type m_body_transfer_type; > bool m_is_stop_handling; > http::http_request_info m_query_info; > size_t m_len_summary, m_len_remain; > config_type& m_config; > bool m_want_close; > protected: > i_service_endpoint* m_psnd_hndlr; > }; > > template<class t_connection_context> > struct i_http_server_handler > { > virtual ~i_http_server_handler(){} > virtual bool handle_http_request(const http_request_info& query_info, http_response_info& response, t_connection_context& m_conn_context)=0; > virtual bool init_server_thread(){return true;} > virtual bool deinit_server_thread(){return true;} > }; > > template<class t_connection_context> > struct custum_handler_config: public http_server_config > { > i_http_server_handler<t_connection_context>* m_phandler; > }; > > > > > > template<class t_connection_context = net_utils::connection_context_base> > class http_custom_handler: public simple_http_connection_handler<t_connection_context> > { > public: > typedef custum_handler_config<t_connection_context> config_type; > > http_custom_handler(i_service_endpoint* psnd_hndlr, config_type& config, t_connection_context& conn_context):simple_http_connection_handler<t_connection_context>(psnd_hndlr, config), > m_config(config), > m_conn_context(conn_context) > {} > inline bool handle_request(const http_request_info& query_info, http_response_info& response) > { > do{if(!(m_config.m_phandler)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.h" << ":" << 176 << "|" << __FUNCTION__ << "|" << "m_config.m_phandler is NULL!!!!" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > response.m_mime_tipe = "text/plain"; > response.m_response_code = 200; > response.m_response_comment = "OK"; > response.m_body.clear(); > return m_config.m_phandler->handle_http_request(query_info, response, m_conn_context); > } > > virtual bool thread_init() > { > return m_config.m_phandler->init_server_thread();; > } > > virtual bool thread_deinit() > { > return m_config.m_phandler->deinit_server_thread(); > } > void handle_qued_callback() > {} > bool after_init_connection() > { > return true; > } > > private: > > config_type& m_config; > t_connection_context& m_conn_context; > }; > } >} >} > ># 1 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" 1 ># 30 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" ># 1 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.h" 1 ># 31 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" 2 ># 1 "/c/honeypenny/contrib/epee/include/reg_exp_definer.h" 1 ># 34 "/c/honeypenny/contrib/epee/include/reg_exp_definer.h" >namespace epee >{ > class global_regexp_critical_section > { > private: > mutable critical_section regexp_lock; > public: > global_regexp_critical_section(){} > critical_section& get_lock()const {return regexp_lock;} > }; > > const static global_regexp_critical_section gregexplock; ># 82 "/c/honeypenny/contrib/epee/include/reg_exp_definer.h" >} ># 32 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" 2 > ># 1 "/c/honeypenny/contrib/epee/include/file_io_utils.h" 1 ># 53 "/c/honeypenny/contrib/epee/include/file_io_utils.h" >namespace epee >{ >namespace file_io_utils >{ ># 222 "/c/honeypenny/contrib/epee/include/file_io_utils.h" > inline > bool is_file_exist(const std::string& path) > { > boost::filesystem::path p(path); > return boost::filesystem::exists(p); > } ># 258 "/c/honeypenny/contrib/epee/include/file_io_utils.h" > inline > bool save_string_to_file(const std::string& path_to_file, const std::string& str) > { > > try > { > std::ofstream fstream; > fstream.exceptions(std::ifstream::failbit | std::ifstream::badbit); > fstream.open(path_to_file, std::ios_base::binary | std::ios_base::out | std::ios_base::trunc); > fstream << str; > fstream.close(); > return true; > } > > catch(...) > { > return false; > } > } ># 304 "/c/honeypenny/contrib/epee/include/file_io_utils.h" > inline > bool get_file_time(const std::string& path_to_file, time_t& ft) > { > boost::system::error_code ec; > ft = boost::filesystem::last_write_time(boost::filesystem::path(path_to_file), ec); > if(!ec) > return true; > else > return false; > } > > inline > bool set_file_time(const std::string& path_to_file, const time_t& ft) > { > boost::system::error_code ec; > boost::filesystem::last_write_time(boost::filesystem::path(path_to_file), ft, ec); > if(!ec) > return true; > else > return false; > } > > > inline > bool load_file_to_string(const std::string& path_to_file, std::string& target_str) > { > try > { > std::ifstream fstream; > fstream.exceptions(std::ifstream::failbit | std::ifstream::badbit); > fstream.open(path_to_file, std::ios_base::binary | std::ios_base::in | std::ios::ate); > > std::ifstream::pos_type file_size = fstream.tellg(); > > if(file_size > 1000000000) > return false; > size_t file_size_t = static_cast<size_t>(file_size); > > target_str.resize(file_size_t); > > fstream.seekg (0, std::ios::beg); > fstream.read((char*)target_str.data(), target_str.size()); > fstream.close(); > return true; > } > > catch(...) > { > return false; > } > } > > inline > bool append_string_to_file(const std::string& path_to_file, const std::string& str) > { > try > { > std::ofstream fstream; > fstream.exceptions(std::ifstream::failbit | std::ifstream::badbit); > fstream.open(path_to_file.c_str(), std::ios_base::binary | std::ios_base::out | std::ios_base::app); > fstream << str; > fstream.close(); > return true; > } > > catch(...) > { > return false; > } > } ># 429 "/c/honeypenny/contrib/epee/include/file_io_utils.h" > inline bool get_folder_content(const std::string& path, std::list<std::string>& target_list, bool only_files = false) > { > try > { > > boost::filesystem::directory_iterator end_itr; > for ( boost::filesystem::directory_iterator itr( path ); itr != end_itr; ++itr ) > { > if ( only_files && boost::filesystem::is_directory(itr->status()) ) > { > continue; > } > target_list.push_back(itr->path().filename().string()); > } > > } > > catch(...) > { > return false; > } > return true; > } >} >} ># 34 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" 2 ># 1 "/c/honeypenny/contrib/epee/include/net/net_parse_helpers.h" 1 ># 30 "/c/honeypenny/contrib/epee/include/net/net_parse_helpers.h" > > > > > >namespace epee >{ >namespace net_utils >{ > > inline bool parse_uri_query(const std::string& query, std::list<std::pair<std::string, std::string> >& params) > { > enum state > { > st_param_name, > st_param_val > }; > state st = st_param_name; > std::string::const_iterator start_it = query.begin(); > std::pair<std::string, std::string> e; > for(std::string::const_iterator it = query.begin(); it != query.end(); it++) > { > switch(st) > { > case st_param_name: > if(*it == '=') > { > e.first.assign(start_it, it); > start_it = it;++start_it; > st = st_param_val; > } > break; > case st_param_val: > if(*it == '&') > { > e.second.assign(start_it, it); > start_it = it;++start_it; > params.push_back(e); > e.first.clear();e.second.clear(); > st = st_param_name; > } > break; > default: > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_parse_helpers.h" << ":" << 73 << "|" << __FUNCTION__ << "|" << "Unknown state " << (int)st << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > } > if(st == st_param_name) > { > if(start_it != query.end()) > { > e.first.assign(start_it, query.end()); > params.push_back(e); > } > }else > { > if(start_it != query.end()) > e.second.assign(start_it, query.end()); > > if(e.first.size()) > params.push_back(e); > } > return true; > } > > inline > bool parse_uri(const std::string uri, http::uri_content& content) > { > > > content.m_query_params.clear(); > static volatile uint32_t regexp_initialized_1 = 0; volatile uint32_t local_is_initialized_1 = regexp_initialized_1; if(!local_is_initialized_1) gregexplock.get_lock().lock(); static const boost::regex rexp_match_uri("^([^?#]*)(\\?([^#]*))?(#(.*))?" , boost::regex::icase | boost::regex::normal); if(!local_is_initialized_1){ boost::interprocess::ipcdetail::atomic_write32(®exp_initialized_1, 1); gregexplock.get_lock().unlock();}; > > boost::smatch result; > if(!boost::regex_search(uri, result, rexp_match_uri, boost::match_default) && result[0].matched) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[PARSE URI] regex not matched for uri: " << uri << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > content.m_path = uri; > return true; > } > if(result[1].matched) > { > content.m_path = result[1]; > } > if(result[3].matched) > { > content.m_query = result[3]; > } > if(result[5].matched) > { > content.m_fragment = result[5]; > } > if(content.m_query.size()) > { > parse_uri_query(content.m_query, content.m_query_params); > } > return true; > } > > > inline > bool parse_url(const std::string url_str, http::url_content& content) > { > > > > static volatile uint32_t regexp_initialized_1 = 0; volatile uint32_t local_is_initialized_1 = regexp_initialized_1; if(!local_is_initialized_1) gregexplock.get_lock().lock(); static const boost::regex rexp_match_uri("^((.*?)://)?(([^/:]*)(:(\\d+))?)(.*)?" , boost::regex::icase | boost::regex::normal); if(!local_is_initialized_1){ boost::interprocess::ipcdetail::atomic_write32(®exp_initialized_1, 1); gregexplock.get_lock().unlock();}; > > content.port = 0; > boost::smatch result; > if(!boost::regex_search(url_str, result, rexp_match_uri, boost::match_default) && result[0].matched) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[PARSE URI] regex not matched for uri: " << rexp_match_uri << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > > return true; > } > if(result[2].matched) > { > content.schema = result[2]; > } > if(result[4].matched) > { > content.host = result[4]; > } > if(result[6].matched) > { > content.port = boost::lexical_cast<uint64_t>(result[6]); > } > if(result[7].matched) > { > content.uri = result[7]; > return parse_uri(result[7], content.m_uri_content); > } > > return true; > } > >} >} ># 35 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" 2 > > > > >namespace epee >{ >namespace net_utils >{ > namespace http > { > > struct multipart_entry > { > std::list<std::pair<std::string, std::string> > m_etc_header_fields; > std::string m_content_disposition; > std::string m_content_type; > std::string m_body; > }; > > inline > bool match_boundary(const std::string& content_type, std::string& boundary) > { > static volatile uint32_t regexp_initialized_1 = 0; volatile uint32_t local_is_initialized_1 = regexp_initialized_1; if(!local_is_initialized_1) gregexplock.get_lock().lock(); static const boost::regex rexp_match_boundary("boundary=(.*?)(($)|([;\\s,]))" , boost::regex::icase | boost::regex::normal); if(!local_is_initialized_1){ boost::interprocess::ipcdetail::atomic_write32(®exp_initialized_1, 1); gregexplock.get_lock().unlock();}; > > boost::smatch result; > if(boost::regex_search(content_type, result, rexp_match_boundary, boost::match_default) && result[0].matched) > { > boundary = result[1]; > return true; > } > > return false; > } > > inline > bool parse_header(std::string::const_iterator it_begin, std::string::const_iterator it_end, multipart_entry& entry) > { > static volatile uint32_t regexp_initialized_1 = 0; volatile uint32_t local_is_initialized_1 = regexp_initialized_1; if(!local_is_initialized_1) gregexplock.get_lock().lock(); static const boost::regex rexp_mach_field("\n?((Content-Disposition)|(Content-Type)" "|([\\w-]+?)) ?: ?((.*?)(\r?\n))[^\t ]" , boost::regex::icase | boost::regex::normal); if(!local_is_initialized_1){ boost::interprocess::ipcdetail::atomic_write32(®exp_initialized_1, 1); gregexplock.get_lock().unlock();} > > > > > ; > > boost::smatch result; > std::string::const_iterator it_current_bound = it_begin; > std::string::const_iterator it_end_bound = it_end; > > > while( boost::regex_search( it_current_bound, it_end_bound, result, rexp_mach_field, boost::match_default) && result[0].matched) > { > const size_t field_val = 6; > const size_t field_etc_name = 4; > > int i = 2; > if(result[i++].matched) > entry.m_content_disposition = result[field_val]; > else if(result[i++].matched) > entry.m_content_type = result[field_val]; > else if(result[i++].matched) > entry.m_etc_header_fields.push_back(std::pair<std::string, std::string>(result[field_etc_name], result[field_val])); > else > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 98 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler::parse_header() not matched last entry in:"<<std::string(it_current_bound, it_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > } > > it_current_bound = result[(int)result.size()-1].first; > } > return true; > } > > inline > bool handle_part_of_multipart(std::string::const_iterator it_begin, std::string::const_iterator it_end, multipart_entry& entry) > { > std::string end_str = "\r\n\r\n"; > std::string::const_iterator end_header_it = std::search(it_begin, it_end, end_str.begin(), end_str.end()); > if(end_header_it == it_end) > { > > return false; > } > > if(!parse_header(it_begin, end_header_it+4, entry)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 119 << "|" << __FUNCTION__ << "|" << "Failed to parse header:" << std::string(it_begin, end_header_it+2) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > entry.m_body.assign(end_header_it+4, it_end); > > return true; > } > > inline > bool parse_multipart_body(const std::string& content_type, const std::string& body, std::list<multipart_entry>& out_values) > { > > > std::string boundary; > if(!match_boundary(content_type, boundary)) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to match boundary in content type: " << content_type << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return false; > } > > boundary+="\r\n"; > bool is_stop = false; > bool first_step = true; > > std::string::const_iterator it_begin = body.begin(); > std::string::const_iterator it_end; > while(!is_stop) > { > std::string::size_type pos = body.find(boundary, std::distance(body.begin(), it_begin)); > > if(std::string::npos == pos) > { > is_stop = true; > boundary.erase(boundary.size()-2, 2); > boundary+= "--"; > pos = body.find(boundary, std::distance(body.begin(), it_begin)); > if(std::string::npos == pos) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Error: Filed to match closing multipart tag" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > it_end = body.end(); > }else > { > it_end = body.begin() + pos; > } > }else > it_end = body.begin() + pos; > > > if(first_step && !is_stop) > { > first_step = false; > it_begin = it_end + boundary.size(); > std::string temp = "\r\n--"; > boundary = temp + boundary; > continue; > } > > out_values.push_back(multipart_entry()); > if(!handle_part_of_multipart(it_begin, it_end, out_values.back())) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to handle_part_of_multipart" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return false; > } > > it_begin = it_end + boundary.size(); > } > > return true; > } > > > > > > template<class t_connection_context> > simple_http_connection_handler<t_connection_context>::simple_http_connection_handler(i_service_endpoint* psnd_hndlr, config_type& config): > m_state(http_state_retriving_comand_line), > m_body_transfer_type(http_body_transfer_undefined), > m_is_stop_handling(false), > m_len_summary(0), > m_len_remain(0), > m_config(config), > m_want_close(false), > m_psnd_hndlr(psnd_hndlr) > { > > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::set_ready_state() > { > m_is_stop_handling = false; > m_state = http_state_retriving_comand_line; > m_body_transfer_type = http_body_transfer_undefined; > m_query_info.clear(); > m_len_summary = 0; > return true; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::handle_recv(const void* ptr, size_t cb) > { > std::string buf((const char*)ptr, cb); > > > > bool res = handle_buff_in(buf); > if(m_want_close ) > return false; > return res; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::handle_buff_in(std::string& buf) > { > > if(m_cache.size()) > m_cache += buf; > else > m_cache.swap(buf); > > m_is_stop_handling = false; > while(!m_is_stop_handling) > { > switch(m_state) > { > case http_state_retriving_comand_line: > > > if(!m_cache.size()) > break; > > > if((m_cache[0] == '\r' || m_cache[0] == '\n')) > { > > > m_cache.erase(0, 1); > break; > } > > if(std::string::npos != m_cache.find('\n', 0)) > handle_invoke_query_line(); > else > { > m_is_stop_handling = true; > if(m_cache.size() > 9000) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 268 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler::handle_buff_out: Too long URI line" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_state = http_state_error; > return false; > } > } > break; > case http_state_retriving_header: > { > std::string::size_type pos = match_end_of_header(m_cache); > if(std::string::npos == pos) > { > m_is_stop_handling = true; > if(m_cache.size() > 100000) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 282 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler::handle_buff_in: Too long header area" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_state = http_state_error; > return false; > } > break; > } > analize_cached_request_header_and_invoke_state(pos); > break; > } > case http_state_retriving_body: > return handle_retriving_query_body(); > case http_state_connection_close: > return false; > default: > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 296 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler::handle_char_out: Wrong state: " << m_state << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > case http_state_error: > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 299 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler::handle_char_out: Error state!!!" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > if(!m_cache.size()) > m_is_stop_handling = true; > } > > return true; > } > > inline bool analize_http_method(const boost::smatch& result, http::http_method& method, int& http_ver_major, int& http_ver_minor) > { > do{if(!(result[0].matched)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 312 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler::analize_http_method() assert failed..." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > http_ver_major = boost::lexical_cast<int>(result[11]); > http_ver_minor = boost::lexical_cast<int>(result[12]); > if(result[4].matched) > method = http::http_method_get; > else if(result[5].matched) > method = http::http_method_head; > else if(result[6].matched) > method = http::http_method_post; > else if(result[7].matched) > method = http::http_method_put; > else > method = http::http_method_etc; > > return true; > } > > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::handle_invoke_query_line() > { > epee::log_space::log_frame frame("simple_http_connection_handler<t_connection_context>::handle_recognize_protocol_out(*)", 3, __null); > > static volatile uint32_t regexp_initialized_1 = 0; volatile uint32_t local_is_initialized_1 = regexp_initialized_1; if(!local_is_initialized_1) gregexplock.get_lock().lock(); static const boost::regex rexp_match_command_line("^(((OPTIONS)|(GET)|(HEAD)|(POST)|(PUT)|(DELETE)|(TRACE)) (\\S+) HTTP/(\\d+).(\\d+))\r?\n" , boost::regex::icase | boost::regex::normal); if(!local_is_initialized_1){ boost::interprocess::ipcdetail::atomic_write32(®exp_initialized_1, 1); gregexplock.get_lock().unlock();}; > > > boost::smatch result; > if(boost::regex_search(m_cache, result, rexp_match_command_line, boost::match_default) && result[0].matched) > { > analize_http_method(result, m_query_info.m_http_method, m_query_info.m_http_ver_hi, m_query_info.m_http_ver_hi); > m_query_info.m_URI = result[10]; > parse_uri(m_query_info.m_URI, m_query_info.m_uri_content); > m_query_info.m_http_method_str = result[2]; > m_query_info.m_full_request_str = result[0]; > > m_cache.erase(m_cache.begin(), to_nonsonst_iterator(m_cache, result[0].second)); > > m_state = http_state_retriving_header; > > return true; > }else > { > m_state = http_state_error; > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 355 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler<t_connection_context>::handle_invoke_query_line(): Failed to match first line: " << m_cache << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > return false; > } > > template<class t_connection_context> > std::string::size_type simple_http_connection_handler<t_connection_context>::match_end_of_header(const std::string& buf) > { > > > std::string::size_type res = buf.find("\r\n\r\n"); > if(std::string::npos != res) > return res+4; > res = buf.find("\n\n"); > if(std::string::npos != res) > return res+2; > return res; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::analize_cached_request_header_and_invoke_state(size_t pos) > { > > > epee::log_space::log_frame frame("simple_http_connection_handler<t_connection_context>::analize_cached_request_header_and_invoke_state(*)", 3, __null); > > m_query_info.m_full_request_buf_size = pos; > m_query_info.m_request_head.assign(m_cache.begin(), m_cache.begin()+pos); > > if(!parse_cached_header(m_query_info.m_header_info, m_cache, pos)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 388 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler<t_connection_context>::analize_cached_request_header_and_invoke_state(): failed to anilize request header: " << m_cache << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_state = http_state_error; > } > > m_cache.erase(0, pos); > > std::string req_command_str = m_query_info.m_full_request_str; > > > if(m_query_info.m_header_info.m_content_length.size()) > { > m_state = http_state_retriving_body; > m_body_transfer_type = http_body_transfer_measure; > if(!get_len_from_content_lenght(m_query_info.m_header_info.m_content_length, m_len_summary)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 403 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler<t_connection_context>::analize_cached_request_header_and_invoke_state(): Failed to get_len_from_content_lenght();, m_query_info.m_content_length="<<m_query_info.m_header_info.m_content_length << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_state = http_state_error; > return false; > } > if(0 == m_len_summary) > { > if(handle_request_and_send_response(m_query_info)) > set_ready_state(); > else > m_state = http_state_error; > } > m_len_remain = m_len_summary; > }else > { > handle_request_and_send_response(m_query_info); > set_ready_state(); > } > > return true; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::handle_retriving_query_body() > { > switch(m_body_transfer_type) > { > case http_body_transfer_measure: > return handle_query_measure(); > case http_body_transfer_chunked: > case http_body_transfer_connection_close: > case http_body_transfer_multipart: > case http_body_transfer_undefined: > default: > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 436 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler<t_connection_context>::handle_retriving_query_body(): Unexpected m_body_query_type state:" << m_body_transfer_type << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_state = http_state_error; > return false; > } > > return true; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::handle_query_measure() > { > > if(m_len_remain >= m_cache.size()) > { > m_len_remain -= m_cache.size(); > m_query_info.m_body += m_cache; > m_cache.clear(); > }else > { > m_query_info.m_body.append(m_cache.begin(), m_cache.begin() + m_len_remain); > m_cache.erase(0, m_len_remain); > m_len_remain = 0; > } > > if(!m_len_remain) > { > if(handle_request_and_send_response(m_query_info)) > set_ready_state(); > else > m_state = http_state_error; > } > return true; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::parse_cached_header(http_header_info& body_info, const std::string& m_cache_to_process, size_t pos) > { > epee::log_space::log_frame frame("http_stream_filter::parse_cached_header(*)", 3, __null); > > static volatile uint32_t regexp_initialized_1 = 0; volatile uint32_t local_is_initialized_1 = regexp_initialized_1; if(!local_is_initialized_1) gregexplock.get_lock().lock(); static const boost::regex rexp_mach_field("\n?((Connection)|(Referer)|(Content-Length)|(Content-Type)|(Transfer-Encoding)|(Content-Encoding)|(Host)|(Cookie)" "|([\\w-]+?)) ?: ?((.*?)(\r?\n))[^\t ]" , boost::regex::icase | boost::regex::normal); if(!local_is_initialized_1){ boost::interprocess::ipcdetail::atomic_write32(®exp_initialized_1, 1); gregexplock.get_lock().unlock();} > > > > > ; > > boost::smatch result; > std::string::const_iterator it_current_bound = m_cache_to_process.begin(); > std::string::const_iterator it_end_bound = m_cache_to_process.begin()+pos; > > body_info.clear(); > > > while( boost::regex_search( it_current_bound, it_end_bound, result, rexp_mach_field, boost::match_default) && result[0].matched) > { > const size_t field_val = 12; > const size_t field_etc_name = 10; > > int i = 2; > if(result[i++].matched) > body_info.m_connection = result[field_val]; > else if(result[i++].matched) > body_info.m_referer = result[field_val]; > else if(result[i++].matched) > body_info.m_content_length = result[field_val]; > else if(result[i++].matched) > body_info.m_content_type = result[field_val]; > else if(result[i++].matched) > body_info.m_transfer_encoding = result[field_val]; > else if(result[i++].matched) > body_info.m_content_encoding = result[field_val]; > else if(result[i++].matched) > body_info.m_host = result[field_val]; > else if(result[i++].matched) > body_info.m_cookie = result[field_val]; > else if(result[i++].matched) > body_info.m_etc_fields.push_back(std::pair<std::string, std::string>(result[field_etc_name], result[field_val])); > else > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.inl" << ":" << 515 << "|" << __FUNCTION__ << "|" << "simple_http_connection_handler<t_connection_context>::parse_cached_header() not matched last entry in:"<<m_cache_to_process << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > } > > it_current_bound = result[(int)result.size()-1]. first; > } > return true; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::get_len_from_content_lenght(const std::string& str, size_t& len) > { > static volatile uint32_t regexp_initialized_1 = 0; volatile uint32_t local_is_initialized_1 = regexp_initialized_1; if(!local_is_initialized_1) gregexplock.get_lock().lock(); static const boost::regex rexp_mach_field("\\d+" , boost::regex::normal); if(!local_is_initialized_1){ boost::interprocess::ipcdetail::atomic_write32(®exp_initialized_1, 1); gregexplock.get_lock().unlock();}; > std::string res; > boost::smatch result; > if(!(boost::regex_search( str, result, rexp_mach_field, boost::match_default) && result[0].matched)) > return false; > > len = boost::lexical_cast<size_t>(result[0]); > return true; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::handle_request_and_send_response(const http::http_request_info& query_info) > { > http_response_info response; > bool res = handle_request(query_info, response); > > > std::string response_data = get_response_header(response); > > > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "HTTP_RESPONSE_HEAD: << \r\n" << response_data << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > > m_psnd_hndlr->do_send((void*)response_data.data(), response_data.size()); > if(response.m_body.size()) > m_psnd_hndlr->do_send((void*)response.m_body.data(), response.m_body.size()); > return res; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::handle_request(const http::http_request_info& query_info, http_response_info& response) > { > > std::string uri_to_path = query_info.m_uri_content.m_path; > if("/" == uri_to_path) > uri_to_path = "/index.html"; > > > m_config.m_lock.lock(); > std::string destination_file_path = m_config.m_folder + uri_to_path; > m_config.m_lock.unlock(); > if(!file_io_utils::load_file_to_string(destination_file_path.c_str(), response.m_body)) > { > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "URI \""<< query_info.m_full_request_str.substr(0, query_info.m_full_request_str.size()-2) << "\" [" << destination_file_path << "] Not Found (404 )" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_default, false, __null);}}; > response.m_body = get_not_found_response_body(query_info.m_URI); > response.m_response_code = 404; > response.m_response_comment = "Not found"; > response.m_mime_tipe = "text/html"; > return true; > } > > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << " -->> " << query_info.m_full_request_str << "\r\n<<--OK" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > response.m_response_code = 200; > response.m_response_comment = "OK"; > response.m_mime_tipe = get_file_mime_tipe(uri_to_path); > > > return true; > } > > template<class t_connection_context> > std::string simple_http_connection_handler<t_connection_context>::get_response_header(const http_response_info& response) > { > std::string buf = "HTTP/1.1 "; > buf += boost::lexical_cast<std::string>(response.m_response_code) + " " + response.m_response_comment + "\r\n" + > "Server: Epee-based\r\n" > "Content-Length: "; > buf += boost::lexical_cast<std::string>(response.m_body.size()) + "\r\n"; > buf += "Content-Type: "; > buf += response.m_mime_tipe + "\r\n"; > > buf += "Last-Modified: "; > time_t tm; > time(&tm); > buf += misc_utils::get_internet_time_str(tm) + "\r\n"; > buf += "Accept-Ranges: bytes\r\n"; > > > string_tools::trim(m_query_info.m_header_info.m_connection); > if(m_query_info.m_header_info.m_connection.size()) > { > if(!string_tools::compare_no_case("close", m_query_info.m_header_info.m_connection)) > { > > buf += "Connection: close\r\n"; > m_state = http_state_connection_close; > m_want_close = true; > } > } > > for(fields_list::const_iterator it = response.m_additional_fields.begin(); it!=response.m_additional_fields.end(); it++) > buf += it->first + ":" + it->second + "\r\n"; > > buf+="\r\n"; > > return buf; > } > > template<class t_connection_context> > std::string simple_http_connection_handler<t_connection_context>::get_file_mime_tipe(const std::string& path) > { > std::string result; > std::string ext = string_tools::get_extension(path); > if(!string_tools::compare_no_case(ext, "gif")) > result = "image/gif"; > else if(!string_tools::compare_no_case(ext, "jpg")) > result = "image/jpeg"; > else if(!string_tools::compare_no_case(ext, "html")) > result = "text/html"; > else if(!string_tools::compare_no_case(ext, "htm")) > result = "text/html"; > else if(!string_tools::compare_no_case(ext, "js")) > result = "application/x-javascript"; > else if(!string_tools::compare_no_case(ext, "css")) > result = "text/css"; > else if(!string_tools::compare_no_case(ext, "xml")) > result = "application/xml"; > else if(!string_tools::compare_no_case(ext, "svg")) > result = "image/svg+xml"; > > > return result; > } > > template<class t_connection_context> > std::string simple_http_connection_handler<t_connection_context>::get_not_found_response_body(const std::string& URI) > { > std::string body = > "<!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML 2.0//EN\">\r\n" > "<html><head>\r\n" > "<title>404 Not Found</title>\r\n" > "</head><body>\r\n" > "<h1>Not Found</h1>\r\n" > "<p>The requested URL \r\n"; > body += URI; > body += "was not found on this server.</p>\r\n" > "</body></html>\r\n"; > > return body; > } > > template<class t_connection_context> > bool simple_http_connection_handler<t_connection_context>::slash_to_back_slash(std::string& str) > { > for(std::string::iterator it = str.begin(); it!=str.end(); it++) > if('/' == *it) > *it = '\\'; > return true; > } > } >} >} ># 211 "/c/honeypenny/contrib/epee/include/net/http_protocol_handler.h" 2 ># 35 "/c/honeypenny/contrib/epee/include/net/http_server_cp2.h" 2 >namespace epee >{ >namespace net_utils >{ > typedef boosted_tcp_server<http::simple_http_connection_handler<> > boosted_http_server_file_system; > typedef boosted_tcp_server<http::http_custom_handler<> > boosted_http_server_custum_handling; >} >} ># 37 "/c/honeypenny/contrib/epee/include/net/http_server_impl_base.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" 1 ># 28 "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" > ># 1 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization.h" 1 ># 27 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization.h" > > > > ># 1 "/c/honeypenny/contrib/epee/include/misc_log_ex.h" 1 ># 32 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/serialization/enableable.h" 1 ># 27 "/c/honeypenny/contrib/epee/include/serialization/enableable.h" > > >namespace epee >{ > > template<class t_obj> > struct enableable > { > t_obj v; > bool enabled; > > enableable() > : v(t_obj()), enabled(true) > { > } > > enableable(const t_obj& _v) > : v(_v), enabled(true) > { > } > > enableable(const enableable<t_obj>& _v) > : v(_v.v), enabled(_v.enabled) > { > } > }; >} ># 33 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization_overloads.h" 1 ># 27 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization_overloads.h" > > >namespace epee >{ > namespace serialization > { > > > template<class t_type, class t_storage> > static bool serialize_t_val(const t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return stg.set_value(pname, d, hparent_section); > } > > template<class t_type, class t_storage> > static bool unserialize_t_val(t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return stg.get_value(pname, d, hparent_section); > } > > template<class t_type, class t_storage> > static bool serialize_t_val_as_blob(const t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > std::string blob((const char *)&d, sizeof(d)); > return stg.set_value(pname, blob, hparent_section); > } > > template<class t_type, class t_storage> > static bool unserialize_t_val_as_blob(t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > std::string blob; > if(!stg.get_value(pname, blob, hparent_section)) > return false; > do{if(!(blob.size() == sizeof(d))) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization_overloads.h" << ":" << 60 << "|" << __FUNCTION__ << "|" << "unserialize_t_val_as_blob: size of " << typeid(t_type).name() << " = " << sizeof(t_type) << ", but stored blod size = " << blob.size() << ", value name = " << pname << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > d = *(const t_type*)blob.data(); > return true; > } > > template<class serializible_type, class t_storage> > static bool serialize_t_obj(const serializible_type& obj, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > typename t_storage::hsection hchild_section = stg.open_section(pname, hparent_section, true); > do{if(!(hchild_section)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization_overloads.h" << ":" << 69 << "|" << __FUNCTION__ << "|" << "serialize_t_obj: failed to open/create section " << pname << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > return obj.store(stg, hchild_section); > } > > template<class serializible_type, class t_storage> > static bool unserialize_t_obj(serializible_type& obj, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > typename t_storage::hsection hchild_section = stg.open_section(pname, hparent_section, true); > if(!hchild_section) return false; > return obj._load(stg, hchild_section); > } > > template<class serializible_type, class t_storage> > static bool serialize_t_obj(enableable<serializible_type>& obj, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > if(!obj.enabled) > return true; > return serialize_t_obj(obj.v, stg, hparent_section, pname); > } > > template<class serializible_type, class t_storage> > static bool unserialize_t_obj(enableable<serializible_type>& obj, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > obj.enabled = false; > typename t_storage::hsection hchild_section = stg.open_section(pname, hparent_section, true); > if(!hchild_section) return false; > obj.enabled = true; > return obj.v._load(stg, hchild_section); > } > > template<class stl_container, class t_storage> > static bool serialize_stl_container_t_val (const stl_container& container, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > if(!container.size()) return true; > typename stl_container::const_iterator it = container.begin(); > typename t_storage::harray hval_array = stg.insert_first_value(pname, *it, hparent_section); > do{if(!(hval_array)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization_overloads.h" << ":" << 105 << "|" << __FUNCTION__ << "|" << "failed to insert first value to storage" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > it++; > for(;it!= container.end();it++) > stg.insert_next_value(hval_array, *it); > > return true; > } > > template<class stl_container, class t_storage> > static bool unserialize_stl_container_t_val(stl_container& container, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > container.clear(); > typename stl_container::value_type exchange_val; > typename t_storage::harray hval_array = stg.get_first_value(pname, exchange_val, hparent_section); > if(!hval_array) return false; > container.push_back(std::move(exchange_val)); > while(stg.get_next_value(hval_array, exchange_val)) > container.push_back(std::move(exchange_val)); > return true; > } > template<class stl_container, class t_storage> > static bool serialize_stl_container_pod_val_as_blob(const stl_container& container, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > if(!container.size()) return true; > typename stl_container::const_iterator it = container.begin(); > std::string mb; > mb.resize(sizeof(typename stl_container::value_type)*container.size()); > typename stl_container::value_type* p_elem = (typename stl_container::value_type*)mb.data(); > if (boost::foreach_detail_::auto_any_t _foreach_col133 = boost::foreach_detail_::contain( (container) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((container), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(container) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(container) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur133 = boost::foreach_detail_::begin( _foreach_col133 , (true ? 0 : boost::foreach_detail_::encode_type(container, boost::foreach_detail_::is_const_(container))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((container), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(container) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(container) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end133 = boost::foreach_detail_::end( _foreach_col133 , (true ? 0 : boost::foreach_detail_::encode_type(container, boost::foreach_detail_::is_const_(container))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((container), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(container) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(container) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue133 = true; _foreach_continue133 && !boost::foreach_detail_::done( _foreach_cur133 , _foreach_end133 , (true ? 0 : boost::foreach_detail_::encode_type(container, boost::foreach_detail_::is_const_(container)))); _foreach_continue133 ? boost::foreach_detail_::next( _foreach_cur133 , (true ? 0 : boost::foreach_detail_::encode_type(container, boost::foreach_detail_::is_const_(container)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue133)) {} else for (const typename stl_container::value_type& v = boost::foreach_detail_::deref( _foreach_cur133 , (true ? 0 : boost::foreach_detail_::encode_type(container, boost::foreach_detail_::is_const_(container)))); !_foreach_continue133; _foreach_continue133 = true) > { > *p_elem = v; > p_elem++; > } > return stg.set_value(pname, mb, hparent_section); > } > > template<class stl_container, class t_storage> > static bool unserialize_stl_container_pod_val_as_blob(stl_container& container, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > container.clear(); > std::string buff; > bool res = stg.get_value(pname, buff, hparent_section); > if(res) > { > size_t loaded_size = buff.size(); > typename stl_container::value_type* pelem = (typename stl_container::value_type*)buff.data(); > do{if(!(!(loaded_size%sizeof(typename stl_container::value_type)))) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > > "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization_overloads.h" ># 151 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization_overloads.h" > << ":" << > > 153 ># 151 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization_overloads.h" > << "|" << __FUNCTION__ << "|" << "size in blob " << loaded_size << " not have not zero modulo for sizeof(value_type) = " << sizeof(typename stl_container::value_type) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0) > > ; > size_t count = (loaded_size/sizeof(typename stl_container::value_type)); > for(size_t i = 0; i < count; i++) > container.push_back(*(pelem++)); > } > return res; > } > > template<class stl_container, class t_storage> > static bool serialize_stl_container_t_obj (const stl_container& container, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > bool res = false; > if(!container.size()) return true; > typename stl_container::const_iterator it = container.begin(); > typename t_storage::hsection hchild_section = nullptr; > typename t_storage::harray hsec_array = stg.insert_first_section(pname, hchild_section, hparent_section); > do{if(!(hsec_array && hchild_section)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization_overloads.h" << ":" << 169 << "|" << __FUNCTION__ << "|" << "failed to insert first section with section name " << pname << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > res = it->store(stg, hchild_section); > it++; > for(;it!= container.end();it++) > { > stg.insert_next_section(hsec_array, hchild_section); > res |= it->store(stg, hchild_section); > } > return res; > } > > template<class stl_container, class t_storage> > static bool unserialize_stl_container_t_obj(stl_container& container, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > bool res = false; > container.clear(); > typename stl_container::value_type val = typename stl_container::value_type(); > typename t_storage::hsection hchild_section = nullptr; > typename t_storage::harray hsec_array = stg.get_first_section(pname, hchild_section, hparent_section); > if(!hsec_array || !hchild_section) return false; > res = val._load(stg, hchild_section); > container.push_back(val); > while(stg.get_next_section(hsec_array, hchild_section)) > { > typename stl_container::value_type val_l = typename stl_container::value_type(); > res |= val_l._load(stg, hchild_section); > container.push_back(std::move(val_l)); > } > return res; > } > > template<bool> > struct kv_serialization_overloads_impl_is_base_serializable_types; > > template<> > struct kv_serialization_overloads_impl_is_base_serializable_types<true> > { > template<class t_type, class t_storage> > static bool kv_serialize(const t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return stg.set_value(pname, d, hparent_section); > } > > template<class t_type, class t_storage> > static bool kv_unserialize(t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return stg.get_value(pname, d, hparent_section); > } > > template<class t_type, class t_storage> > static bool kv_serialize(const std::vector<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return serialize_stl_container_t_val(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool kv_unserialize(std::vector<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return unserialize_stl_container_t_val(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool kv_serialize(const std::list<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return serialize_stl_container_t_val(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool kv_unserialize(std::list<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return unserialize_stl_container_t_val(d, stg, hparent_section, pname); > } > > }; > template<> > struct kv_serialization_overloads_impl_is_base_serializable_types<false> > { > template<class t_type, class t_storage> > static bool kv_serialize(const t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return serialize_t_obj(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool kv_unserialize(t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return unserialize_t_obj(d, stg, hparent_section, pname); > } > > > template<class t_type, class t_storage> > static bool kv_serialize(const std::vector<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return serialize_stl_container_t_obj(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool kv_unserialize(std::vector<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return unserialize_stl_container_t_obj(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool kv_serialize(const std::list<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return serialize_stl_container_t_obj(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool kv_unserialize(std::list<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return unserialize_stl_container_t_obj(d, stg, hparent_section, pname); > } > }; > template<class t_storage> > struct base_serializable_types: public boost::mpl::vector<uint64_t, uint32_t, uint16_t, uint8_t, int64_t, int32_t, int16_t, int8_t, double, bool, std::string, typename t_storage::meta_entry>::type > {}; > > template<bool> struct selector; > template<> > struct selector<true> > { > template<class t_type, class t_storage> > static bool serialize(const t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return kv_serialize(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool serialize_stl_container_pod_val_as_blob(const t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return epee::serialization::serialize_stl_container_pod_val_as_blob(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool serialize_t_val_as_blob(const t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return epee::serialization::serialize_t_val_as_blob(d, stg, hparent_section, pname); > } > > > }; > template<> > struct selector<false> > { > template<class t_type, class t_storage> > static bool serialize(t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return kv_unserialize(d, stg, hparent_section, pname); > } > template<class t_type, class t_storage> > static bool serialize_stl_container_pod_val_as_blob(t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return epee::serialization::unserialize_stl_container_pod_val_as_blob(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > static bool serialize_t_val_as_blob(t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return epee::serialization::unserialize_t_val_as_blob(d, stg, hparent_section, pname); > } > }; > > template<class t_type, class t_storage> > bool kv_serialize(const t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return kv_serialization_overloads_impl_is_base_serializable_types<boost::mpl::contains<base_serializable_types<t_storage>, typename std::remove_const<t_type>::type>::value>::kv_serialize(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > bool kv_unserialize(t_type& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return kv_serialization_overloads_impl_is_base_serializable_types<boost::mpl::contains<base_serializable_types<t_storage>, typename std::remove_const<t_type>::type>::value>::kv_unserialize(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > bool kv_serialize(const std::vector<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return kv_serialization_overloads_impl_is_base_serializable_types<boost::mpl::contains<base_serializable_types<t_storage>, typename std::remove_const<t_type>::type>::value>::kv_serialize(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > bool kv_unserialize(std::vector<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return kv_serialization_overloads_impl_is_base_serializable_types<boost::mpl::contains<base_serializable_types<t_storage>, typename std::remove_const<t_type>::type>::value>::kv_unserialize(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > bool kv_serialize(const std::list<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return kv_serialization_overloads_impl_is_base_serializable_types<boost::mpl::contains<base_serializable_types<t_storage>, typename std::remove_const<t_type>::type>::value>::kv_serialize(d, stg, hparent_section, pname); > } > > template<class t_type, class t_storage> > bool kv_unserialize(std::list<t_type>& d, t_storage& stg, typename t_storage::hsection hparent_section, const char* pname) > { > return kv_serialization_overloads_impl_is_base_serializable_types<boost::mpl::contains<base_serializable_types<t_storage>, typename std::remove_const<t_type>::type>::value>::kv_unserialize(d, stg, hparent_section, pname); > } > } >} ># 34 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization.h" 2 >namespace epee >{ ># 90 "/c/honeypenny/contrib/epee/include/serialization/keyvalue_serialization.h" >} ># 30 "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/storages/portable_storage_template_helper.h" 1 ># 27 "/c/honeypenny/contrib/epee/include/storages/portable_storage_template_helper.h" > ># 1 "/c/honeypenny/contrib/epee/include/storages/parserse_base_utils.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/storages/parserse_base_utils.h" > > >namespace epee >{ >namespace misc_utils >{ > namespace parse > { > inline std::string transform_to_escape_sequence(const std::string& src) > { > > std::string res; > for(std::string::const_iterator it = src.begin(); it!=src.end(); ++it) > { > switch(*it) > { > case '\b': > res+="\\b"; break; > case '\f': > res+="\\f"; break; > case '\n': > res+="\\n"; break; > case '\r': > res+="\\r"; break; > case '\t': > res+="\\t"; break; > case '\v': > res+="\\v"; break; > > > case '"': > res+="\\\""; break; > case '\\': > res+="\\\\"; break; > case '/': > res+="\\/"; break; > default: > res.push_back(*it); > } > } > return res; > } ># 84 "/c/honeypenny/contrib/epee/include/storages/parserse_base_utils.h" > inline void match_string2(std::string::const_iterator& star_end_string, std::string::const_iterator buf_end, std::string& val) > { > val.clear(); > bool escape_mode = false; > std::string::const_iterator it = star_end_string; > ++it; > for(;it != buf_end;it++) > { > if(escape_mode ) > { > switch(*it) > { > case 'b': > val.push_back(0x08);break; > case 'f': > val.push_back(0x0C);break; > case 'n': > val.push_back('\n');break; > case 'r': > val.push_back('\r');break; > case 't': > val.push_back('\t');break; > case 'v': > val.push_back('\v');break; > case '\'': > val.push_back('\'');break; > case '"': > val.push_back('"');break; > case '\\': > val.push_back('\\');break; > case '/': > val.push_back('/');break; > default: > val.push_back(*it); > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Unknown escape sequence :\"\\" << *it << "\"" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > } > escape_mode = false; > }else if(*it == '"') > { > star_end_string = it; > return; > }else if(*it == '\\') > { > escape_mode = true; > } > else > { > val.push_back(*it); > } > } > {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/parserse_base_utils.h" << ":" << 134 << "|" << __FUNCTION__ << "|" << "Failed to match string in json entry: " << std::string(star_end_string, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Failed to match string in json entry: " << std::string(star_end_string, buf_end); throw std::runtime_error(ss.str());}; > } > inline bool match_string(std::string::const_iterator& star_end_string, std::string::const_iterator buf_end, std::string& val) > { > try > { > > match_string2(star_end_string, buf_end, val); > return true; > } > catch(...) > { > return false; > } > } > inline void match_number2(std::string::const_iterator& star_end_string, std::string::const_iterator buf_end, std::string& val, bool& is_float_val, bool& is_signed_val) > { > val.clear(); > is_float_val = false; > for(std::string::const_iterator it = star_end_string;it != buf_end;it++) > { > if(isdigit(*it) || (it == star_end_string && *it == '-') || (val.size() && *it == '.' ) || (is_float_val && (*it == 'e' || *it == 'E' || *it == '-' || *it == '+' )) ) > { > if(!val.size() && *it == '-') > is_signed_val = true; > if(*it == '.' ) > is_float_val = true; > val.push_back(*it); > } > else > { > if(val.size()) > { > star_end_string = --it; > return; > } > else > {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/parserse_base_utils.h" << ":" << 171 << "|" << __FUNCTION__ << "|" << "wrong number in json entry: " << std::string(star_end_string, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "wrong number in json entry: " << std::string(star_end_string, buf_end); throw std::runtime_error(ss.str());}; > } > } > {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/parserse_base_utils.h" << ":" << 174 << "|" << __FUNCTION__ << "|" << "wrong number in json entry: " << std::string(star_end_string, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "wrong number in json entry: " << std::string(star_end_string, buf_end); throw std::runtime_error(ss.str());}; > } > inline bool match_number(std::string::const_iterator& star_end_string, std::string::const_iterator buf_end, std::string& val) > { > try > { > bool is_v_float = false;bool is_signed_val = false; > match_number2(star_end_string, buf_end, val, is_v_float, is_signed_val); > return !is_v_float; > } > catch(...) > { > return false; > } > } > inline void match_word2(std::string::const_iterator& star_end_string, std::string::const_iterator buf_end, std::string& val) > { > val.clear(); > > for(std::string::const_iterator it = star_end_string;it != buf_end;it++) > { > if(!isalpha(*it)) > { > val.assign(star_end_string, it); > if(val.size()) > { > star_end_string = --it; > return; > }else > {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/parserse_base_utils.h" << ":" << 203 << "|" << __FUNCTION__ << "|" << "failed to match word number in json entry: " << std::string(star_end_string, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "failed to match word number in json entry: " << std::string(star_end_string, buf_end); throw std::runtime_error(ss.str());}; > } > } > {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/parserse_base_utils.h" << ":" << 206 << "|" << __FUNCTION__ << "|" << "failed to match word number in json entry: " << std::string(star_end_string, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "failed to match word number in json entry: " << std::string(star_end_string, buf_end); throw std::runtime_error(ss.str());}; > } > inline bool match_word(std::string::const_iterator& star_end_string, std::string::const_iterator buf_end, std::string& val) > { > try > { > match_word2(star_end_string, buf_end, val); > return true; > } > catch(...) > { > return false; > } > } > inline bool match_word_with_extrasymb(std::string::const_iterator& star_end_string, std::string::const_iterator buf_end, std::string& val) > { > val.clear(); > > for(std::string::const_iterator it = star_end_string;it != buf_end;it++) > { > if(!isalnum(*it) && *it != '-' && *it != '_') > { > val.assign(star_end_string, it); > if(val.size()) > { > star_end_string = --it; > return true; > }else > return false; > } > } > return false; > } > inline bool match_word_til_equal_mark(std::string::const_iterator& star_end_string, std::string::const_iterator buf_end, std::string::const_iterator& word_end) > { > word_end = star_end_string; > > for(std::string::const_iterator it = star_end_string;it != buf_end;it++) > { > if(isspace(*it)) > { > > continue; > }else if( *it == '=' ) > { > star_end_string = it; > word_end = it; > return true; > } > } > return false; > } > } >} >} ># 29 "/c/honeypenny/contrib/epee/include/storages/portable_storage_template_helper.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" > > > ># 1 "/c/honeypenny/contrib/epee/include/storages/portable_storage_base.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/storages/portable_storage_base.h" > > ># 1 "/usr/include/boost/variant.hpp" 1 3 4 ># 17 "/usr/include/boost/variant.hpp" 3 4 ># 1 "/usr/include/boost/variant/variant.hpp" 1 3 4 ># 25 "/usr/include/boost/variant/variant.hpp" 3 4 ># 1 "/usr/include/boost/variant/detail/config.hpp" 1 3 4 ># 26 "/usr/include/boost/variant/variant.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/variant/variant_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/variant/variant_fwd.hpp" 3 4 ># 1 "/usr/include/boost/blank_fwd.hpp" 1 3 4 ># 16 "/usr/include/boost/blank_fwd.hpp" 3 4 >namespace boost { > >struct blank; > >} ># 19 "/usr/include/boost/variant/variant_fwd.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/arg.hpp" 1 3 4 ># 20 "/usr/include/boost/variant/variant_fwd.hpp" 2 3 4 ># 67 "/usr/include/boost/variant/variant_fwd.hpp" 3 4 ># 1 "/usr/include/boost/variant/detail/substitute_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/variant/detail/substitute_fwd.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/template_arity.hpp" 1 3 4 ># 18 "/usr/include/boost/variant/detail/substitute_fwd.hpp" 2 3 4 ># 36 "/usr/include/boost/variant/detail/substitute_fwd.hpp" 3 4 >namespace boost { >namespace detail { namespace variant { ># 46 "/usr/include/boost/variant/detail/substitute_fwd.hpp" 3 4 >template < > typename T, typename Dest, typename Source > , typename Arity = mpl::int_< mpl::aux::template_arity<T>::value > > > > > >struct substitute; > > > >}} >} ># 68 "/usr/include/boost/variant/variant_fwd.hpp" 2 3 4 ># 104 "/usr/include/boost/variant/variant_fwd.hpp" 3 4 >namespace boost { > >namespace detail { namespace variant { ># 120 "/usr/include/boost/variant/variant_fwd.hpp" 3 4 >struct void_; > >template <typename T> >struct convert_void >{ > typedef T type; >}; > >template <> >struct convert_void< void_ > >{ > typedef mpl::na type; >}; ># 169 "/usr/include/boost/variant/variant_fwd.hpp" 3 4 >}} ># 213 "/usr/include/boost/variant/variant_fwd.hpp" 3 4 >template < typename T0 = detail::variant::void_ , typename T1 = detail::variant::void_ , typename T2 = detail::variant::void_ , typename T3 = detail::variant::void_ , typename T4 = detail::variant::void_ , typename T5 = detail::variant::void_ , typename T6 = detail::variant::void_ , typename T7 = detail::variant::void_ , typename T8 = detail::variant::void_ , typename T9 = detail::variant::void_ , typename T10 = detail::variant::void_ , typename T11 = detail::variant::void_ , typename T12 = detail::variant::void_ , typename T13 = detail::variant::void_ , typename T14 = detail::variant::void_ , typename T15 = detail::variant::void_ , typename T16 = detail::variant::void_ , typename T17 = detail::variant::void_ , typename T18 = detail::variant::void_ , typename T19 = detail::variant::void_ > class variant; > > > > > > > >template < typename T0 = detail::variant::void_ , typename T1 = detail::variant::void_ , typename T2 = detail::variant::void_ , typename T3 = detail::variant::void_ , typename T4 = detail::variant::void_ , typename T5 = detail::variant::void_ , typename T6 = detail::variant::void_ , typename T7 = detail::variant::void_ , typename T8 = detail::variant::void_ , typename T9 = detail::variant::void_ , typename T10 = detail::variant::void_ , typename T11 = detail::variant::void_ , typename T12 = detail::variant::void_ , typename T13 = detail::variant::void_ , typename T14 = detail::variant::void_ , typename T15 = detail::variant::void_ , typename T16 = detail::variant::void_ , typename T17 = detail::variant::void_ , typename T18 = detail::variant::void_ , typename T19 = detail::variant::void_ > struct make_recursive_variant; ># 232 "/usr/include/boost/variant/variant_fwd.hpp" 3 4 > struct recursive_variant_ {}; ># 242 "/usr/include/boost/variant/variant_fwd.hpp" 3 4 >template <typename Types> struct make_variant_over; > > > > > > >template <typename Types> struct make_recursive_variant_over; > >} ># 30 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/backup_holder.hpp" 1 3 4 ># 17 "/usr/include/boost/variant/detail/backup_holder.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 18 "/usr/include/boost/variant/detail/backup_holder.hpp" 2 3 4 > >namespace boost { >namespace detail { namespace variant { > >template <typename T> >class backup_holder >{ >private: > > T* backup_; > >public: > > ~backup_holder() > { > delete backup_; > } > > explicit backup_holder(T* backup) noexcept > : backup_(backup) > { > } > > backup_holder(const backup_holder&); > >public: > > backup_holder& operator=(const backup_holder& rhs) > { > *backup_ = rhs.get(); > return *this; > } > > backup_holder& operator=(const T& rhs) > { > *backup_ = rhs; > return *this; > } > > void swap(backup_holder& rhs) noexcept > { > T* tmp = rhs.backup_; > rhs.backup_ = this->backup_; > this->backup_ = tmp; > } > >public: > > T& get() > { > return *backup_; > } > > const T& get() const > { > return *backup_; > } > >}; > >template <typename T> >backup_holder<T>::backup_holder(const backup_holder&) > : backup_(0) >{ > > (static_cast<void> (0)); >} > >template <typename T> >void swap(backup_holder<T>& lhs, backup_holder<T>& rhs) noexcept >{ > lhs.swap(rhs); >} > >}} >} ># 31 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/enable_recursive_fwd.hpp" 1 3 4 ># 26 "/usr/include/boost/variant/detail/enable_recursive_fwd.hpp" 3 4 >namespace boost { >namespace detail { namespace variant { ># 37 "/usr/include/boost/variant/detail/enable_recursive_fwd.hpp" 3 4 >template <typename T> >struct recursive_flag >{ > typedef T type; >}; ># 66 "/usr/include/boost/variant/detail/enable_recursive_fwd.hpp" 3 4 >template <typename T> >struct is_recursive_flag > : mpl::false_ >{ >}; > >template <typename T> >struct is_recursive_flag< recursive_flag<T> > > : mpl::true_ >{ >}; ># 95 "/usr/include/boost/variant/detail/enable_recursive_fwd.hpp" 3 4 >template < > typename T > , typename RecursiveVariant > , typename NoWrapper = mpl::false_ > > >struct enable_recursive; > > > > > > >template < > typename RecursiveVariant > , typename NoWrapper = mpl::false_ > > >struct quoted_enable_recursive; > >}} >} ># 32 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/forced_return.hpp" 1 3 4 ># 17 "/usr/include/boost/variant/detail/forced_return.hpp" 3 4 ># 1 "/usr/include/boost/variant/detail/generic_result_type.hpp" 1 3 4 ># 18 "/usr/include/boost/variant/detail/forced_return.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 19 "/usr/include/boost/variant/detail/forced_return.hpp" 2 3 4 > > > > > >namespace boost { >namespace detail { namespace variant { ># 40 "/usr/include/boost/variant/detail/forced_return.hpp" 3 4 >template <typename T> >inline T forced_return( ) >{ > > (static_cast<void> (0)); > > typedef typename boost::remove_reference<T>::type basic_type; > basic_type* dummy = 0; > return *static_cast< basic_type* >(dummy); >} > >template <> >inline void forced_return<void>( ) >{ > > (static_cast<void> (0)); >} ># 101 "/usr/include/boost/variant/detail/forced_return.hpp" 3 4 >}} >} ># 33 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/initializer.hpp" 1 3 4 ># 22 "/usr/include/boost/variant/detail/initializer.hpp" 3 4 ># 1 "/usr/include/boost/variant/recursive_wrapper_fwd.hpp" 1 3 4 ># 29 "/usr/include/boost/variant/recursive_wrapper_fwd.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 30 "/usr/include/boost/variant/recursive_wrapper_fwd.hpp" 2 3 4 > >namespace boost { ># 49 "/usr/include/boost/variant/recursive_wrapper_fwd.hpp" 3 4 >template <typename T> class recursive_wrapper; > > > > > > > >namespace detail { > > > >template <typename T> >struct is_recursive_wrapper_impl > : mpl::false_ >{ >}; > >template <typename T> >struct is_recursive_wrapper_impl< recursive_wrapper<T> > > : mpl::true_ >{ >}; ># 96 "/usr/include/boost/variant/recursive_wrapper_fwd.hpp" 3 4 >} > >template< typename T > struct is_recursive_wrapper : public ::boost::integral_constant<bool,(::boost::detail::is_recursive_wrapper_impl<T>::value)> { public: }; ># 112 "/usr/include/boost/variant/recursive_wrapper_fwd.hpp" 3 4 >template <typename T> >struct unwrap_recursive >{ > typedef T type; > > >}; > >template <typename T> >struct unwrap_recursive< recursive_wrapper<T> > >{ > typedef T type; > > >}; ># 143 "/usr/include/boost/variant/recursive_wrapper_fwd.hpp" 3 4 >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 146 "/usr/include/boost/variant/recursive_wrapper_fwd.hpp" 2 3 4 ># 23 "/usr/include/boost/variant/detail/initializer.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/move.hpp" 1 3 4 ># 29 "/usr/include/boost/variant/detail/move.hpp" 3 4 >namespace boost { >namespace detail { namespace variant { > >using boost::move; ># 48 "/usr/include/boost/variant/detail/move.hpp" 3 4 >template <typename T> >inline void move_swap(T& lhs, T& rhs) >{ > T tmp( boost::detail::variant::move(lhs) ); > lhs = boost::detail::variant::move(rhs); > rhs = boost::detail::variant::move(tmp); >} ># 80 "/usr/include/boost/variant/detail/move.hpp" 3 4 >}} >} ># 24 "/usr/include/boost/variant/detail/initializer.hpp" 2 3 4 ># 40 "/usr/include/boost/variant/detail/initializer.hpp" 3 4 >namespace boost { >namespace detail { namespace variant { ># 62 "/usr/include/boost/variant/detail/initializer.hpp" 3 4 >struct make_initializer_node >{ > template <typename BaseIndexPair, typename Iterator> > struct apply > { > private: > > typedef typename BaseIndexPair::first > base; > typedef typename BaseIndexPair::second > index; > > class initializer_node > : public base > { > private: > > typedef typename mpl::deref<Iterator>::type > recursive_enabled_T; > typedef typename unwrap_recursive<recursive_enabled_T>::type > public_T; > > > typedef boost::is_reference<public_T> > is_reference_content_t; > > typedef typename boost::mpl::if_<is_reference_content_t, public_T, const public_T& >::type > param_T; > > template <class T> struct disable_overload{}; > > typedef typename boost::mpl::if_<is_reference_content_t, disable_overload<public_T>, public_T&& >::type > param2_T; > > > > > > public: > > using base::initialize; > > static int initialize(void* dest, param_T operand) > { > typedef typename boost::detail::make_reference_content< > recursive_enabled_T > >::type internal_T; > > new(dest) internal_T(operand); > return index::value; > } > > > static int initialize(void* dest, param2_T operand) > { > > > (static_cast<void> (0)); > > typedef typename boost::mpl::if_<is_reference_content_t, param2_T, recursive_enabled_T>::type value_T; > new(dest) value_T( boost::detail::variant::move(operand) ); > return index::value; > } > > }; > > friend class initializer_node; > > public: > > typedef mpl::pair< > initializer_node > , typename mpl::next< index >::type > > type; > > }; >}; > > > > > > >class initializer_root >{ >public: > > static void initialize(); > >}; ># 231 "/usr/include/boost/variant/detail/initializer.hpp" 3 4 >}} >} ># 34 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/make_variant_list.hpp" 1 3 4 ># 22 "/usr/include/boost/variant/detail/make_variant_list.hpp" 3 4 >namespace boost { >namespace detail { namespace variant { ># 34 "/usr/include/boost/variant/detail/make_variant_list.hpp" 3 4 >template < typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > >struct make_variant_list >{ >public: > > > > > > > typedef typename mpl::list< > typename convert_void< T0 >::type , typename convert_void< T1 >::type , typename convert_void< T2 >::type , typename convert_void< T3 >::type , typename convert_void< T4 >::type , typename convert_void< T5 >::type , typename convert_void< T6 >::type , typename convert_void< T7 >::type , typename convert_void< T8 >::type , typename convert_void< T9 >::type , typename convert_void< T10 >::type , typename convert_void< T11 >::type , typename convert_void< T12 >::type , typename convert_void< T13 >::type , typename convert_void< T14 >::type , typename convert_void< T15 >::type , typename convert_void< T16 >::type , typename convert_void< T17 >::type , typename convert_void< T18 >::type , typename convert_void< T19 >::type > > > > > >::type type; > > > > >}; > >}} >} ># 35 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/over_sequence.hpp" 1 3 4 ># 27 "/usr/include/boost/variant/detail/over_sequence.hpp" 3 4 >namespace boost { >namespace detail { namespace variant { > > > > > > >template <typename Types> >struct over_sequence >{ > typedef Types type; >}; ># 49 "/usr/include/boost/variant/detail/over_sequence.hpp" 3 4 >template <typename T> >struct is_over_sequence > : mpl::false_ >{ >}; > >template <typename Types> >struct is_over_sequence< over_sequence<Types> > > : mpl::true_ >{ >}; ># 92 "/usr/include/boost/variant/detail/over_sequence.hpp" 3 4 >}} >} ># 36 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/visitation_impl.hpp" 1 3 4 ># 19 "/usr/include/boost/variant/detail/visitation_impl.hpp" 3 4 ># 1 "/usr/include/boost/variant/detail/cast_storage.hpp" 1 3 4 ># 18 "/usr/include/boost/variant/detail/cast_storage.hpp" 3 4 >namespace boost { >namespace detail { namespace variant { > > > > > > > >template <typename T> >inline T& cast_storage( > void* storage > > ) >{ > return *static_cast<T*>(storage); >} > >template <typename T> >inline const T& cast_storage( > const void* storage > > ) >{ > return *static_cast<const T*>(storage); >} > >}} >} ># 20 "/usr/include/boost/variant/detail/visitation_impl.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 24 "/usr/include/boost/variant/detail/visitation_impl.hpp" 2 3 4 ># 54 "/usr/include/boost/variant/detail/visitation_impl.hpp" 3 4 >namespace boost { >namespace detail { namespace variant { > > > > > > >struct apply_visitor_unrolled {}; ># 72 "/usr/include/boost/variant/detail/visitation_impl.hpp" 3 4 >template <typename Iter, typename LastIter> >struct visitation_impl_step >{ > typedef typename mpl::deref<Iter>::type type; > > typedef typename mpl::next<Iter>::type next_iter; > typedef visitation_impl_step< > next_iter, LastIter > > next; >}; > >template <typename LastIter> >struct visitation_impl_step< LastIter,LastIter > >{ > typedef apply_visitor_unrolled type; > typedef visitation_impl_step next; >}; ># 120 "/usr/include/boost/variant/detail/visitation_impl.hpp" 3 4 >template <typename Visitor, typename VoidPtrCV, typename T> >inline > typename Visitor::result_type >visitation_impl_invoke_impl( > int, Visitor& visitor, VoidPtrCV storage, T* > , mpl::true_ > ) >{ > return visitor.internal_visit( > cast_storage<T>(storage), 1L > ); >} > >template <typename Visitor, typename VoidPtrCV, typename T> >inline > typename Visitor::result_type >visitation_impl_invoke_impl( > int internal_which, Visitor& visitor, VoidPtrCV storage, T* > , mpl::false_ > ) >{ > if (internal_which >= 0) > { > return visitor.internal_visit( > cast_storage<T>(storage), 1L > ); > } > else > { > return visitor.internal_visit( > cast_storage< backup_holder<T> >(storage), 1L > ); > } >} > >template <typename Visitor, typename VoidPtrCV, typename T, typename NoBackupFlag> >inline > typename Visitor::result_type >visitation_impl_invoke( > int internal_which, Visitor& visitor, VoidPtrCV storage, T* t > , NoBackupFlag > , int > ) >{ > typedef typename mpl::or_< > NoBackupFlag > , is_nothrow_move_constructible<T> > , has_nothrow_copy<T> > >::type never_uses_backup; > > return (visitation_impl_invoke_impl)( > internal_which, visitor, storage, t > , never_uses_backup() > ); >} > >template <typename Visitor, typename VoidPtrCV, typename NBF> >inline > typename Visitor::result_type >visitation_impl_invoke(int, Visitor&, VoidPtrCV, apply_visitor_unrolled*, NBF, long) >{ > > (static_cast<void> (0)); > typedef typename Visitor::result_type result_type; > return ::boost::detail::variant::forced_return< result_type >(); >} > > > > > > > >template < > typename W, typename S > , typename Visitor, typename VPCV > , typename NBF > > >inline > typename Visitor::result_type >visitation_impl( > int, int, Visitor&, VPCV > , mpl::true_ > , NBF, W* = 0, S* = 0 > ) >{ > > (static_cast<void> (0)); > typedef typename Visitor::result_type result_type; > return ::boost::detail::variant::forced_return< result_type >(); >} > >template < > typename Which, typename step0 > , typename Visitor, typename VoidPtrCV > , typename NoBackupFlag > > >inline > typename Visitor::result_type >visitation_impl( > const int internal_which, const int logical_which > , Visitor& visitor, VoidPtrCV storage > , mpl::false_ > , NoBackupFlag no_backup_flag > , Which* = 0, step0* = 0 > ) >{ > > > > > > > > typedef typename step0::type T0; typedef typename step0::next step1; typedef typename step1::type T1; typedef typename step1::next step2; typedef typename step2::type T2; typedef typename step2::next step3; typedef typename step3::type T3; typedef typename step3::next step4; typedef typename step4::type T4; typedef typename step4::next step5; typedef typename step5::type T5; typedef typename step5::next step6; typedef typename step6::type T6; typedef typename step6::next step7; typedef typename step7::type T7; typedef typename step7::next step8; typedef typename step8::type T8; typedef typename step8::next step9; typedef typename step9::type T9; typedef typename step9::next step10; typedef typename step10::type T10; typedef typename step10::next step11; typedef typename step11::type T11; typedef typename step11::next step12; typedef typename step12::type T12; typedef typename step12::next step13; typedef typename step13::type T13; typedef typename step13::next step14; typedef typename step14::type T14; typedef typename step14::next step15; typedef typename step15::type T15; typedef typename step15::next step16; typedef typename step16::type T16; typedef typename step16::next step17; typedef typename step17::type T17; typedef typename step17::next step18; typedef typename step18::type T18; typedef typename step18::next step19; typedef typename step19::type T19; typedef typename step19::next step20; ># 243 "/usr/include/boost/variant/detail/visitation_impl.hpp" 3 4 > switch (logical_which) > { ># 256 "/usr/include/boost/variant/detail/visitation_impl.hpp" 3 4 > case (Which::value + (0)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T0*>(0) , no_backup_flag, 1L ); case (Which::value + (1)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T1*>(0) , no_backup_flag, 1L ); case (Which::value + (2)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T2*>(0) , no_backup_flag, 1L ); case (Which::value + (3)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T3*>(0) , no_backup_flag, 1L ); case (Which::value + (4)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T4*>(0) , no_backup_flag, 1L ); case (Which::value + (5)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T5*>(0) , no_backup_flag, 1L ); case (Which::value + (6)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T6*>(0) , no_backup_flag, 1L ); case (Which::value + (7)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T7*>(0) , no_backup_flag, 1L ); case (Which::value + (8)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T8*>(0) , no_backup_flag, 1L ); case (Which::value + (9)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T9*>(0) , no_backup_flag, 1L ); case (Which::value + (10)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T10*>(0) , no_backup_flag, 1L ); case (Which::value + (11)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T11*>(0) , no_backup_flag, 1L ); case (Which::value + (12)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T12*>(0) , no_backup_flag, 1L ); case (Which::value + (13)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T13*>(0) , no_backup_flag, 1L ); case (Which::value + (14)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T14*>(0) , no_backup_flag, 1L ); case (Which::value + (15)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T15*>(0) , no_backup_flag, 1L ); case (Which::value + (16)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T16*>(0) , no_backup_flag, 1L ); case (Which::value + (17)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T17*>(0) , no_backup_flag, 1L ); case (Which::value + (18)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T18*>(0) , no_backup_flag, 1L ); case (Which::value + (19)): return (visitation_impl_invoke)( internal_which, visitor, storage , static_cast<T19*>(0) , no_backup_flag, 1L ); > > > > > > > > default: break; > } > > > typedef mpl::int_< > Which::value + (20) > > next_which; > > typedef step20 > next_step; > > typedef typename next_step::type next_type; > typedef typename is_same< next_type,apply_visitor_unrolled >::type > is_apply_visitor_unrolled; > > return visitation_impl( > internal_which, logical_which > , visitor, storage > , is_apply_visitor_unrolled() > , no_backup_flag > , static_cast<next_which*>(0), static_cast<next_step*>(0) > ); >} > >}} >} ># 37 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/hash_variant.hpp" 1 3 4 ># 22 "/usr/include/boost/variant/detail/hash_variant.hpp" 3 4 ># 1 "/usr/include/boost/variant/static_visitor.hpp" 1 3 4 ># 27 "/usr/include/boost/variant/static_visitor.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 28 "/usr/include/boost/variant/static_visitor.hpp" 2 3 4 > >namespace boost { ># 38 "/usr/include/boost/variant/static_visitor.hpp" 3 4 >namespace detail { > > struct is_static_visitor_tag { }; > > typedef void static_visitor_default_return; > >} > >template <typename R = ::boost::detail::static_visitor_default_return> >class static_visitor > : public detail::is_static_visitor_tag >{ >public: > > typedef R result_type; > >protected: > > static_visitor() { } > ~static_visitor() { } > >}; ># 73 "/usr/include/boost/variant/static_visitor.hpp" 3 4 >namespace detail { > >template <typename T> >struct is_static_visitor_impl >{ > static const bool value = (::boost::is_base_and_derived< detail::is_static_visitor_tag, T >::value) > > > > ; >}; > >} > >template< typename T > struct is_static_visitor : public ::boost::integral_constant<bool,(::boost::detail::is_static_visitor_impl<T>::value)> { public: }; > > > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 96 "/usr/include/boost/variant/static_visitor.hpp" 2 3 4 ># 23 "/usr/include/boost/variant/detail/hash_variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/apply_visitor.hpp" 1 3 4 ># 16 "/usr/include/boost/variant/apply_visitor.hpp" 3 4 ># 1 "/usr/include/boost/variant/detail/apply_visitor_unary.hpp" 1 3 4 ># 26 "/usr/include/boost/variant/detail/apply_visitor_unary.hpp" 3 4 >namespace boost { ># 55 "/usr/include/boost/variant/detail/apply_visitor_unary.hpp" 3 4 >template <typename Visitor, typename Visitable> >inline > typename Visitor::result_type >apply_visitor(Visitor& visitor, Visitable& visitable) >{ > return visitable.apply_visitor(visitor); >} ># 71 "/usr/include/boost/variant/detail/apply_visitor_unary.hpp" 3 4 >template <typename Visitor, typename Visitable> >inline > typename Visitor::result_type >apply_visitor(const Visitor& visitor, Visitable& visitable) >{ > return visitable.apply_visitor(visitor); >} > > > >} ># 17 "/usr/include/boost/variant/apply_visitor.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/apply_visitor_binary.hpp" 1 3 4 ># 28 "/usr/include/boost/variant/detail/apply_visitor_binary.hpp" 3 4 >namespace boost { ># 38 "/usr/include/boost/variant/detail/apply_visitor_binary.hpp" 3 4 >namespace detail { namespace variant { > >template <typename Visitor, typename Value1> >class apply_visitor_binary_invoke >{ >public: > > typedef typename Visitor::result_type > result_type; > >private: > > Visitor& visitor_; > Value1& value1_; > >public: > > apply_visitor_binary_invoke(Visitor& visitor, Value1& value1) > : visitor_(visitor) > , value1_(value1) > { > } > >public: > > template <typename Value2> > result_type > operator()(Value2& value2) > { > return visitor_(value1_, value2); > } > >private: > apply_visitor_binary_invoke& operator=(const apply_visitor_binary_invoke&); > >}; > >template <typename Visitor, typename Visitable2> >class apply_visitor_binary_unwrap >{ >public: > > typedef typename Visitor::result_type > result_type; > >private: > > Visitor& visitor_; > Visitable2& visitable2_; > >public: > > apply_visitor_binary_unwrap(Visitor& visitor, Visitable2& visitable2) > : visitor_(visitor) > , visitable2_(visitable2) > { > } > >public: > > template <typename Value1> > result_type > operator()(Value1& value1) > { > apply_visitor_binary_invoke< > Visitor > , Value1 > > invoker(visitor_, value1); > > return boost::apply_visitor(invoker, visitable2_); > } > >private: > apply_visitor_binary_unwrap& operator=(const apply_visitor_binary_unwrap&); > >}; > >}} ># 138 "/usr/include/boost/variant/detail/apply_visitor_binary.hpp" 3 4 >template <typename Visitor, typename Visitable1, typename Visitable2> >inline > typename Visitor::result_type >apply_visitor( > Visitor& visitor > , Visitable1& visitable1, Visitable2& visitable2 > ) >{ > ::boost::detail::variant::apply_visitor_binary_unwrap< > Visitor, Visitable2 > > unwrapper(visitor, visitable2); > > return boost::apply_visitor(unwrapper, visitable1); >} ># 161 "/usr/include/boost/variant/detail/apply_visitor_binary.hpp" 3 4 >template <typename Visitor, typename Visitable1, typename Visitable2> >inline > typename Visitor::result_type > > >apply_visitor( > const Visitor& visitor > , Visitable1& visitable1, Visitable2& visitable2 > ) >{ > ::boost::detail::variant::apply_visitor_binary_unwrap< > const Visitor, Visitable2 > > unwrapper(visitor, visitable2); > > return boost::apply_visitor(unwrapper, visitable1); >} > > > >} ># 18 "/usr/include/boost/variant/apply_visitor.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/detail/apply_visitor_delayed.hpp" 1 3 4 ># 21 "/usr/include/boost/variant/detail/apply_visitor_delayed.hpp" 3 4 >namespace boost { ># 38 "/usr/include/boost/variant/detail/apply_visitor_delayed.hpp" 3 4 >template <typename Visitor> >class apply_visitor_delayed_t >{ >public: > > typedef typename Visitor::result_type > result_type; > >private: > > Visitor& visitor_; > >public: > > explicit apply_visitor_delayed_t(Visitor& visitor) > : visitor_(visitor) > { > } > >public: > > template <typename Visitable> > result_type > operator()(Visitable& visitable) const > { > return apply_visitor(visitor_, visitable); > } > >public: > > template <typename Visitable1, typename Visitable2> > result_type > operator()(Visitable1& visitable1, Visitable2& visitable2) const > { > return apply_visitor(visitor_, visitable1, visitable2); > } > >private: > apply_visitor_delayed_t& operator=(const apply_visitor_delayed_t&); > >}; > >template <typename Visitor> >inline apply_visitor_delayed_t<Visitor> apply_visitor(Visitor& visitor) >{ > return apply_visitor_delayed_t<Visitor>(visitor); >} > >} ># 19 "/usr/include/boost/variant/apply_visitor.hpp" 2 3 4 ># 24 "/usr/include/boost/variant/detail/hash_variant.hpp" 2 3 4 ># 1 "/usr/include/boost/functional/hash_fwd.hpp" 1 3 4 ># 25 "/usr/include/boost/variant/detail/hash_variant.hpp" 2 3 4 > >namespace boost { > > namespace detail { namespace variant { > struct variant_hasher: public boost::static_visitor<std::size_t> { > template <class T> > std::size_t operator()(T const& val) const { > boost::hash<T> hasher; > return hasher(val); > } > }; > }} > > template < typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > > std::size_t hash_value(variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 > const& val) { > std::size_t seed = boost::apply_visitor(detail::variant::variant_hasher(), val); > hash_combine(seed, val.which()); > return seed; > } >} ># 38 "/usr/include/boost/variant/variant.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/blank.hpp" 1 3 4 ># 20 "/usr/include/boost/blank.hpp" 3 4 ># 1 "/usr/include/boost/detail/templated_streams.hpp" 1 3 4 ># 21 "/usr/include/boost/blank.hpp" 2 3 4 > > > > > > > >namespace boost { > >struct blank >{ >}; > > > > >template <> >struct is_pod< blank > > : mpl::true_ >{ >}; > >template <> >struct is_empty< blank > > : mpl::true_ >{ >}; > >template <> >struct is_stateless< blank > > : mpl::true_ >{ >}; > > > > >inline bool operator==(const blank&, const blank&) >{ > return true; >} > >inline bool operator<=(const blank&, const blank&) >{ > return true; >} > >inline bool operator>=(const blank&, const blank&) >{ > return true; >} > >inline bool operator!=(const blank&, const blank&) >{ > return false; >} > >inline bool operator<(const blank&, const blank&) >{ > return false; >} > >inline bool operator>(const blank&, const blank&) >{ > return false; >} > > > > > >template < typename E , typename T > >inline std::basic_ostream< E , T >& operator<<( > std::basic_ostream< E , T >& out > , const blank& > ) >{ > > return out; >} > > > >} ># 46 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/math/common_factor_ct.hpp" 1 3 4 ># 17 "/usr/include/boost/math/common_factor_ct.hpp" 3 4 >namespace boost >{ >namespace math >{ > > > >namespace detail >{ > > > template < static_gcd_type Value1, static_gcd_type Value2 > > struct static_gcd_helper_t > { > private: > static const static_gcd_type new_value1 = Value2; > static const static_gcd_type new_value2 = Value1 % Value2; ># 42 "/usr/include/boost/math/common_factor_ct.hpp" 3 4 > typedef static_gcd_helper_t< static_cast<static_gcd_type>(new_value1), > static_cast<static_gcd_type>(new_value2) > next_step_type; > > > > public: > static const static_gcd_type value = next_step_type::value; > }; > > > template < static_gcd_type Value1 > > struct static_gcd_helper_t< Value1, 0UL > > { > static const static_gcd_type value = Value1; > }; ># 100 "/usr/include/boost/math/common_factor_ct.hpp" 3 4 > template < static_gcd_type Value1, static_gcd_type Value2 > > struct static_lcm_helper_t > { > typedef static_gcd_helper_t<Value1, Value2> gcd_type; > > static const static_gcd_type value = Value1 / gcd_type::value * Value2 > ; > }; > > > template < > > struct static_lcm_helper_t< 0UL, 0UL > > { > static const static_gcd_type value = 0UL; > }; ># 157 "/usr/include/boost/math/common_factor_ct.hpp" 3 4 >} > > > > >template < static_gcd_type Value1, static_gcd_type Value2 > >struct static_gcd : public mpl::integral_c<static_gcd_type, (detail::static_gcd_helper_t<Value1, Value2>::value) > >{ >}; > > > > >template < static_gcd_type Value1, static_gcd_type Value2 > >struct static_lcm : public mpl::integral_c<static_gcd_type, (detail::static_lcm_helper_t<Value1, Value2>::value) > >{ >}; > > >} >} ># 47 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 67 "/usr/include/boost/variant/variant.hpp" 3 4 ># 1 "/usr/include/boost/mpl/empty.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/empty.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/empty_impl.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/empty_impl.hpp" 3 4 >namespace boost { namespace mpl { > > > > >template< typename Tag > >struct empty_impl >{ > template< typename Sequence > struct apply > : is_same< > typename begin<Sequence>::type > , typename end<Sequence>::type > > > { > }; >}; > > template<> struct empty_impl<non_sequence_tag> {}; > >}} ># 20 "/usr/include/boost/mpl/empty.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > > >struct empty > : empty_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence > >{ > >}; > >template<> struct empty< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : empty< T1 > { }; }; template< typename Tag > struct lambda< empty< na > , Tag , int_<-1> > { typedef false_ is_le; typedef empty< na > result_; typedef empty< na > type; }; namespace aux { template< typename T1 > struct template_arity< empty< T1 > > : int_<1> { }; template<> struct template_arity< empty< na > > : int_<-1> { }; } > >}} ># 68 "/usr/include/boost/variant/variant.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/front.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/front.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/front_impl.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/front_impl.hpp" 3 4 >namespace boost { namespace mpl { > > > > >template< typename Tag > >struct front_impl >{ > template< typename Sequence > struct apply > { > typedef typename begin<Sequence>::type iter_; > typedef typename deref<iter_>::type type; > }; >}; > > template<> struct front_impl<non_sequence_tag> {}; > >}} ># 19 "/usr/include/boost/mpl/front.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > > >struct front > : front_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence > >{ > >}; > >template<> struct front< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : front< T1 > { }; }; template< typename Tag > struct lambda< front< na > , Tag , int_<-1> > { typedef false_ is_le; typedef front< na > result_; typedef front< na > type; }; namespace aux { template< typename T1 > struct template_arity< front< T1 > > : int_<1> { }; template<> struct template_arity< front< na > > : int_<-1> { }; } > >}} ># 72 "/usr/include/boost/variant/variant.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/is_sequence.hpp" 1 3 4 ># 40 "/usr/include/boost/mpl/is_sequence.hpp" 3 4 >namespace boost { namespace mpl { ># 90 "/usr/include/boost/mpl/is_sequence.hpp" 3 4 >template< > typename T = na > > >struct is_sequence > : not_< is_same< typename begin<T>::type, void_ > > >{ > >}; ># 108 "/usr/include/boost/mpl/is_sequence.hpp" 3 4 >template<> struct is_sequence< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : is_sequence< T1 > { }; }; template< typename Tag > struct lambda< is_sequence< na > , Tag , int_<-1> > { typedef false_ is_le; typedef is_sequence< na > result_; typedef is_sequence< na > type; }; namespace aux { template< typename T1 > struct template_arity< is_sequence< T1 > > : int_<1> { }; template<> struct template_arity< is_sequence< na > > : int_<-1> { }; } > >}} ># 76 "/usr/include/boost/variant/variant.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/max_element.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/max_element.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 23 "/usr/include/boost/mpl/max_element.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > > > >namespace aux { > >template< typename Predicate > >struct select_max >{ > template< typename OldIterator, typename Iterator > > struct apply > { > typedef typename apply2< > Predicate > , typename deref<OldIterator>::type > , typename deref<Iterator>::type > >::type condition_; > > typedef typename if_< > condition_ > , Iterator > , OldIterator > >::type type; > }; >}; > >} > > >template< > typename Sequence = na > , typename Predicate = less<_,_> > > >struct max_element > : iter_fold< > Sequence > , typename begin<Sequence>::type > , protect< aux::select_max<Predicate> > > > >{ >}; > >template<> struct max_element< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : max_element< T1 > { }; }; template< typename Tag > struct lambda< max_element< na > , Tag , int_<-1> > { typedef false_ is_le; typedef max_element< na > result_; typedef max_element< na > type; }; namespace aux { template< typename T1 > struct template_arity< max_element< T1 > > : int_<1> { }; template<> struct template_arity< max_element< na > > : int_<-1> { }; } > >}} ># 80 "/usr/include/boost/variant/variant.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/sizeof.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/sizeof.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T = na > > >struct sizeof_ > : mpl::size_t< sizeof(T) > >{ > >}; > >template<> struct sizeof_< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : sizeof_< T1 > { }; }; template< typename Tag > struct lambda< sizeof_< na > , Tag , int_<-1> > { typedef false_ is_le; typedef sizeof_< na > result_; typedef sizeof_< na > type; }; namespace aux { template< typename T1 > struct template_arity< sizeof_< T1 > > : int_<1> { }; template<> struct template_arity< sizeof_< na > > : int_<-1> { }; } > >}} ># 88 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/transform.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/transform.hpp" 3 4 ># 1 "/usr/include/boost/mpl/pair_view.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/pair_view.hpp" 3 4 ># 1 "/usr/include/boost/mpl/iterator_category.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/iterator_category.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename Iterator = na > > >struct iterator_category >{ > typedef typename Iterator::category type; > >}; > >template<> struct iterator_category< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : iterator_category< T1 > { }; }; template< typename Tag > struct lambda< iterator_category< na > , Tag , int_<-1> > { typedef false_ is_le; typedef iterator_category< na > result_; typedef iterator_category< na > type; }; namespace aux { template< typename T1 > struct template_arity< iterator_category< T1 > > : int_<1> { }; template<> struct template_arity< iterator_category< na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/pair_view.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/mpl/min_max.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/min_max.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename N1 = na > , typename N2 = na > > >struct min > : if_< less<N1,N2>,N1,N2 > >{ >}; > >template< > typename N1 = na > , typename N2 = na > > >struct max > : if_< less<N1,N2>,N2,N1 > >{ >}; > >template<> struct min< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : min< T1 , T2 > { }; }; template< typename Tag > struct lambda< min< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef min< na , na > result_; typedef min< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< min< T1 , T2 > > : int_<2> { }; template<> struct template_arity< min< na , na > > : int_<-1> { }; } >template<> struct max< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : max< T1 , T2 > { }; }; template< typename Tag > struct lambda< max< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef max< na , na > result_; typedef max< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< max< T1 , T2 > > : int_<2> { }; template<> struct template_arity< max< na , na > > : int_<-1> { }; } > >}} ># 25 "/usr/include/boost/mpl/pair_view.hpp" 2 3 4 > > > > > >namespace boost { namespace mpl { > >namespace aux { >struct pair_iter_tag; ># 59 "/usr/include/boost/mpl/pair_view.hpp" 3 4 >} > >template< > typename Iter1 > , typename Iter2 > , typename Category > > >struct pair_iter >{ > typedef aux::pair_iter_tag tag; > typedef Category category; > typedef Iter1 first; > typedef Iter2 second; ># 85 "/usr/include/boost/mpl/pair_view.hpp" 3 4 >}; > > > > >template< typename Iter1, typename Iter2, typename C > >struct deref< pair_iter<Iter1,Iter2,C> > >{ > typedef pair< > typename deref<Iter1>::type > , typename deref<Iter2>::type > > type; >}; > >template< typename Iter1, typename Iter2, typename C > >struct next< pair_iter<Iter1,Iter2,C> > >{ > typedef typename mpl::next<Iter1>::type i1_; > typedef typename mpl::next<Iter2>::type i2_; > typedef pair_iter<i1_,i2_,C> type; >}; > >template< typename Iter1, typename Iter2, typename C > >struct prior< pair_iter<Iter1,Iter2,C> > >{ > typedef typename mpl::prior<Iter1>::type i1_; > typedef typename mpl::prior<Iter2>::type i2_; > typedef pair_iter<i1_,i2_,C> type; >}; > > > > >template<> struct advance_impl<aux::pair_iter_tag> >{ > template< typename Iter, typename D > struct apply > { > typedef typename mpl::advance< typename Iter::first,D >::type i1_; > typedef typename mpl::advance< typename Iter::second,D >::type i2_; > typedef pair_iter<i1_,i2_,typename Iter::category> type; > }; >}; > >template<> struct distance_impl<aux::pair_iter_tag> >{ > template< typename Iter1, typename Iter2 > struct apply > { > > typedef typename mpl::distance< > typename first<Iter1>::type > , typename first<Iter2>::type > >::type type; > }; >}; > > >template< > typename Sequence1 = na > , typename Sequence2 = na > > >struct pair_view >{ > typedef nested_begin_end_tag tag; > > typedef typename begin<Sequence1>::type iter1_; > typedef typename begin<Sequence2>::type iter2_; > typedef typename min< > typename iterator_category<iter1_>::type > , typename iterator_category<iter2_>::type > >::type category_; > > typedef pair_iter<iter1_,iter2_,category_> begin; > > typedef pair_iter< > typename end<Sequence1>::type > , typename end<Sequence2>::type > , category_ > > end; >}; > >template<> struct pair_view< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : pair_view< T1 , T2 > { }; }; template< typename Tag > struct lambda< pair_view< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef pair_view< na , na > result_; typedef pair_view< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< pair_view< T1 , T2 > > : int_<2> { }; template<> struct template_arity< pair_view< na , na > > : int_<-1> { }; } > >}} ># 21 "/usr/include/boost/mpl/transform.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/bind.hpp" 1 3 4 ># 25 "/usr/include/boost/mpl/transform.hpp" 2 3 4 > > > > > >namespace boost { namespace mpl { > >namespace aux { > >template< > typename Seq > , typename Op > , typename In > > >struct transform1_impl > : fold< > Seq > , typename In::state > , bind2< typename lambda< typename In::operation >::type > , _1 > , bind1< typename lambda<Op>::type, _2> > > > > >{ >}; > >template< > typename Seq > , typename Op > , typename In > > >struct reverse_transform1_impl > : reverse_fold< > Seq > , typename In::state > , bind2< typename lambda< typename In::operation >::type > , _1 > , bind1< typename lambda<Op>::type, _2> > > > > >{ >}; > >template< > typename Seq1 > , typename Seq2 > , typename Op > , typename In > > >struct transform2_impl > : fold< > pair_view<Seq1,Seq2> > , typename In::state > , bind2< typename lambda< typename In::operation >::type > , _1 > , bind2< > typename lambda<Op>::type > , bind1<first<>,_2> > , bind1<second<>,_2> > > > > > > >{ >}; > >template< > typename Seq1 > , typename Seq2 > , typename Op > , typename In > > >struct reverse_transform2_impl > : reverse_fold< > pair_view<Seq1,Seq2> > , typename In::state > , bind2< typename lambda< typename In::operation >::type > , _1 > , bind2< typename lambda< Op >::type > , bind1<first<>,_2> > , bind1<second<>,_2> > > > > > > >{ >}; > >} > > template< typename P1 = na , typename P2 = na , typename P3 = na > struct transform1 : aux::transform1_impl< P1 , P2 , P3> { }; template< typename P1 , typename P2 > struct transform1< P1 , P2,na > : if_< has_push_back< typename clear<P1>::type> , aux::transform1_impl< P1 , P2 , back_inserter< typename clear<P1>::type > > , aux::reverse_transform1_impl< P1 , P2 , front_inserter< typename clear<P1>::type > > >::type { }; template< typename P1 = na , typename P2 = na , typename P3 = na > struct reverse_transform1 : aux::reverse_transform1_impl< P1 , P2 , P3> { }; template< typename P1 , typename P2 > struct reverse_transform1< P1 , P2,na > : if_< has_push_back<P1> , aux::reverse_transform1_impl< P1 , P2 , back_inserter< typename clear<P1>::type > > , aux::transform1_impl< P1 , P2 , front_inserter< typename clear<P1>::type > > >::type { }; template<> struct transform1< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : transform1< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< transform1< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef transform1< na , na , na > result_; typedef transform1< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< transform1< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< transform1< na , na , na > > : int_<-1> { }; } template<> struct reverse_transform1< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : reverse_transform1< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< reverse_transform1< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef reverse_transform1< na , na , na > result_; typedef reverse_transform1< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< reverse_transform1< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< reverse_transform1< na , na , na > > : int_<-1> { }; } > template< typename P1 = na , typename P2 = na , typename P3 = na , typename P4 = na > struct transform2 : aux::transform2_impl< P1 , P2 , P3 , P4> { }; template< typename P1 , typename P2 , typename P3 > struct transform2< P1 , P2 , P3,na > : if_< has_push_back< typename clear<P1>::type> , aux::transform2_impl< P1 , P2 , P3 , back_inserter< typename clear<P1>::type > > , aux::reverse_transform2_impl< P1 , P2 , P3 , front_inserter< typename clear<P1>::type > > >::type { }; template< typename P1 = na , typename P2 = na , typename P3 = na , typename P4 = na > struct reverse_transform2 : aux::reverse_transform2_impl< P1 , P2 , P3 , P4> { }; template< typename P1 , typename P2 , typename P3 > struct reverse_transform2< P1 , P2 , P3,na > : if_< has_push_back<P1> , aux::reverse_transform2_impl< P1 , P2 , P3 , back_inserter< typename clear<P1>::type > > , aux::transform2_impl< P1 , P2 , P3 , front_inserter< typename clear<P1>::type > > >::type { }; template<> struct transform2< na , na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 =na > struct apply : transform2< T1 , T2 , T3 , T4 > { }; }; template< typename Tag > struct lambda< transform2< na , na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef transform2< na , na , na , na > result_; typedef transform2< na , na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 > struct template_arity< transform2< T1 , T2 , T3 , T4 > > : int_<4> { }; template<> struct template_arity< transform2< na , na , na , na > > : int_<-1> { }; } template<> struct reverse_transform2< na , na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 =na > struct apply : reverse_transform2< T1 , T2 , T3 , T4 > { }; }; template< typename Tag > struct lambda< reverse_transform2< na , na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef reverse_transform2< na , na , na , na > result_; typedef reverse_transform2< na , na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 > struct template_arity< reverse_transform2< T1 , T2 , T3 , T4 > > : int_<4> { }; template<> struct template_arity< reverse_transform2< na , na , na , na > > : int_<-1> { }; } ># 138 "/usr/include/boost/mpl/transform.hpp" 3 4 >template< typename Seq1 = na , typename Seq2OrOperation = na , typename OperationOrInserter = na , typename Inserter = na > struct transform { typedef typename eval_if< or_< is_na<OperationOrInserter> , is_lambda_expression< Seq2OrOperation > , not_< is_sequence<Seq2OrOperation> > > , transform1<Seq1,Seq2OrOperation,OperationOrInserter> , transform2<Seq1,Seq2OrOperation,OperationOrInserter,Inserter> >::type type; }; template<> struct transform< na , na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 =na > struct apply : transform< T1 , T2 , T3 , T4 > { }; }; template< typename Tag > struct lambda< transform< na , na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef transform< na , na , na , na > result_; typedef transform< na , na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 > struct template_arity< transform< T1 , T2 , T3 , T4 > > : int_<4> { }; template<> struct template_arity< transform< na , na , na , na > > : int_<-1> { }; } >template< typename Seq1 = na , typename Seq2OrOperation = na , typename OperationOrInserter = na , typename Inserter = na > struct reverse_transform { typedef typename eval_if< or_< is_na<OperationOrInserter> , is_lambda_expression< Seq2OrOperation > , not_< is_sequence<Seq2OrOperation> > > , reverse_transform1<Seq1,Seq2OrOperation,OperationOrInserter> , reverse_transform2<Seq1,Seq2OrOperation,OperationOrInserter,Inserter> >::type type; }; template<> struct reverse_transform< na , na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 =na > struct apply : reverse_transform< T1 , T2 , T3 , T4 > { }; }; template< typename Tag > struct lambda< reverse_transform< na , na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef reverse_transform< na , na , na , na > result_; typedef reverse_transform< na , na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 > struct template_arity< reverse_transform< T1 , T2 , T3 , T4 > > : int_<4> { }; template<> struct template_arity< reverse_transform< na , na , na , na > > : int_<-1> { }; } > > > >}} ># 89 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 115 "/usr/include/boost/variant/variant.hpp" 3 4 >namespace boost { > >namespace detail { namespace variant { > > > > > > >template <typename Sequence, typename F> >struct max_value >{ >private: > > typedef typename mpl::transform1<Sequence, F>::type transformed_; > typedef typename mpl::max_element<transformed_ > > >::type max_it; > >public: > > typedef typename mpl::deref<max_it>::type > type; > >}; > >struct add_alignment >{ > template <typename State, typename Item> > struct apply > : mpl::size_t< > ::boost::math::static_lcm< > State::value > , ::boost::alignment_of<Item>::value > >::value > > > {}; >}; ># 164 "/usr/include/boost/variant/variant.hpp" 3 4 >class no_fallback_type; > >struct find_fallback_type_pred >{ > template <typename Iterator> > struct apply > { > private: > typedef typename mpl::deref<Iterator>::type t_; > > public: > typedef mpl::not_< has_nothrow_constructor<t_> > type; > }; >}; > >template <typename Types> >struct find_fallback_type >{ >private: > > typedef typename mpl::end<Types>::type end_it; > > > > typedef typename mpl::iter_fold_if< > Types > , mpl::int_<0>, mpl::protect< mpl::next<> > > , mpl::protect< find_fallback_type_pred > > >::type first_result_; > > typedef typename first_result_::first first_result_index; > typedef typename first_result_::second first_result_it; > > > > typedef typename mpl::iter_fold_if< > mpl::iterator_range< first_result_it,end_it > > , first_result_index, mpl::protect< mpl::next<> > > , mpl::protect< mpl::not_same_as<boost::blank> > > >::type second_result_; > > typedef typename second_result_::second second_result_it; > >public: > > > typedef typename mpl::eval_if< > is_same< second_result_it,end_it > > , mpl::if_< > is_same< first_result_it,end_it > > , mpl::pair< no_fallback_type,no_fallback_type > > , first_result_ > > > , mpl::identity< second_result_ > > >::type type; > >}; ># 238 "/usr/include/boost/variant/variant.hpp" 3 4 >template <class Types> >struct is_variant_move_noexcept { > typedef typename boost::mpl::find_if< > Types, mpl::not_<boost::is_nothrow_move_constructible<boost::mpl::_1> > > >::type iterator_t; > > typedef typename boost::mpl::end<Types>::type end_t; > typedef typename boost::is_same< > iterator_t, end_t > >::type type; >}; ># 258 "/usr/include/boost/variant/variant.hpp" 3 4 >template <typename Types, typename NeverUsesBackupFlag> >struct make_storage >{ >private: > > typedef typename mpl::eval_if< > NeverUsesBackupFlag > , mpl::identity< Types > > , mpl::push_front< > Types, backup_holder<void*> > > > >::type types; > > typedef typename max_value< > types, mpl::sizeof_<mpl::_1> > >::type max_size; > > > > typedef typename mpl::fold< > types > , mpl::size_t<1> > , add_alignment > >::type max_alignment; ># 290 "/usr/include/boost/variant/variant.hpp" 3 4 >public: > > > > typedef ::boost::aligned_storage< > max_size::value > , max_alignment::value > > type; ># 311 "/usr/include/boost/variant/variant.hpp" 3 4 >}; ># 328 "/usr/include/boost/variant/variant.hpp" 3 4 >struct destroyer > : public static_visitor<> >{ >public: > > template <typename T> > void > internal_visit(T& operand, int) const > { > operand.~T(); > > > > > > > ; > } > >}; ># 356 "/usr/include/boost/variant/variant.hpp" 3 4 >template <typename T> >class known_get > : public static_visitor<T&> >{ > > > >public: > > T& operator()(T& operand) const noexcept > { > return operand; > } > > > > > > template <typename U> > T& operator()(U&) const > { > > (static_cast<void> (0)); > return ::boost::detail::variant::forced_return< T& >(); > } ># 415 "/usr/include/boost/variant/variant.hpp" 3 4 >}; > > > > > > >class copy_into > : public static_visitor<> >{ >private: > > void* storage_; > >public: > > explicit copy_into(void* storage) noexcept > : storage_(storage) > { > } > >public: > > template <typename T> > void > internal_visit(boost::detail::variant::backup_holder<T>& operand, long) const > { > new(storage_) T( operand.get() ); > ; > } > > template <typename T> > void > internal_visit(const boost::detail::variant::backup_holder<T>& operand, long) const > { > new(storage_) T( operand.get() ); > ; > } > > template <typename T> > void > internal_visit(const T& operand, int) const > { > new(storage_) T(operand); > ; > } > >}; > > > > > > > >class move_into > : public static_visitor<> >{ >private: > > void* storage_; > >public: > > explicit move_into(void* storage) noexcept > : storage_(storage) > { > } > >public: > > template <typename T> > void > internal_visit(boost::detail::variant::backup_holder<T>& operand, long) const > { > new(storage_) T( ::boost::detail::variant::move(operand.get()) ); > ; > } > > template <typename T> > void > internal_visit(T& operand, int) const noexcept((noexcept((T(boost::declval<T>()))))) > { > new(storage_) T(::boost::detail::variant::move(operand)); > ; > } >}; ># 510 "/usr/include/boost/variant/variant.hpp" 3 4 >struct assign_storage > : public static_visitor<> >{ >private: > > const void* rhs_storage_; > >public: > > explicit assign_storage(const void* rhs_storage) noexcept > : rhs_storage_(rhs_storage) > { > } > >public: > > template <typename T> > void > internal_visit(backup_holder<T>& lhs_content, long) const > { > lhs_content.get() > = static_cast< const backup_holder<T>* >(rhs_storage_)->get(); > ; > } > > template <typename T> > void > internal_visit(const backup_holder<T>& lhs_content, long) const > { > lhs_content.get() > = static_cast< const backup_holder<T>* >(rhs_storage_)->get(); > ; > } > > template <typename T> > void > internal_visit(T& lhs_content, int) const > { > > > > > > > > lhs_content = *static_cast< const T* >(rhs_storage_); > ; > } > >}; > > > > > > > >struct move_storage > : public static_visitor<> >{ >private: > > void* rhs_storage_; > >public: > > explicit move_storage(void* rhs_storage) noexcept > : rhs_storage_(rhs_storage) > { > } > >public: > > template <typename T> > void > internal_visit(backup_holder<T>& lhs_content, long) const > { > lhs_content.get() > = ::boost::detail::variant::move(static_cast<backup_holder<T>* >(rhs_storage_)->get()); > ; > } > > template <typename T> > void > internal_visit(const backup_holder<T>& lhs_content, long) const > { > lhs_content.get() > = ::boost::detail::variant::move(static_cast<backup_holder<T>* >(rhs_storage_)->get()); > ; > } > > template <typename T> > void > internal_visit(T& lhs_content, int) const > { > > > > > > > > lhs_content = ::boost::detail::variant::move(*static_cast<T* >(rhs_storage_)); > ; > } > >}; ># 625 "/usr/include/boost/variant/variant.hpp" 3 4 >template <typename T> >class direct_assigner > : public static_visitor<bool> >{ >private: > > const T& rhs_; > >public: > > explicit direct_assigner(const T& rhs) noexcept > : rhs_(rhs) > { > } > > > >public: > > bool operator()(T& lhs) > { > lhs = rhs_; > return true; > } > > template <typename U> > bool operator()(U&) noexcept > { > return false; > } ># 688 "/usr/include/boost/variant/variant.hpp" 3 4 >}; ># 697 "/usr/include/boost/variant/variant.hpp" 3 4 >template <typename T> >class direct_mover > : public static_visitor<bool> >{ >private: > > T& rhs_; > >public: > > explicit direct_mover(T& rhs) noexcept > : rhs_(rhs) > { > } > > > >public: > > bool operator()(T& lhs) > { > lhs = ::boost::detail::variant::move(rhs_); > return true; > } > > template <typename U> > bool operator()(U&) noexcept > { > return false; > } ># 746 "/usr/include/boost/variant/variant.hpp" 3 4 >}; ># 758 "/usr/include/boost/variant/variant.hpp" 3 4 >template <typename Variant> >class backup_assigner > : public static_visitor<> >{ >private: > > Variant& lhs_; > int rhs_which_; > const void* rhs_content_; > void (*copy_rhs_content_)(void*, const void*); > >public: > > template<class RhsT> > backup_assigner(Variant& lhs, int rhs_which, const RhsT& rhs_content) > : lhs_(lhs) > , rhs_which_(rhs_which) > , rhs_content_(&rhs_content) > , copy_rhs_content_(&construct_impl<RhsT>) > { > } > >private: > > template<class RhsT> > static void construct_impl(void* addr, const void* obj) > { > new(addr) RhsT(*static_cast<const RhsT*>(obj)); > } > > template <typename LhsT> > void backup_assign_impl( > LhsT& lhs_content > , mpl::true_ > ) > { > > LhsT backup_lhs_content( > ::boost::detail::variant::move(lhs_content) > ); > > > lhs_content.~LhsT(); > > { try > { > > copy_rhs_content_(lhs_.storage_.address(), rhs_content_); > } > catch(...) > { > > new(lhs_.storage_.address()) > LhsT( > ::boost::detail::variant::move(backup_lhs_content) > ); > > > throw;; > } > } > > > lhs_.indicate_which(rhs_which_); > } > > template <typename LhsT> > void backup_assign_impl( > LhsT& lhs_content > , mpl::false_ > ) > { > > LhsT* backup_lhs_ptr = new LhsT(lhs_content); > > > lhs_content.~LhsT(); > > { try > { > > copy_rhs_content_(lhs_.storage_.address(), rhs_content_); > } > catch(...) > { > > new(lhs_.storage_.address()) > backup_holder<LhsT>( backup_lhs_ptr ); > > > lhs_.indicate_backup_which( lhs_.which() ); > > > throw;; > } > } > > > lhs_.indicate_which(rhs_which_); > > > delete backup_lhs_ptr; > } > >public: > > template <typename LhsT> > void > internal_visit(LhsT& lhs_content, int) > { > typedef typename is_nothrow_move_constructible<LhsT>::type > nothrow_move; > > backup_assign_impl( lhs_content, nothrow_move() ); > > ; > } > > > > > > >}; ># 890 "/usr/include/boost/variant/variant.hpp" 3 4 >template <typename Variant> >struct swap_with > : public static_visitor<> >{ >private: > > Variant& toswap_; > >public: > > explicit swap_with(Variant& toswap) > : toswap_(toswap) > { > } > >public: > > template <typename T> > void operator()(T& operand) const > { > > known_get<T> getter; > T& other = toswap_.apply_visitor(getter); > > > ::boost::detail::variant::move_swap( operand, other ); > } > >private: > swap_with& operator=(const swap_with&); > >}; ># 931 "/usr/include/boost/variant/variant.hpp" 3 4 >class reflect > : public static_visitor<const std::type_info&> >{ >public: > > template <typename T> > const std::type_info& operator()(const T&) const noexcept > { > return typeid(T); > } > >}; ># 954 "/usr/include/boost/variant/variant.hpp" 3 4 >template <typename Variant, typename Comp> >class comparer > : public static_visitor<bool> >{ >private: > > const Variant& lhs_; > >public: > > explicit comparer(const Variant& lhs) noexcept > : lhs_(lhs) > { > } > >public: > > template <typename T> > bool operator()(const T& rhs_content) const > { > > known_get<const T> getter; > const T& lhs_content = lhs_.apply_visitor(getter); > > > return Comp()(lhs_content, rhs_content); > } > >private: > comparer& operator=(const comparer&); > >}; > > > > > > >struct equal_comp >{ > template <typename T> > bool operator()(const T& lhs, const T& rhs) const > { > return lhs == rhs; > } >}; > > > > > > >struct less_comp >{ > template <typename T> > bool operator()(const T& lhs, const T& rhs) const > { > return lhs < rhs; > } >}; ># 1022 "/usr/include/boost/variant/variant.hpp" 3 4 >template <typename Visitor> >class invoke_visitor >{ >private: > > Visitor& visitor_; > >public: > > typedef typename Visitor::result_type > result_type; > >public: > > explicit invoke_visitor(Visitor& visitor) noexcept > : visitor_(visitor) > { > } > > > >public: > > template <typename T> > result_type internal_visit(T& operand, int) > { > return visitor_(operand); > } ># 1092 "/usr/include/boost/variant/variant.hpp" 3 4 >public: > > template <typename T> > result_type > internal_visit(boost::recursive_wrapper<T>& operand, long) > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > result_type > internal_visit(const boost::recursive_wrapper<T>& operand, long) > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > result_type > internal_visit(boost::detail::reference_content<T>& operand, long) > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > result_type > internal_visit(const boost::detail::reference_content<T>& operand, long) > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > result_type > internal_visit(boost::detail::variant::backup_holder<T>& operand, long) > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > result_type > internal_visit(const boost::detail::variant::backup_holder<T>& operand, long) > { > return internal_visit( operand.get(), 1L ); > } > > > > > > >}; > >}} > > > > > > >template < > typename T0_ > , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > > >class variant >{ >private: > > typedef variant wknd_self_t; > > struct is_recursive_ > : detail::variant::is_recursive_flag<T0_> > { > }; > > typedef typename mpl::eval_if< > is_recursive_ > , T0_ > , mpl::identity< T0_ > > >::type unwrapped_T0_; > > struct is_sequence_based_ > : detail::variant::is_over_sequence<unwrapped_T0_> > { > }; > > > >private: > > typedef typename mpl::eval_if< > is_sequence_based_ > , unwrapped_T0_ > , detail::variant::make_variant_list< > unwrapped_T0_ > , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 > > > >::type specified_types; > > static_assert(( ::boost::mpl::not_< mpl::empty<specified_types> >::value ), "( ::boost::mpl::not_< mpl::empty<specified_types> >::value )") > > ; > > typedef typename mpl::eval_if< > is_recursive_ > , mpl::transform< > specified_types > , mpl::protect< > detail::variant::quoted_enable_recursive<wknd_self_t> > > > > > , mpl::identity< specified_types > > >::type recursive_enabled_types; > >public: > > typedef typename mpl::transform< > recursive_enabled_types > , unwrap_recursive<mpl::_1> > >::type types; > >private: > > typedef typename mpl::transform< > recursive_enabled_types > , mpl::protect< detail::make_reference_content<> > > >::type internal_types; > > typedef typename mpl::front< > internal_types > >::type internal_T0; ># 1298 "/usr/include/boost/variant/variant.hpp" 3 4 >private: > > typedef typename detail::variant::find_fallback_type< > internal_types > >::type fallback_type_result_; > > typedef typename fallback_type_result_::first > fallback_type_index_; > typedef typename fallback_type_result_::second > fallback_type_; > > struct has_fallback_type_ > : mpl::not_< > is_same< fallback_type_, detail::variant::no_fallback_type > > > > { > }; > > typedef has_fallback_type_ > never_uses_backup_flag; > > typedef typename detail::variant::make_storage< > internal_types, never_uses_backup_flag > >::type storage_t; > > > typedef typename detail::variant::is_variant_move_noexcept< > internal_types > > variant_move_noexcept; > > >private: ># 1340 "/usr/include/boost/variant/variant.hpp" 3 4 > typedef int which_t; ># 1360 "/usr/include/boost/variant/variant.hpp" 3 4 > private: > > > > > which_t which_; > storage_t storage_; > > void indicate_which(int which_arg) noexcept > { > which_ = static_cast<which_t>( which_arg ); > } > > void indicate_backup_which(int which_arg) noexcept > { > which_ = static_cast<which_t>( -(which_arg + 1) ); > } > >private: > > bool using_backup() const noexcept > { > return which_ < 0; > } > >public: > > int which() const noexcept > { > > if (using_backup()) > > return -(which_ + 1); > > > return which_; > } > >private: > > struct initializer > : ::boost::mpl::iter_fold< recursive_enabled_types , ::boost::mpl::pair< ::boost::detail::variant::initializer_root , ::boost::mpl::int_<0> > , ::boost::mpl::protect< ::boost::detail::variant::make_initializer_node > >::type::first > > > { > }; > > void destroy_content() > { > detail::variant::destroyer visitor; > this->internal_apply_visitor(visitor); > } > >public: > > ~variant() noexcept > { > destroy_content(); > } > > variant() > { > > > > > > new( storage_.address() ) internal_T0(); > indicate_which(0); > } > >private: > > class convert_copy_into > : public static_visitor<int> > { > private: > > void* storage_; > > public: > > explicit convert_copy_into(void* storage) noexcept > : storage_(storage) > { > } > > public: > > template <typename T> > int internal_visit(T& operand, int) const > { > > > > > > return initializer::initialize(storage_, operand); > } ># 1468 "/usr/include/boost/variant/variant.hpp" 3 4 > template <typename T> > int internal_visit(boost::detail::reference_content<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(const boost::detail::reference_content<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(boost::detail::variant::backup_holder<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(const boost::detail::variant::backup_holder<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(boost::recursive_wrapper<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(const boost::recursive_wrapper<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > }; > > friend class convert_copy_into; > > > class convert_move_into > : public static_visitor<int> > { > private: > > void* storage_; > > public: > > explicit convert_move_into(void* storage) noexcept > : storage_(storage) > { > } > > public: > > template <typename T> > int internal_visit(T& operand, int) const > { > > > > > > return initializer::initialize(storage_, detail::variant::move(operand) ); > } > > template <typename T> > int internal_visit(boost::detail::reference_content<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(const boost::detail::reference_content<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(boost::detail::variant::backup_holder<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(const boost::detail::variant::backup_holder<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(boost::recursive_wrapper<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > > template <typename T> > int internal_visit(const boost::recursive_wrapper<T>& operand, long) const > { > return internal_visit( operand.get(), 1L ); > } > }; > > friend class convert_move_into; > > >private: > > template <typename T> > void convert_construct( > T& operand > , int > , mpl::false_ = mpl::false_() > ) > { > > > > > > indicate_which( > initializer::initialize( > storage_.address() > , operand > ) > ); > } > > > template <typename T> > typename boost::enable_if<boost::is_rvalue_reference<T&&> >::type convert_construct( > T&& operand > , int > , mpl::false_ = mpl::false_() > ) > { > > > > > > indicate_which( > initializer::initialize( > storage_.address() > , detail::variant::move(operand) > ) > ); > } > > > template <typename Variant> > void convert_construct( > Variant& operand > , long > , mpl::true_ > ) > { > convert_copy_into visitor(storage_.address()); > indicate_which( > operand.internal_apply_visitor(visitor) > ); > } > > > template <typename Variant> > typename boost::enable_if<boost::is_rvalue_reference<Variant&&> >::type convert_construct( > Variant&& operand > , long > , mpl::true_ > ) > { > convert_move_into visitor(storage_.address()); > indicate_which( > operand.internal_apply_visitor(visitor) > ); > } > > > template <typename Variant> > void convert_construct_variant(Variant& operand) > { > > > > > typedef typename mpl::find_if< > types > , is_same< > add_const<mpl::_1> > , const Variant > > > >::type found_it; > > typedef typename mpl::end<types>::type not_found; > typedef typename is_same< > found_it, not_found > >::type is_foreign_variant; > > > convert_construct( > operand, 1L > , is_foreign_variant() > ); > } > > > template <typename Variant> > typename boost::enable_if<boost::is_rvalue_reference<Variant&&> >::type convert_construct_variant(Variant&& operand) > { > > > > > typedef typename mpl::find_if< > types > , is_same< > add_const<mpl::_1> > , const Variant > > > >::type found_it; > > typedef typename mpl::end<types>::type not_found; > typedef typename is_same< > found_it, not_found > >::type is_foreign_variant; > > > convert_construct( > detail::variant::move(operand), 1L > , is_foreign_variant() > ); > } > > > template < typename U0 , typename U1 , typename U2 , typename U3 , typename U4 , typename U5 , typename U6 , typename U7 , typename U8 , typename U9 , typename U10 , typename U11 , typename U12 , typename U13 , typename U14 , typename U15 , typename U16 , typename U17 , typename U18 , typename U19> > void convert_construct( > boost::variant< U0 , U1 , U2 , U3 , U4 , U5 , U6 , U7 , U8 , U9 , U10 , U11 , U12 , U13 , U14 , U15 , U16 , U17 , U18 , U19>& operand > , long > ) > { > convert_construct_variant(operand); > } > > template < typename U0 , typename U1 , typename U2 , typename U3 , typename U4 , typename U5 , typename U6 , typename U7 , typename U8 , typename U9 , typename U10 , typename U11 , typename U12 , typename U13 , typename U14 , typename U15 , typename U16 , typename U17 , typename U18 , typename U19> > void convert_construct( > const boost::variant< U0 , U1 , U2 , U3 , U4 , U5 , U6 , U7 , U8 , U9 , U10 , U11 , U12 , U13 , U14 , U15 , U16 , U17 , U18 , U19>& operand > , long > ) > { > convert_construct_variant(operand); > } > > > template < typename U0 , typename U1 , typename U2 , typename U3 , typename U4 , typename U5 , typename U6 , typename U7 , typename U8 , typename U9 , typename U10 , typename U11 , typename U12 , typename U13 , typename U14 , typename U15 , typename U16 , typename U17 , typename U18 , typename U19> > void convert_construct( > boost::variant< U0 , U1 , U2 , U3 , U4 , U5 , U6 , U7 , U8 , U9 , U10 , U11 , U12 , U13 , U14 , U15 , U16 , U17 , U18 , U19>&& operand > , long > ) > { > convert_construct_variant( detail::variant::move(operand) ); > } > > >public: > > > > template <typename T> > variant(const T& operand) > { > convert_construct(operand, 1L); > } > > template <typename T> > variant(T& operand) > { > convert_construct(operand, 1L); > } ># 1785 "/usr/include/boost/variant/variant.hpp" 3 4 > template <class T> > variant(T&& operand, typename boost::enable_if<boost::is_rvalue_reference<T&&> >::type* = 0, > typename boost::disable_if<boost::is_const<T> >::type* = 0) > { > convert_construct( detail::variant::move(operand), 1L); > } > > >public: > > > variant(const variant& operand) > { > > detail::variant::copy_into visitor( storage_.address() ); > operand.internal_apply_visitor(visitor); > > > indicate_which(operand.which()); > } > > > variant(variant&& operand) noexcept((variant_move_noexcept::type::value)) > { > > detail::variant::move_into visitor( storage_.address() ); > operand.internal_apply_visitor(visitor); > > > indicate_which(operand.which()); > } > > >private: > > > template <typename Variant> > friend class detail::variant::backup_assigner; ># 1831 "/usr/include/boost/variant/variant.hpp" 3 4 > class assigner > : public static_visitor<> > { > private: > > variant& lhs_; > int rhs_which_; > > public: > > assigner(variant& lhs, int rhs_which) noexcept > : lhs_(lhs) > , rhs_which_(rhs_which) > { > } > > private: > > template <typename RhsT, typename B1, typename B2> > void assign_impl( > const RhsT& rhs_content > , mpl::true_ > , B1 > , B2 > ) > { > > lhs_.destroy_content(); > > > new(lhs_.storage_.address()) > RhsT( rhs_content ); > > > lhs_.indicate_which(rhs_which_); > } > > template <typename RhsT, typename B> > void assign_impl( > const RhsT& rhs_content > , mpl::false_ > , mpl::true_ > , B > ) > { > > RhsT temp(rhs_content); > > > lhs_.destroy_content(); > > > new(lhs_.storage_.address()) > RhsT( detail::variant::move(temp) ); > > > lhs_.indicate_which(rhs_which_); > } > > template <typename RhsT> > void assign_impl( > const RhsT& rhs_content > , mpl::false_ > , mpl::false_ > , mpl::true_ > ) > { > > lhs_.destroy_content(); > > { try > { > > new(lhs_.storage_.address()) > RhsT( rhs_content ); > } > catch(...) > { > > new (lhs_.storage_.address()) > fallback_type_; > > > lhs_.indicate_which( > fallback_type_index_::value > ); > > > throw;; > } > } > > > lhs_.indicate_which(rhs_which_); > } > > template <typename RhsT> > void assign_impl( > const RhsT& rhs_content > , mpl::false_ > , mpl::false_ > , mpl::false_ > ) > { > detail::variant::backup_assigner<wknd_self_t> > visitor(lhs_, rhs_which_, rhs_content); > lhs_.internal_apply_visitor(visitor); > } > > public: > > template <typename RhsT> > void > internal_visit(const RhsT& rhs_content, int) > { > typedef typename has_nothrow_copy<RhsT>::type > nothrow_copy; > typedef typename mpl::or_< > nothrow_copy > , is_nothrow_move_constructible<RhsT> > >::type nothrow_move_constructor; > > assign_impl( > rhs_content > , nothrow_copy() > , nothrow_move_constructor() > , has_fallback_type_() > ); > > ; > } > > > > > > > }; > > friend class assigner; ># 1979 "/usr/include/boost/variant/variant.hpp" 3 4 > class move_assigner > : public static_visitor<> > { > private: > > variant& lhs_; > int rhs_which_; > > public: > > move_assigner(variant& lhs, int rhs_which) noexcept > : lhs_(lhs) > , rhs_which_(rhs_which) > { > } > > private: > > template <typename RhsT, typename B2> > void assign_impl( > RhsT& rhs_content > , mpl::true_ > , mpl::false_ > , B2 > ) > { > > lhs_.destroy_content(); > > > new(lhs_.storage_.address()) > RhsT( rhs_content ); > > > lhs_.indicate_which(rhs_which_); > } > > template <typename RhsT, typename B> > void assign_impl( > RhsT& rhs_content > , mpl::true_ > , mpl::true_ > , B > ) > { > > lhs_.destroy_content(); > > > new(lhs_.storage_.address()) > RhsT( detail::variant::move(rhs_content) ); > > > lhs_.indicate_which(rhs_which_); > } > > template <typename RhsT> > void assign_impl( > RhsT& rhs_content > , mpl::false_ > , mpl::false_ > , mpl::true_ > ) > { > > lhs_.destroy_content(); > > { try > { > > new(lhs_.storage_.address()) > RhsT( detail::variant::move(rhs_content) ); > } > catch(...) > { > > new (lhs_.storage_.address()) > fallback_type_; > > > lhs_.indicate_which( > fallback_type_index_::value > ); > > > throw;; > } > } > > > lhs_.indicate_which(rhs_which_); > } > > template <typename RhsT> > void assign_impl( > const RhsT& rhs_content > , mpl::false_ > , mpl::false_ > , mpl::false_ > ) > { > detail::variant::backup_assigner<wknd_self_t> > visitor(lhs_, rhs_which_, rhs_content); > lhs_.internal_apply_visitor(visitor); > } > > public: > > template <typename RhsT> > void > internal_visit(RhsT& rhs_content, int) > { > typedef typename is_nothrow_move_constructible<RhsT>::type > nothrow_move_constructor; > typedef typename mpl::or_< > nothrow_move_constructor > , has_nothrow_copy<RhsT> > >::type nothrow_copy; > > assign_impl( > rhs_content > , nothrow_copy() > , nothrow_move_constructor() > , has_fallback_type_() > ); > > ; > } > > > > > > > }; > > friend class move_assigner; > > > void variant_assign(const variant& rhs) > { > > if (which_ == rhs.which_) > { > > detail::variant::assign_storage visitor(rhs.storage_.address()); > this->internal_apply_visitor(visitor); > } > else > { > > assigner visitor(*this, rhs.which()); > rhs.internal_apply_visitor(visitor); > } > } > > > void variant_assign(variant&& rhs) > { > > if (which_ == rhs.which_) > { > > detail::variant::move_storage visitor(rhs.storage_.address()); > this->internal_apply_visitor(visitor); > } > else > { > > move_assigner visitor(*this, rhs.which()); > rhs.internal_apply_visitor(visitor); > } > } > > >private: > > template <typename T> > void assign(const T& rhs) > { > > detail::variant::direct_assigner<T> direct_assign(rhs); > if (this->apply_visitor(direct_assign) == false) > { > > > > > > > variant temp(rhs); > variant_assign( detail::variant::move(temp) ); > } > } > > > template <typename T> > void move_assign(T&& rhs) > { > > detail::variant::direct_mover<T> direct_move(rhs); > if (this->apply_visitor(direct_move) == false) > { > > > > > > > variant temp( detail::variant::move(rhs) ); > variant_assign( detail::variant::move(temp) ); > } > } > > >public: > > > template <class T> > typename boost::enable_if_c<boost::is_rvalue_reference<T&&>::value && !boost::is_const<T>::value, variant& >::type > operator=(T&& rhs) > { > move_assign( detail::variant::move(rhs) ); > return *this; > } > > > template <typename T> > variant& operator=(const T& rhs) > { > assign(rhs); > return *this; > } > > > variant& operator=(const variant& rhs) > { > variant_assign(rhs); > return *this; > } > > > variant& operator=(variant&& rhs) > { > variant_assign( detail::variant::move(rhs) ); > return *this; > } > > > void swap(variant& rhs) > { > > if (which() == rhs.which()) > { > > detail::variant::swap_with<variant> visitor(rhs); > this->apply_visitor(visitor); > } > else > { > > variant tmp( detail::variant::move(rhs) ); > rhs = detail::variant::move(*this); > *this = detail::variant::move(tmp); > } > } > >public: > > > > > > bool empty() const noexcept > { > return false; > } > > > const std::type_info& type() const > { > detail::variant::reflect visitor; > return this->apply_visitor(visitor); > } > > >public: ># 2284 "/usr/include/boost/variant/variant.hpp" 3 4 > template <typename U> > void > operator==(const U&) const > { > static_assert(false && sizeof(U), "false && sizeof(U)"); > } > > template <typename U> > void > operator<(const U&) const > { > static_assert(false && sizeof(U), "false && sizeof(U)"); > } > >public: > > > > bool operator==(const variant& rhs) const > { > if (this->which() != rhs.which()) > return false; > > detail::variant::comparer< > variant, detail::variant::equal_comp > > visitor(*this); > return rhs.apply_visitor(visitor); > } > > bool operator<(const variant& rhs) const > { > > > > > if (this->which() != rhs.which()) > return this->which() < rhs.which(); > > detail::variant::comparer< > variant, detail::variant::less_comp > > visitor(*this); > return rhs.apply_visitor(visitor); > } > > > > > template < typename U0 , typename U1 , typename U2 , typename U3 , typename U4 , typename U5 , typename U6 , typename U7 , typename U8 , typename U9 , typename U10 , typename U11 , typename U12 , typename U13 , typename U14 , typename U15 , typename U16 , typename U17 , typename U18 , typename U19 > > friend class variant; > >private: > > > > > > > > template <typename Visitor, typename VoidPtrCV> > static > typename Visitor::result_type > > > internal_apply_visitor_impl( > int internal_which > , int logical_which > , Visitor& visitor > , VoidPtrCV storage > ) > { > typedef mpl::int_<0> first_which; > typedef typename mpl::begin<internal_types>::type first_it; > typedef typename mpl::end<internal_types>::type last_it; > > typedef detail::variant::visitation_impl_step< > first_it, last_it > > first_step; > > return detail::variant::visitation_impl( > internal_which, logical_which > , visitor, storage, mpl::false_() > , never_uses_backup_flag() > , static_cast<first_which*>(0), static_cast<first_step*>(0) > ); > } > > template <typename Visitor> > typename Visitor::result_type > > > internal_apply_visitor(Visitor& visitor) > { > return internal_apply_visitor_impl( > which_, which(), visitor, storage_.address() > ); > } > > template <typename Visitor> > typename Visitor::result_type > > > internal_apply_visitor(Visitor& visitor) const > { > return internal_apply_visitor_impl( > which_, which(), visitor, storage_.address() > ); > } > >public: > > template <typename Visitor> > typename Visitor::result_type > > > apply_visitor(Visitor& visitor) > { > detail::variant::invoke_visitor<Visitor> invoker(visitor); > return this->internal_apply_visitor(invoker); > } > > template <typename Visitor> > typename Visitor::result_type > > > apply_visitor(Visitor& visitor) const > { > detail::variant::invoke_visitor<Visitor> invoker(visitor); > return this->internal_apply_visitor(invoker); > } > >}; > > > > > > >template <typename Types> >struct make_variant_over >{ >private: > > > static_assert(( ::boost::mpl::is_sequence<Types>::value ), "( ::boost::mpl::is_sequence<Types>::value )"); > > >public: > > typedef variant< > detail::variant::over_sequence< Types > > > type; > >}; > > > > > > >template < typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > >inline void swap( > variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 >& lhs > , variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 >& rhs > ) >{ > lhs.swap(rhs); >} > >} > > > > ># 1 "/usr/include/boost/variant/detail/variant_io.hpp" 1 3 4 ># 23 "/usr/include/boost/variant/detail/variant_io.hpp" 3 4 >namespace boost { ># 32 "/usr/include/boost/variant/detail/variant_io.hpp" 3 4 >template < > typename E , typename T > , > typename U0 , typename U1 , typename U2 , typename U3 , typename U4 , typename U5 , typename U6 , typename U7 , typename U8 , typename U9 , typename U10 , typename U11 , typename U12 , typename U13 , typename U14 , typename U15 , typename U16 , typename U17 , typename U18 , typename U19 > > >inline std::basic_ostream< E , T >& operator<<( > std::basic_ostream< E , T >& out > , const variant< U0 , U1 , U2 , U3 , U4 , U5 , U6 , U7 , U8 , U9 , U10 , U11 , U12 , U13 , U14 , U15 , U16 , U17 , U18 , U19 >& rhs > ); > >namespace detail { namespace variant { > >template <typename OStream> >class printer > : public boost::static_visitor<> >{ >private: > > OStream& out_; > >public: > > explicit printer(OStream& out) > : out_( out ) > { > } > >public: > > template <typename T> > void operator()(const T& operand) const > { > out_ << operand; > } > >private: > printer& operator=(const printer&); > >}; > >}} > >template < > typename E , typename T > , > typename U0 , typename U1 , typename U2 , typename U3 , typename U4 , typename U5 , typename U6 , typename U7 , typename U8 , typename U9 , typename U10 , typename U11 , typename U12 , typename U13 , typename U14 , typename U15 , typename U16 , typename U17 , typename U18 , typename U19 > > >inline std::basic_ostream< E , T >& operator<<( > std::basic_ostream< E , T >& out > , const variant< U0 , U1 , U2 , U3 , U4 , U5 , U6 , U7 , U8 , U9 , U10 , U11 , U12 , U13 , U14 , U15 , U16 , U17 , U18 , U19 >& rhs > ) >{ > detail::variant::printer< > std::basic_ostream< E , T > > > visitor(out); > > rhs.apply_visitor(visitor); > > return out; >} > >} ># 2458 "/usr/include/boost/variant/variant.hpp" 2 3 4 ># 18 "/usr/include/boost/variant.hpp" 2 3 4 ># 1 "/usr/include/boost/variant/recursive_variant.hpp" 1 3 4 ># 17 "/usr/include/boost/variant/recursive_variant.hpp" 3 4 ># 1 "/usr/include/boost/variant/detail/enable_recursive.hpp" 1 3 4 ># 20 "/usr/include/boost/variant/detail/enable_recursive.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 21 "/usr/include/boost/variant/detail/enable_recursive.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/variant/detail/substitute.hpp" 1 3 4 ># 26 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessor/repeat.hpp" 1 3 4 ># 27 "/usr/include/boost/variant/detail/substitute.hpp" 2 3 4 > > > > > > > >namespace boost { >namespace detail { namespace variant { ># 48 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 >template < > typename T, typename Dest, typename Source > , typename Arity > > > > >struct substitute >{ > typedef T type; >}; ># 76 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 >template <typename Dest, typename Source> struct substitute< Source , Dest , Source , mpl::int_<-1> > { typedef Dest type; }; >template <typename Dest, typename Source> struct substitute< const Source , Dest , Source , mpl::int_<-1> > { typedef const Dest type; }; >template <typename Dest, typename Source> struct substitute< volatile Source , Dest , Source , mpl::int_<-1> > { typedef volatile Dest type; }; >template <typename Dest, typename Source> struct substitute< const volatile Source , Dest , Source , mpl::int_<-1> > { typedef const volatile Dest type; }; ># 101 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 >template <typename T, typename Dest, typename Source> struct substitute< T * , Dest , Source , mpl::int_<-1> > { typedef typename substitute< T, Dest, Source >::type * type; }; >template <typename T, typename Dest, typename Source> struct substitute< T * const , Dest , Source , mpl::int_<-1> > { typedef typename substitute< T, Dest, Source >::type * const type; }; >template <typename T, typename Dest, typename Source> struct substitute< T * volatile , Dest , Source , mpl::int_<-1> > { typedef typename substitute< T, Dest, Source >::type * volatile type; }; >template <typename T, typename Dest, typename Source> struct substitute< T * const volatile , Dest , Source , mpl::int_<-1> > { typedef typename substitute< T, Dest, Source >::type * const volatile type; }; > > > > > > >template <typename T, typename Dest, typename Source> >struct substitute< > T& > , Dest > , Source > , mpl::int_<-1> > > >{ > typedef typename substitute< > T, Dest, Source > >::type & type; >}; ># 140 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 18 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 20 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/variant/detail/substitute.hpp" 1 3 4 ># 211 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 >template < > typename R, typename Dest, typename Source > > >struct substitute< > R (*)( void ) > , Dest > , Source > , mpl::int_<-1> > > >{ >private: > typedef typename substitute< R, Dest, Source >::type r; > >public: > typedef r (*type)( void ); >}; ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/variant/detail/substitute.hpp" 1 3 4 ># 162 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 >template < > template < typename P1 > class T > , typename U1 > , typename Dest > , typename Source > > >struct substitute< > T< U1 > > , Dest > , Source > , mpl::int_<( 1 )> > > >{ >private: > typedef typename substitute< U1, Dest, Source >::type u1; > >public: > typedef T< u1 > type; >}; > > > > >template < > typename R > , typename U1 > , typename Dest > , typename Source > > >struct substitute< > R (*)( U1 ) > , Dest > , Source > , mpl::int_<-1> > > >{ >private: > typedef typename substitute< R, Dest, Source >::type r; > typedef typename substitute< U1, Dest, Source >::type u1; > >public: > typedef r (*type)( u1 ); >}; ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/variant/detail/substitute.hpp" 1 3 4 ># 162 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 >template < > template < typename P1 , typename P2 > class T > , typename U1 , typename U2 > , typename Dest > , typename Source > > >struct substitute< > T< U1 , U2 > > , Dest > , Source > , mpl::int_<( 2 )> > > >{ >private: > typedef typename substitute< U1, Dest, Source >::type u1; typedef typename substitute< U2, Dest, Source >::type u2; > >public: > typedef T< u1 , u2 > type; >}; > > > > >template < > typename R > , typename U1 , typename U2 > , typename Dest > , typename Source > > >struct substitute< > R (*)( U1 , U2 ) > , Dest > , Source > , mpl::int_<-1> > > >{ >private: > typedef typename substitute< R, Dest, Source >::type r; > typedef typename substitute< U1, Dest, Source >::type u1; typedef typename substitute< U2, Dest, Source >::type u2; > >public: > typedef r (*type)( u1 , u2 ); >}; ># 58 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/variant/detail/substitute.hpp" 1 3 4 ># 162 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 >template < > template < typename P1 , typename P2 , typename P3 > class T > , typename U1 , typename U2 , typename U3 > , typename Dest > , typename Source > > >struct substitute< > T< U1 , U2 , U3 > > , Dest > , Source > , mpl::int_<( 3 )> > > >{ >private: > typedef typename substitute< U1, Dest, Source >::type u1; typedef typename substitute< U2, Dest, Source >::type u2; typedef typename substitute< U3, Dest, Source >::type u3; > >public: > typedef T< u1 , u2 , u3 > type; >}; > > > > >template < > typename R > , typename U1 , typename U2 , typename U3 > , typename Dest > , typename Source > > >struct substitute< > R (*)( U1 , U2 , U3 ) > , Dest > , Source > , mpl::int_<-1> > > >{ >private: > typedef typename substitute< R, Dest, Source >::type r; > typedef typename substitute< U1, Dest, Source >::type u1; typedef typename substitute< U2, Dest, Source >::type u2; typedef typename substitute< U3, Dest, Source >::type u3; > >public: > typedef r (*type)( u1 , u2 , u3 ); >}; ># 63 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/variant/detail/substitute.hpp" 1 3 4 ># 162 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 >template < > template < typename P1 , typename P2 , typename P3 , typename P4 > class T > , typename U1 , typename U2 , typename U3 , typename U4 > , typename Dest > , typename Source > > >struct substitute< > T< U1 , U2 , U3 , U4 > > , Dest > , Source > , mpl::int_<( 4 )> > > >{ >private: > typedef typename substitute< U1, Dest, Source >::type u1; typedef typename substitute< U2, Dest, Source >::type u2; typedef typename substitute< U3, Dest, Source >::type u3; typedef typename substitute< U4, Dest, Source >::type u4; > >public: > typedef T< u1 , u2 , u3 , u4 > type; >}; > > > > >template < > typename R > , typename U1 , typename U2 , typename U3 , typename U4 > , typename Dest > , typename Source > > >struct substitute< > R (*)( U1 , U2 , U3 , U4 ) > , Dest > , Source > , mpl::int_<-1> > > >{ >private: > typedef typename substitute< R, Dest, Source >::type r; > typedef typename substitute< U1, Dest, Source >::type u1; typedef typename substitute< U2, Dest, Source >::type u2; typedef typename substitute< U3, Dest, Source >::type u3; typedef typename substitute< U4, Dest, Source >::type u4; > >public: > typedef r (*type)( u1 , u2 , u3 , u4 ); >}; ># 68 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/variant/detail/substitute.hpp" 1 3 4 ># 162 "/usr/include/boost/variant/detail/substitute.hpp" 3 4 >template < > template < typename P1 , typename P2 , typename P3 , typename P4 , typename P5 > class T > , typename U1 , typename U2 , typename U3 , typename U4 , typename U5 > , typename Dest > , typename Source > > >struct substitute< > T< U1 , U2 , U3 , U4 , U5 > > , Dest > , Source > , mpl::int_<( 5 )> > > >{ >private: > typedef typename substitute< U1, Dest, Source >::type u1; typedef typename substitute< U2, Dest, Source >::type u2; typedef typename substitute< U3, Dest, Source >::type u3; typedef typename substitute< U4, Dest, Source >::type u4; typedef typename substitute< U5, Dest, Source >::type u5; > >public: > typedef T< u1 , u2 , u3 , u4 , u5 > type; >}; > > > > >template < > typename R > , typename U1 , typename U2 , typename U3 , typename U4 , typename U5 > , typename Dest > , typename Source > > >struct substitute< > R (*)( U1 , U2 , U3 , U4 , U5 ) > , Dest > , Source > , mpl::int_<-1> > > >{ >private: > typedef typename substitute< R, Dest, Source >::type r; > typedef typename substitute< U1, Dest, Source >::type u1; typedef typename substitute< U2, Dest, Source >::type u2; typedef typename substitute< U3, Dest, Source >::type u3; typedef typename substitute< U4, Dest, Source >::type u4; typedef typename substitute< U5, Dest, Source >::type u5; > >public: > typedef r (*type)( u1 , u2 , u3 , u4 , u5 ); >}; ># 73 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 141 "/usr/include/boost/variant/detail/substitute.hpp" 2 3 4 > > > > > > >}} >} ># 26 "/usr/include/boost/variant/detail/enable_recursive.hpp" 2 3 4 ># 34 "/usr/include/boost/variant/detail/enable_recursive.hpp" 3 4 ># 1 "/usr/include/boost/variant/recursive_wrapper.hpp" 1 3 4 ># 20 "/usr/include/boost/variant/recursive_wrapper.hpp" 3 4 >namespace boost { > > > > > > > >template <typename T> >class recursive_wrapper >{ >public: > > typedef T type; > >private: > > T* p_; > >public: > > ~recursive_wrapper(); > recursive_wrapper(); > > recursive_wrapper(const recursive_wrapper& operand); > recursive_wrapper(const T& operand); > > > recursive_wrapper(recursive_wrapper&& operand); > recursive_wrapper(T&& operand); > > >private: > > void assign(const T& rhs); > >public: > > recursive_wrapper& operator=(const recursive_wrapper& rhs) > { > assign( rhs.get() ); > return *this; > } > > recursive_wrapper& operator=(const T& rhs) > { > assign( rhs ); > return *this; > } > > void swap(recursive_wrapper& operand) noexcept > { > T* temp = operand.p_; > operand.p_ = p_; > p_ = temp; > } > > > > recursive_wrapper& operator=(recursive_wrapper&& rhs) noexcept > { > swap(rhs); > return *this; > } > > recursive_wrapper& operator=(T&& rhs) > { > get() = detail::variant::move(rhs); > return *this; > } > > >public: > > T& get() { return *get_pointer(); } > const T& get() const { return *get_pointer(); } > > T* get_pointer() { return p_; } > const T* get_pointer() const { return p_; } > >}; > >template <typename T> >recursive_wrapper<T>::~recursive_wrapper() >{ > boost::checked_delete(p_); >} > >template <typename T> >recursive_wrapper<T>::recursive_wrapper() > : p_(new T) >{ >} > >template <typename T> >recursive_wrapper<T>::recursive_wrapper(const recursive_wrapper& operand) > : p_(new T( operand.get() )) >{ >} > >template <typename T> >recursive_wrapper<T>::recursive_wrapper(const T& operand) > : p_(new T(operand)) >{ >} > > >template <typename T> >recursive_wrapper<T>::recursive_wrapper(recursive_wrapper&& operand) > : p_(new T( detail::variant::move(operand.get()) )) >{ >} > >template <typename T> >recursive_wrapper<T>::recursive_wrapper(T&& operand) > : p_(new T( detail::variant::move(operand) )) >{ >} > > >template <typename T> >void recursive_wrapper<T>::assign(const T& rhs) >{ > this->get() = rhs; >} > > > > > >template <typename T> >inline void swap(recursive_wrapper<T>& lhs, recursive_wrapper<T>& rhs) noexcept >{ > lhs.swap(rhs); >} > >} ># 35 "/usr/include/boost/variant/detail/enable_recursive.hpp" 2 3 4 > >namespace boost { >namespace detail { namespace variant { ># 83 "/usr/include/boost/variant/detail/enable_recursive.hpp" 3 4 >template <typename T, typename RecursiveVariant, typename NoWrapper> >struct enable_recursive > : substitute< T , RecursiveVariant , ::boost::recursive_variant_ > > > >{ >}; > >template <typename T, typename RecursiveVariant> >struct enable_recursive< T,RecursiveVariant,mpl::false_ > >{ >private: > > typedef typename substitute< T , RecursiveVariant , ::boost::recursive_variant_ > > > ::type t_; > >public: > > > typedef typename mpl::if_< > mpl::or_< > is_same< t_,T > > , is_reference<t_> > , is_pointer<t_> > > > , t_ > , boost::recursive_wrapper<t_> > >::type type; > >}; ># 149 "/usr/include/boost/variant/detail/enable_recursive.hpp" 3 4 >template <typename RecursiveVariant, typename NoWrapper> >struct quoted_enable_recursive >{ > template <typename T> > struct apply > : enable_recursive<T, RecursiveVariant, NoWrapper> > { > }; >}; > >}} >} ># 18 "/usr/include/boost/variant/recursive_variant.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/mpl/equal.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/equal.hpp" 3 4 ># 1 "/usr/include/boost/mpl/bind.hpp" 1 3 4 ># 27 "/usr/include/boost/mpl/equal.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 28 "/usr/include/boost/mpl/equal.hpp" 2 3 4 > > > > > > > >namespace boost { namespace mpl { > >namespace aux { > >template< > typename Predicate > , typename LastIterator1 > , typename LastIterator2 > > >struct equal_pred >{ > template< > typename Iterator2 > , typename Iterator1 > > > struct apply > { > typedef typename and_< > not_< is_same<Iterator1,LastIterator1> > > , not_< is_same<Iterator2,LastIterator2> > > , aux::iter_apply2<Predicate,Iterator1,Iterator2> > >::type type; > }; >}; > >template< > typename Sequence1 > , typename Sequence2 > , typename Predicate > > >struct equal_impl >{ > typedef typename begin<Sequence1>::type first1_; > typedef typename begin<Sequence2>::type first2_; > typedef typename end<Sequence1>::type last1_; > typedef typename end<Sequence2>::type last2_; > > typedef aux::iter_fold_if_impl< > first1_ > , first2_ > , next<> > , protect< aux::equal_pred<Predicate,last1_,last2_> > > , void_ > , always<false_> > > fold_; > > typedef typename fold_::iterator iter1_; > typedef typename fold_::state iter2_; > typedef and_< > is_same<iter1_,last1_> > , is_same<iter2_,last2_> > > result_; > > typedef typename result_::type type; >}; > > >} > > >template< > typename Sequence1 = na > , typename Sequence2 = na > , typename Predicate = is_same<_,_> > > >struct equal > : aux::msvc_eti_base< > typename aux::equal_impl<Sequence1,Sequence2,Predicate>::type > >::type >{ > >}; > >template<> struct equal< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : equal< T1 , T2 > { }; }; template< typename Tag > struct lambda< equal< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef equal< na , na > result_; typedef equal< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< equal< T1 , T2 > > : int_<2> { }; template<> struct template_arity< equal< na , na > > : int_<-1> { }; } > >}} ># 25 "/usr/include/boost/variant/recursive_variant.hpp" 2 3 4 ># 38 "/usr/include/boost/variant/recursive_variant.hpp" 3 4 >namespace boost { > >namespace detail { namespace variant { ># 50 "/usr/include/boost/variant/recursive_variant.hpp" 3 4 >template < > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > , typename RecursiveVariant > , typename Arity > > >struct substitute< > ::boost::variant< > recursive_flag< T0 > > , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 > > > , RecursiveVariant > , ::boost::recursive_variant_ > , Arity > > >{ > typedef ::boost::variant< > recursive_flag< T0 > > , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 > > type; >}; > >template < > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > , typename RecursiveVariant > , typename Arity > > >struct substitute< > ::boost::variant< > ::boost::detail::variant::over_sequence< T0 > > , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 > > > , RecursiveVariant > , ::boost::recursive_variant_ > , Arity > > >{ >private: > > typedef T0 initial_types; > > typedef typename mpl::transform< > initial_types > , mpl::protect< quoted_enable_recursive<RecursiveVariant,mpl::true_> > > >::type types; > >public: > > typedef typename mpl::if_< > mpl::equal<initial_types, types, ::boost::is_same<mpl::_1, mpl::_2> > > , ::boost::variant< > ::boost::detail::variant::over_sequence< T0 > > , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 > > > , ::boost::variant< over_sequence<types> > > >::type type; >}; > >template < > typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > , typename RecursiveVariant > , typename Arity > > >struct substitute< > ::boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 > > , RecursiveVariant > , ::boost::recursive_variant_ > , Arity > > >{ >private: ># 129 "/usr/include/boost/variant/recursive_variant.hpp" 3 4 > typedef typename enable_recursive< T0 , RecursiveVariant , mpl::true_ >::type wknd_T0; typedef typename enable_recursive< T1 , RecursiveVariant , mpl::true_ >::type wknd_T1; typedef typename enable_recursive< T2 , RecursiveVariant , mpl::true_ >::type wknd_T2; typedef typename enable_recursive< T3 , RecursiveVariant , mpl::true_ >::type wknd_T3; typedef typename enable_recursive< T4 , RecursiveVariant , mpl::true_ >::type wknd_T4; typedef typename enable_recursive< T5 , RecursiveVariant , mpl::true_ >::type wknd_T5; typedef typename enable_recursive< T6 , RecursiveVariant , mpl::true_ >::type wknd_T6; typedef typename enable_recursive< T7 , RecursiveVariant , mpl::true_ >::type wknd_T7; typedef typename enable_recursive< T8 , RecursiveVariant , mpl::true_ >::type wknd_T8; typedef typename enable_recursive< T9 , RecursiveVariant , mpl::true_ >::type wknd_T9; typedef typename enable_recursive< T10 , RecursiveVariant , mpl::true_ >::type wknd_T10; typedef typename enable_recursive< T11 , RecursiveVariant , mpl::true_ >::type wknd_T11; typedef typename enable_recursive< T12 , RecursiveVariant , mpl::true_ >::type wknd_T12; typedef typename enable_recursive< T13 , RecursiveVariant , mpl::true_ >::type wknd_T13; typedef typename enable_recursive< T14 , RecursiveVariant , mpl::true_ >::type wknd_T14; typedef typename enable_recursive< T15 , RecursiveVariant , mpl::true_ >::type wknd_T15; typedef typename enable_recursive< T16 , RecursiveVariant , mpl::true_ >::type wknd_T16; typedef typename enable_recursive< T17 , RecursiveVariant , mpl::true_ >::type wknd_T17; typedef typename enable_recursive< T18 , RecursiveVariant , mpl::true_ >::type wknd_T18; typedef typename enable_recursive< T19 , RecursiveVariant , mpl::true_ >::type wknd_T19; > > > > > > > >public: > > typedef ::boost::variant< wknd_T0 , wknd_T1 , wknd_T2 , wknd_T3 , wknd_T4 , wknd_T5 , wknd_T6 , wknd_T7 , wknd_T8 , wknd_T9 , wknd_T10 , wknd_T11 , wknd_T12 , wknd_T13 , wknd_T14 , wknd_T15 , wknd_T16 , wknd_T17 , wknd_T18 , wknd_T19 > type; >}; ># 150 "/usr/include/boost/variant/recursive_variant.hpp" 3 4 >}} > > > > > > >template < typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > >struct make_recursive_variant >{ >public: > > typedef boost::variant< > detail::variant::recursive_flag< T0 > > , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 > > type; > >}; > > > > > > >template <typename Types> >struct make_recursive_variant_over >{ >private: > > > static_assert(( ::boost::mpl::is_sequence<Types>::value ), "( ::boost::mpl::is_sequence<Types>::value )"); > > >public: > > typedef typename make_recursive_variant< > detail::variant::over_sequence< Types > > >::type type; > >}; > >} ># 19 "/usr/include/boost/variant.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/variant/get.hpp" 1 3 4 ># 33 "/usr/include/boost/variant/get.hpp" 3 4 >namespace boost { > > > > > > >class bad_get > : public std::exception >{ >public: > > virtual const char * what() const noexcept > { > return "boost::bad_get: " > "failed value get using boost::get"; > } > >}; ># 60 "/usr/include/boost/variant/get.hpp" 3 4 >namespace detail { namespace variant { > > > > > > >template <typename T> >struct get_visitor >{ >private: > > typedef typename add_pointer<T>::type pointer; > typedef typename add_reference<T>::type reference; > >public: > > typedef pointer result_type; > >public: > > > > pointer operator()(reference operand) const > { > return boost::addressof(operand); > } > > template <typename U> > pointer operator()(const U&) const > { > return static_cast<pointer>(0); > } ># 127 "/usr/include/boost/variant/get.hpp" 3 4 >}; > >}} ># 139 "/usr/include/boost/variant/get.hpp" 3 4 >template <typename U, typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > >inline > typename add_pointer<U>::type >get( > boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 >* operand > > ) >{ > typedef typename add_pointer<U>::type U_ptr; > if (!operand) return static_cast<U_ptr>(0); > > detail::variant::get_visitor<U> v; > return operand->apply_visitor(v); >} > >template <typename U, typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > >inline > typename add_pointer<const U>::type >get( > const boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 >* operand > > ) >{ > typedef typename add_pointer<const U>::type U_ptr; > if (!operand) return static_cast<U_ptr>(0); > > detail::variant::get_visitor<const U> v; > return operand->apply_visitor(v); >} > >template <typename U, typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > >inline > typename add_reference<U>::type >get( > boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 >& operand > > ) >{ > typedef typename add_pointer<U>::type U_ptr; > U_ptr result = get<U>(&operand); > > if (!result) > boost::throw_exception(bad_get()); > return *result; >} > >template <typename U, typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19 > >inline > typename add_reference<const U>::type >get( > const boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19 >& operand > > ) >{ > typedef typename add_pointer<const U>::type U_ptr; > U_ptr result = get<const U>(&operand); > > if (!result) > boost::throw_exception(bad_get()); > return *result; >} > >} ># 23 "/usr/include/boost/variant.hpp" 2 3 4 > > ># 1 "/usr/include/boost/variant/visitor_ptr.hpp" 1 3 4 ># 16 "/usr/include/boost/variant/visitor_ptr.hpp" 3 4 ># 1 "/usr/include/boost/variant/bad_visit.hpp" 1 3 4 ># 18 "/usr/include/boost/variant/bad_visit.hpp" 3 4 >namespace boost { > > > > > > > >struct bad_visit > : std::exception >{ >public: > > virtual const char * what() const throw() > { > return "boost::bad_visit: " > "failed visitation using boost::apply_visitor"; > } > >}; > >} ># 17 "/usr/include/boost/variant/visitor_ptr.hpp" 2 3 4 ># 26 "/usr/include/boost/variant/visitor_ptr.hpp" 3 4 >namespace boost { > > > > > > > >template <typename T, typename R> >class visitor_ptr_t > : public static_visitor<R> >{ >private: > > typedef R (*visitor_t)(T); > > visitor_t visitor_; > >public: > > typedef R result_type; > >private: > > typedef typename mpl::eval_if< > is_reference<T> > , mpl::identity<T> > , add_reference<const T> > >::type argument_fwd_type; > >public: > > explicit visitor_ptr_t(visitor_t visitor) > : visitor_(visitor) > { > } > >public: > > template <typename U> > result_type operator()(const U&) const > { > boost::throw_exception(bad_visit()); > } > > > >public: > > result_type operator()(argument_fwd_type operand) const > { > return visitor_(operand); > } ># 107 "/usr/include/boost/variant/visitor_ptr.hpp" 3 4 >}; > >template <typename R, typename T> >inline visitor_ptr_t<T,R> visitor_ptr(R (*visitor)(T)) >{ > return visitor_ptr_t<T,R>(visitor); >} > >} ># 26 "/usr/include/boost/variant.hpp" 2 3 4 ># 32 "/c/honeypenny/contrib/epee/include/storages/portable_storage_base.h" 2 ># 68 "/c/honeypenny/contrib/epee/include/storages/portable_storage_base.h" >namespace epee >{ > namespace serialization > { > struct section; > > > > > template<class t_entry_type> > struct array_entry_t > { > array_entry_t():m_it(m_array.end()){} > > const t_entry_type* get_first_val() const > { > m_it = m_array.begin(); > return get_next_val(); > } > > t_entry_type* get_first_val() > { > m_it = m_array.begin(); > return get_next_val(); > } > > > const t_entry_type* get_next_val() const > { > if(m_it == m_array.end()) > return nullptr; > return &(*(m_it++)); > } > > t_entry_type* get_next_val() > { > if(m_it == m_array.end()) > return nullptr; > return (t_entry_type*)&(*(m_it++)); > } > > t_entry_type& insert_first_val(const t_entry_type& v) > { > m_array.clear(); > m_it = m_array.end(); > return insert_next_value(v); > } > > t_entry_type& insert_next_value(const t_entry_type& v) > { > m_array.push_back(v); > return m_array.back(); > } > > std::list<t_entry_type> m_array; > mutable typename std::list<t_entry_type>::const_iterator m_it; > }; > > > typedef boost::make_recursive_variant< > array_entry_t<section>, > array_entry_t<uint64_t>, > array_entry_t<uint32_t>, > array_entry_t<uint16_t>, > array_entry_t<uint8_t>, > array_entry_t<int64_t>, > array_entry_t<int32_t>, > array_entry_t<int16_t>, > array_entry_t<int8_t>, > array_entry_t<double>, > array_entry_t<bool>, > array_entry_t<std::string>, > array_entry_t<section>, > array_entry_t<boost::recursive_variant_> > >::type array_entry; > > typedef boost::variant<uint64_t, uint32_t, uint16_t, uint8_t, int64_t, int32_t, int16_t, int8_t, double, bool, std::string, section, array_entry> storage_entry; > > typedef std::string binarybuffer; > > > > > struct section > { > std::map<std::string, storage_entry> m_entries; > }; > > > typedef section* hsection; > typedef array_entry* harray; > } >} ># 33 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" > > > > > >namespace epee >{ > namespace serialization > { > > template<class pack_value, class t_stream> > size_t pack_varint_t(t_stream& strm, uint8_t type_or, size_t& pv) > { > pack_value v = (*((pack_value*)&pv)) << 2; > v |= type_or; > strm.write((const char*)&v, sizeof(pack_value)); > return sizeof(pack_value); > } ># 48 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" >#pragma GCC diagnostic push ># 48 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" ># 49 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" >#pragma GCC diagnostic ignored "-Wstrict-aliasing" ># 49 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" > > template<class t_stream> > size_t pack_varint(t_stream& strm, size_t val) > { > > if(val <= 63) > { > return pack_varint_t<uint8_t>(strm, 0, val); > } > else if(val <= 16383) > { > return pack_varint_t<uint16_t>(strm, 1, val); > }else if(val <= 1073741823) > { > return pack_varint_t<uint32_t>(strm, 2, val); > }else > { > {if(!(val <= 4611686018427387903)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" << ":" << 66 << "|" << __FUNCTION__ << "|" << "failed to pack varint - too big amount = " << val << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "failed to pack varint - too big amount = " << val; throw std::runtime_error(ss.str());};}; > return pack_varint_t<uint64_t>(strm, 3, val); > } > } ># 70 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" >#pragma GCC diagnostic pop ># 70 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" > > > template<class t_stream> > bool put_string(t_stream& strm, const std::string& v) > { > pack_varint(strm, v.size()); > if(v.size()) > strm.write((const char*)v.data(), v.size()); > return true; > } > > template<class t_stream> > struct array_entry_store_visitor: public boost::static_visitor<bool> > { > t_stream& m_strm; > > template<class t_pod_type> > bool pack_pod_array_type(uint8_t contained_type, const array_entry_t<t_pod_type>& arr_pod) > { > uint8_t type = contained_type|0x80; > m_strm.write((const char*)&type, 1); > pack_varint(m_strm, arr_pod.m_array.size()); > for(const t_pod_type& x: arr_pod.m_array) > m_strm.write((const char*)&x, sizeof(t_pod_type)); > return true; > } > > array_entry_store_visitor(t_stream& strm):m_strm(strm){} > bool operator()(const array_entry_t<uint64_t>& v){ return pack_pod_array_type(5, v);} > bool operator()(const array_entry_t<uint32_t>& v){ return pack_pod_array_type(6, v);} > bool operator()(const array_entry_t<uint16_t>& v){ return pack_pod_array_type(7, v);} > bool operator()(const array_entry_t<uint8_t>& v) { return pack_pod_array_type(8, v);} > bool operator()(const array_entry_t<int64_t>& v) { return pack_pod_array_type(1, v);} > bool operator()(const array_entry_t<int32_t>& v) { return pack_pod_array_type(2, v);} > bool operator()(const array_entry_t<int16_t>& v) { return pack_pod_array_type(3, v);} > bool operator()(const array_entry_t<int8_t>& v) { return pack_pod_array_type(4, v);} > bool operator()(const array_entry_t<double>& v) { return pack_pod_array_type(9, v);} > bool operator()(const array_entry_t<bool>& v) { return pack_pod_array_type(11, v);} > bool operator()(const array_entry_t<std::string>& arr_str) > { > uint8_t type = 10|0x80; > m_strm.write((const char*)&type, 1); > pack_varint(m_strm, arr_str.m_array.size()); > for(const std::string& s: arr_str.m_array) > put_string(m_strm, s); > return true; > } > bool operator()(const array_entry_t<section>& arr_sec) > { > uint8_t type = 12|0x80; > m_strm.write((const char*)&type, 1); > pack_varint(m_strm, arr_sec.m_array.size()); > for(const section& s: arr_sec.m_array) > pack_entry_to_buff(m_strm, s); > return true; > } > bool operator()(const array_entry_t<array_entry>& arra_ar) > { > uint8_t type = 13|0x80; > m_strm.write((const char*)&type, 1); > pack_varint(m_strm, arra_ar.m_array.size()); > for(const array_entry& s: arra_ar.m_array) > pack_entry_to_buff(m_strm, s); > return true; > } > }; > > template<class t_stream> > struct storage_entry_store_visitor: public boost::static_visitor<bool> > { > t_stream& m_strm; > storage_entry_store_visitor(t_stream& strm):m_strm(strm){} > template<class pod_type> > bool pack_pod_type(uint8_t type, const pod_type& v) > { > m_strm.write((const char*)&type, 1); > m_strm.write((const char*)&v, sizeof(pod_type)); > return true; > } > > bool operator()(const uint64_t& v){ return pack_pod_type(5, v);} > bool operator()(const uint32_t& v){ return pack_pod_type(6, v);} > bool operator()(const uint16_t& v){ return pack_pod_type(7, v);} > bool operator()(const uint8_t& v) { return pack_pod_type(8, v);} > bool operator()(const int64_t& v) { return pack_pod_type(1, v);} > bool operator()(const int32_t& v) { return pack_pod_type(2, v);} > bool operator()(const int16_t& v) { return pack_pod_type(3, v);} > bool operator()(const int8_t& v) { return pack_pod_type(4, v);} > bool operator()(const double& v) { return pack_pod_type(9, v);} > bool operator()(const bool& v) { return pack_pod_type(11, v);} > bool operator()(const std::string& v) > { > uint8_t type = 10; > m_strm.write((const char*)&type, 1); > put_string(m_strm, v); > return true; > } > bool operator()(const section& v) > { > uint8_t type = 12; > m_strm.write((const char*)&type, 1); > return pack_entry_to_buff(m_strm, v); > } > > bool operator()(const array_entry& v) > { > > > return pack_entry_to_buff(m_strm, v); > } > }; > > template<class t_stream> > bool pack_entry_to_buff(t_stream& strm, const array_entry& ae) > { > array_entry_store_visitor<t_stream> aesv(strm); > return boost::apply_visitor(aesv, ae); > } > > template<class t_stream> > bool pack_entry_to_buff(t_stream& strm, const storage_entry& se) > { > storage_entry_store_visitor<t_stream> sv(strm); > return boost::apply_visitor(sv, se); > } > > template<class t_stream> > bool pack_entry_to_buff(t_stream& strm, const section& sec) > { > typedef std::map<std::string, storage_entry>::value_type section_pair; > pack_varint(strm, sec.m_entries.size()); > for(const section_pair& se: sec.m_entries) > { > {if(!(se.first.size() < std::numeric_limits<uint8_t>::max())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_bin.h" << ":" << 203 << "|" << __FUNCTION__ << "|" << "storage_entry_name is too long: " << se.first.size() << ", val: " << se.first << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "storage_entry_name is too long: " << se.first.size() << ", val: " << se.first; throw std::runtime_error(ss.str());};}; > uint8_t len = static_cast<uint8_t>(se.first.size()); > strm.write((const char*)&len, sizeof(len)); > strm.write(se.first.data(), size_t(len)); > pack_entry_to_buff(strm, se.second); > } > return true; > } > } >} ># 34 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" ># 40 "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" >namespace epee >{ > namespace serialization > { > struct throwable_buffer_reader > { > throwable_buffer_reader(const void* ptr, size_t sz); > void read(void* target, size_t count); > void read_sec_name(std::string& sce_name); > template<class t_pod_type> > void read(t_pod_type& pod_val); > template<class t_type> > t_type read(); > template<class type_name> > storage_entry read_ae(); > storage_entry load_storage_array_entry(uint8_t type); > size_t read_varint(); > template<class t_type> > storage_entry read_se(); > storage_entry load_storage_entry(); > void read(section& sec); > void read(std::string& str); > private: > struct recursuion_limitation_guard > { > size_t& m_counter_ref; > recursuion_limitation_guard(size_t& counter):m_counter_ref(counter) > { > ++m_counter_ref; > {if(!(m_counter_ref < 100)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 69 << "|" << __FUNCTION__ << "|" << "Wrong blob data in portable storage: recursion limitation (" << 100 << ") exceeded" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong blob data in portable storage: recursion limitation (" << 100 << ") exceeded"; throw std::runtime_error(ss.str());};}; > } > ~recursuion_limitation_guard() > { > {if(!(m_counter_ref != 0)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 73 << "|" << __FUNCTION__ << "|" << "Internal error: m_counter_ref == 0 while ~recursuion_limitation_guard()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Internal error: m_counter_ref == 0 while ~recursuion_limitation_guard()"; throw std::runtime_error(ss.str());};}; > --m_counter_ref; > } > }; > > > const uint8_t* m_ptr; > size_t m_count; > size_t m_recursion_count; > }; > > inline throwable_buffer_reader::throwable_buffer_reader(const void* ptr, size_t sz) > { > if(!ptr) > throw std::runtime_error("throwable_buffer_reader: ptr==nullptr"); > if(!sz) > throw std::runtime_error("throwable_buffer_reader: sz==0"); > m_ptr = (uint8_t*)ptr; > m_count = sz; > m_recursion_count = 0; > } > inline > void throwable_buffer_reader::read(void* target, size_t count) > { > recursuion_limitation_guard rl(m_recursion_count); > {if(!(m_count >= count)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 98 << "|" << __FUNCTION__ << "|" << " attempt to read " << count << " bytes from buffer with " << m_count << " bytes remained" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << " attempt to read " << count << " bytes from buffer with " << m_count << " bytes remained"; throw std::runtime_error(ss.str());};}; > memcpy(target, m_ptr, count); > m_ptr += count; > m_count -= count; > } > inline > void throwable_buffer_reader::read_sec_name(std::string& sce_name) > { > recursuion_limitation_guard rl(m_recursion_count); > uint8_t name_len = 0; > read(name_len); > sce_name.resize(name_len); > read((void*)sce_name.data(), name_len); > } > > template<class t_pod_type> > void throwable_buffer_reader::read(t_pod_type& pod_val) > { > recursuion_limitation_guard rl(m_recursion_count); > read(&pod_val, sizeof(pod_val)); > } > > template<class t_type> > t_type throwable_buffer_reader::read() > { > recursuion_limitation_guard rl(m_recursion_count); > t_type v; > read(v); > return v; > } > > > template<class type_name> > storage_entry throwable_buffer_reader::read_ae() > { > recursuion_limitation_guard rl(m_recursion_count); > > array_entry_t<type_name> sa; > size_t size = read_varint(); > > while(size--) > sa.m_array.push_back(read<type_name>()); > return storage_entry(array_entry(sa)); > } > > inline > storage_entry throwable_buffer_reader::load_storage_array_entry(uint8_t type) > { > recursuion_limitation_guard rl(m_recursion_count); > type &= ~0x80; > switch(type) > { > case 1: return read_ae<int64_t>(); > case 2: return read_ae<int32_t>(); > case 3: return read_ae<int16_t>(); > case 4: return read_ae<int8_t>(); > case 5: return read_ae<uint64_t>(); > case 6: return read_ae<uint32_t>(); > case 7: return read_ae<uint16_t>(); > case 8: return read_ae<uint8_t>(); > case 9: return read_ae<double>(); > case 11: return read_ae<bool>(); > case 10: return read_ae<std::string>(); > case 12: return read_ae<section>(); > case 13: return read_ae<array_entry>(); > default: > {if(!(false)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 164 << "|" << __FUNCTION__ << "|" << "unknown entry_type code = " << type << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "unknown entry_type code = " << type; throw std::runtime_error(ss.str());};}; > } > } > > inline > size_t throwable_buffer_reader::read_varint() > { > recursuion_limitation_guard rl(m_recursion_count); > {if(!(m_count >= 1)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 172 << "|" << __FUNCTION__ << "|" << "empty buff, expected place for varint" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "empty buff, expected place for varint"; throw std::runtime_error(ss.str());};}; > size_t v = 0; > uint8_t size_mask = (*(uint8_t*)m_ptr) &0x03; > switch (size_mask) > { > case 0: v = read<uint8_t>();break; > case 1: v = read<uint16_t>();break; > case 2: v = read<uint32_t>();break; > case 3: v = read<uint64_t>();break; > default: > {if(!(false)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 182 << "|" << __FUNCTION__ << "|" << "unknown varint size_mask = " << size_mask << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "unknown varint size_mask = " << size_mask; throw std::runtime_error(ss.str());};}; > } > v >>= 2; > return v; > } > > template<class t_type> > storage_entry throwable_buffer_reader::read_se() > { > recursuion_limitation_guard rl(m_recursion_count); > t_type v; > read(v); > return storage_entry(v); > } > > template<> > inline storage_entry throwable_buffer_reader::read_se<std::string>() > { > recursuion_limitation_guard rl(m_recursion_count); > return storage_entry(read<std::string>()); > } > > > template<> > inline storage_entry throwable_buffer_reader::read_se<section>() > { > recursuion_limitation_guard rl(m_recursion_count); > section s; > storage_entry se(s); > section& section_entry = boost::get<section>(se); > read(section_entry); > return se; > } > > template<> > inline storage_entry throwable_buffer_reader::read_se<array_entry>() > { > recursuion_limitation_guard rl(m_recursion_count); > uint8_t ent_type = 0; > read(ent_type); > {if(!(ent_type&0x80)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 222 << "|" << __FUNCTION__ << "|" << "wrong type sequenses" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "wrong type sequenses"; throw std::runtime_error(ss.str());};}; > return load_storage_array_entry(ent_type); > } > > inline > storage_entry throwable_buffer_reader::load_storage_entry() > { > recursuion_limitation_guard rl(m_recursion_count); > uint8_t ent_type = 0; > read(ent_type); > if(ent_type&0x80) > return load_storage_array_entry(ent_type); > > switch(ent_type) > { > case 1: return read_se<int64_t>(); > case 2: return read_se<int32_t>(); > case 3: return read_se<int16_t>(); > case 4: return read_se<int8_t>(); > case 5: return read_se<uint64_t>(); > case 6: return read_se<uint32_t>(); > case 7: return read_se<uint16_t>(); > case 8: return read_se<uint8_t>(); > case 9: return read_se<double>(); > case 11: return read_se<bool>(); > case 10: return read_se<std::string>(); > case 12: return read_se<section>(); > case 13: return read_se<array_entry>(); > default: > {if(!(false)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 251 << "|" << __FUNCTION__ << "|" << "unknown entry_type code = " << ent_type << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "unknown entry_type code = " << ent_type; throw std::runtime_error(ss.str());};}; > } > } > inline > void throwable_buffer_reader::read(section& sec) > { > recursuion_limitation_guard rl(m_recursion_count); > sec.m_entries.clear(); > size_t count = read_varint(); > while(count--) > { > > std::string sec_name; > read_sec_name(sec_name); > sec.m_entries.insert(std::make_pair(sec_name, load_storage_entry())); > } > } > inline > void throwable_buffer_reader::read(std::string& str) > { > recursuion_limitation_guard rl(m_recursion_count); > size_t len = read_varint(); > {if(!(len < 2000000000)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 273 << "|" << __FUNCTION__ << "|" << "to big string len value in storage: " << len << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "to big string len value in storage: " << len; throw std::runtime_error(ss.str());};}; > {if(!(m_count >= len)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_bin.h" << ":" << 274 << "|" << __FUNCTION__ << "|" << "string len count value " << len << " goes out of remain storage len " << m_count << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "string len count value " << len << " goes out of remain storage len " << m_count; throw std::runtime_error(ss.str());};}; > > str.assign((const char*)m_ptr, len); > m_ptr+=len; > m_count -= len; > } > } >} ># 35 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_json.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/storages/portable_storage_to_json.h" > > > > > >namespace epee >{ > namespace serialization > { > > template<class t_stream> > void dump_as_json(t_stream& strm, const array_entry& ae, size_t indent); > template<class t_stream> > void dump_as_json(t_stream& strm, const storage_entry& se, size_t indent); > template<class t_stream> > void dump_as_json(t_stream& strm, const std::string& v, size_t indent); > template<class t_stream> > void dump_as_json(t_stream& strm, const int8_t& v, size_t indent); > template<class t_stream> > void dump_as_json(t_stream& strm, const uint8_t& v, size_t indent); > template<class t_stream> > void dump_as_json(t_stream& strm, const bool& v, size_t indent); > template<class t_stream, class t_type> > void dump_as_json(t_stream& strm, const t_type& v, size_t indent); > template<class t_stream> > void dump_as_json(t_stream& strm, const section& sec, size_t indent); > > > inline std::string make_indent(size_t indent) > { > return std::string(indent*2, ' '); > } > > template<class t_stream> > struct array_entry_store_to_json_visitor: public boost::static_visitor<void> > { > t_stream& m_strm; > size_t m_indent; > array_entry_store_to_json_visitor(t_stream& strm, size_t indent):m_strm(strm), m_indent(indent){} > > template<class t_type> > void operator()(const array_entry_t<t_type>& a) > { > m_strm << "["; > if(a.m_array.size()) > { > auto last_it = --a.m_array.end(); > for(auto it = a.m_array.begin(); it != a.m_array.end(); it++) > { > dump_as_json(m_strm, *it, m_indent); > if(it != last_it) > m_strm << ","; > } > } > m_strm << "]"; > } > }; > > template<class t_stream> > struct storage_entry_store_to_json_visitor: public boost::static_visitor<void> > { > t_stream& m_strm; > size_t m_indent; > storage_entry_store_to_json_visitor(t_stream& strm, size_t indent):m_strm(strm), m_indent(indent) > {} > > template<class visited_type> > void operator()(const visited_type& v) > { > dump_as_json(m_strm, v, m_indent); > } > }; > > template<class t_stream> > void dump_as_json(t_stream& strm, const array_entry& ae, size_t indent) > { > array_entry_store_to_json_visitor<t_stream> aesv(strm, indent); > boost::apply_visitor(aesv, ae); > } > > template<class t_stream> > void dump_as_json(t_stream& strm, const storage_entry& se, size_t indent) > { > storage_entry_store_to_json_visitor<t_stream> sv(strm, indent); > boost::apply_visitor(sv, se); > } > > template<class t_stream> > void dump_as_json(t_stream& strm, const std::string& v, size_t indent) > { > strm << "\"" << misc_utils::parse::transform_to_escape_sequence(v) << "\""; > } > > template<class t_stream> > void dump_as_json(t_stream& strm, const int8_t& v, size_t indent) > { > strm << static_cast<int32_t>(v); > } > > template<class t_stream> > void dump_as_json(t_stream& strm, const uint8_t& v, size_t indent) > { > strm << static_cast<int32_t>(v); > } > > template<class t_stream> > void dump_as_json(t_stream& strm, const bool& v, size_t indent) > { > if(v) > strm << "true"; > else > strm << "false"; > } > > > > template<class t_stream, class t_type> > void dump_as_json(t_stream& strm, const t_type& v, size_t indent) > { > strm << v; > } > > template<class t_stream> > void dump_as_json(t_stream& strm, const section& sec, size_t indent) > { > size_t local_indent = indent + 1; > strm << "{\r\n"; > std::string indent_str = make_indent(local_indent); > if(sec.m_entries.size()) > { > auto it_last = --sec.m_entries.end(); > for(auto it = sec.m_entries.begin(); it!= sec.m_entries.end();it++) > { > strm << indent_str << "\"" << misc_utils::parse::transform_to_escape_sequence(it->first) << "\"" << ": "; > dump_as_json(strm, it->second, local_indent); > if(it_last != it) > strm << ","; > strm << "\r\n"; > } > } > strm << make_indent(indent) << "}"; > } > } >} ># 36 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" 1 ># 27 "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" > > > > >namespace epee >{ > using namespace misc_utils::parse; > namespace serialization > { > namespace json > { > > > > > > > template<class t_storage> > inline void run_handler(typename t_storage::hsection current_section, std::string::const_iterator& sec_buf_begin, std::string::const_iterator buf_end, t_storage& stg) > { > > std::string::const_iterator sub_element_start; > std::string name; > typename t_storage::harray h_array = nullptr; > enum match_state > { > match_state_lookup_for_section_start, > match_state_lookup_for_name, > match_state_waiting_separator, > match_state_wonder_after_separator, > match_state_wonder_after_value, > match_state_wonder_array, > match_state_array_after_value, > match_state_array_waiting_value, > match_state_error > }; > > enum array_mode > { > array_mode_undifined = 0, > array_mode_sections, > array_mode_string, > array_mode_numbers, > array_mode_booleans > }; > > match_state state = match_state_lookup_for_section_start; > array_mode array_md = array_mode_undifined; > std::string::const_iterator it = sec_buf_begin; > for(;it != buf_end;it++) > { > switch (state) > { > case match_state_lookup_for_section_start: > if(*it == '{') > state = match_state_lookup_for_name; > else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 83 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case match_state_lookup_for_name: > switch(*it) > { > case '"': > match_string2(it, buf_end, name); > state = match_state_waiting_separator; > break; > case '}': > > > sec_buf_begin = it; > return; > default: > if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 98 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > } > break; > case match_state_waiting_separator: > if(*it == ':') > state = match_state_wonder_after_separator; > else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 104 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case match_state_wonder_after_separator: > if(*it == '"') > { > std::string val; > match_string2(it, buf_end, val); > > stg.set_value(name, val, current_section); > state = match_state_wonder_after_value; > }else if (isdigit(*it) || *it == '-') > { > std::string val; > bool is_v_float = false;bool is_signed = false; > match_number2(it, buf_end, val, is_v_float, is_signed); > if(!is_v_float) > { > if(is_signed) > { > int64_t nval = boost::lexical_cast<int64_t>(val); > stg.set_value(name, nval, current_section); > }else > { > uint64_t nval = boost::lexical_cast<uint64_t >(val); > stg.set_value(name, nval, current_section); > } > }else > { > double nval = boost::lexical_cast<double>(val); > stg.set_value(name, nval, current_section); > } > state = match_state_wonder_after_value; > }else if(isalpha(*it) ) > { > std::string word; > match_word2(it, buf_end, word); > if(boost::iequals(word, "null")) > { > state = match_state_wonder_after_value; > > }else if(boost::iequals(word, "true")) > { > stg.set_value(name, true, current_section); > state = match_state_wonder_after_value; > }else if(boost::iequals(word, "false")) > { > stg.set_value(name, false, current_section); > state = match_state_wonder_after_value; > }else {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 152 << "|" << __FUNCTION__ << "|" << "Unknown value keyword " << word << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Unknown value keyword " << word; throw std::runtime_error(ss.str());}; > }else if(*it == '{') > { > > typename t_storage::hsection new_sec = stg.open_section(name, current_section, true); > {if(!(new_sec)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 157 << "|" << __FUNCTION__ << "|" << "Failed to insert new section in json: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Failed to insert new section in json: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > run_handler(new_sec, it, buf_end, stg); > state = match_state_wonder_after_value; > }else if(*it == '[') > { > state = match_state_wonder_array; > }else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 163 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case match_state_wonder_after_value: > if(*it == ',') > state = match_state_lookup_for_name; > else if(*it == '}') > { > > sec_buf_begin = it; > return; > }else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 173 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case match_state_wonder_array: > if(*it == '[') > { > {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 178 << "|" << __FUNCTION__ << "|" << "array of array not suppoerted yet :( sorry" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "array of array not suppoerted yet :( sorry"; throw std::runtime_error(ss.str());}; > > } > if(*it == '{') > { > > typename t_storage::hsection new_sec = nullptr; > h_array = stg.insert_first_section(name, new_sec, current_section); > {if(!(h_array&&new_sec)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 186 << "|" << __FUNCTION__ << "|" << "failed to create new section" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "failed to create new section"; throw std::runtime_error(ss.str());};}; > run_handler(new_sec, it, buf_end, stg); > state = match_state_array_after_value; > array_md = array_mode_sections; > }else if(*it == '"') > { > > std::string val; > match_string2(it, buf_end, val); > h_array = stg.insert_first_value(name, val, current_section); > {if(!(h_array)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 196 << "|" << __FUNCTION__ << "|" << " failed to insert values entry" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << " failed to insert values entry"; throw std::runtime_error(ss.str());};}; > state = match_state_array_after_value; > array_md = array_mode_string; > }else if (isdigit(*it) || *it == '-') > { > std::string val; > bool is_v_float = false;bool is_signed_val = false; > match_number2(it, buf_end, val, is_v_float, is_signed_val); > if(!is_v_float) > { > int64_t nval = boost::lexical_cast<int64_t>(val); > h_array = stg.insert_first_value(name, nval, current_section); > {if(!(h_array)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 208 << "|" << __FUNCTION__ << "|" << " failed to insert values section entry" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << " failed to insert values section entry"; throw std::runtime_error(ss.str());};}; > }else > { > double nval = boost::lexical_cast<double>(val); > h_array = stg.insert_first_value(name, nval, current_section); > {if(!(h_array)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 213 << "|" << __FUNCTION__ << "|" << " failed to insert values section entry" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << " failed to insert values section entry"; throw std::runtime_error(ss.str());};}; > } > > state = match_state_array_after_value; > array_md = array_mode_numbers; > }else if(*it == ']') > { > array_md = array_mode_undifined; > state = match_state_wonder_after_value; > }else if(isalpha(*it) ) > { > std::string word; > match_word2(it, buf_end, word); > if(boost::iequals(word, "true")) > { > h_array = stg.insert_first_value(name, true, current_section); > {if(!(h_array)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 229 << "|" << __FUNCTION__ << "|" << " failed to insert values section entry" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << " failed to insert values section entry"; throw std::runtime_error(ss.str());};}; > state = match_state_array_after_value; > array_md = array_mode_booleans; > }else if(boost::iequals(word, "false")) > { > h_array = stg.insert_first_value(name, false, current_section); > {if(!(h_array)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 235 << "|" << __FUNCTION__ << "|" << " failed to insert values section entry" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << " failed to insert values section entry"; throw std::runtime_error(ss.str());};}; > state = match_state_array_after_value; > array_md = array_mode_booleans; > > }else {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 239 << "|" << __FUNCTION__ << "|" << "Unknown value keyword " << word << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Unknown value keyword " << word; throw std::runtime_error(ss.str());} > }else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 240 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case match_state_array_after_value: > if(*it == ',') > state = match_state_array_waiting_value; > else if(*it == ']') > { > h_array = nullptr; > array_md = array_mode_undifined; > state = match_state_wonder_after_value; > }else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 250 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case match_state_array_waiting_value: > switch(array_md) > { > case array_mode_sections: > if(*it == '{') > { > typename t_storage::hsection new_sec = __null; > bool res = stg.insert_next_section(h_array, new_sec); > {if(!(res&&new_sec)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 260 << "|" << __FUNCTION__ << "|" << "failed to insert next section" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "failed to insert next section"; throw std::runtime_error(ss.str());};}; > run_handler(new_sec, it, buf_end, stg); > state = match_state_array_after_value; > }else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 263 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case array_mode_string: > if(*it == '"') > { > std::string val; > match_string2(it, buf_end, val); > bool res = stg.insert_next_value(h_array, val); > {if(!(res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 271 << "|" << __FUNCTION__ << "|" << "failed to insert values" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "failed to insert values"; throw std::runtime_error(ss.str());};}; > state = match_state_array_after_value; > }else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 273 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case array_mode_numbers: > if (isdigit(*it) || *it == '-') > { > std::string val; > bool is_v_float = false;bool is_signed_val = false; > match_number2(it, buf_end, val, is_v_float, is_signed_val); > bool insert_res = false; > if(!is_v_float) > { > int64_t nval = boost::lexical_cast<int64_t>(val); > insert_res = stg.insert_next_value(h_array, nval); > > }else > { > > double nval = boost::lexical_cast<double>(val); > insert_res = stg.insert_next_value(h_array, nval); > } > {if(!(insert_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 293 << "|" << __FUNCTION__ << "|" << "Failed to insert next value" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Failed to insert next value"; throw std::runtime_error(ss.str());};}; > state = match_state_array_after_value; > array_md = array_mode_numbers; > }else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 296 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case array_mode_booleans: > if(isalpha(*it) ) > { > std::string word; > match_word2(it, buf_end, word); > if(boost::iequals(word, "true")) > { > bool r = stg.insert_next_value(h_array, true); > {if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 306 << "|" << __FUNCTION__ << "|" << " failed to insert values section entry" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << " failed to insert values section entry"; throw std::runtime_error(ss.str());};}; > state = match_state_array_after_value; > }else if(boost::iequals(word, "false")) > { > bool r = stg.insert_next_value(h_array, false); > {if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 311 << "|" << __FUNCTION__ << "|" << " failed to insert values section entry" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << " failed to insert values section entry"; throw std::runtime_error(ss.str());};}; > state = match_state_array_after_value; > } > else {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 314 << "|" << __FUNCTION__ << "|" << "Unknown value keyword " << word << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Unknown value keyword " << word; throw std::runtime_error(ss.str());}; > }else if(!isspace(*it)){ {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 315 << "|" << __FUNCTION__ << "|" << "Wrong JSON character at: " << std::string(it, buf_end) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Wrong JSON character at: " << std::string(it, buf_end); throw std::runtime_error(ss.str());};}; > break; > case array_mode_undifined: > default: > {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 319 << "|" << __FUNCTION__ << "|" << "Bad array state" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "Bad array state"; throw std::runtime_error(ss.str());}; > } > break; > case match_state_error: > default: > {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" << ":" << 324 << "|" << __FUNCTION__ << "|" << "WRONG JSON STATE" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "WRONG JSON STATE"; throw std::runtime_error(ss.str());}; > } > } > } ># 357 "/c/honeypenny/contrib/epee/include/storages/portable_storage_from_json.h" > template<class t_storage> > inline bool load_from_json(const std::string& buff_json, t_storage& stg) > { > std::string::const_iterator sec_buf_begin = buff_json.begin(); > try > { > run_handler(nullptr, sec_buf_begin, buff_json.end(), stg); > return true; > } > catch(const std::exception& ex) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to parse json, what: " << ex.what() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, false, __null);}}; > return false; > } > catch(...) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to parse json" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, false, __null);}}; > return false; > } > } > } > } >} ># 37 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" 1 ># 29 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" > > > > > > >namespace epee >{ > namespace serialization > { > > > template<typename from_type, typename to_type> > void convert_int_to_uint(const from_type& from, to_type& to) > { ># 44 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" >#pragma GCC diagnostic push ># 44 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" > > > {if(!(from >=0)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" << ":" << 46 << "|" << __FUNCTION__ << "|" << "unexpected int value with signed storage value less than 0, and unsigned receiver value" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "unexpected int value with signed storage value less than 0, and unsigned receiver value"; throw std::runtime_error(ss.str());};}; ># 47 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" >#pragma GCC diagnostic ignored "-Wsign-compare" ># 47 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" > > {if(!(from <= std::numeric_limits<to_type>::max())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" << ":" << 48 << "|" << __FUNCTION__ << "|" << "int value overhead: try to set value " << from << " to type " << typeid(to_type).name() << " with max possible value = " << std::numeric_limits<to_type>::max() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "int value overhead: try to set value " << from << " to type " << typeid(to_type).name() << " with max possible value = " << std::numeric_limits<to_type>::max(); throw std::runtime_error(ss.str());};}; > to = static_cast<to_type>(from); ># 50 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" >#pragma GCC diagnostic pop ># 50 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" > > } > template<typename from_type, typename to_type> > void convert_int_to_int(const from_type& from, to_type& to) > { > {if(!(from >= boost::numeric::bounds<to_type>::lowest())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" << ":" << 55 << "|" << __FUNCTION__ << "|" << "int value overhead: try to set value " << from << " to type " << typeid(to_type).name() << " with lowest possible value = " << boost::numeric::bounds<to_type>::lowest() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "int value overhead: try to set value " << from << " to type " << typeid(to_type).name() << " with lowest possible value = " << boost::numeric::bounds<to_type>::lowest(); throw std::runtime_error(ss.str());};}; ># 56 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" >#pragma GCC diagnostic push ># 56 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" > > > {if(!(from <= std::numeric_limits<to_type>::max())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" << ":" << 58 << "|" << __FUNCTION__ << "|" << "int value overhead: try to set value " << from << " to type " << typeid(to_type).name() << " with max possible value = " << std::numeric_limits<to_type>::max() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "int value overhead: try to set value " << from << " to type " << typeid(to_type).name() << " with max possible value = " << std::numeric_limits<to_type>::max(); throw std::runtime_error(ss.str());};}; ># 59 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" >#pragma GCC diagnostic pop ># 59 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" > > to = static_cast<to_type>(from); > } > template<typename from_type, typename to_type> > void convert_uint_to_any_int(const from_type& from, to_type& to) > { ># 65 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" >#pragma GCC diagnostic push ># 65 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" > > > > {if(!(from <= std::numeric_limits<to_type>::max())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" << ":" << 68 << "|" << __FUNCTION__ << "|" << "uint value overhead: try to set value " << from << " to type " << typeid(to_type).name() << " with max possible value = " << std::numeric_limits<to_type>::max() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "uint value overhead: try to set value " << from << " to type " << typeid(to_type).name() << " with max possible value = " << std::numeric_limits<to_type>::max(); throw std::runtime_error(ss.str());};}; > to = static_cast<to_type>(from); ># 70 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" >#pragma GCC diagnostic pop ># 70 "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" > > } > > template<typename from_type, typename to_type, bool, bool> > struct convert_to_signed_unsigned; > > template<typename from_type, typename to_type> > struct convert_to_signed_unsigned<from_type, to_type, true, true> > { > static void convert(const from_type& from, to_type& to) > { > convert_int_to_int(from, to); > } > }; > > template<typename from_type, typename to_type> > struct convert_to_signed_unsigned<from_type, to_type, true, false> > { > static void convert(const from_type& from, to_type& to) > { > convert_int_to_uint(from, to); > } > }; > > template<typename from_type, typename to_type> > struct convert_to_signed_unsigned<from_type, to_type, false, true> > { > static void convert(const from_type& from, to_type& to) > { > convert_uint_to_any_int(from, to); > } > }; > > template<typename from_type, typename to_type> > struct convert_to_signed_unsigned<from_type, to_type, false, false> > { > static void convert(const from_type& from, to_type& to) > { > > convert_uint_to_any_int(from, to); > } > }; > > template<typename from_type, typename to_type, bool> > struct convert_to_integral; > > template<typename from_type, typename to_type> > struct convert_to_integral<from_type, to_type, true> > { > static void convert(const from_type& from, to_type& to) > { > convert_to_signed_unsigned<from_type, to_type, std::is_signed<from_type>::value, std::is_signed<to_type>::value>::convert(from, to); > } > }; > > template<typename from_type, typename to_type> > struct convert_to_integral<from_type, to_type, false> > { > static void convert(const from_type& from, to_type& to) > { > {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage_val_converters.h" << ":" << 130 << "|" << __FUNCTION__ << "|" << "WRONG DATA CONVERSION: from type=" << typeid(from).name() << " to type " << typeid(to).name() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; std::stringstream ss; ss << "WRONG DATA CONVERSION: from type=" << typeid(from).name() << " to type " << typeid(to).name(); throw std::runtime_error(ss.str());}; > } > }; > > template<class from_type, class to_type> > struct is_convertable: std::integral_constant<bool, > std::is_integral<to_type>::value && > std::is_integral<from_type>::value && > !std::is_same<from_type, bool>::value && > !std::is_same<to_type, bool>::value > {}; > > template<typename from_type, typename to_type, bool> > struct convert_to_same; > > template<typename from_type, typename to_type> > struct convert_to_same<from_type, to_type, true> > { > static void convert(const from_type& from, to_type& to) > { > to = from; > } > }; > > template<typename from_type, typename to_type> > struct convert_to_same<from_type, to_type, false> > { > static void convert(const from_type& from, to_type& to) > { > convert_to_integral<from_type, to_type, is_convertable<from_type, to_type>::value>::convert(from, to); > } > }; > > > template<class from_type, class to_type> > void convert_t(const from_type& from, to_type& to) > { > convert_to_same<from_type, to_type, std::is_same<to_type, from_type>::value>::convert(from, to); > } > } >} ># 38 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" 2 > >namespace epee >{ > namespace serialization > { > > > > class portable_storage > { > public: > typedef epee::serialization::hsection hsection; > typedef epee::serialization::harray harray; > typedef storage_entry meta_entry; > > portable_storage(){} > virtual ~portable_storage(){} > hsection open_section(const std::string& section_name, hsection hparent_section, bool create_if_notexist = false); > template<class t_value> > bool get_value(const std::string& value_name, t_value& val, hsection hparent_section); > bool get_value(const std::string& value_name, storage_entry& val, hsection hparent_section); > template<class t_value> > bool set_value(const std::string& value_name, const t_value& target, hsection hparent_section); > > > > template<class t_value> > harray get_first_value(const std::string& value_name, t_value& target, hsection hparent_section); > template<class t_value> > bool get_next_value(harray hval_array, t_value& target); > template<class t_value> > harray insert_first_value(const std::string& value_name, const t_value& target, hsection hparent_section); > template<class t_value> > bool insert_next_value(harray hval_array, const t_value& target); > > harray get_first_section(const std::string& pSectionName, hsection& h_child_section, hsection hparent_section); > bool get_next_section(harray hSecArray, hsection& h_child_section); > harray insert_first_section(const std::string& pSectionName, hsection& hinserted_childsection, hsection hparent_section); > bool insert_next_section(harray hSecArray, hsection& hinserted_childsection); > > > bool delete_entry(const std::string& pentry_name, hsection hparent_section = nullptr); > > > bool store_to_binary(binarybuffer& target); > bool load_from_binary(const binarybuffer& target); > template<class trace_policy> > bool dump_as_xml(std::string& targetObj, const std::string& root_name = ""); > bool dump_as_json(std::string& targetObj, size_t indent = 0); > bool load_from_json(const std::string& source); > > private: > section m_root; > hsection get_root_section() {return &m_root;} > storage_entry* find_storage_entry(const std::string& pentry_name, hsection psection); > template<class entry_type> > storage_entry* insert_new_entry_get_storage_entry(const std::string& pentry_name, hsection psection, const entry_type& entry); > > hsection insert_new_section(const std::string& pentry_name, hsection psection); > >#pragma pack(push) >#pragma pack(1) > struct storage_block_header > { > uint32_t m_signature_a; > uint32_t m_signature_b; > uint8_t m_ver; > }; >#pragma pack(pop) > }; > inline > bool portable_storage::dump_as_json(std::string& buff, size_t indent) > { > try {; > std::stringstream ss; > epee::serialization::dump_as_json(ss, m_root, indent); > buff = ss.str(); > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 116 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::dump_as_json" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 116 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::dump_as_json" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } > } > inline > bool portable_storage::load_from_json(const std::string& source) > { > try {; > return json::load_from_json(source, *this); > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 123 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::load_from_json" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 123 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::load_from_json" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } > } > > template<class trace_policy> > bool portable_storage::dump_as_xml(std::string& targetObj, const std::string& root_name) > { > return false; > } > > inline > bool portable_storage::store_to_binary(binarybuffer& target) > { > try {; > std::stringstream ss; > storage_block_header sbh = boost::value_initialized<decltype(sbh)>(); > sbh.m_signature_a = 0x01011101; > sbh.m_signature_b = 0x01020101; > sbh.m_ver = 1; > ss.write((const char*)&sbh, sizeof(storage_block_header)); > pack_entry_to_buff(ss, m_root); > target = ss.str(); > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 145 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::store_to_binary" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 145 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::store_to_binary" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } > } > inline > bool portable_storage::load_from_binary(const binarybuffer& source) > { > m_root.m_entries.clear(); > if(source.size() < sizeof(storage_block_header)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 153 << "|" << __FUNCTION__ << "|" << "portable_storage: wrong binary format, packet size = " << source.size() << " less than expected sizeof(storage_block_header)=" << sizeof(storage_block_header) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > storage_block_header* pbuff = (storage_block_header*)source.data(); > if(pbuff->m_signature_a != 0x01011101 || > pbuff->m_signature_b != 0x01020101 > ) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 161 << "|" << __FUNCTION__ << "|" << "portable_storage: wrong binary format - signature missmatch" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > if(pbuff->m_ver != 1) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 166 << "|" << __FUNCTION__ << "|" << "portable_storage: wrong binary format - unknown format ver = " << pbuff->m_ver << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > try {; > throwable_buffer_reader buf_reader(source.data()+sizeof(storage_block_header), source.size()-sizeof(storage_block_header)); > buf_reader.read(m_root); > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 173 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::load_from_binary" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 173 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::load_from_binary" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > inline > hsection portable_storage::open_section(const std::string& section_name, hsection hparent_section, bool create_if_notexist) > { > try {; > hparent_section = hparent_section ? hparent_section:&m_root; > storage_entry* pentry = find_storage_entry(section_name, hparent_section); > if(!pentry) > { > if(!create_if_notexist) > return nullptr; > return insert_new_section(section_name, hparent_section); > } > do{if(!(pentry)){; return nullptr;};}while(0); > > if(pentry->type() != typeid(section)) > { > if(create_if_notexist) > *pentry = storage_entry(section()); > else > return nullptr; > } > return &boost::get<section>(*pentry); > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 198 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::open_section" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 198 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::open_section" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; }; > } > > template<class to_type> > struct get_value_visitor: boost::static_visitor<void> > { > to_type& m_target; > get_value_visitor(to_type& target):m_target(target){} > template<class from_type> > void operator()(const from_type& v){convert_t(v, m_target);} > }; > > template<class t_value> > bool portable_storage::get_value(const std::string& value_name, t_value& val, hsection hparent_section) > { > enum { mpl_assertion_in_line_213 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) ( boost::mpl::contains<storage_entry::types, t_value> ))0, 1 ) ) ) }; > > if(!hparent_section) hparent_section = &m_root; > storage_entry* pentry = find_storage_entry(value_name, hparent_section); > if(!pentry) > return false; > > get_value_visitor<t_value> gvv(val); > boost::apply_visitor(gvv, *pentry); > return true; > > } > > inline > bool portable_storage::get_value(const std::string& value_name, storage_entry& val, hsection hparent_section) > { > > if(!hparent_section) hparent_section = &m_root; > storage_entry* pentry = find_storage_entry(value_name, hparent_section); > if(!pentry) > return false; > > val = *pentry; > return true; > > } > > template<class t_value> > bool portable_storage::set_value(const std::string& value_name, const t_value& v, hsection hparent_section) > { > enum { mpl_assertion_in_line_243 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) ( boost::mpl::contains<boost::mpl::push_front<storage_entry::types, storage_entry>::type, t_value> ))0, 1 ) ) ) }; > try {; > if(!hparent_section) > hparent_section = &m_root; > storage_entry* pentry = find_storage_entry(value_name, hparent_section); > if(!pentry) > { > pentry = insert_new_entry_get_storage_entry(value_name, hparent_section, v); > if(!pentry) > return false; > return true; > } > *pentry = storage_entry(v); > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 257 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::template<>set_value" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 257 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::template<>set_value" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > inline > storage_entry* portable_storage::find_storage_entry(const std::string& pentry_name, hsection psection) > { > try {; > do{if(!(psection)){; return nullptr;};}while(0); > auto it = psection->m_entries.find(pentry_name); > if(it == psection->m_entries.end()) > return nullptr; > > return &it->second; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 270 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::find_storage_entry" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 270 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::find_storage_entry" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; }; > } > > template<class entry_type> > storage_entry* portable_storage::insert_new_entry_get_storage_entry(const std::string& pentry_name, hsection psection, const entry_type& entry) > { > try {; > do{if(!(psection)){; return nullptr;};}while(0); > auto ins_res = psection->m_entries.insert(std::pair<std::string, storage_entry>(pentry_name, entry)); > return &ins_res.first->second; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 280 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_new_entry_get_storage_entry" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 280 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_new_entry_get_storage_entry" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; }; > } > > inline > hsection portable_storage::insert_new_section(const std::string& pentry_name, hsection psection) > { > try {; > storage_entry* pse = insert_new_entry_get_storage_entry(pentry_name, psection, section()); > if(!pse) return nullptr; > return &boost::get<section>(*pse); > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 290 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_new_section" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 290 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_new_section" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; }; > } > > template<class to_type> > struct get_first_value_visitor: boost::static_visitor<bool> > { > to_type& m_target; > get_first_value_visitor(to_type& target):m_target(target){} > template<class from_type> > bool operator()(const array_entry_t<from_type>& a) > { > const from_type* pv = a.get_first_val(); > if(!pv) > return false; > convert_t(*pv, m_target); > return true; > } > }; > > template<class t_value> > harray portable_storage::get_first_value(const std::string& value_name, t_value& target, hsection hparent_section) > { > enum { mpl_assertion_in_line_312 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) ( boost::mpl::contains<storage_entry::types, t_value> ))0, 1 ) ) ) }; > > if(!hparent_section) hparent_section = &m_root; > storage_entry* pentry = find_storage_entry(value_name, hparent_section); > if(!pentry) > return nullptr; > if(pentry->type() != typeid(array_entry)) > return nullptr; > array_entry& ar_entry = boost::get<array_entry>(*pentry); > > get_first_value_visitor<t_value> gfv(target); > if(!boost::apply_visitor(gfv, ar_entry)) > return nullptr; > return &ar_entry; > > } > > template<class to_type> > struct get_next_value_visitor: boost::static_visitor<bool> > { > to_type& m_target; > get_next_value_visitor(to_type& target):m_target(target){} > template<class from_type> > bool operator()(const array_entry_t<from_type>& a) > { > > const from_type* pv = a.get_next_val(); > if(!pv) > return false; > convert_t(*pv, m_target); > return true; > } > }; > > > template<class t_value> > bool portable_storage::get_next_value(harray hval_array, t_value& target) > { > enum { mpl_assertion_in_line_350 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) ( boost::mpl::contains<storage_entry::types, t_value> ))0, 1 ) ) ) }; > > do{if(!(hval_array)){; return false;};}while(0); > array_entry& ar_entry = *hval_array; > get_next_value_visitor<t_value> gnv(target); > if(!boost::apply_visitor(gnv, ar_entry)) > return false; > return true; > > } > > template<class t_value> > harray portable_storage::insert_first_value(const std::string& value_name, const t_value& target, hsection hparent_section) > { > try {; > if(!hparent_section) hparent_section = &m_root; > storage_entry* pentry = find_storage_entry(value_name, hparent_section); > if(!pentry) > { > pentry = insert_new_entry_get_storage_entry(value_name, hparent_section, array_entry(array_entry_t<t_value>())); > if(!pentry) > return nullptr; > } > if(pentry->type() != typeid(array_entry)) > *pentry = storage_entry(array_entry(array_entry_t<t_value>())); > > array_entry& arr = boost::get<array_entry>(*pentry); > if(arr.type() != typeid(array_entry_t<t_value>)) > arr = array_entry(array_entry_t<t_value>()); > > array_entry_t<t_value>& arr_typed = boost::get<array_entry_t<t_value> >(arr); > arr_typed.insert_first_val(target); > return &arr; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 383 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_first_value" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 383 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_first_value" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; }; > } > > template<class t_value> > bool portable_storage::insert_next_value(harray hval_array, const t_value& target) > { > try {; > do{if(!(hval_array)){; return false;};}while(0); > > do{if(!(hval_array->type() == typeid(array_entry_t<t_value>))) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" ># 392 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" > << ":" << > 393 ># 392 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" > << "|" << __FUNCTION__ << "|" << "unexpected type in insert_next_value: " << typeid(array_entry_t<t_value>).name() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0) > ; > > array_entry_t<t_value>& arr_typed = boost::get<array_entry_t<t_value> >(*hval_array); > arr_typed.insert_next_value(target); > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 398 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_next_value" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 398 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_next_value" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > > inline > harray portable_storage::get_first_section(const std::string& sec_name, hsection& h_child_section, hsection hparent_section) > { > try {; > if(!hparent_section) hparent_section = &m_root; > storage_entry* pentry = find_storage_entry(sec_name, hparent_section); > if(!pentry) > return nullptr; > if(pentry->type() != typeid(array_entry)) > return nullptr; > array_entry& ar_entry = boost::get<array_entry>(*pentry); > if(ar_entry.type() != typeid(array_entry_t<section>)) > return nullptr; > array_entry_t<section>& sec_array = boost::get<array_entry_t<section>>(ar_entry); > section* psec = sec_array.get_first_val(); > if(!psec) > return nullptr; > h_child_section = psec; > return &ar_entry; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 421 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::get_first_section" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 421 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::get_first_section" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; }; > } > > inline > bool portable_storage::get_next_section(harray hsec_array, hsection& h_child_section) > { > try {; > do{if(!(hsec_array)){; return false;};}while(0); > if(hsec_array->type() != typeid(array_entry_t<section>)) > return nullptr; > array_entry_t<section>& sec_array = boost::get<array_entry_t<section>>(*hsec_array); > h_child_section = sec_array.get_next_val(); > if(!h_child_section) > return false; > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 436 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::get_next_section" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 436 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::get_next_section" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > inline > harray portable_storage::insert_first_section(const std::string& sec_name, hsection& hinserted_childsection, hsection hparent_section) > { > try {; > if(!hparent_section) hparent_section = &m_root; > storage_entry* pentry = find_storage_entry(sec_name, hparent_section); > if(!pentry) > { > pentry = insert_new_entry_get_storage_entry(sec_name, hparent_section, array_entry(array_entry_t<section>())); > if(!pentry) > return nullptr; > } > if(pentry->type() != typeid(array_entry)) > *pentry = storage_entry(array_entry(array_entry_t<section>())); > > array_entry& ar_entry = boost::get<array_entry>(*pentry); > if(ar_entry.type() != typeid(array_entry_t<section>)) > ar_entry = array_entry(array_entry_t<section>()); > > array_entry_t<section>& sec_array = boost::get<array_entry_t<section>>(ar_entry); > hinserted_childsection = &sec_array.insert_first_val(section()); > return &ar_entry; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 461 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_first_section" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 461 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_first_section" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return nullptr; }; > } > > inline > bool portable_storage::insert_next_section(harray hsec_array, hsection& hinserted_childsection) > { > try {; > do{if(!(hsec_array)){; return false;};}while(0); > do{if(!(hsec_array->type() == typeid(array_entry_t<section>))) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" ># 469 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" > << ":" << > 470 ># 469 "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" > << "|" << __FUNCTION__ << "|" << "unexpected type(not 'section') in insert_next_section, type: " << hsec_array->type().name() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0) > ; > > array_entry_t<section>& sec_array = boost::get<array_entry_t<section>>(*hsec_array); > hinserted_childsection = &sec_array.insert_next_value(section()); > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 475 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_next_section" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/portable_storage.h" << ":" << 475 << "|" << __FUNCTION__ << "|" << "Exception at [" << "portable_storage::insert_next_section" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > } >} ># 30 "/c/honeypenny/contrib/epee/include/storages/portable_storage_template_helper.h" 2 > > >namespace epee >{ > namespace serialization > { > > template<class t_struct> > bool load_t_from_json(t_struct& out, const std::string& json_buff) > { > portable_storage ps; > bool rs = ps.load_from_json(json_buff); > if(!rs) > return false; > > return out.load(ps); > } > > template<class t_struct> > bool load_t_from_json_file(t_struct& out, const std::string& json_file) > { > std::string f_buff; > if(!file_io_utils::load_file_to_string(json_file, f_buff)) > return false; > > return load_t_from_json(out, f_buff); > } > > template<class t_struct> > bool store_t_to_json(t_struct& str_in, std::string& json_buff, size_t indent = 0) > { > portable_storage ps; > str_in.store(ps); > ps.dump_as_json(json_buff, indent); > return true; > } > > template<class t_struct> > std::string store_t_to_json(t_struct& str_in, size_t indent = 0) > { > std::string json_buff; > store_t_to_json(str_in, json_buff, indent); > return std::move(json_buff); > } > > template<class t_struct> > bool store_t_to_json_file(t_struct& str_in, const std::string& fpath) > { > std::string json_buff; > store_t_to_json(str_in, json_buff); > return file_io_utils::save_string_to_file(fpath, json_buff); > } > > template<class t_struct> > bool load_t_from_binary(t_struct& out, const std::string& binary_buff) > { > portable_storage ps; > bool rs = ps.load_from_binary(binary_buff); > if(!rs) > return false; > > return out.load(ps); > } > > template<class t_struct> > bool load_t_from_binary_file(t_struct& out, const std::string& binary_file) > { > std::string f_buff; > if(!file_io_utils::load_file_to_string(binary_file, f_buff)) > return false; > > return load_t_from_binary(out, f_buff); > } > > template<class t_struct> > bool store_t_to_binary(t_struct& str_in, std::string& binary_buff, size_t indent = 0) > { > portable_storage ps; > str_in.store(ps); > return ps.store_to_binary(binary_buff); > } > > template<class t_struct> > std::string store_t_to_binary(t_struct& str_in, size_t indent = 0) > { > std::string binary_buff; > store_t_to_binary(str_in, binary_buff, indent); > return std::move(binary_buff); > } > } >} ># 31 "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" 2 ># 114 "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" >namespace epee >{ > namespace json_rpc > { > template<typename t_param> > struct request > { > std::string jsonrpc; > std::string method; > epee::serialization::storage_entry id; > t_param params; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" << ":" << 126 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.jsonrpc, stg, hparent_section, "jsonrpc"); > epee::serialization::selector<is_store>::serialize(this_ref.id, stg, hparent_section, "id"); > epee::serialization::selector<is_store>::serialize(this_ref.method, stg, hparent_section, "method"); > epee::serialization::selector<is_store>::serialize(this_ref.params, stg, hparent_section, "params"); > return true;} > }; > > struct error > { > int64_t code; > std::string message; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" << ":" << 138 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.code, stg, hparent_section, "code"); > epee::serialization::selector<is_store>::serialize(this_ref.message, stg, hparent_section, "message"); > return true;} > }; > > struct dummy_error > { > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" << ":" << 146 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > return true;} > }; > > struct dummy_result > { > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" << ":" << 152 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > return true;} > }; > > template<typename t_param, typename t_error> > struct response > { > std::string jsonrpc; > t_param result; > epee::serialization::storage_entry id; > t_error error; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" << ":" << 163 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.jsonrpc, stg, hparent_section, "jsonrpc"); > epee::serialization::selector<is_store>::serialize(this_ref.id, stg, hparent_section, "id"); > epee::serialization::selector<is_store>::serialize(this_ref.result, stg, hparent_section, "result"); > epee::serialization::selector<is_store>::serialize(this_ref.error, stg, hparent_section, "error"); > return true;} > }; > > template<typename t_param> > struct response<t_param, dummy_error> > { > std::string jsonrpc; > t_param result; > epee::serialization::storage_entry id; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" << ":" << 177 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.jsonrpc, stg, hparent_section, "jsonrpc"); > epee::serialization::selector<is_store>::serialize(this_ref.id, stg, hparent_section, "id"); > epee::serialization::selector<is_store>::serialize(this_ref.result, stg, hparent_section, "result"); > return true;} > }; > > template<typename t_error> > struct response<dummy_result, t_error> > { > std::string jsonrpc; > t_error error; > epee::serialization::storage_entry id; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_server_handlers_map2.h" << ":" << 190 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.jsonrpc, stg, hparent_section, "jsonrpc"); > epee::serialization::selector<is_store>::serialize(this_ref.id, stg, hparent_section, "id"); > epee::serialization::selector<is_store>::serialize(this_ref.error, stg, hparent_section, "error"); > return true;} > }; > > typedef response<dummy_result, error> error_response; > } >} ># 38 "/c/honeypenny/contrib/epee/include/net/http_server_impl_base.h" 2 > >namespace epee >{ > > template<class t_child_class, class t_connection_context = epee::net_utils::connection_context_base> > class http_server_impl_base: public net_utils::http::i_http_server_handler<t_connection_context> > { > > public: > http_server_impl_base() > : m_net_server() > {} > > explicit http_server_impl_base(boost::asio::io_service& external_io_service) > : m_net_server(external_io_service) > {} > > bool init(const std::string& bind_port = "0", const std::string& bind_ip = "0.0.0.0") > { > > > m_net_server.get_config_object().m_phandler = static_cast<t_child_class*>(this); > > > m_net_server.get_config_object().m_folder = ""; > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Binding on " << bind_ip << ":" << bind_port << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > bool res = m_net_server.init_server(bind_port, bind_ip); > if(!res) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_server_impl_base.h" << ":" << 68 << "|" << __FUNCTION__ << "|" << "Failed to bind server" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > return true; > } > > bool run(size_t threads_count, bool wait = true) > { > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Run net_service loop( " << threads_count << " threads)..." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > if(!m_net_server.run_server(threads_count, wait)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/http_server_impl_base.h" << ":" << 80 << "|" << __FUNCTION__ << "|" << "Failed to run net tcp server!" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > } > > if(wait) > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "net_service loop stopped." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return true; > } > > bool deinit() > { > return m_net_server.deinit_server(); > } > > bool timed_wait_server_stop(uint64_t ms) > { > return m_net_server.timed_wait_server_stop(ms); > } > > bool send_stop_signal() > { > m_net_server.send_stop_signal(); > return true; > } > > int get_binded_port() > { > return m_net_server.get_binded_port(); > } > > protected: > net_utils::boosted_tcp_server<net_utils::http::http_custom_handler<t_connection_context> > m_net_server; > }; >} ># 11 "/c/honeypenny/src/rpc/core_rpc_server.h" 2 ># 1 "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" 1 > > > > > ># 1 "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" 1 ># 9 "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" ># 1 "/c/honeypenny/src/currency_core/currency_basic.h" 1 > > > > > > > ># 1 "/usr/include/boost/functional/hash/hash.hpp" 1 3 4 ># 9 "/c/honeypenny/src/currency_core/currency_basic.h" 2 > ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 ># 39 "/usr/include/c++/4.9.0/cstring" 3 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 11 "/c/honeypenny/src/currency_core/currency_basic.h" 2 > ># 1 "/c/honeypenny/src/serialization/serialization.h" 1 ># 9 "/c/honeypenny/src/serialization/serialization.h" > > > > > >template <class T> >struct is_blob_type { typedef boost::false_type type; }; >template <class T> >struct has_free_serializer { typedef boost::true_type type; }; > >template <class Archive, class T> >struct serializer >{ > static bool serialize(Archive &ar, T &v) { > return serialize(ar, v, typename boost::is_integral<T>::type(), typename is_blob_type<T>::type()); > } > static bool serialize(Archive &ar, T &v, boost::false_type, boost::true_type) { > ar.serialize_blob(&v, sizeof(v)); > return true; > } > static bool serialize(Archive &ar, T &v, boost::true_type, boost::false_type) { > ar.serialize_int(v); > return true; > } > static bool serialize(Archive &ar, T &v, boost::false_type, boost::false_type) { > > return v.do_serialize(ar); > } > static void serialize_custom(Archive &ar, T &v, boost::true_type) { > } >}; > >template <class Archive, class T> >inline bool do_serialize(Archive &ar, T &v) >{ > return ::serializer<Archive, T>::serialize(ar, v); >} ># 97 "/c/honeypenny/src/serialization/serialization.h" >namespace serialization { > namespace detail > { > template <typename T> > void prepare_custom_vector_serialization(size_t size, std::vector<T>& vec, const boost::mpl::bool_<true>& ) > { > } > > template <typename T> > void prepare_custom_vector_serialization(size_t size, std::vector<T>& vec, const boost::mpl::bool_<false>& ) > { > vec.resize(size); > } > > template<class Stream> > bool do_check_stream_state(Stream& s, boost::mpl::bool_<true>) > { > return s.good(); > } > > template<class Stream> > bool do_check_stream_state(Stream& s, boost::mpl::bool_<false>) > { > bool result = false; > if (s.good()) > { > std::ios_base::iostate state = s.rdstate(); > result = (-1) == s.peek(); > s.setstate(state); > } > return result; > } > } > > template<class Archive> > bool check_stream_state(Archive& ar) > { > return detail::do_check_stream_state(ar.stream(), typename Archive::is_saving()); > } > > template <class Archive, class T> > inline bool serialize(Archive &ar, T &v) > { > bool r = do_serialize(ar, v); > return r && check_stream_state(ar); > } >} > ># 1 "/c/honeypenny/src/serialization/string.h" 1 ># 9 "/c/honeypenny/src/serialization/string.h" >template <template <bool> class Archive> >inline bool do_serialize(Archive<false>& ar, std::string& str) >{ > size_t size = 0; > ar.serialize_varint(size); > if (ar.remaining_bytes() < size) > { > ar.stream().setstate(std::ios::failbit); > return false; > } > > std::unique_ptr<std::string::value_type[]> buf(new std::string::value_type[size]); > ar.serialize_blob(buf.get(), size); > str.erase(); > str.append(buf.get(), size); > return true; >} > > >template <template <bool> class Archive> >inline bool do_serialize(Archive<true>& ar, std::string& str) >{ > size_t size = str.size(); > ar.serialize_varint(size); > ar.serialize_blob(const_cast<std::string::value_type*>(str.c_str()), size); > return true; >} ># 146 "/c/honeypenny/src/serialization/serialization.h" 2 ># 1 "/c/honeypenny/src/serialization/vector.h" 1 ># 9 "/c/honeypenny/src/serialization/vector.h" >namespace serialization >{ > namespace detail > { > template <typename Archive, class T> > bool serialize_vector_element(Archive& ar, T& e) > { > return ::do_serialize(ar, e); > } > > template <typename Archive> > bool serialize_vector_element(Archive& ar, uint64_t& e) > { > ar.serialize_varint(e); > return true; > } > } >} > >template <template <bool> class Archive, class T> >bool do_serialize(Archive<false> &ar, std::vector<T> &v) >{ > size_t cnt; > ar.begin_array(cnt); > if (!ar.stream().good()) > return false; > v.clear(); > > > if (ar.remaining_bytes() < cnt) { > ar.stream().setstate(std::ios::failbit); > return false; > } > > v.reserve(cnt); > for (size_t i = 0; i < cnt; i++) { > if (i > 0) > ar.delimit_array(); > v.resize(i+1); > if (!::serialization::detail::serialize_vector_element(ar, v[i])) > return false; > if (!ar.stream().good()) > return false; > } > ar.end_array(); > return true; >} > >template <template <bool> class Archive, class T> >bool do_serialize(Archive<true> &ar, std::vector<T> &v) >{ > size_t cnt = v.size(); > ar.begin_array(cnt); > for (size_t i = 0; i < cnt; i++) { > if (!ar.stream().good()) > return false; > if (i > 0) > ar.delimit_array(); > if(!::serialization::detail::serialize_vector_element(ar, v[i])) > return false; > if (!ar.stream().good()) > return false; > } > ar.end_array(); > return true; >} ># 146 "/c/honeypenny/src/serialization/serialization.h" 2 ># 13 "/c/honeypenny/src/currency_core/currency_basic.h" 2 ># 1 "/c/honeypenny/src/serialization/variant.h" 1 ># 13 "/c/honeypenny/src/serialization/variant.h" ># 1 "/usr/include/boost/mpl/pop_front.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/pop_front.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/pop_front_impl.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/aux_/pop_front_impl.hpp" 3 4 >namespace boost { namespace mpl { > > > >template< typename Tag > >struct pop_front_impl >{ > template< typename Sequence > struct apply > > > > > > > > ; >}; > > template<> struct pop_front_impl<non_sequence_tag> {}; > >}} ># 19 "/usr/include/boost/mpl/pop_front.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > > >struct pop_front > : pop_front_impl< typename sequence_tag<Sequence>::type > > ::template apply< Sequence > >{ > >}; > >template<> struct pop_front< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : pop_front< T1 > { }; }; template< typename Tag > struct lambda< pop_front< na > , Tag , int_<-1> > { typedef false_ is_le; typedef pop_front< na > result_; typedef pop_front< na > type; }; namespace aux { template< typename T1 > struct template_arity< pop_front< T1 > > : int_<1> { }; template<> struct template_arity< pop_front< na > > : int_<-1> { }; } > >}} ># 14 "/c/honeypenny/src/serialization/variant.h" 2 > > >template <class Archive, class T> >struct variant_serialization_traits >{ >}; > >template <class Archive, class Variant, class TBegin, class TEnd> >struct variant_reader >{ > typedef typename Archive::variant_tag_type variant_tag_type; > typedef typename boost::mpl::next<TBegin>::type TNext; > typedef typename boost::mpl::deref<TBegin>::type current_type; > > static inline bool read(Archive &ar, Variant &v, variant_tag_type t) > { > if (variant_serialization_traits<Archive, current_type>::get_tag() == t) { > current_type x; > if(!::do_serialize(ar, x)) > { > ar.stream().setstate(std::ios::failbit); > return false; > } > v = x; > } else { > return variant_reader<Archive, Variant, TNext, TEnd>::read(ar, v, t); > } > return true; > } >}; > >template <class Archive, class Variant, class TBegin> >struct variant_reader<Archive, Variant, TBegin, TBegin> >{ > typedef typename Archive::variant_tag_type variant_tag_type; > > static inline bool read(Archive &ar, Variant &v, variant_tag_type t) > { > ar.stream().setstate(std::ios::failbit); > return false; > } > >}; > > >template <template <bool> class Archive, typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19> >struct serializer<Archive<false>, boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19>> >{ > typedef boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19> variant_type; > typedef typename Archive<false>::variant_tag_type variant_tag_type; > typedef typename variant_type::types types; > > static bool serialize(Archive<false> &ar, variant_type &v) { > variant_tag_type t; > ar.begin_variant(); > ar.read_variant_tag(t); > if(!variant_reader<Archive<false>, variant_type, typename boost::mpl::begin<types>::type, typename boost::mpl::end<types>::type>::read(ar, v, t)) > { > ar.stream().setstate(std::ios::failbit); > return false; > } > ar.end_variant(); > return true; > } >}; > >template <template <bool> class Archive, typename T0 , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 , typename T10 , typename T11 , typename T12 , typename T13 , typename T14 , typename T15 , typename T16 , typename T17 , typename T18 , typename T19> >struct serializer<Archive<true>, boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19>> >{ > typedef boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19> variant_type; > > > struct visitor : public boost::static_visitor<bool> > { > Archive<true> &ar; > > visitor(Archive<true> &a) : ar(a) { } > > template <class T> > bool operator ()(T &rv) const > { > ar.begin_variant(); > ar.write_variant_tag(variant_serialization_traits<Archive<true>, T>::get_tag()); > if(!::do_serialize(ar, rv)) > { > ar.stream().setstate(std::ios::failbit); > return false; > } > ar.end_variant(); > return true; > } > }; > > static bool serialize(Archive<true> &ar, variant_type &v) { > return boost::apply_visitor(visitor(ar), v); > } >}; ># 14 "/c/honeypenny/src/currency_core/currency_basic.h" 2 > ># 1 "/c/honeypenny/src/serialization/binary_archive.h" 1 ># 10 "/c/honeypenny/src/serialization/binary_archive.h" ># 1 "/usr/include/c++/4.9.0/cassert" 1 3 ># 41 "/usr/include/c++/4.9.0/cassert" 3 ># 42 "/usr/include/c++/4.9.0/cassert" 3 > ># 1 "/usr/include/assert.h" 1 3 4 ># 43 "/usr/include/c++/4.9.0/cassert" 2 3 ># 11 "/c/honeypenny/src/serialization/binary_archive.h" 2 > > > > ># 1 "/c/honeypenny/src/common/varint.h" 1 ># 13 "/c/honeypenny/src/common/varint.h" >namespace tools { > > template<typename OutputIt, typename T> > typename std::enable_if<std::is_integral<T>::value && std::is_unsigned<T>::value, void>::type > write_varint(OutputIt &&dest, T i) { > while (i >= 0x80) { > *dest++ = (static_cast<char>(i) & 0x7f) | 0x80; > i >>= 7; > } > *dest++ = static_cast<char>(i); > } > > template<typename t_type> > std::string get_varint_data(const t_type& v) > { > std::stringstream ss; > write_varint(std::ostreambuf_iterator<char>(ss), v); > return ss.str(); > } > > template<int bits, typename InputIt, typename T> > typename std::enable_if<std::is_integral<T>::value && std::is_unsigned<T>::value && 0 <= bits && bits <= std::numeric_limits<T>::digits, int>::type > read_varint(InputIt &&first, InputIt &&last, T &i) { > int read = 0; > i = 0; > for (int shift = 0;; shift += 7) { > if (first == last) { > return read; > } > unsigned char byte = *first++; > ++read; > if (shift + 7 >= bits && byte >= 1 << (bits - shift)) { > return -1; > } > if (byte == 0 && shift != 0) { > return -2; > } > i |= static_cast<T>(byte & 0x7f) << shift; > if ((byte & 0x80) == 0) { > break; > } > } > return read; > } > > template<typename InputIt, typename T> > int read_varint(InputIt &&first, InputIt &&last, T &i) { > return read_varint<std::numeric_limits<T>::digits, InputIt, T>(std::move(first), std::move(last), i); > } >} ># 16 "/c/honeypenny/src/serialization/binary_archive.h" 2 ># 18 "/c/honeypenny/src/serialization/binary_archive.h" >#pragma GCC diagnostic push ># 18 "/c/honeypenny/src/serialization/binary_archive.h" > > > > > >template <class Stream, bool IsSaving> >struct binary_archive_base >{ > typedef Stream stream_type; > typedef binary_archive_base<Stream, IsSaving> base_type; > typedef boost::mpl::bool_<IsSaving> is_saving; > > typedef uint8_t variant_tag_type; > > explicit binary_archive_base(stream_type &s) : stream_(s) { } > > void tag(const char *) { } > void begin_object() { } > void end_object() { } > void begin_variant() { } > void end_variant() { } > stream_type &stream() { return stream_; } >protected: > stream_type &stream_; >}; > >template <bool W> >struct binary_archive; > >template <> >struct binary_archive<false> : public binary_archive_base<std::istream, false> >{ > explicit binary_archive(stream_type &s) : base_type(s) { > stream_type::streampos pos = stream_.tellg(); > stream_.seekg(0, std::ios_base::end); > eof_pos_ = stream_.tellg(); > stream_.seekg(pos); > } > > template <class T> > void serialize_int(T &v) > { > serialize_uint(*(typename boost::make_unsigned<T>::type *)&v); > } > > template <class T> > void serialize_uint(T &v, size_t width = sizeof(T)) > { > T ret = 0; > unsigned shift = 0; > for (size_t i = 0; i < width; i++) { > > char c; > stream_.get(c); > T b = (unsigned char)c; > ret += (b << shift); > shift += 8; > } > v = ret; > } > void serialize_blob(void *buf, size_t len, const char *delimiter="") { stream_.read((char *)buf, len); } > > template <class T> > void serialize_varint(T &v) > { > serialize_uvarint(*(typename boost::make_unsigned<T>::type *)(&v)); > } > > template <class T> > void serialize_uvarint(T &v) > { > typedef std::istreambuf_iterator<char> it; > tools::read_varint(it(stream_), it(), v); > } > void begin_array(size_t &s) > { > serialize_varint(s); > } > void begin_array() { } > > void delimit_array() { } > void end_array() { } > > void begin_string(const char *delimiter="\"") { } > void end_string(const char *delimiter="\"") { } > > void read_variant_tag(variant_tag_type &t) { > serialize_int(t); > } > > size_t remaining_bytes() { > if (!stream_.good()) > return 0; > > (static_cast<void> (0)); > return eof_pos_ - stream_.tellg(); > } >protected: > std::streamoff eof_pos_; >}; > >template <> >struct binary_archive<true> : public binary_archive_base<std::ostream, true> >{ > explicit binary_archive(stream_type &s) : base_type(s) { } > > template <class T> > void serialize_int(T v) > { > serialize_uint(static_cast<typename boost::make_unsigned<T>::type>(v)); > } > template <class T> > void serialize_uint(T v) > { > for (size_t i = 0; i < sizeof(T); i++) { > stream_.put((char)(v & 0xff)); > if (1 < sizeof(T)) { > v >>= 8; > } > } > } > void serialize_blob(void *buf, size_t len, const char *delimiter="") { stream_.write((char *)buf, len); } > > template <class T> > void serialize_varint(T &v) > { > serialize_uvarint(*(typename boost::make_unsigned<T>::type *)(&v)); > } > > template <class T> > void serialize_uvarint(T &v) > { > typedef std::ostreambuf_iterator<char> it; > tools::write_varint(it(stream_), v); > } > void begin_array(size_t s) > { > serialize_varint(s); > } > void begin_array() { } > void delimit_array() { } > void end_array() { } > > void begin_string(const char *delimiter="\"") { } > void end_string(const char *delimiter="\"") { } > > void write_variant_tag(variant_tag_type t) { > serialize_int(t); > } >}; ># 169 "/c/honeypenny/src/serialization/binary_archive.h" >#pragma GCC diagnostic pop ># 169 "/c/honeypenny/src/serialization/binary_archive.h" ># 16 "/c/honeypenny/src/currency_core/currency_basic.h" 2 ># 1 "/c/honeypenny/src/serialization/json_archive.h" 1 ># 9 "/c/honeypenny/src/serialization/json_archive.h" > > > ># 1 "/usr/include/c++/4.9.0/cassert" 1 3 ># 41 "/usr/include/c++/4.9.0/cassert" 3 ># 42 "/usr/include/c++/4.9.0/cassert" 3 > ># 1 "/usr/include/assert.h" 1 3 4 ># 43 "/usr/include/c++/4.9.0/cassert" 2 3 ># 13 "/c/honeypenny/src/serialization/json_archive.h" 2 > > > >template <class Stream, bool IsSaving> >struct json_archive_base >{ > typedef Stream stream_type; > typedef json_archive_base<Stream, IsSaving> base_type; > typedef boost::mpl::bool_<IsSaving> is_saving; > > typedef const char *variant_tag_type; > > json_archive_base(stream_type &s, bool indent = false) : stream_(s), indent_(indent), object_begin(false), depth_(0) { } > > void tag(const char *tag) { > if (!object_begin) > stream_ << ", "; > make_indent(); > stream_ << '"' << tag << "\": "; > object_begin = false; > } > > void begin_object() > { > stream_ << "{"; > ++depth_; > object_begin = true; > } > > void end_object() > { > --depth_; > make_indent(); > stream_ << "}"; > } > > void begin_variant() { begin_object(); } > void end_variant() { end_object(); } > Stream &stream() { return stream_; } > >protected: > void make_indent() > { > if (indent_) > { > stream_ << '\n' << std::string(2 * depth_, ' '); > } > } > >protected: > stream_type &stream_; > bool indent_; > bool object_begin; > size_t depth_; >}; > >template <bool W> >struct json_archive; > >template <> >struct json_archive<true> : public json_archive_base<std::ostream, true> >{ > json_archive(stream_type &s, bool indent = false) : base_type(s, indent) { } > > template<typename T> > static auto promote_to_printable_integer_type(T v) -> decltype(+v) > { > > > return +v; > } > > template <class T> > void serialize_int(T v) > { > stream_ << std::dec << promote_to_printable_integer_type(v); > } > > void serialize_blob(void *buf, size_t len, const char *delimiter="\"") { > begin_string(delimiter); > for (size_t i = 0; i < len; i++) { > unsigned char c = ((unsigned char *)buf)[i]; > stream_ << std::hex << std::setw(2) << std::setfill('0') << (int)c; > } > end_string(delimiter); > } > > template <class T> > void serialize_varint(T &v) > { > stream_ << std::dec << promote_to_printable_integer_type(v); > } > > void begin_string(const char *delimiter="\"") > { > stream_ << delimiter; > } > > void end_string(const char *delimiter="\"") > { > stream_ << delimiter; > } > > void begin_array(size_t s=0) > { > inner_array_size_ = s; > ++depth_; > stream_ << "[ "; > } > > void delimit_array() > { > stream_ << ", "; > } > > void end_array() > { > --depth_; > if (0 < inner_array_size_) > { > make_indent(); > } > stream_ << "]"; > } > > void write_variant_tag(const char *t) > { > tag(t); > } > >private: > size_t inner_array_size_; >}; ># 17 "/c/honeypenny/src/currency_core/currency_basic.h" 2 ># 1 "/c/honeypenny/src/serialization/debug_archive.h" 1 ># 10 "/c/honeypenny/src/serialization/debug_archive.h" >template <bool W> >struct debug_archive : public json_archive<W> { > typedef typename json_archive<W>::stream_type stream_type; > > debug_archive(stream_type &s) : json_archive<W>(s) { } >}; > >template <class T> >struct serializer<debug_archive<true>, T> >{ > static void serialize(debug_archive<true> &ar, T &v) > { > ar.begin_object(); > ar.tag(variant_serialization_traits<debug_archive<true>, T>::get_tag()); > serializer<json_archive<true>, T>::serialize(ar, v); > ar.end_object(); > ar.stream() << std::endl; > } >}; ># 18 "/c/honeypenny/src/currency_core/currency_basic.h" 2 ># 1 "/c/honeypenny/src/serialization/crypto.h" 1 > > > > > > ># 1 "/c/honeypenny/src/crypto/chacha8.h" 1 > > > > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 9 "/c/honeypenny/src/crypto/chacha8.h" 2 > > > > > ># 1 "/usr/include/memory.h" 1 3 4 ># 15 "/c/honeypenny/src/crypto/chacha8.h" 2 > ># 1 "/c/honeypenny/src/crypto/hash.h" 1 > > > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 8 "/c/honeypenny/src/crypto/hash.h" 2 > ># 1 "/c/honeypenny/src/common/pod-class.h" 1 ># 10 "/c/honeypenny/src/crypto/hash.h" 2 ># 1 "/c/honeypenny/src/crypto/generic-ops.h" 1 > > > > > > > ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 ># 39 "/usr/include/c++/4.9.0/cstring" 3 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 9 "/c/honeypenny/src/crypto/generic-ops.h" 2 ># 11 "/c/honeypenny/src/crypto/hash.h" 2 > >namespace crypto { > > extern "C" { ># 1 "/c/honeypenny/src/crypto/hash-ops.h" 1 ># 55 "/c/honeypenny/src/crypto/hash-ops.h" >void cn_fast_hash(const void *data, size_t length, char *hash); > > >void hash_extra_blake(const void *data, size_t length, char *hash); >void hash_extra_groestl(const void *data, size_t length, char *hash); >void hash_extra_jh(const void *data, size_t length, char *hash); >void hash_extra_skein(const void *data, size_t length, char *hash); > >void tree_hash(const char (*hashes)[32], size_t count, char *root_hash); ># 16 "/c/honeypenny/src/crypto/hash.h" 2 > } > >#pragma pack(push, 1) > class hash { > char data[32]; > }; >#pragma pack(pop) > > static_assert(sizeof(hash) == 32, "Invalid structure size"); > > > > > > inline void cn_fast_hash(const void *data, std::size_t length, hash &hash) { > cn_fast_hash(data, length, reinterpret_cast<char *>(&hash)); > } > > inline hash cn_fast_hash(const void *data, std::size_t length) { > hash h; > cn_fast_hash(data, length, reinterpret_cast<char *>(&h)); > return h; > } > > > > > > inline void tree_hash(const hash *hashes, std::size_t count, hash &root_hash) { > tree_hash(reinterpret_cast<const char (*)[32]>(hashes), count, reinterpret_cast<char *>(&root_hash)); > } > >} > >namespace crypto { inline bool operator==(const hash &_v1, const hash &_v2) { return std::memcmp(&_v1, &_v2, sizeof(hash)) == 0; } inline bool operator!=(const hash &_v1, const hash &_v2) { return std::memcmp(&_v1, &_v2, sizeof(hash)) != 0; } } namespace crypto { static_assert(sizeof(std::size_t) <= sizeof(hash), "Size of " "hash" " must be at least that of size_t"); inline std::size_t hash_value(const hash &_v) { return reinterpret_cast<const std::size_t &>(_v); } } namespace std { template<> struct hash<crypto::hash> { std::size_t operator()(const crypto::hash &_v) const { return reinterpret_cast<const std::size_t &>(_v); } }; } ># 17 "/c/honeypenny/src/crypto/chacha8.h" 2 > >namespace crypto { > extern "C" { > > void chacha8(const void* data, size_t length, const uint8_t* key, const uint8_t* iv, char* cipher); > > } > >#pragma pack(push, 1) > struct chacha8_key { > uint8_t data[32]; > > ~chacha8_key() > { > memset(data, 0, sizeof(data)); > } > }; > > > struct chacha8_iv { > uint8_t data[8]; > }; >#pragma pack(pop) > > static_assert(sizeof(chacha8_key) == 32 && sizeof(chacha8_iv) == 8, "Invalid structure size"); > > inline void chacha8(const void* data, std::size_t length, const chacha8_key& key, const chacha8_iv& iv, char* cipher) { > chacha8(data, length, reinterpret_cast<const uint8_t*>(&key), reinterpret_cast<const uint8_t*>(&iv), cipher); > } > > inline void generate_chacha8_key(std::string password, chacha8_key& key) { > static_assert(sizeof(chacha8_key) <= sizeof(hash), "Size of hash must be at least that of chacha8_key"); > char pwd_hash[32]; > > crypto::cn_fast_hash(password.data(), password.size(), pwd_hash); > memcpy(&key, pwd_hash, sizeof(key)); > memset(pwd_hash, 0, sizeof(pwd_hash)); > } >} ># 8 "/c/honeypenny/src/serialization/crypto.h" 2 ># 1 "/c/honeypenny/src/crypto/crypto.h" 1 ># 15 "/c/honeypenny/src/crypto/crypto.h" >namespace crypto { > > extern "C" { ># 1 "/c/honeypenny/src/crypto/random.h" 1 > > > > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stddef.h" 1 3 4 ># 8 "/c/honeypenny/src/crypto/random.h" 2 > >void generate_random_bytes(size_t n, void *result); >void grant_random_initialize(void); ># 19 "/c/honeypenny/src/crypto/crypto.h" 2 > } > > extern std::mutex random_lock; > >#pragma pack(push, 1) > class ec_point { > char data[32]; > }; > > class ec_scalar { > char data[32]; > }; > > class public_key: ec_point { > friend class crypto_ops; > }; > > class secret_key: ec_scalar { > friend class crypto_ops; > }; > > class key_derivation: ec_point { > friend class crypto_ops; > }; > > class key_image: ec_point { > friend class crypto_ops; > }; > > class signature { > ec_scalar c, r; > friend class crypto_ops; > }; >#pragma pack(pop) > > static_assert(sizeof(ec_point) == 32 && sizeof(ec_scalar) == 32 && > sizeof(public_key) == 32 && sizeof(secret_key) == 32 && > sizeof(key_derivation) == 32 && sizeof(key_image) == 32 && > sizeof(signature) == 64, "Invalid structure size"); > > class crypto_ops { > crypto_ops(); > crypto_ops(const crypto_ops &); > void operator=(const crypto_ops &); > ~crypto_ops(); > > static void generate_keys(public_key &, secret_key &); > friend void generate_keys(public_key &, secret_key &); > static bool check_key(const public_key &); > friend bool check_key(const public_key &); > static bool secret_key_to_public_key(const secret_key &, public_key &); > friend bool secret_key_to_public_key(const secret_key &, public_key &); > static bool generate_key_derivation(const public_key &, const secret_key &, key_derivation &); > friend bool generate_key_derivation(const public_key &, const secret_key &, key_derivation &); > static bool derive_public_key(const key_derivation &, std::size_t, const public_key &, public_key &); > friend bool derive_public_key(const key_derivation &, std::size_t, const public_key &, public_key &); > static void derive_secret_key(const key_derivation &, std::size_t, const secret_key &, secret_key &); > friend void derive_secret_key(const key_derivation &, std::size_t, const secret_key &, secret_key &); > static void generate_signature(const hash &, const public_key &, const secret_key &, signature &); > friend void generate_signature(const hash &, const public_key &, const secret_key &, signature &); > static bool check_signature(const hash &, const public_key &, const signature &); > friend bool check_signature(const hash &, const public_key &, const signature &); > static void generate_key_image(const public_key &, const secret_key &, key_image &); > friend void generate_key_image(const public_key &, const secret_key &, key_image &); > static void generate_ring_signature(const hash &, const key_image &, > const public_key *const *, std::size_t, const secret_key &, std::size_t, signature *); > friend void generate_ring_signature(const hash &, const key_image &, > const public_key *const *, std::size_t, const secret_key &, std::size_t, signature *); > static bool check_ring_signature(const hash &, const key_image &, > const public_key *const *, std::size_t, const signature *); > friend bool check_ring_signature(const hash &, const key_image &, > const public_key *const *, std::size_t, const signature *); > }; > > > > template<typename T> > typename std::enable_if<std::is_pod<T>::value, T>::type rand() { > typename std::remove_cv<T>::type res; > std::lock_guard<std::mutex> lock(random_lock); > generate_random_bytes(sizeof(T), &res); > return res; > } > > > > inline void generate_keys(public_key &pub, secret_key &sec) { > crypto_ops::generate_keys(pub, sec); > } > > > > inline bool check_key(const public_key &key) { > return crypto_ops::check_key(key); > } > > > > inline bool secret_key_to_public_key(const secret_key &sec, public_key &pub) { > return crypto_ops::secret_key_to_public_key(sec, pub); > } > > > > > > > > inline bool generate_key_derivation(const public_key &key1, const secret_key &key2, key_derivation &derivation) { > return crypto_ops::generate_key_derivation(key1, key2, derivation); > } > inline bool derive_public_key(const key_derivation &derivation, std::size_t output_index, > const public_key &base, public_key &derived_key) { > return crypto_ops::derive_public_key(derivation, output_index, base, derived_key); > } > inline void derive_secret_key(const key_derivation &derivation, std::size_t output_index, > const secret_key &base, secret_key &derived_key) { > crypto_ops::derive_secret_key(derivation, output_index, base, derived_key); > } > > > > inline void generate_signature(const hash &prefix_hash, const public_key &pub, const secret_key &sec, signature &sig) { > crypto_ops::generate_signature(prefix_hash, pub, sec, sig); > } > inline bool check_signature(const hash &prefix_hash, const public_key &pub, const signature &sig) { > return crypto_ops::check_signature(prefix_hash, pub, sig); > } > > > > > > > > inline void generate_key_image(const public_key &pub, const secret_key &sec, key_image &image) { > crypto_ops::generate_key_image(pub, sec, image); > } > inline void generate_ring_signature(const hash &prefix_hash, const key_image &image, > const public_key *const *pubs, std::size_t pubs_count, > const secret_key &sec, std::size_t sec_index, > signature *sig) { > crypto_ops::generate_ring_signature(prefix_hash, image, pubs, pubs_count, sec, sec_index, sig); > } > inline bool check_ring_signature(const hash &prefix_hash, const key_image &image, > const public_key *const *pubs, std::size_t pubs_count, > const signature *sig) { > return crypto_ops::check_ring_signature(prefix_hash, image, pubs, pubs_count, sig); > } > > > > inline void generate_ring_signature(const hash &prefix_hash, const key_image &image, > const std::vector<const public_key *> &pubs, > const secret_key &sec, std::size_t sec_index, > signature *sig) { > generate_ring_signature(prefix_hash, image, pubs.data(), pubs.size(), sec, sec_index, sig); > } > inline bool check_ring_signature(const hash &prefix_hash, const key_image &image, > const std::vector<const public_key *> &pubs, > const signature *sig) { > return check_ring_signature(prefix_hash, image, pubs.data(), pubs.size(), sig); > } >} > >namespace crypto { inline bool operator==(const public_key &_v1, const public_key &_v2) { return std::memcmp(&_v1, &_v2, sizeof(public_key)) == 0; } inline bool operator!=(const public_key &_v1, const public_key &_v2) { return std::memcmp(&_v1, &_v2, sizeof(public_key)) != 0; } } >namespace crypto { inline bool operator==(const secret_key &_v1, const secret_key &_v2) { return std::memcmp(&_v1, &_v2, sizeof(secret_key)) == 0; } inline bool operator!=(const secret_key &_v1, const secret_key &_v2) { return std::memcmp(&_v1, &_v2, sizeof(secret_key)) != 0; } } >namespace crypto { inline bool operator==(const key_image &_v1, const key_image &_v2) { return std::memcmp(&_v1, &_v2, sizeof(key_image)) == 0; } inline bool operator!=(const key_image &_v1, const key_image &_v2) { return std::memcmp(&_v1, &_v2, sizeof(key_image)) != 0; } } namespace crypto { static_assert(sizeof(std::size_t) <= sizeof(key_image), "Size of " "key_image" " must be at least that of size_t"); inline std::size_t hash_value(const key_image &_v) { return reinterpret_cast<const std::size_t &>(_v); } } namespace std { template<> struct hash<crypto::key_image> { std::size_t operator()(const crypto::key_image &_v) const { return reinterpret_cast<const std::size_t &>(_v); } }; } >namespace crypto { inline bool operator==(const signature &_v1, const signature &_v2) { return std::memcmp(&_v1, &_v2, sizeof(signature)) == 0; } inline bool operator!=(const signature &_v1, const signature &_v2) { return std::memcmp(&_v1, &_v2, sizeof(signature)) != 0; } } ># 9 "/c/honeypenny/src/serialization/crypto.h" 2 > > > >template <template <bool> class Archive> >bool do_serialize(Archive<false> &ar, std::vector<crypto::signature> &v) >{ > size_t cnt = v.size(); > v.clear(); > > > if (ar.remaining_bytes() < cnt*sizeof(crypto::signature)) { > ar.stream().setstate(std::ios::failbit); > return false; > } > > v.reserve(cnt); > for (size_t i = 0; i < cnt; i++) { > v.resize(i+1); > ar.serialize_blob(&(v[i]), sizeof(crypto::signature), ""); > if (!ar.stream().good()) > return false; > } > return true; >} > > >template <template <bool> class Archive> >bool do_serialize(Archive<true> &ar, std::vector<crypto::signature> &v) >{ > if (0 == v.size()) return true; > ar.begin_string(); > size_t cnt = v.size(); > for (size_t i = 0; i < cnt; i++) { > ar.serialize_blob(&(v[i]), sizeof(crypto::signature), ""); > if (!ar.stream().good()) > return false; > } > ar.end_string(); > return true; >} > >template<> struct is_blob_type<crypto::chacha8_iv> { typedef boost::true_type type; }; >template<> struct is_blob_type<crypto::hash> { typedef boost::true_type type; }; >template<> struct is_blob_type<crypto::public_key> { typedef boost::true_type type; }; >template<> struct is_blob_type<crypto::secret_key> { typedef boost::true_type type; }; >template<> struct is_blob_type<crypto::key_derivation> { typedef boost::true_type type; }; >template<> struct is_blob_type<crypto::key_image> { typedef boost::true_type type; }; >template<> struct is_blob_type<crypto::signature> { typedef boost::true_type type; }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, crypto::hash> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "hash"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, crypto::public_key> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "public_key"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, crypto::secret_key> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "secret_key"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, crypto::key_derivation> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "key_derivation"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, crypto::key_image> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "key_image"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, crypto::signature> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "signature"; } }; ># 19 "/c/honeypenny/src/currency_core/currency_basic.h" 2 > > ># 1 "/c/honeypenny/src/currency_config.h" 1 ># 22 "/c/honeypenny/src/currency_core/currency_basic.h" 2 > > > ># 1 "/c/honeypenny/src/currency_core/tx_extra.h" 1 ># 26 "/c/honeypenny/src/currency_core/currency_basic.h" 2 > >namespace currency >{ > > const static crypto::hash null_hash = boost::value_initialized<decltype(null_hash)>(); > const static crypto::public_key null_pkey = boost::value_initialized<decltype(null_pkey)>(); > const static crypto::secret_key null_skey = boost::value_initialized<decltype(null_skey)>(); > const static crypto::signature null_sig = boost::value_initialized<decltype(null_sig)>(); > > typedef std::vector<crypto::signature> ring_signature; > > > struct txout_to_script > { > std::vector<crypto::public_key> keys; > std::vector<uint8_t> script; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { ar.begin_object(); bool r = do_serialize_object(ar); ar.end_object(); return r; } template <bool W, template <bool> class Archive> bool do_serialize_object(Archive<W> &ar){ > do { ar.tag("keys"); bool r = ::do_serialize(ar, keys); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("script"); bool r = ::do_serialize(ar, script); if (!r || !ar.stream().good()) return false; } while(0); > return true;} > }; > > struct txout_to_scripthash > { > crypto::hash hash; > }; > >#pragma pack(push, 1) > struct txout_to_key > { > txout_to_key() { } > txout_to_key(const crypto::public_key &_key) : key(_key) { } > > crypto::public_key key; > uint8_t mix_attr; > }; >#pragma pack(pop) > > > struct txin_gen > { > size_t height; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { ar.begin_object(); bool r = do_serialize_object(ar); ar.end_object(); return r; } template <bool W, template <bool> class Archive> bool do_serialize_object(Archive<W> &ar){ > do { ar.tag("height"); ar.serialize_varint(height); if (!ar.stream().good()) return false; } while(0); > return true;} > }; > > struct txin_to_script > { > crypto::hash prev; > size_t prevout; > std::vector<uint8_t> sigset; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { ar.begin_object(); bool r = do_serialize_object(ar); ar.end_object(); return r; } template <bool W, template <bool> class Archive> bool do_serialize_object(Archive<W> &ar){ > do { ar.tag("prev"); bool r = ::do_serialize(ar, prev); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("prevout"); ar.serialize_varint(prevout); if (!ar.stream().good()) return false; } while(0); > do { ar.tag("sigset"); bool r = ::do_serialize(ar, sigset); if (!r || !ar.stream().good()) return false; } while(0); > return true;} > }; > > struct txin_to_scripthash > { > crypto::hash prev; > size_t prevout; > txout_to_script script; > std::vector<uint8_t> sigset; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { ar.begin_object(); bool r = do_serialize_object(ar); ar.end_object(); return r; } template <bool W, template <bool> class Archive> bool do_serialize_object(Archive<W> &ar){ > do { ar.tag("prev"); bool r = ::do_serialize(ar, prev); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("prevout"); ar.serialize_varint(prevout); if (!ar.stream().good()) return false; } while(0); > do { ar.tag("script"); bool r = ::do_serialize(ar, script); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("sigset"); bool r = ::do_serialize(ar, sigset); if (!r || !ar.stream().good()) return false; } while(0); > return true;} > }; > > struct txin_to_key > { > uint64_t amount; > std::vector<uint64_t> key_offsets; > crypto::key_image k_image; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { ar.begin_object(); bool r = do_serialize_object(ar); ar.end_object(); return r; } template <bool W, template <bool> class Archive> bool do_serialize_object(Archive<W> &ar){ > do { ar.tag("amount"); ar.serialize_varint(amount); if (!ar.stream().good()) return false; } while(0); > do { ar.tag("key_offsets"); bool r = ::do_serialize(ar, key_offsets); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("k_image"); bool r = ::do_serialize(ar, k_image); if (!r || !ar.stream().good()) return false; } while(0); > return true;} > }; > > > typedef boost::variant<txin_gen, txin_to_script, txin_to_scripthash, txin_to_key> txin_v; > > typedef boost::variant<txout_to_script, txout_to_scripthash, txout_to_key> txout_target_v; > > > struct tx_out > { > uint64_t amount; > txout_target_v target; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { ar.begin_object(); bool r = do_serialize_object(ar); ar.end_object(); return r; } template <bool W, template <bool> class Archive> bool do_serialize_object(Archive<W> &ar){ > do { ar.tag("amount"); ar.serialize_varint(amount); if (!ar.stream().good()) return false; } while(0); > do { ar.tag("target"); bool r = ::do_serialize(ar, target); if (!r || !ar.stream().good()) return false; } while(0); > return true;} > > > }; > > class transaction_prefix > { > > public: > > size_t version; > uint64_t unlock_time; > > std::vector<txin_v> vin; > std::vector<tx_out> vout; > > std::vector<uint8_t> extra; > uint8_t flags; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { > do { ar.tag("version"); ar.serialize_varint(version); if (!ar.stream().good()) return false; } while(0); > if(1 < version) return false; > do { ar.tag("unlock_time"); ar.serialize_varint(unlock_time); if (!ar.stream().good()) return false; } while(0); > do { ar.tag("vin"); bool r = ::do_serialize(ar, vin); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("vout"); bool r = ::do_serialize(ar, vout); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("extra"); bool r = ::do_serialize(ar, extra); if (!r || !ar.stream().good()) return false; } while(0); > return true;} > > > protected: > transaction_prefix(){} > }; > > class transaction: public transaction_prefix > { > public: > std::vector<std::vector<crypto::signature> > signatures; > > transaction(); > virtual ~transaction(); > void set_null(); > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { ar.begin_object(); bool r = do_serialize_object(ar); ar.end_object(); return r; } template <bool W, template <bool> class Archive> bool do_serialize_object(Archive<W> &ar){ > bool r = ::do_serialize(ar, *static_cast<transaction_prefix *>(this)); if (!r || !ar.stream().good()) return false; > > ar.tag("signatures"); > ar.begin_array(); > ::serialization::detail::prepare_custom_vector_serialization(vin.size(), signatures, typename Archive<W>::is_saving()); > bool signatures_not_expected = signatures.empty(); > if (!signatures_not_expected && vin.size() != signatures.size()) > return false; > > for (size_t i = 0; i < vin.size(); ++i) > { > size_t signature_size = get_signature_size(vin[i]); > if (signatures_not_expected) > { > if (0 == signature_size) > continue; > else > return false; > } > > ::serialization::detail::prepare_custom_vector_serialization(signature_size, signatures[i], typename Archive<W>::is_saving()); > if (signature_size != signatures[i].size()) > return false; > > bool r = ::do_serialize(ar, signatures[i]); if (!r || !ar.stream().good()) return false;; > > if (vin.size() - i > 1) > ar.delimit_array(); > } > ar.end_array(); > return true;} > > private: > static size_t get_signature_size(const txin_v& tx_in); > }; > > > inline > transaction::transaction() > { > set_null(); > } > > inline > transaction::~transaction() > { > > } > > inline > void transaction::set_null() > { > version = 0; > unlock_time = 0; > vin.clear(); > vout.clear(); > extra.clear(); > signatures.clear(); > } > > inline > size_t transaction::get_signature_size(const txin_v& tx_in) > { > struct txin_signature_size_visitor : public boost::static_visitor<size_t> > { > size_t operator()(const txin_gen& txin) const{return 0;} > size_t operator()(const txin_to_script& txin) const{return 0;} > size_t operator()(const txin_to_scripthash& txin) const{return 0;} > size_t operator()(const txin_to_key& txin) const {return txin.key_offsets.size();} > }; > > return boost::apply_visitor(txin_signature_size_visitor(), tx_in); > } > > > > > > > struct block_header > { > uint8_t major_version; > uint8_t minor_version; > uint64_t timestamp; > crypto::hash prev_id; > uint32_t nonce; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { > do { ar.tag("major_version"); bool r = ::do_serialize(ar, major_version); if (!r || !ar.stream().good()) return false; } while(0); > if(major_version > 1) return false; > do { ar.tag("nonce"); bool r = ::do_serialize(ar, nonce); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("prev_id"); bool r = ::do_serialize(ar, prev_id); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("minor_version"); ar.serialize_varint(minor_version); if (!ar.stream().good()) return false; } while(0); > do { ar.tag("timestamp"); ar.serialize_varint(timestamp); if (!ar.stream().good()) return false; } while(0); > return true;} > }; > > struct block: public block_header > { > transaction miner_tx; > std::vector<crypto::hash> tx_hashes; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { ar.begin_object(); bool r = do_serialize_object(ar); ar.end_object(); return r; } template <bool W, template <bool> class Archive> bool do_serialize_object(Archive<W> &ar){ > bool r = ::do_serialize(ar, *static_cast<block_header *>(this)); if (!r || !ar.stream().good()) return false; > do { ar.tag("miner_tx"); bool r = ::do_serialize(ar, miner_tx); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("tx_hashes"); bool r = ::do_serialize(ar, tx_hashes); if (!r || !ar.stream().good()) return false; } while(0); > return true;} > }; > > > > > > struct account_public_address > { > crypto::public_key m_spend_public_key; > crypto::public_key m_view_public_key; > > template <bool W, template <bool> class Archive> bool do_serialize(Archive<W> &ar) { ar.begin_object(); bool r = do_serialize_object(ar); ar.end_object(); return r; } template <bool W, template <bool> class Archive> bool do_serialize_object(Archive<W> &ar){ > do { ar.tag("m_spend_public_key"); bool r = ::do_serialize(ar, m_spend_public_key); if (!r || !ar.stream().good()) return false; } while(0); > do { ar.tag("m_view_public_key"); bool r = ::do_serialize(ar, m_view_public_key); if (!r || !ar.stream().good()) return false; } while(0); > return true;} > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/currency_basic.h" << ":" << 296 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize_t_val_as_blob(this_ref.m_spend_public_key, stg, hparent_section, "m_spend_public_key"); > epee::serialization::selector<is_store>::serialize_t_val_as_blob(this_ref.m_view_public_key, stg, hparent_section, "m_view_public_key"); > return true;} > }; > > struct keypair > { > crypto::public_key pub; > crypto::secret_key sec; > > static inline keypair generate() > { > keypair k; > generate_keys(k.pub, k.sec); > return k; > } > }; > > >} > >template<> struct is_blob_type<currency::txout_to_key> { typedef boost::true_type type; }; >template<> struct is_blob_type<currency::txout_to_scripthash> { typedef boost::true_type type; }; > >template <bool W> struct variant_serialization_traits<binary_archive<W>, currency::txin_gen> { static inline typename binary_archive<W>::variant_tag_type get_tag() { return 0xff; } }; >template <bool W> struct variant_serialization_traits<binary_archive<W>, currency::txin_to_script> { static inline typename binary_archive<W>::variant_tag_type get_tag() { return 0x0; } }; >template <bool W> struct variant_serialization_traits<binary_archive<W>, currency::txin_to_scripthash> { static inline typename binary_archive<W>::variant_tag_type get_tag() { return 0x1; } }; >template <bool W> struct variant_serialization_traits<binary_archive<W>, currency::txin_to_key> { static inline typename binary_archive<W>::variant_tag_type get_tag() { return 0x2; } }; >template <bool W> struct variant_serialization_traits<binary_archive<W>, currency::txout_to_script> { static inline typename binary_archive<W>::variant_tag_type get_tag() { return 0x0; } }; >template <bool W> struct variant_serialization_traits<binary_archive<W>, currency::txout_to_scripthash> { static inline typename binary_archive<W>::variant_tag_type get_tag() { return 0x1; } }; >template <bool W> struct variant_serialization_traits<binary_archive<W>, currency::txout_to_key> { static inline typename binary_archive<W>::variant_tag_type get_tag() { return 0x2; } }; >template <bool W> struct variant_serialization_traits<binary_archive<W>, currency::transaction> { static inline typename binary_archive<W>::variant_tag_type get_tag() { return 0xcc; } }; >template <bool W> struct variant_serialization_traits<binary_archive<W>, currency::block> { static inline typename binary_archive<W>::variant_tag_type get_tag() { return 0xbb; } }; > >template <bool W> struct variant_serialization_traits<json_archive<W>, currency::txin_gen> { static inline typename json_archive<W>::variant_tag_type get_tag() { return "gen"; } }; >template <bool W> struct variant_serialization_traits<json_archive<W>, currency::txin_to_script> { static inline typename json_archive<W>::variant_tag_type get_tag() { return "script"; } }; >template <bool W> struct variant_serialization_traits<json_archive<W>, currency::txin_to_scripthash> { static inline typename json_archive<W>::variant_tag_type get_tag() { return "scripthash"; } }; >template <bool W> struct variant_serialization_traits<json_archive<W>, currency::txin_to_key> { static inline typename json_archive<W>::variant_tag_type get_tag() { return "key"; } }; >template <bool W> struct variant_serialization_traits<json_archive<W>, currency::txout_to_script> { static inline typename json_archive<W>::variant_tag_type get_tag() { return "script"; } }; >template <bool W> struct variant_serialization_traits<json_archive<W>, currency::txout_to_scripthash> { static inline typename json_archive<W>::variant_tag_type get_tag() { return "scripthash"; } }; >template <bool W> struct variant_serialization_traits<json_archive<W>, currency::txout_to_key> { static inline typename json_archive<W>::variant_tag_type get_tag() { return "key"; } }; >template <bool W> struct variant_serialization_traits<json_archive<W>, currency::transaction> { static inline typename json_archive<W>::variant_tag_type get_tag() { return "tx"; } }; >template <bool W> struct variant_serialization_traits<json_archive<W>, currency::block> { static inline typename json_archive<W>::variant_tag_type get_tag() { return "block"; } }; > >template <bool W> struct variant_serialization_traits<debug_archive<W>, currency::txin_gen> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "gen"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, currency::txin_to_script> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "script"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, currency::txin_to_scripthash> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "scripthash"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, currency::txin_to_key> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "key"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, currency::txout_to_script> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "script"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, currency::txout_to_scripthash> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "scripthash"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, currency::txout_to_key> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "key"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, currency::transaction> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "tx"; } }; >template <bool W> struct variant_serialization_traits<debug_archive<W>, currency::block> { static inline typename debug_archive<W>::variant_tag_type get_tag() { return "block"; } }; ># 10 "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" 2 ># 1 "/c/honeypenny/src/currency_protocol/blobdatatype.h" 1 > > > > > > >namespace currency >{ > typedef std::string blobdata; >} ># 11 "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" 2 >namespace currency >{ ># 21 "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" > struct block_complete_entry > { > blobdata block; > std::list<blobdata> txs; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" << ":" << 25 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.block, stg, hparent_section, "block"); > epee::serialization::selector<is_store>::serialize(this_ref.txs, stg, hparent_section, "txs"); > return true;} > }; > > > > > > struct NOTIFY_NEW_BLOCK > { > const static int ID = 2000 + 1; > > struct request > { > block_complete_entry b; > uint64_t current_blockchain_height; > uint32_t hop; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" << ":" << 45 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.b, stg, hparent_section, "b"); > epee::serialization::selector<is_store>::serialize(this_ref.current_blockchain_height, stg, hparent_section, "current_blockchain_height"); > epee::serialization::selector<is_store>::serialize(this_ref.hop, stg, hparent_section, "hop"); > return true;} > }; > }; > > > > > struct NOTIFY_NEW_TRANSACTIONS > { > const static int ID = 2000 + 2; > > struct request > { > std::list<blobdata> txs; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" << ":" << 64 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.txs, stg, hparent_section, "txs"); > return true;} > }; > }; > > > > struct NOTIFY_REQUEST_GET_OBJECTS > { > const static int ID = 2000 + 3; > > struct request > { > std::list<crypto::hash> txs; > std::list<crypto::hash> blocks; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" << ":" << 81 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.txs, stg, hparent_section, "txs"); > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.blocks, stg, hparent_section, "blocks"); > return true;} > }; > }; > > struct NOTIFY_RESPONSE_GET_OBJECTS > { > const static int ID = 2000 + 4; > > struct request > { > std::list<blobdata> txs; > std::list<block_complete_entry> blocks; > std::list<crypto::hash> missed_ids; > uint64_t current_blockchain_height; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" << ":" << 99 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.txs, stg, hparent_section, "txs"); > epee::serialization::selector<is_store>::serialize(this_ref.blocks, stg, hparent_section, "blocks"); > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.missed_ids, stg, hparent_section, "missed_ids"); > epee::serialization::selector<is_store>::serialize(this_ref.current_blockchain_height, stg, hparent_section, "current_blockchain_height"); > return true;} > }; > }; > > > struct CORE_SYNC_DATA > { > uint64_t current_height; > crypto::hash top_id; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" << ":" << 114 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.current_height, stg, hparent_section, "current_height"); > static_assert(std::is_pod<decltype(this_ref.top_id)>::value, "t_type must be a POD type."); epee::serialization::selector<is_store>::serialize_t_val_as_blob(this_ref.top_id, stg, hparent_section, "top_id"); > return true;} > }; > > struct NOTIFY_REQUEST_CHAIN > { > const static int ID = 2000 + 6; > > struct request > { > std::list<crypto::hash> block_ids; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" << ":" << 128 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.block_ids, stg, hparent_section, "block_ids"); > return true;} > }; > }; > > struct NOTIFY_RESPONSE_CHAIN_ENTRY > { > const static int ID = 2000 + 7; > > struct request > { > uint64_t start_height; > uint64_t total_height; > std::list<crypto::hash> m_block_ids; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_defs.h" << ":" << 144 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.start_height, stg, hparent_section, "start_height"); > epee::serialization::selector<is_store>::serialize(this_ref.total_height, stg, hparent_section, "total_height"); > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.m_block_ids, stg, hparent_section, "m_block_ids"); > return true;} > }; > }; > >} ># 7 "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" 2 > ># 1 "/c/honeypenny/src/currency_core/difficulty.h" 1 ># 12 "/c/honeypenny/src/currency_core/difficulty.h" >namespace currency >{ > typedef std::uint64_t difficulty_type; > > bool check_hash(const crypto::hash &hash, difficulty_type difficulty); > difficulty_type next_difficulty(std::vector<std::uint64_t> timestamps, std::vector<difficulty_type> cumulative_difficulties); > difficulty_type next_difficulty(std::vector<std::uint64_t> timestamps, std::vector<difficulty_type> cumulative_difficulties, size_t target_seconds); >} ># 9 "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" 2 > ># 1 "/c/honeypenny/src/p2p/p2p_protocol_defs.h" 1 ># 13 "/c/honeypenny/src/p2p/p2p_protocol_defs.h" >namespace nodetool >{ > typedef boost::uuids::uuid uuid; > typedef uint64_t peerid_type; > typedef std::string blobdata; > >#pragma pack (push, 1) > > struct net_address > { > uint32_t ip; > uint32_t port; > }; > > struct peerlist_entry > { > net_address adr; > peerid_type id; > time_t last_seen; > }; > > struct connection_entry > { > net_address adr; > peerid_type id; > bool is_income; > }; > >#pragma pack(pop) > > inline > bool operator < (const net_address& a, const net_address& b) > { > return epee::misc_utils::is_less_as_pod(a, b); > } > > inline > bool operator == (const net_address& a, const net_address& b) > { > return memcmp(&a, &b, sizeof(a)) == 0; > } > inline > std::string print_peerlist_to_string(const std::list<peerlist_entry>& pl) > { > time_t now_time = 0; > time(&now_time); > std::stringstream ss; > ss << std::setfill ('0') << std::setw (8) << std::hex << std::noshowbase; > if (boost::foreach_detail_::auto_any_t _foreach_col61 = boost::foreach_detail_::contain( (pl) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((pl), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(pl) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(pl) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur61 = boost::foreach_detail_::begin( _foreach_col61 , (true ? 0 : boost::foreach_detail_::encode_type(pl, boost::foreach_detail_::is_const_(pl))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((pl), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(pl) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(pl) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end61 = boost::foreach_detail_::end( _foreach_col61 , (true ? 0 : boost::foreach_detail_::encode_type(pl, boost::foreach_detail_::is_const_(pl))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((pl), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(pl) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(pl) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue61 = true; _foreach_continue61 && !boost::foreach_detail_::done( _foreach_cur61 , _foreach_end61 , (true ? 0 : boost::foreach_detail_::encode_type(pl, boost::foreach_detail_::is_const_(pl)))); _foreach_continue61 ? boost::foreach_detail_::next( _foreach_cur61 , (true ? 0 : boost::foreach_detail_::encode_type(pl, boost::foreach_detail_::is_const_(pl)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue61)) {} else for (const peerlist_entry& pe = boost::foreach_detail_::deref( _foreach_cur61 , (true ? 0 : boost::foreach_detail_::encode_type(pl, boost::foreach_detail_::is_const_(pl)))); !_foreach_continue61; _foreach_continue61 = true) > { > ss << pe.id << "\t" << epee::string_tools::get_ip_string_from_int32(pe.adr.ip) << ":" << boost::lexical_cast<std::string>(pe.adr.port) << " \tlast_seen: " << epee::misc_utils::get_time_interval_string(now_time - pe.last_seen) << std::endl; > } > return ss.str(); > } > > > struct network_config > { > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 71 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.connections_count, stg, hparent_section, "connections_count"); > epee::serialization::selector<is_store>::serialize(this_ref.handshake_interval, stg, hparent_section, "handshake_interval"); > epee::serialization::selector<is_store>::serialize(this_ref.packet_max_size, stg, hparent_section, "packet_max_size"); > epee::serialization::selector<is_store>::serialize(this_ref.config_id, stg, hparent_section, "config_id"); > return true;} > > uint32_t connections_count; > uint32_t connection_timeout; > uint32_t ping_connection_timeout; > uint32_t handshake_interval; > uint32_t packet_max_size; > uint32_t config_id; > uint32_t send_peerlist_sz; > }; > > struct basic_node_data > { > uuid network_id; > int64_t local_time; > uint32_t my_port; > peerid_type peer_id; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 94 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > static_assert(std::is_pod<decltype(this_ref.network_id)>::value, "t_type must be a POD type."); epee::serialization::selector<is_store>::serialize_t_val_as_blob(this_ref.network_id, stg, hparent_section, "network_id"); > epee::serialization::selector<is_store>::serialize(this_ref.peer_id, stg, hparent_section, "peer_id"); > epee::serialization::selector<is_store>::serialize(this_ref.local_time, stg, hparent_section, "local_time"); > epee::serialization::selector<is_store>::serialize(this_ref.my_port, stg, hparent_section, "my_port"); > return true;} > }; ># 116 "/c/honeypenny/src/p2p/p2p_protocol_defs.h" > struct alert_condition > { > uint32_t if_build_less_then; > uint8_t alert_mode; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 121 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.if_build_less_then, stg, hparent_section, "build"); > epee::serialization::selector<is_store>::serialize(this_ref.alert_mode, stg, hparent_section, "mode"); > return true;} > }; > > struct maintainers_info > { > uint64_t timestamp; > > uint8_t ver_major; > uint8_t ver_minor; > uint8_t ver_revision; > uint32_t build_no; > > std::list<alert_condition> conditions; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 138 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.timestamp, stg, hparent_section, "ts"); > epee::serialization::selector<is_store>::serialize(this_ref.ver_major, stg, hparent_section, "maj"); > epee::serialization::selector<is_store>::serialize(this_ref.ver_minor, stg, hparent_section, "min"); > epee::serialization::selector<is_store>::serialize(this_ref.ver_revision, stg, hparent_section, "rev"); > epee::serialization::selector<is_store>::serialize(this_ref.build_no, stg, hparent_section, "build"); > epee::serialization::selector<is_store>::serialize(this_ref.conditions, stg, hparent_section, "cs"); > return true;} > }; > > struct maintainers_entry > { > blobdata maintainers_info_buff; > crypto::signature sign; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 153 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.maintainers_info_buff, stg, hparent_section, "maintainers_info_buff"); > static_assert(std::is_pod<decltype(this_ref.sign)>::value, "t_type must be a POD type."); epee::serialization::selector<is_store>::serialize_t_val_as_blob(this_ref.sign, stg, hparent_section, "sign"); > return true;} > }; > > > > template<class t_playload_type> > struct COMMAND_HANDSHAKE_T > { > const static int ID = 1000 + 1; > > struct request > { > basic_node_data node_data; > t_playload_type payload_data; > maintainers_entry maintrs_entry; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 172 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.node_data, stg, hparent_section, "node_data"); > epee::serialization::selector<is_store>::serialize(this_ref.payload_data, stg, hparent_section, "payload_data"); > epee::serialization::selector<is_store>::serialize(this_ref.maintrs_entry, stg, hparent_section, "maintrs_entry"); > return true;} > }; > > struct response > { > basic_node_data node_data; > t_playload_type payload_data; > std::list<peerlist_entry> local_peerlist; > maintainers_entry maintrs_entry; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 186 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.node_data, stg, hparent_section, "node_data"); > epee::serialization::selector<is_store>::serialize(this_ref.payload_data, stg, hparent_section, "payload_data"); > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.local_peerlist, stg, hparent_section, "local_peerlist"); > epee::serialization::selector<is_store>::serialize(this_ref.maintrs_entry, stg, hparent_section, "maintrs_entry"); > return true;} > }; > }; > > > > > > template<class t_playload_type> > struct COMMAND_TIMED_SYNC_T > { > const static int ID = 1000 + 2; > > struct request > { > t_playload_type payload_data; > maintainers_entry maintrs_entry; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 209 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.payload_data, stg, hparent_section, "payload_data"); > epee::serialization::selector<is_store>::serialize(this_ref.maintrs_entry, stg, hparent_section, "maintrs_entry"); > return true;} > }; > > struct response > { > int64_t local_time; > t_playload_type payload_data; > std::list<peerlist_entry> local_peerlist; > maintainers_entry maintrs_entry; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 222 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.local_time, stg, hparent_section, "local_time"); > epee::serialization::selector<is_store>::serialize(this_ref.payload_data, stg, hparent_section, "payload_data"); > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.local_peerlist, stg, hparent_section, "local_peerlist"); > epee::serialization::selector<is_store>::serialize(this_ref.maintrs_entry, stg, hparent_section, "maintrs_entry"); > return true;} > }; > }; > > > > > > struct COMMAND_PING > { > > > > > > const static int ID = 1000 + 3; > > > > struct request > { > > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 250 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > return true;} > }; > > struct response > { > std::string status; > peerid_type peer_id; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 259 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > epee::serialization::selector<is_store>::serialize(this_ref.peer_id, stg, hparent_section, "peer_id"); > return true;} > }; > }; > > > > > > > struct proof_of_trust > { > peerid_type peer_id; > int64_t time; > crypto::signature sign; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 277 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.peer_id, stg, hparent_section, "peer_id"); > epee::serialization::selector<is_store>::serialize(this_ref.time, stg, hparent_section, "time"); > static_assert(std::is_pod<decltype(this_ref.sign)>::value, "t_type must be a POD type."); epee::serialization::selector<is_store>::serialize_t_val_as_blob(this_ref.sign, stg, hparent_section, "sign"); > return true;} > }; > > > template<class payload_stat_info> > struct COMMAND_REQUEST_STAT_INFO_T > { > const static int ID = 1000 + 4; > > struct request > { > proof_of_trust tr; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 293 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.tr, stg, hparent_section, "tr"); > return true;} > }; > > struct response > { > std::string version; > uint64_t connections_count; > uint64_t incoming_connections_count; > payload_stat_info payload_info; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 305 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.version, stg, hparent_section, "version"); > epee::serialization::selector<is_store>::serialize(this_ref.connections_count, stg, hparent_section, "connections_count"); > epee::serialization::selector<is_store>::serialize(this_ref.incoming_connections_count, stg, hparent_section, "incoming_connections_count"); > epee::serialization::selector<is_store>::serialize(this_ref.payload_info, stg, hparent_section, "payload_info"); > return true;} > }; > }; > > > > > > struct COMMAND_REQUEST_NETWORK_STATE > { > const static int ID = 1000 + 5; > > struct request > { > proof_of_trust tr; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 325 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.tr, stg, hparent_section, "tr"); > return true;} > }; > > struct response > { > std::list<peerlist_entry> local_peerlist_white; > std::list<peerlist_entry> local_peerlist_gray; > std::list<connection_entry> connections_list; > peerid_type my_id; > int64_t local_time; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 337 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.local_peerlist_white, stg, hparent_section, "local_peerlist_white"); > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.local_peerlist_gray, stg, hparent_section, "local_peerlist_gray"); > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.connections_list, stg, hparent_section, "connections_list"); > epee::serialization::selector<is_store>::serialize(this_ref.my_id, stg, hparent_section, "my_id"); > epee::serialization::selector<is_store>::serialize(this_ref.local_time, stg, hparent_section, "local_time"); > return true;} > }; > }; > > > > > struct COMMAND_REQUEST_PEER_ID > { > const static int ID = 1000 + 6; > > struct request > { > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 356 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > return true;} > }; > > struct response > { > peerid_type my_id; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/p2p_protocol_defs.h" << ":" << 364 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.my_id, stg, hparent_section, "my_id"); > return true;} > }; > }; > > > >} ># 11 "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" 2 > >namespace currency >{ > > > > > struct COMMAND_RPC_GET_HEIGHT > { > struct request > { > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 22 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > return true;} > }; > > struct response > { > uint64_t height; > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 31 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.height, stg, hparent_section, "height"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > struct COMMAND_RPC_GET_BLOCKS_FAST > { > > struct request > { > std::list<crypto::hash> block_ids; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 45 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.block_ids, stg, hparent_section, "block_ids"); > return true;} > }; > > struct response > { > std::list<block_complete_entry> blocks; > uint64_t start_height; > uint64_t current_height; > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 57 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.blocks, stg, hparent_section, "blocks"); > epee::serialization::selector<is_store>::serialize(this_ref.start_height, stg, hparent_section, "start_height"); > epee::serialization::selector<is_store>::serialize(this_ref.current_height, stg, hparent_section, "current_height"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > struct COMMAND_RPC_GET_TRANSACTIONS > { > struct request > { > std::list<std::string> txs_hashes; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 72 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.txs_hashes, stg, hparent_section, "txs_hashes"); > return true;} > }; > > > struct response > { > std::list<std::string> txs_as_hex; > std::list<std::string> missed_tx; > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 84 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.txs_as_hex, stg, hparent_section, "txs_as_hex"); > epee::serialization::selector<is_store>::serialize(this_ref.missed_tx, stg, hparent_section, "missed_tx"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > > struct COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES > { > struct request > { > crypto::hash txid; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 98 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > static_assert(std::is_pod<decltype(this_ref.txid)>::value, "t_type must be a POD type."); epee::serialization::selector<is_store>::serialize_t_val_as_blob(this_ref.txid, stg, hparent_section, "txid"); > return true;} > }; > > > struct response > { > std::vector<uint64_t> o_indexes; > std::string status; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 108 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.o_indexes, stg, hparent_section, "o_indexes"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > struct COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS > { > struct request > { > std::list<uint64_t> amounts; > uint64_t outs_count; > bool use_forced_mix_outs; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 122 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.amounts, stg, hparent_section, "amounts"); > epee::serialization::selector<is_store>::serialize(this_ref.outs_count, stg, hparent_section, "outs_count"); > epee::serialization::selector<is_store>::serialize(this_ref.use_forced_mix_outs, stg, hparent_section, "use_forced_mix_outs"); > return true;} > }; > >#pragma pack (push, 1) > struct out_entry > { > uint64_t global_amount_index; > crypto::public_key out_key; > }; >#pragma pack(pop) > > struct outs_for_amount > { > uint64_t amount; > std::list<out_entry> outs; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 142 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.amount, stg, hparent_section, "amount"); > epee::serialization::selector<is_store>::serialize_stl_container_pod_val_as_blob(this_ref.outs, stg, hparent_section, "outs"); > return true;} > }; > > struct response > { > std::vector<outs_for_amount> outs; > std::string status; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 152 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.outs, stg, hparent_section, "outs"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > > struct COMMAND_RPC_SET_MAINTAINERS_INFO > { > typedef nodetool::maintainers_entry request; > > struct response > { > std::string status; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 167 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > > struct COMMAND_RPC_SEND_RAW_TX > { > struct request > { > std::string tx_as_hex; > > request() {} > explicit request(const transaction &); > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 183 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.tx_as_hex, stg, hparent_section, "tx_as_hex"); > return true;} > }; > > > struct response > { > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 193 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > struct COMMAND_RPC_START_MINING > { > struct request > { > std::string miner_address; > uint64_t threads_count; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 206 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.miner_address, stg, hparent_section, "miner_address"); > epee::serialization::selector<is_store>::serialize(this_ref.threads_count, stg, hparent_section, "threads_count"); > return true;} > }; > > struct response > { > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 216 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > struct COMMAND_RPC_GET_INFO > { > struct request > { > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 227 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > return true;} > }; > > struct response > { > std::string status; > uint64_t height; > uint64_t difficulty; > uint64_t tx_count; > uint64_t tx_pool_size; > uint64_t alt_blocks_count; > uint64_t outgoing_connections_count; > uint64_t incoming_connections_count; > uint64_t white_peerlist_size; > uint64_t grey_peerlist_size; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 244 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > epee::serialization::selector<is_store>::serialize(this_ref.height, stg, hparent_section, "height"); > epee::serialization::selector<is_store>::serialize(this_ref.difficulty, stg, hparent_section, "difficulty"); > epee::serialization::selector<is_store>::serialize(this_ref.tx_count, stg, hparent_section, "tx_count"); > epee::serialization::selector<is_store>::serialize(this_ref.tx_pool_size, stg, hparent_section, "tx_pool_size"); > epee::serialization::selector<is_store>::serialize(this_ref.alt_blocks_count, stg, hparent_section, "alt_blocks_count"); > epee::serialization::selector<is_store>::serialize(this_ref.outgoing_connections_count, stg, hparent_section, "outgoing_connections_count"); > epee::serialization::selector<is_store>::serialize(this_ref.incoming_connections_count, stg, hparent_section, "incoming_connections_count"); > epee::serialization::selector<is_store>::serialize(this_ref.white_peerlist_size, stg, hparent_section, "white_peerlist_size"); > epee::serialization::selector<is_store>::serialize(this_ref.grey_peerlist_size, stg, hparent_section, "grey_peerlist_size"); > return true;} > }; > }; > > > > struct COMMAND_RPC_STOP_MINING > { > struct request > { > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 266 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > return true;} > }; > > > struct response > { > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 275 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > > > struct COMMAND_RPC_GETBLOCKCOUNT > { > typedef std::list<std::string> request; > > struct response > { > uint64_t count; > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 292 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.count, stg, hparent_section, "count"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > > }; > > struct COMMAND_RPC_GETBLOCKHASH > { > typedef std::vector<uint64_t> request; > > typedef std::string response; > }; > > > struct COMMAND_RPC_GETBLOCKTEMPLATE > { > struct request > { > uint64_t reserve_size; > std::string wallet_address; > bool donate_to_developers; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 316 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.reserve_size, stg, hparent_section, "reserve_size"); > epee::serialization::selector<is_store>::serialize(this_ref.wallet_address, stg, hparent_section, "wallet_address"); > epee::serialization::selector<is_store>::serialize(this_ref.donate_to_developers, stg, hparent_section, "donate_to_developers"); > return true;} > }; > > struct response > { > uint64_t difficulty; > uint64_t height; > uint64_t reserved_offset; > blobdata blocktemplate_blob; > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 331 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.difficulty, stg, hparent_section, "difficulty"); > epee::serialization::selector<is_store>::serialize(this_ref.height, stg, hparent_section, "height"); > epee::serialization::selector<is_store>::serialize(this_ref.reserved_offset, stg, hparent_section, "reserved_offset"); > epee::serialization::selector<is_store>::serialize(this_ref.blocktemplate_blob, stg, hparent_section, "blocktemplate_blob"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > struct COMMAND_RPC_SUBMITBLOCK > { > typedef std::vector<std::string> request; > > struct response > { > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 349 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > struct block_header_responce > { > uint8_t major_version; > uint8_t minor_version; > uint64_t timestamp; > std::string prev_hash; > uint32_t nonce; > bool orphan_status; > uint64_t height; > uint64_t depth; > std::string hash; > difficulty_type difficulty; > uint64_t reward; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 369 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.major_version, stg, hparent_section, "major_version"); > epee::serialization::selector<is_store>::serialize(this_ref.minor_version, stg, hparent_section, "minor_version"); > epee::serialization::selector<is_store>::serialize(this_ref.timestamp, stg, hparent_section, "timestamp"); > epee::serialization::selector<is_store>::serialize(this_ref.prev_hash, stg, hparent_section, "prev_hash"); > epee::serialization::selector<is_store>::serialize(this_ref.nonce, stg, hparent_section, "nonce"); > epee::serialization::selector<is_store>::serialize(this_ref.orphan_status, stg, hparent_section, "orphan_status"); > epee::serialization::selector<is_store>::serialize(this_ref.height, stg, hparent_section, "height"); > epee::serialization::selector<is_store>::serialize(this_ref.depth, stg, hparent_section, "depth"); > epee::serialization::selector<is_store>::serialize(this_ref.hash, stg, hparent_section, "hash"); > epee::serialization::selector<is_store>::serialize(this_ref.difficulty, stg, hparent_section, "difficulty"); > epee::serialization::selector<is_store>::serialize(this_ref.reward, stg, hparent_section, "reward"); > return true;} > }; > > struct COMMAND_RPC_GET_LAST_BLOCK_HEADER > { > typedef std::list<std::string> request; > > struct response > { > std::string status; > block_header_responce block_header; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 393 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.block_header, stg, hparent_section, "block_header"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > > }; > > struct COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH > { > struct request > { > std::string hash; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 407 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.hash, stg, hparent_section, "hash"); > return true;} > }; > > struct response > { > std::string status; > block_header_responce block_header; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 417 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.block_header, stg, hparent_section, "block_header"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > > }; > > struct COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT > { > struct request > { > uint64_t height; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 431 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.height, stg, hparent_section, "height"); > return true;} > }; > > struct response > { > std::string status; > block_header_responce block_header; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 441 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.block_header, stg, hparent_section, "block_header"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > > }; > > struct alias_rpc_details_base > { > std::string address; > std::string tracking_key; > std::string comment; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 455 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.address, stg, hparent_section, "address"); > epee::serialization::selector<is_store>::serialize(this_ref.tracking_key, stg, hparent_section, "tracking_key"); > epee::serialization::selector<is_store>::serialize(this_ref.comment, stg, hparent_section, "comment"); > return true;} > }; > > struct alias_rpc_details > { > std::string alias; > alias_rpc_details_base details; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 467 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.alias, stg, hparent_section, "alias"); > namespace_accessor<decltype(this_ref.details)>::template serialize_map<is_store>(this_ref.details, stg, hparent_section); > return true;} > > }; > > struct COMMAND_RPC_GET_ALIAS_DETAILS > { > struct request > { > std::string alias; > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 479 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.alias, stg, hparent_section, "alias"); > return true;} > }; > > struct response > { > alias_rpc_details_base alias_details; > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 489 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.alias_details, stg, hparent_section, "alias_details"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > > struct COMMAND_RPC_GET_ALL_ALIASES > { > struct request > { > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 501 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > return true;} > }; > > struct response > { > std::list<alias_rpc_details> aliases; > std::string status; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server_commands_defs.h" << ":" << 510 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.aliases, stg, hparent_section, "aliases"); > epee::serialization::selector<is_store>::serialize(this_ref.status, stg, hparent_section, "status"); > return true;} > }; > }; > > >} ># 12 "/c/honeypenny/src/rpc/core_rpc_server.h" 2 ># 1 "/c/honeypenny/src/currency_core/currency_core.h" 1 ># 11 "/c/honeypenny/src/currency_core/currency_core.h" ># 1 "/c/honeypenny/src/p2p/net_node_common.h" 1 > > > > > > > ># 1 "/c/honeypenny/contrib/epee/include/net/net_utils_base.h" 1 ># 9 "/c/honeypenny/src/p2p/net_node_common.h" 2 > > >namespace nodetool >{ > > typedef boost::uuids::uuid uuid; > typedef boost::uuids::uuid net_connection_id; > > template<class t_connection_context> > struct i_p2p_endpoint > { > virtual bool relay_notify_to_all(int command, const std::string& data_buff, const epee::net_utils::connection_context_base& context)=0; > virtual bool invoke_command_to_peer(int command, const std::string& req_buff, std::string& resp_buff, const epee::net_utils::connection_context_base& context)=0; > virtual bool invoke_notify_to_peer(int command, const std::string& req_buff, const epee::net_utils::connection_context_base& context)=0; > virtual bool drop_connection(const epee::net_utils::connection_context_base& context)=0; > virtual void request_callback(const epee::net_utils::connection_context_base& context)=0; > virtual uint64_t get_connections_count()=0; > virtual void for_each_connection(std::function<bool(t_connection_context&, peerid_type)> f)=0; > }; > > template<class t_connection_context> > struct p2p_endpoint_stub: public i_p2p_endpoint<t_connection_context> > { > virtual bool relay_notify_to_all(int command, const std::string& data_buff, const epee::net_utils::connection_context_base& context) > { > return false; > } > virtual bool invoke_command_to_peer(int command, const std::string& req_buff, std::string& resp_buff, const epee::net_utils::connection_context_base& context) > { > return false; > } > virtual bool invoke_notify_to_peer(int command, const std::string& req_buff, const epee::net_utils::connection_context_base& context) > { > return true; > } > virtual bool drop_connection(const epee::net_utils::connection_context_base& context) > { > return false; > } > virtual void request_callback(const epee::net_utils::connection_context_base& context) > { > > } > virtual void for_each_connection(std::function<bool(t_connection_context&,peerid_type)> f) > { > > } > > virtual uint64_t get_connections_count() > { > return false; > } > }; >} ># 12 "/c/honeypenny/src/currency_core/currency_core.h" 2 ># 1 "/c/honeypenny/src/currency_protocol/currency_protocol_handler_common.h" 1 ># 9 "/c/honeypenny/src/currency_protocol/currency_protocol_handler_common.h" ># 1 "/c/honeypenny/src/currency_core/connection_context.h" 1 > > > > > ># 1 "/usr/include/c++/4.9.0/unordered_set" 1 3 ># 32 "/usr/include/c++/4.9.0/unordered_set" 3 ># 33 "/usr/include/c++/4.9.0/unordered_set" 3 ># 47 "/usr/include/c++/4.9.0/unordered_set" 3 ># 1 "/usr/include/c++/4.9.0/bits/hashtable.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/hashtable.h" 3 ># 34 "/usr/include/c++/4.9.0/bits/hashtable.h" 3 > ># 1 "/usr/include/c++/4.9.0/bits/hashtable_policy.h" 1 3 ># 34 "/usr/include/c++/4.9.0/bits/hashtable_policy.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > class _Hashtable; > > > >namespace __detail >{ > > > > > > > > template<typename _Key, typename _Value, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _Traits> > struct _Hashtable_base; > > > > template<class _Iterator> > inline typename std::iterator_traits<_Iterator>::difference_type > __distance_fw(_Iterator __first, _Iterator __last, > std::input_iterator_tag) > { return 0; } > > template<class _Iterator> > inline typename std::iterator_traits<_Iterator>::difference_type > __distance_fw(_Iterator __first, _Iterator __last, > std::forward_iterator_tag) > { return std::distance(__first, __last); } > > template<class _Iterator> > inline typename std::iterator_traits<_Iterator>::difference_type > __distance_fw(_Iterator __first, _Iterator __last) > { > typedef typename std::iterator_traits<_Iterator>::iterator_category _Tag; > return __distance_fw(__first, __last, _Tag()); > } > > > template <typename _Key, typename _Hash> > struct __is_noexcept_hash : std::integral_constant<bool, > noexcept(declval<const _Hash&>()(declval<const _Key&>()))> > { }; > > struct _Identity > { > template<typename _Tp> > _Tp&& > operator()(_Tp&& __x) const > { return std::forward<_Tp>(__x); } > }; > > struct _Select1st > { > template<typename _Tp> > auto > operator()(_Tp&& __x) const > -> decltype(std::get<0>(std::forward<_Tp>(__x))) > { return std::get<0>(std::forward<_Tp>(__x)); } > }; > > template<typename _NodeAlloc> > struct _Hashtable_alloc; > > > > template<typename _NodeAlloc> > struct _ReuseOrAllocNode > { > private: > using __node_alloc_type = _NodeAlloc; > using __hashtable_alloc = _Hashtable_alloc<__node_alloc_type>; > using __value_alloc_type = typename __hashtable_alloc::__value_alloc_type; > using __value_alloc_traits = > typename __hashtable_alloc::__value_alloc_traits; > using __node_alloc_traits = > typename __hashtable_alloc::__node_alloc_traits; > using __node_type = typename __hashtable_alloc::__node_type; > > public: > _ReuseOrAllocNode(__node_type* __nodes, __hashtable_alloc& __h) > : _M_nodes(__nodes), _M_h(__h) { } > _ReuseOrAllocNode(const _ReuseOrAllocNode&) = delete; > > ~_ReuseOrAllocNode() > { _M_h._M_deallocate_nodes(_M_nodes); } > > template<typename _Arg> > __node_type* > operator()(_Arg&& __arg) const > { > if (_M_nodes) > { > __node_type* __node = _M_nodes; > _M_nodes = _M_nodes->_M_next(); > __node->_M_nxt = nullptr; > __value_alloc_type __a(_M_h._M_node_allocator()); > __value_alloc_traits::destroy(__a, __node->_M_valptr()); > try > { > __value_alloc_traits::construct(__a, __node->_M_valptr(), > std::forward<_Arg>(__arg)); > } > catch(...) > { > __node->~__node_type(); > __node_alloc_traits::deallocate(_M_h._M_node_allocator(), > __node, 1); > throw; > } > return __node; > } > return _M_h._M_allocate_node(std::forward<_Arg>(__arg)); > } > > private: > mutable __node_type* _M_nodes; > __hashtable_alloc& _M_h; > }; > > > > template<typename _NodeAlloc> > struct _AllocNode > { > private: > using __hashtable_alloc = _Hashtable_alloc<_NodeAlloc>; > using __node_type = typename __hashtable_alloc::__node_type; > > public: > _AllocNode(__hashtable_alloc& __h) > : _M_h(__h) { } > > template<typename _Arg> > __node_type* > operator()(_Arg&& __arg) const > { return _M_h._M_allocate_node(std::forward<_Arg>(__arg)); } > > private: > __hashtable_alloc& _M_h; > }; ># 211 "/usr/include/c++/4.9.0/bits/hashtable_policy.h" 3 > template<bool _Cache_hash_code, bool _Constant_iterators, bool _Unique_keys> > struct _Hashtable_traits > { > template<bool _Cond> > using __bool_constant = integral_constant<bool, _Cond>; > > using __hash_cached = __bool_constant<_Cache_hash_code>; > using __constant_iterators = __bool_constant<_Constant_iterators>; > using __unique_keys = __bool_constant<_Unique_keys>; > }; ># 230 "/usr/include/c++/4.9.0/bits/hashtable_policy.h" 3 > struct _Hash_node_base > { > _Hash_node_base* _M_nxt; > > _Hash_node_base() noexcept : _M_nxt() { } > > _Hash_node_base(_Hash_node_base* __next) noexcept : _M_nxt(__next) { } > }; > > > > > > > template<typename _Value> > struct _Hash_node_value_base : _Hash_node_base > { > typedef _Value value_type; > > __gnu_cxx::__aligned_buffer<_Value> _M_storage; > > _Value* > _M_valptr() noexcept > { return _M_storage._M_ptr(); } > > const _Value* > _M_valptr() const noexcept > { return _M_storage._M_ptr(); } > > _Value& > _M_v() noexcept > { return *_M_valptr(); } > > const _Value& > _M_v() const noexcept > { return *_M_valptr(); } > }; > > > > > template<typename _Value, bool _Cache_hash_code> > struct _Hash_node; > > > > > > > template<typename _Value> > struct _Hash_node<_Value, true> : _Hash_node_value_base<_Value> > { > std::size_t _M_hash_code; > > _Hash_node* > _M_next() const noexcept > { return static_cast<_Hash_node*>(this->_M_nxt); } > }; > > > > > > > template<typename _Value> > struct _Hash_node<_Value, false> : _Hash_node_value_base<_Value> > { > _Hash_node* > _M_next() const noexcept > { return static_cast<_Hash_node*>(this->_M_nxt); } > }; > > > template<typename _Value, bool _Cache_hash_code> > struct _Node_iterator_base > { > using __node_type = _Hash_node<_Value, _Cache_hash_code>; > > __node_type* _M_cur; > > _Node_iterator_base(__node_type* __p) noexcept > : _M_cur(__p) { } > > void > _M_incr() noexcept > { _M_cur = _M_cur->_M_next(); } > }; > > template<typename _Value, bool _Cache_hash_code> > inline bool > operator==(const _Node_iterator_base<_Value, _Cache_hash_code>& __x, > const _Node_iterator_base<_Value, _Cache_hash_code >& __y) > noexcept > { return __x._M_cur == __y._M_cur; } > > template<typename _Value, bool _Cache_hash_code> > inline bool > operator!=(const _Node_iterator_base<_Value, _Cache_hash_code>& __x, > const _Node_iterator_base<_Value, _Cache_hash_code>& __y) > noexcept > { return __x._M_cur != __y._M_cur; } > > > template<typename _Value, bool __constant_iterators, bool __cache> > struct _Node_iterator > : public _Node_iterator_base<_Value, __cache> > { > private: > using __base_type = _Node_iterator_base<_Value, __cache>; > using __node_type = typename __base_type::__node_type; > > public: > typedef _Value value_type; > typedef std::ptrdiff_t difference_type; > typedef std::forward_iterator_tag iterator_category; > > using pointer = typename std::conditional<__constant_iterators, > const _Value*, _Value*>::type; > > using reference = typename std::conditional<__constant_iterators, > const _Value&, _Value&>::type; > > _Node_iterator() noexcept > : __base_type(0) { } > > explicit > _Node_iterator(__node_type* __p) noexcept > : __base_type(__p) { } > > reference > operator*() const noexcept > { return this->_M_cur->_M_v(); } > > pointer > operator->() const noexcept > { return this->_M_cur->_M_valptr(); } > > _Node_iterator& > operator++() noexcept > { > this->_M_incr(); > return *this; > } > > _Node_iterator > operator++(int) noexcept > { > _Node_iterator __tmp(*this); > this->_M_incr(); > return __tmp; > } > }; > > > template<typename _Value, bool __constant_iterators, bool __cache> > struct _Node_const_iterator > : public _Node_iterator_base<_Value, __cache> > { > private: > using __base_type = _Node_iterator_base<_Value, __cache>; > using __node_type = typename __base_type::__node_type; > > public: > typedef _Value value_type; > typedef std::ptrdiff_t difference_type; > typedef std::forward_iterator_tag iterator_category; > > typedef const _Value* pointer; > typedef const _Value& reference; > > _Node_const_iterator() noexcept > : __base_type(0) { } > > explicit > _Node_const_iterator(__node_type* __p) noexcept > : __base_type(__p) { } > > _Node_const_iterator(const _Node_iterator<_Value, __constant_iterators, > __cache>& __x) noexcept > : __base_type(__x._M_cur) { } > > reference > operator*() const noexcept > { return this->_M_cur->_M_v(); } > > pointer > operator->() const noexcept > { return this->_M_cur->_M_valptr(); } > > _Node_const_iterator& > operator++() noexcept > { > this->_M_incr(); > return *this; > } > > _Node_const_iterator > operator++(int) noexcept > { > _Node_const_iterator __tmp(*this); > this->_M_incr(); > return __tmp; > } > }; > > > > > > > struct _Mod_range_hashing > { > typedef std::size_t first_argument_type; > typedef std::size_t second_argument_type; > typedef std::size_t result_type; > > result_type > operator()(first_argument_type __num, > second_argument_type __den) const noexcept > { return __num % __den; } > }; > > > > > > > struct _Default_ranged_hash { }; > > > > struct _Prime_rehash_policy > { > _Prime_rehash_policy(float __z = 1.0) > : _M_max_load_factor(__z), _M_next_resize(0) { } > > float > max_load_factor() const noexcept > { return _M_max_load_factor; } > > > std::size_t > _M_next_bkt(std::size_t __n) const; > > > std::size_t > _M_bkt_for_elements(std::size_t __n) const > { return __builtin_ceil(__n / (long double)_M_max_load_factor); } > > > > > > std::pair<bool, std::size_t> > _M_need_rehash(std::size_t __n_bkt, std::size_t __n_elt, > std::size_t __n_ins) const; > > typedef std::size_t _State; > > _State > _M_state() const > { return _M_next_resize; } > > void > _M_reset() noexcept > { _M_next_resize = 0; } > > void > _M_reset(_State __state) > { _M_next_resize = __state; } > > enum { _S_n_primes = sizeof(unsigned long) != 8 ? 256 : 256 + 48 }; > > static const std::size_t _S_growth_factor = 2; > > float _M_max_load_factor; > mutable std::size_t _M_next_resize; > }; ># 527 "/usr/include/c++/4.9.0/bits/hashtable_policy.h" 3 > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits, > bool _Unique_keys = _Traits::__unique_keys::value> > struct _Map_base { }; > > > template<typename _Key, typename _Pair, typename _Alloc, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > struct _Map_base<_Key, _Pair, _Alloc, _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, false> > { > using mapped_type = typename std::tuple_element<1, _Pair>::type; > }; > > > template<typename _Key, typename _Pair, typename _Alloc, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > struct _Map_base<_Key, _Pair, _Alloc, _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true> > { > private: > using __hashtable_base = __detail::_Hashtable_base<_Key, _Pair, > _Select1st, > _Equal, _H1, _H2, _Hash, > _Traits>; > > using __hashtable = _Hashtable<_Key, _Pair, _Alloc, > _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>; > > using __hash_code = typename __hashtable_base::__hash_code; > using __node_type = typename __hashtable_base::__node_type; > > public: > using key_type = typename __hashtable_base::key_type; > using iterator = typename __hashtable_base::iterator; > using mapped_type = typename std::tuple_element<1, _Pair>::type; > > mapped_type& > operator[](const key_type& __k); > > mapped_type& > operator[](key_type&& __k); > > > > mapped_type& > at(const key_type& __k); > > const mapped_type& > at(const key_type& __k) const; > }; > > template<typename _Key, typename _Pair, typename _Alloc, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > typename _Map_base<_Key, _Pair, _Alloc, _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true> > ::mapped_type& > _Map_base<_Key, _Pair, _Alloc, _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true>:: > operator[](const key_type& __k) > { > __hashtable* __h = static_cast<__hashtable*>(this); > __hash_code __code = __h->_M_hash_code(__k); > std::size_t __n = __h->_M_bucket_index(__k, __code); > __node_type* __p = __h->_M_find_node(__n, __k, __code); > > if (!__p) > { > __p = __h->_M_allocate_node(std::piecewise_construct, > std::tuple<const key_type&>(__k), > std::tuple<>()); > return __h->_M_insert_unique_node(__n, __code, __p)->second; > } > > return __p->_M_v().second; > } > > template<typename _Key, typename _Pair, typename _Alloc, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > typename _Map_base<_Key, _Pair, _Alloc, _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true> > ::mapped_type& > _Map_base<_Key, _Pair, _Alloc, _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true>:: > operator[](key_type&& __k) > { > __hashtable* __h = static_cast<__hashtable*>(this); > __hash_code __code = __h->_M_hash_code(__k); > std::size_t __n = __h->_M_bucket_index(__k, __code); > __node_type* __p = __h->_M_find_node(__n, __k, __code); > > if (!__p) > { > __p = __h->_M_allocate_node(std::piecewise_construct, > std::forward_as_tuple(std::move(__k)), > std::tuple<>()); > return __h->_M_insert_unique_node(__n, __code, __p)->second; > } > > return __p->_M_v().second; > } > > template<typename _Key, typename _Pair, typename _Alloc, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > typename _Map_base<_Key, _Pair, _Alloc, _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true> > ::mapped_type& > _Map_base<_Key, _Pair, _Alloc, _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true>:: > at(const key_type& __k) > { > __hashtable* __h = static_cast<__hashtable*>(this); > __hash_code __code = __h->_M_hash_code(__k); > std::size_t __n = __h->_M_bucket_index(__k, __code); > __node_type* __p = __h->_M_find_node(__n, __k, __code); > > if (!__p) > __throw_out_of_range(("_Map_base::at")); > return __p->_M_v().second; > } > > template<typename _Key, typename _Pair, typename _Alloc, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > const typename _Map_base<_Key, _Pair, _Alloc, _Select1st, > _Equal, _H1, _H2, _Hash, _RehashPolicy, > _Traits, true>::mapped_type& > _Map_base<_Key, _Pair, _Alloc, _Select1st, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true>:: > at(const key_type& __k) const > { > const __hashtable* __h = static_cast<const __hashtable*>(this); > __hash_code __code = __h->_M_hash_code(__k); > std::size_t __n = __h->_M_bucket_index(__k, __code); > __node_type* __p = __h->_M_find_node(__n, __k, __code); > > if (!__p) > __throw_out_of_range(("_Map_base::at")); > return __p->_M_v().second; > } > > > > > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > struct _Insert_base > { > protected: > using __hashtable = _Hashtable<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits>; > > using __hashtable_base = _Hashtable_base<_Key, _Value, _ExtractKey, > _Equal, _H1, _H2, _Hash, > _Traits>; > > using value_type = typename __hashtable_base::value_type; > using iterator = typename __hashtable_base::iterator; > using const_iterator = typename __hashtable_base::const_iterator; > using size_type = typename __hashtable_base::size_type; > > using __unique_keys = typename __hashtable_base::__unique_keys; > using __ireturn_type = typename __hashtable_base::__ireturn_type; > using __node_type = _Hash_node<_Value, _Traits::__hash_cached::value>; > using __node_alloc_type = > typename __alloctr_rebind<_Alloc, __node_type>::__type; > using __node_gen_type = _AllocNode<__node_alloc_type>; > > __hashtable& > _M_conjure_hashtable() > { return *(static_cast<__hashtable*>(this)); } > > template<typename _InputIterator, typename _NodeGetter> > void > _M_insert_range(_InputIterator __first, _InputIterator __last, > const _NodeGetter&); > > public: > __ireturn_type > insert(const value_type& __v) > { > __hashtable& __h = _M_conjure_hashtable(); > __node_gen_type __node_gen(__h); > return __h._M_insert(__v, __node_gen, __unique_keys()); > } > > iterator > insert(const_iterator __hint, const value_type& __v) > { > __hashtable& __h = _M_conjure_hashtable(); > __node_gen_type __node_gen(__h); > return __h._M_insert(__hint, __v, __node_gen, __unique_keys()); > } > > void > insert(initializer_list<value_type> __l) > { this->insert(__l.begin(), __l.end()); } > > template<typename _InputIterator> > void > insert(_InputIterator __first, _InputIterator __last) > { > __hashtable& __h = _M_conjure_hashtable(); > __node_gen_type __node_gen(__h); > return _M_insert_range(__first, __last, __node_gen); > } > }; > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > template<typename _InputIterator, typename _NodeGetter> > void > _Insert_base<_Key, _Value, _Alloc, _ExtractKey, _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits>:: > _M_insert_range(_InputIterator __first, _InputIterator __last, > const _NodeGetter& __node_gen) > { > using __rehash_type = typename __hashtable::__rehash_type; > using __rehash_state = typename __hashtable::__rehash_state; > using pair_type = std::pair<bool, std::size_t>; > > size_type __n_elt = __detail::__distance_fw(__first, __last); > > __hashtable& __h = _M_conjure_hashtable(); > __rehash_type& __rehash = __h._M_rehash_policy; > const __rehash_state& __saved_state = __rehash._M_state(); > pair_type __do_rehash = __rehash._M_need_rehash(__h._M_bucket_count, > __h._M_element_count, > __n_elt); > > if (__do_rehash.first) > __h._M_rehash(__do_rehash.second, __saved_state); > > for (; __first != __last; ++__first) > __h._M_insert(*__first, __node_gen, __unique_keys()); > } > > > > > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits, > bool _Constant_iterators = _Traits::__constant_iterators::value, > bool _Unique_keys = _Traits::__unique_keys::value> > struct _Insert; > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > struct _Insert<_Key, _Value, _Alloc, _ExtractKey, _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits, true, true> > : public _Insert_base<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits> > { > using __base_type = _Insert_base<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits>; > using value_type = typename __base_type::value_type; > using iterator = typename __base_type::iterator; > using const_iterator = typename __base_type::const_iterator; > > using __unique_keys = typename __base_type::__unique_keys; > using __hashtable = typename __base_type::__hashtable; > using __node_gen_type = typename __base_type::__node_gen_type; > > using __base_type::insert; > > std::pair<iterator, bool> > insert(value_type&& __v) > { > __hashtable& __h = this->_M_conjure_hashtable(); > __node_gen_type __node_gen(__h); > return __h._M_insert(std::move(__v), __node_gen, __unique_keys()); > } > > iterator > insert(const_iterator __hint, value_type&& __v) > { > __hashtable& __h = this->_M_conjure_hashtable(); > __node_gen_type __node_gen(__h); > return __h._M_insert(__hint, std::move(__v), __node_gen, > __unique_keys()); > } > }; > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > struct _Insert<_Key, _Value, _Alloc, _ExtractKey, _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits, true, false> > : public _Insert_base<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits> > { > using __base_type = _Insert_base<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits>; > using value_type = typename __base_type::value_type; > using iterator = typename __base_type::iterator; > using const_iterator = typename __base_type::const_iterator; > > using __unique_keys = typename __base_type::__unique_keys; > using __hashtable = typename __base_type::__hashtable; > using __node_gen_type = typename __base_type::__node_gen_type; > > using __base_type::insert; > > iterator > insert(value_type&& __v) > { > __hashtable& __h = this->_M_conjure_hashtable(); > __node_gen_type __node_gen(__h); > return __h._M_insert(std::move(__v), __node_gen, __unique_keys()); > } > > iterator > insert(const_iterator __hint, value_type&& __v) > { > __hashtable& __h = this->_M_conjure_hashtable(); > __node_gen_type __node_gen(__h); > return __h._M_insert(__hint, std::move(__v), __node_gen, > __unique_keys()); > } > }; > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits, bool _Unique_keys> > struct _Insert<_Key, _Value, _Alloc, _ExtractKey, _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits, false, _Unique_keys> > : public _Insert_base<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits> > { > using __base_type = _Insert_base<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits>; > using value_type = typename __base_type::value_type; > using iterator = typename __base_type::iterator; > using const_iterator = typename __base_type::const_iterator; > > using __unique_keys = typename __base_type::__unique_keys; > using __hashtable = typename __base_type::__hashtable; > using __ireturn_type = typename __base_type::__ireturn_type; > > using __base_type::insert; > > template<typename _Pair> > using __is_cons = std::is_constructible<value_type, _Pair&&>; > > template<typename _Pair> > using _IFcons = std::enable_if<__is_cons<_Pair>::value>; > > template<typename _Pair> > using _IFconsp = typename _IFcons<_Pair>::type; > > template<typename _Pair, typename = _IFconsp<_Pair>> > __ireturn_type > insert(_Pair&& __v) > { > __hashtable& __h = this->_M_conjure_hashtable(); > return __h._M_emplace(__unique_keys(), std::forward<_Pair>(__v)); > } > > template<typename _Pair, typename = _IFconsp<_Pair>> > iterator > insert(const_iterator __hint, _Pair&& __v) > { > __hashtable& __h = this->_M_conjure_hashtable(); > return __h._M_emplace(__hint, __unique_keys(), > std::forward<_Pair>(__v)); > } > }; > > > > > > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > struct _Rehash_base; > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _Traits> > struct _Rehash_base<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _Prime_rehash_policy, _Traits> > { > using __hashtable = _Hashtable<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, > _Prime_rehash_policy, _Traits>; > > float > max_load_factor() const noexcept > { > const __hashtable* __this = static_cast<const __hashtable*>(this); > return __this->__rehash_policy().max_load_factor(); > } > > void > max_load_factor(float __z) > { > __hashtable* __this = static_cast<__hashtable*>(this); > __this->__rehash_policy(_Prime_rehash_policy(__z)); > } > > void > reserve(std::size_t __n) > { > __hashtable* __this = static_cast<__hashtable*>(this); > __this->rehash(__builtin_ceil(__n / max_load_factor())); > } > }; > > > > > > > > template<int _Nm, typename _Tp, > bool __use_ebo = !__is_final(_Tp) && __is_empty(_Tp)> > struct _Hashtable_ebo_helper; > > > template<int _Nm, typename _Tp> > struct _Hashtable_ebo_helper<_Nm, _Tp, true> > : private _Tp > { > _Hashtable_ebo_helper() = default; > > template<typename _OtherTp> > _Hashtable_ebo_helper(_OtherTp&& __tp) > : _Tp(std::forward<_OtherTp>(__tp)) > { } > > static const _Tp& > _S_cget(const _Hashtable_ebo_helper& __eboh) > { return static_cast<const _Tp&>(__eboh); } > > static _Tp& > _S_get(_Hashtable_ebo_helper& __eboh) > { return static_cast<_Tp&>(__eboh); } > }; > > > template<int _Nm, typename _Tp> > struct _Hashtable_ebo_helper<_Nm, _Tp, false> > { > _Hashtable_ebo_helper() = default; > > template<typename _OtherTp> > _Hashtable_ebo_helper(_OtherTp&& __tp) > : _M_tp(std::forward<_OtherTp>(__tp)) > { } > > static const _Tp& > _S_cget(const _Hashtable_ebo_helper& __eboh) > { return __eboh._M_tp; } > > static _Tp& > _S_get(_Hashtable_ebo_helper& __eboh) > { return __eboh._M_tp; } > > private: > _Tp _M_tp; > }; > > > > > > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash, > bool __cache_hash_code> > struct _Local_iterator_base; ># 1054 "/usr/include/c++/4.9.0/bits/hashtable_policy.h" 3 > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash, > bool __cache_hash_code> > struct _Hash_code_base; > > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash> > struct _Hash_code_base<_Key, _Value, _ExtractKey, _H1, _H2, _Hash, false> > : private _Hashtable_ebo_helper<0, _ExtractKey>, > private _Hashtable_ebo_helper<1, _Hash> > { > private: > using __ebo_extract_key = _Hashtable_ebo_helper<0, _ExtractKey>; > using __ebo_hash = _Hashtable_ebo_helper<1, _Hash>; > > protected: > typedef void* __hash_code; > typedef _Hash_node<_Value, false> __node_type; > > > _Hash_code_base() = default; > > _Hash_code_base(const _ExtractKey& __ex, const _H1&, const _H2&, > const _Hash& __h) > : __ebo_extract_key(__ex), __ebo_hash(__h) { } > > __hash_code > _M_hash_code(const _Key& __key) const > { return 0; } > > std::size_t > _M_bucket_index(const _Key& __k, __hash_code, std::size_t __n) const > { return _M_ranged_hash()(__k, __n); } > > std::size_t > _M_bucket_index(const __node_type* __p, std::size_t __n) const > noexcept( noexcept(declval<const _Hash&>()(declval<const _Key&>(), > (std::size_t)0)) ) > { return _M_ranged_hash()(_M_extract()(__p->_M_v()), __n); } > > void > _M_store_code(__node_type*, __hash_code) const > { } > > void > _M_copy_code(__node_type*, const __node_type*) const > { } > > void > _M_swap(_Hash_code_base& __x) > { > std::swap(_M_extract(), __x._M_extract()); > std::swap(_M_ranged_hash(), __x._M_ranged_hash()); > } > > const _ExtractKey& > _M_extract() const { return __ebo_extract_key::_S_cget(*this); } > > _ExtractKey& > _M_extract() { return __ebo_extract_key::_S_get(*this); } > > const _Hash& > _M_ranged_hash() const { return __ebo_hash::_S_cget(*this); } > > _Hash& > _M_ranged_hash() { return __ebo_hash::_S_get(*this); } > }; > > > > > > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash> > struct _Hash_code_base<_Key, _Value, _ExtractKey, _H1, _H2, _Hash, true>; > > > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2> > struct _Hash_code_base<_Key, _Value, _ExtractKey, _H1, _H2, > _Default_ranged_hash, false> > : private _Hashtable_ebo_helper<0, _ExtractKey>, > private _Hashtable_ebo_helper<1, _H1>, > private _Hashtable_ebo_helper<2, _H2> > { > private: > using __ebo_extract_key = _Hashtable_ebo_helper<0, _ExtractKey>; > using __ebo_h1 = _Hashtable_ebo_helper<1, _H1>; > using __ebo_h2 = _Hashtable_ebo_helper<2, _H2>; > > > friend struct _Local_iterator_base<_Key, _Value, _ExtractKey, _H1, _H2, > _Default_ranged_hash, false>; > > public: > typedef _H1 hasher; > > hasher > hash_function() const > { return _M_h1(); } > > protected: > typedef std::size_t __hash_code; > typedef _Hash_node<_Value, false> __node_type; > > > _Hash_code_base() = default; > > _Hash_code_base(const _ExtractKey& __ex, > const _H1& __h1, const _H2& __h2, > const _Default_ranged_hash&) > : __ebo_extract_key(__ex), __ebo_h1(__h1), __ebo_h2(__h2) { } > > __hash_code > _M_hash_code(const _Key& __k) const > { return _M_h1()(__k); } > > std::size_t > _M_bucket_index(const _Key&, __hash_code __c, std::size_t __n) const > { return _M_h2()(__c, __n); } > > std::size_t > _M_bucket_index(const __node_type* __p, std::size_t __n) const > noexcept( noexcept(declval<const _H1&>()(declval<const _Key&>())) > && noexcept(declval<const _H2&>()((__hash_code)0, > (std::size_t)0)) ) > { return _M_h2()(_M_h1()(_M_extract()(__p->_M_v())), __n); } > > void > _M_store_code(__node_type*, __hash_code) const > { } > > void > _M_copy_code(__node_type*, const __node_type*) const > { } > > void > _M_swap(_Hash_code_base& __x) > { > std::swap(_M_extract(), __x._M_extract()); > std::swap(_M_h1(), __x._M_h1()); > std::swap(_M_h2(), __x._M_h2()); > } > > const _ExtractKey& > _M_extract() const { return __ebo_extract_key::_S_cget(*this); } > > _ExtractKey& > _M_extract() { return __ebo_extract_key::_S_get(*this); } > > const _H1& > _M_h1() const { return __ebo_h1::_S_cget(*this); } > > _H1& > _M_h1() { return __ebo_h1::_S_get(*this); } > > const _H2& > _M_h2() const { return __ebo_h2::_S_cget(*this); } > > _H2& > _M_h2() { return __ebo_h2::_S_get(*this); } > }; > > > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2> > struct _Hash_code_base<_Key, _Value, _ExtractKey, _H1, _H2, > _Default_ranged_hash, true> > : private _Hashtable_ebo_helper<0, _ExtractKey>, > private _Hashtable_ebo_helper<1, _H1>, > private _Hashtable_ebo_helper<2, _H2> > { > private: > > friend struct _Local_iterator_base<_Key, _Value, _ExtractKey, _H1, _H2, > _Default_ranged_hash, true>; > > using __ebo_extract_key = _Hashtable_ebo_helper<0, _ExtractKey>; > using __ebo_h1 = _Hashtable_ebo_helper<1, _H1>; > using __ebo_h2 = _Hashtable_ebo_helper<2, _H2>; > > public: > typedef _H1 hasher; > > hasher > hash_function() const > { return _M_h1(); } > > protected: > typedef std::size_t __hash_code; > typedef _Hash_node<_Value, true> __node_type; > > _Hash_code_base(const _ExtractKey& __ex, > const _H1& __h1, const _H2& __h2, > const _Default_ranged_hash&) > : __ebo_extract_key(__ex), __ebo_h1(__h1), __ebo_h2(__h2) { } > > __hash_code > _M_hash_code(const _Key& __k) const > { return _M_h1()(__k); } > > std::size_t > _M_bucket_index(const _Key&, __hash_code __c, > std::size_t __n) const > { return _M_h2()(__c, __n); } > > std::size_t > _M_bucket_index(const __node_type* __p, std::size_t __n) const > noexcept( noexcept(declval<const _H2&>()((__hash_code)0, > (std::size_t)0)) ) > { return _M_h2()(__p->_M_hash_code, __n); } > > void > _M_store_code(__node_type* __n, __hash_code __c) const > { __n->_M_hash_code = __c; } > > void > _M_copy_code(__node_type* __to, const __node_type* __from) const > { __to->_M_hash_code = __from->_M_hash_code; } > > void > _M_swap(_Hash_code_base& __x) > { > std::swap(_M_extract(), __x._M_extract()); > std::swap(_M_h1(), __x._M_h1()); > std::swap(_M_h2(), __x._M_h2()); > } > > const _ExtractKey& > _M_extract() const { return __ebo_extract_key::_S_cget(*this); } > > _ExtractKey& > _M_extract() { return __ebo_extract_key::_S_get(*this); } > > const _H1& > _M_h1() const { return __ebo_h1::_S_cget(*this); } > > _H1& > _M_h1() { return __ebo_h1::_S_get(*this); } > > const _H2& > _M_h2() const { return __ebo_h2::_S_cget(*this); } > > _H2& > _M_h2() { return __ebo_h2::_S_get(*this); } > }; > > > > > > template <typename _Key, typename _Value, typename _ExtractKey, > typename _Equal, typename _HashCodeType, > bool __cache_hash_code> > struct _Equal_helper; > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _Equal, typename _HashCodeType> > struct _Equal_helper<_Key, _Value, _ExtractKey, _Equal, _HashCodeType, true> > { > static bool > _S_equals(const _Equal& __eq, const _ExtractKey& __extract, > const _Key& __k, _HashCodeType __c, _Hash_node<_Value, true>* __n) > { return __c == __n->_M_hash_code && __eq(__k, __extract(__n->_M_v())); } > }; > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _Equal, typename _HashCodeType> > struct _Equal_helper<_Key, _Value, _ExtractKey, _Equal, _HashCodeType, false> > { > static bool > _S_equals(const _Equal& __eq, const _ExtractKey& __extract, > const _Key& __k, _HashCodeType, _Hash_node<_Value, false>* __n) > { return __eq(__k, __extract(__n->_M_v())); } > }; > > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash> > struct _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, true> > : private _Hashtable_ebo_helper<0, _H2> > { > protected: > using __base_type = _Hashtable_ebo_helper<0, _H2>; > using __hash_code_base = _Hash_code_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, true>; > > _Local_iterator_base() = default; > _Local_iterator_base(const __hash_code_base& __base, > _Hash_node<_Value, true>* __p, > std::size_t __bkt, std::size_t __bkt_count) > : __base_type(__base._M_h2()), > _M_cur(__p), _M_bucket(__bkt), _M_bucket_count(__bkt_count) { } > > void > _M_incr() > { > _M_cur = _M_cur->_M_next(); > if (_M_cur) > { > std::size_t __bkt > = __base_type::_S_get(*this)(_M_cur->_M_hash_code, > _M_bucket_count); > if (__bkt != _M_bucket) > _M_cur = nullptr; > } > } > > _Hash_node<_Value, true>* _M_cur; > std::size_t _M_bucket; > std::size_t _M_bucket_count; > > public: > const void* > _M_curr() const { return _M_cur; } > > std::size_t > _M_get_bucket() const { return _M_bucket; } > }; > > > > > > template<typename _Tp, bool _IsEmpty = std::is_empty<_Tp>::value> > struct _Hash_code_storage > { > __gnu_cxx::__aligned_buffer<_Tp> _M_storage; > > _Tp* > _M_h() { return _M_storage._M_ptr(); } > > const _Tp* > _M_h() const { return _M_storage._M_ptr(); } > }; > > > template<typename _Tp> > struct _Hash_code_storage<_Tp, true> > { > static_assert( std::is_empty<_Tp>::value, "Type must be empty" ); > > > > _Tp* > _M_h() { return reinterpret_cast<_Tp*>(this); } > > const _Tp* > _M_h() const { return reinterpret_cast<const _Tp*>(this); } > }; > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash> > using __hash_code_for_local_iter > = _Hash_code_storage<_Hash_code_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, false>>; > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash> > struct _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, false> > : __hash_code_for_local_iter<_Key, _Value, _ExtractKey, _H1, _H2, _Hash> > { > protected: > using __hash_code_base = _Hash_code_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, false>; > > _Local_iterator_base() : _M_bucket_count(-1) { } > > _Local_iterator_base(const __hash_code_base& __base, > _Hash_node<_Value, false>* __p, > std::size_t __bkt, std::size_t __bkt_count) > : _M_cur(__p), _M_bucket(__bkt), _M_bucket_count(__bkt_count) > { _M_init(__base); } > > ~_Local_iterator_base() > { > if (_M_bucket_count != -1) > _M_destroy(); > } > > _Local_iterator_base(const _Local_iterator_base& __iter) > : _M_cur(__iter._M_cur), _M_bucket(__iter._M_bucket), > _M_bucket_count(__iter._M_bucket_count) > { > if (_M_bucket_count != -1) > _M_init(*__iter._M_h()); > } > > _Local_iterator_base& > operator=(const _Local_iterator_base& __iter) > { > if (_M_bucket_count != -1) > _M_destroy(); > _M_cur = __iter._M_cur; > _M_bucket = __iter._M_bucket; > _M_bucket_count = __iter._M_bucket_count; > if (_M_bucket_count != -1) > _M_init(*__iter._M_h()); > return *this; > } > > void > _M_incr() > { > _M_cur = _M_cur->_M_next(); > if (_M_cur) > { > std::size_t __bkt = this->_M_h()->_M_bucket_index(_M_cur, > _M_bucket_count); > if (__bkt != _M_bucket) > _M_cur = nullptr; > } > } > > _Hash_node<_Value, false>* _M_cur; > std::size_t _M_bucket; > std::size_t _M_bucket_count; > > void > _M_init(const __hash_code_base& __base) > { ::new(this->_M_h()) __hash_code_base(__base); } > > void > _M_destroy() { this->_M_h()->~__hash_code_base(); } > > public: > const void* > _M_curr() const { return _M_cur; } > > std::size_t > _M_get_bucket() const { return _M_bucket; } > }; > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash, bool __cache> > inline bool > operator==(const _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, __cache>& __x, > const _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, __cache>& __y) > { return __x._M_curr() == __y._M_curr(); } > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash, bool __cache> > inline bool > operator!=(const _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, __cache>& __x, > const _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, __cache>& __y) > { return __x._M_curr() != __y._M_curr(); } > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash, > bool __constant_iterators, bool __cache> > struct _Local_iterator > : public _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, __cache> > { > private: > using __base_type = _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, __cache>; > using __hash_code_base = typename __base_type::__hash_code_base; > public: > typedef _Value value_type; > typedef typename std::conditional<__constant_iterators, > const _Value*, _Value*>::type > pointer; > typedef typename std::conditional<__constant_iterators, > const _Value&, _Value&>::type > reference; > typedef std::ptrdiff_t difference_type; > typedef std::forward_iterator_tag iterator_category; > > _Local_iterator() = default; > > _Local_iterator(const __hash_code_base& __base, > _Hash_node<_Value, __cache>* __p, > std::size_t __bkt, std::size_t __bkt_count) > : __base_type(__base, __p, __bkt, __bkt_count) > { } > > reference > operator*() const > { return this->_M_cur->_M_v(); } > > pointer > operator->() const > { return this->_M_cur->_M_valptr(); } > > _Local_iterator& > operator++() > { > this->_M_incr(); > return *this; > } > > _Local_iterator > operator++(int) > { > _Local_iterator __tmp(*this); > this->_M_incr(); > return __tmp; > } > }; > > > template<typename _Key, typename _Value, typename _ExtractKey, > typename _H1, typename _H2, typename _Hash, > bool __constant_iterators, bool __cache> > struct _Local_const_iterator > : public _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, __cache> > { > private: > using __base_type = _Local_iterator_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, __cache>; > using __hash_code_base = typename __base_type::__hash_code_base; > > public: > typedef _Value value_type; > typedef const _Value* pointer; > typedef const _Value& reference; > typedef std::ptrdiff_t difference_type; > typedef std::forward_iterator_tag iterator_category; > > _Local_const_iterator() = default; > > _Local_const_iterator(const __hash_code_base& __base, > _Hash_node<_Value, __cache>* __p, > std::size_t __bkt, std::size_t __bkt_count) > : __base_type(__base, __p, __bkt, __bkt_count) > { } > > _Local_const_iterator(const _Local_iterator<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, > __constant_iterators, > __cache>& __x) > : __base_type(__x) > { } > > reference > operator*() const > { return this->_M_cur->_M_v(); } > > pointer > operator->() const > { return this->_M_cur->_M_valptr(); } > > _Local_const_iterator& > operator++() > { > this->_M_incr(); > return *this; > } > > _Local_const_iterator > operator++(int) > { > _Local_const_iterator __tmp(*this); > this->_M_incr(); > return __tmp; > } > }; ># 1643 "/usr/include/c++/4.9.0/bits/hashtable_policy.h" 3 > template<typename _Key, typename _Value, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _Traits> > struct _Hashtable_base > : public _Hash_code_base<_Key, _Value, _ExtractKey, _H1, _H2, _Hash, > _Traits::__hash_cached::value>, > private _Hashtable_ebo_helper<0, _Equal> > { > public: > typedef _Key key_type; > typedef _Value value_type; > typedef _Equal key_equal; > typedef std::size_t size_type; > typedef std::ptrdiff_t difference_type; > > using __traits_type = _Traits; > using __hash_cached = typename __traits_type::__hash_cached; > using __constant_iterators = typename __traits_type::__constant_iterators; > using __unique_keys = typename __traits_type::__unique_keys; > > using __hash_code_base = _Hash_code_base<_Key, _Value, _ExtractKey, > _H1, _H2, _Hash, > __hash_cached::value>; > > using __hash_code = typename __hash_code_base::__hash_code; > using __node_type = typename __hash_code_base::__node_type; > > using iterator = __detail::_Node_iterator<value_type, > __constant_iterators::value, > __hash_cached::value>; > > using const_iterator = __detail::_Node_const_iterator<value_type, > __constant_iterators::value, > __hash_cached::value>; > > using local_iterator = __detail::_Local_iterator<key_type, value_type, > _ExtractKey, _H1, _H2, _Hash, > __constant_iterators::value, > __hash_cached::value>; > > using const_local_iterator = __detail::_Local_const_iterator<key_type, > value_type, > _ExtractKey, _H1, _H2, _Hash, > __constant_iterators::value, > __hash_cached::value>; > > using __ireturn_type = typename std::conditional<__unique_keys::value, > std::pair<iterator, bool>, > iterator>::type; > private: > using _EqualEBO = _Hashtable_ebo_helper<0, _Equal>; > using _EqualHelper = _Equal_helper<_Key, _Value, _ExtractKey, _Equal, > __hash_code, __hash_cached::value>; > > protected: > _Hashtable_base(const _ExtractKey& __ex, const _H1& __h1, const _H2& __h2, > const _Hash& __hash, const _Equal& __eq) > : __hash_code_base(__ex, __h1, __h2, __hash), _EqualEBO(__eq) > { } > > bool > _M_equals(const _Key& __k, __hash_code __c, __node_type* __n) const > { > return _EqualHelper::_S_equals(_M_eq(), this->_M_extract(), > __k, __c, __n); > } > > void > _M_swap(_Hashtable_base& __x) > { > __hash_code_base::_M_swap(__x); > std::swap(_M_eq(), __x._M_eq()); > } > > const _Equal& > _M_eq() const { return _EqualEBO::_S_cget(*this); } > > _Equal& > _M_eq() { return _EqualEBO::_S_get(*this); } > }; > > > > > > > struct _Equality_base > { > protected: > template<typename _Uiterator> > static bool > _S_is_permutation(_Uiterator, _Uiterator, _Uiterator); > }; > > > template<typename _Uiterator> > bool > _Equality_base:: > _S_is_permutation(_Uiterator __first1, _Uiterator __last1, > _Uiterator __first2) > { > for (; __first1 != __last1; ++__first1, ++__first2) > if (!(*__first1 == *__first2)) > break; > > if (__first1 == __last1) > return true; > > _Uiterator __last2 = __first2; > std::advance(__last2, std::distance(__first1, __last1)); > > for (_Uiterator __it1 = __first1; __it1 != __last1; ++__it1) > { > _Uiterator __tmp = __first1; > while (__tmp != __it1 && !bool(*__tmp == *__it1)) > ++__tmp; > > > if (__tmp != __it1) > continue; > > std::ptrdiff_t __n2 = 0; > for (__tmp = __first2; __tmp != __last2; ++__tmp) > if (*__tmp == *__it1) > ++__n2; > > if (!__n2) > return false; > > std::ptrdiff_t __n1 = 0; > for (__tmp = __it1; __tmp != __last1; ++__tmp) > if (*__tmp == *__it1) > ++__n1; > > if (__n1 != __n2) > return false; > } > return true; > } ># 1791 "/usr/include/c++/4.9.0/bits/hashtable_policy.h" 3 > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits, > bool _Unique_keys = _Traits::__unique_keys::value> > struct _Equality; > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > struct _Equality<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true> > { > using __hashtable = _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>; > > bool > _M_equal(const __hashtable&) const; > }; > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > bool > _Equality<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, true>:: > _M_equal(const __hashtable& __other) const > { > const __hashtable* __this = static_cast<const __hashtable*>(this); > > if (__this->size() != __other.size()) > return false; > > for (auto __itx = __this->begin(); __itx != __this->end(); ++__itx) > { > const auto __ity = __other.find(_ExtractKey()(*__itx)); > if (__ity == __other.end() || !bool(*__ity == *__itx)) > return false; > } > return true; > } > > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > struct _Equality<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, false> > : public _Equality_base > { > using __hashtable = _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>; > > bool > _M_equal(const __hashtable&) const; > }; > > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > bool > _Equality<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits, false>:: > _M_equal(const __hashtable& __other) const > { > const __hashtable* __this = static_cast<const __hashtable*>(this); > > if (__this->size() != __other.size()) > return false; > > for (auto __itx = __this->begin(); __itx != __this->end();) > { > const auto __xrange = __this->equal_range(_ExtractKey()(*__itx)); > const auto __yrange = __other.equal_range(_ExtractKey()(*__itx)); > > if (std::distance(__xrange.first, __xrange.second) > != std::distance(__yrange.first, __yrange.second)) > return false; > > if (!_S_is_permutation(__xrange.first, __xrange.second, > __yrange.first)) > return false; > > __itx = __xrange.second; > } > return true; > } > > > > > > template<typename _NodeAlloc> > struct _Hashtable_alloc : private _Hashtable_ebo_helper<0, _NodeAlloc> > { > private: > using __ebo_node_alloc = _Hashtable_ebo_helper<0, _NodeAlloc>; > public: > using __node_type = typename _NodeAlloc::value_type; > using __node_alloc_type = _NodeAlloc; > > using __node_alloc_traits = __gnu_cxx::__alloc_traits<__node_alloc_type>; > > using __value_type = typename __node_type::value_type; > using __value_alloc_type = > typename __alloctr_rebind<__node_alloc_type, __value_type>::__type; > using __value_alloc_traits = std::allocator_traits<__value_alloc_type>; > > using __node_base = __detail::_Hash_node_base; > using __bucket_type = __node_base*; > using __bucket_alloc_type = > typename __alloctr_rebind<__node_alloc_type, __bucket_type>::__type; > using __bucket_alloc_traits = std::allocator_traits<__bucket_alloc_type>; > > _Hashtable_alloc(const _Hashtable_alloc&) = default; > _Hashtable_alloc(_Hashtable_alloc&&) = default; > > template<typename _Alloc> > _Hashtable_alloc(_Alloc&& __a) > : __ebo_node_alloc(std::forward<_Alloc>(__a)) > { } > > __node_alloc_type& > _M_node_allocator() > { return __ebo_node_alloc::_S_get(*this); } > > const __node_alloc_type& > _M_node_allocator() const > { return __ebo_node_alloc::_S_cget(*this); } > > template<typename... _Args> > __node_type* > _M_allocate_node(_Args&&... __args); > > void > _M_deallocate_node(__node_type* __n); > > > void > _M_deallocate_nodes(__node_type* __n); > > __bucket_type* > _M_allocate_buckets(std::size_t __n); > > void > _M_deallocate_buckets(__bucket_type*, std::size_t __n); > }; > > > > template<typename _NodeAlloc> > template<typename... _Args> > typename _Hashtable_alloc<_NodeAlloc>::__node_type* > _Hashtable_alloc<_NodeAlloc>::_M_allocate_node(_Args&&... __args) > { > auto __nptr = __node_alloc_traits::allocate(_M_node_allocator(), 1); > __node_type* __n = std::__addressof(*__nptr); > try > { > __value_alloc_type __a(_M_node_allocator()); > ::new ((void*)__n) __node_type; > __value_alloc_traits::construct(__a, __n->_M_valptr(), > std::forward<_Args>(__args)...); > return __n; > } > catch(...) > { > __node_alloc_traits::deallocate(_M_node_allocator(), __nptr, 1); > throw; > } > } > > template<typename _NodeAlloc> > void > _Hashtable_alloc<_NodeAlloc>::_M_deallocate_node(__node_type* __n) > { > typedef typename __node_alloc_traits::pointer _Ptr; > auto __ptr = std::pointer_traits<_Ptr>::pointer_to(*__n); > __value_alloc_type __a(_M_node_allocator()); > __value_alloc_traits::destroy(__a, __n->_M_valptr()); > __n->~__node_type(); > __node_alloc_traits::deallocate(_M_node_allocator(), __ptr, 1); > } > > template<typename _NodeAlloc> > void > _Hashtable_alloc<_NodeAlloc>::_M_deallocate_nodes(__node_type* __n) > { > while (__n) > { > __node_type* __tmp = __n; > __n = __n->_M_next(); > _M_deallocate_node(__tmp); > } > } > > template<typename _NodeAlloc> > typename _Hashtable_alloc<_NodeAlloc>::__bucket_type* > _Hashtable_alloc<_NodeAlloc>::_M_allocate_buckets(std::size_t __n) > { > __bucket_alloc_type __alloc(_M_node_allocator()); > > auto __ptr = __bucket_alloc_traits::allocate(__alloc, __n); > __bucket_type* __p = std::__addressof(*__ptr); > __builtin_memset(__p, 0, __n * sizeof(__bucket_type)); > return __p; > } > > template<typename _NodeAlloc> > void > _Hashtable_alloc<_NodeAlloc>::_M_deallocate_buckets(__bucket_type* __bkts, > std::size_t __n) > { > typedef typename __bucket_alloc_traits::pointer _Ptr; > auto __ptr = std::pointer_traits<_Ptr>::pointer_to(*__bkts); > __bucket_alloc_type __alloc(_M_node_allocator()); > __bucket_alloc_traits::deallocate(__alloc, __ptr, __n); > } > > > >} >} ># 36 "/usr/include/c++/4.9.0/bits/hashtable.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Tp, typename _Hash> > using __cache_default > = __not_<__and_< > __is_fast_hash<_Hash>, > > __detail::__is_noexcept_hash<_Tp, _Hash>>>; ># 166 "/usr/include/c++/4.9.0/bits/hashtable.h" 3 > template<typename _Key, typename _Value, typename _Alloc, > typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, > typename _RehashPolicy, typename _Traits> > class _Hashtable > : public __detail::_Hashtable_base<_Key, _Value, _ExtractKey, _Equal, > _H1, _H2, _Hash, _Traits>, > public __detail::_Map_base<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>, > public __detail::_Insert<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>, > public __detail::_Rehash_base<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>, > public __detail::_Equality<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>, > private __detail::_Hashtable_alloc< > typename __alloctr_rebind<_Alloc, > __detail::_Hash_node<_Value, > _Traits::__hash_cached::value> >::__type> > { > using __traits_type = _Traits; > using __hash_cached = typename __traits_type::__hash_cached; > using __node_type = __detail::_Hash_node<_Value, __hash_cached::value>; > using __node_alloc_type = > typename __alloctr_rebind<_Alloc, __node_type>::__type; > > using __hashtable_alloc = __detail::_Hashtable_alloc<__node_alloc_type>; > > using __value_alloc_traits = > typename __hashtable_alloc::__value_alloc_traits; > using __node_alloc_traits = > typename __hashtable_alloc::__node_alloc_traits; > using __node_base = typename __hashtable_alloc::__node_base; > using __bucket_type = typename __hashtable_alloc::__bucket_type; > > public: > typedef _Key key_type; > typedef _Value value_type; > typedef _Alloc allocator_type; > typedef _Equal key_equal; > > > > typedef typename __value_alloc_traits::pointer pointer; > typedef typename __value_alloc_traits::const_pointer const_pointer; > typedef value_type& reference; > typedef const value_type& const_reference; > > private: > using __rehash_type = _RehashPolicy; > using __rehash_state = typename __rehash_type::_State; > > using __constant_iterators = typename __traits_type::__constant_iterators; > using __unique_keys = typename __traits_type::__unique_keys; > > using __key_extract = typename std::conditional< > __constant_iterators::value, > __detail::_Identity, > __detail::_Select1st>::type; > > using __hashtable_base = __detail:: > _Hashtable_base<_Key, _Value, _ExtractKey, > _Equal, _H1, _H2, _Hash, _Traits>; > > using __hash_code_base = typename __hashtable_base::__hash_code_base; > using __hash_code = typename __hashtable_base::__hash_code; > using __ireturn_type = typename __hashtable_base::__ireturn_type; > > using __map_base = __detail::_Map_base<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits>; > > using __rehash_base = __detail::_Rehash_base<_Key, _Value, _Alloc, > _ExtractKey, _Equal, > _H1, _H2, _Hash, > _RehashPolicy, _Traits>; > > using __eq_base = __detail::_Equality<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, > _RehashPolicy, _Traits>; > > using __reuse_or_alloc_node_type = > __detail::_ReuseOrAllocNode<__node_alloc_type>; > > > template<typename _Cond> > using __if_hash_cached = __or_<__not_<__hash_cached>, _Cond>; > > template<typename _Cond> > using __if_hash_not_cached = __or_<__hash_cached, _Cond>; > > > > > > struct __hash_code_base_access : __hash_code_base > { using __hash_code_base::_M_bucket_index; }; > > > > static_assert(noexcept(declval<const __hash_code_base_access&>() > ._M_bucket_index((const __node_type*)nullptr, > (std::size_t)0)), > "Cache the hash code or qualify your functors involved" > " in hash code and bucket index computation with noexcept"); > > > > > > > static_assert(__if_hash_cached<is_default_constructible<_H2>>::value, > "Functor used to map hash code to bucket index" > " must be default constructible"); > > template<typename _Keya, typename _Valuea, typename _Alloca, > typename _ExtractKeya, typename _Equala, > typename _H1a, typename _H2a, typename _Hasha, > typename _RehashPolicya, typename _Traitsa, > bool _Unique_keysa> > friend struct __detail::_Map_base; > > template<typename _Keya, typename _Valuea, typename _Alloca, > typename _ExtractKeya, typename _Equala, > typename _H1a, typename _H2a, typename _Hasha, > typename _RehashPolicya, typename _Traitsa> > friend struct __detail::_Insert_base; > > template<typename _Keya, typename _Valuea, typename _Alloca, > typename _ExtractKeya, typename _Equala, > typename _H1a, typename _H2a, typename _Hasha, > typename _RehashPolicya, typename _Traitsa, > bool _Constant_iteratorsa, bool _Unique_keysa> > friend struct __detail::_Insert; > > public: > using size_type = typename __hashtable_base::size_type; > using difference_type = typename __hashtable_base::difference_type; > > using iterator = typename __hashtable_base::iterator; > using const_iterator = typename __hashtable_base::const_iterator; > > using local_iterator = typename __hashtable_base::local_iterator; > using const_local_iterator = typename __hashtable_base:: > const_local_iterator; > > private: > __bucket_type* _M_buckets; > size_type _M_bucket_count; > __node_base _M_before_begin; > size_type _M_element_count; > _RehashPolicy _M_rehash_policy; > > __hashtable_alloc& > _M_base_alloc() { return *this; } > > using __hashtable_alloc::_M_deallocate_buckets; > > void > _M_deallocate_buckets() > { this->_M_deallocate_buckets(_M_buckets, _M_bucket_count); } > > > > __node_type* > _M_bucket_begin(size_type __bkt) const; > > __node_type* > _M_begin() const > { return static_cast<__node_type*>(_M_before_begin._M_nxt); } > > template<typename _NodeGenerator> > void > _M_assign(const _Hashtable&, const _NodeGenerator&); > > void > _M_move_assign(_Hashtable&&, std::true_type); > > void > _M_move_assign(_Hashtable&&, std::false_type); > > void > _M_reset() noexcept; > > public: > > _Hashtable(size_type __bucket_hint, > const _H1&, const _H2&, const _Hash&, > const _Equal&, const _ExtractKey&, > const allocator_type&); > > template<typename _InputIterator> > _Hashtable(_InputIterator __first, _InputIterator __last, > size_type __bucket_hint, > const _H1&, const _H2&, const _Hash&, > const _Equal&, const _ExtractKey&, > const allocator_type&); > > _Hashtable(const _Hashtable&); > > _Hashtable(_Hashtable&&) noexcept; > > _Hashtable(const _Hashtable&, const allocator_type&); > > _Hashtable(_Hashtable&&, const allocator_type&); > > > explicit > _Hashtable(const allocator_type& __a) > : _Hashtable(10, _H1(), _H2(), _Hash(), key_equal(), > __key_extract(), __a) > { } > > explicit > _Hashtable(size_type __n = 10, > const _H1& __hf = _H1(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _Hashtable(__n, __hf, _H2(), _Hash(), __eql, > __key_extract(), __a) > { } > > template<typename _InputIterator> > _Hashtable(_InputIterator __f, _InputIterator __l, > size_type __n = 0, > const _H1& __hf = _H1(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _Hashtable(__f, __l, __n, __hf, _H2(), _Hash(), __eql, > __key_extract(), __a) > { } > > _Hashtable(initializer_list<value_type> __l, > size_type __n = 0, > const _H1& __hf = _H1(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _Hashtable(__l.begin(), __l.end(), __n, __hf, _H2(), _Hash(), __eql, > __key_extract(), __a) > { } > > _Hashtable& > operator=(const _Hashtable& __ht); > > _Hashtable& > operator=(_Hashtable&& __ht) > noexcept(__node_alloc_traits::_S_nothrow_move()) > { > constexpr bool __move_storage = > __node_alloc_traits::_S_propagate_on_move_assign() > || __node_alloc_traits::_S_always_equal(); > _M_move_assign(std::move(__ht), > integral_constant<bool, __move_storage>()); > return *this; > } > > _Hashtable& > operator=(initializer_list<value_type> __l) > { > __reuse_or_alloc_node_type __roan(_M_begin(), *this); > _M_before_begin._M_nxt = nullptr; > clear(); > this->_M_insert_range(__l.begin(), __l.end(), __roan); > return *this; > } > > ~_Hashtable() noexcept; > > void > swap(_Hashtable&) > noexcept(__node_alloc_traits::_S_nothrow_swap()); > > > iterator > begin() noexcept > { return iterator(_M_begin()); } > > const_iterator > begin() const noexcept > { return const_iterator(_M_begin()); } > > iterator > end() noexcept > { return iterator(nullptr); } > > const_iterator > end() const noexcept > { return const_iterator(nullptr); } > > const_iterator > cbegin() const noexcept > { return const_iterator(_M_begin()); } > > const_iterator > cend() const noexcept > { return const_iterator(nullptr); } > > size_type > size() const noexcept > { return _M_element_count; } > > bool > empty() const noexcept > { return size() == 0; } > > allocator_type > get_allocator() const noexcept > { return allocator_type(this->_M_node_allocator()); } > > size_type > max_size() const noexcept > { return __node_alloc_traits::max_size(this->_M_node_allocator()); } > > > key_equal > key_eq() const > { return this->_M_eq(); } > > > > > size_type > bucket_count() const noexcept > { return _M_bucket_count; } > > size_type > max_bucket_count() const noexcept > { return max_size(); } > > size_type > bucket_size(size_type __n) const > { return std::distance(begin(__n), end(__n)); } > > size_type > bucket(const key_type& __k) const > { return _M_bucket_index(__k, this->_M_hash_code(__k)); } > > local_iterator > begin(size_type __n) > { > return local_iterator(*this, _M_bucket_begin(__n), > __n, _M_bucket_count); > } > > local_iterator > end(size_type __n) > { return local_iterator(*this, nullptr, __n, _M_bucket_count); } > > const_local_iterator > begin(size_type __n) const > { > return const_local_iterator(*this, _M_bucket_begin(__n), > __n, _M_bucket_count); > } > > const_local_iterator > end(size_type __n) const > { return const_local_iterator(*this, nullptr, __n, _M_bucket_count); } > > > const_local_iterator > cbegin(size_type __n) const > { > return const_local_iterator(*this, _M_bucket_begin(__n), > __n, _M_bucket_count); > } > > const_local_iterator > cend(size_type __n) const > { return const_local_iterator(*this, nullptr, __n, _M_bucket_count); } > > float > load_factor() const noexcept > { > return static_cast<float>(size()) / static_cast<float>(bucket_count()); > } > > > > > > > const _RehashPolicy& > __rehash_policy() const > { return _M_rehash_policy; } > > void > __rehash_policy(const _RehashPolicy&); > > > iterator > find(const key_type& __k); > > const_iterator > find(const key_type& __k) const; > > size_type > count(const key_type& __k) const; > > std::pair<iterator, iterator> > equal_range(const key_type& __k); > > std::pair<const_iterator, const_iterator> > equal_range(const key_type& __k) const; > > protected: > > size_type > _M_bucket_index(__node_type* __n) const noexcept > { return __hash_code_base::_M_bucket_index(__n, _M_bucket_count); } > > size_type > _M_bucket_index(const key_type& __k, __hash_code __c) const > { return __hash_code_base::_M_bucket_index(__k, __c, _M_bucket_count); } > > > > __node_base* > _M_find_before_node(size_type, const key_type&, __hash_code) const; > > __node_type* > _M_find_node(size_type __bkt, const key_type& __key, > __hash_code __c) const > { > __node_base* __before_n = _M_find_before_node(__bkt, __key, __c); > if (__before_n) > return static_cast<__node_type*>(__before_n->_M_nxt); > return nullptr; > } > > > void > _M_insert_bucket_begin(size_type, __node_type*); > > > void > _M_remove_bucket_begin(size_type __bkt, __node_type* __next_n, > size_type __next_bkt); > > > __node_base* > _M_get_previous_node(size_type __bkt, __node_base* __n); > > > > > iterator > _M_insert_unique_node(size_type __bkt, __hash_code __code, > __node_type* __n); > > > > iterator > _M_insert_multi_node(__node_type* __hint, > __hash_code __code, __node_type* __n); > > template<typename... _Args> > std::pair<iterator, bool> > _M_emplace(std::true_type, _Args&&... __args); > > template<typename... _Args> > iterator > _M_emplace(std::false_type __uk, _Args&&... __args) > { return _M_emplace(cend(), __uk, std::forward<_Args>(__args)...); } > > > template<typename... _Args> > iterator > _M_emplace(const_iterator, std::true_type __uk, _Args&&... __args) > { return _M_emplace(__uk, std::forward<_Args>(__args)...).first; } > > template<typename... _Args> > iterator > _M_emplace(const_iterator, std::false_type, _Args&&... __args); > > template<typename _Arg, typename _NodeGenerator> > std::pair<iterator, bool> > _M_insert(_Arg&&, const _NodeGenerator&, std::true_type); > > template<typename _Arg, typename _NodeGenerator> > iterator > _M_insert(_Arg&& __arg, const _NodeGenerator& __node_gen, > std::false_type __uk) > { > return _M_insert(cend(), std::forward<_Arg>(__arg), __node_gen, > __uk); > } > > > template<typename _Arg, typename _NodeGenerator> > iterator > _M_insert(const_iterator, _Arg&& __arg, const _NodeGenerator& __node_gen, > std::true_type __uk) > { > return > _M_insert(std::forward<_Arg>(__arg), __node_gen, __uk).first; > } > > > template<typename _Arg, typename _NodeGenerator> > iterator > _M_insert(const_iterator, _Arg&&, const _NodeGenerator&, std::false_type); > > size_type > _M_erase(std::true_type, const key_type&); > > size_type > _M_erase(std::false_type, const key_type&); > > iterator > _M_erase(size_type __bkt, __node_base* __prev_n, __node_type* __n); > > public: > > template<typename... _Args> > __ireturn_type > emplace(_Args&&... __args) > { return _M_emplace(__unique_keys(), std::forward<_Args>(__args)...); } > > template<typename... _Args> > iterator > emplace_hint(const_iterator __hint, _Args&&... __args) > { > return _M_emplace(__hint, __unique_keys(), > std::forward<_Args>(__args)...); > } > > > > > iterator > erase(const_iterator); > > > iterator > erase(iterator __it) > { return erase(const_iterator(__it)); } > > size_type > erase(const key_type& __k) > { > if (__builtin_expect(_M_bucket_count == 0, false)) > return 0; > return _M_erase(__unique_keys(), __k); > } > > iterator > erase(const_iterator, const_iterator); > > void > clear() noexcept; > > > void rehash(size_type __n); > > > > > private: > > void _M_rehash_aux(size_type __n, std::true_type); > > > void _M_rehash_aux(size_type __n, std::false_type); > > > > void _M_rehash(size_type __n, const __rehash_state& __state); > }; > > > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, _RehashPolicy, > _Traits>::__node_type* > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_bucket_begin(size_type __bkt) const > { > __node_base* __n = _M_buckets[__bkt]; > return __n ? static_cast<__node_type*>(__n->_M_nxt) : nullptr; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _Hashtable(size_type __bucket_hint, > const _H1& __h1, const _H2& __h2, const _Hash& __h, > const _Equal& __eq, const _ExtractKey& __exk, > const allocator_type& __a) > : __hashtable_base(__exk, __h1, __h2, __h, __eq), > __map_base(), > __rehash_base(), > __hashtable_alloc(__node_alloc_type(__a)), > _M_element_count(0), > _M_rehash_policy() > { > _M_bucket_count = _M_rehash_policy._M_next_bkt(__bucket_hint); > _M_buckets = this->_M_allocate_buckets(_M_bucket_count); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > template<typename _InputIterator> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _Hashtable(_InputIterator __f, _InputIterator __l, > size_type __bucket_hint, > const _H1& __h1, const _H2& __h2, const _Hash& __h, > const _Equal& __eq, const _ExtractKey& __exk, > const allocator_type& __a) > : __hashtable_base(__exk, __h1, __h2, __h, __eq), > __map_base(), > __rehash_base(), > __hashtable_alloc(__node_alloc_type(__a)), > _M_element_count(0), > _M_rehash_policy() > { > auto __nb_elems = __detail::__distance_fw(__f, __l); > _M_bucket_count = > _M_rehash_policy._M_next_bkt( > std::max(_M_rehash_policy._M_bkt_for_elements(__nb_elems), > __bucket_hint)); > > _M_buckets = this->_M_allocate_buckets(_M_bucket_count); > try > { > for (; __f != __l; ++__f) > this->insert(*__f); > } > catch(...) > { > clear(); > _M_deallocate_buckets(); > throw; > } > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>& > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>::operator=( > const _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>& __ht) > { > if (&__ht == this) > return *this; > > if (__node_alloc_traits::_S_propagate_on_copy_assign()) > { > auto& __this_alloc = this->_M_node_allocator(); > auto& __that_alloc = __ht._M_node_allocator(); > if (!__node_alloc_traits::_S_always_equal() > && __this_alloc != __that_alloc) > { > > this->_M_deallocate_nodes(_M_begin()); > if (__builtin_expect(_M_bucket_count != 0, true)) > _M_deallocate_buckets(); > _M_reset(); > std::__alloc_on_copy(__this_alloc, __that_alloc); > __hashtable_base::operator=(__ht); > _M_bucket_count = __ht._M_bucket_count; > _M_element_count = __ht._M_element_count; > _M_rehash_policy = __ht._M_rehash_policy; > try > { > _M_assign(__ht, > [this](const __node_type* __n) > { return this->_M_allocate_node(__n->_M_v()); }); > } > catch(...) > { > > > _M_reset(); > throw; > } > return *this; > } > std::__alloc_on_copy(__this_alloc, __that_alloc); > } > > > __bucket_type* __former_buckets = nullptr; > std::size_t __former_bucket_count = _M_bucket_count; > const __rehash_state& __former_state = _M_rehash_policy._M_state(); > > if (_M_bucket_count != __ht._M_bucket_count) > { > __former_buckets = _M_buckets; > _M_buckets = this->_M_allocate_buckets(__ht._M_bucket_count); > _M_bucket_count = __ht._M_bucket_count; > } > else > __builtin_memset(_M_buckets, 0, > _M_bucket_count * sizeof(__bucket_type)); > > try > { > __hashtable_base::operator=(__ht); > _M_element_count = __ht._M_element_count; > _M_rehash_policy = __ht._M_rehash_policy; > __reuse_or_alloc_node_type __roan(_M_begin(), *this); > _M_before_begin._M_nxt = nullptr; > _M_assign(__ht, > [&__roan](const __node_type* __n) > { return __roan(__n->_M_v()); }); > if (__former_buckets) > this->_M_deallocate_buckets(__former_buckets, > __former_bucket_count); > } > catch(...) > { > if (__former_buckets) > { > > _M_deallocate_buckets(); > _M_rehash_policy._M_reset(__former_state); > _M_buckets = __former_buckets; > _M_bucket_count = __former_bucket_count; > } > __builtin_memset(_M_buckets, 0, > _M_bucket_count * sizeof(__bucket_type)); > throw; > } > return *this; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > template<typename _NodeGenerator> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_assign(const _Hashtable& __ht, const _NodeGenerator& __node_gen) > { > __bucket_type* __buckets = nullptr; > if (!_M_buckets) > _M_buckets = __buckets = this->_M_allocate_buckets(_M_bucket_count); > > try > { > if (!__ht._M_before_begin._M_nxt) > return; > > > > __node_type* __ht_n = __ht._M_begin(); > __node_type* __this_n = __node_gen(__ht_n); > this->_M_copy_code(__this_n, __ht_n); > _M_before_begin._M_nxt = __this_n; > _M_buckets[_M_bucket_index(__this_n)] = &_M_before_begin; > > > __node_base* __prev_n = __this_n; > for (__ht_n = __ht_n->_M_next(); __ht_n; __ht_n = __ht_n->_M_next()) > { > __this_n = __node_gen(__ht_n); > __prev_n->_M_nxt = __this_n; > this->_M_copy_code(__this_n, __ht_n); > size_type __bkt = _M_bucket_index(__this_n); > if (!_M_buckets[__bkt]) > _M_buckets[__bkt] = __prev_n; > __prev_n = __this_n; > } > } > catch(...) > { > clear(); > if (__buckets) > _M_deallocate_buckets(); > throw; > } > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_reset() noexcept > { > _M_rehash_policy._M_reset(); > _M_bucket_count = 0; > _M_buckets = nullptr; > _M_before_begin._M_nxt = nullptr; > _M_element_count = 0; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_move_assign(_Hashtable&& __ht, std::true_type) > { > this->_M_deallocate_nodes(_M_begin()); > if (__builtin_expect(_M_bucket_count != 0, true)) > _M_deallocate_buckets(); > > __hashtable_base::operator=(std::move(__ht)); > _M_rehash_policy = __ht._M_rehash_policy; > _M_buckets = __ht._M_buckets; > _M_bucket_count = __ht._M_bucket_count; > _M_before_begin._M_nxt = __ht._M_before_begin._M_nxt; > _M_element_count = __ht._M_element_count; > std::__alloc_on_move(this->_M_node_allocator(), __ht._M_node_allocator()); > > > > if (_M_begin()) > _M_buckets[_M_bucket_index(_M_begin())] = &_M_before_begin; > __ht._M_reset(); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_move_assign(_Hashtable&& __ht, std::false_type) > { > if (__ht._M_node_allocator() == this->_M_node_allocator()) > _M_move_assign(std::move(__ht), std::true_type()); > else > { > > __bucket_type* __former_buckets = nullptr; > size_type __former_bucket_count = _M_bucket_count; > const __rehash_state& __former_state = _M_rehash_policy._M_state(); > > if (_M_bucket_count != __ht._M_bucket_count) > { > __former_buckets = _M_buckets; > _M_buckets = this->_M_allocate_buckets(__ht._M_bucket_count); > _M_bucket_count = __ht._M_bucket_count; > } > else > __builtin_memset(_M_buckets, 0, > _M_bucket_count * sizeof(__bucket_type)); > > try > { > __hashtable_base::operator=(std::move(__ht)); > _M_element_count = __ht._M_element_count; > _M_rehash_policy = __ht._M_rehash_policy; > __reuse_or_alloc_node_type __roan(_M_begin(), *this); > _M_before_begin._M_nxt = nullptr; > _M_assign(__ht, > [&__roan](__node_type* __n) > { return __roan(std::move_if_noexcept(__n->_M_v())); }); > __ht.clear(); > } > catch(...) > { > if (__former_buckets) > { > _M_deallocate_buckets(); > _M_rehash_policy._M_reset(__former_state); > _M_buckets = __former_buckets; > _M_bucket_count = __former_bucket_count; > } > __builtin_memset(_M_buckets, 0, > _M_bucket_count * sizeof(__bucket_type)); > throw; > } > } > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _Hashtable(const _Hashtable& __ht) > : __hashtable_base(__ht), > __map_base(__ht), > __rehash_base(__ht), > __hashtable_alloc( > __node_alloc_traits::_S_select_on_copy(__ht._M_node_allocator())), > _M_buckets(), > _M_bucket_count(__ht._M_bucket_count), > _M_element_count(__ht._M_element_count), > _M_rehash_policy(__ht._M_rehash_policy) > { > _M_assign(__ht, > [this](const __node_type* __n) > { return this->_M_allocate_node(__n->_M_v()); }); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _Hashtable(_Hashtable&& __ht) noexcept > : __hashtable_base(__ht), > __map_base(__ht), > __rehash_base(__ht), > __hashtable_alloc(std::move(__ht._M_base_alloc())), > _M_buckets(__ht._M_buckets), > _M_bucket_count(__ht._M_bucket_count), > _M_before_begin(__ht._M_before_begin._M_nxt), > _M_element_count(__ht._M_element_count), > _M_rehash_policy(__ht._M_rehash_policy) > { > > > if (_M_begin()) > _M_buckets[_M_bucket_index(_M_begin())] = &_M_before_begin; > __ht._M_reset(); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _Hashtable(const _Hashtable& __ht, const allocator_type& __a) > : __hashtable_base(__ht), > __map_base(__ht), > __rehash_base(__ht), > __hashtable_alloc(__node_alloc_type(__a)), > _M_buckets(), > _M_bucket_count(__ht._M_bucket_count), > _M_element_count(__ht._M_element_count), > _M_rehash_policy(__ht._M_rehash_policy) > { > _M_assign(__ht, > [this](const __node_type* __n) > { return this->_M_allocate_node(__n->_M_v()); }); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _Hashtable(_Hashtable&& __ht, const allocator_type& __a) > : __hashtable_base(__ht), > __map_base(__ht), > __rehash_base(__ht), > __hashtable_alloc(__node_alloc_type(__a)), > _M_buckets(), > _M_bucket_count(__ht._M_bucket_count), > _M_element_count(__ht._M_element_count), > _M_rehash_policy(__ht._M_rehash_policy) > { > if (__ht._M_node_allocator() == this->_M_node_allocator()) > { > _M_buckets = __ht._M_buckets; > _M_before_begin._M_nxt = __ht._M_before_begin._M_nxt; > > > if (_M_begin()) > _M_buckets[_M_bucket_index(_M_begin())] = &_M_before_begin; > __ht._M_reset(); > } > else > { > _M_assign(__ht, > [this](__node_type* __n) > { > return this->_M_allocate_node( > std::move_if_noexcept(__n->_M_v())); > }); > __ht.clear(); > } > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > ~_Hashtable() noexcept > { > clear(); > if (_M_buckets) > _M_deallocate_buckets(); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > swap(_Hashtable& __x) > noexcept(__node_alloc_traits::_S_nothrow_swap()) > { > > > > this->_M_swap(__x); > > std::__alloc_on_swap(this->_M_node_allocator(), __x._M_node_allocator()); > std::swap(_M_rehash_policy, __x._M_rehash_policy); > std::swap(_M_buckets, __x._M_buckets); > std::swap(_M_bucket_count, __x._M_bucket_count); > std::swap(_M_before_begin._M_nxt, __x._M_before_begin._M_nxt); > std::swap(_M_element_count, __x._M_element_count); > > > > if (_M_begin()) > _M_buckets[_M_bucket_index(_M_begin())] = &_M_before_begin; > if (__x._M_begin()) > __x._M_buckets[__x._M_bucket_index(__x._M_begin())] > = &__x._M_before_begin; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > __rehash_policy(const _RehashPolicy& __pol) > { > size_type __n_bkt = __pol._M_bkt_for_elements(_M_element_count); > __n_bkt = __pol._M_next_bkt(__n_bkt); > if (__n_bkt != _M_bucket_count) > _M_rehash(__n_bkt, _M_rehash_policy._M_state()); > _M_rehash_policy = __pol; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::iterator > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > find(const key_type& __k) > { > if (__builtin_expect(_M_bucket_count == 0, false)) > return end(); > > __hash_code __code = this->_M_hash_code(__k); > std::size_t __n = _M_bucket_index(__k, __code); > __node_type* __p = _M_find_node(__n, __k, __code); > return __p ? iterator(__p) : end(); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::const_iterator > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > find(const key_type& __k) const > { > if (__builtin_expect(_M_bucket_count == 0, false)) > return end(); > > __hash_code __code = this->_M_hash_code(__k); > std::size_t __n = _M_bucket_index(__k, __code); > __node_type* __p = _M_find_node(__n, __k, __code); > return __p ? const_iterator(__p) : end(); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::size_type > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > count(const key_type& __k) const > { > if (__builtin_expect(_M_bucket_count == 0, false)) > return 0; > > __hash_code __code = this->_M_hash_code(__k); > std::size_t __n = _M_bucket_index(__k, __code); > __node_type* __p = _M_bucket_begin(__n); > if (!__p) > return 0; > > std::size_t __result = 0; > for (;; __p = __p->_M_next()) > { > if (this->_M_equals(__k, __code, __p)) > ++__result; > else if (__result) > > > > break; > if (!__p->_M_nxt || _M_bucket_index(__p->_M_next()) != __n) > break; > } > return __result; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > std::pair<typename _Hashtable<_Key, _Value, _Alloc, > _ExtractKey, _Equal, _H1, > _H2, _Hash, _RehashPolicy, > _Traits>::iterator, > typename _Hashtable<_Key, _Value, _Alloc, > _ExtractKey, _Equal, _H1, > _H2, _Hash, _RehashPolicy, > _Traits>::iterator> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > equal_range(const key_type& __k) > { > if (__builtin_expect(_M_bucket_count == 0, false)) > return std::make_pair(end(), end()); > > __hash_code __code = this->_M_hash_code(__k); > std::size_t __n = _M_bucket_index(__k, __code); > __node_type* __p = _M_find_node(__n, __k, __code); > > if (__p) > { > __node_type* __p1 = __p->_M_next(); > while (__p1 && _M_bucket_index(__p1) == __n > && this->_M_equals(__k, __code, __p1)) > __p1 = __p1->_M_next(); > > return std::make_pair(iterator(__p), iterator(__p1)); > } > else > return std::make_pair(end(), end()); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > std::pair<typename _Hashtable<_Key, _Value, _Alloc, > _ExtractKey, _Equal, _H1, > _H2, _Hash, _RehashPolicy, > _Traits>::const_iterator, > typename _Hashtable<_Key, _Value, _Alloc, > _ExtractKey, _Equal, _H1, > _H2, _Hash, _RehashPolicy, > _Traits>::const_iterator> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > equal_range(const key_type& __k) const > { > if (__builtin_expect(_M_bucket_count == 0, false)) > return std::make_pair(end(), end()); > > __hash_code __code = this->_M_hash_code(__k); > std::size_t __n = _M_bucket_index(__k, __code); > __node_type* __p = _M_find_node(__n, __k, __code); > > if (__p) > { > __node_type* __p1 = __p->_M_next(); > while (__p1 && _M_bucket_index(__p1) == __n > && this->_M_equals(__k, __code, __p1)) > __p1 = __p1->_M_next(); > > return std::make_pair(const_iterator(__p), const_iterator(__p1)); > } > else > return std::make_pair(end(), end()); > } > > > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, _RehashPolicy, > _Traits>::__node_base* > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_find_before_node(size_type __n, const key_type& __k, > __hash_code __code) const > { > __node_base* __prev_p = _M_buckets[__n]; > if (!__prev_p) > return nullptr; > > for (__node_type* __p = static_cast<__node_type*>(__prev_p->_M_nxt);; > __p = __p->_M_next()) > { > if (this->_M_equals(__k, __code, __p)) > return __prev_p; > > if (!__p->_M_nxt || _M_bucket_index(__p->_M_next()) != __n) > break; > __prev_p = __p; > } > return nullptr; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_insert_bucket_begin(size_type __bkt, __node_type* __node) > { > if (_M_buckets[__bkt]) > { > > > __node->_M_nxt = _M_buckets[__bkt]->_M_nxt; > _M_buckets[__bkt]->_M_nxt = __node; > } > else > { > > > > __node->_M_nxt = _M_before_begin._M_nxt; > _M_before_begin._M_nxt = __node; > if (__node->_M_nxt) > > > _M_buckets[_M_bucket_index(__node->_M_next())] = __node; > _M_buckets[__bkt] = &_M_before_begin; > } > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_remove_bucket_begin(size_type __bkt, __node_type* __next, > size_type __next_bkt) > { > if (!__next || __next_bkt != __bkt) > { > > > if (__next) > _M_buckets[__next_bkt] = _M_buckets[__bkt]; > > > if (&_M_before_begin == _M_buckets[__bkt]) > _M_before_begin._M_nxt = __next; > _M_buckets[__bkt] = nullptr; > } > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, > _Equal, _H1, _H2, _Hash, _RehashPolicy, > _Traits>::__node_base* > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_get_previous_node(size_type __bkt, __node_base* __n) > { > __node_base* __prev_n = _M_buckets[__bkt]; > while (__prev_n->_M_nxt != __n) > __prev_n = __prev_n->_M_nxt; > return __prev_n; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > template<typename... _Args> > std::pair<typename _Hashtable<_Key, _Value, _Alloc, > _ExtractKey, _Equal, _H1, > _H2, _Hash, _RehashPolicy, > _Traits>::iterator, bool> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_emplace(std::true_type, _Args&&... __args) > { > > __node_type* __node = this->_M_allocate_node(std::forward<_Args>(__args)...); > const key_type& __k = this->_M_extract()(__node->_M_v()); > __hash_code __code; > try > { > __code = this->_M_hash_code(__k); > } > catch(...) > { > this->_M_deallocate_node(__node); > throw; > } > > size_type __bkt = _M_bucket_index(__k, __code); > if (__node_type* __p = _M_find_node(__bkt, __k, __code)) > { > > this->_M_deallocate_node(__node); > return std::make_pair(iterator(__p), false); > } > > > return std::make_pair(_M_insert_unique_node(__bkt, __code, __node), > true); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > template<typename... _Args> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::iterator > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_emplace(const_iterator __hint, std::false_type, _Args&&... __args) > { > > __node_type* __node = > this->_M_allocate_node(std::forward<_Args>(__args)...); > > __hash_code __code; > try > { > __code = this->_M_hash_code(this->_M_extract()(__node->_M_v())); > } > catch(...) > { > this->_M_deallocate_node(__node); > throw; > } > > return _M_insert_multi_node(__hint._M_cur, __code, __node); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::iterator > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_insert_unique_node(size_type __bkt, __hash_code __code, > __node_type* __node) > { > const __rehash_state& __saved_state = _M_rehash_policy._M_state(); > std::pair<bool, std::size_t> __do_rehash > = _M_rehash_policy._M_need_rehash(_M_bucket_count, _M_element_count, 1); > > try > { > if (__do_rehash.first) > { > _M_rehash(__do_rehash.second, __saved_state); > __bkt = _M_bucket_index(this->_M_extract()(__node->_M_v()), __code); > } > > this->_M_store_code(__node, __code); > > > _M_insert_bucket_begin(__bkt, __node); > ++_M_element_count; > return iterator(__node); > } > catch(...) > { > this->_M_deallocate_node(__node); > throw; > } > } > > > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::iterator > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_insert_multi_node(__node_type* __hint, __hash_code __code, > __node_type* __node) > { > const __rehash_state& __saved_state = _M_rehash_policy._M_state(); > std::pair<bool, std::size_t> __do_rehash > = _M_rehash_policy._M_need_rehash(_M_bucket_count, _M_element_count, 1); > > try > { > if (__do_rehash.first) > _M_rehash(__do_rehash.second, __saved_state); > > this->_M_store_code(__node, __code); > const key_type& __k = this->_M_extract()(__node->_M_v()); > size_type __bkt = _M_bucket_index(__k, __code); > > > > __node_base* __prev > = __builtin_expect(__hint != nullptr, false) > && this->_M_equals(__k, __code, __hint) > ? __hint > : _M_find_before_node(__bkt, __k, __code); > if (__prev) > { > > __node->_M_nxt = __prev->_M_nxt; > __prev->_M_nxt = __node; > if (__builtin_expect(__prev == __hint, false)) > > > if (__node->_M_nxt > && !this->_M_equals(__k, __code, __node->_M_next())) > { > size_type __next_bkt = _M_bucket_index(__node->_M_next()); > if (__next_bkt != __bkt) > _M_buckets[__next_bkt] = __node; > } > } > else > > > > > _M_insert_bucket_begin(__bkt, __node); > ++_M_element_count; > return iterator(__node); > } > catch(...) > { > this->_M_deallocate_node(__node); > throw; > } > } > > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > template<typename _Arg, typename _NodeGenerator> > std::pair<typename _Hashtable<_Key, _Value, _Alloc, > _ExtractKey, _Equal, _H1, > _H2, _Hash, _RehashPolicy, > _Traits>::iterator, bool> > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_insert(_Arg&& __v, const _NodeGenerator& __node_gen, std::true_type) > { > const key_type& __k = this->_M_extract()(__v); > __hash_code __code = this->_M_hash_code(__k); > size_type __bkt = _M_bucket_index(__k, __code); > > __node_type* __n = _M_find_node(__bkt, __k, __code); > if (__n) > return std::make_pair(iterator(__n), false); > > __n = __node_gen(std::forward<_Arg>(__v)); > return std::make_pair(_M_insert_unique_node(__bkt, __code, __n), true); > } > > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > template<typename _Arg, typename _NodeGenerator> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::iterator > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_insert(const_iterator __hint, _Arg&& __v, > const _NodeGenerator& __node_gen, > std::false_type) > { > > > __hash_code __code = this->_M_hash_code(this->_M_extract()(__v)); > > > __node_type* __node = __node_gen(std::forward<_Arg>(__v)); > > return _M_insert_multi_node(__hint._M_cur, __code, __node); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::iterator > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > erase(const_iterator __it) > { > __node_type* __n = __it._M_cur; > std::size_t __bkt = _M_bucket_index(__n); > > > > > __node_base* __prev_n = _M_get_previous_node(__bkt, __n); > return _M_erase(__bkt, __prev_n, __n); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::iterator > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_erase(size_type __bkt, __node_base* __prev_n, __node_type* __n) > { > if (__prev_n == _M_buckets[__bkt]) > _M_remove_bucket_begin(__bkt, __n->_M_next(), > __n->_M_nxt ? _M_bucket_index(__n->_M_next()) : 0); > else if (__n->_M_nxt) > { > size_type __next_bkt = _M_bucket_index(__n->_M_next()); > if (__next_bkt != __bkt) > _M_buckets[__next_bkt] = __prev_n; > } > > __prev_n->_M_nxt = __n->_M_nxt; > iterator __result(__n->_M_next()); > this->_M_deallocate_node(__n); > --_M_element_count; > > return __result; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::size_type > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_erase(std::true_type, const key_type& __k) > { > __hash_code __code = this->_M_hash_code(__k); > std::size_t __bkt = _M_bucket_index(__k, __code); > > > __node_base* __prev_n = _M_find_before_node(__bkt, __k, __code); > if (!__prev_n) > return 0; > > > __node_type* __n = static_cast<__node_type*>(__prev_n->_M_nxt); > _M_erase(__bkt, __prev_n, __n); > return 1; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::size_type > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_erase(std::false_type, const key_type& __k) > { > __hash_code __code = this->_M_hash_code(__k); > std::size_t __bkt = _M_bucket_index(__k, __code); > > > __node_base* __prev_n = _M_find_before_node(__bkt, __k, __code); > if (!__prev_n) > return 0; > > > > > > > > __node_type* __n = static_cast<__node_type*>(__prev_n->_M_nxt); > __node_type* __n_last = __n; > std::size_t __n_last_bkt = __bkt; > do > { > __n_last = __n_last->_M_next(); > if (!__n_last) > break; > __n_last_bkt = _M_bucket_index(__n_last); > } > while (__n_last_bkt == __bkt && this->_M_equals(__k, __code, __n_last)); > > > size_type __result = 0; > do > { > __node_type* __p = __n->_M_next(); > this->_M_deallocate_node(__n); > __n = __p; > ++__result; > --_M_element_count; > } > while (__n != __n_last); > > if (__prev_n == _M_buckets[__bkt]) > _M_remove_bucket_begin(__bkt, __n_last, __n_last_bkt); > else if (__n_last && __n_last_bkt != __bkt) > _M_buckets[__n_last_bkt] = __prev_n; > __prev_n->_M_nxt = __n_last; > return __result; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > typename _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, > _Traits>::iterator > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > erase(const_iterator __first, const_iterator __last) > { > __node_type* __n = __first._M_cur; > __node_type* __last_n = __last._M_cur; > if (__n == __last_n) > return iterator(__n); > > std::size_t __bkt = _M_bucket_index(__n); > > __node_base* __prev_n = _M_get_previous_node(__bkt, __n); > bool __is_bucket_begin = __n == _M_bucket_begin(__bkt); > std::size_t __n_bkt = __bkt; > for (;;) > { > do > { > __node_type* __tmp = __n; > __n = __n->_M_next(); > this->_M_deallocate_node(__tmp); > --_M_element_count; > if (!__n) > break; > __n_bkt = _M_bucket_index(__n); > } > while (__n != __last_n && __n_bkt == __bkt); > if (__is_bucket_begin) > _M_remove_bucket_begin(__bkt, __n, __n_bkt); > if (__n == __last_n) > break; > __is_bucket_begin = true; > __bkt = __n_bkt; > } > > if (__n && (__n_bkt != __bkt || __is_bucket_begin)) > _M_buckets[__n_bkt] = __prev_n; > __prev_n->_M_nxt = __n; > return iterator(__n); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > clear() noexcept > { > this->_M_deallocate_nodes(_M_begin()); > __builtin_memset(_M_buckets, 0, _M_bucket_count * sizeof(__bucket_type)); > _M_element_count = 0; > _M_before_begin._M_nxt = nullptr; > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > rehash(size_type __n) > { > const __rehash_state& __saved_state = _M_rehash_policy._M_state(); > std::size_t __buckets > = std::max(_M_rehash_policy._M_bkt_for_elements(_M_element_count + 1), > __n); > __buckets = _M_rehash_policy._M_next_bkt(__buckets); > > if (__buckets != _M_bucket_count) > _M_rehash(__buckets, __saved_state); > else > > _M_rehash_policy._M_reset(__saved_state); > } > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_rehash(size_type __n, const __rehash_state& __state) > { > try > { > _M_rehash_aux(__n, __unique_keys()); > } > catch(...) > { > > > _M_rehash_policy._M_reset(__state); > throw; > } > } > > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_rehash_aux(size_type __n, std::true_type) > { > __bucket_type* __new_buckets = this->_M_allocate_buckets(__n); > __node_type* __p = _M_begin(); > _M_before_begin._M_nxt = nullptr; > std::size_t __bbegin_bkt = 0; > while (__p) > { > __node_type* __next = __p->_M_next(); > std::size_t __bkt = __hash_code_base::_M_bucket_index(__p, __n); > if (!__new_buckets[__bkt]) > { > __p->_M_nxt = _M_before_begin._M_nxt; > _M_before_begin._M_nxt = __p; > __new_buckets[__bkt] = &_M_before_begin; > if (__p->_M_nxt) > __new_buckets[__bbegin_bkt] = __p; > __bbegin_bkt = __bkt; > } > else > { > __p->_M_nxt = __new_buckets[__bkt]->_M_nxt; > __new_buckets[__bkt]->_M_nxt = __p; > } > __p = __next; > } > > if (__builtin_expect(_M_bucket_count != 0, true)) > _M_deallocate_buckets(); > _M_bucket_count = __n; > _M_buckets = __new_buckets; > } > > > > template<typename _Key, typename _Value, > typename _Alloc, typename _ExtractKey, typename _Equal, > typename _H1, typename _H2, typename _Hash, typename _RehashPolicy, > typename _Traits> > void > _Hashtable<_Key, _Value, _Alloc, _ExtractKey, _Equal, > _H1, _H2, _Hash, _RehashPolicy, _Traits>:: > _M_rehash_aux(size_type __n, std::false_type) > { > __bucket_type* __new_buckets = this->_M_allocate_buckets(__n); > > __node_type* __p = _M_begin(); > _M_before_begin._M_nxt = nullptr; > std::size_t __bbegin_bkt = 0; > std::size_t __prev_bkt = 0; > __node_type* __prev_p = nullptr; > bool __check_bucket = false; > > while (__p) > { > __node_type* __next = __p->_M_next(); > std::size_t __bkt = __hash_code_base::_M_bucket_index(__p, __n); > > if (__prev_p && __prev_bkt == __bkt) > { > > > > __p->_M_nxt = __prev_p->_M_nxt; > __prev_p->_M_nxt = __p; > > > > > > > __check_bucket = true; > } > else > { > if (__check_bucket) > { > > > if (__prev_p->_M_nxt) > { > std::size_t __next_bkt > = __hash_code_base::_M_bucket_index(__prev_p->_M_next(), > __n); > if (__next_bkt != __prev_bkt) > __new_buckets[__next_bkt] = __prev_p; > } > __check_bucket = false; > } > > if (!__new_buckets[__bkt]) > { > __p->_M_nxt = _M_before_begin._M_nxt; > _M_before_begin._M_nxt = __p; > __new_buckets[__bkt] = &_M_before_begin; > if (__p->_M_nxt) > __new_buckets[__bbegin_bkt] = __p; > __bbegin_bkt = __bkt; > } > else > { > __p->_M_nxt = __new_buckets[__bkt]->_M_nxt; > __new_buckets[__bkt]->_M_nxt = __p; > } > } > __prev_p = __p; > __prev_bkt = __bkt; > __p = __next; > } > > if (__check_bucket && __prev_p->_M_nxt) > { > std::size_t __next_bkt > = __hash_code_base::_M_bucket_index(__prev_p->_M_next(), __n); > if (__next_bkt != __prev_bkt) > __new_buckets[__next_bkt] = __prev_p; > } > > if (__builtin_expect(_M_bucket_count != 0, true)) > _M_deallocate_buckets(); > _M_bucket_count = __n; > _M_buckets = __new_buckets; > } > > >} ># 48 "/usr/include/c++/4.9.0/unordered_set" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/unordered_set.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template<bool _Cache> > using __uset_traits = __detail::_Hashtable_traits<_Cache, true, true>; > > template<typename _Value, > typename _Hash = hash<_Value>, > typename _Pred = std::equal_to<_Value>, > typename _Alloc = std::allocator<_Value>, > typename _Tr = __uset_traits<__cache_default<_Value, _Hash>::value>> > using __uset_hashtable = _Hashtable<_Value, _Value, _Alloc, > __detail::_Identity, _Pred, _Hash, > __detail::_Mod_range_hashing, > __detail::_Default_ranged_hash, > __detail::_Prime_rehash_policy, _Tr>; > > > template<bool _Cache> > using __umset_traits = __detail::_Hashtable_traits<_Cache, true, false>; > > template<typename _Value, > typename _Hash = hash<_Value>, > typename _Pred = std::equal_to<_Value>, > typename _Alloc = std::allocator<_Value>, > typename _Tr = __umset_traits<__cache_default<_Value, _Hash>::value>> > using __umset_hashtable = _Hashtable<_Value, _Value, _Alloc, > __detail::_Identity, > _Pred, _Hash, > __detail::_Mod_range_hashing, > __detail::_Default_ranged_hash, > __detail::_Prime_rehash_policy, _Tr>; ># 89 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<class _Value, > class _Hash = hash<_Value>, > class _Pred = std::equal_to<_Value>, > class _Alloc = std::allocator<_Value> > > class unordered_set > { > typedef __uset_hashtable<_Value, _Hash, _Pred, _Alloc> _Hashtable; > _Hashtable _M_h; > > public: > > > > typedef typename _Hashtable::key_type key_type; > typedef typename _Hashtable::value_type value_type; > typedef typename _Hashtable::hasher hasher; > typedef typename _Hashtable::key_equal key_equal; > typedef typename _Hashtable::allocator_type allocator_type; > > > > > typedef typename _Hashtable::pointer pointer; > typedef typename _Hashtable::const_pointer const_pointer; > typedef typename _Hashtable::reference reference; > typedef typename _Hashtable::const_reference const_reference; > typedef typename _Hashtable::iterator iterator; > typedef typename _Hashtable::const_iterator const_iterator; > typedef typename _Hashtable::local_iterator local_iterator; > typedef typename _Hashtable::const_local_iterator const_local_iterator; > typedef typename _Hashtable::size_type size_type; > typedef typename _Hashtable::difference_type difference_type; ># 131 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > explicit > unordered_set(size_type __n = 10, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__n, __hf, __eql, __a) > { } ># 152 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<typename _InputIterator> > unordered_set(_InputIterator __f, _InputIterator __l, > size_type __n = 0, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__f, __l, __n, __hf, __eql, __a) > { } > > > unordered_set(const unordered_set&) = default; > > > unordered_set(unordered_set&&) = default; > > > > > > explicit > unordered_set(const allocator_type& __a) > : _M_h(__a) > { } > > > > > > > unordered_set(const unordered_set& __uset, > const allocator_type& __a) > : _M_h(__uset._M_h, __a) > { } > > > > > > > unordered_set(unordered_set&& __uset, > const allocator_type& __a) > : _M_h(std::move(__uset._M_h), __a) > { } ># 207 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > unordered_set(initializer_list<value_type> __l, > size_type __n = 0, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__l, __n, __hf, __eql, __a) > { } > > > unordered_set& > operator=(const unordered_set&) = default; > > > unordered_set& > operator=(unordered_set&&) = default; ># 234 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > unordered_set& > operator=(initializer_list<value_type> __l) > { > _M_h = __l; > return *this; > } > > > > allocator_type > get_allocator() const noexcept > { return _M_h.get_allocator(); } > > > > > bool > empty() const noexcept > { return _M_h.empty(); } > > > size_type > size() const noexcept > { return _M_h.size(); } > > > size_type > max_size() const noexcept > { return _M_h.max_size(); } ># 271 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > begin() noexcept > { return _M_h.begin(); } > > const_iterator > begin() const noexcept > { return _M_h.begin(); } > > > > > > > > iterator > end() noexcept > { return _M_h.end(); } > > const_iterator > end() const noexcept > { return _M_h.end(); } > > > > > > > const_iterator > cbegin() const noexcept > { return _M_h.begin(); } > > > > > > const_iterator > cend() const noexcept > { return _M_h.end(); } ># 327 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<typename... _Args> > std::pair<iterator, bool> > emplace(_Args&&... __args) > { return _M_h.emplace(std::forward<_Args>(__args)...); } ># 353 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<typename... _Args> > iterator > emplace_hint(const_iterator __pos, _Args&&... __args) > { return _M_h.emplace_hint(__pos, std::forward<_Args>(__args)...); } ># 372 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > std::pair<iterator, bool> > insert(const value_type& __x) > { return _M_h.insert(__x); } > > std::pair<iterator, bool> > insert(value_type&& __x) > { return _M_h.insert(std::move(__x)); } ># 401 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > insert(const_iterator __hint, const value_type& __x) > { return _M_h.insert(__hint, __x); } > > iterator > insert(const_iterator __hint, value_type&& __x) > { return _M_h.insert(__hint, std::move(__x)); } ># 419 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<typename _InputIterator> > void > insert(_InputIterator __first, _InputIterator __last) > { _M_h.insert(__first, __last); } ># 431 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > void > insert(initializer_list<value_type> __l) > { _M_h.insert(__l); } ># 449 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > erase(const_iterator __position) > { return _M_h.erase(__position); } > > > iterator > erase(iterator __it) > { return _M_h.erase(__it); } ># 471 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > size_type > erase(const key_type& __x) > { return _M_h.erase(__x); } ># 489 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > erase(const_iterator __first, const_iterator __last) > { return _M_h.erase(__first, __last); } > > > > > > > > void > clear() noexcept > { _M_h.clear(); } ># 512 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > void > swap(unordered_set& __x) > noexcept( noexcept(_M_h.swap(__x._M_h)) ) > { _M_h.swap(__x._M_h); } > > > > > > hasher > hash_function() const > { return _M_h.hash_function(); } > > > > key_equal > key_eq() const > { return _M_h.key_eq(); } ># 545 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > find(const key_type& __x) > { return _M_h.find(__x); } > > const_iterator > find(const key_type& __x) const > { return _M_h.find(__x); } ># 563 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > size_type > count(const key_type& __x) const > { return _M_h.count(__x); } ># 576 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > std::pair<iterator, iterator> > equal_range(const key_type& __x) > { return _M_h.equal_range(__x); } > > std::pair<const_iterator, const_iterator> > equal_range(const key_type& __x) const > { return _M_h.equal_range(__x); } > > > > > > size_type > bucket_count() const noexcept > { return _M_h.bucket_count(); } > > > size_type > max_bucket_count() const noexcept > { return _M_h.max_bucket_count(); } > > > > > > > size_type > bucket_size(size_type __n) const > { return _M_h.bucket_size(__n); } > > > > > > > size_type > bucket(const key_type& __key) const > { return _M_h.bucket(__key); } ># 622 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > local_iterator > begin(size_type __n) > { return _M_h.begin(__n); } > > const_local_iterator > begin(size_type __n) const > { return _M_h.begin(__n); } > > const_local_iterator > cbegin(size_type __n) const > { return _M_h.cbegin(__n); } ># 642 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > local_iterator > end(size_type __n) > { return _M_h.end(__n); } > > const_local_iterator > end(size_type __n) const > { return _M_h.end(__n); } > > const_local_iterator > cend(size_type __n) const > { return _M_h.cend(__n); } > > > > > > float > load_factor() const noexcept > { return _M_h.load_factor(); } > > > > float > max_load_factor() const noexcept > { return _M_h.max_load_factor(); } > > > > > > void > max_load_factor(float __z) > { _M_h.max_load_factor(__z); } ># 683 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > void > rehash(size_type __n) > { _M_h.rehash(__n); } ># 694 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > void > reserve(size_type __n) > { _M_h.reserve(__n); } > > template<typename _Value1, typename _Hash1, typename _Pred1, > typename _Alloc1> > friend bool > operator==(const unordered_set<_Value1, _Hash1, _Pred1, _Alloc1>&, > const unordered_set<_Value1, _Hash1, _Pred1, _Alloc1>&); > }; ># 724 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<class _Value, > class _Hash = hash<_Value>, > class _Pred = std::equal_to<_Value>, > class _Alloc = std::allocator<_Value> > > class unordered_multiset > { > typedef __umset_hashtable<_Value, _Hash, _Pred, _Alloc> _Hashtable; > _Hashtable _M_h; > > public: > > > > typedef typename _Hashtable::key_type key_type; > typedef typename _Hashtable::value_type value_type; > typedef typename _Hashtable::hasher hasher; > typedef typename _Hashtable::key_equal key_equal; > typedef typename _Hashtable::allocator_type allocator_type; > > > > > typedef typename _Hashtable::pointer pointer; > typedef typename _Hashtable::const_pointer const_pointer; > typedef typename _Hashtable::reference reference; > typedef typename _Hashtable::const_reference const_reference; > typedef typename _Hashtable::iterator iterator; > typedef typename _Hashtable::const_iterator const_iterator; > typedef typename _Hashtable::local_iterator local_iterator; > typedef typename _Hashtable::const_local_iterator const_local_iterator; > typedef typename _Hashtable::size_type size_type; > typedef typename _Hashtable::difference_type difference_type; ># 766 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > explicit > unordered_multiset(size_type __n = 10, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__n, __hf, __eql, __a) > { } ># 787 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<typename _InputIterator> > unordered_multiset(_InputIterator __f, _InputIterator __l, > size_type __n = 0, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__f, __l, __n, __hf, __eql, __a) > { } > > > unordered_multiset(const unordered_multiset&) = default; > > > unordered_multiset(unordered_multiset&&) = default; ># 813 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > unordered_multiset(initializer_list<value_type> __l, > size_type __n = 0, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__l, __n, __hf, __eql, __a) > { } > > > unordered_multiset& > operator=(const unordered_multiset&) = default; > > > unordered_multiset& > operator=(unordered_multiset&&) = default; > > > > > > explicit > unordered_multiset(const allocator_type& __a) > : _M_h(__a) > { } > > > > > > > unordered_multiset(const unordered_multiset& __umset, > const allocator_type& __a) > : _M_h(__umset._M_h, __a) > { } > > > > > > > unordered_multiset(unordered_multiset&& __umset, > const allocator_type& __a) > : _M_h(std::move(__umset._M_h), __a) > { } ># 869 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > unordered_multiset& > operator=(initializer_list<value_type> __l) > { > _M_h = __l; > return *this; > } > > > > allocator_type > get_allocator() const noexcept > { return _M_h.get_allocator(); } > > > > > bool > empty() const noexcept > { return _M_h.empty(); } > > > size_type > size() const noexcept > { return _M_h.size(); } > > > size_type > max_size() const noexcept > { return _M_h.max_size(); } ># 906 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > begin() noexcept > { return _M_h.begin(); } > > const_iterator > begin() const noexcept > { return _M_h.begin(); } > > > > > > > > iterator > end() noexcept > { return _M_h.end(); } > > const_iterator > end() const noexcept > { return _M_h.end(); } > > > > > > > const_iterator > cbegin() const noexcept > { return _M_h.begin(); } > > > > > > const_iterator > cend() const noexcept > { return _M_h.end(); } ># 954 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<typename... _Args> > iterator > emplace(_Args&&... __args) > { return _M_h.emplace(std::forward<_Args>(__args)...); } ># 976 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<typename... _Args> > iterator > emplace_hint(const_iterator __pos, _Args&&... __args) > { return _M_h.emplace_hint(__pos, std::forward<_Args>(__args)...); } ># 989 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > insert(const value_type& __x) > { return _M_h.insert(__x); } > > iterator > insert(value_type&& __x) > { return _M_h.insert(std::move(__x)); } ># 1015 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > insert(const_iterator __hint, const value_type& __x) > { return _M_h.insert(__hint, __x); } > > iterator > insert(const_iterator __hint, value_type&& __x) > { return _M_h.insert(__hint, std::move(__x)); } ># 1032 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > template<typename _InputIterator> > void > insert(_InputIterator __first, _InputIterator __last) > { _M_h.insert(__first, __last); } ># 1044 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > void > insert(initializer_list<value_type> __l) > { _M_h.insert(__l); } ># 1063 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > erase(const_iterator __position) > { return _M_h.erase(__position); } > > > iterator > erase(iterator __it) > { return _M_h.erase(__it); } ># 1086 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > size_type > erase(const key_type& __x) > { return _M_h.erase(__x); } ># 1106 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > erase(const_iterator __first, const_iterator __last) > { return _M_h.erase(__first, __last); } ># 1117 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > void > clear() noexcept > { _M_h.clear(); } ># 1130 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > void > swap(unordered_multiset& __x) > noexcept( noexcept(_M_h.swap(__x._M_h)) ) > { _M_h.swap(__x._M_h); } > > > > > > hasher > hash_function() const > { return _M_h.hash_function(); } > > > > key_equal > key_eq() const > { return _M_h.key_eq(); } ># 1163 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > iterator > find(const key_type& __x) > { return _M_h.find(__x); } > > const_iterator > find(const key_type& __x) const > { return _M_h.find(__x); } > > > > > > > > size_type > count(const key_type& __x) const > { return _M_h.count(__x); } ># 1188 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > std::pair<iterator, iterator> > equal_range(const key_type& __x) > { return _M_h.equal_range(__x); } > > std::pair<const_iterator, const_iterator> > equal_range(const key_type& __x) const > { return _M_h.equal_range(__x); } > > > > > > size_type > bucket_count() const noexcept > { return _M_h.bucket_count(); } > > > size_type > max_bucket_count() const noexcept > { return _M_h.max_bucket_count(); } > > > > > > > size_type > bucket_size(size_type __n) const > { return _M_h.bucket_size(__n); } > > > > > > > size_type > bucket(const key_type& __key) const > { return _M_h.bucket(__key); } ># 1234 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > local_iterator > begin(size_type __n) > { return _M_h.begin(__n); } > > const_local_iterator > begin(size_type __n) const > { return _M_h.begin(__n); } > > const_local_iterator > cbegin(size_type __n) const > { return _M_h.cbegin(__n); } ># 1254 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > local_iterator > end(size_type __n) > { return _M_h.end(__n); } > > const_local_iterator > end(size_type __n) const > { return _M_h.end(__n); } > > const_local_iterator > cend(size_type __n) const > { return _M_h.cend(__n); } > > > > > > float > load_factor() const noexcept > { return _M_h.load_factor(); } > > > > float > max_load_factor() const noexcept > { return _M_h.max_load_factor(); } > > > > > > void > max_load_factor(float __z) > { _M_h.max_load_factor(__z); } ># 1295 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > void > rehash(size_type __n) > { _M_h.rehash(__n); } ># 1306 "/usr/include/c++/4.9.0/bits/unordered_set.h" 3 > void > reserve(size_type __n) > { _M_h.reserve(__n); } > > template<typename _Value1, typename _Hash1, typename _Pred1, > typename _Alloc1> > friend bool > operator==(const unordered_multiset<_Value1, _Hash1, _Pred1, _Alloc1>&, > const unordered_multiset<_Value1, _Hash1, _Pred1, _Alloc1>&); > }; > > template<class _Value, class _Hash, class _Pred, class _Alloc> > inline void > swap(unordered_set<_Value, _Hash, _Pred, _Alloc>& __x, > unordered_set<_Value, _Hash, _Pred, _Alloc>& __y) > { __x.swap(__y); } > > template<class _Value, class _Hash, class _Pred, class _Alloc> > inline void > swap(unordered_multiset<_Value, _Hash, _Pred, _Alloc>& __x, > unordered_multiset<_Value, _Hash, _Pred, _Alloc>& __y) > { __x.swap(__y); } > > template<class _Value, class _Hash, class _Pred, class _Alloc> > inline bool > operator==(const unordered_set<_Value, _Hash, _Pred, _Alloc>& __x, > const unordered_set<_Value, _Hash, _Pred, _Alloc>& __y) > { return __x._M_h._M_equal(__y._M_h); } > > template<class _Value, class _Hash, class _Pred, class _Alloc> > inline bool > operator!=(const unordered_set<_Value, _Hash, _Pred, _Alloc>& __x, > const unordered_set<_Value, _Hash, _Pred, _Alloc>& __y) > { return !(__x == __y); } > > template<class _Value, class _Hash, class _Pred, class _Alloc> > inline bool > operator==(const unordered_multiset<_Value, _Hash, _Pred, _Alloc>& __x, > const unordered_multiset<_Value, _Hash, _Pred, _Alloc>& __y) > { return __x._M_h._M_equal(__y._M_h); } > > template<class _Value, class _Hash, class _Pred, class _Alloc> > inline bool > operator!=(const unordered_multiset<_Value, _Hash, _Pred, _Alloc>& __x, > const unordered_multiset<_Value, _Hash, _Pred, _Alloc>& __y) > { return !(__x == __y); } > > >} ># 49 "/usr/include/c++/4.9.0/unordered_set" 2 3 ># 7 "/c/honeypenny/src/currency_core/connection_context.h" 2 > > ># 1 "/c/honeypenny/contrib/epee/include/copyable_atomic.h" 1 ># 27 "/c/honeypenny/contrib/epee/include/copyable_atomic.h" > > > > >namespace epee >{ > class copyable_atomic: public std::atomic<uint32_t> > { > public: > copyable_atomic() > {}; > copyable_atomic(const copyable_atomic& a):std::atomic<uint32_t>(a.load()) > {} > copyable_atomic& operator= (const copyable_atomic& a) > { > store(a.load()); > return *this; > } > uint32_t operator++() > { > return std::atomic<uint32_t>::operator++(); > } > uint32_t operator++(int fake) > { > return std::atomic<uint32_t>::operator++(fake); > } > }; >} ># 10 "/c/honeypenny/src/currency_core/connection_context.h" 2 > >namespace currency >{ > > struct currency_connection_context: public epee::net_utils::connection_context_base > { > > enum state > { > state_befor_handshake = 0, > state_synchronizing, > state_idle, > state_normal > }; > > state m_state; > std::list<crypto::hash> m_needed_objects; > std::unordered_set<crypto::hash> m_requested_objects; > uint64_t m_remote_blockchain_height; > uint64_t m_last_response_height; > epee::copyable_atomic m_callback_request_count; > > }; > > inline std::string get_protocol_state_string(currency_connection_context::state s) > { > switch (s) > { > case currency_connection_context::state_befor_handshake: > return "state_befor_handshake"; > case currency_connection_context::state_synchronizing: > return "state_synchronizing"; > case currency_connection_context::state_idle: > return "state_idle"; > case currency_connection_context::state_normal: > return "state_normal"; > default: > return "unknown"; > } > } > >} ># 10 "/c/honeypenny/src/currency_protocol/currency_protocol_handler_common.h" 2 >namespace currency >{ > > > > struct i_currency_protocol > { > virtual bool relay_block(NOTIFY_NEW_BLOCK::request& arg, currency_connection_context& exclude_context)=0; > virtual bool relay_transactions(NOTIFY_NEW_TRANSACTIONS::request& arg, currency_connection_context& exclude_context)=0; > > }; > > > > > struct currency_protocol_stub: public i_currency_protocol > { > virtual bool relay_block(NOTIFY_NEW_BLOCK::request& arg, currency_connection_context& exclude_context) > { > return false; > } > virtual bool relay_transactions(NOTIFY_NEW_TRANSACTIONS::request& arg, currency_connection_context& exclude_context) > { > return false; > } > > }; >} ># 13 "/c/honeypenny/src/currency_core/currency_core.h" 2 > ># 1 "/c/honeypenny/src/currency_core/tx_pool.h" 1 > > > > > > >using namespace epee; > > > ># 1 "/usr/include/c++/4.9.0/unordered_map" 1 3 ># 32 "/usr/include/c++/4.9.0/unordered_map" 3 ># 33 "/usr/include/c++/4.9.0/unordered_map" 3 ># 48 "/usr/include/c++/4.9.0/unordered_map" 3 ># 1 "/usr/include/c++/4.9.0/bits/unordered_map.h" 1 3 ># 33 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > template<bool _Cache> > using __umap_traits = __detail::_Hashtable_traits<_Cache, false, true>; > > template<typename _Key, > typename _Tp, > typename _Hash = hash<_Key>, > typename _Pred = std::equal_to<_Key>, > typename _Alloc = std::allocator<std::pair<const _Key, _Tp> >, > typename _Tr = __umap_traits<__cache_default<_Key, _Hash>::value>> > using __umap_hashtable = _Hashtable<_Key, std::pair<const _Key, _Tp>, > _Alloc, __detail::_Select1st, > _Pred, _Hash, > __detail::_Mod_range_hashing, > __detail::_Default_ranged_hash, > __detail::_Prime_rehash_policy, _Tr>; > > > template<bool _Cache> > using __ummap_traits = __detail::_Hashtable_traits<_Cache, false, false>; > > template<typename _Key, > typename _Tp, > typename _Hash = hash<_Key>, > typename _Pred = std::equal_to<_Key>, > typename _Alloc = std::allocator<std::pair<const _Key, _Tp> >, > typename _Tr = __ummap_traits<__cache_default<_Key, _Hash>::value>> > using __ummap_hashtable = _Hashtable<_Key, std::pair<const _Key, _Tp>, > _Alloc, __detail::_Select1st, > _Pred, _Hash, > __detail::_Mod_range_hashing, > __detail::_Default_ranged_hash, > __detail::_Prime_rehash_policy, _Tr>; ># 94 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<class _Key, class _Tp, > class _Hash = hash<_Key>, > class _Pred = std::equal_to<_Key>, > class _Alloc = std::allocator<std::pair<const _Key, _Tp> > > > class unordered_map > { > typedef __umap_hashtable<_Key, _Tp, _Hash, _Pred, _Alloc> _Hashtable; > _Hashtable _M_h; > > public: > > > > typedef typename _Hashtable::key_type key_type; > typedef typename _Hashtable::value_type value_type; > typedef typename _Hashtable::mapped_type mapped_type; > typedef typename _Hashtable::hasher hasher; > typedef typename _Hashtable::key_equal key_equal; > typedef typename _Hashtable::allocator_type allocator_type; > > > > > typedef typename _Hashtable::pointer pointer; > typedef typename _Hashtable::const_pointer const_pointer; > typedef typename _Hashtable::reference reference; > typedef typename _Hashtable::const_reference const_reference; > typedef typename _Hashtable::iterator iterator; > typedef typename _Hashtable::const_iterator const_iterator; > typedef typename _Hashtable::local_iterator local_iterator; > typedef typename _Hashtable::const_local_iterator const_local_iterator; > typedef typename _Hashtable::size_type size_type; > typedef typename _Hashtable::difference_type difference_type; ># 138 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > explicit > unordered_map(size_type __n = 10, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__n, __hf, __eql, __a) > { } ># 159 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<typename _InputIterator> > unordered_map(_InputIterator __f, _InputIterator __l, > size_type __n = 0, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__f, __l, __n, __hf, __eql, __a) > { } > > > unordered_map(const unordered_map&) = default; > > > unordered_map(unordered_map&&) = default; > > > > > > explicit > unordered_map(const allocator_type& __a) > : _M_h(__a) > { } > > > > > > > unordered_map(const unordered_map& __umap, > const allocator_type& __a) > : _M_h(__umap._M_h, __a) > { } > > > > > > > unordered_map(unordered_map&& __umap, > const allocator_type& __a) > : _M_h(std::move(__umap._M_h), __a) > { } ># 214 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > unordered_map(initializer_list<value_type> __l, > size_type __n = 0, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__l, __n, __hf, __eql, __a) > { } > > > unordered_map& > operator=(const unordered_map&) = default; > > > unordered_map& > operator=(unordered_map&&) = default; ># 241 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > unordered_map& > operator=(initializer_list<value_type> __l) > { > _M_h = __l; > return *this; > } > > > > allocator_type > get_allocator() const noexcept > { return _M_h.get_allocator(); } > > > > > bool > empty() const noexcept > { return _M_h.empty(); } > > > size_type > size() const noexcept > { return _M_h.size(); } > > > size_type > max_size() const noexcept > { return _M_h.max_size(); } > > > > > > > > iterator > begin() noexcept > { return _M_h.begin(); } > > > > > > > const_iterator > begin() const noexcept > { return _M_h.begin(); } > > const_iterator > cbegin() const noexcept > { return _M_h.begin(); } > > > > > > > iterator > end() noexcept > { return _M_h.end(); } > > > > > > > const_iterator > end() const noexcept > { return _M_h.end(); } > > const_iterator > cend() const noexcept > { return _M_h.end(); } ># 338 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<typename... _Args> > std::pair<iterator, bool> > emplace(_Args&&... __args) > { return _M_h.emplace(std::forward<_Args>(__args)...); } ># 368 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<typename... _Args> > iterator > emplace_hint(const_iterator __pos, _Args&&... __args) > { return _M_h.emplace_hint(__pos, std::forward<_Args>(__args)...); } ># 391 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > std::pair<iterator, bool> > insert(const value_type& __x) > { return _M_h.insert(__x); } > > template<typename _Pair, typename = typename > std::enable_if<std::is_constructible<value_type, > _Pair&&>::value>::type> > std::pair<iterator, bool> > insert(_Pair&& __x) > { return _M_h.insert(std::forward<_Pair>(__x)); } ># 425 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > iterator > insert(const_iterator __hint, const value_type& __x) > { return _M_h.insert(__hint, __x); } > > template<typename _Pair, typename = typename > std::enable_if<std::is_constructible<value_type, > _Pair&&>::value>::type> > iterator > insert(const_iterator __hint, _Pair&& __x) > { return _M_h.insert(__hint, std::forward<_Pair>(__x)); } ># 446 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<typename _InputIterator> > void > insert(_InputIterator __first, _InputIterator __last) > { _M_h.insert(__first, __last); } ># 458 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > void > insert(initializer_list<value_type> __l) > { _M_h.insert(__l); } ># 476 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > iterator > erase(const_iterator __position) > { return _M_h.erase(__position); } > > > iterator > erase(iterator __it) > { return _M_h.erase(__it); } ># 498 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > size_type > erase(const key_type& __x) > { return _M_h.erase(__x); } ># 516 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > iterator > erase(const_iterator __first, const_iterator __last) > { return _M_h.erase(__first, __last); } > > > > > > > > void > clear() noexcept > { _M_h.clear(); } ># 539 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > void > swap(unordered_map& __x) > noexcept( noexcept(_M_h.swap(__x._M_h)) ) > { _M_h.swap(__x._M_h); } > > > > > > hasher > hash_function() const > { return _M_h.hash_function(); } > > > > key_equal > key_eq() const > { return _M_h.key_eq(); } ># 572 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > iterator > find(const key_type& __x) > { return _M_h.find(__x); } > > const_iterator > find(const key_type& __x) const > { return _M_h.find(__x); } ># 590 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > size_type > count(const key_type& __x) const > { return _M_h.count(__x); } ># 603 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > std::pair<iterator, iterator> > equal_range(const key_type& __x) > { return _M_h.equal_range(__x); } > > std::pair<const_iterator, const_iterator> > equal_range(const key_type& __x) const > { return _M_h.equal_range(__x); } ># 625 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > mapped_type& > operator[](const key_type& __k) > { return _M_h[__k]; } > > mapped_type& > operator[](key_type&& __k) > { return _M_h[std::move(__k)]; } ># 642 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > mapped_type& > at(const key_type& __k) > { return _M_h.at(__k); } > > const mapped_type& > at(const key_type& __k) const > { return _M_h.at(__k); } > > > > > > size_type > bucket_count() const noexcept > { return _M_h.bucket_count(); } > > > size_type > max_bucket_count() const noexcept > { return _M_h.max_bucket_count(); } > > > > > > > size_type > bucket_size(size_type __n) const > { return _M_h.bucket_size(__n); } > > > > > > > size_type > bucket(const key_type& __key) const > { return _M_h.bucket(__key); } > > > > > > > > local_iterator > begin(size_type __n) > { return _M_h.begin(__n); } ># 698 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > const_local_iterator > begin(size_type __n) const > { return _M_h.begin(__n); } > > const_local_iterator > cbegin(size_type __n) const > { return _M_h.cbegin(__n); } ># 713 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > local_iterator > end(size_type __n) > { return _M_h.end(__n); } ># 724 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > const_local_iterator > end(size_type __n) const > { return _M_h.end(__n); } > > const_local_iterator > cend(size_type __n) const > { return _M_h.cend(__n); } > > > > > > float > load_factor() const noexcept > { return _M_h.load_factor(); } > > > > float > max_load_factor() const noexcept > { return _M_h.max_load_factor(); } > > > > > > void > max_load_factor(float __z) > { _M_h.max_load_factor(__z); } ># 761 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > void > rehash(size_type __n) > { _M_h.rehash(__n); } ># 772 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > void > reserve(size_type __n) > { _M_h.reserve(__n); } > > template<typename _Key1, typename _Tp1, typename _Hash1, typename _Pred1, > typename _Alloc1> > friend bool > operator==(const unordered_map<_Key1, _Tp1, _Hash1, _Pred1, _Alloc1>&, > const unordered_map<_Key1, _Tp1, _Hash1, _Pred1, _Alloc1>&); > }; ># 806 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<class _Key, class _Tp, > class _Hash = hash<_Key>, > class _Pred = std::equal_to<_Key>, > class _Alloc = std::allocator<std::pair<const _Key, _Tp> > > > class unordered_multimap > { > typedef __ummap_hashtable<_Key, _Tp, _Hash, _Pred, _Alloc> _Hashtable; > _Hashtable _M_h; > > public: > > > > typedef typename _Hashtable::key_type key_type; > typedef typename _Hashtable::value_type value_type; > typedef typename _Hashtable::mapped_type mapped_type; > typedef typename _Hashtable::hasher hasher; > typedef typename _Hashtable::key_equal key_equal; > typedef typename _Hashtable::allocator_type allocator_type; > > > > > typedef typename _Hashtable::pointer pointer; > typedef typename _Hashtable::const_pointer const_pointer; > typedef typename _Hashtable::reference reference; > typedef typename _Hashtable::const_reference const_reference; > typedef typename _Hashtable::iterator iterator; > typedef typename _Hashtable::const_iterator const_iterator; > typedef typename _Hashtable::local_iterator local_iterator; > typedef typename _Hashtable::const_local_iterator const_local_iterator; > typedef typename _Hashtable::size_type size_type; > typedef typename _Hashtable::difference_type difference_type; ># 850 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > explicit > unordered_multimap(size_type __n = 10, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__n, __hf, __eql, __a) > { } ># 871 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<typename _InputIterator> > unordered_multimap(_InputIterator __f, _InputIterator __l, > size_type __n = 0, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__f, __l, __n, __hf, __eql, __a) > { } > > > unordered_multimap(const unordered_multimap&) = default; > > > unordered_multimap(unordered_multimap&&) = default; > > > > > > explicit > unordered_multimap(const allocator_type& __a) > : _M_h(__a) > { } > > > > > > > unordered_multimap(const unordered_multimap& __ummap, > const allocator_type& __a) > : _M_h(__ummap._M_h, __a) > { } > > > > > > > unordered_multimap(unordered_multimap&& __ummap, > const allocator_type& __a) > : _M_h(std::move(__ummap._M_h), __a) > { } ># 926 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > unordered_multimap(initializer_list<value_type> __l, > size_type __n = 0, > const hasher& __hf = hasher(), > const key_equal& __eql = key_equal(), > const allocator_type& __a = allocator_type()) > : _M_h(__l, __n, __hf, __eql, __a) > { } > > > unordered_multimap& > operator=(const unordered_multimap&) = default; > > > unordered_multimap& > operator=(unordered_multimap&&) = default; ># 953 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > unordered_multimap& > operator=(initializer_list<value_type> __l) > { > _M_h = __l; > return *this; > } > > > > allocator_type > get_allocator() const noexcept > { return _M_h.get_allocator(); } > > > > > bool > empty() const noexcept > { return _M_h.empty(); } > > > size_type > size() const noexcept > { return _M_h.size(); } > > > size_type > max_size() const noexcept > { return _M_h.max_size(); } > > > > > > > > iterator > begin() noexcept > { return _M_h.begin(); } > > > > > > > const_iterator > begin() const noexcept > { return _M_h.begin(); } > > const_iterator > cbegin() const noexcept > { return _M_h.begin(); } > > > > > > > iterator > end() noexcept > { return _M_h.end(); } > > > > > > > const_iterator > end() const noexcept > { return _M_h.end(); } > > const_iterator > cend() const noexcept > { return _M_h.end(); } ># 1046 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<typename... _Args> > iterator > emplace(_Args&&... __args) > { return _M_h.emplace(std::forward<_Args>(__args)...); } ># 1072 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<typename... _Args> > iterator > emplace_hint(const_iterator __pos, _Args&&... __args) > { return _M_h.emplace_hint(__pos, std::forward<_Args>(__args)...); } ># 1087 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > iterator > insert(const value_type& __x) > { return _M_h.insert(__x); } > > template<typename _Pair, typename = typename > std::enable_if<std::is_constructible<value_type, > _Pair&&>::value>::type> > iterator > insert(_Pair&& __x) > { return _M_h.insert(std::forward<_Pair>(__x)); } ># 1119 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > iterator > insert(const_iterator __hint, const value_type& __x) > { return _M_h.insert(__hint, __x); } > > template<typename _Pair, typename = typename > std::enable_if<std::is_constructible<value_type, > _Pair&&>::value>::type> > iterator > insert(const_iterator __hint, _Pair&& __x) > { return _M_h.insert(__hint, std::forward<_Pair>(__x)); } ># 1140 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > template<typename _InputIterator> > void > insert(_InputIterator __first, _InputIterator __last) > { _M_h.insert(__first, __last); } ># 1153 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > void > insert(initializer_list<value_type> __l) > { _M_h.insert(__l); } ># 1171 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > iterator > erase(const_iterator __position) > { return _M_h.erase(__position); } > > > iterator > erase(iterator __it) > { return _M_h.erase(__it); } ># 1192 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > size_type > erase(const key_type& __x) > { return _M_h.erase(__x); } ># 1211 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > iterator > erase(const_iterator __first, const_iterator __last) > { return _M_h.erase(__first, __last); } > > > > > > > > void > clear() noexcept > { _M_h.clear(); } ># 1235 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > void > swap(unordered_multimap& __x) > noexcept( noexcept(_M_h.swap(__x._M_h)) ) > { _M_h.swap(__x._M_h); } > > > > > > hasher > hash_function() const > { return _M_h.hash_function(); } > > > > key_equal > key_eq() const > { return _M_h.key_eq(); } ># 1268 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > iterator > find(const key_type& __x) > { return _M_h.find(__x); } > > const_iterator > find(const key_type& __x) const > { return _M_h.find(__x); } > > > > > > > > size_type > count(const key_type& __x) const > { return _M_h.count(__x); } ># 1293 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > std::pair<iterator, iterator> > equal_range(const key_type& __x) > { return _M_h.equal_range(__x); } > > std::pair<const_iterator, const_iterator> > equal_range(const key_type& __x) const > { return _M_h.equal_range(__x); } > > > > > > size_type > bucket_count() const noexcept > { return _M_h.bucket_count(); } > > > size_type > max_bucket_count() const noexcept > { return _M_h.max_bucket_count(); } > > > > > > > size_type > bucket_size(size_type __n) const > { return _M_h.bucket_size(__n); } > > > > > > > size_type > bucket(const key_type& __key) const > { return _M_h.bucket(__key); } > > > > > > > > local_iterator > begin(size_type __n) > { return _M_h.begin(__n); } ># 1349 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > const_local_iterator > begin(size_type __n) const > { return _M_h.begin(__n); } > > const_local_iterator > cbegin(size_type __n) const > { return _M_h.cbegin(__n); } ># 1364 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > local_iterator > end(size_type __n) > { return _M_h.end(__n); } ># 1375 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > const_local_iterator > end(size_type __n) const > { return _M_h.end(__n); } > > const_local_iterator > cend(size_type __n) const > { return _M_h.cend(__n); } > > > > > > float > load_factor() const noexcept > { return _M_h.load_factor(); } > > > > float > max_load_factor() const noexcept > { return _M_h.max_load_factor(); } > > > > > > void > max_load_factor(float __z) > { _M_h.max_load_factor(__z); } ># 1412 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > void > rehash(size_type __n) > { _M_h.rehash(__n); } ># 1423 "/usr/include/c++/4.9.0/bits/unordered_map.h" 3 > void > reserve(size_type __n) > { _M_h.reserve(__n); } > > template<typename _Key1, typename _Tp1, typename _Hash1, typename _Pred1, > typename _Alloc1> > friend bool > operator==(const unordered_multimap<_Key1, _Tp1, > _Hash1, _Pred1, _Alloc1>&, > const unordered_multimap<_Key1, _Tp1, > _Hash1, _Pred1, _Alloc1>&); > }; > > template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> > inline void > swap(unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, > unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) > { __x.swap(__y); } > > template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> > inline void > swap(unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, > unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) > { __x.swap(__y); } > > template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> > inline bool > operator==(const unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, > const unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) > { return __x._M_h._M_equal(__y._M_h); } > > template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> > inline bool > operator!=(const unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, > const unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) > { return !(__x == __y); } > > template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> > inline bool > operator==(const unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, > const unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) > { return __x._M_h._M_equal(__y._M_h); } > > template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc> > inline bool > operator!=(const unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __x, > const unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>& __y) > { return !(__x == __y); } > > >} ># 49 "/usr/include/c++/4.9.0/unordered_map" 2 3 ># 12 "/c/honeypenny/src/currency_core/tx_pool.h" 2 > ># 1 "/usr/include/boost/serialization/version.hpp" 1 3 4 ># 28 "/usr/include/boost/serialization/version.hpp" 3 4 >namespace boost { >namespace serialization { > >struct basic_traits; > > > >template<class T> >struct version >{ > template<class U> > struct traits_class_version { > typedef typename U::version type; > }; > > typedef mpl::integral_c_tag tag; > > > typedef > typename mpl::eval_if< > is_base_and_derived<boost::serialization::basic_traits,T>, > traits_class_version< T >, > mpl::int_<0> > >::type type; > static const int value = version::type::value; >}; > > >template<class T> >const int version<T>::value; > > >} >} ># 14 "/c/honeypenny/src/currency_core/tx_pool.h" 2 ># 1 "/usr/include/boost/utility.hpp" 1 3 4 ># 13 "/usr/include/boost/utility.hpp" 3 4 ># 1 "/usr/include/boost/utility/base_from_member.hpp" 1 3 4 ># 58 "/usr/include/boost/utility/base_from_member.hpp" 3 4 >namespace boost >{ > >namespace detail >{ ># 72 "/usr/include/boost/utility/base_from_member.hpp" 3 4 >template < typename T > >struct remove_cv_ref >{ > typedef typename ::boost::remove_cv<typename > ::boost::remove_reference<T>::type>::type type; > >}; > > > > > > > >template < typename T, typename U > >struct is_related > : public ::boost::is_same< > typename ::boost::detail::remove_cv_ref<T>::type, > typename ::boost::detail::remove_cv_ref<U>::type > >{}; ># 100 "/usr/include/boost/utility/base_from_member.hpp" 3 4 >template<typename ...T> >struct enable_if_unrelated > : public ::boost::enable_if_c<true> >{}; > >template<typename T, typename U, typename ...U2> >struct enable_if_unrelated<T, U, U2...> > : public ::boost::disable_if< ::boost::detail::is_related<T, U> > >{}; > > >} ># 123 "/usr/include/boost/utility/base_from_member.hpp" 3 4 >template < typename MemberType, int UniqueID = 0 > >class base_from_member >{ >protected: > MemberType member; > > > > > > template <typename ...T, typename EnableIf = typename > ::boost::detail::enable_if_unrelated<base_from_member, T...>::type> > explicit constexpr base_from_member( T&& ...x ) > noexcept((noexcept((::new ((void*) 0) MemberType( static_cast<T&&>(x)... ))))) > > : member( static_cast<T&&>(x)... ) > {} ># 149 "/usr/include/boost/utility/base_from_member.hpp" 3 4 >}; > >} ># 14 "/usr/include/boost/utility.hpp" 2 3 4 ># 1 "/usr/include/boost/utility/binary.hpp" 1 3 4 ># 26 "/usr/include/boost/utility/binary.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/control/deduce_d.hpp" 1 3 4 ># 16 "/usr/include/boost/preprocessor/control/deduce_d.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/control/deduce_d.hpp" 2 3 4 ># 27 "/usr/include/boost/utility/binary.hpp" 2 3 4 > > ># 1 "/usr/include/boost/preprocessor/seq/cat.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/seq/cat.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/seq/fold_left.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/seq/fold_left.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/detail/auto_rec.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/seq/fold_left.hpp" 2 3 4 ># 19 "/usr/include/boost/preprocessor/seq/cat.hpp" 2 3 4 ># 30 "/usr/include/boost/utility/binary.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/seq/transform.hpp" 1 3 4 ># 31 "/usr/include/boost/utility/binary.hpp" 2 3 4 ># 1 "/usr/include/boost/preprocessor/arithmetic/mod.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/arithmetic/mod.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/arithmetic/detail/div_base.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/arithmetic/detail/div_base.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/comparison/less_equal.hpp" 1 3 4 ># 20 "/usr/include/boost/preprocessor/arithmetic/detail/div_base.hpp" 2 3 4 ># 18 "/usr/include/boost/preprocessor/arithmetic/mod.hpp" 2 3 4 ># 32 "/usr/include/boost/utility/binary.hpp" 2 3 4 ># 15 "/usr/include/boost/utility.hpp" 2 3 4 > ># 1 "/usr/include/boost/utility/identity_type.hpp" 1 3 4 ># 17 "/usr/include/boost/utility.hpp" 2 3 4 ># 15 "/c/honeypenny/src/currency_core/tx_pool.h" 2 > > > ># 1 "/c/honeypenny/src/currency_core/currency_basic_impl.h" 1 ># 12 "/c/honeypenny/src/currency_core/currency_basic_impl.h" >namespace currency >{ > > > > template<class t_array> > struct array_hasher: std::unary_function<t_array&, std::size_t> > { > std::size_t operator()(const t_array& val) const > { > return boost::hash_range(&val.data[0], &val.data[sizeof(val.data)]); > } > }; > > >#pragma pack(push, 1) > struct public_address_outer_blob > { > uint8_t m_ver; > account_public_address m_address; > uint8_t check_sum; > }; >#pragma pack (pop) > > > > > > size_t get_max_block_size(); > size_t get_max_tx_size(); > bool get_block_reward(size_t median_size, size_t current_block_size, uint64_t already_generated_coins, uint64_t already_donated_coins, uint64_t &reward, uint64_t &max_donation); > uint64_t get_donations_anount_for_day(uint64_t already_donated_coins); > uint64_t get_donations_for_height(uint64_t h, uint64_t already_donated); > void get_donation_parts(uint64_t total_donations, uint64_t& royalty, uint64_t& donation); > uint8_t get_account_address_checksum(const public_address_outer_blob& bl); > std::string get_account_address_as_str(const account_public_address& adr); > bool get_account_address_from_str(account_public_address& adr, const std::string& str); > bool is_coinbase(const transaction& tx); > > bool operator ==(const currency::transaction& a, const currency::transaction& b); > bool operator ==(const currency::block& a, const currency::block& b); >} > >template <class T> >std::ostream &print256(std::ostream &o, const T &v) { > return o << "<" << epee::string_tools::pod_to_hex(v) << ">"; >} > >bool parse_hash256(const std::string str_hash, crypto::hash& hash); > >namespace crypto { > inline std::ostream &operator <<(std::ostream &o, const crypto::public_key &v) { return print256(o, v); } > inline std::ostream &operator <<(std::ostream &o, const crypto::secret_key &v) { return print256(o, v); } > inline std::ostream &operator <<(std::ostream &o, const crypto::key_derivation &v) { return print256(o, v); } > inline std::ostream &operator <<(std::ostream &o, const crypto::key_image &v) { return print256(o, v); } > inline std::ostream &operator <<(std::ostream &o, const crypto::signature &v) { return print256(o, v); } > inline std::ostream &operator <<(std::ostream &o, const crypto::hash &v) { return print256(o, v); } >} ># 19 "/c/honeypenny/src/currency_core/tx_pool.h" 2 ># 1 "/c/honeypenny/src/currency_core/verification_context.h" 1 > > > > > > >namespace currency >{ > > > > struct tx_verification_context > { > bool m_should_be_relayed; > bool m_verifivation_failed; > bool m_verifivation_impossible; > bool m_added_to_pool; > }; > > struct block_verification_context > { > bool m_added_to_main_chain; > bool m_verifivation_failed; > bool m_marked_as_orphaned; > bool m_already_exists; > }; >} ># 20 "/c/honeypenny/src/currency_core/tx_pool.h" 2 > ># 1 "/c/honeypenny/src/common/boost_serialization_helper.h" 1 > > > > > > ># 1 "/usr/include/boost/archive/binary_oarchive.hpp" 1 3 4 ># 21 "/usr/include/boost/archive/binary_oarchive.hpp" 3 4 ># 1 "/usr/include/boost/archive/binary_oarchive_impl.hpp" 1 3 4 ># 21 "/usr/include/boost/archive/binary_oarchive_impl.hpp" 3 4 ># 1 "/usr/include/boost/serialization/pfto.hpp" 1 3 4 ># 43 "/usr/include/boost/serialization/pfto.hpp" 3 4 >namespace boost { >namespace serialization { > >template<class T> >struct pfto_wrapper { > const T & t; > operator const T & (){ > return t; > } > pfto_wrapper (const T & rhs) : t(rhs) {} >}; > >template<class T> >pfto_wrapper< T > make_pfto_wrapper(const T & t, int){ > return pfto_wrapper< T >(t); >} > >template<class T> >pfto_wrapper< T > make_pfto_wrapper(const pfto_wrapper< T > & t, int){ > return t; >} > >} >} ># 22 "/usr/include/boost/archive/binary_oarchive_impl.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 1 3 4 ># 27 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 28 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 ># 40 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 41 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/serialization/throw_exception.hpp" 1 3 4 ># 24 "/usr/include/boost/serialization/throw_exception.hpp" 3 4 >namespace boost { >namespace serialization { ># 35 "/usr/include/boost/serialization/throw_exception.hpp" 3 4 >template<class E> inline void throw_exception(E const & e){ > throw e; >} > > > >} >} ># 45 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 > ># 1 "/usr/include/boost/archive/basic_streambuf_locale_saver.hpp" 1 3 4 ># 40 "/usr/include/boost/archive/basic_streambuf_locale_saver.hpp" 3 4 >namespace boost{ >namespace archive{ > >template < typename Ch, class Tr > >class basic_streambuf_locale_saver : > private boost::noncopyable >{ >public: > typedef ::std::basic_streambuf<Ch, Tr> 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_; >}; > >} >} ># 47 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/archive_exception.hpp" 1 3 4 ># 20 "/usr/include/boost/archive/archive_exception.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 21 "/usr/include/boost/archive/archive_exception.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/archive/detail/decl.hpp" 1 3 4 ># 26 "/usr/include/boost/archive/archive_exception.hpp" 2 3 4 ># 35 "/usr/include/boost/archive/archive_exception.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 36 "/usr/include/boost/archive/archive_exception.hpp" 2 3 4 > >namespace boost { >namespace archive { > > > > >class archive_exception : > public virtual std::exception >{ >protected: > char m_buffer[128]; >public: > typedef enum { > no_exception, > other_exception, > unregistered_class, > > invalid_signature, > > unsupported_version, > > pointer_conflict, > > > > > incompatible_native_format, > > array_size_too_short, > input_stream_error, > invalid_class_name, > > > unregistered_cast, > > unsupported_class_version, > > > multiple_code_instantiation, > > output_stream_error > } 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(); >}; > >} >} > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 98 "/usr/include/boost/archive/archive_exception.hpp" 2 3 4 ># 48 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/is_bitwise_serializable.hpp" 1 3 4 ># 27 "/usr/include/boost/serialization/is_bitwise_serializable.hpp" 3 4 >namespace boost { >namespace serialization { > template<class T> > struct is_bitwise_serializable > : public is_arithmetic< T > > {}; >} >} ># 49 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/placeholders.hpp" 1 3 4 ># 50 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/array.hpp" 1 3 4 ># 19 "/usr/include/boost/serialization/array.hpp" 3 4 ># 1 "/usr/include/boost/serialization/nvp.hpp" 1 3 4 ># 31 "/usr/include/boost/serialization/nvp.hpp" 3 4 ># 1 "/usr/include/boost/serialization/level.hpp" 1 3 4 ># 34 "/usr/include/boost/serialization/level.hpp" 3 4 ># 1 "/usr/include/boost/serialization/level_enum.hpp" 1 3 4 ># 19 "/usr/include/boost/serialization/level_enum.hpp" 3 4 >namespace boost { >namespace serialization { > > > > > >enum level_type >{ > > > not_serializable = 0, > > > > > > > primitive_type = 1, > > > > object_serializable = 2, > > > > > > > > object_class_info = 3 >}; > >} >} ># 35 "/usr/include/boost/serialization/level.hpp" 2 3 4 > >namespace boost { >namespace serialization { > >struct basic_traits; > > >template<class T> >struct implementation_level_impl { > template<class U> > struct traits_class_level { > typedef typename U::level type; > }; > > typedef mpl::integral_c_tag tag; > > > typedef > typename mpl::eval_if< > is_base_and_derived<boost::serialization::basic_traits, T>, > traits_class_level< T >, > > typename mpl::eval_if< > is_fundamental< T >, > mpl::int_<primitive_type>, > > typename mpl::eval_if< > is_class< T >, > mpl::int_<object_class_info>, > > typename mpl::eval_if< > is_array< T >, > > > > mpl::int_<object_serializable>, > > > typename mpl::eval_if< > is_enum< T >, > > > > mpl::int_<primitive_type>, > > > mpl::int_<not_serializable> > > > > > > > > > >::type type; > > static const int value = type::value; >}; > >template<class T> >struct implementation_level : > public implementation_level_impl<const T> >{ >}; > >template<class T, int L > >inline bool operator>=(implementation_level< T > t, enum level_type l) >{ > return t.value >= (int)l; >} > >} >} ># 32 "/usr/include/boost/serialization/nvp.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/tracking.hpp" 1 3 4 ># 31 "/usr/include/boost/serialization/tracking.hpp" 3 4 ># 1 "/usr/include/boost/serialization/tracking_enum.hpp" 1 3 4 ># 19 "/usr/include/boost/serialization/tracking_enum.hpp" 3 4 >namespace boost { >namespace serialization { > > > > > > >enum tracking_type >{ > > track_never = 0, > > > track_selectively = 1, > > track_always = 2 >}; > >} >} ># 32 "/usr/include/boost/serialization/tracking.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/type_info_implementation.hpp" 1 3 4 ># 27 "/usr/include/boost/serialization/type_info_implementation.hpp" 3 4 ># 1 "/usr/include/boost/serialization/traits.hpp" 1 3 4 ># 35 "/usr/include/boost/serialization/traits.hpp" 3 4 >namespace boost { >namespace serialization { > > >struct basic_traits {}; > >template <class T> >struct extended_type_info_impl; > >template< > class T, > int Level, > int Tracking, > unsigned int Version = 0, > class ETII = extended_type_info_impl< T >, > class Wrapper = mpl::false_ >> >struct traits : public basic_traits { > static_assert(Version == 0 || Level >= object_class_info, "Version == 0 || Level >= object_class_info"); > static_assert(Tracking == track_never || Level >= object_serializable, "Tracking == track_never || Level >= object_serializable"); > typedef typename mpl::int_<Level> level; > typedef typename mpl::int_<Tracking> tracking; > typedef typename mpl::int_<Version> version; > typedef ETII type_info_implementation; > typedef Wrapper is_wrapper; >}; > >} >} ># 28 "/usr/include/boost/serialization/type_info_implementation.hpp" 2 3 4 > >namespace boost { >namespace serialization { > > > >template<class T> >struct type_info_implementation { > template<class U> > struct traits_class_typeinfo_implementation { > typedef typename U::type_info_implementation::type type; > }; > > > typedef > typename mpl::eval_if< > is_base_and_derived<boost::serialization::basic_traits, T>, > traits_class_typeinfo_implementation< T >, > > mpl::identity< > typename extended_type_info_impl< T >::type > > > >::type type; >}; > >} >} ># 33 "/usr/include/boost/serialization/tracking.hpp" 2 3 4 > >namespace boost { >namespace serialization { > >struct basic_traits; > > >template<class T> >struct tracking_level_impl { > template<class U> > struct traits_class_tracking { > typedef typename U::tracking type; > }; > typedef mpl::integral_c_tag tag; > > > typedef > typename mpl::eval_if< > is_base_and_derived<boost::serialization::basic_traits, T>, > traits_class_tracking< T >, > > typename mpl::eval_if< > is_pointer< T >, > > mpl::int_<track_never>, > > typename mpl::eval_if< > > typename mpl::equal_to< > implementation_level< T >, > mpl::int_<primitive_type> > >, > > mpl::int_<track_never>, > > mpl::int_<track_selectively> > > > >::type type; > static const int value = type::value; >}; > >template<class T> >struct tracking_level : > public tracking_level_impl<const T> >{ >}; > >template<class T, enum tracking_type L> >inline bool operator>=(tracking_level< T > t, enum tracking_type l) >{ > return t.value >= (int)l; >} > >} >} ># 33 "/usr/include/boost/serialization/nvp.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/split_member.hpp" 1 3 4 ># 23 "/usr/include/boost/serialization/split_member.hpp" 3 4 ># 1 "/usr/include/boost/serialization/access.hpp" 1 3 4 ># 23 "/usr/include/boost/serialization/access.hpp" 3 4 >namespace boost { > >namespace archive { >namespace detail { > template<class Archive, class T> > class iserializer; > template<class Archive, class T> > class oserializer; >} >} > >namespace serialization { > > >template<class Archive, class T> >inline void serialize_adl(Archive &, T &, const unsigned int); >namespace detail { > template<class Archive, class T> > struct member_saver; > template<class Archive, class T> > struct member_loader; >} > > > > > > >class access { >public: > > > > > template<class Archive, class T> > friend struct detail::member_saver; > template<class Archive, class T> > friend struct detail::member_loader; > template<class Archive, class T> > friend class archive::detail::iserializer; > template<class Archive, class T> > friend class archive::detail::oserializer; > template<class Archive, class T> > friend inline void serialize( > Archive & ar, > T & t, > const unsigned int file_version > ); > template<class Archive, class T> > friend inline void save_construct_data( > Archive & ar, > const T * t, > const unsigned int file_version > ); > template<class Archive, class T> > friend inline void load_construct_data( > Archive & ar, > T * t, > const unsigned int file_version > ); > > > > template<class Archive, class T> > static void member_save( > Archive & ar, > > T & t, > const unsigned int file_version > ){ > t.save(ar, file_version); > } > template<class Archive, class T> > static void member_load( > Archive & ar, > T & t, > const unsigned int file_version > ){ > t.load(ar, file_version); > } > template<class Archive, class T> > static void serialize( > Archive & ar, > T & t, > const unsigned int file_version > ){ ># 118 "/usr/include/boost/serialization/access.hpp" 3 4 > t.serialize(ar, file_version); > } > template<class T> > static void destroy( const T * t) > { > > > delete const_cast<T *>(t); > } > template<class T> > static void construct(T * t){ > > > > ::new(t)T; > } > template<class T, class U> > static T & cast_reference(U & u){ > return static_cast<T &>(u); > } > template<class T, class U> > static T * cast_pointer(U * u){ > return static_cast<T *>(u); > } >}; > >} >} ># 24 "/usr/include/boost/serialization/split_member.hpp" 2 3 4 > >namespace boost { >namespace archive { > namespace detail { > template<class Archive> class interface_oarchive; > template<class Archive> class interface_iarchive; > } >} > >namespace serialization { >namespace detail { > > template<class Archive, class T> > struct member_saver { > static void invoke( > Archive & ar, > const T & t, > const unsigned int file_version > ){ > access::member_save(ar, t, file_version); > } > }; > > template<class Archive, class T> > struct member_loader { > static void invoke( > Archive & ar, > T & t, > const unsigned int file_version > ){ > access::member_load(ar, t, file_version); > } > }; > >} > >template<class Archive, class T> >inline void split_member( > Archive & ar, T & t, const unsigned int file_version >){ > typedef typename mpl::eval_if< > typename Archive::is_saving, > mpl::identity<detail::member_saver<Archive, T> >, > mpl::identity<detail::member_loader<Archive, T> > > >::type typex; > typex::invoke(ar, t, file_version); >} > >} >} ># 34 "/usr/include/boost/serialization/nvp.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/base_object.hpp" 1 3 4 ># 34 "/usr/include/boost/serialization/base_object.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_polymorphic.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/is_polymorphic.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/is_polymorphic.hpp" 2 3 4 > > >namespace boost{ ># 106 "/usr/include/boost/type_traits/is_polymorphic.hpp" 3 4 >template< typename T > struct is_polymorphic : public ::boost::integral_constant<bool,__is_polymorphic(T)> { public: }; > > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 113 "/usr/include/boost/type_traits/is_polymorphic.hpp" 2 3 4 ># 35 "/usr/include/boost/serialization/base_object.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/serialization/force_include.hpp" 1 3 4 ># 39 "/usr/include/boost/serialization/base_object.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/void_cast_fwd.hpp" 1 3 4 ># 23 "/usr/include/boost/serialization/void_cast_fwd.hpp" 3 4 >namespace boost { >namespace serialization { >namespace void_cast_detail{ >class void_caster; >} >template<class Derived, class Base> > >inline const void_cast_detail::void_caster & void_cast_register( > const Derived * dnull = __null, > const Base * bnull = __null >) __attribute__ ((__used__)); >} >} ># 40 "/usr/include/boost/serialization/base_object.hpp" 2 3 4 > >namespace boost { >namespace serialization { > >namespace detail >{ > > > template<class B, class D> > struct base_cast > { > typedef typename > mpl::if_< > is_const<D>, > const B, > B > >::type type; > static_assert(is_const<type>::value == is_const<D>::value, "is_const<type>::value == is_const<D>::value"); > }; > > > template<class Base, class Derived> > struct base_register > { > struct polymorphic { > static void const * invoke(){ > Base const * const b = 0; > Derived const * const d = 0; > return & void_cast_register(d, b); > } > }; > struct non_polymorphic { > static void const * invoke(){ > return 0; > } > }; > static void const * invoke(){ > typedef typename mpl::eval_if< > is_polymorphic<Base>, > mpl::identity<polymorphic>, > mpl::identity<non_polymorphic> > >::type type; > return type::invoke(); > } > }; > >} ># 97 "/usr/include/boost/serialization/base_object.hpp" 3 4 >template<class Base, class Derived> >typename detail::base_cast<Base, Derived>::type & >base_object(Derived &d) >{ > static_assert(( is_base_and_derived<Base,Derived>::value), "( is_base_and_derived<Base,Derived>::value)"); > static_assert(! is_pointer<Derived>::value, "! is_pointer<Derived>::value"); > typedef typename detail::base_cast<Base, Derived>::type type; > detail::base_register<type, Derived>::invoke(); > return access::cast_reference<type, Derived>(d); >} > > >} >} ># 35 "/usr/include/boost/serialization/nvp.hpp" 2 3 4 > ># 1 "/usr/include/boost/serialization/wrapper.hpp" 1 3 4 ># 14 "/usr/include/boost/serialization/wrapper.hpp" 3 4 >namespace boost { namespace serialization { > > > > > > > >template< > class T, > int Level = object_serializable, > int Tracking = track_never, > unsigned int Version = 0, > class ETII = extended_type_info_impl< T > >> >struct wrapper_traits : > public traits<T,Level,Tracking,Version,ETII,mpl::true_> >{}; > >template<class T> >struct is_wrapper_impl : > boost::mpl::eval_if< > boost::is_base_and_derived<basic_traits,T>, > boost::mpl::true_, > boost::mpl::false_ > >::type >{}; > >template<class T> >struct is_wrapper { > typedef typename is_wrapper_impl<const T>::type type; >}; > >} >} ># 37 "/usr/include/boost/serialization/nvp.hpp" 2 3 4 > >namespace boost { >namespace serialization { > >template<class T> >struct nvp : > public std::pair<const char *, T *>, > public wrapper_traits<const nvp< T > > >{ > explicit nvp(const char * name_, T & t) : > > > std::pair<const char *, T *>(name_, (T*)(& t)) > {} > nvp(const nvp & rhs) : > > std::pair<const char *, T *>(rhs.first, (T*)rhs.second) > {} > > const char * name() const { > return this->first; > } > T & value() const { > return *(this->second); > } > > const T & const_value() const { > return *(this->second); > } > > > > > > > > template<class Archivex> > void save( > Archivex & ar, > const unsigned int > ) const { > > ar.operator<<(const_value()); > } > template<class Archivex> > void load( > Archivex & ar, > const unsigned int > ){ > > ar.operator>>(value()); > } > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } >}; > >template<class T> >inline > >const > >nvp< T > make_nvp(const char * name, T & t){ > return nvp< T >(name, t); >} ># 128 "/usr/include/boost/serialization/nvp.hpp" 3 4 >} >} ># 20 "/usr/include/boost/serialization/array.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 24 "/usr/include/boost/serialization/array.hpp" 2 3 4 > > > > >namespace boost { namespace serialization { ># 40 "/usr/include/boost/serialization/array.hpp" 3 4 >template <class Archive> >struct use_array_optimization : boost::mpl::always<boost::mpl::false_> {}; > > >template<class T> >class array : > public wrapper_traits<const array< T > > >{ >public: > typedef T value_type; > > array(value_type* t, std::size_t s) : > m_t(t), > m_element_count(s) > {} > array(const array & rhs) : > m_t(rhs.m_t), > m_element_count(rhs.m_element_count) > {} > array & operator=(const array & rhs){ > m_t = rhs.m_t; > m_element_count = rhs.m_element_count; > } > > > template<class Archive> > void serialize_optimized(Archive &ar, const unsigned int, mpl::false_ ) const > { > > std::size_t c = count(); > value_type * t = address(); > while(0 < c--) > ar & boost::serialization::make_nvp("item", *t++); > } > > > template<class Archive> > void serialize_optimized(Archive &ar, const unsigned int version, mpl::true_ ) > { > boost::serialization::split_member(ar, *this, version); > } > > > template<class Archive> > void save(Archive &ar, const unsigned int version) const > { > ar.save_array(*this,version); > } > > > template<class Archive> > void load(Archive &ar, const unsigned int version) > { > ar.load_array(*this,version); > } > > > template<class Archive> > void serialize(Archive &ar, const unsigned int version) > { > typedef typename > boost::serialization::use_array_optimization<Archive>::template apply< > typename remove_const< T >::type > >::type use_optimized; > serialize_optimized(ar,version,use_optimized()); > } > > value_type* address() const > { > return m_t; > } > > std::size_t count() const > { > return m_element_count; > } > >private: > value_type* m_t; > std::size_t m_element_count; >}; > >template<class T> >inline > >const > >array< T > make_array( T* t, std::size_t s){ > return array< T >(t, s); >} > >template <class Archive, class T, std::size_t N> >void serialize(Archive& ar, boost::array<T,N>& a, const unsigned int ) >{ > ar & boost::serialization::make_nvp("elems",a.elems); >} > >} } ># 51 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/auto_link_archive.hpp" 1 3 4 ># 45 "/usr/include/boost/archive/detail/auto_link_archive.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 46 "/usr/include/boost/archive/detail/auto_link_archive.hpp" 2 3 4 ># 52 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 53 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 > >namespace boost { >namespace archive { > > > > >template<class Archive, class Elem, class Tr> >class basic_binary_oprimitive >{ > > friend class save_access; >protected: > > > > std::basic_streambuf<Elem, Tr> & m_sb; > > Archive * This(){ > return static_cast<Archive *>(this); > } > > boost::scoped_ptr<std::locale> archive_locale; > basic_streambuf_locale_saver<Elem, Tr> locale_saver; > > > template<class T> > void save(const T & t) > { > save_binary(& t, sizeof(T)); > } > > > > > > > void save(const bool t){ > (static_cast<void> (0)); > save_binary(& t, sizeof(t)); > } > void > save(const std::string &s); > > void > save(const std::wstring &ws); > > void > save(const char * t); > void > save(const wchar_t * t); > > void > init(); > > > basic_binary_oprimitive( > std::basic_streambuf<Elem, Tr> & sb, > bool no_codecvt > ); > > ~basic_binary_oprimitive(); >public: > > > > > > struct use_array_optimization { > template <class T> > > > > > > struct apply : public boost::serialization::is_bitwise_serializable< T > {}; > > }; > > > > template <class ValueType> > void save_array(boost::serialization::array<ValueType> const& a, unsigned int) > { > save_binary(a.address(),a.count()*sizeof(ValueType)); > } > > void save_binary(const void *address, std::size_t count); >}; > >template<class Archive, class Elem, class Tr> >inline void >basic_binary_oprimitive<Archive, Elem, Tr>::save_binary( > const void *address, > std::size_t count >){ ># 161 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 3 4 > count = ( count + sizeof(Elem) - 1) > / sizeof(Elem); > (static_cast<void> (0)); > std::streamsize scount = m_sb.sputn( > static_cast<const Elem *>(address), > static_cast<std::streamsize>(count) > ); > if(count != static_cast<std::size_t>(scount)) > boost::serialization::throw_exception( > archive_exception(archive_exception::output_stream_error) > ); > > > > > >} > >} >} > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 183 "/usr/include/boost/archive/basic_binary_oprimitive.hpp" 2 3 4 ># 23 "/usr/include/boost/archive/binary_oarchive_impl.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 1 3 4 ># 26 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 27 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/archive/detail/common_oarchive.hpp" 1 3 4 ># 21 "/usr/include/boost/archive/detail/common_oarchive.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/basic_oarchive.hpp" 1 3 4 ># 28 "/usr/include/boost/archive/detail/basic_oarchive.hpp" 3 4 ># 1 "/usr/include/boost/archive/basic_archive.hpp" 1 3 4 ># 19 "/usr/include/boost/archive/basic_archive.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 20 "/usr/include/boost/archive/basic_archive.hpp" 2 3 4 > ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 22 "/usr/include/boost/archive/basic_archive.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 27 "/usr/include/boost/archive/basic_archive.hpp" 2 3 4 > >namespace boost { >namespace archive { ># 40 "/usr/include/boost/archive/basic_archive.hpp" 3 4 >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_){ > (static_cast<void> (0)); > } > 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; > } > > operator base_type () const { > return t; > } > > 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; > } >}; > >library_version_type >BOOST_ARCHIVE_VERSION(); > >class version_type { >private: > typedef uint_least32_t base_type; > base_type t; >public: > > version_type(): t(0) {}; > explicit version_type(const unsigned int & t_) : t(t_){ > (static_cast<void> (0)); > } > version_type(const version_type & t_) : > t(t_.t) > {} > version_type & operator=(const version_type & rhs){ > t = rhs.t; > return *this; > } > > operator base_type () const { > return t; > } > > 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: > > class_id_type() : t(0) {}; > explicit class_id_type(const int t_) : t(t_){ > (static_cast<void> (0)); > } > explicit class_id_type(const std::size_t t_) : t(t_){ > > } > 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; > } > > > operator int () const { > return t; > } > > 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; > } >}; > > > >class object_id_type { >private: > typedef uint_least32_t base_type; > base_type t; >public: > object_id_type(): t(0) {}; > > explicit object_id_type(const std::size_t & t_) : t(t_){ > (static_cast<void> (0)); > } > 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; > } > > operator uint_least32_t () const { > return t; > } > > 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; > } >}; > > > > > >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<const char * &>(t); > } > operator char * () { > return t; > } > explicit class_name_type(const char *key_) > : t(const_cast<char *>(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, > no_codecvt = 2, > no_xml_tag_checking = 4, > no_tracking = 8, > flags_last = 8 >}; > >const char * >BOOST_ARCHIVE_SIGNATURE(); ># 262 "/usr/include/boost/archive/basic_archive.hpp" 3 4 >class class_id_reference_type : public class_id_type { public: explicit class_id_reference_type(const class_id_type tt) : class_id_type(tt){} }; >class class_id_optional_type : public class_id_type { public: explicit class_id_optional_type(const class_id_type tt) : class_id_type(tt){} }; >class object_reference_type : public object_id_type { public: explicit object_reference_type(const object_id_type tt) : object_id_type(tt){} }; > >} >} > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 270 "/usr/include/boost/archive/basic_archive.hpp" 2 3 4 > > > > > > >namespace boost { namespace serialization { template <> struct implementation_level_impl< const boost::archive::library_version_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } >namespace boost { namespace serialization { template <> struct implementation_level_impl< const boost::archive::version_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } >namespace boost { namespace serialization { template <> struct implementation_level_impl< const boost::archive::class_id_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } >namespace boost { namespace serialization { template <> struct implementation_level_impl< const boost::archive::class_id_reference_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } >namespace boost { namespace serialization { template <> struct implementation_level_impl< const boost::archive::class_id_optional_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } >namespace boost { namespace serialization { template <> struct implementation_level_impl< const boost::archive::class_name_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } >namespace boost { namespace serialization { template <> struct implementation_level_impl< const boost::archive::object_id_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } >namespace boost { namespace serialization { template <> struct implementation_level_impl< const boost::archive::object_reference_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } >namespace boost { namespace serialization { template <> struct implementation_level_impl< const boost::archive::tracking_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } > > > > > > >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< boost::archive::library_version_type > : mpl::true_ {}; }} >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< boost::archive::version_type > : mpl::true_ {}; }} >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< boost::archive::class_id_type > : mpl::true_ {}; }} >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< boost::archive::class_id_reference_type > : mpl::true_ {}; }} >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< boost::archive::class_id_optional_type > : mpl::true_ {}; }} >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< boost::archive::class_name_type > : mpl::true_ {}; }} >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< boost::archive::object_id_type > : mpl::true_ {}; }} >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< boost::archive::object_reference_type > : mpl::true_ {}; }} >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< boost::archive::tracking_type > : mpl::true_ {}; }} ># 29 "/usr/include/boost/archive/detail/basic_oarchive.hpp" 2 3 4 > > ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 32 "/usr/include/boost/archive/detail/basic_oarchive.hpp" 2 3 4 > >namespace boost { >namespace serialization { > class extended_type_info; >} > >namespace archive { >namespace detail { > >class basic_oarchive_impl; >class basic_oserializer; >class basic_pointer_oserializer; > > >class basic_oarchive : > private boost::noncopyable >{ > friend class basic_oarchive_impl; > > > > basic_oarchive_impl * pimpl; > > > > 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); > > > virtual > > ~basic_oarchive(); >public: > > 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(boost::archive::class_id_type(-1)); > } > > void end_preamble(); > library_version_type get_library_version() const; > unsigned int get_flags() const; >}; > >} >} >} > > > > > > > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 105 "/usr/include/boost/archive/detail/basic_oarchive.hpp" 2 3 4 ># 22 "/usr/include/boost/archive/detail/common_oarchive.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/interface_oarchive.hpp" 1 3 4 ># 19 "/usr/include/boost/archive/detail/interface_oarchive.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 20 "/usr/include/boost/archive/detail/interface_oarchive.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/archive/detail/oserializer.hpp" 1 3 4 ># 25 "/usr/include/boost/archive/detail/oserializer.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 26 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 ># 38 "/usr/include/boost/archive/detail/oserializer.hpp" 3 4 ># 1 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 1 3 4 ># 22 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstdarg" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdarg" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdarg" 3 > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/stdarg.h" 1 3 4 ># 43 "/usr/include/c++/4.9.0/cstdarg" 2 3 ># 52 "/usr/include/c++/4.9.0/cstdarg" 3 >namespace std >{ > using ::va_list; >} ># 23 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 24 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/serialization/static_warning.hpp" 1 3 4 ># 73 "/usr/include/boost/serialization/static_warning.hpp" 3 4 ># 1 "/usr/include/boost/mpl/print.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/print.hpp" 3 4 >namespace boost { namespace mpl { > >namespace aux { ># 40 "/usr/include/boost/mpl/print.hpp" 3 4 >} > > >template <class T> >struct print > : mpl::identity<T> > > > >{ > > > > > > enum { > n = > > > > sizeof(T) > -1 > > }; > >}; > > > > > > > >}} ># 74 "/usr/include/boost/serialization/static_warning.hpp" 2 3 4 > > >namespace boost { >namespace serialization { > >template<int L> >struct BOOST_SERIALIZATION_STATIC_WARNING_LINE{}; > >template<bool B, int L> >struct static_warning_test{ > typename boost::mpl::eval_if_c< > B, > boost::mpl::true_, > typename boost::mpl::identity< > boost::mpl::print< > BOOST_SERIALIZATION_STATIC_WARNING_LINE<L> > > > > > >::type type; >}; > >template<int i> >struct BOOST_SERIALIZATION_SS {}; > >} >} ># 28 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/serialization/config.hpp" 1 3 4 ># 81 "/usr/include/boost/serialization/config.hpp" 3 4 ># 1 "/usr/include/boost/config/auto_link.hpp" 1 3 4 ># 82 "/usr/include/boost/serialization/config.hpp" 2 3 4 ># 32 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/singleton.hpp" 1 3 4 ># 37 "/usr/include/boost/serialization/singleton.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 38 "/usr/include/boost/serialization/singleton.hpp" 2 3 4 ># 47 "/usr/include/boost/serialization/singleton.hpp" 3 4 >namespace boost { >namespace serialization { ># 80 "/usr/include/boost/serialization/singleton.hpp" 3 4 >class singleton_module : > public boost::noncopyable >{ >private: > static bool & get_lock(){ > static bool lock = false; > return lock; > } >public: > > > > static void lock(){ > get_lock() = true; > } > static void unlock(){ > get_lock() = false; > } > static bool is_locked() { > return get_lock(); > } >}; > >namespace detail { > >template<class T> >class singleton_wrapper : public T >{ >public: > static bool m_is_destroyed; > ~singleton_wrapper(){ > m_is_destroyed = true; > } >}; > >template<class T> >bool detail::singleton_wrapper< T >::m_is_destroyed = false; > >} > >template <class T> >class singleton : public singleton_module >{ >private: > static T & instance; > > static void use(T const &) {} > static T & get_instance() { > static detail::singleton_wrapper< T > t; > > > (static_cast<void> (0)); > use(instance); > return static_cast<T &>(t); > } >public: > static T & get_mutable_instance(){ > (static_cast<void> (0)); > return get_instance(); > } > static const T & get_const_instance(){ > return get_instance(); > } > static bool is_destroyed(){ > return detail::singleton_wrapper< T >::m_is_destroyed; > } >}; > >template<class T> > T & singleton< T >::instance = singleton< T >::get_instance(); > >} >} ># 33 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/extended_type_info.hpp" 1 3 4 ># 21 "/usr/include/boost/serialization/extended_type_info.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstdarg" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdarg" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdarg" 3 ># 22 "/usr/include/boost/serialization/extended_type_info.hpp" 2 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 23 "/usr/include/boost/serialization/extended_type_info.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 30 "/usr/include/boost/serialization/extended_type_info.hpp" 2 3 4 > > > > > > > >namespace boost { >namespace serialization { > >namespace void_cast_detail{ > class void_caster; >} > >class extended_type_info : > private boost::noncopyable >{ >private: > friend class boost::serialization::void_cast_detail::void_caster; > > > > > const unsigned int m_type_info_key; > virtual bool is_less_than(const extended_type_info & ) const = 0; > virtual bool is_equal(const extended_type_info & ) const = 0; > const char * m_key; > >protected: > void key_unregister() const; > void key_register() const; > > > > extended_type_info( > const unsigned int type_info_key, > const char * key > ); > > > virtual > > ~extended_type_info(); >public: > const char * get_key() const { > return m_key; > } > virtual const char * get_debug_info() const = 0; > bool operator<(const extended_type_info &rhs) const; > bool operator==(const extended_type_info &rhs) const; > bool operator!=(const extended_type_info &rhs) const { > return !(operator==(rhs)); > } > > > static const extended_type_info * > find(const char *key); > > virtual void * construct(unsigned int = 0, ...) const = 0; > virtual void destroy(void const * const ) const = 0; >}; > >template<class T> >struct guid_defined : boost::mpl::false_ {}; > >namespace ext { > template <typename T> > struct guid_impl > { > static inline const char * call() > { > return __null; > } > }; >} > >template<class T> >inline const char * guid(){ > return ext::guid_impl<T>::call(); >} > >} >} > > > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 119 "/usr/include/boost/serialization/extended_type_info.hpp" 2 3 4 ># 34 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/factory.hpp" 1 3 4 ># 19 "/usr/include/boost/serialization/factory.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstdarg" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdarg" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdarg" 3 ># 20 "/usr/include/boost/serialization/factory.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/preprocessor/comparison/greater.hpp" 1 3 4 ># 17 "/usr/include/boost/preprocessor/comparison/greater.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/comparison/less.hpp" 1 3 4 ># 18 "/usr/include/boost/preprocessor/comparison/less.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/comparison/not_equal.hpp" 1 3 4 ># 19 "/usr/include/boost/preprocessor/comparison/less.hpp" 2 3 4 ># 18 "/usr/include/boost/preprocessor/comparison/greater.hpp" 2 3 4 ># 24 "/usr/include/boost/serialization/factory.hpp" 2 3 4 > > >namespace std{ > > > >} > >namespace boost { >namespace serialization { > > >template<class T, int N> >T * factory(std::va_list){ > (static_cast<void> (0)); > > return __null; >} > >} >} ># 35 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 42 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 2 3 4 > > > > > > >namespace boost { >namespace serialization { >namespace typeid_system { > >class extended_type_info_typeid_0 : > public extended_type_info >{ > virtual const char * get_debug_info() const { > if(static_cast<const std::type_info *>(0) == m_ti) > return static_cast<const char *>(0); > return m_ti->name(); > } >protected: > const std::type_info * m_ti; > extended_type_info_typeid_0(const char * key); > ~extended_type_info_typeid_0(); > void type_register(const std::type_info & ti); > void type_unregister(); > const extended_type_info * > get_extended_type_info(const std::type_info & ti) const; >public: > virtual bool > is_less_than(const extended_type_info &rhs) const; > virtual bool > is_equal(const extended_type_info &rhs) const; > const std::type_info & get_typeid() const { > return *m_ti; > } >}; > >} > >template<class T> >class extended_type_info_typeid : > public typeid_system::extended_type_info_typeid_0, > public singleton<extended_type_info_typeid< T > > >{ >public: > extended_type_info_typeid() : > typeid_system::extended_type_info_typeid_0(get_key()) > { > type_register(typeid(T)); > key_register(); > } > ~extended_type_info_typeid(){ > key_unregister(); > type_unregister(); > } > > > const extended_type_info * > get_derived_extended_type_info(const T & t) const { > > > typedef boost::serialization::BOOST_SERIALIZATION_SS< sizeof( boost::serialization::static_warning_test< boost::is_polymorphic< T >::value, 102 > ) > STATIC_WARNING_LINE102;; > return > typeid_system::extended_type_info_typeid_0::get_extended_type_info( > typeid(t) > ); > } > const char * get_key() const { > return boost::serialization::guid< T >(); > } > virtual void * construct(unsigned int count, ...) const{ > > std::va_list ap; > __builtin_va_start(ap,count); > switch(count){ > case 0: > return factory<typename boost::remove_const< T >::type, 0>(ap); > case 1: > return factory<typename boost::remove_const< T >::type, 1>(ap); > case 2: > return factory<typename boost::remove_const< T >::type, 2>(ap); > case 3: > return factory<typename boost::remove_const< T >::type, 3>(ap); > case 4: > return factory<typename boost::remove_const< T >::type, 4>(ap); > default: > (static_cast<void> (0)); > > return __null; > } > } > virtual void destroy(void const * const p) const { > boost::serialization::access::destroy( > static_cast<T const *>(p) > ); > > } >}; > >} >} > > > > > > > > namespace boost { > namespace serialization { > template<class T> > struct extended_type_info_impl { > typedef typename > boost::serialization::extended_type_info_typeid< T > type; > }; > } > } > > > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 164 "/usr/include/boost/serialization/extended_type_info_typeid.hpp" 2 3 4 ># 39 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 > > ># 1 "/usr/include/boost/serialization/smart_cast.hpp" 1 3 4 ># 61 "/usr/include/boost/serialization/smart_cast.hpp" 3 4 >namespace boost { >namespace serialization { >namespace smart_cast_impl { > > template<class T> > struct reference { > > struct polymorphic { > > struct linear { > template<class U> > static T cast(U & u){ > return static_cast< T >(u); > } > }; > > struct cross { > template<class U> > static T cast(U & u){ > return dynamic_cast< T >(u); > } > }; > > template<class U> > static T cast(U & u){ ># 98 "/usr/include/boost/serialization/smart_cast.hpp" 3 4 > typedef typename mpl::eval_if< > typename mpl::and_< > mpl::not_<is_base_and_derived< > typename remove_reference< T >::type, > U > > >, > mpl::not_<is_base_and_derived< > U, > typename remove_reference< T >::type > > > > >, > > mpl::identity<cross>, > mpl::identity<linear> > >::type typex; > > return typex::cast(u); > > } > }; > > struct non_polymorphic { > template<class U> > static T cast(U & u){ > return static_cast< T >(u); > } > }; > template<class U> > static T cast(U & u){ > > > > > > > > typedef typename mpl::eval_if< > boost::is_polymorphic<U>, > mpl::identity<polymorphic>, > mpl::identity<non_polymorphic> > >::type typex; > return typex::cast(u); > > } > }; > > template<class T> > struct pointer { > > struct polymorphic { ># 202 "/usr/include/boost/serialization/smart_cast.hpp" 3 4 > template<class U> > static T cast(U * u){ > T tmp = dynamic_cast< T >(u); > > > > return tmp; > } > > }; > > struct non_polymorphic { > template<class U> > static T cast(U * u){ > return static_cast< T >(u); > } > }; > > template<class U> > static T cast(U * u){ > > > > > > > > typedef typename mpl::eval_if< > boost::is_polymorphic<U>, > mpl::identity<polymorphic>, > mpl::identity<non_polymorphic> > >::type typex; > return typex::cast(u); > > } > > }; > > template<class TPtr> > struct void_pointer { > template<class UPtr> > static TPtr cast(UPtr uptr){ > return static_cast<TPtr>(uptr); > } > }; > > template<class T> > struct error { > > > > template<class U> > static T cast(U u){ > static_assert(sizeof(T)==0, "sizeof(T)==0"); > return * static_cast<T *>(__null); > } > }; > >} > > > > > > >template<class T, class U> >T smart_cast(U u) { > typedef > typename mpl::eval_if< > typename mpl::or_< > boost::is_same<void *, U>, > boost::is_same<void *, T>, > boost::is_same<const void *, U>, > boost::is_same<const void *, T> > >, > mpl::identity<smart_cast_impl::void_pointer< T > >, > > typename mpl::eval_if<boost::is_pointer<U>, > mpl::identity<smart_cast_impl::pointer< T > >, > > typename mpl::eval_if<boost::is_reference<U>, > mpl::identity<smart_cast_impl::reference< T > >, > > mpl::identity<smart_cast_impl::error< T > > > > > > > > >::type typex; > return typex::cast(u); >} > > > >template<class T, class U> >T smart_cast_reference(U & u) { > return smart_cast_impl::reference< T >::cast(u); >} > >} >} ># 42 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/assume_abstract.hpp" 1 3 4 ># 29 "/usr/include/boost/serialization/assume_abstract.hpp" 3 4 >namespace boost { >namespace serialization { > template<class T> > struct is_abstract : boost::is_abstract< T > {} ; >} >} ># 43 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/type_traits/remove_extent.hpp" 1 3 4 ># 21 "/usr/include/boost/type_traits/remove_extent.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/type_trait_def.hpp" 2 3 4 ># 22 "/usr/include/boost/type_traits/remove_extent.hpp" 2 3 4 > > > >namespace boost { > >template< typename T > struct remove_extent { public: typedef T type; }; > > >template< typename T, std::size_t N > struct remove_extent<T[N]> { public: typedef T type; }; >template< typename T, std::size_t N > struct remove_extent<T const[N]> { public: typedef T const type; }; >template< typename T, std::size_t N > struct remove_extent<T volatile[N]> { public: typedef T volatile type; }; >template< typename T, std::size_t N > struct remove_extent<T const volatile[N]> { public: typedef T const volatile type; }; > >template< typename T > struct remove_extent<T[]> { public: typedef T type; }; >template< typename T > struct remove_extent<T const[]> { public: typedef T const type; }; >template< typename T > struct remove_extent<T volatile[]> { public: typedef T volatile type; }; >template< typename T > struct remove_extent<T const volatile[]> { public: typedef T const volatile type; }; > > > >} > > > ># 1 "/usr/include/boost/type_traits/detail/type_trait_undef.hpp" 1 3 4 ># 47 "/usr/include/boost/type_traits/remove_extent.hpp" 2 3 4 ># 50 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 > ># 1 "/usr/include/boost/serialization/serialization.hpp" 1 3 4 ># 14 "/usr/include/boost/serialization/serialization.hpp" 3 4 ># 1 "/usr/include/boost/serialization/strong_typedef.hpp" 1 3 4 ># 15 "/usr/include/boost/serialization/serialization.hpp" 2 3 4 ># 59 "/usr/include/boost/serialization/serialization.hpp" 3 4 >namespace boost { >namespace serialization { > >struct version_type : boost::totally_ordered1< version_type , boost::totally_ordered2< version_type, unsigned int > > { unsigned int t; explicit version_type(const unsigned int t_) : t(t_) {}; version_type(): t() {}; version_type(const version_type & t_) : t(t_.t){} version_type & operator=(const version_type & rhs) { t = rhs.t; return *this;} version_type & operator=(const unsigned int & rhs) { t = rhs; return *this;} operator const unsigned int & () const {return t; } operator unsigned int & () { return t; } bool operator==(const version_type & rhs) const { return t == rhs.t; } bool operator<(const version_type & rhs) const { return t < rhs.t; } }; > > >template<class Archive, class T> >inline void serialize( > Archive & ar, T & t, const unsigned int file_version >){ > access::serialize(ar, t, static_cast<unsigned int>(file_version)); >} > > >template<class Archive, class T> >inline void save_construct_data( > Archive & , > const T * , > const unsigned int >){ > > >} > > >template<class Archive, class T> >inline void load_construct_data( > Archive & , > T * t, > const unsigned int >){ > > > > access::construct(t); >} ># 112 "/usr/include/boost/serialization/serialization.hpp" 3 4 >template<class Archive, class T> >inline void serialize_adl( > Archive & ar, > T & t, > const unsigned int file_version >){ ># 127 "/usr/include/boost/serialization/serialization.hpp" 3 4 > const version_type v(file_version); > serialize(ar, t, v); > > > >} > >template<class Archive, class T> >inline void save_construct_data_adl( > Archive & ar, > const T * t, > const unsigned int file_version >){ > > > const version_type v(file_version); > save_construct_data(ar, t, v); > > > >} > >template<class Archive, class T> >inline void load_construct_data_adl( > Archive & ar, > T * t, > const unsigned int file_version >){ > > > const version_type v(file_version); > load_construct_data(ar, t, v); > > > >} > >} >} ># 52 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/serialization/void_cast.hpp" 1 3 4 ># 29 "/usr/include/boost/serialization/void_cast.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/is_virtual_base_of.hpp" 1 3 4 ># 17 "/usr/include/boost/type_traits/is_virtual_base_of.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 18 "/usr/include/boost/type_traits/is_virtual_base_of.hpp" 2 3 4 > >namespace boost { >namespace detail { ># 28 "/usr/include/boost/type_traits/is_virtual_base_of.hpp" 3 > > >template<typename Base, typename Derived, typename tag> >struct is_virtual_base_of_impl >{ > static const bool value = false; >}; > >template<typename Base, typename Derived> >struct is_virtual_base_of_impl<Base, Derived, mpl::true_> >{ ># 55 "/usr/include/boost/type_traits/is_virtual_base_of.hpp" 3 > struct boost_type_traits_internal_struct_X : public Derived, virtual Base > { > boost_type_traits_internal_struct_X(); > boost_type_traits_internal_struct_X(const boost_type_traits_internal_struct_X&); > boost_type_traits_internal_struct_X& operator=(const boost_type_traits_internal_struct_X&); > ~boost_type_traits_internal_struct_X()throw(); > }; > struct boost_type_traits_internal_struct_Y : public Derived > { > boost_type_traits_internal_struct_Y(); > boost_type_traits_internal_struct_Y(const boost_type_traits_internal_struct_Y&); > boost_type_traits_internal_struct_Y& operator=(const boost_type_traits_internal_struct_Y&); > ~boost_type_traits_internal_struct_Y()throw(); > }; > > static const bool value = (sizeof(boost_type_traits_internal_struct_X)==sizeof(boost_type_traits_internal_struct_Y)); >}; > >template<typename Base, typename Derived> >struct is_virtual_base_of_impl2 >{ > typedef typename mpl::and_<is_base_of<Base, Derived>, mpl::not_<is_same<Base, Derived> > >::type tag_type; > typedef is_virtual_base_of_impl<Base, Derived, tag_type> imp; > static const bool value = imp::value; >}; > > > > > >} > >template< typename Base, typename Derived > struct is_virtual_base_of : public ::boost::integral_constant<bool,(::boost::detail::is_virtual_base_of_impl2<Base,Derived>::value)> { public: }; > > > > > > > >template< typename Base, typename Derived > struct is_virtual_base_of< Base&,Derived > : public ::boost::integral_constant<bool,false> { public: }; >template< typename Base, typename Derived > struct is_virtual_base_of< Base,Derived& > : public ::boost::integral_constant<bool,false> { public: }; >template< typename Base, typename Derived > struct is_virtual_base_of< Base&,Derived& > : public ::boost::integral_constant<bool,false> { public: }; > > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 103 "/usr/include/boost/type_traits/is_virtual_base_of.hpp" 2 3 ># 30 "/usr/include/boost/serialization/void_cast.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 34 "/usr/include/boost/serialization/void_cast.hpp" 2 3 4 > > > > > > >namespace boost { >namespace serialization { > >class extended_type_info; > > > > > > >void const * >void_upcast( > extended_type_info const & derived, > extended_type_info const & base, > void const * const t >); > >inline void * >void_upcast( > extended_type_info const & derived, > extended_type_info const & base, > void * const t >){ > return const_cast<void*>(void_upcast( > derived, > base, > const_cast<void const *>(t) > )); >} > >void const * >void_downcast( > extended_type_info const & derived, > extended_type_info const & base, > void const * const t >); > >inline void * >void_downcast( > extended_type_info const & derived, > extended_type_info const & base, > void * const t >){ > return const_cast<void*>(void_downcast( > derived, > base, > const_cast<void const *>(t) > )); >} > >namespace void_cast_detail { > >class void_caster : > private boost::noncopyable >{ > friend > void const * > boost::serialization::void_upcast( > extended_type_info const & derived, > extended_type_info const & base, > void const * const > ); > friend > void const * > boost::serialization::void_downcast( > extended_type_info const & derived, > extended_type_info const & base, > void const * const > ); >protected: > void recursive_register(bool includes_virtual_base = false) const; > void recursive_unregister() const; > virtual bool has_virtual_base() const = 0; >public: > > const extended_type_info * m_derived; > const extended_type_info * m_base; > std::ptrdiff_t m_difference; > void_caster const * const m_parent; > > > > > > > bool operator<(const void_caster & rhs) const; > > const void_caster & operator*(){ > return *this; > } > > virtual void const * upcast(void const * const t) const = 0; > virtual void const * downcast(void const * const t) const = 0; > > void_caster( > extended_type_info const * derived, > extended_type_info const * base, > std::ptrdiff_t difference = 0, > void_caster const * const parent = 0 > ) : > m_derived(derived), > m_base(base), > m_difference(difference), > m_parent(parent) > {} > virtual ~void_caster(){} >}; > > > > > > >template <class Derived, class Base> >class void_caster_primitive : > public void_caster >{ > virtual void const * downcast(void const * const t) const { > const Derived * d = > boost::serialization::smart_cast<const Derived *, const Base *>( > static_cast<const Base *>(t) > ); > return d; > } > virtual void const * upcast(void const * const t) const { > const Base * b = > boost::serialization::smart_cast<const Base *, const Derived *>( > static_cast<const Derived *>(t) > ); > return b; > } > virtual bool has_virtual_base() const { > return false; > } >public: > void_caster_primitive(); > virtual ~void_caster_primitive(); >}; > >template <class Derived, class Base> >void_caster_primitive<Derived, Base>::void_caster_primitive() : > void_caster( > & type_info_implementation<Derived>::type::get_const_instance(), > & type_info_implementation<Base>::type::get_const_instance(), > > > reinterpret_cast<std::ptrdiff_t>( > static_cast<Derived *>( > reinterpret_cast<Base *>(1) > ) > ) - 1 > ) >{ > recursive_register(); >} > >template <class Derived, class Base> >void_caster_primitive<Derived, Base>::~void_caster_primitive(){ > recursive_unregister(); >} > >template <class Derived, class Base> >class void_caster_virtual_base : > public void_caster >{ > virtual bool has_virtual_base() const { > return true; > } >public: > virtual void const * downcast(void const * const t) const { > const Derived * d = > dynamic_cast<const Derived *>( > static_cast<const Base *>(t) > ); > return d; > } > virtual void const * upcast(void const * const t) const { > const Base * b = > dynamic_cast<const Base *>( > static_cast<const Derived *>(t) > ); > return b; > } > void_caster_virtual_base(); > virtual ~void_caster_virtual_base(); >}; > > > > > >template <class Derived, class Base> >void_caster_virtual_base<Derived,Base>::void_caster_virtual_base() : > void_caster( > & (type_info_implementation<Derived>::type::get_const_instance()), > & (type_info_implementation<Base>::type::get_const_instance()) > ) >{ > recursive_register(true); >} > >template <class Derived, class Base> >void_caster_virtual_base<Derived,Base>::~void_caster_virtual_base(){ > recursive_unregister(); >} > >template <class Derived, class Base> >struct void_caster_base : > public void_caster >{ > typedef > typename mpl::eval_if<boost::is_virtual_base_of<Base,Derived>, > mpl::identity< > void_cast_detail::void_caster_virtual_base<Derived, Base> > > > , > mpl::identity< > void_cast_detail::void_caster_primitive<Derived, Base> > > > >::type type; >}; > >} > >template<class Derived, class Base> > >inline const void_cast_detail::void_caster & void_cast_register( > Derived const * , > Base const * >){ > typedef > typename mpl::eval_if<boost::is_virtual_base_of<Base,Derived>, > mpl::identity< > void_cast_detail::void_caster_virtual_base<Derived, Base> > > > , > mpl::identity< > void_cast_detail::void_caster_primitive<Derived, Base> > > > >::type typex; > return singleton<typex>::get_const_instance(); >} > >template<class Derived, class Base> >class void_caster : > public void_cast_detail::void_caster_base<Derived, Base>::type >{ >}; > >} >} > > > > > ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 297 "/usr/include/boost/serialization/void_cast.hpp" 2 3 4 ># 58 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 > ># 1 "/usr/include/boost/serialization/collection_size_type.hpp" 1 3 4 ># 12 "/usr/include/boost/serialization/collection_size_type.hpp" 3 4 ># 1 "/usr/include/boost/serialization/split_free.hpp" 1 3 4 ># 24 "/usr/include/boost/serialization/split_free.hpp" 3 4 >namespace boost { >namespace archive { > namespace detail { > template<class Archive> class interface_oarchive; > template<class Archive> class interface_iarchive; > } >} > >namespace serialization { > > >template<class Archive, class T> >struct free_saver { > static void invoke( > Archive & ar, > const T & t, > const unsigned int file_version > ){ > > > const version_type v(file_version); > save(ar, t, v); > } >}; >template<class Archive, class T> >struct free_loader { > static void invoke( > Archive & ar, > T & t, > const unsigned int file_version > ){ > > > const version_type v(file_version); > load(ar, t, v); > } >}; > > >template<class Archive, class T> >inline void split_free( > Archive & ar, > T & t, > const unsigned int file_version >){ > typedef typename mpl::eval_if< > typename Archive::is_saving, > mpl::identity< free_saver<Archive, T> >, > mpl::identity< free_loader<Archive, T> > > >::type typex; > typex::invoke(ar, t, file_version); >} > >} >} ># 13 "/usr/include/boost/serialization/collection_size_type.hpp" 2 3 4 > > >namespace boost { >namespace serialization { > > > >class collection_size_type { >private: > typedef std::size_t base_type; > base_type t; >public: > collection_size_type(): t(0) {}; > explicit collection_size_type(const std::size_t & t_) : > t(t_) > {} > collection_size_type(const collection_size_type & t_) : > t(t_.t) > {} > collection_size_type & operator=(const collection_size_type & rhs){ > t = rhs.t; > return *this; > } > collection_size_type & operator=(const unsigned int & rhs){ > t = rhs; > return *this; > } > > operator base_type () const { > return t; > } > > operator base_type & () { > return t; > } > bool operator==(const collection_size_type & rhs) const { > return t == rhs.t; > } > bool operator<(const collection_size_type & rhs) const { > return t < rhs.t; > } >}; > > >} } > >namespace boost { namespace serialization { template <> struct implementation_level_impl< const collection_size_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< collection_size_type > : mpl::true_ {}; }} ># 60 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/archive/detail/basic_oserializer.hpp" 1 3 4 ># 25 "/usr/include/boost/archive/detail/basic_oserializer.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/basic_serializer.hpp" 1 3 4 ># 19 "/usr/include/boost/archive/detail/basic_serializer.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 20 "/usr/include/boost/archive/detail/basic_serializer.hpp" 2 3 4 ># 31 "/usr/include/boost/archive/detail/basic_serializer.hpp" 3 4 >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) > { > (static_cast<void> (0)); > } >public: > inline bool > operator<(const basic_serializer & rhs) const { > > > > > 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) > {} >}; > >} >} >} ># 26 "/usr/include/boost/archive/detail/basic_oserializer.hpp" 2 3 4 > ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 28 "/usr/include/boost/archive/detail/basic_oserializer.hpp" 2 3 4 > > > > > > >namespace boost { >namespace serialization { > class extended_type_info; >} > > >namespace archive { >namespace detail { > >class basic_oarchive; >class basic_pointer_oserializer; > >class basic_oserializer : > public basic_serializer >{ >private: > basic_pointer_oserializer *m_bpos; >protected: > explicit basic_oserializer( > const boost::serialization::extended_type_info & type_ > ); > > > virtual > > ~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; > > virtual bool class_info() const = 0; > > virtual bool tracking(const unsigned int flags) const = 0; > > virtual version_type version() const = 0; > > virtual bool is_polymorphic() const = 0; >}; > >} >} >} > > > > > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 92 "/usr/include/boost/archive/detail/basic_oserializer.hpp" 2 3 4 ># 65 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/basic_pointer_oserializer.hpp" 1 3 4 ># 24 "/usr/include/boost/archive/detail/basic_pointer_oserializer.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 25 "/usr/include/boost/archive/detail/basic_pointer_oserializer.hpp" 2 3 4 > > > > > > >namespace boost { >namespace serialization { > class extended_type_info; >} > >namespace archive { >namespace detail { > >class basic_oarchive; >class basic_oserializer; > >class basic_pointer_oserializer : > public basic_serializer >{ >protected: > explicit basic_pointer_oserializer( > const boost::serialization::extended_type_info & type_ > ); >public: > > > virtual > > ~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; >}; > >} >} >} > > > > > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 71 "/usr/include/boost/archive/detail/basic_pointer_oserializer.hpp" 2 3 4 ># 66 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/archive_serializer_map.hpp" 1 3 4 ># 25 "/usr/include/boost/archive/detail/archive_serializer_map.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 26 "/usr/include/boost/archive/detail/archive_serializer_map.hpp" 2 3 4 > >namespace boost { > >namespace serialization { > class extended_type_info; >} > >namespace archive { >namespace detail { > >class basic_serializer; > >template<class Archive> >class >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_ > ); >}; > >} >} >} > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 54 "/usr/include/boost/archive/detail/archive_serializer_map.hpp" 2 3 4 ># 67 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/check.hpp" 1 3 4 ># 44 "/usr/include/boost/archive/detail/check.hpp" 3 4 >namespace boost { >namespace archive { >namespace detail { > > > >template<class T> >inline void check_object_level(){ > typedef > typename mpl::greater_equal< > serialization::implementation_level< T >, > mpl::int_<serialization::primitive_type> > >::type typex; > > > > static_assert(typex::value, "typex::value"); >} > >template<class T> >inline void check_object_versioning(){ > typedef > typename mpl::or_< > typename mpl::greater< > serialization::implementation_level< T >, > mpl::int_<serialization::object_serializable> > >, > typename mpl::equal_to< > serialization::version< T >, > mpl::int_<0> > > > > typex; > > > static_assert(typex::value, "typex::value"); >} > >template<class T> >inline void check_object_tracking(){ > > > static_assert(! boost::is_const< T >::value, "! boost::is_const< T >::value"); > typedef typename mpl::equal_to< > serialization::tracking_level< T >, > mpl::int_<serialization::track_never> > >::type typex; ># 98 "/usr/include/boost/archive/detail/check.hpp" 3 4 > typedef boost::serialization::BOOST_SERIALIZATION_SS< sizeof( boost::serialization::static_warning_test< typex::value, 98 > ) > STATIC_WARNING_LINE98;; >} > > > >template<class T> >inline void check_pointer_level(){ > > > typedef > typename mpl::or_< > typename mpl::greater< > serialization::implementation_level< T >, > mpl::int_<serialization::object_serializable> > >, > typename mpl::not_< > typename mpl::equal_to< > serialization::tracking_level< T >, > mpl::int_<serialization::track_selectively> > > > > > > typex; ># 137 "/usr/include/boost/archive/detail/check.hpp" 3 4 > typedef boost::serialization::BOOST_SERIALIZATION_SS< sizeof( boost::serialization::static_warning_test< typex::value, 137 > ) > STATIC_WARNING_LINE137;; >} > >template<class T> >void inline check_pointer_tracking(){ > typedef typename mpl::greater< > serialization::tracking_level< T >, > mpl::int_<serialization::track_never> > >::type typex; > > > typedef boost::serialization::BOOST_SERIALIZATION_SS< sizeof( boost::serialization::static_warning_test< typex::value, 148 > ) > STATIC_WARNING_LINE148;; >} > >template<class T> >inline void check_const_loading(){ > typedef > typename mpl::or_< > typename boost::serialization::is_wrapper< T >, > typename mpl::not_< > typename boost::is_const< T > > > > >::type typex; > > > static_assert(typex::value, "typex::value"); >} > >} >} >} ># 68 "/usr/include/boost/archive/detail/oserializer.hpp" 2 3 4 > >namespace boost { > >namespace serialization { > class extended_type_info; >} > >namespace archive { > > > >class save_access { >public: > template<class Archive> > static void end_preamble(Archive & ar){ > ar.end_preamble(); > } > template<class Archive, class T> > static void save_primitive(Archive & ar, const T & t){ > ar.end_preamble(); > ar.save(t); > } >}; > >namespace detail { > > > > > > >template<class Archive, class T> >class oserializer : public basic_oserializer >{ >private: > > >public: > explicit oserializer() : > basic_oserializer( > boost::serialization::singleton< > typename > boost::serialization::type_info_implementation< T >::type > >::get_const_instance() > ) > {} > virtual void save_object_data( > basic_oarchive & ar, > const void *x > ) const __attribute__ ((__used__)); > virtual bool class_info() const { > return boost::serialization::implementation_level< T >::value > >= boost::serialization::object_class_info; > } > virtual bool tracking(const unsigned int ) 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(){} >}; > > > > > >template<class Archive, class T> > void oserializer<Archive, T>::save_object_data( > basic_oarchive & ar, > const void *x >) const { > > > static_assert(boost::is_const< T >::value == false, "boost::is_const< T >::value == false"); > boost::serialization::serialize_adl( > boost::serialization::smart_cast_reference<Archive &>(ar), > * static_cast<T *>(const_cast<void *>(x)), > version() > ); >} > > > > > > >template<class Archive, class T> >class pointer_oserializer : > public basic_pointer_oserializer >{ >private: > const basic_oserializer & > get_basic_serializer() const { > return boost::serialization::singleton< > oserializer<Archive, T> > >::get_const_instance(); > } > virtual void save_object_ptr( > basic_oarchive & ar, > const void * x > ) const __attribute__ ((__used__)); >public: > pointer_oserializer(); > ~pointer_oserializer(); >}; > > > > > >template<class Archive, class T> > void pointer_oserializer<Archive, T>::save_object_ptr( > basic_oarchive & ar, > const void * x >) const { > (static_cast<void> (0)); > > > T * t = static_cast<T *>(const_cast<void *>(x)); > const unsigned int file_version = boost::serialization::version< T >::value; > Archive & ar_impl > = boost::serialization::smart_cast_reference<Archive &>(ar); > boost::serialization::save_construct_data_adl<Archive, T>( > ar_impl, > t, > file_version > ); > ar_impl << boost::serialization::make_nvp(__null, * t); >} > >template<class Archive, class T> >pointer_oserializer<Archive, T>::pointer_oserializer() : > basic_pointer_oserializer( > boost::serialization::singleton< > typename > boost::serialization::type_info_implementation< T >::type > >::get_const_instance() > ) >{ > > boost::serialization::singleton< > oserializer<Archive, T> > >::get_mutable_instance().set_bpos(this); > archive_serializer_map<Archive>::insert(this); >} > >template<class Archive, class T> >pointer_oserializer<Archive, T>::~pointer_oserializer(){ > archive_serializer_map<Archive>::erase(this); >} > >template<class Archive> >struct save_non_pointer_type { > > > struct save_primitive { > template<class T> > static void invoke(Archive & ar, const T & t){ > save_access::save_primitive(ar, t); > } > }; > > struct save_only { > template<class T> > static void invoke(Archive & ar, const T & t){ > > > boost::serialization::serialize_adl( > ar, > const_cast<T &>(t), > ::boost::serialization::version< T >::value > ); > } > }; > > > struct save_standard { > template<class T> > static void invoke(Archive &ar, const T & t){ > ar.save_object( > & t, > boost::serialization::singleton< > oserializer<Archive, T> > >::get_const_instance() > ); > } > }; > > > > struct save_conditional { > template<class T> > static void invoke(Archive &ar, const T &t){ > > save_standard::invoke(ar, t); > > > } > }; > > > template<class T> > static void invoke(Archive & ar, const T & t){ > typedef > typename mpl::eval_if< > > mpl::equal_to< > boost::serialization::implementation_level< T >, > mpl::int_<boost::serialization::primitive_type> > >, > mpl::identity<save_primitive>, > > typename mpl::eval_if< > > mpl::greater_equal< > boost::serialization::implementation_level< T >, > mpl::int_<boost::serialization::object_class_info> > >, > > mpl::identity<save_standard>, > > typename mpl::eval_if< > > mpl::equal_to< > boost::serialization::tracking_level< T >, > mpl::int_<boost::serialization::track_never> > >, > > mpl::identity<save_only>, > > > mpl::identity<save_conditional> > > > >::type typex; > check_object_versioning< T >(); > typex::invoke(ar, t); > } > template<class T> > static void invoke(Archive & ar, T & t){ > check_object_level< T >(); > check_object_tracking< T >(); > invoke(ar, const_cast<const T &>(t)); > } >}; > >template<class Archive> >struct save_pointer_type { > struct abstract > { > template<class T> > static const basic_pointer_oserializer * register_type(Archive & ){ > > static_assert(boost::is_polymorphic< T >::value, "boost::is_polymorphic< T >::value"); > return __null; > } > }; > > struct non_abstract > { > template<class T> > static const basic_pointer_oserializer * register_type(Archive & ar){ > return ar.register_type(static_cast<T *>(__null)); > } > }; > > template<class T> > static const basic_pointer_oserializer * register_type(Archive &ar, T & ){ > > > > > typedef > typename mpl::eval_if< > boost::serialization::is_abstract< T >, > mpl::identity<abstract>, > mpl::identity<non_abstract> > >::type typex; > return typex::template register_type< T >(ar); > } > > struct non_polymorphic > { > template<class T> > static void save( > Archive &ar, > T & t > ){ > const basic_pointer_oserializer & bpos = > boost::serialization::singleton< > pointer_oserializer<Archive, T> > >::get_const_instance(); > > ar.save_pointer(& t, & bpos); > } > }; > > struct polymorphic > { > template<class T> > static void save( > Archive &ar, > T & t > ){ > typename > boost::serialization::type_info_implementation< T >::type const > & i = boost::serialization::singleton< > typename > boost::serialization::type_info_implementation< T >::type > >::get_const_instance(); > > boost::serialization::extended_type_info const * const this_type = & i; > > > > (static_cast<void> (0)); > > const boost::serialization::extended_type_info * true_type = > i.get_derived_extended_type_info(t); > > > > if(__null == true_type){ > boost::serialization::throw_exception( > archive_exception( > archive_exception::unregistered_class, > "derived class not registered or exported" > ) > ); > } > > > const void *vp = static_cast<const void *>(&t); > if(*this_type == *true_type){ > const basic_pointer_oserializer * bpos = register_type(ar, t); > ar.save_pointer(vp, bpos); > return; > } > > > vp = serialization::void_downcast( > *true_type, > *this_type, > static_cast<const void *>(&t) > ); > if(__null == vp){ > boost::serialization::throw_exception( > archive_exception( > archive_exception::unregistered_cast, > true_type->get_debug_info(), > this_type->get_debug_info() > ) > ); > } > > > > > const basic_pointer_oserializer * bpos > = static_cast<const basic_pointer_oserializer *>( > boost::serialization::singleton< > archive_serializer_map<Archive> > >::get_const_instance().find(*true_type) > ); > (static_cast<void> (0)); > 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<class T> > static void save( > Archive & ar, > const T & t > ){ > check_pointer_level< T >(); > check_pointer_tracking< T >(); > typedef typename mpl::eval_if< > is_polymorphic< T >, > mpl::identity<polymorphic>, > mpl::identity<non_polymorphic> > >::type type; > type::save(ar, const_cast<T &>(t)); > } > > template<class TPtr> > static void invoke(Archive &ar, const TPtr t){ > register_type(ar, * t); > if(__null == t){ > basic_oarchive & boa > = boost::serialization::smart_cast_reference<basic_oarchive &>(ar); > boa.save_null_pointer(); > save_access::end_preamble(ar); > return; > } > save(ar, * t); > } >}; > >template<class Archive> >struct save_enum_type >{ > template<class T> > static void invoke(Archive &ar, const T &t){ > > const int i = static_cast<int>(t); > ar << boost::serialization::make_nvp(__null, i); > } >}; > >template<class Archive> >struct save_array_type >{ > template<class T> > static void invoke(Archive &ar, const T &t){ > typedef typename boost::remove_extent< T >::type value_type; > > save_access::end_preamble(ar); > > std::size_t c = sizeof(t) / ( > static_cast<const char *>(static_cast<const void *>(&t[1])) > - static_cast<const char *>(static_cast<const void *>(&t[0])) > ); > boost::serialization::collection_size_type count(c); > ar << boost::serialization::make_nvp("count", count); > ar << serialization::make_array(static_cast<value_type const*>(&t[0]),count); > } >}; > >} > >template<class Archive, class T> >inline void save(Archive & ar, T &t){ > typedef > typename mpl::eval_if<is_pointer< T >, > mpl::identity<detail::save_pointer_type<Archive> >, > > typename mpl::eval_if<is_enum< T >, > mpl::identity<detail::save_enum_type<Archive> >, > > typename mpl::eval_if<is_array< T >, > mpl::identity<detail::save_array_type<Archive> >, > > mpl::identity<detail::save_non_pointer_type<Archive> > > > > > > >::type typex; > typex::invoke(ar, t); >} > >} >} ># 24 "/usr/include/boost/archive/detail/interface_oarchive.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 25 "/usr/include/boost/archive/detail/interface_oarchive.hpp" 2 3 4 > > > >namespace boost { >namespace archive { >namespace detail { > >class basic_pointer_oserializer; > >template<class Archive> >class interface_oarchive >{ >protected: > interface_oarchive(){}; >public: > > > typedef mpl::bool_<false> is_loading; > typedef mpl::bool_<true> is_saving; > > > Archive * This(){ > return static_cast<Archive *>(this); > } > > template<class T> > const basic_pointer_oserializer * > register_type(const T * = __null){ > const basic_pointer_oserializer & bpos = > boost::serialization::singleton< > pointer_oserializer<Archive, T> > >::get_const_instance(); > this->This()->register_basic_serializer(bpos.get_basic_serializer()); > return & bpos; > } > > template<class T> > Archive & operator<<(T & t){ > this->This()->save_override(t, 0); > return * this->This(); > } > > > template<class T> > Archive & operator&(T & t){ > > return * this->This() << const_cast<const T &>(t); > > > > } >}; > >} >} >} > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 83 "/usr/include/boost/archive/detail/interface_oarchive.hpp" 2 3 4 ># 23 "/usr/include/boost/archive/detail/common_oarchive.hpp" 2 3 4 > > > > > > >namespace boost { >namespace archive { >namespace detail { > > >template<class Archive> >class common_oarchive : > public basic_oarchive, > public interface_oarchive<Archive> >{ > friend class interface_oarchive<Archive>; >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: > > template<class T> > void save_override(T & t, int){ > archive::save(* this->This(), t); > } > void save_start(const char * ){} > void save_end(const char * ){} > common_oarchive(unsigned int flags = 0) : > basic_oarchive(flags), > interface_oarchive<Archive>() > {} >}; > >} >} >} ># 35 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/string.hpp" 1 3 4 ># 25 "/usr/include/boost/serialization/string.hpp" 3 4 >namespace boost { namespace serialization { template <> struct implementation_level_impl< const std::string > { typedef mpl::integral_c_tag tag; typedef mpl::int_< boost::serialization::primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } > >namespace boost { namespace serialization { template <> struct implementation_level_impl< const std::wstring > { typedef mpl::integral_c_tag tag; typedef mpl::int_< boost::serialization::primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } ># 36 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 2 3 4 > ># 1 "/usr/include/boost/serialization/item_version_type.hpp" 1 3 4 ># 9 "/usr/include/boost/serialization/item_version_type.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 10 "/usr/include/boost/serialization/item_version_type.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 16 "/usr/include/boost/serialization/item_version_type.hpp" 2 3 4 > >namespace boost { >namespace serialization { > > > > > > >class item_version_type { >private: > typedef unsigned int base_type; > base_type t; >public: > > item_version_type(): t(0) {}; > explicit item_version_type(const unsigned int t_) : t(t_){ > (static_cast<void> (0)); > } > item_version_type(const item_version_type & t_) : > t(t_.t) > {} > item_version_type & operator=(item_version_type rhs){ > t = rhs.t; > return *this; > } > > operator base_type () const { > return t; > } > > operator base_type & () { > return t; > } > bool operator==(const item_version_type & rhs) const { > return t == rhs.t; > } > bool operator<(const item_version_type & rhs) const { > return t < rhs.t; > } >}; > > > > > >} } > >namespace boost { namespace serialization { template<> struct is_bitwise_serializable< item_version_type > : mpl::true_ {}; }} > >namespace boost { namespace serialization { template <> struct implementation_level_impl< const item_version_type > { typedef mpl::integral_c_tag tag; typedef mpl::int_< primitive_type > type; static const int value = implementation_level_impl::type::value; }; } } ># 38 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 2 3 4 > ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 40 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 2 3 4 > > > > > > >namespace boost { >namespace archive { ># 57 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 3 4 >template<class Archive> >class basic_binary_oarchive : > public archive::detail::common_oarchive<Archive> >{ >protected: > > > > > > > > friend class detail::interface_oarchive<Archive>; > > > typedef detail::common_oarchive<Archive> detail_common_oarchive; > template<class T> > void save_override(const T & t, int version){ > this->detail_common_oarchive::save_override(t, static_cast<int>(version)); > } > > > > static_assert(sizeof(tracking_type) == sizeof(bool), "sizeof(tracking_type) == sizeof(bool)"); > > static_assert(sizeof(class_id_type) == sizeof(int_least16_t), "sizeof(class_id_type) == sizeof(int_least16_t)"); > static_assert(sizeof(class_id_reference_type) == sizeof(int_least16_t), "sizeof(class_id_reference_type) == sizeof(int_least16_t)"); > > static_assert(sizeof(object_id_type) == sizeof(uint_least32_t), "sizeof(object_id_type) == sizeof(uint_least32_t)"); > static_assert(sizeof(object_reference_type) == sizeof(uint_least32_t), "sizeof(object_reference_type) == sizeof(uint_least32_t)"); > > > void save_override(const class_id_optional_type & , int){} ># 146 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 3 4 > void save_override(const class_name_type & t, int){ > const std::string s(t); > * this->This() << s; > } ># 163 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 3 4 > void > init(); > > basic_binary_oarchive(unsigned int flags) : > detail::common_oarchive<Archive>(flags) > {} >}; > >} >} > > > > > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 179 "/usr/include/boost/archive/basic_binary_oarchive.hpp" 2 3 4 ># 24 "/usr/include/boost/archive/binary_oarchive_impl.hpp" 2 3 4 > > > > > > >namespace boost { >namespace archive { > >template<class Archive, class Elem, class Tr> >class binary_oarchive_impl : > public basic_binary_oprimitive<Archive, Elem, Tr>, > public basic_binary_oarchive<Archive> >{ > > > > friend class detail::interface_oarchive<Archive>; > friend class basic_binary_oarchive<Archive>; > friend class save_access; >protected: > > > > > template<class T> > void save_override(T & t, int){ > this->basic_binary_oarchive<Archive>::save_override(t, 0L); > } > void init(unsigned int flags) { > if(0 != (flags & no_header)) > return; > > this->basic_binary_oarchive<Archive>::init(); > this->basic_binary_oprimitive<Archive, Elem, Tr>::init(); > > > > > } > binary_oarchive_impl( > std::basic_streambuf<Elem, Tr> & bsb, > unsigned int flags > ) : > basic_binary_oprimitive<Archive, Elem, Tr>( > bsb, > 0 != (flags & no_codecvt) > ), > basic_binary_oarchive<Archive>(flags) > { > init(flags); > } > binary_oarchive_impl( > std::basic_ostream<Elem, Tr> & os, > unsigned int flags > ) : > basic_binary_oprimitive<Archive, Elem, Tr>( > * os.rdbuf(), > 0 != (flags & no_codecvt) > ), > basic_binary_oarchive<Archive>(flags) > { > init(flags); > } >}; > >} >} ># 22 "/usr/include/boost/archive/binary_oarchive.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/register_archive.hpp" 1 3 4 > > > > > > >namespace boost { namespace archive { namespace detail { > > > > > > > >struct adl_tag {}; > >template <class Archive, class Serializable> >struct ptr_serialization_support; > > > > > >template <class Archive, class Serializable> >struct _ptr_serialization_support > : ptr_serialization_support<Archive,Serializable> >{ > typedef int type; >}; ># 72 "/usr/include/boost/archive/detail/register_archive.hpp" 3 4 >template <class Serializable> >void instantiate_ptr_serialization(Serializable*, int, adl_tag ) {} ># 89 "/usr/include/boost/archive/detail/register_archive.hpp" 3 4 >}}} ># 23 "/usr/include/boost/archive/binary_oarchive.hpp" 2 3 4 > > > > > > >namespace boost { >namespace archive { > > > > >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 boost { namespace archive { namespace detail { template <class Serializable> typename _ptr_serialization_support<boost::archive::binary_oarchive, Serializable>::type instantiate_ptr_serialization( Serializable*, boost::archive::binary_oarchive*, adl_tag ); }}} >namespace boost { namespace serialization { template <> struct use_array_optimization<boost::archive::binary_oarchive> { template <class ValueType> struct apply : boost::mpl::apply1<boost::archive::binary_oarchive::use_array_optimization , typename boost::remove_const<ValueType>::type >::type {}; }; }} ># 8 "/c/honeypenny/src/common/boost_serialization_helper.h" 2 ># 1 "/usr/include/boost/archive/binary_iarchive.hpp" 1 3 4 ># 20 "/usr/include/boost/archive/binary_iarchive.hpp" 3 4 ># 1 "/usr/include/boost/archive/binary_iarchive_impl.hpp" 1 3 4 ># 21 "/usr/include/boost/archive/binary_iarchive_impl.hpp" 3 4 ># 1 "/usr/include/boost/archive/basic_binary_iprimitive.hpp" 1 3 4 ># 31 "/usr/include/boost/archive/basic_binary_iprimitive.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 32 "/usr/include/boost/archive/basic_binary_iprimitive.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 34 "/usr/include/boost/archive/basic_binary_iprimitive.hpp" 2 3 4 ># 46 "/usr/include/boost/archive/basic_binary_iprimitive.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 47 "/usr/include/boost/archive/basic_binary_iprimitive.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/mpl/placeholders.hpp" 1 3 4 ># 55 "/usr/include/boost/archive/basic_binary_iprimitive.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 59 "/usr/include/boost/archive/basic_binary_iprimitive.hpp" 2 3 4 > >namespace boost { >namespace archive { > > > >template<class Archive, class Elem, class Tr> >class basic_binary_iprimitive >{ > > friend class load_access; >protected: > > > > std::basic_streambuf<Elem, Tr> & m_sb; > > Archive * This(){ > return static_cast<Archive *>(this); > } > > > boost::scoped_ptr<std::locale> archive_locale; > basic_streambuf_locale_saver<Elem, Tr> locale_saver; > > > > template<class T> > void load(T & t){ > load_binary(& t, sizeof(T)); > } > > > > > > void load(bool & t){ > load_binary(& t, sizeof(t)); > int i = t; > (static_cast<void> (0)); > (void)i; > } > void > load(std::string &s); > > void > load(std::wstring &ws); > > void > load(char * t); > void > load(wchar_t * t); > > void > init(); > > basic_binary_iprimitive( > std::basic_streambuf<Elem, Tr> & sb, > bool no_codecvt > ); > > ~basic_binary_iprimitive(); >public: > > > > struct use_array_optimization { > template <class T> > > > > > > struct apply : public boost::serialization::is_bitwise_serializable< T > {}; > > }; > > > template <class ValueType> > void load_array(serialization::array<ValueType>& a, unsigned int) > { > load_binary(a.address(),a.count()*sizeof(ValueType)); > } > > void > load_binary(void *address, std::size_t count); >}; > >template<class Archive, class Elem, class Tr> >inline void >basic_binary_iprimitive<Archive, Elem, Tr>::load_binary( > void *address, > std::size_t count >){ > > (static_cast<void> (0)) > > > ; > std::streamsize s = static_cast<std::streamsize>(count / sizeof(Elem)); > std::streamsize scount = m_sb.sgetn( > static_cast<Elem *>(address), > s > ); > if(scount != s) > boost::serialization::throw_exception( > archive_exception(archive_exception::input_stream_error) > ); > > (static_cast<void> (0)); > s = static_cast<std::streamsize>(count % sizeof(Elem)); > if(0 < s){ > > > > > 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<char*>(address) + (count - s), &t, s); > } >} > >} >} > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 189 "/usr/include/boost/archive/basic_binary_iprimitive.hpp" 2 3 4 ># 22 "/usr/include/boost/archive/binary_iarchive_impl.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/basic_binary_iarchive.hpp" 1 3 4 ># 31 "/usr/include/boost/archive/basic_binary_iarchive.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/common_iarchive.hpp" 1 3 4 ># 21 "/usr/include/boost/archive/detail/common_iarchive.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/basic_iarchive.hpp" 1 3 4 ># 29 "/usr/include/boost/archive/detail/basic_iarchive.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 30 "/usr/include/boost/archive/detail/basic_iarchive.hpp" 2 3 4 > >namespace boost { >namespace serialization { > class extended_type_info; >} > >namespace archive { >namespace detail { > >class basic_iarchive_impl; >class basic_iserializer; >class basic_pointer_iserializer; > > >class basic_iarchive : > private boost::noncopyable >{ > friend class basic_iarchive_impl; > > > > 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); > > > virtual > > ~basic_iarchive(); >public: > > 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 > ) > > ); > > 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(); >}; > >} >} >} > > > > > > > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 109 "/usr/include/boost/archive/detail/basic_iarchive.hpp" 2 3 4 ># 22 "/usr/include/boost/archive/detail/common_iarchive.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/basic_pointer_iserializer.hpp" 1 3 4 ># 24 "/usr/include/boost/archive/detail/basic_pointer_iserializer.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 25 "/usr/include/boost/archive/detail/basic_pointer_iserializer.hpp" 2 3 4 > > > > > > >namespace boost { >namespace serialization { > class extended_type_info; >} > > >namespace archive { >namespace detail { > >class basic_iarchive; >class basic_iserializer; > >class basic_pointer_iserializer > : public basic_serializer { >protected: > explicit basic_pointer_iserializer( > const boost::serialization::extended_type_info & type_ > ); > > > virtual > > ~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; >}; > >} >} >} > > > > > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 72 "/usr/include/boost/archive/detail/basic_pointer_iserializer.hpp" 2 3 4 ># 23 "/usr/include/boost/archive/detail/common_iarchive.hpp" 2 3 4 ># 1 "/usr/include/boost/archive/detail/interface_iarchive.hpp" 1 3 4 ># 19 "/usr/include/boost/archive/detail/interface_iarchive.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 20 "/usr/include/boost/archive/detail/interface_iarchive.hpp" 2 3 4 > > ># 1 "/usr/include/boost/archive/detail/iserializer.hpp" 1 3 4 ># 70 "/usr/include/boost/archive/detail/iserializer.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/has_new_operator.hpp" 1 3 4 ># 19 "/usr/include/boost/type_traits/has_new_operator.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 20 "/usr/include/boost/type_traits/has_new_operator.hpp" 2 3 4 > >namespace boost { >namespace detail { > template <class U, U x> > struct test; > > template <typename T> > struct has_new_operator_impl { > template<class U> > static type_traits::yes_type check_sig1( > U*, > test< > void *(*)(std::size_t), > &U::operator new > >* = __null > ); > template<class U> > static type_traits::no_type check_sig1(...); > > template<class U> > static type_traits::yes_type check_sig2( > U*, > test< > void *(*)(std::size_t, const std::nothrow_t&), > &U::operator new > >* = __null > ); > template<class U> > static type_traits::no_type check_sig2(...); > > template<class U> > static type_traits::yes_type check_sig3( > U*, > test< > void *(*)(std::size_t, void*), > &U::operator new > >* = __null > ); > template<class U> > static type_traits::no_type check_sig3(...); > > > template<class U> > static type_traits::yes_type check_sig4( > U*, > test< > void *(*)(std::size_t), > &U::operator new[] > >* = __null > ); > template<class U> > static type_traits::no_type check_sig4(...); > > template<class U> > static type_traits::yes_type check_sig5( > U*, > test< > void *(*)(std::size_t, const std::nothrow_t&), > &U::operator new[] > >* = __null > ); > template<class U> > static type_traits::no_type check_sig5(...); > > template<class U> > static type_traits::yes_type check_sig6( > U*, > test< > void *(*)(std::size_t, void*), > &U::operator new[] > >* = __null > ); > template<class U> > static type_traits::no_type check_sig6(...); > > > > > static const unsigned s1 = sizeof(has_new_operator_impl<T>::template check_sig1<T>(0)); > static const unsigned s2 = sizeof(has_new_operator_impl<T>::template check_sig2<T>(0)); > static const unsigned s3 = sizeof(has_new_operator_impl<T>::template check_sig3<T>(0)); > static const unsigned s4 = sizeof(has_new_operator_impl<T>::template check_sig4<T>(0)); > static const unsigned s5 = sizeof(has_new_operator_impl<T>::template check_sig5<T>(0)); > static const unsigned s6 = sizeof(has_new_operator_impl<T>::template check_sig6<T>(0)); ># 121 "/usr/include/boost/type_traits/has_new_operator.hpp" 3 4 > static const bool value = (::boost::type_traits::ice_or< (s1 == sizeof(type_traits::yes_type)), (s2 == sizeof(type_traits::yes_type)), (s3 == sizeof(type_traits::yes_type)), (s4 == sizeof(type_traits::yes_type)), (s5 == sizeof(type_traits::yes_type)), (s6 == sizeof(type_traits::yes_type)) >::value) ># 130 "/usr/include/boost/type_traits/has_new_operator.hpp" 3 4 > ; > }; >} > >template< typename T > struct has_new_operator : public ::boost::integral_constant<bool,::boost::detail::has_new_operator_impl<T>::value> { public: }; > >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 139 "/usr/include/boost/type_traits/has_new_operator.hpp" 2 3 4 ># 71 "/usr/include/boost/archive/detail/iserializer.hpp" 2 3 4 ># 88 "/usr/include/boost/archive/detail/iserializer.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/basic_iserializer.hpp" 1 3 4 ># 19 "/usr/include/boost/archive/detail/basic_iserializer.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 4 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 20 "/usr/include/boost/archive/detail/basic_iserializer.hpp" 2 3 4 > > > > > > ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 27 "/usr/include/boost/archive/detail/basic_iserializer.hpp" 2 3 4 > > > > > > >namespace boost { >namespace serialization { > class extended_type_info; >} > > >namespace archive { >namespace detail { > >class basic_iarchive; >class basic_pointer_iserializer; > >class basic_iserializer : > public basic_serializer >{ >private: > basic_pointer_iserializer *m_bpis; >protected: > explicit basic_iserializer( > const boost::serialization::extended_type_info & type > ); > > > virtual > > ~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; > > virtual bool class_info() const = 0 ; > > virtual bool tracking(const unsigned int) const = 0 ; > > virtual version_type version() const = 0 ; > > virtual bool is_polymorphic() const = 0; > virtual void destroy( void *address) const = 0 ; >}; > >} >} >} > > > > > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 94 "/usr/include/boost/archive/detail/basic_iserializer.hpp" 2 3 4 ># 89 "/usr/include/boost/archive/detail/iserializer.hpp" 2 3 4 > > > > >namespace boost { > >namespace serialization { > class extended_type_info; >} > >namespace archive { > > > >class load_access { >public: > template<class Archive, class T> > static void load_primitive(Archive &ar, T &t){ > ar.load(t); > } >}; > >namespace detail { > > > > > > >template<class Archive, class T> >class iserializer : public basic_iserializer >{ >private: > virtual void destroy( void *address) const { > boost::serialization::access::destroy(static_cast<T *>(address)); > } >protected: > > explicit iserializer() : > basic_iserializer( > boost::serialization::singleton< > typename > boost::serialization::type_info_implementation< T >::type > >::get_const_instance() > ) > {} >public: > virtual void load_object_data( > basic_iarchive & ar, > void *x, > const unsigned int file_version > ) const __attribute__ ((__used__)); > virtual bool class_info() const { > return boost::serialization::implementation_level< T >::value > >= boost::serialization::object_class_info; > } > virtual bool tracking(const unsigned int ) 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(){}; >}; > > > > > >template<class Archive, class T> > void iserializer<Archive, T>::load_object_data( > basic_iarchive & ar, > void *x, > const unsigned int file_version >) const { ># 188 "/usr/include/boost/archive/detail/iserializer.hpp" 3 4 > boost::serialization::serialize_adl( > boost::serialization::smart_cast_reference<Archive &>(ar), > * static_cast<T *>(x), > file_version > ); >} > > > > > > >template<class Archive, class T> >class pointer_iserializer : > public basic_pointer_iserializer >{ >private: > virtual const basic_iserializer & get_basic_serializer() const { > return boost::serialization::singleton< > iserializer<Archive, T> > >::get_const_instance(); > } > virtual void load_object_ptr( > basic_iarchive & ar, > void * & x, > const unsigned int file_version > ) const __attribute__ ((__used__)); >protected: > > pointer_iserializer(); > ~pointer_iserializer(); >}; ># 236 "/usr/include/boost/archive/detail/iserializer.hpp" 3 4 >template<class T> >struct heap_allocator >{ > > > > > > > > struct has_new_operator { > static T* invoke() { > return static_cast<T *>((T::operator new)(sizeof(T))); > } > }; > struct doesnt_have_new_operator { > static T* invoke() { > return static_cast<T *>(operator new(sizeof(T))); > } > }; > static T * invoke() { > typedef typename > mpl::eval_if< > boost::has_new_operator< T >, > mpl::identity<has_new_operator >, > mpl::identity<doesnt_have_new_operator > > >::type typex; > return typex::invoke(); > } > >}; > > >template <typename T> >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; >}; > > > >template<class Archive, class T> > void pointer_iserializer<Archive, T>::load_object_ptr( > basic_iarchive & ar, > void * & x, > const unsigned int file_version >) const >{ > Archive & ar_impl = > boost::serialization::smart_cast_reference<Archive &>(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; > > > > > { try { > > > ar.next_object_pointer(t); > boost::serialization::load_construct_data_adl<Archive, T>( > ar_impl, > t, > file_version > ); > } > catch(...){ > ap.release(); > throw;; > } > } > > ar_impl >> boost::serialization::make_nvp(__null, * t); > ap.release(); >} > >template<class Archive, class T> >pointer_iserializer<Archive, T>::pointer_iserializer() : > basic_pointer_iserializer( > boost::serialization::singleton< > typename > boost::serialization::type_info_implementation< T >::type > >::get_const_instance() > ) >{ > boost::serialization::singleton< > iserializer<Archive, T> > >::get_mutable_instance().set_bpis(this); > archive_serializer_map<Archive>::insert(this); >} > >template<class Archive, class T> >pointer_iserializer<Archive, T>::~pointer_iserializer(){ > archive_serializer_map<Archive>::erase(this); >} > >template<class Archive> >struct load_non_pointer_type { > > > struct load_primitive { > template<class T> > static void invoke(Archive & ar, T & t){ > load_access::load_primitive(ar, t); > } > }; > > > struct load_only { > template<class T> > static void invoke(Archive & ar, const T & t){ > > > > boost::serialization::serialize_adl( > ar, > const_cast<T &>(t), > boost::serialization::version< T >::value > ); > } > }; > > > > struct load_standard { > template<class T> > static void invoke(Archive &ar, const T & t){ > void * x = & const_cast<T &>(t); > ar.load_object( > x, > boost::serialization::singleton< > iserializer<Archive, T> > >::get_const_instance() > ); > } > }; > > struct load_conditional { > template<class T> > static void invoke(Archive &ar, T &t){ > > load_standard::invoke(ar, t); > > > } > }; > > template<class T> > static void invoke(Archive & ar, T &t){ > typedef typename mpl::eval_if< > > mpl::equal_to< > boost::serialization::implementation_level< T >, > mpl::int_<boost::serialization::primitive_type> > >, > mpl::identity<load_primitive>, > > typename mpl::eval_if< > > mpl::greater_equal< > boost::serialization::implementation_level< T >, > mpl::int_<boost::serialization::object_class_info> > >, > > mpl::identity<load_standard>, > > typename mpl::eval_if< > > mpl::equal_to< > boost::serialization::tracking_level< T >, > mpl::int_<boost::serialization::track_never> > >, > > mpl::identity<load_only>, > > > mpl::identity<load_conditional> > > > >::type typex; > check_object_versioning< T >(); > check_object_level< T >(); > typex::invoke(ar, t); > } >}; > >template<class Archive> >struct load_pointer_type { > struct abstract > { > template<class T> > static const basic_pointer_iserializer * register_type(Archive & ){ > > static_assert(boost::is_polymorphic< T >::value, "boost::is_polymorphic< T >::value"); > return static_cast<basic_pointer_iserializer *>(__null); > } > }; > > struct non_abstract > { > template<class T> > static const basic_pointer_iserializer * register_type(Archive & ar){ > return ar.register_type(static_cast<T *>(__null)); > } > }; > > template<class T> > static const basic_pointer_iserializer * register_type(Archive &ar, const T & ){ > > > > > typedef typename > mpl::eval_if< > boost::serialization::is_abstract<const T>, > boost::mpl::identity<abstract>, > boost::mpl::identity<non_abstract> > >::type typex; > return typex::template register_type< T >(ar); > } > > template<class T> > static T * pointer_tweak( > const boost::serialization::extended_type_info & eti, > void const * const t, > const T & > ) { > > return static_cast<T *>( > const_cast<void *>( > boost::serialization::void_upcast( > eti, > boost::serialization::singleton< > typename > boost::serialization::type_info_implementation< T >::type > >::get_const_instance(), > t > ) > ) > ); > } > > template<class T> > static void check_load(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<const basic_pointer_iserializer *>( > archive_serializer_map<Archive>::find(type) > ); > } > > template<class Tptr> > 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( > > > > > (void * & )t, > bpis_ptr, > find > ); > > if(newbpis_ptr != bpis_ptr){ > t = pointer_tweak(newbpis_ptr->get_eti(), t, *t); > } > } >}; > >template<class Archive> >struct load_enum_type { > template<class T> > static void invoke(Archive &ar, T &t){ > > int i; > ar >> boost::serialization::make_nvp(__null, i); > t = static_cast< T >(i); > } >}; > >template<class Archive> >struct load_array_type { > template<class T> > static void invoke(Archive &ar, T &t){ > typedef typename remove_extent< T >::type value_type; > > > > > > std::size_t current_count = sizeof(t) / ( > static_cast<char *>(static_cast<void *>(&t[1])) > - static_cast<char *>(static_cast<void *>(&t[0])) > ); > boost::serialization::collection_size_type count; > ar >> boost::serialization::make_nvp("count", count); > if(static_cast<std::size_t>(count) > current_count) > boost::serialization::throw_exception( > archive::archive_exception( > boost::archive::archive_exception::array_size_too_short > ) > ); > ar >> serialization::make_array(static_cast<value_type*>(&t[0]),count); > } >}; > >} > >template<class Archive, class T> >inline void load(Archive & ar, T &t){ > > > > > detail::check_const_loading< T >(); > typedef > typename mpl::eval_if<is_pointer< T >, > mpl::identity<detail::load_pointer_type<Archive> > > , > typename mpl::eval_if<is_array< T >, > mpl::identity<detail::load_array_type<Archive> > > , > typename mpl::eval_if<is_enum< T >, > mpl::identity<detail::load_enum_type<Archive> > > , > mpl::identity<detail::load_non_pointer_type<Archive> > > > > > > >::type typex; > typex::invoke(ar, t); >} ># 629 "/usr/include/boost/archive/detail/iserializer.hpp" 3 4 >} >} ># 23 "/usr/include/boost/archive/detail/interface_iarchive.hpp" 2 3 4 > ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 25 "/usr/include/boost/archive/detail/interface_iarchive.hpp" 2 3 4 > >namespace boost { >namespace archive { >namespace detail { > >class basic_pointer_iserializer; > >template<class Archive> >class interface_iarchive >{ >protected: > interface_iarchive(){}; >public: > > > typedef mpl::bool_<true> is_loading; > typedef mpl::bool_<false> is_saving; > > > Archive * This(){ > return static_cast<Archive *>(this); > } > > template<class T> > const basic_pointer_iserializer * > register_type(T * = __null){ > const basic_pointer_iserializer & bpis = > boost::serialization::singleton< > pointer_iserializer<Archive, T> > >::get_const_instance(); > this->This()->register_basic_serializer(bpis.get_basic_serializer()); > return & bpis; > } > template<class T> > Archive & operator>>(T & t){ > this->This()->load_override(t, 0); > return * this->This(); > } > > > template<class T> > Archive & operator&(T & t){ > return *(this->This()) >> t; > } >}; > >} >} >} > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 76 "/usr/include/boost/archive/detail/interface_iarchive.hpp" 2 3 4 ># 24 "/usr/include/boost/archive/detail/common_iarchive.hpp" 2 3 4 > > > > > > >namespace boost { >namespace archive { >namespace detail { > >class extended_type_info; > > >template<class Archive> >class common_iarchive : > public basic_iarchive, > public interface_iarchive<Archive> >{ > friend class interface_iarchive<Archive>; >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: > > template<class T> > void load_override(T & t, int){ > archive::load(* this->This(), t); > } > > > void load_start(const char * ){} > void load_end(const char * ){} > > common_iarchive(unsigned int flags = 0) : > basic_iarchive(flags), > interface_iarchive<Archive>() > {} >}; > >} >} >} ># 32 "/usr/include/boost/archive/basic_binary_iarchive.hpp" 2 3 4 ># 42 "/usr/include/boost/archive/basic_binary_iarchive.hpp" 3 4 ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 43 "/usr/include/boost/archive/basic_binary_iarchive.hpp" 2 3 4 > >namespace boost { >namespace archive { > > > >template<class Archive> >class basic_binary_iarchive : > public detail::common_iarchive<Archive> >{ >protected: > > > > > > > > friend class detail::interface_iarchive<Archive>; > > > > > > typedef detail::common_iarchive<Archive> detail_common_iarchive; > template<class T> > void load_override(T & t, int version){ > this->detail_common_iarchive::load_override(t, static_cast<int>(version)); > } > > > > > static_assert(sizeof(class_id_type) == sizeof(int_least16_t), "sizeof(class_id_type) == sizeof(int_least16_t)"); > static_assert(sizeof(class_id_reference_type) == sizeof(int_least16_t), "sizeof(class_id_reference_type) == sizeof(int_least16_t)"); > > static_assert(sizeof(object_id_type) == sizeof(uint_least32_t), "sizeof(object_id_type) == sizeof(uint_least32_t)"); > static_assert(sizeof(object_reference_type) == sizeof(uint_least32_t), "sizeof(object_reference_type) == sizeof(uint_least32_t)"); > > > void load_override(class_id_optional_type & , int){} > > void load_override(tracking_type & t, int ){ > 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<class_id_type &>(t), version); > } ># 142 "/usr/include/boost/archive/basic_binary_iarchive.hpp" 3 4 > 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){ > > 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(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); > } > } > > void > load_override(class_name_type & t, int); > void > init(); > > basic_binary_iarchive(unsigned int flags) : > detail::common_iarchive<Archive>(flags) > {} >}; > >} >} > > > > > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 221 "/usr/include/boost/archive/basic_binary_iarchive.hpp" 2 3 4 ># 23 "/usr/include/boost/archive/binary_iarchive_impl.hpp" 2 3 4 > > > > > > >namespace boost { >namespace archive { > >template<class Archive, class Elem, class Tr> >class binary_iarchive_impl : > public basic_binary_iprimitive<Archive, Elem, Tr>, > public basic_binary_iarchive<Archive> >{ > > > > friend class detail::interface_iarchive<Archive>; > friend class basic_binary_iarchive<Archive>; > friend class load_access; >protected: > > > > > template<class T> > void load_override(T & t, int){ > this->basic_binary_iarchive<Archive>::load_override(t, 0L); > } > void init(unsigned int flags){ > if(0 != (flags & no_header)) > return; > > this->basic_binary_iarchive<Archive>::init(); > this->basic_binary_iprimitive<Archive, Elem, Tr>::init(); > > > > > } > binary_iarchive_impl( > std::basic_streambuf<Elem, Tr> & bsb, > unsigned int flags > ) : > basic_binary_iprimitive<Archive, Elem, Tr>( > bsb, > 0 != (flags & no_codecvt) > ), > basic_binary_iarchive<Archive>(flags) > { > init(flags); > } > binary_iarchive_impl( > std::basic_istream<Elem, Tr> & is, > unsigned int flags > ) : > basic_binary_iprimitive<Archive, Elem, Tr>( > * is.rdbuf(), > 0 != (flags & no_codecvt) > ), > basic_binary_iarchive<Archive>(flags) > { > init(flags); > } >}; > >} >} ># 21 "/usr/include/boost/archive/binary_iarchive.hpp" 2 3 4 > > > > > > > >namespace boost { >namespace archive { > > > > > > >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) > {} >}; > >} >} > > > > > ># 1 "/usr/include/boost/archive/shared_ptr_helper.hpp" 1 3 4 ># 29 "/usr/include/boost/archive/shared_ptr_helper.hpp" 3 4 ># 1 "/usr/include/boost/serialization/shared_ptr_132.hpp" 1 3 4 ># 35 "/usr/include/boost/serialization/shared_ptr_132.hpp" 3 4 ># 1 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 1 3 4 ># 23 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 24 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/serialization/detail/shared_count_132.hpp" 1 3 4 ># 28 "/usr/include/boost/serialization/detail/shared_count_132.hpp" 3 4 ># 1 "/usr/include/boost/detail/lightweight_mutex.hpp" 1 3 4 ># 20 "/usr/include/boost/detail/lightweight_mutex.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/lightweight_mutex.hpp" 1 3 4 ># 34 "/usr/include/boost/smart_ptr/detail/lightweight_mutex.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/lwm_pthreads.hpp" 1 3 4 ># 20 "/usr/include/boost/smart_ptr/detail/lwm_pthreads.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 21 "/usr/include/boost/smart_ptr/detail/lwm_pthreads.hpp" 2 3 4 > > >namespace boost >{ > >namespace detail >{ > >class lightweight_mutex >{ >private: > > pthread_mutex_t m_; > > lightweight_mutex(lightweight_mutex const &); > lightweight_mutex & operator=(lightweight_mutex const &); > >public: > > lightweight_mutex() > { > > > > > > > ((void)(pthread_mutex_init( &m_, 0 ) == 0)); > > } > > ~lightweight_mutex() > { > ((void)(pthread_mutex_destroy( &m_ ) == 0)); > } > > class scoped_lock; > friend class scoped_lock; > > class scoped_lock > { > private: > > pthread_mutex_t & m_; > > scoped_lock(scoped_lock const &); > scoped_lock & operator=(scoped_lock const &); > > public: > > scoped_lock(lightweight_mutex & m): m_(m.m_) > { > ((void)(pthread_mutex_lock( &m_ ) == 0)); > } > > ~scoped_lock() > { > ((void)(pthread_mutex_unlock( &m_ ) == 0)); > } > }; >}; > >} > >} ># 35 "/usr/include/boost/smart_ptr/detail/lightweight_mutex.hpp" 2 3 4 ># 21 "/usr/include/boost/detail/lightweight_mutex.hpp" 2 3 4 ># 29 "/usr/include/boost/serialization/detail/shared_count_132.hpp" 2 3 4 ># 53 "/usr/include/boost/serialization/detail/shared_count_132.hpp" 3 4 >namespace boost_132 { ># 78 "/usr/include/boost/serialization/detail/shared_count_132.hpp" 3 4 >class bad_weak_ptr: public std::exception >{ >public: > > virtual char const * what() const throw() > { > return "boost::bad_weak_ptr"; > } >}; > > > > > >namespace detail{ > >class sp_counted_base >{ > > > typedef boost::detail::lightweight_mutex mutex_type; > >public: > > sp_counted_base(): use_count_(1), weak_count_(1) > { > } > > virtual ~sp_counted_base() > { > } > > > > > virtual void dispose() = 0; > > > > virtual void destruct() > { > delete this; > } > > virtual void * get_deleter(std::type_info const & ti) = 0; > > void add_ref_copy() > { > > mutex_type::scoped_lock lock(mtx_); > > ++use_count_; > } > > void add_ref_lock() > { > > mutex_type::scoped_lock lock(mtx_); > > if(use_count_ == 0) boost::serialization::throw_exception(bad_weak_ptr()); > ++use_count_; > } > > void release() > { > { > > mutex_type::scoped_lock lock(mtx_); > > long new_use_count = --use_count_; > > if(new_use_count != 0) return; > } > > dispose(); > weak_release(); > } > > void weak_add_ref() > { > > mutex_type::scoped_lock lock(mtx_); > > ++weak_count_; > } > > void weak_release() > { > long new_weak_count; > > { > > mutex_type::scoped_lock lock(mtx_); > > new_weak_count = --weak_count_; > } > > if(new_weak_count == 0) > { > destruct(); > } > } > > long use_count() const > { > > mutex_type::scoped_lock lock(mtx_); > > return use_count_; > } > > >public: > sp_counted_base(sp_counted_base const &); > sp_counted_base & operator= (sp_counted_base const &); > > long use_count_; > long weak_count_; > > > mutable mutex_type mtx_; > >}; ># 241 "/usr/include/boost/serialization/detail/shared_count_132.hpp" 3 4 >template<class P, class D> class sp_counted_base_impl: public sp_counted_base >{ > >public: > P ptr; > D del; > > sp_counted_base_impl(sp_counted_base_impl const &); > sp_counted_base_impl & operator= (sp_counted_base_impl const &); > > typedef sp_counted_base_impl<P, D> this_type; > >public: > > > > sp_counted_base_impl(P p, D d): ptr(p), del(d) > { > > > > } > > virtual void dispose() > { > > > > del(ptr); > } > > virtual void * get_deleter(std::type_info const & ti) > { > return ti == typeid(D)? &del: 0; > } ># 304 "/usr/include/boost/serialization/detail/shared_count_132.hpp" 3 4 >}; ># 313 "/usr/include/boost/serialization/detail/shared_count_132.hpp" 3 4 >class weak_count; > >class shared_count >{ > >public: > sp_counted_base * pi_; > > > > > > friend class weak_count; > >public: > > shared_count(): pi_(0) > > > > { > } > > template<class P, class D> shared_count(P p, D d): pi_(0) > > > > { > > > try > { > pi_ = new sp_counted_base_impl<P, D>(p, d); > } > catch(...) > { > d(p); > throw; > } ># 364 "/usr/include/boost/serialization/detail/shared_count_132.hpp" 3 4 > } > > > > > > template<class Y> > explicit shared_count(std::auto_ptr<Y> & r): pi_( > new sp_counted_base_impl< > Y *, > boost::checked_deleter<Y> > >(r.get(), boost::checked_deleter<Y>())) > > > > { > r.release(); > } > > > > ~shared_count() > { > if(pi_ != 0) pi_->release(); > > > > } > > shared_count(shared_count const & r): pi_(r.pi_) > > > > { > if(pi_ != 0) pi_->add_ref_copy(); > } > > explicit shared_count(weak_count const & r); > > shared_count & operator= (shared_count const & r) > { > sp_counted_base * tmp = r.pi_; > > if(tmp != pi_) > { > if(tmp != 0) tmp->add_ref_copy(); > if(pi_ != 0) pi_->release(); > pi_ = tmp; > } > > return *this; > } > > void swap(shared_count & r) > { > sp_counted_base * tmp = r.pi_; > r.pi_ = pi_; > pi_ = tmp; > } > > long use_count() const > { > return pi_ != 0? pi_->use_count(): 0; > } > > bool unique() const > { > return use_count() == 1; > } > > friend inline bool operator==(shared_count const & a, shared_count const & b) > { > return a.pi_ == b.pi_; > } > > friend inline bool operator<(shared_count const & a, shared_count const & b) > { > return std::less<sp_counted_base *>()(a.pi_, b.pi_); > } > > void * get_deleter(std::type_info const & ti) const > { > return pi_? pi_->get_deleter(ti): 0; > } >}; > > > > > > >class weak_count >{ >private: > > sp_counted_base * pi_; > > > > > > friend class shared_count; > >public: > > weak_count(): pi_(0) > > > > { > } > > weak_count(shared_count const & r): pi_(r.pi_) > > > > { > if(pi_ != 0) pi_->weak_add_ref(); > } > > weak_count(weak_count const & r): pi_(r.pi_) > > > > { > if(pi_ != 0) pi_->weak_add_ref(); > } > > ~weak_count() > { > if(pi_ != 0) pi_->weak_release(); > > > > } > > weak_count & operator= (shared_count const & r) > { > sp_counted_base * tmp = r.pi_; > if(tmp != 0) tmp->weak_add_ref(); > if(pi_ != 0) pi_->weak_release(); > pi_ = tmp; > > return *this; > } > > weak_count & operator= (weak_count const & r) > { > sp_counted_base * tmp = r.pi_; > if(tmp != 0) tmp->weak_add_ref(); > if(pi_ != 0) pi_->weak_release(); > pi_ = tmp; > > return *this; > } > > void swap(weak_count & r) > { > sp_counted_base * tmp = r.pi_; > r.pi_ = pi_; > pi_ = tmp; > } > > long use_count() const > { > return pi_ != 0? pi_->use_count(): 0; > } > > friend inline bool operator==(weak_count const & a, weak_count const & b) > { > return a.pi_ == b.pi_; > } > > friend inline bool operator<(weak_count const & a, weak_count const & b) > { > return std::less<sp_counted_base *>()(a.pi_, b.pi_); > } >}; > >inline shared_count::shared_count(weak_count const & r): pi_(r.pi_) > > > >{ > if(pi_ != 0) > { > pi_->add_ref_lock(); > } > else > { > boost::serialization::throw_exception(bad_weak_ptr()); > } >} > >} > >} ># 30 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 2 3 4 ># 42 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 3 4 >namespace boost_132 { > >template<class T> class weak_ptr; >template<class T> class enable_shared_from_this; > >namespace detail >{ > >struct static_cast_tag {}; >struct const_cast_tag {}; >struct dynamic_cast_tag {}; >struct polymorphic_cast_tag {}; > >template<class T> struct shared_ptr_traits >{ > typedef T & reference; >}; > >template<> struct shared_ptr_traits<void> >{ > typedef void reference; >}; > > > >template<> struct shared_ptr_traits<void const> >{ > typedef void reference; >}; > >template<> struct shared_ptr_traits<void volatile> >{ > typedef void reference; >}; > >template<> struct shared_ptr_traits<void const volatile> >{ > typedef void reference; >}; > > > > > >template<class T, class Y> void sp_enable_shared_from_this( shared_count const & pn, enable_shared_from_this< T > const * pe, Y const * px ) >{ > if(pe != 0) pe->_internal_weak_this._internal_assign(const_cast<Y*>(px), pn); >} > >inline void sp_enable_shared_from_this( shared_count const & , ... ) >{ >} > >} ># 106 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 3 4 >template<class T> class shared_ptr >{ >private: > > typedef shared_ptr< T > this_type; > >public: > > typedef T element_type; > typedef T value_type; > typedef T * pointer; > typedef typename detail::shared_ptr_traits< T >::reference reference; > > shared_ptr(): px(0), pn() > { > } > > > > > > template<class Y> > explicit shared_ptr(Y * p): px(p), pn(p, boost::checked_deleter<Y>()) > > { > detail::sp_enable_shared_from_this( pn, p, p ); > } > > > > > > > > template<class Y, class D> shared_ptr(Y * p, D d): px(p), pn(p, d) > { > detail::sp_enable_shared_from_this( pn, p, p ); > } > > > > > > > shared_ptr & operator=(shared_ptr const & r) > { > px = r.px; > pn = r.pn; > return *this; > } > > > > template<class Y> > explicit shared_ptr(weak_ptr<Y> const & r): pn(r.pn) > { > > px = r.px; > } > > template<class Y> > shared_ptr(shared_ptr<Y> const & r): px(r.px), pn(r.pn) > { > } > > template<class Y> > shared_ptr(shared_ptr<Y> const & r, detail::static_cast_tag): px(static_cast<element_type *>(r.px)), pn(r.pn) > { > } > > template<class Y> > shared_ptr(shared_ptr<Y> const & r, detail::const_cast_tag): px(const_cast<element_type *>(r.px)), pn(r.pn) > { > } > > template<class Y> > shared_ptr(shared_ptr<Y> const & r, detail::dynamic_cast_tag): px(dynamic_cast<element_type *>(r.px)), pn(r.pn) > { > if(px == 0) > { > pn = detail::shared_count(); > } > } > > template<class Y> > shared_ptr(shared_ptr<Y> const & r, detail::polymorphic_cast_tag): px(dynamic_cast<element_type *>(r.px)), pn(r.pn) > { > if(px == 0) > { > boost::serialization::throw_exception(std::bad_cast()); > } > } > > > > template<class Y> > explicit shared_ptr(std::auto_ptr<Y> & r): px(r.get()), pn() > { > Y * tmp = r.get(); > pn = detail::shared_count(r); > detail::sp_enable_shared_from_this( pn, tmp, tmp ); > } > > > > > > template<class Y> > shared_ptr & operator=(shared_ptr<Y> const & r) > { > px = r.px; > pn = r.pn; > return *this; > } > > > > > > template<class Y> > shared_ptr & operator=(std::auto_ptr<Y> & r) > { > this_type(r).swap(*this); > return *this; > } > > > > void reset() > { > this_type().swap(*this); > } > > template<class Y> void reset(Y * p) > { > (static_cast<void> (0)); > this_type(p).swap(*this); > } > > template<class Y, class D> void reset(Y * p, D d) > { > this_type(p, d).swap(*this); > } > > reference operator* () const > { > (static_cast<void> (0)); > return *px; > } > > T * operator-> () const > { > (static_cast<void> (0)); > return px; > } > > T * get() const > { > return px; > } ># 286 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 3 4 > typedef T * this_type::*unspecified_bool_type; > > operator unspecified_bool_type() const > { > return px == 0? 0: &this_type::px; > } > > > > > > bool operator! () const > { > return px == 0; > } > > bool unique() const > { > return pn.unique(); > } > > long use_count() const > { > return pn.use_count(); > } > > void swap(shared_ptr< T > & other) > { > std::swap(px, other.px); > pn.swap(other.pn); > } > > template<class Y> bool _internal_less(shared_ptr<Y> const & rhs) const > { > return pn < rhs.pn; > } > > void * _internal_get_deleter(std::type_info const & ti) const > { > return pn.get_deleter(ti); > } > > > > > > >private: > > template<class Y> friend class shared_ptr; > template<class Y> friend class weak_ptr; > > > >public: > T * px; > detail::shared_count pn; > >}; > >template<class T, class U> inline bool operator==(shared_ptr< T > const & a, shared_ptr<U> const & b) >{ > return a.get() == b.get(); >} > >template<class T, class U> inline bool operator!=(shared_ptr< T > const & a, shared_ptr<U> const & b) >{ > return a.get() != b.get(); >} ># 367 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 3 4 >template<class T, class U> inline bool operator<(shared_ptr< T > const & a, shared_ptr<U> const & b) >{ > return a._internal_less(b); >} > >template<class T> inline void swap(shared_ptr< T > & a, shared_ptr< T > & b) >{ > a.swap(b); >} > >template<class T, class U> shared_ptr< T > static_pointer_cast(shared_ptr<U> const & r) >{ > return shared_ptr< T >(r, detail::static_cast_tag()); >} > >template<class T, class U> shared_ptr< T > const_pointer_cast(shared_ptr<U> const & r) >{ > return shared_ptr< T >(r, detail::const_cast_tag()); >} > >template<class T, class U> shared_ptr< T > dynamic_pointer_cast(shared_ptr<U> const & r) >{ > return shared_ptr< T >(r, detail::dynamic_cast_tag()); >} > > > >template<class T, class U> shared_ptr< T > shared_static_cast(shared_ptr<U> const & r) >{ > return shared_ptr< T >(r, detail::static_cast_tag()); >} > >template<class T, class U> shared_ptr< T > shared_dynamic_cast(shared_ptr<U> const & r) >{ > return shared_ptr< T >(r, detail::dynamic_cast_tag()); >} > >template<class T, class U> shared_ptr< T > shared_polymorphic_cast(shared_ptr<U> const & r) >{ > return shared_ptr< T >(r, detail::polymorphic_cast_tag()); >} > >template<class T, class U> shared_ptr< T > shared_polymorphic_downcast(shared_ptr<U> const & r) >{ > (static_cast<void> (0)); > return shared_static_cast< T >(r); >} > > > >template<class T> inline T * get_pointer(shared_ptr< T > const & p) >{ > return p.get(); >} ># 439 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 3 4 >template<class E, class T, class Y> std::basic_ostream<E, T> & operator<< (std::basic_ostream<E, T> & os, shared_ptr<Y> const & p) > >{ > os << p.get(); > return os; >} ># 463 "/usr/include/boost/serialization/detail/shared_ptr_132.hpp" 3 4 >template<class D, class T> D * get_deleter(shared_ptr< T > const & p) >{ > return static_cast<D *>(p._internal_get_deleter(typeid(D))); >} > > > >} ># 36 "/usr/include/boost/serialization/shared_ptr_132.hpp" 2 3 4 > > > > > >namespace boost_132 { >namespace serialization { >namespace detail { > >struct null_deleter { > void operator()(void const *) const {} >}; > >} >} >} > > > > >namespace boost { >namespace serialization { > >template<class Archive, class P, class D> >inline void serialize( > Archive & , > boost_132::detail::sp_counted_base_impl<P, D> & , > const unsigned int >){ > > > boost::serialization::void_cast_register< > boost_132::detail::sp_counted_base_impl<P, D>, > boost_132::detail::sp_counted_base > >( > static_cast<boost_132::detail::sp_counted_base_impl<P, D> *>(__null), > static_cast<boost_132::detail::sp_counted_base *>(__null) > ); >} > >template<class Archive, class P, class D> >inline void save_construct_data( > Archive & ar, > const > boost_132::detail::sp_counted_base_impl<P, D> *t, > const unsigned int >){ > > ar << boost::serialization::make_nvp("ptr", t->ptr); >} > >template<class Archive, class P, class D> >inline void load_construct_data( > Archive & ar, > boost_132::detail::sp_counted_base_impl<P, D> * t, > const unsigned int >){ > P ptr_; > ar >> boost::serialization::make_nvp("ptr", ptr_); > > > > > > > > ::new(t)boost_132::detail::sp_counted_base_impl< > P, > boost_132::serialization::detail::null_deleter > >( > ptr_, boost_132::serialization::detail::null_deleter() > ); > > > > > t->use_count_ = 0; >} > >} >} > > > > >namespace boost { >namespace serialization { > >template<class Archive> >inline void save( > Archive & ar, > const boost_132::detail::shared_count &t, > const unsigned int >){ > ar << boost::serialization::make_nvp("pi", t.pi_); >} > >template<class Archive> >inline void load( > Archive & ar, > boost_132::detail::shared_count &t, > const unsigned int >){ > ar >> boost::serialization::make_nvp("pi", t.pi_); > if(__null != t.pi_) > t.pi_->add_ref_copy(); >} > >} >} > >namespace boost { namespace serialization { template<class Archive> inline void serialize( Archive & ar, boost_132::detail::shared_count & t, const unsigned int file_version ){ split_free(ar, t, file_version); } }} > > > > >namespace boost { >namespace serialization { > >template<class Archive, class T> >inline void save( > Archive & ar, > const boost_132::shared_ptr< T > &t, > const unsigned int >){ > > > ar.register_type(static_cast< > boost_132::detail::sp_counted_base_impl<T *, boost::checked_deleter< T > > * > >(__null)); > ar << boost::serialization::make_nvp("px", t.px); > ar << boost::serialization::make_nvp("pn", t.pn); >} > >template<class Archive, class T> >inline void load( > Archive & ar, > boost_132::shared_ptr< T > &t, > const unsigned int >){ > > > ar.register_type(static_cast< > boost_132::detail::sp_counted_base_impl<T *, boost::checked_deleter< T > > * > >(__null)); > ar >> boost::serialization::make_nvp("px", t.px); > ar >> boost::serialization::make_nvp("pn", t.pn); >} > >template<class Archive, class T> >inline void serialize( > Archive & ar, > boost_132::shared_ptr< T > &t, > const unsigned int file_version >){ > > > static_assert(boost::serialization::tracking_level< T >::value != boost::serialization::track_never, "boost::serialization::tracking_level< T >::value != boost::serialization::track_never") > > > ; > boost::serialization::split_free(ar, t, file_version); >} > >} >} ># 30 "/usr/include/boost/archive/shared_ptr_helper.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/archive/detail/abi_prefix.hpp" 1 3 4 ># 11 "/usr/include/boost/archive/detail/abi_prefix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_prefix.hpp" 1 3 4 ># 12 "/usr/include/boost/archive/detail/abi_prefix.hpp" 2 3 4 ># 36 "/usr/include/boost/archive/shared_ptr_helper.hpp" 2 3 4 > >namespace boost_132 { > template<class T> class shared_ptr; >} >namespace boost { > template<class T> class shared_ptr; > namespace serialization { > class extended_type_info; > template<class Archive, class T> > inline void load( > Archive & ar, > boost::shared_ptr< T > &t, > const unsigned int file_version > ); > } >namespace archive{ >namespace detail { > > > > >class shared_ptr_helper { > struct collection_type_compare { > bool operator()( > const shared_ptr<const void> &lhs, > const shared_ptr<const void> &rhs > )const{ > return lhs.get() < rhs.get(); > } > }; > typedef std::set< > boost::shared_ptr<const void>, > collection_type_compare > > collection_type; > typedef collection_type::const_iterator iterator_type; > > > > > > 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); > } > }; > > > > > template<class Archive, class T> > friend inline void boost::serialization::load( > Archive & ar, > boost::shared_ptr< T > &t, > const unsigned int file_version > ); ># 112 "/usr/include/boost/archive/shared_ptr_helper.hpp" 3 4 > std::list<boost_132::shared_ptr<const void> > * m_pointers_132; > > > > > shared_ptr<void> > get_od( > const void * od, > const boost::serialization::extended_type_info * true_type, > const boost::serialization::extended_type_info * this_type > ); > > void > append(const boost::shared_ptr<const void> &); > > template<class T> > struct non_polymorphic { > static const boost::serialization::extended_type_info * > get_object_identifier(T &){ > return & boost::serialization::singleton< > typename > boost::serialization::type_info_implementation< T >::type > >::get_const_instance(); > } > }; > template<class T> > struct polymorphic { > static const boost::serialization::extended_type_info * > get_object_identifier(T & t){ > return boost::serialization::singleton< > typename > boost::serialization::type_info_implementation< T >::type > >::get_const_instance().get_derived_extended_type_info(t); > } > }; >public: > template<class T> > 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(); > > > > typedef typename mpl::eval_if< > is_polymorphic< T >, > mpl::identity<polymorphic< T > >, > mpl::identity<non_polymorphic< T > > > >::type type; > > const boost::serialization::extended_type_info * true_type > = type::get_object_identifier(*t); > > > > if(__null == true_type) > boost::serialization::throw_exception( > archive_exception( > archive_exception::unregistered_class, > this_type->get_debug_info() > ) > ); > shared_ptr<void> r = > get_od( > static_cast<const void *>(t), > true_type, > this_type > ); > if(!r){ > s.reset(t); > const void * od = void_downcast( > *true_type, > *this_type, > static_cast<const void *>(t) > ); > shared_ptr<const void> sp(s, od); > append(sp); > } > else{ > s = shared_ptr< T >( > r, > static_cast<T *>(r.get()) > ); > } > } > > > void > append(const boost_132::shared_ptr<const void> & t); > >public: > > shared_ptr_helper(); > > ~shared_ptr_helper(); >}; > >} >} >} > ># 1 "/usr/include/boost/archive/detail/abi_suffix.hpp" 1 3 4 ># 14 "/usr/include/boost/archive/detail/abi_suffix.hpp" 3 4 ># 1 "/usr/include/boost/config/abi_suffix.hpp" 1 3 4 ># 15 "/usr/include/boost/archive/detail/abi_suffix.hpp" 2 3 4 ># 218 "/usr/include/boost/archive/shared_ptr_helper.hpp" 2 3 4 ># 64 "/usr/include/boost/archive/binary_iarchive.hpp" 2 3 4 > >namespace boost { >namespace archive { > > > > >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 boost { namespace archive { namespace detail { template <class Serializable> typename _ptr_serialization_support<boost::archive::binary_iarchive, Serializable>::type instantiate_ptr_serialization( Serializable*, boost::archive::binary_iarchive*, adl_tag ); }}} >namespace boost { namespace serialization { template <> struct use_array_optimization<boost::archive::binary_iarchive> { template <class ValueType> struct apply : boost::mpl::apply1<boost::archive::binary_iarchive::use_array_optimization , typename boost::remove_const<ValueType>::type >::type {}; }; }} ># 9 "/c/honeypenny/src/common/boost_serialization_helper.h" 2 > > > > > >namespace tools >{ > template<class t_object> > bool serialize_obj_to_file(t_object& obj, const std::string& file_path) > { > try {; > std::ofstream data_file; > data_file.open( file_path , std::ios_base::binary | std::ios_base::out| std::ios::trunc); > if(data_file.fail()) > return false; > > boost::archive::binary_oarchive a(data_file); > a << obj; > > return !data_file.fail(); > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/common/boost_serialization_helper.h" << ":" << 29 << "|" << __FUNCTION__ << "|" << "Exception at [" << "serialize_obj_to_file" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/common/boost_serialization_helper.h" << ":" << 29 << "|" << __FUNCTION__ << "|" << "Exception at [" << "serialize_obj_to_file" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > template<class t_object> > bool unserialize_obj_from_file(t_object& obj, const std::string& file_path) > { > try {; > > std::ifstream data_file; > data_file.open( file_path, std::ios_base::binary | std::ios_base::in); > if(data_file.fail()) > return false; > boost::archive::binary_iarchive a(data_file); > > a >> obj; > return !data_file.fail(); > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/common/boost_serialization_helper.h" << ":" << 45 << "|" << __FUNCTION__ << "|" << "Exception at [" << "unserialize_obj_from_file" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/common/boost_serialization_helper.h" << ":" << 45 << "|" << __FUNCTION__ << "|" << "Exception at [" << "unserialize_obj_from_file" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } >} ># 22 "/c/honeypenny/src/currency_core/tx_pool.h" 2 > > >namespace currency >{ > class blockchain_storage; > > > > > class tx_memory_pool: boost::noncopyable > { > public: > tx_memory_pool(blockchain_storage& bchs); > bool add_tx(const transaction &tx, const crypto::hash &id, size_t blob_size, tx_verification_context& tvc, bool keeped_by_block); > bool add_tx(const transaction &tx, tx_verification_context& tvc, bool keeped_by_block); > > bool take_tx(const crypto::hash &id, transaction &tx, size_t& blob_size, uint64_t& fee); > > bool have_tx(const crypto::hash &id); > bool have_tx_keyimg_as_spent(const crypto::key_image& key_im); > bool have_tx_keyimges_as_spent(const transaction& tx); > > bool on_blockchain_inc(uint64_t new_block_height, const crypto::hash& top_block_id); > bool on_blockchain_dec(uint64_t new_block_height, const crypto::hash& top_block_id); > > void lock(); > void unlock(); > > > bool init(const std::string& config_folder); > bool deinit(); > bool fill_block_template(block &bl, size_t median_size, uint64_t already_generated_coins, uint64_t already_donated_coins, size_t &total_size, uint64_t &fee); > bool get_transactions(std::list<transaction>& txs); > bool get_transaction(const crypto::hash& h, transaction& tx); > size_t get_transactions_count(); > bool remove_transaction_keyimages(const transaction& tx); > bool have_key_images(const std::unordered_set<crypto::key_image>& kic, const transaction& tx); > bool append_key_images(std::unordered_set<crypto::key_image>& kic, const transaction& tx); > std::string print_pool(bool short_format); > > > > > > > template<class archive_t> > void serialize(archive_t & ar, const unsigned int version) > { > if(version < 8 ) > return; > std::string project_name = "forceberry""_testnet"; ar & project_name; if(project_name != "forceberry""_testnet") {throw std::runtime_error(std::string("wrong storage file: project name in file: ") + project_name + ", expected: " + "forceberry""_testnet" );}; > epee::critical_region_t<decltype(m_transactions_lock)> critical_region_var(m_transactions_lock); > ar & m_transactions; > ar & m_spent_key_images; > } > > struct tx_details > { > transaction tx; > size_t blob_size; > uint64_t fee; > crypto::hash max_used_block_id; > uint64_t max_used_block_height; > bool kept_by_block; > > uint64_t last_failed_height; > crypto::hash last_failed_id; > }; > > private: > bool is_transaction_ready_to_go(tx_details& txd); > typedef std::unordered_map<crypto::hash, tx_details > transactions_container; > typedef std::unordered_map<crypto::key_image, std::unordered_set<crypto::hash> > key_images_container; > > epee::critical_section m_transactions_lock; > transactions_container m_transactions; > key_images_container m_spent_key_images; > > > > std::string m_config_folder; > blockchain_storage& m_blockchain; ># 130 "/c/honeypenny/src/currency_core/tx_pool.h" > class amount_visitor: public boost::static_visitor<uint64_t> > { > public: > uint64_t operator()(const txin_to_key& tx) const > { > return tx.amount; > } > uint64_t operator()(const txin_gen& tx) const > { > do{if(!(false)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/tx_pool.h" << ":" << 139 << "|" << __FUNCTION__ << "|" << "coinbase transaction in memory pool" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > return 0; > } > uint64_t operator()(const txin_to_script& tx) const {return 0;} > uint64_t operator()(const txin_to_scripthash& tx) const {return 0;} > }; > > }; >} > >namespace boost >{ > namespace serialization > { > template<class archive_t> > void serialize(archive_t & ar, currency::tx_memory_pool::tx_details& td, const unsigned int version) > { > ar & td.blob_size; > ar & td.fee; > ar & td.tx; > ar & td.max_used_block_height; > ar & td.max_used_block_id; > ar & td.last_failed_height; > ar & td.last_failed_id; > > } > } >} >namespace boost { namespace serialization { template<> struct version<currency::tx_memory_pool > { typedef mpl::int_<8> type; typedef mpl::integral_c_tag tag; static const int value = version::type::value; enum { mpl_assertion_in_line_167 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) ( boost::mpl::less< boost::mpl::int_<8>, boost::mpl::int_<256> > ))0, 1 ) ) ) }; }; } } ># 15 "/c/honeypenny/src/currency_core/currency_core.h" 2 ># 1 "/c/honeypenny/src/currency_core/blockchain_storage.h" 1 ># 9 "/c/honeypenny/src/currency_core/blockchain_storage.h" ># 1 "/usr/include/boost/serialization/list.hpp" 1 3 4 ># 23 "/usr/include/boost/serialization/list.hpp" 3 4 ># 1 "/usr/include/boost/serialization/collections_save_imp.hpp" 1 3 4 ># 28 "/usr/include/boost/serialization/collections_save_imp.hpp" 3 4 >namespace boost{ >namespace serialization { >namespace stl { > > > > > >template<class Archive, class Container> >inline void save_collection(Archive & ar, const Container &s) >{ > > collection_size_type count(s.size()); > const item_version_type item_version( > version<typename Container::value_type>::value > ); > ar << boost::serialization::make_nvp("count", count); ># 53 "/usr/include/boost/serialization/collections_save_imp.hpp" 3 4 > ar << boost::serialization::make_nvp("item_version", item_version); > > > typename Container::const_iterator it = s.begin(); > while(count-- > 0){ > > boost::serialization::save_construct_data_adl( > ar, > &(*it), > item_version > ); > ar << boost::serialization::make_nvp("item", *it++); > } >} > >} >} >} ># 24 "/usr/include/boost/serialization/list.hpp" 2 3 4 ># 1 "/usr/include/boost/serialization/collections_load_imp.hpp" 1 3 4 ># 25 "/usr/include/boost/serialization/collections_load_imp.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 26 "/usr/include/boost/serialization/collections_load_imp.hpp" 2 3 4 ># 38 "/usr/include/boost/serialization/collections_load_imp.hpp" 3 4 ># 1 "/usr/include/boost/serialization/detail/stack_constructor.hpp" 1 3 4 ># 25 "/usr/include/boost/serialization/detail/stack_constructor.hpp" 3 4 >namespace boost{ >namespace serialization { >namespace detail { > > > >template<typename T > >struct stack_allocate >{ > T * address() { > return static_cast<T*>(storage_.address()); > } > T & reference() { > return * address(); > } >private: > typedef typename boost::aligned_storage< > sizeof(T), > > > > boost::alignment_of<T>::value > > > type; > type storage_; >}; > > >template<class Archive, class T> >struct stack_construct : public stack_allocate<T> >{ > stack_construct(Archive & ar, const unsigned int version){ > > boost::serialization::load_construct_data_adl( > ar, > this->address(), > version > ); > } > ~stack_construct(){ > this->address()->~T(); > } >}; > >} >} >} ># 39 "/usr/include/boost/serialization/collections_load_imp.hpp" 2 3 4 > > > >namespace boost{ >namespace serialization { >namespace stl { > > > > > > >template<class Archive, class Container> >struct archive_input_seq >{ > inline typename Container::iterator > operator()( > Archive &ar, > Container &s, > const unsigned int v, > typename Container::iterator hint > ){ > typedef typename Container::value_type type; > detail::stack_construct<Archive, type> t(ar, v); > > ar >> boost::serialization::make_nvp("item", t.reference()); > s.push_back(t.reference()); > ar.reset_object_address(& s.back() , & t.reference()); > return hint; > } >}; > > >template<class Archive, class Container> >struct archive_input_map >{ > inline typename Container::iterator > operator()( > Archive &ar, > Container &s, > const unsigned int v, > typename Container::iterator hint > ){ > typedef typename Container::value_type type; > detail::stack_construct<Archive, type> t(ar, v); > > ar >> boost::serialization::make_nvp("item", t.reference()); > typename Container::iterator result = > s.insert(hint, t.reference()); > > > > ar.reset_object_address( > & (result->second), > & t.reference().second > ); > return result; > } >}; > > >template<class Archive, class Container> >struct archive_input_set >{ > inline typename Container::iterator > operator()( > Archive &ar, > Container &s, > const unsigned int v, > typename Container::iterator hint > ){ > typedef typename Container::value_type type; > detail::stack_construct<Archive, type> t(ar, v); > > ar >> boost::serialization::make_nvp("item", t.reference()); > typename Container::iterator result = > s.insert(hint, t.reference()); > ar.reset_object_address(& (* result), & t.reference()); > return result; > } >}; > >template<class Container> >class reserve_imp >{ >public: > void operator()(Container &s, std::size_t count) const { > s.reserve(count); > } >}; > >template<class Container> >class no_reserve_imp >{ >public: > void operator()(Container & , std::size_t ) const{} >}; > >template<class Archive, class Container, class InputFunction, class R> >inline void load_collection(Archive & ar, Container &s) >{ > s.clear(); > collection_size_type count; > const boost::archive::library_version_type library_version( > ar.get_library_version() > ); > > item_version_type item_version(0); > ar >> boost::serialization::make_nvp("count", count); > if(boost::archive::library_version_type(3) < library_version){ > ar >> boost::serialization::make_nvp("item_version", item_version); > } > > R rx; > rx(s, count); > InputFunction ifunc; > typename Container::iterator hint; > hint = s.begin(); > while(count-- > 0){ > hint = ifunc(ar, s, item_version, hint); > } >} > >} >} >} ># 25 "/usr/include/boost/serialization/list.hpp" 2 3 4 > > >namespace boost { >namespace serialization { > >template<class Archive, class U, class Allocator> >inline void save( > Archive & ar, > const std::list<U, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::save_collection< > Archive, > std::list<U, Allocator> > >(ar, t); >} > >template<class Archive, class U, class Allocator> >inline void load( > Archive & ar, > std::list<U, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::load_collection< > Archive, > std::list<U, Allocator>, > boost::serialization::stl::archive_input_seq< > Archive, > std::list<U, Allocator> > >, > boost::serialization::stl::no_reserve_imp<std::list<U, Allocator> > > >(ar, t); >} > > > >template<class Archive, class U, class Allocator> >inline void serialize( > Archive & ar, > std::list<U, Allocator> & t, > const unsigned int file_version >){ > boost::serialization::split_free(ar, t, file_version); >} > >} >} > ># 1 "/usr/include/boost/serialization/collection_traits.hpp" 1 3 4 ># 29 "/usr/include/boost/serialization/collection_traits.hpp" 3 4 ># 1 "/usr/include/boost/cstdint.hpp" 1 3 4 ># 30 "/usr/include/boost/serialization/collection_traits.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/climits" 1 3 4 ># 39 "/usr/include/c++/4.9.0/climits" 3 4 ># 40 "/usr/include/c++/4.9.0/climits" 3 > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 42 "/usr/include/c++/4.9.0/climits" 2 3 ># 32 "/usr/include/boost/serialization/collection_traits.hpp" 2 3 4 ># 74 "/usr/include/boost/serialization/list.hpp" 2 3 4 > >namespace boost { namespace serialization { template<> struct implementation_level< std::list < bool > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < signed char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < unsigned char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < signed int > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < unsigned int > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < signed long > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < unsigned long > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < float > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < double > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < unsigned short > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < signed short > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < boost::long_long_type > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < boost::ulong_long_type > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::list < wchar_t > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; } } ># 10 "/c/honeypenny/src/currency_core/blockchain_storage.h" 2 ># 1 "/usr/include/boost/multi_index_container.hpp" 1 3 4 ># 20 "/usr/include/boost/multi_index_container.hpp" 3 4 ># 1 "/usr/include/boost/detail/allocator_utilities.hpp" 1 3 4 ># 21 "/usr/include/boost/detail/allocator_utilities.hpp" 3 4 >namespace boost{ > >namespace detail{ > > > > > > >namespace allocator{ > > > > > > >template<typename Type> >class partial_std_allocator_wrapper:public std::allocator<Type> >{ >public: > > > > > > typedef Type value_type; > > partial_std_allocator_wrapper(){}; > > template<typename Other> > partial_std_allocator_wrapper(const partial_std_allocator_wrapper<Other>&){} > > partial_std_allocator_wrapper(const std::allocator<Type>& x): > std::allocator<Type>(x) > { > }; ># 70 "/usr/include/boost/detail/allocator_utilities.hpp" 3 4 >}; ># 101 "/usr/include/boost/detail/allocator_utilities.hpp" 3 4 >template<typename Allocator> >struct is_partial_std_allocator >{ > static const bool value=false; >}; > > > > > >template<typename Allocator,typename Type> >struct partial_std_allocator_rebind_to >{ > typedef partial_std_allocator_wrapper<Type> type; >}; ># 142 "/usr/include/boost/detail/allocator_utilities.hpp" 3 4 >template<typename Allocator> >struct rebinder >{ > template<typename Type> > struct result > { > typedef typename Allocator::template > rebind<Type>::other other; > }; >}; > > >template<typename Allocator,typename Type> >struct compliant_allocator_rebind_to >{ > typedef typename rebinder<Allocator>:: > template result<Type>::other type; >}; > > > >template<typename Allocator,typename Type> >struct rebind_to: > mpl::eval_if_c< > is_partial_std_allocator<Allocator>::value, > partial_std_allocator_rebind_to<Allocator,Type>, > compliant_allocator_rebind_to<Allocator,Type> > > >{ >}; > > > >template<typename Type> >void construct(void* p,const Type& t) >{ > new (p) Type(t); >} ># 190 "/usr/include/boost/detail/allocator_utilities.hpp" 3 4 >template<typename Type> >void destroy(const Type* p) >{ > > > > > p->~Type(); > > >} > > > > > >} > >} > >} ># 21 "/usr/include/boost/multi_index_container.hpp" 2 3 4 ># 31 "/usr/include/boost/multi_index_container.hpp" 3 4 ># 1 "/usr/include/boost/multi_index_container_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/multi_index_container_fwd.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/identity.hpp" 1 3 4 ># 18 "/usr/include/boost/multi_index/identity.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/identity_fwd.hpp" 1 3 4 ># 16 "/usr/include/boost/multi_index/identity_fwd.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >template<class Type> struct identity; > >} > >} ># 19 "/usr/include/boost/multi_index/identity.hpp" 2 3 4 ># 27 "/usr/include/boost/multi_index/identity.hpp" 3 4 >namespace boost{ > >template<class Type> class reference_wrapper; > >namespace multi_index{ > >namespace detail{ ># 55 "/usr/include/boost/multi_index/identity.hpp" 3 4 >template<typename Type> >struct const_identity_base >{ > typedef Type result_type; > > template<typename ChainedPtr> > > > typename disable_if<is_convertible<const ChainedPtr&,Type&>,Type&>::type > > > > > operator()(const ChainedPtr& x)const > { > return operator()(*x); > } > > Type& operator()(Type& x)const > { > return x; > } > > Type& operator()(const reference_wrapper<Type>& x)const > { > return x.get(); > } > > Type& operator()( > const reference_wrapper<typename remove_const<Type>::type>& x,int=0)const > { > return x.get(); > } >}; > >template<typename Type> >struct non_const_identity_base >{ > typedef Type result_type; > > > > template<typename ChainedPtr> > > > typename disable_if< > is_convertible<const ChainedPtr&,const Type&>,Type&>::type > > > > > operator()(const ChainedPtr& x)const > { > return operator()(*x); > } > > const Type& operator()(const Type& x,int=0)const > { > return x; > } > > Type& operator()(Type& x)const > { > return x; > } > > const Type& operator()(const reference_wrapper<const Type>& x,int=0)const > { > return x.get(); > } > > Type& operator()(const reference_wrapper<Type>& x)const > { > return x.get(); > } >}; > >} > >template<class Type> >struct identity: > mpl::if_c< > is_const<Type>::value, > detail::const_identity_base<Type>,detail::non_const_identity_base<Type> > >::type >{ >}; > >} > >} ># 18 "/usr/include/boost/multi_index_container_fwd.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/indexed_by.hpp" 1 3 4 ># 51 "/usr/include/boost/multi_index/indexed_by.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >template< > typename T0 , typename T1 =mpl::na , typename T2 =mpl::na , typename T3 =mpl::na , typename T4 =mpl::na , typename T5 =mpl::na , typename T6 =mpl::na , typename T7 =mpl::na , typename T8 =mpl::na , typename T9 =mpl::na , typename T10 =mpl::na , typename T11 =mpl::na , typename T12 =mpl::na , typename T13 =mpl::na , typename T14 =mpl::na , typename T15 =mpl::na , typename T16 =mpl::na , typename T17 =mpl::na , typename T18 =mpl::na , typename T19 =mpl::na > > >> >struct indexed_by: > mpl::vector< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19> >{ >}; > >} > >} ># 19 "/usr/include/boost/multi_index_container_fwd.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/ordered_index_fwd.hpp" 1 3 4 ># 16 "/usr/include/boost/multi_index/ordered_index_fwd.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/ord_index_args.hpp" 1 3 4 ># 21 "/usr/include/boost/multi_index/detail/ord_index_args.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/tag.hpp" 1 3 4 ># 17 "/usr/include/boost/multi_index/tag.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/no_duplicate_tags.hpp" 1 3 4 ># 18 "/usr/include/boost/multi_index/detail/no_duplicate_tags.hpp" 3 4 ># 1 "/usr/include/boost/mpl/set/set0.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/set/set0.hpp" 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/at_impl.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/set/aux_/at_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/has_key_impl.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/set/aux_/has_key_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/tag.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/set/aux_/tag.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >struct set_tag; > >}}} ># 19 "/usr/include/boost/mpl/set/aux_/has_key_impl.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/has_key_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/has_key_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct has_key_impl; >template< typename AssociativeSequence, typename Key > struct has_key; > >}} ># 20 "/usr/include/boost/mpl/set/aux_/has_key_impl.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/aux_/overload_names.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/aux_/overload_names.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/ptr_to_ref.hpp" 1 3 4 ># 40 "/usr/include/boost/mpl/aux_/ptr_to_ref.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > >template< typename T > static T const& ptr_to_ref(T*); > >}}} ># 18 "/usr/include/boost/mpl/aux_/overload_names.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/aux_/config/operators.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/overload_names.hpp" 2 3 4 ># 22 "/usr/include/boost/mpl/set/aux_/has_key_impl.hpp" 2 3 4 > > > > > > >namespace boost { namespace mpl { > >template<> >struct has_key_impl< aux::set_tag > >{ > template< typename Set, typename T > struct apply ># 47 "/usr/include/boost/mpl/set/aux_/has_key_impl.hpp" 3 4 > : bool_< > ( sizeof( Set::is_masked_( aux::ptr_to_ref(static_cast<Set*>(0)), static_cast<aux::type_wrapper<T>*>(0) ) > > > ) == sizeof(aux::no_tag) ) > > > { > > }; >}; > >}} ># 19 "/usr/include/boost/mpl/set/aux_/at_impl.hpp" 2 3 4 > > > > >namespace boost { namespace mpl { > >template<> >struct at_impl< aux::set_tag > >{ > template< typename Set, typename T > struct apply > { > typedef typename if_< > has_key_impl<aux::set_tag>::apply<Set,T> > , T > , void_ > >::type type; > }; >}; > >}} ># 19 "/usr/include/boost/mpl/set/set0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/clear_impl.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/set/aux_/clear_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/set0.hpp" 1 3 4 ># 28 "/usr/include/boost/mpl/set/aux_/set0.hpp" 3 4 >namespace boost { namespace mpl { ># 53 "/usr/include/boost/mpl/set/aux_/set0.hpp" 3 4 >template< typename Dummy = na > struct set0 >{ > typedef set0<> item_; > typedef item_ type; > typedef aux::set_tag tag; > typedef void_ last_masked_; > typedef void_ item_type_; > typedef long_<0> size; > typedef long_<1> order; > > static aux::no_tag order_by_key_(set0<> const&, void const volatile*); > static aux::yes_tag is_masked_(set0<> const&, void const volatile*); >}; > >}} ># 20 "/usr/include/boost/mpl/set/aux_/clear_impl.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template<> >struct clear_impl< aux::set_tag > >{ > template< typename Set > struct apply > { > typedef set0<> type; > }; >}; > >}} ># 20 "/usr/include/boost/mpl/set/set0.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/set/aux_/size_impl.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/set/aux_/size_impl.hpp" 3 4 >namespace boost { namespace mpl { > >template<> >struct size_impl< aux::set_tag > >{ > template< typename Set > struct apply > : Set::size > { > }; >}; > >}} ># 22 "/usr/include/boost/mpl/set/set0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/empty_impl.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/set/aux_/empty_impl.hpp" 3 4 >namespace boost { namespace mpl { > >template<> >struct empty_impl< aux::set_tag > >{ > template< typename Set > struct apply > : not_< typename Set::size > > { > }; >}; > >}} ># 23 "/usr/include/boost/mpl/set/set0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/insert_impl.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/set/aux_/insert_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/insert_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/insert_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct insert_impl; >template< typename Sequence, typename Pos_or_T, typename T > struct insert; > >}} ># 19 "/usr/include/boost/mpl/set/aux_/insert_impl.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/set/aux_/item.hpp" 1 3 4 ># 26 "/usr/include/boost/mpl/set/aux_/item.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename T, typename Base > >struct s_item > : Base >{ > typedef s_item<T,Base> item_; > typedef void_ last_masked_; > typedef T item_type_; > typedef Base base; > > typedef typename next< typename Base::size >::type size; > typedef typename next< typename Base::order >::type order; > > > > > typedef char (&order_tag_)[order::value]; > > > static order_tag_ order_by_key_(s_item const&, aux::type_wrapper<T>*); using Base::order_by_key_; > static aux::no_tag is_masked_(s_item const&, aux::type_wrapper<T>*); using Base::is_masked_; >}; > > >template< typename T, typename Base > >struct s_mask > : Base >{ > typedef s_mask<T,Base> item_; > typedef T last_masked_; > typedef void_ item_type_; > typedef Base base; > typedef typename prior< typename Base::size >::type size; > > static aux::yes_tag is_masked_(s_mask const&, aux::type_wrapper<T>*); using Base::is_masked_; >}; > > >template< typename T, typename Base > >struct s_unmask > : Base >{ > typedef s_unmask<T,Base> item_; > typedef void_ last_masked_; > typedef T item_type_; > typedef Base base; > typedef typename next< typename Base::size >::type size; > > static aux::no_tag is_masked_(s_unmask const&, aux::type_wrapper<T>*); using Base::is_masked_; >}; > >}} ># 21 "/usr/include/boost/mpl/set/aux_/insert_impl.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/base.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/base.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T = na > > >struct base >{ > typedef typename T::base type; > >}; > >template<> struct base< na > { template< typename T1 , typename T2 =na , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : base< T1 > { }; }; template< typename Tag > struct lambda< base< na > , Tag , int_<-1> > { typedef false_ is_le; typedef base< na > result_; typedef base< na > type; }; namespace aux { template< typename T1 > struct template_arity< base< T1 > > : int_<1> { }; template<> struct template_arity< base< na > > : int_<-1> { }; } > >}} ># 24 "/usr/include/boost/mpl/set/aux_/insert_impl.hpp" 2 3 4 > > > > > >namespace boost { namespace mpl { > >namespace aux { >template< typename Set, typename T > struct set_insert_impl > : eval_if< > has_key_impl<aux::set_tag>::apply<Set,T> > , identity<Set> > , eval_if< > is_same< T,typename Set::last_masked_ > > , base<Set> > , identity< s_item<T,typename Set::item_> > > > > > >{ >}; >} > >template<> >struct insert_impl< aux::set_tag > >{ > template< > typename Set > , typename PosOrKey > , typename KeyOrNA > > > struct apply > : aux::set_insert_impl< > Set > , typename if_na<KeyOrNA,PosOrKey>::type > > > { > }; >}; > >}} ># 24 "/usr/include/boost/mpl/set/set0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/erase_impl.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/set/aux_/erase_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/erase_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/erase_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct erase_impl; >template< typename Sequence, typename First, typename Last > struct erase; > >}} ># 19 "/usr/include/boost/mpl/set/aux_/erase_impl.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/erase_key_impl.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/set/aux_/erase_key_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/erase_key_fwd.hpp" 1 3 4 ># 17 "/usr/include/boost/mpl/erase_key_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct erase_key_impl; >template< typename Sequence, typename Key > struct erase_key; > >}} ># 19 "/usr/include/boost/mpl/set/aux_/erase_key_impl.hpp" 2 3 4 ># 28 "/usr/include/boost/mpl/set/aux_/erase_key_impl.hpp" 3 4 >namespace boost { namespace mpl { > >template<> >struct erase_key_impl< aux::set_tag > >{ > template< > typename Set > , typename T > > > struct apply > : eval_if< > has_key_impl<aux::set_tag>::apply<Set,T> > , eval_if< > is_same< T,typename Set::item_type_ > > , base<Set> > , identity< s_mask<T,typename Set::item_> > > > > , identity<Set> > > > { > }; >}; > >}} ># 20 "/usr/include/boost/mpl/set/aux_/erase_impl.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template<> >struct erase_impl< aux::set_tag > >{ > template< > typename Set > , typename Pos > , typename unused_ > > > struct apply > : erase_key_impl<aux::set_tag> > ::apply<Set,typename Pos::type> > { > }; >}; > >}} ># 25 "/usr/include/boost/mpl/set/set0.hpp" 2 3 4 > > ># 1 "/usr/include/boost/mpl/set/aux_/key_type_impl.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/set/aux_/key_type_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/key_type_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/key_type_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct key_type_impl; >template< typename AssociativeSequence, typename T > struct key_type; > >}} ># 19 "/usr/include/boost/mpl/set/aux_/key_type_impl.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template<> >struct key_type_impl< aux::set_tag > >{ > template< typename Set, typename T > struct apply > { > typedef T type; > }; >}; > >}} ># 28 "/usr/include/boost/mpl/set/set0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/value_type_impl.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/set/aux_/value_type_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/value_type_fwd.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/value_type_fwd.hpp" 3 4 >namespace boost { namespace mpl { > >template< typename Tag > struct value_type_impl; >template< typename AssociativeSequence, typename T > struct value_type; > >}} ># 19 "/usr/include/boost/mpl/set/aux_/value_type_impl.hpp" 2 3 4 > > >namespace boost { namespace mpl { > >template<> >struct value_type_impl< aux::set_tag > >{ > template< typename Set, typename T > struct apply > { > typedef T type; > }; >}; > >}} ># 29 "/usr/include/boost/mpl/set/set0.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/begin_end_impl.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/set/aux_/begin_end_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/set/aux_/iterator.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/set/aux_/iterator.hpp" 3 4 ># 1 "/usr/include/boost/mpl/has_key.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/has_key.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/has_key_impl.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/aux_/has_key_impl.hpp" 3 4 >namespace boost { namespace mpl { > > > >template< typename Tag > struct has_key_impl >{ > template< typename AssociativeSequence, typename Key > struct apply; >}; > > template<> struct has_key_impl<non_sequence_tag> {}; > >}} ># 21 "/usr/include/boost/mpl/has_key.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< > typename AssociativeSequence = na > , typename Key = na > > >struct has_key > : has_key_impl< typename sequence_tag<AssociativeSequence>::type > > ::template apply<AssociativeSequence,Key> >{ > >}; > >template<> struct has_key< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : has_key< T1 , T2 > { }; }; template< typename Tag > struct lambda< has_key< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef has_key< na , na > result_; typedef has_key< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< has_key< T1 , T2 > > : int_<2> { }; template<> struct template_arity< has_key< na , na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/mpl/set/aux_/iterator.hpp" 2 3 4 > > > > > > > >namespace boost { namespace mpl { > > >template< typename Set, typename Tail > struct s_iter; > >template< typename Set, typename Tail > struct s_iter_get > : eval_if< > has_key< Set,typename Tail::item_type_ > > , identity< s_iter<Set,Tail> > > , next< s_iter<Set,Tail> > > > >{ >}; > >template< typename Set, typename Tail > struct s_iter_impl >{ > typedef Tail tail_; > typedef forward_iterator_tag category; > typedef typename Tail::item_type_ type; > > > > >}; > > > >template< typename Set, typename Tail > >struct next< s_iter<Set,Tail> > > : s_iter_get< Set,typename Tail::base > >{ >}; > >template< typename Set > >struct next< s_iter<Set,set0<> > > >{ > typedef s_iter<Set,set0<> > type; >}; > >template< typename Set, typename Tail > struct s_iter > : s_iter_impl<Set,Tail> >{ >}; > >template< typename Set > struct s_iter<Set, set0<> > >{ > typedef forward_iterator_tag category; >}; ># 96 "/usr/include/boost/mpl/set/aux_/iterator.hpp" 3 4 >}} ># 20 "/usr/include/boost/mpl/set/aux_/begin_end_impl.hpp" 2 3 4 > >namespace boost { namespace mpl { > >template<> >struct begin_impl< aux::set_tag > >{ > template< typename Set > struct apply > : s_iter_get<Set,typename Set::item_> > { > }; >}; > >template<> >struct end_impl< aux::set_tag > >{ > template< typename Set > struct apply > { > typedef s_iter< Set,set0<> > type; > }; >}; > >}} ># 30 "/usr/include/boost/mpl/set/set0.hpp" 2 3 4 ># 19 "/usr/include/boost/multi_index/detail/no_duplicate_tags.hpp" 2 3 4 > >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 36 "/usr/include/boost/multi_index/detail/no_duplicate_tags.hpp" 3 4 >struct duplicate_tag_mark{}; > >struct duplicate_tag_marker >{ > template <typename MplSet,typename Tag> > struct apply > { > typedef mpl::s_item< > typename mpl::if_<mpl::has_key<MplSet,Tag>,duplicate_tag_mark,Tag>::type, > MplSet > > type; > }; >}; > >template<typename TagList> >struct no_duplicate_tags >{ > typedef typename mpl::fold< > TagList, > mpl::set0<>, > duplicate_tag_marker > >::type aux; > > static const bool value=!(mpl::has_key<aux,duplicate_tag_mark>::value) > ; >}; > > > > > >struct duplicate_tag_list_marker >{ > template <typename MplSet,typename Index> > struct apply:mpl::fold< > typename Index::tag_list, > MplSet, > duplicate_tag_marker> > { > }; >}; > >template<typename IndexList> >struct no_duplicate_tags_in_index_list >{ > typedef typename mpl::fold< > IndexList, > mpl::set0<>, > duplicate_tag_list_marker > >::type aux; > > static const bool value=!(mpl::has_key<aux,duplicate_tag_mark>::value) > ; >}; > >} > >} > >} ># 18 "/usr/include/boost/multi_index/tag.hpp" 2 3 4 ># 50 "/usr/include/boost/multi_index/tag.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > >struct tag_marker{}; > >template<typename T> >struct is_tag >{ > static const bool value=(is_base_and_derived<tag_marker,T>::value); >}; > >} > >template< > typename T0 =mpl::na , typename T1 =mpl::na , typename T2 =mpl::na , typename T3 =mpl::na , typename T4 =mpl::na , typename T5 =mpl::na , typename T6 =mpl::na , typename T7 =mpl::na , typename T8 =mpl::na , typename T9 =mpl::na , typename T10 =mpl::na , typename T11 =mpl::na , typename T12 =mpl::na , typename T13 =mpl::na , typename T14 =mpl::na , typename T15 =mpl::na , typename T16 =mpl::na , typename T17 =mpl::na , typename T18 =mpl::na , typename T19 =mpl::na > > > >> >struct tag:private detail::tag_marker >{ > > > > > typedef typename mpl::transform< > mpl::vector< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19>, > mpl::identity<mpl::_1> > >::type type; > > static_assert(detail::no_duplicate_tags<type>::value, "detail::no_duplicate_tags<type>::value"); >}; > >} > >} ># 22 "/usr/include/boost/multi_index/detail/ord_index_args.hpp" 2 3 4 > > > > >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 43 "/usr/include/boost/multi_index/detail/ord_index_args.hpp" 3 4 >template<typename KeyFromValue> >struct index_args_default_compare >{ > typedef std::less<typename KeyFromValue::result_type> type; >}; > >template<typename Arg1,typename Arg2,typename Arg3> >struct ordered_index_args >{ > typedef is_tag<Arg1> full_form; > > typedef typename mpl::if_< > full_form, > Arg1, > tag< > >::type tag_list_type; > typedef typename mpl::if_< > full_form, > Arg2, > Arg1>::type key_from_value_type; > typedef typename mpl::if_< > full_form, > Arg3, > Arg2>::type supplied_compare_type; > typedef typename mpl::eval_if< > mpl::is_na<supplied_compare_type>, > index_args_default_compare<key_from_value_type>, > mpl::identity<supplied_compare_type> > >::type compare_type; > > static_assert(is_tag<tag_list_type>::value, "is_tag<tag_list_type>::value"); > static_assert(!mpl::is_na<key_from_value_type>::value, "!mpl::is_na<key_from_value_type>::value"); > static_assert(!mpl::is_na<compare_type>::value, "!mpl::is_na<compare_type>::value"); >}; > >} > >} > >} ># 17 "/usr/include/boost/multi_index/ordered_index_fwd.hpp" 2 3 4 > >namespace boost{ > >namespace multi_index{ > >namespace detail{ > >template< > typename KeyFromValue,typename Compare, > typename SuperMeta,typename TagList,typename Category >> >class ordered_index; > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator==( > const ordered_index< > KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index< > KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y); > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator<( > const ordered_index< > KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index< > KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y); > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator!=( > const ordered_index< > KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index< > KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y); > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator>( > const ordered_index< > KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index< > KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y); > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator>=( > const ordered_index< > KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index< > KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y); > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator<=( > const ordered_index< > KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index< > KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y); > >template< > typename KeyFromValue,typename Compare, > typename SuperMeta,typename TagList,typename Category >> >void swap( > ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& x, > ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& y); > >} > > > >template<typename Arg1,typename Arg2=mpl::na,typename Arg3=mpl::na> >struct ordered_unique; > >template<typename Arg1,typename Arg2=mpl::na,typename Arg3=mpl::na> >struct ordered_non_unique; > >} > >} ># 20 "/usr/include/boost/multi_index_container_fwd.hpp" 2 3 4 > > >namespace boost{ > >namespace multi_index{ > > > > > >template< > typename Value, > typename IndexSpecifierList=indexed_by<ordered_unique<identity<Value> > >, > typename Allocator=std::allocator<Value> > >class multi_index_container; > >template<typename MultiIndexContainer,int N> >struct nth_index; > >template<typename MultiIndexContainer,typename Tag> >struct index; > >template<typename MultiIndexContainer,int N> >struct nth_index_iterator; > >template<typename MultiIndexContainer,int N> >struct nth_index_const_iterator; > >template<typename MultiIndexContainer,typename Tag> >struct index_iterator; > >template<typename MultiIndexContainer,typename Tag> >struct index_const_iterator; > > > > > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator==( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y); > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator<( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y); > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator!=( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y); > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator>( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y); > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator>=( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y); > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator<=( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y); > >template<typename Value,typename IndexSpecifierList,typename Allocator> >void swap( > multi_index_container<Value,IndexSpecifierList,Allocator>& x, > multi_index_container<Value,IndexSpecifierList,Allocator>& y); > >} > > > > > >using multi_index::multi_index_container; > >} ># 32 "/usr/include/boost/multi_index_container.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/access_specifier.hpp" 1 3 4 ># 33 "/usr/include/boost/multi_index_container.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/adl_swap.hpp" 1 3 4 ># 19 "/usr/include/boost/multi_index/detail/adl_swap.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > >template<typename T> >void adl_swap(T& x,T& y) >{ > > > using std::swap; > swap(x,y); > > > > >} > >} > >} > >} ># 34 "/usr/include/boost/multi_index_container.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/base_type.hpp" 1 3 4 ># 19 "/usr/include/boost/multi_index/detail/base_type.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 20 "/usr/include/boost/multi_index/detail/base_type.hpp" 2 3 4 > ># 1 "/usr/include/boost/multi_index/detail/index_base.hpp" 1 3 4 ># 22 "/usr/include/boost/multi_index/detail/index_base.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/copy_map.hpp" 1 3 4 ># 19 "/usr/include/boost/multi_index/detail/copy_map.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/auto_space.hpp" 1 3 4 ># 20 "/usr/include/boost/multi_index/detail/auto_space.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/prevent_eti.hpp" 1 3 4 ># 25 "/usr/include/boost/multi_index/detail/prevent_eti.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 47 "/usr/include/boost/multi_index/detail/prevent_eti.hpp" 3 4 >template<typename Type,typename Construct> >struct prevent_eti >{ > typedef Construct type; >}; > > >} > >} > >} ># 21 "/usr/include/boost/multi_index/detail/auto_space.hpp" 2 3 4 > > > >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 46 "/usr/include/boost/multi_index/detail/auto_space.hpp" 3 4 >template<typename T,typename Allocator=std::allocator<T> > >struct auto_space:private noncopyable >{ > typedef typename prevent_eti< > Allocator, > typename boost::detail::allocator::rebind_to< > Allocator,T > >::type > >::type::pointer pointer; > > explicit auto_space(const Allocator& al=Allocator(),std::size_t n=1): > al_(al),n_(n),data_(n_?al_.allocate(n_):pointer(0)) > {} > > ~auto_space() > { > if(n_)al_.deallocate(data_,n_); > } > > Allocator get_allocator()const{return al_;} > > pointer data()const{return data_;} > > void swap(auto_space& x) > { > if(al_!=x.al_)adl_swap(al_,x.al_); > std::swap(n_,x.n_); > std::swap(data_,x.data_); > } > >private: > typename boost::detail::allocator::rebind_to< > Allocator,T>::type al_; > std::size_t n_; > pointer data_; >}; > >template<typename T,typename Allocator> >void swap(auto_space<T,Allocator>& x,auto_space<T,Allocator>& y) >{ > x.swap(y); >} > >} > >} > >} ># 20 "/usr/include/boost/multi_index/detail/copy_map.hpp" 2 3 4 > > > > > >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 43 "/usr/include/boost/multi_index/detail/copy_map.hpp" 3 4 >template <typename Node> >struct copy_map_entry >{ > copy_map_entry(Node* f,Node* s):first(f),second(s){} > > Node* first; > Node* second; > > bool operator<(const copy_map_entry<Node>& x)const > { > return std::less<Node*>()(first,x.first); > } >}; > >template <typename Node,typename Allocator> >class copy_map:private noncopyable >{ >public: > typedef const copy_map_entry<Node>* const_iterator; > > copy_map( > const Allocator& al,std::size_t size,Node* header_org,Node* header_cpy): > al_(al),size_(size),spc(al_,size_),n(0), > header_org_(header_org),header_cpy_(header_cpy),released(false) > {} > > ~copy_map() > { > if(!released){ > for(std::size_t i=0;i<n;++i){ > boost::detail::allocator::destroy(&(spc.data()+i)->second->value()); > deallocate((spc.data()+i)->second); > } > } > } > > const_iterator begin()const{return &*spc.data();} > const_iterator end()const{return &*(spc.data()+n);} > > void clone(Node* node) > { > (spc.data()+n)->first=node; > (spc.data()+n)->second=&*al_.allocate(1); > { try{ > boost::detail::allocator::construct( > &(spc.data()+n)->second->value(),node->value()); > } > catch(...){ > deallocate((spc.data()+n)->second); > throw;; > } > } > ++n; > > if(n==size_)std::sort(&*spc.data(),&*spc.data()+size_); > } > > Node* find(Node* node)const > { > if(node==header_org_)return header_cpy_; > return std::lower_bound( > begin(),end(),copy_map_entry<Node>(node,0))->second; > } > > void release() > { > released=true; > } > >private: > typedef typename prevent_eti< > Allocator, > typename boost::detail::allocator::rebind_to< > Allocator,Node>::type > >::type allocator_type; > typedef typename allocator_type::pointer allocator_pointer; > > allocator_type al_; > std::size_t size_; > auto_space<copy_map_entry<Node>,Allocator> spc; > std::size_t n; > Node* header_org_; > Node* header_cpy_; > bool released; > > void deallocate(Node* node) > { > al_.deallocate(static_cast<allocator_pointer>(node),1); > } >}; > >} > >} > >} ># 23 "/usr/include/boost/multi_index/detail/index_base.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/do_not_copy_elements_tag.hpp" 1 3 4 ># 16 "/usr/include/boost/multi_index/detail/do_not_copy_elements_tag.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > > >struct do_not_copy_elements_tag{}; > >} > >} > >} ># 24 "/usr/include/boost/multi_index/detail/index_base.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/node_type.hpp" 1 3 4 ># 18 "/usr/include/boost/multi_index/detail/node_type.hpp" 3 4 ># 1 "/usr/include/boost/mpl/bind.hpp" 1 3 4 ># 19 "/usr/include/boost/multi_index/detail/node_type.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/reverse_iter_fold.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/reverse_iter_fold.hpp" 3 4 ># 1 "/usr/include/boost/mpl/arg.hpp" 1 3 4 ># 21 "/usr/include/boost/mpl/reverse_iter_fold.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/aux_/reverse_iter_fold_impl.hpp" 1 3 4 ># 19 "/usr/include/boost/mpl/aux_/reverse_iter_fold_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 20 "/usr/include/boost/mpl/aux_/reverse_iter_fold_impl.hpp" 2 3 4 ># 34 "/usr/include/boost/mpl/aux_/reverse_iter_fold_impl.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/reverse_iter_fold_impl.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/reverse_iter_fold_impl.hpp" 3 4 >namespace boost { namespace mpl { namespace aux { > > > >template< > long N > , typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_iter_fold_impl; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_iter_fold_impl< 0,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef fwd_state0 bkwd_state0; > typedef bkwd_state0 state; > typedef iter0 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_iter_fold_impl< 1,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp,fwd_state0,iter0 >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > > > typedef fwd_state1 bkwd_state1; > typedef typename apply2< BackwardOp,bkwd_state1,iter0 >::type bkwd_state0; > typedef bkwd_state0 state; > typedef iter1 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_iter_fold_impl< 2,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp,fwd_state0,iter0 >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp,fwd_state1,iter1 >::type fwd_state2; > typedef typename mpl::next<iter1>::type iter2; > > > typedef fwd_state2 bkwd_state2; > typedef typename apply2< BackwardOp,bkwd_state2,iter1 >::type bkwd_state1; > typedef typename apply2< BackwardOp,bkwd_state1,iter0 >::type bkwd_state0; > > > typedef bkwd_state0 state; > typedef iter2 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_iter_fold_impl< 3,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp,fwd_state0,iter0 >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp,fwd_state1,iter1 >::type fwd_state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp,fwd_state2,iter2 >::type fwd_state3; > typedef typename mpl::next<iter2>::type iter3; > > > typedef fwd_state3 bkwd_state3; > typedef typename apply2< BackwardOp,bkwd_state3,iter2 >::type bkwd_state2; > typedef typename apply2< BackwardOp,bkwd_state2,iter1 >::type bkwd_state1; > typedef typename apply2< BackwardOp,bkwd_state1,iter0 >::type bkwd_state0; > > > typedef bkwd_state0 state; > typedef iter3 iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_iter_fold_impl< 4,First,Last,State,BackwardOp,ForwardOp > >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp,fwd_state0,iter0 >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp,fwd_state1,iter1 >::type fwd_state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp,fwd_state2,iter2 >::type fwd_state3; > typedef typename mpl::next<iter2>::type iter3; > typedef typename apply2< ForwardOp,fwd_state3,iter3 >::type fwd_state4; > typedef typename mpl::next<iter3>::type iter4; > > > typedef fwd_state4 bkwd_state4; > typedef typename apply2< BackwardOp,bkwd_state4,iter3 >::type bkwd_state3; > typedef typename apply2< BackwardOp,bkwd_state3,iter2 >::type bkwd_state2; > typedef typename apply2< BackwardOp,bkwd_state2,iter1 >::type bkwd_state1; > typedef typename apply2< BackwardOp,bkwd_state1,iter0 >::type bkwd_state0; > > > typedef bkwd_state0 state; > typedef iter4 iterator; >}; > >template< > long N > , typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_iter_fold_impl >{ > typedef First iter0; > typedef State fwd_state0; > typedef typename apply2< ForwardOp,fwd_state0,iter0 >::type fwd_state1; > typedef typename mpl::next<iter0>::type iter1; > typedef typename apply2< ForwardOp,fwd_state1,iter1 >::type fwd_state2; > typedef typename mpl::next<iter1>::type iter2; > typedef typename apply2< ForwardOp,fwd_state2,iter2 >::type fwd_state3; > typedef typename mpl::next<iter2>::type iter3; > typedef typename apply2< ForwardOp,fwd_state3,iter3 >::type fwd_state4; > typedef typename mpl::next<iter3>::type iter4; > > > typedef reverse_iter_fold_impl< > ( (N - 4) < 0 ? 0 : N - 4 ) > , iter4 > , Last > , fwd_state4 > , BackwardOp > , ForwardOp > > nested_chunk; > > typedef typename nested_chunk::state bkwd_state4; > typedef typename apply2< BackwardOp,bkwd_state4,iter3 >::type bkwd_state3; > typedef typename apply2< BackwardOp,bkwd_state3,iter2 >::type bkwd_state2; > typedef typename apply2< BackwardOp,bkwd_state2,iter1 >::type bkwd_state1; > typedef typename apply2< BackwardOp,bkwd_state1,iter0 >::type bkwd_state0; > > > typedef bkwd_state0 state; > typedef typename nested_chunk::iterator iterator; >}; > >template< > typename First > , typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_iter_fold_impl< -1,First,Last,State,BackwardOp,ForwardOp > >{ > typedef reverse_iter_fold_impl< > -1 > , typename mpl::next<First>::type > , Last > , typename apply2< ForwardOp,State,First >::type > , BackwardOp > , ForwardOp > > nested_step; > > typedef typename apply2< > BackwardOp > , typename nested_step::state > , First > >::type state; > > typedef typename nested_step::iterator iterator; >}; > >template< > typename Last > , typename State > , typename BackwardOp > , typename ForwardOp > > >struct reverse_iter_fold_impl< -1,Last,Last,State,BackwardOp,ForwardOp > >{ > typedef State state; > typedef Last iterator; >}; > >}}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 35 "/usr/include/boost/mpl/aux_/reverse_iter_fold_impl.hpp" 2 3 4 ># 23 "/usr/include/boost/mpl/reverse_iter_fold.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< > typename Sequence = na > , typename State = na > , typename BackwardOp = na > , typename ForwardOp = arg<1> > > >struct reverse_iter_fold >{ > typedef typename aux::reverse_iter_fold_impl< > ::boost::mpl::O1_size<Sequence>::value > , typename begin<Sequence>::type > , typename end<Sequence>::type > , State > , typename lambda<BackwardOp>::type > , typename lambda<ForwardOp>::type > >::state type; > > > > > > >}; > >template<> struct reverse_iter_fold< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : reverse_iter_fold< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< reverse_iter_fold< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef reverse_iter_fold< na , na , na > result_; typedef reverse_iter_fold< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< reverse_iter_fold< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< reverse_iter_fold< na , na , na > > : int_<-1> { }; } > >}} ># 20 "/usr/include/boost/multi_index/detail/node_type.hpp" 2 3 4 > > ># 1 "/usr/include/boost/multi_index/detail/header_holder.hpp" 1 3 4 ># 18 "/usr/include/boost/multi_index/detail/header_holder.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 32 "/usr/include/boost/multi_index/detail/header_holder.hpp" 3 4 >template<typename NodeTypePtr,typename Final> >struct header_holder:private noncopyable >{ > header_holder():member(final().allocate_node()){} > ~header_holder(){final().deallocate_node(&*member);} > > NodeTypePtr member; > >private: > Final& final(){return *static_cast<Final*>(this);} >}; > >} > >} > >} ># 23 "/usr/include/boost/multi_index/detail/node_type.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/index_node_base.hpp" 1 3 4 ># 17 "/usr/include/boost/multi_index/detail/index_node_base.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/aligned_storage.hpp" 1 3 4 ># 18 "/usr/include/boost/multi_index/detail/index_node_base.hpp" 2 3 4 ># 26 "/usr/include/boost/multi_index/detail/index_node_base.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > > >template<typename Value> >struct pod_value_holder >{ > typename aligned_storage< > sizeof(Value), > alignment_of<Value>::value > >::type space; >}; > >template<typename Value,typename Allocator> >struct index_node_base:private pod_value_holder<Value> >{ > typedef index_node_base base_type; > typedef Value value_type; > typedef Allocator allocator_type; > > value_type& value() > { > return *static_cast<value_type*>( > static_cast<void*>(&this->space)); > } > > const value_type& value()const > { > return *static_cast<const value_type*>( > static_cast<const void*>(&this->space)); > } > > static index_node_base* from_value(const value_type* p) > { > return static_cast<index_node_base *>( > reinterpret_cast<pod_value_holder<Value>*>( > const_cast<value_type*>(p))); > } > >private: > > friend class boost::serialization::access; > > > > > > > template<class Archive> > void serialize(Archive&,const unsigned int) > { > } > >}; > >template<typename Node,typename Value> >Node* node_from_value( > const Value* p > ) >{ > typedef typename Node::allocator_type allocator_type; > return static_cast<Node*>( > index_node_base<Value,allocator_type>::from_value(p)); >} > >} > >} ># 111 "/usr/include/boost/multi_index/detail/index_node_base.hpp" 3 4 >namespace multi_index{ >namespace detail{ > > >template<class Archive,typename Value,typename Allocator> >inline void load_construct_data( > Archive&,boost::multi_index::detail::index_node_base<Value,Allocator>*, > const unsigned int) >{ > throw_exception( > archive::archive_exception(archive::archive_exception::other_exception)); >} > > > > >} >} > > > > >} ># 24 "/usr/include/boost/multi_index/detail/node_type.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/is_index_list.hpp" 1 3 4 ># 20 "/usr/include/boost/multi_index/detail/is_index_list.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > >template<typename T> >struct is_index_list >{ > static const bool mpl_sequence=mpl::is_sequence<T>::value; > static const bool non_empty=!mpl::empty<T>::value; > static const bool value=mpl_sequence&&non_empty; >}; > >} > >} > >} ># 25 "/usr/include/boost/multi_index/detail/node_type.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/msvc_index_specifier.hpp" 1 3 4 ># 26 "/usr/include/boost/multi_index/detail/node_type.hpp" 2 3 4 > > >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 49 "/usr/include/boost/multi_index/detail/node_type.hpp" 3 4 >struct index_node_applier >{ > template<typename IndexSpecifierIterator,typename Super> > struct apply > { > typedef typename mpl::deref<IndexSpecifierIterator>::type index_specifier; > typedef typename index_specifier:: > template node_class<Super>::type type; > }; >}; > > >template<typename Value,typename IndexSpecifierList,typename Allocator> >struct multi_index_node_type >{ > static_assert(detail::is_index_list<IndexSpecifierList>::value, "detail::is_index_list<IndexSpecifierList>::value"); > > typedef typename mpl::reverse_iter_fold< > IndexSpecifierList, > index_node_base<Value,Allocator>, > mpl::bind2<index_node_applier,mpl::_2,mpl::_1> > >::type type; >}; > >} > >} > >} ># 25 "/usr/include/boost/multi_index/detail/index_base.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/vartempl_support.hpp" 1 3 4 ># 228 "/usr/include/boost/multi_index/detail/vartempl_support.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > >template<typename Value,typename... Args> >Value* vartempl_placement_new(Value*x,Args&&... args) >{ > return new(x) Value(std::forward<Args>(args)...); >} > >} > >} > >} ># 26 "/usr/include/boost/multi_index/detail/index_base.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/multi_index/detail/index_loader.hpp" 1 3 4 ># 25 "/usr/include/boost/multi_index/detail/index_loader.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > > > > >template<typename Node,typename FinalNode,typename Allocator> >class index_loader:private noncopyable >{ >public: > index_loader(const Allocator& al,std::size_t size): > spc(al,size),size_(size),n(0),sorted(false) > { > } > > template<class Archive> > void add(Node* node,Archive& ar,const unsigned int) > { > ar>>serialization::make_nvp("position",*node); > entries()[n++]=node; > } > > template<class Archive> > void add_track(Node* node,Archive& ar,const unsigned int) > { > ar>>serialization::make_nvp("position",*node); > } > > > > > > > > template<typename Rearranger,class Archive> > void load(Rearranger r,Archive& ar,const unsigned int)const > { > FinalNode* prev=unchecked_load_node(ar); > if(!prev)return; > > if(!sorted){ > std::sort(entries(),entries()+size_); > sorted=true; > } > > check_node(prev); > > for(;;){ > for(;;){ > FinalNode* node=load_node(ar); > if(!node)break; > > if(node==prev)prev=0; > r(prev,node); > > prev=node; > } > prev=load_node(ar); > if(!prev)break; > } > } > >private: > Node** entries()const{return &*spc.data();} > > > > > > template<class Archive> > FinalNode* unchecked_load_node(Archive& ar)const > { > Node* node=0; > ar>>serialization::make_nvp("pointer",node); > return static_cast<FinalNode*>(node); > } > > template<class Archive> > FinalNode* load_node(Archive& ar)const > { > Node* node=0; > ar>>serialization::make_nvp("pointer",node); > check_node(node); > return static_cast<FinalNode*>(node); > } > > void check_node(Node* node)const > { > if(node!=0&&!std::binary_search(entries(),entries()+size_,node)){ > throw_exception( > archive::archive_exception( > archive::archive_exception::other_exception)); > } > } > > auto_space<Node*,Allocator> spc; > std::size_t size_; > std::size_t n; > mutable bool sorted; >}; > >} > >} > >} ># 32 "/usr/include/boost/multi_index/detail/index_base.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/index_saver.hpp" 1 3 4 ># 17 "/usr/include/boost/multi_index/detail/index_saver.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/index_matcher.hpp" 1 3 4 ># 23 "/usr/include/boost/multi_index/detail/index_matcher.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 58 "/usr/include/boost/multi_index/detail/index_matcher.hpp" 3 4 >namespace index_matcher{ ># 67 "/usr/include/boost/multi_index/detail/index_matcher.hpp" 3 4 >struct entry >{ > entry(void* node_,std::size_t pos_=0):node(node_),pos(pos_){} > > > > void* node; > std::size_t pos; > entry* previous; > bool ordered; > > struct less_by_node > { > bool operator()( > const entry& x,const entry& y)const > { > return std::less<void*>()(x.node,y.node); > } > }; > > > > std::size_t pile_top; > entry* pile_top_entry; > > struct less_by_pile_top > { > bool operator()( > const entry& x,const entry& y)const > { > return x.pile_top<y.pile_top; > } > }; >}; > > > >template<typename Allocator> >class algorithm_base:private noncopyable >{ >protected: > algorithm_base(const Allocator& al,std::size_t size): > spc(al,size),size_(size),n_(0),sorted(false) > { > } > > void add(void* node) > { > entries()[n_]=entry(node,n_); > ++n_; > } > > void begin_algorithm()const > { > if(!sorted){ > std::sort(entries(),entries()+size_,entry::less_by_node()); > sorted=true; > } > num_piles=0; > } > > void add_node_to_algorithm(void* node)const > { > entry* ent= > std::lower_bound( > entries(),entries()+size_, > entry(node),entry::less_by_node()); > ent->ordered=false; > std::size_t n=ent->pos; > > entry dummy(0); > dummy.pile_top=n; > > entry* pile_ent= > std::lower_bound( > entries(),entries()+num_piles, > dummy,entry::less_by_pile_top()); > > pile_ent->pile_top=n; > pile_ent->pile_top_entry=ent; > > > if(pile_ent>&entries()[0]){ > ent->previous=(pile_ent-1)->pile_top_entry; > } > > if(pile_ent==&entries()[num_piles]){ > ++num_piles; > } > } > > void finish_algorithm()const > { > if(num_piles>0){ > > > > > > entry* ent=entries()[num_piles-1].pile_top_entry; > for(std::size_t n=num_piles;n--;){ > ent->ordered=true; > ent=ent->previous; > } > } > } > > bool is_ordered(void * node)const > { > return std::lower_bound( > entries(),entries()+size_, > entry(node),entry::less_by_node())->ordered; > } > >private: > entry* entries()const{return &*spc.data();} > > auto_space<entry,Allocator> spc; > std::size_t size_; > std::size_t n_; > mutable bool sorted; > mutable std::size_t num_piles; >}; > > > > > > > >template<typename Node,typename Allocator> >class algorithm:private algorithm_base<Allocator> >{ > typedef algorithm_base<Allocator> super; > >public: > algorithm(const Allocator& al,std::size_t size):super(al,size){} > > void add(Node* node) > { > super::add(node); > } > > template<typename IndexIterator> > void execute(IndexIterator first,IndexIterator last)const > { > super::begin_algorithm(); > > for(IndexIterator it=first;it!=last;++it){ > add_node_to_algorithm(get_node(it)); > } > > super::finish_algorithm(); > } > > bool is_ordered(Node* node)const > { > return super::is_ordered(node); > } > >private: > void add_node_to_algorithm(Node* node)const > { > super::add_node_to_algorithm(node); > } > > template<typename IndexIterator> > static Node* get_node(IndexIterator it) > { > return static_cast<Node*>(it.get_node()); > } >}; > >} > >} > >} > >} ># 18 "/usr/include/boost/multi_index/detail/index_saver.hpp" 2 3 4 > > > > >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 37 "/usr/include/boost/multi_index/detail/index_saver.hpp" 3 4 >template<typename Node,typename Allocator> >class index_saver:private noncopyable >{ >public: > index_saver(const Allocator& al,std::size_t size):alg(al,size){} > > template<class Archive> > void add(Node* node,Archive& ar,const unsigned int) > { > ar<<serialization::make_nvp("position",*node); > alg.add(node); > } > > template<class Archive> > void add_track(Node* node,Archive& ar,const unsigned int) > { > ar<<serialization::make_nvp("position",*node); > } > > template<typename IndexIterator,class Archive> > void save( > IndexIterator first,IndexIterator last,Archive& ar, > const unsigned int)const > { > > > alg.execute(first,last); ># 95 "/usr/include/boost/multi_index/detail/index_saver.hpp" 3 4 > std::size_t last_saved=3; > for(IndexIterator it=first,prev=first;it!=last;prev=it++,++last_saved){ > if(!alg.is_ordered(get_node(it))){ > if(last_saved>1)save_node(get_node(prev),ar); > save_node(get_node(it),ar); > last_saved=0; > } > else if(last_saved==2)save_node(null_node(),ar); > } > if(last_saved<=2)save_node(null_node(),ar); > > > > save_node(null_node(),ar); > } > >private: > template<typename IndexIterator> > static Node* get_node(IndexIterator it) > { > return it.get_node(); > } > > static Node* null_node(){return 0;} > > template<typename Archive> > static void save_node(Node* node,Archive& ar) > { > ar<<serialization::make_nvp("pointer",node); > } > > index_matcher::algorithm<Node,Allocator> alg; >}; > >} > >} > >} ># 33 "/usr/include/boost/multi_index/detail/index_base.hpp" 2 3 4 > > >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 49 "/usr/include/boost/multi_index/detail/index_base.hpp" 3 4 >struct lvalue_tag{}; >struct rvalue_tag{}; >struct emplaced_tag{}; > >template<typename Value,typename IndexSpecifierList,typename Allocator> >class index_base >{ >protected: > typedef index_node_base<Value,Allocator> node_type; > typedef typename multi_index_node_type< > Value,IndexSpecifierList,Allocator>::type final_node_type; > typedef multi_index_container< > Value,IndexSpecifierList,Allocator> final_type; > typedef tuples::null_type ctor_args_list; > typedef typename > boost::detail::allocator::rebind_to< > Allocator, > typename Allocator::value_type>::type final_allocator_type; > typedef mpl::vector0<> index_type_list; > typedef mpl::vector0<> iterator_type_list; > typedef mpl::vector0<> const_iterator_type_list; > typedef copy_map< > final_node_type, > final_allocator_type> copy_map_type; > > > typedef index_saver< > node_type, > final_allocator_type> index_saver_type; > typedef index_loader< > node_type, > final_node_type, > final_allocator_type> index_loader_type; > > >private: > typedef Value value_type; > >protected: > explicit index_base(const ctor_args_list&,const Allocator&){} > > index_base( > const index_base<Value,IndexSpecifierList,Allocator>&, > do_not_copy_elements_tag) > {} > > void copy_( > const index_base<Value,IndexSpecifierList,Allocator>&,const copy_map_type&) > {} > > node_type* insert_(const value_type& v,node_type* x,lvalue_tag) > { > boost::detail::allocator::construct(&x->value(),v); > return x; > } > > node_type* insert_(const value_type& v,node_type* x,rvalue_tag) > { > > > > > > > > new (&x->value()) value_type(boost::move(const_cast<value_type&>(v))); > return x; > } > > node_type* insert_(const value_type&,node_type* x,emplaced_tag) > { > return x; > } > > node_type* insert_(const value_type& v,node_type*,node_type* x,lvalue_tag) > { > boost::detail::allocator::construct(&x->value(),v); > return x; > } > > node_type* insert_(const value_type& v,node_type*,node_type* x,rvalue_tag) > { > new (&x->value()) value_type(boost::move(const_cast<value_type&>(v))); > return x; > } > > node_type* insert_(const value_type&,node_type*,node_type* x,emplaced_tag) > { > return x; > } > > void erase_(node_type* x) > { > boost::detail::allocator::destroy(&x->value()); > } > > void delete_node_(node_type* x) > { > boost::detail::allocator::destroy(&x->value()); > } > > void clear_(){} > > void swap_(index_base<Value,IndexSpecifierList,Allocator>&){} > > void swap_elements_(index_base<Value,IndexSpecifierList,Allocator>&){} > > bool replace_(const value_type& v,node_type* x,lvalue_tag) > { > x->value()=v; > return true; > } > > bool replace_(const value_type& v,node_type* x,rvalue_tag) > { > x->value()=boost::move(const_cast<value_type&>(v)); > return true; > } > > bool modify_(node_type*){return true;} > > bool modify_rollback_(node_type*){return true;} > > > > > template<typename Archive> > void save_(Archive&,const unsigned int,const index_saver_type&)const{} > > template<typename Archive> > void load_(Archive&,const unsigned int,const index_loader_type&){} ># 190 "/usr/include/boost/multi_index/detail/index_base.hpp" 3 4 > final_type& final(){return *static_cast<final_type*>(this);} > const final_type& final()const{return *static_cast<const final_type*>(this);} > > final_node_type* final_header()const{return final().header();} > > bool final_empty_()const{return final().empty_();} > std::size_t final_size_()const{return final().size_();} > std::size_t final_max_size_()const{return final().max_size_();} > > std::pair<final_node_type*,bool> final_insert_(const value_type& x) > {return final().insert_(x);} > std::pair<final_node_type*,bool> final_insert_rv_(const value_type& x) > {return final().insert_rv_(x);} > template<typename T> > std::pair<final_node_type*,bool> final_insert_ref_(T& t) > {return final().insert_ref_(t);} > > template<typename... Args> > std::pair<final_node_type*,bool> final_emplace_( > Args&&... args) > { > return final().emplace_(std::forward<Args>(args)...); > } > > std::pair<final_node_type*,bool> final_insert_( > const value_type& x,final_node_type* position) > {return final().insert_(x,position);} > std::pair<final_node_type*,bool> final_insert_rv_( > const value_type& x,final_node_type* position) > {return final().insert_rv_(x,position);} > template<typename T> > std::pair<final_node_type*,bool> final_insert_ref_( > T& t,final_node_type* position) > {return final().insert_ref_(t,position);} > > template<typename... Args> > std::pair<final_node_type*,bool> final_emplace_hint_( > final_node_type* position,Args&&... args) > { > return final().emplace_hint_( > position,std::forward<Args>(args)...); > } > > void final_erase_(final_node_type* x){final().erase_(x);} > > void final_delete_node_(final_node_type* x){final().delete_node_(x);} > void final_delete_all_nodes_(){final().delete_all_nodes_();} > void final_clear_(){final().clear_();} > > void final_swap_(final_type& x){final().swap_(x);} > > bool final_replace_( > const value_type& k,final_node_type* x) > {return final().replace_(k,x);} > bool final_replace_rv_( > const value_type& k,final_node_type* x) > {return final().replace_rv_(k,x);} > > template<typename Modifier> > bool final_modify_(Modifier& mod,final_node_type* x) > {return final().modify_(mod,x);} > > template<typename Modifier,typename Rollback> > bool final_modify_(Modifier& mod,Rollback& back,final_node_type* x) > {return final().modify_(mod,back,x);} > > > > >}; > >} > >} > >} ># 22 "/usr/include/boost/multi_index/detail/base_type.hpp" 2 3 4 > > > > >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 47 "/usr/include/boost/multi_index/detail/base_type.hpp" 3 4 >struct index_applier >{ > template<typename IndexSpecifierMeta,typename SuperMeta> > struct apply > { > typedef typename IndexSpecifierMeta::type index_specifier; > typedef typename index_specifier:: > template index_class<SuperMeta>::type type; > }; >}; > > >template<int N,typename Value,typename IndexSpecifierList,typename Allocator> >struct nth_layer >{ > static const int length=mpl::size<IndexSpecifierList>::value; > > typedef typename mpl::eval_if_c< > N==length, > mpl::identity<index_base<Value,IndexSpecifierList,Allocator> >, > mpl::apply2< > index_applier, > mpl::at_c<IndexSpecifierList,N>, > nth_layer<N+1,Value,IndexSpecifierList,Allocator> > > > >::type type; >}; > >template<typename Value,typename IndexSpecifierList,typename Allocator> >struct multi_index_base_type:nth_layer<0,Value,IndexSpecifierList,Allocator> >{ > static_assert(detail::is_index_list<IndexSpecifierList>::value, "detail::is_index_list<IndexSpecifierList>::value"); >}; > >} > >} > >} ># 35 "/usr/include/boost/multi_index_container.hpp" 2 3 4 > ># 1 "/usr/include/boost/multi_index/detail/converter.hpp" 1 3 4 ># 16 "/usr/include/boost/multi_index/detail/converter.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > > > >template<typename MultiIndexContainer,typename Index> >struct converter >{ > static const Index& index(const MultiIndexContainer& x){return x;} > static Index& index(MultiIndexContainer& x){return x;} > > static typename Index::const_iterator const_iterator( > const MultiIndexContainer& x,typename MultiIndexContainer::node_type* node) > { > return x.Index::make_iterator(node); > } > > static typename Index::iterator iterator( > MultiIndexContainer& x,typename MultiIndexContainer::node_type* node) > { > return x.Index::make_iterator(node); > } >}; > >} > >} > >} ># 37 "/usr/include/boost/multi_index_container.hpp" 2 3 4 > ># 1 "/usr/include/boost/multi_index/detail/has_tag.hpp" 1 3 4 ># 19 "/usr/include/boost/multi_index/detail/has_tag.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > >template<typename Tag> >struct has_tag >{ > template<typename Index> > struct apply:mpl::contains<typename Index::tag_list,Tag> > { > }; >}; > >} > >} > >} ># 39 "/usr/include/boost/multi_index_container.hpp" 2 3 4 > > ># 1 "/usr/include/boost/multi_index/detail/safe_mode.hpp" 1 3 4 ># 42 "/usr/include/boost/multi_index_container.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/scope_guard.hpp" 1 3 4 ># 19 "/usr/include/boost/multi_index/detail/scope_guard.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 60 "/usr/include/boost/multi_index/detail/scope_guard.hpp" 3 4 >class scope_guard_impl_base >{ >public: > scope_guard_impl_base():dismissed_(false){} > void dismiss()const{dismissed_=true;} > > > > > void touch()const{} > >protected: > ~scope_guard_impl_base(){} > > scope_guard_impl_base(const scope_guard_impl_base& other): > dismissed_(other.dismissed_) > { > other.dismiss(); > } > > template<typename J> > static void safe_execute(J& j){ > { try{ > if(!j.dismissed_)j.execute(); > } > catch(...){} > } > } > > mutable bool dismissed_; > >private: > scope_guard_impl_base& operator=(const scope_guard_impl_base&); >}; > >typedef const scope_guard_impl_base& scope_guard; > >struct null_guard : public scope_guard_impl_base >{ > template< class T1 > > null_guard( const T1& ) > { } > > template< class T1, class T2 > > null_guard( const T1&, const T2& ) > { } > > template< class T1, class T2, class T3 > > null_guard( const T1&, const T2&, const T3& ) > { } > > template< class T1, class T2, class T3, class T4 > > null_guard( const T1&, const T2&, const T3&, const T4& ) > { } > > template< class T1, class T2, class T3, class T4, class T5 > > null_guard( const T1&, const T2&, const T3&, const T4&, const T5& ) > { } >}; > >template< bool cond, class T > >struct null_guard_return >{ > typedef typename boost::mpl::if_c<cond,T,null_guard>::type type; >}; > >template<typename F> >class scope_guard_impl0:public scope_guard_impl_base >{ >public: > scope_guard_impl0(F fun):fun_(fun){} > ~scope_guard_impl0(){scope_guard_impl_base::safe_execute(*this);} > void execute(){fun_();} > >protected: > > F fun_; >}; > >template<typename F> >inline scope_guard_impl0<F> make_guard(F fun) >{ > return scope_guard_impl0<F>(fun); >} > >template<bool cond, typename F> >inline typename null_guard_return<cond,scope_guard_impl0<F> >::type >make_guard_if_c(F fun) >{ > return typename null_guard_return<cond,scope_guard_impl0<F> >::type(fun); >} > >template<typename C, typename F> >inline typename null_guard_return<C::value,scope_guard_impl0<F> >::type >make_guard_if(F fun) >{ > return make_guard_if<C::value>(fun); >} > >template<typename F,typename P1> >class scope_guard_impl1:public scope_guard_impl_base >{ >public: > scope_guard_impl1(F fun,P1 p1):fun_(fun),p1_(p1){} > ~scope_guard_impl1(){scope_guard_impl_base::safe_execute(*this);} > void execute(){fun_(p1_);} > >protected: > F fun_; > const P1 p1_; >}; > >template<typename F,typename P1> >inline scope_guard_impl1<F,P1> make_guard(F fun,P1 p1) >{ > return scope_guard_impl1<F,P1>(fun,p1); >} > >template<bool cond, typename F,typename P1> >inline typename null_guard_return<cond,scope_guard_impl1<F,P1> >::type >make_guard_if_c(F fun,P1 p1) >{ > return typename null_guard_return<cond,scope_guard_impl1<F,P1> >::type(fun,p1); >} > >template<typename C, typename F,typename P1> >inline typename null_guard_return<C::value,scope_guard_impl1<F,P1> >::type >make_guard_if(F fun,P1 p1) >{ > return make_guard_if_c<C::value>(fun,p1); >} > >template<typename F,typename P1,typename P2> >class scope_guard_impl2:public scope_guard_impl_base >{ >public: > scope_guard_impl2(F fun,P1 p1,P2 p2):fun_(fun),p1_(p1),p2_(p2){} > ~scope_guard_impl2(){scope_guard_impl_base::safe_execute(*this);} > void execute(){fun_(p1_,p2_);} > >protected: > F fun_; > const P1 p1_; > const P2 p2_; >}; > >template<typename F,typename P1,typename P2> >inline scope_guard_impl2<F,P1,P2> make_guard(F fun,P1 p1,P2 p2) >{ > return scope_guard_impl2<F,P1,P2>(fun,p1,p2); >} > >template<bool cond, typename F,typename P1,typename P2> >inline typename null_guard_return<cond,scope_guard_impl2<F,P1,P2> >::type >make_guard_if_c(F fun,P1 p1,P2 p2) >{ > return typename null_guard_return<cond,scope_guard_impl2<F,P1,P2> >::type(fun,p1,p2); >} > >template<typename C, typename F,typename P1,typename P2> >inline typename null_guard_return<C::value,scope_guard_impl2<F,P1,P2> >::type >make_guard_if(F fun,P1 p1,P2 p2) >{ > return make_guard_if_c<C::value>(fun,p1,p2); >} > >template<typename F,typename P1,typename P2,typename P3> >class scope_guard_impl3:public scope_guard_impl_base >{ >public: > scope_guard_impl3(F fun,P1 p1,P2 p2,P3 p3):fun_(fun),p1_(p1),p2_(p2),p3_(p3){} > ~scope_guard_impl3(){scope_guard_impl_base::safe_execute(*this);} > void execute(){fun_(p1_,p2_,p3_);} > >protected: > F fun_; > const P1 p1_; > const P2 p2_; > const P3 p3_; >}; > >template<typename F,typename P1,typename P2,typename P3> >inline scope_guard_impl3<F,P1,P2,P3> make_guard(F fun,P1 p1,P2 p2,P3 p3) >{ > return scope_guard_impl3<F,P1,P2,P3>(fun,p1,p2,p3); >} > >template<bool cond,typename F,typename P1,typename P2,typename P3> >inline typename null_guard_return<cond,scope_guard_impl3<F,P1,P2,P3> >::type >make_guard_if_c(F fun,P1 p1,P2 p2,P3 p3) >{ > return typename null_guard_return<cond,scope_guard_impl3<F,P1,P2,P3> >::type(fun,p1,p2,p3); >} > >template<typename C,typename F,typename P1,typename P2,typename P3> >inline typename null_guard_return< C::value,scope_guard_impl3<F,P1,P2,P3> >::type >make_guard_if(F fun,P1 p1,P2 p2,P3 p3) >{ > return make_guard_if_c<C::value>(fun,p1,p2,p3); >} > >template<typename F,typename P1,typename P2,typename P3,typename P4> >class scope_guard_impl4:public scope_guard_impl_base >{ >public: > scope_guard_impl4(F fun,P1 p1,P2 p2,P3 p3,P4 p4): > fun_(fun),p1_(p1),p2_(p2),p3_(p3),p4_(p4){} > ~scope_guard_impl4(){scope_guard_impl_base::safe_execute(*this);} > void execute(){fun_(p1_,p2_,p3_,p4_);} > >protected: > F fun_; > const P1 p1_; > const P2 p2_; > const P3 p3_; > const P4 p4_; >}; > >template<typename F,typename P1,typename P2,typename P3,typename P4> >inline scope_guard_impl4<F,P1,P2,P3,P4> make_guard( > F fun,P1 p1,P2 p2,P3 p3,P4 p4) >{ > return scope_guard_impl4<F,P1,P2,P3,P4>(fun,p1,p2,p3,p4); >} > >template<bool cond, typename F,typename P1,typename P2,typename P3,typename P4> >inline typename null_guard_return<cond,scope_guard_impl4<F,P1,P2,P3,P4> >::type >make_guard_if_c( > F fun,P1 p1,P2 p2,P3 p3,P4 p4) >{ > return typename null_guard_return<cond,scope_guard_impl4<F,P1,P2,P3,P4> >::type(fun,p1,p2,p3,p4); >} > >template<typename C, typename F,typename P1,typename P2,typename P3,typename P4> >inline typename null_guard_return<C::value,scope_guard_impl4<F,P1,P2,P3,P4> >::type >make_guard_if( > F fun,P1 p1,P2 p2,P3 p3,P4 p4) >{ > return make_guard_if_c<C::value>(fun,p1,p2,p3,p4); >} > >template<class Obj,typename MemFun> >class obj_scope_guard_impl0:public scope_guard_impl_base >{ >public: > obj_scope_guard_impl0(Obj& obj,MemFun mem_fun):obj_(obj),mem_fun_(mem_fun){} > ~obj_scope_guard_impl0(){scope_guard_impl_base::safe_execute(*this);} > void execute(){(obj_.*mem_fun_)();} > >protected: > Obj& obj_; > MemFun mem_fun_; >}; > >template<class Obj,typename MemFun> >inline obj_scope_guard_impl0<Obj,MemFun> make_obj_guard(Obj& obj,MemFun mem_fun) >{ > return obj_scope_guard_impl0<Obj,MemFun>(obj,mem_fun); >} > >template<bool cond, class Obj,typename MemFun> >inline typename null_guard_return<cond,obj_scope_guard_impl0<Obj,MemFun> >::type >make_obj_guard_if_c(Obj& obj,MemFun mem_fun) >{ > return typename null_guard_return<cond,obj_scope_guard_impl0<Obj,MemFun> >::type(obj,mem_fun); >} > >template<typename C, class Obj,typename MemFun> >inline typename null_guard_return<C::value,obj_scope_guard_impl0<Obj,MemFun> >::type >make_obj_guard_if(Obj& obj,MemFun mem_fun) >{ > return make_obj_guard_if_c<C::value>(obj,mem_fun); >} > >template<class Obj,typename MemFun,typename P1> >class obj_scope_guard_impl1:public scope_guard_impl_base >{ >public: > obj_scope_guard_impl1(Obj& obj,MemFun mem_fun,P1 p1): > obj_(obj),mem_fun_(mem_fun),p1_(p1){} > ~obj_scope_guard_impl1(){scope_guard_impl_base::safe_execute(*this);} > void execute(){(obj_.*mem_fun_)(p1_);} > >protected: > Obj& obj_; > MemFun mem_fun_; > const P1 p1_; >}; > >template<class Obj,typename MemFun,typename P1> >inline obj_scope_guard_impl1<Obj,MemFun,P1> make_obj_guard( > Obj& obj,MemFun mem_fun,P1 p1) >{ > return obj_scope_guard_impl1<Obj,MemFun,P1>(obj,mem_fun,p1); >} > >template<bool cond, class Obj,typename MemFun,typename P1> >inline typename null_guard_return<cond,obj_scope_guard_impl1<Obj,MemFun,P1> >::type >make_obj_guard_if_c( Obj& obj,MemFun mem_fun,P1 p1) >{ > return typename null_guard_return<cond,obj_scope_guard_impl1<Obj,MemFun,P1> >::type(obj,mem_fun,p1); >} > >template<typename C, class Obj,typename MemFun,typename P1> >inline typename null_guard_return<C::value,obj_scope_guard_impl1<Obj,MemFun,P1> >::type >make_obj_guard_if( Obj& obj,MemFun mem_fun,P1 p1) >{ > return make_obj_guard_if_c<C::value>(obj,mem_fun,p1); >} > >template<class Obj,typename MemFun,typename P1,typename P2> >class obj_scope_guard_impl2:public scope_guard_impl_base >{ >public: > obj_scope_guard_impl2(Obj& obj,MemFun mem_fun,P1 p1,P2 p2): > obj_(obj),mem_fun_(mem_fun),p1_(p1),p2_(p2) > {} > ~obj_scope_guard_impl2(){scope_guard_impl_base::safe_execute(*this);} > void execute(){(obj_.*mem_fun_)(p1_,p2_);} > >protected: > Obj& obj_; > MemFun mem_fun_; > const P1 p1_; > const P2 p2_; >}; > >template<class Obj,typename MemFun,typename P1,typename P2> >inline obj_scope_guard_impl2<Obj,MemFun,P1,P2> >make_obj_guard(Obj& obj,MemFun mem_fun,P1 p1,P2 p2) >{ > return obj_scope_guard_impl2<Obj,MemFun,P1,P2>(obj,mem_fun,p1,p2); >} > >template<bool cond, class Obj,typename MemFun,typename P1,typename P2> >inline typename null_guard_return<cond,obj_scope_guard_impl2<Obj,MemFun,P1,P2> >::type >make_obj_guard_if_c(Obj& obj,MemFun mem_fun,P1 p1,P2 p2) >{ > return typename null_guard_return<cond,obj_scope_guard_impl2<Obj,MemFun,P1,P2> >::type(obj,mem_fun,p1,p2); >} > >template<typename C, class Obj,typename MemFun,typename P1,typename P2> >inline typename null_guard_return<C::value,obj_scope_guard_impl2<Obj,MemFun,P1,P2> >::type >make_obj_guard_if(Obj& obj,MemFun mem_fun,P1 p1,P2 p2) >{ > return make_obj_guard_if_c<C::value>(obj,mem_fun,p1,p2); >} > >template<class Obj,typename MemFun,typename P1,typename P2,typename P3> >class obj_scope_guard_impl3:public scope_guard_impl_base >{ >public: > obj_scope_guard_impl3(Obj& obj,MemFun mem_fun,P1 p1,P2 p2,P3 p3): > obj_(obj),mem_fun_(mem_fun),p1_(p1),p2_(p2),p3_(p3) > {} > ~obj_scope_guard_impl3(){scope_guard_impl_base::safe_execute(*this);} > void execute(){(obj_.*mem_fun_)(p1_,p2_,p3_);} > >protected: > Obj& obj_; > MemFun mem_fun_; > const P1 p1_; > const P2 p2_; > const P3 p3_; >}; > >template<class Obj,typename MemFun,typename P1,typename P2,typename P3> >inline obj_scope_guard_impl3<Obj,MemFun,P1,P2,P3> >make_obj_guard(Obj& obj,MemFun mem_fun,P1 p1,P2 p2,P3 p3) >{ > return obj_scope_guard_impl3<Obj,MemFun,P1,P2,P3>(obj,mem_fun,p1,p2,p3); >} > >template<bool cond, class Obj,typename MemFun,typename P1,typename P2,typename P3> >inline typename null_guard_return<cond,obj_scope_guard_impl3<Obj,MemFun,P1,P2,P3> >::type >make_obj_guard_if_c(Obj& obj,MemFun mem_fun,P1 p1,P2 p2,P3 p3) >{ > return typename null_guard_return<cond,obj_scope_guard_impl3<Obj,MemFun,P1,P2,P3> >::type(obj,mem_fun,p1,p2,p3); >} > >template<typename C, class Obj,typename MemFun,typename P1,typename P2,typename P3> >inline typename null_guard_return<C::value,obj_scope_guard_impl3<Obj,MemFun,P1,P2,P3> >::type >make_obj_guard_if(Obj& obj,MemFun mem_fun,P1 p1,P2 p2,P3 p3) >{ > return make_obj_guard_if_c<C::value>(obj,mem_fun,p1,p2,p3); >} > >} > >} > >} ># 43 "/usr/include/boost/multi_index_container.hpp" 2 3 4 ># 53 "/usr/include/boost/multi_index_container.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/archive_constructed.hpp" 1 3 4 ># 23 "/usr/include/boost/multi_index/detail/archive_constructed.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > >template<typename T> >struct archive_constructed:private noncopyable >{ > template<class Archive> > archive_constructed(Archive& ar,const unsigned int version) > { > serialization::load_construct_data_adl(ar,&get(),version); > { try{ > ar>>get(); > } > catch(...){ > (&get())->~T(); > throw;; > } > } > } > > template<class Archive> > archive_constructed(const char* name,Archive& ar,const unsigned int version) > { > serialization::load_construct_data_adl(ar,&get(),version); > { try{ > ar>>serialization::make_nvp(name,get()); > } > catch(...){ > (&get())->~T(); > throw;; > } > } > } > > ~archive_constructed() > { > (&get())->~T(); > } > > T& get(){return *static_cast<T*>(static_cast<void*>(&space));} > >private: > typename aligned_storage<sizeof(T),alignment_of<T>::value>::type space; >}; > >} > >} > >} ># 54 "/usr/include/boost/multi_index_container.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/serialization_version.hpp" 1 3 4 ># 20 "/usr/include/boost/multi_index/detail/serialization_version.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > > > > >template<typename T> >struct serialization_version >{ > serialization_version(): > value(boost::serialization::version<serialization_version>::value){} > > serialization_version& operator=(unsigned int x){value=x;return *this;}; > > operator unsigned int()const{return value;} > >private: > friend class boost::serialization::access; > > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } > > template<class Archive> > void save(Archive&,const unsigned int)const{} > > template<class Archive> > void load(Archive&,const unsigned int version) > { > this->value=version; > } > > unsigned int value; >}; > >} > >} > > >namespace serialization { >template<typename T> >struct version<boost::multi_index::detail::serialization_version<T> > >{ > static const int value=version<T>::value; >}; >} > > >} ># 55 "/usr/include/boost/multi_index_container.hpp" 2 3 4 ># 75 "/usr/include/boost/multi_index_container.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > > > > > > >template<typename Value,typename IndexSpecifierList,typename Allocator> >class multi_index_container: > private ::boost::base_from_member< > typename boost::detail::allocator::rebind_to< > Allocator, > typename detail::multi_index_node_type< > Value,IndexSpecifierList,Allocator>::type > >::type>, > private detail::header_holder< > typename detail::prevent_eti< > Allocator, > typename boost::detail::allocator::rebind_to< > Allocator, > typename detail::multi_index_node_type< > Value,IndexSpecifierList,Allocator>::type > >::type > >::type::pointer, > multi_index_container<Value,IndexSpecifierList,Allocator> >, > public detail::multi_index_base_type< > Value,IndexSpecifierList,Allocator>::type >{ ># 115 "/usr/include/boost/multi_index_container.hpp" 3 4 >private: > > > > template <typename,typename,typename> friend class detail::index_base; > template <typename,typename> friend struct detail::header_holder; > template <typename,typename> friend struct detail::converter; > > > typedef typename detail::multi_index_base_type< > Value,IndexSpecifierList,Allocator>::type super; > typedef typename > boost::detail::allocator::rebind_to< > Allocator, > typename super::node_type > >::type node_allocator; > typedef ::boost::base_from_member< > node_allocator> bfm_allocator; > typedef detail::header_holder< > typename detail::prevent_eti< > Allocator, > node_allocator > >::type::pointer, > multi_index_container> bfm_header; > > > > > > >public: > > > > > typedef typename super::ctor_args_list ctor_args_list; > typedef IndexSpecifierList index_specifier_type_list; ># 172 "/usr/include/boost/multi_index_container.hpp" 3 4 > typedef typename super::index_type_list index_type_list; > > > typedef typename super::iterator_type_list iterator_type_list; > typedef typename super::const_iterator_type_list const_iterator_type_list; > typedef typename super::value_type value_type; > typedef typename super::final_allocator_type allocator_type; > typedef typename super::iterator iterator; > typedef typename super::const_iterator const_iterator; > > static_assert(detail::no_duplicate_tags_in_index_list<index_type_list>::value, "detail::no_duplicate_tags_in_index_list<index_type_list>::value") > ; > > > > typedef typename super::node_type node_type; > > > > explicit multi_index_container( ># 205 "/usr/include/boost/multi_index_container.hpp" 3 4 > const ctor_args_list& args_list=ctor_args_list(), > const allocator_type& al=allocator_type()): > > > bfm_allocator(al), > super(args_list,bfm_allocator::member), > node_count(0) > { > ; > } > > explicit multi_index_container(const allocator_type& al): > bfm_allocator(al), > super(ctor_args_list(),bfm_allocator::member), > node_count(0) > { > ; > } > > template<typename InputIterator> > multi_index_container( > InputIterator first,InputIterator last, ># 240 "/usr/include/boost/multi_index_container.hpp" 3 4 > const ctor_args_list& args_list=ctor_args_list(), > const allocator_type& al=allocator_type()): > > > bfm_allocator(al), > super(args_list,bfm_allocator::member), > node_count(0) > { > ; > { try{ > iterator hint=super::end(); > for(;first!=last;++first){ > hint=super::make_iterator( > insert_ref_(*first,hint.get_node()).first); > ++hint; > } > } > catch(...){ > clear_(); > throw;; > } > } > } > > > multi_index_container( > std::initializer_list<Value> list, > const ctor_args_list& args_list=ctor_args_list(), > const allocator_type& al=allocator_type()): > bfm_allocator(al), > super(args_list,bfm_allocator::member), > node_count(0) > { > ; > { try{ > typedef typename std::initializer_list<Value>::iterator init_iterator; > > iterator hint=super::end(); > for(init_iterator first=list.begin(),last=list.end(); > first!=last;++first){ > hint=super::make_iterator(insert_(*first,hint.get_node()).first); > ++hint; > } > } > catch(...){ > clear_(); > throw;; > } > } > } > > > multi_index_container( > const multi_index_container<Value,IndexSpecifierList,Allocator>& x): > bfm_allocator(x.bfm_allocator::member), > bfm_header(), > super(x), > node_count(0) > { > copy_map_type map(bfm_allocator::member,x.size(),x.header(),header()); > for(const_iterator it=x.begin(),it_end=x.end();it!=it_end;++it){ > map.clone(it.get_node()); > } > super::copy_(x,map); > map.release(); > node_count=x.size(); > > > > > > ; > } > > multi_index_container(multi_index_container && x): > bfm_allocator(x.bfm_allocator::member), > bfm_header(), > super(x,detail::do_not_copy_elements_tag()), > node_count(0) > { > ; > ; > swap_elements_(x); > } > > ~multi_index_container() > { > delete_all_nodes_(); > } ># 344 "/usr/include/boost/multi_index_container.hpp" 3 4 > multi_index_container<Value,IndexSpecifierList,Allocator>& operator=( > const multi_index_container & x) > { > multi_index_container y(x); > this->swap(y); > return *this; > } > > multi_index_container<Value,IndexSpecifierList,Allocator>& operator=( > multi_index_container && x) > { > this->swap(x); > return *this; > } > > > multi_index_container<Value,IndexSpecifierList,Allocator>& operator=( > std::initializer_list<Value> list) > { > ; > typedef typename std::initializer_list<Value>::iterator init_iterator; > > multi_index_container x(*this,detail::do_not_copy_elements_tag()); > iterator hint=x.end(); > for(init_iterator first=list.begin(),last=list.end(); > first!=last;++first){ > hint=x.make_iterator(x.insert_(*first,hint.get_node()).first); > ++hint; > } > x.swap_elements_(*this); > return*this; > } > > > allocator_type get_allocator()const > { > return allocator_type(bfm_allocator::member); > } > > > > > template<int N> > struct nth_index > { > static_assert(N>=0&&N<mpl::size<index_type_list>::type::value, "N>=0&&N<mpl::size<index_type_list>::type::value"); > typedef typename mpl::at_c<index_type_list,N>::type type; > }; > > template<int N> > typename nth_index<N>::type& get() > { > static_assert(N>=0&&N<mpl::size<index_type_list>::type::value, "N>=0&&N<mpl::size<index_type_list>::type::value"); > return *this; > } > > template<int N> > const typename nth_index<N>::type& get( > )const > { > static_assert(N>=0&&N<mpl::size<index_type_list>::type::value, "N>=0&&N<mpl::size<index_type_list>::type::value"); > return *this; > } > > > > > > template<typename Tag> > struct index > { > typedef typename mpl::find_if< > index_type_list, > detail::has_tag<Tag> > >::type iter; > > static const bool index_found=!(is_same<iter,typename mpl::end<index_type_list>::type >::value) > ; > static_assert(index_found, "index_found"); > > typedef typename mpl::deref<iter>::type type; > }; > > template<typename Tag> > typename index<Tag>::type& get() > { > return *this; > } > > template<typename Tag> > const typename index<Tag>::type& get( > )const > { > return *this; > } > > > > > > template<int N> > struct nth_index_iterator > { > typedef typename nth_index<N>::type::iterator type; > }; > > template<int N> > struct nth_index_const_iterator > { > typedef typename nth_index<N>::type::const_iterator type; > }; > > template<int N,typename IteratorType> > typename nth_index_iterator<N>::type project( > IteratorType it > ) > { > typedef typename nth_index<N>::type index; > > > static_assert((mpl::contains<iterator_type_list,IteratorType>::value), "(mpl::contains<iterator_type_list,IteratorType>::value)") > ; > > > ((void)0);; > ((void)0); > ; > > return index::make_iterator(static_cast<node_type*>(it.get_node())); > } > > template<int N,typename IteratorType> > typename nth_index_const_iterator<N>::type project( > IteratorType it > )const > { > typedef typename nth_index<N>::type index; > > > static_assert(( mpl::contains<iterator_type_list,IteratorType>::value|| mpl::contains<const_iterator_type_list,IteratorType>::value), "( mpl::contains<iterator_type_list,IteratorType>::value|| mpl::contains<const_iterator_type_list,IteratorType>::value)") > > ; > > > ((void)0);; > ((void)0); > ; > return index::make_iterator(static_cast<node_type*>(it.get_node())); > } > > > > > > template<typename Tag> > struct index_iterator > { > typedef typename index<Tag>::type::iterator type; > }; > > template<typename Tag> > struct index_const_iterator > { > typedef typename index<Tag>::type::const_iterator type; > }; > > template<typename Tag,typename IteratorType> > typename index_iterator<Tag>::type project( > IteratorType it > ) > { > typedef typename index<Tag>::type index; > > > static_assert((mpl::contains<iterator_type_list,IteratorType>::value), "(mpl::contains<iterator_type_list,IteratorType>::value)") > ; > > > ((void)0);; > ((void)0); > ; > return index::make_iterator(static_cast<node_type*>(it.get_node())); > } > > template<typename Tag,typename IteratorType> > typename index_const_iterator<Tag>::type project( > IteratorType it > )const > { > typedef typename index<Tag>::type index; > > > static_assert(( mpl::contains<iterator_type_list,IteratorType>::value|| mpl::contains<const_iterator_type_list,IteratorType>::value), "( mpl::contains<iterator_type_list,IteratorType>::value|| mpl::contains<const_iterator_type_list,IteratorType>::value)") > > ; > > > ((void)0);; > ((void)0); > ; > return index::make_iterator(static_cast<node_type*>(it.get_node())); > } > > >protected: > typedef typename super::copy_map_type copy_map_type; > > > multi_index_container( > const multi_index_container<Value,IndexSpecifierList,Allocator>& x, > detail::do_not_copy_elements_tag): > bfm_allocator(x.bfm_allocator::member), > bfm_header(), > super(x,detail::do_not_copy_elements_tag()), > node_count(0) > { > ; > } > > > node_type* header()const > { > return &*bfm_header::member; > } > > node_type* allocate_node() > { > return &*bfm_allocator::member.allocate(1); > } > > void deallocate_node(node_type* x) > { > typedef typename node_allocator::pointer node_pointer; > bfm_allocator::member.deallocate(static_cast<node_pointer>(x),1); > } > > bool empty_()const > { > return node_count==0; > } > > std::size_t size_()const > { > return node_count; > } > > std::size_t max_size_()const > { > return static_cast<std::size_t >(-1); > } > > template<typename Variant> > std::pair<node_type*,bool> insert_(const Value& v,Variant variant) > { > node_type* x=allocate_node(); > { try{ > node_type* res=super::insert_(v,x,variant); > if(res==x){ > ++node_count; > return std::pair<node_type*,bool>(res,true); > } > else{ > deallocate_node(x); > return std::pair<node_type*,bool>(res,false); > } > } > catch(...){ > deallocate_node(x); > throw;; > } > } > } > > std::pair<node_type*,bool> insert_(const Value& v) > { > return insert_(v,detail::lvalue_tag()); > } > > std::pair<node_type*,bool> insert_rv_(const Value& v) > { > return insert_(v,detail::rvalue_tag()); > } > > template<typename T> > std::pair<node_type*,bool> insert_ref_(T& t) > { > node_type* x=allocate_node(); > { try{ > new(&x->value()) value_type(t); > { try{ > node_type* res=super::insert_(x->value(),x,detail::emplaced_tag()); > if(res==x){ > ++node_count; > return std::pair<node_type*,bool>(res,true); > } > else{ > boost::detail::allocator::destroy(&x->value()); > deallocate_node(x); > return std::pair<node_type*,bool>(res,false); > } > } > catch(...){ > boost::detail::allocator::destroy(&x->value()); > throw;; > } > } > } > catch(...){ > deallocate_node(x); > throw;; > } > } > } > > std::pair<node_type*,bool> insert_ref_(const value_type& x) > { > return insert_(x); > } > > std::pair<node_type*,bool> insert_ref_(value_type& x) > { > return insert_(x); > } > > template<typename... Args> > std::pair<node_type*,bool> emplace_( > Args&&... args) > { > node_type* x=allocate_node(); > { try{ > detail::vartempl_placement_new( > &x->value(),std::forward<Args>(args)...); > { try{ > node_type* res=super::insert_(x->value(),x,detail::emplaced_tag()); > if(res==x){ > ++node_count; > return std::pair<node_type*,bool>(res,true); > } > else{ > boost::detail::allocator::destroy(&x->value()); > deallocate_node(x); > return std::pair<node_type*,bool>(res,false); > } > } > catch(...){ > boost::detail::allocator::destroy(&x->value()); > throw;; > } > } > } > catch(...){ > deallocate_node(x); > throw;; > } > } > } > > template<typename Variant> > std::pair<node_type*,bool> insert_( > const Value& v,node_type* position,Variant variant) > { > node_type* x=allocate_node(); > { try{ > node_type* res=super::insert_(v,position,x,variant); > if(res==x){ > ++node_count; > return std::pair<node_type*,bool>(res,true); > } > else{ > deallocate_node(x); > return std::pair<node_type*,bool>(res,false); > } > } > catch(...){ > deallocate_node(x); > throw;; > } > } > } > > std::pair<node_type*,bool> insert_(const Value& v,node_type* position) > { > return insert_(v,position,detail::lvalue_tag()); > } > > std::pair<node_type*,bool> insert_rv_(const Value& v,node_type* position) > { > return insert_(v,position,detail::rvalue_tag()); > } > > template<typename T> > std::pair<node_type*,bool> insert_ref_( > T& t,node_type* position) > { > node_type* x=allocate_node(); > { try{ > new(&x->value()) value_type(t); > { try{ > node_type* res=super::insert_( > x->value(),position,x,detail::emplaced_tag()); > if(res==x){ > ++node_count; > return std::pair<node_type*,bool>(res,true); > } > else{ > boost::detail::allocator::destroy(&x->value()); > deallocate_node(x); > return std::pair<node_type*,bool>(res,false); > } > } > catch(...){ > boost::detail::allocator::destroy(&x->value()); > throw;; > } > } > } > catch(...){ > deallocate_node(x); > throw;; > } > } > } > > std::pair<node_type*,bool> insert_ref_( > const value_type& x,node_type* position) > { > return insert_(x,position); > } > > std::pair<node_type*,bool> insert_ref_( > value_type& x,node_type* position) > { > return insert_(x,position); > } > > template<typename... Args> > std::pair<node_type*,bool> emplace_hint_( > node_type* position, > Args&&... args) > { > node_type* x=allocate_node(); > { try{ > detail::vartempl_placement_new( > &x->value(),std::forward<Args>(args)...); > { try{ > node_type* res=super::insert_( > x->value(),position,x,detail::emplaced_tag()); > if(res==x){ > ++node_count; > return std::pair<node_type*,bool>(res,true); > } > else{ > boost::detail::allocator::destroy(&x->value()); > deallocate_node(x); > return std::pair<node_type*,bool>(res,false); > } > } > catch(...){ > boost::detail::allocator::destroy(&x->value()); > throw;; > } > } > } > catch(...){ > deallocate_node(x); > throw;; > } > } > } > > void erase_(node_type* x) > { > --node_count; > super::erase_(x); > deallocate_node(x); > } > > void delete_node_(node_type* x) > { > super::delete_node_(x); > deallocate_node(x); > } > > void delete_all_nodes_() > { > super::delete_all_nodes_(); > } > > void clear_() > { > delete_all_nodes_(); > super::clear_(); > node_count=0; > } > > void swap_(multi_index_container<Value,IndexSpecifierList,Allocator>& x) > { > if(bfm_allocator::member!=x.bfm_allocator::member){ > detail::adl_swap(bfm_allocator::member,x.bfm_allocator::member); > } > std::swap(bfm_header::member,x.bfm_header::member); > super::swap_(x); > std::swap(node_count,x.node_count); > } > > void swap_elements_( > multi_index_container<Value,IndexSpecifierList,Allocator>& x) > { > std::swap(bfm_header::member,x.bfm_header::member); > super::swap_elements_(x); > std::swap(node_count,x.node_count); > } > > bool replace_(const Value& k,node_type* x) > { > return super::replace_(k,x,detail::lvalue_tag()); > } > > bool replace_rv_(const Value& k,node_type* x) > { > return super::replace_(k,x,detail::rvalue_tag()); > } > > template<typename Modifier> > bool modify_(Modifier& mod,node_type* x) > { > mod(const_cast<value_type&>(x->value())); > > { try{ > if(!super::modify_(x)){ > deallocate_node(x); > --node_count; > return false; > } > else return true; > } > catch(...){ > deallocate_node(x); > --node_count; > throw;; > } > } > } > > template<typename Modifier,typename Rollback> > bool modify_(Modifier& mod,Rollback& back,node_type* x) > { > mod(const_cast<value_type&>(x->value())); > > bool b; > { try{ > b=super::modify_rollback_(x); > } > catch(...){ > { try{ > back(const_cast<value_type&>(x->value())); > throw;; > } > catch(...){ > this->erase_(x); > throw;; > } > } > } > } > > { try{ > if(!b){ > back(const_cast<value_type&>(x->value())); > return false; > } > else return true; > } > catch(...){ > this->erase_(x); > throw;; > } > } > } > > > > > friend class boost::serialization::access; > > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } > > typedef typename super::index_saver_type index_saver_type; > typedef typename super::index_loader_type index_loader_type; > > template<class Archive> > void save(Archive& ar,const unsigned int version)const > { > > > const serialization::collection_size_type s(size_()); > const detail::serialization_version<value_type> value_version; > ar<<serialization::make_nvp("count",s); > ar<<serialization::make_nvp("value_version",value_version); > > > > > > > index_saver_type sm(bfm_allocator::member,s); > > for(iterator it=super::begin(),it_end=super::end();it!=it_end;++it){ > serialization::save_construct_data_adl(ar,&*it,value_version); > ar<<serialization::make_nvp("item",*it); > sm.add(it.get_node(),ar,version); > } > sm.add_track(header(),ar,version); > > super::save_(ar,version,sm); > } > > template<class Archive> > void load(Archive& ar,const unsigned int version) > { > ; > > clear_(); > > > serialization::collection_size_type s; > detail::serialization_version<value_type> value_version; > if(version<1){ > std::size_t sz; > ar>>serialization::make_nvp("count",sz); > s=static_cast<serialization::collection_size_type>(sz); > } > else{ > ar>>serialization::make_nvp("count",s); > } > if(version<2){ > value_version=0; > } > else{ > ar>>serialization::make_nvp("value_version",value_version); > } > > > > > > > index_loader_type lm(bfm_allocator::member,s); > > for(std::size_t n=0;n<s;++n){ > detail::archive_constructed<Value> value("item",ar,value_version); > std::pair<node_type*,bool> p=insert_( > value.get(),super::end().get_node()); > if(!p.second)throw_exception( > archive::archive_exception( > archive::archive_exception::other_exception)); > ar.reset_object_address(&p.first->value(),&value.get()); > lm.add(p.first,ar,version); > } > lm.add_track(header(),ar,version); > > super::load_(ar,version,lm); > } ># 1023 "/usr/include/boost/multi_index_container.hpp" 3 4 >private: > std::size_t node_count; > > > > > >}; > > > > > > > >template<typename MultiIndexContainer,int N> >struct nth_index >{ > static const int M=mpl::size<typename MultiIndexContainer::index_type_list>::type::value > > ; > static_assert(N>=0&&N<M, "N>=0&&N<M"); > typedef typename mpl::at_c< > typename MultiIndexContainer::index_type_list,N>::type type; >}; > >template<int N,typename Value,typename IndexSpecifierList,typename Allocator> >typename nth_index< > multi_index_container<Value,IndexSpecifierList,Allocator>,N>::type& >get( > multi_index_container<Value,IndexSpecifierList,Allocator>& m > ) >{ > typedef multi_index_container< > Value,IndexSpecifierList,Allocator> multi_index_type; > typedef typename nth_index< > multi_index_container< > Value,IndexSpecifierList,Allocator>, > N > >::type index; > > static_assert(N>=0&& N< mpl::size< typename multi_index_type::index_type_list >::type::value, "N>=0&& N< mpl::size< BOOST_DEDUCED_TYPENAME multi_index_type::index_type_list >::type::value") > > > > ; > > return detail::converter<multi_index_type,index>::index(m); >} > >template<int N,typename Value,typename IndexSpecifierList,typename Allocator> >const typename nth_index< > multi_index_container<Value,IndexSpecifierList,Allocator>,N>::type& >get( > const multi_index_container<Value,IndexSpecifierList,Allocator>& m > ) >{ > typedef multi_index_container< > Value,IndexSpecifierList,Allocator> multi_index_type; > typedef typename nth_index< > multi_index_container< > Value,IndexSpecifierList,Allocator>, > N > >::type index; > > static_assert(N>=0&& N< mpl::size< typename multi_index_type::index_type_list >::type::value, "N>=0&& N< mpl::size< BOOST_DEDUCED_TYPENAME multi_index_type::index_type_list >::type::value") > > > > ; > > return detail::converter<multi_index_type,index>::index(m); >} > > > >template<typename MultiIndexContainer,typename Tag> >struct index >{ > typedef typename MultiIndexContainer::index_type_list index_type_list; > > typedef typename mpl::find_if< > index_type_list, > detail::has_tag<Tag> > >::type iter; > > static const bool index_found=!(is_same<iter,typename mpl::end<index_type_list>::type >::value) > ; > static_assert(index_found, "index_found"); > > typedef typename mpl::deref<iter>::type type; >}; > >template< > typename Tag,typename Value,typename IndexSpecifierList,typename Allocator >> >typename ::boost::multi_index::index< > multi_index_container<Value,IndexSpecifierList,Allocator>,Tag>::type& >get( > multi_index_container<Value,IndexSpecifierList,Allocator>& m > ) >{ > typedef multi_index_container< > Value,IndexSpecifierList,Allocator> multi_index_type; > typedef typename ::boost::multi_index::index< > multi_index_container< > Value,IndexSpecifierList,Allocator>, > Tag > >::type index; > > return detail::converter<multi_index_type,index>::index(m); >} > >template< > typename Tag,typename Value,typename IndexSpecifierList,typename Allocator >> >const typename ::boost::multi_index::index< > multi_index_container<Value,IndexSpecifierList,Allocator>,Tag>::type& >get( > const multi_index_container<Value,IndexSpecifierList,Allocator>& m > ) >{ > typedef multi_index_container< > Value,IndexSpecifierList,Allocator> multi_index_type; > typedef typename ::boost::multi_index::index< > multi_index_container< > Value,IndexSpecifierList,Allocator>, > Tag > >::type index; > > return detail::converter<multi_index_type,index>::index(m); >} > > > >template<typename MultiIndexContainer,int N> >struct nth_index_iterator >{ > typedef typename detail::prevent_eti< > nth_index<MultiIndexContainer,N>, > typename nth_index<MultiIndexContainer,N>::type>::type::iterator type; >}; > >template<typename MultiIndexContainer,int N> >struct nth_index_const_iterator >{ > typedef typename detail::prevent_eti< > nth_index<MultiIndexContainer,N>, > typename nth_index<MultiIndexContainer,N>::type > >::type::const_iterator type; >}; > >template< > int N,typename IteratorType, > typename Value,typename IndexSpecifierList,typename Allocator> >typename nth_index_iterator< > multi_index_container<Value,IndexSpecifierList,Allocator>,N>::type >project( > multi_index_container<Value,IndexSpecifierList,Allocator>& m, > IteratorType it > ) >{ > typedef multi_index_container< > Value,IndexSpecifierList,Allocator> multi_index_type; > typedef typename nth_index<multi_index_type,N>::type index; > > > > static_assert(( mpl::contains< typename multi_index_type::iterator_type_list, IteratorType>::value), "( mpl::contains< BOOST_DEDUCED_TYPENAME multi_index_type::iterator_type_list, IteratorType>::value)") > > > ; > > > ((void)0);; ># 1206 "/usr/include/boost/multi_index_container.hpp" 3 4 > return detail::converter<multi_index_type,index>::iterator( > m,static_cast<typename multi_index_type::node_type*>(it.get_node())); >} > >template< > int N,typename IteratorType, > typename Value,typename IndexSpecifierList,typename Allocator> >typename nth_index_const_iterator< > multi_index_container<Value,IndexSpecifierList,Allocator>,N>::type >project( > const multi_index_container<Value,IndexSpecifierList,Allocator>& m, > IteratorType it > ) >{ > typedef multi_index_container< > Value,IndexSpecifierList,Allocator> multi_index_type; > typedef typename nth_index<multi_index_type,N>::type index; > > > > static_assert(( mpl::contains< typename multi_index_type::iterator_type_list, IteratorType>::value|| mpl::contains< typename multi_index_type::const_iterator_type_list, IteratorType>::value), "( mpl::contains< BOOST_DEDUCED_TYPENAME multi_index_type::iterator_type_list, IteratorType>::value|| mpl::contains< BOOST_DEDUCED_TYPENAME multi_index_type::const_iterator_type_list, IteratorType>::value)") > > > > > > ; > > > ((void)0);; ># 1244 "/usr/include/boost/multi_index_container.hpp" 3 4 > return detail::converter<multi_index_type,index>::const_iterator( > m,static_cast<typename multi_index_type::node_type*>(it.get_node())); >} > > > >template<typename MultiIndexContainer,typename Tag> >struct index_iterator >{ > typedef typename ::boost::multi_index::index< > MultiIndexContainer,Tag>::type::iterator type; >}; > >template<typename MultiIndexContainer,typename Tag> >struct index_const_iterator >{ > typedef typename ::boost::multi_index::index< > MultiIndexContainer,Tag>::type::const_iterator type; >}; > >template< > typename Tag,typename IteratorType, > typename Value,typename IndexSpecifierList,typename Allocator> >typename index_iterator< > multi_index_container<Value,IndexSpecifierList,Allocator>,Tag>::type >project( > multi_index_container<Value,IndexSpecifierList,Allocator>& m, > IteratorType it > ) >{ > typedef multi_index_container< > Value,IndexSpecifierList,Allocator> multi_index_type; > typedef typename ::boost::multi_index::index< > multi_index_type,Tag>::type index; > > > > static_assert(( mpl::contains< typename multi_index_type::iterator_type_list, IteratorType>::value), "( mpl::contains< BOOST_DEDUCED_TYPENAME multi_index_type::iterator_type_list, IteratorType>::value)") > > > ; > > > ((void)0);; ># 1296 "/usr/include/boost/multi_index_container.hpp" 3 4 > return detail::converter<multi_index_type,index>::iterator( > m,static_cast<typename multi_index_type::node_type*>(it.get_node())); >} > >template< > typename Tag,typename IteratorType, > typename Value,typename IndexSpecifierList,typename Allocator> >typename index_const_iterator< > multi_index_container<Value,IndexSpecifierList,Allocator>,Tag>::type >project( > const multi_index_container<Value,IndexSpecifierList,Allocator>& m, > IteratorType it > ) >{ > typedef multi_index_container< > Value,IndexSpecifierList,Allocator> multi_index_type; > typedef typename ::boost::multi_index::index< > multi_index_type,Tag>::type index; > > > > static_assert(( mpl::contains< typename multi_index_type::iterator_type_list, IteratorType>::value|| mpl::contains< typename multi_index_type::const_iterator_type_list, IteratorType>::value), "( mpl::contains< BOOST_DEDUCED_TYPENAME multi_index_type::iterator_type_list, IteratorType>::value|| mpl::contains< BOOST_DEDUCED_TYPENAME multi_index_type::const_iterator_type_list, IteratorType>::value)") > > > > > > ; > > > ((void)0);; ># 1335 "/usr/include/boost/multi_index_container.hpp" 3 4 > return detail::converter<multi_index_type,index>::const_iterator( > m,static_cast<typename multi_index_type::node_type*>(it.get_node())); >} > > > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator==( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y) >{ > return get<0>(x)==get<0>(y); >} > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator<( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y) >{ > return get<0>(x)<get<0>(y); >} > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator!=( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y) >{ > return get<0>(x)!=get<0>(y); >} > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator>( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y) >{ > return get<0>(x)>get<0>(y); >} > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator>=( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y) >{ > return get<0>(x)>=get<0>(y); >} > >template< > typename Value1,typename IndexSpecifierList1,typename Allocator1, > typename Value2,typename IndexSpecifierList2,typename Allocator2 >> >bool operator<=( > const multi_index_container<Value1,IndexSpecifierList1,Allocator1>& x, > const multi_index_container<Value2,IndexSpecifierList2,Allocator2>& y) >{ > return get<0>(x)<=get<0>(y); >} > > > >template<typename Value,typename IndexSpecifierList,typename Allocator> >void swap( > multi_index_container<Value,IndexSpecifierList,Allocator>& x, > multi_index_container<Value,IndexSpecifierList,Allocator>& y) >{ > x.swap(y); >} > >} ># 1426 "/usr/include/boost/multi_index_container.hpp" 3 4 >namespace serialization { >template<typename Value,typename IndexSpecifierList,typename Allocator> >struct version< > boost::multi_index_container<Value,IndexSpecifierList,Allocator> >> >{ > static const int value=2; >}; >} > > > > > > >using multi_index::get; >using multi_index::project; > >} ># 11 "/c/honeypenny/src/currency_core/blockchain_storage.h" 2 ># 1 "/usr/include/boost/multi_index/global_fun.hpp" 1 3 4 ># 28 "/usr/include/boost/multi_index/global_fun.hpp" 3 4 >namespace boost{ > >template<class T> class reference_wrapper; > >namespace multi_index{ > >namespace detail{ ># 59 "/usr/include/boost/multi_index/global_fun.hpp" 3 4 >template<class Value,typename Type,Type (*PtrToFunction)(Value)> >struct const_ref_global_fun_base >{ > typedef typename remove_reference<Type>::type result_type; > > template<typename ChainedPtr> > > > typename disable_if< > is_convertible<const ChainedPtr&,Value>,Type>::type > > > > > operator()(const ChainedPtr& x)const > { > return operator()(*x); > } > > Type operator()(Value x)const > { > return PtrToFunction(x); > } > > Type operator()( > const reference_wrapper< > typename remove_reference<Value>::type>& x)const > { > return operator()(x.get()); > } > > Type operator()( > const reference_wrapper< > typename remove_const< > typename remove_reference<Value>::type>::type>& x,int=0)const > { > return operator()(x.get()); > } >}; > >template<class Value,typename Type,Type (*PtrToFunction)(Value)> >struct non_const_ref_global_fun_base >{ > typedef typename remove_reference<Type>::type result_type; > > template<typename ChainedPtr> > > > typename disable_if< > is_convertible<ChainedPtr&,Value>,Type>::type > > > > > operator()(const ChainedPtr& x)const > { > return operator()(*x); > } > > Type operator()(Value x)const > { > return PtrToFunction(x); > } > > Type operator()( > const reference_wrapper< > typename remove_reference<Value>::type>& x)const > { > return operator()(x.get()); > } >}; > >template<class Value,typename Type,Type (*PtrToFunction)(Value)> >struct non_ref_global_fun_base >{ > typedef typename remove_reference<Type>::type result_type; > > template<typename ChainedPtr> > > > typename disable_if< > is_convertible<const ChainedPtr&,const Value&>,Type>::type > > > > > operator()(const ChainedPtr& x)const > { > return operator()(*x); > } > > Type operator()(const Value& x)const > { > return PtrToFunction(x); > } > > Type operator()(const reference_wrapper<const Value>& x)const > { > return operator()(x.get()); > } > > Type operator()( > const reference_wrapper< > typename remove_const<Value>::type>& x,int=0)const > { > return operator()(x.get()); > } >}; > >} > >template<class Value,typename Type,Type (*PtrToFunction)(Value)> >struct global_fun: > mpl::if_c< > is_reference<Value>::value, > typename mpl::if_c< > is_const<typename remove_reference<Value>::type>::value, > detail::const_ref_global_fun_base<Value,Type,PtrToFunction>, > detail::non_const_ref_global_fun_base<Value,Type,PtrToFunction> > >::type, > detail::non_ref_global_fun_base<Value,Type,PtrToFunction> > >::type >{ >}; > >} > >} ># 12 "/c/honeypenny/src/currency_core/blockchain_storage.h" 2 ># 1 "/usr/include/boost/multi_index/hashed_index.hpp" 1 3 4 ># 29 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/bucket_array.hpp" 1 3 4 ># 19 "/usr/include/boost/multi_index/detail/bucket_array.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/hash_index_node.hpp" 1 3 4 ># 21 "/usr/include/boost/multi_index/detail/hash_index_node.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > >template<typename Allocator> >struct hashed_index_node_impl >{ > typedef typename prevent_eti< > Allocator, > typename boost::detail::allocator::rebind_to< > Allocator,hashed_index_node_impl > >::type > >::type::pointer pointer; > typedef typename prevent_eti< > Allocator, > typename boost::detail::allocator::rebind_to< > Allocator,hashed_index_node_impl > >::type > >::type::const_pointer const_pointer; > > pointer& next(){return next_;} > pointer next()const{return next_;} > > > > static void increment(pointer& x,pointer bbegin,pointer bend) > { > std::less_equal<pointer> leq; > > x=x->next(); > if(leq(bbegin,x)&&leq(x,bend)){ > do{ > ++x; > }while(x->next()==x); > x=x->next(); > } > } > > static void link(pointer x,pointer pos) > { > x->next()=pos->next(); > pos->next()=x; > }; > > static void unlink(pointer x) > { > pointer y=x->next(); > while(y->next()!=x){y=y->next();} > y->next()=x->next(); > } > > static pointer prev(pointer x) > { > pointer y=x->next(); > while(y->next()!=x){y=y->next();} > return y; > } > > static void unlink_next(pointer x) > { > x->next()=x->next()->next(); > } > >private: > pointer next_; >}; > >template<typename Super> >struct hashed_index_node_trampoline: > prevent_eti< > Super, > hashed_index_node_impl< > typename boost::detail::allocator::rebind_to< > typename Super::allocator_type, > char > >::type > > > >::type >{ > typedef typename prevent_eti< > Super, > hashed_index_node_impl< > typename boost::detail::allocator::rebind_to< > typename Super::allocator_type, > char > >::type > > > >::type impl_type; >}; > >template<typename Super> >struct hashed_index_node:Super,hashed_index_node_trampoline<Super> >{ >private: > typedef hashed_index_node_trampoline<Super> trampoline; > >public: > typedef typename trampoline::impl_type impl_type; > typedef typename trampoline::pointer impl_pointer; > typedef typename trampoline::const_pointer const_impl_pointer; > > impl_pointer impl() > { > return static_cast<impl_pointer>( > static_cast<impl_type*>(static_cast<trampoline*>(this))); > } > > const_impl_pointer impl()const > { > return static_cast<const_impl_pointer>( > static_cast<const impl_type*>(static_cast<const trampoline*>(this))); > } > > static hashed_index_node* from_impl(impl_pointer x) > { > return static_cast<hashed_index_node*>( > static_cast<trampoline*>(&*x)); > } > > static const hashed_index_node* from_impl(const_impl_pointer x) > { > return static_cast<const hashed_index_node*>( > static_cast<const trampoline*>(&*x)); > } > > static void increment( > hashed_index_node*& x,impl_pointer bbegin,impl_pointer bend) > { > impl_pointer xi=x->impl(); > trampoline::increment(xi,bbegin,bend); > x=from_impl(xi); > } >}; > >} > >} > >} ># 20 "/usr/include/boost/multi_index/detail/bucket_array.hpp" 2 3 4 > > > ># 1 "/usr/lib/gcc/x86_64-redhat-linux/4.9.0/include/limits.h" 1 3 4 ># 24 "/usr/include/boost/multi_index/detail/bucket_array.hpp" 2 3 4 > > > > > > > >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > >class bucket_array_base:private noncopyable >{ >protected: > inline static std::size_t next_prime(std::size_t n) > { > static const std::size_t prime_list[]={ > 53ul, 97ul, 193ul, 389ul, 769ul, > 1543ul, 3079ul, 6151ul, 12289ul, 24593ul, > 49157ul, 98317ul, 196613ul, 393241ul, 786433ul, > 1572869ul, 3145739ul, 6291469ul, 12582917ul, 25165843ul, > 50331653ul, 100663319ul, 201326611ul, 402653189ul, 805306457ul, > 1610612741ul, 3221225473ul, ># 62 "/usr/include/boost/multi_index/detail/bucket_array.hpp" 3 4 > 6442450939ul, 12884901893ul, 25769803751ul, 51539607551ul, > 103079215111ul, 206158430209ul, 412316860441ul, 824633720831ul, > 1649267441651ul, 3298534883309ul, 6597069766657ul, 13194139533299ul, > 26388279066623ul, 52776558133303ul, 105553116266489ul, 211106232532969ul, > 422212465066001ul, 844424930131963ul, 1688849860263953ul, > 3377699720527861ul, 6755399441055731ul, 13510798882111483ul, > 27021597764222939ul, 54043195528445957ul, 108086391056891903ul, > 216172782113783843ul, 432345564227567621ul, 864691128455135207ul, > 1729382256910270481ul, 3458764513820540933ul, 6917529027641081903ul, > 13835058055282163729ul, 18446744073709551557ul > > > }; > static const std::size_t prime_list_size= > sizeof(prime_list)/sizeof(prime_list[0]); > > std::size_t const *bound= > std::lower_bound(prime_list,prime_list+prime_list_size,n); > if(bound==prime_list+prime_list_size)bound--; > return *bound; > } >}; > >template<typename Allocator> >class bucket_array:public bucket_array_base >{ > typedef typename prevent_eti< > Allocator, > hashed_index_node_impl< > typename boost::detail::allocator::rebind_to< > Allocator, > char > >::type > > > >::type node_impl_type; > >public: > typedef typename node_impl_type::pointer pointer; > > bucket_array(const Allocator& al,pointer end_,std::size_t size): > size_(bucket_array_base::next_prime(size)), > spc(al,size_+1) > { > clear(); > end()->next()=end_; > end_->next()=end(); > } > > std::size_t size()const > { > return size_; > } > > std::size_t position(std::size_t hash)const > { > return hash%size_; > } > > pointer begin()const{return buckets();} > pointer end()const{return buckets()+size_;} > pointer at(std::size_t n)const{return buckets()+n;} > > std::size_t first_nonempty(std::size_t n)const > { > for(;;++n){ > pointer x=at(n); > if(x->next()!=x)return n; > } > } > > void clear() > { > for(pointer x=begin(),y=end();x!=y;++x)x->next()=x; > } > > void swap(bucket_array& x) > { > std::swap(size_,x.size_); > spc.swap(x.spc); > } > >private: > std::size_t size_; > auto_space<node_impl_type,Allocator> spc; > > pointer buckets()const > { > return spc.data(); > } > > > friend class boost::serialization::access; > > > > > > > template<class Archive> > void serialize(Archive&,const unsigned int) > { > } > >}; > >template<typename Allocator> >void swap(bucket_array<Allocator>& x,bucket_array<Allocator>& y) >{ > x.swap(y); >} > >} > >} ># 187 "/usr/include/boost/multi_index/detail/bucket_array.hpp" 3 4 >namespace multi_index{ >namespace detail{ > > >template<class Archive,typename Allocator> >inline void load_construct_data( > Archive&,boost::multi_index::detail::bucket_array<Allocator>*, > const unsigned int) >{ > throw_exception( > archive::archive_exception(archive::archive_exception::other_exception)); >} > > > > >} >} > > > > >} ># 30 "/usr/include/boost/multi_index/hashed_index.hpp" 2 3 4 > ># 1 "/usr/include/boost/multi_index/detail/hash_index_iterator.hpp" 1 3 4 ># 24 "/usr/include/boost/multi_index/detail/hash_index_iterator.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > >template<typename Node,typename BucketArray> >class hashed_index_iterator: > public forward_iterator_helper< > hashed_index_iterator<Node,BucketArray>, > typename Node::value_type, > std::ptrdiff_t, > const typename Node::value_type*, > const typename Node::value_type&> >{ >public: > hashed_index_iterator(){} > hashed_index_iterator(Node* node_,BucketArray* buckets_): > node(node_),buckets(buckets_) > {} > > const typename Node::value_type& operator*()const > { > return node->value(); > } > > hashed_index_iterator& operator++() > { > Node::increment(node,buckets->begin(),buckets->end()); > return *this; > } > > > > > > > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } > > typedef typename Node::base_type node_base_type; > > template<class Archive> > void save(Archive& ar,const unsigned int)const > { > node_base_type* bnode=node; > ar<<serialization::make_nvp("pointer",bnode); > ar<<serialization::make_nvp("pointer",buckets); > } > > template<class Archive> > void load(Archive& ar,const unsigned int) > { > node_base_type* bnode; > ar>>serialization::make_nvp("pointer",bnode); > node=static_cast<Node*>(bnode); > ar>>serialization::make_nvp("pointer",buckets); > } > > > > > typedef Node node_type; > > Node* get_node()const{return node;} > >private: > Node* node; > BucketArray* buckets; >}; > >template<typename Node,typename BucketArray> >bool operator==( > const hashed_index_iterator<Node,BucketArray>& x, > const hashed_index_iterator<Node,BucketArray>& y) >{ > return x.get_node()==y.get_node(); >} > >} > >} > >} ># 32 "/usr/include/boost/multi_index/hashed_index.hpp" 2 3 4 > ># 1 "/usr/include/boost/multi_index/detail/modify_key_adaptor.hpp" 1 3 4 ># 16 "/usr/include/boost/multi_index/detail/modify_key_adaptor.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > > > >template<typename Fun,typename Value,typename KeyFromValue> >struct modify_key_adaptor >{ > > modify_key_adaptor(Fun f_,KeyFromValue kfv_):f(f_),kfv(kfv_){} > > void operator()(Value& x) > { > f(kfv(x)); > } > >private: > Fun f; > KeyFromValue kfv; >}; > >} > >} > >} ># 34 "/usr/include/boost/multi_index/hashed_index.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/safe_ctr_proxy.hpp" 1 3 4 ># 35 "/usr/include/boost/multi_index/hashed_index.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/multi_index/hashed_index_fwd.hpp" 1 3 4 ># 16 "/usr/include/boost/multi_index/hashed_index_fwd.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/hash_index_args.hpp" 1 3 4 ># 17 "/usr/include/boost/multi_index/detail/hash_index_args.hpp" 3 4 ># 1 "/usr/include/boost/functional/hash.hpp" 1 3 4 > > > > > ># 1 "/usr/include/boost/functional/hash/hash.hpp" 1 3 4 ># 7 "/usr/include/boost/functional/hash.hpp" 2 3 4 ># 18 "/usr/include/boost/multi_index/detail/hash_index_args.hpp" 2 3 4 ># 27 "/usr/include/boost/multi_index/detail/hash_index_args.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 49 "/usr/include/boost/multi_index/detail/hash_index_args.hpp" 3 4 >template<typename KeyFromValue> >struct index_args_default_hash >{ > typedef ::boost::hash<typename KeyFromValue::result_type> type; >}; > >template<typename KeyFromValue> >struct index_args_default_pred >{ > typedef std::equal_to<typename KeyFromValue::result_type> type; >}; > >template<typename Arg1,typename Arg2,typename Arg3,typename Arg4> >struct hashed_index_args >{ > typedef is_tag<Arg1> full_form; > > typedef typename mpl::if_< > full_form, > Arg1, > tag< > >::type tag_list_type; > typedef typename mpl::if_< > full_form, > Arg2, > Arg1>::type key_from_value_type; > typedef typename mpl::if_< > full_form, > Arg3, > Arg2>::type supplied_hash_type; > typedef typename mpl::eval_if< > mpl::is_na<supplied_hash_type>, > index_args_default_hash<key_from_value_type>, > mpl::identity<supplied_hash_type> > >::type hash_type; > typedef typename mpl::if_< > full_form, > Arg4, > Arg3>::type supplied_pred_type; > typedef typename mpl::eval_if< > mpl::is_na<supplied_pred_type>, > index_args_default_pred<key_from_value_type>, > mpl::identity<supplied_pred_type> > >::type pred_type; > > static_assert(is_tag<tag_list_type>::value, "is_tag<tag_list_type>::value"); > static_assert(!mpl::is_na<key_from_value_type>::value, "!mpl::is_na<key_from_value_type>::value"); > static_assert(!mpl::is_na<hash_type>::value, "!mpl::is_na<hash_type>::value"); > static_assert(!mpl::is_na<pred_type>::value, "!mpl::is_na<pred_type>::value"); >}; > >} > >} > >} ># 17 "/usr/include/boost/multi_index/hashed_index_fwd.hpp" 2 3 4 > >namespace boost{ > >namespace multi_index{ > >namespace detail{ > >template< > typename KeyFromValue,typename Hash,typename Pred, > typename SuperMeta,typename TagList,typename Category >> >class hashed_index; > >template< > typename KeyFromValue,typename Hash,typename Pred, > typename SuperMeta,typename TagList,typename Category >> >void swap( > hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& x, > hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& y); > >} > > > >template< > typename Arg1,typename Arg2=mpl::na, > typename Arg3=mpl::na,typename Arg4=mpl::na >> >struct hashed_unique; > >template< > typename Arg1,typename Arg2=mpl::na, > typename Arg3=mpl::na,typename Arg4=mpl::na >> >struct hashed_non_unique; > >} > >} ># 39 "/usr/include/boost/multi_index/hashed_index.hpp" 2 3 4 ># 64 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 77 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 >struct hashed_unique_tag{}; >struct hashed_non_unique_tag{}; > >template< > typename KeyFromValue,typename Hash,typename Pred, > typename SuperMeta,typename TagList,typename Category >> >class hashed_index: > protected SuperMeta::type ># 100 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 >{ ># 111 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 > typedef typename SuperMeta::type super; > >protected: > typedef hashed_index_node< > typename super::node_type> node_type; > >private: > typedef typename node_type::impl_type node_impl_type; > typedef typename node_impl_type::pointer node_impl_pointer; > typedef bucket_array< > typename super::final_allocator_type> bucket_array_type; > >public: > > > typedef typename KeyFromValue::result_type key_type; > typedef typename node_type::value_type value_type; > typedef KeyFromValue key_from_value; > typedef Hash hasher; > typedef Pred key_equal; > typedef tuple<std::size_t, > key_from_value,hasher,key_equal> ctor_args; > typedef typename super::final_allocator_type allocator_type; > typedef typename allocator_type::pointer pointer; > typedef typename allocator_type::const_pointer const_pointer; > typedef typename allocator_type::reference reference; > typedef typename allocator_type::const_reference const_reference; > typedef std::size_t size_type; > typedef std::ptrdiff_t difference_type; ># 156 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 > typedef hashed_index_iterator< > node_type,bucket_array_type> iterator; > > > typedef iterator const_iterator; > > typedef iterator local_iterator; > typedef const_iterator const_local_iterator; > typedef TagList tag_list; > >protected: > typedef typename super::final_node_type final_node_type; > typedef tuples::cons< > ctor_args, > typename super::ctor_args_list> ctor_args_list; > typedef typename mpl::push_front< > typename super::index_type_list, > hashed_index>::type index_type_list; > typedef typename mpl::push_front< > typename super::iterator_type_list, > iterator>::type iterator_type_list; > typedef typename mpl::push_front< > typename super::const_iterator_type_list, > const_iterator>::type const_iterator_type_list; > typedef typename super::copy_map_type copy_map_type; > > > typedef typename super::index_saver_type index_saver_type; > typedef typename super::index_loader_type index_loader_type; > > >private: ># 200 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 > typedef typename call_traits<value_type>::param_type value_param_type; > typedef typename call_traits< > key_type>::param_type key_param_type; > > > > > > typedef std::pair<iterator,bool> emplace_return_type; > >public: > > > > > > > hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& operator=( > const hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& x) > { > this->final()=x.final(); > return *this; > } > > > hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& operator=( > std::initializer_list<value_type> list) > { > this->final()=list; > return *this; > } > > > allocator_type get_allocator()const > { > return this->final().get_allocator(); > } > > > > bool empty()const{return this->final_empty_();} > size_type size()const{return this->final_size_();} > size_type max_size()const{return this->final_max_size_();} > > > > iterator begin() > { > return make_iterator( > node_type::from_impl(buckets.at(first_bucket)->next())); > } > > const_iterator begin()const > { > return make_iterator( > node_type::from_impl(buckets.at(first_bucket)->next())); > } > > iterator end(){return make_iterator(header());} > const_iterator end()const{return make_iterator(header());} > > const_iterator cbegin()const{return begin();} > const_iterator cend()const{return end();} > > iterator iterator_to(const value_type& x) > { > return make_iterator(node_from_value<node_type>(&x)); > } > > const_iterator iterator_to(const value_type& x)const > { > return make_iterator(node_from_value<node_type>(&x)); > } > > > > template<typename... Args> emplace_return_type emplace(Args&&... args) { return emplace_impl(std::forward<Args>(args)...); } > > > template<typename... Args> iterator emplace_hint( iterator position,Args&&... args) { return emplace_hint_impl(position,std::forward<Args>(args)...); } > > > std::pair<iterator,bool> insert(const value_type& x) > { > ; > std::pair<final_node_type*,bool> p=this->final_insert_(x); > return std::pair<iterator,bool>(make_iterator(p.first),p.second); > } > > std::pair<iterator,bool> insert(value_type && x) > { > ; > std::pair<final_node_type*,bool> p=this->final_insert_rv_(x); > return std::pair<iterator,bool>(make_iterator(p.first),p.second); > } > > iterator insert(iterator position,const value_type& x) > { > ((void)0);; > ((void)0);; > ; > std::pair<final_node_type*,bool> p=this->final_insert_( > x,static_cast<final_node_type*>(position.get_node())); > return make_iterator(p.first); > } > > iterator insert(iterator position,value_type && x) > { > ((void)0);; > ((void)0);; > ; > std::pair<final_node_type*,bool> p=this->final_insert_rv_( > x,static_cast<final_node_type*>(position.get_node())); > return make_iterator(p.first); > } > > template<typename InputIterator> > void insert(InputIterator first,InputIterator last) > { > ; > for(;first!=last;++first)this->final_insert_ref_(*first); > } > > > void insert(std::initializer_list<value_type> list) > { > insert(list.begin(),list.end()); > } > > > iterator erase(iterator position) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > this->final_erase_(static_cast<final_node_type*>(position++.get_node())); > return position; > } > > size_type erase(key_param_type k) > { > ; > > size_type s=0; > std::size_t buc=buckets.position(hash_(k)); > node_impl_pointer x=buckets.at(buc); > node_impl_pointer y=x->next(); > while(y!=x){ > if(eq_(k,key(node_type::from_impl(y)->value()))){ > bool b; > do{ > node_impl_pointer z=y->next(); > b=z!=x&&eq_( > key(node_type::from_impl(y)->value()), > key(node_type::from_impl(z)->value())); > this->final_erase_( > static_cast<final_node_type*>(node_type::from_impl(y))); > y=z; > ++s; > }while(b); > break; > } > y=y->next(); > } > return s; > } > > iterator erase(iterator first,iterator last) > { > ((void)0);; > ((void)0);; > ((void)0);; > ((void)0);; > ((void)0);; > ; > while(first!=last){ > first=erase(first); > } > return first; > } > > bool replace(iterator position,const value_type& x) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > return this->final_replace_( > x,static_cast<final_node_type*>(position.get_node())); > } > > bool replace(iterator position,value_type && x) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > return this->final_replace_rv_( > x,static_cast<final_node_type*>(position.get_node())); > } > > template<typename Modifier> > bool modify(iterator position,Modifier mod) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; ># 419 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 > return this->final_modify_( > mod,static_cast<final_node_type*>(position.get_node())); > } > > template<typename Modifier,typename Rollback> > bool modify(iterator position,Modifier mod,Rollback back) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; ># 440 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 > return this->final_modify_( > mod,back,static_cast<final_node_type*>(position.get_node())); > } > > template<typename Modifier> > bool modify_key(iterator position,Modifier mod) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > return modify( > position,modify_key_adaptor<Modifier,value_type,KeyFromValue>(mod,key)); > } > > template<typename Modifier,typename Rollback> > bool modify_key(iterator position,Modifier mod,Rollback back) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > return modify( > position, > modify_key_adaptor<Modifier,value_type,KeyFromValue>(mod,key), > modify_key_adaptor<Rollback,value_type,KeyFromValue>(back,key)); > } > > void clear() > { > ; > this->final_clear_(); > } > > void swap(hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& x) > { > ; > ; > this->final_swap_(x.final()); > } > > > > key_from_value key_extractor()const{return key;} > hasher hash_function()const{return hash_;} > key_equal key_eq()const{return eq_;} > > > > > > > > template<typename CompatibleKey> > iterator find(const CompatibleKey& k)const > { > return find(k,hash_,eq_); > } > > template< > typename CompatibleKey,typename CompatibleHash,typename CompatiblePred > > > iterator find( > const CompatibleKey& k, > const CompatibleHash& hash,const CompatiblePred& eq)const > { > std::size_t buc=buckets.position(hash(k)); > node_impl_pointer x=buckets.at(buc); > node_impl_pointer y=x->next(); > while(y!=x){ > if(eq(k,key(node_type::from_impl(y)->value()))){ > return make_iterator(node_type::from_impl(y)); > } > y=y->next(); > } > return end(); > } > > template<typename CompatibleKey> > size_type count(const CompatibleKey& k)const > { > return count(k,hash_,eq_); > } > > template< > typename CompatibleKey,typename CompatibleHash,typename CompatiblePred > > > size_type count( > const CompatibleKey& k, > const CompatibleHash& hash,const CompatiblePred& eq)const > { > size_type res=0; > std::size_t buc=buckets.position(hash(k)); > node_impl_pointer x=buckets.at(buc); > node_impl_pointer y=x->next(); > while(y!=x){ > if(eq(k,key(node_type::from_impl(y)->value()))){ > do{ > ++res; > y=y->next(); > }while(y!=x&&eq(k,key(node_type::from_impl(y)->value()))); > break; > } > y=y->next(); > } > return res; > } > > template<typename CompatibleKey> > std::pair<iterator,iterator> equal_range(const CompatibleKey& k)const > { > return equal_range(k,hash_,eq_); > } > > template< > typename CompatibleKey,typename CompatibleHash,typename CompatiblePred > > > std::pair<iterator,iterator> equal_range( > const CompatibleKey& k, > const CompatibleHash& hash,const CompatiblePred& eq)const > { > std::size_t buc=buckets.position(hash(k)); > node_impl_pointer x=buckets.at(buc); > node_impl_pointer y=x->next(); > while(y!=x){ > if(eq(k,key(node_type::from_impl(y)->value()))){ > node_impl_pointer y0=y; > do{ > y=y->next(); > }while(y!=x&&eq(k,key(node_type::from_impl(y)->value()))); > if(y==x){ > do{ > ++y; > }while(y==y->next()); > y=y->next(); > } > return std::pair<iterator,iterator>( > make_iterator(node_type::from_impl(y0)), > make_iterator(node_type::from_impl(y))); > } > y=y->next(); > } > return std::pair<iterator,iterator>(end(),end()); > } > > > > size_type bucket_count()const{return buckets.size();} > size_type max_bucket_count()const{return static_cast<size_type>(-1);} > > size_type bucket_size(size_type n)const > { > size_type res=0; > node_impl_pointer x=buckets.at(n); > node_impl_pointer y=x->next(); > while(y!=x){ > ++res; > y=y->next(); > } > return res; > } > > size_type bucket(key_param_type k)const > { > return buckets.position(hash_(k)); > } > > local_iterator begin(size_type n) > { > return const_cast<const hashed_index*>(this)->begin(n); > } > > const_local_iterator begin(size_type n)const > { > node_impl_pointer x=buckets.at(n); > node_impl_pointer y=x->next(); > if(y==x)return end(); > return make_iterator(node_type::from_impl(y)); > } > > local_iterator end(size_type n) > { > return const_cast<const hashed_index*>(this)->end(n); > } > > const_local_iterator end(size_type n)const > { > node_impl_pointer x=buckets.at(n); > if(x==x->next())return end(); > do{ > ++x; > }while(x==x->next()); > return make_iterator(node_type::from_impl(x->next())); > } > > const_local_iterator cbegin(size_type n)const{return begin(n);} > const_local_iterator cend(size_type n)const{return end(n);} > > local_iterator local_iterator_to(const value_type& x) > { > return make_iterator(node_from_value<node_type>(&x)); > } > > const_local_iterator local_iterator_to(const value_type& x)const > { > return make_iterator(node_from_value<node_type>(&x)); > } > > > > float load_factor()const{return static_cast<float>(size())/bucket_count();} > float max_load_factor()const{return mlf;} > void max_load_factor(float z){mlf=z;calculate_max_load();} > > void rehash(size_type n) > { > ; > if(size()<max_load&&n<=bucket_count())return; > > size_type bc =(std::numeric_limits<size_type>::max)(); > float fbc=static_cast<float>(1+size()/mlf); > if(bc>fbc){ > bc=static_cast<size_type>(fbc); > if(bc<n)bc=n; > } > unchecked_rehash(bc); > } > >protected: > hashed_index(const ctor_args_list& args_list,const allocator_type& al): > super(args_list.get_tail(),al), > key(tuples::get<1>(args_list.get_head())), > hash_(tuples::get<2>(args_list.get_head())), > eq_(tuples::get<3>(args_list.get_head())), > buckets(al,header()->impl(),tuples::get<0>(args_list.get_head())), > mlf(1.0f), > first_bucket(buckets.size()) > { > calculate_max_load(); > } > > hashed_index( > const hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& x): > super(x), > > > > > > key(x.key), > hash_(x.hash_), > eq_(x.eq_), > buckets(x.get_allocator(),header()->impl(),x.buckets.size()), > mlf(x.mlf), > max_load(x.max_load), > first_bucket(x.first_bucket) > { > > > > } > > hashed_index( > const hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& x, > do_not_copy_elements_tag): > super(x,do_not_copy_elements_tag()), > > > > > > key(x.key), > hash_(x.hash_), > eq_(x.eq_), > buckets(x.get_allocator(),header()->impl(),0), > mlf(1.0f), > first_bucket(buckets.size()) > { > calculate_max_load(); > } > > ~hashed_index() > { > > } ># 740 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 > iterator make_iterator(node_type* node) > { > return iterator(node,&buckets); > } > > const_iterator make_iterator(node_type* node)const > { > return const_iterator(node,&const_cast<bucket_array_type&>(buckets)); > } > > > void copy_( > const hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& x, > const copy_map_type& map) > { > for(node_impl_pointer begin_org=x.buckets.begin(), > begin_cpy=buckets.begin(), > end_org=x.buckets.end(); > begin_org!=end_org;++begin_org,++begin_cpy){ > > node_impl_pointer next_org=begin_org->next(); > node_impl_pointer cpy=begin_cpy; > while(next_org!=begin_org){ > cpy->next()= > static_cast<node_type*>( > map.find( > static_cast<final_node_type*>( > node_type::from_impl(next_org))))->impl(); > next_org=next_org->next(); > cpy=cpy->next(); > } > cpy->next()=begin_cpy; > } > > super::copy_(x,map); > } > > template<typename Variant> > node_type* insert_(value_param_type v,node_type* x,Variant variant) > { > reserve(size()+1); > > std::size_t buc=find_bucket(v); > node_impl_pointer pos=buckets.at(buc); > if(!link_point(v,pos,Category()))return node_type::from_impl(pos); > > node_type* res=static_cast<node_type*>(super::insert_(v,x,variant)); > if(res==x){ > link(x,pos); > if(first_bucket>buc)first_bucket=buc; > } > return res; > } > > template<typename Variant> > node_type* insert_( > value_param_type v,node_type* position,node_type* x,Variant variant) > { > reserve(size()+1); > > std::size_t buc=find_bucket(v); > node_impl_pointer pos=buckets.at(buc); > if(!link_point(v,pos,Category()))return node_type::from_impl(pos); > > node_type* res= > static_cast<node_type*>(super::insert_(v,position,x,variant)); > if(res==x){ > link(x,pos); > if(first_bucket>buc)first_bucket=buc; > } > return res; > } > > void erase_(node_type* x) > { > unlink(x); > first_bucket=buckets.first_nonempty(first_bucket); > super::erase_(x); > > > > > } > > void delete_all_nodes_() > { > for(node_impl_pointer x=buckets.begin(),x_end=buckets.end(); > x!=x_end;++x){ > node_impl_pointer y=x->next(); > while(y!=x){ > node_impl_pointer z=y->next(); > this->final_delete_node_( > static_cast<final_node_type*>(node_type::from_impl(y))); > y=z; > } > } > } > > void clear_() > { > super::clear_(); > buckets.clear(); > first_bucket=buckets.size(); > > > > > } > > void swap_( > hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& x) > { > std::swap(key,x.key); > std::swap(hash_,x.hash_); > std::swap(eq_,x.eq_); > buckets.swap(x.buckets); > std::swap(mlf,x.mlf); > std::swap(max_load,x.max_load); > std::swap(first_bucket,x.first_bucket); > > > > > > super::swap_(x); > } > > void swap_elements_( > hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& x) > { > buckets.swap(x.buckets); > std::swap(mlf,x.mlf); > std::swap(max_load,x.max_load); > std::swap(first_bucket,x.first_bucket); > > > > > > super::swap_elements_(x); > } > > template<typename Variant> > bool replace_(value_param_type v,node_type* x,Variant variant) > { > if(eq_(key(v),key(x->value()))){ > return super::replace_(v,x,variant); > } > > node_impl_pointer y=prev(x); > unlink_next(y); > > { try{ > std::size_t buc=find_bucket(v); > node_impl_pointer pos=buckets.at(buc); > if(link_point(v,pos,Category())&&super::replace_(v,x,variant)){ > link(x,pos); > if(first_bucket>buc){ > first_bucket=buc; > } > else if(first_bucket<buc){ > first_bucket=buckets.first_nonempty(first_bucket); > } > return true; > } > link(x,y); > return false; > } > catch(...){ > link(x,y); > throw;; > } > } > } > > bool modify_(node_type* x) > { > std::size_t buc; > bool b; > { try{ > buc=find_bucket(x->value()); > b=in_place(x->impl(),key(x->value()),buc,Category()); > } > catch(...){ > erase_(x); > throw;; > } > } > if(!b){ > unlink(x); > { try{ > node_impl_pointer pos=buckets.at(buc); > if(!link_point(x->value(),pos,Category())){ > first_bucket=buckets.first_nonempty(first_bucket); > super::erase_(x); > > > > > return false; > } > link(x,pos); > if(first_bucket>buc){ > first_bucket=buc; > } > else if(first_bucket<buc){ > first_bucket=buckets.first_nonempty(first_bucket); > } > } > catch(...){ > first_bucket=buckets.first_nonempty(first_bucket); > super::erase_(x); > > > > > > throw;; > } > } > } > > { try{ > if(!super::modify_(x)){ > unlink(x); > first_bucket=buckets.first_nonempty(first_bucket); > > > > return false; > } > else return true; > } > catch(...){ > unlink(x); > first_bucket=buckets.first_nonempty(first_bucket); > > > > > > throw;; > } > } > } > > bool modify_rollback_(node_type* x) > { > std::size_t buc=find_bucket(x->value()); > if(in_place(x->impl(),key(x->value()),buc,Category())){ > return super::modify_rollback_(x); > } > > node_impl_pointer y=prev(x); > unlink_next(y); > > { try{ > node_impl_pointer pos=buckets.at(buc); > if(link_point(x->value(),pos,Category())&&super::modify_rollback_(x)){ > link(x,pos); > if(first_bucket>buc){ > first_bucket=buc; > } > else if(first_bucket<buc){ > first_bucket=buckets.first_nonempty(first_bucket); > } > return true; > } > link(x,y); > return false; > } > catch(...){ > link(x,y); > throw;; > } > } > } > > > > > template<typename Archive> > void save_( > Archive& ar,const unsigned int version,const index_saver_type& sm)const > { > ar<<serialization::make_nvp("position",buckets); > super::save_(ar,version,sm); > } > > template<typename Archive> > void load_(Archive& ar,const unsigned int version,const index_loader_type& lm) > { > ar>>serialization::make_nvp("position",buckets); > super::load_(ar,version,lm); > } ># 1075 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 >private: > node_type* header()const{return this->final_header();} > > std::size_t find_bucket(value_param_type v)const > { > return bucket(key(v)); > } > > bool link_point( > value_param_type v,node_impl_pointer& pos,hashed_unique_tag) > { > node_impl_pointer x=pos->next(); > while(x!=pos){ > if(eq_(key(v),key(node_type::from_impl(x)->value()))){ > pos=x; > return false; > } > x=x->next(); > } > return true; > } > > bool link_point( > value_param_type v,node_impl_pointer& pos,hashed_non_unique_tag) > { > node_impl_pointer prev=pos; > node_impl_pointer x=pos->next(); > while(x!=pos){ > if(eq_(key(v),key(node_type::from_impl(x)->value()))){ > pos=prev; > return true; > } > prev=x; > x=x->next(); > } > return true; > } > > static void link(node_type* x,node_impl_pointer pos) > { > node_impl_type::link(x->impl(),pos); > }; > > static void link(node_impl_pointer x,node_impl_pointer pos) > { > node_impl_type::link(x,pos); > }; > > static void unlink(node_type* x) > { > node_impl_type::unlink(x->impl()); > }; > > static node_impl_pointer prev(node_type* x) > { > return node_impl_type::prev(x->impl()); > } > > static node_impl_pointer prev_from(node_type* x,node_impl_pointer y) > { > return node_impl_type::prev_from(x->impl(),y); > } > > static void unlink_next(node_impl_pointer x) > { > node_impl_type::unlink_next(x); > } > > void calculate_max_load() > { > float fml=static_cast<float>(mlf*bucket_count()); > max_load=(std::numeric_limits<size_type>::max)(); > if(max_load>fml)max_load=static_cast<size_type>(fml); > } > > void reserve(size_type n) > { > if(n>max_load){ > size_type bc =(std::numeric_limits<size_type>::max)(); > float fbc=static_cast<float>(1+static_cast<double>(n)/mlf); > if(bc>fbc)bc =static_cast<size_type>(fbc); > unchecked_rehash(bc); > } > } > > void unchecked_rehash(size_type n) > { > bucket_array_type buckets1(get_allocator(),header()->impl(),n); > auto_space<std::size_t,allocator_type> hashes(get_allocator(),size()); > > std::size_t i=0; > node_impl_pointer x=buckets.begin(); > node_impl_pointer x_end=buckets.end(); > for(;x!=x_end;++x){ > node_impl_pointer y=x->next(); > while(y!=x){ > hashes.data()[i++]=hash_(key(node_type::from_impl(y)->value())); > y=y->next(); > } > } > > i=0; > x=buckets.begin(); > for(;x!=x_end;++x){ > node_impl_pointer y=x->next(); > while(y!=x){ > node_impl_pointer z=y->next(); > std::size_t buc1=buckets1.position(hashes.data()[i++]); > node_impl_pointer x1=buckets1.at(buc1); > link(y,x1); > y=z; > } > } > > buckets.swap(buckets1); > calculate_max_load(); > first_bucket=buckets.first_nonempty(0); > } > > bool in_place( > node_impl_pointer x,key_param_type k,std::size_t buc, > hashed_unique_tag)const > { > std::less_equal<node_impl_pointer> leq; > node_impl_pointer bbegin=buckets.begin(); > node_impl_pointer bend=buckets.end(); > node_impl_pointer pbuc=x->next(); > > while(!leq(bbegin,pbuc)||!leq(pbuc,bend))pbuc=pbuc->next(); > if(buc!=static_cast<std::size_t>(pbuc-bbegin))return false; > > node_impl_pointer y=x; > while(y->next()!=x){ > y=y->next(); > if(y==pbuc)continue; > if(eq_(k,key(node_type::from_impl(y)->value())))return false; > } > return true; > } > > bool in_place( > node_impl_pointer x,key_param_type k,std::size_t buc, > hashed_non_unique_tag)const > { > std::less_equal<node_impl_pointer> leq; > node_impl_pointer bbegin=buckets.begin(); > node_impl_pointer bend=buckets.end(); > node_impl_pointer pbuc=x->next(); > > while(!leq(bbegin,pbuc)||!leq(pbuc,bend))pbuc=pbuc->next(); > if(buc!=static_cast<std::size_t>(pbuc-bbegin))return false; > > node_impl_pointer y=x->next(); > if(y!=pbuc){ > if(eq_(k,key(node_type::from_impl(y)->value()))){ > > return true; > } > else{ > y=y->next(); > while(y!=pbuc){ > if(eq_(k,key(node_type::from_impl(y)->value())))return false; > y=y->next(); > } > } > } > while(y->next()!=x){ > y=y->next(); > if(eq_(k,key(node_type::from_impl(y)->value()))){ > while(y->next()!=x){ > y=y->next(); > if(!eq_(k,key(node_type::from_impl(y)->value())))return false; > } > > return true; > } > } > return true; > } ># 1264 "/usr/include/boost/multi_index/hashed_index.hpp" 3 4 > template<typename... Args> > std::pair<iterator,bool> emplace_impl(Args&&... args) > { > ; > std::pair<final_node_type*,bool>p= > this->final_emplace_(std::forward<Args>(args)...); > return std::pair<iterator,bool>(make_iterator(p.first),p.second); > } > > template<typename... Args> > iterator emplace_hint_impl( > iterator position,Args&&... args) > { > ((void)0);; > ((void)0);; > ; > std::pair<final_node_type*,bool>p= > this->final_emplace_hint_( > static_cast<final_node_type*>(position.get_node()), > std::forward<Args>(args)...); > return make_iterator(p.first); > } > > key_from_value key; > hasher hash_; > key_equal eq_; > bucket_array_type buckets; > float mlf; > size_type max_load; > std::size_t first_bucket; > > > > > >}; > > > >template< > typename KeyFromValue,typename Hash,typename Pred, > typename SuperMeta,typename TagList,typename Category >> >void swap( > hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& x, > hashed_index<KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>& y) >{ > x.swap(y); >} > >} > > > >template<typename Arg1,typename Arg2,typename Arg3,typename Arg4> >struct hashed_unique >{ > typedef typename detail::hashed_index_args< > Arg1,Arg2,Arg3,Arg4> index_args; > typedef typename index_args::tag_list_type::type tag_list_type; > typedef typename index_args::key_from_value_type key_from_value_type; > typedef typename index_args::hash_type hash_type; > typedef typename index_args::pred_type pred_type; > > template<typename Super> > struct node_class > { > typedef detail::hashed_index_node<Super> type; > }; > > template<typename SuperMeta> > struct index_class > { > typedef detail::hashed_index< > key_from_value_type,hash_type,pred_type, > SuperMeta,tag_list_type,detail::hashed_unique_tag> type; > }; >}; > >template<typename Arg1,typename Arg2,typename Arg3,typename Arg4> >struct hashed_non_unique >{ > typedef typename detail::hashed_index_args< > Arg1,Arg2,Arg3,Arg4> index_args; > typedef typename index_args::tag_list_type::type tag_list_type; > typedef typename index_args::key_from_value_type key_from_value_type; > typedef typename index_args::hash_type hash_type; > typedef typename index_args::pred_type pred_type; > > template<typename Super> > struct node_class > { > typedef detail::hashed_index_node<Super> type; > }; > > template<typename SuperMeta> > struct index_class > { > typedef detail::hashed_index< > key_from_value_type,hash_type,pred_type, > SuperMeta,tag_list_type,detail::hashed_non_unique_tag> type; > }; >}; > >} > >} > > > >template< > typename KeyFromValue,typename Hash,typename Pred, > typename SuperMeta,typename TagList,typename Category >> >inline boost::mpl::true_* boost_foreach_is_noncopyable( > boost::multi_index::detail::hashed_index< > KeyFromValue,Hash,Pred,SuperMeta,TagList,Category>*&, > boost::foreach::tag) >{ > return 0; >} ># 13 "/c/honeypenny/src/currency_core/blockchain_storage.h" 2 ># 1 "/usr/include/boost/multi_index/member.hpp" 1 3 4 ># 26 "/usr/include/boost/multi_index/member.hpp" 3 4 >namespace boost{ > >template<class T> class reference_wrapper; > >namespace multi_index{ > >namespace detail{ ># 54 "/usr/include/boost/multi_index/member.hpp" 3 4 >template<class Class,typename Type,Type Class::*PtrToMember> >struct const_member_base >{ > typedef Type result_type; > > template<typename ChainedPtr> > > > typename disable_if< > is_convertible<const ChainedPtr&,const Class&>,Type&>::type > > > > > operator()(const ChainedPtr& x)const > { > return operator()(*x); > } > > Type& operator()(const Class& x)const > { > return x.*PtrToMember; > } > > Type& operator()(const reference_wrapper<const Class>& x)const > { > return operator()(x.get()); > } > > Type& operator()(const reference_wrapper<Class>& x,int=0)const > { > return operator()(x.get()); > } >}; > >template<class Class,typename Type,Type Class::*PtrToMember> >struct non_const_member_base >{ > typedef Type result_type; > > template<typename ChainedPtr> > > > typename disable_if< > is_convertible<const ChainedPtr&,const Class&>,Type&>::type > > > > > operator()(const ChainedPtr& x)const > { > return operator()(*x); > } > > const Type& operator()(const Class& x,int=0)const > { > return x.*PtrToMember; > } > > Type& operator()(Class& x)const > { > return x.*PtrToMember; > } > > const Type& operator()(const reference_wrapper<const Class>& x,int=0)const > { > return operator()(x.get()); > } > > Type& operator()(const reference_wrapper<Class>& x)const > { > return operator()(x.get()); > } >}; > >} > >template<class Class,typename Type,Type Class::*PtrToMember> >struct member: > mpl::if_c< > is_const<Type>::value, > detail::const_member_base<Class,Type,PtrToMember>, > detail::non_const_member_base<Class,Type,PtrToMember> > >::type >{ >}; > >namespace detail{ ># 157 "/usr/include/boost/multi_index/member.hpp" 3 4 >template<class Class,typename Type,std::size_t OffsetOfMember> >struct const_member_offset_base >{ > typedef Type result_type; > > template<typename ChainedPtr> > > > typename disable_if< > is_convertible<const ChainedPtr&,const Class&>,Type&>::type > > > > > operator()(const ChainedPtr& x)const > { > return operator()(*x); > } > > Type& operator()(const Class& x)const > { > return *static_cast<const Type*>( > static_cast<const void*>( > static_cast<const char*>( > static_cast<const void *>(&x))+OffsetOfMember)); > } > > Type& operator()(const reference_wrapper<const Class>& x)const > { > return operator()(x.get()); > } > > Type& operator()(const reference_wrapper<Class>& x,int=0)const > { > return operator()(x.get()); > } >}; > >template<class Class,typename Type,std::size_t OffsetOfMember> >struct non_const_member_offset_base >{ > typedef Type result_type; > > template<typename ChainedPtr> > > > typename disable_if< > is_convertible<const ChainedPtr&,const Class&>,Type&>::type > > > > > operator()(const ChainedPtr& x)const > { > return operator()(*x); > } > > const Type& operator()(const Class& x,int=0)const > { > return *static_cast<const Type*>( > static_cast<const void*>( > static_cast<const char*>( > static_cast<const void *>(&x))+OffsetOfMember)); > } > > Type& operator()(Class& x)const > { > return *static_cast<Type*>( > static_cast<void*>( > static_cast<char*>(static_cast<void *>(&x))+OffsetOfMember)); > } > > const Type& operator()(const reference_wrapper<const Class>& x,int=0)const > { > return operator()(x.get()); > } > > Type& operator()(const reference_wrapper<Class>& x)const > { > return operator()(x.get()); > } >}; > >} > >template<class Class,typename Type,std::size_t OffsetOfMember> >struct member_offset: > mpl::if_c< > is_const<Type>::value, > detail::const_member_offset_base<Class,Type,OffsetOfMember>, > detail::non_const_member_offset_base<Class,Type,OffsetOfMember> > >::type >{ >}; ># 265 "/usr/include/boost/multi_index/member.hpp" 3 4 >} > >} ># 14 "/c/honeypenny/src/currency_core/blockchain_storage.h" 2 > > > > > ># 1 "/c/honeypenny/src/common/util.h" 1 ># 16 "/c/honeypenny/src/common/util.h" >namespace tools >{ > std::string get_default_data_dir(); > std::string get_os_version_string(); > bool create_directories_if_necessary(const std::string& path); > std::error_code replace_file(const std::string& replacement_name, const std::string& replaced_name); > > inline crypto::hash get_proof_of_trust_hash(const nodetool::proof_of_trust& pot) > { > std::string s; > s.append(reinterpret_cast<const char*>(&pot.peer_id), sizeof(pot.peer_id)); > s.append(reinterpret_cast<const char*>(&pot.time), sizeof(pot.time)); > return crypto::cn_fast_hash(s.data(), s.size()); > } > > inline > crypto::public_key get_public_key_from_string(const std::string& str_key) > { > crypto::public_key k = boost::value_initialized<decltype(k)>(); > epee::string_tools::hex_to_pod(str_key, k); > return k; > } > > > class signal_handler > { > public: > template<typename T> > static bool install(T t) > { ># 54 "/c/honeypenny/src/common/util.h" > signal(2, posix_handler); > signal(15, posix_handler); > m_handler = t; > return true; > > } > > private: ># 78 "/c/honeypenny/src/common/util.h" > static void posix_handler(int ) > { > handle_signal(); > } > > > static void handle_signal() > { > static std::mutex m_mutex; > std::unique_lock<std::mutex> lock(m_mutex); > m_handler(); > } > > private: > static std::function<void(void)> m_handler; > }; >} ># 20 "/c/honeypenny/src/currency_core/blockchain_storage.h" 2 > > > ># 1 "/c/honeypenny/src/currency_core/currency_format_utils.h" 1 ># 9 "/c/honeypenny/src/currency_core/currency_format_utils.h" ># 1 "/c/honeypenny/src/currency_core/account.h" 1 ># 11 "/c/honeypenny/src/currency_core/account.h" >namespace currency >{ > > struct account_keys > { > account_public_address m_account_address; > crypto::secret_key m_spend_secret_key; > crypto::secret_key m_view_secret_key; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/account.h" << ":" << 20 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.m_account_address, stg, hparent_section, "m_account_address"); > epee::serialization::selector<is_store>::serialize_t_val_as_blob(this_ref.m_spend_secret_key, stg, hparent_section, "m_spend_secret_key"); > epee::serialization::selector<is_store>::serialize_t_val_as_blob(this_ref.m_view_secret_key, stg, hparent_section, "m_view_secret_key"); > return true;} > }; > > > > > class account_base > { > public: > account_base(); > void generate(); > const account_keys& get_keys() const; > std::string get_public_address_str(); > > uint64_t get_createtime() const { return m_creation_timestamp; } > void set_createtime(uint64_t val) { m_creation_timestamp = val; } > > bool load(const std::string& file_path); > bool store(const std::string& file_path); > > template <class t_archive> > inline void serialize(t_archive &a, const unsigned int ) > { > a & m_keys; > a & m_creation_timestamp; > } > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/account.h" << ":" << 51 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.m_keys, stg, hparent_section, "m_keys"); > epee::serialization::selector<is_store>::serialize(this_ref.m_creation_timestamp, stg, hparent_section, "m_creation_timestamp"); > return true;} > > private: > void set_null(); > account_keys m_keys; > uint64_t m_creation_timestamp; > }; >} ># 10 "/c/honeypenny/src/currency_core/currency_format_utils.h" 2 > > > ># 1 "/c/honeypenny/src/crypto/wild_keccak.h" 1 ># 9 "/c/honeypenny/src/crypto/wild_keccak.h" ># 27 "/c/honeypenny/src/crypto/wild_keccak.h" >namespace crypto >{ > template<typename pod_operand_a, typename pod_operand_b> > pod_operand_a xor_pod(const pod_operand_a& a, const pod_operand_b& b) > { > static_assert(sizeof(pod_operand_a) == sizeof(pod_operand_b), "invalid xor_h usage: different sizes"); > static_assert(sizeof(pod_operand_a)%8 == 0, "invalid xor_h usage: wrong size"); > > hash r; > for(size_t i = 0; i != 4; i++) > { > ((uint64_t*)&r)[i] = ((const uint64_t*)&a)[i] ^ ((const uint64_t*)&b)[i]; > } > return r; > } ># 52 "/c/honeypenny/src/crypto/wild_keccak.h" > typedef uint64_t state_t_m[25]; > typedef uint64_t mixin_t[24]; > > > template<class f_traits> > int keccak_generic(const uint8_t *in, size_t inlen, uint8_t *md, int mdlen) > { > state_t_m st; > uint8_t temp[144]; > int i, rsiz, rsizw; > > rsiz = sizeof(state_t_m) == mdlen ? 136 : 200 - 2 * mdlen; > rsizw = rsiz / 8; > > memset(st, 0, sizeof(st)); > > for ( ; inlen >= rsiz; inlen -= rsiz, in += rsiz) { > for (i = 0; i < rsizw; i++) > st[i] ^= ((uint64_t *) in)[i]; > f_traits::keccakf(st, 24); > } > > > > memcpy(temp, in, inlen); > temp[inlen++] = 1; > memset(temp + inlen, 0, rsiz - inlen); > temp[rsiz - 1] |= 0x80; > > for (i = 0; i < rsizw; i++) > st[i] ^= ((uint64_t *) temp)[i]; > > f_traits::keccakf(st, 24); > > memcpy(md, st, mdlen); > > return 0; > } > > template<class f_traits, class callback_t> > int wild_keccak(const uint8_t *in, size_t inlen, uint8_t *md, int mdlen, callback_t cb) > { > state_t_m st; > uint8_t temp[144]; > int rsiz, rsizw; > > rsiz = sizeof(state_t_m) == mdlen ? 136 : 200 - 2 * mdlen; > rsizw = rsiz / 8; > memset(&st[0], 0, 25*sizeof(st[0])); > > > for ( ; inlen >= rsiz; inlen -= rsiz, in += rsiz) > { > for (size_t i = 0; i < rsizw; i++) > st[i] ^= ((uint64_t *) in)[i]; > > for(size_t ll = 0; ll != 24; ll++) > { > if(ll != 0) > { > mixin_t mix_in; > cb(st, mix_in); > for (size_t k = 0; k < 24; k++) > st[k] ^= mix_in[k]; > } > f_traits::keccakf(st, 1); > } > } > > > memcpy(temp, in, inlen); > temp[inlen++] = 1; > memset(temp + inlen, 0, rsiz - inlen); > temp[rsiz - 1] |= 0x80; > > for (size_t i = 0; i < rsizw; i++) > st[i] ^= ((uint64_t *) temp)[i]; > > > for(size_t ll = 0; ll != 24; ll++) > { > if(ll != 0) > { > mixin_t mix_in; > cb(st, mix_in); > for (size_t k = 0; k < 24; k++) > st[k] ^= mix_in[k]; > } > f_traits::keccakf(st, 1); > } > > memcpy(md, st, mdlen); > > return 0; > } > > template<class f_traits, class callback_t> > int wild_keccak_dbl(const uint8_t *in, size_t inlen, uint8_t *md, int mdlen, callback_t cb) > { > > wild_keccak<f_traits>(in, inlen, md, mdlen, cb); > wild_keccak<f_traits>(md, mdlen, md, mdlen, cb); > return 0; > } > > class regular_f > { > public: > static void keccakf(uint64_t st[25], int rounds); > }; > > class mul_f > { > public: > static void keccakf(uint64_t st[25], int rounds); > }; >} ># 14 "/c/honeypenny/src/currency_core/currency_format_utils.h" 2 > >namespace currency >{ > > struct tx_source_entry > { > typedef std::pair<uint64_t, crypto::public_key> output_entry; > > std::vector<output_entry> outputs; > uint64_t real_output; > crypto::public_key real_out_tx_key; > size_t real_output_in_tx_index; > uint64_t amount; > }; > > struct tx_destination_entry > { > uint64_t amount; > account_public_address addr; > > tx_destination_entry() : amount(0), addr(boost::value_initialized<decltype(addr)>()) { } > tx_destination_entry(uint64_t a, const account_public_address &ad) : amount(a), addr(ad) { } > }; > > struct alias_info_base > { > account_public_address m_address; > crypto::secret_key m_view_key; > crypto::signature m_sign; > std::string m_text_comment; > }; > > struct alias_info: public alias_info_base > { > std::string m_alias; > }; > > struct tx_extra_info > { > crypto::public_key m_tx_pub_key; > alias_info m_alias; > }; > > > void get_transaction_prefix_hash(const transaction_prefix& tx, crypto::hash& h); > crypto::hash get_transaction_prefix_hash(const transaction_prefix& tx); > bool parse_and_validate_tx_from_blob(const blobdata& tx_blob, transaction& tx, crypto::hash& tx_hash, crypto::hash& tx_prefix_hash); > bool parse_and_validate_tx_from_blob(const blobdata& tx_blob, transaction& tx); > bool get_donation_accounts(account_keys &donation_acc, account_keys &royalty_acc); > bool construct_miner_tx(size_t height, size_t median_size, uint64_t already_generated_coins, > size_t current_block_size, > uint64_t fee, > const account_public_address &miner_address, > transaction& tx, > const blobdata& extra_nonce = blobdata(), > size_t max_outs = 11); > > bool construct_miner_tx(size_t height, size_t median_size, uint64_t already_generated_coins, > uint64_t already_donated_coins, > size_t current_block_size, > uint64_t fee, > const account_public_address &miner_address, > const account_public_address &donation_address, > const account_public_address &royalty_address, > transaction& tx, > const blobdata& extra_nonce = blobdata(), > size_t max_outs = 11, > size_t percents_to_donate = 0, > const alias_info& alias = alias_info() > ); > > bool construct_tx_out(const account_public_address& destination_addr, const crypto::secret_key& tx_sec_key, size_t output_index, uint64_t amount, transaction& tx, uint8_t tx_outs_attr = 0); > bool construct_tx(const account_keys& sender_account_keys, const std::vector<tx_source_entry>& sources, const std::vector<tx_destination_entry>& destinations, transaction& tx, uint64_t unlock_time, uint8_t tx_outs_attr = 0); > bool sign_update_alias(alias_info& ai, const crypto::public_key& pkey, const crypto::secret_key& skey); > bool make_tx_extra_alias_entry(std::string& buff, const alias_info& alinfo, bool make_buff_to_sign = false); > bool add_tx_extra_alias(transaction& tx, const alias_info& alinfo); > bool parse_and_validate_tx_extra(const transaction& tx, tx_extra_info& extra); > bool parse_and_validate_tx_extra(const transaction& tx, crypto::public_key& tx_pub_key); > crypto::public_key get_tx_pub_key_from_extra(const transaction& tx); > bool add_tx_pub_key_to_extra(transaction& tx, const crypto::public_key& tx_pub_key); > bool add_tx_extra_nonce(transaction& tx, const blobdata& extra_nonce); > bool is_out_to_acc(const account_keys& acc, const txout_to_key& out_key, const crypto::public_key& tx_pub_key, size_t output_index); > bool lookup_acc_outs(const account_keys& acc, const transaction& tx, const crypto::public_key& tx_pub_key, std::vector<size_t>& outs, uint64_t& money_transfered); > bool lookup_acc_outs(const account_keys& acc, const transaction& tx, std::vector<size_t>& outs, uint64_t& money_transfered); > bool get_tx_fee(const transaction& tx, uint64_t & fee); > uint64_t get_tx_fee(const transaction& tx); > bool generate_key_image_helper(const account_keys& ack, const crypto::public_key& tx_public_key, size_t real_output_index, keypair& in_ephemeral, crypto::key_image& ki); > void get_blob_hash(const blobdata& blob, crypto::hash& res); > crypto::hash get_blob_hash(const blobdata& blob); > std::string short_hash_str(const crypto::hash& h); > bool get_block_scratchpad_addendum(const block& b, std::vector<crypto::hash>& res); > bool get_scratchpad_patch(size_t global_start_entry, size_t local_start_entry, size_t local_end_entry, const std::vector<crypto::hash>& scratchpd, std::map<uint64_t, crypto::hash>& patch); > bool push_block_scratchpad_data(const block& b, std::vector<crypto::hash>& scratchpd); > bool push_block_scratchpad_data(size_t global_start_entry, const block& b, std::vector<crypto::hash>& scratchpd, std::map<uint64_t, crypto::hash>& patch); > bool pop_block_scratchpad_data(const block& b, std::vector<crypto::hash>& scratchpd); > bool apply_scratchpad_patch(std::vector<crypto::hash>& scratchpd, std::map<uint64_t, crypto::hash>& patch); > > crypto::hash get_transaction_hash(const transaction& t); > bool get_transaction_hash(const transaction& t, crypto::hash& res); > bool get_transaction_hash(const transaction& t, crypto::hash& res, size_t& blob_size); > blobdata get_block_hashing_blob(const block& b); > bool get_block_hash(const block& b, crypto::hash& res); > crypto::hash get_block_hash(const block& b); > bool generate_genesis_block(block& bl); > bool parse_and_validate_block_from_blob(const blobdata& b_blob, block& b); > bool get_inputs_money_amount(const transaction& tx, uint64_t& money); > uint64_t get_outs_money_amount(const transaction& tx); > bool check_inputs_types_supported(const transaction& tx); > bool check_outs_valid(const transaction& tx); > blobdata get_block_hashing_blob(const block& b); > bool parse_amount(uint64_t& amount, const std::string& str_amount); > > bool check_money_overflow(const transaction& tx); > bool check_outs_overflow(const transaction& tx); > bool check_inputs_overflow(const transaction& tx); > uint64_t get_block_height(const block& b); > std::vector<uint64_t> relative_output_offsets_to_absolute(const std::vector<uint64_t>& off); > std::vector<uint64_t> absolute_output_offsets_to_relative(const std::vector<uint64_t>& off); > std::string print_money(uint64_t amount); > std::string dump_scratchpad(const std::vector<crypto::hash>& scr); > std::string dump_patch(const std::map<uint64_t, crypto::hash>& patch); > > > > bool get_block_scratchpad_data(const block& b, std::string& res, uint64_t selector); > struct get_scratchpad_param > { > uint64_t selectors[4]; > }; > > template<typename callback_t> > bool make_scratchpad_from_selector(const get_scratchpad_param& prm, blobdata& bd, uint64_t height, callback_t get_blocks_accessor) > { > > if(!height) > { > bd = "GENESIS"; > return true; > } > > uint64_t index_a = prm.selectors[0]%height; > uint64_t index_b = prm.selectors[1]%height; > > > block ba = boost::value_initialized<decltype(ba)>(); > block bb = boost::value_initialized<decltype(bb)>(); > bool r = get_blocks_accessor(index_a, ba); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/currency_format_utils.h" << ":" << 161 << "|" << __FUNCTION__ << "|" << "Failed to get block \"a\" from block accessor, index=" << index_a << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > r = get_blocks_accessor(index_a, bb); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/currency_format_utils.h" << ":" << 163 << "|" << __FUNCTION__ << "|" << "Failed to get block \"b\" from block accessor, index=" << index_b << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > r = get_block_scratchpad_data(ba, bd, prm.selectors[2]); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/currency_format_utils.h" << ":" << 166 << "|" << __FUNCTION__ << "|" << "Failed to get_block_scratchpad_data for a, index=" << index_a << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > r = get_block_scratchpad_data(bb, bd, prm.selectors[3]); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/currency_format_utils.h" << ":" << 168 << "|" << __FUNCTION__ << "|" << "Failed to get_block_scratchpad_data for b, index=" << index_b << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > return true; > } > > template<typename callback_t> > bool get_blob_longhash(const blobdata& bd, crypto::hash& res, uint64_t height, callback_t accessor) > { > crypto::wild_keccak_dbl<crypto::mul_f>(reinterpret_cast<const uint8_t*>(bd.data()), bd.size(), reinterpret_cast<uint8_t*>(&res), sizeof(res), [&](crypto::state_t_m& st, crypto::mixin_t& mix) > { > if(!height) > { > memset(&mix, 0, sizeof(mix)); > return; > } > > for(size_t i = 0; i!=6; i++) > { > *(crypto::hash*)&mix[i*4] = crypto::xor_pod(accessor(st[i*4]), crypto::xor_pod(accessor(st[i*4+1]), crypto::xor_pod(accessor(st[i*4+2]), accessor(st[i*4+3])))); > } > }); > return true; > } > > template<typename callback_t> > bool get_block_longhash(const block& b, crypto::hash& res, uint64_t height, callback_t accessor) > { > blobdata bd = get_block_hashing_blob(b); > return get_blob_longhash(bd, res, height, accessor); > } > > template<typename callback_t> > crypto::hash get_block_longhash(const block& b, uint64_t height, callback_t cb) > { > crypto::hash p = null_hash; > get_block_longhash(b, p, height, cb); > return p; > } > > template<class t_object> > bool t_serializable_object_to_blob(const t_object& to, blobdata& b_blob) > { > std::stringstream ss; > binary_archive<true> ba(ss); > bool r = ::serialization::serialize(ba, const_cast<t_object&>(to)); > b_blob = ss.str(); > return r; > } > > template<class t_object> > blobdata t_serializable_object_to_blob(const t_object& to) > { > blobdata b; > t_serializable_object_to_blob(to, b); > return b; > } > > template<class t_object> > bool get_object_hash(const t_object& o, crypto::hash& res) > { > get_blob_hash(t_serializable_object_to_blob(o), res); > return true; > } > > template<class t_object> > size_t get_object_blobsize(const t_object& o) > { > blobdata b = t_serializable_object_to_blob(o); > return b.size(); > } > > template<class t_object> > bool get_object_hash(const t_object& o, crypto::hash& res, size_t& blob_size) > { > blobdata bl = t_serializable_object_to_blob(o); > blob_size = bl.size(); > get_blob_hash(bl, res); > return true; > } > > template <typename T> > std::string obj_to_json_str(T& obj) > { > std::stringstream ss; > json_archive<true> ar(ss, true); > bool r = ::serialization::serialize(ar, obj); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/currency_format_utils.h" << ":" << 253 << "|" << __FUNCTION__ << "|" << "obj_to_json_str failed: serialization::serialize returned false" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return "";};}while(0); > return ss.str(); > } > > > template<typename chunk_handler_t, typename dust_handler_t> > void decompose_amount_into_digits(uint64_t amount, uint64_t dust_threshold, const chunk_handler_t& chunk_handler, const dust_handler_t& dust_handler) > { > if (0 == amount) > { > return; > } > > bool is_dust_handled = false; > uint64_t dust = 0; > uint64_t order = 1; > while (0 != amount) > { > uint64_t chunk = (amount % 10) * order; > amount /= 10; > order *= 10; > > if (dust + chunk <= dust_threshold) > { > dust += chunk; > } > else > { > if (!is_dust_handled && 0 != dust) > { > dust_handler(dust); > is_dust_handled = true; > } > if (0 != chunk) > { > chunk_handler(chunk); > } > } > } > > if (!is_dust_handled && 0 != dust) > { > dust_handler(dust); > } > } > > blobdata block_to_blob(const block& b); > bool block_to_blob(const block& b, blobdata& b_blob); > blobdata tx_to_blob(const transaction& b); > bool tx_to_blob(const transaction& b, blobdata& b_blob); > void get_tx_tree_hash(const std::vector<crypto::hash>& tx_hashes, crypto::hash& h); > crypto::hash get_tx_tree_hash(const std::vector<crypto::hash>& tx_hashes); > crypto::hash get_tx_tree_hash(const block& b); > > > > > >} ># 24 "/c/honeypenny/src/currency_core/blockchain_storage.h" 2 > > ># 1 "/c/honeypenny/src/currency_core/checkpoints.h" 1 ># 10 "/c/honeypenny/src/currency_core/checkpoints.h" >namespace currency >{ > class checkpoints > { > public: > checkpoints(); > bool add_checkpoint(uint64_t height, const std::string& hash_str); > bool is_in_checkpoint_zone(uint64_t height) const; > bool check_block(uint64_t height, const crypto::hash& h) const; > private: > std::map<uint64_t, crypto::hash> m_points; > }; >} ># 27 "/c/honeypenny/src/currency_core/blockchain_storage.h" 2 > >namespace currency >{ > > > > > class blockchain_storage > { > public: > struct transaction_chain_entry > { > transaction tx; > uint64_t m_keeper_block_height; > size_t m_blob_size; > std::vector<uint64_t> m_global_output_indexes; > }; > > struct block_extended_info > { > block bl; > uint64_t height; > size_t block_cumulative_size; > difficulty_type cumulative_difficulty; > uint64_t already_generated_coins; > uint64_t already_donated_coins; > uint64_t scratch_offset; > }; > > blockchain_storage(tx_memory_pool& tx_pool); > > bool init() { return init(tools::get_default_data_dir()); } > bool init(const std::string& config_folder); > bool deinit(); > > void set_checkpoints(checkpoints&& chk_pts) { m_checkpoints = chk_pts; } > > > bool get_blocks(uint64_t start_offset, size_t count, std::list<block>& blocks, std::list<transaction>& txs); > bool get_blocks(uint64_t start_offset, size_t count, std::list<block>& blocks); > bool get_alternative_blocks(std::list<block>& blocks); > size_t get_alternative_blocks_count(); > crypto::hash get_block_id_by_height(uint64_t height); > bool get_block_by_hash(const crypto::hash &h, block &blk); > bool get_block_by_height(uint64_t h, block &blk); > void get_all_known_block_ids(std::list<crypto::hash> &main, std::list<crypto::hash> &alt, std::list<crypto::hash> &invalid); > > template<class archive_t> > void serialize(archive_t & ar, const unsigned int version); > > bool have_tx(const crypto::hash &id); > bool have_tx_keyimges_as_spent(const transaction &tx); > bool have_tx_keyimg_as_spent(const crypto::key_image &key_im); > transaction *get_tx(const crypto::hash &id); > > template<class visitor_t> > bool scan_outputkeys_for_indexes(const txin_to_key& tx_in_to_key, visitor_t& vis, uint64_t* pmax_related_block_height = __null); > > uint64_t get_current_blockchain_height(); > crypto::hash get_top_block_id(); > crypto::hash get_top_block_id(uint64_t& height); > bool get_top_block(block& b); > difficulty_type get_difficulty_for_next_block(); > bool add_new_block(const block& bl_, block_verification_context& bvc); > bool reset_and_set_genesis_block(const block& b); > bool create_block_template(block& b, const account_public_address& miner_address, difficulty_type& di, uint64_t& height, const blobdata& ex_nonce, size_t percents_to_donate, const alias_info& ai); > bool have_block(const crypto::hash& id); > size_t get_total_transactions(); > bool get_outs(uint64_t amount, std::list<crypto::public_key>& pkeys); > bool get_short_chain_history(std::list<crypto::hash>& ids); > bool find_blockchain_supplement(const std::list<crypto::hash>& qblock_ids, NOTIFY_RESPONSE_CHAIN_ENTRY::request& resp); > bool find_blockchain_supplement(const std::list<crypto::hash>& qblock_ids, uint64_t& starter_offset); > bool find_blockchain_supplement(const std::list<crypto::hash>& qblock_ids, std::list<std::pair<block, std::list<transaction> > >& blocks, uint64_t& total_height, uint64_t& start_height, size_t max_count); > bool handle_get_objects(NOTIFY_REQUEST_GET_OBJECTS::request& arg, NOTIFY_RESPONSE_GET_OBJECTS::request& rsp); > bool handle_get_objects(const COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::request& req, COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::response& res); > bool get_random_outs_for_amounts(const COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::request& req, COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::response& res); > bool get_backward_blocks_sizes(size_t from_height, std::vector<size_t>& sz, size_t count); > bool get_tx_outputs_gindexs(const crypto::hash& tx_id, std::vector<uint64_t>& indexs); > bool get_alias_info(const std::string& alias, alias_info_base& info); > bool get_all_aliases(std::list<alias_info>& aliases); > bool store_blockchain(); > bool check_tx_input(const txin_to_key& txin, const crypto::hash& tx_prefix_hash, const std::vector<crypto::signature>& sig, uint64_t* pmax_related_block_height = __null); > bool check_tx_inputs(const transaction& tx, const crypto::hash& tx_prefix_hash, uint64_t* pmax_used_block_height = __null); > bool check_tx_inputs(const transaction& tx, uint64_t* pmax_used_block_height = __null); > bool check_tx_inputs(const transaction& tx, uint64_t& pmax_used_block_height, crypto::hash& max_used_block_id); > uint64_t get_current_comulative_blocksize_limit(); > bool is_storing_blockchain(){return m_is_blockchain_storing;} > uint64_t block_difficulty(size_t i); > bool copy_scratchpad(std::vector<crypto::hash>& scr); > > template<class t_ids_container, class t_blocks_container, class t_missed_container> > bool get_blocks(const t_ids_container& block_ids, t_blocks_container& blocks, t_missed_container& missed_bs) > { > epee::critical_region_t<decltype(m_blockchain_lock)> critical_region_var(m_blockchain_lock); > > if (boost::foreach_detail_::auto_any_t _foreach_col122 = boost::foreach_detail_::contain( (block_ids) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((block_ids), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(block_ids) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(block_ids) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur122 = boost::foreach_detail_::begin( _foreach_col122 , (true ? 0 : boost::foreach_detail_::encode_type(block_ids, boost::foreach_detail_::is_const_(block_ids))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((block_ids), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(block_ids) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(block_ids) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end122 = boost::foreach_detail_::end( _foreach_col122 , (true ? 0 : boost::foreach_detail_::encode_type(block_ids, boost::foreach_detail_::is_const_(block_ids))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((block_ids), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(block_ids) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(block_ids) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue122 = true; _foreach_continue122 && !boost::foreach_detail_::done( _foreach_cur122 , _foreach_end122 , (true ? 0 : boost::foreach_detail_::encode_type(block_ids, boost::foreach_detail_::is_const_(block_ids)))); _foreach_continue122 ? boost::foreach_detail_::next( _foreach_cur122 , (true ? 0 : boost::foreach_detail_::encode_type(block_ids, boost::foreach_detail_::is_const_(block_ids)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue122)) {} else for (const auto& bl_id = boost::foreach_detail_::deref( _foreach_cur122 , (true ? 0 : boost::foreach_detail_::encode_type(block_ids, boost::foreach_detail_::is_const_(block_ids)))); !_foreach_continue122; _foreach_continue122 = true) > { > auto it = m_blocks_index.find(bl_id); > if(it == m_blocks_index.end()) > missed_bs.push_back(bl_id); > else > { > do{if(!(it->second < m_blocks.size())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/src/currency_core/blockchain_storage.h" ># 129 "/c/honeypenny/src/currency_core/blockchain_storage.h" > << ":" << > 130 ># 129 "/c/honeypenny/src/currency_core/blockchain_storage.h" > << "|" << __FUNCTION__ << "|" << "Internal error: bl_id=" << string_tools::pod_to_hex(bl_id) << " have index record with offset="<<it->second<< ", bigger then m_blocks.size()=" << m_blocks.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0) > ; > blocks.push_back(m_blocks[it->second].bl); > } > } > return true; > } > > template<class t_ids_container, class t_tx_container, class t_missed_container> > bool get_transactions(const t_ids_container& txs_ids, t_tx_container& txs, t_missed_container& missed_txs) > { > epee::critical_region_t<decltype(m_blockchain_lock)> critical_region_var(m_blockchain_lock); > > if (boost::foreach_detail_::auto_any_t _foreach_col142 = boost::foreach_detail_::contain( (txs_ids) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((txs_ids), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(txs_ids) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(txs_ids) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur142 = boost::foreach_detail_::begin( _foreach_col142 , (true ? 0 : boost::foreach_detail_::encode_type(txs_ids, boost::foreach_detail_::is_const_(txs_ids))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((txs_ids), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(txs_ids) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(txs_ids) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end142 = boost::foreach_detail_::end( _foreach_col142 , (true ? 0 : boost::foreach_detail_::encode_type(txs_ids, boost::foreach_detail_::is_const_(txs_ids))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((txs_ids), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(txs_ids) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(txs_ids) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue142 = true; _foreach_continue142 && !boost::foreach_detail_::done( _foreach_cur142 , _foreach_end142 , (true ? 0 : boost::foreach_detail_::encode_type(txs_ids, boost::foreach_detail_::is_const_(txs_ids)))); _foreach_continue142 ? boost::foreach_detail_::next( _foreach_cur142 , (true ? 0 : boost::foreach_detail_::encode_type(txs_ids, boost::foreach_detail_::is_const_(txs_ids)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue142)) {} else for (const auto& tx_id = boost::foreach_detail_::deref( _foreach_cur142 , (true ? 0 : boost::foreach_detail_::encode_type(txs_ids, boost::foreach_detail_::is_const_(txs_ids)))); !_foreach_continue142; _foreach_continue142 = true) > { > auto it = m_transactions.find(tx_id); > if(it == m_transactions.end()) > { > transaction tx; > if(!m_tx_pool.get_transaction(tx_id, tx)) > missed_txs.push_back(tx_id); > else > txs.push_back(tx); > } > else > txs.push_back(it->second.tx); > } > return true; > } > > void print_blockchain(uint64_t start_index, uint64_t end_index); > void print_blockchain_index(); > void print_blockchain_outs(const std::string& file); > > private: > typedef std::unordered_map<crypto::hash, size_t> blocks_by_id_index; > typedef std::unordered_map<crypto::hash, transaction_chain_entry> transactions_container; > typedef std::unordered_set<crypto::key_image> key_images_container; > typedef std::vector<block_extended_info> blocks_container; > typedef std::unordered_map<crypto::hash, block_extended_info> blocks_ext_by_hash; > typedef std::unordered_map<crypto::hash, block> blocks_by_hash; > typedef std::map<uint64_t, std::vector<std::pair<crypto::hash, size_t>>> outputs_container; > typedef std::map<std::string, std::list<alias_info_base>> aliases_container; > > tx_memory_pool& m_tx_pool; > critical_section m_blockchain_lock; > > > blocks_container m_blocks; > blocks_by_id_index m_blocks_index; > transactions_container m_transactions; > key_images_container m_spent_keys; > size_t m_current_block_cumul_sz_limit; > > > > blocks_ext_by_hash m_alternative_chains; > > > blocks_ext_by_hash m_invalid_blocks; > outputs_container m_outputs; > aliases_container m_aliases; > std::vector<crypto::hash> m_scratchpad; > > std::string m_config_folder; > checkpoints m_checkpoints; > std::atomic<bool> m_is_in_checkpoint_zone; > std::atomic<bool> m_is_blockchain_storing; > > account_keys m_donations_account; > account_keys m_royalty_account; > > bool switch_to_alternative_blockchain(std::list<blocks_ext_by_hash::iterator>& alt_chain); > bool pop_block_from_blockchain(); > bool purge_block_data_from_blockchain(const block& b, size_t processed_tx_count); > bool purge_transaction_from_blockchain(const crypto::hash& tx_id); > bool purge_transaction_keyimages_from_blockchain(const transaction& tx, bool strict_check); > > bool handle_block_to_main_chain(const block& bl, block_verification_context& bvc); > bool handle_block_to_main_chain(const block& bl, const crypto::hash& id, block_verification_context& bvc); > bool handle_alternative_block(const block& b, const crypto::hash& id, block_verification_context& bvc); > difficulty_type get_next_difficulty_for_alternative_chain(const std::list<blocks_ext_by_hash::iterator>& alt_chain, block_extended_info& bei); > bool prevalidate_miner_transaction(const block& b, uint64_t height); > bool validate_miner_transaction(const block& b, size_t cumulative_block_size, uint64_t fee, uint64_t& base_reward, uint64_t already_generated_coins, uint64_t already_donated_coins, uint64_t& donation_total); > bool validate_transaction(const block& b, uint64_t height, const transaction& tx); > bool rollback_blockchain_switching(std::list<block>& original_chain, size_t rollback_height); > bool add_transaction_from_block(const transaction& tx, const crypto::hash& tx_id, const crypto::hash& bl_id, uint64_t bl_height); > bool push_transaction_to_global_outs_index(const transaction& tx, const crypto::hash& tx_id, std::vector<uint64_t>& global_indexes); > bool pop_transaction_from_global_index(const transaction& tx, const crypto::hash& tx_id); > bool get_last_n_blocks_sizes(std::vector<size_t>& sz, size_t count); > bool add_out_to_get_random_outs(std::vector<std::pair<crypto::hash, size_t> >& amount_outs, COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::outs_for_amount& result_outs, uint64_t amount, size_t i, uint64_t mix_count, bool use_only_forced_to_mix = false); > bool is_tx_spendtime_unlocked(uint64_t unlock_time); > bool add_block_as_invalid(const block& bl, const crypto::hash& h); > bool add_block_as_invalid(const block_extended_info& bei, const crypto::hash& h); > size_t find_end_of_allowed_index(const std::vector<std::pair<crypto::hash, size_t> >& amount_outs); > bool check_block_timestamp_main(const block& b); > bool check_block_timestamp(std::vector<uint64_t> timestamps, const block& b); > uint64_t get_adjusted_time(); > bool complete_timestamps_vector(uint64_t start_height, std::vector<uint64_t>& timestamps); > bool update_next_comulative_size_limit(); > bool lookfor_donation(const transaction& tx, uint64_t& donation, uint64_t& royalty); > bool get_block_for_scratchpad_alt(uint64_t connection_height, uint64_t block_index, std::list<blockchain_storage::blocks_ext_by_hash::iterator>& alt_chain, block & b); > bool process_blockchain_tx_extra(const transaction& tx); > bool unprocess_blockchain_tx_extra(const transaction& tx); > bool pop_alias_info(const alias_info& ai); > bool put_alias_info(const alias_info& ai); > bool validate_donations_value(uint64_t donation, uint64_t royalty); > > bool get_required_donations_value_for_next_block(uint64_t& don_am); > }; ># 247 "/c/honeypenny/src/currency_core/blockchain_storage.h" > template<class archive_t> > void blockchain_storage::serialize(archive_t & ar, const unsigned int version) > { > if(version < 14) > return; > std::string project_name = "forceberry""_testnet"; ar & project_name; if(project_name != "forceberry""_testnet") {throw std::runtime_error(std::string("wrong storage file: project name in file: ") + project_name + ", expected: " + "forceberry""_testnet" );}; > epee::critical_region_t<decltype(m_blockchain_lock)> critical_region_var(m_blockchain_lock); > ar & m_blocks; > ar & m_blocks_index; > ar & m_transactions; > ar & m_spent_keys; > ar & m_alternative_chains; > ar & m_outputs; > ar & m_invalid_blocks; > ar & m_current_block_cumul_sz_limit; > ar & m_aliases; > ar & m_scratchpad; > > > uint64_t total_check_count = m_blocks.size() + m_blocks_index.size() + m_transactions.size() + m_spent_keys.size() + m_alternative_chains.size() + m_outputs.size() + m_invalid_blocks.size() + m_current_block_cumul_sz_limit; > if(archive_t::is_saving::value) > { > ar & total_check_count; > }else > { > uint64_t total_check_count_loaded = 0; > ar & total_check_count_loaded; > if(total_check_count != total_check_count_loaded) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/blockchain_storage.h" << ":" << 276 << "|" << __FUNCTION__ << "|" << "Blockchain storage data corruption detected. total_count loaded from file = " << total_check_count_loaded << ", expected = " << total_check_count << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Blockchain storage:" << std::endl << "m_blocks: " << m_blocks.size() << std::endl << "m_blocks_index: " << m_blocks_index.size() << std::endl << "m_transactions: " << m_transactions.size() << std::endl << "m_spent_keys: " << m_spent_keys.size() << std::endl << "m_alternative_chains: " << m_alternative_chains.size() << std::endl << "m_outputs: " << m_outputs.size() << std::endl << "m_invalid_blocks: " << m_invalid_blocks.size() << std::endl << "m_current_block_cumul_sz_limit: " << m_current_block_cumul_sz_limit << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}} > > > > > > > > ; > > throw std::runtime_error("Blockchain data corruption"); > } > } > > > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Blockchain storage:" << std::endl << "m_blocks: " << m_blocks.size() << std::endl << "m_blocks_index: " << m_blocks_index.size() << std::endl << "m_transactions: " << m_transactions.size() << std::endl << "m_spent_keys: " << m_spent_keys.size() << std::endl << "m_alternative_chains: " << m_alternative_chains.size() << std::endl << "m_outputs: " << m_outputs.size() << std::endl << "m_invalid_blocks: " << m_invalid_blocks.size() << std::endl << "m_current_block_cumul_sz_limit: " << m_current_block_cumul_sz_limit << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}} > > > > > > > > ; > } > > > template<class visitor_t> > bool blockchain_storage::scan_outputkeys_for_indexes(const txin_to_key& tx_in_to_key, visitor_t& vis, uint64_t* pmax_related_block_height) > { > epee::critical_region_t<decltype(m_blockchain_lock)> critical_region_var(m_blockchain_lock); > auto it = m_outputs.find(tx_in_to_key.amount); > if(it == m_outputs.end() || !tx_in_to_key.key_offsets.size()) > return false; > > std::vector<uint64_t> absolute_offsets = relative_output_offsets_to_absolute(tx_in_to_key.key_offsets); > > > std::vector<std::pair<crypto::hash, size_t> >& amount_outs_vec = it->second; > size_t count = 0; > if (boost::foreach_detail_::auto_any_t _foreach_col318 = boost::foreach_detail_::contain( (absolute_offsets) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((absolute_offsets), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(absolute_offsets) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(absolute_offsets) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur318 = boost::foreach_detail_::begin( _foreach_col318 , (true ? 0 : boost::foreach_detail_::encode_type(absolute_offsets, boost::foreach_detail_::is_const_(absolute_offsets))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((absolute_offsets), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(absolute_offsets) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(absolute_offsets) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end318 = boost::foreach_detail_::end( _foreach_col318 , (true ? 0 : boost::foreach_detail_::encode_type(absolute_offsets, boost::foreach_detail_::is_const_(absolute_offsets))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((absolute_offsets), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(absolute_offsets) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(absolute_offsets) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue318 = true; _foreach_continue318 && !boost::foreach_detail_::done( _foreach_cur318 , _foreach_end318 , (true ? 0 : boost::foreach_detail_::encode_type(absolute_offsets, boost::foreach_detail_::is_const_(absolute_offsets)))); _foreach_continue318 ? boost::foreach_detail_::next( _foreach_cur318 , (true ? 0 : boost::foreach_detail_::encode_type(absolute_offsets, boost::foreach_detail_::is_const_(absolute_offsets)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue318)) {} else for (uint64_t i = boost::foreach_detail_::deref( _foreach_cur318 , (true ? 0 : boost::foreach_detail_::encode_type(absolute_offsets, boost::foreach_detail_::is_const_(absolute_offsets)))); !_foreach_continue318; _foreach_continue318 = true) > { > if(i >= amount_outs_vec.size() ) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Wrong index in transaction inputs: " << i << ", expected maximum " << amount_outs_vec.size() - 1 << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return false; > } > transactions_container::iterator tx_it = m_transactions.find(amount_outs_vec[i].first); > do{if(!(tx_it != m_transactions.end())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/blockchain_storage.h" << ":" << 326 << "|" << __FUNCTION__ << "|" << "Wrong transaction id in output indexes: " <<string_tools::pod_to_hex(amount_outs_vec[i].first) << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > do{if(!(amount_outs_vec[i].second < tx_it->second.tx.vout.size())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/src/currency_core/blockchain_storage.h" ># 327 "/c/honeypenny/src/currency_core/blockchain_storage.h" > << ":" << > 328 ># 327 "/c/honeypenny/src/currency_core/blockchain_storage.h" > << "|" << __FUNCTION__ << "|" << "Wrong index in transaction outputs: " << amount_outs_vec[i].second << ", expected less then " << tx_it->second.tx.vout.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0) > ; > > > do{if(!(tx_it->second.tx.vout[amount_outs_vec[i].second].target.type() == typeid(const txout_to_key))) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/blockchain_storage.h" << ":" << 331 << "|" << __FUNCTION__ << "|" << "wrong variant type: " << tx_it->second.tx.vout[amount_outs_vec[i].second].target.type().name() << ", expected " << typeid(const txout_to_key).name() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); const txout_to_key& outtk = boost::get<const txout_to_key>(tx_it->second.tx.vout[amount_outs_vec[i].second].target);; > if(outtk.mix_attr > 1) > do{if(!(tx_in_to_key.key_offsets.size() >= outtk.mix_attr)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/blockchain_storage.h" << ":" << 333 << "|" << __FUNCTION__ << "|" << "transaction out[" << count << "] is marked to be used minimum with " << outtk.mix_attr << "parts in ring signature, but input used only " << tx_in_to_key.key_offsets.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > else if(outtk.mix_attr == 1) > do{if(!(tx_in_to_key.key_offsets.size() == 1)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/blockchain_storage.h" << ":" << 335 << "|" << __FUNCTION__ << "|" << "transaction out[" << count << "] is marked to be used minimum with " << outtk.mix_attr << "parts in ring signature, but input used is " << tx_in_to_key.key_offsets.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > if(!vis.handle_output(tx_it->second.tx, tx_it->second.tx.vout[amount_outs_vec[i].second])) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to handle_output for output no = " << count << ", with absolute offset " << i << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return false; > } > if(count++ == absolute_offsets.size()-1 && pmax_related_block_height) > { > if(*pmax_related_block_height < tx_it->second.m_keeper_block_height) > *pmax_related_block_height = tx_it->second.m_keeper_block_height; > } > } > > return true; > } >} > > > >namespace boost { namespace serialization { template<> struct version<currency::blockchain_storage > { typedef mpl::int_<14> type; typedef mpl::integral_c_tag tag; static const int value = version::type::value; enum { mpl_assertion_in_line_355 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) ( boost::mpl::less< boost::mpl::int_<14>, boost::mpl::int_<256> > ))0, 1 ) ) ) }; }; } } ># 16 "/c/honeypenny/src/currency_core/currency_core.h" 2 ># 1 "/c/honeypenny/src/currency_core/miner.h" 1 ># 9 "/c/honeypenny/src/currency_core/miner.h" ># 1 "/usr/include/boost/program_options.hpp" 1 3 4 ># 16 "/usr/include/boost/program_options.hpp" 3 4 ># 1 "/usr/include/boost/program_options/positional_options.hpp" 1 3 4 ># 19 "/usr/include/boost/program_options/positional_options.hpp" 3 4 >namespace boost { namespace program_options { ># 36 "/usr/include/boost/program_options/positional_options.hpp" 3 4 > class positional_options_description { > public: > positional_options_description(); > > > > > > > positional_options_description& > add(const char* name, int max_count); > > > > > unsigned max_total_count() const; > > > > > > const std::string& name_for_position(unsigned position) const; > > private: > > > > std::vector<std::string> m_names; > std::string m_trailing; > }; > >}} ># 17 "/usr/include/boost/program_options.hpp" 2 3 4 ># 1 "/usr/include/boost/program_options/parsers.hpp" 1 3 4 ># 11 "/usr/include/boost/program_options/parsers.hpp" 3 4 ># 1 "/usr/include/boost/program_options/option.hpp" 1 3 4 ># 14 "/usr/include/boost/program_options/option.hpp" 3 4 >namespace boost { namespace program_options { ># 23 "/usr/include/boost/program_options/option.hpp" 3 4 > template<class charT> > class basic_option { > public: > basic_option() > : position_key(-1) > , unregistered(false) > , case_insensitive(false) > {} > basic_option(const std::string& xstring_key, > const std::vector< std::string> &xvalue) > : string_key(xstring_key) > , value(xvalue) > , unregistered(false) > , case_insensitive(false) > {} > > > > std::string string_key; > > > > > > > int position_key; > > std::vector< std::basic_string<charT> > value; > > > std::vector< std::basic_string<charT> > original_tokens; > > > > > > bool unregistered; > > > > bool case_insensitive; > }; > typedef basic_option<char> option; > typedef basic_option<wchar_t> woption; > >}} ># 12 "/usr/include/boost/program_options/parsers.hpp" 2 3 4 ># 1 "/usr/include/boost/program_options/detail/cmdline.hpp" 1 3 4 ># 12 "/usr/include/boost/program_options/detail/cmdline.hpp" 3 4 ># 1 "/usr/include/boost/program_options/cmdline.hpp" 1 3 4 ># 9 "/usr/include/boost/program_options/cmdline.hpp" 3 4 >namespace boost { namespace program_options { namespace command_line_style { ># 26 "/usr/include/boost/program_options/cmdline.hpp" 3 4 > enum style_t { > > allow_long = 1, > > allow_short = allow_long << 1, > > allow_dash_for_short = allow_short << 1, > > allow_slash_for_short = allow_dash_for_short << 1, > > > > > > > long_allow_adjacent = allow_slash_for_short << 1, > > > long_allow_next = long_allow_adjacent << 1, > > > short_allow_adjacent = long_allow_next << 1, > > > short_allow_next = short_allow_adjacent << 1, > > > > > > > > allow_sticky = short_allow_next << 1, > > > > > > allow_guessing = allow_sticky << 1, > > > long_case_insensitive = allow_guessing << 1, > > > short_case_insensitive = long_case_insensitive << 1, > > > case_insensitive = (long_case_insensitive | short_case_insensitive), > > > > allow_long_disguise = short_case_insensitive << 1, > > unix_style = (allow_short | short_allow_adjacent | short_allow_next > | allow_long | long_allow_adjacent | long_allow_next > | allow_sticky | allow_guessing > | allow_dash_for_short), > > default_style = unix_style > }; >}}} ># 13 "/usr/include/boost/program_options/detail/cmdline.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/function.hpp" 1 3 4 ># 64 "/usr/include/boost/function.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 1 3 4 ># 24 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/lower1.hpp" 2 3 4 ># 25 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > ># 1 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 1 3 4 ># 12 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 3 4 ># 1 "/usr/include/boost/preprocessor/slot/detail/shared.hpp" 1 3 4 ># 13 "/usr/include/boost/preprocessor/iteration/detail/bounds/upper1.hpp" 2 3 4 ># 27 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 47 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 48 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 53 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 58 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 63 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 68 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 73 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 78 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 83 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 88 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 93 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/function/detail/function_iterate.hpp" 1 3 4 ># 14 "/usr/include/boost/function/detail/function_iterate.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 15 "/usr/include/boost/function/detail/function_iterate.hpp" 2 3 4 ># 98 "/usr/include/boost/preprocessor/iteration/detail/iter/forward1.hpp" 2 3 4 ># 65 "/usr/include/boost/function.hpp" 2 3 4 ># 21 "/usr/include/boost/program_options/detail/cmdline.hpp" 2 3 4 ># 30 "/usr/include/boost/program_options/detail/cmdline.hpp" 3 4 >namespace boost { namespace program_options { namespace detail { ># 59 "/usr/include/boost/program_options/detail/cmdline.hpp" 3 4 > class cmdline { > public: > > typedef ::boost::program_options::command_line_style::style_t style_t; > > typedef function1<std::pair<std::string, std::string>, > const std::string&> > additional_parser; > > typedef function1<std::vector<option>, std::vector<std::string>&> > style_parser; ># 78 "/usr/include/boost/program_options/detail/cmdline.hpp" 3 4 > cmdline(const std::vector<std::string>& args); > > > cmdline(int argc, const char*const * argv); > > void style(int style); ># 94 "/usr/include/boost/program_options/detail/cmdline.hpp" 3 4 > int get_canonical_option_prefix(); > > void allow_unregistered(); > > void set_options_description(const options_description& desc); > void set_positional_options( > const positional_options_description& m_positional); > > std::vector<option> run(); > > std::vector<option> parse_long_option(std::vector<std::string>& args); > std::vector<option> parse_short_option(std::vector<std::string>& args); > std::vector<option> parse_dos_option(std::vector<std::string>& args); > std::vector<option> parse_disguised_long_option( > std::vector<std::string>& args); > std::vector<option> parse_terminator( > std::vector<std::string>& args); > std::vector<option> handle_additional_parser( > std::vector<std::string>& args); ># 123 "/usr/include/boost/program_options/detail/cmdline.hpp" 3 4 > void set_additional_parser(additional_parser p); > > void extra_style_parser(style_parser s); > > void check_style(int style) const; > > bool is_style_active(style_t style) const; > > void init(const std::vector<std::string>& args); > > void > finish_option(option& opt, > std::vector<std::string>& other_tokens, > const std::vector<style_parser>& style_parsers); > > > std::vector<std::string> args; > style_t m_style; > bool m_allow_unregistered; > > const options_description* m_desc; > const positional_options_description* m_positional; > > additional_parser m_additional_parser; > style_parser m_style_parser; > }; > > void test_cmdline_detail(); > >}}} ># 13 "/usr/include/boost/program_options/parsers.hpp" 2 3 4 > ># 1 "/usr/include/boost/function/function1.hpp" 1 3 4 ># 11 "/usr/include/boost/function/function1.hpp" 3 4 ># 1 "/usr/include/boost/function/detail/maybe_include.hpp" 1 3 4 ># 12 "/usr/include/boost/function/function1.hpp" 2 3 4 ># 15 "/usr/include/boost/program_options/parsers.hpp" 2 3 4 ># 25 "/usr/include/boost/program_options/parsers.hpp" 3 4 >namespace boost { namespace program_options { > > class options_description; > class positional_options_description; > > > > > > > > template<class charT> > class basic_parsed_options { > public: > explicit basic_parsed_options(const options_description* xdescription, int options_prefix = 0) > : description(xdescription), m_options_prefix(options_prefix) {} > > std::vector< basic_option<charT> > options; > > > > > > const options_description* description; ># 59 "/usr/include/boost/program_options/parsers.hpp" 3 4 > int m_options_prefix; > }; > > > > > > template<> > class basic_parsed_options<wchar_t> { > public: > > explicit basic_parsed_options(const basic_parsed_options<char>& po); > > std::vector< basic_option<wchar_t> > options; > const options_description* description; > > > > basic_parsed_options<char> utf8_encoded_options; ># 88 "/usr/include/boost/program_options/parsers.hpp" 3 4 > int m_options_prefix; > }; > > typedef basic_parsed_options<char> parsed_options; > typedef basic_parsed_options<wchar_t> wparsed_options; > > > > > > typedef function1<std::pair<std::string, std::string>, const std::string&> ext_parser; ># 114 "/usr/include/boost/program_options/parsers.hpp" 3 4 > template<class charT> > class basic_command_line_parser : private detail::cmdline { > public: > > > > basic_command_line_parser(const std::vector< > std::basic_string<charT> >& args); > > > > basic_command_line_parser(int argc, const charT* const argv[]); > > > basic_command_line_parser& options(const options_description& desc); > > basic_command_line_parser& positional( > const positional_options_description& desc); > > > basic_command_line_parser& style(int); > > basic_command_line_parser& extra_parser(ext_parser); > > > > > basic_parsed_options<charT> run(); ># 151 "/usr/include/boost/program_options/parsers.hpp" 3 4 > basic_command_line_parser& allow_unregistered(); > > using detail::cmdline::style_parser; > > basic_command_line_parser& extra_style_parser(style_parser s); > > private: > const options_description* m_desc; > }; > > typedef basic_command_line_parser<char> command_line_parser; > typedef basic_command_line_parser<wchar_t> wcommand_line_parser; > > > > > template<class charT> > basic_parsed_options<charT> > parse_command_line(int argc, const charT* const argv[], > const options_description&, > int style = 0, > function1<std::pair<std::string, std::string>, > const std::string&> ext > = ext_parser()); > > > > > > template<class charT> > > > > basic_parsed_options<charT> > parse_config_file(std::basic_istream<charT>&, const options_description&, > bool allow_unregistered = false); > > > > > > > template<class charT> > > > > basic_parsed_options<charT> > parse_config_file(const char* filename, const options_description&, > bool allow_unregistered = false); > > > > enum collect_unrecognized_mode > { include_positional, exclude_positional }; > > > > > > > > template<class charT> > std::vector< std::basic_string<charT> > > collect_unrecognized(const std::vector< basic_option<charT> >& options, > enum collect_unrecognized_mode mode); ># 226 "/usr/include/boost/program_options/parsers.hpp" 3 4 > parsed_options > parse_environment(const options_description&, > const function1<std::string, std::string>& name_mapper); > > > > > > > > parsed_options > parse_environment(const options_description&, const std::string& prefix); > > > > > > > parsed_options > parse_environment(const options_description&, const char* prefix); ># 254 "/usr/include/boost/program_options/parsers.hpp" 3 4 > std::vector<std::string> > split_unix(const std::string& cmdline, const std::string& seperator = " \t", > const std::string& quote = "'\"", const std::string& escape = "\\"); > > > > std::vector<std::wstring> > split_unix(const std::wstring& cmdline, const std::wstring& seperator = L" \t", > const std::wstring& quote = L"'\"", const std::wstring& escape = L"\\"); ># 283 "/usr/include/boost/program_options/parsers.hpp" 3 4 >}} > > > > > > > ># 1 "/usr/include/boost/program_options/detail/parsers.hpp" 1 3 4 ># 9 "/usr/include/boost/program_options/detail/parsers.hpp" 3 4 ># 1 "/usr/include/boost/program_options/detail/convert.hpp" 1 3 4 ># 19 "/usr/include/boost/program_options/detail/convert.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cwchar" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cwchar" 3 4 ># 40 "/usr/include/c++/4.9.0/cwchar" 3 > > > > ># 1 "/usr/include/wchar.h" 1 3 4 ># 45 "/usr/include/c++/4.9.0/cwchar" 2 3 ># 20 "/usr/include/boost/program_options/detail/convert.hpp" 2 3 4 ># 30 "/usr/include/boost/program_options/detail/convert.hpp" 3 4 >namespace boost { > > > > std::wstring > from_8_bit(const std::string& s, > const std::codecvt<wchar_t, char, std::mbstate_t>& cvt); > > > > std::string > to_8_bit(const std::wstring& s, > const std::codecvt<wchar_t, char, std::mbstate_t>& cvt); > > > > > std::wstring > from_utf8(const std::string& s); > > > std::string > to_utf8(const std::wstring& s); > > > > std::string > to_local_8_bit(const std::wstring& s); > > > > std::wstring > from_local_8_bit(const std::string& s); > > namespace program_options > { > > > > > std::string to_internal(const std::string&); > > std::string to_internal(const std::wstring&); > > template<class T> > std::vector<std::string> to_internal(const std::vector<T>& s) > { > std::vector<std::string> result; > for (unsigned i = 0; i < s.size(); ++i) > result.push_back(to_internal(s[i])); > return result; > } > > } > > > >} ># 10 "/usr/include/boost/program_options/detail/parsers.hpp" 2 3 4 > > > >namespace boost { namespace program_options { > > namespace detail { > template<class charT, class Iterator> > std::vector<std::basic_string<charT> > > make_vector(Iterator i, Iterator e) > { > std::vector<std::basic_string<charT> > result; > > > for(; i != e; ++i) > result.push_back(*i); > return result; > } > } > > template<class charT> > basic_command_line_parser<charT>:: > basic_command_line_parser(const std::vector< > std::basic_string<charT> >& xargs) > : detail::cmdline(to_internal(xargs)) > {} > > > template<class charT> > basic_command_line_parser<charT>:: > basic_command_line_parser(int argc, const charT* const argv[]) > : detail::cmdline( > > > to_internal(detail::make_vector<charT, const charT* const*>(argv+1, argv+argc+!argc))) > {} > > > template<class charT> > basic_command_line_parser<charT>& > basic_command_line_parser<charT>::options(const options_description& desc) > { > detail::cmdline::set_options_description(desc); > m_desc = &desc; > return *this; > } > > template<class charT> > basic_command_line_parser<charT>& > basic_command_line_parser<charT>::positional( > const positional_options_description& desc) > { > detail::cmdline::set_positional_options(desc); > return *this; > } > > template<class charT> > basic_command_line_parser<charT>& > basic_command_line_parser<charT>::style(int xstyle) > { > detail::cmdline::style(xstyle); > return *this; > } > > template<class charT> > basic_command_line_parser<charT>& > basic_command_line_parser<charT>::extra_parser(ext_parser ext) > { > detail::cmdline::set_additional_parser(ext); > return *this; > } > > template<class charT> > basic_command_line_parser<charT>& > basic_command_line_parser<charT>::allow_unregistered() > { > detail::cmdline::allow_unregistered(); > return *this; > } > > template<class charT> > basic_command_line_parser<charT>& > basic_command_line_parser<charT>::extra_style_parser(style_parser s) > { > detail::cmdline::extra_style_parser(s); > return *this; > } > > > > template<class charT> > basic_parsed_options<charT> > basic_command_line_parser<charT>::run() > { > > > > > parsed_options result(m_desc, detail::cmdline::get_canonical_option_prefix()); > result.options = detail::cmdline::run(); > > > > return basic_parsed_options<charT>(result); > } > > > template<class charT> > basic_parsed_options<charT> > parse_command_line(int argc, const charT* const argv[], > const options_description& desc, > int style, > function1<std::pair<std::string, std::string>, > const std::string&> ext) > { > return basic_command_line_parser<charT>(argc, argv).options(desc). > style(style).extra_parser(ext).run(); > } > > template<class charT> > std::vector< std::basic_string<charT> > > collect_unrecognized(const std::vector< basic_option<charT> >& options, > enum collect_unrecognized_mode mode) > { > std::vector< std::basic_string<charT> > result; > for(unsigned i = 0; i < options.size(); ++i) > { > if (options[i].unregistered || > (mode == include_positional && options[i].position_key != -1)) > { > copy(options[i].original_tokens.begin(), > options[i].original_tokens.end(), > back_inserter(result)); > } > } > return result; > } > > >}} ># 292 "/usr/include/boost/program_options/parsers.hpp" 2 3 4 ># 18 "/usr/include/boost/program_options.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/program_options/version.hpp" 1 3 4 ># 24 "/usr/include/boost/program_options.hpp" 2 3 4 ># 10 "/c/honeypenny/src/currency_core/miner.h" 2 > > > ># 1 "/c/honeypenny/contrib/epee/include/math_helper.h" 1 ># 30 "/c/honeypenny/contrib/epee/include/math_helper.h" > > > > > ># 1 "/usr/include/boost/timer.hpp" 1 3 4 ># 21 "/usr/include/boost/timer.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/ctime" 1 3 4 ># 39 "/usr/include/c++/4.9.0/ctime" 3 4 ># 40 "/usr/include/c++/4.9.0/ctime" 3 ># 22 "/usr/include/boost/timer.hpp" 2 3 4 > > > > > > > >namespace boost { ># 44 "/usr/include/boost/timer.hpp" 3 4 >class timer >{ > public: > timer() { _start_time = std::clock(); } > > > > void restart() { _start_time = std::clock(); } > double elapsed() const > { return double(std::clock() - _start_time) / 1000000l; } > > double elapsed_max() const > > > { > return (double((std::numeric_limits<std::clock_t>::max)()) > - double(_start_time)) / double(1000000l); > } > > double elapsed_min() const > { return double(1)/double(1000000l); } > > private: > std::clock_t _start_time; >}; > >} ># 36 "/c/honeypenny/contrib/epee/include/math_helper.h" 2 > > > > > >namespace epee >{ >namespace math_helper >{ > > template<typename val, int default_base> > class average > { > public: > > average() > { > m_base = default_base; > m_last_avg_val = 0; > } > > bool set_base() > { > epee::critical_region_t<decltype(m_lock)> critical_region_var(m_lock); > > m_base = default_base; > if(m_list.size() > m_base) > m_list.resize(m_base); > > return true; > } > > typedef val value_type; > > void push(const value_type& vl) > { > epee::critical_region_t<decltype(m_lock)> critical_region_var(m_lock); > > > m_list.push_back(vl); > if(m_list.size() > m_base ) > m_list.pop_front(); > > } > > double update(const value_type& vl) > { > epee::critical_region_t<decltype(m_lock)> critical_region_var(m_lock); > > push(vl); > > > return get_avg(); > } > > double get_avg() > { > epee::critical_region_t<decltype(m_lock)> critical_region_var(m_lock); > > value_type vl = std::accumulate(m_list.begin(), m_list.end(), value_type(0)); > if(m_list.size()) > return m_last_avg_val = (double)(vl/m_list.size()); > > return m_last_avg_val = (double)vl; > } > > value_type get_last_val() > { > epee::critical_region_t<decltype(m_lock)> critical_region_var(m_lock); > if(m_list.size()) > return m_list.back(); > > return 0; > } > > private: > unsigned int m_base; > double m_last_avg_val; > std::list<value_type> m_list; > critical_section m_lock; > }; ># 157 "/c/honeypenny/contrib/epee/include/math_helper.h" > template<uint64_t default_time_window> > class speed > { > public: > > speed() > { > m_time_window = default_time_window; > m_last_speed_value = 0; > } > bool chick() > { > > uint64_t ticks = misc_utils::get_tick_count(); > { epee::critical_region_t<decltype(m_lock)> critical_region_var(m_lock); > m_chicks.push_back(ticks); > }; > > > return true; > } > > bool chick(size_t count) > { > for(size_t s = 0; s != count; s++) > chick(); > > return true; > } > > > size_t get_speed() > { > flush(misc_utils::get_tick_count()); > return m_last_speed_value = m_chicks.size(); > } > private: > > bool flush(uint64_t ticks) > { > { epee::critical_region_t<decltype(m_lock)> critical_region_var(m_lock); > std::list<uint64_t>::iterator it = m_chicks.begin(); > while(it != m_chicks.end()) > { > if(*it + m_time_window < ticks) > m_chicks.erase(it++); > else > break; > } > }; > return true; > } > > std::list<uint64_t> m_chicks; > uint64_t m_time_window; > size_t m_last_speed_value; > critical_section m_lock; > }; > > > template<class tlist> > void randomize_list(tlist& t_list) > { > for(typename tlist::iterator it = t_list.begin();it!=t_list.end();it++) > { > size_t offset = rand()%t_list.size(); > typename tlist::iterator it_2 = t_list.begin(); > for(size_t local_offset = 0;local_offset!=offset;local_offset++) > it_2++; > if(it_2 == it) > continue; > std::swap(*it_2, *it); > } > > } ># 232 "/c/honeypenny/contrib/epee/include/math_helper.h" >#pragma GCC diagnostic push ># 232 "/c/honeypenny/contrib/epee/include/math_helper.h" ># 233 "/c/honeypenny/contrib/epee/include/math_helper.h" >#pragma GCC diagnostic ignored "-Wstrict-aliasing" ># 233 "/c/honeypenny/contrib/epee/include/math_helper.h" > > inline > uint64_t generated_random_uint64() > { > boost::uuids::uuid id___ = boost::uuids::random_generator()(); > return *reinterpret_cast<uint64_t*>(&id___.data[0]); > } ># 240 "/c/honeypenny/contrib/epee/include/math_helper.h" >#pragma GCC diagnostic pop ># 240 "/c/honeypenny/contrib/epee/include/math_helper.h" > > template<int default_interval, bool start_immediate = true> > class once_a_time_seconds > { > public: > once_a_time_seconds():m_interval(default_interval) > { > m_last_worked_time = 0; > if(!start_immediate) > time(&m_last_worked_time); > } > > template<class functor_t> > bool do_call(functor_t functr) > { > time_t current_time = 0; > time(¤t_time); > > if(current_time - m_last_worked_time > m_interval) > { > bool res = functr(); > time(&m_last_worked_time); > return res; > } > return true; > } > > private: > time_t m_last_worked_time; > time_t m_interval; > }; >} >} ># 14 "/c/honeypenny/src/currency_core/miner.h" 2 > > >namespace currency >{ > > struct i_miner_handler > { > virtual bool handle_block_found(block& b) = 0; > virtual bool get_block_template(block& b, const account_public_address& adr, difficulty_type& diffic, uint64_t& height, const blobdata& ex_nonce, size_t percents_to_donate, const alias_info& ai) = 0; > protected: > ~i_miner_handler(){}; > }; > > > > > class miner > { > public: > miner(i_miner_handler* phandler, blockchain_storage& bc); > ~miner(); > bool init(const boost::program_options::variables_map& vm); > static void init_options(boost::program_options::options_description& desc); > bool set_block_template(const block& bl, const difficulty_type& diffic, uint64_t height); > bool on_block_chain_update(); > bool start(const account_public_address& adr, size_t threads_count); > uint64_t get_speed(); > void send_stop_signal(); > bool stop(); > bool is_mining(); > bool on_idle(); > void on_synchronized(); > > void pause(); > void resume(); > void do_print_hashrate(bool do_hr); > bool set_alias_info(const alias_info& ai); > > template<typename callback_t> > static bool find_nonce_for_given_block(block& bl, const difficulty_type& diffic, uint64_t height, callback_t scratch_accessor) > { > blobdata bd = get_block_hashing_blob(bl); > for(; bl.nonce != std::numeric_limits<uint32_t>::max(); bl.nonce++) > { > crypto::hash h; > *reinterpret_cast<uint32_t*>(&bd[1]) = bl.nonce; > get_blob_longhash(bd, h, height, scratch_accessor); > > if(check_hash(h, diffic)) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Found nonce for block: " << get_block_hash(bl) << "[" << height << "]: PoW:" << h << "(diff:" << diffic << ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return true; > } > } > return false; > } > > > > private: > bool worker_thread(); > bool request_block_template(); > void merge_hr(); > bool validate_alias_info(); > bool update_scratchpad(); > > struct miner_config > { > uint64_t current_extra_message_index; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/miner.h" << ":" << 84 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.current_extra_message_index, stg, hparent_section, "current_extra_message_index"); > return true;} > }; > > > volatile uint32_t m_stop; > ::critical_section m_template_lock; > block m_template; > std::atomic<uint32_t> m_template_no; > std::atomic<uint32_t> m_starter_nonce; > difficulty_type m_diffic; > uint64_t m_height; > volatile uint32_t m_thread_index; > volatile uint32_t m_threads_total; > std::atomic<int32_t> m_pausers_count; > ::critical_section m_miners_count_lock; > > std::list<boost::thread> m_threads; > ::critical_section m_threads_lock; > i_miner_handler* m_phandler; > blockchain_storage& m_bc; > account_public_address m_mine_address; > math_helper::once_a_time_seconds<5> m_update_block_template_interval; > math_helper::once_a_time_seconds<2> m_update_merge_hr_interval; > std::vector<blobdata> m_extra_messages; > miner_config m_config; > std::string m_config_folder_path; > std::atomic<uint64_t> m_current_hash_rate; > std::atomic<uint64_t> m_last_hr_merge_time; > std::atomic<uint64_t> m_hashes; > bool m_do_print_hashrate; > bool m_do_mining; > alias_info m_aliace_to_apply_in_block; > critical_section m_aliace_to_apply_in_block_lock; > bool m_do_donate; > std::vector<crypto::hash> m_scratchpad; > }; >} ># 17 "/c/honeypenny/src/currency_core/currency_core.h" 2 > ># 1 "/c/honeypenny/src/currency_core/currency_stat_info.h" 1 ># 9 "/c/honeypenny/src/currency_core/currency_stat_info.h" >namespace currency >{ > struct core_stat_info > { > uint64_t tx_pool_size; > uint64_t blockchain_height; > uint64_t mining_speed; > uint64_t alternative_blocks; > std::string top_block_id_str; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_core/currency_stat_info.h" << ":" << 19 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.tx_pool_size, stg, hparent_section, "tx_pool_size"); > epee::serialization::selector<is_store>::serialize(this_ref.blockchain_height, stg, hparent_section, "blockchain_height"); > epee::serialization::selector<is_store>::serialize(this_ref.mining_speed, stg, hparent_section, "mining_speed"); > epee::serialization::selector<is_store>::serialize(this_ref.alternative_blocks, stg, hparent_section, "alternative_blocks"); > epee::serialization::selector<is_store>::serialize(this_ref.top_block_id_str, stg, hparent_section, "top_block_id_str"); > return true;} > }; >} ># 19 "/c/honeypenny/src/currency_core/currency_core.h" 2 ># 22 "/c/honeypenny/src/currency_core/currency_core.h" >#pragma GCC diagnostic push ># 22 "/c/honeypenny/src/currency_core/currency_core.h" > > > >namespace currency >{ > > > > class core: public i_miner_handler > { > public: > core(i_currency_protocol* pprotocol); > bool handle_get_objects(NOTIFY_REQUEST_GET_OBJECTS::request& arg, NOTIFY_RESPONSE_GET_OBJECTS::request& rsp, currency_connection_context& context); > bool on_idle(); > bool handle_incoming_tx(const blobdata& tx_blob, tx_verification_context& tvc, bool keeped_by_block); > bool handle_incoming_block(const blobdata& block_blob, block_verification_context& bvc, bool update_miner_blocktemplate = true); > i_currency_protocol* get_protocol(){return m_pprotocol;} > > > virtual bool handle_block_found( block& b); > virtual bool get_block_template(block& b, const account_public_address& adr, difficulty_type& diffic, uint64_t& height, const blobdata& ex_nonce, size_t percents_to_donate, const alias_info& ai); > > > miner& get_miner(){return m_miner;} > static void init_options(boost::program_options::options_description& desc); > bool init(const boost::program_options::variables_map& vm); > bool set_genesis_block(const block& b); > bool deinit(); > uint64_t get_current_blockchain_height(); > bool get_blockchain_top(uint64_t& heeight, crypto::hash& top_id); > bool get_blocks(uint64_t start_offset, size_t count, std::list<block>& blocks, std::list<transaction>& txs); > bool get_blocks(uint64_t start_offset, size_t count, std::list<block>& blocks); > template<class t_ids_container, class t_blocks_container, class t_missed_container> > bool get_blocks(const t_ids_container& block_ids, t_blocks_container& blocks, t_missed_container& missed_bs) > { > return m_blockchain_storage.get_blocks(block_ids, blocks, missed_bs); > } > crypto::hash get_block_id_by_height(uint64_t height); > bool get_transactions(const std::vector<crypto::hash>& txs_ids, std::list<transaction>& txs, std::list<crypto::hash>& missed_txs); > bool get_transaction(const crypto::hash &h, transaction &tx); > bool get_block_by_hash(const crypto::hash &h, block &blk); > void get_all_known_block_ids(std::list<crypto::hash> &main, std::list<crypto::hash> &alt, std::list<crypto::hash> &invalid); > > bool get_alternative_blocks(std::list<block>& blocks); > size_t get_alternative_blocks_count(); > > void set_currency_protocol(i_currency_protocol* pprotocol); > void set_checkpoints(checkpoints&& chk_pts); > > bool get_pool_transactions(std::list<transaction>& txs); > size_t get_pool_transactions_count(); > size_t get_blockchain_total_transactions(); > bool get_outs(uint64_t amount, std::list<crypto::public_key>& pkeys); > bool have_block(const crypto::hash& id); > bool get_short_chain_history(std::list<crypto::hash>& ids); > bool find_blockchain_supplement(const std::list<crypto::hash>& qblock_ids, NOTIFY_RESPONSE_CHAIN_ENTRY::request& resp); > bool find_blockchain_supplement(const std::list<crypto::hash>& qblock_ids, std::list<std::pair<block, std::list<transaction> > >& blocks, uint64_t& total_height, uint64_t& start_height, size_t max_count); > bool get_stat_info(core_stat_info& st_inf); > bool get_backward_blocks_sizes(uint64_t from_height, std::vector<size_t>& sizes, size_t count); > bool get_tx_outputs_gindexs(const crypto::hash& tx_id, std::vector<uint64_t>& indexs); > crypto::hash get_tail_id(); > bool get_random_outs_for_amounts(const COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::request& req, COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::response& res); > void pause_mine(); > void resume_mine(); > blockchain_storage& get_blockchain_storage(){return m_blockchain_storage;} > > void print_blockchain(uint64_t start_index, uint64_t end_index); > void print_blockchain_index(); > std::string print_pool(bool short_format); > void print_blockchain_outs(const std::string& file); > void on_synchronized(); > > private: > bool add_new_tx(const transaction& tx, const crypto::hash& tx_hash, const crypto::hash& tx_prefix_hash, size_t blob_size, tx_verification_context& tvc, bool keeped_by_block); > bool add_new_tx(const transaction& tx, tx_verification_context& tvc, bool keeped_by_block); > bool add_new_block(const block& b, block_verification_context& bvc); > bool load_state_data(); > bool parse_tx_from_blob(transaction& tx, crypto::hash& tx_hash, crypto::hash& tx_prefix_hash, const blobdata& blob); > > bool check_tx_syntax(const transaction& tx); > > bool check_tx_semantic(const transaction& tx, bool keeped_by_block); > > > bool is_key_image_spent(const crypto::key_image& key_im); > > bool check_tx_ring_signature(const txin_to_key& tx, const crypto::hash& tx_prefix_hash, const std::vector<crypto::signature>& sig); > bool is_tx_spendtime_unlocked(uint64_t unlock_time); > bool update_miner_block_template(); > bool handle_command_line(const boost::program_options::variables_map& vm); > bool on_update_blocktemplate_interval(); > bool check_tx_inputs_keyimages_diff(const transaction& tx); > > > tx_memory_pool m_mempool; > blockchain_storage m_blockchain_storage; > i_currency_protocol* m_pprotocol; > critical_section m_incoming_tx_lock; > > miner m_miner; > account_public_address m_miner_address; > std::string m_config_folder; > currency_protocol_stub m_protocol_stub; > math_helper::once_a_time_seconds<60*60*12, false> m_store_blockchain_interval; > friend class tx_validate_inputs; > std::atomic<bool> m_starter_message_showed; > }; >} ># 131 "/c/honeypenny/src/currency_core/currency_core.h" >#pragma GCC diagnostic pop ># 131 "/c/honeypenny/src/currency_core/currency_core.h" ># 13 "/c/honeypenny/src/rpc/core_rpc_server.h" 2 ># 1 "/c/honeypenny/src/p2p/net_node.h" 1 ># 9 "/c/honeypenny/src/p2p/net_node.h" ># 1 "/usr/include/boost/bimap.hpp" 1 3 4 ># 13 "/usr/include/boost/bimap.hpp" 3 4 ># 1 "/usr/include/boost/bimap/bimap.hpp" 1 3 4 ># 53 "/usr/include/boost/bimap/bimap.hpp" 3 4 ># 1 "/usr/include/boost/bimap/detail/user_interface_config.hpp" 1 3 4 ># 54 "/usr/include/boost/bimap/bimap.hpp" 2 3 4 > > > > > > > ># 1 "/usr/include/boost/bimap/detail/bimap_core.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/detail/bimap_core.hpp" 3 4 ># 1 "/usr/include/boost/mpl/placeholders.hpp" 1 3 4 ># 22 "/usr/include/boost/bimap/detail/bimap_core.hpp" 2 3 4 ># 38 "/usr/include/boost/bimap/detail/bimap_core.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 1 3 4 ># 29 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 3 4 ># 1 "/usr/include/boost/functional/hash/hash.hpp" 1 3 4 ># 30 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/bimap/tags/tagged.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/tags/tagged.hpp" 3 4 >namespace boost { >namespace bimaps { ># 51 "/usr/include/boost/bimap/tags/tagged.hpp" 3 4 >namespace tags { ># 80 "/usr/include/boost/bimap/tags/tagged.hpp" 3 4 >template< class Type, class Tag > >struct tagged >{ > typedef Type value_type; > typedef Tag tag; >}; > >} >} >} ># 35 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/tags/support/default_tagged.hpp" 1 3 4 ># 42 "/usr/include/boost/bimap/tags/support/default_tagged.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace tags { >namespace support { > > > > > >template< class Type, class DefaultTag > >struct default_tagged >{ > typedef tagged<Type,DefaultTag> type; >}; > >template< class Type, class OldTag, class NewTag > >struct default_tagged< tagged< Type, OldTag >, NewTag > >{ > typedef tagged<Type,OldTag> type; >}; > >} >} >} >} ># 36 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/tags/support/tag_of.hpp" 1 3 4 ># 22 "/usr/include/boost/bimap/tags/support/tag_of.hpp" 3 4 ># 1 "/usr/include/boost/bimap/detail/debug/static_error.hpp" 1 3 4 ># 23 "/usr/include/boost/bimap/tags/support/tag_of.hpp" 2 3 4 ># 46 "/usr/include/boost/bimap/tags/support/tag_of.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace tags { >namespace support { > > > > >template< class Type > >struct tag_of >{ > struct BIMAP_STATIC_ERROR__USING_TAG_OF_WITH_AN_UNTAGGED_TYPE {}; struct BIMAP_STATIC_ERROR__USING_TAG_OF_WITH_AN_UNTAGGED_TYPE; typedef struct BIMAP_STATIC_ERROR__USING_TAG_OF_WITH_AN_UNTAGGED_TYPE57 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__USING_TAG_OF_WITH_AN_UNTAGGED_TYPE::************ assert_arg()) (Type) { return 0; } } mpl_assert_arg57; enum { mpl_assertion_in_line_57 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg57::assert_arg() ) ) }; >}; > >template< class Type, class Tag > >struct tag_of< tagged< Type, Tag > > >{ > typedef Tag type; >}; > > >} >} >} >} ># 37 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/tags/support/value_type_of.hpp" 1 3 4 ># 44 "/usr/include/boost/bimap/tags/support/value_type_of.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace tags { >namespace support { > > > > >template< class Type > >struct value_type_of >{ > typedef Type type; >}; > >template< class Type, class Tag > >struct value_type_of< tagged< Type, Tag > > >{ > typedef Type type; >}; > > >} >} >} >} ># 38 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 2 3 4 > ># 1 "/usr/include/boost/bimap/relation/member_at.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/relation/member_at.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { ># 43 "/usr/include/boost/bimap/relation/member_at.hpp" 3 4 >namespace member_at { > > > > > > > struct left {}; > > > > > > > struct right {}; > > > > > > > struct info {}; > >} > >} >} >} ># 40 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/relation/detail/mutant.hpp" 1 3 4 ># 30 "/usr/include/boost/bimap/relation/detail/mutant.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { > > > >namespace detail { ># 49 "/usr/include/boost/bimap/relation/detail/mutant.hpp" 3 4 >template< class View, class Type > >typename enable_if< mpl::not_< is_const< Type > >, > >View& > >>::type mutate( Type & m ) >{ > enum { mpl_assertion_in_line_58 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) ( ::boost::mpl::contains<typename Type::mutant_views,View> ))0, 1 ) ) ) } > > ; > return *reinterpret_cast< View* >(boost::addressof(m)); >} > >template< class View, class Type > >typename enable_if< is_const< Type >, > >const View& > >>::type mutate( Type & m ) >{ > enum { mpl_assertion_in_line_71 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) ( ::boost::mpl::contains<typename Type::mutant_views,View> ))0, 1 ) ) ) } > > ; > return *reinterpret_cast< const View* >(boost::addressof(m)); >} > > > >} >} >} >} ># 41 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/relation/structured_pair.hpp" 1 3 4 ># 35 "/usr/include/boost/bimap/relation/structured_pair.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/pair_layout.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/relation/pair_layout.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { > > > > > >struct normal_layout {}; > > > >struct mirror_layout {}; ># 53 "/usr/include/boost/bimap/relation/pair_layout.hpp" 3 4 >template< class Layout > >struct inverse_layout >{ > typedef normal_layout type; >}; > >template<> >struct inverse_layout< normal_layout > >{ > typedef mirror_layout type; >}; > > > >} >} >} ># 36 "/usr/include/boost/bimap/relation/structured_pair.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/relation/symmetrical_base.hpp" 1 3 4 ># 31 "/usr/include/boost/bimap/relation/symmetrical_base.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { > > > > > > >template< class TA, class TB, bool force_mutable = false > >class symmetrical_base >{ > > public: > > typedef typename tags::support::default_tagged > < > TA, > member_at::left > > >::type tagged_left_type; > > typedef typename tags::support::default_tagged > < > TB, > member_at::right > > >::type tagged_right_type; > > public: > > > > > typedef typename ::boost::mpl::if_c< force_mutable, > > typename ::boost::remove_const< > typename tagged_left_type::value_type >::type, > typename tagged_left_type::value_type > > >::type left_value_type; > > typedef typename ::boost::mpl::if_c< force_mutable, > > typename ::boost::remove_const< > typename tagged_right_type::value_type >::type, > typename tagged_right_type::value_type > > >::type right_value_type; > > > > > typedef typename tagged_left_type ::tag left_tag; > typedef typename tagged_right_type::tag right_tag; > >}; > > > >} >} >} ># 37 "/usr/include/boost/bimap/relation/structured_pair.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/relation/support/get.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/relation/support/get.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/support/value_type_of.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/relation/support/value_type_of.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/detail/metadata_access_builder.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/relation/detail/metadata_access_builder.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/support/is_tag_of_member_at.hpp" 1 3 4 ># 26 "/usr/include/boost/bimap/relation/support/is_tag_of_member_at.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/support/member_with_tag.hpp" 1 3 4 ># 60 "/usr/include/boost/bimap/relation/support/member_with_tag.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { >namespace support { > >template >< > class Tag, > class Relation, > class Enable = void >> >struct member_with_tag >{ > struct BIMAP_STATIC_ERROR__MEMBER_WITH_TAG_FAILURE {}; struct BIMAP_STATIC_ERROR__MEMBER_WITH_TAG_FAILURE; typedef struct BIMAP_STATIC_ERROR__MEMBER_WITH_TAG_FAILURE73 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__MEMBER_WITH_TAG_FAILURE::************ assert_arg()) (Relation,Tag) { return 0; } } mpl_assert_arg73; enum { mpl_assertion_in_line_73 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg73::assert_arg() ) ) }; >}; > >template< class Relation > >struct member_with_tag >< > member_at::left, Relation, void >> >{ > typedef member_at::left type; >}; > >template< class Relation > >struct member_with_tag >< > member_at::right, Relation, void >> >{ > typedef member_at::right type; >}; > >template< class Relation > >struct member_with_tag >< > member_at::info, Relation, void >> >{ > typedef member_at::info type; >}; > > >template< class Tag, class Relation > >struct member_with_tag >< > Tag, Relation, > typename enable_if > < > mpl::and_ > < > mpl::not_< is_same<Tag,member_at::left> >, > is_same > < > Tag, > typename Relation::left_tag > > > > > > >::type >> >{ > typedef member_at::left type; >}; > >template< class Tag, class Relation > >struct member_with_tag >< > Tag, > Relation, > typename enable_if > < > mpl::and_ > < > mpl::not_< is_same<Tag,member_at::right> >, > is_same > < > Tag, > typename Relation::right_tag > > > > > > >::type >> >{ > typedef member_at::right type; >}; > >template< class Tag, class Relation > >struct member_with_tag >< > Tag, Relation, > typename enable_if > < > mpl::and_ > < > mpl::not_< is_same<Tag,member_at::info> >, > is_same > < > Tag, > typename Relation::info_tag > > > > > > >::type >> >{ > typedef member_at::info type; >}; > >} >} >} >} ># 27 "/usr/include/boost/bimap/relation/support/is_tag_of_member_at.hpp" 2 3 4 ># 82 "/usr/include/boost/bimap/relation/support/is_tag_of_member_at.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { >namespace support { > > > > >template >< > class Tag, > class Relation, > class Enable = void >> >struct is_tag_of_member_at_left : > ::boost::mpl::false_ {}; > >template< class Tag, class Relation > >struct is_tag_of_member_at_left >< > Tag, Relation, > typename enable_if > < > is_same > < > typename member_with_tag<Tag,Relation>::type, > member_at::left > > > > >::type >> : > ::boost::mpl::true_ {}; > > > > >template >< > class Tag, > class Relation, > class Enable = void >> >struct is_tag_of_member_at_right : > ::boost::mpl::false_ {}; > >template< class Tag, class Relation > >struct is_tag_of_member_at_right >< > Tag, Relation, > typename enable_if > < > is_same > < > typename member_with_tag<Tag,Relation>::type, > member_at::right > > > > >::type >> : > ::boost::mpl::true_ {}; > > > > > >template >< > class Tag, > class Relation, > class Enable = void >> >struct is_tag_of_member_at_info : > ::boost::mpl::false_ {}; > >template< class Tag, class Relation > >struct is_tag_of_member_at_info >< > Tag, Relation, > typename enable_if > < > is_same > < > typename member_with_tag<Tag,Relation>::type, > member_at::info > > > > >::type >> : > ::boost::mpl::true_ {}; > >} >} >} >} ># 22 "/usr/include/boost/bimap/relation/detail/metadata_access_builder.hpp" 2 3 4 ># 22 "/usr/include/boost/bimap/relation/support/value_type_of.hpp" 2 3 4 ># 41 "/usr/include/boost/bimap/relation/support/value_type_of.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { >namespace support { ># 57 "/usr/include/boost/bimap/relation/support/value_type_of.hpp" 3 4 >template < class Tag, class SymmetricType, class Enable = void > struct value_type_of { struct BIMAP_STATIC_ERROR__value_type_of_FAILURE {}; struct BIMAP_STATIC_ERROR__value_type_of_FAILURE; typedef struct BIMAP_STATIC_ERROR__value_type_of_FAILURE62 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__value_type_of_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg62; enum { mpl_assertion_in_line_62 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg62::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct value_type_of < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_value_type type; }; template< class Tag, class SymmetricType > struct value_type_of < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_value_type type; }; ># 66 "/usr/include/boost/bimap/relation/support/value_type_of.hpp" 3 4 >template< class Tag, class SymmetricType > >struct value_type_of >< > Tag, SymmetricType, > typename enable_if > < > ::boost::bimaps::relation::support::is_tag_of_member_at_info > < > Tag, > SymmetricType > > > > >::type >> >{ > typedef typename SymmetricType::info_type type; >}; > >} >} >} >} ># 22 "/usr/include/boost/bimap/relation/support/get.hpp" 2 3 4 > ># 1 "/usr/include/boost/bimap/relation/detail/access_builder.hpp" 1 3 4 ># 24 "/usr/include/boost/bimap/relation/support/get.hpp" 2 3 4 ># 57 "/usr/include/boost/bimap/relation/support/get.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { >namespace support { ># 91 "/usr/include/boost/bimap/relation/support/get.hpp" 3 4 >namespace result_of { template< class Tag, class SymmetricType > struct get { typedef typename value_type_of < Tag,SymmetricType >::type value_type; typedef typename mpl::if_< is_const<SymmetricType>, typename call_traits<value_type>::const_reference, typename call_traits<value_type>::reference >::type type; }; } ># 102 "/usr/include/boost/bimap/relation/support/get.hpp" 3 4 >namespace detail { template< class SymmetricType > typename result_of::get < ::boost::bimaps::relation::member_at::left,SymmetricType >::type get( ::boost::bimaps::relation::member_at::left, SymmetricType & st ) { return st.get_left(); } template< class SymmetricType > typename result_of::get < ::boost::bimaps::relation::member_at::right,SymmetricType >::type get( ::boost::bimaps::relation::member_at::right, SymmetricType & st ) { return st.get_right(); } } ># 111 "/usr/include/boost/bimap/relation/support/get.hpp" 3 4 >namespace detail { > >template< class SymmetricType > >typename result_of::get< > ::boost::bimaps::relation::member_at::info, SymmetricType >::type >get(::boost::bimaps::relation::member_at::info, SymmetricType & rel) >{ > return rel.info; >} > >} > > > > >template< class Tag, class SymmetricType > typename result_of::get<Tag,SymmetricType>::type get( SymmetricType & s ) { typedef typename ::boost::bimaps::relation::support:: member_with_tag < Tag,SymmetricType >::type member_at_tag; return detail::get(member_at_tag(),s); } > > > > > >} >} >} >} ># 38 "/usr/include/boost/bimap/relation/structured_pair.hpp" 2 3 4 > > > > >namespace boost { >namespace bimaps { >namespace relation { > >namespace detail { > > > > > > > >template< class FirstType, class SecondType > >class normal_storage : > public symmetrical_base<FirstType,SecondType> >{ > typedef symmetrical_base<FirstType,SecondType> base_; > > public: > > typedef normal_storage storage_; > > typedef typename base_::left_value_type first_type; > typedef typename base_::right_value_type second_type; > > first_type first; > second_type second; > > normal_storage() {} > > normal_storage(typename ::boost::call_traits< > first_type >::param_type f, > typename ::boost::call_traits< > second_type>::param_type s) > > : first(f), second(s) {} > > typename base_:: left_value_type & get_left() { return first; } > const typename base_:: left_value_type & get_left()const { return first; } > typename base_::right_value_type & get_right() { return second; } > const typename base_::right_value_type & get_right()const { return second; } >}; > > > > > > > >template< class FirstType, class SecondType > >class mirror_storage : > public symmetrical_base<SecondType,FirstType> >{ > typedef symmetrical_base<SecondType,FirstType> base_; > > public: > > typedef mirror_storage storage_; > > typedef typename base_::left_value_type second_type; > typedef typename base_::right_value_type first_type; > > second_type second; > first_type first; > > mirror_storage() {} > > mirror_storage(typename ::boost::call_traits<first_type >::param_type f, > typename ::boost::call_traits<second_type >::param_type s) > > : second(s), first(f) {} > > typename base_:: left_value_type & get_left() { return second; } > const typename base_:: left_value_type & get_left()const { return second; } > typename base_::right_value_type & get_right() { return first; } > const typename base_::right_value_type & get_right()const { return first; } >}; ># 136 "/usr/include/boost/bimap/relation/structured_pair.hpp" 3 4 >template >< > class FirstType, > class SecondType, > class Layout >> >struct storage_finder >{ > typedef normal_storage<FirstType,SecondType> type; >}; > >template >< > class FirstType, > class SecondType >> >struct storage_finder<FirstType,SecondType,mirror_layout> >{ > typedef mirror_storage<FirstType,SecondType> type; >}; > > > > >template< class TA, class TB, class Info, class Layout > >class pair_info_hook : > public ::boost::bimaps::relation::detail::storage_finder<TA,TB,Layout>::type >{ > typedef typename ::boost::bimaps::relation::detail::storage_finder<TA,TB,Layout>::type base_; > > typedef typename ::boost::bimaps::tags::support:: > default_tagged<Info,member_at::info>::type tagged_info_type; > > public: > typedef typename tagged_info_type::value_type info_type; > typedef typename tagged_info_type::tag info_tag; > > info_type info; > > protected: > > pair_info_hook() {} > > pair_info_hook( typename ::boost::call_traits< > typename base_::first_type > >::param_type f, > typename ::boost::call_traits< > typename base_::second_type > >::param_type s, > typename ::boost::call_traits< > info_type > >::param_type i = info_type() ) > : base_(f,s), info(i) {} > > template< class Pair > > pair_info_hook( const Pair & p) : > base_(p.first,p.second), > info(p.info) {} > > template< class Pair > > void change_to( const Pair & p ) > { > base_::first = p.first ; > base_::second = p.second; > info = p.info ; > } > > void clear_info() > { > info = info_type(); > }; >}; > >template< class TA, class TB, class Layout> >class pair_info_hook<TA,TB,::boost::mpl::na,Layout> : > public ::boost::bimaps::relation::detail::storage_finder<TA,TB,Layout>::type >{ > typedef typename ::boost::bimaps::relation::detail::storage_finder<TA,TB,Layout>::type base_; > > public: > typedef ::boost::mpl::na info_type; > typedef member_at::info info_tag; > > protected: > > pair_info_hook() {} > > pair_info_hook( typename ::boost::call_traits< > typename base_::first_type > >::param_type f, > typename ::boost::call_traits< > typename base_::second_type > >::param_type s) > > : base_(f,s) {} > > template< class Pair > > pair_info_hook( const Pair & p ) : > base_(p.first,p.second) {} > > template< class Pair > > void change_to( const Pair & p ) > { > base_::first = p.first ; > base_::second = p.second; > } > > void clear_info() {}; >}; > > > >} > >template< class TA, class TB, class Info, bool FM > >class mutant_relation; ># 261 "/usr/include/boost/bimap/relation/structured_pair.hpp" 3 4 >template< class FirstType, class SecondType, class Info, class Layout = normal_layout > >class structured_pair : > > public ::boost::bimaps::relation::detail::pair_info_hook > < > FirstType, SecondType, > Info, > Layout > > > > >{ > typedef typename ::boost::bimaps::relation::detail::pair_info_hook > < > FirstType, SecondType, > Info, > Layout > > > base_; > > public: > > typedef ::boost::mpl::vector3< > structured_pair< FirstType, SecondType, Info, normal_layout >, > structured_pair< FirstType, SecondType, Info, mirror_layout >, > typename ::boost::mpl::if_< > typename ::boost::is_same<Layout, normal_layout>::type, > mutant_relation< FirstType, SecondType, Info, true >, > mutant_relation< SecondType, FirstType, Info, true > > >::type > > > mutant_views; > > structured_pair() {} > > structured_pair(typename boost::call_traits< > typename base_::first_type >::param_type f, > typename boost::call_traits< > typename base_::second_type >::param_type s) > : base_(f,s) {} > > structured_pair(typename boost::call_traits< > typename base_::first_type >::param_type f, > typename boost::call_traits< > typename base_::second_type >::param_type s, > typename boost::call_traits< > typename base_::info_type >::param_type i) > : base_(f,s,i) {} > > template< class OtherLayout > > structured_pair( > const structured_pair<FirstType,SecondType,Info,OtherLayout> & p) > : base_(p) {} > > template< class OtherLayout > > structured_pair& operator=( > const structured_pair<FirstType,SecondType,OtherLayout> & p) > { > base_::change_to(p); > return *this; > } > > template< class First, class Second > > structured_pair(const std::pair<First,Second> & p) : > base_(p.first,p.second) > {} > > template< class First, class Second > > structured_pair& operator=(const std::pair<First,Second> & p) > { > base_::first = p.first; > base_::second = p.second; > base_::clear_info(); > return *this; > } > > template< class Tag > > const typename ::boost::bimaps::relation::support:: > result_of::get<Tag,const structured_pair>::type > get() const > { > return ::boost::bimaps::relation::support::get<Tag>(*this); > } > > template< class Tag > > typename ::boost::bimaps::relation::support:: > result_of::get<Tag,structured_pair>::type > get() > { > return ::boost::bimaps::relation::support::get<Tag>(*this); > } >}; > > > >template< class FirstType, class SecondType, class Info, class Layout1, class Layout2 > >bool operator==(const structured_pair<FirstType,SecondType,Info,Layout1> & a, > const structured_pair<FirstType,SecondType,Info,Layout2> & b) >{ > return ( ( a.first == b.first ) && > ( a.second == b.second ) ); >} > >template< class FirstType, class SecondType, class Info, class Layout1, class Layout2 > >bool operator!=(const structured_pair<FirstType,SecondType,Info,Layout1> & a, > const structured_pair<FirstType,SecondType,Info,Layout2> & b) >{ > return ! ( a == b ); >} > >template< class FirstType, class SecondType, class Info, class Layout1, class Layout2 > >bool operator<(const structured_pair<FirstType,SecondType,Info,Layout1> & a, > const structured_pair<FirstType,SecondType,Info,Layout2> & b) >{ > return ( ( a.first < b.first ) || > (( a.first == b.first ) && ( a.second < b.second ))); >} > >template< class FirstType, class SecondType, class Info, class Layout1, class Layout2 > >bool operator<=(const structured_pair<FirstType,SecondType,Info,Layout1> & a, > const structured_pair<FirstType,SecondType,Info,Layout2> & b) >{ > return ( ( a.first < b.first ) || > (( a.first == b.first ) && ( a.second <= b.second ))); >} > >template< class FirstType, class SecondType, class Info, class Layout1, class Layout2 > >bool operator>(const structured_pair<FirstType,SecondType,Info,Layout1> & a, > const structured_pair<FirstType,SecondType,Info,Layout2> & b) >{ > return ( ( a.first > b.first ) || > (( a.first == b.first ) && ( a.second > b.second ))); >} > >template< class FirstType, class SecondType, class Info, class Layout1, class Layout2 > >bool operator>=(const structured_pair<FirstType,SecondType,Info,Layout1> & a, > const structured_pair<FirstType,SecondType,Info,Layout2> & b) >{ > return ( ( a.first > b.first ) || > (( a.first == b.first ) && ( a.second >= b.second ))); >} > > > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator==(const structured_pair<FirstType,SecondType,Info,Layout> & a, > const std::pair<F,S> & b) >{ > return ( ( a.first == b.first ) && > ( a.second == b.second ) ); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator!=(const structured_pair<FirstType,SecondType,Info,Layout> & a, > const std::pair<F,S> & b) >{ > return ! ( a == b ); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator<(const structured_pair<FirstType,SecondType,Info,Layout> & a, > const std::pair<F,S> & b) >{ > return ( ( a.first < b.first ) || > (( a.first == b.first ) && ( a.second < b.second ))); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator<=(const structured_pair<FirstType,SecondType,Info,Layout> & a, > const std::pair<F,S> & b) >{ > return ( ( a.first < b.first ) || > (( a.first == b.first ) && ( a.second <= b.second ))); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator>(const structured_pair<FirstType,SecondType,Info,Layout> & a, > const std::pair<F,S> & b) >{ > return ( ( a.first > b.first ) || > (( a.first == b.first ) && ( a.second > b.second ))); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator>=(const structured_pair<FirstType,SecondType,Info,Layout> & a, > const std::pair<F,S> & b) >{ > return ( ( a.first > b.first ) || > (( a.first == b.first ) && ( a.second >= b.second ))); >} > > > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator==(const std::pair<F,S> & a, > const structured_pair<FirstType,SecondType,Info,Layout> & b) >{ > return ( ( a.first == b.first ) && > ( a.second == b.second ) ); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator!=(const std::pair<F,S> & a, > const structured_pair<FirstType,SecondType,Info,Layout> & b) >{ > return ! ( a == b ); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator<(const std::pair<F,S> & a, > const structured_pair<FirstType,SecondType,Info,Layout> & b) >{ > return ( ( a.first < b.first ) || > (( a.first == b.first ) && ( a.second < b.second ))); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator<=(const std::pair<F,S> & a, > const structured_pair<FirstType,SecondType,Info,Layout> & b) >{ > return ( ( a.first < b.first ) || > (( a.first == b.first ) && ( a.second <= b.second ))); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator>(const std::pair<F,S> & a, > const structured_pair<FirstType,SecondType,Info,Layout> & b) >{ > return ( ( a.first > b.first ) || > (( a.first == b.first ) && ( a.second > b.second ))); >} > >template< class FirstType, class SecondType, class Info, class Layout, class F, class S > >bool operator>=(const std::pair<F,S> & a, > const structured_pair<FirstType,SecondType,Info,Layout> & b) >{ > return ( ( a.first > b.first ) || > (( a.first == b.first ) && ( a.second >= b.second ))); >} > > >namespace detail { > >template< class FirstType, class SecondType, class Info, class Layout> >structured_pair<FirstType,SecondType,Info,Layout> > copy_with_first_replaced(structured_pair<FirstType,SecondType,Info,Layout> const& p, > typename ::boost::call_traits< typename > structured_pair<FirstType,SecondType,Info,Layout>::first_type> > ::param_type f) >{ > return structured_pair<FirstType,SecondType,Info,Layout>(f,p.second,p.info); >} > >template< class FirstType, class SecondType, class Layout> >structured_pair<FirstType,SecondType,::boost::mpl::na,Layout> > copy_with_first_replaced(structured_pair<FirstType,SecondType,::boost::mpl::na,Layout> const& p, > typename ::boost::call_traits< typename > structured_pair<FirstType,SecondType,::boost::mpl::na,Layout>::first_type> > ::param_type f) >{ > return structured_pair<FirstType,SecondType,::boost::mpl::na,Layout>(f,p.second); >} > >template< class FirstType, class SecondType, class Info, class Layout> >structured_pair<FirstType,SecondType,Info,Layout> > copy_with_second_replaced(structured_pair<FirstType,SecondType,Info,Layout> const& p, > typename ::boost::call_traits< typename > structured_pair<FirstType,SecondType,Info,Layout>::second_type> > ::param_type s) >{ > return structured_pair<FirstType,SecondType,Info,Layout>(p.first,s,p.info); >} > >template< class FirstType, class SecondType, class Layout> >structured_pair<FirstType,SecondType,::boost::mpl::na,Layout> > copy_with_second_replaced(structured_pair<FirstType,SecondType,::boost::mpl::na,Layout> const& p, > typename ::boost::call_traits< typename > structured_pair<FirstType,SecondType,::boost::mpl::na,Layout>::second_type> > ::param_type s) >{ > return structured_pair<FirstType,SecondType,::boost::mpl::na,Layout>(p.first,s); >} > >} > > >} >} >} ># 42 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 2 3 4 > > > >namespace boost { >namespace bimaps { >namespace relation { > >namespace detail { > > > > >template< class LeftType, class RightType, bool force_mutable > >class relation_storage : > public symmetrical_base<LeftType,RightType,force_mutable> >{ > typedef symmetrical_base<LeftType,RightType,force_mutable> base_; > > typedef relation_storage storage_; > > public: > > typedef relation_storage<LeftType,RightType,false> non_mutable_storage; > > typedef ::boost::mpl::vector2 > < > relation_storage< LeftType, RightType, true >, > relation_storage< LeftType, RightType, false > > > > mutant_views; > > > > typename base_::left_value_type left; > typename base_::right_value_type right; > > > relation_storage() {} > > relation_storage(typename ::boost::call_traits< > typename base_::left_value_type > >::param_type l, > typename ::boost::call_traits< > typename base_::right_value_type > >::param_type r) > > : left(l), right(r) {} > > typename base_:: left_value_type & get_left() { return left; } > const typename base_:: left_value_type & get_left()const { return left; } > typename base_::right_value_type & get_right() { return right; } > const typename base_::right_value_type & get_right()const { return right; } >}; > > > >template< class TA, class TB, class Info, bool force_mutable > >class relation_info_hook : public > ::boost::bimaps::relation::detail::relation_storage<TA,TB,force_mutable> >{ > typedef ::boost::bimaps::relation::detail:: > relation_storage<TA,TB,force_mutable> base_; > > typedef typename ::boost::bimaps::tags::support:: > default_tagged<Info,member_at::info>::type tagged_info_type; > > public: > typedef typename tagged_info_type::value_type info_type; > typedef typename tagged_info_type::tag info_tag; > > info_type info; > > protected: > > relation_info_hook() {} > > relation_info_hook( typename ::boost::call_traits< > typename base_::left_value_type > >::param_type l, > typename ::boost::call_traits< > typename base_::right_value_type > >::param_type r, > typename ::boost::call_traits< > info_type > >::param_type i = info_type() ) > > : base_(l,r), info(i) {} > > template< class Relation > > relation_info_hook( const Relation & rel ) : > base_(rel.left,rel.right), > info(rel.info) {} > > template< class Relation > > void change_to( const Relation & rel ) > { > base_::left = rel.left ; > base_::right = rel.right; > info = rel.info ; > } > > > template< class Archive > > void serialize(Archive & ar, const unsigned int) > { > ar & ::boost::serialization::make_nvp("left" , base_::left ); > ar & ::boost::serialization::make_nvp("right", base_::right); > ar & ::boost::serialization::make_nvp("info" , info ); > } > >}; > >template< class TA, class TB, bool force_mutable> >class relation_info_hook<TA,TB,::boost::mpl::na,force_mutable> : > public ::boost::bimaps::relation::detail::relation_storage<TA,TB,force_mutable> >{ > typedef ::boost::bimaps::relation::detail:: > relation_storage<TA,TB,force_mutable> base_; > > public: > typedef ::boost::mpl::na info_type; > typedef member_at::info info_tag; > > protected: > > relation_info_hook() {} > > relation_info_hook( typename ::boost::call_traits< > typename base_::left_value_type > >::param_type l, > typename ::boost::call_traits< > typename base_::right_value_type > >::param_type r) > > : base_(l,r) {} > > template< class Relation > > relation_info_hook( const Relation & rel ) : > base_(rel.left,rel.right) {} > > template< class Relation > > void change_to( const Relation & rel ) > { > base_::left = rel.left ; > base_::right = rel.right; > } > > > template< class Archive > > void serialize(Archive & ar, const unsigned int) > { > ar & ::boost::serialization::make_nvp("left" , base_::left ); > ar & ::boost::serialization::make_nvp("right", base_::right); > } > >}; > > >} ># 226 "/usr/include/boost/bimap/relation/mutant_relation.hpp" 3 4 >template< class TA, class TB, class Info = ::boost::mpl::na, bool force_mutable = false > >class mutant_relation : public > ::boost::bimaps::relation::detail:: > relation_info_hook<TA,TB,Info,force_mutable> >{ > typedef ::boost::bimaps::relation::detail:: > relation_info_hook<TA,TB,Info,force_mutable> base_; > > public: > > > > > typedef ::boost::bimaps::relation::detail:: > relation_storage<TA,TB,force_mutable> storage_base; > > > > typedef mutant_relation<TA,TB,Info,false> above_view; > > > > > typedef structured_pair< TA, TB, Info, normal_layout > left_pair; > typedef structured_pair< TB, TA, Info, mirror_layout > right_pair; > > > typedef ::boost::mpl::vector4 > < > left_pair, > right_pair, > > mutant_relation< TA, TB, Info, true >, > mutant_relation< TA, TB, Info, false > > > > mutant_views; > > mutant_relation() {} > > mutant_relation(typename ::boost::call_traits< > typename base_:: left_value_type > >::param_type l, > typename ::boost::call_traits< > typename base_::right_value_type > >::param_type r) : > base_(l,r) {} > > mutant_relation(typename ::boost::call_traits< > typename base_:: left_value_type > >::param_type l, > typename ::boost::call_traits< > typename base_::right_value_type > >::param_type r, > typename ::boost::call_traits< > typename base_::info_type > >::param_type i) : > base_(l,r,i) {} > > mutant_relation(const mutant_relation<TA,TB,Info,false> & rel) : > base_(rel) {} > > mutant_relation(const mutant_relation<TA,TB,Info,true> & rel) : > base_(rel) {} > > > > template< bool FM > > mutant_relation& operator=(const mutant_relation<TA,TB,Info,FM> & rel) > { > base_::change_to(rel); > return *this; > } > > > > > > > left_pair & get_left_pair() > { > return ::boost::bimaps::relation::detail::mutate<left_pair>(*this); > } > > const left_pair & get_left_pair() const > { > return ::boost::bimaps::relation::detail::mutate<left_pair>(*this); > } > > right_pair & get_right_pair() > { > return ::boost::bimaps::relation::detail::mutate<right_pair>(*this); > } > > const right_pair & get_right_pair() const > { > return ::boost::bimaps::relation::detail::mutate<right_pair>(*this); > } > > above_view & get_view() > { > return ::boost::bimaps::relation::detail::mutate<above_view>(*this); > } > > const above_view & get_view() const > { > return ::boost::bimaps::relation::detail::mutate<above_view>(*this); > } > > template< class Tag > > const typename ::boost::bimaps::relation::support:: > result_of::get<Tag,const mutant_relation>::type > get() const > { > return ::boost::bimaps::relation::support::get<Tag>(*this); > } > > template< class Tag > > typename ::boost::bimaps::relation::support:: > result_of::get<Tag,mutant_relation>::type > get() > { > return ::boost::bimaps::relation::support::get<Tag>(*this); > } > > > > private: > friend class ::boost::serialization::access; > > template<class Archive> > void serialize(Archive & ar, const unsigned int version) > { > base_::serialize(ar,version); > } > > >}; > > > >template< class FirstType, class SecondType, bool FM > >std::size_t hash_value(const detail::relation_storage<FirstType,SecondType,FM> & r) >{ > std::size_t seed = 0; > ::boost::hash_combine(seed, r. left ); > ::boost::hash_combine(seed, r.right ); > > return seed; >} > > > >template< class FirstType, class SecondType, bool FM1, bool FM2 > >bool operator==(const detail::relation_storage<FirstType,SecondType,FM1> & a, > const detail::relation_storage<FirstType,SecondType,FM2> & b) >{ > return ( ( a.left == b.left ) && > ( a.right == b.right ) ); >} > >template< class FirstType, class SecondType, bool FM1, bool FM2 > >bool operator!=(const detail::relation_storage<FirstType,SecondType,FM1> & a, > const detail::relation_storage<FirstType,SecondType,FM2> & b) >{ > return ! ( a == b ); >} > >template< class FirstType, class SecondType, bool FM1, bool FM2 > >bool operator<(const detail::relation_storage<FirstType,SecondType,FM1> & a, > const detail::relation_storage<FirstType,SecondType,FM2> & b) >{ > return ( ( a.left < b.left ) || > (( a.left == b.left ) && ( a.right < b.right ))); >} > >template< class FirstType, class SecondType, bool FM1, bool FM2 > >bool operator<=(const detail::relation_storage<FirstType,SecondType,FM1> & a, > const detail::relation_storage<FirstType,SecondType,FM2> & b) >{ > return ( ( a.left < b.left ) || > (( a.left == b.left ) && ( a.right <= b.right ))); >} > >template< class FirstType, class SecondType, bool FM1, bool FM2 > >bool operator>(const detail::relation_storage<FirstType,SecondType,FM1> & a, > const detail::relation_storage<FirstType,SecondType,FM2> & b) >{ > return ( ( a.left > b.left ) || > (( a.left == b.left ) && ( a.right > b.right ))); >} > >template< class FirstType, class SecondType, bool FM1, bool FM2 > >bool operator>=(const detail::relation_storage<FirstType,SecondType,FM1> & a, > const detail::relation_storage<FirstType,SecondType,FM2> & b) >{ > return ( ( a.left > b.left ) || > (( a.left == b.left ) && ( a.right >= b.right ))); >} > >namespace detail { > >template< class TA, class TB, class Info, bool force_mutable> >mutant_relation<TA,TB,Info,force_mutable> > copy_with_left_replaced(mutant_relation<TA,TB,Info,force_mutable> const& rel, > typename ::boost::call_traits< typename > mutant_relation<TA,TB,Info,force_mutable>::left_value_type> > ::param_type l) >{ > return mutant_relation<TA,TB,Info,force_mutable>(l,rel.right,rel.info); >} > >template< class TA, class TB, bool force_mutable> >mutant_relation<TA,TB,::boost::mpl::na,force_mutable> > copy_with_left_replaced(mutant_relation<TA,TB,::boost::mpl::na,force_mutable> const& rel, > typename ::boost::call_traits< typename > mutant_relation<TA,TB,::boost::mpl::na,force_mutable>::left_value_type> > ::param_type l) >{ > return mutant_relation<TA,TB,::boost::mpl::na,force_mutable>(l,rel.right); >} > >template< class TA, class TB, class Info, bool force_mutable> >mutant_relation<TA,TB,Info,force_mutable> > copy_with_right_replaced(mutant_relation<TA,TB,Info,force_mutable> const& rel, > typename ::boost::call_traits< typename > mutant_relation<TA,TB,Info,force_mutable>::right_value_type> > ::param_type r) >{ > return mutant_relation<TA,TB,Info,force_mutable>(rel.left,r,rel.info); >} > >template< class TA, class TB, bool force_mutable> >mutant_relation<TA,TB,::boost::mpl::na,force_mutable> > copy_with_right_replaced(mutant_relation<TA,TB,::boost::mpl::na,force_mutable> const& rel, > typename ::boost::call_traits< typename > mutant_relation<TA,TB,::boost::mpl::na,force_mutable>::right_value_type> > ::param_type r) >{ > return mutant_relation<TA,TB,::boost::mpl::na,force_mutable>(rel.left,r); >} > >} > >} >} >} ># 39 "/usr/include/boost/bimap/detail/bimap_core.hpp" 2 3 4 > ># 1 "/usr/include/boost/bimap/relation/support/data_extractor.hpp" 1 3 4 ># 33 "/usr/include/boost/bimap/relation/support/data_extractor.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { >namespace support { > >template< class Tag, class Relation > >struct data_extractor_implementation; > >template< class Relation > >struct data_extractor_implementation< member_at::left, Relation > : > public std::unary_function<Relation,typename Relation::left_value_type> >{ > typename Relation::left_value_type const & > operator()(Relation const & rel) const > { > return rel.left; > } > > typename Relation::left_value_type & > operator()(Relation & rel) const > { > return rel.left; > } >}; > >template< class Relation > >struct data_extractor_implementation< member_at::right, Relation > : > public std::unary_function<Relation,typename Relation::right_value_type> >{ > typename Relation::right_value_type const & > operator()(Relation const & rel) const > { > return rel.right; > } > > typename Relation::right_value_type & > operator()(Relation & rel) const > { > return rel.right; > } >}; > >template< class Tag, class Relation > >struct data_extractor >{ > typedef data_extractor_implementation > < > typename member_with_tag<Tag,Relation>::type, > Relation > > > type; >}; > >template< class Relation > >struct both_keys_extractor >{ > typedef typename Relation::storage_base result_type; > > const result_type & operator()(const Relation & rel) const > { > return rel; > } > > result_type & operator()( Relation & rel) const > { > return rel; > } >}; > >} >} >} >} ># 41 "/usr/include/boost/bimap/detail/bimap_core.hpp" 2 3 4 > > ># 1 "/usr/include/boost/bimap/detail/manage_bimap_key.hpp" 1 3 4 ># 24 "/usr/include/boost/bimap/detail/manage_bimap_key.hpp" 3 4 ># 1 "/usr/include/boost/bimap/detail/is_set_type_of.hpp" 1 3 4 ># 22 "/usr/include/boost/bimap/detail/is_set_type_of.hpp" 3 4 ># 1 "/usr/include/boost/bimap/detail/concept_tags.hpp" 1 3 4 ># 22 "/usr/include/boost/bimap/detail/concept_tags.hpp" 3 4 ># 1 "/usr/include/boost/mpl/placeholders.hpp" 1 3 4 ># 23 "/usr/include/boost/bimap/detail/concept_tags.hpp" 2 3 4 > > >namespace boost { >namespace bimaps { >namespace detail { > > > > > > > >struct set_type_of_tag {}; > > > >struct set_type_of_relation_tag {}; > > > >struct side_based_tag : set_type_of_relation_tag {}; > >} ># 68 "/usr/include/boost/bimap/detail/concept_tags.hpp" 3 4 >struct left_based : ::boost::bimaps::detail::side_based_tag >{ > > > template< class Relation > struct bind_to { typedef void type; }; > > typedef mpl::bool_<true> left_mutable_key; > typedef mpl::bool_<true> right_mutable_key; >}; > >struct right_based : ::boost::bimaps::detail::side_based_tag >{ > > > template< class Relation > struct bind_to { typedef void type; }; > > typedef mpl::bool_<true> left_mutable_key; > typedef mpl::bool_<true> right_mutable_key; >}; > > > >typedef mpl::_ _relation; > >} >} ># 23 "/usr/include/boost/bimap/detail/is_set_type_of.hpp" 2 3 4 ># 47 "/usr/include/boost/bimap/detail/is_set_type_of.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace detail { > >template< class Type > >struct is_set_type_of : > is_base_of< set_type_of_tag, Type > {}; > >template< class Type > >struct is_set_type_of_relation : > is_base_of< set_type_of_relation_tag, Type > {}; > >} >} >} ># 25 "/usr/include/boost/bimap/detail/manage_bimap_key.hpp" 2 3 4 > ># 1 "/usr/include/boost/bimap/set_of.hpp" 1 3 4 ># 31 "/usr/include/boost/bimap/set_of.hpp" 3 4 ># 1 "/usr/include/boost/bimap/detail/generate_index_binder.hpp" 1 3 4 ># 32 "/usr/include/boost/bimap/set_of.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/detail/generate_view_binder.hpp" 1 3 4 ># 33 "/usr/include/boost/bimap/set_of.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/detail/generate_relation_binder.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/detail/generate_relation_binder.hpp" 3 4 ># 1 "/usr/include/boost/mpl/apply.hpp" 1 3 4 ># 22 "/usr/include/boost/bimap/detail/generate_relation_binder.hpp" 2 3 4 ># 34 "/usr/include/boost/bimap/set_of.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/multi_index/ordered_index.hpp" 1 3 4 ># 55 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/bidir_node_iterator.hpp" 1 3 4 ># 24 "/usr/include/boost/multi_index/detail/bidir_node_iterator.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > > >template<typename Node> >class bidir_node_iterator: > public bidirectional_iterator_helper< > bidir_node_iterator<Node>, > typename Node::value_type, > std::ptrdiff_t, > const typename Node::value_type*, > const typename Node::value_type&> >{ >public: > bidir_node_iterator(){} > explicit bidir_node_iterator(Node* node_):node(node_){} > > const typename Node::value_type& operator*()const > { > return node->value(); > } > > bidir_node_iterator& operator++() > { > Node::increment(node); > return *this; > } > > bidir_node_iterator& operator--() > { > Node::decrement(node); > return *this; > } > > > > > > > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } > > typedef typename Node::base_type node_base_type; > > template<class Archive> > void save(Archive& ar,const unsigned int)const > { > node_base_type* bnode=node; > ar<<serialization::make_nvp("pointer",bnode); > } > > template<class Archive> > void load(Archive& ar,const unsigned int) > { > node_base_type* bnode; > ar>>serialization::make_nvp("pointer",bnode); > node=static_cast<Node*>(bnode); > } > > > > > typedef Node node_type; > > Node* get_node()const{return node;} > >private: > Node* node; >}; > >template<typename Node> >bool operator==( > const bidir_node_iterator<Node>& x, > const bidir_node_iterator<Node>& y) >{ > return x.get_node()==y.get_node(); >} > >} > >} > >} ># 56 "/usr/include/boost/multi_index/ordered_index.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/multi_index/detail/ord_index_node.hpp" 1 3 4 ># 51 "/usr/include/boost/multi_index/detail/ord_index_node.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/uintptr_type.hpp" 1 3 4 ># 19 "/usr/include/boost/multi_index/detail/uintptr_type.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 35 "/usr/include/boost/multi_index/detail/uintptr_type.hpp" 3 4 >template<int N>struct uintptr_candidates; >template<>struct uintptr_candidates<-1>{typedef unsigned int type;}; >template<>struct uintptr_candidates<0> {typedef unsigned int type;}; >template<>struct uintptr_candidates<1> {typedef unsigned short type;}; >template<>struct uintptr_candidates<2> {typedef unsigned long type;}; > > >template<>struct uintptr_candidates<3> {typedef boost::ulong_long_type type;}; > > > > > > > >template<>struct uintptr_candidates<4> {typedef unsigned int type;}; > > >struct uintptr_aux >{ > static const int index= sizeof(void*)==sizeof(uintptr_candidates<0>::type)?0: sizeof(void*)==sizeof(uintptr_candidates<1>::type)?1: sizeof(void*)==sizeof(uintptr_candidates<2>::type)?2: sizeof(void*)==sizeof(uintptr_candidates<3>::type)?3: sizeof(void*)==sizeof(uintptr_candidates<4>::type)?4:-1 > > > > > ; > > static const bool has_uintptr_type=(index>=0); > > typedef uintptr_candidates<index>::type type; >}; > >typedef mpl::bool_<uintptr_aux::has_uintptr_type> has_uintptr_type; >typedef uintptr_aux::type uintptr_type; > >} > >} > >} ># 52 "/usr/include/boost/multi_index/detail/ord_index_node.hpp" 2 3 4 > > > > >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > >enum ordered_index_color{red=false,black=true}; >enum ordered_index_side{to_left=false,to_right=true}; > >template<typename Allocator> >struct ordered_index_node_impl; > >template<typename Allocator> >struct ordered_index_node_std_base >{ > typedef typename prevent_eti< > Allocator, > typename boost::detail::allocator::rebind_to< > Allocator, > ordered_index_node_impl<Allocator> > >::type > >::type::pointer pointer; > typedef typename prevent_eti< > Allocator, > typename boost::detail::allocator::rebind_to< > Allocator, > ordered_index_node_impl<Allocator> > >::type > >::type::const_pointer const_pointer; > typedef ordered_index_color& color_ref; > typedef pointer& parent_ref; > > ordered_index_color& color(){return color_;} > ordered_index_color color()const{return color_;} > pointer& parent(){return parent_;} > pointer parent()const{return parent_;} > pointer& left(){return left_;} > pointer left()const{return left_;} > pointer& right(){return right_;} > pointer right()const{return right_;} > >private: > ordered_index_color color_; > pointer parent_; > pointer left_; > pointer right_; >}; ># 124 "/usr/include/boost/multi_index/detail/ord_index_node.hpp" 3 4 >template<typename Allocator> >struct ordered_index_node_compressed_base >{ > typedef ordered_index_node_impl<Allocator>* pointer; > typedef const ordered_index_node_impl<Allocator>* const_pointer; > > struct color_ref > { > color_ref(uintptr_type* r_):r(r_){} > > operator ordered_index_color()const > { > return ordered_index_color(*r&uintptr_type(1)); > } > > color_ref& operator=(ordered_index_color c) > { > *r&=~uintptr_type(1); > *r|=uintptr_type(c); > return *this; > } > > color_ref& operator=(const color_ref& x) > { > return operator=(x.operator ordered_index_color()); > } > > private: > uintptr_type* r; > }; > > struct parent_ref > { > parent_ref(uintptr_type* r_):r(r_){} > > operator pointer()const > { > return (pointer)(void*)(*r&~uintptr_type(1)); > } > > parent_ref& operator=(pointer p) > { > *r=((uintptr_type)(void*)p)|(*r&uintptr_type(1)); > return *this; > } > > parent_ref& operator=(const parent_ref& x) > { > return operator=(x.operator pointer()); > } > > pointer operator->()const > { > return operator pointer(); > } > > private: > uintptr_type* r; > }; > > color_ref color(){return color_ref(&parentcolor_);} > ordered_index_color color()const > { > return ordered_index_color(parentcolor_&std::size_t(1ul)); > } > > parent_ref parent(){return parent_ref(&parentcolor_);} > pointer parent()const > { > return (pointer)(void*)(parentcolor_&~uintptr_type(1)); > } > > pointer& left(){return left_;} > pointer left()const{return left_;} > pointer& right(){return right_;} > pointer right()const{return right_;} > >private: > uintptr_type parentcolor_; > pointer left_; > pointer right_; >}; > > > > > >template<typename Allocator> >struct ordered_index_node_impl_base: > > > mpl::if_c< > !(has_uintptr_type::value)|| > (alignment_of<ordered_index_node_compressed_base<Allocator> >::value%2)|| > !(is_same< > typename prevent_eti< > Allocator, > typename boost::detail::allocator::rebind_to< > Allocator, > ordered_index_node_impl<Allocator> > >::type > >::type::pointer, > ordered_index_node_impl<Allocator>*>::value), > ordered_index_node_std_base<Allocator>, > ordered_index_node_compressed_base<Allocator> > >::type > > > > >{}; > >template<typename Allocator> >struct ordered_index_node_impl:ordered_index_node_impl_base<Allocator> >{ >private: > typedef ordered_index_node_impl_base<Allocator> super; > >public: > typedef typename super::color_ref color_ref; > typedef typename super::parent_ref parent_ref; > typedef typename super::pointer pointer; > typedef typename super::const_pointer const_pointer; > > > > static void increment(pointer& x) > { > if(x->right()!=pointer(0)){ > x=x->right(); > while(x->left()!=pointer(0))x=x->left(); > } > else{ > pointer y=x->parent(); > while(x==y->right()){ > x=y; > y=y->parent(); > } > if(x->right()!=y)x=y; > } > } > > static void decrement(pointer& x) > { > if(x->color()==red&&x->parent()->parent()==x){ > x=x->right(); > } > else if(x->left()!=pointer(0)){ > pointer y=x->left(); > while(y->right()!=pointer(0))y=y->right(); > x=y; > }else{ > pointer y=x->parent(); > while(x==y->left()){ > x=y; > y=y->parent(); > } > x=y; > } > } > > > > static void rotate_left(pointer x,parent_ref root) > { > pointer y=x->right(); > x->right()=y->left(); > if(y->left()!=pointer(0))y->left()->parent()=x; > y->parent()=x->parent(); > > if(x==root) root=y; > else if(x==x->parent()->left())x->parent()->left()=y; > else x->parent()->right()=y; > y->left()=x; > x->parent()=y; > } > > static pointer minimum(pointer x) > { > while(x->left()!=pointer(0))x=x->left(); > return x; > } > > static pointer maximum(pointer x) > { > while(x->right()!=pointer(0))x=x->right(); > return x; > } > > static void rotate_right(pointer x,parent_ref root) > { > pointer y=x->left(); > x->left()=y->right(); > if(y->right()!=pointer(0))y->right()->parent()=x; > y->parent()=x->parent(); > > if(x==root) root=y; > else if(x==x->parent()->right())x->parent()->right()=y; > else x->parent()->left()=y; > y->right()=x; > x->parent()=y; > } > > static void rebalance(pointer x,parent_ref root) > { > x->color()=red; > while(x!=root&&x->parent()->color()==red){ > if(x->parent()==x->parent()->parent()->left()){ > pointer y=x->parent()->parent()->right(); > if(y!=pointer(0)&&y->color()==red){ > x->parent()->color()=black; > y->color()=black; > x->parent()->parent()->color()=red; > x=x->parent()->parent(); > } > else{ > if(x==x->parent()->right()){ > x=x->parent(); > rotate_left(x,root); > } > x->parent()->color()=black; > x->parent()->parent()->color()=red; > rotate_right(x->parent()->parent(),root); > } > } > else{ > pointer y=x->parent()->parent()->left(); > if(y!=pointer(0)&&y->color()==red){ > x->parent()->color()=black; > y->color()=black; > x->parent()->parent()->color()=red; > x=x->parent()->parent(); > } > else{ > if(x==x->parent()->left()){ > x=x->parent(); > rotate_right(x,root); > } > x->parent()->color()=black; > x->parent()->parent()->color()=red; > rotate_left(x->parent()->parent(),root); > } > } > } > root->color()=black; > } > > static void link( > pointer x,ordered_index_side side,pointer position,pointer header) > { > if(side==to_left){ > position->left()=x; > if(position==header){ > header->parent()=x; > header->right()=x; > } > else if(position==header->left()){ > header->left()=x; > } > } > else{ > position->right()=x; > if(position==header->right()){ > header->right()=x; > } > } > x->parent()=position; > x->left()=pointer(0); > x->right()=pointer(0); > ordered_index_node_impl::rebalance(x,header->parent()); > } > > static pointer rebalance_for_erase( > pointer z,parent_ref root,pointer& leftmost,pointer& rightmost) > { > pointer y=z; > pointer x=pointer(0); > pointer x_parent=pointer(0); > if(y->left()==pointer(0)){ > x=y->right(); > } > else{ > if(y->right()==pointer(0)){ > x=y->left(); > } > else{ > y=y->right(); > while(y->left()!=pointer(0))y=y->left(); > x=y->right(); > } > } > if(y!=z){ > z->left()->parent()=y; > y->left()=z->left(); > if(y!=z->right()){ > x_parent=y->parent(); > if(x!=pointer(0))x->parent()=y->parent(); > y->parent()->left()=x; > y->right()=z->right(); > z->right()->parent()=y; > } > else{ > x_parent=y; > } > > if(root==z) root=y; > else if(z->parent()->left()==z)z->parent()->left()=y; > else z->parent()->right()=y; > y->parent()=z->parent(); > ordered_index_color c=y->color(); > y->color()=z->color(); > z->color()=c; > y=z; > } > else{ > x_parent=y->parent(); > if(x!=pointer(0))x->parent()=y->parent(); > if(root==z){ > root=x; > } > else{ > if(z->parent()->left()==z)z->parent()->left()=x; > else z->parent()->right()=x; > } > if(leftmost==z){ > if(z->right()==pointer(0)){ > leftmost=z->parent(); > } > else{ > leftmost=minimum(x); > } > } > if(rightmost==z){ > if(z->left()==pointer(0)){ > rightmost=z->parent(); > } > else{ > rightmost=maximum(x); > } > } > } > if(y->color()!=red){ > while(x!=root&&(x==pointer(0)|| x->color()==black)){ > if(x==x_parent->left()){ > pointer w=x_parent->right(); > if(w->color()==red){ > w->color()=black; > x_parent->color()=red; > rotate_left(x_parent,root); > w=x_parent->right(); > } > if((w->left()==pointer(0)||w->left()->color()==black) && > (w->right()==pointer(0)||w->right()->color()==black)){ > w->color()=red; > x=x_parent; > x_parent=x_parent->parent(); > } > else{ > if(w->right()==pointer(0 ) > || w->right()->color()==black){ > if(w->left()!=pointer(0)) w->left()->color()=black; > w->color()=red; > rotate_right(w,root); > w=x_parent->right(); > } > w->color()=x_parent->color(); > x_parent->color()=black; > if(w->right()!=pointer(0))w->right()->color()=black; > rotate_left(x_parent,root); > break; > } > } > else{ > pointer w=x_parent->left(); > if(w->color()==red){ > w->color()=black; > x_parent->color()=red; > rotate_right(x_parent,root); > w=x_parent->left(); > } > if((w->right()==pointer(0)||w->right()->color()==black) && > (w->left()==pointer(0)||w->left()->color()==black)){ > w->color()=red; > x=x_parent; > x_parent=x_parent->parent(); > } > else{ > if(w->left()==pointer(0)||w->left()->color()==black){ > if(w->right()!=pointer(0))w->right()->color()=black; > w->color()=red; > rotate_left(w,root); > w=x_parent->left(); > } > w->color()=x_parent->color(); > x_parent->color()=black; > if(w->left()!=pointer(0))w->left()->color()=black; > rotate_right(x_parent,root); > break; > } > } > } > if(x!=pointer(0))x->color()=black; > } > return y; > } > > static void restore(pointer x,pointer position,pointer header) > { > if(position->left()==pointer(0)||position->left()==header){ > link(x,to_left,position,header); > } > else{ > decrement(position); > link(x,to_right,position,header); > } > } ># 556 "/usr/include/boost/multi_index/detail/ord_index_node.hpp" 3 4 >}; > >template<typename Super> >struct ordered_index_node_trampoline: > prevent_eti< > Super, > ordered_index_node_impl< > typename boost::detail::allocator::rebind_to< > typename Super::allocator_type, > char > >::type > > > >::type >{ > typedef typename prevent_eti< > Super, > ordered_index_node_impl< > typename boost::detail::allocator::rebind_to< > typename Super::allocator_type, > char > >::type > > > >::type impl_type; >}; > >template<typename Super> >struct ordered_index_node:Super,ordered_index_node_trampoline<Super> >{ >private: > typedef ordered_index_node_trampoline<Super> trampoline; > >public: > typedef typename trampoline::impl_type impl_type; > typedef typename trampoline::color_ref impl_color_ref; > typedef typename trampoline::parent_ref impl_parent_ref; > typedef typename trampoline::pointer impl_pointer; > typedef typename trampoline::const_pointer const_impl_pointer; > > impl_color_ref color(){return trampoline::color();} > ordered_index_color color()const{return trampoline::color();} > impl_parent_ref parent(){return trampoline::parent();} > impl_pointer parent()const{return trampoline::parent();} > impl_pointer& left(){return trampoline::left();} > impl_pointer left()const{return trampoline::left();} > impl_pointer& right(){return trampoline::right();} > impl_pointer right()const{return trampoline::right();} > > impl_pointer impl() > { > return static_cast<impl_pointer>( > static_cast<impl_type*>(static_cast<trampoline*>(this))); > } > > const_impl_pointer impl()const > { > return static_cast<const_impl_pointer>( > static_cast<const impl_type*>(static_cast<const trampoline*>(this))); > } > > static ordered_index_node* from_impl(impl_pointer x) > { > return static_cast<ordered_index_node*>( > static_cast<trampoline*>(&*x)); > } > > static const ordered_index_node* from_impl(const_impl_pointer x) > { > return static_cast<const ordered_index_node*>( > static_cast<const trampoline*>(&*x)); > } > > > > static void increment(ordered_index_node*& x) > { > impl_pointer xi=x->impl(); > trampoline::increment(xi); > x=from_impl(xi); > } > > static void decrement(ordered_index_node*& x) > { > impl_pointer xi=x->impl(); > trampoline::decrement(xi); > x=from_impl(xi); > } >}; > >} > >} > >} ># 60 "/usr/include/boost/multi_index/ordered_index.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/ord_index_ops.hpp" 1 3 4 ># 46 "/usr/include/boost/multi_index/detail/ord_index_ops.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > > >template< > typename Node,typename KeyFromValue, > typename CompatibleKey,typename CompatibleCompare >> >inline Node* ordered_index_find( > Node* top,Node* y,const KeyFromValue& key,const CompatibleKey& x, > const CompatibleCompare& comp) >{ > Node* y0=y; > > while (top){ > if(!comp(key(top->value()),x)){ > y=top; > top=Node::from_impl(top->left()); > } > else top=Node::from_impl(top->right()); > } > > return (y==y0||comp(x,key(y->value())))?y0:y; >} > >template< > typename Node,typename KeyFromValue, > typename CompatibleKey,typename CompatibleCompare >> >inline Node* ordered_index_lower_bound( > Node* top,Node* y,const KeyFromValue& key,const CompatibleKey& x, > const CompatibleCompare& comp) >{ > while(top){ > if(!comp(key(top->value()),x)){ > y=top; > top=Node::from_impl(top->left()); > } > else top=Node::from_impl(top->right()); > } > > return y; >} > >template< > typename Node,typename KeyFromValue, > typename CompatibleKey,typename CompatibleCompare >> >inline Node* ordered_index_upper_bound( > Node* top,Node* y,const KeyFromValue& key,const CompatibleKey& x, > const CompatibleCompare& comp) >{ > while(top){ > if(comp(x,key(top->value()))){ > y=top; > top=Node::from_impl(top->left()); > } > else top=Node::from_impl(top->right()); > } > > return y; >} > >template< > typename Node,typename KeyFromValue, > typename CompatibleKey,typename CompatibleCompare >> >inline std::pair<Node*,Node*> ordered_index_equal_range( > Node* top,Node* y,const KeyFromValue& key,const CompatibleKey& x, > const CompatibleCompare& comp) >{ > while(top){ > if(comp(key(top->value()),x)){ > top=Node::from_impl(top->right()); > } > else if(comp(x,key(top->value()))){ > y=top; > top=Node::from_impl(top->left()); > } > else{ > return std::pair<Node*,Node*>( > ordered_index_lower_bound(Node::from_impl(top->left()),top,key,x,comp), > ordered_index_upper_bound(Node::from_impl(top->right()),y,key,x,comp)); > } > } > > return std::pair<Node*,Node*>(y,y); >} > >} > >} > >} ># 61 "/usr/include/boost/multi_index/ordered_index.hpp" 2 3 4 > > > ># 1 "/usr/include/boost/multi_index/detail/unbounded.hpp" 1 3 4 ># 19 "/usr/include/boost/multi_index/detail/unbounded.hpp" 3 4 >namespace boost{ > >namespace multi_index{ ># 45 "/usr/include/boost/multi_index/detail/unbounded.hpp" 3 4 >namespace detail{class unbounded_helper;} > >detail::unbounded_helper unbounded(detail::unbounded_helper); > >namespace detail{ > >class unbounded_helper >{ > unbounded_helper(){} > unbounded_helper(const unbounded_helper&){} > friend unbounded_helper multi_index::unbounded(unbounded_helper); >}; > >typedef unbounded_helper (*unbounded_type)(unbounded_helper); > >} > >inline detail::unbounded_helper unbounded(detail::unbounded_helper) >{ > return detail::unbounded_helper(); >} > > > > >namespace detail{ > >struct none_unbounded_tag{}; >struct lower_unbounded_tag{}; >struct upper_unbounded_tag{}; >struct both_unbounded_tag{}; > >} > >} > >} ># 65 "/usr/include/boost/multi_index/ordered_index.hpp" 2 3 4 ># 1 "/usr/include/boost/multi_index/detail/value_compare.hpp" 1 3 4 ># 20 "/usr/include/boost/multi_index/detail/value_compare.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > >template<typename Value,typename KeyFromValue,typename Compare> >struct value_comparison:std::binary_function<Value,Value,bool> >{ > value_comparison( > const KeyFromValue& key_=KeyFromValue(),const Compare& comp_=Compare()): > key(key_),comp(comp_) > { > } > > bool operator()( > typename call_traits<Value>::param_type x, > typename call_traits<Value>::param_type y)const > { > return comp(key(x),key(y)); > } > >private: > KeyFromValue key; > Compare comp; >}; > >} > >} > >} ># 66 "/usr/include/boost/multi_index/ordered_index.hpp" 2 3 4 ># 80 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 ># 1 "/usr/include/boost/multi_index/detail/duplicates_iterator.hpp" 1 3 4 ># 20 "/usr/include/boost/multi_index/detail/duplicates_iterator.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ > > > > > >template<typename Node,typename Predicate> >class duplicates_iterator >{ >public: > typedef typename Node::value_type value_type; > typedef std::ptrdiff_t difference_type; > typedef const typename Node::value_type* pointer; > typedef const typename Node::value_type& reference; > typedef std::forward_iterator_tag iterator_category; > > duplicates_iterator(Node* node_,Node* end_,Predicate pred_): > node(node_),begin_chunk(0),end(end_),pred(pred_) > { > advance(); > } > > duplicates_iterator(Node* end_,Predicate pred_): > node(end_),begin_chunk(end_),end(end_),pred(pred_) > { > } > > reference operator*()const > { > return node->value(); > } > > pointer operator->()const > { > return &node->value(); > } > > duplicates_iterator& operator++() > { > Node::increment(node); > sync(); > return *this; > } > > duplicates_iterator operator++(int) > { > duplicates_iterator tmp(*this); > ++(*this); > return tmp; > } > > Node* get_node()const{return node;} > >private: > void sync() > { > if(node!=end&&pred(begin_chunk->value(),node->value()))advance(); > } > > void advance() > { > for(Node* node2=node;node!=end;node=node2){ > Node::increment(node2); > if(node2!=end&&!pred(node->value(),node2->value()))break; > } > begin_chunk=node; > } > > Node* node; > Node* begin_chunk; > Node* end; > Predicate pred; >}; > >template<typename Node,typename Predicate> >bool operator==( > const duplicates_iterator<Node,Predicate>& x, > const duplicates_iterator<Node,Predicate>& y) >{ > return x.get_node()==y.get_node(); >} > >template<typename Node,typename Predicate> >bool operator!=( > const duplicates_iterator<Node,Predicate>& x, > const duplicates_iterator<Node,Predicate>& y) >{ > return !(x==y); >} > >} > >} > >} ># 81 "/usr/include/boost/multi_index/ordered_index.hpp" 2 3 4 ># 96 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 >namespace boost{ > >namespace multi_index{ > >namespace detail{ ># 109 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 >struct ordered_unique_tag{}; >struct ordered_non_unique_tag{}; > >template< > typename KeyFromValue,typename Compare, > typename SuperMeta,typename TagList,typename Category >> >class ordered_index: > protected SuperMeta::type ># 131 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 >{ ># 142 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 > typedef typename SuperMeta::type super; > >protected: > typedef ordered_index_node< > typename super::node_type> node_type; > >private: > typedef typename node_type::impl_type node_impl_type; > typedef typename node_impl_type::pointer node_impl_pointer; > >public: > > > typedef typename KeyFromValue::result_type key_type; > typedef typename node_type::value_type value_type; > typedef KeyFromValue key_from_value; > typedef Compare key_compare; > typedef value_comparison< > value_type,KeyFromValue,Compare> value_compare; > typedef tuple<key_from_value,key_compare> ctor_args; > typedef typename super::final_allocator_type allocator_type; > typedef typename allocator_type::reference reference; > typedef typename allocator_type::const_reference const_reference; ># 178 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 > typedef bidir_node_iterator<node_type> iterator; > > > typedef iterator const_iterator; > > typedef std::size_t size_type; > typedef std::ptrdiff_t difference_type; > typedef typename allocator_type::pointer pointer; > typedef typename allocator_type::const_pointer const_pointer; > typedef typename > boost::reverse_iterator<iterator> reverse_iterator; > typedef typename > boost::reverse_iterator<const_iterator> const_reverse_iterator; > typedef TagList tag_list; > >protected: > typedef typename super::final_node_type final_node_type; > typedef tuples::cons< > ctor_args, > typename super::ctor_args_list> ctor_args_list; > typedef typename mpl::push_front< > typename super::index_type_list, > ordered_index>::type index_type_list; > typedef typename mpl::push_front< > typename super::iterator_type_list, > iterator>::type iterator_type_list; > typedef typename mpl::push_front< > typename super::const_iterator_type_list, > const_iterator>::type const_iterator_type_list; > typedef typename super::copy_map_type copy_map_type; > > > typedef typename super::index_saver_type index_saver_type; > typedef typename super::index_loader_type index_loader_type; > > >private: ># 225 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 > typedef typename call_traits< > value_type>::param_type value_param_type; > typedef typename call_traits< > key_type>::param_type key_param_type; > > > > > > typedef std::pair<iterator,bool> emplace_return_type; > >public: > > > > > > > ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& operator=( > const ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& x) > { > this->final()=x.final(); > return *this; > } > > > ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& operator=( > std::initializer_list<value_type> list) > { > this->final()=list; > return *this; > } > > > allocator_type get_allocator()const > { > return this->final().get_allocator(); > } > > > > iterator begin(){return make_iterator(leftmost());} > const_iterator begin()const{return make_iterator(leftmost());} > iterator end(){return make_iterator(header());} > const_iterator end()const{return make_iterator(header());} > reverse_iterator rbegin(){return make_reverse_iterator(end());} > const_reverse_iterator rbegin()const{return make_reverse_iterator(end());} > reverse_iterator rend(){return make_reverse_iterator(begin());} > const_reverse_iterator rend()const{return make_reverse_iterator(begin());} > const_iterator cbegin()const{return begin();} > const_iterator cend()const{return end();} > const_reverse_iterator crbegin()const{return rbegin();} > const_reverse_iterator crend()const{return rend();} > > iterator iterator_to(const value_type& x) > { > return make_iterator(node_from_value<node_type>(&x)); > } > > const_iterator iterator_to(const value_type& x)const > { > return make_iterator(node_from_value<node_type>(&x)); > } > > > > bool empty()const{return this->final_empty_();} > size_type size()const{return this->final_size_();} > size_type max_size()const{return this->final_max_size_();} > > > > template<typename... Args> emplace_return_type emplace(Args&&... args) { return emplace_impl(std::forward<Args>(args)...); } > > > template<typename... Args> iterator emplace_hint( iterator position,Args&&... args) { return emplace_hint_impl(position,std::forward<Args>(args)...); } > > > std::pair<iterator,bool> insert(const value_type& x) > { > ; > std::pair<final_node_type*,bool> p=this->final_insert_(x); > return std::pair<iterator,bool>(make_iterator(p.first),p.second); > } > > std::pair<iterator,bool> insert(value_type && x) > { > ; > std::pair<final_node_type*,bool> p=this->final_insert_rv_(x); > return std::pair<iterator,bool>(make_iterator(p.first),p.second); > } > > iterator insert(iterator position,const value_type& x) > { > ((void)0);; > ((void)0);; > ; > std::pair<final_node_type*,bool> p=this->final_insert_( > x,static_cast<final_node_type*>(position.get_node())); > return make_iterator(p.first); > } > > iterator insert(iterator position,value_type && x) > { > ((void)0);; > ((void)0);; > ; > std::pair<final_node_type*,bool> p=this->final_insert_rv_( > x,static_cast<final_node_type*>(position.get_node())); > return make_iterator(p.first); > } > > template<typename InputIterator> > void insert(InputIterator first,InputIterator last) > { > ; > node_type* hint=header(); > for(;first!=last;++first){ > hint=this->final_insert_ref_( > *first,static_cast<final_node_type*>(hint)).first; > node_type::increment(hint); > } > } > > > void insert(std::initializer_list<value_type> list) > { > insert(list.begin(),list.end()); > } > > > iterator erase(iterator position) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > this->final_erase_(static_cast<final_node_type*>(position++.get_node())); > return position; > } > > size_type erase(key_param_type x) > { > ; > std::pair<iterator,iterator> p=equal_range(x); > size_type s=0; > while(p.first!=p.second){ > p.first=erase(p.first); > ++s; > } > return s; > } > > iterator erase(iterator first,iterator last) > { > ((void)0);; > ((void)0);; > ((void)0);; > ((void)0);; > ((void)0);; > ; > while(first!=last){ > first=erase(first); > } > return first; > } > > bool replace(iterator position,const value_type& x) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > return this->final_replace_( > x,static_cast<final_node_type*>(position.get_node())); > } > > bool replace(iterator position,value_type && x) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > return this->final_replace_rv_( > x,static_cast<final_node_type*>(position.get_node())); > } > > template<typename Modifier> > bool modify(iterator position,Modifier mod) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; ># 429 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 > return this->final_modify_( > mod,static_cast<final_node_type*>(position.get_node())); > } > > template<typename Modifier,typename Rollback> > bool modify(iterator position,Modifier mod,Rollback back) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; ># 450 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 > return this->final_modify_( > mod,back,static_cast<final_node_type*>(position.get_node())); > } > > template<typename Modifier> > bool modify_key(iterator position,Modifier mod) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > return modify( > position,modify_key_adaptor<Modifier,value_type,KeyFromValue>(mod,key)); > } > > template<typename Modifier,typename Rollback> > bool modify_key(iterator position,Modifier mod,Rollback back) > { > ((void)0);; > ((void)0);; > ((void)0);; > ; > return modify( > position, > modify_key_adaptor<Modifier,value_type,KeyFromValue>(mod,key), > modify_key_adaptor<Rollback,value_type,KeyFromValue>(back,key)); > } > > void swap(ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& x) > { > ; > ; > this->final_swap_(x.final()); > } > > void clear() > { > ; > this->final_clear_(); > } > > > > key_from_value key_extractor()const{return key;} > key_compare key_comp()const{return comp_;} > value_compare value_comp()const{return value_compare(key,comp_);} > > > > > > > > template<typename CompatibleKey> > iterator find(const CompatibleKey& x)const > { > return make_iterator(ordered_index_find(root(),header(),key,x,comp_)); > } > > template<typename CompatibleKey,typename CompatibleCompare> > iterator find( > const CompatibleKey& x,const CompatibleCompare& comp)const > { > return make_iterator(ordered_index_find(root(),header(),key,x,comp)); > } > > template<typename CompatibleKey> > size_type count(const CompatibleKey& x)const > { > return count(x,comp_); > } > > template<typename CompatibleKey,typename CompatibleCompare> > size_type count(const CompatibleKey& x,const CompatibleCompare& comp)const > { > std::pair<iterator,iterator> p=equal_range(x,comp); > size_type n=std::distance(p.first,p.second); > return n; > } > > template<typename CompatibleKey> > iterator lower_bound(const CompatibleKey& x)const > { > return make_iterator( > ordered_index_lower_bound(root(),header(),key,x,comp_)); > } > > template<typename CompatibleKey,typename CompatibleCompare> > iterator lower_bound( > const CompatibleKey& x,const CompatibleCompare& comp)const > { > return make_iterator( > ordered_index_lower_bound(root(),header(),key,x,comp)); > } > > template<typename CompatibleKey> > iterator upper_bound(const CompatibleKey& x)const > { > return make_iterator( > ordered_index_upper_bound(root(),header(),key,x,comp_)); > } > > template<typename CompatibleKey,typename CompatibleCompare> > iterator upper_bound( > const CompatibleKey& x,const CompatibleCompare& comp)const > { > return make_iterator( > ordered_index_upper_bound(root(),header(),key,x,comp)); > } > > template<typename CompatibleKey> > std::pair<iterator,iterator> equal_range( > const CompatibleKey& x)const > { > std::pair<node_type*,node_type*> p= > ordered_index_equal_range(root(),header(),key,x,comp_); > return std::pair<iterator,iterator>( > make_iterator(p.first),make_iterator(p.second)); > } > > template<typename CompatibleKey,typename CompatibleCompare> > std::pair<iterator,iterator> equal_range( > const CompatibleKey& x,const CompatibleCompare& comp)const > { > std::pair<node_type*,node_type*> p= > ordered_index_equal_range(root(),header(),key,x,comp); > return std::pair<iterator,iterator>( > make_iterator(p.first),make_iterator(p.second)); > } > > > > template<typename LowerBounder,typename UpperBounder> > std::pair<iterator,iterator> > range(LowerBounder lower,UpperBounder upper)const > { > typedef typename mpl::if_< > is_same<LowerBounder,unbounded_type>, > typename mpl::if_< > is_same<UpperBounder,unbounded_type>, > both_unbounded_tag, > lower_unbounded_tag > >::type, > typename mpl::if_< > is_same<UpperBounder,unbounded_type>, > upper_unbounded_tag, > none_unbounded_tag > >::type > >::type dispatch; > > return range(lower,upper,dispatch()); > } > >protected: > ordered_index(const ctor_args_list& args_list,const allocator_type& al): > super(args_list.get_tail(),al), > key(tuples::get<0>(args_list.get_head())), > comp_(tuples::get<1>(args_list.get_head())) > { > empty_initialize(); > } > > ordered_index( > const ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& x): > super(x), > > > > > > key(x.key), > comp_(x.comp_) > { > > > > } > > ordered_index( > const ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& x, > do_not_copy_elements_tag): > super(x,do_not_copy_elements_tag()), > > > > > > key(x.key), > comp_(x.comp_) > { > empty_initialize(); > } > > ~ordered_index() > { > > } > > > > > > > iterator make_iterator(node_type* node){return iterator(node);} > const_iterator make_iterator(node_type* node)const > {return const_iterator(node);} > > > void copy_( > const ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& x, > const copy_map_type& map) > { > if(!x.root()){ > empty_initialize(); > } > else{ > header()->color()=x.header()->color(); > > node_type* root_cpy=map.find(static_cast<final_node_type*>(x.root())); > header()->parent()=root_cpy->impl(); > > node_type* leftmost_cpy=map.find( > static_cast<final_node_type*>(x.leftmost())); > header()->left()=leftmost_cpy->impl(); > > node_type* rightmost_cpy=map.find( > static_cast<final_node_type*>(x.rightmost())); > header()->right()=rightmost_cpy->impl(); > > typedef typename copy_map_type::const_iterator copy_map_iterator; > for(copy_map_iterator it=map.begin(),it_end=map.end();it!=it_end;++it){ > node_type* org=it->first; > node_type* cpy=it->second; > > cpy->color()=org->color(); > > node_impl_pointer parent_org=org->parent(); > if(parent_org==node_impl_pointer(0))cpy->parent()=node_impl_pointer(0); > else{ > node_type* parent_cpy=map.find( > static_cast<final_node_type*>(node_type::from_impl(parent_org))); > cpy->parent()=parent_cpy->impl(); > if(parent_org->left()==org->impl()){ > parent_cpy->left()=cpy->impl(); > } > else if(parent_org->right()==org->impl()){ > > parent_cpy->right()=cpy->impl(); > } > } > > if(org->left()==node_impl_pointer(0)) > cpy->left()=node_impl_pointer(0); > if(org->right()==node_impl_pointer(0)) > cpy->right()=node_impl_pointer(0); > } > } > > super::copy_(x,map); > } > > template<typename Variant> > node_type* insert_(value_param_type v,node_type* x,Variant variant) > { > link_info inf; > if(!link_point(key(v),inf,Category())){ > return node_type::from_impl(inf.pos); > } > > node_type* res=static_cast<node_type*>(super::insert_(v,x,variant)); > if(res==x){ > node_impl_type::link(x->impl(),inf.side,inf.pos,header()->impl()); > } > return res; > } > > template<typename Variant> > node_type* insert_( > value_param_type v,node_type* position,node_type* x,Variant variant) > { > link_info inf; > if(!hinted_link_point(key(v),position,inf,Category())){ > return node_type::from_impl(inf.pos); > } > > node_type* res=static_cast<node_type*>(super::insert_(v,position,x,variant)); > if(res==x){ > node_impl_type::link(x->impl(),inf.side,inf.pos,header()->impl()); > } > return res; > } > > void erase_(node_type* x) > { > node_impl_type::rebalance_for_erase( > x->impl(),header()->parent(),header()->left(),header()->right()); > super::erase_(x); > > > > > } > > void delete_all_nodes_() > { > delete_all_nodes(root()); > } > > void clear_() > { > super::clear_(); > empty_initialize(); > > > > > } > > void swap_(ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& x) > { > std::swap(key,x.key); > std::swap(comp_,x.comp_); > > > > > > super::swap_(x); > } > > void swap_elements_( > ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& x) > { > > > > > super::swap_elements_(x); > } > > template<typename Variant> > bool replace_(value_param_type v,node_type* x,Variant variant) > { > if(in_place(v,x,Category())){ > return super::replace_(v,x,variant); > } > > node_type* next=x; > node_type::increment(next); > > node_impl_type::rebalance_for_erase( > x->impl(),header()->parent(),header()->left(),header()->right()); > > { try{ > link_info inf; > if(link_point(key(v),inf,Category())&&super::replace_(v,x,variant)){ > node_impl_type::link(x->impl(),inf.side,inf.pos,header()->impl()); > return true; > } > node_impl_type::restore(x->impl(),next->impl(),header()->impl()); > return false; > } > catch(...){ > node_impl_type::restore(x->impl(),next->impl(),header()->impl()); > throw;; > } > } > } > > bool modify_(node_type* x) > { > bool b; > { try{ > b=in_place(x->value(),x,Category()); > } > catch(...){ > erase_(x); > throw;; > } > } > if(!b){ > node_impl_type::rebalance_for_erase( > x->impl(),header()->parent(),header()->left(),header()->right()); > { try{ > link_info inf; > if(!link_point(key(x->value()),inf,Category())){ > super::erase_(x); > > > > > return false; > } > node_impl_type::link(x->impl(),inf.side,inf.pos,header()->impl()); > } > catch(...){ > super::erase_(x); > > > > > > throw;; > } > } > } > > { try{ > if(!super::modify_(x)){ > node_impl_type::rebalance_for_erase( > x->impl(),header()->parent(),header()->left(),header()->right()); > > > > > > return false; > } > else return true; > } > catch(...){ > node_impl_type::rebalance_for_erase( > x->impl(),header()->parent(),header()->left(),header()->right()); > > > > > > throw;; > } > } > } > > bool modify_rollback_(node_type* x) > { > if(in_place(x->value(),x,Category())){ > return super::modify_rollback_(x); > } > > node_type* next=x; > node_type::increment(next); > > node_impl_type::rebalance_for_erase( > x->impl(),header()->parent(),header()->left(),header()->right()); > > { try{ > link_info inf; > if(link_point(key(x->value()),inf,Category())&& > super::modify_rollback_(x)){ > node_impl_type::link(x->impl(),inf.side,inf.pos,header()->impl()); > return true; > } > node_impl_type::restore(x->impl(),next->impl(),header()->impl()); > return false; > } > catch(...){ > node_impl_type::restore(x->impl(),next->impl(),header()->impl()); > throw;; > } > } > } > > > > > template<typename Archive> > void save_( > Archive& ar,const unsigned int version,const index_saver_type& sm)const > { > save_(ar,version,sm,Category()); > } > > template<typename Archive> > void load_(Archive& ar,const unsigned int version,const index_loader_type& lm) > { > load_(ar,version,lm,Category()); > } ># 978 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 >private: > node_type* header()const{return this->final_header();} > node_type* root()const{return node_type::from_impl(header()->parent());} > node_type* leftmost()const{return node_type::from_impl(header()->left());} > node_type* rightmost()const{return node_type::from_impl(header()->right());} > > void empty_initialize() > { > header()->color()=red; > > > header()->parent()=node_impl_pointer(0); > header()->left()=header()->impl(); > header()->right()=header()->impl(); > } > > struct link_info > { > link_info():side(to_left){} > > ordered_index_side side; > node_impl_pointer pos; > }; > > bool link_point(key_param_type k,link_info& inf,ordered_unique_tag) > { > node_type* y=header(); > node_type* x=root(); > bool c=true; > while(x){ > y=x; > c=comp_(k,key(x->value())); > x=node_type::from_impl(c?x->left():x->right()); > } > node_type* yy=y; > if(c){ > if(yy==leftmost()){ > inf.side=to_left; > inf.pos=y->impl(); > return true; > } > else node_type::decrement(yy); > } > > if(comp_(key(yy->value()),k)){ > inf.side=c?to_left:to_right; > inf.pos=y->impl(); > return true; > } > else{ > inf.pos=yy->impl(); > return false; > } > } > > bool link_point(key_param_type k,link_info& inf,ordered_non_unique_tag) > { > node_type* y=header(); > node_type* x=root(); > bool c=true; > while (x){ > y=x; > c=comp_(k,key(x->value())); > x=node_type::from_impl(c?x->left():x->right()); > } > inf.side=c?to_left:to_right; > inf.pos=y->impl(); > return true; > } > > bool lower_link_point(key_param_type k,link_info& inf,ordered_non_unique_tag) > { > node_type* y=header(); > node_type* x=root(); > bool c=false; > while (x){ > y=x; > c=comp_(key(x->value()),k); > x=node_type::from_impl(c?x->right():x->left()); > } > inf.side=c?to_right:to_left; > inf.pos=y->impl(); > return true; > } > > bool hinted_link_point( > key_param_type k,node_type* position,link_info& inf,ordered_unique_tag) > { > if(position->impl()==header()->left()){ > if(size()>0&&comp_(k,key(position->value()))){ > inf.side=to_left; > inf.pos=position->impl(); > return true; > } > else return link_point(k,inf,ordered_unique_tag()); > } > else if(position==header()){ > if(comp_(key(rightmost()->value()),k)){ > inf.side=to_right; > inf.pos=rightmost()->impl(); > return true; > } > else return link_point(k,inf,ordered_unique_tag()); > } > else{ > node_type* before=position; > node_type::decrement(before); > if(comp_(key(before->value()),k)&&comp_(k,key(position->value()))){ > if(before->right()==node_impl_pointer(0)){ > inf.side=to_right; > inf.pos=before->impl(); > return true; > } > else{ > inf.side=to_left; > inf.pos=position->impl(); > return true; > } > } > else return link_point(k,inf,ordered_unique_tag()); > } > } > > bool hinted_link_point( > key_param_type k,node_type* position,link_info& inf,ordered_non_unique_tag) > { > if(position->impl()==header()->left()){ > if(size()>0&&!comp_(key(position->value()),k)){ > inf.side=to_left; > inf.pos=position->impl(); > return true; > } > else return lower_link_point(k,inf,ordered_non_unique_tag()); > } > else if(position==header()){ > if(!comp_(k,key(rightmost()->value()))){ > inf.side=to_right; > inf.pos=rightmost()->impl(); > return true; > } > else return link_point(k,inf,ordered_non_unique_tag()); > } > else{ > node_type* before=position; > node_type::decrement(before); > if(!comp_(k,key(before->value()))){ > if(!comp_(key(position->value()),k)){ > if(before->right()==node_impl_pointer(0)){ > inf.side=to_right; > inf.pos=before->impl(); > return true; > } > else{ > inf.side=to_left; > inf.pos=position->impl(); > return true; > } > } > else return lower_link_point(k,inf,ordered_non_unique_tag()); > } > else return link_point(k,inf,ordered_non_unique_tag()); > } > } > > void delete_all_nodes(node_type* x) > { > if(!x)return; > > delete_all_nodes(node_type::from_impl(x->left())); > delete_all_nodes(node_type::from_impl(x->right())); > this->final_delete_node_(static_cast<final_node_type*>(x)); > } > > bool in_place(value_param_type v,node_type* x,ordered_unique_tag) > { > node_type* y; > if(x!=leftmost()){ > y=x; > node_type::decrement(y); > if(!comp_(key(y->value()),key(v)))return false; > } > > y=x; > node_type::increment(y); > return y==header()||comp_(key(v),key(y->value())); > } > > bool in_place(value_param_type v,node_type* x,ordered_non_unique_tag) > { > node_type* y; > if(x!=leftmost()){ > y=x; > node_type::decrement(y); > if(comp_(key(v),key(y->value())))return false; > } > > y=x; > node_type::increment(y); > return y==header()||!comp_(key(y->value()),key(v)); > } ># 1187 "/usr/include/boost/multi_index/ordered_index.hpp" 3 4 > template<typename... Args> > std::pair<iterator,bool> emplace_impl(Args&&... args) > { > ; > std::pair<final_node_type*,bool>p= > this->final_emplace_(std::forward<Args>(args)...); > return std::pair<iterator,bool>(make_iterator(p.first),p.second); > } > > template<typename... Args> > iterator emplace_hint_impl( > iterator position,Args&&... args) > { > ((void)0);; > ((void)0);; > ; > std::pair<final_node_type*,bool>p= > this->final_emplace_hint_( > static_cast<final_node_type*>(position.get_node()), > std::forward<Args>(args)...); > return make_iterator(p.first); > } > > template<typename LowerBounder,typename UpperBounder> > std::pair<iterator,iterator> > range(LowerBounder lower,UpperBounder upper,none_unbounded_tag)const > { > node_type* y=header(); > node_type* z=root(); > > while(z){ > if(!lower(key(z->value()))){ > z=node_type::from_impl(z->right()); > } > else if(!upper(key(z->value()))){ > y=z; > z=node_type::from_impl(z->left()); > } > else{ > return std::pair<iterator,iterator>( > make_iterator( > lower_range(node_type::from_impl(z->left()),z,lower)), > make_iterator( > upper_range(node_type::from_impl(z->right()),y,upper))); > } > } > > return std::pair<iterator,iterator>(make_iterator(y),make_iterator(y)); > } > > template<typename LowerBounder,typename UpperBounder> > std::pair<iterator,iterator> > range(LowerBounder,UpperBounder upper,lower_unbounded_tag)const > { > return std::pair<iterator,iterator>( > begin(), > make_iterator(upper_range(root(),header(),upper))); > } > > template<typename LowerBounder,typename UpperBounder> > std::pair<iterator,iterator> > range(LowerBounder lower,UpperBounder,upper_unbounded_tag)const > { > return std::pair<iterator,iterator>( > make_iterator(lower_range(root(),header(),lower)), > end()); > } > > template<typename LowerBounder,typename UpperBounder> > std::pair<iterator,iterator> > range(LowerBounder,UpperBounder,both_unbounded_tag)const > { > return std::pair<iterator,iterator>(begin(),end()); > } > > template<typename LowerBounder> > node_type * lower_range(node_type* top,node_type* y,LowerBounder lower)const > { > while(top){ > if(lower(key(top->value()))){ > y=top; > top=node_type::from_impl(top->left()); > } > else top=node_type::from_impl(top->right()); > } > > return y; > } > > template<typename UpperBounder> > node_type * upper_range(node_type* top,node_type* y,UpperBounder upper)const > { > while(top){ > if(!upper(key(top->value()))){ > y=top; > top=node_type::from_impl(top->left()); > } > else top=node_type::from_impl(top->right()); > } > > return y; > } > > > template<typename Archive> > void save_( > Archive& ar,const unsigned int version,const index_saver_type& sm, > ordered_unique_tag)const > { > super::save_(ar,version,sm); > } > > template<typename Archive> > void load_( > Archive& ar,const unsigned int version,const index_loader_type& lm, > ordered_unique_tag) > { > super::load_(ar,version,lm); > } > > template<typename Archive> > void save_( > Archive& ar,const unsigned int version,const index_saver_type& sm, > ordered_non_unique_tag)const > { > typedef duplicates_iterator<node_type,value_compare> dup_iterator; > > sm.save( > dup_iterator(begin().get_node(),end().get_node(),value_comp()), > dup_iterator(end().get_node(),value_comp()), > ar,version); > super::save_(ar,version,sm); > } > > template<typename Archive> > void load_( > Archive& ar,const unsigned int version,const index_loader_type& lm, > ordered_non_unique_tag) > { > lm.load( > ::boost::bind(&ordered_index::rearranger,this,_1,_2), > ar,version); > super::load_(ar,version,lm); > } > > void rearranger(node_type* position,node_type *x) > { > if(!position||comp_(key(position->value()),key(x->value()))){ > position=lower_bound(key(x->value())).get_node(); > } > else if(comp_(key(x->value()),key(position->value()))){ > > throw_exception( > archive::archive_exception( > archive::archive_exception::other_exception)); > } > else node_type::increment(position); > > if(position!=x){ > node_impl_type::rebalance_for_erase( > x->impl(),header()->parent(),header()->left(),header()->right()); > node_impl_type::restore( > x->impl(),position->impl(),header()->impl()); > } > } > > > key_from_value key; > key_compare comp_; > > > > > >}; > > > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator==( > const ordered_index<KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index<KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y) >{ > return x.size()==y.size()&&std::equal(x.begin(),x.end(),y.begin()); >} > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator<( > const ordered_index<KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index<KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y) >{ > return std::lexicographical_compare(x.begin(),x.end(),y.begin(),y.end()); >} > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator!=( > const ordered_index<KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index<KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y) >{ > return !(x==y); >} > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator>( > const ordered_index<KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index<KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y) >{ > return y<x; >} > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator>=( > const ordered_index<KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index<KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y) >{ > return !(x<y); >} > >template< > typename KeyFromValue1,typename Compare1, > typename SuperMeta1,typename TagList1,typename Category1, > typename KeyFromValue2,typename Compare2, > typename SuperMeta2,typename TagList2,typename Category2 >> >bool operator<=( > const ordered_index<KeyFromValue1,Compare1,SuperMeta1,TagList1,Category1>& x, > const ordered_index<KeyFromValue2,Compare2,SuperMeta2,TagList2,Category2>& y) >{ > return !(x>y); >} > > > >template< > typename KeyFromValue,typename Compare, > typename SuperMeta,typename TagList,typename Category >> >void swap( > ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& x, > ordered_index<KeyFromValue,Compare,SuperMeta,TagList,Category>& y) >{ > x.swap(y); >} > >} > > > >template<typename Arg1,typename Arg2,typename Arg3> >struct ordered_unique >{ > typedef typename detail::ordered_index_args< > Arg1,Arg2,Arg3> index_args; > typedef typename index_args::tag_list_type::type tag_list_type; > typedef typename index_args::key_from_value_type key_from_value_type; > typedef typename index_args::compare_type compare_type; > > template<typename Super> > struct node_class > { > typedef detail::ordered_index_node<Super> type; > }; > > template<typename SuperMeta> > struct index_class > { > typedef detail::ordered_index< > key_from_value_type,compare_type, > SuperMeta,tag_list_type,detail::ordered_unique_tag> type; > }; >}; > >template<typename Arg1,typename Arg2,typename Arg3> >struct ordered_non_unique >{ > typedef detail::ordered_index_args< > Arg1,Arg2,Arg3> index_args; > typedef typename index_args::tag_list_type::type tag_list_type; > typedef typename index_args::key_from_value_type key_from_value_type; > typedef typename index_args::compare_type compare_type; > > template<typename Super> > struct node_class > { > typedef detail::ordered_index_node<Super> type; > }; > > template<typename SuperMeta> > struct index_class > { > typedef detail::ordered_index< > key_from_value_type,compare_type, > SuperMeta,tag_list_type,detail::ordered_non_unique_tag> type; > }; >}; > >} > >} > > > >template< > typename KeyFromValue,typename Compare, > typename SuperMeta,typename TagList,typename Category >> >inline boost::mpl::true_* boost_foreach_is_noncopyable( > boost::multi_index::detail::ordered_index< > KeyFromValue,Compare,SuperMeta,TagList,Category>*&, > boost::foreach::tag) >{ > return 0; >} ># 38 "/usr/include/boost/bimap/set_of.hpp" 2 3 4 > ># 1 "/usr/include/boost/bimap/views/map_view.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/views/map_view.hpp" 3 4 ># 1 "/usr/include/boost/bimap/container_adaptor/map_adaptor.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/container_adaptor/map_adaptor.hpp" 3 4 ># 1 "/usr/include/boost/bimap/container_adaptor/ordered_associative_container_adaptor.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/container_adaptor/ordered_associative_container_adaptor.hpp" 3 4 ># 1 "/usr/include/boost/bimap/container_adaptor/associative_container_adaptor.hpp" 1 3 4 ># 26 "/usr/include/boost/bimap/container_adaptor/associative_container_adaptor.hpp" 3 4 ># 1 "/usr/include/boost/bimap/container_adaptor/detail/identity_converters.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/container_adaptor/detail/identity_converters.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace container_adaptor { > > > >namespace detail { > > > > > > > >template >< > class BaseIterator , class Iterator, > class BaseConstIterator , class ConstIterator >> >struct iterator_to_base_identity >{ > BaseIterator operator()(Iterator iter) const > { > return BaseIterator(iter); > } > > BaseConstIterator operator()(ConstIterator iter) const > { > return BaseConstIterator(iter); > } >}; > > > >template< class BaseIterator, class Iterator > >struct iterator_to_base_identity<BaseIterator,Iterator,BaseIterator,Iterator> >{ > BaseIterator operator()(Iterator iter) const > { > return BaseIterator(iter); > } >}; ># 72 "/usr/include/boost/bimap/container_adaptor/detail/identity_converters.hpp" 3 4 >template >< > class BaseIterator , class Iterator, > class BaseConstIterator , class ConstIterator >> >struct iterator_from_base_identity >{ > Iterator operator()(BaseIterator iter) const > { > return Iterator(iter); > } > ConstIterator operator()(BaseConstIterator iter) const > { > return ConstIterator(iter); > } >}; > > > >template< class BaseIterator, class Iterator, class ConstIterator > >struct iterator_from_base_identity<BaseIterator,Iterator,BaseIterator,ConstIterator> >{ > Iterator operator()(BaseIterator iter) const > { > return Iterator(iter); > } >}; > > > > > >template< class BaseValue, class Value > >struct value_to_base_identity >{ > BaseValue operator()(const Value & val) const > { > return BaseValue(val); > } >}; > > > >template< class Value > >struct value_to_base_identity< Value, Value > >{ > const Value & operator()(const Value & val) const > { > return val; > } >}; > > > > > >template< class BaseValue, class Value > >struct value_from_base_identity >{ > Value operator()(const BaseValue & val) const > { > return Value(val); > } >}; > > > >template< class Value > >struct value_from_base_identity<Value,Value> >{ > Value & operator()(Value & val) const > { > return val; > } > > const Value & operator()(const Value & val) const > { > return val; > } >}; > > > > > >template< class BaseKey, class Key > >struct key_to_base_identity >{ > BaseKey operator()(const Key & k) const > { > return BaseKey(k); > } >}; > > > >template< class Key > >struct key_to_base_identity< Key, Key > >{ > > > > template< class CompatibleKey > > const CompatibleKey & operator()(const CompatibleKey & k) const > { > return k; > } >}; > > > >} >} >} >} ># 27 "/usr/include/boost/bimap/container_adaptor/associative_container_adaptor.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/container_adaptor/container_adaptor.hpp" 1 3 4 ># 28 "/usr/include/boost/bimap/container_adaptor/container_adaptor.hpp" 3 4 ># 1 "/usr/include/boost/bimap/container_adaptor/detail/functor_bag.hpp" 1 3 4 ># 30 "/usr/include/boost/bimap/container_adaptor/detail/functor_bag.hpp" 3 4 ># 1 "/usr/include/boost/mpl/placeholders.hpp" 1 3 4 ># 31 "/usr/include/boost/bimap/container_adaptor/detail/functor_bag.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/mpl/inherit_linearly.hpp" 1 3 4 ># 18 "/usr/include/boost/mpl/inherit_linearly.hpp" 3 4 ># 1 "/usr/include/boost/mpl/empty_base.hpp" 1 3 4 ># 24 "/usr/include/boost/mpl/empty_base.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 1 3 4 ># 14 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 3 4 ># 1 "/usr/include/boost/type_traits/detail/template_arity_spec.hpp" 1 3 4 ># 15 "/usr/include/boost/type_traits/detail/bool_trait_def.hpp" 2 3 4 ># 25 "/usr/include/boost/mpl/empty_base.hpp" 2 3 4 > >namespace boost { namespace mpl { > > > > >struct empty_base {}; > >template< typename T > >struct is_empty_base > : false_ >{ > > > >}; > >template<> >struct is_empty_base<empty_base> > : true_ >{ > > > >}; > >}} > >namespace boost { >template<> struct is_empty< mpl::empty_base > : public ::boost::integral_constant<bool,true> { public: }; >} > ># 1 "/usr/include/boost/type_traits/detail/bool_trait_undef.hpp" 1 3 4 ># 58 "/usr/include/boost/mpl/empty_base.hpp" 2 3 4 ># 19 "/usr/include/boost/mpl/inherit_linearly.hpp" 2 3 4 > > > >namespace boost { namespace mpl { > >template< > typename Types_ = na > , typename Node_ = na > , typename Root_ = empty_base > > >struct inherit_linearly > : fold<Types_,Root_,Node_> >{ > >}; > >template<> struct inherit_linearly< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : inherit_linearly< T1 , T2 > { }; }; template< typename Tag > struct lambda< inherit_linearly< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef inherit_linearly< na , na > result_; typedef inherit_linearly< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< inherit_linearly< T1 , T2 > > : int_<2> { }; template<> struct template_arity< inherit_linearly< na , na > > : int_<-1> { }; } > >}} ># 36 "/usr/include/boost/bimap/container_adaptor/detail/functor_bag.hpp" 2 3 4 ># 1 "/usr/include/boost/mpl/inherit.hpp" 1 3 4 ># 33 "/usr/include/boost/mpl/inherit.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 1 3 4 ># 37 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 3 4 ># 1 "/usr/include/boost/mpl/aux_/preprocessed/gcc/inherit.hpp" 1 3 4 ># 12 "/usr/include/boost/mpl/aux_/preprocessed/gcc/inherit.hpp" 3 4 >namespace boost { namespace mpl { > >template< > typename T1 = na > , typename T2 = na > > >struct inherit2 > : T1, T2 >{ > typedef inherit2 type; > >}; > >template< typename T1 > >struct inherit2< T1,empty_base > >{ > typedef T1 type; > >}; > >template< typename T2 > >struct inherit2< empty_base,T2 > >{ > typedef T2 type; > >}; > >template<> >struct inherit2< empty_base,empty_base > >{ > typedef empty_base type; > >}; > >template<> struct inherit2< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : inherit2< T1 , T2 > { }; }; template< typename Tag > struct lambda< inherit2< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef inherit2< na , na > result_; typedef inherit2< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< inherit2< T1 , T2 > > : int_<2> { }; template<> struct template_arity< inherit2< na , na > > : int_<-1> { }; } > >template< > typename T1 = na, typename T2 = na, typename T3 = na > > >struct inherit3 > : inherit2< > typename inherit2< > T1, T2 > >::type > , T3 > > >{ > > > > > >}; > >template<> struct inherit3< na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 =na , typename T5 =na > struct apply : inherit3< T1 , T2 , T3 > { }; }; template< typename Tag > struct lambda< inherit3< na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef inherit3< na , na , na > result_; typedef inherit3< na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 > struct template_arity< inherit3< T1 , T2 , T3 > > : int_<3> { }; template<> struct template_arity< inherit3< na , na , na > > : int_<-1> { }; } > >template< > typename T1 = na, typename T2 = na, typename T3 = na, typename T4 = na > > >struct inherit4 > : inherit2< > typename inherit3< > T1, T2, T3 > >::type > , T4 > > >{ > > > > > >}; > >template<> struct inherit4< na , na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 =na > struct apply : inherit4< T1 , T2 , T3 , T4 > { }; }; template< typename Tag > struct lambda< inherit4< na , na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef inherit4< na , na , na , na > result_; typedef inherit4< na , na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 > struct template_arity< inherit4< T1 , T2 , T3 , T4 > > : int_<4> { }; template<> struct template_arity< inherit4< na , na , na , na > > : int_<-1> { }; } > >template< > typename T1 = na, typename T2 = na, typename T3 = na, typename T4 = na > , typename T5 = na > > >struct inherit5 > : inherit2< > typename inherit4< > T1, T2, T3, T4 > >::type > , T5 > > >{ > > > > > >}; > >template<> struct inherit5< na , na , na , na , na > { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct apply : inherit5< T1 , T2 , T3 , T4 , T5 > { }; }; template< typename Tag > struct lambda< inherit5< na , na , na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef inherit5< na , na , na , na , na > result_; typedef inherit5< na , na , na , na , na > type; }; namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct template_arity< inherit5< T1 , T2 , T3 , T4 , T5 > > : int_<5> { }; template<> struct template_arity< inherit5< na , na , na , na , na > > : int_<-1> { }; } > > > >template< > typename T1 = empty_base, typename T2 = empty_base > , typename T3 = empty_base, typename T4 = empty_base > , typename T5 = empty_base > > >struct inherit > : inherit5< T1,T2,T3,T4,T5 > >{ >}; > >template<> >struct inherit< na,na,na,na,na > >{ > template< > > typename T1 = empty_base, typename T2 = empty_base > , typename T3 = empty_base, typename T4 = empty_base > , typename T5 = empty_base > > > > struct apply > : inherit< T1,T2,T3,T4,T5 > > { > }; >}; > >template< typename Tag > struct lambda< inherit< na , na , na , na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef inherit< na , na , na , na , na > result_; typedef inherit< na , na , na , na , na > type; }; > >namespace aux { template< typename T1 , typename T2 , typename T3 , typename T4 , typename T5 > struct template_arity< inherit< T1 , T2 , T3 , T4 , T5 > > : int_<5> { }; template<> struct template_arity< inherit< na , na , na , na , na > > : int_<-1> { }; } >}} ># 38 "/usr/include/boost/mpl/aux_/include_preprocessed.hpp" 2 3 4 ># 34 "/usr/include/boost/mpl/inherit.hpp" 2 3 4 ># 37 "/usr/include/boost/bimap/container_adaptor/detail/functor_bag.hpp" 2 3 4 > >namespace boost { >namespace bimaps { >namespace container_adaptor { >namespace detail { ># 51 "/usr/include/boost/bimap/container_adaptor/detail/functor_bag.hpp" 3 4 >template < class Data, class FunctorList > >struct data_with_functor_bag : > > public mpl::inherit_linearly< > > FunctorList, > mpl::if_< is_base_of< mpl::_2, mpl::_1 >, > > mpl::_1, > > > > mpl::inherit< mpl::_1, mpl::_2 > > > > > > >::type >{ > Data data; > > data_with_functor_bag() {} > > data_with_functor_bag(typename add_reference<Data>::type d) > : data(d) {} > > template< class Functor > > Functor& functor() > { > return *(static_cast<Functor*>(this)); > } > > template< class Functor > > const Functor& functor() const > { > return *(static_cast<Functor const *>(this)); > } >}; > >} >} >} >} ># 29 "/usr/include/boost/bimap/container_adaptor/container_adaptor.hpp" 2 3 4 > ># 1 "/usr/include/boost/mpl/copy.hpp" 1 3 4 ># 22 "/usr/include/boost/mpl/copy.hpp" 3 4 >namespace boost { namespace mpl { > >namespace aux { > >template< > typename Sequence > , typename Inserter > > >struct copy_impl > : fold< > Sequence > , typename Inserter::state > , typename Inserter::operation > > >{ >}; > >template< > typename Sequence > , typename Inserter > > >struct reverse_copy_impl > : reverse_fold< > Sequence > , typename Inserter::state > , typename Inserter::operation > > >{ >}; > >} > > template< typename P1 = na , typename P2 = na > struct copy : aux::copy_impl< P1 , P2> { }; template< typename P1 > struct copy< P1,na > : if_< has_push_back< typename clear<P1>::type> , aux::copy_impl< P1 , back_inserter< typename clear<P1>::type > > , aux::reverse_copy_impl< P1 , front_inserter< typename clear<P1>::type > > >::type { }; template< typename P1 = na , typename P2 = na > struct reverse_copy : aux::reverse_copy_impl< P1 , P2> { }; template< typename P1 > struct reverse_copy< P1,na > : if_< has_push_back<P1> , aux::reverse_copy_impl< P1 , back_inserter< typename clear<P1>::type > > , aux::copy_impl< P1 , front_inserter< typename clear<P1>::type > > >::type { }; template<> struct copy< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : copy< T1 , T2 > { }; }; template< typename Tag > struct lambda< copy< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef copy< na , na > result_; typedef copy< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< copy< T1 , T2 > > : int_<2> { }; template<> struct template_arity< copy< na , na > > : int_<-1> { }; } template<> struct reverse_copy< na , na > { template< typename T1 , typename T2 , typename T3 =na , typename T4 =na , typename T5 =na > struct apply : reverse_copy< T1 , T2 > { }; }; template< typename Tag > struct lambda< reverse_copy< na , na > , Tag , int_<-1> > { typedef false_ is_le; typedef reverse_copy< na , na > result_; typedef reverse_copy< na , na > type; }; namespace aux { template< typename T1 , typename T2 > struct template_arity< reverse_copy< T1 , T2 > > : int_<2> { }; template<> struct template_arity< reverse_copy< na , na > > : int_<-1> { }; } > >}} ># 31 "/usr/include/boost/bimap/container_adaptor/container_adaptor.hpp" 2 3 4 > > > > > >namespace boost { >namespace bimaps { > > > >namespace container_adaptor { > > > >template >< > class Base, > > class Iterator, > class ConstIterator, > > class IteratorToBaseConverter = ::boost::mpl::na, > class IteratorFromBaseConverter = ::boost::mpl::na, > class ValueToBaseConverter = ::boost::mpl::na, > class ValueFromBaseConverter = ::boost::mpl::na, > > class FunctorsFromDerivedClasses = mpl::vector<> >> >class container_adaptor >{ > > > public: > > typedef Iterator iterator; > typedef ConstIterator const_iterator; > > typedef typename iterator_value < iterator >::type value_type; > typedef typename iterator_pointer < iterator >::type pointer; > typedef typename iterator_reference< iterator >::type reference; > typedef typename iterator_reference< const_iterator >::type const_reference; > > typedef typename Base::size_type size_type; > typedef typename Base::difference_type difference_type; > > typedef typename mpl::if_< ::boost::mpl::is_na<IteratorToBaseConverter>, > > ::boost::bimaps::container_adaptor::detail:: > iterator_to_base_identity > < > typename Base::iterator , iterator, > typename Base::const_iterator , const_iterator > >, > > > > IteratorToBaseConverter > > > >::type iterator_to_base; > > typedef typename mpl::if_< ::boost::mpl::is_na<IteratorFromBaseConverter>, > > ::boost::bimaps::container_adaptor::detail:: > iterator_from_base_identity > < > typename Base::iterator , iterator, > typename Base::const_iterator , const_iterator > >, > > > > IteratorFromBaseConverter > > > >::type iterator_from_base; > > typedef typename mpl::if_< ::boost::mpl::is_na<ValueToBaseConverter>, > > ::boost::bimaps::container_adaptor::detail:: > value_to_base_identity > < > typename Base::value_type, > value_type > >, > > > > ValueToBaseConverter > > > >::type value_to_base; > > typedef typename mpl::if_< ::boost::mpl::is_na<ValueFromBaseConverter>, > > ::boost::bimaps::container_adaptor::detail:: > value_from_base_identity > < > typename Base::value_type, > value_type > >, > > > > ValueFromBaseConverter > > > >::type value_from_base; > > > > public: > > explicit container_adaptor(Base & c) : dwfb(c) {} > > protected: > > typedef Base base_type; > > typedef container_adaptor container_adaptor_; > > const Base & base() const { return dwfb.data; } > Base & base() { return dwfb.data; } > > > > public: > > size_type size() const { return base().size(); } > size_type max_size() const { return base().max_size(); } > bool empty() const { return base().empty(); } > > iterator begin() > { > return this->template functor<iterator_from_base>()( base().begin() ); > } > > iterator end() > { > return this->template functor<iterator_from_base>()( base().end() ); > } > > const_iterator begin() const > { > return this->template functor<iterator_from_base>()( base().begin() ); > } > > const_iterator end() const > { > return this->template functor<iterator_from_base>()( base().end() ); > } > > > iterator erase(iterator pos) > { > return this->template functor<iterator_from_base>()( > base().erase(this->template functor<iterator_to_base>()(pos)) > ); > } > > iterator erase(iterator first, iterator last) > { > return this->template functor<iterator_from_base>()( > base().erase( > this->template functor<iterator_to_base>()(first), > this->template functor<iterator_to_base>()(last) > ) > ); > } > > void clear() > { > base().clear(); > } > > template< class InputIterator > > void insert(InputIterator iterBegin, InputIterator iterEnd) > { > for( ; iterBegin != iterEnd ; ++iterBegin ) > { > base().insert( this->template > functor<value_to_base>()( *iterBegin ) > ); > } > } > > std::pair<iterator, bool> insert( > typename ::boost::call_traits< value_type >::param_type x) > { > std::pair< typename Base::iterator, bool > r( > base().insert( this->template functor<value_to_base>()(x) ) > ); > > return std::pair<iterator, bool>( this->template > functor<iterator_from_base>()(r.first),r.second > ); > } > > iterator insert(iterator pos, > typename ::boost::call_traits< value_type >::param_type x) > { > return this->template functor<iterator_from_base>()( > base().insert( > this->template functor<iterator_to_base>()(pos), > this->template functor<value_to_base>()(x)) > ); > } > > void swap( container_adaptor & c ) > { > base().swap( c.base() ); > } > > > > protected: > > template< class Functor > > Functor & functor() > { > return dwfb.template functor<Functor>(); > } > > template< class Functor > > Functor const & functor() const > { > return dwfb.template functor<Functor>(); > } > > > > private: > > ::boost::bimaps::container_adaptor::detail::data_with_functor_bag > < > Base &, > > typename mpl::copy > < > mpl::vector > < > iterator_to_base, > iterator_from_base, > value_to_base, > value_from_base > >, > > mpl::front_inserter< FunctorsFromDerivedClasses > > > >::type > > > dwfb; >}; > > >} >} >} ># 28 "/usr/include/boost/bimap/container_adaptor/associative_container_adaptor.hpp" 2 3 4 > > >namespace boost { >namespace bimaps { >namespace container_adaptor { > > > >template >< > class Base, class Iterator, class ConstIterator, class KeyType, > class IteratorToBaseConverter, class IteratorFromBaseConverter, > class ValueToBaseConverter, class ValueFromBaseConverter, class KeyToBaseConverter, > class FunctorsFromDerivedClasses >> >struct associative_container_adaptor_base >{ > typedef container_adaptor > < > Base, > > Iterator, ConstIterator, > > IteratorToBaseConverter, IteratorFromBaseConverter, > ValueToBaseConverter , ValueFromBaseConverter, > > typename mpl::push_front< > > FunctorsFromDerivedClasses, > > typename mpl::if_< ::boost::mpl::is_na<KeyToBaseConverter>, > > detail::key_to_base_identity > < > typename Base::key_type, KeyType > >, > > > > KeyToBaseConverter > > > >::type > > >::type > > > type; >}; > > > > > > >template >< > class Base, > > class Iterator, > class ConstIterator, > > class KeyType, > > class IteratorToBaseConverter = ::boost::mpl::na, > class IteratorFromBaseConverter = ::boost::mpl::na, > class ValueToBaseConverter = ::boost::mpl::na, > class ValueFromBaseConverter = ::boost::mpl::na, > class KeyToBaseConverter = ::boost::mpl::na, > > class FunctorsFromDerivedClasses = mpl::vector<> >> >class associative_container_adaptor : > > public associative_container_adaptor_base > < > Base, Iterator, ConstIterator, KeyType, > IteratorToBaseConverter, IteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, KeyToBaseConverter, > FunctorsFromDerivedClasses > > >::type >{ > > > > typedef typename associative_container_adaptor_base > < > Base, Iterator, ConstIterator, KeyType, > IteratorToBaseConverter, IteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, KeyToBaseConverter, > FunctorsFromDerivedClasses > > >::type base_; > > public: > > typedef KeyType key_type; > > protected: > > typedef typename mpl::if_< ::boost::mpl::is_na<KeyToBaseConverter>, > > detail::key_to_base_identity > < > typename Base::key_type, KeyType > >, > > > > KeyToBaseConverter > > > >::type key_to_base; > > public: > > explicit associative_container_adaptor(Base & c) > : base_(c) {} > > protected: > > > typedef associative_container_adaptor associative_container_adaptor_; > > > > public: > > template< class CompatibleKey > > typename base_::size_type erase(const CompatibleKey & k) > { > return this->base().erase > ( > this->template functor<key_to_base>()(k) > ); > } > > > > typename base_::iterator erase( > typename base_::iterator pos) > { > return base_::container_adaptor_::erase(pos); > } > > typename base_::iterator erase( > typename base_::iterator first, > typename base_::iterator last) > { > return base_::container_adaptor_::erase(first,last); > } > > template< class CompatibleKey > > typename base_::size_type count(const CompatibleKey & k) const > { > return this->base().count( > this->template functor<key_to_base>()(k) > ); > } > > template< class CompatibleKey > > typename base_::iterator find(const CompatibleKey & k) > { > return this->template functor<typename base_::iterator_from_base>() > ( > this->base().find( > this->template functor<key_to_base>()(k) > ) > ); > } > > template< class CompatibleKey > > typename base_::const_iterator > find(const CompatibleKey & k) const > { > return this->template functor< > typename base_::iterator_from_base>() > ( > this->base().find( > this->template functor<key_to_base>()(k) > ) > ); > } > > template< class CompatibleKey > > std::pair > < > typename base_::iterator, > typename base_::iterator > > > equal_range(const CompatibleKey & k) > { > std::pair< > > typename Base::iterator, > typename Base::iterator > > > r( this->base().equal_range( > this->template functor<key_to_base>()(k) > ) > ); > > return std::pair > < > typename base_::iterator, > typename base_::iterator > >( > this->template functor< > typename base_::iterator_from_base > >() ( r.first ), > this->template functor< > typename base_::iterator_from_base > >() ( r.second ) > ); > } > > template< class CompatibleKey > > std::pair > < > typename base_::const_iterator, > typename base_::const_iterator > > > equal_range(const CompatibleKey & k) const > { > std::pair< > > typename Base::const_iterator, > typename Base::const_iterator > > > r( this->base().equal_range( > this->template functor<key_to_base>()(k) > ) > ); > > return std::pair > < > typename base_::const_iterator, > typename base_::const_iterator > >( > this->template functor< > typename base_::iterator_from_base > >() ( r.first ), > this->template functor< > typename base_::iterator_from_base > >() ( r.second ) > ); > } > >}; > > >} >} >} ># 22 "/usr/include/boost/bimap/container_adaptor/ordered_associative_container_adaptor.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/container_adaptor/detail/comparison_adaptor.hpp" 1 3 4 ># 24 "/usr/include/boost/bimap/container_adaptor/detail/comparison_adaptor.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace container_adaptor { >namespace detail { > > > > > > > >template < class Compare, class NewType, class Converter > >struct comparison_adaptor : std::binary_function<NewType,NewType,bool> >{ > comparison_adaptor( const Compare & comp, const Converter & conv) > : compare(comp), converter(conv) {} > > bool operator()( typename call_traits<NewType>::param_type x, > typename call_traits<NewType>::param_type y) const > { > return compare( converter(x), converter(y) ); > } > > private: > Compare compare; > Converter converter; >}; > >template < class Compare, class NewType, class Converter > >struct compatible_comparison_adaptor : std::binary_function<NewType,NewType,bool> >{ > compatible_comparison_adaptor( const Compare & comp, const Converter & conv) > : compare(comp), converter(conv) {} > > template< class CompatibleTypeLeft, class CompatibleTypeRight > > bool operator()( const CompatibleTypeLeft & x, > const CompatibleTypeRight & y) const > { > return compare( converter(x), converter(y) ); > } > > private: > Compare compare; > Converter converter; >}; ># 77 "/usr/include/boost/bimap/container_adaptor/detail/comparison_adaptor.hpp" 3 4 >template < class Compare, class NewType, class Converter > >struct unary_check_adaptor : std::unary_function<NewType,bool> >{ > unary_check_adaptor( const Compare & comp, const Converter & conv ) : > compare(comp), converter(conv) {} > > bool operator()( typename call_traits<NewType>::param_type x) const > { > return compare( converter(x) ); > } > > private: > Compare compare; > Converter converter; >}; > >} >} >} >} ># 23 "/usr/include/boost/bimap/container_adaptor/ordered_associative_container_adaptor.hpp" 2 3 4 > > > > > > > >namespace boost { >namespace bimaps { >namespace container_adaptor { > > > >template >< > class Base, class Iterator, class ConstIterator, > class ReverseIterator, class ConstReverseIterator, class KeyType, > class IteratorToBaseConverter, class IteratorFromBaseConverter, > class ReverseIteratorFromBaseConverter, > class ValueToBaseConverter, class ValueFromBaseConverter, > class KeyToBaseConverter, > class FunctorsFromDerivedClasses >> >struct ordered_associative_container_adaptor_base >{ > typedef associative_container_adaptor< > Base, Iterator, ConstIterator, KeyType, > IteratorToBaseConverter, IteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, KeyToBaseConverter, > > typename mpl::push_front< > > FunctorsFromDerivedClasses, > > typename mpl::if_< > ::boost::mpl::is_na<ReverseIteratorFromBaseConverter>, > > detail::iterator_from_base_identity > < > typename Base::reverse_iterator, > ReverseIterator, > typename Base::const_reverse_iterator, > ConstReverseIterator > >, > > > > ReverseIteratorFromBaseConverter > > > >::type > > >::type > > > type; >}; > > > > > >template >< > class Base, > > class Iterator, > class ConstIterator, > class ReverseIterator, > class ConstReverseIterator, > > class KeyType, > > class IteratorToBaseConverter = ::boost::mpl::na, > class IteratorFromBaseConverter = ::boost::mpl::na, > class ReverseIteratorFromBaseConverter = ::boost::mpl::na, > class ValueToBaseConverter = ::boost::mpl::na, > class ValueFromBaseConverter = ::boost::mpl::na, > class KeyToBaseConverter = ::boost::mpl::na, > > class FunctorsFromDerivedClasses = mpl::vector<> >> >class ordered_associative_container_adaptor : > > public ordered_associative_container_adaptor_base > < > Base, Iterator, ConstIterator, > ReverseIterator, ConstReverseIterator, KeyType, > IteratorToBaseConverter, IteratorFromBaseConverter, > ReverseIteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, KeyToBaseConverter, > FunctorsFromDerivedClasses > > >::type, > > ::boost::totally_ordered > < > ordered_associative_container_adaptor > < > Base, Iterator, ConstIterator, > ReverseIterator, ConstReverseIterator, > KeyType, IteratorToBaseConverter, IteratorFromBaseConverter, > ReverseIteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, > KeyToBaseConverter, FunctorsFromDerivedClasses > > > > >{ > > > typedef typename ordered_associative_container_adaptor_base > < > Base, Iterator, ConstIterator, > ReverseIterator, ConstReverseIterator, KeyType, > IteratorToBaseConverter, IteratorFromBaseConverter, > ReverseIteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, KeyToBaseConverter, > FunctorsFromDerivedClasses > > >::type base_; > > public: > > typedef detail::compatible_comparison_adaptor > < > typename Base::key_compare, > typename base_::key_type, > typename base_::key_to_base > > > key_compare; > > typedef detail::comparison_adaptor > < > typename Base::value_compare, > typename base_::value_type, > typename base_::value_to_base > > > value_compare; > > typedef ReverseIterator reverse_iterator; > typedef ConstReverseIterator const_reverse_iterator; > > protected: > > typedef typename mpl::if_< > ::boost::mpl::is_na<ReverseIteratorFromBaseConverter>, > > detail::iterator_from_base_identity > < > typename Base::reverse_iterator, > reverse_iterator, > typename Base::const_reverse_iterator, > const_reverse_iterator > >, > > > > ReverseIteratorFromBaseConverter > > > >::type reverse_iterator_from_base; > > > > public: > > explicit ordered_associative_container_adaptor(Base & c) > : base_(c) {} > > protected: > > typedef ordered_associative_container_adaptor > ordered_associative_container_adaptor_; > > > > public: > > reverse_iterator rbegin() > { > return this->template functor< > reverse_iterator_from_base > >() ( this->base().rbegin() ); > > } > > reverse_iterator rend() > { > return this->template functor< > reverse_iterator_from_base > >() ( this->base().rend() ); > } > > const_reverse_iterator rbegin() const > { > return this->template functor< > reverse_iterator_from_base > >() ( this->base().rbegin() ); > } > > const_reverse_iterator rend() const > { > return this->template functor< > reverse_iterator_from_base > >() ( this->base().rend() ); > } > > key_compare key_comp() const > { > typedef typename base_::key_to_base key_to_base_; > > return key_compare( > this->base().key_comp(), > this->template functor<key_to_base_>() > ); > } > > value_compare value_comp() const > { > typedef typename base_::value_to_base value_to_base_; > > return value_compare( > this->base().value_comp(), > this->template functor<value_to_base_>() > ); > } > > template< class CompatibleKey > > typename base_::iterator lower_bound(const CompatibleKey & k) > { > return this->template functor< > typename base_::iterator_from_base>()( > this->base().lower_bound( > this->template functor<typename base_::key_to_base>()(k) > ) > ); > } > > template< class CompatibleKey > > typename base_::const_iterator lower_bound(const CompatibleKey & k) const > { > return this->template functor< > typename base_::iterator_from_base>()( > this->base().lower_bound( > this->template functor<typename base_::key_to_base>()(k) > ) > ); > } > > template< class CompatibleKey > > typename base_::iterator upper_bound(const CompatibleKey & k) > { > return this->template functor< > typename base_::iterator_from_base>()( > this->base().upper_bound( > this->template functor<typename base_::key_to_base>()(k) > ) > ); > } > > template< class CompatibleKey > > typename base_::const_iterator upper_bound(const CompatibleKey & k) const > { > return this->template functor< > typename base_::iterator_from_base>()( > this->base().upper_bound( > this->template functor<typename base_::key_to_base>()(k) > ) > ); > } > > > > bool operator==(const ordered_associative_container_adaptor & c) const > { > return ( this->base() == c.base() ); > } > > bool operator<(const ordered_associative_container_adaptor & c) const > { > return ( this->base() < c.base() ); > } >}; > > >} >} >} ># 22 "/usr/include/boost/bimap/container_adaptor/map_adaptor.hpp" 2 3 4 > > > > >namespace boost { >namespace bimaps { >namespace container_adaptor { > > > >template >< > class Base, > > class Iterator, > class ConstIterator, > class ReverseIterator, > class ConstReverseIterator, > > class IteratorToBaseConverter = ::boost::mpl::na, > class IteratorFromBaseConverter = ::boost::mpl::na, > class ReverseIteratorFromBaseConverter = ::boost::mpl::na, > class ValueToBaseConverter = ::boost::mpl::na, > class ValueFromBaseConverter = ::boost::mpl::na, > class KeyToBaseConverter = ::boost::mpl::na, > > class FunctorsFromDerivedClasses = mpl::vector<> >> >class map_adaptor : > > public ::boost::bimaps::container_adaptor:: > ordered_associative_container_adaptor > < > Base, > Iterator, ConstIterator, ReverseIterator, ConstReverseIterator, > typename Iterator::value_type::first_type, > IteratorToBaseConverter, IteratorFromBaseConverter, > ReverseIteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, > KeyToBaseConverter, > FunctorsFromDerivedClasses > > >{ > > typedef ::boost::bimaps::container_adaptor:: > ordered_associative_container_adaptor > < > Base, > Iterator, ConstIterator, ReverseIterator, ConstReverseIterator, > typename Iterator::value_type::first_type, > IteratorToBaseConverter, IteratorFromBaseConverter, > ReverseIteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, > KeyToBaseConverter, > FunctorsFromDerivedClasses > > > base_; > > > > public: > > typedef typename Iterator::value_type::second_type data_type; > typedef data_type mapped_type; > > > > public: > > explicit map_adaptor(Base & c) : > base_(c) {} > > protected: > > typedef map_adaptor map_adaptor_; > > > > public: > > template< class CompatibleKey > > data_type& operator[](const CompatibleKey & k) > { > return this->base() > [this->template functor<typename base_::key_to_base>()(k)]; > } > > template< class CompatibleKey > > data_type& at(const CompatibleKey & k) > { > return this->base(). > at(this->template functor<typename base_::key_to_base>()(k)); > } > > template< class CompatibleKey > > const data_type& at(const CompatibleKey & k) const > { > return this->base(). > at(this->template functor<typename base_::key_to_base>()(k)); > } > >}; > > >} >} >} ># 22 "/usr/include/boost/bimap/views/map_view.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/detail/map_view_base.hpp" 1 3 4 ># 28 "/usr/include/boost/bimap/detail/map_view_base.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/support/get_pair_functor.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/relation/support/get_pair_functor.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/support/pair_by.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/relation/support/pair_by.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/support/pair_type_by.hpp" 1 3 4 ># 41 "/usr/include/boost/bimap/relation/support/pair_type_by.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { >namespace support { > > > >template < class Tag, class SymmetricType, class Enable = void > struct pair_type_by { struct BIMAP_STATIC_ERROR__pair_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__pair_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__pair_type_by_FAILURE53 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__pair_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg53; enum { mpl_assertion_in_line_53 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg53::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct pair_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_pair type; }; template< class Tag, class SymmetricType > struct pair_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_pair type; }; > > > > > > >} >} >} >} ># 22 "/usr/include/boost/bimap/relation/support/pair_by.hpp" 2 3 4 ># 50 "/usr/include/boost/bimap/relation/support/pair_by.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { >namespace support { ># 84 "/usr/include/boost/bimap/relation/support/pair_by.hpp" 3 4 >namespace result_of { template< class Tag, class SymmetricType > struct pair_by { typedef typename pair_type_by < Tag,SymmetricType >::type value_type; typedef typename mpl::if_< is_const<SymmetricType>, typename call_traits<value_type>::const_reference, typename call_traits<value_type>::reference >::type type; }; } ># 95 "/usr/include/boost/bimap/relation/support/pair_by.hpp" 3 4 >namespace detail { template< class Relation > typename result_of::pair_by < ::boost::bimaps::relation::member_at::left,Relation >::type pair_by( ::boost::bimaps::relation::member_at::left, Relation & rel ) { return rel.get_left_pair(); } template< class Relation > typename result_of::pair_by < ::boost::bimaps::relation::member_at::right,Relation >::type pair_by( ::boost::bimaps::relation::member_at::right, Relation & rel ) { return rel.get_right_pair(); } } ># 107 "/usr/include/boost/bimap/relation/support/pair_by.hpp" 3 4 >template< class Tag, class SymmetricType > typename result_of::pair_by<Tag,SymmetricType>::type pair_by( SymmetricType & s ) { typedef typename ::boost::bimaps::relation::support:: member_with_tag < Tag,SymmetricType >::type member_at_tag; return detail::pair_by(member_at_tag(),s); } > > > > >} >} >} >} ># 22 "/usr/include/boost/bimap/relation/support/get_pair_functor.hpp" 2 3 4 > >namespace boost { >namespace bimaps { >namespace relation { >namespace support { ># 39 "/usr/include/boost/bimap/relation/support/get_pair_functor.hpp" 3 4 >template< class Tag, class Relation > >struct get_pair_functor >{ > typename result_of::pair_by<Tag,Relation>::type > operator()( Relation & r ) const > { > return pair_by<Tag>(r); > } > > typename result_of::pair_by<Tag,const Relation>::type > operator()( const Relation & r ) const > { > return pair_by<Tag>(r); > } >}; ># 62 "/usr/include/boost/bimap/relation/support/get_pair_functor.hpp" 3 4 >template< class Relation > >struct get_above_view_functor >{ > typename Relation::above_view & > operator()( Relation & r ) const > { > return r.get_view(); > } > > const typename Relation::above_view & > operator()( const Relation & r ) const > { > return r.get_view(); > } >}; > >} >} >} >} ># 29 "/usr/include/boost/bimap/detail/map_view_base.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/relation/detail/to_mutable_relation_functor.hpp" 1 3 4 ># 25 "/usr/include/boost/bimap/relation/detail/to_mutable_relation_functor.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { >namespace detail { > > > >template< class Tag, class Relation > >struct pair_to_relation_functor >{ > const Relation > operator()(const typename ::boost::bimaps::relation::support:: > pair_type_by<Tag,Relation>::type & p) const > { > return Relation(p); > } >}; > >template< class Tag, class TA, class TB, class Info > >struct pair_to_relation_functor< > Tag,::boost::bimaps::relation::mutant_relation<TA,TB,Info,true> > >{ > typedef ::boost::bimaps::relation::mutant_relation<TA,TB,Info,true> Relation; > > Relation & > operator()( typename ::boost::bimaps::relation::support:: > pair_type_by<Tag,Relation>::type & p ) const > { > return ::boost::bimaps::relation::detail::mutate<Relation>(p); > } > > const Relation & > operator()( const typename ::boost::bimaps::relation::support:: > pair_type_by<Tag,Relation>::type & p) const > { > return ::boost::bimaps::relation::detail::mutate<Relation>(p); > } >}; > > > > >template< class Relation > >struct get_mutable_relation_functor >{ > const Relation > operator()( const typename Relation::above_view & r ) const > { > return Relation(r); > } >}; > >template< class TA, class TB, class Info > >struct get_mutable_relation_functor< ::boost::bimaps::relation::mutant_relation<TA,TB,Info,true> > >{ > typedef ::boost::bimaps::relation::mutant_relation<TA,TB,Info,true> Relation; > > Relation & > operator()( typename Relation::above_view & r ) const > { > return ::boost::bimaps::relation::detail::mutate<Relation>(r); > } > > const Relation & > operator()( const typename Relation::above_view & r ) const > { > return ::boost::bimaps::relation::detail::mutate<Relation>(r); > } >}; > >} >} >} >} ># 30 "/usr/include/boost/bimap/detail/map_view_base.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/container_adaptor/support/iterator_facade_converters.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/container_adaptor/support/iterator_facade_converters.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace container_adaptor { > > > >namespace support { > > > > > > >template >< > class Iterator, > class ConstIterator >> >struct iterator_facade_to_base >{ > typename Iterator::base_type operator()(Iterator iter) const > { > return iter.base(); > } > > typename ConstIterator::base_type operator()(ConstIterator iter) const > { > return iter.base(); > } >}; > > > >template >< > class Iterator >> >struct iterator_facade_to_base<Iterator,Iterator> >{ > typename Iterator::base_type operator()(Iterator iter) const > { > return iter.base(); > } >}; > > > > > > >} >} >} >} ># 31 "/usr/include/boost/bimap/detail/map_view_base.hpp" 2 3 4 > ># 1 "/usr/include/boost/bimap/relation/support/opposite_tag.hpp" 1 3 4 ># 40 "/usr/include/boost/bimap/relation/support/opposite_tag.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace relation { >namespace support { > > > >template < class Tag, class SymmetricType, class Enable = void > struct opossite_tag { struct BIMAP_STATIC_ERROR__opossite_tag_FAILURE {}; struct BIMAP_STATIC_ERROR__opossite_tag_FAILURE; typedef struct BIMAP_STATIC_ERROR__opossite_tag_FAILURE52 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__opossite_tag_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg52; enum { mpl_assertion_in_line_52 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg52::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct opossite_tag < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_tag type; }; template< class Tag, class SymmetricType > struct opossite_tag < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_tag type; }; > > > > > > >} >} >} >} ># 33 "/usr/include/boost/bimap/detail/map_view_base.hpp" 2 3 4 > > ># 1 "/usr/include/boost/bimap/support/key_type_by.hpp" 1 3 4 ># 45 "/usr/include/boost/bimap/support/key_type_by.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace support { > > > >template < class Tag, class SymmetricType, class Enable = void > struct key_type_by { struct BIMAP_STATIC_ERROR__key_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__key_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__key_type_by_FAILURE56 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__key_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg56; enum { mpl_assertion_in_line_56 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg56::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct key_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_key_type type; }; template< class Tag, class SymmetricType > struct key_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_key_type type; }; > > > > > > > >} >} >} ># 36 "/usr/include/boost/bimap/detail/map_view_base.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/support/data_type_by.hpp" 1 3 4 ># 54 "/usr/include/boost/bimap/support/data_type_by.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace support { > > > >template < class Tag, class SymmetricType, class Enable = void > struct data_type_by { struct BIMAP_STATIC_ERROR__data_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__data_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__data_type_by_FAILURE65 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__data_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg65; enum { mpl_assertion_in_line_65 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg65::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct data_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_data_type type; }; template< class Tag, class SymmetricType > struct data_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_data_type type; }; > > > > > > >} >} >} ># 37 "/usr/include/boost/bimap/detail/map_view_base.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/support/value_type_by.hpp" 1 3 4 ># 44 "/usr/include/boost/bimap/support/value_type_by.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace support { > > > >template < class Tag, class SymmetricType, class Enable = void > struct value_type_by { struct BIMAP_STATIC_ERROR__value_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__value_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__value_type_by_FAILURE55 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__value_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg55; enum { mpl_assertion_in_line_55 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg55::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct value_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_value_type type; }; template< class Tag, class SymmetricType > struct value_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_value_type type; }; ># 59 "/usr/include/boost/bimap/support/value_type_by.hpp" 3 4 >} >} >} ># 38 "/usr/include/boost/bimap/detail/map_view_base.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/detail/modifier_adaptor.hpp" 1 3 4 ># 23 "/usr/include/boost/bimap/detail/modifier_adaptor.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace detail { > > > >template >< > class Modifier, > class NewArgument, > class FirstExtractor, > class SecondExtractor >> >struct relation_modifier_adaptor : > public std::unary_function<NewArgument,bool>, > Modifier, > FirstExtractor, > SecondExtractor >{ > relation_modifier_adaptor( const Modifier & m ) : Modifier(m) {} > relation_modifier_adaptor( const Modifier & m, > const FirstExtractor & fe, > const SecondExtractor & se ) : > Modifier(m), FirstExtractor(fe), SecondExtractor(se) {} > > void operator()( NewArgument & x ) const > { > Modifier::operator()( > FirstExtractor ::operator()( x ), > SecondExtractor::operator()( x ) > ); > } >}; > > > > > >template >< > class Modifier, > class NewArgument, > class Extractor >> >struct unary_modifier_adaptor : > public std::unary_function<NewArgument,bool>, > Modifier, > Extractor >{ > unary_modifier_adaptor( const Modifier & m ) : Modifier(m) {} > unary_modifier_adaptor( const Modifier & m, > const Extractor & fe) : > Modifier(m), Extractor(fe) {} > > void operator()( NewArgument & x ) const > { > Modifier::operator()( Extractor::operator()( x ) ); > } >}; > > >} >} >} ># 39 "/usr/include/boost/bimap/detail/map_view_base.hpp" 2 3 4 > ># 1 "/usr/include/boost/bimap/detail/map_view_iterator.hpp" 1 3 4 ># 33 "/usr/include/boost/bimap/detail/map_view_iterator.hpp" 3 4 ># 1 "/usr/include/boost/bimap/relation/detail/static_access_builder.hpp" 1 3 4 ># 34 "/usr/include/boost/bimap/detail/map_view_iterator.hpp" 2 3 4 > >namespace boost { >namespace bimaps { >namespace detail { > > > > > > >template< class Tag, class BimapCore > struct map_view_iterator ; >template< class Tag, class BimapCore > struct const_map_view_iterator ; > >template< class Tag, class BimapCore > struct reverse_map_view_iterator ; >template< class Tag, class BimapCore > struct const_reverse_map_view_iterator ; > >template< class Tag, class BimapCore > struct local_map_view_iterator ; >template< class Tag, class BimapCore > struct const_local_map_view_iterator ; ># 94 "/usr/include/boost/bimap/detail/map_view_iterator.hpp" 3 4 >template < class Tag, class BimapCore, class Enable = void > struct core_iterator_type_by { struct BIMAP_STATIC_ERROR__core_iterator_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__core_iterator_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__core_iterator_type_by_FAILURE95 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__core_iterator_type_by_FAILURE::************ assert_arg()) (BimapCore,Tag) { return 0; } } mpl_assert_arg95; enum { mpl_assertion_in_line_95 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg95::assert_arg() ) ) }; }; template< class Tag, class BimapCore > struct core_iterator_type_by < Tag, BimapCore, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, BimapCore > >::type > { typedef typename BimapCore::core_type::template index<typename BimapCore::left_tag> ::type::iterator type; }; template< class Tag, class BimapCore > struct core_iterator_type_by < Tag, BimapCore, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, BimapCore > >::type > { typedef typename BimapCore::core_type::template index<typename BimapCore::right_tag> ::type::iterator type; }; > > >template < class Tag, class BimapCore, class Enable = void > struct reverse_core_iterator_type_by { struct BIMAP_STATIC_ERROR__reverse_core_iterator_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__reverse_core_iterator_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__reverse_core_iterator_type_by_FAILURE98 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__reverse_core_iterator_type_by_FAILURE::************ assert_arg()) (BimapCore,Tag) { return 0; } } mpl_assert_arg98; enum { mpl_assertion_in_line_98 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg98::assert_arg() ) ) }; }; template< class Tag, class BimapCore > struct reverse_core_iterator_type_by < Tag, BimapCore, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, BimapCore > >::type > { typedef typename BimapCore::core_type::template index<typename BimapCore::left_tag> ::type::reverse_iterator type; }; template< class Tag, class BimapCore > struct reverse_core_iterator_type_by < Tag, BimapCore, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, BimapCore > >::type > { typedef typename BimapCore::core_type::template index<typename BimapCore::right_tag> ::type::reverse_iterator type; }; > > >template < class Tag, class BimapCore, class Enable = void > struct local_core_iterator_type_by { struct BIMAP_STATIC_ERROR__local_core_iterator_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__local_core_iterator_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__local_core_iterator_type_by_FAILURE101 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__local_core_iterator_type_by_FAILURE::************ assert_arg()) (BimapCore,Tag) { return 0; } } mpl_assert_arg101; enum { mpl_assertion_in_line_101 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg101::assert_arg() ) ) }; }; template< class Tag, class BimapCore > struct local_core_iterator_type_by < Tag, BimapCore, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, BimapCore > >::type > { typedef typename BimapCore::core_type::template index<typename BimapCore::left_tag> ::type::local_iterator type; }; template< class Tag, class BimapCore > struct local_core_iterator_type_by < Tag, BimapCore, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, BimapCore > >::type > { typedef typename BimapCore::core_type::template index<typename BimapCore::right_tag> ::type::local_iterator type; }; > > > > > >template< class Tag, class BimapCore > >struct map_view_iterator_adaptor { > typedef iterator_adaptor< > map_view_iterator<Tag,BimapCore>, > typename core_iterator_type_by<Tag,BimapCore>::type, > typename > ::boost::bimaps::support::value_type_by<Tag,BimapCore>::type > > type; >}; >template< class Tag, class BimapCore > >struct map_view_iterator : > public map_view_iterator_adaptor<Tag,BimapCore>::type >{ > typedef typename > map_view_iterator_adaptor<Tag,BimapCore>::type base_; > public: > > map_view_iterator() {} > map_view_iterator(typename base_::base_type const& iter) > : base_(iter) {} > map_view_iterator(map_view_iterator const & iter) > : base_(iter.base()) {} > > typename base_::reference dereference() const > { > return ::boost::bimaps::relation::support::pair_by<Tag>( > *const_cast<typename base_::base_type::value_type*>( > &(*this->base()) > ) > ); > } > private: > friend class iterator_core_access; > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } friend class ::boost::serialization::access; template< class Archive > void save(Archive & ar, const unsigned int) const { ar << ::boost::serialization::make_nvp("mi_iterator",this->base()); } template< class Archive > void load(Archive & ar, const unsigned int) { typename base_::base_type iter; ar >> ::boost::serialization::make_nvp("mi_iterator",iter); this->base_reference() = iter; } >}; > > >template< class Tag, class BimapCore > >struct const_map_view_iterator_adaptor { > typedef iterator_adaptor< > const_map_view_iterator<Tag,BimapCore>, > typename core_iterator_type_by<Tag,BimapCore>::type, > const typename > ::boost::bimaps::support::value_type_by<Tag,BimapCore>::type > > type; >}; >template< class Tag, class BimapCore > >struct const_map_view_iterator : > public const_map_view_iterator_adaptor<Tag,BimapCore>::type >{ > typedef typename > const_map_view_iterator_adaptor<Tag,BimapCore>::type base_; > public: > > const_map_view_iterator() {} > const_map_view_iterator( > typename base_::base_type const& iter) > : base_(iter) {} > const_map_view_iterator(const_map_view_iterator const & iter) > : base_(iter.base()) {} > const_map_view_iterator(map_view_iterator<Tag,BimapCore> i) > : base_(i.base()) {} > > typename base_::reference dereference() const > { > return ::boost::bimaps::relation::support::pair_by<Tag>(*this->base()); > } > private: > friend class iterator_core_access; > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } friend class ::boost::serialization::access; template< class Archive > void save(Archive & ar, const unsigned int) const { ar << ::boost::serialization::make_nvp("mi_iterator",this->base()); } template< class Archive > void load(Archive & ar, const unsigned int) { typename base_::base_type iter; ar >> ::boost::serialization::make_nvp("mi_iterator",iter); this->base_reference() = iter; } >}; > > > > >template< class Tag, class BimapCore > >struct reverse_map_view_iterator_adaptor { > typedef iterator_adaptor< > reverse_map_view_iterator<Tag,BimapCore>, > typename > reverse_core_iterator_type_by<Tag,BimapCore>::type, > typename > ::boost::bimaps::support::value_type_by<Tag,BimapCore>::type > > type; >}; >template< class Tag, class BimapCore > >struct reverse_map_view_iterator : > public reverse_map_view_iterator_adaptor<Tag,BimapCore>::type >{ > typedef typename > reverse_map_view_iterator_adaptor<Tag,BimapCore>::type base_; > public: > > reverse_map_view_iterator() {} > reverse_map_view_iterator( > typename base_::base_type const& iter) > : base_(iter) {} > reverse_map_view_iterator(reverse_map_view_iterator const & iter) > : base_(iter.base()) {} > > typename base_::reference dereference() const > { > return ::boost::bimaps::relation::support::pair_by<Tag>( > *const_cast<typename base_::base_type::value_type*>( > &(*this->base()) > ) > ); > } > private: > friend class iterator_core_access; > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } friend class ::boost::serialization::access; template< class Archive > void save(Archive & ar, const unsigned int) const { ar << ::boost::serialization::make_nvp("mi_iterator",this->base()); } template< class Archive > void load(Archive & ar, const unsigned int) { typename base_::base_type iter; ar >> ::boost::serialization::make_nvp("mi_iterator",iter); this->base_reference() = iter; } >}; > >template< class Tag, class BimapCore > >struct const_reverse_map_view_iterator_adaptor { > typedef iterator_adaptor< > const_reverse_map_view_iterator<Tag,BimapCore>, > typename > reverse_core_iterator_type_by<Tag,BimapCore>::type, > const typename > ::boost::bimaps::support::value_type_by<Tag,BimapCore>::type > > type; >}; >template< class Tag, class BimapCore > >struct const_reverse_map_view_iterator : > public const_reverse_map_view_iterator_adaptor<Tag,BimapCore>::type >{ > typedef typename > const_reverse_map_view_iterator_adaptor<Tag,BimapCore>::type base_; > > public: > > const_reverse_map_view_iterator() {} > const_reverse_map_view_iterator( > typename base_::base_type const& iter) > : base_(iter) {} > const_reverse_map_view_iterator(const_reverse_map_view_iterator const & iter) > : base_(iter.base()) {} > const_reverse_map_view_iterator(reverse_map_view_iterator<Tag,BimapCore> i) > : base_(i.base()) {} > > typename base_::reference dereference() const > { > return ::boost::bimaps::relation::support::pair_by<Tag>(*this->base()); > } > private: > friend class iterator_core_access; > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } friend class ::boost::serialization::access; template< class Archive > void save(Archive & ar, const unsigned int) const { ar << ::boost::serialization::make_nvp("mi_iterator",this->base()); } template< class Archive > void load(Archive & ar, const unsigned int) { typename base_::base_type iter; ar >> ::boost::serialization::make_nvp("mi_iterator",iter); this->base_reference() = iter; } >}; > > > > >template< class Tag, class BimapCore > >struct local_map_view_iterator_adaptor { > typedef iterator_adaptor< > local_map_view_iterator<Tag,BimapCore>, > typename > local_core_iterator_type_by<Tag,BimapCore>::type, > typename > ::boost::bimaps::support::value_type_by<Tag,BimapCore>::type > > type; >}; >template< class Tag, class BimapCore > >struct local_map_view_iterator : > public local_map_view_iterator_adaptor<Tag,BimapCore>::type >{ > typedef typename > local_map_view_iterator_adaptor<Tag,BimapCore>::type base_; > public: > > local_map_view_iterator() {} > local_map_view_iterator( > typename base_::base_type const& iter) > : base_(iter) {} > local_map_view_iterator(local_map_view_iterator const & iter) > : base_(iter.base()) {} > > typename base_::reference dereference() const > { > return ::boost::bimaps::relation::support::pair_by<Tag>( > *const_cast<typename base_::base_type::value_type*>( > &(*this->base()) > ) > ); > } > private: > friend class iterator_core_access; > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } friend class ::boost::serialization::access; template< class Archive > void save(Archive & ar, const unsigned int) const { ar << ::boost::serialization::make_nvp("mi_iterator",this->base()); } template< class Archive > void load(Archive & ar, const unsigned int) { typename base_::base_type iter; ar >> ::boost::serialization::make_nvp("mi_iterator",iter); this->base_reference() = iter; } >}; > >template< class Tag, class BimapCore > >struct const_local_map_view_iterator_adaptor { > typedef iterator_adaptor< > const_local_map_view_iterator<Tag,BimapCore>, > typename > local_core_iterator_type_by<Tag,BimapCore>::type, > const typename > ::boost::bimaps::support::value_type_by<Tag,BimapCore>::type > > type; >}; >template< class Tag, class BimapCore > >struct const_local_map_view_iterator : > public const_local_map_view_iterator_adaptor<Tag,BimapCore>::type >{ > typedef typename > const_local_map_view_iterator_adaptor<Tag,BimapCore>::type base_; > public: > > const_local_map_view_iterator() {} > const_local_map_view_iterator( > typename base_::base_type const& iter) > : base_(iter) {} > const_local_map_view_iterator(const_local_map_view_iterator const & iter) > : base_(iter.base()) {} > const_local_map_view_iterator(local_map_view_iterator<Tag,BimapCore> i) > : base_(i.base()) {} > > typename base_::reference dereference() const > { > return ::boost::bimaps::relation::support::pair_by<Tag>(*this->base()); > } > private: > friend class iterator_core_access; > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } friend class ::boost::serialization::access; template< class Archive > void save(Archive & ar, const unsigned int) const { ar << ::boost::serialization::make_nvp("mi_iterator",this->base()); } template< class Archive > void load(Archive & ar, const unsigned int) { typename base_::base_type iter; ar >> ::boost::serialization::make_nvp("mi_iterator",iter); this->base_reference() = iter; } >}; > > > >} >} >} ># 41 "/usr/include/boost/bimap/detail/map_view_base.hpp" 2 3 4 > >namespace boost { >namespace bimaps { > >namespace detail { ># 94 "/usr/include/boost/bimap/detail/map_view_base.hpp" 3 4 >template< class Derived, class Tag, class BimapType> >class map_view_base >{ > typedef ::boost::bimaps::container_adaptor::support:: > iterator_facade_to_base< > ::boost::bimaps::detail:: map_view_iterator<Tag,BimapType>, > ::boost::bimaps::detail::const_map_view_iterator<Tag,BimapType> > > iterator_to_base_; > > typedef ::boost::bimaps::relation::detail:: > pair_to_relation_functor<Tag, > typename BimapType::relation> value_to_base_; > > typedef typename ::boost::bimaps::support:: > key_type_by<Tag,BimapType>::type key_type_; > > typedef typename ::boost::bimaps::support:: > data_type_by<Tag,BimapType>::type data_type_; > > typedef typename ::boost::bimaps::relation::support:: > pair_type_by<Tag, > typename BimapType::relation>::type value_type_; > > typedef > ::boost::bimaps::detail::map_view_iterator<Tag,BimapType> iterator_; > > public: > > bool replace(iterator_ position, const value_type_ & x) > { > return derived().base().replace( > derived().template functor<iterator_to_base_>()(position), > derived().template functor<value_to_base_>()(x) > ); > } > > template< class CompatibleKey > > bool replace_key(iterator_ position, const CompatibleKey & k) > { > return derived().base().replace( > derived().template functor<iterator_to_base_>()(position), > derived().template functor<value_to_base_>()( > ::boost::bimaps::relation::detail:: > copy_with_first_replaced(*position,k) > ) > ); > } > > template< class CompatibleData > > bool replace_data(iterator_ position, const CompatibleData & d) > { > return derived().base().replace( > derived().template functor<iterator_to_base_>()(position), > derived().template functor<value_to_base_>()( > ::boost::bimaps::relation::detail:: > copy_with_second_replaced(*position,d) > ) > ); > } ># 187 "/usr/include/boost/bimap/detail/map_view_base.hpp" 3 4 > template< class Modifier > > bool modify_key(iterator_ position, Modifier mod) > { > return derived().base().modify_key( > derived().template functor<iterator_to_base_>()(position), mod > ); > } > > template< class Modifier > > bool modify_data(iterator_ position, Modifier mod) > { > typedef typename ::boost::bimaps::relation::support:: > data_extractor > < > typename ::boost::bimaps::relation::support:: > opossite_tag<Tag,BimapType>::type, > typename BimapType::relation > > >::type data_extractor_; > > return derived().base().modify( > > derived().template functor<iterator_to_base_>()(position), > > > > > ::boost::bimaps::detail::unary_modifier_adaptor > < > Modifier, > typename BimapType::relation, > data_extractor_ > > >(mod) > ); > } > > protected: > > typedef map_view_base map_view_base_; > > private: > > > > Derived& derived() > { > return *static_cast<Derived*>(this); > } > > Derived const& derived() const > { > return *static_cast<Derived const*>(this); > } >}; > > > > >template< class Derived, class Tag, class BimapType> >class mutable_data_unique_map_view_access >{ > typedef typename ::boost::bimaps::support:: > data_type_by<Tag,BimapType>::type data_type_; > > public: > > template< class CompatibleKey > > data_type_ & at(const CompatibleKey& k) > { > typedef ::boost::bimaps::detail:: > map_view_iterator<Tag,BimapType> iterator; > > iterator iter = derived().find(k); > if( iter == derived().end() ) > { > ::boost::throw_exception( > std::out_of_range("bimap<>: invalid key") > ); > } > return iter->second; > } > > template< class CompatibleKey > > const data_type_ & at(const CompatibleKey& k) const > { > typedef ::boost::bimaps::detail:: > const_map_view_iterator<Tag,BimapType> const_iterator; > > const_iterator iter = derived().find(k); > if( iter == derived().end() ) > { > ::boost::throw_exception( > std::out_of_range("bimap<>: invalid key") > ); > } > return iter->second; > } > > template< class CompatibleKey > > data_type_ & operator[](const CompatibleKey& k) > { > typedef ::boost::bimaps::detail:: > map_view_iterator<Tag,BimapType> iterator; > > typedef typename ::boost::bimaps::support:: > value_type_by<Tag,BimapType>::type value_type; > > iterator iter = derived().find(k); > if( iter == derived().end() ) > { > iter = derived().insert( value_type(k,data_type_()) ).first; > } > return iter->second; > } > > protected: > > typedef mutable_data_unique_map_view_access > mutable_data_unique_map_view_access_; > > private: > > > > Derived& derived() > { > return *static_cast<Derived*>(this); > } > > Derived const& derived() const > { > return *static_cast<Derived const*>(this); > } >}; > > >template< class Derived, class Tag, class BimapType> >class non_mutable_data_unique_map_view_access >{ > typedef typename ::boost::bimaps::support:: > data_type_by<Tag,BimapType>::type data_type_; > > public: > > template< class CompatibleKey > > const data_type_ & at(const CompatibleKey& k) const > { > typedef ::boost::bimaps::detail:: > const_map_view_iterator<Tag,BimapType> const_iterator; > > const_iterator iter = derived().find(k); > if( iter == derived().end() ) > { > ::boost::throw_exception( > std::out_of_range("bimap<>: invalid key") > ); > } > return iter->second; > } > > template< class CompatibleKey > > data_type_ & operator[](const CompatibleKey&) > { > struct BIMAP_STATIC_ERROR__OPERATOR_BRACKET_IS_NOT_SUPPORTED {}; struct BIMAP_STATIC_ERROR__OPERATOR_BRACKET_IS_NOT_SUPPORTED; typedef struct BIMAP_STATIC_ERROR__OPERATOR_BRACKET_IS_NOT_SUPPORTED351 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__OPERATOR_BRACKET_IS_NOT_SUPPORTED::************ assert_arg()) (Derived) { return 0; } } mpl_assert_arg351; enum { mpl_assertion_in_line_351 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg351::assert_arg() ) ) }; > } > > protected: > > typedef non_mutable_data_unique_map_view_access > non_mutable_data_unique_map_view_access_; > > private: > > > > Derived& derived() > { > return *static_cast<Derived*>(this); > } > > Derived const& derived() const > { > return *static_cast<Derived const*>(this); > } >}; > > >template< class Derived, class Tag, class BimapType> >struct unique_map_view_access >{ > private: > typedef typename ::boost::bimaps::support:: > value_type_by<Tag,BimapType>::type value_type; > > public: > typedef typename ::boost::mpl::if_ > < > typename ::boost::is_const< > typename value_type::second_type >::type, > > non_mutable_data_unique_map_view_access<Derived,Tag,BimapType>, > mutable_data_unique_map_view_access<Derived,Tag,BimapType> > > >::type type; >}; > > > > > >template< class MapView > >struct left_map_view_extra_typedefs {}; > >template< class MapView > >struct right_map_view_extra_typedefs {}; > >} > > > > >template <class T> inline const T& make_const(const T& t) { return t; } > >} >} ># 23 "/usr/include/boost/bimap/views/map_view.hpp" 2 3 4 > >namespace boost { >namespace bimaps { >namespace views { ># 37 "/usr/include/boost/bimap/views/map_view.hpp" 3 4 >template< class Tag, class BimapType > >class map_view >: > public ::boost::bimaps::container_adaptor::map_adaptor < typename BimapType::core_type:: template index<Tag>::type, ::boost::bimaps::detail:: map_view_iterator<Tag,BimapType>, ::boost::bimaps::detail::const_map_view_iterator<Tag,BimapType>, ::boost::bimaps::detail:: reverse_map_view_iterator<Tag,BimapType>, ::boost::bimaps::detail::const_reverse_map_view_iterator<Tag,BimapType>, ::boost::bimaps::container_adaptor::support::iterator_facade_to_base < ::boost::bimaps::detail:: map_view_iterator<Tag,BimapType>, ::boost::bimaps::detail::const_map_view_iterator<Tag,BimapType> >, ::boost::mpl::na, ::boost::mpl::na, ::boost::bimaps::relation::detail:: pair_to_relation_functor<Tag,typename BimapType::relation>, ::boost::bimaps::relation::support:: get_pair_functor<Tag, typename BimapType::relation > > > > > > , > public ::boost::bimaps::detail:: > map_view_base< map_view<Tag,BimapType>,Tag,BimapType >, > public ::boost::bimaps::detail:: > unique_map_view_access< map_view<Tag,BimapType>, Tag, BimapType>::type >{ > typedef ::boost::bimaps::container_adaptor::map_adaptor < typename BimapType::core_type:: template index<Tag>::type, ::boost::bimaps::detail:: map_view_iterator<Tag,BimapType>, ::boost::bimaps::detail::const_map_view_iterator<Tag,BimapType>, ::boost::bimaps::detail:: reverse_map_view_iterator<Tag,BimapType>, ::boost::bimaps::detail::const_reverse_map_view_iterator<Tag,BimapType>, ::boost::bimaps::container_adaptor::support::iterator_facade_to_base < ::boost::bimaps::detail:: map_view_iterator<Tag,BimapType>, ::boost::bimaps::detail::const_map_view_iterator<Tag,BimapType> >, ::boost::mpl::na, ::boost::mpl::na, ::boost::bimaps::relation::detail:: pair_to_relation_functor<Tag,typename BimapType::relation>, ::boost::bimaps::relation::support:: get_pair_functor<Tag, typename BimapType::relation > > > > > > > base_; > > friend class ::boost::bimaps::detail::map_view_base< map_view<Tag,BimapType>,Tag,BimapType >; > > typedef typename ::boost::bimaps::detail:: > unique_map_view_access< > map_view<Tag,BimapType>, Tag, BimapType > > >::type unique_map_view_access_; > > public: > > typedef typename base_::value_type::info_type info_type; > > map_view(typename base_::base_type & c) : base_(c) {} > > using unique_map_view_access_::at; > using unique_map_view_access_::operator[]; > > typedef std::pair< typename base_::iterator, typename base_::iterator> range_type; typedef std::pair< typename base_::const_iterator, typename base_::const_iterator> const_range_type; template< class LowerBounder, class UpperBounder> range_type range(LowerBounder lower,UpperBounder upper) { std::pair< typename base_::base_type::iterator, typename base_::base_type::iterator > r( this->base().range(lower,upper) ); return range_type( this->template functor< typename base_::iterator_from_base >() ( r.first ), this->template functor< typename base_::iterator_from_base >() ( r.second ) ); } template< class LowerBounder, class UpperBounder> const_range_type range(LowerBounder lower,UpperBounder upper) const { std::pair< typename base_::base_type::const_iterator, typename base_::base_type::const_iterator > r( this->base().range(lower,upper) ); return const_range_type( this->template functor< typename base_::iterator_from_base >() ( r.first ), this->template functor< typename base_::iterator_from_base >() ( r.second ) ); } > > map_view & operator=(const map_view & v) > { > this->base() = v.base(); > return *this; > } > > > > > template< class CompatibleKey > > const info_type & info_at(const CompatibleKey& k) const > { > typename base_::const_iterator iter = this->find(k); > if( iter == this->end() ) > { > ::boost::throw_exception( > std::out_of_range("bimap<>: invalid key") > ); > } > return iter->info; > } > > template< class CompatibleKey > > info_type & info_at(const CompatibleKey& k) > { > typename base_::iterator iter = this->find(k); > if( iter == this->end() ) > { > ::boost::throw_exception( > std::out_of_range("bimap<>: invalid key") > ); > } > return iter->info; > } >}; > >} ># 129 "/usr/include/boost/bimap/views/map_view.hpp" 3 4 >namespace detail { > >template< class Tag, class BimapType > >struct left_map_view_extra_typedefs< ::boost::bimaps::views::map_view<Tag,BimapType> > >{ > private: typedef ::boost::bimaps::views::map_view<Tag,BimapType> map_view_; > public : typedef typename map_view_::reverse_iterator left_reverse_iterator; typedef typename map_view_::const_reverse_iterator left_const_reverse_iterator; typedef typename map_view_::range_type left_range_type; typedef typename map_view_::const_range_type left_const_range_type; typedef typename map_view_::key_compare left_key_compare; >}; > >template< class Tag, class BimapType > >struct right_map_view_extra_typedefs< ::boost::bimaps::views::map_view<Tag,BimapType> > >{ > private: typedef ::boost::bimaps::views::map_view<Tag,BimapType> map_view_; > public : typedef typename map_view_::reverse_iterator right_reverse_iterator; typedef typename map_view_::const_reverse_iterator right_const_reverse_iterator; typedef typename map_view_::range_type right_range_type; typedef typename map_view_::const_range_type right_const_range_type; typedef typename map_view_::key_compare right_key_compare; >}; > >} > > > > > > >} >} ># 40 "/usr/include/boost/bimap/set_of.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/views/set_view.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/views/set_view.hpp" 3 4 ># 1 "/usr/include/boost/bimap/container_adaptor/set_adaptor.hpp" 1 3 4 ># 25 "/usr/include/boost/bimap/container_adaptor/set_adaptor.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace container_adaptor { > > > >template >< > class Base, > > class Iterator, > class ConstIterator, > class ReverseIterator, > class ConstReverseIterator, > > class IteratorToBaseConverter = ::boost::mpl::na, > class IteratorFromBaseConverter = ::boost::mpl::na, > class ReverseIteratorFromBaseConverter = ::boost::mpl::na, > class ValueToBaseConverter = ::boost::mpl::na, > class ValueFromBaseConverter = ::boost::mpl::na, > class KeyToBaseConverter = ::boost::mpl::na, > > class FunctorsFromDerivedClasses = mpl::vector<> >> >class set_adaptor : > > public ::boost::bimaps::container_adaptor:: > ordered_associative_container_adaptor > < > Base, > Iterator, ConstIterator, ReverseIterator, ConstReverseIterator, > typename Iterator::value_type, > IteratorToBaseConverter, IteratorFromBaseConverter, > ReverseIteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, > KeyToBaseConverter, > FunctorsFromDerivedClasses > > >{ > > typedef ::boost::bimaps::container_adaptor:: > ordered_associative_container_adaptor > < > Base, > Iterator, ConstIterator, ReverseIterator, ConstReverseIterator, > typename Iterator::value_type, > IteratorToBaseConverter, IteratorFromBaseConverter, > ReverseIteratorFromBaseConverter, > ValueToBaseConverter, ValueFromBaseConverter, > KeyToBaseConverter, > FunctorsFromDerivedClasses > > > base_; > > > > public: > > explicit set_adaptor(Base & c) : > base_(c) {} > > protected: > > typedef set_adaptor set_adaptor_; > >}; > > >} >} >} ># 22 "/usr/include/boost/bimap/views/set_view.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/detail/set_view_base.hpp" 1 3 4 ># 24 "/usr/include/boost/bimap/detail/set_view_base.hpp" 3 4 ># 1 "/usr/include/boost/bimap/detail/set_view_iterator.hpp" 1 3 4 ># 31 "/usr/include/boost/bimap/detail/set_view_iterator.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace detail { ># 46 "/usr/include/boost/bimap/detail/set_view_iterator.hpp" 3 4 >template< class CoreIterator > struct set_view_iterator; > >template< class CoreIterator > >struct set_view_iterator_base >{ > typedef iterator_adaptor > < > set_view_iterator< CoreIterator >, > CoreIterator, > typename CoreIterator::value_type::above_view > > > type; >}; > > > >template< class CoreIterator > >struct set_view_iterator : public set_view_iterator_base<CoreIterator>::type >{ > typedef typename set_view_iterator_base<CoreIterator>::type base_; > > public: > > set_view_iterator() {} > > set_view_iterator(CoreIterator const& iter) > : base_(iter) {} > > set_view_iterator(set_view_iterator const & iter) > : base_(iter.base()) {} > > typename base_::reference dereference() const > { > return const_cast< > typename base_::base_type::value_type*>( > &(*this->base()) > )->get_view(); > } > > private: > > friend class iterator_core_access; > > > > > > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } > > friend class ::boost::serialization::access; > > template< class Archive > > void save(Archive & ar, const unsigned int) const > { > ar << ::boost::serialization::make_nvp("mi_iterator",this->base()); > } > > template< class Archive > > void load(Archive & ar, const unsigned int) > { > CoreIterator iter; > ar >> ::boost::serialization::make_nvp("mi_iterator",iter); > this->base_reference() = iter; > } > > >}; > > > >template< class CoreIterator > struct const_set_view_iterator; > >template< class CoreIterator > >struct const_set_view_iterator_base >{ > typedef iterator_adaptor > < > const_set_view_iterator< CoreIterator >, > CoreIterator, > const typename CoreIterator::value_type::above_view > > > type; >}; ># 138 "/usr/include/boost/bimap/detail/set_view_iterator.hpp" 3 4 >template< class CoreIterator > >struct const_set_view_iterator : public const_set_view_iterator_base<CoreIterator>::type >{ > typedef typename const_set_view_iterator_base<CoreIterator>::type base_; > > public: > > const_set_view_iterator() {} > > const_set_view_iterator(CoreIterator const& iter) > : base_(iter) {} > > const_set_view_iterator(const_set_view_iterator const & iter) > : base_(iter.base()) {} > > const_set_view_iterator(set_view_iterator<CoreIterator> i) > : base_(i.base()) {} > > typename base_::reference dereference() const > { > return this->base()->get_view(); > } > > private: > > friend class iterator_core_access; > > > > > > template<class Archive> void serialize( Archive &ar, const unsigned int file_version ){ boost::serialization::split_member(ar, *this, file_version); } > > friend class ::boost::serialization::access; > > template< class Archive > > void save(Archive & ar, const unsigned int) const > { > ar << ::boost::serialization::make_nvp("mi_iterator",this->base()); > } > > template< class Archive > > void load(Archive & ar, const unsigned int) > { > CoreIterator iter; > ar >> ::boost::serialization::make_nvp("mi_iterator",iter); > this->base_reference() = iter; > } > > >}; > > >} >} >} ># 25 "/usr/include/boost/bimap/detail/set_view_base.hpp" 2 3 4 > > > > > >namespace boost { >namespace bimaps { >namespace detail { > >template< class Key, class Value, class KeyToBase > >class set_view_key_to_base >{ > public: > const Key operator()( const Value & v ) const > { > return keyToBase( v ); > } > private: > KeyToBase keyToBase; >}; > >template< class MutantRelationStorage, class KeyToBase > >class set_view_key_to_base<MutantRelationStorage,MutantRelationStorage,KeyToBase> >{ > typedef typename MutantRelationStorage::non_mutable_storage non_mutable_storage; > public: > const MutantRelationStorage & operator()( const non_mutable_storage & k ) const > { > return ::boost::bimaps::relation::detail::mutate<MutantRelationStorage>(k); > } > const MutantRelationStorage & operator()( const MutantRelationStorage & k ) const > { > return k; > } >}; ># 164 "/usr/include/boost/bimap/detail/set_view_base.hpp" 3 4 >template< class Derived, class Index > >class set_view_base >{ > typedef ::boost::bimaps::container_adaptor::support:: > iterator_facade_to_base > < > ::boost::bimaps::detail:: > set_view_iterator<typename Index:: iterator>, > ::boost::bimaps::detail:: > const_set_view_iterator<typename Index::const_iterator> > > > iterator_to_base_; > > typedef typename Index::value_type::left_value_type left_type_; > > typedef typename Index::value_type::right_value_type right_type_; > > typedef typename Index::value_type value_type_; > > typedef ::boost::bimaps::detail:: > set_view_iterator<typename Index::iterator> iterator_; > > public: > > bool replace(iterator_ position, > const value_type_ & x) > { > return derived().base().replace( > derived().template functor<iterator_to_base_>()(position),x > ); > } > > template< class CompatibleLeftType > > bool replace_left(iterator_ position, > const CompatibleLeftType & l) > { > return derived().base().replace( > derived().template functor<iterator_to_base_>()(position), > ::boost::bimaps::relation::detail::copy_with_left_replaced(*position,l) > ); > } > > template< class CompatibleRightType > > bool replace_right(iterator_ position, > const CompatibleRightType & r) > { > return derived().base().replace( > derived().template functor<iterator_to_base_>()(position), > ::boost::bimaps::relation::detail::copy_with_right_replaced(*position,r) > ); > } ># 306 "/usr/include/boost/bimap/detail/set_view_base.hpp" 3 4 > protected: > > typedef set_view_base set_view_base_; > > private: > > > > Derived& derived() > { > return *static_cast<Derived*>(this); > } > > Derived const& derived() const > { > return *static_cast<Derived const*>(this); > } >}; > > > >} >} >} ># 23 "/usr/include/boost/bimap/views/set_view.hpp" 2 3 4 > >namespace boost { >namespace bimaps { >namespace views { ># 37 "/usr/include/boost/bimap/views/set_view.hpp" 3 4 >template< class CoreIndex > >class set_view >: > public ::boost::bimaps::container_adaptor::set_adaptor < CoreIndex, ::boost::bimaps::detail:: set_view_iterator< typename CoreIndex::iterator >, ::boost::bimaps::detail:: const_set_view_iterator< typename CoreIndex::const_iterator >, ::boost::bimaps::detail:: set_view_iterator< typename CoreIndex::reverse_iterator >, ::boost::bimaps::detail:: const_set_view_iterator< typename CoreIndex::const_reverse_iterator >, ::boost::bimaps::container_adaptor::support::iterator_facade_to_base < ::boost::bimaps::detail:: set_view_iterator< typename CoreIndex::iterator>, ::boost::bimaps::detail::const_set_view_iterator< typename CoreIndex::const_iterator> >, ::boost::mpl::na, ::boost::mpl::na, ::boost::bimaps::relation::detail:: get_mutable_relation_functor< typename CoreIndex::value_type >, ::boost::bimaps::relation::support:: get_above_view_functor< typename CoreIndex::value_type >, ::boost::bimaps::detail::set_view_key_to_base< typename CoreIndex::key_type, typename CoreIndex::value_type, typename CoreIndex::key_from_value > > > > > > , > > public ::boost::bimaps::detail:: > set_view_base< set_view< CoreIndex >, CoreIndex > >{ > typedef ::boost::bimaps::container_adaptor::set_adaptor < CoreIndex, ::boost::bimaps::detail:: set_view_iterator< typename CoreIndex::iterator >, ::boost::bimaps::detail:: const_set_view_iterator< typename CoreIndex::const_iterator >, ::boost::bimaps::detail:: set_view_iterator< typename CoreIndex::reverse_iterator >, ::boost::bimaps::detail:: const_set_view_iterator< typename CoreIndex::const_reverse_iterator >, ::boost::bimaps::container_adaptor::support::iterator_facade_to_base < ::boost::bimaps::detail:: set_view_iterator< typename CoreIndex::iterator>, ::boost::bimaps::detail::const_set_view_iterator< typename CoreIndex::const_iterator> >, ::boost::mpl::na, ::boost::mpl::na, ::boost::bimaps::relation::detail:: get_mutable_relation_functor< typename CoreIndex::value_type >, ::boost::bimaps::relation::support:: get_above_view_functor< typename CoreIndex::value_type >, ::boost::bimaps::detail::set_view_key_to_base< typename CoreIndex::key_type, typename CoreIndex::value_type, typename CoreIndex::key_from_value > > > > > > > base_; > > friend class ::boost::bimaps::detail::set_view_base< set_view< CoreIndex >, CoreIndex >; > > public: > > set_view(typename base_::base_type & c) : base_(c) {} ># 92 "/usr/include/boost/bimap/views/set_view.hpp" 3 4 > set_view & operator=(const set_view & v) > { > this->base() = v.base(); > return *this; > } >}; > > >} >} >} ># 41 "/usr/include/boost/bimap/set_of.hpp" 2 3 4 > >namespace boost { >namespace bimaps { ># 109 "/usr/include/boost/bimap/set_of.hpp" 3 4 >template >< > class KeyType, > class KeyCompare = std::less< typename > ::boost::bimaps::tags::support::value_type_of<KeyType>::type > >> >struct set_of : public ::boost::bimaps::detail::set_type_of_tag >{ > > typedef KeyType user_type; > > > typedef typename ::boost::bimaps::tags::support:: > value_type_of<user_type>::type value_type; > > > typedef KeyCompare key_compare; > > struct lazy_concept_checked > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::AssignableConcept<value_type>)>::failed> boost_concept_check130 > ; > > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::BinaryFunctionConcept<key_compare,bool,value_type,value_type>)>::failed> boost_concept_check133 > ; > > typedef set_of type; > }; > > template< class KeyExtractor, class Tag > struct index_bind { typedef multi_index::ordered_unique < multi_index::tag< Tag >, KeyExtractor, key_compare > type; }; ># 147 "/usr/include/boost/bimap/set_of.hpp" 3 4 > template< class Tag, class BimapType > struct map_view_bind { typedef views::map_view < Tag, BimapType > type; }; > > > > > > template< class IndexType > struct set_view_bind { typedef views::set_view<IndexType> type; }; > > > > > > typedef mpl::bool_<false> mutable_key; >}; ># 182 "/usr/include/boost/bimap/set_of.hpp" 3 4 >template< class KeyCompare = std::less< _relation > > >struct set_of_relation : public ::boost::bimaps::detail::set_type_of_relation_tag >{ > > typedef KeyCompare key_compare; > > template< class Relation > struct bind_to { typedef set_of < Relation, typename mpl::apply<key_compare, typename Relation::storage_base >::type > type; }; ># 197 "/usr/include/boost/bimap/set_of.hpp" 3 4 > typedef mpl::bool_<false> left_mutable_key; > typedef mpl::bool_<false> right_mutable_key; >}; > >} >} ># 27 "/usr/include/boost/bimap/detail/manage_bimap_key.hpp" 2 3 4 > >namespace boost { >namespace bimaps { >namespace detail { ># 48 "/usr/include/boost/bimap/detail/manage_bimap_key.hpp" 3 4 >template< class Type > >struct manage_bimap_key >{ > >typedef typename > > mpl::eval_if< typename is_set_type_of< Type >::type, > > mpl::identity< Type >, > > > > > mpl::identity< set_of< Type > > > > > >::type set_type; > > > > typedef typename mpl::if_c< true, set_type, > typename set_type::lazy_concept_checked::type > >::type type; >}; > > > > > >} >} >} ># 44 "/usr/include/boost/bimap/detail/bimap_core.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/detail/manage_additional_parameters.hpp" 1 3 4 ># 31 "/usr/include/boost/bimap/detail/manage_additional_parameters.hpp" 3 4 >namespace boost { >namespace bimaps { > >template< class Type > >struct with_info >{ > typedef Type value_type; >}; > >namespace detail { > > > >template< class Type > >struct is_with_info : ::boost::mpl::false_ {}; > >template< class ValueType > >struct is_with_info< with_info<ValueType> > : ::boost::mpl::true_ {}; ># 73 "/usr/include/boost/bimap/detail/manage_additional_parameters.hpp" 3 4 >template< class AP1, class AP2, class AP3 > >struct manage_additional_parameters >{ > > > > > > > > struct case_NNN > { > typedef left_based set_type_of_relation; > typedef std::allocator<void> allocator; > typedef ::boost::mpl::na additional_info; > }; > > > > > > > > struct case_ANN > { > typedef left_based set_type_of_relation; > typedef AP1 allocator; > typedef ::boost::mpl::na additional_info; > }; ># 110 "/usr/include/boost/bimap/detail/manage_additional_parameters.hpp" 3 4 > struct case_SNN > { > typedef AP1 set_type_of_relation; > typedef std::allocator<void> allocator; > typedef ::boost::mpl::na additional_info; > }; ># 124 "/usr/include/boost/bimap/detail/manage_additional_parameters.hpp" 3 4 > struct case_SAN > { > typedef AP1 set_type_of_relation; > typedef AP2 allocator; > typedef ::boost::mpl::na additional_info; > }; > > > > > > > > struct case_HNN > { > typedef left_based set_type_of_relation; > typedef std::allocator<void> allocator; > typedef typename AP1::value_type additional_info; > }; ># 151 "/usr/include/boost/bimap/detail/manage_additional_parameters.hpp" 3 4 > struct case_SHN > { > typedef AP1 set_type_of_relation; > typedef std::allocator<void> allocator; > typedef typename AP2::value_type additional_info; > }; ># 165 "/usr/include/boost/bimap/detail/manage_additional_parameters.hpp" 3 4 > struct case_HAN > { > typedef left_based set_type_of_relation; > typedef AP2 allocator; > typedef typename AP1::value_type additional_info; > }; ># 179 "/usr/include/boost/bimap/detail/manage_additional_parameters.hpp" 3 4 > struct case_SHA > { > typedef AP1 set_type_of_relation; > typedef AP2 allocator; > typedef typename AP2::value_type additional_info; > }; > > > > typedef typename mpl::if_ > < > ::boost::mpl::is_na<AP1>, > case_NNN, > typename mpl::if_ > < > ::boost::mpl::is_na<AP2>, > typename mpl::if_ > < > is_set_type_of_relation<AP1>, > case_SNN, > typename mpl::if_ > < > is_with_info<AP1>, > case_HNN, > case_ANN > > >::type > > >::type, > typename mpl::if_ > < > ::boost::mpl::is_na<AP3>, > typename mpl::if_ > < > is_with_info<AP1>, > case_HAN, > typename mpl::if_ > < > is_with_info<AP2>, > case_SHN, > case_SAN > > >::type > > >::type, > > case_SHA > > >::type > > >::type > > >::type type; > >}; > > > >} >} >} ># 45 "/usr/include/boost/bimap/detail/bimap_core.hpp" 2 3 4 > > > > ># 1 "/usr/include/boost/bimap/unconstrained_set_of.hpp" 1 3 4 ># 35 "/usr/include/boost/bimap/unconstrained_set_of.hpp" 3 4 ># 1 "/usr/include/boost/bimap/views/unconstrained_map_view.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/views/unconstrained_map_view.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace views { > > > >template< class Tag, class BimapType> >class unconstrained_map_view >{ > public: > template< class T > > unconstrained_map_view(const T &) {} > > typedef void iterator; > typedef void const_iterator; > typedef void reference; > typedef void const_reference; > typedef void info_type; >}; > >} >} >} ># 36 "/usr/include/boost/bimap/unconstrained_set_of.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/views/unconstrained_set_view.hpp" 1 3 4 ># 21 "/usr/include/boost/bimap/views/unconstrained_set_view.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace views { > > > >template< class CoreIndex > >class unconstrained_set_view >{ > public: > template< class T > > unconstrained_set_view(const T &) {} > > typedef void iterator; > typedef void const_iterator; >}; > >} >} >} ># 37 "/usr/include/boost/bimap/unconstrained_set_of.hpp" 2 3 4 > >namespace boost { >namespace bimaps { ># 60 "/usr/include/boost/bimap/unconstrained_set_of.hpp" 3 4 >template >< > class KeyType >> >struct unconstrained_set_of : public ::boost::bimaps::detail::set_type_of_tag >{ > > typedef KeyType user_type; > > > typedef typename ::boost::bimaps::tags::support:: > value_type_of<user_type>::type value_type; > > struct lazy_concept_checked > { > typedef ::boost::concepts::detail::instantiate< &::boost::concepts::requirement_<void(*)(boost::AssignableConcept<value_type>)>::failed> boost_concept_check76 > ; > > typedef unconstrained_set_of type; > }; > > template< class KeyExtractor, class Tag > struct index_bind { typedef void type; }; > > template< class Tag, class BimapType > struct map_view_bind { typedef views::unconstrained_map_view < Tag, BimapType > type; }; > > > > > > template< class IndexType > struct set_view_bind { typedef views::unconstrained_set_view<IndexType> type; }; > > > > > > typedef mpl::bool_<true> mutable_key; >}; ># 107 "/usr/include/boost/bimap/unconstrained_set_of.hpp" 3 4 >struct unconstrained_set_of_relation : public ::boost::bimaps::detail::set_type_of_relation_tag >{ > > template< class Relation > struct bind_to { typedef unconstrained_set_of<Relation> type; }; > > > > > > typedef mpl::bool_<true> left_mutable_key; > typedef mpl::bool_<true> right_mutable_key; >}; > > > >namespace detail { > >template<class T> >struct is_unconstrained_set_of : > ::boost::mpl::false_ {}; > >template<class T> >struct is_unconstrained_set_of< unconstrained_set_of<T> > : > ::boost::mpl::true_ {}; > >} > > > >} >} ># 50 "/usr/include/boost/bimap/detail/bimap_core.hpp" 2 3 4 > >namespace boost { >namespace bimaps { > > > >namespace detail { > > > >template< class Type > >struct get_value_type >{ > typedef typename Type::value_type type; >}; > >struct independent_index_tag {}; ># 79 "/usr/include/boost/bimap/detail/bimap_core.hpp" 3 4 >template< class LeftSetType, class RightSetType, class AP1, class AP2, class AP3 > >class bimap_core >{ > > > public: > > typedef typename manage_bimap_key > < > LeftSetType > > >::type left_set_type; > > typedef typename manage_bimap_key > < > RightSetType > > >::type right_set_type; > > > private: > > typedef typename ::boost::bimaps::tags::support::default_tagged > < > typename left_set_type::user_type, > ::boost::bimaps::relation::member_at::left > > >::type left_tagged_type; > > typedef typename ::boost::bimaps::tags::support::default_tagged > < > typename right_set_type::user_type, > ::boost::bimaps::relation::member_at::right > > >::type right_tagged_type; > > public: > > > > typedef typename left_tagged_type::tag left_tag; > typedef typename right_tagged_type::tag right_tag; > > > > > > typedef typename left_set_type::value_type left_key_type; > typedef typename right_set_type::value_type right_key_type; > > > > > > typedef right_key_type left_data_type; > typedef left_key_type right_data_type; > > > > > > private: > > typedef typename manage_additional_parameters<AP1,AP2,AP3>::type parameters; > > > > public: > > typedef ::boost::bimaps::relation::mutant_relation > < > > ::boost::bimaps::tags::tagged< > typename mpl::if_< > mpl::and_ > < > typename left_set_type::mutable_key, > typename parameters::set_type_of_relation::left_mutable_key > >, > > left_key_type, > > > > typename ::boost::add_const< left_key_type >::type > > > >::type, > left_tag > >, > > ::boost::bimaps::tags::tagged< > typename mpl::if_< > mpl::and_ > < > typename right_set_type::mutable_key, > typename parameters::set_type_of_relation::right_mutable_key > >, > > right_key_type, > > > > typename ::boost::add_const< right_key_type >::type > > > >::type, > right_tag > >, > > > typename parameters::additional_info, > > > true > > > relation; > > > > typedef typename relation::left_pair left_value_type; > typedef typename relation::right_pair right_value_type; > > > > > > private: > > typedef typename relation::storage_base relation_storage_base; > > typedef ::boost::multi_index::member< relation_storage_base,left_key_type,&relation_storage_base::left > > left_member_extractor; > > typedef ::boost::multi_index::member< relation_storage_base,right_key_type,&relation_storage_base::right > > right_member_extractor; > > > > > > > typedef typename mpl::if_< > ::boost::bimaps::detail::is_unconstrained_set_of< left_set_type >, > > mpl::vector<>, > > > > mpl::vector > < > typename left_set_type:: > template index_bind > < > left_member_extractor, > left_tag > > >::type > > > > >::type left_core_indices; > > typedef typename mpl::if_< > ::boost::bimaps::detail::is_unconstrained_set_of< right_set_type >, > > left_core_indices, > > > > typename mpl::push_front > < > left_core_indices, > > typename right_set_type:: > template index_bind > < > right_member_extractor, > right_tag > > >::type > > >::type > > >::type basic_core_indices; ># 273 "/usr/include/boost/bimap/detail/bimap_core.hpp" 3 4 > typedef typename mpl::if_< > > is_same< typename parameters::set_type_of_relation, left_based >, > > ::boost::bimaps::tags::tagged< left_set_type, left_tag >, > > typename mpl::if_< > is_same< typename parameters::set_type_of_relation, right_based >, > > ::boost::bimaps::tags::tagged< right_set_type, right_tag >, > > > > tags::tagged > < > typename parameters:: > set_type_of_relation::template bind_to > < > relation > > >::type, > independent_index_tag > > > > >::type > >::type tagged_set_of_relation_type; > > protected: > > typedef typename tagged_set_of_relation_type::tag > relation_set_tag; > > typedef typename tagged_set_of_relation_type::value_type > relation_set_type_of; > > > > > > > typedef typename mpl::if_< > ::boost::bimaps::detail::is_unconstrained_set_of< left_set_type >, > > typename mpl::if_< > ::boost::bimaps::detail::is_unconstrained_set_of< right_set_type >, > > independent_index_tag, > right_tag > > >::type, > > left_tag > > >::type logic_left_tag; > > typedef typename mpl::if_< > ::boost::bimaps::detail::is_unconstrained_set_of< right_set_type >, > > typename mpl::if_< > ::boost::bimaps::detail::is_unconstrained_set_of< left_set_type >, > > independent_index_tag, > left_tag > > >::type, > > right_tag > > >::type logic_right_tag; > > typedef typename mpl::if_< > is_same< relation_set_tag, independent_index_tag >, > > typename mpl::if_< > ::boost::bimaps::detail:: > is_unconstrained_set_of< relation_set_type_of >, > > logic_left_tag, > independent_index_tag > > >::type, > > typename mpl::if_< > is_same< typename parameters::set_type_of_relation, left_based >, > > logic_left_tag, > logic_right_tag > > >::type > > >::type logic_relation_set_tag; > > private: > > typedef typename mpl::if_< > mpl::and_< is_same< relation_set_tag, independent_index_tag >, > mpl::not_< > ::boost::bimaps::detail:: > is_unconstrained_set_of< relation_set_type_of > > > > >, > > typename mpl::push_front > < > basic_core_indices, > > typename relation_set_type_of:: > template index_bind > < > ::boost::bimaps::relation::support::both_keys_extractor<relation>, > independent_index_tag > > >::type > > >::type, > > > > basic_core_indices > > > >::type complete_core_indices; > > struct core_indices : public complete_core_indices {}; > > > > > public: > > typedef multi_index::multi_index_container > < > relation, > core_indices, > typename parameters::allocator:: > template rebind<relation>::other > > > core_type; > > > > public: > > typedef typename ::boost::multi_index:: > index<core_type, logic_left_tag>::type left_index; > > typedef typename ::boost::multi_index:: > index<core_type,logic_right_tag>::type right_index; > > typedef typename left_index::iterator left_core_iterator; > typedef typename left_index::const_iterator left_core_const_iterator; > > typedef typename right_index::iterator right_core_iterator; > typedef typename right_index::const_iterator right_core_const_iterator; > > > > typedef typename ::boost::multi_index::index > < > core_type, logic_relation_set_tag > > >::type relation_set_core_index; > > typedef typename relation_set_type_of:: > template set_view_bind > < > relation_set_core_index > > >::type relation_set; > > public: > > typedef bimap_core bimap_core_; >}; > > > > > >template< class BimapBaseType > >struct left_map_view_type >{ > typedef typename BimapBaseType::left_set_type left_set_type; > typedef typename > left_set_type::template map_view_bind< > typename BimapBaseType::left_tag, BimapBaseType > >::type type; >}; > >template< class BimapBaseType > >struct right_map_view_type >{ > typedef typename BimapBaseType::right_set_type right_set_type; > typedef typename > right_set_type::template map_view_bind< > typename BimapBaseType::right_tag, BimapBaseType > >::type type; >}; > > >} >} >} ># 62 "/usr/include/boost/bimap/bimap.hpp" 2 3 4 > > > > > ># 1 "/usr/include/boost/bimap/support/map_type_by.hpp" 1 3 4 ># 44 "/usr/include/boost/bimap/support/map_type_by.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace support { > > > >template < class Tag, class SymmetricType, class Enable = void > struct map_type_by { struct BIMAP_STATIC_ERROR__map_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__map_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__map_type_by_FAILURE55 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__map_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg55; enum { mpl_assertion_in_line_55 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg55::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct map_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_map type; }; template< class Tag, class SymmetricType > struct map_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_map type; }; ># 59 "/usr/include/boost/bimap/support/map_type_by.hpp" 3 4 >} >} >} ># 68 "/usr/include/boost/bimap/bimap.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/support/map_by.hpp" 1 3 4 ># 66 "/usr/include/boost/bimap/support/map_by.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace support { ># 99 "/usr/include/boost/bimap/support/map_by.hpp" 3 4 >namespace result_of { template< class Tag, class SymmetricType > struct map_by { typedef typename map_type_by < Tag,SymmetricType >::type value_type; typedef typename mpl::if_< is_const<SymmetricType>, typename call_traits<value_type>::const_reference, typename call_traits<value_type>::reference >::type type; }; } ># 108 "/usr/include/boost/bimap/support/map_by.hpp" 3 4 >namespace detail { template< class Bimap > typename result_of::map_by < ::boost::bimaps::relation::member_at::left,Bimap >::type map_by( ::boost::bimaps::relation::member_at::left, Bimap & b ) { return b.left; } template< class Bimap > typename result_of::map_by < ::boost::bimaps::relation::member_at::right,Bimap >::type map_by( ::boost::bimaps::relation::member_at::right, Bimap & b ) { return b.right; } } ># 120 "/usr/include/boost/bimap/support/map_by.hpp" 3 4 >template< class Tag, class SymmetricType > typename result_of::map_by<Tag,SymmetricType>::type map_by( SymmetricType & s ) { typedef typename ::boost::bimaps::relation::support:: member_with_tag < Tag,SymmetricType >::type member_at_tag; return detail::map_by(member_at_tag(),s); } > > > > >} >} >} ># 69 "/usr/include/boost/bimap/bimap.hpp" 2 3 4 ># 1 "/usr/include/boost/bimap/support/iterator_type_by.hpp" 1 3 4 ># 75 "/usr/include/boost/bimap/support/iterator_type_by.hpp" 3 4 >namespace boost { >namespace bimaps { >namespace support { > > > >template < class Tag, class SymmetricType, class Enable = void > struct iterator_type_by { struct BIMAP_STATIC_ERROR__iterator_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__iterator_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__iterator_type_by_FAILURE86 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__iterator_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg86; enum { mpl_assertion_in_line_86 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg86::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_iterator type; }; template< class Tag, class SymmetricType > struct iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_iterator type; }; ># 90 "/usr/include/boost/bimap/support/iterator_type_by.hpp" 3 4 >template < class Tag, class SymmetricType, class Enable = void > struct const_iterator_type_by { struct BIMAP_STATIC_ERROR__const_iterator_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__const_iterator_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__const_iterator_type_by_FAILURE95 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__const_iterator_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg95; enum { mpl_assertion_in_line_95 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg95::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct const_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_const_iterator type; }; template< class Tag, class SymmetricType > struct const_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_const_iterator type; }; ># 100 "/usr/include/boost/bimap/support/iterator_type_by.hpp" 3 4 >template < class Tag, class SymmetricType, class Enable = void > struct reverse_iterator_type_by { struct BIMAP_STATIC_ERROR__reverse_iterator_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__reverse_iterator_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__reverse_iterator_type_by_FAILURE105 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__reverse_iterator_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg105; enum { mpl_assertion_in_line_105 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg105::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct reverse_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_reverse_iterator type; }; template< class Tag, class SymmetricType > struct reverse_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_reverse_iterator type; }; ># 109 "/usr/include/boost/bimap/support/iterator_type_by.hpp" 3 4 >template < class Tag, class SymmetricType, class Enable = void > struct const_reverse_iterator_type_by { struct BIMAP_STATIC_ERROR__const_reverse_iterator_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__const_reverse_iterator_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__const_reverse_iterator_type_by_FAILURE114 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__const_reverse_iterator_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg114; enum { mpl_assertion_in_line_114 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg114::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct const_reverse_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_const_reverse_iterator type; }; template< class Tag, class SymmetricType > struct const_reverse_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_const_reverse_iterator type; }; ># 119 "/usr/include/boost/bimap/support/iterator_type_by.hpp" 3 4 >template < class Tag, class SymmetricType, class Enable = void > struct local_iterator_type_by { struct BIMAP_STATIC_ERROR__local_iterator_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__local_iterator_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__local_iterator_type_by_FAILURE124 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__local_iterator_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg124; enum { mpl_assertion_in_line_124 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg124::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct local_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_local_iterator type; }; template< class Tag, class SymmetricType > struct local_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_local_iterator type; }; ># 128 "/usr/include/boost/bimap/support/iterator_type_by.hpp" 3 4 >template < class Tag, class SymmetricType, class Enable = void > struct const_local_iterator_type_by { struct BIMAP_STATIC_ERROR__const_local_iterator_type_by_FAILURE {}; struct BIMAP_STATIC_ERROR__const_local_iterator_type_by_FAILURE; typedef struct BIMAP_STATIC_ERROR__const_local_iterator_type_by_FAILURE133 : boost::mpl::assert_ { static boost::mpl::failed ************ (BIMAP_STATIC_ERROR__const_local_iterator_type_by_FAILURE::************ assert_arg()) (SymmetricType,Tag) { return 0; } } mpl_assert_arg133; enum { mpl_assertion_in_line_133 = sizeof( boost::mpl::assertion_failed<(false)>( mpl_assert_arg133::assert_arg() ) ) }; }; template< class Tag, class SymmetricType > struct const_local_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_left < Tag, SymmetricType > >::type > { typedef typename SymmetricType::left_const_local_iterator type; }; template< class Tag, class SymmetricType > struct const_local_iterator_type_by < Tag, SymmetricType, typename enable_if < ::boost::bimaps::relation::support::is_tag_of_member_at_right < Tag, SymmetricType > >::type > { typedef typename SymmetricType::right_const_local_iterator type; }; > > > > > > >} >} >} ># 70 "/usr/include/boost/bimap/bimap.hpp" 2 3 4 > > > >namespace boost { > > > > > >namespace bimaps { ># 126 "/usr/include/boost/bimap/bimap.hpp" 3 4 >template >< > class KeyTypeA, class KeyTypeB, > class AP1 = ::boost::mpl::na, > class AP2 = ::boost::mpl::na, > class AP3 = ::boost::mpl::na >> >class bimap >: > > > public ::boost::bimaps::detail::bimap_core<KeyTypeA,KeyTypeB,AP1,AP2,AP3>, > > > > public ::boost::bimaps::detail::bimap_core<KeyTypeA,KeyTypeB,AP1,AP2,AP3> > ::relation_set, > > > > public ::boost::bimaps::detail:: left_map_view_extra_typedefs< > typename ::boost::bimaps::detail::left_map_view_type< > ::boost::bimaps::detail::bimap_core<KeyTypeA,KeyTypeB,AP1,AP2,AP3> > >::type > >, > public ::boost::bimaps::detail::right_map_view_extra_typedefs< > typename ::boost::bimaps::detail::right_map_view_type< > ::boost::bimaps::detail::bimap_core<KeyTypeA,KeyTypeB,AP1,AP2,AP3> > >::type > > >{ > typedef typename ::boost::bimaps::detail:: > bimap_core<KeyTypeA,KeyTypeB,AP1,AP2,AP3> base_; > > typename base_::core_type core; > > public: ># 181 "/usr/include/boost/bimap/bimap.hpp" 3 4 > typedef typename ::boost::bimaps::detail:: > left_map_view_type<base_>::type left_map; > typedef typename ::boost::bimaps::detail:: > right_map_view_type<base_>::type right_map; > > typedef typename > left_map::iterator left_iterator; > typedef typename > left_map::const_iterator left_const_iterator; > > typedef typename > right_map::iterator right_iterator; > typedef typename > right_map::const_iterator right_const_iterator; > > typedef typename > left_map::reference left_reference; > typedef typename > left_map::const_reference left_const_reference; > > typedef typename > right_map::reference right_reference; > typedef typename > right_map::const_reference right_const_reference; > > typedef typename base_::relation::info_type info_type; > > typedef typename base_::core_type::allocator_type allocator_type; > > > left_map left; > > > right_map right; > > typedef typename base_::logic_relation_set_tag > logic_relation_set_tag; > typedef typename base_::logic_left_tag logic_left_tag; > typedef typename base_::logic_right_tag logic_right_tag; > typedef typename base_::core_type::ctor_args_list > ctor_args_list; > > bimap(const allocator_type& al = allocator_type()) : > > base_::relation_set( > ::boost::multi_index::get< > logic_relation_set_tag > >(core) > ), > > core(al), > > left ( > ::boost::multi_index::get< > logic_left_tag > >(core) > ), > right ( > ::boost::multi_index::get< > logic_right_tag > >(core) > ) > > {} > > template< class InputIterator > > bimap(InputIterator first,InputIterator last, > const allocator_type& al = allocator_type()) : > > base_::relation_set( > ::boost::multi_index::get< > typename base_::logic_relation_set_tag>(core) > ), > > core(first,last,ctor_args_list(),al), > > left ( > ::boost::multi_index::get< > typename base_::logic_left_tag>(core) > ), > right ( > ::boost::multi_index::get< > typename base_::logic_right_tag>(core) > ) > > {} > > bimap(const bimap& x) : > > base_::relation_set( > ::boost::multi_index::get< > typename base_::logic_relation_set_tag>(core) > ), > > core(x.core), > > left ( > ::boost::multi_index::get< > typename base_::logic_left_tag>(core) > ), > right ( > ::boost::multi_index::get< > typename base_::logic_right_tag>(core) > ) > > {} > > bimap& operator=(const bimap& x) > { > core = x.core; > return *this; > } > > > > template< class IteratorType > > left_iterator project_left(IteratorType iter) > { > return core.template project< > typename base_::logic_left_tag>(iter.base()); > } > > template< class IteratorType > > left_const_iterator project_left(IteratorType iter) const > { > return core.template project< > typename base_::logic_left_tag>(iter.base()); > } > > template< class IteratorType > > right_iterator project_right(IteratorType iter) > { > return core.template project< > typename base_::logic_right_tag>(iter.base()); > } > > template< class IteratorType > > right_const_iterator project_right(IteratorType iter) const > { > return core.template project< > typename base_::logic_right_tag>(iter.base()); > } > > template< class IteratorType > > typename base_::relation_set::iterator > project_up(IteratorType iter) > { > return core.template project< > typename base_::logic_relation_set_tag>(iter.base()); > } > > template< class IteratorType > > typename base_::relation_set::const_iterator > project_up(IteratorType iter) const > { > return core.template project< > typename base_::logic_relation_set_tag>(iter.base()); > } > > > > template< class Tag, class IteratorType > > typename ::boost::bimaps::support:: > iterator_type_by<Tag,bimap>::type > project(IteratorType iter > ) > { > return core.template project<Tag>(iter.base()); > } > > template< class Tag, class IteratorType > > typename ::boost::bimaps::support:: > const_iterator_type_by<Tag,bimap>::type > project(IteratorType iter > ) const > { > return core.template project<Tag>(iter.base()); > } > > template< class Tag > > struct map_by : > public ::boost::bimaps::support::map_type_by<Tag,bimap>::type > { > typedef typename ::boost::bimaps::support:: > map_type_by<Tag,bimap>::type type; > > private: map_by() {} > }; > > template< class Tag > > typename ::boost::bimaps::support:: > map_type_by<Tag,bimap>::type & > by() > { > return ::boost::bimaps::support::map_by<Tag>(*this); > } > > template< class Tag > > const typename ::boost::bimaps::support:: > map_type_by<Tag,bimap>::type & > by() const > { > return ::boost::bimaps::support::map_by<Tag>(*this); > } > > > > > > > private: > > friend class boost::serialization::access; > > template<class Archive> > void serialize(Archive & ar, const unsigned int) > { > ar & serialization::make_nvp("mi_core",core); > } > > >}; > >} >} ># 429 "/usr/include/boost/bimap/bimap.hpp" 3 4 >namespace boost { >namespace bimaps { > >using ::boost::bimaps::tags::tagged; > >namespace member_at = ::boost::bimaps::relation::member_at; > >using ::boost::multi_index::unbounded; > >} >} ># 14 "/usr/include/boost/bimap.hpp" 2 3 4 > >namespace boost >{ > using ::boost::bimaps::bimap; >} ># 10 "/c/honeypenny/src/p2p/net_node.h" 2 ># 20 "/c/honeypenny/src/p2p/net_node.h" ># 1 "/c/honeypenny/contrib/epee/include/net/levin_server_cp2.h" 1 ># 33 "/c/honeypenny/contrib/epee/include/net/levin_server_cp2.h" ># 1 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler.h" 1 ># 32 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler.h" ># 1 "/usr/include/boost/uuid/uuid_generators.hpp" 1 3 4 ># 14 "/usr/include/boost/uuid/uuid_generators.hpp" 3 4 ># 1 "/usr/include/boost/uuid/nil_generator.hpp" 1 3 4 ># 13 "/usr/include/boost/uuid/nil_generator.hpp" 3 4 >namespace boost { >namespace uuids { > > >struct nil_generator { > typedef uuid result_type; > > uuid operator()() const { > > uuid u = {{0}}; > return u; > } >}; > >inline uuid nil_uuid() { > return nil_generator()(); >} > >}} ># 15 "/usr/include/boost/uuid/uuid_generators.hpp" 2 3 4 ># 1 "/usr/include/boost/uuid/string_generator.hpp" 1 3 4 ># 13 "/usr/include/boost/uuid/string_generator.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 14 "/usr/include/boost/uuid/string_generator.hpp" 2 3 4 ># 26 "/usr/include/boost/uuid/string_generator.hpp" 3 4 >namespace boost { >namespace uuids { ># 39 "/usr/include/boost/uuid/string_generator.hpp" 3 4 >struct string_generator { > typedef uuid result_type; > > template <typename ch, typename char_traits, typename alloc> > uuid operator()(std::basic_string<ch, char_traits, alloc> const& s) const { > return operator()(s.begin(), s.end()); > } > > uuid operator()(char const*const s) const { > return operator()(s, s+std::strlen(s)); > } > > uuid operator()(wchar_t const*const s) const { > return operator()(s, s+std::wcslen(s)); > } > > template <typename CharIterator> > uuid operator()(CharIterator begin, CharIterator end) const > { > typedef typename std::iterator_traits<CharIterator>::value_type char_type; > > > char_type c = get_next_char(begin, end); > bool has_open_brace = is_open_brace(c); > char_type open_brace_char = c; > if (has_open_brace) { > c = get_next_char(begin, end); > } > > bool has_dashes = false; > > uuid u; > int i=0; > for (uuid::iterator it_byte=u.begin(); it_byte!=u.end(); ++it_byte, ++i) { > if (it_byte != u.begin()) { > c = get_next_char(begin, end); > } > > if (i == 4) { > has_dashes = is_dash(c); > if (has_dashes) { > c = get_next_char(begin, end); > } > } > > if (has_dashes) { > if (i == 6 || i == 8 || i == 10) { > if (is_dash(c)) { > c = get_next_char(begin, end); > } else { > throw_invalid(); > } > } > } > > *it_byte = get_value(c); > > c = get_next_char(begin, end); > *it_byte <<= 4; > *it_byte |= get_value(c); > } > > > if (has_open_brace) { > c = get_next_char(begin, end); > check_close_brace(c, open_brace_char); > } > > return u; > } > >private: > template <typename CharIterator> > typename std::iterator_traits<CharIterator>::value_type > get_next_char(CharIterator& begin, CharIterator end) const { > if (begin == end) { > throw_invalid(); > } > return *begin++; > } > > unsigned char get_value(char c) const { > static char const*const digits_begin = "0123456789abcdefABCDEF"; > static char const*const digits_end = digits_begin + 22; > > static unsigned char const values[] = > { 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,10,11,12,13,14,15 > , static_cast<unsigned char>(-1) }; > > char const* d = std::find(digits_begin, digits_end, c); > return values[d - digits_begin]; > } > > unsigned char get_value(wchar_t c) const { > static wchar_t const*const digits_begin = L"0123456789abcdefABCDEF"; > static wchar_t const*const digits_end = digits_begin + 22; > > static unsigned char const values[] = > { 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,10,11,12,13,14,15 > , static_cast<unsigned char>(-1) }; > > wchar_t const* d = std::find(digits_begin, digits_end, c); > return values[d - digits_begin]; > } > > bool is_dash(char c) const { > return c == '-'; > } > > bool is_dash(wchar_t c) const { > return c == L'-'; > } > > > bool is_open_brace(char c) const { > return (c == '{'); > } > > bool is_open_brace(wchar_t c) const { > return (c == L'{'); > } > > void check_close_brace(char c, char open_brace) const { > if (open_brace == '{' && c == '}') { > > } else { > throw_invalid(); > } > } > > void check_close_brace(wchar_t c, wchar_t open_brace) const { > if (open_brace == L'{' && c == L'}') { > > } else { > throw_invalid(); > } > } > > void throw_invalid() const { > ::boost::exception_detail::throw_exception_(std::runtime_error("invalid uuid string"),__PRETTY_FUNCTION__,"/usr/include/boost/uuid/string_generator.hpp",178); > } >}; > >}} ># 16 "/usr/include/boost/uuid/uuid_generators.hpp" 2 3 4 ># 1 "/usr/include/boost/uuid/name_generator.hpp" 1 3 4 ># 13 "/usr/include/boost/uuid/name_generator.hpp" 3 4 ># 1 "/usr/include/boost/assert.hpp" 1 3 4 ># 51 "/usr/include/boost/assert.hpp" 3 4 ># 1 "/usr/include/assert.h" 1 3 4 ># 52 "/usr/include/boost/assert.hpp" 2 3 4 ># 14 "/usr/include/boost/uuid/name_generator.hpp" 2 3 4 > ># 1 "/usr/include/c++/4.9.0/cstring" 1 3 4 ># 39 "/usr/include/c++/4.9.0/cstring" 3 4 ># 40 "/usr/include/c++/4.9.0/cstring" 3 ># 16 "/usr/include/boost/uuid/name_generator.hpp" 2 3 4 ># 24 "/usr/include/boost/uuid/name_generator.hpp" 3 4 >namespace boost { >namespace uuids { > > > >class name_generator { >public: > typedef uuid result_type; > > explicit name_generator(uuid const& namespace_uuid) > : namespace_uuid(namespace_uuid) > {} > > uuid operator()(const char* name) { > reset(); > process_characters(name, std::strlen(name)); > return sha_to_uuid(); > } > > uuid operator()(const wchar_t* name) { > reset(); > process_characters(name, std::wcslen(name)); > return sha_to_uuid(); > } > > template <typename ch, typename char_traits, typename alloc> > uuid operator()(std::basic_string<ch, char_traits, alloc> const& name) { > reset(); > process_characters(name.c_str(), name.length()); > return sha_to_uuid(); > } > > uuid operator()(void const* buffer, std::size_t byte_count) { > reset(); > sha.process_bytes(buffer, byte_count); > return sha_to_uuid(); > }; > >private: > > > > > > template <typename char_type> > void process_characters(char_type const*const characters, size_t count) { > (static_cast<void> (0)); > > for (size_t i=0; i<count; i++) { > uint32_t c = characters[i]; > sha.process_byte( (c >> 0) & 0xFF ); > sha.process_byte( (c >> 8) & 0xFF ); > sha.process_byte( (c >> 16) & 0xFF ); > sha.process_byte( (c >> 24) & 0xFF ); > } > } > > void process_characters(char const*const characters, size_t count) { > sha.process_bytes(characters, count); > } > > void reset() > { > sha.reset(); > sha.process_bytes(namespace_uuid.begin(), namespace_uuid.size()); > } > > uuid sha_to_uuid() > { > unsigned int digest[5]; > > sha.get_digest(digest); > > uuid u; > for (int i=0; i<4; ++i) { > *(u.begin() + i*4+0) = ((digest[i] >> 24) & 0xFF); > *(u.begin() + i*4+1) = ((digest[i] >> 16) & 0xFF); > *(u.begin() + i*4+2) = ((digest[i] >> 8) & 0xFF); > *(u.begin() + i*4+3) = ((digest[i] >> 0) & 0xFF); > } > > > > *(u.begin()+8) &= 0xBF; > *(u.begin()+8) |= 0x80; > > > > *(u.begin()+6) &= 0x5F; > *(u.begin()+6) |= 0x50; > > return u; > } > >private: > uuid namespace_uuid; > detail::sha1 sha; >}; > >}} ># 17 "/usr/include/boost/uuid/uuid_generators.hpp" 2 3 4 ># 33 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/net/levin_base.h" 1 ># 36 "/c/honeypenny/contrib/epee/include/net/levin_base.h" >namespace epee >{ >namespace levin >{ >#pragma pack(push) >#pragma pack(1) > struct bucket_head > { > uint64_t m_signature; > uint64_t m_cb; > bool m_have_to_return_data; > uint32_t m_command; > int32_t m_return_code; > uint32_t m_reservedA; > uint32_t m_reservedB; > }; >#pragma pack(pop) > > >#pragma pack(push) >#pragma pack(1) > struct bucket_head2 > { > uint64_t m_signature; > uint64_t m_cb; > bool m_have_to_return_data; > uint32_t m_command; > int32_t m_return_code; > uint32_t m_flags; > uint32_t m_protocol_version; > }; >#pragma pack(pop) ># 80 "/c/honeypenny/contrib/epee/include/net/levin_base.h" > template<class t_connection_context = net_utils::connection_context_base> > struct levin_commands_handler > { > virtual int invoke(int command, const std::string& in_buff, std::string& buff_out, t_connection_context& context)=0; > virtual int notify(int command, const std::string& in_buff, t_connection_context& context)=0; > virtual void callback(t_connection_context& context){}; > > virtual void on_connection_new(t_connection_context& context){}; > virtual void on_connection_close(t_connection_context& context){}; > > }; ># 102 "/c/honeypenny/contrib/epee/include/net/levin_base.h" > inline > const char* get_err_descr(int err) > { > switch(err) > { > case 0: return "LEVIN_OK";; > case -1: return "LEVIN_ERROR_CONNECTION";; > case -2: return "LEVIN_ERROR_CONNECTION_NOT_FOUND";; > case -3: return "LEVIN_ERROR_CONNECTION_DESTROYED";; > case -4: return "LEVIN_ERROR_CONNECTION_TIMEDOUT";; > case -5: return "LEVIN_ERROR_CONNECTION_NO_DUPLEX_PROTOCOL";; > case -6: return "LEVIN_ERROR_CONNECTION_HANDLER_NOT_DEFINED";; > case -7: return "LEVIN_ERROR_FORMAT";; > default: > return "unknown code"; > } > } > > >} >} ># 34 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler.h" 2 > >namespace epee >{ >namespace levin >{ > template<class t_connection_context = net_utils::connection_context_base> > struct protocl_handler_config > { > levin_commands_handler<t_connection_context>* m_pcommands_handler; > }; > > template<class t_connection_context = net_utils::connection_context_base> > class protocol_handler > { > public: > typedef t_connection_context connection_context; > typedef protocl_handler_config<t_connection_context> config_type; > > protocol_handler(net_utils::i_service_endpoint* psnd_hndlr, config_type& config, t_connection_context& conn_context); > virtual ~protocol_handler(){} > > virtual bool handle_recv(const void* ptr, size_t cb); > > bool after_init_connection(){return true;} > private: > enum connection_data_state > { > conn_state_reading_head, > conn_state_reading_body > }; > > > config_type& m_config; > t_connection_context& m_conn_context; > net_utils::i_service_endpoint* m_psnd_hndlr; > std::string m_cach_in_buffer; > connection_data_state m_state; > bucket_head m_current_head; > }; > > template<class t_connection_context> > protocol_handler<t_connection_context>::protocol_handler(net_utils::i_service_endpoint* psnd_hndlr, config_type& config, t_connection_context& conn_context): > m_config(config), > m_conn_context(conn_context), > m_psnd_hndlr(psnd_hndlr), > m_state(conn_state_reading_head), > m_current_head(bucket_head()) > {} > > template<class t_connection_context> > bool protocol_handler<t_connection_context>::handle_recv(const void* ptr, size_t cb) > { > if(!m_config.m_pcommands_handler) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler.h" << ":" << 88 << "|" << __FUNCTION__ << "|" << "Command handler not set!" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > m_cach_in_buffer.append((const char*)ptr, cb); > > bool is_continue = true; > while(is_continue) > { > switch(m_state) > { > case conn_state_reading_head: > if(m_cach_in_buffer.size() < sizeof(bucket_head)) > { > if(m_cach_in_buffer.size() >= sizeof(uint64_t) && *((uint64_t*)m_cach_in_buffer.data()) != 0x0101010101012101LL) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler.h" << ":" << 103 << "|" << __FUNCTION__ << "|" << "Signature missmatch on accepted connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > is_continue = false; > break; > } > { > bucket_head* phead = (bucket_head*)m_cach_in_buffer.data(); > if(0x0101010101012101LL != phead->m_signature) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler.h" << ":" << 113 << "|" << __FUNCTION__ << "|" << "Signature missmatch on accepted connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > m_current_head = *phead; > } > m_cach_in_buffer.erase(0, sizeof(bucket_head)); > m_state = conn_state_reading_body; > break; > case conn_state_reading_body: > if(m_cach_in_buffer.size() < m_current_head.m_cb) > { > is_continue = false; > break; > } > { > std::string buff_to_invoke; > if(m_cach_in_buffer.size() == m_current_head.m_cb) > buff_to_invoke.swap(m_cach_in_buffer); > else > { > buff_to_invoke.assign(m_cach_in_buffer, 0, (std::string::size_type)m_current_head.m_cb); > m_cach_in_buffer.erase(0, (std::string::size_type)m_current_head.m_cb); > } > > > if(m_current_head.m_have_to_return_data) > { > std::string return_buff; > m_current_head.m_return_code = m_config.m_pcommands_handler->invoke(m_current_head.m_command, buff_to_invoke, return_buff, m_conn_context); > m_current_head.m_cb = return_buff.size(); > m_current_head.m_have_to_return_data = false; > std::string send_buff((const char*)&m_current_head, sizeof(m_current_head)); > send_buff += return_buff; > > if(!m_psnd_hndlr->do_send(send_buff.data(), send_buff.size())) > return false; > > } > else > m_config.m_pcommands_handler->notify(m_current_head.m_command, buff_to_invoke, m_conn_context); > } > m_state = conn_state_reading_head; > break; > default: > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler.h" << ":" << 157 << "|" << __FUNCTION__ << "|" << "Undefined state in levin_server_impl::connection_handler, m_state=" << m_state << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > } > > return true; > } > > > > > > > >} >} ># 34 "/c/honeypenny/contrib/epee/include/net/levin_server_cp2.h" 2 ># 1 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" 1 ># 27 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" > > > ># 1 "/usr/include/boost/smart_ptr/make_shared.hpp" 1 3 4 ># 15 "/usr/include/boost/smart_ptr/make_shared.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/make_shared_object.hpp" 1 3 4 ># 17 "/usr/include/boost/smart_ptr/make_shared_object.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/sp_forward.hpp" 1 3 4 ># 20 "/usr/include/boost/smart_ptr/detail/sp_forward.hpp" 3 4 >namespace boost >{ > >namespace detail >{ > > > >template< class T > T&& sp_forward( T & t ) noexcept >{ > return static_cast< T&& >( t ); >} > > > >} > >} ># 18 "/usr/include/boost/smart_ptr/make_shared_object.hpp" 2 3 4 > > > > > >namespace boost >{ > >namespace detail >{ > >template< std::size_t N, std::size_t A > struct sp_aligned_storage >{ > union type > { > char data_[ N ]; > typename boost::type_with_alignment< A >::type align_; > }; >}; > >template< class T > class sp_ms_deleter >{ >private: > > typedef typename sp_aligned_storage< sizeof( T ), ::boost::alignment_of< T >::value >::type storage_type; > > bool initialized_; > storage_type storage_; > >private: > > void destroy() > { > if( initialized_ ) > { > > > > T * p = reinterpret_cast< T* >( storage_.data_ ); > p->~T(); > > > > > > > > initialized_ = false; > } > } > >public: > > sp_ms_deleter() noexcept : initialized_( false ) > { > } > > > sp_ms_deleter( sp_ms_deleter const & ) noexcept : initialized_( false ) > { > } > > ~sp_ms_deleter() > { > destroy(); > } > > void operator()( T * ) > { > destroy(); > } > > static void operator_fn( T* ) > { > } > > void * address() noexcept > { > return storage_.data_; > } > > void set_initialized() noexcept > { > initialized_ = true; > } >}; > >template< class T > struct sp_if_not_array >{ > typedef boost::shared_ptr< T > type; >}; > > > >template< class T > struct sp_if_not_array< T[] > >{ >}; > > > >template< class T, std::size_t N > struct sp_if_not_array< T[N] > >{ >}; > > > > > >} ># 138 "/usr/include/boost/smart_ptr/make_shared_object.hpp" 3 4 >template< class T > typename boost::detail::sp_if_not_array< T >::type make_shared() >{ > boost::shared_ptr< T > pt( static_cast< T* >( 0 ), boost::detail::sp_inplace_tag< boost::detail::sp_ms_deleter< T > >() ); > > boost::detail::sp_ms_deleter< T > * pd = static_cast<boost::detail::sp_ms_deleter< T > *>( pt._internal_get_untyped_deleter() ); > > void * pv = pd->address(); > > ::new( pv ) T(); > pd->set_initialized(); > > T * pt2 = static_cast< T* >( pv ); > > boost::detail::sp_enable_shared_from_this( &pt, pt2, pt2 ); > return boost::shared_ptr< T >( pt, pt2 ); >} > >template< class T > typename boost::detail::sp_if_not_array< T >::type make_shared_noinit() >{ > boost::shared_ptr< T > pt( static_cast< T* >( 0 ), boost::detail::sp_inplace_tag< boost::detail::sp_ms_deleter< T > >() ); > > boost::detail::sp_ms_deleter< T > * pd = static_cast<boost::detail::sp_ms_deleter< T > *>( pt._internal_get_untyped_deleter() ); > > void * pv = pd->address(); > > ::new( pv ) T; > pd->set_initialized(); > > T * pt2 = static_cast< T* >( pv ); > > boost::detail::sp_enable_shared_from_this( &pt, pt2, pt2 ); > return boost::shared_ptr< T >( pt, pt2 ); >} > >template< class T, class A > typename boost::detail::sp_if_not_array< T >::type allocate_shared( A const & a ) >{ > boost::shared_ptr< T > pt( static_cast< T* >( 0 ), boost::detail::sp_inplace_tag< boost::detail::sp_ms_deleter< T > >(), a ); > > boost::detail::sp_ms_deleter< T > * pd = static_cast<boost::detail::sp_ms_deleter< T > *>( pt._internal_get_untyped_deleter() ); > > void * pv = pd->address(); > > ::new( pv ) T(); > pd->set_initialized(); > > T * pt2 = static_cast< T* >( pv ); > > boost::detail::sp_enable_shared_from_this( &pt, pt2, pt2 ); > return boost::shared_ptr< T >( pt, pt2 ); >} > >template< class T, class A > typename boost::detail::sp_if_not_array< T >::type allocate_shared_noinit( A const & a ) >{ > boost::shared_ptr< T > pt( static_cast< T* >( 0 ), boost::detail::sp_inplace_tag< boost::detail::sp_ms_deleter< T > >(), a ); > > boost::detail::sp_ms_deleter< T > * pd = static_cast<boost::detail::sp_ms_deleter< T > *>( pt._internal_get_untyped_deleter() ); > > void * pv = pd->address(); > > ::new( pv ) T; > pd->set_initialized(); > > T * pt2 = static_cast< T* >( pv ); > > boost::detail::sp_enable_shared_from_this( &pt, pt2, pt2 ); > return boost::shared_ptr< T >( pt, pt2 ); >} > > > > > >template< class T, class Arg1, class... Args > typename boost::detail::sp_if_not_array< T >::type make_shared( Arg1 && arg1, Args && ... args ) >{ > boost::shared_ptr< T > pt( static_cast< T* >( 0 ), boost::detail::sp_inplace_tag< boost::detail::sp_ms_deleter< T > >() ); > > boost::detail::sp_ms_deleter< T > * pd = static_cast<boost::detail::sp_ms_deleter< T > *>( pt._internal_get_untyped_deleter() ); > > void * pv = pd->address(); > > ::new( pv ) T( boost::detail::sp_forward<Arg1>( arg1 ), boost::detail::sp_forward<Args>( args )... ); > pd->set_initialized(); > > T * pt2 = static_cast< T* >( pv ); > > boost::detail::sp_enable_shared_from_this( &pt, pt2, pt2 ); > return boost::shared_ptr< T >( pt, pt2 ); >} > >template< class T, class A, class Arg1, class... Args > typename boost::detail::sp_if_not_array< T >::type allocate_shared( A const & a, Arg1 && arg1, Args && ... args ) >{ > boost::shared_ptr< T > pt( static_cast< T* >( 0 ), boost::detail::sp_inplace_tag< boost::detail::sp_ms_deleter< T > >(), a ); > > boost::detail::sp_ms_deleter< T > * pd = static_cast<boost::detail::sp_ms_deleter< T > *>( pt._internal_get_untyped_deleter() ); > > void * pv = pd->address(); > > ::new( pv ) T( boost::detail::sp_forward<Arg1>( arg1 ), boost::detail::sp_forward<Args>( args )... ); > pd->set_initialized(); > > T * pt2 = static_cast< T* >( pv ); > > boost::detail::sp_enable_shared_from_this( &pt, pt2, pt2 ); > return boost::shared_ptr< T >( pt, pt2 ); >} ># 1030 "/usr/include/boost/smart_ptr/make_shared_object.hpp" 3 4 >} ># 16 "/usr/include/boost/smart_ptr/make_shared.hpp" 2 3 4 > > ># 1 "/usr/include/boost/smart_ptr/make_shared_array.hpp" 1 3 4 ># 13 "/usr/include/boost/smart_ptr/make_shared_array.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/array_deleter.hpp" 1 3 4 ># 12 "/usr/include/boost/smart_ptr/detail/array_deleter.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/array_utility.hpp" 1 3 4 ># 16 "/usr/include/boost/smart_ptr/detail/array_utility.hpp" 3 4 >namespace boost { > namespace detail { > template<typename T> > inline void array_destroy(T*, std::size_t, boost::true_type) { > } > template<typename T> > inline void array_destroy(T* memory, std::size_t size, boost::false_type) { > for (std::size_t i = size; i > 0; ) { > memory[--i].~T(); > } > } > template<typename T> > inline void array_destroy(T* memory, std::size_t size) { > boost::has_trivial_destructor<T> type; > array_destroy(memory, size, type); > } > template<typename T> > inline void array_init(T* memory, std::size_t size, boost::true_type) { > for (std::size_t i = 0; i < size; i++) { > memory[i] = T(); > } > } > template<typename T> > inline void array_init(T* memory, std::size_t size, boost::false_type) { > > std::size_t i = 0; > try { > for (; i < size; i++) { > void* p1 = memory + i; > ::new(p1) T(); > } > } catch (...) { > array_destroy(memory, i); > throw; > } > > > > > > > } > template<typename T> > inline void array_init(T* memory, std::size_t size) { > boost::has_trivial_default_constructor<T> type; > array_init(memory, size, type); > } > > template<typename T> > inline void array_init_value(T* memory, std::size_t size, T&& value) { > > std::size_t i = 0; > try { > for (; i < size; i++) { > void* p1 = memory + i; > ::new(p1) T(value); > } > } catch (...) { > array_destroy(memory, i); > throw; > } > > > > > > > } > > template<typename T, typename... Args> > inline void array_init_args(T* memory, std::size_t size, Args&&... args) { > > std::size_t i = 0; > try { > for (; i < size; i++) { > void* p1 = memory + i; > ::new(p1) T(args...); > } > } catch (...) { > array_destroy(memory, i); > throw; > } > > > > > > > } > > > template<typename T> > inline void array_init_list(T* memory, std::size_t size, const T* list) { > > std::size_t i = 0; > try { > for (; i < size; i++) { > void* p1 = memory + i; > ::new(p1) T(list[i]); > } > } catch (...) { > array_destroy(memory, i); > throw; > } > > > > > > > } > template<typename T, std::size_t N> > inline void array_init_list(T* memory, std::size_t size, const T* list) { > > std::size_t i = 0; > try { > for (; i < size; i++) { > void* p1 = memory + i; > ::new(p1) T(list[i % N]); > } > } catch (...) { > array_destroy(memory, i); > throw; > } > > > > > > > } > template<typename T> > inline void array_noinit(T*, std::size_t, boost::true_type) { > } > template<typename T> > inline void array_noinit(T* memory, std::size_t size, boost::false_type) { > > std::size_t i = 0; > try { > for (; i < size; i++) { > void* p1 = memory + i; > ::new(p1) T; > } > } catch (...) { > array_destroy(memory, i); > throw; > } > > > > > > > } > template<typename T> > inline void array_noinit(T* memory, std::size_t size) { > boost::has_trivial_default_constructor<T> type; > array_noinit(memory, size, type); > } > } >} ># 13 "/usr/include/boost/smart_ptr/detail/array_deleter.hpp" 2 3 4 > > >namespace boost { > namespace detail { > template<typename T> > class array_deleter; > template<typename T> > class array_deleter<T[]> { > public: > array_deleter(std::size_t size_) > : size(size_), > object(0) { > } > ~array_deleter() { > if (object) { > array_destroy(object, size); > } > } > void init(T* memory) { > array_init(memory, size); > object = memory; > } > > void init(T* memory, T&& value) { > array_init_value(memory, size, sp_forward<T>(value)); > object = memory; > } > > template<typename... Args> > void init(T* memory, Args&&... args) { > array_init_args(memory, size, sp_forward<Args>(args)...); > object = memory; > } > > > void init_list(T* memory, const T* list) { > array_init_list(memory, size, list); > object = memory; > } > template<std::size_t M> > void init_list(T* memory, const T* list) { > array_init_list<T, M>(memory, size, list); > object = memory; > } > void noinit(T* memory) { > array_noinit(memory, size); > object = memory; > } > void operator()(const void*) { > if (object) { > array_destroy(object, size); > object = 0; > } > } > private: > std::size_t size; > T* object; > }; > template<typename T, std::size_t N> > class array_deleter<T[N]> { > public: > array_deleter() > : object(0) { > } > ~array_deleter() { > if (object) { > array_destroy(object, N); > } > } > void init(T* memory) { > array_init(memory, N); > object = memory; > } > > void init(T* memory, T&& value) { > array_init_value(memory, N, sp_forward<T>(value)); > object = memory; > } > > template<typename... Args> > void init(T* memory, Args&&... args) { > array_init_args(memory, N, sp_forward<Args>(args)...); > object = memory; > } > > > void init_list(T* memory, const T* list) { > array_init_list(memory, N, list); > object = memory; > } > template<std::size_t M> > void init_list(T* memory, const T* list) { > array_init_list<T, M>(memory, N, list); > object = memory; > } > void noinit(T* memory) { > array_noinit(memory, N); > object = memory; > } > void operator()(const void*) { > if (object) { > array_destroy(object, N); > object = 0; > } > } > private: > T* object; > }; > } >} ># 14 "/usr/include/boost/smart_ptr/make_shared_array.hpp" 2 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/array_traits.hpp" 1 3 4 ># 14 "/usr/include/boost/smart_ptr/detail/array_traits.hpp" 3 4 >namespace boost { > namespace detail { > template<typename T> > struct array_base { > typedef typename boost::remove_cv<T>::type type; > }; > template<typename T> > struct array_base<T[]> { > typedef typename array_base<T>::type type; > }; > template<typename T, std::size_t N> > struct array_base<T[N]> { > typedef typename array_base<T>::type type; > }; > template<typename T> > struct array_total { > enum { > size = 1 > }; > }; > template<typename T, std::size_t N> > struct array_total<T[N]> { > enum { > size = N * array_total<T>::size > }; > }; > template<typename T> > struct array_inner; > template<typename T> > struct array_inner<T[]> { > typedef T type; > }; > template<typename T, std::size_t N> > struct array_inner<T[N]> { > typedef T type; > }; > } >} ># 15 "/usr/include/boost/smart_ptr/make_shared_array.hpp" 2 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/make_array_helper.hpp" 1 3 4 ># 14 "/usr/include/boost/smart_ptr/detail/make_array_helper.hpp" 3 4 >namespace boost { > namespace detail { > template<typename T, typename Y = char> > class make_array_helper; > template<typename T, typename Y> > class make_array_helper<T[], Y> { > template<typename T2, typename Y2> > friend class make_array_helper; > public: > typedef Y value_type; > typedef Y* pointer; > typedef const Y* const_pointer; > typedef Y& reference; > typedef const Y& const_reference; > typedef std::size_t size_type; > typedef ptrdiff_t difference_type; > template<typename U> > struct rebind { > typedef make_array_helper<T[], U> other; > }; > make_array_helper(std::size_t size_, T** data_) > : size(sizeof(T) * size_), > data(data_) { > } > template<class U> > make_array_helper(const make_array_helper<T[], U>& other) > : size(other.size), > data(other.data) { > } > pointer address(reference value) const { > return &value; > } > const_pointer address(const_reference value) const { > return &value; > } > size_type max_size() const { > return static_cast<std::size_t>(-1) / sizeof(Y); > } > pointer allocate(size_type count, const void* = 0) { > std::size_t a1 = boost::alignment_of<T>::value; > std::size_t n1 = count * sizeof(Y) + a1 - 1; > void* p1 = ::operator new(n1 + size); > char* p2 = static_cast<char*>(p1) + n1; > while (std::size_t(p2) % a1 != 0) { > p2--; > } > *data = reinterpret_cast<T*>(p2); > return reinterpret_cast<Y*>(p1); > } > void deallocate(pointer memory, size_type) { > void* p1 = memory; > ::operator delete(p1); > } > void construct(pointer memory, const Y& value) { > void* p1 = memory; > ::new(p1) Y(value); > } > void destroy(pointer memory) { > memory->~Y(); > } > template<typename U> > bool operator==(const make_array_helper<T[], U>&) const { > return true; > } > template<typename U> > bool operator!=(const make_array_helper<T[], U>& other) const { > return !(*this == other); > } > private: > std::size_t size; > T** data; > }; > template<typename T, std::size_t N, typename Y> > class make_array_helper<T[N], Y> { > template<typename T2, typename Y2> > friend class make_array_helper; > public: > typedef Y value_type; > typedef Y* pointer; > typedef const Y* const_pointer; > typedef Y& reference; > typedef const Y& const_reference; > typedef std::size_t size_type; > typedef ptrdiff_t difference_type; > template<typename U> > struct rebind { > typedef make_array_helper<T[N], U> other; > }; > make_array_helper(T** data_) > : data(data_) { > } > template<class U> > make_array_helper(const make_array_helper<T[N], U>& other) > : data(other.data) { > } > pointer address(reference value) const { > return &value; > } > const_pointer address(const_reference value) const { > return &value; > } > size_type max_size() const { > return static_cast<std::size_t>(-1) / sizeof(Y); > } > pointer allocate(size_type count, const void* = 0) { > std::size_t a1 = boost::alignment_of<T>::value; > std::size_t n1 = count * sizeof(Y) + a1 - 1; > void* p1 = ::operator new(n1 + N1); > char* p2 = static_cast<char*>(p1) + n1; > while (std::size_t(p2) % a1 != 0) { > p2--; > } > *data = reinterpret_cast<T*>(p2); > return reinterpret_cast<Y*>(p1); > } > void deallocate(pointer memory, size_type) { > void* p1 = memory; > ::operator delete(p1); > } > void construct(pointer memory, const Y& value) { > void* p1 = memory; > ::new(p1) Y(value); > } > void destroy(pointer memory) { > memory->~Y(); > } > template<typename U> > bool operator==(const make_array_helper<T[N], U>&) const { > return true; > } > template<typename U> > bool operator!=(const make_array_helper<T[N], U>& other) const { > return !(*this == other); > } > private: > enum { > N1 = N * sizeof(T) > }; > T** data; > }; > } >} ># 16 "/usr/include/boost/smart_ptr/make_shared_array.hpp" 2 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/sp_if_array.hpp" 1 3 4 ># 14 "/usr/include/boost/smart_ptr/detail/sp_if_array.hpp" 3 4 >namespace boost { > namespace detail { > template<typename T> > struct sp_if_array; > template<typename T> > struct sp_if_array<T[]> { > typedef boost::shared_ptr<T[]> type; > }; > template<typename T> > struct sp_if_size_array; > template<typename T, std::size_t N> > struct sp_if_size_array<T[N]> { > typedef boost::shared_ptr<T[N]> type; > }; > } >} ># 17 "/usr/include/boost/smart_ptr/make_shared_array.hpp" 2 3 4 > > > > >namespace boost { > template<typename T> > inline typename boost::detail::sp_if_array<T>::type > make_shared(std::size_t size) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > T1* p1 = 0; > T2* p2 = 0; > std::size_t n1 = size * boost::detail::array_total<T1>::size; > boost::detail::make_array_helper<T2[]> a1(n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2); > return boost::shared_ptr<T>(s1, p1); > } > > template<typename T, typename... Args> > inline typename boost::detail::sp_if_array<T>::type > make_shared(std::size_t size, Args&&... args) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > T1* p1 = 0; > T2* p2 = 0; > std::size_t n1 = size * boost::detail::array_total<T1>::size; > boost::detail::make_array_helper<T2[]> a1(n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2, boost::detail::sp_forward<Args>(args)...); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T, typename... Args> > inline typename boost::detail::sp_if_size_array<T>::type > make_shared(Args&&... args) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > enum { > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > boost::detail::make_array_helper<T2[N]> a1(&p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2, boost::detail::sp_forward<Args>(args)...); > return boost::shared_ptr<T>(s1, p1); > } > > > template<typename T> > inline typename boost::detail::sp_if_size_array<T>::type > make_shared(const T& list) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > typedef const T2 T3; > enum { > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > T3* p3 = 0; > boost::detail::make_array_helper<T2[N]> a1(&p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p3 = reinterpret_cast<T3*>(list); > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init_list(p2, p3); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T> > inline typename boost::detail::sp_if_array<T>::type > make_shared(std::size_t size, > const typename boost::detail::array_inner<T>::type& list) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > typedef const T2 T3; > enum { > M = boost::detail::array_total<T1>::size > }; > T1* p1 = 0; > T2* p2 = 0; > T3* p3 = 0; > std::size_t n1 = M * size; > boost::detail::make_array_helper<T2[]> a1(n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p3 = reinterpret_cast<T3*>(list); > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->template init_list<M>(p2, p3); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T> > inline typename boost::detail::sp_if_size_array<T>::type > make_shared(const typename boost::detail::array_inner<T>::type& list) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > typedef const T2 T3; > enum { > M = boost::detail::array_total<T1>::size, > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > T3* p3 = 0; > boost::detail::make_array_helper<T2[N]> a1(&p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p3 = reinterpret_cast<T3*>(list); > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->template init_list<M>(p2, p3); > return boost::shared_ptr<T>(s1, p1); > } > > template<typename T> > inline typename boost::detail::sp_if_array<T>::type > make_shared(std::initializer_list<typename boost::detail::array_inner<T>::type> list) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > typedef const T2 T3; > T1* p1 = 0; > T2* p2 = 0; > T3* p3 = 0; > std::size_t n1 = list.size() * boost::detail::array_total<T1>::size; > boost::detail::make_array_helper<T2[]> a1(n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p3 = reinterpret_cast<T3*>(list.begin()); > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init_list(p2, p3); > return boost::shared_ptr<T>(s1, p1); > } > > > template<typename T> > inline typename boost::detail::sp_if_array<T>::type > make_shared(std::size_t size, > typename boost::detail::array_base<T>::type&& value) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > T1* p1 = 0; > T2* p2 = 0; > std::size_t n1 = size * boost::detail::array_total<T1>::size; > boost::detail::make_array_helper<T2[]> a1(n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2, boost::detail::sp_forward<T2>(value)); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T> > inline typename boost::detail::sp_if_size_array<T>::type > make_shared(typename boost::detail::array_base<T>::type&& value) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > enum { > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > boost::detail::make_array_helper<T2[N]> a1(&p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2, boost::detail::sp_forward<T2>(value)); > return boost::shared_ptr<T>(s1, p1); > } > > > template<typename T> > inline typename boost::detail::sp_if_array<T>::type > make_shared_noinit(std::size_t size) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > T1* p1 = 0; > T2* p2 = 0; > std::size_t n1 = size * boost::detail::array_total<T1>::size; > boost::detail::make_array_helper<T2[]> a1(n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->noinit(p2); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T> > inline typename boost::detail::sp_if_size_array<T>::type > make_shared_noinit() { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > enum { > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > boost::detail::make_array_helper<T2[N]> a1(&p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->noinit(p2); > return boost::shared_ptr<T>(s1, p1); > } >} ># 19 "/usr/include/boost/smart_ptr/make_shared.hpp" 2 3 4 ># 1 "/usr/include/boost/smart_ptr/allocate_shared_array.hpp" 1 3 4 ># 13 "/usr/include/boost/smart_ptr/allocate_shared_array.hpp" 3 4 ># 1 "/usr/include/boost/smart_ptr/detail/allocate_array_helper.hpp" 1 3 4 ># 14 "/usr/include/boost/smart_ptr/detail/allocate_array_helper.hpp" 3 4 >namespace boost { > namespace detail { > template<typename A, typename T, typename Y = char> > class allocate_array_helper; > template<typename A, typename T, typename Y> > class allocate_array_helper<A, T[], Y> { > template<typename A9, typename T9, typename Y9> > friend class allocate_array_helper; > typedef typename A::template rebind<Y> ::other A2; > typedef typename A::template rebind<char>::other A3; > public: > typedef typename A2::value_type value_type; > typedef typename A2::pointer pointer; > typedef typename A2::const_pointer const_pointer; > typedef typename A2::reference reference; > typedef typename A2::const_reference const_reference; > typedef typename A2::size_type size_type; > typedef typename A2::difference_type difference_type; > template<typename U> > struct rebind { > typedef allocate_array_helper<A, T[], U> other; > }; > allocate_array_helper(const A& allocator_, std::size_t size_, T** data_) > : allocator(allocator_), > size(sizeof(T) * size_), > data(data_) { > } > template<class U> > allocate_array_helper(const allocate_array_helper<A, T[], U>& other) > : allocator(other.allocator), > size(other.size), > data(other.data) { > } > pointer address(reference value) const { > return allocator.address(value); > } > const_pointer address(const_reference value) const { > return allocator.address(value); > } > size_type max_size() const { > return allocator.max_size(); > } > pointer allocate(size_type count, const void* value = 0) { > std::size_t a1 = boost::alignment_of<T>::value; > std::size_t n1 = count * sizeof(Y) + a1 - 1; > char* p1 = A3(allocator).allocate(n1 + size, value); > char* p2 = p1 + n1; > while (std::size_t(p2) % a1 != 0) { > p2--; > } > *data = reinterpret_cast<T*>(p2); > return reinterpret_cast<Y*>(p1); > } > void deallocate(pointer memory, size_type count) { > std::size_t a1 = boost::alignment_of<T>::value; > std::size_t n1 = count * sizeof(Y) + a1 - 1; > char* p1 = reinterpret_cast<char*>(memory); > A3(allocator).deallocate(p1, n1 + size); > } > void construct(pointer memory, const Y& value) { > allocator.construct(memory, value); > } > void destroy(pointer memory) { > allocator.destroy(memory); > } > template<typename U> > bool operator==(const allocate_array_helper<A, T[], U>& other) const { > return allocator == other.allocator; > } > template<typename U> > bool operator!=(const allocate_array_helper<A, T[], U>& other) const { > return !(*this == other); > } > private: > A2 allocator; > std::size_t size; > T** data; > }; > template<typename A, typename T, std::size_t N, typename Y> > class allocate_array_helper<A, T[N], Y> { > template<typename A9, typename T9, typename Y9> > friend class allocate_array_helper; > typedef typename A::template rebind<Y> ::other A2; > typedef typename A::template rebind<char>::other A3; > public: > typedef typename A2::value_type value_type; > typedef typename A2::pointer pointer; > typedef typename A2::const_pointer const_pointer; > typedef typename A2::reference reference; > typedef typename A2::const_reference const_reference; > typedef typename A2::size_type size_type; > typedef typename A2::difference_type difference_type; > template<typename U> > struct rebind { > typedef allocate_array_helper<A, T[N], U> other; > }; > allocate_array_helper(const A& allocator_, T** data_) > : allocator(allocator_), > data(data_) { > } > template<class U> > allocate_array_helper(const allocate_array_helper<A, T[N], U>& other) > : allocator(other.allocator), > data(other.data) { > } > pointer address(reference value) const { > return allocator.address(value); > } > const_pointer address(const_reference value) const { > return allocator.address(value); > } > size_type max_size() const { > return allocator.max_size(); > } > pointer allocate(size_type count, const void* value = 0) { > std::size_t a1 = boost::alignment_of<T>::value; > std::size_t n1 = count * sizeof(Y) + a1 - 1; > char* p1 = A3(allocator).allocate(n1 + N1, value); > char* p2 = p1 + n1; > while (std::size_t(p2) % a1 != 0) { > p2--; > } > *data = reinterpret_cast<T*>(p2); > return reinterpret_cast<Y*>(p1); > } > void deallocate(pointer memory, size_type count) { > std::size_t a1 = boost::alignment_of<T>::value; > std::size_t n1 = count * sizeof(Y) + a1 - 1; > char* p1 = reinterpret_cast<char*>(memory); > A3(allocator).deallocate(p1, n1 + N1); > } > void construct(pointer memory, const Y& value) { > allocator.construct(memory, value); > } > void destroy(pointer memory) { > allocator.destroy(memory); > } > template<typename U> > bool operator==(const allocate_array_helper<A, T[N], U>& other) const { > return allocator == other.allocator; > } > template<typename U> > bool operator!=(const allocate_array_helper<A, T[N], U>& other) const { > return !(*this == other); > } > private: > enum { > N1 = N * sizeof(T) > }; > A2 allocator; > T** data; > }; > } >} ># 14 "/usr/include/boost/smart_ptr/allocate_shared_array.hpp" 2 3 4 > > > > > > > >namespace boost { > template<typename T, typename A> > inline typename boost::detail::sp_if_array<T>::type > allocate_shared(const A& allocator, std::size_t size) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > T1* p1 = 0; > T2* p2 = 0; > std::size_t n1 = size * boost::detail::array_total<T1>::size; > boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2); > return boost::shared_ptr<T>(s1, p1); > } > > template<typename T, typename A, typename... Args> > inline typename boost::detail::sp_if_array<T>::type > allocate_shared(const A& allocator, std::size_t size, Args&&... args) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > T1* p1 = 0; > T2* p2 = 0; > std::size_t n1 = size * boost::detail::array_total<T1>::size; > boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2, boost::detail::sp_forward<Args>(args)...); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T, typename A, typename... Args> > inline typename boost::detail::sp_if_size_array<T>::type > allocate_shared(const A& allocator, Args&&... args) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > enum { > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2, boost::detail::sp_forward<Args>(args)...); > return boost::shared_ptr<T>(s1, p1); > } > > > template<typename T, typename A> > inline typename boost::detail::sp_if_size_array<T>::type > allocate_shared(const A& allocator, const T& list) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > typedef const T2 T3; > enum { > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > T3* p3 = 0; > boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p3 = reinterpret_cast<T3*>(list); > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init_list(p2, p3); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T, typename A> > inline typename boost::detail::sp_if_array<T>::type > allocate_shared(const A& allocator, std::size_t size, > const typename boost::detail::array_inner<T>::type& list) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > typedef const T2 T3; > enum { > M = boost::detail::array_total<T1>::size > }; > T1* p1 = 0; > T2* p2 = 0; > T3* p3 = 0; > std::size_t n1 = M * size; > boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p3 = reinterpret_cast<T3*>(list); > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->template init_list<M>(p2, p3); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T, typename A> > inline typename boost::detail::sp_if_size_array<T>::type > allocate_shared(const A& allocator, > const typename boost::detail::array_inner<T>::type& list) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > typedef const T2 T3; > enum { > M = boost::detail::array_total<T1>::size, > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > T3* p3 = 0; > boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p3 = reinterpret_cast<T3*>(list); > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->template init_list<M>(p2, p3); > return boost::shared_ptr<T>(s1, p1); > } > > template<typename T, typename A> > inline typename boost::detail::sp_if_array<T>::type > allocate_shared(const A& allocator, > std::initializer_list<typename boost::detail::array_inner<T>::type> list) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > typedef const T2 T3; > T1* p1 = 0; > T2* p2 = 0; > T3* p3 = 0; > std::size_t n1 = list.size() * boost::detail::array_total<T1>::size; > boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p3 = reinterpret_cast<T3*>(list.begin()); > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init_list(p2, p3); > return boost::shared_ptr<T>(s1, p1); > } > > > template<typename T, typename A> > inline typename boost::detail::sp_if_array<T>::type > allocate_shared(const A& allocator, std::size_t size, > typename boost::detail::array_base<T>::type&& value) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > T1* p1 = 0; > T2* p2 = 0; > std::size_t n1 = size * boost::detail::array_total<T1>::size; > boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2, boost::detail::sp_forward<T2>(value)); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T, typename A> > inline typename boost::detail::sp_if_size_array<T>::type > allocate_shared(const A& allocator, > typename boost::detail::array_base<T>::type&& value) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > enum { > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->init(p2, boost::detail::sp_forward<T2>(value)); > return boost::shared_ptr<T>(s1, p1); > } > > > template<typename T, typename A> > inline typename boost::detail::sp_if_array<T>::type > allocate_shared_noinit(const A& allocator, std::size_t size) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > T1* p1 = 0; > T2* p2 = 0; > std::size_t n1 = size * boost::detail::array_total<T1>::size; > boost::detail::allocate_array_helper<A, T2[]> a1(allocator, n1, &p2); > boost::detail::array_deleter<T2[]> d1(n1); > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->noinit(p2); > return boost::shared_ptr<T>(s1, p1); > } > template<typename T, typename A> > inline typename boost::detail::sp_if_size_array<T>::type > allocate_shared_noinit(const A& allocator) { > typedef typename boost::detail::array_inner<T>::type T1; > typedef typename boost::detail::array_base<T1>::type T2; > enum { > N = boost::detail::array_total<T>::size > }; > T1* p1 = 0; > T2* p2 = 0; > boost::detail::allocate_array_helper<A, T2[N]> a1(allocator, &p2); > boost::detail::array_deleter<T2[N]> d1; > boost::shared_ptr<T> s1(p1, d1, a1); > typedef boost::detail::array_deleter<T2[N]>* D2; > p1 = reinterpret_cast<T1*>(p2); > D2 d2 = static_cast<D2>(s1._internal_get_untyped_deleter()); > d2->noinit(p2); > return boost::shared_ptr<T>(s1, p1); > } >} ># 20 "/usr/include/boost/smart_ptr/make_shared.hpp" 2 3 4 ># 31 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" 2 > > > > > > > >namespace epee >{ >namespace levin >{ > > > > >template<class t_connection_context> >class async_protocol_handler; > >template<class t_connection_context> >class async_protocol_handler_config >{ > typedef std::map<boost::uuids::uuid, async_protocol_handler<t_connection_context>* > connections_map; > critical_section m_connects_lock; > connections_map m_connects; > > void add_connection(async_protocol_handler<t_connection_context>* pc); > void del_connection(async_protocol_handler<t_connection_context>* pc); > > async_protocol_handler<t_connection_context>* find_connection(boost::uuids::uuid connection_id) const; > int find_and_lock_connection(boost::uuids::uuid connection_id, async_protocol_handler<t_connection_context>*& aph); > > friend class async_protocol_handler<t_connection_context>; > >public: > typedef t_connection_context connection_context; > levin_commands_handler<t_connection_context>* m_pcommands_handler; > uint64_t m_max_packet_size; > uint64_t m_invoke_timeout; > > int invoke(int command, const std::string& in_buff, std::string& buff_out, boost::uuids::uuid connection_id); > template<class callback_t> > int invoke_async(int command, const std::string& in_buff, boost::uuids::uuid connection_id, callback_t cb, size_t timeout = 0); > > int notify(int command, const std::string& in_buff, boost::uuids::uuid connection_id); > bool close(boost::uuids::uuid connection_id); > bool update_connection_context(const t_connection_context& contxt); > bool request_callback(boost::uuids::uuid connection_id); > template<class callback_t> > bool foreach_connection(callback_t cb); > size_t get_connections_count(); > > async_protocol_handler_config():m_pcommands_handler(__null), m_max_packet_size(100000000) > {} >}; > > > > > >template<class t_connection_context = net_utils::connection_context_base> >class async_protocol_handler >{ >public: > typedef t_connection_context connection_context; > typedef async_protocol_handler_config<t_connection_context> config_type; > > enum stream_state > { > stream_state_head, > stream_state_body > }; > > std::atomic<bool> m_deletion_initiated; > std::atomic<bool> m_protocol_released; > volatile uint32_t m_invoke_buf_ready; > > volatile int m_invoke_result_code; > > critical_section m_local_inv_buff_lock; > std::string m_local_inv_buff; > > critical_section m_send_lock; > critical_section m_call_lock; > > volatile uint32_t m_wait_count; > volatile uint32_t m_close_called; > bucket_head2 m_current_head; > net_utils::i_service_endpoint* m_pservice_endpoint; > config_type& m_config; > t_connection_context& m_connection_context; > > std::string m_cache_in_buffer; > stream_state m_state; > > int32_t m_oponent_protocol_ver; > bool m_connection_initialized; > > struct invoke_response_handler_base > { > virtual bool handle(int res, const std::string& buff, connection_context& context)=0; > virtual bool is_timer_started() const=0; > virtual void cancel()=0; > virtual bool cancel_timer()=0; > }; > template <class callback_t> > struct anvoke_handler: invoke_response_handler_base > { > anvoke_handler(const callback_t& cb, uint64_t timeout, async_protocol_handler& con, int command) > :m_cb(cb), m_con(con), m_timer(con.m_pservice_endpoint->get_io_service()), m_timer_started(false), > m_cancel_timer_called(false), m_timer_cancelled(false), m_command(command) > { > if(m_con.start_outer_call()) > { > m_timer.expires_from_now(boost::posix_time::milliseconds(timeout)); > m_timer.async_wait([&con, command, cb](const boost::system::error_code& ec) > { > if(ec == boost::asio::error::operation_aborted) > return; > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(con.get_context_ref()) << "]" << "Timeout on invoke operation happened, command: " << command << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > std::string fake; > cb(-4, fake, con.get_context_ref()); > con.close(); > con.finish_outer_call(); > }); > m_timer_started = true; > } > } > virtual ~anvoke_handler() > {} > callback_t m_cb; > async_protocol_handler& m_con; > boost::asio::deadline_timer m_timer; > bool m_timer_started; > bool m_cancel_timer_called; > bool m_timer_cancelled; > int m_command; > virtual bool handle(int res, const std::string& buff, typename async_protocol_handler::connection_context& context) > { > if(!cancel_timer()) > return false; > m_cb(res, buff, context); > m_con.finish_outer_call(); > return true; > } > virtual bool is_timer_started() const > { > return m_timer_started; > } > virtual void cancel() > { > if(cancel_timer()) > { > std::string fake; > m_cb(-3, fake, m_con.get_context_ref()); > m_con.finish_outer_call(); > } > } > virtual bool cancel_timer() > { > if(!m_cancel_timer_called) > { > m_cancel_timer_called = true; > boost::system::error_code ignored_ec; > m_timer_cancelled = 1 == m_timer.cancel(ignored_ec); > } > return m_timer_cancelled; > } > }; > critical_section m_invoke_response_handlers_lock; > std::list<boost::shared_ptr<invoke_response_handler_base> > m_invoke_response_handlers; > > template<class callback_t> > bool add_invoke_response_handler(callback_t cb, uint64_t timeout, async_protocol_handler& con, int command) > { > epee::critical_region_t<decltype(m_invoke_response_handlers_lock)> critical_region_var(m_invoke_response_handlers_lock); > boost::shared_ptr<invoke_response_handler_base> handler(boost::make_shared<anvoke_handler<callback_t>>(cb, timeout, con, command)); > m_invoke_response_handlers.push_back(handler); > return handler->is_timer_started(); > } > template<class callback_t> friend struct anvoke_handler; >public: > async_protocol_handler(net_utils::i_service_endpoint* psnd_hndlr, > config_type& config, > t_connection_context& conn_context): > m_current_head(bucket_head2()), > m_pservice_endpoint(psnd_hndlr), > m_config(config), > m_connection_context(conn_context), > m_state(stream_state_head) > { > m_close_called = 0; > m_deletion_initiated = false; > m_protocol_released = false; > m_wait_count = 0; > m_oponent_protocol_ver = 0; > m_connection_initialized = false; > } > virtual ~async_protocol_handler() > { > m_deletion_initiated = true; > if(m_connection_initialized) > { > m_config.del_connection(this); > } > > for (size_t i = 0; i < 60 * 1000 / 100 && 0 != boost::interprocess::ipcdetail::atomic_read32(&m_wait_count); ++i) > { > misc_utils::sleep_no_w(100); > } > do{if(!(0 == boost::interprocess::ipcdetail::atomic_read32(&m_wait_count))) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 240 << "|" << __FUNCTION__ << "|" << "Failed to wait for operation completion. m_wait_count = " << m_wait_count << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return;};}while(0); > > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "~async_protocol_handler()" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > } > > bool start_outer_call() > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "[levin_protocol] -->> start_outer_call" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > if(!m_pservice_endpoint->add_ref()) > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "[levin_protocol] -->> start_outer_call failed" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_red, false, __null);}}; > return false; > } > boost::interprocess::ipcdetail::atomic_inc32(&m_wait_count); > return true; > } > bool finish_outer_call() > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "[levin_protocol] <<-- finish_outer_call" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > boost::interprocess::ipcdetail::atomic_dec32(&m_wait_count); > m_pservice_endpoint->release(); > return true; > } > > bool release_protocol() > { > decltype(m_invoke_response_handlers) local_invoke_response_handlers; > { epee::critical_region_t<decltype(m_invoke_response_handlers_lock)> critical_region_var(m_invoke_response_handlers_lock); > local_invoke_response_handlers.swap(m_invoke_response_handlers); > m_protocol_released = true; > }; > > > > std::for_each(local_invoke_response_handlers.begin(), local_invoke_response_handlers.end(), [](const boost::shared_ptr<invoke_response_handler_base>& pinv_resp_hndlr) { > pinv_resp_hndlr->cancel(); > }); > > return true; > } > > bool close() > { > boost::interprocess::ipcdetail::atomic_inc32(&m_close_called); > > m_pservice_endpoint->close(); > return true; > } > > void update_connection_context(const connection_context& contxt) > { > m_connection_context = contxt; > } > > void request_callback() > { > misc_utils::auto_scope_leave_caller scope_exit_handler = misc_utils::create_scope_leave_handler( > boost::bind(&async_protocol_handler::finish_outer_call, this)); > > m_pservice_endpoint->request_callback(); > } > > void handle_qued_callback() > { > m_config.m_pcommands_handler->callback(m_connection_context); > } > > virtual bool handle_recv(const void* ptr, size_t cb) > { > if(boost::interprocess::ipcdetail::atomic_read32(&m_close_called)) > return false; > > if(!m_config.m_pcommands_handler) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 314 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Commands handler not set!" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > if(m_cache_in_buffer.size() + cb > m_config.m_max_packet_size) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > > "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" ># 320 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" > << ":" << > > 322 ># 320 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" > << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Maximum packet size exceed!, m_max_packet_size = " << m_config.m_max_packet_size << ", packet received " << m_cache_in_buffer.size() + cb << ", connection will be closed." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);} > > ; > return false; > } > > m_cache_in_buffer.append((const char*)ptr, cb); > > bool is_continue = true; > while(is_continue) > { > switch(m_state) > { > case stream_state_body: > if(m_cache_in_buffer.size() < m_current_head.m_cb) > { > is_continue = false; > break; > } > { > std::string buff_to_invoke; > if(m_cache_in_buffer.size() == m_current_head.m_cb) > buff_to_invoke.swap(m_cache_in_buffer); > else > { > buff_to_invoke.assign(m_cache_in_buffer, 0, (std::string::size_type)m_current_head.m_cb); > m_cache_in_buffer.erase(0, (std::string::size_type)m_current_head.m_cb); > } > > bool is_response = (m_oponent_protocol_ver == 1 && m_current_head.m_flags&0x00000002); > > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "LEVIN_PACKET_RECIEVED. [len=" << m_current_head.m_cb << ", flags" << m_current_head.m_flags << ", r?=" << m_current_head.m_have_to_return_data <<", cmd = " << m_current_head.m_command << ", v=" << m_current_head.m_protocol_version << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}} > > > > ; > > if(is_response) > { > > epee::critical_region_t<decltype(m_invoke_response_handlers_lock)> invoke_response_handlers_guard(m_invoke_response_handlers_lock); > if(!m_invoke_response_handlers.empty()) > { > boost::shared_ptr<invoke_response_handler_base> response_handler = m_invoke_response_handlers.front(); > bool timer_cancelled = response_handler->cancel_timer(); > > if(timer_cancelled) > m_invoke_response_handlers.pop_front(); > invoke_response_handlers_guard.unlock(); > > if(timer_cancelled) > response_handler->handle(m_current_head.m_command, buff_to_invoke, m_connection_context); > } > else > { > invoke_response_handlers_guard.unlock(); > > if(!boost::interprocess::ipcdetail::atomic_read32(&m_wait_count) && !boost::interprocess::ipcdetail::atomic_read32(&m_close_called)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 379 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "no active invoke when response came, wtf?" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > }else > { > { epee::critical_region_t<decltype(m_local_inv_buff_lock)> critical_region_var(m_local_inv_buff_lock); > buff_to_invoke.swap(m_local_inv_buff); > buff_to_invoke.clear(); > m_invoke_result_code = m_current_head.m_return_code; > }; > boost::interprocess::ipcdetail::atomic_write32(&m_invoke_buf_ready, 1); > } > } > }else > { > if(m_current_head.m_have_to_return_data) > { > std::string return_buff; > m_current_head.m_return_code = m_config.m_pcommands_handler->invoke( > m_current_head.m_command, > buff_to_invoke, > return_buff, > m_connection_context); > m_current_head.m_cb = return_buff.size(); > m_current_head.m_have_to_return_data = false; > m_current_head.m_protocol_version = 1; > m_current_head.m_flags = 0x00000002; > std::string send_buff((const char*)&m_current_head, sizeof(m_current_head)); > send_buff += return_buff; > { epee::critical_region_t<decltype(m_send_lock)> critical_region_var(m_send_lock); > if(!m_pservice_endpoint->do_send(send_buff.data(), send_buff.size())) > return false; > }; > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "LEVIN_PACKET_SENT. [len=" << m_current_head.m_cb << ", flags" << m_current_head.m_flags << ", r?=" << m_current_head.m_have_to_return_data <<", cmd = " << m_current_head.m_command << ", ver=" << m_current_head.m_protocol_version << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}} > > > > ; > } > else > m_config.m_pcommands_handler->notify(m_current_head.m_command, buff_to_invoke, m_connection_context); > } > } > m_state = stream_state_head; > break; > case stream_state_head: > { > if(m_cache_in_buffer.size() < sizeof(bucket_head2)) > { > if(m_cache_in_buffer.size() >= sizeof(uint64_t) && *((uint64_t*)m_cache_in_buffer.data()) != 0x0101010101012101LL) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 429 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Signature mismatch, connection will be closed" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > is_continue = false; > break; > } > > bucket_head2* phead = (bucket_head2*)m_cache_in_buffer.data(); > if(0x0101010101012101LL != phead->m_signature) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 439 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Signature mismatch, connection will be closed" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > m_current_head = *phead; > > m_cache_in_buffer.erase(0, sizeof(bucket_head2)); > m_state = stream_state_body; > m_oponent_protocol_ver = m_current_head.m_protocol_version; > if(m_current_head.m_cb > m_config.m_max_packet_size) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > > "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" ># 449 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" > << ":" << > > 451 ># 449 "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" > << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Maximum packet size exceed!, m_max_packet_size = " << m_config.m_max_packet_size << ", packet header received " << m_current_head.m_cb << ", connection will be closed." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);} > > ; > return false; > } > } > break; > default: > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 457 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Undefined state in levin_server_impl::connection_handler, m_state=" << m_state << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > } > > return true; > } > > bool after_init_connection() > { > if (!m_connection_initialized) > { > m_connection_initialized = true; > m_config.add_connection(this); > } > return true; > } > > template<class callback_t> > bool async_invoke(int command, const std::string& in_buff, callback_t cb, size_t timeout = 0) > { > misc_utils::auto_scope_leave_caller scope_exit_handler = misc_utils::create_scope_leave_handler( > boost::bind(&async_protocol_handler::finish_outer_call, this)); > > if(timeout == 0) > timeout = m_config.m_invoke_timeout; > > int err_code = 0; > do > { > if(m_deletion_initiated) > { > err_code = -3; > break; > } > > epee::critical_region_t<decltype(m_call_lock)> critical_region_var(m_call_lock); > > if(m_deletion_initiated) > { > err_code = -3; > break; > } > > bucket_head2 head = {0}; > head.m_signature = 0x0101010101012101LL; > head.m_cb = in_buff.size(); > head.m_have_to_return_data = true; > > head.m_flags = 0x00000001; > head.m_command = command; > head.m_protocol_version = 1; > > boost::interprocess::ipcdetail::atomic_write32(&m_invoke_buf_ready, 0); > { epee::critical_region_t<decltype(m_send_lock)> critical_region_var(m_send_lock); > epee::critical_region_t<decltype(m_invoke_response_handlers_lock)> critical_region_var1(m_invoke_response_handlers_lock); > if(!m_pservice_endpoint->do_send(&head, sizeof(head))) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 515 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Failed to do_send" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > err_code = -1; > break; > } > > if(!m_pservice_endpoint->do_send(in_buff.data(), (int)in_buff.size())) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 522 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Failed to do_send" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > err_code = -1; > break; > } > > if(!add_invoke_response_handler(cb, timeout, *this, command)) > { > err_code = -3; > break; > } > }; > } while (false); > > if (0 != err_code) > { > std::string stub_buff; > > cb(err_code, stub_buff, m_connection_context); > return false; > } > > return true; > } > > int invoke(int command, const std::string& in_buff, std::string& buff_out) > { > misc_utils::auto_scope_leave_caller scope_exit_handler = misc_utils::create_scope_leave_handler( > boost::bind(&async_protocol_handler::finish_outer_call, this)); > > if(m_deletion_initiated) > return -3; > > epee::critical_region_t<decltype(m_call_lock)> critical_region_var(m_call_lock); > > if(m_deletion_initiated) > return -3; > > bucket_head2 head = {0}; > head.m_signature = 0x0101010101012101LL; > head.m_cb = in_buff.size(); > head.m_have_to_return_data = true; > > head.m_flags = 0x00000001; > head.m_command = command; > head.m_protocol_version = 1; > > boost::interprocess::ipcdetail::atomic_write32(&m_invoke_buf_ready, 0); > { epee::critical_region_t<decltype(m_send_lock)> critical_region_var(m_send_lock); > if(!m_pservice_endpoint->do_send(&head, sizeof(head))) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 572 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Failed to do_send" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return -1; > } > > if(!m_pservice_endpoint->do_send(in_buff.data(), (int)in_buff.size())) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 578 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Failed to do_send" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return -1; > } > }; > > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "LEVIN_PACKET_SENT. [len=" << head.m_cb << ", f=" << head.m_flags << ", r?=" << head.m_have_to_return_data << ", cmd = " << head.m_command << ", ver=" << head.m_protocol_version << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}} > > > > ; > > uint64_t ticks_start = misc_utils::get_tick_count(); > > while(!boost::interprocess::ipcdetail::atomic_read32(&m_invoke_buf_ready) && !m_deletion_initiated && !m_protocol_released) > { > if(misc_utils::get_tick_count() - ticks_start > m_config.m_invoke_timeout) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "invoke timeout (" << m_config.m_invoke_timeout << "), closing connection " << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > close(); > return -4; > } > if(!m_pservice_endpoint->call_run_once_service_io()) > return -3; > } > > if(m_deletion_initiated || m_protocol_released) > return -3; > > { epee::critical_region_t<decltype(m_local_inv_buff_lock)> critical_region_var(m_local_inv_buff_lock); > buff_out.swap(m_local_inv_buff); > m_local_inv_buff.clear(); > }; > > return m_invoke_result_code; > } > > int notify(int command, const std::string& in_buff) > { > misc_utils::auto_scope_leave_caller scope_exit_handler = misc_utils::create_scope_leave_handler( > boost::bind(&async_protocol_handler::finish_outer_call, this)); > > if(m_deletion_initiated) > return -3; > > epee::critical_region_t<decltype(m_call_lock)> critical_region_var(m_call_lock); > > if(m_deletion_initiated) > return -3; > > bucket_head2 head = {0}; > head.m_signature = 0x0101010101012101LL; > head.m_have_to_return_data = false; > head.m_cb = in_buff.size(); > > head.m_command = command; > head.m_protocol_version = 1; > head.m_flags = 0x00000001; > { epee::critical_region_t<decltype(m_send_lock)> critical_region_var(m_send_lock); > if(!m_pservice_endpoint->do_send(&head, sizeof(head))) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 638 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "Failed to do_send()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return -1; > } > > if(!m_pservice_endpoint->do_send(in_buff.data(), (int)in_buff.size())) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/levin_protocol_handler_async.h" << ":" << 644 << "|" << __FUNCTION__ << "|" << "Failed to do_send()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return -1; > } > }; > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(m_connection_context) << "]" << "LEVIN_PACKET_SENT. [len=" << head.m_cb << ", f=" << head.m_flags << ", r?=" << head.m_have_to_return_data << ", cmd = " << head.m_command << ", ver=" << head.m_protocol_version << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}} > > > > ; > > return 1; > } > > boost::uuids::uuid get_connection_id() {return m_connection_context.m_connection_id;} > > t_connection_context& get_context_ref() {return m_connection_context;} >}; > >template<class t_connection_context> >void async_protocol_handler_config<t_connection_context>::del_connection(async_protocol_handler<t_connection_context>* pconn) >{ > { epee::critical_region_t<decltype(m_connects_lock)> critical_region_var(m_connects_lock); > m_connects.erase(pconn->get_connection_id()); > }; > m_pcommands_handler->on_connection_close(pconn->m_connection_context); >} > >template<class t_connection_context> >void async_protocol_handler_config<t_connection_context>::add_connection(async_protocol_handler<t_connection_context>* pconn) >{ > { epee::critical_region_t<decltype(m_connects_lock)> critical_region_var(m_connects_lock); > m_connects[pconn->get_connection_id()] = pconn; > }; > m_pcommands_handler->on_connection_new(pconn->m_connection_context); >} > >template<class t_connection_context> >async_protocol_handler<t_connection_context>* async_protocol_handler_config<t_connection_context>::find_connection(boost::uuids::uuid connection_id) const >{ > auto it = m_connects.find(connection_id); > return it == m_connects.end() ? 0 : it->second; >} > >template<class t_connection_context> >int async_protocol_handler_config<t_connection_context>::find_and_lock_connection(boost::uuids::uuid connection_id, async_protocol_handler<t_connection_context>*& aph) >{ > epee::critical_region_t<decltype(m_connects_lock)> critical_region_var(m_connects_lock); > aph = find_connection(connection_id); > if(0 == aph) > return -2; > if(!aph->start_outer_call()) > return -3; > return 0; >} > >template<class t_connection_context> >int async_protocol_handler_config<t_connection_context>::invoke(int command, const std::string& in_buff, std::string& buff_out, boost::uuids::uuid connection_id) >{ > async_protocol_handler<t_connection_context>* aph; > int r = find_and_lock_connection(connection_id, aph); > return 0 == r ? aph->invoke(command, in_buff, buff_out) : r; >} > >template<class t_connection_context> template<class callback_t> >int async_protocol_handler_config<t_connection_context>::invoke_async(int command, const std::string& in_buff, boost::uuids::uuid connection_id, callback_t cb, size_t timeout) >{ > async_protocol_handler<t_connection_context>* aph; > int r = find_and_lock_connection(connection_id, aph); > return 0 == r ? aph->async_invoke(command, in_buff, cb, timeout) : r; >} > >template<class t_connection_context> template<class callback_t> >bool async_protocol_handler_config<t_connection_context>::foreach_connection(callback_t cb) >{ > epee::critical_region_t<decltype(m_connects_lock)> critical_region_var(m_connects_lock); > for(auto& c: m_connects) > { > async_protocol_handler<t_connection_context>* aph = c.second; > if(!cb(aph->get_context_ref())) > return false; > } > return true; >} > >template<class t_connection_context> >size_t async_protocol_handler_config<t_connection_context>::get_connections_count() >{ > epee::critical_region_t<decltype(m_connects_lock)> critical_region_var(m_connects_lock); > return m_connects.size(); >} > >template<class t_connection_context> >int async_protocol_handler_config<t_connection_context>::notify(int command, const std::string& in_buff, boost::uuids::uuid connection_id) >{ > async_protocol_handler<t_connection_context>* aph; > int r = find_and_lock_connection(connection_id, aph); > return 0 == r ? aph->notify(command, in_buff) : r; >} > >template<class t_connection_context> >bool async_protocol_handler_config<t_connection_context>::close(boost::uuids::uuid connection_id) >{ > epee::critical_region_t<decltype(m_connects_lock)> critical_region_var(m_connects_lock); > async_protocol_handler<t_connection_context>* aph = find_connection(connection_id); > return 0 != aph ? aph->close() : false; >} > >template<class t_connection_context> >bool async_protocol_handler_config<t_connection_context>::update_connection_context(const t_connection_context& contxt) >{ > epee::critical_region_t<decltype(m_connects_lock)> critical_region_var(m_connects_lock); > async_protocol_handler<t_connection_context>* aph = find_connection(contxt.m_connection_id); > if(0 == aph) > return false; > aph->update_connection_context(contxt); > return true; >} > >template<class t_connection_context> >bool async_protocol_handler_config<t_connection_context>::request_callback(boost::uuids::uuid connection_id) >{ > async_protocol_handler<t_connection_context>* aph; > int r = find_and_lock_connection(connection_id, aph); > if(0 == r) > { > aph->request_callback(); > return true; > } > else > { > return false; > } >} >} >} ># 35 "/c/honeypenny/contrib/epee/include/net/levin_server_cp2.h" 2 > >namespace epee >{ >namespace net_utils >{ > typedef boosted_tcp_server<levin::protocol_handler<> > boosted_levin_server; > typedef boosted_tcp_server<levin::async_protocol_handler<> > boosted_levin_async_server; >} >} ># 21 "/c/honeypenny/src/p2p/net_node.h" 2 > ># 1 "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" 1 ># 27 "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" > > > > ># 1 "/c/honeypenny/contrib/epee/include/net/levin_base.h" 1 ># 32 "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" 2 > >namespace epee >{ > namespace net_utils > { > template<class t_arg, class t_result, class t_transport> > bool invoke_remote_command2(int command, const t_arg& out_struct, t_result& result_struct, t_transport& transport) > { > if(!transport.is_connected()) > return false; > > serialization::portable_storage stg; > out_struct.store(stg); > std::string buff_to_send, buff_to_recv; > stg.store_to_binary(buff_to_send); > > int res = transport.invoke(command, buff_to_send, buff_to_recv); > if( res <=0 ) > { > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to invoke command " << command << " return code " << res << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_red, false, __null);}}; > return false; > } > serialization::portable_storage stg_ret; > if(!stg_ret.load_from_binary(buff_to_recv)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" << ":" << 57 << "|" << __FUNCTION__ << "|" << "Failed to load_from_binary on command " << command << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > result_struct.load(stg_ret); > return true; > } > > template<class t_arg, class t_transport> > bool notify_remote_command2(int command, const t_arg& out_struct, t_transport& transport) > { > if(!transport.is_connected()) > return false; > > serialization::portable_storage stg; > out_struct.store(&stg); > std::string buff_to_send; > stg.store_to_binary(buff_to_send); > > int res = transport.notify(command, buff_to_send); > if(res <=0 ) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" << ":" << 78 << "|" << __FUNCTION__ << "|" << "Failed to notify command " << command << " return code " << res << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > return true; > } > > template<class t_arg, class t_result, class t_transport> > bool invoke_remote_command2(boost::uuids::uuid conn_id, int command, const t_arg& out_struct, t_result& result_struct, t_transport& transport) > { > > typename serialization::portable_storage stg; > out_struct.store(stg); > std::string buff_to_send, buff_to_recv; > stg.store_to_binary(buff_to_send); > > int res = transport.invoke(command, buff_to_send, buff_to_recv, conn_id); > if( res <=0 ) > { > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to invoke command " << command << " return code " << res << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_default, false, __null);}}; > return false; > } > typename serialization::portable_storage stg_ret; > if(!stg_ret.load_from_binary(buff_to_recv)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" << ":" << 102 << "|" << __FUNCTION__ << "|" << "Failed to load_from_binary on command " << command << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > result_struct.load(stg_ret); > > return true; > } > > template<class t_result, class t_arg, class callback_t, class t_transport> > bool async_invoke_remote_command2(boost::uuids::uuid conn_id, int command, const t_arg& out_struct, t_transport& transport, callback_t cb, size_t inv_timeout = 0) > { > typename serialization::portable_storage stg; > const_cast<t_arg&>(out_struct).store(stg); > std::string buff_to_send, buff_to_recv; > stg.store_to_binary(buff_to_send); > int res = transport.invoke_async(command, buff_to_send, conn_id, [cb, command](int code, const std::string& buff, typename t_transport::connection_context& context)->bool > { > t_result result_struct = boost::value_initialized<decltype(result_struct)>(); > if( code <=0 ) > { > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to invoke command " << command << " return code " << code << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_default, false, __null);}}; > cb(code, result_struct, context); > return false; > } > serialization::portable_storage stg_ret; > if(!stg_ret.load_from_binary(buff)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" << ":" << 129 << "|" << __FUNCTION__ << "|" << "Failed to load_from_binary on command " << command << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > cb(-7, result_struct, context); > return false; > } > result_struct.load(stg_ret); > cb(code, result_struct, context); > return true; > }, inv_timeout); > if( res <=0 ) > { > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to invoke command " << command << " return code " << res << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_default, false, __null);}}; > return false; > } > return true; > } > > template<class t_arg, class t_transport> > bool notify_remote_command2(boost::uuids::uuid conn_id, int command, const t_arg& out_struct, t_transport& transport) > { > > serialization::portable_storage stg; > out_struct.store(stg); > std::string buff_to_send, buff_to_recv; > stg.store_to_binary(buff_to_send); > > int res = transport.notify(command, buff_to_send, conn_id); > if(res <=0 ) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to notify command " << command << " return code " << res << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, false, __null);}}; > return false; > } > return true; > } > > > template<class t_owner, class t_in_type, class t_out_type, class t_context, class callback_t> > int buff_to_t_adapter(int command, const std::string& in_buff, std::string& buff_out, callback_t cb, t_context& context ) > { > serialization::portable_storage strg; > if(!strg.load_from_binary(in_buff)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" << ":" << 170 << "|" << __FUNCTION__ << "|" << "Failed to load_from_binary in command " << command << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return -1; > } > boost::value_initialized<t_in_type> in_struct; > boost::value_initialized<t_out_type> out_struct; > > static_cast<t_in_type&>(in_struct).load(strg); > int res = cb(command, static_cast<t_in_type&>(in_struct), static_cast<t_out_type&>(out_struct), context); > serialization::portable_storage strg_out; > static_cast<t_out_type&>(out_struct).store(strg_out); > > if(!strg_out.store_to_binary(buff_out)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" << ":" << 183 << "|" << __FUNCTION__ << "|" << "Failed to store_to_binary in command" << command << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return -1; > } > > return res; > }; > > template<class t_owner, class t_in_type, class t_context, class callback_t> > int buff_to_t_adapter(t_owner* powner, int command, const std::string& in_buff, callback_t cb, t_context& context) > { > serialization::portable_storage strg; > if(!strg.load_from_binary(in_buff)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" << ":" << 196 << "|" << __FUNCTION__ << "|" << "Failed to load_from_binary in notify " << command << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return -1; > } > boost::value_initialized<t_in_type> in_struct; > static_cast<t_in_type&>(in_struct).load(strg); > return cb(command, in_struct, context); > }; ># 287 "/c/honeypenny/contrib/epee/include/storages/levin_abstract_invoke2.h" > } >} ># 23 "/c/honeypenny/src/p2p/net_node.h" 2 ># 1 "/c/honeypenny/src/p2p/net_peerlist.h" 1 ># 24 "/c/honeypenny/src/p2p/net_peerlist.h" ># 1 "/c/honeypenny/contrib/epee/include/net/local_ip.h" 1 ># 28 "/c/honeypenny/contrib/epee/include/net/local_ip.h" > > >namespace epee >{ > namespace net_utils > { > inline > bool is_ip_local(uint32_t ip) > { > > > > > > > if( (ip | 0xffffff00) == 0xffffff0a) > return true; > > if( (ip | 0xffff0000) == 0xffffa8c0) > return true; > > if( (ip | 0xffffff00) == 0xffffffac) > { > uint32_t second_num = (ip << 8) & 0xff000000; > if(second_num >= 16 && second_num <= 31 ) > return true; > } > return false; > } > inline > bool is_ip_loopback(uint32_t ip) > { > if( (ip | 0xffffff00) == 0xffffff7f) > return true; > > > > > > return false; > } > > } >} ># 25 "/c/honeypenny/src/p2p/net_peerlist.h" 2 > > ># 1 "/c/honeypenny/src/p2p/net_peerlist_boost_serialization.h" 1 > > > > > > >namespace boost >{ > namespace serialization > { > > template <class Archive, class ver_type> > inline void serialize(Archive &a, nodetool::net_address& na, const ver_type ver) > { > a & na.ip; > a & na.port; > } > > > template <class Archive, class ver_type> > inline void serialize(Archive &a, nodetool::peerlist_entry& pl, const ver_type ver) > { > a & pl.adr; > a & pl.id; > a & pl.last_seen; > } > } >} ># 28 "/c/honeypenny/src/p2p/net_peerlist.h" 2 > > > > >namespace nodetool >{ > > > > > > class peerlist_manager > { > public: > bool init(bool allow_local_ip); > bool deinit(); > size_t get_white_peers_count(){epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); return m_peers_white.size();} > size_t get_gray_peers_count(){epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); return m_peers_gray.size();} > bool merge_peerlist(const std::list<peerlist_entry>& outer_bs); > bool get_peerlist_head(std::list<peerlist_entry>& bs_head, uint32_t depth = 250); > bool get_peerlist_full(std::list<peerlist_entry>& pl_gray, std::list<peerlist_entry>& pl_white); > bool get_white_peer_by_index(peerlist_entry& p, size_t i); > bool get_gray_peer_by_index(peerlist_entry& p, size_t i); > bool append_with_peer_white(const peerlist_entry& pr); > bool append_with_peer_gray(const peerlist_entry& pr); > bool set_peer_just_seen(peerid_type peer, uint32_t ip, uint32_t port); > bool set_peer_just_seen(peerid_type peer, const net_address& addr); > bool set_peer_unreachable(const peerlist_entry& pr); > bool is_ip_allowed(uint32_t ip); > void trim_white_peerlist(); > void trim_gray_peerlist(); > > > private: > struct by_time{}; > struct by_id{}; > struct by_addr{}; > > struct modify_all_but_id > { > modify_all_but_id(const peerlist_entry& ple):m_ple(ple){} > void operator()(peerlist_entry& e) > { > e.id = m_ple.id; > } > private: > const peerlist_entry& m_ple; > }; > > struct modify_all > { > modify_all(const peerlist_entry& ple):m_ple(ple){} > void operator()(peerlist_entry& e) > { > e = m_ple; > } > private: > const peerlist_entry& m_ple; > }; > > struct modify_last_seen > { > modify_last_seen(time_t last_seen):m_last_seen(last_seen){} > void operator()(peerlist_entry& e) > { > e.last_seen = m_last_seen; > } > private: > time_t m_last_seen; > }; > > > typedef boost::multi_index_container< > peerlist_entry, > boost::multi_index::indexed_by< > > boost::multi_index::ordered_unique<boost::multi_index::tag<by_addr>, boost::multi_index::member<peerlist_entry,net_address,&peerlist_entry::adr> >, > > boost::multi_index::ordered_non_unique<boost::multi_index::tag<by_time>, boost::multi_index::member<peerlist_entry,time_t,&peerlist_entry::last_seen> > > > > > peers_indexed; > > typedef boost::multi_index_container< > peerlist_entry, > boost::multi_index::indexed_by< > > boost::multi_index::ordered_unique<boost::multi_index::tag<by_id>, boost::multi_index::member<peerlist_entry,uint64_t,&peerlist_entry::id> >, > > boost::multi_index::ordered_unique<boost::multi_index::tag<by_addr>, boost::multi_index::member<peerlist_entry,net_address,&peerlist_entry::adr> >, > > boost::multi_index::ordered_non_unique<boost::multi_index::tag<by_time>, boost::multi_index::member<peerlist_entry,time_t,&peerlist_entry::last_seen> > > > > > peers_indexed_old; > public: > > template <class Archive, class t_version_type> > void serialize(Archive &ar, const t_version_type ver) > { > if(ver < 6) > throw std::runtime_error("not supported storage format"); > std::string project_name = "forceberry""_testnet"; ar & project_name; if(project_name != "forceberry""_testnet") {throw std::runtime_error(std::string("wrong storage file: project name in file: ") + project_name + ", expected: " + "forceberry""_testnet" );}; > epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); > ar & m_peers_white; > ar & m_peers_gray; > } > > private: > bool peers_indexed_from_old(const peers_indexed_old& pio, peers_indexed& pi); > > friend class boost::serialization::access; > epee::critical_section m_peerlist_lock; > std::string m_config_folder; > bool m_allow_local_ip; > > > peers_indexed m_peers_gray; > peers_indexed m_peers_white; > }; > > inline > bool peerlist_manager::init(bool allow_local_ip) > { > m_allow_local_ip = allow_local_ip; > return true; > } > > inline > bool peerlist_manager::deinit() > { > return true; > } > > inline > bool peerlist_manager::peers_indexed_from_old(const peers_indexed_old& pio, peers_indexed& pi) > { > for(auto x: pio) > { > auto by_addr_it = pi.get<by_addr>().find(x.adr); > if(by_addr_it == pi.get<by_addr>().end()) > { > pi.insert(x); > } > } > > return true; > } > > inline void peerlist_manager::trim_white_peerlist() > { > while(m_peers_gray.size() > 5000) > { > peers_indexed::index<by_time>::type& sorted_index=m_peers_gray.get<by_time>(); > sorted_index.erase(sorted_index.begin()); > } > } > > inline void peerlist_manager::trim_gray_peerlist() > { > while(m_peers_white.size() > 1000) > { > peers_indexed::index<by_time>::type& sorted_index=m_peers_white.get<by_time>(); > sorted_index.erase(sorted_index.begin()); > } > } > > inline > bool peerlist_manager::merge_peerlist(const std::list<peerlist_entry>& outer_bs) > { > epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); > if (boost::foreach_detail_::auto_any_t _foreach_col197 = boost::foreach_detail_::contain( (outer_bs) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((outer_bs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(outer_bs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(outer_bs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur197 = boost::foreach_detail_::begin( _foreach_col197 , (true ? 0 : boost::foreach_detail_::encode_type(outer_bs, boost::foreach_detail_::is_const_(outer_bs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((outer_bs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(outer_bs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(outer_bs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end197 = boost::foreach_detail_::end( _foreach_col197 , (true ? 0 : boost::foreach_detail_::encode_type(outer_bs, boost::foreach_detail_::is_const_(outer_bs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((outer_bs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(outer_bs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(outer_bs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue197 = true; _foreach_continue197 && !boost::foreach_detail_::done( _foreach_cur197 , _foreach_end197 , (true ? 0 : boost::foreach_detail_::encode_type(outer_bs, boost::foreach_detail_::is_const_(outer_bs)))); _foreach_continue197 ? boost::foreach_detail_::next( _foreach_cur197 , (true ? 0 : boost::foreach_detail_::encode_type(outer_bs, boost::foreach_detail_::is_const_(outer_bs)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue197)) {} else for (const peerlist_entry& be = boost::foreach_detail_::deref( _foreach_cur197 , (true ? 0 : boost::foreach_detail_::encode_type(outer_bs, boost::foreach_detail_::is_const_(outer_bs)))); !_foreach_continue197; _foreach_continue197 = true) > { > append_with_peer_gray(be); > } > > trim_gray_peerlist(); > return true; > } > > inline > bool peerlist_manager::get_white_peer_by_index(peerlist_entry& p, size_t i) > { > epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); > if(i >= m_peers_white.size()) > return false; > > peers_indexed::index<by_time>::type& by_time_index = m_peers_white.get<by_time>(); > p = *epee::misc_utils::move_it_backward(--by_time_index.end(), i); > return true; > } > > inline > bool peerlist_manager::get_gray_peer_by_index(peerlist_entry& p, size_t i) > { > epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); > if(i >= m_peers_gray.size()) > return false; > > peers_indexed::index<by_time>::type& by_time_index = m_peers_gray.get<by_time>(); > p = *epee::misc_utils::move_it_backward(--by_time_index.end(), i); > return true; > } > > inline > bool peerlist_manager::is_ip_allowed(uint32_t ip) > { > > if(epee::net_utils::is_ip_loopback(ip)) > return false; > > if(!m_allow_local_ip && epee::net_utils::is_ip_local(ip)) > return false; > > return true; > } > > inline > bool peerlist_manager::get_peerlist_head(std::list<peerlist_entry>& bs_head, uint32_t depth) > { > > epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); > peers_indexed::index<by_time>::type& by_time_index=m_peers_white.get<by_time>(); > uint32_t cnt = 0; > if (boost::foreach_detail_::auto_any_t _foreach_col250 = boost::foreach_detail_::contain( (by_time_index) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((by_time_index), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(by_time_index) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(by_time_index) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur250 = boost::foreach_detail_::rbegin( _foreach_col250 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index, boost::foreach_detail_::is_const_(by_time_index))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((by_time_index), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(by_time_index) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(by_time_index) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end250 = boost::foreach_detail_::rend( _foreach_col250 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index, boost::foreach_detail_::is_const_(by_time_index))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((by_time_index), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(by_time_index) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(by_time_index) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue250 = true; _foreach_continue250 && !boost::foreach_detail_::rdone( _foreach_cur250 , _foreach_end250 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index, boost::foreach_detail_::is_const_(by_time_index)))); _foreach_continue250 ? boost::foreach_detail_::rnext( _foreach_cur250 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index, boost::foreach_detail_::is_const_(by_time_index)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue250)) {} else for (const peers_indexed::value_type& vl = boost::foreach_detail_::rderef( _foreach_cur250 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index, boost::foreach_detail_::is_const_(by_time_index)))); !_foreach_continue250; _foreach_continue250 = true) > { > if(!vl.last_seen) > continue; > bs_head.push_back(vl); > if(cnt++ > depth) > break; > } > return true; > } > > inline > bool peerlist_manager::get_peerlist_full(std::list<peerlist_entry>& pl_gray, std::list<peerlist_entry>& pl_white) > { > epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); > peers_indexed::index<by_time>::type& by_time_index_gr=m_peers_gray.get<by_time>(); > if (boost::foreach_detail_::auto_any_t _foreach_col266 = boost::foreach_detail_::contain( (by_time_index_gr) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((by_time_index_gr), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(by_time_index_gr) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(by_time_index_gr) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur266 = boost::foreach_detail_::rbegin( _foreach_col266 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_gr, boost::foreach_detail_::is_const_(by_time_index_gr))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((by_time_index_gr), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(by_time_index_gr) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(by_time_index_gr) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end266 = boost::foreach_detail_::rend( _foreach_col266 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_gr, boost::foreach_detail_::is_const_(by_time_index_gr))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((by_time_index_gr), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(by_time_index_gr) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(by_time_index_gr) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue266 = true; _foreach_continue266 && !boost::foreach_detail_::rdone( _foreach_cur266 , _foreach_end266 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_gr, boost::foreach_detail_::is_const_(by_time_index_gr)))); _foreach_continue266 ? boost::foreach_detail_::rnext( _foreach_cur266 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_gr, boost::foreach_detail_::is_const_(by_time_index_gr)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue266)) {} else for (const peers_indexed::value_type& vl = boost::foreach_detail_::rderef( _foreach_cur266 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_gr, boost::foreach_detail_::is_const_(by_time_index_gr)))); !_foreach_continue266; _foreach_continue266 = true) > { > pl_gray.push_back(vl); > } > > peers_indexed::index<by_time>::type& by_time_index_wt=m_peers_white.get<by_time>(); > if (boost::foreach_detail_::auto_any_t _foreach_col272 = boost::foreach_detail_::contain( (by_time_index_wt) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((by_time_index_wt), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(by_time_index_wt) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(by_time_index_wt) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur272 = boost::foreach_detail_::rbegin( _foreach_col272 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_wt, boost::foreach_detail_::is_const_(by_time_index_wt))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((by_time_index_wt), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(by_time_index_wt) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(by_time_index_wt) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end272 = boost::foreach_detail_::rend( _foreach_col272 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_wt, boost::foreach_detail_::is_const_(by_time_index_wt))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((by_time_index_wt), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(by_time_index_wt) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(by_time_index_wt) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue272 = true; _foreach_continue272 && !boost::foreach_detail_::rdone( _foreach_cur272 , _foreach_end272 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_wt, boost::foreach_detail_::is_const_(by_time_index_wt)))); _foreach_continue272 ? boost::foreach_detail_::rnext( _foreach_cur272 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_wt, boost::foreach_detail_::is_const_(by_time_index_wt)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue272)) {} else for (const peers_indexed::value_type& vl = boost::foreach_detail_::rderef( _foreach_cur272 , (true ? 0 : boost::foreach_detail_::encode_type(by_time_index_wt, boost::foreach_detail_::is_const_(by_time_index_wt)))); !_foreach_continue272; _foreach_continue272 = true) > { > pl_white.push_back(vl); > } > > return true; > } > > inline > bool peerlist_manager::set_peer_just_seen(peerid_type peer, uint32_t ip, uint32_t port) > { > net_address addr; > addr.ip = ip; > addr.port = port; > return set_peer_just_seen(peer, addr); > } > > inline > bool peerlist_manager::set_peer_just_seen(peerid_type peer, const net_address& addr) > { > try {; > epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); > > peerlist_entry ple; > ple.adr = addr; > ple.id = peer; > ple.last_seen = time(__null); > return append_with_peer_white(ple); > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_peerlist.h" << ":" << 300 << "|" << __FUNCTION__ << "|" << "Exception at [" << "peerlist_manager::set_peer_just_seen()" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_peerlist.h" << ":" << 300 << "|" << __FUNCTION__ << "|" << "Exception at [" << "peerlist_manager::set_peer_just_seen()" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > inline > bool peerlist_manager::append_with_peer_white(const peerlist_entry& ple) > { > try {; > if(!is_ip_allowed(ple.adr.ip)) > return true; > > epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); > > auto by_addr_it_wt = m_peers_white.get<by_addr>().find(ple.adr); > if(by_addr_it_wt == m_peers_white.get<by_addr>().end()) > { > > m_peers_white.insert(ple); > trim_white_peerlist(); > }else > { > > m_peers_white.replace(by_addr_it_wt, ple); > } > > auto by_addr_it_gr = m_peers_gray.get<by_addr>().find(ple.adr); > if(by_addr_it_gr != m_peers_gray.get<by_addr>().end()) > { > m_peers_gray.erase(by_addr_it_gr); > } > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_peerlist.h" << ":" << 330 << "|" << __FUNCTION__ << "|" << "Exception at [" << "peerlist_manager::append_with_peer_white()" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_peerlist.h" << ":" << 330 << "|" << __FUNCTION__ << "|" << "Exception at [" << "peerlist_manager::append_with_peer_white()" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > } > > inline > bool peerlist_manager::append_with_peer_gray(const peerlist_entry& ple) > { > try {; > if(!is_ip_allowed(ple.adr.ip)) > return true; > > epee::critical_region_t<decltype(m_peerlist_lock)> critical_region_var(m_peerlist_lock); > > auto by_addr_it_wt = m_peers_white.get<by_addr>().find(ple.adr); > if(by_addr_it_wt != m_peers_white.get<by_addr>().end()) > return true; > > > auto by_addr_it_gr = m_peers_gray.get<by_addr>().find(ple.adr); > if(by_addr_it_gr == m_peers_gray.get<by_addr>().end()) > { > > m_peers_gray.insert(ple); > trim_gray_peerlist(); > }else > { > > m_peers_gray.replace(by_addr_it_gr, ple); > } > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_peerlist.h" << ":" << 359 << "|" << __FUNCTION__ << "|" << "Exception at [" << "peerlist_manager::append_with_peer_gray()" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_peerlist.h" << ":" << 359 << "|" << __FUNCTION__ << "|" << "Exception at [" << "peerlist_manager::append_with_peer_gray()" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > return true; > } > >} > >namespace boost { namespace serialization { template<> struct version<nodetool::peerlist_manager > { typedef mpl::int_<6> type; typedef mpl::integral_c_tag tag; static const int value = version::type::value; enum { mpl_assertion_in_line_365 = sizeof( boost::mpl::assertion_failed<false>( boost::mpl::assert_arg( (void (*) ( boost::mpl::less< boost::mpl::int_<6>, boost::mpl::int_<256> > ))0, 1 ) ) ) }; }; } } ># 24 "/c/honeypenny/src/p2p/net_node.h" 2 ># 1 "/c/honeypenny/src/p2p/p2p_networks.h" 1 > > > > > > >namespace nodetool >{ > > > > const static boost::uuids::uuid P2P_NETWORK_ID = { { 0x11 ,0x10, 0x01, 0x11 , 0x01, 0x00 , 0x01, 0x01, 0x10, 0x11, 0x02, 0x10, 0x11, 0x11, 0x01, 0x10} }; > >} ># 25 "/c/honeypenny/src/p2p/net_node.h" 2 > > ># 1 "/c/honeypenny/src/p2p/maintainers_info_boost_serialization.h" 1 > > > > > > ># 1 "/c/honeypenny/src/common/crypto_boost_serialization.h" 1 > > > > > > ># 1 "/usr/include/boost/serialization/vector.hpp" 1 3 4 ># 30 "/usr/include/boost/serialization/vector.hpp" 3 4 ># 1 "/usr/include/boost/serialization/detail/get_data.hpp" 1 3 4 ># 23 "/usr/include/boost/serialization/detail/get_data.hpp" 3 4 ># 1 "/usr/include/c++/4.9.0/valarray" 1 3 4 ># 34 "/usr/include/c++/4.9.0/valarray" 3 4 ># 35 "/usr/include/c++/4.9.0/valarray" 3 > > ># 1 "/usr/include/c++/4.9.0/cmath" 1 3 ># 39 "/usr/include/c++/4.9.0/cmath" 3 ># 40 "/usr/include/c++/4.9.0/cmath" 3 ># 38 "/usr/include/c++/4.9.0/valarray" 2 3 > > > > > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<class _Clos, typename _Tp> > class _Expr; > > template<typename _Tp1, typename _Tp2> > class _ValArray; > > template<class _Oper, template<class, class> class _Meta, class _Dom> > struct _UnClos; > > template<class _Oper, > template<class, class> class _Meta1, > template<class, class> class _Meta2, > class _Dom1, class _Dom2> > class _BinClos; > > template<template<class, class> class _Meta, class _Dom> > class _SClos; > > template<template<class, class> class _Meta, class _Dom> > class _GClos; > > template<template<class, class> class _Meta, class _Dom> > class _IClos; > > template<template<class, class> class _Meta, class _Dom> > class _ValFunClos; > > template<template<class, class> class _Meta, class _Dom> > class _RefFunClos; > > template<class _Tp> class valarray; > class slice; > template<class _Tp> class slice_array; > class gslice; > template<class _Tp> class gslice_array; > template<class _Tp> class mask_array; > template<class _Tp> class indirect_array; > > >} > ># 1 "/usr/include/c++/4.9.0/bits/valarray_array.h" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/valarray_array.h" 3 ># 36 "/usr/include/c++/4.9.0/bits/valarray_array.h" 3 > > > ># 1 "/usr/include/c++/4.9.0/cstdlib" 1 3 ># 39 "/usr/include/c++/4.9.0/cstdlib" 3 ># 40 "/usr/include/c++/4.9.0/cstdlib" 3 ># 40 "/usr/include/c++/4.9.0/bits/valarray_array.h" 2 3 > > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > > inline void* > __valarray_get_memory(size_t __n) > { return operator new(__n); } > > template<typename _Tp> > inline _Tp*__restrict__ > __valarray_get_storage(size_t __n) > { > return static_cast<_Tp*__restrict__> > (std::__valarray_get_memory(__n * sizeof(_Tp))); > } > > > inline void > __valarray_release_memory(void* __p) > { operator delete(__p); } > > > > template<typename _Tp, bool> > struct _Array_default_ctor > { > > > inline static void > _S_do_it(_Tp* __b, _Tp* __e) > { > while (__b != __e) > new(__b++) _Tp(); > } > }; > > template<typename _Tp> > struct _Array_default_ctor<_Tp, true> > { > > inline static void > _S_do_it(_Tp* __b, _Tp* __e) > { __builtin_memset(__b, 0, (__e - __b) * sizeof(_Tp)); } > }; > > template<typename _Tp> > inline void > __valarray_default_construct(_Tp* __b, _Tp* __e) > { > _Array_default_ctor<_Tp, __is_scalar<_Tp>::__value>::_S_do_it(__b, __e); > } > > > > > template<typename _Tp, bool> > struct _Array_init_ctor > { > > > inline static void > _S_do_it(_Tp* __b, _Tp* __e, const _Tp __t) > { > while (__b != __e) > new(__b++) _Tp(__t); > } > }; > > template<typename _Tp> > struct _Array_init_ctor<_Tp, true> > { > inline static void > _S_do_it(_Tp* __b, _Tp* __e, const _Tp __t) > { > while (__b != __e) > *__b++ = __t; > } > }; > > template<typename _Tp> > inline void > __valarray_fill_construct(_Tp* __b, _Tp* __e, const _Tp __t) > { > _Array_init_ctor<_Tp, __is_trivial(_Tp)>::_S_do_it(__b, __e, __t); > } > > > > > > template<typename _Tp, bool> > struct _Array_copy_ctor > { > > > inline static void > _S_do_it(const _Tp* __b, const _Tp* __e, _Tp* __restrict__ __o) > { > while (__b != __e) > new(__o++) _Tp(*__b++); > } > }; > > template<typename _Tp> > struct _Array_copy_ctor<_Tp, true> > { > inline static void > _S_do_it(const _Tp* __b, const _Tp* __e, _Tp* __restrict__ __o) > { __builtin_memcpy(__o, __b, (__e - __b) * sizeof(_Tp)); } > }; > > template<typename _Tp> > inline void > __valarray_copy_construct(const _Tp* __b, const _Tp* __e, > _Tp* __restrict__ __o) > { > _Array_copy_ctor<_Tp, __is_trivial(_Tp)>::_S_do_it(__b, __e, __o); > } > > > template<typename _Tp> > inline void > __valarray_copy_construct (const _Tp* __restrict__ __a, size_t __n, > size_t __s, _Tp* __restrict__ __o) > { > if (__is_trivial(_Tp)) > while (__n--) > { > *__o++ = *__a; > __a += __s; > } > else > while (__n--) > { > new(__o++) _Tp(*__a); > __a += __s; > } > } > > > template<typename _Tp> > inline void > __valarray_copy_construct (const _Tp* __restrict__ __a, > const size_t* __restrict__ __i, > _Tp* __restrict__ __o, size_t __n) > { > if (__is_trivial(_Tp)) > while (__n--) > *__o++ = __a[*__i++]; > else > while (__n--) > new (__o++) _Tp(__a[*__i++]); > } > > > template<typename _Tp> > inline void > __valarray_destroy_elements(_Tp* __b, _Tp* __e) > { > if (!__is_trivial(_Tp)) > while (__b != __e) > { > __b->~_Tp(); > ++__b; > } > } > > > template<typename _Tp> > inline void > __valarray_fill(_Tp* __restrict__ __a, size_t __n, const _Tp& __t) > { > while (__n--) > *__a++ = __t; > } > > > template<typename _Tp> > inline void > __valarray_fill(_Tp* __restrict__ __a, size_t __n, > size_t __s, const _Tp& __t) > { > for (size_t __i = 0; __i < __n; ++__i, __a += __s) > *__a = __t; > } > > > template<typename _Tp> > inline void > __valarray_fill(_Tp* __restrict__ __a, const size_t* __restrict__ __i, > size_t __n, const _Tp& __t) > { > for (size_t __j = 0; __j < __n; ++__j, ++__i) > __a[*__i] = __t; > } > > > > template<typename _Tp, bool> > struct _Array_copier > { > inline static void > _S_do_it(const _Tp* __restrict__ __a, size_t __n, _Tp* __restrict__ __b) > { > while(__n--) > *__b++ = *__a++; > } > }; > > template<typename _Tp> > struct _Array_copier<_Tp, true> > { > inline static void > _S_do_it(const _Tp* __restrict__ __a, size_t __n, _Tp* __restrict__ __b) > { __builtin_memcpy(__b, __a, __n * sizeof (_Tp)); } > }; > > > template<typename _Tp> > inline void > __valarray_copy(const _Tp* __restrict__ __a, size_t __n, > _Tp* __restrict__ __b) > { > _Array_copier<_Tp, __is_trivial(_Tp)>::_S_do_it(__a, __n, __b); > } > > > template<typename _Tp> > inline void > __valarray_copy(const _Tp* __restrict__ __a, size_t __n, size_t __s, > _Tp* __restrict__ __b) > { > for (size_t __i = 0; __i < __n; ++__i, ++__b, __a += __s) > *__b = *__a; > } > > > template<typename _Tp> > inline void > __valarray_copy(const _Tp* __restrict__ __a, _Tp* __restrict__ __b, > size_t __n, size_t __s) > { > for (size_t __i = 0; __i < __n; ++__i, ++__a, __b += __s) > *__b = *__a; > } > > > > template<typename _Tp> > inline void > __valarray_copy(const _Tp* __restrict__ __src, size_t __n, size_t __s1, > _Tp* __restrict__ __dst, size_t __s2) > { > for (size_t __i = 0; __i < __n; ++__i) > __dst[__i * __s2] = __src[__i * __s1]; > } > > > template<typename _Tp> > inline void > __valarray_copy(const _Tp* __restrict__ __a, > const size_t* __restrict__ __i, > _Tp* __restrict__ __b, size_t __n) > { > for (size_t __j = 0; __j < __n; ++__j, ++__b, ++__i) > *__b = __a[*__i]; > } > > > template<typename _Tp> > inline void > __valarray_copy(const _Tp* __restrict__ __a, size_t __n, > _Tp* __restrict__ __b, const size_t* __restrict__ __i) > { > for (size_t __j = 0; __j < __n; ++__j, ++__a, ++__i) > __b[*__i] = *__a; > } > > > > template<typename _Tp> > inline void > __valarray_copy(const _Tp* __restrict__ __src, size_t __n, > const size_t* __restrict__ __i, > _Tp* __restrict__ __dst, const size_t* __restrict__ __j) > { > for (size_t __k = 0; __k < __n; ++__k) > __dst[*__j++] = __src[*__i++]; > } ># 344 "/usr/include/c++/4.9.0/bits/valarray_array.h" 3 > template<typename _Tp> > inline _Tp > __valarray_sum(const _Tp* __f, const _Tp* __l) > { > _Tp __r = _Tp(); > while (__f != __l) > __r += *__f++; > return __r; > } > > > template<typename _Tp> > inline _Tp > __valarray_product(const _Tp* __f, const _Tp* __l) > { > _Tp __r = _Tp(1); > while (__f != __l) > __r = __r * *__f++; > return __r; > } > > > template<typename _Ta> > inline typename _Ta::value_type > __valarray_min(const _Ta& __a) > { > size_t __s = __a.size(); > typedef typename _Ta::value_type _Value_type; > _Value_type __r = __s == 0 ? _Value_type() : __a[0]; > for (size_t __i = 1; __i < __s; ++__i) > { > _Value_type __t = __a[__i]; > if (__t < __r) > __r = __t; > } > return __r; > } > > template<typename _Ta> > inline typename _Ta::value_type > __valarray_max(const _Ta& __a) > { > size_t __s = __a.size(); > typedef typename _Ta::value_type _Value_type; > _Value_type __r = __s == 0 ? _Value_type() : __a[0]; > for (size_t __i = 1; __i < __s; ++__i) > { > _Value_type __t = __a[__i]; > if (__t > __r) > __r = __t; > } > return __r; > } > > > > > > > > template<typename _Tp> > struct _Array > { > explicit _Array(size_t); > explicit _Array(_Tp* const __restrict__); > explicit _Array(const valarray<_Tp>&); > _Array(const _Tp* __restrict__, size_t); > > _Tp* begin() const; > > _Tp* const __restrict__ _M_data; > }; > > > > template<typename _Tp> > inline void > __valarray_copy_construct(_Array<_Tp> __a, _Array<size_t> __i, > _Array<_Tp> __b, size_t __n) > { std::__valarray_copy_construct(__a._M_data, __i._M_data, > __b._M_data, __n); } > > > template<typename _Tp> > inline void > __valarray_copy_construct(_Array<_Tp> __a, size_t __n, size_t __s, > _Array<_Tp> __b) > { std::__valarray_copy_construct(__a._M_data, __n, __s, __b._M_data); } > > template<typename _Tp> > inline void > __valarray_fill (_Array<_Tp> __a, size_t __n, const _Tp& __t) > { std::__valarray_fill(__a._M_data, __n, __t); } > > template<typename _Tp> > inline void > __valarray_fill(_Array<_Tp> __a, size_t __n, size_t __s, const _Tp& __t) > { std::__valarray_fill(__a._M_data, __n, __s, __t); } > > template<typename _Tp> > inline void > __valarray_fill(_Array<_Tp> __a, _Array<size_t> __i, > size_t __n, const _Tp& __t) > { std::__valarray_fill(__a._M_data, __i._M_data, __n, __t); } > > > template<typename _Tp> > inline void > __valarray_copy(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) > { std::__valarray_copy(__a._M_data, __n, __b._M_data); } > > > template<typename _Tp> > inline void > __valarray_copy(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) > { std::__valarray_copy(__a._M_data, __n, __s, __b._M_data); } > > > template<typename _Tp> > inline void > __valarray_copy(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) > { __valarray_copy(__a._M_data, __b._M_data, __n, __s); } > > > > template<typename _Tp> > inline void > __valarray_copy(_Array<_Tp> __a, size_t __n, size_t __s1, > _Array<_Tp> __b, size_t __s2) > { std::__valarray_copy(__a._M_data, __n, __s1, __b._M_data, __s2); } > > > template<typename _Tp> > inline void > __valarray_copy(_Array<_Tp> __a, _Array<size_t> __i, > _Array<_Tp> __b, size_t __n) > { std::__valarray_copy(__a._M_data, __i._M_data, __b._M_data, __n); } > > > template<typename _Tp> > inline void > __valarray_copy(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, > _Array<size_t> __i) > { std::__valarray_copy(__a._M_data, __n, __b._M_data, __i._M_data); } > > > > template<typename _Tp> > inline void > __valarray_copy(_Array<_Tp> __src, size_t __n, _Array<size_t> __i, > _Array<_Tp> __dst, _Array<size_t> __j) > { > std::__valarray_copy(__src._M_data, __n, __i._M_data, > __dst._M_data, __j._M_data); > } > > template<typename _Tp> > inline > _Array<_Tp>::_Array(size_t __n) > : _M_data(__valarray_get_storage<_Tp>(__n)) > { std::__valarray_default_construct(_M_data, _M_data + __n); } > > template<typename _Tp> > inline > _Array<_Tp>::_Array(_Tp* const __restrict__ __p) > : _M_data (__p) {} > > template<typename _Tp> > inline > _Array<_Tp>::_Array(const valarray<_Tp>& __v) > : _M_data (__v._M_data) {} > > template<typename _Tp> > inline > _Array<_Tp>::_Array(const _Tp* __restrict__ __b, size_t __s) > : _M_data(__valarray_get_storage<_Tp>(__s)) > { std::__valarray_copy_construct(__b, __s, _M_data); } > > template<typename _Tp> > inline _Tp* > _Array<_Tp>::begin () const > { return _M_data; } ># 675 "/usr/include/c++/4.9.0/bits/valarray_array.h" 3 > template<typename _Tp> inline void _Array_augmented___plus(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p += __t; } template<typename _Tp> inline void _Array_augmented___plus(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p += *__q; } template<typename _Tp, class _Dom> void _Array_augmented___plus(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p += __e[__i]; } template<typename _Tp> inline void _Array_augmented___plus(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p += *__q; } template<typename _Tp> inline void _Array_augmented___plus(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p += *__q; } template<typename _Tp, class _Dom> void _Array_augmented___plus(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p += __e[__i]; } template<typename _Tp> inline void _Array_augmented___plus(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] += *__q; } template<typename _Tp> inline void _Array_augmented___plus(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p += __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___plus(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] += __e[__k]; } template<typename _Tp> void _Array_augmented___plus(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p += *__q; } } template<typename _Tp> void _Array_augmented___plus(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p += *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___plus(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p += __e[__i]; } } > template<typename _Tp> inline void _Array_augmented___minus(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p -= __t; } template<typename _Tp> inline void _Array_augmented___minus(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p -= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___minus(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p -= __e[__i]; } template<typename _Tp> inline void _Array_augmented___minus(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p -= *__q; } template<typename _Tp> inline void _Array_augmented___minus(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p -= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___minus(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p -= __e[__i]; } template<typename _Tp> inline void _Array_augmented___minus(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] -= *__q; } template<typename _Tp> inline void _Array_augmented___minus(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p -= __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___minus(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] -= __e[__k]; } template<typename _Tp> void _Array_augmented___minus(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p -= *__q; } } template<typename _Tp> void _Array_augmented___minus(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p -= *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___minus(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p -= __e[__i]; } } > template<typename _Tp> inline void _Array_augmented___multiplies(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p *= __t; } template<typename _Tp> inline void _Array_augmented___multiplies(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p *= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___multiplies(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p *= __e[__i]; } template<typename _Tp> inline void _Array_augmented___multiplies(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p *= *__q; } template<typename _Tp> inline void _Array_augmented___multiplies(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p *= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___multiplies(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p *= __e[__i]; } template<typename _Tp> inline void _Array_augmented___multiplies(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] *= *__q; } template<typename _Tp> inline void _Array_augmented___multiplies(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p *= __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___multiplies(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] *= __e[__k]; } template<typename _Tp> void _Array_augmented___multiplies(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p *= *__q; } } template<typename _Tp> void _Array_augmented___multiplies(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p *= *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___multiplies(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p *= __e[__i]; } } > template<typename _Tp> inline void _Array_augmented___divides(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p /= __t; } template<typename _Tp> inline void _Array_augmented___divides(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p /= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___divides(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p /= __e[__i]; } template<typename _Tp> inline void _Array_augmented___divides(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p /= *__q; } template<typename _Tp> inline void _Array_augmented___divides(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p /= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___divides(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p /= __e[__i]; } template<typename _Tp> inline void _Array_augmented___divides(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] /= *__q; } template<typename _Tp> inline void _Array_augmented___divides(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p /= __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___divides(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] /= __e[__k]; } template<typename _Tp> void _Array_augmented___divides(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p /= *__q; } } template<typename _Tp> void _Array_augmented___divides(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p /= *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___divides(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p /= __e[__i]; } } > template<typename _Tp> inline void _Array_augmented___modulus(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p %= __t; } template<typename _Tp> inline void _Array_augmented___modulus(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p %= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___modulus(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p %= __e[__i]; } template<typename _Tp> inline void _Array_augmented___modulus(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p %= *__q; } template<typename _Tp> inline void _Array_augmented___modulus(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p %= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___modulus(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p %= __e[__i]; } template<typename _Tp> inline void _Array_augmented___modulus(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] %= *__q; } template<typename _Tp> inline void _Array_augmented___modulus(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p %= __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___modulus(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] %= __e[__k]; } template<typename _Tp> void _Array_augmented___modulus(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p %= *__q; } } template<typename _Tp> void _Array_augmented___modulus(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p %= *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___modulus(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p %= __e[__i]; } } > template<typename _Tp> inline void _Array_augmented___bitwise_xor(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p ^= __t; } template<typename _Tp> inline void _Array_augmented___bitwise_xor(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p ^= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_xor(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p ^= __e[__i]; } template<typename _Tp> inline void _Array_augmented___bitwise_xor(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p ^= *__q; } template<typename _Tp> inline void _Array_augmented___bitwise_xor(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p ^= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_xor(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p ^= __e[__i]; } template<typename _Tp> inline void _Array_augmented___bitwise_xor(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] ^= *__q; } template<typename _Tp> inline void _Array_augmented___bitwise_xor(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p ^= __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_xor(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] ^= __e[__k]; } template<typename _Tp> void _Array_augmented___bitwise_xor(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p ^= *__q; } } template<typename _Tp> void _Array_augmented___bitwise_xor(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p ^= *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_xor(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p ^= __e[__i]; } } > template<typename _Tp> inline void _Array_augmented___bitwise_or(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p |= __t; } template<typename _Tp> inline void _Array_augmented___bitwise_or(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p |= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_or(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p |= __e[__i]; } template<typename _Tp> inline void _Array_augmented___bitwise_or(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p |= *__q; } template<typename _Tp> inline void _Array_augmented___bitwise_or(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p |= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_or(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p |= __e[__i]; } template<typename _Tp> inline void _Array_augmented___bitwise_or(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] |= *__q; } template<typename _Tp> inline void _Array_augmented___bitwise_or(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p |= __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_or(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] |= __e[__k]; } template<typename _Tp> void _Array_augmented___bitwise_or(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p |= *__q; } } template<typename _Tp> void _Array_augmented___bitwise_or(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p |= *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_or(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p |= __e[__i]; } } > template<typename _Tp> inline void _Array_augmented___bitwise_and(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p &= __t; } template<typename _Tp> inline void _Array_augmented___bitwise_and(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p &= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_and(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p &= __e[__i]; } template<typename _Tp> inline void _Array_augmented___bitwise_and(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p &= *__q; } template<typename _Tp> inline void _Array_augmented___bitwise_and(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p &= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_and(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p &= __e[__i]; } template<typename _Tp> inline void _Array_augmented___bitwise_and(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] &= *__q; } template<typename _Tp> inline void _Array_augmented___bitwise_and(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p &= __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_and(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] &= __e[__k]; } template<typename _Tp> void _Array_augmented___bitwise_and(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p &= *__q; } } template<typename _Tp> void _Array_augmented___bitwise_and(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p &= *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___bitwise_and(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p &= __e[__i]; } } > template<typename _Tp> inline void _Array_augmented___shift_left(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p <<= __t; } template<typename _Tp> inline void _Array_augmented___shift_left(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p <<= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___shift_left(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p <<= __e[__i]; } template<typename _Tp> inline void _Array_augmented___shift_left(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p <<= *__q; } template<typename _Tp> inline void _Array_augmented___shift_left(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p <<= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___shift_left(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p <<= __e[__i]; } template<typename _Tp> inline void _Array_augmented___shift_left(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] <<= *__q; } template<typename _Tp> inline void _Array_augmented___shift_left(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p <<= __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___shift_left(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] <<= __e[__k]; } template<typename _Tp> void _Array_augmented___shift_left(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p <<= *__q; } } template<typename _Tp> void _Array_augmented___shift_left(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p <<= *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___shift_left(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p <<= __e[__i]; } } > template<typename _Tp> inline void _Array_augmented___shift_right(_Array<_Tp> __a, size_t __n, const _Tp& __t) { for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p) *__p >>= __t; } template<typename _Tp> inline void _Array_augmented___shift_right(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b) { _Tp* __p = __a._M_data; for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__p, ++__q) *__p >>= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___shift_right(_Array<_Tp> __a, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__p) *__p >>= __e[__i]; } template<typename _Tp> inline void _Array_augmented___shift_right(_Array<_Tp> __a, size_t __n, size_t __s, _Array<_Tp> __b) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __s * __n; __p += __s, ++__q) *__p >>= *__q; } template<typename _Tp> inline void _Array_augmented___shift_right(_Array<_Tp> __a, _Array<_Tp> __b, size_t __n, size_t __s) { _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, __q += __s) *__p >>= *__q; } template<typename _Tp, class _Dom> void _Array_augmented___shift_right(_Array<_Tp> __a, size_t __s, const _Expr<_Dom, _Tp>& __e, size_t __n) { _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, __p += __s) *__p >>= __e[__i]; } template<typename _Tp> inline void _Array_augmented___shift_right(_Array<_Tp> __a, _Array<size_t> __i, _Array<_Tp> __b, size_t __n) { _Tp* __q(__b._M_data); for (size_t* __j = __i._M_data; __j < __i._M_data + __n; ++__j, ++__q) __a._M_data[*__j] >>= *__q; } template<typename _Tp> inline void _Array_augmented___shift_right(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<size_t> __i) { _Tp* __p(__a._M_data); for (size_t* __j = __i._M_data; __j<__i._M_data + __n; ++__j, ++__p) *__p >>= __b._M_data[*__j]; } template<typename _Tp, class _Dom> void _Array_augmented___shift_right(_Array<_Tp> __a, _Array<size_t> __i, const _Expr<_Dom, _Tp>& __e, size_t __n) { size_t* __j(__i._M_data); for (size_t __k = 0; __k<__n; ++__k, ++__j) __a._M_data[*__j] >>= __e[__k]; } template<typename _Tp> void _Array_augmented___shift_right(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; ++__q, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p >>= *__q; } } template<typename _Tp> void _Array_augmented___shift_right(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, _Array<bool> __m) { bool* __ok(__m._M_data); _Tp* __q(__b._M_data); for (_Tp* __p = __a._M_data; __p < __a._M_data + __n; ++__p, ++__ok, ++__q) { while (! *__ok) { ++__ok; ++__q; } *__p >>= *__q; } } template<typename _Tp, class _Dom> void _Array_augmented___shift_right(_Array<_Tp> __a, _Array<bool> __m, const _Expr<_Dom, _Tp>& __e, size_t __n) { bool* __ok(__m._M_data); _Tp* __p(__a._M_data); for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) { while (! *__ok) { ++__ok; ++__p; } *__p >>= __e[__i]; } } > > > > >} > ># 1 "/usr/include/c++/4.9.0/bits/valarray_array.tcc" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/valarray_array.tcc" 3 >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > template<typename _Tp> > void > __valarray_fill(_Array<_Tp> __a, size_t __n, _Array<bool> __m, > const _Tp& __t) > { > _Tp* __p = __a._M_data; > bool* __ok (__m._M_data); > for (size_t __i=0; __i < __n; ++__i, ++__ok, ++__p) > { > while (!*__ok) > { > ++__ok; > ++__p; > } > *__p = __t; > } > } > > > > > > > > template<typename _Tp> > void > __valarray_copy(_Array<_Tp> __a, _Array<bool> __m, _Array<_Tp> __b, > size_t __n) > { > _Tp* __p (__a._M_data); > bool* __ok (__m._M_data); > for (_Tp* __q = __b._M_data; __q < __b._M_data + __n; > ++__q, ++__ok, ++__p) > { > while (! *__ok) > { > ++__ok; > ++__p; > } > *__q = *__p; > } > } > > > > > > > > template<typename _Tp> > void > __valarray_copy(_Array<_Tp> __a, size_t __n, _Array<_Tp> __b, > _Array<bool> __m) > { > _Tp* __q (__b._M_data); > bool* __ok (__m._M_data); > for (_Tp* __p = __a._M_data; __p < __a._M_data+__n; > ++__p, ++__ok, ++__q) > { > while (! *__ok) > { > ++__ok; > ++__q; > } > *__q = *__p; > } > } > > > > > > > template<typename _Tp> > void > __valarray_copy(_Array<_Tp> __a, _Array<bool> __m, size_t __n, > _Array<_Tp> __b, _Array<bool> __k) > { > _Tp* __p (__a._M_data); > _Tp* __q (__b._M_data); > bool* __srcok (__m._M_data); > bool* __dstok (__k._M_data); > for (size_t __i = 0; __i < __n; > ++__srcok, ++__p, ++__dstok, ++__q, ++__i) > { > while (! *__srcok) > { > ++__srcok; > ++__p; > } > while (! *__dstok) > { > ++__dstok; > ++__q; > } > *__q = *__p; > } > } > > > > template<typename _Tp, class _Dom> > void > __valarray_copy(const _Expr<_Dom, _Tp>& __e, size_t __n, _Array<_Tp> __a) > { > _Tp* __p (__a._M_data); > for (size_t __i = 0; __i < __n; ++__i, ++__p) > *__p = __e[__i]; > } > > > > template<typename _Tp, class _Dom> > void > __valarray_copy(const _Expr<_Dom, _Tp>& __e, size_t __n, > _Array<_Tp> __a, size_t __s) > { > _Tp* __p (__a._M_data); > for (size_t __i = 0; __i < __n; ++__i, __p += __s) > *__p = __e[__i]; > } > > > > template<typename _Tp, class _Dom> > void > __valarray_copy(const _Expr<_Dom, _Tp>& __e, size_t __n, > _Array<_Tp> __a, _Array<size_t> __i) > { > size_t* __j (__i._M_data); > for (size_t __k = 0; __k < __n; ++__k, ++__j) > __a._M_data[*__j] = __e[__k]; > } > > > > template<typename _Tp> > void > __valarray_copy(_Array<_Tp> __e, _Array<size_t> __f, > size_t __n, > _Array<_Tp> __a, _Array<size_t> __i) > { > size_t* __g (__f._M_data); > size_t* __j (__i._M_data); > for (size_t __k = 0; __k < __n; ++__k, ++__j, ++__g) > __a._M_data[*__j] = __e._M_data[*__g]; > } > > > > > > > > template<typename _Tp, class _Dom> > void > __valarray_copy(const _Expr<_Dom, _Tp>& __e, size_t __n, > _Array<_Tp> __a, _Array<bool> __m) > { > bool* __ok (__m._M_data); > _Tp* __p (__a._M_data); > for (size_t __i = 0; __i < __n; ++__i, ++__ok, ++__p) > { > while (! *__ok) > { > ++__ok; > ++__p; > } > *__p = __e[__i]; > } > } > > > template<typename _Tp, class _Dom> > void > __valarray_copy_construct(const _Expr<_Dom, _Tp>& __e, size_t __n, > _Array<_Tp> __a) > { > _Tp* __p (__a._M_data); > for (size_t __i = 0; __i < __n; ++__i, ++__p) > new (__p) _Tp(__e[__i]); > } > > > template<typename _Tp> > void > __valarray_copy_construct(_Array<_Tp> __a, _Array<bool> __m, > _Array<_Tp> __b, size_t __n) > { > _Tp* __p (__a._M_data); > bool* __ok (__m._M_data); > for (_Tp* __q = __b._M_data; __q < __b._M_data+__n; ++__q, ++__ok, ++__p) > { > while (! *__ok) > { > ++__ok; > ++__p; > } > new (__q) _Tp(*__p); > } > } > > >} ># 692 "/usr/include/c++/4.9.0/bits/valarray_array.h" 2 3 ># 90 "/usr/include/c++/4.9.0/valarray" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/valarray_before.h" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/valarray_before.h" 3 ># 36 "/usr/include/c++/4.9.0/bits/valarray_before.h" 3 > ># 1 "/usr/include/c++/4.9.0/bits/slice_array.h" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/slice_array.h" 3 ># 36 "/usr/include/c++/4.9.0/bits/slice_array.h" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 59 "/usr/include/c++/4.9.0/bits/slice_array.h" 3 > class slice > { > public: > > slice(); ># 72 "/usr/include/c++/4.9.0/bits/slice_array.h" 3 > slice(size_t __o, size_t __d, size_t __s); > > > size_t start() const; > > size_t size() const; > > size_t stride() const; > > private: > size_t _M_off; > size_t _M_sz; > size_t _M_st; > }; > > > > inline > slice::slice() > : _M_off(0), _M_sz(0), _M_st(0) {} > > inline > slice::slice(size_t __o, size_t __d, size_t __s) > : _M_off(__o), _M_sz(__d), _M_st(__s) {} > > inline size_t > slice::start() const > { return _M_off; } > > inline size_t > slice::size() const > { return _M_sz; } > > inline size_t > slice::stride() const > { return _M_st; } ># 122 "/usr/include/c++/4.9.0/bits/slice_array.h" 3 > template<typename _Tp> > class slice_array > { > public: > typedef _Tp value_type; > > > > > > slice_array(const slice_array&); > > > > slice_array& operator=(const slice_array&); > > > void operator=(const valarray<_Tp>&) const; > > void operator*=(const valarray<_Tp>&) const; > > void operator/=(const valarray<_Tp>&) const; > > void operator%=(const valarray<_Tp>&) const; > > void operator+=(const valarray<_Tp>&) const; > > void operator-=(const valarray<_Tp>&) const; > > void operator^=(const valarray<_Tp>&) const; > > void operator&=(const valarray<_Tp>&) const; > > void operator|=(const valarray<_Tp>&) const; > > void operator<<=(const valarray<_Tp>&) const; > > void operator>>=(const valarray<_Tp>&) const; > > void operator=(const _Tp &) const; > > > template<class _Dom> > void operator=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator*=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator/=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator%=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator+=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator-=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator^=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator&=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator|=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator<<=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator>>=(const _Expr<_Dom, _Tp>&) const; > > private: > friend class valarray<_Tp>; > slice_array(_Array<_Tp>, const slice&); > > const size_t _M_sz; > const size_t _M_stride; > const _Array<_Tp> _M_array; > > > slice_array(); > }; > > template<typename _Tp> > inline > slice_array<_Tp>::slice_array(_Array<_Tp> __a, const slice& __s) > : _M_sz(__s.size()), _M_stride(__s.stride()), > _M_array(__a.begin() + __s.start()) {} > > template<typename _Tp> > inline > slice_array<_Tp>::slice_array(const slice_array<_Tp>& a) > : _M_sz(a._M_sz), _M_stride(a._M_stride), _M_array(a._M_array) {} > > > > > template<typename _Tp> > inline slice_array<_Tp>& > slice_array<_Tp>::operator=(const slice_array<_Tp>& __a) > { > std::__valarray_copy(__a._M_array, __a._M_sz, __a._M_stride, > _M_array, _M_stride); > return *this; > } > > template<typename _Tp> > inline void > slice_array<_Tp>::operator=(const _Tp& __t) const > { std::__valarray_fill(_M_array, _M_sz, _M_stride, __t); } > > template<typename _Tp> > inline void > slice_array<_Tp>::operator=(const valarray<_Tp>& __v) const > { std::__valarray_copy(_Array<_Tp>(__v), _M_array, _M_sz, _M_stride); } > > template<typename _Tp> > template<class _Dom> > inline void > slice_array<_Tp>::operator=(const _Expr<_Dom,_Tp>& __e) const > { std::__valarray_copy(__e, _M_sz, _M_array, _M_stride); } ># 256 "/usr/include/c++/4.9.0/bits/slice_array.h" 3 >template<typename _Tp> inline void slice_array<_Tp>::operator *=(const valarray<_Tp>& __v) const { _Array_augmented___multiplies(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator *=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___multiplies(_M_array, _M_stride, __e, _M_sz); } >template<typename _Tp> inline void slice_array<_Tp>::operator /=(const valarray<_Tp>& __v) const { _Array_augmented___divides(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator /=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___divides(_M_array, _M_stride, __e, _M_sz); } >template<typename _Tp> inline void slice_array<_Tp>::operator %=(const valarray<_Tp>& __v) const { _Array_augmented___modulus(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator %=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___modulus(_M_array, _M_stride, __e, _M_sz); } >template<typename _Tp> inline void slice_array<_Tp>::operator +=(const valarray<_Tp>& __v) const { _Array_augmented___plus(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator +=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___plus(_M_array, _M_stride, __e, _M_sz); } >template<typename _Tp> inline void slice_array<_Tp>::operator -=(const valarray<_Tp>& __v) const { _Array_augmented___minus(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator -=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___minus(_M_array, _M_stride, __e, _M_sz); } >template<typename _Tp> inline void slice_array<_Tp>::operator ^=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_xor(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator ^=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___bitwise_xor(_M_array, _M_stride, __e, _M_sz); } >template<typename _Tp> inline void slice_array<_Tp>::operator &=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_and(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator &=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___bitwise_and(_M_array, _M_stride, __e, _M_sz); } >template<typename _Tp> inline void slice_array<_Tp>::operator |=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_or(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator |=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___bitwise_or(_M_array, _M_stride, __e, _M_sz); } >template<typename _Tp> inline void slice_array<_Tp>::operator <<=(const valarray<_Tp>& __v) const { _Array_augmented___shift_left(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator <<=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___shift_left(_M_array, _M_stride, __e, _M_sz); } >template<typename _Tp> inline void slice_array<_Tp>::operator >>=(const valarray<_Tp>& __v) const { _Array_augmented___shift_right(_M_array, _M_sz, _M_stride, _Array<_Tp>(__v)); } template<typename _Tp> template<class _Dom> inline void slice_array<_Tp>::operator >>=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___shift_right(_M_array, _M_stride, __e, _M_sz); } > > > > > > >} ># 38 "/usr/include/c++/4.9.0/bits/valarray_before.h" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 53 "/usr/include/c++/4.9.0/bits/valarray_before.h" 3 > template<typename _Tp1, typename _Tp2> class _Constant; ># 63 "/usr/include/c++/4.9.0/bits/valarray_before.h" 3 > struct _Abs > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return abs(__t); } > }; > > struct _Cos > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return cos(__t); } > }; > > struct _Acos > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return acos(__t); } > }; > > struct _Cosh > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return cosh(__t); } > }; > > struct _Sin > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return sin(__t); } > }; > > struct _Asin > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return asin(__t); } > }; > > struct _Sinh > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return sinh(__t); } > }; > > struct _Tan > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return tan(__t); } > }; > > struct _Atan > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return atan(__t); } > }; > > struct _Tanh > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return tanh(__t); } > }; > > struct _Exp > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return exp(__t); } > }; > > struct _Log > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return log(__t); } > }; > > struct _Log10 > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return log10(__t); } > }; > > struct _Sqrt > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return sqrt(__t); } > }; > > > > > > struct __unary_plus > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return +__t; } > }; > > struct __negate > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return -__t; } > }; > > struct __bitwise_not > { > template<typename _Tp> > _Tp operator()(const _Tp& __t) const > { return ~__t; } > }; > > struct __plus > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x + __y; } > }; > > struct __minus > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x - __y; } > }; > > struct __multiplies > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x * __y; } > }; > > struct __divides > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x / __y; } > }; > > struct __modulus > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x % __y; } > }; > > struct __bitwise_xor > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x ^ __y; } > }; > > struct __bitwise_and > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x & __y; } > }; > > struct __bitwise_or > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x | __y; } > }; > > struct __shift_left > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x << __y; } > }; > > struct __shift_right > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return __x >> __y; } > }; > > struct __logical_and > { > template<typename _Tp> > bool operator()(const _Tp& __x, const _Tp& __y) const > { return __x && __y; } > }; > > struct __logical_or > { > template<typename _Tp> > bool operator()(const _Tp& __x, const _Tp& __y) const > { return __x || __y; } > }; > > struct __logical_not > { > template<typename _Tp> > bool operator()(const _Tp& __x) const > { return !__x; } > }; > > struct __equal_to > { > template<typename _Tp> > bool operator()(const _Tp& __x, const _Tp& __y) const > { return __x == __y; } > }; > > struct __not_equal_to > { > template<typename _Tp> > bool operator()(const _Tp& __x, const _Tp& __y) const > { return __x != __y; } > }; > > struct __less > { > template<typename _Tp> > bool operator()(const _Tp& __x, const _Tp& __y) const > { return __x < __y; } > }; > > struct __greater > { > template<typename _Tp> > bool operator()(const _Tp& __x, const _Tp& __y) const > { return __x > __y; } > }; > > struct __less_equal > { > template<typename _Tp> > bool operator()(const _Tp& __x, const _Tp& __y) const > { return __x <= __y; } > }; > > struct __greater_equal > { > template<typename _Tp> > bool operator()(const _Tp& __x, const _Tp& __y) const > { return __x >= __y; } > }; > > > struct _Atan2 > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return atan2(__x, __y); } > }; > > struct _Pow > { > template<typename _Tp> > _Tp operator()(const _Tp& __x, const _Tp& __y) const > { return pow(__x, __y); } > }; > > > > > > template<typename, typename _Tp> > struct __fun > { > typedef _Tp result_type; > }; > > > template<typename _Tp> > struct __fun<__logical_not, _Tp> > { > typedef bool result_type; > }; > > template<typename _Tp> > struct __fun<__logical_and, _Tp> > { > typedef bool result_type; > }; > > template<typename _Tp> > struct __fun<__logical_or, _Tp> > { > typedef bool result_type; > }; > > template<typename _Tp> > struct __fun<__less, _Tp> > { > typedef bool result_type; > }; > > template<typename _Tp> > struct __fun<__greater, _Tp> > { > typedef bool result_type; > }; > > template<typename _Tp> > struct __fun<__less_equal, _Tp> > { > typedef bool result_type; > }; > > template<typename _Tp> > struct __fun<__greater_equal, _Tp> > { > typedef bool result_type; > }; > > template<typename _Tp> > struct __fun<__equal_to, _Tp> > { > typedef bool result_type; > }; > > template<typename _Tp> > struct __fun<__not_equal_to, _Tp> > { > typedef bool result_type; > }; > > > > > > template<typename _Dom, typename _Arg> > class _FunBase > { > public: > typedef typename _Dom::value_type value_type; > > _FunBase(const _Dom& __e, value_type __f(_Arg)) > : _M_expr(__e), _M_func(__f) {} > > value_type operator[](size_t __i) const > { return _M_func (_M_expr[__i]); } > > size_t size() const { return _M_expr.size ();} > > private: > const _Dom& _M_expr; > value_type (*_M_func)(_Arg); > }; > > template<class _Dom> > struct _ValFunClos<_Expr,_Dom> : _FunBase<_Dom, typename _Dom::value_type> > { > typedef _FunBase<_Dom, typename _Dom::value_type> _Base; > typedef typename _Base::value_type value_type; > typedef value_type _Tp; > > _ValFunClos(const _Dom& __e, _Tp __f(_Tp)) : _Base(__e, __f) {} > }; > > template<typename _Tp> > struct _ValFunClos<_ValArray,_Tp> : _FunBase<valarray<_Tp>, _Tp> > { > typedef _FunBase<valarray<_Tp>, _Tp> _Base; > typedef _Tp value_type; > > _ValFunClos(const valarray<_Tp>& __v, _Tp __f(_Tp)) : _Base(__v, __f) {} > }; > > template<class _Dom> > struct _RefFunClos<_Expr, _Dom> > : _FunBase<_Dom, const typename _Dom::value_type&> > { > typedef _FunBase<_Dom, const typename _Dom::value_type&> _Base; > typedef typename _Base::value_type value_type; > typedef value_type _Tp; > > _RefFunClos(const _Dom& __e, _Tp __f(const _Tp&)) > : _Base(__e, __f) {} > }; > > template<typename _Tp> > struct _RefFunClos<_ValArray, _Tp> > : _FunBase<valarray<_Tp>, const _Tp&> > { > typedef _FunBase<valarray<_Tp>, const _Tp&> _Base; > typedef _Tp value_type; > > _RefFunClos(const valarray<_Tp>& __v, _Tp __f(const _Tp&)) > : _Base(__v, __f) {} > }; > > > > > > template<class _Oper, class _Arg> > class _UnBase > { > public: > typedef typename _Arg::value_type _Vt; > typedef typename __fun<_Oper, _Vt>::result_type value_type; > > _UnBase(const _Arg& __e) : _M_expr(__e) {} > > value_type operator[](size_t __i) const > { return _Oper()(_M_expr[__i]); } > > size_t size() const { return _M_expr.size(); } > > private: > const _Arg& _M_expr; > }; > > template<class _Oper, class _Dom> > struct _UnClos<_Oper, _Expr, _Dom> > : _UnBase<_Oper, _Dom> > { > typedef _Dom _Arg; > typedef _UnBase<_Oper, _Dom> _Base; > typedef typename _Base::value_type value_type; > > _UnClos(const _Arg& __e) : _Base(__e) {} > }; > > template<class _Oper, typename _Tp> > struct _UnClos<_Oper, _ValArray, _Tp> > : _UnBase<_Oper, valarray<_Tp> > > { > typedef valarray<_Tp> _Arg; > typedef _UnBase<_Oper, valarray<_Tp> > _Base; > typedef typename _Base::value_type value_type; > > _UnClos(const _Arg& __e) : _Base(__e) {} > }; > > > > > > > template<class _Oper, class _FirstArg, class _SecondArg> > class _BinBase > { > public: > typedef typename _FirstArg::value_type _Vt; > typedef typename __fun<_Oper, _Vt>::result_type value_type; > > _BinBase(const _FirstArg& __e1, const _SecondArg& __e2) > : _M_expr1(__e1), _M_expr2(__e2) {} > > value_type operator[](size_t __i) const > { return _Oper()(_M_expr1[__i], _M_expr2[__i]); } > > size_t size() const { return _M_expr1.size(); } > > private: > const _FirstArg& _M_expr1; > const _SecondArg& _M_expr2; > }; > > > template<class _Oper, class _Clos> > class _BinBase2 > { > public: > typedef typename _Clos::value_type _Vt; > typedef typename __fun<_Oper, _Vt>::result_type value_type; > > _BinBase2(const _Clos& __e, const _Vt& __t) > : _M_expr1(__e), _M_expr2(__t) {} > > value_type operator[](size_t __i) const > { return _Oper()(_M_expr1[__i], _M_expr2); } > > size_t size() const { return _M_expr1.size(); } > > private: > const _Clos& _M_expr1; > const _Vt& _M_expr2; > }; > > template<class _Oper, class _Clos> > class _BinBase1 > { > public: > typedef typename _Clos::value_type _Vt; > typedef typename __fun<_Oper, _Vt>::result_type value_type; > > _BinBase1(const _Vt& __t, const _Clos& __e) > : _M_expr1(__t), _M_expr2(__e) {} > > value_type operator[](size_t __i) const > { return _Oper()(_M_expr1, _M_expr2[__i]); } > > size_t size() const { return _M_expr2.size(); } > > private: > const _Vt& _M_expr1; > const _Clos& _M_expr2; > }; > > template<class _Oper, class _Dom1, class _Dom2> > struct _BinClos<_Oper, _Expr, _Expr, _Dom1, _Dom2> > : _BinBase<_Oper, _Dom1, _Dom2> > { > typedef _BinBase<_Oper, _Dom1, _Dom2> _Base; > typedef typename _Base::value_type value_type; > > _BinClos(const _Dom1& __e1, const _Dom2& __e2) : _Base(__e1, __e2) {} > }; > > template<class _Oper, typename _Tp> > struct _BinClos<_Oper,_ValArray, _ValArray, _Tp, _Tp> > : _BinBase<_Oper, valarray<_Tp>, valarray<_Tp> > > { > typedef _BinBase<_Oper, valarray<_Tp>, valarray<_Tp> > _Base; > typedef typename _Base::value_type value_type; > > _BinClos(const valarray<_Tp>& __v, const valarray<_Tp>& __w) > : _Base(__v, __w) {} > }; > > template<class _Oper, class _Dom> > struct _BinClos<_Oper, _Expr, _ValArray, _Dom, typename _Dom::value_type> > : _BinBase<_Oper, _Dom, valarray<typename _Dom::value_type> > > { > typedef typename _Dom::value_type _Tp; > typedef _BinBase<_Oper,_Dom,valarray<_Tp> > _Base; > typedef typename _Base::value_type value_type; > > _BinClos(const _Dom& __e1, const valarray<_Tp>& __e2) > : _Base(__e1, __e2) {} > }; > > template<class _Oper, class _Dom> > struct _BinClos<_Oper, _ValArray, _Expr, typename _Dom::value_type, _Dom> > : _BinBase<_Oper, valarray<typename _Dom::value_type>,_Dom> > { > typedef typename _Dom::value_type _Tp; > typedef _BinBase<_Oper, valarray<_Tp>, _Dom> _Base; > typedef typename _Base::value_type value_type; > > _BinClos(const valarray<_Tp>& __e1, const _Dom& __e2) > : _Base(__e1, __e2) {} > }; > > template<class _Oper, class _Dom> > struct _BinClos<_Oper, _Expr, _Constant, _Dom, typename _Dom::value_type> > : _BinBase2<_Oper, _Dom> > { > typedef typename _Dom::value_type _Tp; > typedef _BinBase2<_Oper,_Dom> _Base; > typedef typename _Base::value_type value_type; > > _BinClos(const _Dom& __e1, const _Tp& __e2) : _Base(__e1, __e2) {} > }; > > template<class _Oper, class _Dom> > struct _BinClos<_Oper, _Constant, _Expr, typename _Dom::value_type, _Dom> > : _BinBase1<_Oper, _Dom> > { > typedef typename _Dom::value_type _Tp; > typedef _BinBase1<_Oper, _Dom> _Base; > typedef typename _Base::value_type value_type; > > _BinClos(const _Tp& __e1, const _Dom& __e2) : _Base(__e1, __e2) {} > }; > > template<class _Oper, typename _Tp> > struct _BinClos<_Oper, _ValArray, _Constant, _Tp, _Tp> > : _BinBase2<_Oper, valarray<_Tp> > > { > typedef _BinBase2<_Oper,valarray<_Tp> > _Base; > typedef typename _Base::value_type value_type; > > _BinClos(const valarray<_Tp>& __v, const _Tp& __t) : _Base(__v, __t) {} > }; > > template<class _Oper, typename _Tp> > struct _BinClos<_Oper, _Constant, _ValArray, _Tp, _Tp> > : _BinBase1<_Oper, valarray<_Tp> > > { > typedef _BinBase1<_Oper, valarray<_Tp> > _Base; > typedef typename _Base::value_type value_type; > > _BinClos(const _Tp& __t, const valarray<_Tp>& __v) : _Base(__t, __v) {} > }; > > > > > template<typename _Dom> > class _SBase > { > public: > typedef typename _Dom::value_type value_type; > > _SBase (const _Dom& __e, const slice& __s) > : _M_expr (__e), _M_slice (__s) {} > > value_type > operator[] (size_t __i) const > { return _M_expr[_M_slice.start () + __i * _M_slice.stride ()]; } > > size_t > size() const > { return _M_slice.size (); } > > private: > const _Dom& _M_expr; > const slice& _M_slice; > }; > > template<typename _Tp> > class _SBase<_Array<_Tp> > > { > public: > typedef _Tp value_type; > > _SBase (_Array<_Tp> __a, const slice& __s) > : _M_array (__a._M_data+__s.start()), _M_size (__s.size()), > _M_stride (__s.stride()) {} > > value_type > operator[] (size_t __i) const > { return _M_array._M_data[__i * _M_stride]; } > > size_t > size() const > { return _M_size; } > > private: > const _Array<_Tp> _M_array; > const size_t _M_size; > const size_t _M_stride; > }; > > template<class _Dom> > struct _SClos<_Expr, _Dom> > : _SBase<_Dom> > { > typedef _SBase<_Dom> _Base; > typedef typename _Base::value_type value_type; > > _SClos (const _Dom& __e, const slice& __s) : _Base (__e, __s) {} > }; > > template<typename _Tp> > struct _SClos<_ValArray, _Tp> > : _SBase<_Array<_Tp> > > { > typedef _SBase<_Array<_Tp> > _Base; > typedef _Tp value_type; > > _SClos (_Array<_Tp> __a, const slice& __s) : _Base (__a, __s) {} > }; > > >} ># 91 "/usr/include/c++/4.9.0/valarray" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 115 "/usr/include/c++/4.9.0/valarray" 3 > template<class _Tp> > class valarray > { > template<class _Op> > struct _UnaryOp > { > typedef typename __fun<_Op, _Tp>::result_type __rt; > typedef _Expr<_UnClos<_Op, _ValArray, _Tp>, __rt> _Rt; > }; > public: > typedef _Tp value_type; > > > > valarray(); > > > explicit valarray(size_t); > > > valarray(const _Tp&, size_t); > > > valarray(const _Tp* __restrict__, size_t); > > > valarray(const valarray&); > > > > valarray(valarray&&) noexcept; > > > > valarray(const slice_array<_Tp>&); > > > valarray(const gslice_array<_Tp>&); > > > valarray(const mask_array<_Tp>&); > > > valarray(const indirect_array<_Tp>&); > > > > valarray(initializer_list<_Tp>); > > > template<class _Dom> > valarray(const _Expr<_Dom, _Tp>& __e); > > ~valarray() noexcept; ># 178 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp>& operator=(const valarray<_Tp>& __v); ># 188 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp>& operator=(valarray<_Tp>&& __v) noexcept; ># 198 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp>& operator=(const _Tp& __t); ># 208 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp>& operator=(const slice_array<_Tp>& __sa); ># 218 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp>& operator=(const gslice_array<_Tp>& __ga); ># 228 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp>& operator=(const mask_array<_Tp>& __ma); ># 238 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp>& operator=(const indirect_array<_Tp>& __ia); ># 249 "/usr/include/c++/4.9.0/valarray" 3 > valarray& operator=(initializer_list<_Tp> __l); > > > template<class _Dom> valarray<_Tp>& > operator= (const _Expr<_Dom, _Tp>&); ># 262 "/usr/include/c++/4.9.0/valarray" 3 > _Tp& operator[](size_t __i); > > > > const _Tp& operator[](size_t) const; ># 279 "/usr/include/c++/4.9.0/valarray" 3 > _Expr<_SClos<_ValArray, _Tp>, _Tp> operator[](slice __s) const; ># 291 "/usr/include/c++/4.9.0/valarray" 3 > slice_array<_Tp> operator[](slice __s); ># 302 "/usr/include/c++/4.9.0/valarray" 3 > _Expr<_GClos<_ValArray, _Tp>, _Tp> operator[](const gslice& __s) const; ># 314 "/usr/include/c++/4.9.0/valarray" 3 > gslice_array<_Tp> operator[](const gslice& __s); ># 328 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp> operator[](const valarray<bool>& __m) const; ># 342 "/usr/include/c++/4.9.0/valarray" 3 > mask_array<_Tp> operator[](const valarray<bool>& __m); ># 355 "/usr/include/c++/4.9.0/valarray" 3 > _Expr<_IClos<_ValArray, _Tp>, _Tp> > operator[](const valarray<size_t>& __i) const; ># 370 "/usr/include/c++/4.9.0/valarray" 3 > indirect_array<_Tp> operator[](const valarray<size_t>& __i); > > > > typename _UnaryOp<__unary_plus>::_Rt operator+() const; > > > typename _UnaryOp<__negate>::_Rt operator-() const; > > > typename _UnaryOp<__bitwise_not>::_Rt operator~() const; > > > typename _UnaryOp<__logical_not>::_Rt operator!() const; > > > > valarray<_Tp>& operator*=(const _Tp&); > > > valarray<_Tp>& operator/=(const _Tp&); > > > valarray<_Tp>& operator%=(const _Tp&); > > > valarray<_Tp>& operator+=(const _Tp&); > > > valarray<_Tp>& operator-=(const _Tp&); > > > valarray<_Tp>& operator^=(const _Tp&); > > > valarray<_Tp>& operator&=(const _Tp&); > > > valarray<_Tp>& operator|=(const _Tp&); > > > valarray<_Tp>& operator<<=(const _Tp&); > > > valarray<_Tp>& operator>>=(const _Tp&); > > > valarray<_Tp>& operator*=(const valarray<_Tp>&); > > > valarray<_Tp>& operator/=(const valarray<_Tp>&); > > > valarray<_Tp>& operator%=(const valarray<_Tp>&); > > > valarray<_Tp>& operator+=(const valarray<_Tp>&); > > > valarray<_Tp>& operator-=(const valarray<_Tp>&); > > > valarray<_Tp>& operator^=(const valarray<_Tp>&); > > > valarray<_Tp>& operator|=(const valarray<_Tp>&); > > > valarray<_Tp>& operator&=(const valarray<_Tp>&); > > > valarray<_Tp>& operator<<=(const valarray<_Tp>&); > > > valarray<_Tp>& operator>>=(const valarray<_Tp>&); > > template<class _Dom> > valarray<_Tp>& operator*=(const _Expr<_Dom, _Tp>&); > template<class _Dom> > valarray<_Tp>& operator/=(const _Expr<_Dom, _Tp>&); > template<class _Dom> > valarray<_Tp>& operator%=(const _Expr<_Dom, _Tp>&); > template<class _Dom> > valarray<_Tp>& operator+=(const _Expr<_Dom, _Tp>&); > template<class _Dom> > valarray<_Tp>& operator-=(const _Expr<_Dom, _Tp>&); > template<class _Dom> > valarray<_Tp>& operator^=(const _Expr<_Dom, _Tp>&); > template<class _Dom> > valarray<_Tp>& operator|=(const _Expr<_Dom, _Tp>&); > template<class _Dom> > valarray<_Tp>& operator&=(const _Expr<_Dom, _Tp>&); > template<class _Dom> > valarray<_Tp>& operator<<=(const _Expr<_Dom, _Tp>&); > template<class _Dom> > valarray<_Tp>& operator>>=(const _Expr<_Dom, _Tp>&); > > > > > void swap(valarray<_Tp>& __v) noexcept; > > > > size_t size() const; > > > > > > > > _Tp sum() const; > > > _Tp min() const; > > > _Tp max() const; ># 505 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp> shift (int __n) const; ># 522 "/usr/include/c++/4.9.0/valarray" 3 > valarray<_Tp> cshift(int __n) const; ># 534 "/usr/include/c++/4.9.0/valarray" 3 > _Expr<_ValFunClos<_ValArray, _Tp>, _Tp> apply(_Tp func(_Tp)) const; ># 546 "/usr/include/c++/4.9.0/valarray" 3 > _Expr<_RefFunClos<_ValArray, _Tp>, _Tp> apply(_Tp func(const _Tp&)) const; ># 557 "/usr/include/c++/4.9.0/valarray" 3 > void resize(size_t __size, _Tp __c = _Tp()); > > private: > size_t _M_size; > _Tp* __restrict__ _M_data; > > friend class _Array<_Tp>; > }; > > template<typename _Tp> > inline const _Tp& > valarray<_Tp>::operator[](size_t __i) const > { > ; > return _M_data[__i]; > } > > template<typename _Tp> > inline _Tp& > valarray<_Tp>::operator[](size_t __i) > { > ; > return _M_data[__i]; > } > > > > >} > ># 1 "/usr/include/c++/4.9.0/bits/valarray_after.h" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/valarray_after.h" 3 ># 36 "/usr/include/c++/4.9.0/bits/valarray_after.h" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > template<class _Dom> > class _GBase > { > public: > typedef typename _Dom::value_type value_type; > > _GBase (const _Dom& __e, const valarray<size_t>& __i) > : _M_expr (__e), _M_index(__i) {} > > value_type > operator[] (size_t __i) const > { return _M_expr[_M_index[__i]]; } > > size_t > size () const > { return _M_index.size(); } > > private: > const _Dom& _M_expr; > const valarray<size_t>& _M_index; > }; > > template<typename _Tp> > class _GBase<_Array<_Tp> > > { > public: > typedef _Tp value_type; > > _GBase (_Array<_Tp> __a, const valarray<size_t>& __i) > : _M_array (__a), _M_index(__i) {} > > value_type > operator[] (size_t __i) const > { return _M_array._M_data[_M_index[__i]]; } > > size_t > size () const > { return _M_index.size(); } > > private: > const _Array<_Tp> _M_array; > const valarray<size_t>& _M_index; > }; > > template<class _Dom> > struct _GClos<_Expr, _Dom> > : _GBase<_Dom> > { > typedef _GBase<_Dom> _Base; > typedef typename _Base::value_type value_type; > > _GClos (const _Dom& __e, const valarray<size_t>& __i) > : _Base (__e, __i) {} > }; > > template<typename _Tp> > struct _GClos<_ValArray, _Tp> > : _GBase<_Array<_Tp> > > { > typedef _GBase<_Array<_Tp> > _Base; > typedef typename _Base::value_type value_type; > > _GClos (_Array<_Tp> __a, const valarray<size_t>& __i) > : _Base (__a, __i) {} > }; > > > > > template<class _Dom> > class _IBase > { > public: > typedef typename _Dom::value_type value_type; > > _IBase (const _Dom& __e, const valarray<size_t>& __i) > : _M_expr (__e), _M_index (__i) {} > > value_type > operator[] (size_t __i) const > { return _M_expr[_M_index[__i]]; } > > size_t > size() const > { return _M_index.size(); } > > private: > const _Dom& _M_expr; > const valarray<size_t>& _M_index; > }; > > template<class _Dom> > struct _IClos<_Expr, _Dom> > : _IBase<_Dom> > { > typedef _IBase<_Dom> _Base; > typedef typename _Base::value_type value_type; > > _IClos (const _Dom& __e, const valarray<size_t>& __i) > : _Base (__e, __i) {} > }; > > template<typename _Tp> > struct _IClos<_ValArray, _Tp> > : _IBase<valarray<_Tp> > > { > typedef _IBase<valarray<_Tp> > _Base; > typedef _Tp value_type; > > _IClos (const valarray<_Tp>& __a, const valarray<size_t>& __i) > : _Base (__a, __i) {} > }; > > > > > template<class _Clos, typename _Tp> > class _Expr > { > public: > typedef _Tp value_type; > > _Expr(const _Clos&); > > const _Clos& operator()() const; > > value_type operator[](size_t) const; > valarray<value_type> operator[](slice) const; > valarray<value_type> operator[](const gslice&) const; > valarray<value_type> operator[](const valarray<bool>&) const; > valarray<value_type> operator[](const valarray<size_t>&) const; > > _Expr<_UnClos<__unary_plus, std::_Expr, _Clos>, value_type> > operator+() const; > > _Expr<_UnClos<__negate, std::_Expr, _Clos>, value_type> > operator-() const; > > _Expr<_UnClos<__bitwise_not, std::_Expr, _Clos>, value_type> > operator~() const; > > _Expr<_UnClos<__logical_not, std::_Expr, _Clos>, bool> > operator!() const; > > size_t size() const; > value_type sum() const; > > valarray<value_type> shift(int) const; > valarray<value_type> cshift(int) const; > > value_type min() const; > value_type max() const; > > valarray<value_type> apply(value_type (*)(const value_type&)) const; > valarray<value_type> apply(value_type (*)(value_type)) const; > > private: > const _Clos _M_closure; > }; > > template<class _Clos, typename _Tp> > inline > _Expr<_Clos, _Tp>::_Expr(const _Clos& __c) : _M_closure(__c) {} > > template<class _Clos, typename _Tp> > inline const _Clos& > _Expr<_Clos, _Tp>::operator()() const > { return _M_closure; } > > template<class _Clos, typename _Tp> > inline _Tp > _Expr<_Clos, _Tp>::operator[](size_t __i) const > { return _M_closure[__i]; } > > template<class _Clos, typename _Tp> > inline valarray<_Tp> > _Expr<_Clos, _Tp>::operator[](slice __s) const > { > valarray<_Tp> __v = valarray<_Tp>(*this)[__s]; > return __v; > } > > template<class _Clos, typename _Tp> > inline valarray<_Tp> > _Expr<_Clos, _Tp>::operator[](const gslice& __gs) const > { > valarray<_Tp> __v = valarray<_Tp>(*this)[__gs]; > return __v; > } > > template<class _Clos, typename _Tp> > inline valarray<_Tp> > _Expr<_Clos, _Tp>::operator[](const valarray<bool>& __m) const > { > valarray<_Tp> __v = valarray<_Tp>(*this)[__m]; > return __v; > } > > template<class _Clos, typename _Tp> > inline valarray<_Tp> > _Expr<_Clos, _Tp>::operator[](const valarray<size_t>& __i) const > { > valarray<_Tp> __v = valarray<_Tp>(*this)[__i]; > return __v; > } > > template<class _Clos, typename _Tp> > inline size_t > _Expr<_Clos, _Tp>::size() const > { return _M_closure.size(); } > > template<class _Clos, typename _Tp> > inline valarray<_Tp> > _Expr<_Clos, _Tp>::shift(int __n) const > { > valarray<_Tp> __v = valarray<_Tp>(*this).shift(__n); > return __v; > } > > template<class _Clos, typename _Tp> > inline valarray<_Tp> > _Expr<_Clos, _Tp>::cshift(int __n) const > { > valarray<_Tp> __v = valarray<_Tp>(*this).cshift(__n); > return __v; > } > > template<class _Clos, typename _Tp> > inline valarray<_Tp> > _Expr<_Clos, _Tp>::apply(_Tp __f(const _Tp&)) const > { > valarray<_Tp> __v = valarray<_Tp>(*this).apply(__f); > return __v; > } > > template<class _Clos, typename _Tp> > inline valarray<_Tp> > _Expr<_Clos, _Tp>::apply(_Tp __f(_Tp)) const > { > valarray<_Tp> __v = valarray<_Tp>(*this).apply(__f); > return __v; > } > > > template<class _Clos, typename _Tp> > inline _Tp > _Expr<_Clos, _Tp>::sum() const > { > size_t __n = _M_closure.size(); > if (__n == 0) > return _Tp(); > else > { > _Tp __s = _M_closure[--__n]; > while (__n != 0) > __s += _M_closure[--__n]; > return __s; > } > } > > template<class _Clos, typename _Tp> > inline _Tp > _Expr<_Clos, _Tp>::min() const > { return __valarray_min(_M_closure); } > > template<class _Clos, typename _Tp> > inline _Tp > _Expr<_Clos, _Tp>::max() const > { return __valarray_max(_M_closure); } > > template<class _Dom, typename _Tp> > inline _Expr<_UnClos<__logical_not, _Expr, _Dom>, bool> > _Expr<_Dom, _Tp>::operator!() const > { > typedef _UnClos<__logical_not, std::_Expr, _Dom> _Closure; > return _Expr<_Closure, bool>(_Closure(this->_M_closure)); > } ># 331 "/usr/include/c++/4.9.0/bits/valarray_after.h" 3 > template<class _Dom, typename _Tp> inline _Expr<_UnClos<__unary_plus, std::_Expr, _Dom>, _Tp> _Expr<_Dom, _Tp>::operator +() const { typedef _UnClos<__unary_plus, std::_Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(this->_M_closure)); } > template<class _Dom, typename _Tp> inline _Expr<_UnClos<__negate, std::_Expr, _Dom>, _Tp> _Expr<_Dom, _Tp>::operator -() const { typedef _UnClos<__negate, std::_Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(this->_M_closure)); } > template<class _Dom, typename _Tp> inline _Expr<_UnClos<__bitwise_not, std::_Expr, _Dom>, _Tp> _Expr<_Dom, _Tp>::operator ~() const { typedef _UnClos<__bitwise_not, std::_Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(this->_M_closure)); } ># 402 "/usr/include/c++/4.9.0/bits/valarray_after.h" 3 > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__plus, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__plus, typename _Dom1::value_type>::result_type> operator +(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__plus, _Arg>::result_type _Value; typedef _BinClos<__plus, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__plus, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__plus, typename _Dom::value_type>::result_type> operator +(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__plus, _Arg>::result_type _Value; typedef _BinClos<__plus, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__plus, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__plus, typename _Dom::value_type>::result_type> operator +(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__plus, _Arg>::result_type _Value; typedef _BinClos<__plus, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__plus, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__plus, typename _Dom::value_type>::result_type> operator +(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__plus, _Arg>::result_type _Value; typedef _BinClos<__plus, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__plus, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__plus, typename _Dom::value_type>::result_type> operator +(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__plus, _Tp>::result_type _Value; typedef _BinClos<__plus, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__minus, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__minus, typename _Dom1::value_type>::result_type> operator -(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__minus, _Arg>::result_type _Value; typedef _BinClos<__minus, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__minus, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__minus, typename _Dom::value_type>::result_type> operator -(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__minus, _Arg>::result_type _Value; typedef _BinClos<__minus, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__minus, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__minus, typename _Dom::value_type>::result_type> operator -(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__minus, _Arg>::result_type _Value; typedef _BinClos<__minus, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__minus, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__minus, typename _Dom::value_type>::result_type> operator -(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__minus, _Arg>::result_type _Value; typedef _BinClos<__minus, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__minus, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__minus, typename _Dom::value_type>::result_type> operator -(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__minus, _Tp>::result_type _Value; typedef _BinClos<__minus, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__multiplies, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__multiplies, typename _Dom1::value_type>::result_type> operator *(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__multiplies, _Arg>::result_type _Value; typedef _BinClos<__multiplies, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__multiplies, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__multiplies, typename _Dom::value_type>::result_type> operator *(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__multiplies, _Arg>::result_type _Value; typedef _BinClos<__multiplies, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__multiplies, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__multiplies, typename _Dom::value_type>::result_type> operator *(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__multiplies, _Arg>::result_type _Value; typedef _BinClos<__multiplies, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__multiplies, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__multiplies, typename _Dom::value_type>::result_type> operator *(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__multiplies, _Arg>::result_type _Value; typedef _BinClos<__multiplies, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__multiplies, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__multiplies, typename _Dom::value_type>::result_type> operator *(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__multiplies, _Tp>::result_type _Value; typedef _BinClos<__multiplies, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__divides, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__divides, typename _Dom1::value_type>::result_type> operator /(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__divides, _Arg>::result_type _Value; typedef _BinClos<__divides, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__divides, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__divides, typename _Dom::value_type>::result_type> operator /(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__divides, _Arg>::result_type _Value; typedef _BinClos<__divides, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__divides, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__divides, typename _Dom::value_type>::result_type> operator /(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__divides, _Arg>::result_type _Value; typedef _BinClos<__divides, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__divides, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__divides, typename _Dom::value_type>::result_type> operator /(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__divides, _Arg>::result_type _Value; typedef _BinClos<__divides, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__divides, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__divides, typename _Dom::value_type>::result_type> operator /(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__divides, _Tp>::result_type _Value; typedef _BinClos<__divides, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__modulus, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__modulus, typename _Dom1::value_type>::result_type> operator %(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__modulus, _Arg>::result_type _Value; typedef _BinClos<__modulus, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__modulus, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__modulus, typename _Dom::value_type>::result_type> operator %(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__modulus, _Arg>::result_type _Value; typedef _BinClos<__modulus, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__modulus, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__modulus, typename _Dom::value_type>::result_type> operator %(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__modulus, _Arg>::result_type _Value; typedef _BinClos<__modulus, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__modulus, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__modulus, typename _Dom::value_type>::result_type> operator %(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__modulus, _Arg>::result_type _Value; typedef _BinClos<__modulus, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__modulus, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__modulus, typename _Dom::value_type>::result_type> operator %(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__modulus, _Tp>::result_type _Value; typedef _BinClos<__modulus, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__bitwise_xor, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__bitwise_xor, typename _Dom1::value_type>::result_type> operator ^(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__bitwise_xor, _Arg>::result_type _Value; typedef _BinClos<__bitwise_xor, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__bitwise_xor, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__bitwise_xor, typename _Dom::value_type>::result_type> operator ^(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__bitwise_xor, _Arg>::result_type _Value; typedef _BinClos<__bitwise_xor, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__bitwise_xor, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__bitwise_xor, typename _Dom::value_type>::result_type> operator ^(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__bitwise_xor, _Arg>::result_type _Value; typedef _BinClos<__bitwise_xor, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__bitwise_xor, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__bitwise_xor, typename _Dom::value_type>::result_type> operator ^(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__bitwise_xor, _Arg>::result_type _Value; typedef _BinClos<__bitwise_xor, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__bitwise_xor, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__bitwise_xor, typename _Dom::value_type>::result_type> operator ^(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__bitwise_xor, _Tp>::result_type _Value; typedef _BinClos<__bitwise_xor, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__bitwise_and, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__bitwise_and, typename _Dom1::value_type>::result_type> operator &(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__bitwise_and, _Arg>::result_type _Value; typedef _BinClos<__bitwise_and, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__bitwise_and, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__bitwise_and, typename _Dom::value_type>::result_type> operator &(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__bitwise_and, _Arg>::result_type _Value; typedef _BinClos<__bitwise_and, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__bitwise_and, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__bitwise_and, typename _Dom::value_type>::result_type> operator &(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__bitwise_and, _Arg>::result_type _Value; typedef _BinClos<__bitwise_and, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__bitwise_and, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__bitwise_and, typename _Dom::value_type>::result_type> operator &(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__bitwise_and, _Arg>::result_type _Value; typedef _BinClos<__bitwise_and, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__bitwise_and, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__bitwise_and, typename _Dom::value_type>::result_type> operator &(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__bitwise_and, _Tp>::result_type _Value; typedef _BinClos<__bitwise_and, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__bitwise_or, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__bitwise_or, typename _Dom1::value_type>::result_type> operator |(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__bitwise_or, _Arg>::result_type _Value; typedef _BinClos<__bitwise_or, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__bitwise_or, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__bitwise_or, typename _Dom::value_type>::result_type> operator |(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__bitwise_or, _Arg>::result_type _Value; typedef _BinClos<__bitwise_or, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__bitwise_or, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__bitwise_or, typename _Dom::value_type>::result_type> operator |(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__bitwise_or, _Arg>::result_type _Value; typedef _BinClos<__bitwise_or, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__bitwise_or, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__bitwise_or, typename _Dom::value_type>::result_type> operator |(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__bitwise_or, _Arg>::result_type _Value; typedef _BinClos<__bitwise_or, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__bitwise_or, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__bitwise_or, typename _Dom::value_type>::result_type> operator |(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__bitwise_or, _Tp>::result_type _Value; typedef _BinClos<__bitwise_or, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__shift_left, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__shift_left, typename _Dom1::value_type>::result_type> operator <<(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__shift_left, _Arg>::result_type _Value; typedef _BinClos<__shift_left, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__shift_left, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__shift_left, typename _Dom::value_type>::result_type> operator <<(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__shift_left, _Arg>::result_type _Value; typedef _BinClos<__shift_left, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__shift_left, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__shift_left, typename _Dom::value_type>::result_type> operator <<(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__shift_left, _Arg>::result_type _Value; typedef _BinClos<__shift_left, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__shift_left, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__shift_left, typename _Dom::value_type>::result_type> operator <<(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__shift_left, _Arg>::result_type _Value; typedef _BinClos<__shift_left, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__shift_left, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__shift_left, typename _Dom::value_type>::result_type> operator <<(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__shift_left, _Tp>::result_type _Value; typedef _BinClos<__shift_left, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__shift_right, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__shift_right, typename _Dom1::value_type>::result_type> operator >>(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__shift_right, _Arg>::result_type _Value; typedef _BinClos<__shift_right, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__shift_right, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__shift_right, typename _Dom::value_type>::result_type> operator >>(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__shift_right, _Arg>::result_type _Value; typedef _BinClos<__shift_right, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__shift_right, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__shift_right, typename _Dom::value_type>::result_type> operator >>(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__shift_right, _Arg>::result_type _Value; typedef _BinClos<__shift_right, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__shift_right, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__shift_right, typename _Dom::value_type>::result_type> operator >>(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__shift_right, _Arg>::result_type _Value; typedef _BinClos<__shift_right, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__shift_right, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__shift_right, typename _Dom::value_type>::result_type> operator >>(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__shift_right, _Tp>::result_type _Value; typedef _BinClos<__shift_right, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__logical_and, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__logical_and, typename _Dom1::value_type>::result_type> operator &&(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__logical_and, _Arg>::result_type _Value; typedef _BinClos<__logical_and, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__logical_and, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__logical_and, typename _Dom::value_type>::result_type> operator &&(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__logical_and, _Arg>::result_type _Value; typedef _BinClos<__logical_and, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__logical_and, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__logical_and, typename _Dom::value_type>::result_type> operator &&(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__logical_and, _Arg>::result_type _Value; typedef _BinClos<__logical_and, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__logical_and, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__logical_and, typename _Dom::value_type>::result_type> operator &&(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__logical_and, _Arg>::result_type _Value; typedef _BinClos<__logical_and, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__logical_and, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__logical_and, typename _Dom::value_type>::result_type> operator &&(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__logical_and, _Tp>::result_type _Value; typedef _BinClos<__logical_and, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__logical_or, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__logical_or, typename _Dom1::value_type>::result_type> operator ||(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__logical_or, _Arg>::result_type _Value; typedef _BinClos<__logical_or, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__logical_or, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__logical_or, typename _Dom::value_type>::result_type> operator ||(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__logical_or, _Arg>::result_type _Value; typedef _BinClos<__logical_or, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__logical_or, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__logical_or, typename _Dom::value_type>::result_type> operator ||(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__logical_or, _Arg>::result_type _Value; typedef _BinClos<__logical_or, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__logical_or, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__logical_or, typename _Dom::value_type>::result_type> operator ||(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__logical_or, _Arg>::result_type _Value; typedef _BinClos<__logical_or, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__logical_or, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__logical_or, typename _Dom::value_type>::result_type> operator ||(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__logical_or, _Tp>::result_type _Value; typedef _BinClos<__logical_or, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__equal_to, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__equal_to, typename _Dom1::value_type>::result_type> operator ==(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__equal_to, _Arg>::result_type _Value; typedef _BinClos<__equal_to, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__equal_to, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__equal_to, typename _Dom::value_type>::result_type> operator ==(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__equal_to, _Arg>::result_type _Value; typedef _BinClos<__equal_to, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__equal_to, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__equal_to, typename _Dom::value_type>::result_type> operator ==(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__equal_to, _Arg>::result_type _Value; typedef _BinClos<__equal_to, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__equal_to, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__equal_to, typename _Dom::value_type>::result_type> operator ==(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__equal_to, _Arg>::result_type _Value; typedef _BinClos<__equal_to, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__equal_to, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__equal_to, typename _Dom::value_type>::result_type> operator ==(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__equal_to, _Tp>::result_type _Value; typedef _BinClos<__equal_to, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__not_equal_to, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__not_equal_to, typename _Dom1::value_type>::result_type> operator !=(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__not_equal_to, _Arg>::result_type _Value; typedef _BinClos<__not_equal_to, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__not_equal_to, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__not_equal_to, typename _Dom::value_type>::result_type> operator !=(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__not_equal_to, _Arg>::result_type _Value; typedef _BinClos<__not_equal_to, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__not_equal_to, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__not_equal_to, typename _Dom::value_type>::result_type> operator !=(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__not_equal_to, _Arg>::result_type _Value; typedef _BinClos<__not_equal_to, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__not_equal_to, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__not_equal_to, typename _Dom::value_type>::result_type> operator !=(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__not_equal_to, _Arg>::result_type _Value; typedef _BinClos<__not_equal_to, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__not_equal_to, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__not_equal_to, typename _Dom::value_type>::result_type> operator !=(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__not_equal_to, _Tp>::result_type _Value; typedef _BinClos<__not_equal_to, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__less, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__less, typename _Dom1::value_type>::result_type> operator <(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__less, _Arg>::result_type _Value; typedef _BinClos<__less, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__less, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__less, typename _Dom::value_type>::result_type> operator <(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__less, _Arg>::result_type _Value; typedef _BinClos<__less, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__less, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__less, typename _Dom::value_type>::result_type> operator <(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__less, _Arg>::result_type _Value; typedef _BinClos<__less, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__less, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__less, typename _Dom::value_type>::result_type> operator <(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__less, _Arg>::result_type _Value; typedef _BinClos<__less, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__less, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__less, typename _Dom::value_type>::result_type> operator <(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__less, _Tp>::result_type _Value; typedef _BinClos<__less, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__greater, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__greater, typename _Dom1::value_type>::result_type> operator >(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__greater, _Arg>::result_type _Value; typedef _BinClos<__greater, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__greater, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__greater, typename _Dom::value_type>::result_type> operator >(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__greater, _Arg>::result_type _Value; typedef _BinClos<__greater, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__greater, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__greater, typename _Dom::value_type>::result_type> operator >(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__greater, _Arg>::result_type _Value; typedef _BinClos<__greater, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__greater, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__greater, typename _Dom::value_type>::result_type> operator >(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__greater, _Arg>::result_type _Value; typedef _BinClos<__greater, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__greater, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__greater, typename _Dom::value_type>::result_type> operator >(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__greater, _Tp>::result_type _Value; typedef _BinClos<__greater, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__less_equal, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__less_equal, typename _Dom1::value_type>::result_type> operator <=(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__less_equal, _Arg>::result_type _Value; typedef _BinClos<__less_equal, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__less_equal, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__less_equal, typename _Dom::value_type>::result_type> operator <=(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__less_equal, _Arg>::result_type _Value; typedef _BinClos<__less_equal, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__less_equal, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__less_equal, typename _Dom::value_type>::result_type> operator <=(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__less_equal, _Arg>::result_type _Value; typedef _BinClos<__less_equal, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__less_equal, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__less_equal, typename _Dom::value_type>::result_type> operator <=(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__less_equal, _Arg>::result_type _Value; typedef _BinClos<__less_equal, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__less_equal, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__less_equal, typename _Dom::value_type>::result_type> operator <=(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__less_equal, _Tp>::result_type _Value; typedef _BinClos<__less_equal, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } > template<class _Dom1, class _Dom2> inline _Expr<_BinClos<__greater_equal, _Expr, _Expr, _Dom1, _Dom2>, typename __fun<__greater_equal, typename _Dom1::value_type>::result_type> operator >=(const _Expr<_Dom1, typename _Dom1::value_type>& __v, const _Expr<_Dom2, typename _Dom2::value_type>& __w) { typedef typename _Dom1::value_type _Arg; typedef typename __fun<__greater_equal, _Arg>::result_type _Value; typedef _BinClos<__greater_equal, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __w())); } template<class _Dom> inline _Expr<_BinClos<__greater_equal, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename __fun<__greater_equal, typename _Dom::value_type>::result_type> operator >=(const _Expr<_Dom, typename _Dom::value_type>& __v, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__greater_equal, _Arg>::result_type _Value; typedef _BinClos<__greater_equal, _Expr, _Constant, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__v(), __t)); } template<class _Dom> inline _Expr<_BinClos<__greater_equal, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__greater_equal, typename _Dom::value_type>::result_type> operator >=(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__greater_equal, _Arg>::result_type _Value; typedef _BinClos<__greater_equal, _Constant, _Expr, _Arg, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__t, __v())); } template<class _Dom> inline _Expr<_BinClos<__greater_equal, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename __fun<__greater_equal, typename _Dom::value_type>::result_type> operator >=(const _Expr<_Dom,typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Arg; typedef typename __fun<__greater_equal, _Arg>::result_type _Value; typedef _BinClos<__greater_equal, _Expr, _ValArray, _Dom, _Arg> _Closure; return _Expr<_Closure, _Value>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<__greater_equal, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename __fun<__greater_equal, typename _Dom::value_type>::result_type> operator >=(const valarray<typename _Dom::value_type>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef typename __fun<__greater_equal, _Tp>::result_type _Value; typedef _BinClos<__greater_equal, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Value>(_Closure(__v, __e ())); } ># 442 "/usr/include/c++/4.9.0/bits/valarray_after.h" 3 > template<class _Dom> inline _Expr<_UnClos<_Abs, _Expr, _Dom>, typename _Dom::value_type> abs(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Abs, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Abs, _ValArray, _Tp>, _Tp> abs(const valarray<_Tp>& __v) { typedef _UnClos<_Abs, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Cos, _Expr, _Dom>, typename _Dom::value_type> cos(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Cos, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Cos, _ValArray, _Tp>, _Tp> cos(const valarray<_Tp>& __v) { typedef _UnClos<_Cos, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Acos, _Expr, _Dom>, typename _Dom::value_type> acos(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Acos, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Acos, _ValArray, _Tp>, _Tp> acos(const valarray<_Tp>& __v) { typedef _UnClos<_Acos, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Cosh, _Expr, _Dom>, typename _Dom::value_type> cosh(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Cosh, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Cosh, _ValArray, _Tp>, _Tp> cosh(const valarray<_Tp>& __v) { typedef _UnClos<_Cosh, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Sin, _Expr, _Dom>, typename _Dom::value_type> sin(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Sin, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Sin, _ValArray, _Tp>, _Tp> sin(const valarray<_Tp>& __v) { typedef _UnClos<_Sin, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Asin, _Expr, _Dom>, typename _Dom::value_type> asin(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Asin, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Asin, _ValArray, _Tp>, _Tp> asin(const valarray<_Tp>& __v) { typedef _UnClos<_Asin, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Sinh, _Expr, _Dom>, typename _Dom::value_type> sinh(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Sinh, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Sinh, _ValArray, _Tp>, _Tp> sinh(const valarray<_Tp>& __v) { typedef _UnClos<_Sinh, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Tan, _Expr, _Dom>, typename _Dom::value_type> tan(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Tan, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Tan, _ValArray, _Tp>, _Tp> tan(const valarray<_Tp>& __v) { typedef _UnClos<_Tan, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Tanh, _Expr, _Dom>, typename _Dom::value_type> tanh(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Tanh, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Tanh, _ValArray, _Tp>, _Tp> tanh(const valarray<_Tp>& __v) { typedef _UnClos<_Tanh, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Atan, _Expr, _Dom>, typename _Dom::value_type> atan(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Atan, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Atan, _ValArray, _Tp>, _Tp> atan(const valarray<_Tp>& __v) { typedef _UnClos<_Atan, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Exp, _Expr, _Dom>, typename _Dom::value_type> exp(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Exp, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Exp, _ValArray, _Tp>, _Tp> exp(const valarray<_Tp>& __v) { typedef _UnClos<_Exp, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Log, _Expr, _Dom>, typename _Dom::value_type> log(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Log, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Log, _ValArray, _Tp>, _Tp> log(const valarray<_Tp>& __v) { typedef _UnClos<_Log, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Log10, _Expr, _Dom>, typename _Dom::value_type> log10(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Log10, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Log10, _ValArray, _Tp>, _Tp> log10(const valarray<_Tp>& __v) { typedef _UnClos<_Log10, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } > template<class _Dom> inline _Expr<_UnClos<_Sqrt, _Expr, _Dom>, typename _Dom::value_type> sqrt(const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _UnClos<_Sqrt, _Expr, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e())); } template<typename _Tp> inline _Expr<_UnClos<_Sqrt, _ValArray, _Tp>, _Tp> sqrt(const valarray<_Tp>& __v) { typedef _UnClos<_Sqrt, _ValArray, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v)); } ># 543 "/usr/include/c++/4.9.0/bits/valarray_after.h" 3 >template<class _Dom1, class _Dom2> inline _Expr<_BinClos<_Atan2, _Expr, _Expr, _Dom1, _Dom2>, typename _Dom1::value_type> atan2(const _Expr<_Dom1, typename _Dom1::value_type>& __e1, const _Expr<_Dom2, typename _Dom2::value_type>& __e2) { typedef typename _Dom1::value_type _Tp; typedef _BinClos<_Atan2, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e1(), __e2())); } template<class _Dom> inline _Expr<_BinClos<_Atan2, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename _Dom::value_type> atan2(const _Expr<_Dom, typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Tp; typedef _BinClos<_Atan2, _Expr, _ValArray, _Dom, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<_Atan2, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename _Dom::value_type> atan2(const valarray<typename _Dom::valarray>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _BinClos<_Atan2, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v, __e())); } template<class _Dom> inline _Expr<_BinClos<_Atan2, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename _Dom::value_type> atan2(const _Expr<_Dom, typename _Dom::value_type>& __e, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Tp; typedef _BinClos<_Atan2, _Expr, _Constant, _Dom, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e(), __t)); } template<class _Dom> inline _Expr<_BinClos<_Atan2, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename _Dom::value_type> atan2(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _BinClos<_Atan2, _Constant, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__t, __e())); } template<typename _Tp> inline _Expr<_BinClos<_Atan2, _ValArray, _ValArray, _Tp, _Tp>, _Tp> atan2(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { typedef _BinClos<_Atan2, _ValArray, _ValArray, _Tp, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<_Atan2, _ValArray, _Constant, _Tp, _Tp>, _Tp> atan2(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<_Atan2, _ValArray, _Constant, _Tp, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<_Atan2, _Constant, _ValArray, _Tp, _Tp>, _Tp> atan2(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<_Atan2, _Constant, _ValArray, _Tp, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__t, __v)); } >template<class _Dom1, class _Dom2> inline _Expr<_BinClos<_Pow, _Expr, _Expr, _Dom1, _Dom2>, typename _Dom1::value_type> pow(const _Expr<_Dom1, typename _Dom1::value_type>& __e1, const _Expr<_Dom2, typename _Dom2::value_type>& __e2) { typedef typename _Dom1::value_type _Tp; typedef _BinClos<_Pow, _Expr, _Expr, _Dom1, _Dom2> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e1(), __e2())); } template<class _Dom> inline _Expr<_BinClos<_Pow, _Expr, _ValArray, _Dom, typename _Dom::value_type>, typename _Dom::value_type> pow(const _Expr<_Dom, typename _Dom::value_type>& __e, const valarray<typename _Dom::value_type>& __v) { typedef typename _Dom::value_type _Tp; typedef _BinClos<_Pow, _Expr, _ValArray, _Dom, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e(), __v)); } template<class _Dom> inline _Expr<_BinClos<_Pow, _ValArray, _Expr, typename _Dom::value_type, _Dom>, typename _Dom::value_type> pow(const valarray<typename _Dom::valarray>& __v, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _BinClos<_Pow, _ValArray, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v, __e())); } template<class _Dom> inline _Expr<_BinClos<_Pow, _Expr, _Constant, _Dom, typename _Dom::value_type>, typename _Dom::value_type> pow(const _Expr<_Dom, typename _Dom::value_type>& __e, const typename _Dom::value_type& __t) { typedef typename _Dom::value_type _Tp; typedef _BinClos<_Pow, _Expr, _Constant, _Dom, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__e(), __t)); } template<class _Dom> inline _Expr<_BinClos<_Pow, _Constant, _Expr, typename _Dom::value_type, _Dom>, typename _Dom::value_type> pow(const typename _Dom::value_type& __t, const _Expr<_Dom, typename _Dom::value_type>& __e) { typedef typename _Dom::value_type _Tp; typedef _BinClos<_Pow, _Constant, _Expr, _Tp, _Dom> _Closure; return _Expr<_Closure, _Tp>(_Closure(__t, __e())); } template<typename _Tp> inline _Expr<_BinClos<_Pow, _ValArray, _ValArray, _Tp, _Tp>, _Tp> pow(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { typedef _BinClos<_Pow, _ValArray, _ValArray, _Tp, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<_Pow, _ValArray, _Constant, _Tp, _Tp>, _Tp> pow(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<_Pow, _ValArray, _Constant, _Tp, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<_Pow, _Constant, _ValArray, _Tp, _Tp>, _Tp> pow(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<_Pow, _Constant, _ValArray, _Tp, _Tp> _Closure; return _Expr<_Closure, _Tp>(_Closure(__t, __v)); } > > > > >} ># 588 "/usr/include/c++/4.9.0/valarray" 2 3 > ># 1 "/usr/include/c++/4.9.0/bits/gslice.h" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/gslice.h" 3 ># 36 "/usr/include/c++/4.9.0/bits/gslice.h" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 64 "/usr/include/c++/4.9.0/bits/gslice.h" 3 > class gslice > { > public: > > gslice(); ># 80 "/usr/include/c++/4.9.0/bits/gslice.h" 3 > gslice(size_t __o, const valarray<size_t>& __l, > const valarray<size_t>& __s); > > > > > > gslice(const gslice&); > > > ~gslice(); > > > > gslice& operator=(const gslice&); > > > size_t start() const; > > > valarray<size_t> size() const; > > > valarray<size_t> stride() const; > > private: > struct _Indexer > { > size_t _M_count; > size_t _M_start; > valarray<size_t> _M_size; > valarray<size_t> _M_stride; > valarray<size_t> _M_index; > > _Indexer() > : _M_count(1), _M_start(0), _M_size(), _M_stride(), _M_index() {} > > _Indexer(size_t, const valarray<size_t>&, > const valarray<size_t>&); > > void > _M_increment_use() > { ++_M_count; } > > size_t > _M_decrement_use() > { return --_M_count; } > }; > > _Indexer* _M_index; > > template<typename _Tp> friend class valarray; > }; > > inline size_t > gslice::start() const > { return _M_index ? _M_index->_M_start : 0; } > > inline valarray<size_t> > gslice::size() const > { return _M_index ? _M_index->_M_size : valarray<size_t>(); } > > inline valarray<size_t> > gslice::stride() const > { return _M_index ? _M_index->_M_stride : valarray<size_t>(); } > > > > inline > gslice::gslice() > : _M_index(new gslice::_Indexer()) {} > > inline > gslice::gslice(size_t __o, const valarray<size_t>& __l, > const valarray<size_t>& __s) > : _M_index(new gslice::_Indexer(__o, __l, __s)) {} > > inline > gslice::gslice(const gslice& __g) > : _M_index(__g._M_index) > { if (_M_index) _M_index->_M_increment_use(); } > > inline > gslice::~gslice() > { > if (_M_index && _M_index->_M_decrement_use() == 0) > delete _M_index; > } > > inline gslice& > gslice::operator=(const gslice& __g) > { > if (__g._M_index) > __g._M_index->_M_increment_use(); > if (_M_index && _M_index->_M_decrement_use() == 0) > delete _M_index; > _M_index = __g._M_index; > return *this; > } > > > > >} ># 590 "/usr/include/c++/4.9.0/valarray" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/gslice_array.h" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/gslice_array.h" 3 ># 36 "/usr/include/c++/4.9.0/bits/gslice_array.h" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 59 "/usr/include/c++/4.9.0/bits/gslice_array.h" 3 > template<typename _Tp> > class gslice_array > { > public: > typedef _Tp value_type; > > > > > > gslice_array(const gslice_array&); > > > > gslice_array& operator=(const gslice_array&); > > > void operator=(const valarray<_Tp>&) const; > > void operator*=(const valarray<_Tp>&) const; > > void operator/=(const valarray<_Tp>&) const; > > void operator%=(const valarray<_Tp>&) const; > > void operator+=(const valarray<_Tp>&) const; > > void operator-=(const valarray<_Tp>&) const; > > void operator^=(const valarray<_Tp>&) const; > > void operator&=(const valarray<_Tp>&) const; > > void operator|=(const valarray<_Tp>&) const; > > void operator<<=(const valarray<_Tp>&) const; > > void operator>>=(const valarray<_Tp>&) const; > > void operator=(const _Tp&) const; > > template<class _Dom> > void operator=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator*=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator/=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator%=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator+=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator-=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator^=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator&=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator|=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator<<=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator>>=(const _Expr<_Dom, _Tp>&) const; > > private: > _Array<_Tp> _M_array; > const valarray<size_t>& _M_index; > > friend class valarray<_Tp>; > > gslice_array(_Array<_Tp>, const valarray<size_t>&); > > > gslice_array(); > }; > > template<typename _Tp> > inline > gslice_array<_Tp>::gslice_array(_Array<_Tp> __a, > const valarray<size_t>& __i) > : _M_array(__a), _M_index(__i) {} > > template<typename _Tp> > inline > gslice_array<_Tp>::gslice_array(const gslice_array<_Tp>& __a) > : _M_array(__a._M_array), _M_index(__a._M_index) {} > > template<typename _Tp> > inline gslice_array<_Tp>& > gslice_array<_Tp>::operator=(const gslice_array<_Tp>& __a) > { > std::__valarray_copy(_Array<_Tp>(__a._M_array), > _Array<size_t>(__a._M_index), _M_index.size(), > _M_array, _Array<size_t>(_M_index)); > return *this; > } > > template<typename _Tp> > inline void > gslice_array<_Tp>::operator=(const _Tp& __t) const > { > std::__valarray_fill(_M_array, _Array<size_t>(_M_index), > _M_index.size(), __t); > } > > template<typename _Tp> > inline void > gslice_array<_Tp>::operator=(const valarray<_Tp>& __v) const > { > std::__valarray_copy(_Array<_Tp>(__v), __v.size(), > _M_array, _Array<size_t>(_M_index)); > } > > template<typename _Tp> > template<class _Dom> > inline void > gslice_array<_Tp>::operator=(const _Expr<_Dom, _Tp>& __e) const > { > std::__valarray_copy (__e, _M_index.size(), _M_array, > _Array<size_t>(_M_index)); > } ># 200 "/usr/include/c++/4.9.0/bits/gslice_array.h" 3 >template<typename _Tp> inline void gslice_array<_Tp>::operator *=(const valarray<_Tp>& __v) const { _Array_augmented___multiplies(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator *= (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___multiplies(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } >template<typename _Tp> inline void gslice_array<_Tp>::operator /=(const valarray<_Tp>& __v) const { _Array_augmented___divides(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator /= (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___divides(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } >template<typename _Tp> inline void gslice_array<_Tp>::operator %=(const valarray<_Tp>& __v) const { _Array_augmented___modulus(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator %= (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___modulus(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } >template<typename _Tp> inline void gslice_array<_Tp>::operator +=(const valarray<_Tp>& __v) const { _Array_augmented___plus(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator += (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___plus(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } >template<typename _Tp> inline void gslice_array<_Tp>::operator -=(const valarray<_Tp>& __v) const { _Array_augmented___minus(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator -= (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___minus(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } >template<typename _Tp> inline void gslice_array<_Tp>::operator ^=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_xor(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator ^= (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___bitwise_xor(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } >template<typename _Tp> inline void gslice_array<_Tp>::operator &=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_and(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator &= (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___bitwise_and(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } >template<typename _Tp> inline void gslice_array<_Tp>::operator |=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_or(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator |= (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___bitwise_or(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } >template<typename _Tp> inline void gslice_array<_Tp>::operator <<=(const valarray<_Tp>& __v) const { _Array_augmented___shift_left(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator <<= (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___shift_left(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } >template<typename _Tp> inline void gslice_array<_Tp>::operator >>=(const valarray<_Tp>& __v) const { _Array_augmented___shift_right(_M_array, _Array<size_t>(_M_index), _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void gslice_array<_Tp>::operator >>= (const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___shift_right(_M_array, _Array<size_t>(_M_index), __e, _M_index.size()); } > > > > > > >} ># 591 "/usr/include/c++/4.9.0/valarray" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/mask_array.h" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/mask_array.h" 3 ># 36 "/usr/include/c++/4.9.0/bits/mask_array.h" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 61 "/usr/include/c++/4.9.0/bits/mask_array.h" 3 > template <class _Tp> > class mask_array > { > public: > typedef _Tp value_type; > > > > > > mask_array (const mask_array&); > > > > mask_array& operator=(const mask_array&); > > void operator=(const valarray<_Tp>&) const; > > void operator*=(const valarray<_Tp>&) const; > > void operator/=(const valarray<_Tp>&) const; > > void operator%=(const valarray<_Tp>&) const; > > void operator+=(const valarray<_Tp>&) const; > > void operator-=(const valarray<_Tp>&) const; > > void operator^=(const valarray<_Tp>&) const; > > void operator&=(const valarray<_Tp>&) const; > > void operator|=(const valarray<_Tp>&) const; > > void operator<<=(const valarray<_Tp>&) const; > > void operator>>=(const valarray<_Tp>&) const; > > void operator=(const _Tp&) const; > > > > template<class _Dom> > void operator=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator*=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator/=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator%=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator+=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator-=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator^=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator&=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator|=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator<<=(const _Expr<_Dom,_Tp>&) const; > template<class _Dom> > void operator>>=(const _Expr<_Dom,_Tp>&) const; > > private: > mask_array(_Array<_Tp>, size_t, _Array<bool>); > friend class valarray<_Tp>; > > const size_t _M_sz; > const _Array<bool> _M_mask; > const _Array<_Tp> _M_array; > > > mask_array(); > }; > > template<typename _Tp> > inline mask_array<_Tp>::mask_array(const mask_array<_Tp>& a) > : _M_sz(a._M_sz), _M_mask(a._M_mask), _M_array(a._M_array) {} > > template<typename _Tp> > inline > mask_array<_Tp>::mask_array(_Array<_Tp> __a, size_t __s, _Array<bool> __m) > : _M_sz(__s), _M_mask(__m), _M_array(__a) {} > > template<typename _Tp> > inline mask_array<_Tp>& > mask_array<_Tp>::operator=(const mask_array<_Tp>& __a) > { > std::__valarray_copy(__a._M_array, __a._M_mask, > _M_sz, _M_array, _M_mask); > return *this; > } > > template<typename _Tp> > inline void > mask_array<_Tp>::operator=(const _Tp& __t) const > { std::__valarray_fill(_M_array, _M_sz, _M_mask, __t); } > > template<typename _Tp> > inline void > mask_array<_Tp>::operator=(const valarray<_Tp>& __v) const > { std::__valarray_copy(_Array<_Tp>(__v), __v.size(), _M_array, _M_mask); } > > template<typename _Tp> > template<class _Ex> > inline void > mask_array<_Tp>::operator=(const _Expr<_Ex, _Tp>& __e) const > { std::__valarray_copy(__e, __e.size(), _M_array, _M_mask); } ># 190 "/usr/include/c++/4.9.0/bits/mask_array.h" 3 >template<typename _Tp> inline void mask_array<_Tp>::operator *=(const valarray<_Tp>& __v) const { _Array_augmented___multiplies(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator *=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___multiplies(_M_array, _M_mask, __e, __e.size()); } >template<typename _Tp> inline void mask_array<_Tp>::operator /=(const valarray<_Tp>& __v) const { _Array_augmented___divides(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator /=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___divides(_M_array, _M_mask, __e, __e.size()); } >template<typename _Tp> inline void mask_array<_Tp>::operator %=(const valarray<_Tp>& __v) const { _Array_augmented___modulus(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator %=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___modulus(_M_array, _M_mask, __e, __e.size()); } >template<typename _Tp> inline void mask_array<_Tp>::operator +=(const valarray<_Tp>& __v) const { _Array_augmented___plus(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator +=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___plus(_M_array, _M_mask, __e, __e.size()); } >template<typename _Tp> inline void mask_array<_Tp>::operator -=(const valarray<_Tp>& __v) const { _Array_augmented___minus(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator -=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___minus(_M_array, _M_mask, __e, __e.size()); } >template<typename _Tp> inline void mask_array<_Tp>::operator ^=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_xor(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator ^=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___bitwise_xor(_M_array, _M_mask, __e, __e.size()); } >template<typename _Tp> inline void mask_array<_Tp>::operator &=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_and(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator &=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___bitwise_and(_M_array, _M_mask, __e, __e.size()); } >template<typename _Tp> inline void mask_array<_Tp>::operator |=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_or(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator |=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___bitwise_or(_M_array, _M_mask, __e, __e.size()); } >template<typename _Tp> inline void mask_array<_Tp>::operator <<=(const valarray<_Tp>& __v) const { _Array_augmented___shift_left(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator <<=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___shift_left(_M_array, _M_mask, __e, __e.size()); } >template<typename _Tp> inline void mask_array<_Tp>::operator >>=(const valarray<_Tp>& __v) const { _Array_augmented___shift_right(_M_array, _M_mask, _Array<_Tp>(__v), __v.size()); } template<typename _Tp> template<class _Dom> inline void mask_array<_Tp>::operator >>=(const _Expr<_Dom, _Tp>& __e) const { _Array_augmented___shift_right(_M_array, _M_mask, __e, __e.size()); } > > > > > > >} ># 592 "/usr/include/c++/4.9.0/valarray" 2 3 ># 1 "/usr/include/c++/4.9.0/bits/indirect_array.h" 1 3 ># 35 "/usr/include/c++/4.9.0/bits/indirect_array.h" 3 ># 36 "/usr/include/c++/4.9.0/bits/indirect_array.h" 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ ># 61 "/usr/include/c++/4.9.0/bits/indirect_array.h" 3 > template <class _Tp> > class indirect_array > { > public: > typedef _Tp value_type; > > > > > > indirect_array(const indirect_array&); > > > > indirect_array& operator=(const indirect_array&); > > > void operator=(const valarray<_Tp>&) const; > > void operator*=(const valarray<_Tp>&) const; > > void operator/=(const valarray<_Tp>&) const; > > void operator%=(const valarray<_Tp>&) const; > > void operator+=(const valarray<_Tp>&) const; > > void operator-=(const valarray<_Tp>&) const; > > void operator^=(const valarray<_Tp>&) const; > > void operator&=(const valarray<_Tp>&) const; > > void operator|=(const valarray<_Tp>&) const; > > void operator<<=(const valarray<_Tp>&) const; > > void operator>>=(const valarray<_Tp>&) const; > > void operator= (const _Tp&) const; > > > template<class _Dom> > void operator=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator*=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator/=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator%=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator+=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator-=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator^=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator&=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator|=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator<<=(const _Expr<_Dom, _Tp>&) const; > template<class _Dom> > void operator>>=(const _Expr<_Dom, _Tp>&) const; > > private: > > indirect_array(_Array<_Tp>, size_t, _Array<size_t>); > > friend class valarray<_Tp>; > friend class gslice_array<_Tp>; > > const size_t _M_sz; > const _Array<size_t> _M_index; > const _Array<_Tp> _M_array; > > > indirect_array(); > }; > > template<typename _Tp> > inline > indirect_array<_Tp>::indirect_array(const indirect_array<_Tp>& __a) > : _M_sz(__a._M_sz), _M_index(__a._M_index), _M_array(__a._M_array) {} > > template<typename _Tp> > inline > indirect_array<_Tp>::indirect_array(_Array<_Tp> __a, size_t __s, > _Array<size_t> __i) > : _M_sz(__s), _M_index(__i), _M_array(__a) {} > > template<typename _Tp> > inline indirect_array<_Tp>& > indirect_array<_Tp>::operator=(const indirect_array<_Tp>& __a) > { > std::__valarray_copy(__a._M_array, _M_sz, __a._M_index, _M_array, > _M_index); > return *this; > } > > template<typename _Tp> > inline void > indirect_array<_Tp>::operator=(const _Tp& __t) const > { std::__valarray_fill(_M_array, _M_index, _M_sz, __t); } > > template<typename _Tp> > inline void > indirect_array<_Tp>::operator=(const valarray<_Tp>& __v) const > { std::__valarray_copy(_Array<_Tp>(__v), _M_sz, _M_array, _M_index); } > > template<typename _Tp> > template<class _Dom> > inline void > indirect_array<_Tp>::operator=(const _Expr<_Dom, _Tp>& __e) const > { std::__valarray_copy(__e, _M_sz, _M_array, _M_index); } ># 194 "/usr/include/c++/4.9.0/bits/indirect_array.h" 3 >template<typename _Tp> inline void indirect_array<_Tp>::operator *=(const valarray<_Tp>& __v) const { _Array_augmented___multiplies(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator *=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___multiplies(_M_array, _M_index, __e, _M_sz); } >template<typename _Tp> inline void indirect_array<_Tp>::operator /=(const valarray<_Tp>& __v) const { _Array_augmented___divides(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator /=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___divides(_M_array, _M_index, __e, _M_sz); } >template<typename _Tp> inline void indirect_array<_Tp>::operator %=(const valarray<_Tp>& __v) const { _Array_augmented___modulus(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator %=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___modulus(_M_array, _M_index, __e, _M_sz); } >template<typename _Tp> inline void indirect_array<_Tp>::operator +=(const valarray<_Tp>& __v) const { _Array_augmented___plus(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator +=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___plus(_M_array, _M_index, __e, _M_sz); } >template<typename _Tp> inline void indirect_array<_Tp>::operator -=(const valarray<_Tp>& __v) const { _Array_augmented___minus(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator -=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___minus(_M_array, _M_index, __e, _M_sz); } >template<typename _Tp> inline void indirect_array<_Tp>::operator ^=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_xor(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator ^=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___bitwise_xor(_M_array, _M_index, __e, _M_sz); } >template<typename _Tp> inline void indirect_array<_Tp>::operator &=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_and(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator &=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___bitwise_and(_M_array, _M_index, __e, _M_sz); } >template<typename _Tp> inline void indirect_array<_Tp>::operator |=(const valarray<_Tp>& __v) const { _Array_augmented___bitwise_or(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator |=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___bitwise_or(_M_array, _M_index, __e, _M_sz); } >template<typename _Tp> inline void indirect_array<_Tp>::operator <<=(const valarray<_Tp>& __v) const { _Array_augmented___shift_left(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator <<=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___shift_left(_M_array, _M_index, __e, _M_sz); } >template<typename _Tp> inline void indirect_array<_Tp>::operator >>=(const valarray<_Tp>& __v) const { _Array_augmented___shift_right(_M_array, _M_index, _Array<_Tp>(__v), _M_sz); } template<typename _Tp> template<class _Dom> inline void indirect_array<_Tp>::operator >>=(const _Expr<_Dom,_Tp>& __e) const { _Array_augmented___shift_right(_M_array, _M_index, __e, _M_sz); } > > > > > > >} ># 593 "/usr/include/c++/4.9.0/valarray" 2 3 > >namespace std __attribute__ ((__visibility__ ("default"))) >{ > > > > > > > > template<typename _Tp> > inline > valarray<_Tp>::valarray() : _M_size(0), _M_data(0) {} > > template<typename _Tp> > inline > valarray<_Tp>::valarray(size_t __n) > : _M_size(__n), _M_data(__valarray_get_storage<_Tp>(__n)) > { std::__valarray_default_construct(_M_data, _M_data + __n); } > > template<typename _Tp> > inline > valarray<_Tp>::valarray(const _Tp& __t, size_t __n) > : _M_size(__n), _M_data(__valarray_get_storage<_Tp>(__n)) > { std::__valarray_fill_construct(_M_data, _M_data + __n, __t); } > > template<typename _Tp> > inline > valarray<_Tp>::valarray(const _Tp* __restrict__ __p, size_t __n) > : _M_size(__n), _M_data(__valarray_get_storage<_Tp>(__n)) > { > ; > std::__valarray_copy_construct(__p, __p + __n, _M_data); > } > > template<typename _Tp> > inline > valarray<_Tp>::valarray(const valarray<_Tp>& __v) > : _M_size(__v._M_size), _M_data(__valarray_get_storage<_Tp>(__v._M_size)) > { std::__valarray_copy_construct(__v._M_data, __v._M_data + _M_size, > _M_data); } > > > template<typename _Tp> > inline > valarray<_Tp>::valarray(valarray<_Tp>&& __v) noexcept > : _M_size(__v._M_size), _M_data(__v._M_data) > { > __v._M_size = 0; > __v._M_data = 0; > } > > > template<typename _Tp> > inline > valarray<_Tp>::valarray(const slice_array<_Tp>& __sa) > : _M_size(__sa._M_sz), _M_data(__valarray_get_storage<_Tp>(__sa._M_sz)) > { > std::__valarray_copy_construct > (__sa._M_array, __sa._M_sz, __sa._M_stride, _Array<_Tp>(_M_data)); > } > > template<typename _Tp> > inline > valarray<_Tp>::valarray(const gslice_array<_Tp>& __ga) > : _M_size(__ga._M_index.size()), > _M_data(__valarray_get_storage<_Tp>(_M_size)) > { > std::__valarray_copy_construct > (__ga._M_array, _Array<size_t>(__ga._M_index), > _Array<_Tp>(_M_data), _M_size); > } > > template<typename _Tp> > inline > valarray<_Tp>::valarray(const mask_array<_Tp>& __ma) > : _M_size(__ma._M_sz), _M_data(__valarray_get_storage<_Tp>(__ma._M_sz)) > { > std::__valarray_copy_construct > (__ma._M_array, __ma._M_mask, _Array<_Tp>(_M_data), _M_size); > } > > template<typename _Tp> > inline > valarray<_Tp>::valarray(const indirect_array<_Tp>& __ia) > : _M_size(__ia._M_sz), _M_data(__valarray_get_storage<_Tp>(__ia._M_sz)) > { > std::__valarray_copy_construct > (__ia._M_array, __ia._M_index, _Array<_Tp>(_M_data), _M_size); > } > > > template<typename _Tp> > inline > valarray<_Tp>::valarray(initializer_list<_Tp> __l) > : _M_size(__l.size()), _M_data(__valarray_get_storage<_Tp>(__l.size())) > { std::__valarray_copy_construct(__l.begin(), __l.end(), _M_data); } > > > template<typename _Tp> template<class _Dom> > inline > valarray<_Tp>::valarray(const _Expr<_Dom, _Tp>& __e) > : _M_size(__e.size()), _M_data(__valarray_get_storage<_Tp>(_M_size)) > { std::__valarray_copy_construct(__e, _M_size, _Array<_Tp>(_M_data)); } > > template<typename _Tp> > inline > valarray<_Tp>::~valarray() noexcept > { > std::__valarray_destroy_elements(_M_data, _M_data + _M_size); > std::__valarray_release_memory(_M_data); > } > > template<typename _Tp> > inline valarray<_Tp>& > valarray<_Tp>::operator=(const valarray<_Tp>& __v) > { > > > if (_M_size == __v._M_size) > std::__valarray_copy(__v._M_data, _M_size, _M_data); > else > { > if (_M_data) > { > std::__valarray_destroy_elements(_M_data, _M_data + _M_size); > std::__valarray_release_memory(_M_data); > } > _M_size = __v._M_size; > _M_data = __valarray_get_storage<_Tp>(_M_size); > std::__valarray_copy_construct(__v._M_data, __v._M_data + _M_size, > _M_data); > } > return *this; > } > > > template<typename _Tp> > inline valarray<_Tp>& > valarray<_Tp>::operator=(valarray<_Tp>&& __v) noexcept > { > if (_M_data) > { > std::__valarray_destroy_elements(_M_data, _M_data + _M_size); > std::__valarray_release_memory(_M_data); > } > _M_size = __v._M_size; > _M_data = __v._M_data; > __v._M_size = 0; > __v._M_data = 0; > return *this; > } > > template<typename _Tp> > inline valarray<_Tp>& > valarray<_Tp>::operator=(initializer_list<_Tp> __l) > { > > > if (_M_size == __l.size()) > std::__valarray_copy(__l.begin(), __l.size(), _M_data); > else > { > if (_M_data) > { > std::__valarray_destroy_elements(_M_data, _M_data + _M_size); > std::__valarray_release_memory(_M_data); > } > _M_size = __l.size(); > _M_data = __valarray_get_storage<_Tp>(_M_size); > std::__valarray_copy_construct(__l.begin(), __l.begin() + _M_size, > _M_data); > } > return *this; > } > > > template<typename _Tp> > inline valarray<_Tp>& > valarray<_Tp>::operator=(const _Tp& __t) > { > std::__valarray_fill(_M_data, _M_size, __t); > return *this; > } > > template<typename _Tp> > inline valarray<_Tp>& > valarray<_Tp>::operator=(const slice_array<_Tp>& __sa) > { > ; > std::__valarray_copy(__sa._M_array, __sa._M_sz, > __sa._M_stride, _Array<_Tp>(_M_data)); > return *this; > } > > template<typename _Tp> > inline valarray<_Tp>& > valarray<_Tp>::operator=(const gslice_array<_Tp>& __ga) > { > ; > std::__valarray_copy(__ga._M_array, _Array<size_t>(__ga._M_index), > _Array<_Tp>(_M_data), _M_size); > return *this; > } > > template<typename _Tp> > inline valarray<_Tp>& > valarray<_Tp>::operator=(const mask_array<_Tp>& __ma) > { > ; > std::__valarray_copy(__ma._M_array, __ma._M_mask, > _Array<_Tp>(_M_data), _M_size); > return *this; > } > > template<typename _Tp> > inline valarray<_Tp>& > valarray<_Tp>::operator=(const indirect_array<_Tp>& __ia) > { > ; > std::__valarray_copy(__ia._M_array, __ia._M_index, > _Array<_Tp>(_M_data), _M_size); > return *this; > } > > template<typename _Tp> template<class _Dom> > inline valarray<_Tp>& > valarray<_Tp>::operator=(const _Expr<_Dom, _Tp>& __e) > { > > > if (_M_size == __e.size()) > std::__valarray_copy(__e, _M_size, _Array<_Tp>(_M_data)); > else > { > if (_M_data) > { > std::__valarray_destroy_elements(_M_data, _M_data + _M_size); > std::__valarray_release_memory(_M_data); > } > _M_size = __e.size(); > _M_data = __valarray_get_storage<_Tp>(_M_size); > std::__valarray_copy_construct(__e, _M_size, _Array<_Tp>(_M_data)); > } > return *this; > } > > template<typename _Tp> > inline _Expr<_SClos<_ValArray,_Tp>, _Tp> > valarray<_Tp>::operator[](slice __s) const > { > typedef _SClos<_ValArray,_Tp> _Closure; > return _Expr<_Closure, _Tp>(_Closure (_Array<_Tp>(_M_data), __s)); > } > > template<typename _Tp> > inline slice_array<_Tp> > valarray<_Tp>::operator[](slice __s) > { return slice_array<_Tp>(_Array<_Tp>(_M_data), __s); } > > template<typename _Tp> > inline _Expr<_GClos<_ValArray,_Tp>, _Tp> > valarray<_Tp>::operator[](const gslice& __gs) const > { > typedef _GClos<_ValArray,_Tp> _Closure; > return _Expr<_Closure, _Tp> > (_Closure(_Array<_Tp>(_M_data), __gs._M_index->_M_index)); > } > > template<typename _Tp> > inline gslice_array<_Tp> > valarray<_Tp>::operator[](const gslice& __gs) > { > return gslice_array<_Tp> > (_Array<_Tp>(_M_data), __gs._M_index->_M_index); > } > > template<typename _Tp> > inline valarray<_Tp> > valarray<_Tp>::operator[](const valarray<bool>& __m) const > { > size_t __s = 0; > size_t __e = __m.size(); > for (size_t __i=0; __i<__e; ++__i) > if (__m[__i]) ++__s; > return valarray<_Tp>(mask_array<_Tp>(_Array<_Tp>(_M_data), __s, > _Array<bool> (__m))); > } > > template<typename _Tp> > inline mask_array<_Tp> > valarray<_Tp>::operator[](const valarray<bool>& __m) > { > size_t __s = 0; > size_t __e = __m.size(); > for (size_t __i=0; __i<__e; ++__i) > if (__m[__i]) ++__s; > return mask_array<_Tp>(_Array<_Tp>(_M_data), __s, _Array<bool>(__m)); > } > > template<typename _Tp> > inline _Expr<_IClos<_ValArray,_Tp>, _Tp> > valarray<_Tp>::operator[](const valarray<size_t>& __i) const > { > typedef _IClos<_ValArray,_Tp> _Closure; > return _Expr<_Closure, _Tp>(_Closure(*this, __i)); > } > > template<typename _Tp> > inline indirect_array<_Tp> > valarray<_Tp>::operator[](const valarray<size_t>& __i) > { > return indirect_array<_Tp>(_Array<_Tp>(_M_data), __i.size(), > _Array<size_t>(__i)); > } > > > template<class _Tp> > inline void > valarray<_Tp>::swap(valarray<_Tp>& __v) noexcept > { > std::swap(_M_size, __v._M_size); > std::swap(_M_data, __v._M_data); > } > > > template<class _Tp> > inline size_t > valarray<_Tp>::size() const > { return _M_size; } > > template<class _Tp> > inline _Tp > valarray<_Tp>::sum() const > { > ; > return std::__valarray_sum(_M_data, _M_data + _M_size); > } > > template<class _Tp> > inline valarray<_Tp> > valarray<_Tp>::shift(int __n) const > { > valarray<_Tp> __ret; > > if (_M_size == 0) > return __ret; > > _Tp* __restrict__ __tmp_M_data = > std::__valarray_get_storage<_Tp>(_M_size); > > if (__n == 0) > std::__valarray_copy_construct(_M_data, > _M_data + _M_size, __tmp_M_data); > else if (__n > 0) > { > if (size_t(__n) > _M_size) > __n = int(_M_size); > > std::__valarray_copy_construct(_M_data + __n, > _M_data + _M_size, __tmp_M_data); > std::__valarray_default_construct(__tmp_M_data + _M_size - __n, > __tmp_M_data + _M_size); > } > else > { > if (-size_t(__n) > _M_size) > __n = -int(_M_size); > > std::__valarray_copy_construct(_M_data, _M_data + _M_size + __n, > __tmp_M_data - __n); > std::__valarray_default_construct(__tmp_M_data, > __tmp_M_data - __n); > } > > __ret._M_size = _M_size; > __ret._M_data = __tmp_M_data; > return __ret; > } > > template<class _Tp> > inline valarray<_Tp> > valarray<_Tp>::cshift(int __n) const > { > valarray<_Tp> __ret; > > if (_M_size == 0) > return __ret; > > _Tp* __restrict__ __tmp_M_data = > std::__valarray_get_storage<_Tp>(_M_size); > > if (__n == 0) > std::__valarray_copy_construct(_M_data, > _M_data + _M_size, __tmp_M_data); > else if (__n > 0) > { > if (size_t(__n) > _M_size) > __n = int(__n % _M_size); > > std::__valarray_copy_construct(_M_data, _M_data + __n, > __tmp_M_data + _M_size - __n); > std::__valarray_copy_construct(_M_data + __n, _M_data + _M_size, > __tmp_M_data); > } > else > { > if (-size_t(__n) > _M_size) > __n = -int(-size_t(__n) % _M_size); > > std::__valarray_copy_construct(_M_data + _M_size + __n, > _M_data + _M_size, __tmp_M_data); > std::__valarray_copy_construct(_M_data, _M_data + _M_size + __n, > __tmp_M_data - __n); > } > > __ret._M_size = _M_size; > __ret._M_data = __tmp_M_data; > return __ret; > } > > template<class _Tp> > inline void > valarray<_Tp>::resize(size_t __n, _Tp __c) > { > > > > std::__valarray_destroy_elements(_M_data, _M_data + _M_size); > if (_M_size != __n) > { > std::__valarray_release_memory(_M_data); > _M_size = __n; > _M_data = __valarray_get_storage<_Tp>(__n); > } > std::__valarray_fill_construct(_M_data, _M_data + __n, __c); > } > > template<typename _Tp> > inline _Tp > valarray<_Tp>::min() const > { > ; > return *std::min_element(_M_data, _M_data + _M_size); > } > > template<typename _Tp> > inline _Tp > valarray<_Tp>::max() const > { > ; > return *std::max_element(_M_data, _M_data + _M_size); > } > > template<class _Tp> > inline _Expr<_ValFunClos<_ValArray, _Tp>, _Tp> > valarray<_Tp>::apply(_Tp func(_Tp)) const > { > typedef _ValFunClos<_ValArray, _Tp> _Closure; > return _Expr<_Closure, _Tp>(_Closure(*this, func)); > } > > template<class _Tp> > inline _Expr<_RefFunClos<_ValArray, _Tp>, _Tp> > valarray<_Tp>::apply(_Tp func(const _Tp &)) const > { > typedef _RefFunClos<_ValArray, _Tp> _Closure; > return _Expr<_Closure, _Tp>(_Closure(*this, func)); > } ># 1073 "/usr/include/c++/4.9.0/valarray" 3 > template<typename _Tp> inline typename valarray<_Tp>::template _UnaryOp<__unary_plus>::_Rt valarray<_Tp>::operator +() const { typedef _UnClos<__unary_plus, _ValArray, _Tp> _Closure; typedef typename __fun<__unary_plus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(*this)); } > template<typename _Tp> inline typename valarray<_Tp>::template _UnaryOp<__negate>::_Rt valarray<_Tp>::operator -() const { typedef _UnClos<__negate, _ValArray, _Tp> _Closure; typedef typename __fun<__negate, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(*this)); } > template<typename _Tp> inline typename valarray<_Tp>::template _UnaryOp<__bitwise_not>::_Rt valarray<_Tp>::operator ~() const { typedef _UnClos<__bitwise_not, _ValArray, _Tp> _Closure; typedef typename __fun<__bitwise_not, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(*this)); } > template<typename _Tp> inline typename valarray<_Tp>::template _UnaryOp<__logical_not>::_Rt valarray<_Tp>::operator !() const { typedef _UnClos<__logical_not, _ValArray, _Tp> _Closure; typedef typename __fun<__logical_not, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(*this)); } ># 1099 "/usr/include/c++/4.9.0/valarray" 3 >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator +=(const _Tp &__t) { _Array_augmented___plus(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator +=(const valarray<_Tp> &__v) { ; _Array_augmented___plus(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator -=(const _Tp &__t) { _Array_augmented___minus(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator -=(const valarray<_Tp> &__v) { ; _Array_augmented___minus(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator *=(const _Tp &__t) { _Array_augmented___multiplies(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator *=(const valarray<_Tp> &__v) { ; _Array_augmented___multiplies(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator /=(const _Tp &__t) { _Array_augmented___divides(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator /=(const valarray<_Tp> &__v) { ; _Array_augmented___divides(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator %=(const _Tp &__t) { _Array_augmented___modulus(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator %=(const valarray<_Tp> &__v) { ; _Array_augmented___modulus(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator ^=(const _Tp &__t) { _Array_augmented___bitwise_xor(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator ^=(const valarray<_Tp> &__v) { ; _Array_augmented___bitwise_xor(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator &=(const _Tp &__t) { _Array_augmented___bitwise_and(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator &=(const valarray<_Tp> &__v) { ; _Array_augmented___bitwise_and(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator |=(const _Tp &__t) { _Array_augmented___bitwise_or(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator |=(const valarray<_Tp> &__v) { ; _Array_augmented___bitwise_or(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator <<=(const _Tp &__t) { _Array_augmented___shift_left(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator <<=(const valarray<_Tp> &__v) { ; _Array_augmented___shift_left(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } >template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator >>=(const _Tp &__t) { _Array_augmented___shift_right(_Array<_Tp>(_M_data), _M_size, __t); return *this; } template<class _Tp> inline valarray<_Tp>& valarray<_Tp>::operator >>=(const valarray<_Tp> &__v) { ; _Array_augmented___shift_right(_Array<_Tp>(_M_data), _M_size, _Array<_Tp>(__v._M_data)); return *this; } ># 1121 "/usr/include/c++/4.9.0/valarray" 3 >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator +=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___plus(_Array<_Tp>(_M_data), __e, _M_size); return *this; } >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator -=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___minus(_Array<_Tp>(_M_data), __e, _M_size); return *this; } >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator *=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___multiplies(_Array<_Tp>(_M_data), __e, _M_size); return *this; } >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator /=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___divides(_Array<_Tp>(_M_data), __e, _M_size); return *this; } >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator %=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___modulus(_Array<_Tp>(_M_data), __e, _M_size); return *this; } >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator ^=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___bitwise_xor(_Array<_Tp>(_M_data), __e, _M_size); return *this; } >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator &=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___bitwise_and(_Array<_Tp>(_M_data), __e, _M_size); return *this; } >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator |=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___bitwise_or(_Array<_Tp>(_M_data), __e, _M_size); return *this; } >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator <<=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___shift_left(_Array<_Tp>(_M_data), __e, _M_size); return *this; } >template<class _Tp> template<class _Dom> inline valarray<_Tp>& valarray<_Tp>::operator >>=(const _Expr<_Dom, _Tp>& __e) { _Array_augmented___shift_right(_Array<_Tp>(_M_data), __e, _M_size); return *this; } ># 1167 "/usr/include/c++/4.9.0/valarray" 3 >template<typename _Tp> inline _Expr<_BinClos<__plus, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__plus, _Tp>::result_type> operator +(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__plus, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__plus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__plus, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__plus, _Tp>::result_type> operator +(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__plus, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__plus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__plus, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__plus, _Tp>::result_type> operator +(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__plus, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__plus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__minus, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__minus, _Tp>::result_type> operator -(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__minus, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__minus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__minus, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__minus, _Tp>::result_type> operator -(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__minus, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__minus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__minus, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__minus, _Tp>::result_type> operator -(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__minus, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__minus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__multiplies, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__multiplies, _Tp>::result_type> operator *(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__multiplies, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__multiplies, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__multiplies, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__multiplies, _Tp>::result_type> operator *(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__multiplies, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__multiplies, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__multiplies, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__multiplies, _Tp>::result_type> operator *(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__multiplies, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__multiplies, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__divides, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__divides, _Tp>::result_type> operator /(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__divides, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__divides, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__divides, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__divides, _Tp>::result_type> operator /(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__divides, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__divides, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__divides, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__divides, _Tp>::result_type> operator /(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__divides, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__divides, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__modulus, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__modulus, _Tp>::result_type> operator %(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__modulus, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__modulus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__modulus, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__modulus, _Tp>::result_type> operator %(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__modulus, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__modulus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__modulus, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__modulus, _Tp>::result_type> operator %(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__modulus, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__modulus, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__bitwise_xor, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__bitwise_xor, _Tp>::result_type> operator ^(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__bitwise_xor, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__bitwise_xor, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__bitwise_xor, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__bitwise_xor, _Tp>::result_type> operator ^(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__bitwise_xor, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__bitwise_xor, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__bitwise_xor, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__bitwise_xor, _Tp>::result_type> operator ^(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__bitwise_xor, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__bitwise_xor, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__bitwise_and, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__bitwise_and, _Tp>::result_type> operator &(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__bitwise_and, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__bitwise_and, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__bitwise_and, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__bitwise_and, _Tp>::result_type> operator &(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__bitwise_and, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__bitwise_and, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__bitwise_and, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__bitwise_and, _Tp>::result_type> operator &(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__bitwise_and, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__bitwise_and, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__bitwise_or, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__bitwise_or, _Tp>::result_type> operator |(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__bitwise_or, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__bitwise_or, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__bitwise_or, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__bitwise_or, _Tp>::result_type> operator |(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__bitwise_or, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__bitwise_or, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__bitwise_or, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__bitwise_or, _Tp>::result_type> operator |(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__bitwise_or, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__bitwise_or, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__shift_left, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__shift_left, _Tp>::result_type> operator <<(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__shift_left, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__shift_left, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__shift_left, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__shift_left, _Tp>::result_type> operator <<(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__shift_left, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__shift_left, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__shift_left, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__shift_left, _Tp>::result_type> operator <<(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__shift_left, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__shift_left, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__shift_right, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__shift_right, _Tp>::result_type> operator >>(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__shift_right, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__shift_right, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__shift_right, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__shift_right, _Tp>::result_type> operator >>(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__shift_right, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__shift_right, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__shift_right, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__shift_right, _Tp>::result_type> operator >>(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__shift_right, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__shift_right, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__logical_and, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__logical_and, _Tp>::result_type> operator &&(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__logical_and, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__logical_and, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__logical_and, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__logical_and, _Tp>::result_type> operator &&(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__logical_and, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__logical_and, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__logical_and, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__logical_and, _Tp>::result_type> operator &&(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__logical_and, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__logical_and, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__logical_or, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__logical_or, _Tp>::result_type> operator ||(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__logical_or, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__logical_or, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__logical_or, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__logical_or, _Tp>::result_type> operator ||(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__logical_or, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__logical_or, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__logical_or, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__logical_or, _Tp>::result_type> operator ||(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__logical_or, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__logical_or, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__equal_to, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__equal_to, _Tp>::result_type> operator ==(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__equal_to, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__equal_to, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__equal_to, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__equal_to, _Tp>::result_type> operator ==(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__equal_to, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__equal_to, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__equal_to, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__equal_to, _Tp>::result_type> operator ==(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__equal_to, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__equal_to, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__not_equal_to, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__not_equal_to, _Tp>::result_type> operator !=(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__not_equal_to, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__not_equal_to, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__not_equal_to, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__not_equal_to, _Tp>::result_type> operator !=(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__not_equal_to, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__not_equal_to, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__not_equal_to, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__not_equal_to, _Tp>::result_type> operator !=(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__not_equal_to, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__not_equal_to, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__less, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__less, _Tp>::result_type> operator <(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__less, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__less, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__less, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__less, _Tp>::result_type> operator <(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__less, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__less, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__less, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__less, _Tp>::result_type> operator <(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__less, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__less, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__greater, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__greater, _Tp>::result_type> operator >(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__greater, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__greater, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__greater, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__greater, _Tp>::result_type> operator >(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__greater, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__greater, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__greater, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__greater, _Tp>::result_type> operator >(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__greater, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__greater, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__less_equal, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__less_equal, _Tp>::result_type> operator <=(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__less_equal, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__less_equal, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__less_equal, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__less_equal, _Tp>::result_type> operator <=(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__less_equal, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__less_equal, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__less_equal, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__less_equal, _Tp>::result_type> operator <=(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__less_equal, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__less_equal, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } >template<typename _Tp> inline _Expr<_BinClos<__greater_equal, _ValArray, _ValArray, _Tp, _Tp>, typename __fun<__greater_equal, _Tp>::result_type> operator >=(const valarray<_Tp>& __v, const valarray<_Tp>& __w) { ; typedef _BinClos<__greater_equal, _ValArray, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__greater_equal, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __w)); } template<typename _Tp> inline _Expr<_BinClos<__greater_equal, _ValArray,_Constant, _Tp, _Tp>, typename __fun<__greater_equal, _Tp>::result_type> operator >=(const valarray<_Tp>& __v, const _Tp& __t) { typedef _BinClos<__greater_equal, _ValArray, _Constant, _Tp, _Tp> _Closure; typedef typename __fun<__greater_equal, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__v, __t)); } template<typename _Tp> inline _Expr<_BinClos<__greater_equal, _Constant, _ValArray, _Tp, _Tp>, typename __fun<__greater_equal, _Tp>::result_type> operator >=(const _Tp& __t, const valarray<_Tp>& __v) { typedef _BinClos<__greater_equal, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<__greater_equal, _Tp>::result_type _Rt; return _Expr<_Closure, _Rt>(_Closure(__t, __v)); } ># 1194 "/usr/include/c++/4.9.0/valarray" 3 > template<class _Tp> > inline _Tp* > begin(valarray<_Tp>& __va) > { return std::__addressof(__va[0]); } > > > > > > > template<class _Tp> > inline const _Tp* > begin(const valarray<_Tp>& __va) > { return std::__addressof(__va[0]); } > > > > > > > template<class _Tp> > inline _Tp* > end(valarray<_Tp>& __va) > { return std::__addressof(__va[0]) + __va.size(); } > > > > > > > template<class _Tp> > inline const _Tp* > end(const valarray<_Tp>& __va) > { return std::__addressof(__va[0]) + __va.size(); } > > > > > >} ># 24 "/usr/include/boost/serialization/detail/get_data.hpp" 2 3 4 > >namespace boost { >namespace serialization { >namespace detail { > >template <class T, class Allocator> >T* get_data(std::vector<T,Allocator>& v) >{ > return v.empty() ? 0 : &(v[0]); >} > >template <class T, class Allocator> >T* get_data(std::vector<T,Allocator> const & v) >{ > return get_data(const_cast<std::vector<T,Allocator>&>(v)); >} > >template <class T> >T* get_data(std::valarray<T>& v) >{ > return v.size()==0 ? 0 : &(v[0]); >} > >template <class T> >const T* get_data(std::valarray<T> const& v) >{ > return get_data(const_cast<std::valarray<T>&>(v)); >} > >} >} >} ># 31 "/usr/include/boost/serialization/vector.hpp" 2 3 4 ># 46 "/usr/include/boost/serialization/vector.hpp" 3 4 >namespace boost { >namespace serialization { > > > > > > >template<class Archive, class U, class Allocator> >inline void save( > Archive & ar, > const std::vector<U, Allocator> &t, > const unsigned int , > mpl::false_ >){ > boost::serialization::stl::save_collection<Archive, std::vector<U, Allocator> >( > ar, t > ); >} > >template<class Archive, class U, class Allocator> >inline void load( > Archive & ar, > std::vector<U, Allocator> &t, > const unsigned int , > mpl::false_ >){ > boost::serialization::stl::load_collection< > Archive, > std::vector<U, Allocator>, > boost::serialization::stl::archive_input_seq< > Archive, std::vector<U, Allocator> > >, > boost::serialization::stl::reserve_imp<std::vector<U, Allocator> > > >(ar, t); >} > > > >template<class Archive, class U, class Allocator> >inline void save( > Archive & ar, > const std::vector<U, Allocator> &t, > const unsigned int , > mpl::true_ >){ > const collection_size_type count(t.size()); > ar << boost::serialization::make_nvp("count", count); > if (!t.empty()) > ar << make_array(detail::get_data(t),t.size()); >} > >template<class Archive, class U, class Allocator> >inline void load( > Archive & ar, > std::vector<U, Allocator> &t, > const unsigned int , > mpl::true_ >){ > collection_size_type count(t.size()); > ar >> boost::serialization::make_nvp("count", count); > t.resize(count); > unsigned int item_version=0; > if((ar.get_library_version()==4 || ar.get_library_version()==5)) { > ar >> boost::serialization::make_nvp("item_version", item_version); > } > if (!t.empty()) > ar >> make_array(detail::get_data(t),t.size()); > } > > > >template<class Archive, class U, class Allocator> >inline void save( > Archive & ar, > const std::vector<U, Allocator> &t, > const unsigned int file_version >){ > typedef typename > boost::serialization::use_array_optimization<Archive>::template apply< > typename remove_const<U>::type > >::type use_optimized; > save(ar,t,file_version, use_optimized()); >} > >template<class Archive, class U, class Allocator> >inline void load( > Archive & ar, > std::vector<U, Allocator> &t, > const unsigned int file_version >){ > > > > > > > > typedef typename > boost::serialization::use_array_optimization<Archive>::template apply< > typename remove_const<U>::type > >::type use_optimized; > load(ar,t,file_version, use_optimized()); >} > > > >template<class Archive, class U, class Allocator> >inline void serialize( > Archive & ar, > std::vector<U, Allocator> & t, > const unsigned int file_version >){ > boost::serialization::split_free(ar, t, file_version); >} > > > > > >template<class Archive, class Allocator> >inline void save( > Archive & ar, > const std::vector<bool, Allocator> &t, > const unsigned int >){ > > collection_size_type count (t.size()); > ar << boost::serialization::make_nvp("count", count); > std::vector<bool>::const_iterator it = t.begin(); > while(count-- > 0){ > bool tb = *it++; > ar << boost::serialization::make_nvp("item", tb); > } >} > >template<class Archive, class Allocator> >inline void load( > Archive & ar, > std::vector<bool, Allocator> &t, > const unsigned int >){ > > collection_size_type count; > ar >> boost::serialization::make_nvp("count", count); > t.clear(); > while(count-- > 0){ > bool i; > ar >> boost::serialization::make_nvp("item", i); > t.push_back(i); > } >} > > > >template<class Archive, class Allocator> >inline void serialize( > Archive & ar, > std::vector<bool, Allocator> & t, > const unsigned int file_version >){ > boost::serialization::split_free(ar, t, file_version); >} > > > >} >} > > > >namespace boost { namespace serialization { template<> struct implementation_level< std::vector < bool > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < signed char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < unsigned char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < signed int > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < unsigned int > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < signed long > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < unsigned long > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < float > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < double > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < unsigned short > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < signed short > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < boost::long_long_type > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < boost::ulong_long_type > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::vector < wchar_t > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; } } ># 8 "/c/honeypenny/src/common/crypto_boost_serialization.h" 2 ># 1 "/usr/include/boost/serialization/utility.hpp" 1 3 4 ># 28 "/usr/include/boost/serialization/utility.hpp" 3 4 >namespace boost { >namespace serialization { > > >template<class Archive, class F, class S> >inline void serialize( > Archive & ar, > std::pair<F, S> & p, > const unsigned int >){ > > > > typedef typename boost::remove_const<F>::type typef; > ar & boost::serialization::make_nvp("first", const_cast<typef &>(p.first)); > ar & boost::serialization::make_nvp("second", p.second); >} > > >template <class T, class U> >struct is_bitwise_serializable<std::pair<T,U> > > : public mpl::and_<is_bitwise_serializable< T >,is_bitwise_serializable<U> > >{ >}; > >} >} ># 9 "/c/honeypenny/src/common/crypto_boost_serialization.h" 2 ># 1 "/usr/include/boost/serialization/variant.hpp" 1 3 4 ># 46 "/usr/include/boost/serialization/variant.hpp" 3 4 >namespace boost { >namespace serialization { > >template<class Archive> >struct variant_save_visitor : > boost::static_visitor<> >{ > variant_save_visitor(Archive& ar) : > m_ar(ar) > {} > template<class T> > void operator()(T const & value) const > { > m_ar << boost::serialization::make_nvp("value", value); > } >private: > Archive & m_ar; >}; > >template<class Archive, class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >void save( > Archive & ar, > boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19> const & v, > unsigned int >){ > int which = v.which(); > ar << boost::serialization::make_nvp("which", which); > typedef typename boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19>::types types; > variant_save_visitor<Archive> visitor(ar); > v.apply_visitor(visitor); >} > >template<class S> >struct variant_impl { > > struct load_null { > template<class Archive, class V> > static void invoke( > Archive & , > int , > V & , > const unsigned int > ){} > }; > > struct load_impl { > template<class Archive, class V> > static void invoke( > Archive & ar, > int which, > V & v, > const unsigned int version > ){ > if(which == 0){ > > > > > typedef typename mpl::front<S>::type head_type; > head_type value; > ar >> boost::serialization::make_nvp("value", value); > v = value; > ar.reset_object_address(& boost::get<head_type>(v), & value); > return; > } > typedef typename mpl::pop_front<S>::type type; > variant_impl<type>::load(ar, which - 1, v, version); > } > }; > > template<class Archive, class V> > static void load( > Archive & ar, > int which, > V & v, > const unsigned int version > ){ > typedef typename mpl::eval_if<mpl::empty<S>, > mpl::identity<load_null>, > mpl::identity<load_impl> > >::type typex; > typex::invoke(ar, which, v, version); > } > >}; > >template<class Archive, class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >void load( > Archive & ar, > boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19>& v, > const unsigned int version >){ > int which; > typedef typename boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19>::types types; > ar >> boost::serialization::make_nvp("which", which); > if(which >= mpl::size<types>::value) > > boost::serialization::throw_exception( > boost::archive::archive_exception( > boost::archive::archive_exception::unsupported_version > ) > ); > variant_impl<types>::load(ar, which, v, version); >} > >template<class Archive, class T0 , class T1 , class T2 , class T3 , class T4 , class T5 , class T6 , class T7 , class T8 , class T9 , class T10 , class T11 , class T12 , class T13 , class T14 , class T15 , class T16 , class T17 , class T18 , class T19> >inline void serialize( > Archive & ar, > boost::variant< T0 , T1 , T2 , T3 , T4 , T5 , T6 , T7 , T8 , T9 , T10 , T11 , T12 , T13 , T14 , T15 , T16 , T17 , T18 , T19> & v, > const unsigned int file_version >){ > split_free(ar,v,file_version); >} > >} >} ># 10 "/c/honeypenny/src/common/crypto_boost_serialization.h" 2 ># 1 "/usr/include/boost/serialization/set.hpp" 1 3 4 ># 27 "/usr/include/boost/serialization/set.hpp" 3 4 >namespace boost { >namespace serialization { > >template<class Archive, class Key, class Compare, class Allocator > >inline void save( > Archive & ar, > const std::set<Key, Compare, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::save_collection< > Archive, std::set<Key, Compare, Allocator> > >(ar, t); >} > >template<class Archive, class Key, class Compare, class Allocator > >inline void load( > Archive & ar, > std::set<Key, Compare, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::load_collection< > Archive, > std::set<Key, Compare, Allocator>, > boost::serialization::stl::archive_input_set< > Archive, std::set<Key, Compare, Allocator> > >, > boost::serialization::stl::no_reserve_imp<std::set< > Key, Compare, Allocator> > > > >(ar, t); >} > > > >template<class Archive, class Key, class Compare, class Allocator > >inline void serialize( > Archive & ar, > std::set<Key, Compare, Allocator> & t, > const unsigned int file_version >){ > boost::serialization::split_free(ar, t, file_version); >} > > >template<class Archive, class Key, class Compare, class Allocator > >inline void save( > Archive & ar, > const std::multiset<Key, Compare, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::save_collection< > Archive, > std::multiset<Key, Compare, Allocator> > >(ar, t); >} > >template<class Archive, class Key, class Compare, class Allocator > >inline void load( > Archive & ar, > std::multiset<Key, Compare, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::load_collection< > Archive, > std::multiset<Key, Compare, Allocator>, > boost::serialization::stl::archive_input_set< > Archive, std::multiset<Key, Compare, Allocator> > >, > boost::serialization::stl::no_reserve_imp< > std::multiset<Key, Compare, Allocator> > > > >(ar, t); >} > > > >template<class Archive, class Key, class Compare, class Allocator > >inline void serialize( > Archive & ar, > std::multiset<Key, Compare, Allocator> & t, > const unsigned int file_version >){ > boost::serialization::split_free(ar, t, file_version); >} > >} >} > > > >namespace boost { namespace serialization { template<> struct implementation_level< std::set < bool > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < signed char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < unsigned char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < signed int > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < unsigned int > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < signed long > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < unsigned long > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < float > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < double > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < unsigned short > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < signed short > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < boost::long_long_type > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < boost::ulong_long_type > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::set < wchar_t > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; } } >namespace boost { namespace serialization { template<> struct implementation_level< std::multiset < bool > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < signed char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < unsigned char > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < signed int > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < unsigned int > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < signed long > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < unsigned long > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < float > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < double > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < unsigned short > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < signed short > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < boost::long_long_type > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < boost::ulong_long_type > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; template<> struct implementation_level< std::multiset < wchar_t > > { typedef mpl::integral_c_tag tag; typedef mpl::int_<object_serializable> type; static const int value = object_serializable; }; } } ># 11 "/c/honeypenny/src/common/crypto_boost_serialization.h" 2 ># 1 "/usr/include/boost/serialization/map.hpp" 1 3 4 ># 29 "/usr/include/boost/serialization/map.hpp" 3 4 >namespace boost { >namespace serialization { > >template<class Archive, class Type, class Key, class Compare, class Allocator > >inline void save( > Archive & ar, > const std::map<Key, Type, Compare, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::save_collection< > Archive, > std::map<Key, Type, Compare, Allocator> > >(ar, t); >} > >template<class Archive, class Type, class Key, class Compare, class Allocator > >inline void load( > Archive & ar, > std::map<Key, Type, Compare, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::load_collection< > Archive, > std::map<Key, Type, Compare, Allocator>, > boost::serialization::stl::archive_input_map< > Archive, std::map<Key, Type, Compare, Allocator> >, > boost::serialization::stl::no_reserve_imp<std::map< > Key, Type, Compare, Allocator > > > > > >(ar, t); >} > > > >template<class Archive, class Type, class Key, class Compare, class Allocator > >inline void serialize( > Archive & ar, > std::map<Key, Type, Compare, Allocator> &t, > const unsigned int file_version >){ > boost::serialization::split_free(ar, t, file_version); >} > > >template<class Archive, class Type, class Key, class Compare, class Allocator > >inline void save( > Archive & ar, > const std::multimap<Key, Type, Compare, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::save_collection< > Archive, > std::multimap<Key, Type, Compare, Allocator> > >(ar, t); >} > >template<class Archive, class Type, class Key, class Compare, class Allocator > >inline void load( > Archive & ar, > std::multimap<Key, Type, Compare, Allocator> &t, > const unsigned int >){ > boost::serialization::stl::load_collection< > Archive, > std::multimap<Key, Type, Compare, Allocator>, > boost::serialization::stl::archive_input_map< > Archive, std::multimap<Key, Type, Compare, Allocator> > >, > boost::serialization::stl::no_reserve_imp< > std::multimap<Key, Type, Compare, Allocator> > > > >(ar, t); >} > > > >template<class Archive, class Type, class Key, class Compare, class Allocator > >inline void serialize( > Archive & ar, > std::multimap<Key, Type, Compare, Allocator> &t, > const unsigned int file_version >){ > boost::serialization::split_free(ar, t, file_version); >} > >} >} ># 12 "/c/honeypenny/src/common/crypto_boost_serialization.h" 2 > > > > >namespace boost >{ > namespace serialization > { > > template <class Archive> > inline void serialize(Archive &a, crypto::public_key &x, const boost::serialization::version_type ver) > { > a & reinterpret_cast<char (&)[sizeof(crypto::public_key)]>(x); > } > template <class Archive> > inline void serialize(Archive &a, crypto::secret_key &x, const boost::serialization::version_type ver) > { > a & reinterpret_cast<char (&)[sizeof(crypto::secret_key)]>(x); > } > template <class Archive> > inline void serialize(Archive &a, crypto::key_derivation &x, const boost::serialization::version_type ver) > { > a & reinterpret_cast<char (&)[sizeof(crypto::key_derivation)]>(x); > } > template <class Archive> > inline void serialize(Archive &a, crypto::key_image &x, const boost::serialization::version_type ver) > { > a & reinterpret_cast<char (&)[sizeof(crypto::key_image)]>(x); > } > > template <class Archive> > inline void serialize(Archive &a, crypto::signature &x, const boost::serialization::version_type ver) > { > a & reinterpret_cast<char (&)[sizeof(crypto::signature)]>(x); > } > template <class Archive> > inline void serialize(Archive &a, crypto::hash &x, const boost::serialization::version_type ver) > { > a & reinterpret_cast<char (&)[sizeof(crypto::hash)]>(x); > } > } >} ># 8 "/c/honeypenny/src/p2p/maintainers_info_boost_serialization.h" 2 > >namespace boost >{ > namespace serialization > { > template <class Archive, class ver_type> > inline void serialize(Archive &a, nodetool::alert_condition& ac, const ver_type ver) > { > a & ac.alert_mode; > a & ac.if_build_less_then; > } > > template <class Archive, class ver_type> > inline void serialize(Archive &a, nodetool::maintainers_info& mi, const ver_type ver) > { > a & mi.timestamp; > a & mi.ver_major; > a & mi.ver_minor; > a & mi.ver_revision; > a & mi.build_no; > a & mi.conditions; > } > > template <class Archive, class ver_type> > inline void serialize(Archive &a, nodetool::maintainers_entry& me, const ver_type ver) > { > a & me.maintainers_info_buff; > a & me.sign; > } > } >} ># 28 "/c/honeypenny/src/p2p/net_node.h" 2 > >using namespace epee; ># 34 "/c/honeypenny/src/p2p/net_node.h" >#pragma GCC diagnostic push ># 34 "/c/honeypenny/src/p2p/net_node.h" > > > >namespace nodetool >{ > template<class base_type> > struct p2p_connection_context_t: base_type > { > peerid_type peer_id; > }; > > template<class t_payload_net_handler> > class node_server: public levin::levin_commands_handler<p2p_connection_context_t<typename t_payload_net_handler::connection_context> >, > public i_p2p_endpoint<typename t_payload_net_handler::connection_context> > { > struct by_conn_id{}; > struct by_peer_id{}; > struct by_addr{}; > > typedef p2p_connection_context_t<typename t_payload_net_handler::connection_context> p2p_connection_context; > > typedef COMMAND_HANDSHAKE_T<typename t_payload_net_handler::payload_type> COMMAND_HANDSHAKE; > typedef COMMAND_TIMED_SYNC_T<typename t_payload_net_handler::payload_type> COMMAND_TIMED_SYNC; > > public: > typedef t_payload_net_handler payload_net_handler; > > node_server(t_payload_net_handler& payload_handler):m_payload_handler(payload_handler), > m_allow_local_ip(false), > m_hide_my_port(false), > m_alert_mode(0), > m_maintainers_entry_local(boost::value_initialized<decltype(m_maintainers_entry_local)>()), > m_maintainers_info_local(boost::value_initialized<decltype(m_maintainers_info_local)>()) > {} > > static void init_options(boost::program_options::options_description& desc); > > bool run(); > bool init(const boost::program_options::variables_map& vm); > bool deinit(); > bool send_stop_signal(); > uint32_t get_this_peer_port(){return m_listenning_port;} > t_payload_net_handler& get_payload_object(); > > template <class Archive, class t_version_type> > void serialize(Archive &a, const t_version_type ver) > { > a & m_peerlist; > a & m_config.m_peer_id; > if(ver < 2) > return; > a & m_maintainers_info_local; > a & m_maintainers_entry_local; > a & m_alert_mode; > } > > bool log_peerlist(); > bool log_connections(); > virtual uint64_t get_connections_count(); > size_t get_outgoing_connections_count(); > peerlist_manager& get_peerlist_manager(){return m_peerlist;} > bool handle_maintainers_entry(const maintainers_entry& me); > private: > typedef COMMAND_REQUEST_STAT_INFO_T<typename t_payload_net_handler::stat_info> COMMAND_REQUEST_STAT_INFO; > > int invoke(int command, const std::string& in_buff, std::string& buff_out, p2p_connection_context& context) { bool handled = false; return handle_invoke_map(false, command, in_buff, buff_out, context, handled); }; > int notify(int command, const std::string& in_buff, p2p_connection_context& context) { bool handled = false; std::string fake_str; return handle_invoke_map(true, command, in_buff, fake_str, context, handled); }; > > template <class t_context> int handle_invoke_map(bool is_notify, int command, const std::string& in_buff, std::string& buff_out, t_context& context, bool& handled) { typedef node_server internal_owner_type_name; > if(!is_notify && COMMAND_HANDSHAKE::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename COMMAND_HANDSHAKE::request, typename COMMAND_HANDSHAKE::response>(command, in_buff, buff_out, boost::bind(&node_server::handle_handshake, this, _1, _2, _3, _4), context);} > if(!is_notify && COMMAND_TIMED_SYNC::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename COMMAND_TIMED_SYNC::request, typename COMMAND_TIMED_SYNC::response>(command, in_buff, buff_out, boost::bind(&node_server::handle_timed_sync, this, _1, _2, _3, _4), context);} > if(!is_notify && COMMAND_PING::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename COMMAND_PING::request, typename COMMAND_PING::response>(command, in_buff, buff_out, boost::bind(&node_server::handle_ping, this, _1, _2, _3, _4), context);} > > if(!is_notify && COMMAND_REQUEST_STAT_INFO::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename COMMAND_REQUEST_STAT_INFO::request, typename COMMAND_REQUEST_STAT_INFO::response>(command, in_buff, buff_out, boost::bind(&node_server::handle_get_stat_info, this, _1, _2, _3, _4), context);} > if(!is_notify && COMMAND_REQUEST_NETWORK_STATE::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename COMMAND_REQUEST_NETWORK_STATE::request, typename COMMAND_REQUEST_NETWORK_STATE::response>(command, in_buff, buff_out, boost::bind(&node_server::handle_get_network_state, this, _1, _2, _3, _4), context);} > if(!is_notify && COMMAND_REQUEST_PEER_ID::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename COMMAND_REQUEST_PEER_ID::request, typename COMMAND_REQUEST_PEER_ID::response>(command, in_buff, buff_out, boost::bind(&node_server::handle_get_peer_id, this, _1, _2, _3, _4), context);} > > { int res = m_payload_handler.handle_invoke_map(is_notify, command, in_buff, buff_out, static_cast<typename t_payload_net_handler::connection_context&>(context), handled); if(handled) return res; } > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.h" << ":" << 112 << "|" << __FUNCTION__ << "|" << "Unkonown command:" << command << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return -6; } > > > int handle_handshake(int command, typename COMMAND_HANDSHAKE::request& arg, typename COMMAND_HANDSHAKE::response& rsp, p2p_connection_context& context); > int handle_timed_sync(int command, typename COMMAND_TIMED_SYNC::request& arg, typename COMMAND_TIMED_SYNC::response& rsp, p2p_connection_context& context); > int handle_ping(int command, COMMAND_PING::request& arg, COMMAND_PING::response& rsp, p2p_connection_context& context); > > int handle_get_stat_info(int command, typename COMMAND_REQUEST_STAT_INFO::request& arg, typename COMMAND_REQUEST_STAT_INFO::response& rsp, p2p_connection_context& context); > int handle_get_network_state(int command, COMMAND_REQUEST_NETWORK_STATE::request& arg, COMMAND_REQUEST_NETWORK_STATE::response& rsp, p2p_connection_context& context); > int handle_get_peer_id(int command, COMMAND_REQUEST_PEER_ID::request& arg, COMMAND_REQUEST_PEER_ID::response& rsp, p2p_connection_context& context); > > bool init_config(); > bool make_default_config(); > bool store_config(); > bool check_trust(const proof_of_trust& tr); > > > > virtual void on_connection_new(p2p_connection_context& context); > virtual void on_connection_close(p2p_connection_context& context); > virtual void callback(p2p_connection_context& context); > > virtual bool relay_notify_to_all(int command, const std::string& data_buff, const epee::net_utils::connection_context_base& context); > virtual bool invoke_command_to_peer(int command, const std::string& req_buff, std::string& resp_buff, const epee::net_utils::connection_context_base& context); > virtual bool invoke_notify_to_peer(int command, const std::string& req_buff, const epee::net_utils::connection_context_base& context); > virtual bool drop_connection(const epee::net_utils::connection_context_base& context); > virtual void request_callback(const epee::net_utils::connection_context_base& context); > virtual void for_each_connection(std::function<bool(typename t_payload_net_handler::connection_context&, peerid_type)> f); > > bool parse_peer_from_string(nodetool::net_address& pe, const std::string& node_addr); > bool handle_command_line(const boost::program_options::variables_map& vm); > bool idle_worker(); > bool handle_remote_peerlist(const std::list<peerlist_entry>& peerlist, time_t local_time, const net_utils::connection_context_base& context); > bool get_local_node_data(basic_node_data& node_data); > > > bool merge_peerlist_with_local(const std::list<peerlist_entry>& bs); > bool fix_time_delta(std::list<peerlist_entry>& local_peerlist, time_t local_time, int64_t& delta); > > bool connections_maker(); > bool peer_sync_idle_maker(); > bool do_handshake_with_peer(peerid_type& pi, p2p_connection_context& context, bool just_take_peerlist = false); > bool do_peer_timed_sync(const net_utils::connection_context_base& context, peerid_type peer_id); > > bool make_new_connection_from_peerlist(bool use_white_list); > bool try_to_connect_and_handshake_with_new_peer(const net_address& na, bool just_take_peerlist = false, uint64_t last_seen_stamp = 0, bool white = true); > size_t get_random_index_with_fixed_probability(size_t max_index); > bool is_peer_used(const peerlist_entry& peer); > bool is_addr_connected(const net_address& peer); > template<class t_callback> > bool try_ping(basic_node_data& node_data, p2p_connection_context& context, t_callback cb); > bool make_expected_connections_count(bool white_list, size_t expected_connections); > void cache_connect_fail_info(const net_address& addr); > bool is_addr_recently_failed(const net_address& addr); > bool fill_maintainers_entry(maintainers_entry& me); > bool on_maintainers_entry_update(); > bool handle_alert_conditions(); > > bool clam_alert_worker(); > bool urgent_alert_worker(); > bool critical_alert_worker(); > > > > std::string print_connections_container(); > > > typedef net_utils::boosted_tcp_server<levin::async_protocol_handler<p2p_connection_context> > net_server; > > struct config > { > network_config m_net_config; > uint64_t m_peer_id; > > public: template<class t_storage> bool store( t_storage& st, typename t_storage::hsection hparent_section = nullptr) const { return serialize_map<true>(*this, st, hparent_section); } template<class t_storage> bool _load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { return serialize_map<false>(*this, stg, hparent_section); } template<class t_storage> bool load( t_storage& stg, typename t_storage::hsection hparent_section = nullptr) { try{ return serialize_map<false>(*this, stg, hparent_section); } catch(const std::exception& err) { (void)(err); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.h" << ":" << 186 << "|" << __FUNCTION__ << "|" << "Exception on unserializing: " << err.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } } template<bool is_store, class this_type, class t_storage> static bool serialize_map(this_type& this_ref, t_storage& stg, typename t_storage::hsection hparent_section) { > epee::serialization::selector<is_store>::serialize(this_ref.m_net_config, stg, hparent_section, "m_net_config"); > epee::serialization::selector<is_store>::serialize(this_ref.m_peer_id, stg, hparent_section, "m_peer_id"); > return true;} > }; > > config m_config; > std::string m_config_folder; > > bool m_have_address; > bool m_first_connection_maker_call; > uint32_t m_listenning_port; > uint32_t m_external_port; > uint32_t m_ip_address; > bool m_allow_local_ip; > bool m_hide_my_port; > > > > > t_payload_net_handler& m_payload_handler; > peerlist_manager m_peerlist; > > math_helper::once_a_time_seconds<60> m_peer_handshake_idle_maker_interval; > math_helper::once_a_time_seconds<1> m_connections_maker_interval; > math_helper::once_a_time_seconds<60*30, false> m_peerlist_store_interval; > > > math_helper::once_a_time_seconds<60, false> m_calm_alert_interval; > math_helper::once_a_time_seconds<10, false> m_urgent_alert_interval; > math_helper::once_a_time_seconds<1, false> m_critical_alert_interval; > > std::string m_bind_ip; > std::string m_port; > > int64_t m_last_stat_request_time; > > std::list<net_address> m_priority_peers; > std::vector<net_address> m_seed_nodes; > std::list<nodetool::peerlist_entry> m_command_line_peers; > int64_t m_peer_livetime; > > net_server m_net_server; > > std::map<net_address, time_t> m_conn_fails_cache; > critical_section m_conn_fails_cache_lock; > crypto::public_key m_maintainers_pub_key; > > maintainers_info m_maintainers_info_local; > maintainers_entry m_maintainers_entry_local; > uint8_t m_alert_mode; > critical_section m_maintainers_local_lock; > > }; >} > > > > ># 1 "/c/honeypenny/src/p2p/net_node.inl" 1 > > > > > > ># 1 "/c/honeypenny/build/version/version.h" 1 ># 8 "/c/honeypenny/src/p2p/net_node.inl" 2 > ># 1 "/c/honeypenny/src/common/command_line.h" 1 ># 15 "/c/honeypenny/src/common/command_line.h" >namespace command_line >{ > template<typename T, bool required = false> > struct arg_descriptor; > > template<typename T> > struct arg_descriptor<T, false> > { > typedef T value_type; > > const char* name; > const char* description; > T default_value; > bool not_use_default; > }; > > template<typename T> > struct arg_descriptor<std::vector<T>, false> > { > typedef std::vector<T> value_type; > > const char* name; > const char* description; > }; > > template<typename T> > struct arg_descriptor<T, true> > { > static_assert(!std::is_same<T, bool>::value, "Boolean switch can't be required"); > > typedef T value_type; > > const char* name; > const char* description; > }; > > template<typename T> > boost::program_options::typed_value<T, char>* make_semantic(const arg_descriptor<T, true>& ) > { > return boost::program_options::value<T>()->required(); > } > > template<typename T> > boost::program_options::typed_value<T, char>* make_semantic(const arg_descriptor<T, false>& arg) > { > auto semantic = boost::program_options::value<T>(); > if (!arg.not_use_default) > semantic->default_value(arg.default_value); > return semantic; > } > > template<typename T> > boost::program_options::typed_value<T, char>* make_semantic(const arg_descriptor<T, false>& arg, const T& def) > { > auto semantic = boost::program_options::value<T>(); > if (!arg.not_use_default) > semantic->default_value(def); > return semantic; > } > > template<typename T> > boost::program_options::typed_value<std::vector<T>, char>* make_semantic(const arg_descriptor<std::vector<T>, false>& ) > { > auto semantic = boost::program_options::value< std::vector<T> >(); > semantic->default_value(std::vector<T>(), ""); > return semantic; > } > > template<typename T, bool required> > void add_arg(boost::program_options::options_description& description, const arg_descriptor<T, required>& arg, bool unique = true) > { > if (0 != description.find_nothrow(arg.name, false)) > { > do{if(!(!unique)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/common/command_line.h" << ":" << 88 << "|" << __FUNCTION__ << "|" << "Argument already exists: " << arg.name << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void();};}while(0); > return; > } > > description.add_options()(arg.name, make_semantic(arg), arg.description); > } > > template<typename T> > void add_arg(boost::program_options::options_description& description, const arg_descriptor<T, false>& arg, const T& def, bool unique = true) > { > if (0 != description.find_nothrow(arg.name, false)) > { > do{if(!(!unique)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/common/command_line.h" << ":" << 100 << "|" << __FUNCTION__ << "|" << "Argument already exists: " << arg.name << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void();};}while(0); > return; > } > > description.add_options()(arg.name, make_semantic(arg, def), arg.description); > } > > template<> > inline void add_arg(boost::program_options::options_description& description, const arg_descriptor<bool, false>& arg, bool unique) > { > if (0 != description.find_nothrow(arg.name, false)) > { > do{if(!(!unique)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/common/command_line.h" << ":" << 112 << "|" << __FUNCTION__ << "|" << "Argument already exists: " << arg.name << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return void();};}while(0); > return; > } > > description.add_options()(arg.name, boost::program_options::bool_switch(), arg.description); > } > > template<typename charT> > boost::program_options::basic_parsed_options<charT> parse_command_line(int argc, const charT* const argv[], > const boost::program_options::options_description& desc, bool allow_unregistered = false) > { > auto parser = boost::program_options::command_line_parser(argc, argv); > parser.options(desc); > if (allow_unregistered) > { > parser.allow_unregistered(); > } > return parser.run(); > } > > template<typename F> > bool handle_error_helper(const boost::program_options::options_description& desc, F parser) > { > try > { > return parser(); > } > catch (std::exception& e) > { > std::cerr << "Failed to parse arguments: " << e.what() << std::endl; > std::cerr << desc << std::endl; > return false; > } > catch (...) > { > std::cerr << "Failed to parse arguments: unknown exception" << std::endl; > std::cerr << desc << std::endl; > return false; > } > } > > template<typename T, bool required> > bool has_arg(const boost::program_options::variables_map& vm, const arg_descriptor<T, required>& arg) > { > auto value = vm[arg.name]; > return !value.empty(); > } > > > template<typename T, bool required> > T get_arg(const boost::program_options::variables_map& vm, const arg_descriptor<T, required>& arg) > { > return vm[arg.name].template as<T>(); > } > > template<> > inline bool has_arg<bool, false>(const boost::program_options::variables_map& vm, const arg_descriptor<bool, false>& arg) > { > return get_arg<bool, false>(vm, arg); > } > > > extern const arg_descriptor<bool> arg_help; > extern const arg_descriptor<bool> arg_version; > extern const arg_descriptor<std::string> arg_data_dir; >} ># 10 "/c/honeypenny/src/p2p/net_node.inl" 2 > ># 1 "/c/honeypenny/contrib/epee/include/net/net_helper.h" 1 ># 30 "/c/honeypenny/contrib/epee/include/net/net_helper.h" ># 40 "/c/honeypenny/contrib/epee/include/net/net_helper.h" ># 1 "/usr/include/boost/preprocessor/selection/min.hpp" 1 3 4 ># 41 "/c/honeypenny/contrib/epee/include/net/net_helper.h" 2 > > > > > > ># 1 "/c/honeypenny/contrib/epee/include/net/../string_tools.h" 1 ># 48 "/c/honeypenny/contrib/epee/include/net/net_helper.h" 2 > > > > > > >namespace epee >{ >namespace net_utils >{ > > class blocked_mode_client > { > > > struct handler_obj > { > handler_obj(boost::system::error_code& error, size_t& bytes_transferred):ref_error(error), ref_bytes_transferred(bytes_transferred) > {} > handler_obj(const handler_obj& other_obj):ref_error(other_obj.ref_error), ref_bytes_transferred(other_obj.ref_bytes_transferred) > {} > > boost::system::error_code& ref_error; > size_t& ref_bytes_transferred; > > void operator()(const boost::system::error_code& error, > std::size_t bytes_transferred > ) > { > ref_error = error; > ref_bytes_transferred = bytes_transferred; > } > }; > > public: > inline > blocked_mode_client():m_socket(m_io_service), > m_initialized(false), > m_connected(false), > m_deadline(m_io_service), > m_shutdowned(0) > { > > > m_initialized = true; > > > > > > m_deadline.expires_at(boost::posix_time::pos_infin); > > > check_deadline(); > > } > inline > ~blocked_mode_client() > { > > shutdown(); > } > > inline void set_recv_timeout(int reciev_timeout) > { > m_reciev_timeout = reciev_timeout; > } > > inline > bool connect(const std::string& addr, int port, unsigned int connect_timeout, unsigned int reciev_timeout, const std::string& bind_ip = "0.0.0.0") > { > return connect(addr, std::to_string(port), connect_timeout, reciev_timeout, bind_ip); > } > > inline > bool connect(const std::string& addr, const std::string& port, unsigned int connect_timeout, unsigned int reciev_timeout, const std::string& bind_ip = "0.0.0.0") > { > m_connect_timeout = connect_timeout; > m_reciev_timeout = reciev_timeout; > m_connected = false; > if(!m_reciev_timeout) > m_reciev_timeout = m_connect_timeout; > > try > { > m_socket.close(); > > > > > > boost::asio::ip::tcp::resolver resolver(m_io_service); > boost::asio::ip::tcp::resolver::query query(boost::asio::ip::tcp::v4(), addr, port); > boost::asio::ip::tcp::resolver::iterator iterator = resolver.resolve(query); > boost::asio::ip::tcp::resolver::iterator end; > if(iterator == end) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 145 << "|" << __FUNCTION__ << "|" << "Failed to resolve " << addr << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > > > > > boost::asio::ip::tcp::endpoint remote_endpoint(*iterator); > > > m_socket.open(remote_endpoint.protocol()); > if(bind_ip != "0.0.0.0" && bind_ip != "0" && bind_ip != "" ) > { > boost::asio::ip::tcp::endpoint local_endpoint(boost::asio::ip::address::from_string(addr.c_str()), 0); > m_socket.bind(local_endpoint); > } > > > m_deadline.expires_from_now(boost::posix_time::milliseconds(m_connect_timeout)); > > > boost::system::error_code ec = boost::asio::error::would_block; > > > m_socket.async_connect(remote_endpoint, boost::lambda::var(ec) = boost::lambda::_1); > while (ec == boost::asio::error::would_block) > { > m_io_service.run_one(); > } > > if (!ec && m_socket.is_open()) > { > m_connected = true; > m_deadline.expires_at(boost::posix_time::pos_infin); > return true; > }else > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Some problems at connect, message: " << ec.message() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > return false; > } > > } > catch(const boost::system::system_error& er) > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Some problems at connect, message: " << er.what() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > return false; > } > catch(...) > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Some fatal problems." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > return false; > } > > return true; > } > > > inline > bool disconnect() > { > try > { > if(m_connected) > { > m_connected = false; > m_socket.shutdown(boost::asio::ip::tcp::socket::shutdown_both); > > } > } > > catch(const boost::system::system_error& ) > { > > return false; > } > catch(...) > { > > return false; > } > return true; > } > > > inline > bool send(const std::string& buff) > { > > try > { > m_deadline.expires_from_now(boost::posix_time::milliseconds(m_reciev_timeout)); > > > > > > > boost::system::error_code ec = boost::asio::error::would_block; > > > > > > boost::asio::async_write(m_socket, boost::asio::buffer(buff), boost::lambda::var(ec) = boost::lambda::_1); > > > while (ec == boost::asio::error::would_block) > { > m_io_service.run_one(); > } > > if (ec) > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Problems at write: " << ec.message() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > m_connected = false; > return false; > }else > { > m_deadline.expires_at(boost::posix_time::pos_infin); > } > } > > catch(const boost::system::system_error& er) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 270 << "|" << __FUNCTION__ << "|" << "Some problems at connect, message: " << er.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > catch(...) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 275 << "|" << __FUNCTION__ << "|" << "Some fatal problems." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > return true; > } > > inline > bool send(const void* data, size_t sz) > { > try > { ># 309 "/c/honeypenny/contrib/epee/include/net/net_helper.h" > boost::system::error_code ec; > > size_t writen = m_socket.write_some(boost::asio::buffer(data, sz), ec); > > > > if (!writen || ec) > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Problems at write: " << ec.message() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > m_connected = false; > return false; > }else > { > m_deadline.expires_at(boost::posix_time::pos_infin); > } > } > > catch(const boost::system::system_error& er) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 328 << "|" << __FUNCTION__ << "|" << "Some problems at send, message: " << er.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_connected = false; > return false; > } > catch(...) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 334 << "|" << __FUNCTION__ << "|" << "Some fatal problems." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > return true; > } > > bool is_connected() > { > return m_connected && m_socket.is_open(); > > > > } > > inline > bool recv(std::string& buff) > { > > try > { > > > > m_deadline.expires_from_now(boost::posix_time::milliseconds(m_reciev_timeout)); ># 372 "/c/honeypenny/contrib/epee/include/net/net_helper.h" > boost::system::error_code ec = boost::asio::error::would_block; > size_t bytes_transfered = 0; > > handler_obj hndlr(ec, bytes_transfered); > > char local_buff[10000] = {0}; > > boost::asio::async_read(m_socket, boost::asio::buffer(local_buff, sizeof(local_buff)), boost::asio::transfer_at_least(1), hndlr); > > > while (ec == boost::asio::error::would_block && !boost::interprocess::ipcdetail::atomic_read32(&m_shutdowned)) > { > m_io_service.run_one(); > } > > > if (ec) > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "READ ENDS: Connection err_code " << ec.value() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > if(ec == boost::asio::error::eof) > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Connection err_code eof." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > > return true; > } > > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Problems at read: " << ec.message() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > m_connected = false; > return false; > }else > { > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "READ ENDS: Success. bytes_tr: " << bytes_transfered << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > m_deadline.expires_at(boost::posix_time::pos_infin); > } > > > > > buff.assign(local_buff, bytes_transfered); > return true; > } > > catch(const boost::system::system_error& er) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 416 << "|" << __FUNCTION__ << "|" << "Some problems at read, message: " << er.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_connected = false; > return false; > } > catch(...) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 422 << "|" << __FUNCTION__ << "|" << "Some fatal problems at read." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > > > return false; > > } > > inline bool recv_n(std::string& buff, int64_t sz) > { > > try > { > > > > m_deadline.expires_from_now(boost::posix_time::milliseconds(m_reciev_timeout)); ># 454 "/c/honeypenny/contrib/epee/include/net/net_helper.h" > buff.resize(static_cast<size_t>(sz)); > boost::system::error_code ec = boost::asio::error::would_block; > size_t bytes_transfered = 0; > > > handler_obj hndlr(ec, bytes_transfered); > > > boost::asio::async_read(m_socket, boost::asio::buffer((char*)buff.data(), buff.size()), boost::asio::transfer_at_least(buff.size()), hndlr); > > > while (ec == boost::asio::error::would_block && !boost::interprocess::ipcdetail::atomic_read32(&m_shutdowned)) > { > m_io_service.run_one(); > } > > if (ec) > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Problems at read: " << ec.message() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > m_connected = false; > return false; > }else > { > m_deadline.expires_at(boost::posix_time::pos_infin); > } > > if(bytes_transfered != buff.size()) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 482 << "|" << __FUNCTION__ << "|" << "Transferred missmatch with transfer_at_least value: m_bytes_transferred=" << bytes_transfered << " at_least value=" << buff.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > return true; > } > > catch(const boost::system::system_error& er) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 491 << "|" << __FUNCTION__ << "|" << "Some problems at read, message: " << er.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_connected = false; > return false; > } > catch(...) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 497 << "|" << __FUNCTION__ << "|" << "Some fatal problems at read." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > > > return false; > } > > bool shutdown() > { > m_deadline.cancel(); > boost::system::error_code ignored_ec; > m_socket.cancel(ignored_ec); > m_socket.shutdown(boost::asio::ip::tcp::socket::shutdown_both, ignored_ec); > m_socket.close(ignored_ec); > boost::interprocess::ipcdetail::atomic_write32(&m_shutdowned, 1); > m_connected = false; > return true; > } > > void set_connected(bool connected) > { > m_connected = connected; > } > boost::asio::io_service& get_io_service() > { > return m_io_service; > } > > boost::asio::ip::tcp::socket& get_socket() > { > return m_socket; > } > > private: > > void check_deadline() > { > > > > if (m_deadline.expires_at() <= boost::asio::deadline_timer::traits_type::now()) > { > > > > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Timed out socket" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > m_connected = false; > m_socket.close(); > > > > m_deadline.expires_at(boost::posix_time::pos_infin); > } > > > m_deadline.async_wait(boost::bind(&blocked_mode_client::check_deadline, this)); > } > > > > protected: > boost::asio::io_service m_io_service; > boost::asio::ip::tcp::socket m_socket; > int m_connect_timeout; > int m_reciev_timeout; > bool m_initialized; > bool m_connected; > boost::asio::deadline_timer m_deadline; > volatile uint32_t m_shutdowned; > }; > > > > > > class async_blocked_mode_client: public blocked_mode_client > { > public: > async_blocked_mode_client():m_send_deadline(blocked_mode_client::m_io_service) > { > > > > > m_send_deadline.expires_at(boost::posix_time::pos_infin); > > > check_send_deadline(); > } > ~async_blocked_mode_client() > { > m_send_deadline.cancel(); > } > > bool shutdown() > { > blocked_mode_client::shutdown(); > m_send_deadline.cancel(); > return true; > } > > inline > bool send(const void* data, size_t sz) > { > try > { ># 627 "/c/honeypenny/contrib/epee/include/net/net_helper.h" > boost::system::error_code ec; > > size_t writen = m_socket.write_some(boost::asio::buffer(data, sz), ec); > > if (!writen || ec) > { > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Problems at write: " << ec.message() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > return false; > }else > { > m_send_deadline.expires_at(boost::posix_time::pos_infin); > } > } > > catch(const boost::system::system_error& er) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 643 << "|" << __FUNCTION__ << "|" << "Some problems at connect, message: " << er.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > catch(...) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/contrib/epee/include/net/net_helper.h" << ":" << 648 << "|" << __FUNCTION__ << "|" << "Some fatal problems." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > return true; > } > > > private: > > boost::asio::deadline_timer m_send_deadline; > > void check_send_deadline() > { > > > > if (m_send_deadline.expires_at() <= boost::asio::deadline_timer::traits_type::now()) > { > > > > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Timed out socket" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > m_socket.close(); > > > > m_send_deadline.expires_at(boost::posix_time::pos_infin); > } > > > m_send_deadline.async_wait(boost::bind(&async_blocked_mode_client::check_send_deadline, this)); > } > }; >} >} ># 12 "/c/honeypenny/src/p2p/net_node.inl" 2 ># 21 "/c/honeypenny/src/p2p/net_node.inl" >namespace nodetool >{ > namespace > { > const command_line::arg_descriptor<std::string> arg_p2p_bind_ip = {"p2p-bind-ip", "Interface for p2p network protocol", "0.0.0.0"}; > const command_line::arg_descriptor<std::string> arg_p2p_bind_port = {"p2p-bind-port", "Port for p2p network protocol", boost::to_string(20101)}; > const command_line::arg_descriptor<uint32_t> arg_p2p_external_port = {"p2p-external-port", "External port for p2p network protocol (if port forwarding used with NAT)", 0}; > const command_line::arg_descriptor<bool> arg_p2p_allow_local_ip = {"allow-local-ip", "Allow local ip add to peer list, mostly in debug purposes"}; > const command_line::arg_descriptor<std::vector<std::string> > arg_p2p_add_peer = {"add-peer", "Manually add peer to local peerlist"}; > const command_line::arg_descriptor<std::vector<std::string> > arg_p2p_add_priority_node = {"add-priority-node", "Specify list of peers to connect to and attempt to keep the connection open"}; > const command_line::arg_descriptor<std::vector<std::string> > arg_p2p_seed_node = {"seed-node", "Connect to a node to retrieve peer addresses, and disconnect"}; > const command_line::arg_descriptor<bool> arg_p2p_hide_my_port = {"hide-my-port", "Do not announce yourself as peerlist candidate", false, true}; } > > > template<class t_payload_net_handler> > void node_server<t_payload_net_handler>::init_options(boost::program_options::options_description& desc) > { > command_line::add_arg(desc, arg_p2p_bind_ip); > command_line::add_arg(desc, arg_p2p_bind_port); > command_line::add_arg(desc, arg_p2p_external_port); > command_line::add_arg(desc, arg_p2p_allow_local_ip); > command_line::add_arg(desc, arg_p2p_add_peer); > command_line::add_arg(desc, arg_p2p_add_priority_node); > command_line::add_arg(desc, arg_p2p_seed_node); > command_line::add_arg(desc, arg_p2p_hide_my_port); } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::init_config() > { > > try {; > bool r = string_tools::hex_to_pod("d2f6bc35dc4e4a43235ae12620df4612df590c6e1df0a18a55c5e12d81502aa7", m_maintainers_pub_key); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 53 << "|" << __FUNCTION__ << "|" << "Failed to parse P2P_MAINTAINERS_PUB_KEY = " << "d2f6bc35dc4e4a43235ae12620df4612df590c6e1df0a18a55c5e12d81502aa7" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > make_default_config(); > > std::string state_file_path = m_config_folder + "/" + "p2pstate.bin"; > tools::unserialize_obj_from_file(*this, state_file_path); > > > m_config.m_net_config.handshake_interval = 60; > m_config.m_net_config.connections_count = 8; > m_config.m_net_config.packet_max_size = 50000000; > m_config.m_net_config.config_id = 0; > m_config.m_net_config.connection_timeout = 5000; > m_config.m_net_config.ping_connection_timeout = 2000; > m_config.m_net_config.send_peerlist_sz = 250; > > m_first_connection_maker_call = true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 70 << "|" << __FUNCTION__ << "|" << "Exception at [" << "node_server::init_config" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 70 << "|" << __FUNCTION__ << "|" << "Exception at [" << "node_server::init_config" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > return true; > } > > template<class t_payload_net_handler> > void node_server<t_payload_net_handler>::for_each_connection(std::function<bool(typename t_payload_net_handler::connection_context&, peerid_type)> f) > { > m_net_server.get_config_object().foreach_connection([&](p2p_connection_context& cntx){ > return f(cntx, cntx.peer_id); > }); > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::make_default_config() > { > m_config.m_peer_id = crypto::rand<uint64_t>(); > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::parse_peer_from_string(nodetool::net_address& pe, const std::string& node_addr) > { > return string_tools::parse_peer_from_string(pe.ip, pe.port, node_addr); > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::handle_command_line(const boost::program_options::variables_map& vm) > { > m_bind_ip = command_line::get_arg(vm, arg_p2p_bind_ip); > m_port = command_line::get_arg(vm, arg_p2p_bind_port); > m_external_port = command_line::get_arg(vm, arg_p2p_external_port); > m_allow_local_ip = command_line::get_arg(vm, arg_p2p_allow_local_ip); > > if (command_line::has_arg(vm, arg_p2p_add_peer)) > { > std::vector<std::string> perrs = command_line::get_arg(vm, arg_p2p_add_peer); > for(const std::string& pr_str: perrs) > { > nodetool::peerlist_entry pe = boost::value_initialized<decltype(pe)>(); > pe.id = crypto::rand<uint64_t>(); > bool r = parse_peer_from_string(pe.adr, pr_str); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 111 << "|" << __FUNCTION__ << "|" << "Failed to parse address from string: " << pr_str << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > m_command_line_peers.push_back(pe); > } > } > > if (command_line::has_arg(vm, arg_p2p_add_priority_node)) > { > std::vector<std::string> perrs = command_line::get_arg(vm, arg_p2p_add_priority_node); > for(const std::string& pr_str: perrs) > { > nodetool::net_address na = boost::value_initialized<decltype(na)>(); > bool r = parse_peer_from_string(na, pr_str); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 123 << "|" << __FUNCTION__ << "|" << "Failed to parse address from string: " << pr_str << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > m_priority_peers.push_back(na); > } > } > if (command_line::has_arg(vm, arg_p2p_seed_node)) > { > std::vector<std::string> seed_perrs = command_line::get_arg(vm, arg_p2p_seed_node); > for(const std::string& pr_str: seed_perrs) > { > nodetool::net_address na = boost::value_initialized<decltype(na)>(); > bool r = parse_peer_from_string(na, pr_str); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 134 << "|" << __FUNCTION__ << "|" << "Failed to parse seed address from string: " << pr_str << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > m_seed_nodes.push_back(na); > } > } > if(command_line::has_arg(vm, arg_p2p_hide_my_port)) > m_hide_my_port = true; return true; > } > > namespace > { > template<typename T> > bool append_net_address(T& nodes, const std::string& addr) > { > using namespace boost::asio; > > size_t pos = addr.find_last_of(':'); > do{if(!(std::string::npos != pos && addr.length() - 1 != pos && 0 != pos)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 150 << "|" << __FUNCTION__ << "|" << "Failed to parse seed address from string: '" << addr << '\'' << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > std::string host = addr.substr(0, pos); > std::string port = addr.substr(pos + 1); > > io_service io_srv; > ip::tcp::resolver resolver(io_srv); > ip::tcp::resolver::query query(host, port); > boost::system::error_code ec; > ip::tcp::resolver::iterator i = resolver.resolve(query, ec); > do{if(!(!ec)) {{if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to resolve host name '" << host << "': " << ec.message() << ':' << ec.value() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; return false;};}while(0); > > ip::tcp::resolver::iterator iend; > for (; i != iend; ++i) > { > ip::tcp::endpoint endpoint = *i; > if (endpoint.address().is_v4()) > { > nodetool::net_address na; > na.ip = boost::asio::detail::socket_ops::host_to_network_long(endpoint.address().to_v4().to_ulong()); > na.port = endpoint.port(); > nodes.push_back(na); > {if ( 4 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Added seed node: " << endpoint.address().to_v4().to_string(ec) << ':' << na.port << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 4, epee::log_space::console_color_default, false, __null);}}; > } > else > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "IPv6 doesn't supported, skip '" << host << "' -> " << endpoint.address().to_v6().to_string(ec) << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > } > } > > return true; > } > } > > > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::init(const boost::program_options::variables_map& vm) > { > > append_net_address(m_seed_nodes, "107.170.97.197:" "20101");; > append_net_address(m_seed_nodes, "188.226.215.102:" "20101");; > append_net_address(m_seed_nodes, "128.199.196.65:" "20101");; > append_net_address(m_seed_nodes, "107.170.228.11:" "20101");; > > bool res = handle_command_line(vm); > do{if(!(res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 195 << "|" << __FUNCTION__ << "|" << "Failed to handle command line" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > m_config_folder = command_line::get_arg(vm, command_line::arg_data_dir); > > res = init_config(); > do{if(!(res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 199 << "|" << __FUNCTION__ << "|" << "Failed to init config." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > res = m_peerlist.init(m_allow_local_ip); > do{if(!(res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 202 << "|" << __FUNCTION__ << "|" << "Failed to init peerlist." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > > for(auto& p: m_command_line_peers) > m_peerlist.append_with_peer_white(p); > > > m_have_address = true; > m_ip_address = 0; > m_last_stat_request_time = 0; > > > m_net_server.set_threads_prefix("P2P"); > m_net_server.get_config_object().m_pcommands_handler = this; > m_net_server.get_config_object().m_invoke_timeout = 60*2*1000; > > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Binding on " << m_bind_ip << ":" << m_port << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > res = m_net_server.init_server(m_port, m_bind_ip); > do{if(!(res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 221 << "|" << __FUNCTION__ << "|" << "Failed to bind server" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > m_listenning_port = m_net_server.get_binded_port(); > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Net service binded on " << m_bind_ip << ":" << m_listenning_port << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_green, false, __null);}}; > if(m_external_port) > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "External port defined as " << m_external_port << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return res; > } > > template<class t_payload_net_handler> > typename node_server<t_payload_net_handler>::payload_net_handler& node_server<t_payload_net_handler>::get_payload_object() > { > return m_payload_handler; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::run() > { > > int thrds_count = 10; > > m_net_server.add_idle_handler(boost::bind(&node_server<t_payload_net_handler>::idle_worker, this), 1000); > m_net_server.add_idle_handler(boost::bind(&t_payload_net_handler::on_idle, &m_payload_handler), 1000); > > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Run net_service loop( " << thrds_count << " threads)..." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > if(!m_net_server.run_server(thrds_count)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 249 << "|" << __FUNCTION__ << "|" << "Failed to run net tcp server!" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > } > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "net_service loop stopped." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return true; > } > > > template<class t_payload_net_handler> > uint64_t node_server<t_payload_net_handler>::get_connections_count() > { > return m_net_server.get_config_object().get_connections_count(); > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::deinit() > { > m_peerlist.deinit(); > m_net_server.deinit_server(); > return store_config(); > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::store_config() > { > > try {; > if (!tools::create_directories_if_necessary(m_config_folder)) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to create data directory: " << m_config_folder << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return false; > } > > std::string state_file_path = m_config_folder + "/" + "p2pstate.bin"; > tools::serialize_obj_to_file(*this, state_file_path); > return true; > } catch(const std::exception& ex) { (void)(ex); { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 285 << "|" << __FUNCTION__ << "|" << "Exception at [" << "node_server<t_payload_net_handler>::save" << "], what=" << ex.what() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; } catch(...){ { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 285 << "|" << __FUNCTION__ << "|" << "Exception at [" << "node_server<t_payload_net_handler>::save" << "], generic exception \"...\"" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false; }; > > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::send_stop_signal() > { > m_net_server.send_stop_signal(); > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[node] Stop signal sent" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::on_maintainers_entry_update() > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Fresh maintainers info recieved(timestamp: " << m_maintainers_info_local.timestamp << ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_magenta, false, __null);}}; > if(6 < m_maintainers_info_local.build_no) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Newer version avaliable: " << static_cast<uint32_t>(m_maintainers_info_local.ver_major) << "." << static_cast<uint32_t>(m_maintainers_info_local.ver_minor) << "." << static_cast<uint32_t>(m_maintainers_info_local.ver_revision) << "." << static_cast<uint32_t>(m_maintainers_info_local.build_no) << ", current version: " << "0.1.0" "." "6" "(" "184e11c" ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_magenta, false, __null);}} > > > > ; > handle_alert_conditions(); > } > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::handle_maintainers_entry(const maintainers_entry& me) > { > if(me.sign == boost::value_initialized<decltype(me.sign)>()) > return true; > > bool r = crypto::check_signature(crypto::cn_fast_hash(me.maintainers_info_buff.data(), me.maintainers_info_buff.size()), m_maintainers_pub_key, me.sign); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 321 << "|" << __FUNCTION__ << "|" << "Failed to check signature in maintainers_entry" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > maintainers_info mi = boost::value_initialized<decltype(mi)>(); > r = epee::serialization::load_t_from_binary(mi, me.maintainers_info_buff); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 325 << "|" << __FUNCTION__ << "|" << "Failed to load maintainers_info from maintainers_entry buff" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > if(mi.timestamp > m_maintainers_info_local.timestamp) > { > > epee::critical_region_t<decltype(m_maintainers_local_lock)> critical_region_var(m_maintainers_local_lock); > m_maintainers_entry_local = me; > m_maintainers_info_local = mi; > on_maintainers_entry_update(); > } > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::fill_maintainers_entry(maintainers_entry& me) > { > me = m_maintainers_entry_local; > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::do_handshake_with_peer(peerid_type& pi, p2p_connection_context& context_, bool just_take_peerlist) > { > typename COMMAND_HANDSHAKE::request arg = boost::value_initialized<decltype(arg)>(); > typename COMMAND_HANDSHAKE::response rsp = boost::value_initialized<decltype(rsp)>(); > get_local_node_data(arg.node_data); > m_payload_handler.get_payload_sync_data(arg.payload_data); > fill_maintainers_entry(arg.maintrs_entry); > > simple_event ev; > std::atomic<bool> hsh_result(false); > > bool r = net_utils::async_invoke_remote_command2<typename COMMAND_HANDSHAKE::response>(context_.m_connection_id, COMMAND_HANDSHAKE::ID, arg, m_net_server.get_config_object(), > [this, &pi, &ev, &hsh_result, &just_take_peerlist](int code, const typename COMMAND_HANDSHAKE::response& rsp, p2p_connection_context& context) > { > misc_utils::auto_scope_leave_caller scope_exit_handler = misc_utils::create_scope_leave_handler([&](){ev.raise();}); > > if(code < 0) > { > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE invoke failed. (" << code << ", " << levin::get_err_descr(code) << ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_red, false, __null);}}; > return; > } > > if(rsp.node_data.network_id != P2P_NETWORK_ID) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 369 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE Failed, wrong network!, closing connection." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return; > } > > if(!handle_maintainers_entry(rsp.maintrs_entry)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 375 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE Failed, wrong maintainers entry!, closing connection." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return; > } > > if(!handle_remote_peerlist(rsp.local_peerlist, rsp.node_data.local_time, context)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 381 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE: failed to handle_remote_peerlist(...), closing connection." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return; > } > hsh_result = true; > if(!just_take_peerlist) > { > if(!m_payload_handler.process_payload_sync_data(rsp.payload_data, context, true)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 389 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE invoked, but process_payload_sync_data returned false, dropping connection." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > hsh_result = false; > return; > } > > pi = context.peer_id = rsp.node_data.peer_id; > m_peerlist.set_peer_just_seen(rsp.node_data.peer_id, context.m_remote_ip, context.m_remote_port); > > if(rsp.node_data.peer_id == m_config.m_peer_id) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Connection to self detected, dropping connection" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > hsh_result = false; > return; > } > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << " COMMAND_HANDSHAKE INVOKED OK" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > }else > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << " COMMAND_HANDSHAKE(AND CLOSE) INVOKED OK" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > } > }, 5000); > > if(r) > { > ev.wait(); > } > > if(!hsh_result) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context_) << "]" << "COMMAND_HANDSHAKE Failed" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > m_net_server.get_config_object().close(context_.m_connection_id); > } > > return hsh_result; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::do_peer_timed_sync(const net_utils::connection_context_base& context_, peerid_type peer_id) > { > typename COMMAND_TIMED_SYNC::request arg = boost::value_initialized<decltype(arg)>(); > m_payload_handler.get_payload_sync_data(arg.payload_data); > fill_maintainers_entry(arg.maintrs_entry); > > bool r = net_utils::async_invoke_remote_command2<typename COMMAND_TIMED_SYNC::response>(context_.m_connection_id, COMMAND_TIMED_SYNC::ID, arg, m_net_server.get_config_object(), > [this](int code, const typename COMMAND_TIMED_SYNC::response& rsp, p2p_connection_context& context) > { > if(code < 0) > { > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_TIMED_SYNC invoke failed. (" << code << ", " << levin::get_err_descr(code) << ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_red, false, __null);}}; > return; > } > > if(!handle_maintainers_entry(rsp.maintrs_entry)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 442 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE Failed, wrong maintainers entry!, closing connection." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return; > } > > if(!handle_remote_peerlist(rsp.local_peerlist, rsp.local_time, context)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 448 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_TIMED_SYNC: failed to handle_remote_peerlist(...), closing connection." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_net_server.get_config_object().close(context.m_connection_id ); > } > if(!context.m_is_income) > m_peerlist.set_peer_just_seen(context.peer_id, context.m_remote_ip, context.m_remote_port); > m_payload_handler.process_payload_sync_data(rsp.payload_data, context, false); > }); > > if(!r) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context_) << "]" << "COMMAND_TIMED_SYNC Failed" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > return false; > } > return true; > } > > template<class t_payload_net_handler> > size_t node_server<t_payload_net_handler>::get_random_index_with_fixed_probability(size_t max_index) > { > > if(!max_index) > return 0; > > size_t x = crypto::rand<size_t>()%(max_index+1); > size_t res = (x*x*x)/(max_index*max_index); > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Random connection index=" << res << "(x="<< x << ", max_index=" << max_index << ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > return res; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::is_peer_used(const peerlist_entry& peer) > { > > if(m_config.m_peer_id == peer.id) > return true; > > bool used = false; > m_net_server.get_config_object().foreach_connection([&](const p2p_connection_context& cntxt) > { > if(cntxt.peer_id == peer.id || (!cntxt.m_is_income && peer.adr.ip == cntxt.m_remote_ip && peer.adr.port == cntxt.m_remote_port)) > { > used = true; > return false; > } > return true; > }); > > return used; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::is_addr_connected(const net_address& peer) > { > bool connected = false; > m_net_server.get_config_object().foreach_connection([&](const p2p_connection_context& cntxt) > { > if(!cntxt.m_is_income && peer.ip == cntxt.m_remote_ip && peer.port == cntxt.m_remote_port) > { > connected = true; > return false; > } > return true; > }); > > return connected; > } > > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::try_to_connect_and_handshake_with_new_peer(const net_address& na, bool just_take_peerlist, uint64_t last_seen_stamp, bool white) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Connecting to " << string_tools::get_ip_string_from_int32(na.ip) << ":" << string_tools::num_to_string_fast(na.port) << "(white=" << white << ", last_seen: " << (last_seen_stamp?misc_utils::get_time_interval_string(time(__null) - last_seen_stamp):"never" ) << ")..." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > > typename net_server::t_connection_context con = boost::value_initialized<decltype(con)>(); > bool res = m_net_server.connect(string_tools::get_ip_string_from_int32(na.ip), > string_tools::num_to_string_fast(na.port), > m_config.m_net_config.connection_timeout, > con); > if(!res) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Connect failed to " << string_tools::get_ip_string_from_int32(na.ip) << ":" << string_tools::num_to_string_fast(na.port) << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}} > > > ; > > return false; > } > peerid_type pi = boost::value_initialized<decltype(pi)>(); > res = do_handshake_with_peer(pi, con, just_take_peerlist); > if(!res) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(con) << "]" << "Failed to HANDSHAKE with peer " << string_tools::get_ip_string_from_int32(na.ip) << ":" << string_tools::num_to_string_fast(na.port) << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}} > > > ; > return false; > } > if(just_take_peerlist) > { > m_net_server.get_config_object().close(con.m_connection_id); > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(con) << "]" << "CONNECTION HANDSHAKED OK AND CLOSED." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_green, false, __null);}}; > return true; > } > > peerlist_entry pe_local = boost::value_initialized<decltype(pe_local)>(); > pe_local.adr = na; > pe_local.id = pi; > time(&pe_local.last_seen); > m_peerlist.append_with_peer_white(pe_local); > > > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(con) << "]" << "CONNECTION HANDSHAKED OK." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_green, false, __null);}}; > return true; > } > > template<class t_payload_net_handler> > void node_server<t_payload_net_handler>::cache_connect_fail_info(const net_address& addr) > { > epee::critical_region_t<decltype(m_conn_fails_cache_lock)> critical_region_var(m_conn_fails_cache_lock); > m_conn_fails_cache[addr] = time(__null); > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::is_addr_recently_failed(const net_address& addr) > { > epee::critical_region_t<decltype(m_conn_fails_cache_lock)> critical_region_var(m_conn_fails_cache_lock); > auto it = m_conn_fails_cache.find(addr); > if(it == m_conn_fails_cache.end()) > return false; > > if(time(__null) - it->second > 60*60) > return false; > else > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::make_new_connection_from_peerlist(bool use_white_list) > { > size_t local_peers_count = use_white_list ? m_peerlist.get_white_peers_count():m_peerlist.get_gray_peers_count(); > if(!local_peers_count) > return false; > > size_t max_random_index = std::min<uint64_t>(local_peers_count -1, 20); > > std::set<size_t> tried_peers; > > size_t try_count = 0; > size_t rand_count = 0; > while(rand_count < (max_random_index+1)*3 && try_count < 10 && !m_net_server.is_stop_signal_sent()) > { > ++rand_count; > size_t random_index = get_random_index_with_fixed_probability(max_random_index); > do{if(!(random_index < local_peers_count)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 601 << "|" << __FUNCTION__ << "|" << "random_starter_index < peers_local.size() failed!!" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > if(tried_peers.count(random_index)) > continue; > > tried_peers.insert(random_index); > peerlist_entry pe = boost::value_initialized<decltype(pe)>(); > bool r = use_white_list ? m_peerlist.get_white_peer_by_index(pe, random_index):m_peerlist.get_gray_peer_by_index(pe, random_index); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 609 << "|" << __FUNCTION__ << "|" << "Failed to get random peer from peerlist(white:" << use_white_list << ")" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > > ++try_count; > > if(is_peer_used(pe)) > continue; > > if(is_addr_recently_failed(pe.adr)) > continue; > > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Selected peer: " << pe.id << " " << string_tools::get_ip_string_from_int32(pe.adr.ip) << ":" << boost::lexical_cast<std::string>(pe.adr.port) << "[white=" << use_white_list << "] last_seen: " << (pe.last_seen ? misc_utils::get_time_interval_string(time(__null) - pe.last_seen) : "never") << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_default, false, __null);}}; > > if(!try_to_connect_and_handshake_with_new_peer(pe.adr, false, pe.last_seen, use_white_list)) > { > cache_connect_fail_info(pe.adr); > continue; > } > > return true; > } > return false; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::connections_maker() > { > if(!m_peerlist.get_white_peers_count() && m_seed_nodes.size()) > { > size_t try_count = 0; > size_t current_index = crypto::rand<size_t>()%m_seed_nodes.size(); > while(true) > { > if(m_net_server.is_stop_signal_sent()) > return false; > > if(try_to_connect_and_handshake_with_new_peer(m_seed_nodes[current_index], true)) > break; > if(++try_count > m_seed_nodes.size()) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Failed to connect to any of seed peers, continuing without seeds" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, false, __null);}}; > break; > } > if(++current_index >= m_seed_nodes.size()) > current_index = 0; > } > } > > for(const net_address& na: m_priority_peers) > { > if(m_net_server.is_stop_signal_sent()) > return false; > > if(is_addr_connected(na)) > continue; > try_to_connect_and_handshake_with_new_peer(na); > } > > size_t expected_white_connections = (m_config.m_net_config.connections_count*70)/100; > > size_t conn_count = get_outgoing_connections_count(); > if(conn_count < m_config.m_net_config.connections_count) > { > if(conn_count < expected_white_connections) > { > > if(!make_expected_connections_count(true, expected_white_connections)) > return false; > > if(!make_expected_connections_count(false, m_config.m_net_config.connections_count)) > return false; > }else > { > > if(!make_expected_connections_count(false, m_config.m_net_config.connections_count)) > return false; > > if(!make_expected_connections_count(true, m_config.m_net_config.connections_count)) > return false; > } > } > > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::make_expected_connections_count(bool white_list, size_t expected_connections) > { > size_t conn_count = get_outgoing_connections_count(); > > while(conn_count < expected_connections) > { > if(m_net_server.is_stop_signal_sent()) > return false; > > if(!make_new_connection_from_peerlist(white_list)) > break; > conn_count = get_outgoing_connections_count(); > } > return true; > } > > > template<class t_payload_net_handler> > size_t node_server<t_payload_net_handler>::get_outgoing_connections_count() > { > size_t count = 0; > m_net_server.get_config_object().foreach_connection([&](const p2p_connection_context& cntxt) > { > if(!cntxt.m_is_income) > ++count; > return true; > }); > > return count; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::idle_worker() > { > m_peer_handshake_idle_maker_interval.do_call(boost::bind(&node_server<t_payload_net_handler>::peer_sync_idle_maker, this)); > m_connections_maker_interval.do_call(boost::bind(&node_server<t_payload_net_handler>::connections_maker, this)); > m_peerlist_store_interval.do_call(boost::bind(&node_server<t_payload_net_handler>::store_config, this)); > > m_calm_alert_interval.do_call([&](){return clam_alert_worker();}); > m_urgent_alert_interval.do_call([&](){return urgent_alert_worker();}); > m_critical_alert_interval.do_call([&](){return critical_alert_worker();}); > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::clam_alert_worker() > { > if(m_alert_mode != 1) > return true; > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "This software is is up to date, please update." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::urgent_alert_worker() > { > if(m_alert_mode != 2) > return true; > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[URGENT]:This software is is up to date, please update." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_cyan, false, __null);}}; > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::critical_alert_worker() > { > if(m_alert_mode != 3) > return true; > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[CRITICAL]:This software is is up to date, please update." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, false, __null);}}; > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::handle_alert_conditions() > { > epee::critical_region_t<decltype(m_maintainers_local_lock)> critical_region_var(m_maintainers_local_lock); > m_alert_mode = 0; > for(auto c: m_maintainers_info_local.conditions) > { > if(6 < c.if_build_less_then && c.alert_mode > m_alert_mode) > m_alert_mode = c.alert_mode; > } > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::peer_sync_idle_maker() > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "STARTED PEERLIST IDLE HANDSHAKE" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > typedef std::list<std::pair<net_utils::connection_context_base, peerid_type> > local_connects_type; > local_connects_type cncts; > m_net_server.get_config_object().foreach_connection([&](const p2p_connection_context& cntxt) > { > if(cntxt.peer_id) > cncts.push_back(local_connects_type::value_type(cntxt, cntxt.peer_id)); > return true; > }); > > std::for_each(cncts.begin(), cncts.end(), [&](const typename local_connects_type::value_type& vl){do_peer_timed_sync(vl.first, vl.second);}); > > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "FINISHED PEERLIST IDLE HANDSHAKE" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::fix_time_delta(std::list<peerlist_entry>& local_peerlist, time_t local_time, int64_t& delta) > { > > time_t now = 0; > time(&now); > delta = now - local_time; > > if (boost::foreach_detail_::auto_any_t _foreach_col808 = boost::foreach_detail_::contain( (local_peerlist) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((local_peerlist), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(local_peerlist) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(local_peerlist) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur808 = boost::foreach_detail_::begin( _foreach_col808 , (true ? 0 : boost::foreach_detail_::encode_type(local_peerlist, boost::foreach_detail_::is_const_(local_peerlist))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((local_peerlist), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(local_peerlist) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(local_peerlist) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end808 = boost::foreach_detail_::end( _foreach_col808 , (true ? 0 : boost::foreach_detail_::encode_type(local_peerlist, boost::foreach_detail_::is_const_(local_peerlist))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((local_peerlist), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(local_peerlist) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(local_peerlist) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue808 = true; _foreach_continue808 && !boost::foreach_detail_::done( _foreach_cur808 , _foreach_end808 , (true ? 0 : boost::foreach_detail_::encode_type(local_peerlist, boost::foreach_detail_::is_const_(local_peerlist)))); _foreach_continue808 ? boost::foreach_detail_::next( _foreach_cur808 , (true ? 0 : boost::foreach_detail_::encode_type(local_peerlist, boost::foreach_detail_::is_const_(local_peerlist)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue808)) {} else for (peerlist_entry& be = boost::foreach_detail_::deref( _foreach_cur808 , (true ? 0 : boost::foreach_detail_::encode_type(local_peerlist, boost::foreach_detail_::is_const_(local_peerlist)))); !_foreach_continue808; _foreach_continue808 = true) > { > if(be.last_seen > local_time) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "FOUND FUTURE peerlist for entry " << string_tools::get_ip_string_from_int32(be.adr.ip) << ":" << be.adr.port << " last_seen: " << be.last_seen << ", local_time(on remote node):" << local_time << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, false, __null);}}; > return false; > } > be.last_seen += delta; > } > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::handle_remote_peerlist(const std::list<peerlist_entry>& peerlist, time_t local_time, const net_utils::connection_context_base& context) > { > int64_t delta = 0; > std::list<peerlist_entry> peerlist_ = peerlist; > if(!fix_time_delta(peerlist_, local_time, delta)) > return false; > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "REMOTE PEERLIST: TIME_DELTA: " << delta << ", remote peerlist size=" << peerlist_.size() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > {if ( 3 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "REMOTE PEERLIST: " << print_peerlist_to_string(peerlist_) << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 3, epee::log_space::console_color_default, false, __null);}}; > return m_peerlist.merge_peerlist(peerlist_); > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::get_local_node_data(basic_node_data& node_data) > { > node_data.local_time = time(__null); > node_data.peer_id = m_config.m_peer_id; > if(!m_hide_my_port) > node_data.my_port = m_external_port ? m_external_port : m_listenning_port; > else > node_data.my_port = 0; > node_data.network_id = P2P_NETWORK_ID; > return true; > } > > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::check_trust(const proof_of_trust& tr) > { > int64_t local_time = time(__null); > int64_t time_delata = local_time > tr.time ? local_time - tr.time: tr.time - local_time; > if(time_delata > 24*60*60 ) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 853 << "|" << __FUNCTION__ << "|" << "check_trust failed to check time conditions, local_time=" << local_time << ", proof_time=" << tr.time << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > if(m_last_stat_request_time >= tr.time ) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 858 << "|" << __FUNCTION__ << "|" << "check_trust failed to check time conditions, last_stat_request_time=" << m_last_stat_request_time << ", proof_time=" << tr.time << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > if(m_config.m_peer_id != tr.peer_id) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 863 << "|" << __FUNCTION__ << "|" << "check_trust failed: peer_id mismatch (passed " << tr.peer_id << ", expected " << m_config.m_peer_id<< ")" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > crypto::public_key pk = boost::value_initialized<decltype(pk)>(); > string_tools::hex_to_pod("d2f6bc35dc4e4a43235ae12620df4612df590c6e1df0a18a55c5e12d81502aa7", pk); > crypto::hash h = tools::get_proof_of_trust_hash(tr); > if(!crypto::check_signature(h, pk, tr.sign)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 871 << "|" << __FUNCTION__ << "|" << "check_trust failed: sign check failed" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > > m_last_stat_request_time = tr.time; > return true; > } > > template<class t_payload_net_handler> > int node_server<t_payload_net_handler>::handle_get_stat_info(int command, typename COMMAND_REQUEST_STAT_INFO::request& arg, typename COMMAND_REQUEST_STAT_INFO::response& rsp, p2p_connection_context& context) > { > if(!check_trust(arg.tr)) > { > drop_connection(context); > return 1; > } > rsp.connections_count = m_net_server.get_config_object().get_connections_count(); > rsp.incoming_connections_count = rsp.connections_count - get_outgoing_connections_count(); > rsp.version = "0.1.0" "." "6" "(" "184e11c" ")"; > m_payload_handler.get_stat_info(rsp.payload_info); > return 1; > } > > template<class t_payload_net_handler> > int node_server<t_payload_net_handler>::handle_get_network_state(int command, COMMAND_REQUEST_NETWORK_STATE::request& arg, COMMAND_REQUEST_NETWORK_STATE::response& rsp, p2p_connection_context& context) > { > if(!check_trust(arg.tr)) > { > drop_connection(context); > return 1; > } > m_net_server.get_config_object().foreach_connection([&](const p2p_connection_context& cntxt) > { > connection_entry ce; > ce.adr.ip = cntxt.m_remote_ip; > ce.adr.port = cntxt.m_remote_port; > ce.id = cntxt.peer_id; > ce.is_income = cntxt.m_is_income; > rsp.connections_list.push_back(ce); > return true; > }); > > m_peerlist.get_peerlist_full(rsp.local_peerlist_gray, rsp.local_peerlist_white); > rsp.my_id = m_config.m_peer_id; > rsp.local_time = time(__null); > return 1; > } > > template<class t_payload_net_handler> > int node_server<t_payload_net_handler>::handle_get_peer_id(int command, COMMAND_REQUEST_PEER_ID::request& arg, COMMAND_REQUEST_PEER_ID::response& rsp, p2p_connection_context& context) > { > rsp.my_id = m_config.m_peer_id; > return 1; > } > > > template<class t_payload_net_handler> > void node_server<t_payload_net_handler>::request_callback(const epee::net_utils::connection_context_base& context) > { > m_net_server.get_config_object().request_callback(context.m_connection_id); > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::relay_notify_to_all(int command, const std::string& data_buff, const epee::net_utils::connection_context_base& context) > { > std::list<boost::uuids::uuid> connections; > m_net_server.get_config_object().foreach_connection([&](const p2p_connection_context& cntxt) > { > if(cntxt.peer_id && context.m_connection_id != cntxt.m_connection_id) > connections.push_back(cntxt.m_connection_id); > return true; > }); > > if (boost::foreach_detail_::auto_any_t _foreach_col944 = boost::foreach_detail_::contain( (connections) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((connections), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(connections) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(connections) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur944 = boost::foreach_detail_::begin( _foreach_col944 , (true ? 0 : boost::foreach_detail_::encode_type(connections, boost::foreach_detail_::is_const_(connections))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((connections), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(connections) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(connections) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end944 = boost::foreach_detail_::end( _foreach_col944 , (true ? 0 : boost::foreach_detail_::encode_type(connections, boost::foreach_detail_::is_const_(connections))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((connections), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(connections) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(connections) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue944 = true; _foreach_continue944 && !boost::foreach_detail_::done( _foreach_cur944 , _foreach_end944 , (true ? 0 : boost::foreach_detail_::encode_type(connections, boost::foreach_detail_::is_const_(connections)))); _foreach_continue944 ? boost::foreach_detail_::next( _foreach_cur944 , (true ? 0 : boost::foreach_detail_::encode_type(connections, boost::foreach_detail_::is_const_(connections)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue944)) {} else for (const auto& c_id = boost::foreach_detail_::deref( _foreach_cur944 , (true ? 0 : boost::foreach_detail_::encode_type(connections, boost::foreach_detail_::is_const_(connections)))); !_foreach_continue944; _foreach_continue944 = true) > { > m_net_server.get_config_object().notify(command, data_buff, c_id); > } > return true; > } > > template<class t_payload_net_handler> > void node_server<t_payload_net_handler>::callback(p2p_connection_context& context) > { > m_payload_handler.on_callback(context); > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::invoke_notify_to_peer(int command, const std::string& req_buff, const epee::net_utils::connection_context_base& context) > { > int res = m_net_server.get_config_object().notify(command, req_buff, context.m_connection_id); > return res > 0; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::invoke_command_to_peer(int command, const std::string& req_buff, std::string& resp_buff, const epee::net_utils::connection_context_base& context) > { > int res = m_net_server.get_config_object().invoke(command, req_buff, resp_buff, context.m_connection_id); > return res > 0; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::drop_connection(const epee::net_utils::connection_context_base& context) > { > m_net_server.get_config_object().close(context.m_connection_id); > return true; > } > > template<class t_payload_net_handler> template<class t_callback> > bool node_server<t_payload_net_handler>::try_ping(basic_node_data& node_data, p2p_connection_context& context, t_callback cb) > { > if(!node_data.my_port) > return false; > > uint32_t actual_ip = context.m_remote_ip; > if(!m_peerlist.is_ip_allowed(actual_ip)) > return false; > std::string ip = string_tools::get_ip_string_from_int32(actual_ip); > std::string port = string_tools::num_to_string_fast(node_data.my_port); > peerid_type pr = node_data.peer_id; > bool r = m_net_server.connect_async(ip, port, m_config.m_net_config.ping_connection_timeout, [cb, ip, port, pr, this]( > const typename net_server::t_connection_context& ping_context, > const boost::system::error_code& ec)->bool > { > if(ec) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(ping_context) << "]" << "back ping connect failed to " << ip << ":" << port << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > return false; > } > COMMAND_PING::request req; > COMMAND_PING::response rsp; > > > > > > bool inv_call_res = net_utils::async_invoke_remote_command2<COMMAND_PING::response>(ping_context.m_connection_id, COMMAND_PING::ID, req, m_net_server.get_config_object(), > [=](int code, const COMMAND_PING::response& rsp, p2p_connection_context& context) > { > if(code <= 0) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(ping_context) << "]" << "Failed to invoke COMMAND_PING to " << ip << ":" << port << "(" << code << ", " << levin::get_err_descr(code) << ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > return; > } > > if(rsp.status != "OK" || pr != rsp.peer_id) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(ping_context) << "]" << "back ping invoke wrong response \"" << rsp.status << "\" from" << ip << ":" << port << ", hsh_peer_id=" << pr << ", rsp.peer_id=" << rsp.peer_id << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > return; > } > m_net_server.get_config_object().close(ping_context.m_connection_id); > cb(); > }); > > if(!inv_call_res) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(ping_context) << "]" << "back ping invoke failed to " << ip << ":" << port << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > m_net_server.get_config_object().close(ping_context.m_connection_id); > return false; > } > return true; > }); > if(!r) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 1034 << "|" << __FUNCTION__ << "|" << "Failed to call connect_async, network error." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > } > return r; > } > > template<class t_payload_net_handler> > int node_server<t_payload_net_handler>::handle_timed_sync(int command, typename COMMAND_TIMED_SYNC::request& arg, typename COMMAND_TIMED_SYNC::response& rsp, p2p_connection_context& context) > { > if(!handle_maintainers_entry(arg.maintrs_entry)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 1044 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE Failed, wrong maintainers entry!, closing connection." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return 1; > } > > if(!m_payload_handler.process_payload_sync_data(arg.payload_data, context, false)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 1050 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Failed to process_payload_sync_data(), dropping connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > drop_connection(context); > return 1; > } > > > rsp.local_time = time(__null); > m_peerlist.get_peerlist_head(rsp.local_peerlist); > m_payload_handler.get_payload_sync_data(rsp.payload_data); > fill_maintainers_entry(rsp.maintrs_entry); > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_TIMED_SYNC" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > return 1; > } > > template<class t_payload_net_handler> > int node_server<t_payload_net_handler>::handle_handshake(int command, typename COMMAND_HANDSHAKE::request& arg, typename COMMAND_HANDSHAKE::response& rsp, p2p_connection_context& context) > { > if(arg.node_data.network_id != P2P_NETWORK_ID) > { > > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "WRONG NETWORK AGENT CONNECTED! id=" << string_tools::get_str_from_guid_a(arg.node_data.network_id) << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > drop_connection(context); > return 1; > } > > if(!context.m_is_income) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 1077 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE came not from incoming connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > drop_connection(context); > return 1; > } > > if(context.peer_id) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 1084 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE came, but seems that connection already have associated peer_id (double COMMAND_HANDSHAKE?)" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > drop_connection(context); > return 1; > } > > if(!handle_maintainers_entry(arg.maintrs_entry)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 1091 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE Failed, wrong maintainers entry!, closing connection." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return 1; > } > > if(!m_payload_handler.process_payload_sync_data(arg.payload_data, context, true)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/p2p/net_node.inl" << ":" << 1097 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE came, but process_payload_sync_data returned false, dropping connection." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > drop_connection(context); > return 1; > } > > context.peer_id = arg.node_data.peer_id; > > if(arg.node_data.peer_id != m_config.m_peer_id && arg.node_data.my_port) > { > peerid_type peer_id_l = arg.node_data.peer_id; > uint32_t port_l = arg.node_data.my_port; > > try_ping(arg.node_data, context, [peer_id_l, port_l, context, this]() > { > > peerlist_entry pe; > pe.adr.ip = context.m_remote_ip; > pe.adr.port = port_l; > time(&pe.last_seen); > pe.id = peer_id_l; > this->m_peerlist.append_with_peer_white(pe); > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "PING SUCCESS " << string_tools::get_ip_string_from_int32(context.m_remote_ip) << ":" << port_l << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > }); > } > > > m_peerlist.get_peerlist_head(rsp.local_peerlist); > get_local_node_data(rsp.node_data); > m_payload_handler.get_payload_sync_data(rsp.payload_data); > fill_maintainers_entry(rsp.maintrs_entry); > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_HANDSHAKE" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_green, false, __null);}}; > return 1; > } > > template<class t_payload_net_handler> > int node_server<t_payload_net_handler>::handle_ping(int command, COMMAND_PING::request& arg, COMMAND_PING::response& rsp, p2p_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "COMMAND_PING" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > rsp.status = "OK"; > rsp.peer_id = m_config.m_peer_id; > return 1; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::log_peerlist() > { > std::list<peerlist_entry> pl_wite; > std::list<peerlist_entry> pl_gray; > m_peerlist.get_peerlist_full(pl_gray, pl_wite); > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << std::endl << "Peerlist white:" << std::endl << print_peerlist_to_string(pl_wite) << std::endl << "Peerlist gray:" << std::endl << print_peerlist_to_string(pl_gray) << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return true; > } > > template<class t_payload_net_handler> > bool node_server<t_payload_net_handler>::log_connections() > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Connections: \r\n" << print_connections_container() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > return true; > } > > template<class t_payload_net_handler> > std::string node_server<t_payload_net_handler>::print_connections_container() > { > > std::stringstream ss; > m_net_server.get_config_object().foreach_connection([&](const p2p_connection_context& cntxt) > { > ss << string_tools::get_ip_string_from_int32(cntxt.m_remote_ip) << ":" << cntxt.m_remote_port > << " \t\tpeer_id " << cntxt.peer_id > << " \t\tconn_id " << string_tools::get_str_from_guid_a(cntxt.m_connection_id) << (cntxt.m_is_income ? " INC":" OUT") > << std::endl; > return true; > }); > std::string s = ss.str(); > return s; > } > > template<class t_payload_net_handler> > void node_server<t_payload_net_handler>::on_connection_new(p2p_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "["<< net_utils::print_connection_context(context) << "] NEW CONNECTION" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > } > > template<class t_payload_net_handler> > void node_server<t_payload_net_handler>::on_connection_close(p2p_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "["<< net_utils::print_connection_context(context) << "] CLOSE CONNECTION" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > } > >} ># 246 "/c/honeypenny/src/p2p/net_node.h" 2 ># 247 "/c/honeypenny/src/p2p/net_node.h" >#pragma GCC diagnostic pop ># 247 "/c/honeypenny/src/p2p/net_node.h" ># 14 "/c/honeypenny/src/rpc/core_rpc_server.h" 2 ># 1 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.h" 1 ># 17 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.h" ># 17 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.h" >#pragma GCC diagnostic push ># 17 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.h" > > > >namespace currency >{ > > template<class t_core> > class t_currency_protocol_handler: public i_currency_protocol > { > public: > typedef currency_connection_context connection_context; > typedef core_stat_info stat_info; > typedef t_currency_protocol_handler<t_core> currency_protocol_handler; > typedef CORE_SYNC_DATA payload_type; > > t_currency_protocol_handler(t_core& rcore, nodetool::i_p2p_endpoint<connection_context>* p_net_layout); > > template <class t_context> int handle_invoke_map(bool is_notify, int command, const std::string& in_buff, std::string& buff_out, t_context& context, bool& handled) { typedef currency_protocol_handler internal_owner_type_name; > if(is_notify && NOTIFY_NEW_BLOCK::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename NOTIFY_NEW_BLOCK::request>(this, command, in_buff, boost::bind(¤cy_protocol_handler::handle_notify_new_block, this, _1, _2, _3), context);} > if(is_notify && NOTIFY_NEW_TRANSACTIONS::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename NOTIFY_NEW_TRANSACTIONS::request>(this, command, in_buff, boost::bind(¤cy_protocol_handler::handle_notify_new_transactions, this, _1, _2, _3), context);} > if(is_notify && NOTIFY_REQUEST_GET_OBJECTS::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename NOTIFY_REQUEST_GET_OBJECTS::request>(this, command, in_buff, boost::bind(¤cy_protocol_handler::handle_request_get_objects, this, _1, _2, _3), context);} > if(is_notify && NOTIFY_RESPONSE_GET_OBJECTS::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename NOTIFY_RESPONSE_GET_OBJECTS::request>(this, command, in_buff, boost::bind(¤cy_protocol_handler::handle_response_get_objects, this, _1, _2, _3), context);} > if(is_notify && NOTIFY_REQUEST_CHAIN::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename NOTIFY_REQUEST_CHAIN::request>(this, command, in_buff, boost::bind(¤cy_protocol_handler::handle_request_chain, this, _1, _2, _3), context);} > if(is_notify && NOTIFY_RESPONSE_CHAIN_ENTRY::ID == command) {handled=true;return epee::net_utils::buff_to_t_adapter<internal_owner_type_name, typename NOTIFY_RESPONSE_CHAIN_ENTRY::request>(this, command, in_buff, boost::bind(¤cy_protocol_handler::handle_response_chain_entry, this, _1, _2, _3), context);} > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_handler.h" << ":" << 41 << "|" << __FUNCTION__ << "|" << "Unkonown command:" << command << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return -6; } > > bool on_idle(); > bool init(const boost::program_options::variables_map& vm); > bool deinit(); > void set_p2p_endpoint(nodetool::i_p2p_endpoint<connection_context>* p2p); > > bool process_payload_sync_data(const CORE_SYNC_DATA& hshd, currency_connection_context& context, bool is_inital); > bool get_payload_sync_data(blobdata& data); > bool get_payload_sync_data(CORE_SYNC_DATA& hshd); > bool get_stat_info(core_stat_info& stat_inf); > bool on_callback(currency_connection_context& context); > t_core& get_core(){return m_core;} > bool is_synchronized(){return m_synchronized;} > void log_connections(); > private: > > int handle_notify_new_block(int command, NOTIFY_NEW_BLOCK::request& arg, currency_connection_context& context); > int handle_notify_new_transactions(int command, NOTIFY_NEW_TRANSACTIONS::request& arg, currency_connection_context& context); > int handle_request_get_objects(int command, NOTIFY_REQUEST_GET_OBJECTS::request& arg, currency_connection_context& context); > int handle_response_get_objects(int command, NOTIFY_RESPONSE_GET_OBJECTS::request& arg, currency_connection_context& context); > int handle_request_chain(int command, NOTIFY_REQUEST_CHAIN::request& arg, currency_connection_context& context); > int handle_response_chain_entry(int command, NOTIFY_RESPONSE_CHAIN_ENTRY::request& arg, currency_connection_context& context); > > > > virtual bool relay_block(NOTIFY_NEW_BLOCK::request& arg, currency_connection_context& exclude_context); > virtual bool relay_transactions(NOTIFY_NEW_TRANSACTIONS::request& arg, currency_connection_context& exclude_context); > > > bool request_missing_objects(currency_connection_context& context, bool check_having_blocks); > size_t get_synchronizing_connections_count(); > bool on_connection_synchronized(); > t_core& m_core; > > nodetool::p2p_endpoint_stub<connection_context> m_p2p_stub; > nodetool::i_p2p_endpoint<connection_context>* m_p2p; > std::atomic<uint32_t> m_syncronized_connections_count; > std::atomic<bool> m_synchronized; > > template<class t_parametr> > bool post_notify(typename t_parametr::request& arg, currency_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << net_utils::print_connection_context_short(context) << "] post " << typeid(t_parametr).name() << " -->" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > std::string blob; > epee::serialization::store_t_to_binary(arg, blob); > return m_p2p->invoke_notify_to_peer(t_parametr::ID, blob, context); > } > > template<class t_parametr> > bool relay_post_notify(typename t_parametr::request& arg, currency_connection_context& exlude_context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << net_utils::print_connection_context_short(exlude_context) << "] post relay " << typeid(t_parametr).name() << " -->" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > std::string arg_buff; > epee::serialization::store_t_to_binary(arg, arg_buff); > return m_p2p->relay_notify_to_all(t_parametr::ID, arg_buff, exlude_context); > } > }; >} > > ># 1 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" 1 > > > > > > ># 1 "/c/honeypenny/contrib/epee/include/profile_tools.h" 1 ># 31 "/c/honeypenny/contrib/epee/include/profile_tools.h" >namespace epee >{ ># 62 "/c/honeypenny/contrib/epee/include/profile_tools.h" >namespace profile_tools >{ > struct local_call_account > { > local_call_account(const char* pstr):m_count_of_call(0), m_summary_time_used(0),m_pname(pstr) > {} > ~local_call_account() > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "PROFILE "<<m_pname<<":av_time:\t" << (m_count_of_call ? (m_summary_time_used/m_count_of_call):0) <<" sum_time:\t"<<m_summary_time_used<<" call_count:\t" << m_count_of_call << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, "profile_details.log");}}; > } > > size_t m_count_of_call; > uint64_t m_summary_time_used; > const char* m_pname; > }; > > struct call_frame > { > > call_frame(local_call_account& cc):m_cc(cc) > { > cc.m_count_of_call++; > m_call_time = boost::posix_time::microsec_clock::local_time(); > > } > > ~call_frame() > { > > > boost::posix_time::ptime now_t(boost::posix_time::microsec_clock::local_time()); > boost::posix_time::time_duration delta_microsec = now_t - m_call_time; > uint64_t miliseconds_used = delta_microsec.total_microseconds(); > > > > m_cc.m_summary_time_used += miliseconds_used; > } > > private: > local_call_account& m_cc; > boost::posix_time::ptime m_call_time; > }; > > >} >} ># 8 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" 2 >namespace currency >{ > > > template<class t_core> > t_currency_protocol_handler<t_core>::t_currency_protocol_handler(t_core& rcore, nodetool::i_p2p_endpoint<connection_context>* p_net_layout):m_core(rcore), > m_p2p(p_net_layout), > m_syncronized_connections_count(0), > m_synchronized(false) > > { > if(!m_p2p) > m_p2p = &m_p2p_stub; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::init(const boost::program_options::variables_map& vm) > { > return true; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::deinit() > { > > > return true; > } > > template<class t_core> > void t_currency_protocol_handler<t_core>::set_p2p_endpoint(nodetool::i_p2p_endpoint<connection_context>* p2p) > { > if(p2p) > m_p2p = p2p; > else > m_p2p = &m_p2p_stub; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::on_callback(currency_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "callback fired" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > do{if(!(context.m_callback_request_count > 0)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" << ":" << 50 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "false callback fired, but context.m_callback_request_count=" << context.m_callback_request_count << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > --context.m_callback_request_count; > > if(context.m_state == currency_connection_context::state_synchronizing) > { > NOTIFY_REQUEST_CHAIN::request r = boost::value_initialized<NOTIFY_REQUEST_CHAIN::request>(); > m_core.get_short_chain_history(r.block_ids); > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "-->>NOTIFY_REQUEST_CHAIN: m_block_ids.size()=" << r.block_ids.size() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > post_notify<NOTIFY_REQUEST_CHAIN>(r, context); > } > > return true; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::get_stat_info(core_stat_info& stat_inf) > { > return m_core.get_stat_info(stat_inf); > } > > template<class t_core> > void t_currency_protocol_handler<t_core>::log_connections() > { > std::stringstream ss; > > ss << std::setw(25) << std::left << "Remote Host" > << std::setw(20) << "Peer id" > << std::setw(25) << "Recv/Sent (inactive,sec)" > << std::setw(25) << "State" > << std::setw(20) << "Livetime(seconds)" << std::endl; > > m_p2p->for_each_connection([&](const connection_context& cntxt, nodetool::peerid_type peer_id) > { > ss << std::setw(25) << std::left << std::string(cntxt.m_is_income ? " [INC]":"[OUT]") + > string_tools::get_ip_string_from_int32(cntxt.m_remote_ip) + ":" + std::to_string(cntxt.m_remote_port) > << std::setw(20) << std::hex << peer_id > << std::setw(25) << std::to_string(cntxt.m_recv_cnt)+ "(" + std::to_string(time(__null) - cntxt.m_last_recv) + ")" + "/" + std::to_string(cntxt.m_send_cnt) + "(" + std::to_string(time(__null) - cntxt.m_last_send) + ")" > << std::setw(25) << get_protocol_state_string(cntxt.m_state) > << std::setw(20) << std::to_string(time(__null) - cntxt.m_started) << std::endl; > return true; > }); > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "Connections: " << std::endl << ss.str() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::process_payload_sync_data(const CORE_SYNC_DATA& hshd, currency_connection_context& context, bool is_inital) > { > if(context.m_state == currency_connection_context::state_befor_handshake && !is_inital) > return true; > > if(context.m_state == currency_connection_context::state_synchronizing) > return true; > > if(m_core.have_block(hshd.top_id)) > { > context.m_state = currency_connection_context::state_normal; > if(is_inital) > on_connection_synchronized(); > return true; > } > > {if ( (is_inital ? 0:1) <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Sync data returned unknown top block: " << m_core.get_current_blockchain_height() << "->" << hshd.current_height << "[" << static_cast<int64_t>(hshd.current_height - m_core.get_current_blockchain_height()) << " blocks(" << (hshd.current_height - m_core.get_current_blockchain_height()) /720 << " days) behind] " << std::endl << "remote top: " << hshd.top_id << "[" << hshd.current_height << "]" << ", set SYNCHRONIZATION mode" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), (is_inital ? 0:1), epee::log_space::console_color_yellow, false, __null);}} > > ; > context.m_state = currency_connection_context::state_synchronizing; > context.m_remote_blockchain_height = hshd.current_height; > > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "requesting callback" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > ++context.m_callback_request_count; > m_p2p->request_callback(context); > return true; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::get_payload_sync_data(CORE_SYNC_DATA& hshd) > { > m_core.get_blockchain_top(hshd.current_height, hshd.top_id); > hshd.current_height +=1; > return true; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::get_payload_sync_data(blobdata& data) > { > CORE_SYNC_DATA hsd = boost::value_initialized<CORE_SYNC_DATA>(); > get_payload_sync_data(hsd); > epee::serialization::store_t_to_binary(hsd, data); > return true; > } > > template<class t_core> > int t_currency_protocol_handler<t_core>::handle_notify_new_block(int command, NOTIFY_NEW_BLOCK::request& arg, currency_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "NOTIFY_NEW_BLOCK (hop " << arg.hop << ")" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > if(context.m_state != currency_connection_context::state_normal) > return 1; > > for(auto tx_blob_it = arg.b.txs.begin(); tx_blob_it!=arg.b.txs.end();tx_blob_it++) > { > currency::tx_verification_context tvc = boost::value_initialized<decltype(tvc)>(); > m_core.handle_incoming_tx(*tx_blob_it, tvc, true); > if(tvc.m_verifivation_failed) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Block verification failed: transaction verification failed, dropping connection" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > m_p2p->drop_connection(context); > return 1; > } > } > > > block_verification_context bvc = boost::value_initialized<block_verification_context>(); > m_core.pause_mine(); > m_core.handle_incoming_block(arg.b.block, bvc); > m_core.resume_mine(); > if(bvc.m_verifivation_failed) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Block verification failed, dropping connection" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > m_p2p->drop_connection(context); > return 1; > } > if(bvc.m_added_to_main_chain) > { > ++arg.hop; > > relay_block(arg, context); > }else if(bvc.m_marked_as_orphaned) > { > context.m_state = currency_connection_context::state_synchronizing; > NOTIFY_REQUEST_CHAIN::request r = boost::value_initialized<NOTIFY_REQUEST_CHAIN::request>(); > m_core.get_short_chain_history(r.block_ids); > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "-->>NOTIFY_REQUEST_CHAIN: m_block_ids.size()=" << r.block_ids.size() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > post_notify<NOTIFY_REQUEST_CHAIN>(r, context); > } > > return 1; > } > > template<class t_core> > int t_currency_protocol_handler<t_core>::handle_notify_new_transactions(int command, NOTIFY_NEW_TRANSACTIONS::request& arg, currency_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "NOTIFY_NEW_TRANSACTIONS" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > if(context.m_state != currency_connection_context::state_normal) > return 1; > > for(auto tx_blob_it = arg.txs.begin(); tx_blob_it!=arg.txs.end();) > { > currency::tx_verification_context tvc = boost::value_initialized<decltype(tvc)>(); > m_core.handle_incoming_tx(*tx_blob_it, tvc, false); > if(tvc.m_verifivation_failed) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Tx verification failed, dropping connection" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > m_p2p->drop_connection(context); > return 1; > } > if(tvc.m_should_be_relayed) > ++tx_blob_it; > else > arg.txs.erase(tx_blob_it++); > } > > if(arg.txs.size()) > { > > relay_transactions(arg, context); > } > > return true; > } > > template<class t_core> > int t_currency_protocol_handler<t_core>::handle_request_get_objects(int command, NOTIFY_REQUEST_GET_OBJECTS::request& arg, currency_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "NOTIFY_REQUEST_GET_OBJECTS" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > NOTIFY_RESPONSE_GET_OBJECTS::request rsp; > if(!m_core.handle_get_objects(arg, rsp, context)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" << ":" << 226 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "failed to handle request NOTIFY_REQUEST_GET_OBJECTS, dropping connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_p2p->drop_connection(context); > } > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "-->>NOTIFY_RESPONSE_GET_OBJECTS: blocks.size()=" << rsp.blocks.size() << ", txs.size()=" << rsp.txs.size() << ", rsp.m_current_blockchain_height=" << rsp.current_blockchain_height << ", missed_ids.size()=" << rsp.missed_ids.size() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}} > ; > post_notify<NOTIFY_RESPONSE_GET_OBJECTS>(rsp, context); > return 1; > } > > template<class t_core> > int t_currency_protocol_handler<t_core>::handle_response_get_objects(int command, NOTIFY_RESPONSE_GET_OBJECTS::request& arg, currency_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "NOTIFY_RESPONSE_GET_OBJECTS" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > if(context.m_last_response_height > arg.current_blockchain_height) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" ># 241 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << ":" << > 242 ># 241 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "sent wrong NOTIFY_HAVE_OBJECTS: arg.m_current_blockchain_height=" << arg.current_blockchain_height << " < m_last_response_height=" << context.m_last_response_height << ", dropping connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);} > ; > m_p2p->drop_connection(context); > return 1; > } > > context.m_remote_blockchain_height = arg.current_blockchain_height; > > size_t count = 0; > if (boost::foreach_detail_::auto_any_t _foreach_col250 = boost::foreach_detail_::contain( (arg.blocks) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((arg.blocks), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur250 = boost::foreach_detail_::begin( _foreach_col250 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((arg.blocks), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end250 = boost::foreach_detail_::end( _foreach_col250 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((arg.blocks), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue250 = true; _foreach_continue250 && !boost::foreach_detail_::done( _foreach_cur250 , _foreach_end250 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks)))); _foreach_continue250 ? boost::foreach_detail_::next( _foreach_cur250 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue250)) {} else for (const block_complete_entry& block_entry = boost::foreach_detail_::deref( _foreach_cur250 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks)))); !_foreach_continue250; _foreach_continue250 = true) > { > ++count; > block b; > if(!parse_and_validate_block_from_blob(block_entry.block, b)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" ># 256 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << ":" << > 257 ># 256 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "sent wrong block: failed to parse and validate block: \r\n" << string_tools::buff_to_hex_nodelimer(block_entry.block) << "\r\n dropping connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);} > ; > m_p2p->drop_connection(context); > return 1; > } > > if(count == 2) > { > if(m_core.have_block(get_block_hash(b))) > { > context.m_state = currency_connection_context::state_idle; > context.m_needed_objects.clear(); > context.m_requested_objects.clear(); > {if ( 1 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Connection set to idle state." << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 1, epee::log_space::console_color_default, false, __null);}}; > return 1; > } > } > > auto req_it = context.m_requested_objects.find(get_block_hash(b)); > if(req_it == context.m_requested_objects.end()) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" ># 277 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << ":" << > 278 ># 277 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "sent wrong NOTIFY_RESPONSE_GET_OBJECTS: block with id=" << string_tools::pod_to_hex(get_blob_hash(block_entry.block)) << " wasn't requested, dropping connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);} > ; > m_p2p->drop_connection(context); > return 1; > } > if(b.tx_hashes.size() != block_entry.txs.size()) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" ># 284 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << ":" << > 285 ># 284 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "sent wrong NOTIFY_RESPONSE_GET_OBJECTS: block with id=" << string_tools::pod_to_hex(get_blob_hash(block_entry.block)) << ", tx_hashes.size()=" << b.tx_hashes.size() << " mismatch with block_complete_entry.m_txs.size()=" << block_entry.txs.size() << ", dropping connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);} > ; > m_p2p->drop_connection(context); > return 1; > } > > context.m_requested_objects.erase(req_it); > } > > if(context.m_requested_objects.size()) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "returned not all requested objects (context.m_requested_objects.size()=" << context.m_requested_objects.size() << "), dropping connection" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, false, __null);}} > ; > m_p2p->drop_connection(context); > return 1; > } > > { > m_core.pause_mine(); > misc_utils::auto_scope_leave_caller scope_exit_handler = misc_utils::create_scope_leave_handler( > boost::bind(&t_core::resume_mine, &m_core)); > > if (boost::foreach_detail_::auto_any_t _foreach_col306 = boost::foreach_detail_::contain( (arg.blocks) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((arg.blocks), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur306 = boost::foreach_detail_::begin( _foreach_col306 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((arg.blocks), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end306 = boost::foreach_detail_::end( _foreach_col306 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((arg.blocks), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(arg.blocks) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue306 = true; _foreach_continue306 && !boost::foreach_detail_::done( _foreach_cur306 , _foreach_end306 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks)))); _foreach_continue306 ? boost::foreach_detail_::next( _foreach_cur306 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue306)) {} else for (const block_complete_entry& block_entry = boost::foreach_detail_::deref( _foreach_cur306 , (true ? 0 : boost::foreach_detail_::encode_type(arg.blocks, boost::foreach_detail_::is_const_(arg.blocks)))); !_foreach_continue306; _foreach_continue306 = true) > { > > uint64_t transactions_process_time = misc_utils::get_tick_count();; > if (boost::foreach_detail_::auto_any_t _foreach_col310 = boost::foreach_detail_::contain( (block_entry.txs) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((block_entry.txs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(block_entry.txs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(block_entry.txs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur310 = boost::foreach_detail_::begin( _foreach_col310 , (true ? 0 : boost::foreach_detail_::encode_type(block_entry.txs, boost::foreach_detail_::is_const_(block_entry.txs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((block_entry.txs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(block_entry.txs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(block_entry.txs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end310 = boost::foreach_detail_::end( _foreach_col310 , (true ? 0 : boost::foreach_detail_::encode_type(block_entry.txs, boost::foreach_detail_::is_const_(block_entry.txs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((block_entry.txs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(block_entry.txs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(block_entry.txs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue310 = true; _foreach_continue310 && !boost::foreach_detail_::done( _foreach_cur310 , _foreach_end310 , (true ? 0 : boost::foreach_detail_::encode_type(block_entry.txs, boost::foreach_detail_::is_const_(block_entry.txs)))); _foreach_continue310 ? boost::foreach_detail_::next( _foreach_cur310 , (true ? 0 : boost::foreach_detail_::encode_type(block_entry.txs, boost::foreach_detail_::is_const_(block_entry.txs)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue310)) {} else for (auto& tx_blob = boost::foreach_detail_::deref( _foreach_cur310 , (true ? 0 : boost::foreach_detail_::encode_type(block_entry.txs, boost::foreach_detail_::is_const_(block_entry.txs)))); !_foreach_continue310; _foreach_continue310 = true) > { > tx_verification_context tvc = boost::value_initialized<decltype(tvc)>(); > m_core.handle_incoming_tx(tx_blob, tvc, true); > if(tvc.m_verifivation_failed) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" ># 316 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << ":" << > 317 ># 316 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "transaction verification failed on NOTIFY_RESPONSE_GET_OBJECTS, \r\ntx_id = " << string_tools::pod_to_hex(get_blob_hash(tx_blob)) << ", dropping connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);} > ; > m_p2p->drop_connection(context); > return 1; > } > } > transactions_process_time = misc_utils::get_tick_count() - transactions_process_time;; > > > uint64_t block_process_time = misc_utils::get_tick_count();; > block_verification_context bvc = boost::value_initialized<block_verification_context>(); > > m_core.handle_incoming_block(block_entry.block, bvc, false); > > if(bvc.m_verifivation_failed) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Block verification failed, dropping connection" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > m_p2p->drop_connection(context); > return 1; > } > if(bvc.m_marked_as_orphaned) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Block received at sync phase was marked as orphaned, dropping connection" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > m_p2p->drop_connection(context); > return 1; > } > > block_process_time = misc_utils::get_tick_count() - block_process_time;; > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Block process time: " << block_process_time + transactions_process_time << "(" << transactions_process_time << "/" << block_process_time << ")ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > } > } > > request_missing_objects(context, true); > return 1; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::on_idle() > { > return m_core.on_idle(); > } > > template<class t_core> > int t_currency_protocol_handler<t_core>::handle_request_chain(int command, NOTIFY_REQUEST_CHAIN::request& arg, currency_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "NOTIFY_REQUEST_CHAIN: m_block_ids.size()=" << arg.block_ids.size() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > NOTIFY_RESPONSE_CHAIN_ENTRY::request r; > if(!m_core.find_blockchain_supplement(arg.block_ids, r)) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" << ":" << 365 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "Failed to handle NOTIFY_REQUEST_CHAIN." << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return 1; > } > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "-->>NOTIFY_RESPONSE_CHAIN_ENTRY: m_start_height=" << r.start_height << ", m_total_height=" << r.total_height << ", m_block_ids.size()=" << r.m_block_ids.size() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > post_notify<NOTIFY_RESPONSE_CHAIN_ENTRY>(r, context); > return 1; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::request_missing_objects(currency_connection_context& context, bool check_having_blocks) > { > if(context.m_needed_objects.size()) > { > > NOTIFY_REQUEST_GET_OBJECTS::request req; > size_t count = 0; > auto it = context.m_needed_objects.begin(); > > while(it != context.m_needed_objects.end() && count < 200) > { > if( !(check_having_blocks && m_core.have_block(*it))) > { > req.blocks.push_back(*it); > ++count; > context.m_requested_objects.insert(*it); > } > context.m_needed_objects.erase(it++); > } > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "-->>NOTIFY_REQUEST_GET_OBJECTS: blocks.size()=" << req.blocks.size() << ", txs.size()=" << req.txs.size() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > post_notify<NOTIFY_REQUEST_GET_OBJECTS>(req, context); > }else if(context.m_last_response_height < context.m_remote_blockchain_height-1) > { > > NOTIFY_REQUEST_CHAIN::request r = boost::value_initialized<NOTIFY_REQUEST_CHAIN::request>(); > m_core.get_short_chain_history(r.block_ids); > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "-->>NOTIFY_REQUEST_CHAIN: m_block_ids.size()=" << r.block_ids.size() << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > post_notify<NOTIFY_REQUEST_CHAIN>(r, context); > }else > { > do{if(!(context.m_last_response_height == context.m_remote_blockchain_height-1 && !context.m_needed_objects.size() && !context.m_requested_objects.size())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > > > > > > > "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" ># 404 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << ":" << > > > > > > > 411 ># 404 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << "|" << __FUNCTION__ << "|" << "request_missing_blocks final condition failed!" << "\r\nm_last_response_height=" << context.m_last_response_height << "\r\nm_remote_blockchain_height=" << context.m_remote_blockchain_height << "\r\nm_needed_objects.size()=" << context.m_needed_objects.size() << "\r\nm_requested_objects.size()=" << context.m_requested_objects.size() << "\r\non connection [" << net_utils::print_connection_context_short(context)<< "]" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0) > > > > > > > ; > > context.m_state = currency_connection_context::state_normal; > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << " SYNCHRONIZED OK" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_green, false, __null);}}; > on_connection_synchronized(); > } > return true; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::on_connection_synchronized() > { > bool val_expected = false; > if(m_synchronized.compare_exchange_strong(val_expected, true)) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << std::endl << "**********************************************************************" << std::endl << "You are now synchronized with the network. You may now start simplewallet." << std::endl << std::endl << "Please note, that the blockchain will be saved only after you quit the daemon with \"exit\" command or if you use \"save\" command." << std::endl << "Otherwise, you will possibly need to synchronize the blockchain again." << std::endl << std::endl << "Use \"help\" command to see the list of available commands." << std::endl << "**********************************************************************" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}} > > > > > > > ; > m_core.on_synchronized(); > } > return true; > } > > template<class t_core> > size_t t_currency_protocol_handler<t_core>::get_synchronizing_connections_count() > { > size_t count = 0; > m_p2p->for_each_connection([&](currency_connection_context& context, nodetool::peerid_type peer_id)->bool{ > if(context.m_state == currency_connection_context::state_synchronizing) > ++count; > return true; > }); > return count; > } > > template<class t_core> > int t_currency_protocol_handler<t_core>::handle_response_chain_entry(int command, NOTIFY_RESPONSE_CHAIN_ENTRY::request& arg, currency_connection_context& context) > { > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "NOTIFY_RESPONSE_CHAIN_ENTRY: m_block_ids.size()=" << arg.m_block_ids.size() << ", m_start_height=" << arg.start_height << ", m_total_height=" << arg.total_height << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}} > ; > > if(!arg.m_block_ids.size()) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" << ":" << 459 << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "sent empty m_block_ids, dropping connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > m_p2p->drop_connection(context); > return 1; > } > > if(!m_core.have_block(arg.m_block_ids.front())) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" ># 466 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << ":" << > 467 ># 466 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "sent m_block_ids starting from unknown id: " << string_tools::pod_to_hex(arg.m_block_ids.front()) << " , dropping connection" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);} > ; > m_p2p->drop_connection(context); > return 1; > } > > context.m_remote_blockchain_height = arg.total_height; > context.m_last_response_height = arg.start_height + arg.m_block_ids.size()-1; > if(context.m_last_response_height > context.m_remote_blockchain_height) > { > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << > > "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" ># 476 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << ":" << > > 478 ># 476 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.inl" > << "|" << __FUNCTION__ << "|" << "[" << epee::net_utils::print_connection_context_short(context) << "]" << "sent wrong NOTIFY_RESPONSE_CHAIN_ENTRY, with \r\nm_total_height=" << arg.total_height << "\r\nm_start_height=" << arg.start_height << "\r\nm_block_ids.size()=" << arg.m_block_ids.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);} > > ; > m_p2p->drop_connection(context); > } > > if (boost::foreach_detail_::auto_any_t _foreach_col482 = boost::foreach_detail_::contain( (arg.m_block_ids) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((arg.m_block_ids), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(arg.m_block_ids) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(arg.m_block_ids) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur482 = boost::foreach_detail_::begin( _foreach_col482 , (true ? 0 : boost::foreach_detail_::encode_type(arg.m_block_ids, boost::foreach_detail_::is_const_(arg.m_block_ids))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((arg.m_block_ids), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(arg.m_block_ids) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(arg.m_block_ids) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end482 = boost::foreach_detail_::end( _foreach_col482 , (true ? 0 : boost::foreach_detail_::encode_type(arg.m_block_ids, boost::foreach_detail_::is_const_(arg.m_block_ids))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((arg.m_block_ids), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(arg.m_block_ids) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(arg.m_block_ids) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue482 = true; _foreach_continue482 && !boost::foreach_detail_::done( _foreach_cur482 , _foreach_end482 , (true ? 0 : boost::foreach_detail_::encode_type(arg.m_block_ids, boost::foreach_detail_::is_const_(arg.m_block_ids)))); _foreach_continue482 ? boost::foreach_detail_::next( _foreach_cur482 , (true ? 0 : boost::foreach_detail_::encode_type(arg.m_block_ids, boost::foreach_detail_::is_const_(arg.m_block_ids)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue482)) {} else for (auto& bl_id = boost::foreach_detail_::deref( _foreach_cur482 , (true ? 0 : boost::foreach_detail_::encode_type(arg.m_block_ids, boost::foreach_detail_::is_const_(arg.m_block_ids)))); !_foreach_continue482; _foreach_continue482 = true) > { > if(!m_core.have_block(bl_id)) > context.m_needed_objects.push_back(bl_id); > } > > request_missing_objects(context, false); > return 1; > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::relay_block(NOTIFY_NEW_BLOCK::request& arg, currency_connection_context& exclude_context) > { > return relay_post_notify<NOTIFY_NEW_BLOCK>(arg, exclude_context); > } > > template<class t_core> > bool t_currency_protocol_handler<t_core>::relay_transactions(NOTIFY_NEW_TRANSACTIONS::request& arg, currency_connection_context& exclude_context) > { > return relay_post_notify<NOTIFY_NEW_TRANSACTIONS>(arg, exclude_context); > } >} ># 103 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.h" 2 ># 104 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.h" >#pragma GCC diagnostic pop ># 104 "/c/honeypenny/src/currency_protocol/currency_protocol_handler.h" ># 15 "/c/honeypenny/src/rpc/core_rpc_server.h" 2 > >namespace currency >{ > > > > class core_rpc_server: public epee::http_server_impl_base<core_rpc_server> > { > public: > typedef epee::net_utils::connection_context_base connection_context; > > core_rpc_server(core& cr, nodetool::node_server<currency::t_currency_protocol_handler<currency::core> >& p2p); > > static void init_options(boost::program_options::options_description& desc); > bool init(const boost::program_options::variables_map& vm); > private: > > bool handle_http_request(const epee::net_utils::http::http_request_info& query_info, epee::net_utils::http::http_response_info& response, connection_context& m_conn_context) { {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "HTTP [" << epee::string_tools::get_ip_string_from_int32(m_conn_context.m_remote_ip ) << "] " << query_info.m_http_method_str << " " << query_info.m_URI << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; response.m_response_code = 200; response.m_response_comment = "Ok"; if(!handle_http_request_map(query_info, response, m_conn_context)) {response.m_response_code = 404;response.m_response_comment = "Not found";} return true; }; > > template<class t_context> bool handle_http_request_map(const epee::net_utils::http::http_request_info& query_info, epee::net_utils::http::http_response_info& response_info, t_context& m_conn_context) { bool handled = false; if(false) return true; > else if(query_info.m_URI == "/getheight") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_HEIGHT::request> req; bool parse_res = epee::serialization::load_t_from_json(static_cast<COMMAND_RPC_GET_HEIGHT::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 35 << "|" << __FUNCTION__ << "|" << "Failed to parse json: \r\n" << query_info.m_body << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_HEIGHT::response> resp; if(!on_get_height(static_cast<COMMAND_RPC_GET_HEIGHT::request&>(req), static_cast<COMMAND_RPC_GET_HEIGHT::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 35 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_get_height" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(static_cast<COMMAND_RPC_GET_HEIGHT::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/getheight" << " processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/getblocks.bin") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_BLOCKS_FAST::request> req; bool parse_res = epee::serialization::load_t_from_binary(static_cast<COMMAND_RPC_GET_BLOCKS_FAST::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 36 << "|" << __FUNCTION__ << "|" << "Failed to parse bin body data, body size=" << query_info.m_body.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_BLOCKS_FAST::response> resp; if(!on_get_blocks(static_cast<COMMAND_RPC_GET_BLOCKS_FAST::request&>(req), static_cast<COMMAND_RPC_GET_BLOCKS_FAST::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 36 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_get_blocks" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = misc_utils::get_tick_count(); epee::serialization::store_t_to_binary(static_cast<COMMAND_RPC_GET_BLOCKS_FAST::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = " application/octet-stream"; response_info.m_header_info.m_content_type = " application/octet-stream"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/getblocks.bin" << "() processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/get_o_indexes.bin") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::request> req; bool parse_res = epee::serialization::load_t_from_binary(static_cast<COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 37 << "|" << __FUNCTION__ << "|" << "Failed to parse bin body data, body size=" << query_info.m_body.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::response> resp; if(!on_get_indexes(static_cast<COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::request&>(req), static_cast<COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 37 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_get_indexes" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = misc_utils::get_tick_count(); epee::serialization::store_t_to_binary(static_cast<COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = " application/octet-stream"; response_info.m_header_info.m_content_type = " application/octet-stream"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/get_o_indexes.bin" << "() processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/getrandom_outs.bin") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::request> req; bool parse_res = epee::serialization::load_t_from_binary(static_cast<COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 38 << "|" << __FUNCTION__ << "|" << "Failed to parse bin body data, body size=" << query_info.m_body.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::response> resp; if(!on_get_random_outs(static_cast<COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::request&>(req), static_cast<COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 38 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_get_random_outs" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = misc_utils::get_tick_count(); epee::serialization::store_t_to_binary(static_cast<COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = " application/octet-stream"; response_info.m_header_info.m_content_type = " application/octet-stream"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/getrandom_outs.bin" << "() processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/set_maintainers_info.bin") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_SET_MAINTAINERS_INFO::request> req; bool parse_res = epee::serialization::load_t_from_binary(static_cast<COMMAND_RPC_SET_MAINTAINERS_INFO::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 39 << "|" << __FUNCTION__ << "|" << "Failed to parse bin body data, body size=" << query_info.m_body.size() << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_SET_MAINTAINERS_INFO::response> resp; if(!on_set_maintainers_info(static_cast<COMMAND_RPC_SET_MAINTAINERS_INFO::request&>(req), static_cast<COMMAND_RPC_SET_MAINTAINERS_INFO::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 39 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_set_maintainers_info" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = misc_utils::get_tick_count(); epee::serialization::store_t_to_binary(static_cast<COMMAND_RPC_SET_MAINTAINERS_INFO::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = " application/octet-stream"; response_info.m_header_info.m_content_type = " application/octet-stream"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/set_maintainers_info.bin" << "() processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/gettransactions") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_TRANSACTIONS::request> req; bool parse_res = epee::serialization::load_t_from_json(static_cast<COMMAND_RPC_GET_TRANSACTIONS::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 40 << "|" << __FUNCTION__ << "|" << "Failed to parse json: \r\n" << query_info.m_body << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_TRANSACTIONS::response> resp; if(!on_get_transactions(static_cast<COMMAND_RPC_GET_TRANSACTIONS::request&>(req), static_cast<COMMAND_RPC_GET_TRANSACTIONS::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 40 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_get_transactions" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(static_cast<COMMAND_RPC_GET_TRANSACTIONS::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/gettransactions" << " processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/sendrawtransaction") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_SEND_RAW_TX::request> req; bool parse_res = epee::serialization::load_t_from_json(static_cast<COMMAND_RPC_SEND_RAW_TX::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 41 << "|" << __FUNCTION__ << "|" << "Failed to parse json: \r\n" << query_info.m_body << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_SEND_RAW_TX::response> resp; if(!on_send_raw_tx(static_cast<COMMAND_RPC_SEND_RAW_TX::request&>(req), static_cast<COMMAND_RPC_SEND_RAW_TX::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 41 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_send_raw_tx" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(static_cast<COMMAND_RPC_SEND_RAW_TX::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/sendrawtransaction" << " processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/start_mining") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_START_MINING::request> req; bool parse_res = epee::serialization::load_t_from_json(static_cast<COMMAND_RPC_START_MINING::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 42 << "|" << __FUNCTION__ << "|" << "Failed to parse json: \r\n" << query_info.m_body << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_START_MINING::response> resp; if(!on_start_mining(static_cast<COMMAND_RPC_START_MINING::request&>(req), static_cast<COMMAND_RPC_START_MINING::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 42 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_start_mining" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(static_cast<COMMAND_RPC_START_MINING::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/start_mining" << " processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/stop_mining") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_STOP_MINING::request> req; bool parse_res = epee::serialization::load_t_from_json(static_cast<COMMAND_RPC_STOP_MINING::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 43 << "|" << __FUNCTION__ << "|" << "Failed to parse json: \r\n" << query_info.m_body << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_STOP_MINING::response> resp; if(!on_stop_mining(static_cast<COMMAND_RPC_STOP_MINING::request&>(req), static_cast<COMMAND_RPC_STOP_MINING::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 43 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_stop_mining" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(static_cast<COMMAND_RPC_STOP_MINING::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/stop_mining" << " processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/getinfo") { handled = true; uint64_t ticks = misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_INFO::request> req; bool parse_res = epee::serialization::load_t_from_json(static_cast<COMMAND_RPC_GET_INFO::request&>(req), query_info.m_body); do{if(!(parse_res)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 44 << "|" << __FUNCTION__ << "|" << "Failed to parse json: \r\n" << query_info.m_body << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<COMMAND_RPC_GET_INFO::response> resp; if(!on_get_info(static_cast<COMMAND_RPC_GET_INFO::request&>(req), static_cast<COMMAND_RPC_GET_INFO::response&>(resp), m_conn_context)) { { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.h" << ":" << 44 << "|" << __FUNCTION__ << "|" << "Failed to " << "on_get_info" << "()" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; response_info.m_response_code = 500; response_info.m_response_comment = "Internal Server Error"; return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(static_cast<COMMAND_RPC_GET_INFO::response&>(resp), response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "/getinfo" << " processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; } > else if(query_info.m_URI == "/json_rpc") { uint64_t ticks = epee::misc_utils::get_tick_count(); epee::serialization::portable_storage ps; if(!ps.load_from_json(query_info.m_body)) { boost::value_initialized<epee::json_rpc::error_response> rsp; static_cast<epee::json_rpc::error_response&>(rsp).error.code = -32700; static_cast<epee::json_rpc::error_response&>(rsp).error.message = "Parse error"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(rsp), response_info.m_body); return true; } epee::serialization::storage_entry id_; id_ = epee::serialization::storage_entry(std::string()); ps.get_value("id", id_, nullptr); std::string callback_name; if(!ps.get_value("method", callback_name, nullptr)) { epee::json_rpc::error_response rsp; rsp.jsonrpc = "2.0"; rsp.error.code = -32600; rsp.error.message = "Invalid Request"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(rsp), response_info.m_body); return true; } if(false) return true; > else if(callback_name == "getblockcount") { handled = true; boost::value_initialized<epee::json_rpc::request<COMMAND_RPC_GETBLOCKCOUNT::request> > req_; epee::json_rpc::request<COMMAND_RPC_GETBLOCKCOUNT::request>& req = static_cast<epee::json_rpc::request<COMMAND_RPC_GETBLOCKCOUNT::request>&>(req_); if(!req.load(ps)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32602; fail_resp.error.message = "Invalid params"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<epee::json_rpc::response<COMMAND_RPC_GETBLOCKCOUNT::response, epee::json_rpc::dummy_error> > resp_; epee::json_rpc::response<COMMAND_RPC_GETBLOCKCOUNT::response, epee::json_rpc::dummy_error>& resp = static_cast<epee::json_rpc::response<COMMAND_RPC_GETBLOCKCOUNT::response, epee::json_rpc::dummy_error> &>(resp_); resp.jsonrpc = "2.0"; resp.id = req.id; if(!on_getblockcount(req.params, resp.result, m_conn_context)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32603; fail_resp.error.message = "Internal error"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(resp, response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << query_info.m_URI << "[" << "getblockcount" << "] processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; return true;} > else if(callback_name == "on_getblockhash") { handled = true; boost::value_initialized<epee::json_rpc::request<COMMAND_RPC_GETBLOCKHASH::request> > req_; epee::json_rpc::request<COMMAND_RPC_GETBLOCKHASH::request>& req = static_cast<epee::json_rpc::request<COMMAND_RPC_GETBLOCKHASH::request>&>(req_); if(!req.load(ps)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32602; fail_resp.error.message = "Invalid params"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<epee::json_rpc::response<COMMAND_RPC_GETBLOCKHASH::response, epee::json_rpc::dummy_error> > resp_; epee::json_rpc::response<COMMAND_RPC_GETBLOCKHASH::response, epee::json_rpc::dummy_error>& resp = static_cast<epee::json_rpc::response<COMMAND_RPC_GETBLOCKHASH::response, epee::json_rpc::dummy_error> &>(resp_); resp.jsonrpc = "2.0"; resp.id = req.id; epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; if(!on_getblockhash(req.params, resp.result, fail_resp.error, m_conn_context)) { epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(resp, response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << query_info.m_URI << "[" << "on_getblockhash" << "] processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; return true;} > else if(callback_name == "getblocktemplate") { handled = true; boost::value_initialized<epee::json_rpc::request<COMMAND_RPC_GETBLOCKTEMPLATE::request> > req_; epee::json_rpc::request<COMMAND_RPC_GETBLOCKTEMPLATE::request>& req = static_cast<epee::json_rpc::request<COMMAND_RPC_GETBLOCKTEMPLATE::request>&>(req_); if(!req.load(ps)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32602; fail_resp.error.message = "Invalid params"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<epee::json_rpc::response<COMMAND_RPC_GETBLOCKTEMPLATE::response, epee::json_rpc::dummy_error> > resp_; epee::json_rpc::response<COMMAND_RPC_GETBLOCKTEMPLATE::response, epee::json_rpc::dummy_error>& resp = static_cast<epee::json_rpc::response<COMMAND_RPC_GETBLOCKTEMPLATE::response, epee::json_rpc::dummy_error> &>(resp_); resp.jsonrpc = "2.0"; resp.id = req.id; epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; if(!on_getblocktemplate(req.params, resp.result, fail_resp.error, m_conn_context)) { epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(resp, response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << query_info.m_URI << "[" << "getblocktemplate" << "] processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; return true;} > else if(callback_name == "submitblock") { handled = true; boost::value_initialized<epee::json_rpc::request<COMMAND_RPC_SUBMITBLOCK::request> > req_; epee::json_rpc::request<COMMAND_RPC_SUBMITBLOCK::request>& req = static_cast<epee::json_rpc::request<COMMAND_RPC_SUBMITBLOCK::request>&>(req_); if(!req.load(ps)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32602; fail_resp.error.message = "Invalid params"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<epee::json_rpc::response<COMMAND_RPC_SUBMITBLOCK::response, epee::json_rpc::dummy_error> > resp_; epee::json_rpc::response<COMMAND_RPC_SUBMITBLOCK::response, epee::json_rpc::dummy_error>& resp = static_cast<epee::json_rpc::response<COMMAND_RPC_SUBMITBLOCK::response, epee::json_rpc::dummy_error> &>(resp_); resp.jsonrpc = "2.0"; resp.id = req.id; epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; if(!on_submitblock(req.params, resp.result, fail_resp.error, m_conn_context)) { epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(resp, response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << query_info.m_URI << "[" << "submitblock" << "] processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; return true;} > else if(callback_name == "getlastblockheader") { handled = true; boost::value_initialized<epee::json_rpc::request<COMMAND_RPC_GET_LAST_BLOCK_HEADER::request> > req_; epee::json_rpc::request<COMMAND_RPC_GET_LAST_BLOCK_HEADER::request>& req = static_cast<epee::json_rpc::request<COMMAND_RPC_GET_LAST_BLOCK_HEADER::request>&>(req_); if(!req.load(ps)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32602; fail_resp.error.message = "Invalid params"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<epee::json_rpc::response<COMMAND_RPC_GET_LAST_BLOCK_HEADER::response, epee::json_rpc::dummy_error> > resp_; epee::json_rpc::response<COMMAND_RPC_GET_LAST_BLOCK_HEADER::response, epee::json_rpc::dummy_error>& resp = static_cast<epee::json_rpc::response<COMMAND_RPC_GET_LAST_BLOCK_HEADER::response, epee::json_rpc::dummy_error> &>(resp_); resp.jsonrpc = "2.0"; resp.id = req.id; epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; if(!on_get_last_block_header(req.params, resp.result, fail_resp.error, m_conn_context)) { epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(resp, response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << query_info.m_URI << "[" << "getlastblockheader" << "] processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; return true;} > else if(callback_name == "getblockheaderbyhash") { handled = true; boost::value_initialized<epee::json_rpc::request<COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::request> > req_; epee::json_rpc::request<COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::request>& req = static_cast<epee::json_rpc::request<COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::request>&>(req_); if(!req.load(ps)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32602; fail_resp.error.message = "Invalid params"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<epee::json_rpc::response<COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::response, epee::json_rpc::dummy_error> > resp_; epee::json_rpc::response<COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::response, epee::json_rpc::dummy_error>& resp = static_cast<epee::json_rpc::response<COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::response, epee::json_rpc::dummy_error> &>(resp_); resp.jsonrpc = "2.0"; resp.id = req.id; epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; if(!on_get_block_header_by_hash(req.params, resp.result, fail_resp.error, m_conn_context)) { epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(resp, response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << query_info.m_URI << "[" << "getblockheaderbyhash" << "] processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; return true;} > else if(callback_name == "getblockheaderbyheight") { handled = true; boost::value_initialized<epee::json_rpc::request<COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::request> > req_; epee::json_rpc::request<COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::request>& req = static_cast<epee::json_rpc::request<COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::request>&>(req_); if(!req.load(ps)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32602; fail_resp.error.message = "Invalid params"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<epee::json_rpc::response<COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::response, epee::json_rpc::dummy_error> > resp_; epee::json_rpc::response<COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::response, epee::json_rpc::dummy_error>& resp = static_cast<epee::json_rpc::response<COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::response, epee::json_rpc::dummy_error> &>(resp_); resp.jsonrpc = "2.0"; resp.id = req.id; epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; if(!on_get_block_header_by_height(req.params, resp.result, fail_resp.error, m_conn_context)) { epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(resp, response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << query_info.m_URI << "[" << "getblockheaderbyheight" << "] processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; return true;} > else if(callback_name == "get_alias_details") { handled = true; boost::value_initialized<epee::json_rpc::request<COMMAND_RPC_GET_ALIAS_DETAILS::request> > req_; epee::json_rpc::request<COMMAND_RPC_GET_ALIAS_DETAILS::request>& req = static_cast<epee::json_rpc::request<COMMAND_RPC_GET_ALIAS_DETAILS::request>&>(req_); if(!req.load(ps)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32602; fail_resp.error.message = "Invalid params"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<epee::json_rpc::response<COMMAND_RPC_GET_ALIAS_DETAILS::response, epee::json_rpc::dummy_error> > resp_; epee::json_rpc::response<COMMAND_RPC_GET_ALIAS_DETAILS::response, epee::json_rpc::dummy_error>& resp = static_cast<epee::json_rpc::response<COMMAND_RPC_GET_ALIAS_DETAILS::response, epee::json_rpc::dummy_error> &>(resp_); resp.jsonrpc = "2.0"; resp.id = req.id; epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; if(!on_get_alias_details(req.params, resp.result, fail_resp.error, m_conn_context)) { epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(resp, response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << query_info.m_URI << "[" << "get_alias_details" << "] processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; return true;} > else if(callback_name == "get_all_alias_details") { handled = true; boost::value_initialized<epee::json_rpc::request<COMMAND_RPC_GET_ALL_ALIASES::request> > req_; epee::json_rpc::request<COMMAND_RPC_GET_ALL_ALIASES::request>& req = static_cast<epee::json_rpc::request<COMMAND_RPC_GET_ALL_ALIASES::request>&>(req_); if(!req.load(ps)) { epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; fail_resp.error.code = -32602; fail_resp.error.message = "Invalid params"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks1 = epee::misc_utils::get_tick_count(); boost::value_initialized<epee::json_rpc::response<COMMAND_RPC_GET_ALL_ALIASES::response, epee::json_rpc::dummy_error> > resp_; epee::json_rpc::response<COMMAND_RPC_GET_ALL_ALIASES::response, epee::json_rpc::dummy_error>& resp = static_cast<epee::json_rpc::response<COMMAND_RPC_GET_ALL_ALIASES::response, epee::json_rpc::dummy_error> &>(resp_); resp.jsonrpc = "2.0"; resp.id = req.id; epee::json_rpc::error_response fail_resp = boost::value_initialized<decltype(fail_resp)>(); fail_resp.jsonrpc = "2.0"; fail_resp.id = req.id; if(!on_get_all_aliases(req.params, resp.result, fail_resp.error, m_conn_context)) { epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(fail_resp), response_info.m_body); return true; } uint64_t ticks2 = epee::misc_utils::get_tick_count(); epee::serialization::store_t_to_json(resp, response_info.m_body); uint64_t ticks3 = epee::misc_utils::get_tick_count(); response_info.m_mime_tipe = "application/json"; response_info.m_header_info.m_content_type = " application/json"; {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << query_info.m_URI << "[" << "get_all_alias_details" << "] processed with " << ticks1-ticks << "/"<< ticks2-ticks1 << "/" << ticks3-ticks2 << "ms" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; return true;} > epee::json_rpc::error_response rsp; rsp.id = id_; rsp.jsonrpc = "2.0"; rsp.error.code = -32601; rsp.error.message = "Method not found"; epee::serialization::store_t_to_json(static_cast<epee::json_rpc::error_response&>(rsp), response_info.m_body); return true; } > return handled;} > > bool on_get_height(const COMMAND_RPC_GET_HEIGHT::request& req, COMMAND_RPC_GET_HEIGHT::response& res, connection_context& cntx); > bool on_get_blocks(const COMMAND_RPC_GET_BLOCKS_FAST::request& req, COMMAND_RPC_GET_BLOCKS_FAST::response& res, connection_context& cntx); > bool on_get_transactions(const COMMAND_RPC_GET_TRANSACTIONS::request& req, COMMAND_RPC_GET_TRANSACTIONS::response& res, connection_context& cntx); > bool on_get_indexes(const COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::request& req, COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::response& res, connection_context& cntx); > bool on_send_raw_tx(const COMMAND_RPC_SEND_RAW_TX::request& req, COMMAND_RPC_SEND_RAW_TX::response& res, connection_context& cntx); > bool on_start_mining(const COMMAND_RPC_START_MINING::request& req, COMMAND_RPC_START_MINING::response& res, connection_context& cntx); > bool on_stop_mining(const COMMAND_RPC_STOP_MINING::request& req, COMMAND_RPC_STOP_MINING::response& res, connection_context& cntx); > bool on_get_random_outs(const COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::request& req, COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::response& res, connection_context& cntx); > bool on_get_info(const COMMAND_RPC_GET_INFO::request& req, COMMAND_RPC_GET_INFO::response& res, connection_context& cntx); > bool on_set_maintainers_info(const COMMAND_RPC_SET_MAINTAINERS_INFO::request& req, COMMAND_RPC_SET_MAINTAINERS_INFO::response& res, connection_context& cntx); > > > bool on_getblockcount(const COMMAND_RPC_GETBLOCKCOUNT::request& req, COMMAND_RPC_GETBLOCKCOUNT::response& res, connection_context& cntx); > bool on_getblockhash(const COMMAND_RPC_GETBLOCKHASH::request& req, COMMAND_RPC_GETBLOCKHASH::response& res, epee::json_rpc::error& error_resp, connection_context& cntx); > bool on_getblocktemplate(const COMMAND_RPC_GETBLOCKTEMPLATE::request& req, COMMAND_RPC_GETBLOCKTEMPLATE::response& res, epee::json_rpc::error& error_resp, connection_context& cntx); > bool on_submitblock(const COMMAND_RPC_SUBMITBLOCK::request& req, COMMAND_RPC_SUBMITBLOCK::response& res, epee::json_rpc::error& error_resp, connection_context& cntx); > bool on_get_last_block_header(const COMMAND_RPC_GET_LAST_BLOCK_HEADER::request& req, COMMAND_RPC_GET_LAST_BLOCK_HEADER::response& res, epee::json_rpc::error& error_resp, connection_context& cntx); > bool on_get_block_header_by_hash(const COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::request& req, COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::response& res, epee::json_rpc::error& error_resp, connection_context& cntx); > bool on_get_block_header_by_height(const COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::request& req, COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::response& res, epee::json_rpc::error& error_resp, connection_context& cntx); > bool on_get_alias_details(const COMMAND_RPC_GET_ALIAS_DETAILS::request& req, COMMAND_RPC_GET_ALIAS_DETAILS::response& res, epee::json_rpc::error& error_resp, connection_context& cntx); > bool on_get_all_aliases(const COMMAND_RPC_GET_ALL_ALIASES::request& req, COMMAND_RPC_GET_ALL_ALIASES::response& res, epee::json_rpc::error& error_resp, connection_context& cntx); > > bool handle_command_line(const boost::program_options::variables_map& vm); > bool check_core_ready(); > > > uint64_t get_block_reward(const block& blk); > bool fill_block_header_responce(const block& blk, bool orphan_status, block_header_responce& responce); > > core& m_core; > nodetool::node_server<currency::t_currency_protocol_handler<currency::core> >& m_p2p; > std::string m_port; > std::string m_bind_ip; > }; >} ># 11 "/c/honeypenny/src/rpc/core_rpc_server.cpp" 2 > > > > > > ># 1 "/c/honeypenny/src/rpc/core_rpc_server_error_codes.h" 1 ># 18 "/c/honeypenny/src/rpc/core_rpc_server.cpp" 2 > >namespace currency >{ > namespace > { > const command_line::arg_descriptor<std::string> arg_rpc_bind_ip = {"rpc-bind-ip", "", "127.0.0.1"}; > const command_line::arg_descriptor<std::string> arg_rpc_bind_port = {"rpc-bind-port", "", std::to_string(20102)}; > } > > > void core_rpc_server::init_options(boost::program_options::options_description& desc) > { > command_line::add_arg(desc, arg_rpc_bind_ip); > command_line::add_arg(desc, arg_rpc_bind_port); > } > > core_rpc_server::core_rpc_server(core& cr, nodetool::node_server<currency::t_currency_protocol_handler<currency::core> >& p2p):m_core(cr), m_p2p(p2p) > {} > > bool core_rpc_server::handle_command_line(const boost::program_options::variables_map& vm) > { > m_bind_ip = command_line::get_arg(vm, arg_rpc_bind_ip); > m_port = command_line::get_arg(vm, arg_rpc_bind_port); > return true; > } > > bool core_rpc_server::init(const boost::program_options::variables_map& vm) > { > m_net_server.set_threads_prefix("RPC"); > bool r = handle_command_line(vm); > do{if(!(r)) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.cpp" << ":" << 48 << "|" << __FUNCTION__ << "|" << "Failed to process command line in core_rpc_server" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return false;};}while(0); > return epee::http_server_impl_base<core_rpc_server, connection_context>::init(m_port, m_bind_ip); > } > > bool core_rpc_server::check_core_ready() > { > if(!m_p2p.get_payload_object().is_synchronized()) > { > return false; > } > if(m_p2p.get_payload_object().get_core().get_blockchain_storage().is_storing_blockchain()) > { > return false; > } > return true; > } > > > > bool core_rpc_server::on_get_height(const COMMAND_RPC_GET_HEIGHT::request& req, COMMAND_RPC_GET_HEIGHT::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > res.height = m_core.get_current_blockchain_height(); > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_get_info(const COMMAND_RPC_GET_INFO::request& req, COMMAND_RPC_GET_INFO::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > res.height = m_core.get_current_blockchain_height(); > res.difficulty = m_core.get_blockchain_storage().get_difficulty_for_next_block(); > res.tx_count = m_core.get_blockchain_storage().get_total_transactions() - res.height; > res.tx_pool_size = m_core.get_pool_transactions_count(); > res.alt_blocks_count = m_core.get_blockchain_storage().get_alternative_blocks_count(); > uint64_t total_conn = m_p2p.get_connections_count(); > res.outgoing_connections_count = m_p2p.get_outgoing_connections_count(); > res.incoming_connections_count = total_conn - res.outgoing_connections_count; > res.white_peerlist_size = m_p2p.get_peerlist_manager().get_white_peers_count(); > res.grey_peerlist_size = m_p2p.get_peerlist_manager().get_gray_peers_count(); > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_get_blocks(const COMMAND_RPC_GET_BLOCKS_FAST::request& req, COMMAND_RPC_GET_BLOCKS_FAST::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > std::list<std::pair<block, std::list<transaction> > > bs; > if(!m_core.find_blockchain_supplement(req.block_ids, bs, res.current_height, res.start_height, 1000)) > { > res.status = "Failed"; > return false; > } > > if (boost::foreach_detail_::auto_any_t _foreach_col102 = boost::foreach_detail_::contain( (bs) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((bs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(bs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(bs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur102 = boost::foreach_detail_::begin( _foreach_col102 , (true ? 0 : boost::foreach_detail_::encode_type(bs, boost::foreach_detail_::is_const_(bs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((bs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(bs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(bs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end102 = boost::foreach_detail_::end( _foreach_col102 , (true ? 0 : boost::foreach_detail_::encode_type(bs, boost::foreach_detail_::is_const_(bs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((bs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(bs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(bs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue102 = true; _foreach_continue102 && !boost::foreach_detail_::done( _foreach_cur102 , _foreach_end102 , (true ? 0 : boost::foreach_detail_::encode_type(bs, boost::foreach_detail_::is_const_(bs)))); _foreach_continue102 ? boost::foreach_detail_::next( _foreach_cur102 , (true ? 0 : boost::foreach_detail_::encode_type(bs, boost::foreach_detail_::is_const_(bs)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue102)) {} else for (auto& b = boost::foreach_detail_::deref( _foreach_cur102 , (true ? 0 : boost::foreach_detail_::encode_type(bs, boost::foreach_detail_::is_const_(bs)))); !_foreach_continue102; _foreach_continue102 = true) > { > res.blocks.resize(res.blocks.size()+1); > res.blocks.back().block = block_to_blob(b.first); > if (boost::foreach_detail_::auto_any_t _foreach_col106 = boost::foreach_detail_::contain( (b.second) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((b.second), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(b.second) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(b.second) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur106 = boost::foreach_detail_::begin( _foreach_col106 , (true ? 0 : boost::foreach_detail_::encode_type(b.second, boost::foreach_detail_::is_const_(b.second))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((b.second), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(b.second) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(b.second) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end106 = boost::foreach_detail_::end( _foreach_col106 , (true ? 0 : boost::foreach_detail_::encode_type(b.second, boost::foreach_detail_::is_const_(b.second))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((b.second), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(b.second) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(b.second) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue106 = true; _foreach_continue106 && !boost::foreach_detail_::done( _foreach_cur106 , _foreach_end106 , (true ? 0 : boost::foreach_detail_::encode_type(b.second, boost::foreach_detail_::is_const_(b.second)))); _foreach_continue106 ? boost::foreach_detail_::next( _foreach_cur106 , (true ? 0 : boost::foreach_detail_::encode_type(b.second, boost::foreach_detail_::is_const_(b.second)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue106)) {} else for (auto& t = boost::foreach_detail_::deref( _foreach_cur106 , (true ? 0 : boost::foreach_detail_::encode_type(b.second, boost::foreach_detail_::is_const_(b.second)))); !_foreach_continue106; _foreach_continue106 = true) > { > res.blocks.back().txs.push_back(tx_to_blob(t)); > } > } > > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_get_random_outs(const COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::request& req, COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > res.status = "Failed"; > if(!m_core.get_random_outs_for_amounts(req, res)) > { > return true; > } > > res.status = "OK"; > std::stringstream ss; > typedef COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::outs_for_amount outs_for_amount; > typedef COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS::out_entry out_entry; > std::for_each(res.outs.begin(), res.outs.end(), [&](outs_for_amount& ofa) > { > ss << "[" << ofa.amount << "]:"; > do{if(!(ofa.outs.size())) {{ std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.cpp" << ":" << 132 << "|" << __FUNCTION__ << "|" << "internal error: ofa.outs.size() is empty for amount " << ofa.amount << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; return ;;};}while(0); > std::for_each(ofa.outs.begin(), ofa.outs.end(), [&](out_entry& oe) > { > ss << oe.global_amount_index << " "; > }); > ss << std::endl; > }); > std::string s = ss.str(); > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "COMMAND_RPC_GET_RANDOM_OUTPUTS_FOR_AMOUNTS: " << std::endl << s << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_get_indexes(const COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::request& req, COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > bool r = m_core.get_tx_outputs_gindexs(req.txid, res.o_indexes); > if(!r) > { > res.status = "Failed"; > return true; > } > res.status = "OK"; > {if ( 2 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "COMMAND_RPC_GET_TX_GLOBAL_OUTPUTS_INDEXES: [" << res.o_indexes.size() << "]" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 2, epee::log_space::console_color_default, false, __null);}}; > return true; > } > > bool core_rpc_server::on_set_maintainers_info(const COMMAND_RPC_SET_MAINTAINERS_INFO::request& req, COMMAND_RPC_SET_MAINTAINERS_INFO::response& res, connection_context& cntx) > { > if(!m_p2p.handle_maintainers_entry(req)) > { > res.status = "Failed to get call handle_maintainers_entry()"; > return true; > } > > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_get_transactions(const COMMAND_RPC_GET_TRANSACTIONS::request& req, COMMAND_RPC_GET_TRANSACTIONS::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > std::vector<crypto::hash> vh; > if (boost::foreach_detail_::auto_any_t _foreach_col175 = boost::foreach_detail_::contain( (req.txs_hashes) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((req.txs_hashes), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(req.txs_hashes) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(req.txs_hashes) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur175 = boost::foreach_detail_::begin( _foreach_col175 , (true ? 0 : boost::foreach_detail_::encode_type(req.txs_hashes, boost::foreach_detail_::is_const_(req.txs_hashes))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((req.txs_hashes), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(req.txs_hashes) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(req.txs_hashes) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end175 = boost::foreach_detail_::end( _foreach_col175 , (true ? 0 : boost::foreach_detail_::encode_type(req.txs_hashes, boost::foreach_detail_::is_const_(req.txs_hashes))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((req.txs_hashes), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(req.txs_hashes) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(req.txs_hashes) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue175 = true; _foreach_continue175 && !boost::foreach_detail_::done( _foreach_cur175 , _foreach_end175 , (true ? 0 : boost::foreach_detail_::encode_type(req.txs_hashes, boost::foreach_detail_::is_const_(req.txs_hashes)))); _foreach_continue175 ? boost::foreach_detail_::next( _foreach_cur175 , (true ? 0 : boost::foreach_detail_::encode_type(req.txs_hashes, boost::foreach_detail_::is_const_(req.txs_hashes)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue175)) {} else for (const auto& tx_hex_str = boost::foreach_detail_::deref( _foreach_cur175 , (true ? 0 : boost::foreach_detail_::encode_type(req.txs_hashes, boost::foreach_detail_::is_const_(req.txs_hashes)))); !_foreach_continue175; _foreach_continue175 = true) > { > blobdata b; > if(!string_tools::parse_hexstr_to_binbuff(tx_hex_str, b)) > { > res.status = "Failed to parse hex representation of transaction hash"; > return true; > } > if(b.size() != sizeof(crypto::hash)) > { > res.status = "Failed, size of data mismatch"; > } > vh.push_back(*reinterpret_cast<const crypto::hash*>(b.data())); > } > std::list<crypto::hash> missed_txs; > std::list<transaction> txs; > bool r = m_core.get_transactions(vh, txs, missed_txs); > if(!r) > { > res.status = "Failed"; > return true; > } > > if (boost::foreach_detail_::auto_any_t _foreach_col198 = boost::foreach_detail_::contain( (txs) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((txs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(txs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(txs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur198 = boost::foreach_detail_::begin( _foreach_col198 , (true ? 0 : boost::foreach_detail_::encode_type(txs, boost::foreach_detail_::is_const_(txs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((txs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(txs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(txs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end198 = boost::foreach_detail_::end( _foreach_col198 , (true ? 0 : boost::foreach_detail_::encode_type(txs, boost::foreach_detail_::is_const_(txs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((txs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(txs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(txs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue198 = true; _foreach_continue198 && !boost::foreach_detail_::done( _foreach_cur198 , _foreach_end198 , (true ? 0 : boost::foreach_detail_::encode_type(txs, boost::foreach_detail_::is_const_(txs)))); _foreach_continue198 ? boost::foreach_detail_::next( _foreach_cur198 , (true ? 0 : boost::foreach_detail_::encode_type(txs, boost::foreach_detail_::is_const_(txs)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue198)) {} else for (auto& tx = boost::foreach_detail_::deref( _foreach_cur198 , (true ? 0 : boost::foreach_detail_::encode_type(txs, boost::foreach_detail_::is_const_(txs)))); !_foreach_continue198; _foreach_continue198 = true) > { > blobdata blob = t_serializable_object_to_blob(tx); > res.txs_as_hex.push_back(string_tools::buff_to_hex_nodelimer(blob)); > } > > if (boost::foreach_detail_::auto_any_t _foreach_col204 = boost::foreach_detail_::contain( (missed_txs) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((missed_txs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(missed_txs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(missed_txs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur204 = boost::foreach_detail_::begin( _foreach_col204 , (true ? 0 : boost::foreach_detail_::encode_type(missed_txs, boost::foreach_detail_::is_const_(missed_txs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((missed_txs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(missed_txs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(missed_txs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end204 = boost::foreach_detail_::end( _foreach_col204 , (true ? 0 : boost::foreach_detail_::encode_type(missed_txs, boost::foreach_detail_::is_const_(missed_txs))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((missed_txs), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(missed_txs) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(missed_txs) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue204 = true; _foreach_continue204 && !boost::foreach_detail_::done( _foreach_cur204 , _foreach_end204 , (true ? 0 : boost::foreach_detail_::encode_type(missed_txs, boost::foreach_detail_::is_const_(missed_txs)))); _foreach_continue204 ? boost::foreach_detail_::next( _foreach_cur204 , (true ? 0 : boost::foreach_detail_::encode_type(missed_txs, boost::foreach_detail_::is_const_(missed_txs)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue204)) {} else for (const auto& miss_tx = boost::foreach_detail_::deref( _foreach_cur204 , (true ? 0 : boost::foreach_detail_::encode_type(missed_txs, boost::foreach_detail_::is_const_(missed_txs)))); !_foreach_continue204; _foreach_continue204 = true) > { > res.missed_tx.push_back(string_tools::pod_to_hex(miss_tx)); > } > > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_send_raw_tx(const COMMAND_RPC_SEND_RAW_TX::request& req, COMMAND_RPC_SEND_RAW_TX::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > > std::string tx_blob; > if(!string_tools::parse_hexstr_to_binbuff(req.tx_as_hex, tx_blob)) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[on_send_raw_tx]: Failed to parse tx from hexbuff: " << req.tx_as_hex << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > res.status = "Failed"; > return true; > } > > currency_connection_context fake_context = boost::value_initialized<decltype(fake_context)>(); > tx_verification_context tvc = boost::value_initialized<decltype(tvc)>(); > if(!m_core.handle_incoming_tx(tx_blob, tvc, false)) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[on_send_raw_tx]: Failed to process tx" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > res.status = "Failed"; > return true; > } > > if(tvc.m_verifivation_failed) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[on_send_raw_tx]: tx verification failed" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > res.status = "Failed"; > return true; > } > > if(!tvc.m_should_be_relayed) > { > {if ( 0 <= epee::log_space::log_singletone::get_log_detalisation_level() ) {std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "[on_send_raw_tx]: tx accepted, but not relayed" << std::endl;epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_default, false, __null);}}; > res.status = "Not relayed"; > return true; > } > > > NOTIFY_NEW_TRANSACTIONS::request r; > r.txs.push_back(tx_blob); > m_core.get_protocol()->relay_transactions(r, fake_context); > > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_start_mining(const COMMAND_RPC_START_MINING::request& req, COMMAND_RPC_START_MINING::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > account_public_address adr; > if(!get_account_address_from_str(adr, req.miner_address)) > { > res.status = "Failed, wrong address"; > return true; > } > > if(!m_core.get_miner().start(adr, static_cast<size_t>(req.threads_count))) > { > res.status = "Failed, mining not started"; > return true; > } > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_stop_mining(const COMMAND_RPC_STOP_MINING::request& req, COMMAND_RPC_STOP_MINING::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > if(!m_core.get_miner().stop()) > { > res.status = "Failed, mining not stopped"; > return true; > } > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_getblockcount(const COMMAND_RPC_GETBLOCKCOUNT::request& req, COMMAND_RPC_GETBLOCKCOUNT::response& res, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > res.count = m_core.get_current_blockchain_height(); > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_getblockhash(const COMMAND_RPC_GETBLOCKHASH::request& req, COMMAND_RPC_GETBLOCKHASH::response& res, epee::json_rpc::error& error_resp, connection_context& cntx) > { > if(!check_core_ready()) > { > error_resp.code = -9; > error_resp.message = "Core is busy"; > return false; > } > if(req.size() != 1) > { > error_resp.code = -1; > error_resp.message = "Wrong parameters, expected height"; > return false; > } > uint64_t h = req[0]; > if(m_core.get_current_blockchain_height() <= h) > { > error_resp.code = -2; > error_resp.message = std::string("To big height: ") + std::to_string(h) + ", current blockchain height = " + std::to_string(m_core.get_current_blockchain_height()); > } > res = string_tools::pod_to_hex(m_core.get_block_id_by_height(h)); > return true; > } > > uint64_t slow_memmem(void* start_buff, size_t buflen,void* pat,size_t patlen) > { > void* buf = start_buff; > void* end=(char*)buf+buflen-patlen; > while((buf=memchr(buf,((char*)pat)[0],buflen))) > { > if(buf>end) > return 0; > if(memcmp(buf,pat,patlen)==0) > return (char*)buf - (char*)start_buff; > buf=(char*)buf+1; > } > return 0; > } > > bool core_rpc_server::on_getblocktemplate(const COMMAND_RPC_GETBLOCKTEMPLATE::request& req, COMMAND_RPC_GETBLOCKTEMPLATE::response& res, epee::json_rpc::error& error_resp, connection_context& cntx) > { > if(!check_core_ready()) > { > error_resp.code = -9; > error_resp.message = "Core is busy"; > return false; > } > > if(req.reserve_size > 255) > { > error_resp.code = -3; > error_resp.message = "To big reserved size, maximum 255"; > return false; > } > > currency::account_public_address acc = boost::value_initialized<decltype(acc)>(); > > if(!req.wallet_address.size() || !currency::get_account_address_from_str(acc, req.wallet_address)) > { > error_resp.code = -4; > error_resp.message = "Failed to parse wallet address"; > return false; > } > > block b = boost::value_initialized<decltype(b)>(); > currency::blobdata blob_reserve; > blob_reserve.resize(req.reserve_size, 0); > if(!m_core.get_block_template(b, acc, res.difficulty, res.height, blob_reserve, req.donate_to_developers? 100:0, alias_info())) > { > error_resp.code = -5; > error_resp.message = "Internal error: failed to create block template"; > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.cpp" << ":" << 367 << "|" << __FUNCTION__ << "|" << "Failed to create block template" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > blobdata block_blob = t_serializable_object_to_blob(b); > crypto::public_key tx_pub_key = null_pkey; > currency::parse_and_validate_tx_extra(b.miner_tx, tx_pub_key); > if(tx_pub_key == null_pkey) > { > error_resp.code = -5; > error_resp.message = "Internal error: failed to create block template"; > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.cpp" << ":" << 377 << "|" << __FUNCTION__ << "|" << "Failed to tx pub key in coinbase extra" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > res.reserved_offset = slow_memmem((void*)block_blob.data(), block_blob.size(), &tx_pub_key, sizeof(tx_pub_key)); > if(!res.reserved_offset) > { > error_resp.code = -5; > error_resp.message = "Internal error: failed to create block template"; > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.cpp" << ":" << 385 << "|" << __FUNCTION__ << "|" << "Failed to find tx pub key in blockblob" << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > res.reserved_offset += sizeof(tx_pub_key) + 3; > if(res.reserved_offset + req.reserve_size > block_blob.size()) > { > error_resp.code = -5; > error_resp.message = "Internal error: failed to create block template"; > { std::stringstream ss________; ss________ << epee::log_space::log_singletone::get_prefix_entry() << "ERROR " << "/c/honeypenny/src/rpc/core_rpc_server.cpp" << ":" << 393 << "|" << __FUNCTION__ << "|" << "Failed to calculate offset for " << std::endl; epee::log_space::log_singletone::do_log_message(ss________.str(), 0, epee::log_space::console_color_red, true, __null);; epee::log_space::log_singletone::get_set_err_count(true, epee::log_space::log_singletone::get_set_err_count()+1);}; > return false; > } > res.blocktemplate_blob = string_tools::buff_to_hex_nodelimer(block_blob); > > return true; > } > > bool core_rpc_server::on_submitblock(const COMMAND_RPC_SUBMITBLOCK::request& req, COMMAND_RPC_SUBMITBLOCK::response& res, epee::json_rpc::error& error_resp, connection_context& cntx) > { > if(!check_core_ready()){res.status = "BUSY";return true;}; > if(req.size()!=1) > { > error_resp.code = -1; > error_resp.message = "Wrong param"; > return false; > } > blobdata blockblob; > if(!string_tools::parse_hexstr_to_binbuff(req[0], blockblob)) > { > error_resp.code = -6; > error_resp.message = "Wrong block blob"; > return false; > } > currency::block_verification_context bvc = boost::value_initialized<decltype(bvc)>(); > m_core.handle_incoming_block(blockblob, bvc); > if(!bvc.m_added_to_main_chain) > { > error_resp.code = -7; > error_resp.message = "Block not accepted"; > return false; > } > res.status = "OK"; > return true; > } > > uint64_t core_rpc_server::get_block_reward(const block& blk) > { > uint64_t reward = 0; > if (boost::foreach_detail_::auto_any_t _foreach_col432 = boost::foreach_detail_::contain( (blk.miner_tx.vout) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((blk.miner_tx.vout), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(blk.miner_tx.vout) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(blk.miner_tx.vout) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_cur432 = boost::foreach_detail_::begin( _foreach_col432 , (true ? 0 : boost::foreach_detail_::encode_type(blk.miner_tx.vout, boost::foreach_detail_::is_const_(blk.miner_tx.vout))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((blk.miner_tx.vout), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(blk.miner_tx.vout) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(blk.miner_tx.vout) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else if (boost::foreach_detail_::auto_any_t _foreach_end432 = boost::foreach_detail_::end( _foreach_col432 , (true ? 0 : boost::foreach_detail_::encode_type(blk.miner_tx.vout, boost::foreach_detail_::is_const_(blk.miner_tx.vout))) , (true ? 0 : boost::foreach_detail_::or_( boost::foreach_detail_::is_rvalue_((blk.miner_tx.vout), 0) , boost::foreach_detail_::and_( boost::foreach_detail_::not_(boost_foreach_is_noncopyable( boost::foreach_detail_::to_ptr(blk.miner_tx.vout) , boost_foreach_argument_dependent_lookup_hack_value)) , boost_foreach_is_lightweight_proxy( boost::foreach_detail_::to_ptr(blk.miner_tx.vout) , boost_foreach_argument_dependent_lookup_hack_value)))))) {} else for (bool _foreach_continue432 = true; _foreach_continue432 && !boost::foreach_detail_::done( _foreach_cur432 , _foreach_end432 , (true ? 0 : boost::foreach_detail_::encode_type(blk.miner_tx.vout, boost::foreach_detail_::is_const_(blk.miner_tx.vout)))); _foreach_continue432 ? boost::foreach_detail_::next( _foreach_cur432 , (true ? 0 : boost::foreach_detail_::encode_type(blk.miner_tx.vout, boost::foreach_detail_::is_const_(blk.miner_tx.vout)))) : (void)0) if (boost::foreach_detail_::set_false(_foreach_continue432)) {} else for (const tx_out& out = boost::foreach_detail_::deref( _foreach_cur432 , (true ? 0 : boost::foreach_detail_::encode_type(blk.miner_tx.vout, boost::foreach_detail_::is_const_(blk.miner_tx.vout)))); !_foreach_continue432; _foreach_continue432 = true) > { > reward += out.amount; > } > return reward; > } > > bool core_rpc_server::fill_block_header_responce(const block& blk, bool orphan_status, block_header_responce& responce) > { > > > responce.major_version = blk.major_version; > responce.minor_version = blk.minor_version; > responce.timestamp = blk.timestamp; > responce.prev_hash = string_tools::pod_to_hex(blk.prev_id); > responce.nonce = blk.nonce; > responce.orphan_status = orphan_status; > responce.height = get_block_height(blk); > responce.depth = m_core.get_current_blockchain_height() - responce.height - 1; > responce.hash = string_tools::pod_to_hex(get_block_hash(blk)); > responce.difficulty = m_core.get_blockchain_storage().block_difficulty(responce.height); > responce.reward = get_block_reward(blk); > return true; > } > > bool core_rpc_server::on_get_last_block_header(const COMMAND_RPC_GET_LAST_BLOCK_HEADER::request& req, COMMAND_RPC_GET_LAST_BLOCK_HEADER::response& res, epee::json_rpc::error& error_resp, connection_context& cntx) > { > if(!check_core_ready()) > { > error_resp.code = -9; > error_resp.message = "Core is busy."; > return false; > } > block last_block = boost::value_initialized<decltype(last_block)>(); > bool have_last_block_hash = m_core.get_blockchain_storage().get_top_block(last_block); > if (!have_last_block_hash) > { > error_resp.code = -5; > error_resp.message = "Internal error: can't get last block hash."; > return false; > } > bool responce_filled = fill_block_header_responce(last_block, false, res.block_header); > if (!responce_filled) > { > error_resp.code = -5; > error_resp.message = "Internal error: can't produce valid response."; > return false; > } > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_get_block_header_by_hash(const COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::request& req, COMMAND_RPC_GET_BLOCK_HEADER_BY_HASH::response& res, epee::json_rpc::error& error_resp, connection_context& cntx){ > if(!check_core_ready()) > { > error_resp.code = -9; > error_resp.message = "Core is busy."; > return false; > } > crypto::hash block_hash; > bool hash_parsed = parse_hash256(req.hash, block_hash); > if(!hash_parsed) > { > error_resp.code = -1; > error_resp.message = "Failed to parse hex representation of block hash. Hex = " + req.hash + '.'; > return false; > } > block blk; > bool have_block = m_core.get_block_by_hash(block_hash, blk); > if (!have_block) > { > error_resp.code = -5; > error_resp.message = "Internal error: can't get block by hash. Hash = " + req.hash + '.'; > return false; > } > if (blk.miner_tx.vin.front().type() != typeid(txin_gen)) > { > error_resp.code = -5; > error_resp.message = "Internal error: coinbase transaction in the block has the wrong type"; > return false; > } > uint64_t block_height = boost::get<txin_gen>(blk.miner_tx.vin.front()).height; > bool responce_filled = fill_block_header_responce(blk, false, res.block_header); > if (!responce_filled) > { > error_resp.code = -5; > error_resp.message = "Internal error: can't produce valid response."; > return false; > } > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_get_block_header_by_height(const COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::request& req, COMMAND_RPC_GET_BLOCK_HEADER_BY_HEIGHT::response& res, epee::json_rpc::error& error_resp, connection_context& cntx){ > if(!check_core_ready()) > { > error_resp.code = -9; > error_resp.message = "Core is busy."; > return false; > } > if(m_core.get_current_blockchain_height() <= req.height) > { > error_resp.code = -2; > error_resp.message = std::string("To big height: ") + std::to_string(req.height) + ", current blockchain height = " + std::to_string(m_core.get_current_blockchain_height()); > return false; > } > block blk = boost::value_initialized<decltype(blk)>(); > bool r = m_core.get_blockchain_storage().get_block_by_height(req.height, blk); > > bool responce_filled = fill_block_header_responce(blk, false, res.block_header); > if (!responce_filled) > { > error_resp.code = -5; > error_resp.message = "Internal error: can't produce valid response."; > return false; > } > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_get_alias_details(const COMMAND_RPC_GET_ALIAS_DETAILS::request& req, COMMAND_RPC_GET_ALIAS_DETAILS::response& res, epee::json_rpc::error& error_resp, connection_context& cntx) > { > if(!check_core_ready()) > { > error_resp.code = -9; > error_resp.message = "Core is busy."; > return false; > } > alias_info_base aib = boost::value_initialized<decltype(aib)>(); > if(!m_core.get_blockchain_storage().get_alias_info(req.alias, aib)) > { > res.status = "Alias not found."; > return true; > } > res.alias_details.address = currency::get_account_address_as_str(aib.m_address); > res.alias_details.comment = aib.m_text_comment; > if(aib.m_view_key != currency::null_skey) > res.alias_details.tracking_key = string_tools::pod_to_hex(aib.m_view_key); > > res.status = "OK"; > return true; > } > > bool core_rpc_server::on_get_all_aliases(const COMMAND_RPC_GET_ALL_ALIASES::request& req, COMMAND_RPC_GET_ALL_ALIASES::response& res, epee::json_rpc::error& error_resp, connection_context& cntx) > { > if(!check_core_ready()) > { > error_resp.code = -9; > error_resp.message = "Core is busy."; > return false; > } > > std::list<currency::alias_info> aliases; > m_core.get_blockchain_storage().get_all_aliases(aliases); > for(auto a: aliases) > { > res.aliases.push_back(alias_rpc_details()); > res.aliases.back().alias = a.m_alias; > res.aliases.back().details.address = currency::get_account_address_as_str(a.m_address); > res.aliases.back().details.comment = a.m_text_comment; > if(a.m_view_key != currency::null_skey) > res.aliases.back().details.tracking_key = string_tools::pod_to_hex(a.m_view_key); > } > res.status = "OK"; > return true; > } > >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 1096488
: 894373